From a4382e5f37adb621cba826d799a63744668ecbd1 Mon Sep 17 00:00:00 2001 From: Andreas Schuh Date: Tue, 1 Mar 2016 21:03:05 +0000 Subject: cmake: Require CMake 2.8.12 in NC tests --- test/nc/CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'test') diff --git a/test/nc/CMakeLists.txt b/test/nc/CMakeLists.txt index e425d91..d00b07d 100644 --- a/test/nc/CMakeLists.txt +++ b/test/nc/CMakeLists.txt @@ -1,6 +1,6 @@ ## gflags negative compilation tests -cmake_minimum_required (VERSION 2.8) +cmake_minimum_required (VERSION 2.8.12 FATAL_ERROR) if (NOT TEST_NAME) message (FATAL_ERROR "Missing TEST_NAME CMake flag") @@ -13,4 +13,4 @@ find_package (gflags REQUIRED) include_directories ("${CMAKE_CURRENT_SOURCE_DIR}/..") add_definitions (-DTEST_${TEST_NAME_UPPER}) add_executable (gflags_${TEST_NAME} gflags_nc.cc) -target_link_libraries(gflags_${TEST_NAME} ${gflags_LIBRARIES}) +target_link_libraries(gflags_${TEST_NAME} gflags) -- cgit v1.2.3 From 7a21c16f00a3e1cb141d331d980204e113f80abc Mon Sep 17 00:00:00 2001 From: Andreas Schuh Date: Tue, 1 Mar 2016 21:04:10 +0000 Subject: cmake: Rename targets to gflags[_nothreads]_(static|shared), support find_package COMPONENTS --- test/CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'test') diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 77b582f..2119943 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -22,9 +22,9 @@ else () set (type static) endif () if (BUILD_gflags_LIB) - link_libraries (gflags-${type}) + link_libraries (gflags_${type}) else () - link_libraries (gflags_nothreads-${type}) + link_libraries (gflags_nothreads_${type}) endif () # ---------------------------------------------------------------------------- -- cgit v1.2.3