PDA

View Full Version : GCC 3.4.6 or GCC 4.3.x


cubber
05-07-2009, 01:16 PM
I have noticed in the past that when compiling the server on Gentoo Linux with GCC 4.x.x I would get a lot of ghosting, jumping, and warping mobs as seen in this post http://www.eqemulator.net/forums/showthread.php?t=27234 . However when I compiled the server under GCC 3.4.6 I would not get these issues. I have since dedicated a machine to eqemu which only uses Gentoo and GCC 3.4.6.

However, now I would like to use the machine for other things that require GCC 4.3.x and would like to know if the issues I experienced with GCC 4.x.x are now gone or if they are still present?

If anyone could respond with their latest experiences with Linux preferably Gentoo and compiling and using the EQEMU server under GCC 4.3.x it would be much appreciated.

I would hate to take the time to rebuild my server under GCC 4.3.x then go to install the emulater only to find the same issues are still there.

Thanks...

cubber
05-08-2009, 10:45 AM
I am trying to build this on a test machine with:

i686-pc-linux-gnu-4.3.3

World fails to build with the following output:

ccache gcc -c -Wall -Wuninitialized -Wwrite-strings -Wcast-qual -Wcomment -Wcast-align -Wno-deprecated -march=native -O2 -pthread -pipe -I../common/SocketLib -DFX -D_GNU_SOURCE -DINVERSEXY -DWORLD -DDEBUG=5 -DEQDEBUG=5 -DSHAREMEM -DCATCH_CRASH -DNO_PIDLOG -DFIELD_ITEMS -DIRC -Di386 -DAPP_OPCODE_SIZE=2 -DEQBOTS -DEMBPERL -DEMBPERL_PLUGIN -DHAS_UNION_SEMUN -I/usr/include/mysql -DHAVE_ERRNO_AS_DEFINE=1 -fno-strict-aliasing -pipe -Wdeclaration-after-statement -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -I/usr/lib/perl5/5.8.8/i686-linux/CORE client.cpp -o client.o
cc1plus: warning: command line option "-Wdeclaration-after-statement" is valid for C/ObjC but not for C++
client.cpp: In member function 'bool Client::HandlePacket(const EQApplicationPacket*)':
client.cpp:578: error: 'INT_MAX' was not declared in this scope
client.cpp: In function 'bool CheckCharCreateInfo(CharCreate_Struct*)':
client.cpp:1271: warning: comparison between signed and unsigned integer expressions
client.cpp:1271: warning: comparison between signed and unsigned integer expressions
client.cpp:1276: warning: comparison between signed and unsigned integer expressions
client.cpp:1276: warning: comparison between signed and unsigned integer expressions
client.cpp:1281: warning: comparison between signed and unsigned integer expressions
client.cpp:1281: warning: comparison between signed and unsigned integer expressions
client.cpp:1286: warning: comparison between signed and unsigned integer expressions
client.cpp:1286: warning: comparison between signed and unsigned integer expressions
client.cpp:1291: warning: comparison between signed and unsigned integer expressions
client.cpp:1291: warning: comparison between signed and unsigned integer expressions
client.cpp:1296: warning: comparison between signed and unsigned integer expressions
client.cpp:1296: warning: comparison between signed and unsigned integer expressions
client.cpp:1301: warning: comparison between signed and unsigned integer expressions
client.cpp:1301: warning: comparison between signed and unsigned integer expressions
make[1]: *** [client.o] Error 1
make[1]: Leaving directory `/usr/src/eqemu/core/trunk/EQEmuServer/world'
make: *** [all] Error 2


This is building the latest svn Rev 483 which builds fine on my machine with gcc 3.4.6.

Kobaz
05-08-2009, 05:02 PM
On my Debian machine I set up a chroot that has the older build chain in it to resolve this problem.

cubber
05-08-2009, 08:14 PM
Thanks for the reply. On gentoo I can have multiple GCC installations running on the same server. They are slotted and I would use gcc-config to switch between them. I actually wrote a guide on how to do it a long time ago on these forums.

I just dug it up here: http://www.eqemulator.net/forums/showpost.php?p=126383&postcount=17

Gonna just go that route again. I was hoping to not have to have multiple GCC's installed but guess it is best for compatability reasons.

erde
05-09-2009, 04:09 AM
INT_MAX is defined in limits.h. i think there is a
#include <limits.h>
missing.

http://en.wikipedia.org/wiki/Limits.h

Xelaan
05-18-2009, 10:36 AM
I just compiled a few minutes ago using the latest SVN (whatever is there today 5-18-2009) and I did receive some warnings I did get a succesfull compile. I do not have the rest of the server running yet though so i cannot speak to ghosting or other issues.

I compiled using gcc version 4.3.2 (Debian 4.3.2-1.1)

Jim

cubber
05-31-2009, 10:41 PM
I was just able to compile the instance branch Rev610 successfully with

gcc version 4.3.2 (Gentoo 4.3.2-r3 p1.6, pie-10.1.5)

I also tested the install and found no ghosting, jumping or warping mobs so far like I had experienced before in earlier attempts using gcc 4.x.x

I actually compiled using this gcc version by accident cause I never switched back to 3.4.6 before I ran make. I realized after it was done and figured..

"hey it actually compiled, maybe I should test it!"