5

I'm using RHEL 5.3, shipped with gcc 4.1.2 and boost 1.33. So, there's no boost::unorded_map, no make_shared() factory function to create boost::shared_ptr and other features available in newer releases of boost.

Is there're a newer version of boost compatible with the version of gcc? If yes, how the upgrade is performed?

dimba
  • 26,717
  • 34
  • 141
  • 196
  • just install the newest version, you can follow steps here https://stackoverflow.com/questions/12578499/how-to-install-boost-on-ubuntu – Amr Magdy Jul 06 '20 at 07:35

3 Answers3

8

Download the latest version (1.43.0) of the Boost libraries from the Boost website and follow the steps in the getting started guide, which explains how to build Boost on a number of platforms, including Linux.

James McNellis
  • 348,265
  • 75
  • 913
  • 977
4

Simply download and install the newest version; it will adapt itself automatically to your compiler.

Philipp
  • 48,066
  • 12
  • 84
  • 109
  • 1
    Not sure if that's correct. I just downloaded and installed 1.58 and `cat /usr/include/boost/version.hpp | grep "define BOOST_LIB_VERSION"` still yields 1.54? – knutole Apr 22 '15 at 12:20
1

Sure, just download the latest source from link text. If you are only using header only libraries, it just needs to be unpacked. If you are using one of a handful that require a library, you will need to build those.

KeithB
  • 16,577
  • 3
  • 41
  • 45