Minore cmake fix

This commit is contained in:
gabime 2019-05-12 16:13:13 +03:00
parent 8b4eedb594
commit ee0fdf016a

View File

@ -63,7 +63,7 @@ if(SPDLOG_STATIC_LIB)
set(SRC_FILES "${SRC_BASE}/spdlog.cpp")
add_library(spdlog STATIC ${SRC_FILES})
target_include_directories(spdlog PUBLIC "$<BUILD_INTERFACE:${CMAKE_CURRENT_LIST_DIR}/include>")
target_link_libraries(spdlog -Wl,--as-needed)
target_link_libraries(spdlog)
else()
add_library(spdlog INTERFACE)
target_include_directories(spdlog INTERFACE "$<BUILD_INTERFACE:${CMAKE_CURRENT_LIST_DIR}/include>")