i used -O4 already so it is exist and -O3 compiled my all gentoo system so it`s not so dangoures .
i tried the same thing in crosscompiling and got the same thing it start eating my all mem(512 MegaByte RAM + 512MegaByte Swap).
it`s a gcc bug.
just anyone that have cross compile SDK do this:
1.go to vba sourceforge site and download 1.7.2 source
2.configure with:
LDFLAGS="-Wl,-rpath-link,/opt/arm/3.3.2/armv5tel-cacko-linux/X11R6/lib" ./configure --host=armv5tel-cacko-linux --build=i686-linux --x-includes=/opt/arm/3.3.2/armv5tel-cacko-linux/X11R6/include --x-libraries=/opt/arm/3.3.2/armv5tel-cacko-linux/X11R6/lib --disable-debug --prefix=/usr CFLAGS="-g -O4 -mcpu=iwmmxt -mtune=iwmmxt" CXXFLAGS="-O4 -mcpu=iwmmxt -mtune=iwmmxt"
you can try -O2 or -O3 if you want it still willn`t work.
if it work or doesn`t work post here i want to see if i am the only one that have that problem
EDIT:the error that i get is:
armv5tel-cacko-linux-g++: Internal error: Killed (program cc1plus)
Please submit a full bug report.
See for instructions.
make[2]: *** [GBA.o] Error 1
make[2]: Leaving directory `/home/uriel/VisualBoyAdvance-1.7.2/src/sdl'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/uriel/VisualBoyAdvance-1.7.2/src'
make: *** [all-recursive] Error 1
if you read file INSTALL in vba src you will see that if you use gcc 2.9.5 you should not enable optimazions(coz it will hang on GBA,cpp which is true) ,but we have 3.4.4 maybe the same bug is still in our 3.4.4?