summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarc Kleine-Budde <mkl@pengutronix.de>2005-04-07 07:18:15 +0000
committerMarc Kleine-Budde <mkl@pengutronix.de>2005-04-07 07:18:15 +0000
commit827e4a0309d13f4107635a6b98e5e55b72f54261 (patch)
tree3009b54243951323b5b9ed2f5bdc1ff623646b1f
parent6ce5e3197aff991ee9a3c5b9bbc35c75703e6d69 (diff)
downloadcanutils-827e4a0309d13f4107635a6b98e5e55b72f54261.tar.gz
canutils-827e4a0309d13f4107635a6b98e5e55b72f54261.tar.xz
added pkg-config file
git-svn-id: https://iocaste.extern.pengutronix.de/svn/canutils/trunks/canutils-1.0-trunk@20 5fd5a299-6ef2-0310-aa18-8b01d7c39d8c
-rw-r--r--Makefile.am6
-rw-r--r--autogen.sh29
-rw-r--r--config/Makefile.am7
-rw-r--r--config/canutils.pc.in9
-rw-r--r--configure.ac5
5 files changed, 40 insertions, 16 deletions
diff --git a/Makefile.am b/Makefile.am
index d6682f8..fbbbc59 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,11 +1,7 @@
-#
-# Binary programs
-#
-
bin_PROGRAMS = candump canecho cansend
sbin_PROGRAMS = canconfig
-SUBDIRS = include
+SUBDIRS = include config
AM_CPPFLAGS = \
-I$(top_srcdir)/include
diff --git a/autogen.sh b/autogen.sh
index a4dddc3..3bcd1a7 100644
--- a/autogen.sh
+++ b/autogen.sh
@@ -1,16 +1,25 @@
#!/bin/sh
+ACLOCAL=${ACLOCAL:=aclocal}
+AUTOHEADER=${AUTOHEADER:=autoheader}
+AUTOMAKE=${AUTOMAKE:=automake}
+AUTOCONF=${AUTOCONF:=autoconf}
-echo "running aclocal (tested with 1.7.9)..."
-aclocal -I config/m4
+echo use aclocal: $ACLOCAL
+echo use autoheader: $AUTOHEADER
+echo use automake: $AUTOMAKE
+echo use autoconf: $AUTOCONF
-echo "running libtoolize (tested with 1.5.6)..."
-libtoolize --force
+$ACLOCAL --version | \
+ awk -vPROG="aclocal" -vVERS=1.7\
+ '{if ($1 == PROG) {gsub ("-.*","",$4); if ($4 < VERS) print PROG" < version "VERS"\nThis may result in errors\n"}}'
-echo "running autoheader"
-autoheader
+$AUTOMAKE --version | \
+ awk -vPROG="automake" -vVERS=1.7\
+ '{if ($1 == PROG) {gsub ("-.*","",$4); if ($4 < VERS) print PROG" < version "VERS"\nThis may result in errors\n"}}'
-echo "running automake (tested with 1.7.9)..."
-automake --add-missing --gnu -Wall
+$ACLOCAL -I config/m4 && \
+libtoolize --force && \
+$AUTOHEADER && \
+$AUTOMAKE --gnu --add-missing -Wall && \
+$AUTOCONF -Wall
-echo "running autoconf (tested with 2.59)..."
-autoconf \ No newline at end of file
diff --git a/config/Makefile.am b/config/Makefile.am
new file mode 100644
index 0000000..e373214
--- /dev/null
+++ b/config/Makefile.am
@@ -0,0 +1,7 @@
+EXTRA_DIST = canutils.pc.in
+
+pkgconfigdir = $(libdir)/pkgconfig
+pkgconfig_DATA = canutils.pc
+
+MAINTAINERCLEANFILES = \
+ Makefile.in \ No newline at end of file
diff --git a/config/canutils.pc.in b/config/canutils.pc.in
new file mode 100644
index 0000000..29e86f0
--- /dev/null
+++ b/config/canutils.pc.in
@@ -0,0 +1,9 @@
+prefix=@prefix@
+exec_prefix=@exec_prefix@
+libdir=@libdir@
+includedir=@includedir@
+
+Name: canutils
+Description: ifconfig like tool for can devices
+Version: @VERSION@
+Cflags: -I${includedir}/socket-can \ No newline at end of file
diff --git a/configure.ac b/configure.ac
index 4ce6dff..ce2c675 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3,7 +3,7 @@
AC_PREREQ(2.59)
-AC_INIT([canutils], [1.0.1], [socket-can@pengutronix.de])
+AC_INIT([canutils], [1.0.2], [socket-can@pengutronix.de])
AC_CONFIG_HEADERS([include/can_config.h])
AC_CONFIG_AUX_DIR([config/autoconf])
AC_CONFIG_MACRO_DIR([config/m4])
@@ -36,6 +36,9 @@ AC_TYPE_SIZE_T
# Checks for library functions.
AC_CONFIG_FILES([ \
Makefile \
+ config/canutils.pc \
+ config/Makefile \
include/Makefile \
])
+
AC_OUTPUT