[pacman-dev] [PATCH] libalpm: add pkg-config file
Dave Reisner
d at falconindy.com
Tue Mar 20 00:00:31 EDT 2012
Borrowed heavily from libarchive.
Signed-off-by: Dave Reisner <dreisner at archlinux.org>
---
Throw a bone to the few projects who link against us...
configure.ac | 1 +
lib/libalpm/Makefile.am | 3 +++
lib/libalpm/libalpm.pc.in | 11 +++++++++++
3 files changed, 15 insertions(+)
create mode 100644 lib/libalpm/libalpm.pc.in
diff --git a/configure.ac b/configure.ac
index 12a6e65..9093a90 100644
--- a/configure.ac
+++ b/configure.ac
@@ -382,6 +382,7 @@ AC_DEFINE_UNQUOTED([SCRIPTLET_SHELL], "$SCRIPTLET_SHELL", [The shell used to run
AC_CONFIG_FILES([
lib/libalpm/Makefile
lib/libalpm/po/Makefile.in
+lib/libalpm/libalpm.pc
src/pacman/Makefile
src/pacman/po/Makefile.in
src/util/Makefile
diff --git a/lib/libalpm/Makefile.am b/lib/libalpm/Makefile.am
index 61dcb87..17d9a58 100644
--- a/lib/libalpm/Makefile.am
+++ b/lib/libalpm/Makefile.am
@@ -23,6 +23,9 @@ if ENABLE_GNU89_INLINE_CC
AM_CFLAGS += -fgnu89-inline
endif
+pkgconfigdir = $(libdir)/pkgconfig
+pkgconfig_DATA = libalpm.pc
+
libalpm_la_SOURCES = \
add.h add.c \
alpm.h alpm.c \
diff --git a/lib/libalpm/libalpm.pc.in b/lib/libalpm/libalpm.pc.in
new file mode 100644
index 0000000..12bea28
--- /dev/null
+++ b/lib/libalpm/libalpm.pc.in
@@ -0,0 +1,11 @@
+prefix=@prefix@
+exec_prefix=@exec_prefix@
+libdir=@libdir@
+includedir=@includedir@
+
+Name: libalpm
+Description: Arch Linux package management library
+Version: @VERSION@
+Cflags: -I${includedir}
+Libs: -L${libdir} -lalpm
+Libs.private: @LIBS@
--
1.7.9.4
More information about the pacman-dev
mailing list