Can't Compile Gpu940


efegea

Active Member
Joined
Aug 8, 2005
Messages
636
Age
39
Location
GP32Spain, Spain
After a while I decided to start coding again, for the GBAX compo.

But gpu940 fails to compile

CODE
/usr/local/open2x/bin/open2x-ld -o gpu940.elf -L../console -L../perftime -L../lib -L/usr/local/open2x/lib/gcc/arm-gp2x-linux/3.4.6 -L/usr/local/open2x/lib/gcc/open2x/4.0.2 -T script.ld -N -s
gpu940.o: In function `next_log_2':
/home/frajan/cvs/gpu940/bin/gpu940.c:206: undefined reference to `__assert_fail'
gpu940.o: In function `next_cmd':
/home/frajan/cvs/gpu940/bin/gpu940.c:287: undefined reference to `__assert_fail'
clip.o: In function `clip_poly':
/home/frajan/cvs/gpu940/bin/clip.c:63: undefined reference to `__assert_fail'
/home/frajan/cvs/gpu940/bin/clip.c:110: undefined reference to `__assert_fail'
codegen.o: In function `add_patch':
/home/frajan/cvs/gpu940/bin/codegen.c:316: undefined reference to `__assert_fail'
codegen.o:/home/frajan/cvs/gpu940/bin/codegen.c:341: more undefined references to `__assert_fail' follow
make[2]: *** [gpu940] Error 1
make[2]: Leaving directory `/home/frajan/cvs/gpu940/bin'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/frajan/cvs/gpu940'
make: *** [all] Error 2
 
efegea said:
CODE

/home/frajan/cvs/gpu940/bin/gpu940.c:206: undefined reference to `__assert_fail'
gpu940.o: In function `next_cmd':

(Didn't read it, wnet to sleep at 6:33am, so..)

Are you using ASSERT() or assert() or the like? (Or depending on code that does)? Maybe you can avoid it, or supply the __assert_fail handler?

jeff
 
Last edited by a moderator:
Grab the precompiled version.

It might be that you have an older gcc (3.x).

Good luck. Any hints on what you are working on?
 
mth411 said:
Grab the precompiled version.

It might be that you have an older gcc (3.x).

Good luck. Any hints on what you are working on?
I have a 4.0.2 gcc from open2x project, I have compiled gpu940 before, but now I can't.

I prefer to compile the CVS version than using precompiled binaries.


I'm working in a 3D engine for a game. I have not touched the code in a while (about 4 or 5 months) but now I'm going to code again for the GBAX, well, I want to, because I'm laaaazyy. The actual code can show animated Quake2 models on the GP2X :) But now I'm going to rewrite it...

Oh, and the game...my original idea was a survival horror game.
 
Last edited by a moderator:
efegea said:
CODE
/usr/local/open2x/bin/open2x-ld -o gpu940.elf -L../console -L../perftime -L../lib -L/usr/local/open2x/lib/gcc/arm-gp2x-linux/3.4.6 -L/usr/local/open2x/lib/gcc/open2x/4.0.2 -T script.ld -N -s
gpu940.o: In function `next_log_2':
/home/frajan/cvs/gpu940/bin/gpu940.c:206: undefined reference to `__assert_fail'

Here, you are compiling for the gp2x. In general, when compiling for the GP2X, I always define NDEBUG, so that all the assert() calls vanish. Normally, the gp2xenv.sh scripts does this, by defined CFLAGS with "-DNDEBUG" (amongst many other things).

I suggest you source this script before running make.

I also suggest you give a try to the gpu940 user mailing list if you plan to work with the lib
(https://mail.gna.org/listinfo/gpu940-users/)
 
Last edited by a moderator:
rixed said:
Here, you are compiling for the gp2x. In general, when compiling for the GP2X, I always define NDEBUG, so that all the assert() calls vanish. Normally, the gp2xenv.sh scripts does this, by defined CFLAGS with "-DNDEBUG" (amongst many other things).

I suggest you source this script before running make.
I already did that. I have compiled gpu940 a lot of times :lol:

rixed said:
I also suggest you give a try to the gpu940 user mailing list if you plan to work with the lib
(https://mail.gna.org/listinfo/gpu940-users/)
I'm suscribed to the list. But there is not traffic since a few months ago, or I am unsuscribed?

I sent a mail to the list a few months ago but never got answer :blink: (the subject was: "black screen")
 
Last edited by a moderator:
efegea said:
rixed said:
Normally, the gp2xenv.sh scripts does this, by defining CFLAGS with "-DNDEBUG" (amongst many other things).
I suggest you source this script before running make.
I already did that. I have compiled gpu940 a lot of times :lol:



So you have a NDEBUG preprocessor constant defined ? But gcc nonetheless introduces some calls to __assert_fail() ??
That's very surprising.

efegea said:
rixed said:
I also suggest you give a try to the gpu940 user mailing list if you plan to work with the lib
(https://mail.gna.org/listinfo/gpu940-users/)
I'm suscribed to the list. But there is not traffic since a few months ago, or I am unsuscribed?



Yes, there are no traffic since several months.
Probably because there are no more bugs anymore :)
Or because I didn't implement much new things lately :-(

efegea said:
I sent a mail to the list a few months ago but never got answer :blink: (the subject was: "black screen")
Yeah your mail is in the archive. I remember having read it (and I think I fixed the problem in the Makefiles you
reported at that time), but you are right that nobody inquired much about your black screen problem.
Does it still occur ?
 
Last edited by a moderator:
I have solved the problem, now compiles and works (no black screen!) It was a problem with my modifications of the gp2xenv file. I had commented out the CFLAGS line >_<
 
Back
Top