1
0
Fork 0
mirror of https://github.com/TheLartians/ModernCppStarter.git synced 2025-09-03 23:50:53 +02:00

final cleanup

add some notes to not install tcov od test builds
This commit is contained in:
ClausKlein 2021-02-07 01:10:24 +01:00
parent 3c55643690
commit a6a16d64f3
2 changed files with 11 additions and 8 deletions

View file

@ -38,9 +38,9 @@ CPMAddPackage(
VERSION 1.4
)
# NOTE: If fmt is not imported, this is needed to prevent:
# CMake Error: install(EXPORT "GreeterTargets" ...) includes target
# "Greeter" which requires target "fmt" that is not in any export set.
# NOTE: If fmt is not imported, this is needed to prevent: CMake Error: install(EXPORT
# "GreeterTargets" ...) includes target "Greeter" which requires target "fmt" that is not in any
# export set.
option(FMT_INSTALL "needed!" YES)
CPMAddPackage(
@ -67,12 +67,13 @@ target_compile_features(Greeter PUBLIC cxx_std_17)
target_sources(Greeter PRIVATE ${headers} ${sources})
# being a cross-platform target, we enforce standards conformance on MSVC
# this should not exported on UNIX! CK
target_compile_options(Greeter PUBLIC "$<$<CXX_COMPILER_ID:MSVC>:/permissive->")
if(MSVC)
target_compile_options(Greeter PUBLIC /permissive)
endif()
# Link dependencies (if required)
target_link_libraries(Greeter PRIVATE fmt::fmt-header-only)
#XXX target_link_libraries(Greeter PUBLIC fmt::fmt)
# XXX target_link_libraries(Greeter PUBLIC fmt::fmt)
target_include_directories(
Greeter PUBLIC $<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/include>