2

A few months ago I installed boost on Ubuntu 22.04 using:

sudo apt-get install libboost-all-dev

This installed version 1.74. However, I need 1.82 and the 22.04 repositories do not contain 1.82.

I am aware of this page:

https://www.boost.org/doc/libs/1_82_0/more/getting_started/unix-variants.html

but it mentions the installation path as /usr/local:

Select your configuration options and invoke ./bootstrap.sh again without the --help option. Unless you have write permission in your system's /usr/local/ directory, you'll probably want to at least use

whereas my current installation on Ubuntu seems to be /usr/include/boost/?

Do I just download the tar to my Downloads and enter:

cd Downloads/boost_1_82_0
./bootstrap.sh --prefix=/usr/include/

?

So the emphasis on the question is, for Ubuntu should I use that prefix/is the above correct?

(Asking as I don't want to corrupt my existing environment)

intrigued_66
  • 16,082
  • 51
  • 118
  • 189

1 Answers1

3

Install boost-1.82 from Lauchpad PPA Builds of latest releases of the C++ BOOST library.

Follow the manual from there.

sudo add-apt-repository ppa:mhier/libboost-latest
sudo apt update
sudo apt install libboost
# or sudo apt install libboost1.82-dev
273K
  • 29,503
  • 10
  • 41
  • 64
  • Nice. I didn't know about this one – sehe Jun 23 '23 at 22:52
  • Unfortunately I got an error halfway through due to DPDK and now my installation seems corrupted. If you're able to help it would be greatly appreciated: https://stackoverflow.com/questions/76547317/boost-apt-update-failed-in-middle-due-to-dpdk-now-unsure-which-version-i-have – intrigued_66 Jun 24 '23 at 17:43