summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile.am4
-rw-r--r--configure.in1
-rw-r--r--libart-2.0-uninstalled.pc.in2
-rw-r--r--libart-2.0.pc.in2
-rw-r--r--libart2-config (renamed from libart-config.in)27
5 files changed, 17 insertions, 19 deletions
diff --git a/Makefile.am b/Makefile.am
index aec6c5d..a7399d1 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -12,7 +12,6 @@ art_config.h:
EXTRA_DIST = \
libart.def \
- libart-config.in \
libart-2.0.pc.in \
libart-2.0-uninstalled.pc.in
@@ -166,9 +165,6 @@ tests: testart testuta
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = libart-2.0.pc
-libart2-config: libart-config
- cp -f libart-config libart2-config
-
install-data-local: install-ms-lib install-libtool-import-lib
uninstall-local: uninstall-ms-lib uninstall-libtool-import-lib
diff --git a/configure.in b/configure.in
index 0010d48..ba44d56 100644
--- a/configure.in
+++ b/configure.in
@@ -108,7 +108,6 @@ libart-2.0.pc
libart-2.0-uninstalled.pc
libart-zip])
-AC_CONFIG_FILES([libart-config],[chmod +x libart-config])
AC_CONFIG_FILES([gen_art_config.sh],[chmod +x gen_art_config.sh])
AC_OUTPUT
diff --git a/libart-2.0-uninstalled.pc.in b/libart-2.0-uninstalled.pc.in
index f731e54..6dddc9d 100644
--- a/libart-2.0-uninstalled.pc.in
+++ b/libart-2.0-uninstalled.pc.in
@@ -5,6 +5,6 @@ includedir=@includedir@
Name: libart
Description: LGPL version of the libart library
-Version: @VERSION@
+Version: @LIBART_VERSION@
Libs: ${pc_top_builddir}/${pcfiledir}/libart_lgpl_2.la
Cflags: -I${pc_top_builddir}/${pcfiledir}
diff --git a/libart-2.0.pc.in b/libart-2.0.pc.in
index 1df143b..063e1f5 100644
--- a/libart-2.0.pc.in
+++ b/libart-2.0.pc.in
@@ -5,6 +5,6 @@ includedir=@includedir@
Name: libart
Description: LGPL version of the libart library
-Version: @VERSION@
+Version: @LIBART_VERSION@
Libs: -L${libdir} -lart_lgpl_2
Cflags: -I${includedir}/libart-2.0
diff --git a/libart-config.in b/libart2-config
index e32f010..2d97c61 100644
--- a/libart-config.in
+++ b/libart2-config
@@ -1,19 +1,24 @@
#!/bin/sh
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-exec_prefix_set=no
-libs=""
-output_libs=no
-
usage="\
-Usage: libart-config [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--libs] [--cflags]"
+Usage: libart2-config [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--libs] [--cflags]"
if test $# -eq 0; then
echo "${usage}" 1>&2
exit 1
fi
+if ! which pkg-config >/dev/null; then
+ echo "pkg-config not found on your system" 1>&2
+ exit 1
+fi
+
+prefix=`pkg-config --variable=prefix libart-2.0`
+exec_prefix=`pkg-config --variable=exec_prefix libart-2.0`
+exec_prefix_set=no
+libs=""
+output_libs=no
+
while test $# -gt 0; do
case "$1" in
-*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
@@ -38,14 +43,13 @@ while test $# -gt 0; do
echo $exec_prefix
;;
--version)
- echo @LIBART_VERSION@
+ echo `pkg-config --modversion libart-2.0`
;;
--cflags)
- includes=-I@includedir@/libart-2.0
- echo $includes
+ echo `pkg-config --cflags-only-I libart-2.0`
;;
--libs)
- libs="$libs -L@libdir@ -lart_lgpl_2"
+ libs=`pkg-config --libs libart-2.0`
output_libs=yes
;;
--static)
@@ -62,4 +66,3 @@ done
if test $output_libs = yes ; then
echo $libs
fi
-