Speeding up the library gives errors on ubuntu
I am trying to compile a package on ubuntu 8.1
when running this command: ./ configure I get the following error:
checking Boost headers version> = 103700 ... no configure: error: cannot find Boost headers version> = 103700
knowing that I have installed the necessary boost packages using the following command:
$ apt-get install libboost-dev libboost-graph-dev libboost-iostreams-dev
Can anyone please help?
Thank you. Now it works, but I get another error on startup. / configure: check boost / iostreams / device / file_descriptor.hpp usability ... yes check boost / iostreams / device / file_descriptor.hpp presence ... yes check for boost / iostreams / device / file_descriptor.hpp ... yes check library Boost iostreams ... no configure: error: can't find flags to communicate with Boost iostreams, any ideas please?
a source to share
Maybe the boost version you get from the Ubuntu repository is too old (she suggested here that the highest version for 8.10 is 1.35; it looks like your script config is asking for 1.37). You may need to build from source; there is some more information in the answers to the question I linked which hopefully helps.
UPDATE:
From your new error it seems like it configure
can't find the boost_iostreams library now. On my system, is it /usr/lib/libboost_iostreams-mt.[a|so]
- do you have these files (maybe in a different directory depending on where you installed boost)?
You can also try running ldconfig
in case there is no symbolic link (from, say,
libboost_iostreams-mt.so.1.37.0
to libboost_iostreams-mt.so
).
Is this configure
GNU generated autoconf
? If so, there should be a file named config.log
in the same directory that contains a list of all the commands configure
that were tried to run while looking for things. If there is anything about boost_iostreams
you could you post it?
One completely random guess: some examples I found on the web link boost_iostreams
without the multithreading suffix -mt
, but I don't have them at all on my machine. Perhaps your configure
script is running on the same problem?
UPDATE 2
configure
The script seems to be looking for a single-threaded debug build of the boost iostreams library, which is not built by default when built from source on Linux. Also, by default in linux, you shouldn't specify libraries based on build configuration (so the libraries you found in /usr/lib
may not be the ones you installed from source, unless you override that). This stuff isn't really explained on the boost site, I only found out in the file Jamroot
( bjam --help
works too)! Anyway, to get the library with the correct build configuration and name it correctly, I need to go to the root of the boost source tree and run:
sudo bjam --with-iostreams --layout=tagged variant=debug threading=single install
For me, this puts libraries ( libboost_iostreams-d.a
and shared versions) in /usr/local/lib
where it ld
will find them by default, so that should be fine. If you need them to go somewhere else, you can use the option --prefix=...
for bjam
eg. if you want them in /usr/lib
, you can do --prefix=/usr
. If the package you are building needs more powerful libraries, you can delete --with-iostreams
and then they will all be created (or replace iostream
with the name of another library you need).
Side note: I needed to install the package libbz2-dev
in order to get the forced iostreams to build - it's easy to overlook the error here if you build the whole boost as there is so much output there.
a source to share