PDA

View Full Version : 3.12 compile errors on FreeBSD 4.5


steve
11-12-2002, 09:25 PM
Well, first off, make doesn't work to compile because I get dependency errors. So I'm using gmake instead.

Here are the errors I get:
[4:22](veeshan@shell3)[~/emu/zone]> gmake
gcc -c -Wall -Wuninitialized -Wwrite-strings -Wcast-qual -Wbad-function-cast -Wstrict-prototypes -Wnested-externs
-Wcomment -Wcast-align -O -ggdb -m486 -pthread -pipe -D_GNU_SOURCE -DINVERSEXY
-DFX -I/usr/include/mysql -I/usr/mysql/include ../common/EQNetwork.cpp -o ../common/EQNetwork.o
../common/EQNetwork.cpp: In method `bool EQNetworkServer::Open(short unsigned int = 0)':
../common/EQNetwork.cpp:112: aggregate `struct sockaddr_in address' has incomplete type and cannot be initialized
../common/EQNetwork.cpp:120: confused by earlier errors, bailing out
gmake: *** [../common/EQNetwork.o] Error 1
And
[4:23](veeshan@shell3)[~/emu/world]> gmake
gcc -c -Wall -Wuninitialized -Wwrite-strings -Wcast-qual -Wbad-function-cast -Wstrict-prototypes -Wnested-externs
-Wcomment -Wcast-align -Winline -Waggregate-return -g -m486 -O3 -pthread -pipe -DFX -D_GNU_SOURCE -DINVERSEXY
-I/usr/include/mysql -I/usr/mysql/include ../common/EQNetwork.cpp -o ../common/EQNetwork.o
In file included from ../common/EQNetwork.cpp:25:
/usr/include/g++/iomanip.h: In method `class smanip<TP> sapp<TP>::operator ()(TP)':
/usr/include/g++/iomanip.h:50: warning: function returns an aggregate
/usr/include/g++/iomanip.h: In method `class imanip<TP> iapp<TP>::operator ()(TP)':
/usr/include/g++/iomanip.h:106: warning: function returns an aggregate
/usr/include/g++/iomanip.h: In method `class omanip<TP> oapp<TP>::operator ()(TP)':
/usr/include/g++/iomanip.h:138: warning: function returns an aggregate
/usr/include/g++/iomanip.h: In function `class smanip<int> setbase(int)':
/usr/include/g++/iomanip.h:171: warning: function returns an aggregate
/usr/include/g++/iomanip.h: In function `class smanip<int> setfill(int)':
/usr/include/g++/iomanip.h:172: warning: function returns an aggregate
/usr/include/g++/iomanip.h: In function `class smanip<int> setprecision(int)':
/usr/include/g++/iomanip.h:173: warning: function returns an aggregate
/usr/include/g++/iomanip.h: In function `class smanip<int> setw(int)':
/usr/include/g++/iomanip.h:174: warning: function returns an aggregate
/usr/include/g++/iomanip.h: In function `class smanip<long unsigned int> resetiosflags(long unsigned int)':
/usr/include/g++/iomanip.h:176: warning: function returns an aggregate
/usr/include/g++/iomanip.h: In function `class smanip<long unsigned int> setiosflags(long unsigned int)':
/usr/include/g++/iomanip.h:177: warning: function returns an aggregate
../common/EQNetwork.cpp: In method `bool EQNetworkServer::Open(short unsigned int = 0)':
../common/EQNetwork.cpp:112: aggregate `struct sockaddr_in address' has incomplete type and cannot be initialized
../common/EQNetwork.cpp:120: confused by earlier errors, bailing out
gmake: *** [../common/EQNetwork.o] Error 1
Any clues?

steve
11-17-2002, 03:14 PM
Anyone? :)

Zafar
11-17-2002, 07:24 PM
The errors that I get during my compilation of EQEmu, I get errors myself. I usually ignore most of them, because they seem more towards Win32 issues--and not Linux/Unix based code; correct me there if I am wrong.



Anyone? :)

steve
11-17-2002, 09:19 PM
It never finishes compiling, it dies and stops on those errors.

seqmage
11-17-2002, 09:59 PM
I am not a linux guru, but working with ShowEQ and getting that compiled, its a good idea to make sure your gcc libs and g++ libs are up to date.

kathgar
11-18-2002, 02:24 AM
We don't have any *bsd code, I have not coded in it yet but it seems atleast the socket struct is different.. also what version of gcc are you using? some of the 3.XX versions have problems

emu3qaz
02-26-2003, 11:29 AM
Try replacing:

unsigned int fromlen;

with:

socklen_t fromlen;

var1ety
02-28-2003, 12:06 PM
eqemu compiles out of the box on freebsd on 0.4.1 .. some more stuff got changed between 0.4.1 and 0.4.2, and again between 0.4.3, so the compile is crapping out.

i used to have a readme file included with the distro detailing what changes had to be made, but that didn't make it over from 0.4.1 to 0.4.2, or something. anyhow, you need linuxthreads installed, as well as mysql stuff, and you need to compile using gmake -f makefilefreebsd. Note, this isn't working atm with 0.4.2, as I mentioned above, but hopefully by 0.4.3 we'll be up and going again.

var1ety
02-28-2003, 01:13 PM
nightly CVS isn't in a state to compile for me yet, maybe in another few days. Gonna try to hook up with some devs so I can get at it before they release so us FreeBSD users won't be out in the cold this time =)

Until then, I'm going to try to attach a diff against 0.4.2-RELEASE to allow it to compile out of the box on FreeBSD (4.8-prelease, at least). My old readme is gone, but I'll briefly summarize it here:

you need to install devel/linuxthreads to compile, in addition to mysql. The relevant headers should automatically put themselves into /usr/local/include/mysql if you don't futz with anything.

you *must* compile with make -f makefilefreebsd

Note: the problems from 0.4.1->0.4.2 consisted entirely of someone moving socket.h before types.h in several files.

as always, grab my patch from:
http://sourceforge.net/tracker/index.php?func=detail&aid=663533&group_id=41381&atid=430534