diff --git a/cmake/install.cmake b/cmake/install.cmake index a06b371..13565b5 100644 --- a/cmake/install.cmake +++ b/cmake/install.cmake @@ -2,8 +2,18 @@ include(CMakePackageConfigHelpers) set(ConfigPackageLocation lib/cmake/${PROJECT_NAME}) -install(TARGETS ctbench-grapher-plot ctbench-grapher-utils ctbench-compiler-launcher - EXPORT ctbench-targets) +install( + DIRECTORY grapher/include/grapher + TYPE INCLUDE) + +install( + TARGETS + grapher + ctbench-compile-opts + ctbench-grapher-plot + ctbench-grapher-utils + ctbench-compiler-launcher + EXPORT ctbench-targets) export(EXPORT ctbench-targets FILE ctbench-targets.cmake) @@ -16,14 +26,18 @@ install(FILES cmake/ctbench-api.cmake DESTINATION ${ConfigPackageLocation}) # CMake package config files -configure_package_config_file(cmake/ctbench-config.cmake.in ctbench-config.cmake - INSTALL_DESTINATION ${ConfigPackageLocation}) +configure_package_config_file( + cmake/ctbench-config.cmake.in + ctbench-config.cmake + INSTALL_DESTINATION ${ConfigPackageLocation}) write_basic_package_version_file( ctbench-config-version.cmake VERSION ${PROJECT_VERSION} COMPATIBILITY SameMajorVersion) -install(FILES ${CMAKE_BINARY_DIR}/ctbench-config.cmake - ${CMAKE_BINARY_DIR}/ctbench-config-version.cmake - DESTINATION ${ConfigPackageLocation}) +install( + FILES + ${CMAKE_BINARY_DIR}/ctbench-config.cmake + ${CMAKE_BINARY_DIR}/ctbench-config-version.cmake + DESTINATION ${ConfigPackageLocation}) diff --git a/grapher/cmake/grapher-target.cmake b/grapher/cmake/grapher-target.cmake index 0a8fd4a..dbbe55c 100644 --- a/grapher/cmake/grapher-target.cmake +++ b/grapher/cmake/grapher-target.cmake @@ -2,12 +2,22 @@ file(GLOB_RECURSE GRAPHER_SOURCES lib/*.cpp) add_library(grapher STATIC ${GRAPHER_SOURCES}) -target_include_directories(grapher PUBLIC include) +target_include_directories(grapher + PUBLIC + "$/include" + "$" +) llvm_map_components_to_libnames(llvm_libs support) -target_link_libraries( - grapher PUBLIC ctbench-compile-opts nlohmann_json::nlohmann_json - sciplot::sciplot fmt::fmt stdc++fs tbb ${llvm_libs}) +target_link_libraries(grapher + PUBLIC + ctbench-compile-opts + nlohmann_json::nlohmann_json + sciplot::sciplot + fmt::fmt + stdc++fs + tbb + ${llvm_libs}) target_compile_options(grapher PUBLIC -DJSON_NOEXCEPTION)