Go Back   EQEmulator Home > EQEmulator Forums > Support > Support::Linux Servers

Support::Linux Servers Support forum for Linux EQEMu users.

Reply
 
Thread Tools Display Modes
  #1  
Old 07-05-2005, 02:56 PM
loser
Fire Beetle
 
Join Date: Jun 2005
Posts: 9
Default Compiling Problems do not want to end

Hi all,

i have a big big problem.
Since 1 and a half week it try to find a way to get my files compiled.
Alot of ppl already gave me some advice but still not able to fix my stuff.

I will paste my errors here so you can help me, if you can and want.

EMuShareMem Compile:

>>>make clean
rm -f MMFMutex.o Doors.o Items.o Spells.o NPCFactionLists.o MMF.o Loot.o ../common/timer.o ../common/unix.o ../common/EMuShareMem.o libEMuShareMem.so<<< so far so good

>>>make
gcc -Wall -Wuninitialized -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wno-deprecated -Wcomment -Wcast-align -DDEBUG=1 -DSHAREMEM -DCATCH_CRASH -DEMUSHAREMEM -g -fPIC -O2 -D_GNU_SOURCE -DINVERSEXY -DFX `mysql_config --cflags` -c MMFMutex.cpp -o MMFMutex.o
cc1plus: warning: command line option "-Wstrict-prototypes" is valid for Ada/C/ObjC but not for C++
gcc -Wall -Wuninitialized -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wno-deprecated -Wcomment -Wcast-align -DDEBUG=1 -DSHAREMEM -DCATCH_CRASH -DEMUSHAREMEM -g -fPIC -O2 -D_GNU_SOURCE -DINVERSEXY -DFX `mysql_config --cflags` -c Doors.cpp -o Doors.o
cc1plus: warning: command line option "-Wstrict-prototypes" is valid for Ada/C/ObjC but not for C++
gcc -Wall -Wuninitialized -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wno-deprecated -Wcomment -Wcast-align -DDEBUG=1 -DSHAREMEM -DCATCH_CRASH -DEMUSHAREMEM -g -fPIC -O2 -D_GNU_SOURCE -DINVERSEXY -DFX `mysql_config --cflags` -c Items.cpp -o Items.o
cc1plus: warning: command line option "-Wstrict-prototypes" is valid for Ada/C/ObjC but not for C++
gcc -Wall -Wuninitialized -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wno-deprecated -Wcomment -Wcast-align -DDEBUG=1 -DSHAREMEM -DCATCH_CRASH -DEMUSHAREMEM -g -fPIC -O2 -D_GNU_SOURCE -DINVERSEXY -DFX `mysql_config --cflags` -c Spells.cpp -o Spells.o
cc1plus: warning: command line option "-Wstrict-prototypes" is valid for Ada/C/ObjC but not for C++
In file included from ../zone/client.h:38,
from ../zone/masterentity.h:6,
from Spells.cpp:13:
../zone/../common/Item.h:261: error: `sint16 Inventory::_PutItem(sint16, ItemInst*)' is protected
../zone/../common/Item.h:453: error: within this context
../zone/../common/Item.h:264: error: `sint16 Inventory::_HasItem(std::map<sint16, ItemInst*, std::less<sint16>, std::allocator<std::pair<const sint16, ItemInst*> > >&, const Item_Struct*, uint' is protected
../zone/../common/Item.h:514: error: within this context
../zone/../common/Item.h:266: error: `sint16 Inventory::_HasItemByUse(std::map<sint16, ItemInst*, std::less<sint16>, std::allocator<std::pair<const sint16, ItemInst*> > >&, uint8, uint' is protected
../zone/../common/Item.h:516: error: within this context
../zone/../common/Item.h:261: error: `sint16 Inventory::_PutItem(sint16, ItemInst*)' is protected
../zone/../common/Item.h:523: error: within this context
make: *** [Spells.o] Error 1 >>> BIG PROBLEM

Zone Compile:

<<<make
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/EQNetwork.cpp -o ../common/EQNetwork.o
cc1plus: warning: command line option "-Wstrict-prototypes" is valid for Ada/C/ObjC but not for C++
../common/EQNetwork.cpp: In function `type HI_LOSWAPlong(type)':
../common/EQNetwork.cpp:73: error: `a' undeclared (first use this function)
../common/EQNetwork.cpp:73: error: (Each undeclared identifier is reported only once for each function it appears in.)
../common/EQNetwork.cpp:73: error: no matching function for call to `LO_WORD(<type error>)'
../common/EQNetwork.cpp:73: error: there are no arguments to `HIWORD' that depend on a template parameter, so a declaration of `HIWORD' must be available
../common/EQNetwork.cpp:73: error: (if you use `-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated)
make: *** [../common/EQNetwork.o] Error 1>>>

World COMPILE:

<<<gcc -c -Wall -Wuninitialized -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wcomment -Wcast-align -Winline -Wno-deprecated -g -march=i686 -O -pthread -pipe -DFX -D_GNU_SOURCE -DINVERSEXY -DWORLD -DDEBUG=5 -DSHAREMEM -DCATCH_CRASH -DNO_PIDLOG -DFIELD_ITEMS -I/usr/include/mysql -I/usr/mysql/include ../common/EQNetwork.cpp -o ../common/EQNetwork.o
cc1plus: warning: command line option "-Wstrict-prototypes" is valid for Ada/C/ObjC but not for C++
../common/EQNetwork.cpp: In function `type HI_LOSWAPlong(type)':
../common/EQNetwork.cpp:73: error: `a' undeclared (first use this function)
../common/EQNetwork.cpp:73: error: (Each undeclared identifier is reported only once for each function it appears in.)
../common/EQNetwork.cpp:73: error: no matching function for call to `LO_WORD(<type error>)'
../common/EQNetwork.cpp:73: error: there are no arguments to `HIWORD' that depend on a template parameter, so a declaration of `HIWORD' must be available
../common/EQNetwork.cpp:73: error: (if you use `-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated)
make: *** [../common/EQNetwork.o] Error 1>>>


Ok whats wrong with it?

Please help me )
Reply With Quote
  #2  
Old 07-05-2005, 11:32 PM
zelgar
Fire Beetle
 
Join Date: Jul 2004
Location: Traverse City, MI
Posts: 27
Default

The first part of that is fairly straightforward. Use your favorite editor (VIM all the way... down with EMacs!) to edit ./source/common/Item.cpp, and change line 271 to public instead of protected. (I haven't found any problems with doing it this way, if it's going to mess things up, the devs are sure to let me know)

As for the Network.cpp problems, the stem from an incorrect declaration statement. Again, use your favorite VIM on ./source/common/EQNetwork.cpp, and change the first part of line 80 to be "a" instead of "x"
Code:
type HI_LOSWAPlong (type a) ...

Hope it helps.
__________________
MUDding: the process of getting dirty in wet dirt; Driving big trucks through muddy two-tracks; Multi-User Dimension.

Admin of Dark Rifts (MUD)
darkrifts.org port 5000

Last edited by zelgar; 07-06-2005 at 07:35 AM..
Reply With Quote
  #3  
Old 07-06-2005, 01:16 PM
loser
Fire Beetle
 
Join Date: Jun 2005
Posts: 9
Default )

Thx for trying to help me.

but looks like that it create more errors.

i check again later if i made a mistake.

Loser
Reply With Quote
  #4  
Old 07-06-2005, 03:19 PM
zelgar
Fire Beetle
 
Join Date: Jul 2004
Location: Traverse City, MI
Posts: 27
Default

It's not that it created more errors, it's that it allowed errors further in the code to be displayed. Compiling an object is a sequential event, if it can not proceed beyond Point A, that is all you will see. As soon as Point A is good, it can reach Point B, and so on.

I had quite a few innumerable errors with the CVS pull of the source that I got, the only ones I had a hard time getting fixed up were with EQNetwork.cpp. I hope your luck is better than mine.
__________________
MUDding: the process of getting dirty in wet dirt; Driving big trucks through muddy two-tracks; Multi-User Dimension.

Admin of Dark Rifts (MUD)
darkrifts.org port 5000
Reply With Quote
  #5  
Old 07-06-2005, 07:46 PM
loser
Fire Beetle
 
Join Date: Jun 2005
Posts: 9
Default (

just kill me )

Hey i think you have some ideas ... are u in IRC?
Reply With Quote
  #6  
Old 07-06-2005, 11:12 PM
zelgar
Fire Beetle
 
Join Date: Jul 2004
Location: Traverse City, MI
Posts: 27
Default

Nope. I primarily just dabble here and there. I'm actually just as lost as the next guy. However, I've been programming for roughly 12 years, but just starting to get a hold of C/C++, so I can figure some things out at this point.
__________________
MUDding: the process of getting dirty in wet dirt; Driving big trucks through muddy two-tracks; Multi-User Dimension.

Admin of Dark Rifts (MUD)
darkrifts.org port 5000
Reply With Quote
  #7  
Old 07-07-2005, 04:33 AM
Cisyouc
Demi-God
 
Join Date: Jun 2004
Location: Heaven.
Posts: 1,260
Default

Quote:
(VIM all the way... down with EMacs!)
nano ftw .
__________________
namespace retval { template <class T> class ReturnValueGen { private: T x; public: ReturnValueGen() { x = 0; }; T& Generator() { return x; }; }; } int main() { retval::ReturnValueGen<int> retvalue; return retvalue.Generator(); }
C++ is wonderful.
Reply With Quote
  #8  
Old 07-07-2005, 08:16 AM
Doodman's Avatar
Doodman
Developer
 
Join Date: Aug 2003
Posts: 246
Default

What version of gcc? I've heard reports of problems with gcc 4.

gcc --version

will tell you.
Reply With Quote
  #9  
Old 07-07-2005, 02:01 PM
loser
Fire Beetle
 
Join Date: Jun 2005
Posts: 9
Default gcc

Hi Doodman,

well my gcc is 3.4.3. 2050227
Reply With Quote
  #10  
Old 07-08-2005, 02:45 AM
zelgar
Fire Beetle
 
Join Date: Jul 2004
Location: Traverse City, MI
Posts: 27
Default

I'm running gcc 4.0.0, and had TONS error call-outs following correction of the x -> a in EQNetwork.cpp

I was fairly certain that it was a 4.0.0 issue however, since that is the only thing I could find.
__________________
MUDding: the process of getting dirty in wet dirt; Driving big trucks through muddy two-tracks; Multi-User Dimension.

Admin of Dark Rifts (MUD)
darkrifts.org port 5000
Reply With Quote
  #11  
Old 07-08-2005, 10:31 AM
zelgar
Fire Beetle
 
Join Date: Jul 2004
Location: Traverse City, MI
Posts: 27
Default

I'm not sure yet if it will make a difference, but the GNU team released gcc 4.0.1 yesterday.
__________________
MUDding: the process of getting dirty in wet dirt; Driving big trucks through muddy two-tracks; Multi-User Dimension.

Admin of Dark Rifts (MUD)
darkrifts.org port 5000
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 11:41 AM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3