Skip to content

Commit

Permalink
Build only Boost test_exec_monitor statically
Browse files Browse the repository at this point in the history
  • Loading branch information
rcaelers committed Aug 27, 2024
1 parent 2905143 commit deab474
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -679,17 +679,24 @@ if (WIN32)
endif()

if (HAVE_TESTS)
#set(Boost_USE_STATIC_LIBS ON)
set(BOOST_COMPONENTS ${BOOST_COMPONENTS} unit_test_framework test_exec_monitor)
set(BOOST_COMPONENTS ${BOOST_COMPONENTS} unit_test_framework )
endif()

set (BOOST_MIN_VERSION "1.54.0")
if (CMAKE_COMPILER_IS_GNUCXX AND CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 10.0.0)
set (BOOST_MIN_VERSION "1.73.0") #https://github.com/boostorg/signals2/commit/15fcf213563718d2378b6b83a1614680a4fa8cec
endif()

set(Boost_USE_STATIC_LIBS OFF)
set(Boost_USE_SHARED_LIBS ON)
find_package(Boost ${BOOST_MIN_VERSION} REQUIRED COMPONENTS ${BOOST_COMPONENTS})

if (HAVE_TESTS)
set(Boost_USE_STATIC_LIBS ON)
find_package(Boost ${BOOST_MIN_VERSION} REQUIRED COMPONENTS test_exec_monitor)
endif()


#----------------------------------------------------------------------------------------------------
# Wayland

Expand Down

0 comments on commit deab474

Please sign in to comment.