Switched to header only spdlog for better portability
This commit is contained in:
@@ -23,19 +23,6 @@ if(LLVM_CONFIG_PATH)
|
||||
set(LLVM_CONFIG_BINARY ${LLVM_CONFIG_PATH})
|
||||
endif(LLVM_CONFIG_PATH)
|
||||
|
||||
message(STATUS "Checking for fmt...")
|
||||
find_package(fmt REQUIRED)
|
||||
|
||||
message(STATUS "Checking for spdlog...")
|
||||
find_package(spdlog REQUIRED)
|
||||
if(APPLE)
|
||||
get_target_property(SPDLOG_INCLUDE_DIRS spdlog::spdlog_header_only INTERFACE_INCLUDE_DIRECTORIES)
|
||||
else(APPLE)
|
||||
get_target_property(SPDLOG_INCLUDE_DIRS spdlog::spdlog INTERFACE_INCLUDE_DIRECTORIES)
|
||||
add_definitions(-DSPDLOG_FMT_EXTERNAL)
|
||||
endif(APPLE)
|
||||
|
||||
|
||||
message(STATUS "Checking for yaml-cpp...")
|
||||
find_package(yaml-cpp REQUIRED)
|
||||
|
||||
@@ -68,7 +55,6 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
|
||||
endif()
|
||||
include_directories(${CLANG_UML_INSTALL_INCLUDE_DIR})
|
||||
include_directories(${YAML_CPP_INCLUDE_DIR})
|
||||
include_directories(${SPDLOG_INCLUDE_DIRS})
|
||||
include_directories(${UML_HEADERS_DIR})
|
||||
include_directories(${THIRDPARTY_HEADERS_DIR})
|
||||
include_directories(${THIRDPARTY_HEADERS_DIR}/cppast/include)
|
||||
@@ -84,12 +70,7 @@ add_library(clang-umllib OBJECT ${SOURCES})
|
||||
|
||||
add_executable(clang-uml ${MAIN_SOURCE_FILE})
|
||||
install(TARGETS clang-uml DESTINATION ${CLANG_UML_INSTALL_BIN_DIR})
|
||||
target_link_libraries(clang-uml ${LIBCLANG_LIBRARIES} ${YAML_CPP_LIBRARIES} fmt::fmt cppast clang-umllib)
|
||||
if(APPLE)
|
||||
target_link_libraries(clang-uml spdlog::spdlog_header_only)
|
||||
else(APPLE)
|
||||
target_link_libraries(clang-uml spdlog::spdlog)
|
||||
endif(APPLE)
|
||||
target_link_libraries(clang-uml ${LIBCLANG_LIBRARIES} ${YAML_CPP_LIBRARIES} cppast clang-umllib)
|
||||
|
||||
target_compile_features(clang-uml PRIVATE cxx_std_17)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user