Some Errors...
I'm having a problem compiling the "net.cpp" file:
When I run make in the zone directory, I get this at the end of the output: Quote:
The closest I could find to a replication of the problem was this post, and I'm not running SuSE. (Slackware for me! ;)) Any ideas? |
What gcc version are you using?
(gcc --version) |
3.3.4
Here's the full output, if it helps any: Quote:
|
Comment out the code declaring strsep in net.cpp. Let it use the function already on your system, and see if that doesn't work.
|
Thanks, that got me past that part. Now it just throws this error:
Quote:
Code:
CC=gcc Quote:
|
Just a guess, but edit the makefile you're using, and look at the "SF" variable. Try adding "../common/opcodemgr.o", "../common/emu_opcodes.o", and "../common/EQPacket.o" to it if they're not there already.
You may also be able to just do "make -f makefile.bsd" (always seemed to be more updated) instead. If neither of those work, you'll have to find which file has "OpcodeNames" defined in it. |
How to fix linker errors
Quote:
This is a common problem with development code in many projects. To resolve it (OK, bad joke I know!) use grep: Code:
cd ${your_source_directory} Check that it's not in the "APP" line in the makefile. Then APPEND it to that line. Rerun "make clean && make". Either that fixes it (and possibly another link error shows itself) or it doesnt, in which case you replace the thing you added to the makefile with another likely suspect. Note that not knowing this kind of stuff suggests you are a bit out of your depth, and a course or decent book on C++ might be a good idea. There's some decent stuff in the LDP (Programming HOWTO for example )to read if you are very bright. |
Thanks, Bleh, adding those files worked. :)
I ended up with two more errors, but I somehow managed to fix them myself, as they were similar to the previous ones. The first one was this: Code:
gcc -c -Wall -Wuninitialized -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wno-deprecated -Wcomment -Wcast-align -O2 -ggdb -pthread -pipe -D_GNU_SOURCE -DINVERSEXY -DFX -DZONE -DEQDEBUG=5 -DNO_PIDLOG -DSHAREMEM -DSPELL_EFFECT_SPAM -DFIELD_ITEMS `mysql_config --cflags` ../common/EQPacket.cpp -o ../common/EQPacket.o Code:
void EQPacket::DumpRaw(FILE *to) const Code:
void dump_message_column(unsigned char *buffer, unsigned long length, string leader); The second was: Code:
../common/EQPacket.o(.text+0x10fa): In function `EQProtocolPacket::ValidateCRC(unsigned char const*, int, unsigned)': However, I ran into another error trying to run world: Quote:
I can't figure out why it would be trying to load a DLL when I'm running this on Linux... Quote:
I am looking into some books, though. (Judging from reviews, C++ Primer Plus looks good...) |
All times are GMT -4. The time now is 08:05 AM. |
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.