From 21ccdad4601b74bd928721206ef365975627d39d Mon Sep 17 00:00:00 2001 From: Andreas Suter Date: Fri, 4 May 2018 18:18:01 +0200 Subject: [PATCH] added a missing CMakeLists.txt file. --- src/external/nexus/CMakeLists.txt | 32 +++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 src/external/nexus/CMakeLists.txt diff --git a/src/external/nexus/CMakeLists.txt b/src/external/nexus/CMakeLists.txt new file mode 100644 index 00000000..bdb25cd9 --- /dev/null +++ b/src/external/nexus/CMakeLists.txt @@ -0,0 +1,32 @@ +# - PNeXus library ------------------------------------------------------------ + +include_directories(${NEXUS_INCLUDE_DIR}) # to get the nexus headers + +#--- create pkg-config info --------------------------------------------------- +set(prefix "${CMAKE_INSTALL_PREFIX}") +set(exec_prefix "\$\{prefix\}") +set(libdir "\$\{exec_prefix\}/lib") +set(includedir "\$\{prefix\}/include") +set(PNEXUS_VERSION "0.9.0") +set(PNEXUS_LIBRARY_NAME "PNeXus") +configure_file("PNeXus.pc.in" "PNeXus.pc" @ONLY) + +#--- lib creation ------------------------------------------------------------- +add_library(PNeXus SHARED + PNeXus.cpp +) + +#--- add library dependencies ------------------------------------------------- +target_link_libraries(PNeXus ${NEXUS_LIBRARY}) + +#--- install PNeXus solib ----------------------------------------------------- +install(TARGETS PNeXus DESTINATION lib) + +#--- install PNeXus header ---------------------------------------------------- +install(FILES PNeXus.h DESTINATION include) + +#--- install pkg-config info -------------------------------------------------- +install( + FILES ${CMAKE_CURRENT_BINARY_DIR}/PNeXus.pc + DESTINATION lib/pkgconfig +)