ToyElephant ToyElephant - 1 month ago 11
C++ Question

How can I install boost multiprecision library in ubuntu

I installed boost library in my ubuntu 12.04 machine using the following command:

sudo apt-get install libboost-all-dev


But when I checked
/usr/include/boost
, I don't see header files for multiprecision package (
cpp_dec_float.hpp
). Do I need to install it separately?

Answer

Boost.Multiprecission is present in Boost 1.53 onwards.

http://www.boost.org/doc/libs/1_53_0/libs/multiprecision/doc/html/boost_multiprecision/map/hist.html

If you install libboost-all-dev metapackage from precise repository by dependncy you get libboost-dev and by dependncy you also get libboost1.46-dev which is unfortunately too old.

You might try your luck with some PPA repository.

E. g. this one:

https://launchpad.net/~apokluda/+archive/ubuntu/boost1.53

and install the package following this tutorial.

https://charmie11.wordpress.com/2013/10/27/install-boost-1-53-on-ubuntu-by-package-manager/

Comments