diff --git a/cgogn/core/CMakeLists.txt b/cgogn/core/CMakeLists.txt index 74fd732f..53b2c9a3 100644 --- a/cgogn/core/CMakeLists.txt +++ b/cgogn/core/CMakeLists.txt @@ -274,6 +274,9 @@ else() target_compile_definitions(${PROJECT_NAME} PUBLIC "CGOGN_ENDIANNESS=CGOGN_LITTLE_ENDIAN") endif() +configure_file(${PROJECT_SOURCE_DIR}/cgogn_core.pc.in ${CMAKE_CURRENT_BINARY_DIR}/cgogn_core.pc @ONLY) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/cgogn_core.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) + install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/cgogn/core FILES_MATCHING PATTERN "*.h" diff --git a/cgogn/core/cgogn_core.pc.in b/cgogn/core/cgogn_core.pc.in new file mode 100644 index 00000000..ae4f5524 --- /dev/null +++ b/cgogn/core/cgogn_core.pc.in @@ -0,0 +1,12 @@ +prefix=@CMAKE_INSTALL_PREFIX@ +exec_prefix=${prefix} +libdir=@CMAKE_INSTALL_LIBDIR@ +includedir=@CMAKE_INSTALL_INCLUDEDIR@ + +Name: @PROJECT_NAME@ +Description: core library of the cgogn geometric modeling kernel +Version: @CGoGN_VERSION@ +Requires: @PKG_CONFIG_REQUIRES@ + +Libs: -L${libdir} -l@PROJECT_NAME@ +Cflags: -I${includedir} diff --git a/cgogn/geometry/CMakeLists.txt b/cgogn/geometry/CMakeLists.txt index 14660165..7e7728ed 100644 --- a/cgogn/geometry/CMakeLists.txt +++ b/cgogn/geometry/CMakeLists.txt @@ -69,6 +69,10 @@ target_include_directories(${PROJECT_NAME} PUBLIC target_link_libraries(${PROJECT_NAME} cgogn::core Eigen3::Eigen) +set(PKG_CONFIG_REQUIRES "cgogn_core") +configure_file(${PROJECT_SOURCE_DIR}/cgogn_geometry.pc.in ${CMAKE_CURRENT_BINARY_DIR}/cgogn_geometry.pc @ONLY) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/cgogn_geometry.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) + install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/cgogn/geometry FILES_MATCHING PATTERN "*.h" diff --git a/cgogn/geometry/cgogn_geometry.pc.in b/cgogn/geometry/cgogn_geometry.pc.in new file mode 100644 index 00000000..9b43d1f6 --- /dev/null +++ b/cgogn/geometry/cgogn_geometry.pc.in @@ -0,0 +1,12 @@ +prefix=@CMAKE_INSTALL_PREFIX@ +exec_prefix=${prefix} +libdir=@CMAKE_INSTALL_LIBDIR@ +includedir=@CMAKE_INSTALL_INCLUDEDIR@ + +Name: @PROJECT_NAME@ +Description: geometry library of the cgogn geometric modeling kernel +Version: @CGoGN_VERSION@ +Requires: @PKG_CONFIG_REQUIRES@ + +Libs: -L${libdir} -l@PROJECT_NAME@ +Cflags: -I${includedir} diff --git a/cgogn/io/CMakeLists.txt b/cgogn/io/CMakeLists.txt index 7253485f..082912d5 100644 --- a/cgogn/io/CMakeLists.txt +++ b/cgogn/io/CMakeLists.txt @@ -73,6 +73,10 @@ target_include_directories(${PROJECT_NAME} PUBLIC target_link_libraries(${PROJECT_NAME} cgogn::core cgogn::geometry ZLIB::ZLIB ply Meshb TinyXML2::TinyXML2) +set(PKG_CONFIG_REQUIRES "cgogn_core cgogn_geometry") +configure_file(${PROJECT_SOURCE_DIR}/cgogn_io.pc.in ${CMAKE_CURRENT_BINARY_DIR}/cgogn_io.pc @ONLY) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/cgogn_io.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) + install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/cgogn/io FILES_MATCHING PATTERN "*.h" diff --git a/cgogn/io/cgogn_io.pc.in b/cgogn/io/cgogn_io.pc.in new file mode 100644 index 00000000..0d168690 --- /dev/null +++ b/cgogn/io/cgogn_io.pc.in @@ -0,0 +1,12 @@ +prefix=@CMAKE_INSTALL_PREFIX@ +exec_prefix=${prefix} +libdir=@CMAKE_INSTALL_LIBDIR@ +includedir=@CMAKE_INSTALL_INCLUDEDIR@ + +Name: @PROJECT_NAME@ +Description: I/O library of the cgogn geometric modeling kernel +Version: @CGoGN_VERSION@ +Requires: @PKG_CONFIG_REQUIRES@ + +Libs: -L${libdir} -l@PROJECT_NAME@ +Cflags: -I${includedir} diff --git a/cgogn/modeling/CMakeLists.txt b/cgogn/modeling/CMakeLists.txt index 2ee5f631..144e79f4 100644 --- a/cgogn/modeling/CMakeLists.txt +++ b/cgogn/modeling/CMakeLists.txt @@ -56,6 +56,9 @@ target_include_directories(${PROJECT_NAME} PUBLIC target_link_libraries(${PROJECT_NAME} cgogn::core cgogn::geometry) +set(PKG_CONFIG_REQUIRES "cgogn_core cgogn_geometry") +configure_file(${PROJECT_SOURCE_DIR}/cgogn_modeling.pc.in ${CMAKE_CURRENT_BINARY_DIR}/cgogn_modeling.pc @ONLY) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/cgogn_modeling.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/cgogn/modeling diff --git a/cgogn/modeling/cgogn_modeling.pc.in b/cgogn/modeling/cgogn_modeling.pc.in new file mode 100644 index 00000000..d085c1a1 --- /dev/null +++ b/cgogn/modeling/cgogn_modeling.pc.in @@ -0,0 +1,12 @@ +prefix=@CMAKE_INSTALL_PREFIX@ +exec_prefix=${prefix} +libdir=@CMAKE_INSTALL_LIBDIR@ +includedir=@CMAKE_INSTALL_INCLUDEDIR@ + +Name: @PROJECT_NAME@ +Description: modeling library of the cgogn geometric modeling kernel +Version: @CGoGN_VERSION@ +Requires: @PKG_CONFIG_REQUIRES@ + +Libs: -L${libdir} -l@PROJECT_NAME@ +Cflags: -I${includedir} diff --git a/cgogn/rendering/CMakeLists.txt b/cgogn/rendering/CMakeLists.txt index fb53ea48..38ff6d1e 100644 --- a/cgogn/rendering/CMakeLists.txt +++ b/cgogn/rendering/CMakeLists.txt @@ -99,6 +99,10 @@ target_include_directories(${PROJECT_NAME} PUBLIC target_link_libraries(${PROJECT_NAME} cgogn::core cgogn::geometry Qt5::Gui QOGLViewer) +set(PKG_CONFIG_REQUIRES "cgogn_core cgogn_geometry") +configure_file(${PROJECT_SOURCE_DIR}/cgogn_rendering.pc.in ${CMAKE_CURRENT_BINARY_DIR}/cgogn_rendering.pc @ONLY) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/cgogn_rendering.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) + install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/cgogn/rendering FILES_MATCHING PATTERN "*.h" diff --git a/cgogn/rendering/cgogn_rendering.pc.in b/cgogn/rendering/cgogn_rendering.pc.in new file mode 100644 index 00000000..7aebb52d --- /dev/null +++ b/cgogn/rendering/cgogn_rendering.pc.in @@ -0,0 +1,12 @@ +prefix=@CMAKE_INSTALL_PREFIX@ +exec_prefix=${prefix} +libdir=@CMAKE_INSTALL_LIBDIR@ +includedir=@CMAKE_INSTALL_INCLUDEDIR@ + +Name: @PROJECT_NAME@ +Description: rendering library of the cgogn geometric modeling kernel +Version: @CGoGN_VERSION@ +Requires: @PKG_CONFIG_REQUIRES@ + +Libs: -L${libdir} -l@PROJECT_NAME@ +Cflags: -I${includedir} diff --git a/cgogn/topology/CMakeLists.txt b/cgogn/topology/CMakeLists.txt index 02861d17..76871c46 100644 --- a/cgogn/topology/CMakeLists.txt +++ b/cgogn/topology/CMakeLists.txt @@ -38,6 +38,10 @@ target_include_directories(${PROJECT_NAME} PUBLIC target_link_libraries(${PROJECT_NAME} cgogn::core cgogn::geometry) +set(PKG_CONFIG_REQUIRES "cgogn_core cgogn_geometry") +configure_file(${PROJECT_SOURCE_DIR}/cgogn_topology.pc.in ${CMAKE_CURRENT_BINARY_DIR}/cgogn_topology.pc @ONLY) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/cgogn_topology.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) + install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/cgogn/topology FILES_MATCHING PATTERN "*.h" diff --git a/cgogn/topology/cgogn_topology.pc.in b/cgogn/topology/cgogn_topology.pc.in new file mode 100644 index 00000000..0c1dc756 --- /dev/null +++ b/cgogn/topology/cgogn_topology.pc.in @@ -0,0 +1,12 @@ +prefix=@CMAKE_INSTALL_PREFIX@ +exec_prefix=${prefix} +libdir=@CMAKE_INSTALL_LIBDIR@ +includedir=@CMAKE_INSTALL_INCLUDEDIR@ + +Name: @PROJECT_NAME@ +Description: topology library of the cgogn geometric modeling kernel +Version: @CGoGN_VERSION@ +Requires: @PKG_CONFIG_REQUIRES@ + +Libs: -L${libdir} -l@PROJECT_NAME@ +Cflags: -I${includedir}