From 8dbf12ef43b0d77d94811608cd3754cf2de6fdfb Mon Sep 17 00:00:00 2001 From: Andrey Astafyev Date: Tue, 12 Feb 2019 23:18:40 +0300 Subject: [PATCH] =?UTF-8?q?=D0=90=D0=B2=D1=82=D0=BE=D0=BC=D0=B0=D1=82?= =?UTF-8?q?=D0=B8=D1=87=D0=B5=D1=81=D0=BA=D0=BE=D0=B5=20=D1=81=D0=BE=D0=B7?= =?UTF-8?q?=D0=B4=D0=B0=D0=BD=D0=B8=D0=B5=20=D1=84=D0=B0=D0=B9=D0=BB=D0=B0?= =?UTF-8?q?=20=D0=B4=D0=BB=D1=8F=20pkgconfig?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CMLibCommonLibraryTarget.cmake | 1 + pc/lib.pc.in | 13 +++++++++++++ 2 files changed, 14 insertions(+) create mode 100644 pc/lib.pc.in diff --git a/CMLibCommonLibraryTarget.cmake b/CMLibCommonLibraryTarget.cmake index 2891f78..601b43a 100644 --- a/CMLibCommonLibraryTarget.cmake +++ b/CMLibCommonLibraryTarget.cmake @@ -20,5 +20,6 @@ function(add_common_library LIBNAME SOURCES) set_target_properties(${LIBNAME}_static PROPERTIES OUTPUT_NAME ${LIBNAME} ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_INSTALL_LIBDIR}) + configure_file(${CMAKE_SOURCE_DIR}/cmake/cmlib/pc/lib.pc.in ${CMAKE_BINARY_DIR}/${LIBNAME}.pc) endfunction() diff --git a/pc/lib.pc.in b/pc/lib.pc.in new file mode 100644 index 0000000..681db44 --- /dev/null +++ b/pc/lib.pc.in @@ -0,0 +1,13 @@ +prefix=@CMAKE_INSTALL_PREFIX@ +exec_prefix=@CMAKE_INSTALL_PREFIX@ +libdir=@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_LIBDIR@ +includedir=@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_INCLUDEDIR@ + +Name: @current_target@ +Description: @current_target@ library +Version: @_ver@ + +Requires: +Libs: -L@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_LIBDIR@ -l@current_target@ +Cflags: -I@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_INCLUDEDIR@ +