Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Static Compilation on libboost 1.71 fails #78

Open
polarisfm opened this issue Jan 17, 2021 · 0 comments
Open

Static Compilation on libboost 1.71 fails #78

polarisfm opened this issue Jan 17, 2021 · 0 comments

Comments

@polarisfm
Copy link
Contributor

Static compilation on newer versions of libboost fails, notably libboost 1.71 which ships with Ubuntu 20.04 and Debian 11.

This was tested on Ubuntu 20.04 and Debian 11 on amd64 and arm64 machines. The issue isn't related to the compiler used and is reproducible using gcc 9, gcc 10, clang 10, and clang 11.

Currently you can workaround this issue by using debootstrap to spin up an older distribution, then chroot into it, but that isn't a great long-term fix.

cmake errors (Debian 11 arm64):

CMake Error at /usr/lib/aarch64-linux-gnu/cmake/Boost-1.71.0/BoostConfig.cmake:117 (find_package):
  Found package configuration file:

    /usr/lib/aarch64-linux-gnu/cmake/boost_system-1.71.0/boost_system-config.cmake

  but it set boost_system_FOUND to FALSE so package "boost_system" is
  considered to be NOT FOUND.  Reason given by package:

  No suitable build variant has been found.

  The following variants have been tried and rejected:

  * libboost_system.so.1.71.0 (shared, Boost_USE_STATIC_LIBS=ON)

  * libboost_system.a (shared runtime, Boost_USE_STATIC_RUNTIME=ON)

Call Stack (most recent call first):
  /usr/lib/aarch64-linux-gnu/cmake/Boost-1.71.0/BoostConfig.cmake:182 (boost_find_component)
  /usr/share/cmake-3.18/Modules/FindBoost.cmake:448 (find_package)
  CMakeLists.txt:882 (find_package)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants
@polarisfm and others