Tremulous Forum
General => Troubleshooting => Topic started by: dodo1122 on July 11, 2007, 09:35:17 pm
-
This is what i get when compiling trem on my gentoo with gcc-4.2.0 and glibc-2.6:
dominic@gentoo trunk % make
make -C src/tools/lcc install
make[1]: Entering directory `/home/dominic/trunk/src/tools/lcc'
install -s -m 0755 build-linux-x86/q3lcc ../
install -s -m 0755 build-linux-x86/q3cpp ../
install -s -m 0755 build-linux-x86/q3rcc ../
make[1]: Leaving directory `/home/dominic/trunk/src/tools/lcc'
make -C src/tools/asm install
make[1]: Entering directory `/home/dominic/trunk/src/tools/asm'
gcc -O2 -Wall -Werror -fno-strict-aliasing -o q3asm q3asm.c cmdlib.c
cc1: warnings being treated as errors
cmdlib.c: In function ‘ExpandPath’:
cmdlib.c:316: warning: the address of ‘qdir’ will always evaluate as ‘true’
cmdlib.c: In function ‘ExpandGamePath’:
cmdlib.c:329: warning: the address of ‘qdir’ will always evaluate as ‘true’
make[1]: *** [q3asm] Error 1
make[1]: Leaving directory `/home/dominic/trunk/src/tools/asm'
make: *** [tools] Error 2
I recompiled my whole system with these two is well, without any errors.
This is SVN954.
I tried to set the CFLAGS back to normal in the Makefile, but that did not obviously help. Tried different svn checkouts, still the same.
I recompiled my whole system with these two is well, without any errors.
The problem from what i see is
cc1: warnings being treated as errors
Now, why? :P
Anyone can help?
dodo
-
stop making gentoo compile with -Werror
-
i am not. I haven't changed the Makefile, and none of my system flags have that (which are not used while compiling trem anyway iirc).
It is clean SVN that i am compiling, and it still fails.
dodo
-
i am not. I haven't changed the Makefile, and none of my system flags have that (which are not used while compiling trem anyway iirc).
It is clean SVN that i am compiling, and it still fails.
dodo
Go look in the log you posted, -Werror is right there. Remove it?
-
GCC has found a real bug, it should be
if (!qdir[0])
instead of
if (!qdir)
qdir is really always true because it's global array of 1024 chars. According to the comment, the condition which GCC refuses to compile tests the string in qdir, not the adress of the array itself.
And dodo, don't use stuff which is not yet available for public testing.
-
why not? :P gcc-4.2.0 will be shortly in the gentoo's portage tree(keyworded), and right now its working pretty stable for me, and so is glibc-2.6 . As i've mentioned, i recompiled my whole system with it, and not a single serious error appeared. This is the first "bug" i have encountered while using gcc-4.2.0 & glibc-2.6. And i would like to point out that gcc-4.2.0 is actually marked as stable. Its not like im using gcc-4.3.0, although i would love to (-march=core2 being the main reason).
dodo
-
GCC has found a real bug, it should be
if (!qdir[0])
instead of
if (!qdir)
qdir is really always true because it's global array of 1024 chars. According to the comment, the condition which GCC refuses to compile tests the string in qdir, not the adress of the array itself.
And dodo, don't use stuff which is not yet available for public testing.
that bug is fixed upstream already.
-
heh, so i'll wait till tomorrow and upgrade gcc to 4.2.1 ;-)
dodo