build: Conan generator changed to provide more transparent dependency handling

This commit is contained in:
Mateusz Pusz committed 2020-12-09 18:49:39 +01:00
1 parent 9efa8b4711
commit c5919d2cd8
7 files changed
+15 -63

No files matched your search

+1 -1
View File
@@ -27,7 +27,7 @@ function(add_metabench_test target name erb_path range)
target_compile_features(${target} PUBLIC cxx_std_20)
target_link_libraries(${target}
PUBLIC
$<IF:$<TARGET_EXISTS:CONAN_PKG::range-v3>,CONAN_PKG::range-v3,range-v3::range-v3>
range-v3::range-v3>
)
target_compile_options(${target}
PUBLIC
+2 -3
View File
@@ -22,8 +22,7 @@
cmake_minimum_required(VERSION 3.12)
# check if conan installed a test framework
conan_check_testing(catch2)
find_package(Catch2 CONFIG REQUIRED)
add_executable(unit_tests_runtime
catch_main.cpp
@@ -36,7 +35,7 @@ add_executable(unit_tests_runtime
target_link_libraries(unit_tests_runtime
PRIVATE
mp-units::mp-units
$<IF:$<TARGET_EXISTS:CONAN_PKG::catch2>,CONAN_PKG::catch2,Catch2::Catch2>
Catch2::Catch2
)
if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")