Scons can't find boost serialization

Questions, problems and discussion about compiling FreeOrion.

Moderators: Oberlus, Oberlus

Message
Author
User avatar
IConrad
Space Kraken
Posts: 163
Joined: Mon Nov 10, 2008 5:55 pm

Scons can't find boost serialization

#1 Post by IConrad » Mon Dec 15, 2008 3:24 am

This is the relevant error area. I have all the 1.36 libraries installed; GG installed just fine. I definitely have the serialization dev file installed.

Relevant scons printout:
Checking Boost version >= 1.36... (cached) yes
Checking for C++ header file boost/graph/dijkstra_shortest_paths.hpp... yes
Looking for boost lib boost_serialization...
Checking for boost::archive::binary_iarchive::is_saving() in C++ library boost_serialization... no
Checking for boost::archive::binary_iarchive::is_saving() in C++ library boost_serialization-mt... no
Boost configuration... (cached) no
I am running Ubuntu 8.10 amd64 architecture.

Any suggestions? (Please note; I cannot compile Boost on my own.)

User avatar
Geoff the Medio
Programming, Design, Admin
Posts: 12567
Joined: Wed Oct 08, 2003 1:33 am
Location: Munich

Re: Scons can't find boost serialization

#2 Post by Geoff the Medio » Mon Dec 15, 2008 4:23 am

Please post the contents of your config.log file. (At least, I think that's the file to post... it's been a while since I've dealt with posts about this type of issue.)

User avatar
IConrad
Space Kraken
Posts: 163
Joined: Mon Nov 10, 2008 5:55 pm

Re: Scons can't find boost serialization

#3 Post by IConrad » Mon Dec 15, 2008 4:48 am

Enter the config.log file:
file /home/ian/freeorion/FreeOrion/SConstruct,line 185:
Configure(confdir = .sconf_temp)
scons: Configure: Checking for Py_Initialize() in C library python2.5...
.sconf_temp/conftest_0.c <-
|
|
|#include "Python.h"
|
|int
|main() {
| Py_Initialize();
|return 0;
|}
|
gcc -o .sconf_temp/conftest_0.o -c -I/usr/include/python2.5 .sconf_temp/conftest_0.c
close failed: [Errno 9] Bad file descriptor
gcc -o .sconf_temp/conftest_0 .sconf_temp/conftest_0.o -L/usr/lib -lpython2.5
close failed: [Errno 9] Bad file descriptor
scons: Configure: yes

scons: Configure: Checking for pkg-config...
pkg-config --atleast-pkgconfig-version 0.15.0
close failed: [Errno 9] Bad file descriptor
scons: Configure: yes

scons: Configure: Checking for GiGiSDL >= 0.6.0...
pkg-config GiGiSDL --atleast-version 0.6.0
close failed: [Errno 9] Bad file descriptor
scons: Configure: yes

scons: Configure: Checking for C++ header file boost/shared_ptr.hpp...
.sconf_temp/conftest_3.cpp <-
|
|#include "boost/shared_ptr.hpp"
|
|
g++ -o .sconf_temp/conftest_3.o -c -pthread -D_GNU_SOURCE=1 -D_REENTRANT -I/usr/include/python2.5 -I/usr/local/include -I/usr/include/SDL -I/usr/include/boost .sconf_temp/conftest_3.cpp
close failed: [Errno 9] Bad file descriptor
scons: Configure: yes

scons: Configure: Checking Boost version >= 1.36...
scons: Configure: (cached) yes

scons: Configure: Checking for C++ header file boost/graph/dijkstra_shortest_paths.hpp...
.sconf_temp/conftest_4.cpp <-
|
|#include <boost/graph/dijkstra_shortest_paths.hpp>
|
|
g++ -o .sconf_temp/conftest_4.o -c -pthread -D_GNU_SOURCE=1 -D_REENTRANT -I/usr/include/python2.5 -I/usr/local/include -I/usr/include/SDL -I/usr/include/boost .sconf_temp/conftest_4.cpp
close failed: [Errno 9] Bad file descriptor
scons: Configure: yes

scons: Configure: Checking for boost::archive::binary_iarchive::is_saving() in C++ library boost_serialization...
.sconf_temp/conftest_5.cpp <-
|
|
|#include "boost/archive/binary_iarchive.hpp"
|
|int
|main() {
| boost::archive::binary_iarchive::is_saving();
|return 0;
|}
|
g++ -o .sconf_temp/conftest_5.o -c -pthread -D_GNU_SOURCE=1 -D_REENTRANT -I/usr/include/python2.5 -I/usr/local/include -I/usr/include/SDL -I/usr/include/boost .sconf_temp/conftest_5.cpp
close failed: [Errno 9] Bad file descriptor
scons: Configure: Caught exception while building ".sconf_temp/conftest_5":

Traceback (most recent call last):
File "/usr/lib/scons/SCons/Job.py", line 198, in start
task.prepare()
File "/usr/lib/scons/SCons/Taskmaster.py", line 186, in prepare
t.prepare()
File "/usr/lib/scons/SCons/Node/FS.py", line 2558, in prepare
SCons.Node.Node.prepare(self)
File "/usr/lib/scons/SCons/Node/__init__.py", line 356, in prepare
raise SCons.Errors.StopError, msg % (i, self)
SCons.Errors.StopError: Implicit dependency `/usr/local/lib/libGiGi.so' not found, needed by target `.sconf_temp/conftest_5'.
scons: Configure: no

scons: Configure: Checking for boost::archive::binary_iarchive::is_saving() in C++ library boost_serialization-mt...
.sconf_temp/conftest_6.cpp <-
|
|
|#include "boost/archive/binary_iarchive.hpp"
|
|int
|main() {
| boost::archive::binary_iarchive::is_saving();
|return 0;
|}
|
g++ -o .sconf_temp/conftest_6.o -c -pthread -D_GNU_SOURCE=1 -D_REENTRANT -I/usr/include/python2.5 -I/usr/local/include -I/usr/include/SDL -I/usr/include/boost .sconf_temp/conftest_6.cpp
close failed: [Errno 9] Bad file descriptor
scons: Configure: Caught exception while building ".sconf_temp/conftest_6":

Traceback (most recent call last):
File "/usr/lib/scons/SCons/Job.py", line 198, in start
task.prepare()
File "/usr/lib/scons/SCons/Taskmaster.py", line 186, in prepare
t.prepare()
File "/usr/lib/scons/SCons/Node/FS.py", line 2558, in prepare
SCons.Node.Node.prepare(self)
File "/usr/lib/scons/SCons/Node/__init__.py", line 356, in prepare
raise SCons.Errors.StopError, msg % (i, self)
SCons.Errors.StopError: Implicit dependency `/usr/local/lib/libGiGi.so' not found, needed by target `.sconf_temp/conftest_6'.
scons: Configure: no

scons: Configure: Boost configuration...
scons: Configure: (cached) no

User avatar
OndrejR
Space Dragon
Posts: 339
Joined: Thu Oct 02, 2008 11:00 pm
Location: Slovakia

Re: Scons can't find boost serialization

#4 Post by OndrejR » Mon Dec 15, 2008 6:11 am

Did you install development version of boost? Something like libboost1.36-dev. I installed libboost 1.36 from Debian(they later removed it from repositories) and I can compile and run FreeOrion although boost 1.36 is buggy. In Ubuntu probably they corrected these errors. I have same architecture amd64.

User avatar
IConrad
Space Kraken
Posts: 163
Joined: Mon Nov 10, 2008 5:55 pm

Re: Scons can't find boost serialization

#5 Post by IConrad » Mon Dec 15, 2008 7:10 am

Yes I have the dev files installed. There isn't a single boost file w/ 1.36 version that I don't have installed.

User avatar
OndrejR
Space Dragon
Posts: 339
Joined: Thu Oct 02, 2008 11:00 pm
Location: Slovakia

Re: Scons can't find boost serialization

#6 Post by OndrejR » Mon Dec 15, 2008 7:36 am

I have installed
libboost-serialization1.36.0
installed files

Code: Select all

/usr/lib/libboost_serialization.so.1.36.0
/usr/lib/libboost_serialization-mt.so.1.36.0
/usr/lib/libboost_wserialization.so.1.36.0
/usr/lib/libboost_wserialization-mt.so.1.36.0
/usr/share
/usr/share/lintian
/usr/share/lintian/overrides
/usr/share/lintian/overrides/libboost-serialization1.36.0
/usr/share/doc
/usr/share/doc/libboost-serialization1.36.0
/usr/share/doc/libboost-serialization1.36.0/README.Debian.gz
/usr/share/doc/libboost-serialization1.36.0/changelog.Debian.gz
/usr/share/doc/libboost-serialization1.36.0/copyright
libboost-serialization1.36-dev
installed files

Code: Select all

/usr/include/boost/serialization
/usr/include/boost/serialization/version.hpp
/usr/include/boost/serialization/vector.hpp
/usr/include/boost/serialization/force_include.hpp
/usr/include/boost/serialization/hash_collections_save_imp.hpp
/usr/include/boost/serialization/array.hpp
/usr/include/boost/serialization/collection_traits.hpp
/usr/include/boost/serialization/extended_type_info_typeid.hpp
/usr/include/boost/serialization/tracking.hpp
/usr/include/boost/serialization/access.hpp
/usr/include/boost/serialization/slist.hpp
/usr/include/boost/serialization/valarray.hpp
/usr/include/boost/serialization/list.hpp
/usr/include/boost/serialization/hash_map.hpp
/usr/include/boost/serialization/extended_type_info_no_rtti.hpp
/usr/include/boost/serialization/deque.hpp
/usr/include/boost/serialization/extended_type_info.hpp
/usr/include/boost/serialization/nvp.hpp
/usr/include/boost/serialization/ephemeral.hpp
/usr/include/boost/serialization/map.hpp
/usr/include/boost/serialization/shared_ptr_132.hpp
/usr/include/boost/serialization/set.hpp
/usr/include/boost/serialization/base_object.hpp
/usr/include/boost/serialization/level.hpp
/usr/include/boost/serialization/level_enum.hpp
/usr/include/boost/serialization/serialization.hpp
/usr/include/boost/serialization/hash_collections_load_imp.hpp
/usr/include/boost/serialization/traits.hpp
/usr/include/boost/serialization/factory.hpp
/usr/include/boost/serialization/void_cast_fwd.hpp
/usr/include/boost/serialization/collections_save_imp.hpp
/usr/include/boost/serialization/void_cast.hpp
/usr/include/boost/serialization/collection_size_type.hpp
/usr/include/boost/serialization/wrapper.hpp
/usr/include/boost/serialization/tracking_enum.hpp
/usr/include/boost/serialization/shared_ptr.hpp
/usr/include/boost/serialization/split_member.hpp
/usr/include/boost/serialization/detail
/usr/include/boost/serialization/detail/stack_constructor.hpp
/usr/include/boost/serialization/detail/shared_ptr_132.hpp
/usr/include/boost/serialization/detail/shared_count_132.hpp
/usr/include/boost/serialization/detail/get_data.hpp
/usr/include/boost/serialization/detail/shared_ptr_nmt_132.hpp
/usr/include/boost/serialization/split_free.hpp
/usr/include/boost/serialization/utility.hpp
/usr/include/boost/serialization/optional.hpp
/usr/include/boost/serialization/hash_set.hpp
/usr/include/boost/serialization/weak_ptr.hpp
/usr/include/boost/serialization/vector_135.hpp
/usr/include/boost/serialization/collections_load_imp.hpp
/usr/include/boost/serialization/assume_abstract.hpp
/usr/include/boost/serialization/config.hpp
/usr/include/boost/serialization/is_bitwise_serializable.hpp
/usr/include/boost/serialization/string.hpp
/usr/include/boost/serialization/type_info_implementation.hpp
/usr/include/boost/serialization/export.hpp
/usr/include/boost/serialization/binary_object.hpp
/usr/include/boost/serialization/scoped_ptr.hpp
/usr/include/boost/serialization/variant.hpp
/usr/include/boost/serialization/singleton.hpp
/usr/include/boost/serialization/complex.hpp
/usr/lib
/usr/lib/libboost_wserialization-mt.a
/usr/lib/libboost_serialization.a
/usr/lib/libboost_serialization-mt.a
/usr/lib/libboost_wserialization.a
/usr/share
/usr/share/doc
/usr/share/doc/libboost-serialization1.36-dev
/usr/share/doc/libboost-serialization1.36-dev/README.Debian.gz
/usr/share/doc/libboost-serialization1.36-dev/changelog.Debian.gz
/usr/share/doc/libboost-serialization1.36-dev/copyright
/usr/lib/libboost_wserialization-gcc43-1_36.a
/usr/lib/libboost_serialization.so
/usr/lib/libboost_serialization-gcc43-mt-1_36.so
/usr/lib/libboost_wserialization-gcc43-mt-1_36.so
/usr/lib/libboost_serialization-gcc43-mt-1_36.a
/usr/lib/libboost_wserialization-mt.so
/usr/lib/libboost_serialization-mt.so
/usr/lib/libboost_wserialization.so
/usr/lib/libboost_serialization-gcc43-1_36.a
/usr/lib/libboost_serialization-gcc43-1_36.so
/usr/lib/libboost_wserialization-gcc43-mt-1_36.a
/usr/lib/libboost_wserialization-gcc43-1_36.so
If these files are on disk, then you may run ldconfig as root
in ubuntu as

Code: Select all

sudo ldconfig
After installing GiGi rerun ldconfig with libc.conf containing /usr/local/lib

User avatar
IConrad
Space Kraken
Posts: 163
Joined: Mon Nov 10, 2008 5:55 pm

Re: Scons can't find boost serialization

#7 Post by IConrad » Mon Dec 15, 2008 7:56 pm

OndrejR wrote: If these files are on disk, then you may run ldconfig as root
in ubuntu as
Code:
sudo ldconfig


After installing GiGi rerun ldconfig with libc.conf containing /usr/local/lib
I have installed
libboost-serialization1.36.0
installed files

Code: Select all

/usr/lib/libboost_serialization.so.1.36.0
/usr/lib/libboost_serialization-mt.so.1.36.0
/usr/lib/libboost_wserialization.so.1.36.0
/usr/lib/libboost_wserialization-mt.so.1.36.0
/usr/share
/usr/share/lintian
/usr/share/lintian/overrides
/usr/share/lintian/overrides/libboost-serialization1.36.0
/usr/share/doc
/usr/share/doc/libboost-serialization1.36.0
/usr/share/doc/libboost-serialization1.36.0/README.Debian.gz
/usr/share/doc/libboost-serialization1.36.0/changelog.Debian.gz
/usr/share/doc/libboost-serialization1.36.0/copyright
libboost-serialization1.36-dev
installed files

Code: Select all

/usr/include/boost/serialization
/usr/include/boost/serialization/version.hpp
/usr/include/boost/serialization/vector.hpp
/usr/include/boost/serialization/force_include.hpp
/usr/include/boost/serialization/hash_collections_save_imp.hpp
/usr/include/boost/serialization/array.hpp
/usr/include/boost/serialization/collection_traits.hpp
/usr/include/boost/serialization/extended_type_info_typeid.hpp
/usr/include/boost/serialization/tracking.hpp
/usr/include/boost/serialization/access.hpp
/usr/include/boost/serialization/slist.hpp
/usr/include/boost/serialization/valarray.hpp
/usr/include/boost/serialization/list.hpp
/usr/include/boost/serialization/hash_map.hpp
/usr/include/boost/serialization/extended_type_info_no_rtti.hpp
/usr/include/boost/serialization/deque.hpp
/usr/include/boost/serialization/extended_type_info.hpp
/usr/include/boost/serialization/nvp.hpp
/usr/include/boost/serialization/ephemeral.hpp
/usr/include/boost/serialization/map.hpp
/usr/include/boost/serialization/shared_ptr_132.hpp
/usr/include/boost/serialization/set.hpp
/usr/include/boost/serialization/base_object.hpp
/usr/include/boost/serialization/level.hpp
/usr/include/boost/serialization/level_enum.hpp
/usr/include/boost/serialization/serialization.hpp
/usr/include/boost/serialization/hash_collections_load_imp.hpp
/usr/include/boost/serialization/traits.hpp
/usr/include/boost/serialization/factory.hpp
/usr/include/boost/serialization/void_cast_fwd.hpp
/usr/include/boost/serialization/collections_save_imp.hpp
/usr/include/boost/serialization/void_cast.hpp
/usr/include/boost/serialization/collection_size_type.hpp
/usr/include/boost/serialization/wrapper.hpp
/usr/include/boost/serialization/tracking_enum.hpp
/usr/include/boost/serialization/shared_ptr.hpp
/usr/include/boost/serialization/split_member.hpp
/usr/include/boost/serialization/detail
/usr/include/boost/serialization/detail/stack_constructor.hpp
/usr/include/boost/serialization/detail/shared_ptr_132.hpp
/usr/include/boost/serialization/detail/shared_count_132.hpp
/usr/include/boost/serialization/detail/get_data.hpp
/usr/include/boost/serialization/detail/shared_ptr_nmt_132.hpp
/usr/include/boost/serialization/split_free.hpp
/usr/include/boost/serialization/utility.hpp
/usr/include/boost/serialization/optional.hpp
/usr/include/boost/serialization/hash_set.hpp
/usr/include/boost/serialization/weak_ptr.hpp
/usr/include/boost/serialization/vector_135.hpp
/usr/include/boost/serialization/collections_load_imp.hpp
/usr/include/boost/serialization/assume_abstract.hpp
/usr/include/boost/serialization/config.hpp
/usr/include/boost/serialization/is_bitwise_serializable.hpp
/usr/include/boost/serialization/string.hpp
/usr/include/boost/serialization/type_info_implementation.hpp
/usr/include/boost/serialization/export.hpp
/usr/include/boost/serialization/binary_object.hpp
/usr/include/boost/serialization/scoped_ptr.hpp
/usr/include/boost/serialization/variant.hpp
/usr/include/boost/serialization/singleton.hpp
/usr/include/boost/serialization/complex.hpp
/usr/lib
/usr/lib/libboost_wserialization-mt.a
/usr/lib/libboost_serialization.a
/usr/lib/libboost_serialization-mt.a
/usr/lib/libboost_wserialization.a
/usr/share
/usr/share/doc
/usr/share/doc/libboost-serialization1.36-dev
/usr/share/doc/libboost-serialization1.36-dev/README.Debian.gz
/usr/share/doc/libboost-serialization1.36-dev/changelog.Debian.gz
/usr/share/doc/libboost-serialization1.36-dev/copyright
/usr/lib/libboost_wserialization-gcc43-1_36.a
/usr/lib/libboost_serialization.so
/usr/lib/libboost_serialization-gcc43-mt-1_36.so
/usr/lib/libboost_wserialization-gcc43-mt-1_36.so
/usr/lib/libboost_serialization-gcc43-mt-1_36.a
/usr/lib/libboost_wserialization-mt.so
/usr/lib/libboost_serialization-mt.so
/usr/lib/libboost_wserialization.so
/usr/lib/libboost_serialization-gcc43-1_36.a
/usr/lib/libboost_serialization-gcc43-1_36.so
/usr/lib/libboost_wserialization-gcc43-mt-1_36.a
/usr/lib/libboost_wserialization-gcc43-1_36.so
If these files are on disk, then you may run ldconfig as root
in ubuntu as

Code: Select all

sudo ldconfig
After installing GiGi rerun ldconfig with libc.conf containing /usr/local/lib
This had absolutely no effect whatsoever. libc.conf already contained /usr/local/lib. I have confirmed that each and every file you listed is, in fact, on my machine -- in the folders you referenced.

obgr_seneca
Space Floater
Posts: 34
Joined: Wed Mar 12, 2008 9:00 am
Location: Horb, Germany

Re: Scons can't find boost serialization

#8 Post by obgr_seneca » Tue Dec 16, 2008 6:17 pm

I'm having a similar problem. After trying some fixes for other things (thanks to Zach), I gave up, cause I was running out of time...
Now I tried again, I built boost-1.37.0, since 1.36.0 didn't work for me, now I'm getting the following error message:

Code: Select all

/usr/include/boost/serialization/access.hpp:109: error: 'class __gnu_cxx::__normal_iterator<const char*, std::basic_string<char, std::char_traits<char>, std::allocator<char> > >' has no member named 'serialize'
scons: *** [tutorial/saveload.o] Error 1
scons: building terminated because of errors.
scons configure is running without any problems...

User avatar
OndrejR
Space Dragon
Posts: 339
Joined: Thu Oct 02, 2008 11:00 pm
Location: Slovakia

Re: Scons can't find boost serialization

#9 Post by OndrejR » Tue Dec 16, 2008 7:29 pm

obgr_seneca wrote:I'm having a similar problem. After trying some fixes for other things (thanks to Zach), I gave up, cause I was running out of time...
Now I tried again, I built boost-1.37.0, since 1.36.0 didn't work for me, now I'm getting the following error message:

Code: Select all

/usr/include/boost/serialization/access.hpp:109: error: 'class __gnu_cxx::__normal_iterator<const char*, std::basic_string<char, std::char_traits<char>, std::allocator<char> > >' has no member named 'serialize'
scons: *** [tutorial/saveload.o] Error 1
scons: building terminated because of errors.
scons configure is running without any problems...
This error don't affect GiGi and is known. You can install it with command:

Code: Select all

scons install

IConrad: Try first to compile GiGi and then FreeOrion

Code: Select all

scons --clean
scons configure
scons
Problem is maybe with old config.cache which scons --clean solves

obgr_seneca
Space Floater
Posts: 34
Joined: Wed Mar 12, 2008 9:00 am
Location: Horb, Germany

Re: Scons can't find boost serialization

#10 Post by obgr_seneca » Tue Dec 16, 2008 9:19 pm

OndrejR wrote:This error don't affect GiGi and is known. You can install it with command:

Code: Select all

scons install
I can't because rpmbuild won't let me. I have to use

Code: Select all

scons configure
scons
and then install it manually file by file, because GiGi's installation-routine seems not to support installing into a buildroot directory, like it is done, when building RPMs.
And every step has to return "0" or rpmbuild will exit.

Oliver

User avatar
IConrad
Space Kraken
Posts: 163
Joined: Mon Nov 10, 2008 5:55 pm

Re: Scons can't find boost serialization

#11 Post by IConrad » Wed Dec 17, 2008 7:33 pm

OndrejR wrote:IConrad: Try first to compile GiGi and then FreeOrion

Code: Select all

scons --clean
scons configure
scons
Problem is maybe with old config.cache which scons --clean solves
No dice. scons configure can't find serialization either. I'm still getting exactly the same error. I've tried doing a fresh dl of the svn as well.

User avatar
Geoff the Medio
Programming, Design, Admin
Posts: 12567
Joined: Wed Oct 08, 2003 1:33 am
Location: Munich

Re: Scons can't find boost serialization

#12 Post by Geoff the Medio » Wed Dec 17, 2008 8:55 pm

There are some options you can specify to scons. Try scons -h for a list (if I remember correctly). I think there are some for specifying the location of boost or parts of boost. In windows you can specify the include and library directories separately, but this might be different on linux. It might help to tell scons where the boost libraries are located, if it can't find them on the system itself.

User avatar
OndrejR
Space Dragon
Posts: 339
Joined: Thu Oct 02, 2008 11:00 pm
Location: Slovakia

Re: Scons can't find boost serialization

#13 Post by OndrejR » Wed Dec 17, 2008 8:56 pm

IConrad: According your config.log conf_test5 and conf_test6 failed

conf_test5

Code: Select all

#include "boost/archive/binary_iarchive.hpp"
conf_test6

Code: Select all

#include "boost/iostreams/filtering_stream.hpp"
But also in previous tests there is problem with bad descriptor. Could you post version of used gcc and g++?

Code: Select all

gcc --version
g++ --version

User avatar
IConrad
Space Kraken
Posts: 163
Joined: Mon Nov 10, 2008 5:55 pm

Re: Scons can't find boost serialization

#14 Post by IConrad » Wed Dec 17, 2008 9:37 pm

Geoff; I actually tried that to no success.

OndrejR; I'll get that info when I'm back on my own machine.

User avatar
IConrad
Space Kraken
Posts: 163
Joined: Mon Nov 10, 2008 5:55 pm

Re: Scons can't find boost serialization

#15 Post by IConrad » Thu Dec 18, 2008 2:33 am

My magic console tells me I'm running v. 4.3.2.

More specifically:

Code: Select all

gcc (Ubuntu 4.3.2-1ubuntu11) 4.3.2
g++ (Ubuntu 4.3.2-1ubuntu11) 4.3.2

Post Reply