]> git.sur5r.net Git - kconfig-frontends/commitdiff
libs/parser: add pkg-config file
authorYann E. MORIN <yann.morin.1998@free.fr>
Mon, 28 Nov 2016 18:59:03 +0000 (19:59 +0100)
committerYann E. MORIN <yann.morin.1998@free.fr>
Tue, 29 Nov 2016 20:07:06 +0000 (21:07 +0100)
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
.gitignore
Makefile.am
configure.ac
libs/parser/kconfig-parser.pc.in [new file with mode: 0644]

index a4095f8636918a15deae2a987975f40ef93f01d0..69bf859d7e2ac8767ddd44e6141ac0f5e8321c7b 100644 (file)
@@ -21,6 +21,7 @@
 /libs/parser/hconf.c
 /libs/parser/lconf.c
 /libs/parser/yconf.c
+/libs/parser/kconfig-parser.pc
 
 /utils/kconfig-tweak
 /utils/kconfig-gettext
index 3b0d65160315c1a10658328c5d05013487acda6b..1bde1e36c5f7ec2b0fc62772921fd00c8226cddc 100644 (file)
@@ -85,6 +85,12 @@ BUILT_SOURCES += libs/parser/hconf.c libs/parser/lconf.c
 CLEANFILES += libs/parser/hconf.c libs/parser/lconf.c libs/parser/yconf.c
 EXTRA_DIST += libs/parser/yconf.y.patch
 
+# libs/parser/kconfig-parser.pc generated by AC_CONFIG_FILES in configure.ac
+pkgconfigdir = $(libdir)/pkg-config
+pkgconfig_DATA = libs/parser/kconfig-parser.pc
+CLEANFILES += libs/parser/kconfig-parser.pc
+EXTRA_DIST += libs/parser/kconfig-parser.pc.in
+
 #--------------------------
 # lxdialog lib (for mconf)
 if COND_lxdialog
index ba7db9b155bdff560e8d0bb265b24b16558f162f..b465dac4ed49dc8b1241023e361e5c9142e45582 100644 (file)
@@ -498,8 +498,14 @@ AS_IF(
 
 #----------------------------------------
 # Finalise
+# All generated files are generated by a Makefile rule, except Makefile
+# itself of course.
+# There is no generic solution in automake to generate a file from its
+# .in source, so we'd have to provide custom, hand-made rules, which is
+# not nice. So, we handle libs/parser/kconfig-parser.pc here.
 AC_CONFIG_FILES([
     Makefile
+    libs/parser/kconfig-parser.pc
 ])
 AC_OUTPUT
 
diff --git a/libs/parser/kconfig-parser.pc.in b/libs/parser/kconfig-parser.pc.in
new file mode 100644 (file)
index 0000000..086b3f8
--- /dev/null
@@ -0,0 +1,11 @@
+prefix=@prefix@
+exec_prefix=@exec_prefix@
+libdir=@libdir@
+includedir=${prefix}/include
+
+Name: kconfig-parser
+Description: kconfig-parser library
+Requires:
+Version: @KCONFIGPARSER_LIB_VERSION@
+Libs: -L${libdir} -lkconfig-parser
+Cflags: -I${includedir}