FreeOrion

Forums for the FreeOrion project
It is currently Sun May 26, 2013 3:03 am

All times are UTC




Post new topic Reply to topic  [ 7 posts ] 
Author Message
 Post subject: API Error
PostPosted: Mon Mar 24, 2008 6:28 pm 
Offline
Space Krill

Joined: Mon Mar 24, 2008 6:24 pm
Posts: 3
Hi,

compiled from source, on amd64 gentoo 2.6.24.
When i start the game, it closes after generating the galaxy with this lines:

deepsliver@box ~ $ less .freeorion/freeorion.log
2008-03-24 19:04:25,716 ERROR Client : Unable to initialise OpenAL device:
2008-03-24 19:04:25,821 DEBUG Client : SDLInit() complete.
2008-03-24 19:04:25,822 DEBUG Client : GLInit() complete.
2008-03-24 19:04:26,104 DEBUG Client : Limited FPS to 60
2008-03-24 19:05:20,543 ERROR Client : ClientNetworking::NetworkingThread() : Networking thread will be terminated due to disconnect exception "API error"
2008-03-24 19:05:27,701 ERROR Client : HumanClientFSM : A Disconnection event was passed to the HumanClientFSM. This event is illegal in the FSM's current state. It is being ignored.
2008-03-24 19:05:32,620 DEBUG Client : Initiating Exit (code 1 - error termination)
2008-03-24 19:05:32,659 ERROR Client : ClientNetworking::NetworkingThread() : Networking thread will be terminated due to disconnect exception "API error"
2008-03-24 19:05:33,631 DEBUG Client : SDLQuit() complete.

any idea which api is involved here?

tnx
deepsliver


Top
 Profile  
 
 Post subject: Re: API Error
PostPosted: Mon Mar 24, 2008 7:23 pm 
Offline
Programming Lead Emeritus
User avatar

Joined: Thu Jun 26, 2003 1:33 pm
Posts: 1092
I have no idea what the problem is specifically, but that "API error" is coming from Boost.Asio. In general, I would be surprised if either Asio or FO were able to be successfully built and run as 64-bit code.


Top
 Profile  
 
 Post subject: Re: API Error
PostPosted: Tue Mar 25, 2008 7:31 am 
Offline
Static Linker
User avatar

Joined: Thu Jun 28, 2007 10:28 am
Posts: 347
I don't think that running on a amd64-kernel does make much difference.

Is $HOME/freeorion the directory where you compiled the app, or is it an installation-path.

If the latter, try running the app inside the source-directory.

You could try to run the statically linked version, see here:
http://psitronic.de/div/FO/

normally you would download "latest.tar.gz" :-)


Top
 Profile  
 
 Post subject: Re: API Error
PostPosted: Tue Mar 25, 2008 10:07 am 
Offline
Space Krill

Joined: Mon Mar 24, 2008 6:24 pm
Posts: 3
Hello kroddn,
thank you for the static version. It won't run here because of missing a library:

deepsliver@box ~/tmp/freeorion/static/freeorion $ ldd freeorionca
linux-gate.so.1 => (0xffffe000)
libpython2.4.so.1.0 => not found
libpthread.so.0 => /lib32/libpthread.so.0 (0xf7ec3000)
libc.so.6 => /lib32/libc.so.6 (0xf7d8e000)
/lib/ld-linux.so.2 (0xf7f08000)
deepsliver@box ~/tmp/freeorion/static/freeorion $ locate libpython2.4.so.1.0
/usr/lib64/libpython2.4.so.1.0
deepsliver@box ~/tmp/freeorion/static/freeorion $ ls -l /usr/lib64/libpython2.4.so.1.0
-r-xr-xr-x 1 root root 1157152 Feb 12 14:09 /usr/lib64/libpython2.4.so.1.0

as you can see, it is there, but can not be found from freeorionca


If i run from source directory, i get this:

deepsliver@box ~/tmp/freeorion/FreeOrion $ ./freeorion
open /dev/[sound/]dsp: No such file or directory
HumanClientApp::HandleMessage(HOST_SP_GAME)
HumanClientApp::HandleMessage(GAME_START)
HumanClientApp::HandleSaveGameDataRequest(SAVE_GAME)
Received save game data from player Happy_Player ... 0 orders received
Received save game data from player AI_2 ... 0 orders received
Received save game data from player AI_1 ... 0 orders received
Received save game data from player AI_3 ... 0 orders received
Received save game data from player AI_4 ... 0 orders received
std::runtime_error exception caught in GUI::Run(): boost::filesystem::basic_directory_iterator constructor

looks like a problem within boost, but which directory is needed here? How can i debug this?

Greetings
deepsliver


Top
 Profile  
 
 Post subject: Re: API Error
PostPosted: Tue Mar 25, 2008 10:25 am 
Offline
Static Linker
User avatar

Joined: Thu Jun 28, 2007 10:28 am
Posts: 347
Now THAT (your first error) is definitive a problem related to your 64bit-ubuntu-Version.

Can you try the following with the statically version?

export LD_LIBRARY_PATH=/usr/lib64; ./freeorion

I didn't want to link python statically, but if you are interested I could link freeorionca with python2.4 statically. Maybe then it will work:

http://psitronic.de/div/FO/freeorionca.gz

Copy that into your install-path and do "gzip -d freeorionca.gz"


Top
 Profile  
 
 Post subject: Re: API Error
PostPosted: Tue Mar 25, 2008 12:34 pm 
Offline
Space Krill

Joined: Mon Mar 24, 2008 6:24 pm
Posts: 3
Hi,

export LD_LIBRARY_PATH=/usr/lib64; ./freeorion results in:

tmp/freeorion/static/freeorion/freeorionca: error while loading shared libraries: libpython2.4.so.1.0: wrong ELF class: ELFCLASS64

the second try worked, you have to chmod 775 freeorionca after unpack, with this solution i can play the game while i search for the solution on the self compiled version.

Thank you,
deepsliver


Top
 Profile  
 
 Post subject: Re: API Error
PostPosted: Tue Mar 25, 2008 5:50 pm 
Offline
Static Linker
User avatar

Joined: Thu Jun 28, 2007 10:28 am
Posts: 347
Okay, the I will keep python2.4 linked statically.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group