Skip to content
Snippets Groups Projects
Commit 0735a00f authored by Carl Philipp Klemm's avatar Carl Philipp Klemm
Browse files

Add pkg-config files, add install information

parent aa121593
Branches
No related tags found
No related merge requests found
......@@ -6,6 +6,12 @@ find_package(PkgConfig REQUIRED)
pkg_search_module(EIS REQUIRED libeisgenerator)
find_package(sciplot)
set(API_HEADERS_CPP_DIR eisnoise/)
set(API_HEADERS_CPP
${API_HEADERS_CPP_DIR}/eisnoise.h
)
set(COMMON_COMPILE_OPTIONS
"-Wall"
"-Wno-reorder"
......@@ -20,6 +26,11 @@ target_link_libraries( ${PROJECT_NAME} -lpthread ${EIS_LIBRARIES} -ltbb)
target_include_directories(${PROJECT_NAME} PRIVATE ${EIS_INCLUDE_DIRS})
target_compile_definitions(${PROJECT_NAME} PUBLIC DATA_DIR="${CMAKE_CURRENT_SOURCE_DIR}")
target_compile_options(${PROJECT_NAME} PRIVATE ${COMMON_COMPILE_OPTIONS})
configure_file(pkgconfig/libeisnoise.in pkgconfig/libeisnoise.pc @ONLY)
install(TARGETS ${PROJECT_NAME} DESTINATION lib)
install(TARGETS ${PROJECT_NAME} FILE_SET header_set DESTINATION include/${PROJECT_NAME})
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/pkgconfig/libeisnoise.pc DESTINATION lib/pkgconfig)
if(NOT sciplot_FOUND)
message(WARNING "Sciplot not found, ${PROJECT_NAME}_test application wont be compiled")
......
includedir=@CMAKE_INSTALL_PREFIX@/include
libdir=@CMAKE_INSTALL_PREFIX@/lib
Name: libeisnoise
Description: EIS noise library
Version: 1.0
Libs: -L${libdir} -leisnoise
Cflags: -I${includedir}/@API_HEADERS_CPP_DIR@
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment