From a322807e503d55e609bd20afcaa90c73ad00cfbf Mon Sep 17 00:00:00 2001 From: Joel Holdsworth Date: Sat, 20 Oct 2012 19:01:58 +0100 Subject: [PATCH] Moved unit test build commands into test/CMakeLists.txt --- CMakeLists.txt | 4 ---- test/CMakeLists.txt | 10 ++++++++++ 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a54708e3..dc576ed1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -53,11 +53,7 @@ endif() find_package(Qt4 REQUIRED) -if(ENABLE_TESTS) -find_package(Boost 1.46 COMPONENTS unit_test_framework REQUIRED) -else() find_package(Boost 1.46) -endif() #=============================================================================== #= Config Header diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 363470bb..6da1a247 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -18,6 +18,8 @@ ## along with this program. If not, see . ## +find_package(Boost 1.46 COMPONENTS unit_test_framework REQUIRED) + set(pulseview_TEST_SOURCES ${PROJECT_SOURCE_DIR}/pv/datasnapshot.cpp ${PROJECT_SOURCE_DIR}/pv/logicdatasnapshot.cpp @@ -27,6 +29,14 @@ set(pulseview_TEST_SOURCES add_definitions(-DBOOST_TEST_DYN_LINK) +include_directories( + ${Boost_INCLUDE_DIRS} +) + +set(PULSEVIEW_LINK_LIBS + ${Boost_LIBRARIES} +) + add_executable(pulseview-test ${pulseview_TEST_SOURCES} ) -- 2.30.2