- https://www.boost.org
- http://www.boost.org/build
- https://boostorg.github.io/build/tutorial.html
- https://boostorg.github.io/build/manual/develop/
- https://github.com/boostorg
$ sudo apt install build-essential pkg-config cmake
- Install MSYS2 (https://www.msys2.org)
- Open
Start Menu > MSYS2 64bit > MSYS2 MSYS
and run the following commands:
$ pacman -Syu
$ ########## Close terminal window. ##########
$ pacman -Su
$ pacman -S base-devel
$ pacman -S mingw-w64-i686-toolchain
$ pacman -S mingw-w64-x86_64-toolchain
$ pacman -S mingw-w64-i686-cmake
$ pacman -S mingw-w64-x86_64-cmake
- To compile 32-bit version:
Start Menu > MSYS2 64bit > MSYS2 MinGW 32-bit
- To compile 64-bit version:
Start Menu > MSYS2 64bit > MSYS2 MinGW 64-bit
- Dependencies:
ibstdc++-6.dll
libgcc_s_dw2-1.dll
(for x86)libgcc_s_seh-1.dll
(for x64)libwinpthread-1.dll
libbz2-1.dll
libiconv-2.dll
liblzma-5.dll
libzstd.dll
zlib1.dll
$ cd boost_x_y_z
$ ./bootstrap.sh
$ ./b2 variant=release link=shared threading=multi hardcode-dll-paths=true dll-path=\$ORIGIN install --prefix=$HOME/boost
$ cd boost_x_y_z
$ ./bootstrap.sh
$ ./b2 variant=release link=static cflags=-fPIC cxxflags=-fPIC threading=multi install --prefix=$HOME/boost
- CMake:
set(Boost_USE_STATIC_LIBS ON)