Add dependency to header only fmtlib
This commit is contained in:
parent
7a2350bc3c
commit
bafdbc35cc
@ -73,8 +73,17 @@ macro (config_hook)
|
||||
if(NOT cjson_FOUND)
|
||||
list(APPEND EXTRA_INCLUDES ${PROJECT_SOURCE_DIR}/external/cjson)
|
||||
endif()
|
||||
if(TARGET fmt::fmt)
|
||||
get_target_property(fmt_INCLUDES fmt::fmt INTERFACE_INCLUDE_DIRECTORIES)
|
||||
elseif(TARGET fmt)
|
||||
get_target_property(fmt_INCLUDES fmt INTERFACE_INCLUDE_DIRECTORIES)
|
||||
else()
|
||||
message(FATAL_ERROR "Cannot identify fmt target to use")
|
||||
endif()
|
||||
add_definitions(-DFMT_HEADER_ONLY)
|
||||
|
||||
# For this project
|
||||
include_directories(${EXTRA_INCLUDES} ${PROJECT_BINARY_DIR}/include)
|
||||
include_directories(${EXTRA_INCLUDES} ${PROJECT_BINARY_DIR}/include ${fmt_INCLUDES})
|
||||
|
||||
# For downstreams
|
||||
list(APPEND EXTRA_INCLUDES ${PROJECT_BINARY_DIR}/include)
|
||||
|
@ -15,6 +15,7 @@ set (opm-common_DEPS
|
||||
list(APPEND opm-common_DEPS
|
||||
# various runtime library enhancements
|
||||
"Boost 1.44.0 COMPONENTS system unit_test_framework REQUIRED"
|
||||
"fmt REQUIRED"
|
||||
"OpenMP QUIET"
|
||||
)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user