cmake: Add pkgconfig file.
authorAndreas Schneider <asn@samba.org>
Wed, 22 Jan 2014 09:28:11 +0000 (10:28 +0100)
committerAndreas Schneider <asn@samba.org>
Wed, 22 Jan 2014 09:28:11 +0000 (10:28 +0100)
CMakeLists.txt
nss_wrapper.pc.cmake [new file with mode: 0644]

index e8b0ad0cdd8b9825af6968f7212a5e3dbd13d365..0ea202d2fc498aba4866e47a6a72c4ea6089a7da 100644 (file)
@@ -56,6 +56,17 @@ install(
     DESTINATION
         ${BIN_INSTALL_DIR})
 
+# pkg-config file
+configure_file(nss_wrapper.pc.cmake ${CMAKE_CURRENT_BINARY_DIR}/nss_wrapper.pc @ONLY)
+install(
+  FILES
+    ${CMAKE_CURRENT_BINARY_DIR}/nss_wrapper.pc
+  DESTINATION
+    ${LIB_INSTALL_DIR}/pkgconfig
+  COMPONENT
+    pkgconfig
+)
+
 if (UNIT_TESTING)
     find_package(CMocka REQUIRED)
     include(AddCMockaTest)
diff --git a/nss_wrapper.pc.cmake b/nss_wrapper.pc.cmake
new file mode 100644 (file)
index 0000000..6fb8ff2
--- /dev/null
@@ -0,0 +1,3 @@
+Name: @APPLICATION_NAME@
+Description: The nss_wrapper library
+Version: @APPLICATION_VERSION@