FS#64132 - Boost CMake module shows incorrect include path
Attached to Project:
Arch Linux
Opened by Rodrigo Fernandes (rfernandes) - Monday, 14 October 2019, 19:24 GMT
Last edited by Antonio Rojas (arojas) - Tuesday, 15 October 2019, 12:22 GMT
Opened by Rodrigo Fernandes (rfernandes) - Monday, 14 October 2019, 19:24 GMT
Last edited by Antonio Rojas (arojas) - Tuesday, 15 October 2019, 12:22 GMT
|
Details
Description:
CMake integration of find_package(Boost) incorrectly resolves the Boost_INCLUDE_DIRS to "/include", resulting in the build failure of projects that have boost as a dependency Additional info: Version 1.71.0-2 has the issue, 1.69.0-2 was fine Steps to reproduce: (Minimal CMakeLists.txt) ``` project(boostTest) find_package(Boost REQUIRED) message(STATUS "-> ${Boost_INCLUDE_DIRS}") ``` running `cmake .` will show that Boost_INCLUDE_DIRS is resolved to "/include" instead of "/usr/include" |
This task depends upon
-- -> /usr/include
```
-- Found Boost: /lib64/cmake/Boost-1.71.0/BoostConfig.cmake (found version "1.71.0")
-- -> /include
```
But if I rollback (or install boost1.69)
```
-- Found Boost: /usr/include (found version "1.69.0")
-- -> /usr/include
```
`
-- The CXX compiler identification is GNU 9.2.0
-- Check for working C compiler: /usr/lib/ccache/bin/gcc
-- Check for working C compiler: /usr/lib/ccache/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/lib/ccache/bin/g++
-- Check for working CXX compiler: /usr/lib/ccache/bin/g++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found Boost 1.71.0 at /lib64/cmake/Boost-1.71.0
-- Requested configuration: QUIET REQUIRED
-- BoostConfig: find_package(boost_headers 1.71.0 EXACT CONFIG REQUIRED QUIET HINTS /lib64/cmake)
-- Found boost_headers 1.71.0 at /lib64/cmake/boost_headers-1.71.0
-- Found Boost: /lib64/cmake/Boost-1.71.0/BoostConfig.cmake (found version "1.71.0")
-- -> /include
You may want to suggest upstream to change ABSOLUTE to REALPATH in boost_headers-config.cmake, this will make it work even with /bin in PATH.