diff options
author | Andreas Gruenbacher <agruen@suse.de> | 2003-01-31 12:45:37 +0000 |
---|---|---|
committer | Andreas Gruenbacher <agruen@suse.de> | 2003-01-31 12:45:37 +0000 |
commit | 21a15e55a81ea4bd2bc21729ceebe6be6a9ccd9b (patch) | |
tree | 150f25f9add7ecb5ae144ab63a62c3b43d25f378 /Makefile | |
parent | f07f43d191fe23209876061b7a31b5cb1e9a219d (diff) | |
download | quilt-21a15e55a81ea4bd2bc21729ceebe6be6a9ccd9b.tar.gz |
Install binary backup-files into /usr/lib/quilt and the remaining scripts under /usr/share/quilt/scripts.
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 37 |
1 files changed, 23 insertions, 14 deletions
@@ -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" \ |