summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Gruenbacher <agruen@suse.de>2003-01-31 12:45:37 +0000
committerAndreas Gruenbacher <agruen@suse.de>2003-01-31 12:45:37 +0000
commit21a15e55a81ea4bd2bc21729ceebe6be6a9ccd9b (patch)
tree150f25f9add7ecb5ae144ab63a62c3b43d25f378
parentf07f43d191fe23209876061b7a31b5cb1e9a219d (diff)
downloadquilt-21a15e55a81ea4bd2bc21729ceebe6be6a9ccd9b.tar.gz
Install binary backup-files into /usr/lib/quilt and the remaining scripts under /usr/share/quilt/scripts.
-rw-r--r--Makefile37
-rw-r--r--quilt.changes4
-rw-r--r--quilt/add.in6
-rw-r--r--quilt/applied.in6
-rw-r--r--quilt/delete.in8
-rw-r--r--quilt/diff.in6
-rw-r--r--quilt/files.in6
-rw-r--r--quilt/import.in8
-rw-r--r--quilt/new.in6
-rw-r--r--quilt/next.in6
-rw-r--r--quilt/patches.in6
-rw-r--r--quilt/pop.in8
-rw-r--r--quilt/previous.in6
-rw-r--r--quilt/push.in8
-rw-r--r--quilt/refresh.in10
-rw-r--r--quilt/remove.in6
-rw-r--r--quilt/series.in6
-rw-r--r--quilt/setup.in8
-rw-r--r--quilt/top.in6
-rw-r--r--quilt/unapplied.in6
-rwxr-xr-xscripts/apatch.in (renamed from lib/apatch.in)6
-rw-r--r--[-rwxr-xr-x]scripts/parse-patch.in (renamed from lib/parse-patch.in)0
-rw-r--r--scripts/patchfns.in (renamed from lib/patchfns.in)0
-rwxr-xr-xscripts/rpatch.in (renamed from lib/rpatch.in)6
-rwxr-xr-xscripts/spec2series.in (renamed from lib/spec2series.in)0
25 files changed, 94 insertions, 81 deletions
diff --git a/Makefile b/Makefile
index ab0c47c..4b527ed 100644
--- a/Makefile
+++ b/Makefile
@@ -9,7 +9,8 @@ mandir := $(datadir)/man
docdir := $(datadir)/doc/packages
QUILT_DIR = $(datadir)/$(PACKAGE)
-LIB_DIR = $(datadir)/$(PACKAGE)/lib
+SCRIPTS_DIR = $(QUILT_DIR)/scripts
+LIB_DIR = $(prefix)/lib/$(PACKAGE)
PERL := /usr/bin/perl
BASH := /bin/bash
@@ -40,11 +41,16 @@ QUILT := $(QUILT_IN)
SRC += $(QUILT_SRC:%=quilt/%)
DIRT += $(QUILT_IN:%=quilt/%)
-LIB_IN := apatch rpatch patchfns parse-patch spec2series
-LIB_SRC := $(LIB_IN:%=%.in) backup-files.c
-LIB := $(LIB_IN) backup-files
+SCRIPTS_IN := apatch rpatch patchfns parse-patch spec2series
+SCRIPTS_SRC := $(SCRIPTS_IN:%=%.in)
+SCRIPTS := $(SCRIPTS_IN)
+SRC += $(SCRIPTS_SRC:%=scripts/%)
+DIRT += $(SCRIPTS_IN:%=scripts/%)
+
+LIB_SRC := backup-files.c
+LIB := backup-files
SRC += $(LIB_SRC:%=lib/%)
-DIRT += $(LIB_IN:%=lib/%) lib/backup-files{,.o}
+DIRT += lib/backup-files{,.o}
DOC_IN := README
DOC_SRC := $(DOC_IN:%=doc/%.in)
@@ -62,8 +68,8 @@ SRC += $(DEBIAN:%=debian/%)
all : scripts
-scripts : $(BIN:%=bin/%) $(QUILT:%=quilt/%) $(LIB:%=lib/%) \
- $(DOC:%=doc/%) $(MAN1)
+scripts : $(BIN:%=bin/%) $(QUILT:%=quilt/%) $(SCRIPTS:%=scripts/%) \
+ $(LIB:%=lib/%) $(DOC:%=doc/%) $(MAN1)
dist : $(PACKAGE)-$(VERSION).tar.gz
@@ -80,7 +86,7 @@ reference : $(QUILT:%=quilt/%)
do \
echo "$$i >> README" >&2; \
echo; \
- (bash -c ". lib/patchfns ; . $$i -h"); \
+ (bash -c ". scripts/patchfns ; . $$i -h"); \
done | \
awk '/Usage:/ { sub(/Usage: ?/, "") ; print ; next } '$$'\n'' \
{ printf " %s\n", $$0 }'
@@ -103,12 +109,14 @@ install : all
install -d $(BUILD_ROOT)$(QUILT_DIR)
install -m 755 $(QUILT:%=quilt/%) $(BUILD_ROOT)$(QUILT_DIR)/
+
+ install -d $(BUILD_ROOT)$(SCRIPTS_DIR)
+ install -m 755 $(filter-out scripts/patchfns, $(SCRIPTS:%=scripts/%)) \
+ $(BUILD_ROOT)$(SCRIPTS_DIR)
+ install -m 644 scripts/patchfns $(BUILD_ROOT)$(SCRIPTS_DIR)
install -d $(BUILD_ROOT)$(LIB_DIR)
- install -m 755 $(filter-out lib/patchfns lib/backup-files, \
- $(LIB:%=lib/%)) $(BUILD_ROOT)$(LIB_DIR)/
- install -m 644 lib/patchfns $(BUILD_ROOT)$(LIB_DIR)/
- install -m 755 -s lib/backup-files $(BUILD_ROOT)$(LIB_DIR)/
+ install -m 755 -s $(LIB:%=lib/%) $(BUILD_ROOT)$(LIB_DIR)/
install -d $(BUILD_ROOT)$(docdir)/$(PACKAGE)
install -m 644 doc/README $(BUILD_ROOT)$(docdir)/$(PACKAGE)/
@@ -117,7 +125,7 @@ install : all
install -m 644 $(MAN1) $(BUILD_ROOT)$(mandir)/man1/
$(PACKAGE).spec : $(PACKAGE).spec.in $(PACKAGE).changes Makefile \
- lib/parse-patch
+ scripts/parse-patch
@echo "Generating spec file"
@sed -e 's/^\(Version:[ \t]*\).*/\1$(VERSION)/' \
-e 's/^\(Release:[ \t]\).*/\1$(RELEASE)/' \
@@ -132,7 +140,7 @@ $(PACKAGE).spec : $(PACKAGE).spec.in $(PACKAGE).changes Makefile \
and print \
) or die "Syntax error in line $$. of changelog:\n$$_\n"; \
' $(PACKAGE).changes \
- | lib/parse-patch -u changelog $@
+ | scripts/parse-patch -u changelog $@
clean distclean :
rm -f $(DIRT)
@@ -141,6 +149,7 @@ clean distclean :
@echo "$< -> $@"
@sed -e "s:@LIB@:$(LIB_DIR):g" \
-e "s:@QUILT@:$(QUILT_DIR):g" \
+ -e "s:@SCRIPTS@:$(SCRIPTS_DIR):g" \
-e "s:@PERL@:$(PERL):g" \
-e "s:@BASH@:$(BASH):g" \
-e "s:@DIFF@:$(DIFF):g" \
diff --git a/quilt.changes b/quilt.changes
index 89dde3f..9021f70 100644
--- a/quilt.changes
+++ b/quilt.changes
@@ -2,6 +2,10 @@
Fri Jan 31 13:05:18 CET 2003 - agruen@suse.de
- Add syntax highlighting tags for emacs and vim.
+- Move all scripts from lib/ to scripts/. Install lib/backup-files
+ in /usr/lib/quilt/, and install the scripts in
+ /usr/share/quilt/scripts/, so that no binaries are installed
+ under /usr/share.
-------------------------------------------------------------------
Fri Jan 31 09:15:01 +0100 2003 - Martin.Quinson@ens-lyon.fr
diff --git a/quilt/add.in b/quilt/add.in
index cdecc28..cf15ce6 100644
--- a/quilt/add.in
+++ b/quilt/add.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/quilt/applied.in b/quilt/applied.in
index acba908..806d4bf 100644
--- a/quilt/applied.in
+++ b/quilt/applied.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/quilt/delete.in b/quilt/delete.in
index 806068b..bc2cc2a 100644
--- a/quilt/delete.in
+++ b/quilt/delete.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
@@ -80,7 +80,7 @@ fi
if is_applied $patch
then
if [ "$patch" != "$(top_patch)" ] || \
- ! @LIB@/rpatch -fq "$patch"
+ ! @SCRIPTS@/rpatch -fq "$patch"
then
echo "Patch $patch is currently applied"
exit 1
diff --git a/quilt/diff.in b/quilt/diff.in
index f55e8db..ac6ea9a 100644
--- a/quilt/diff.in
+++ b/quilt/diff.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/quilt/files.in b/quilt/files.in
index 46ee531..9efaac3 100644
--- a/quilt/files.in
+++ b/quilt/files.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/quilt/import.in b/quilt/import.in
index a8532d7..f201a7d 100644
--- a/quilt/import.in
+++ b/quilt/import.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
@@ -160,7 +160,7 @@ then
! grep -q '^%patch$' "$input_file"
then
echo "Updating %patch section of patch $patch"
- if ! @LIB@/parse-patch -u patch $patch_file < "$input_file"
+ if ! @SCRIPTS@/parse-patch -u patch $patch_file < "$input_file"
then
echo "Failed to update %patch section of patch $patch"
exit 1
diff --git a/quilt/new.in b/quilt/new.in
index 16d7c96..316efcb 100644
--- a/quilt/new.in
+++ b/quilt/new.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/quilt/next.in b/quilt/next.in
index 4c979f6..77a746b 100644
--- a/quilt/next.in
+++ b/quilt/next.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/quilt/patches.in b/quilt/patches.in
index 19535d7..e8dda34 100644
--- a/quilt/patches.in
+++ b/quilt/patches.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/quilt/pop.in b/quilt/pop.in
index 9ef7132..4ae716f 100644
--- a/quilt/pop.in
+++ b/quilt/pop.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
@@ -172,7 +172,7 @@ trap "interrupted=1" SIGINT
for patch in $patches
do
- if ! @LIB@/rpatch $rpatch_options $patch
+ if ! @SCRIPTS@/rpatch $rpatch_options $patch
then
exit 1
fi
diff --git a/quilt/previous.in b/quilt/previous.in
index 05323d5..4768220 100644
--- a/quilt/previous.in
+++ b/quilt/previous.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/quilt/push.in b/quilt/push.in
index 8d6a78a..ca91940 100644
--- a/quilt/push.in
+++ b/quilt/push.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
@@ -175,7 +175,7 @@ trap "interrupted=1" SIGINT
for patch in $patches
do
- if ! @LIB@/apatch $apatch_options $patch
+ if ! @SCRIPTS@/apatch $apatch_options $patch
then
exit 1
fi
diff --git a/quilt/refresh.in b/quilt/refresh.in
index de1152a..7357837 100644
--- a/quilt/refresh.in
+++ b/quilt/refresh.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
@@ -171,10 +171,10 @@ then
if [ -x "$DIFFSTAT" ]
then
$DIFFSTAT $tmpfile 2>/dev/null \
- | @LIB@/parse-patch -u diffstat $patch_file
+ | @SCRIPTS@/parse-patch -u diffstat $patch_file
fi
cat $tmpfile \
- | @LIB@/parse-patch -u patch $patch_file
+ | @SCRIPTS@/parse-patch -u patch $patch_file
else
if ! tmpfile2=$(@MKTEMP@ /tmp/patch-scripts.XXXXXX)
then
diff --git a/quilt/remove.in b/quilt/remove.in
index 2ec6a4d..9ecf0d2 100644
--- a/quilt/remove.in
+++ b/quilt/remove.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/quilt/series.in b/quilt/series.in
index dcadbf8..ec4dddb 100644
--- a/quilt/series.in
+++ b/quilt/series.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/quilt/setup.in b/quilt/setup.in
index d663fcd..300c2a5 100644
--- a/quilt/setup.in
+++ b/quilt/setup.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
@@ -86,7 +86,7 @@ case "$1" in
spec_file="$1"
tmpfile=$(@MKTEMP@ /tmp/patch-scripts.XXXXXX)
series_file=$tmpfile
- if ! @LIB@/spec2series "$spec_file" > $tmpfile
+ if ! @SCRIPTS@/spec2series "$spec_file" > $tmpfile
then
exit 1
fi
diff --git a/quilt/top.in b/quilt/top.in
index bdf829f..f87e1ff 100644
--- a/quilt/top.in
+++ b/quilt/top.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/quilt/unapplied.in b/quilt/unapplied.in
index 3decb12..4df3367 100644
--- a/quilt/unapplied.in
+++ b/quilt/unapplied.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/lib/apatch.in b/scripts/apatch.in
index a749b46..d225bde 100755
--- a/lib/apatch.in
+++ b/scripts/apatch.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/lib/parse-patch.in b/scripts/parse-patch.in
index 56c3c55..56c3c55 100755..100644
--- a/lib/parse-patch.in
+++ b/scripts/parse-patch.in
diff --git a/lib/patchfns.in b/scripts/patchfns.in
index e17d164..e17d164 100644
--- a/lib/patchfns.in
+++ b/scripts/patchfns.in
diff --git a/lib/rpatch.in b/scripts/rpatch.in
index 7c69594..afdf230 100755
--- a/lib/rpatch.in
+++ b/scripts/rpatch.in
@@ -9,12 +9,12 @@
# Read in library functions
if [ "$(type -t patch_file_name)" != function ]
then
- if ! [ -r @LIB@/patchfns ]
+ if ! [ -r @SCRIPTS@/patchfns ]
then
- echo "Cannot read library @LIB@/patchfns" >&2
+ echo "Cannot read library @SCRIPTS@/patchfns" >&2
exit 1
fi
- . @LIB@/patchfns
+ . @SCRIPTS@/patchfns
fi
usage()
diff --git a/lib/spec2series.in b/scripts/spec2series.in
index 63aa50b..63aa50b 100755
--- a/lib/spec2series.in
+++ b/scripts/spec2series.in