summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Gruenbacher <agruen@suse.de>2003-02-16 20:40:14 +0000
committerAndreas Gruenbacher <agruen@suse.de>2003-02-16 20:40:14 +0000
commit18aa8f49c35c6dfd9adbce79b2c8196f16571d38 (patch)
tree84e9908f19cca792b59158ac0bcdf6e64339231e
parent3eecd9793f12f5ac7b87bceba06c343dfbc7cd3a (diff)
downloadquilt-18aa8f49c35c6dfd9adbce79b2c8196f16571d38.tar.gz
Merge James's diffstat patch (check for existence of %diffstat section removed).
-rw-r--r--Makefile.in2
-rw-r--r--configure.ac20
-rw-r--r--quilt/refresh.in2
-rw-r--r--scripts/patchfns.in3
4 files changed, 22 insertions, 5 deletions
diff --git a/Makefile.in b/Makefile.in
index 9829de8..9fdea02 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -23,6 +23,7 @@ DIFF := @DIFF@
PATCH := @PATCH@
MKTEMP := @MKTEMP@
MSGFMT := @MSGFMT@
+DIFFSTAT := @DIFFSTAT@
ifeq "$(MSGFMT)" ""
MAKE_NLS := @true
@@ -166,6 +167,7 @@ $(PACKAGE).spec : $(PACKAGE).spec.in $(PACKAGE).changes Makefile \
-e 's:@PACKAGE_BUGREPORT''@:$(PACKAGE_BUGREPORT):g' \
-e 's:@VERSION''@:$(VERSION):g' \
-e 's:@RELEASE''@:$(RELEASE):g' \
+ -e 's:@DIFFSTAT''@:$(DIFFSTAT):g' \
$< > $@
@chmod --reference=$< $@
diff --git a/configure.ac b/configure.ac
index 708f59e..cffd83b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2,7 +2,7 @@ dnl Process this file with autoconf to produce a configure script.
AC_INIT([quilt],[0.22],[quilt-dev@nongnu.org])
AC_CONFIG_AUX_DIR(config)
AC_PREREQ(2.53)
-AC_REVISION ($Revision: 1.10 $)
+AC_REVISION ($Revision: 1.11 $)
PACKAGE_RELEASE=1
AC_SUBST(PACKAGE_RELEASE)
@@ -152,6 +152,24 @@ else
AC_MSG_RESULT(yes)
fi
+# Check for diffstat
+AC_ARG_WITH(diffstat, AC_HELP_STRING(
+ [--with-diffstat], [name of the diffstat executable to use]),
+ [
+ DIFFSTAT="$withval"
+ AC_SUBST(DIFFSTAT)
+ AC_MSG_NOTICE([Using diffstat executable $DIFFSTAT])
+ ],[
+ AC_PATH_PROG(DIFFSTAT, diffstat)
+ ])
+if test -z "$DIFFSTAT"; then
+ AC_MSG_WARN([
+diffstat does not appear to be in your path, this is not a fatal error however
+$PACKAGE_NAME has increased functionality if diffstat exists. If you have diffstat
+you can specify the location the option '--with-diffstat'.
+])
+fi
+
# Check for NLS
AC_ARG_ENABLE(nls, AC_HELP_STRING(
[--enable-nls], [include natural language support]))
diff --git a/quilt/refresh.in b/quilt/refresh.in
index dc6b440..7f2c425 100644
--- a/quilt/refresh.in
+++ b/quilt/refresh.in
@@ -166,7 +166,7 @@ if [ -e $patch_file ] && grep -q '^%patch$' $patch_file
then
if [ -x "$DIFFSTAT" ]
then
- $DIFFSTAT $tmpfile 2>/dev/null \
+ @DIFFSTAT@ $tmpfile 2>/dev/null \
| @SCRIPTS@/parse-patch -u diffstat $patch_file
fi
cat $tmpfile \
diff --git a/scripts/patchfns.in b/scripts/patchfns.in
index a605b19..d9862fb 100644
--- a/scripts/patchfns.in
+++ b/scripts/patchfns.in
@@ -29,9 +29,6 @@ fi
DB=".pc/applied-patches"
-# Define where diffstat lives (may be missing)
-DIFFSTAT=/usr/bin/diffstat
-
# Quote a string for use in a basic regular expression.
quote_bre()
{