|
Boost : |
From: Dennis Luehring (dl.soluz_at_[hidden])
Date: 2021-07-15 08:28:21
Am 15.07.2021 um 09:34 schrieb Alexander Grund via Boost:
> Am 15.07.21 um 09:17 schrieb Dennis Luehring via Boost:
>> my boost build:
>> � mkdir ~/dev/3rdparty-liux-gcc
>> � cd ~/dev/3rdparty-linux-gcc
>> � wget
>> https://dl.bintray.com/boostorg/release/1.75.0/source/boost_1_75_0.tar.bz2
>>
>> � tar -xf boost_1_75_0.tar.bz2
>> � ln -s boost_1_75_0 ./boost
>> � cd boost_1_75_0
>> � ./bootstrap.sh
>> � ./b2 --toolset=gcc cxxflags=-fPIC --build-dir=./_build
>> address-model=64 architecture=x86 link=static threading=multi
>> --with-graph --with-nowide --with-test --width-config --with-system
>> --with-filesystem --stagedir=./_x64
>> � ln -s _x64/lib lib
>>
>> my simple test hierarchy:
>>
>> boost_using_cmake_tests
>> boost_using_cmake_tests\_build
>> boost_using_cmake_tests\boost_using_cmake
>> boost_using_cmake_tests\boost_using_cmake\CMakeLists.txt
>> ����� cmake_minimum_required (VERSION 3.16)
>> ����� set(Boost_NO_BOOST_CMAKE TRUE)
>> ����� set(Boost_NO_SYSTEM_PATHS TRUE)
>> ����� project (using_boost_with_cmake)
>> ����� set( MY_THIRD_PARTY_LIBS "~/dev/3rdparty-linux-gcc" )
>> ����� set( BOOST_ROOT ${MY_THIRD_PARTY_LIBS}/boost )
>> ����� set( BOOST_INCLUDEDIR ${BOOST_ROOT}/boost)
>> ����� set( BOOST_LIBRARYDIR ${BOOST_ROOT}/lib)
>> ����� find_package(Boost REQUIRED COMPONENTS unit_test_framework
>> filesystem system)
> You explicitely opt-out of Boosts CMake support:
> set(Boost_NO_BOOST_CMAKE TRUE)
> You set the wrong folder: set( BOOST_ROOT ${MY_THIRD_PARTY_LIBS}/boost )
>
> The INCLUDEDIR/LIBRARYDIR are not required.
>
> --> More generic: `export
> CMAKE_PREFIX_PATH=$HOME/dev/3rdparty-linux-gc/boost_1_75_:$CMAKE_PREFIX_PATH`
> Then you don't need ANY BOOST_*/Boost_* settings in your CML and can
> simply call find_package
>
>
thank you - works with cmake 3.19.4+ and boost 1.75/1.76
cmake 3.18.6 (the default under Ubuntu 21.04, and the version i started
the jouney with) still does not work and gives the unsupported messages
thats why initially setted all the paths that way
it seems that the mind version of cmake is 3.19.4 to support finding out
of the box - is that correct?
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk