diff --git a/cpp/thirdparty/CMakeLists.txt b/cpp/thirdparty/CMakeLists.txt index d75fd27f33..be97f12677 100644 --- a/cpp/thirdparty/CMakeLists.txt +++ b/cpp/thirdparty/CMakeLists.txt @@ -66,40 +66,21 @@ endif() # ## BOOST if(MEMILIO_USE_BUNDLED_BOOST) - message(STATUS "Downloading Boost library. This may take several minutes. This is the time to get yourself a coffee. :-)") + message(STATUS "Downloading Boost library") + + string(REPLACE "." "_" MEMILIO_BOOST_VERSION_UNDERSC "${MEMILIO_BOOST_VERSION}") include(FetchContent) FetchContent_Declare(boost - GIT_REPOSITORY https://github.com/boostorg/boost.git - GIT_TAG boost-${MEMILIO_BOOST_VERSION}) + #don't use the URL from github, that download isn't complete and requires more setup (subrepositories, bootstrapping) + URL https://archives.boost.io/release/${MEMILIO_BOOST_VERSION}/source/boost_${MEMILIO_BOOST_VERSION_UNDERSC}.tar.gz + ) FetchContent_GetProperties(boost) if(NOT boost_POPULATED) FetchContent_Populate(boost) endif() - - add_custom_target(boost-bootstrap ALL - DEPENDS "${boost_SOURCE_DIR}/boost" - ) - - if(MSVC) - add_custom_command( - OUTPUT "${boost_SOURCE_DIR}/boost" - COMMAND "bootstrap.bat" - COMMAND "b2.exe" headers - WORKING_DIRECTORY ${boost_SOURCE_DIR} - VERBATIM - ) - else() - add_custom_command( - OUTPUT "${boost_SOURCE_DIR}/boost" - COMMAND ./bootstrap.sh - COMMAND ./b2 headers - WORKING_DIRECTORY ${boost_SOURCE_DIR} - VERBATIM - ) - endif() - + add_library(boost INTERFACE) add_dependencies(boost boost-bootstrap) add_library(Boost::boost ALIAS boost) diff --git a/pycode/memilio-generation/CMakeLists.txt b/pycode/memilio-generation/CMakeLists.txt index 313001faf3..c14e703e82 100644 --- a/pycode/memilio-generation/CMakeLists.txt +++ b/pycode/memilio-generation/CMakeLists.txt @@ -13,8 +13,6 @@ set(CMAKE_EXPORT_COMPILE_COMMANDS ON) # add in C++ library add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../../cpp ${CMAKE_CURRENT_BINARY_DIR}/cpp EXCLUDE_FROM_ALL) -add_custom_target(DUMMY ALL) -add_dependencies(DUMMY boost-bootstrap) FIND_LIBRARY(LIBCLANG_PATH clang HINTS ${CMAKE_CXX_COMPILER}/../../ ) diff --git a/pycode/memilio-generation/memilio/generation_test/test_oseir_generation.py b/pycode/memilio-generation/memilio/generation_test/test_oseir_generation.py index 7cae459d09..5913acf8de 100644 --- a/pycode/memilio-generation/memilio/generation_test/test_oseir_generation.py +++ b/pycode/memilio-generation/memilio/generation_test/test_oseir_generation.py @@ -51,11 +51,6 @@ class TestOseirGeneration(unittest.TestCase): cmake_cmd, stdout=subprocess.PIPE, cwd=build_dir.name) cmake_cmd_result.check_returncode() - cmake_cmd = ["cmake", "--build", ".", "--target", "boost-bootstrap"] - cmake_cmd_result = subprocess.run( - cmake_cmd, stdout=subprocess.PIPE, cwd=build_dir.name) - cmake_cmd_result.check_returncode() - @patch('memilio.generation.scanner.utility.try_get_compilation_database_path') def setUp(self, try_get_compilation_database_path_mock): try_get_compilation_database_path_mock.return_value = self.build_dir.name