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 06-03-2009, 05:08 AM
RequiemTCE
Fire Beetle
 
Join Date: Mar 2009
Location: Cambridge, MA
Posts: 7
Default Compile problems under RHEL

System:
2.6.24.5-grsec #1 SMP Thu Dec 18 18:11:30 EST 2008 x86_64 x86_64 x86_64 GNU/Linux

gcc version 4.3.2 20081007 (Red Hat 4.3.2-7) (GCC)

I run into this when attempting to build most of the directories in the source checked out via SVN (Rev 619):

Code:
common/TCPConnection.cpp -o ../common/TCPConnection.o
cc1plus: warning: command line option "-Wdeclaration-after-statement" is valid for C/ObjC but not for C++
../common/TCPConnection.cpp: In member function bool TCPConnection::GetSockName(char*, uint16*):
../common/TCPConnection.cpp:148: error: cannot convert size_t* to socklen_t* for argument 3 to int getsockname(int, sockaddr*, socklen_t*)
make: *** [../common/TCPConnection.o] Error 1
make: Leaving directory `/home/eqemu/incoming/EQEmuServer/zone'
I made some light modifications to the makefiles in each directory to specify an alternate compiler/linker and to remove "-march=i686" from COPTS to prevent: "../common/timer.cpp:1: error: CPU you selected does not support x86-64 instruction set"

Any ideas?
Reply With Quote
  #2  
Old 06-03-2009, 05:21 AM
RequiemTCE
Fire Beetle
 
Join Date: Mar 2009
Location: Cambridge, MA
Posts: 7
Default

I selected GCC 4.3.2 per: http://www.eqemulator.net/forums/sho...89&postcount=7
Reply With Quote
  #3  
Old 06-03-2009, 06:04 AM
RequiemTCE
Fire Beetle
 
Join Date: Mar 2009
Location: Cambridge, MA
Posts: 7
Default

Ok, I've got it compiled now. Here's what I did to make it compile under RHEL/x86_64.

Install GCC 4.3.2:
Code:
yum install gcc43 gcc43-c++
----------------

Modify the following files:

Code:
EMuShareMem/makefile
world/makefile
zone/makefile
eqlaunch/makefile
mailserver/makefile
chatserver/makefile
In each of these, replace all instances of "gcc" with "gcc43", and remove "-march=i686" from the COPTS section(if present).

----------------

Modify utils/Makefile:
Replace all occurances of "g++" with "g++43".

----------------

Modify common/TCPConnection.h as follows:
Code:
#else
        size_t addrlen;
#endif
becomes
Code:
#else
        socklen_t addrlen;
#endif
----------------

Modify common/crc32.cpp as follows:
Code:
//#if !defined(i386)
//#define i386  // If you are on a non-Intel based platform (Sparc/HP/NEC/etc), you will want$
//#endif
becomes
Code:
//#if !defined(i386)
//#define i386  // If you are on a non-Intel based platform (Sparc/HP/NEC/etc), you will want$
//#endif
#undef i386
Reply With Quote
  #4  
Old 06-03-2009, 07:49 AM
gaeorn
Developer
 
Join Date: Apr 2009
Location: USA
Posts: 478
Default

Based on the errors you ran into compiling, I'm guessing you are running a 64bit system. There are other changes needed to get 64bit working properly (and it's still a work in progress). Let me know if I am correct and I'll post some patches for you.
Reply With Quote
  #5  
Old 06-03-2009, 08:52 AM
RequiemTCE
Fire Beetle
 
Join Date: Mar 2009
Location: Cambridge, MA
Posts: 7
Default

Quote:
Originally Posted by gaeorn View Post
Based on the errors you ran into compiling, I'm guessing you are running a 64bit system. There are other changes needed to get 64bit working properly (and it's still a work in progress). Let me know if I am correct and I'll post some patches for you.
I am running it on a 64-bit server yes. The issue I'm having right now is that it times out attempting to load items from the database when launching the world or zone servers.

Also, addendum to above: Copy libEMuShareMem.so into /lib64.

Code:
[Debug] [WORLD__INIT] Loading items..
[Status] libEMuShareMem.so loaded


Error: EMuShareMem: DLLLoadItems: !ItemsMMF.IsLoaded() (timeout)
[Debug] [WORLD__INIT_ERR] Error: Could not load item data.  But ignoring
Reply With Quote
  #6  
Old 06-03-2009, 12:25 PM
gaeorn
Developer
 
Join Date: Apr 2009
Location: USA
Posts: 478
Default

Did you increase the shared memory size for the system? If not, add:

kernel.shmmax = 134217728

to /etc/sysctl.conf and reboot. Otherwise, I have no idea why you would be having problems reading in the items.
Reply With Quote
  #7  
Old 06-16-2009, 11:43 PM
RequiemTCE
Fire Beetle
 
Join Date: Mar 2009
Location: Cambridge, MA
Posts: 7
Default

I just got back to trying to get this working.

From /etc/sysctl.conf:
Code:
# Controls the default maxmimum size of a mesage queue
kernel.msgmax = 65536

# Controls the maximum shared segment size, in bytes
kernel.shmmax = 68719476736

# Controls the maximum number of shared memory segments, in pages
kernel.shmall = 4294967296
You had mentioned some patches, is there a suggested method for going about getting a codebase that will work in 64-bit?
Reply With Quote
  #8  
Old 06-17-2009, 01:10 PM
gaeorn
Developer
 
Join Date: Apr 2009
Location: USA
Posts: 478
Default

If you look in these forums under development: code submissions, there is a list of patches for 64bit systems I have submitted to be included in the code base.
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 07:44 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