Install Boost properly

Hi!

Could anyone suggest me how to get boost installed and run properly with its dependencies?
I am using Suse Linux Enterprise Server 11 SP3 X86_64.

Thanks for the help!

What is your goal?

Boost is split up into several packages.
If you install an application that uses boost via rpm/YaST/zypper, the needed packages should be installed automatically.

If you want to write a program using boost yourself, install “boost-devel”.

I am using Suse Linux Enterprise Server 11 SP3 X86_64.

Then you are in the wrong forums, this is for openSUSE only.

Head over to https://forums.suse.com/ , the people there should know better about SLES specifics.

I am trying to compile a c++ driver for cassandra ( https://github.com/datastax/cpp-driver/ ) which requires boost.

I have already installed boost-devel 1.55.0 via zypper. The installation wasn’t ideal since I had two options as you can see in the image (http://hpics.li/f6eb3d3). When I try to “make”, the processus exits with the following message:

make[2]: *** No rule to make target ‘/usr/lib64/libboost_system.so’, needed by ‘libcql.so.0.7.0’. Stop.
make[1]: *** [CMakeFiles/cql.dir/all] Error 2
make: *** [all] Error 2

Why did you install a Fedora package? This is incompatible with the rest of the boost packages from SUSE, and might even install the files to the wrong location.
Install the boost-devel that comes with your SLES.

Although, as I said, I don’t really know much about SLES, especially not which packages it contains.

When I try to “make”, the processus exits with the following message:

make[2]: *** No rule to make target ‘/usr/lib64/libboost_system.so’, needed by ‘libcql.so.0.7.0’. Stop.
make[1]: *** [CMakeFiles/cql.dir/all] Error 2
make: *** [all] Error 2

Well, I do have /usr/lib64/libboost_system.so on my openSUSE 13.1 system, and it is contained in the package “boost-devel”:

# rpm -qf /usr/lib64/libboost_system.so
boost-devel-1.53.0-4.1.2.x86_64

Thanks alot! I didn’t notice that it was from fedora!

I downloaded and installed boost-devel-1.55.0-8.17.1.x86_64.rpm (from http://www.rpmseek.com/rpm-pl/boost-devel.html?hl=com&cx=816:B:40), unfortunately the result is the same. http://hpics.li/a41c465

Also, I checked the “/usr/lib64/” directory and this time boost libs are there: http://hpics.li/f287bd5

And which one did you pick there?
The top ones are for CentOS.

Please post the output of:

rpm -qi boost-devel

Also, I checked the “/usr/lib64/” directory and this time boost libs are there: http://hpics.li/f287bd5

No, they are not.
An entry that is colored in yellow with red background means a symlink where the target is missing, i.e. it points to nowhere.

Again, you should install the “boost-devel” that is included in your SLES. Only this will match your system.
Just running “zypper in -f boost-devel” (-f to force the re-installation) should work.

If the version included in SLES 11 SP3 is too old for you and you need 1.55, this is available on OBS:
http://software.opensuse.org/package/boost
Click on “Show other versions” and then on “Show possibly unstable packages” below SUSE SLE-11 SP 3.

You should add the corresponding repo to your system, because when you compile against boost-devel-1.55.0 you will also need the corresponding libboost-xxx packages in version 1.55.0 to run your self-copmpiled software.
That’s why it would be better to stick with the one included in your distribution.

But again, you should better ask in the SUSE forums.
I (and most people here) only know about _open_SUSE.

Output of “rpm -qi boost-devel”: http://hpics.li/8a88948

The rpm available on OBS are only sources, I tried to install the package anyway, but it didn’t help: http://hpics.li/ffbaa1d
I have already created a post in the SUSE forum (https://forums.suse.com/showthread.php?4989-Installing-Boost-properly&p=22347#post22347). I am waiting for someone to reply :slight_smile:

This is for SP2, not sure if that would make a difference.

Anyway, as I already indicated in my previous post, you would need the actual 1.55.0 boost libraries as well (preferably from the same repo).
I checked now on my system, and /usr/lib64/libboost_system.so points to /usr/lib64/libboost_system.so.1.53.0, which is contained in the package libboost_system1_53_0. You probably don’t have libboost_system1_55_0 installed, so /usr/lib64/libboost_system.so.1.55.0 doesn’t exist on your system and the link points to nowhere.
The necessary packages should be installed automatically via RPM package dependencies, but you actually told zypper to ignore them.

So if you need 1.55.0, add one of those OBS repos (so that all dependencies are found automatically), re-install boost-devel and it should work:
F.e.:

zypper ar http://download.opensuse.org/repositories/home:ghaskins/SLE_11_SP3/home:ghaskins.repo
zypper ref
zypper in -f boost-devel-1.55.0

Or just install the boost-devel included in your SLES, as I already wrote twice.

The rpm available on OBS are only sources, I tried to install the package anyway, but it didn’t help: http://hpics.li/ffbaa1d

“boost-devel” is available there as well. What do you think where the package that you downloaded comes from? :wink:

For some reasons, “boost-devel” isn’t shown in the search results, but it is there in the repos.

I have already created a post in the SUSE forum (Rancher Labs). I am waiting for someone to reply :slight_smile:

Good.
Although I think we’re near to the solution here now anyway… :wink:

Thank you so much! It worked for the first error, but now there is another one: http://hpics.li/fb3b287

Issue resloved!

Thank you once again wolfi323 for your help!

Well, this looks like a bug in the source code you try to compile.

Maybe that source file is just missing a “#include <string.h>”?
Try to add that to extra/ccm_bridge/src/cql_escape_sequences_remover.cpp .

For string.h you need glibc-devel installed, but if a package would be missing, you should get a different error message I suppose. (something about file not found)

Btw, AFAICS that file does contain “#include <string.h>” as first line.
So did you download the current version?
This has been fixed apparently 22 days ago with this commit: (see at the bottom)

So maybe just re-download the current source code and try again.

I had an older version! Everything works fine thanks to you. :slight_smile: