1cmake_minimum_required(VERSION 3.1...3.18) 2 3project(fmt-test) 4 5add_subdirectory(../.. fmt) 6 7add_executable(library-test "main.cc") 8target_link_libraries(library-test fmt::fmt) 9target_compile_options(library-test PRIVATE ${PEDANTIC_COMPILE_FLAGS}) 10target_include_directories(library-test PUBLIC SYSTEM .) 11 12if (TARGET fmt::fmt-header-only) 13 add_executable(header-only-test "main.cc") 14 target_link_libraries(header-only-test fmt::fmt-header-only) 15 target_compile_options(header-only-test PRIVATE ${PEDANTIC_COMPILE_FLAGS}) 16 target_include_directories(header-only-test PUBLIC SYSTEM .) 17endif () 18