Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 31 Aug 2010 10:39:36 +0200
From:      =?ISO-8859-1?Q?Ren=E9_Ladan?= <r.c.ladan@gmail.com>
To:        freebsd ports <freebsd-ports@freebsd.org>
Subject:   devel/sdl12 and gcc -m32
Message-ID:  <AANLkTi=TX_=NkGdVVUKhbNg_oV0BaK580A%2Buxua7nj2Z@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Hi,

I was trying to build the future port games/avp-demo (ports/138806) on
my 9.0-amd64 laptop
with system gcc, but this failed because of SDL errors:

gcc -m32 -g -Wall -pipe -Isrc -Isrc/include -Isrc/win95 -Isrc/avp
-Isrc/avp/win95 -Isrc/avp/support -Isrc/avp/win95/frontend
-Isrc/avp/win95/gadgets -I/usr/local/include/SDL -I/usr/local/include
-D_GNU_SOURCE=1 -D_REENTRANT -I/usr/local/include -c -o src/main.o
src/main.c
In file included from /usr/local/include/SDL/SDL_main.h:26,
from /usr/local/include/SDL/SDL.h:30,
from src/main.c:6:
/usr/local/include/SDL/SDL_stdinc.h:131: error: size of array
'SDL_dummy_uint64' is negative
/usr/local/include/SDL/SDL_stdinc.h:132: error: size of array
'SDL_dummy_sint64' is negative

Note the -m32 flag passed to gcc, which is used to force generating
32-bit code on 64-bit
platforms. The flag is set in the Makefile of the game itself. When I
removed the flag I ran into
code snippets which would need a rewrite for 64-bit platforms
(typecasting, extending hash
functions on pointers, etc).

I guess SDL is tellng that I cannot have 64-bit values on a 32-bit
target when I have devel/sdl12
compiled as the native 64-bit version. Is this a limitation of SDL itself?

Regards,
Rene
-- 
http://www.rene-ladan.nl/

GPG fingerprint = E738 5471 D185 7013 0EE0  4FC8 3C1D 6F83 12E1 84F6
(subkeys.pgp.net)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?AANLkTi=TX_=NkGdVVUKhbNg_oV0BaK580A%2Buxua7nj2Z>