DESTDIR support

This commit is contained in:
joerg 2010-07-07 00:29:32 +00:00
parent 224ea05ab3
commit 96dfd05cea
5 changed files with 54 additions and 18 deletions

View file

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.13 2010/07/06 10:17:16 jmmv Exp $
# $NetBSD: Makefile,v 1.14 2010/07/07 00:29:32 joerg Exp $
#
DISTNAME= xml2doc-20030510
@ -11,6 +11,8 @@ MAINTAINER= pkgsrc-users@NetBSD.org
HOMEPAGE= http://xml2doc.sourceforge.net/
COMMENT= Xml to document formats converter
PKG_DESTDIR_SUPPORT= user-destdir
WRKSRC= ${WRKDIR}/xml2doc
USE_PKGLOCALEDIR= yes
GNU_CONFIGURE= yes

View file

@ -1,7 +1,8 @@
$NetBSD: distinfo,v 1.3 2005/02/24 14:48:50 agc Exp $
$NetBSD: distinfo,v 1.4 2010/07/07 00:29:32 joerg Exp $
SHA1 (xml2doc-20030510.tgz) = 2453ff5437c40974f8804fe5907e483792ae6d2a
RMD160 (xml2doc-20030510.tgz) = d2f7d13ace6dc0a68a3ca4aec993ca78b18930e6
Size (xml2doc-20030510.tgz) = 53307 bytes
SHA1 (patch-aa) = 72daac7f1af2278957f00622bafd44657ed1fea8
SHA1 (patch-ab) = 714a95e6d7dc9ccf6c690904dcfdcd85ada0e5d7
SHA1 (patch-aa) = ca63abf9c7decaec9eb4dcf0afc448378f217060
SHA1 (patch-ab) = 880e18a8aada22160ae069986ef5f98e8fdea6a2
SHA1 (patch-ac) = 1b387078c52f17bc2a82a0b43bb3352dcba968fb

View file

@ -1,27 +1,34 @@
$NetBSD: patch-aa,v 1.1.1.1 2004/02/23 08:39:00 xtraeme Exp $
$NetBSD: patch-aa,v 1.2 2010/07/07 00:29:32 joerg Exp $
--- doc/Makefile.in.orig 2004-02-23 09:26:44.000000000 +0100
+++ doc/Makefile.in 2004-02-23 09:31:00.000000000 +0100
@@ -9,7 +9,6 @@
export PATH=$(PATH):$(PWD)/src/ ;
for A in *.xml; do xml2doc -oP $$A $$A.pdf ; done ;
xml2doc -oM manpage.xml manpage.man ;
--- doc/Makefile.in.orig 2003-05-10 14:44:26.000000000 +0000
+++ doc/Makefile.in
@@ -6,10 +6,8 @@ all:
build:
@printf "\e[32mBuilding documentation...\e[0m\n"
- export PATH=$(PATH):$(PWD)/src/ ;
- for A in *.xml; do xml2doc -oP $$A $$A.pdf ; done ;
- xml2doc -oM manpage.xml manpage.man ;
- gzip manpage.man ;
+ for A in *.xml; do ../src/xml2doc -oP $$A $$A.pdf ; done ;
+ ../src/xml2doc -oM manpage.xml manpage.man;
@printf "\e[32mDONE\e[0m\n"
mrproper: clean
@@ -21,10 +20,10 @@
@@ -20,11 +18,11 @@ clean:
install: build
@printf "\e[32mInstalling documentation...\e[0m\n"
@mkdir -p $(PREFIX)/share/man/man1
- @mkdir -p $(PREFIX)/share/man/man1
- cp -f manpage.man.gz $(PREFIX)/share/man/man1/xml2doc.1.gz
- gzip -f $(PREFIX)/share/man/man1/xml2doc.1
- @mkdir -p $(PREFIX)/share/doc/xml2doc
- for A in $(DOCS); do cp -f $$A $(PREFIX)/share/doc/xml2doc/ ;done
+ $(BSD_INSTALL_MAN) manpage.man $(PREFIX)/man/man1/xml2doc.1
+ @$(BSD_INSTALL_DATA_DIR) $(PREFIX)/share/doc/xml2doc
+ @mkdir -p ${DESTDIR}$(PREFIX)/${PKGMANDIR}/man1
+ $(BSD_INSTALL_MAN) manpage.man ${DESTDIR}$(PREFIX)/${PKGMANDIR}/man1/xml2doc.1
+ @$(BSD_INSTALL_DATA_DIR) ${DESTDIR}$(PREFIX)/share/doc/xml2doc
+ for A in $(DOCS); do $(BSD_INSTALL_DATA) $$A \
+ $(PREFIX)/share/doc/xml2doc/ ;done
+ ${DESTDIR}$(PREFIX)/share/doc/xml2doc/ ;done
remove:
@printf "\e[32mDeinstalling documentation...\e[0m\n"

View file

@ -1,6 +1,6 @@
$NetBSD: patch-ab,v 1.1 2004/09/10 08:40:51 jmmv Exp $
$NetBSD: patch-ab,v 1.2 2010/07/07 00:29:32 joerg Exp $
--- src/Makefile.in.orig 2003-05-03 03:37:38.000000000 +0200
--- src/Makefile.in.orig 2003-05-03 01:37:38.000000000 +0000
+++ src/Makefile.in
@@ -11,13 +11,9 @@ PREFIX=@PREFIX@
@ -19,3 +19,14 @@ $NetBSD: patch-ab,v 1.1 2004/09/10 08:40:51 jmmv Exp $
BIN=xml2doc
all:
@@ -25,8 +21,8 @@ all:
install: build
@printf "\e[32mInstalling binaries...\e[0m\n"
- mkdir -p $(PREFIX)/bin
- install -m 0755 ./$(BIN) $(PREFIX)/bin/$(BIN)
+ mkdir -p ${DESTDIR}$(PREFIX)/bin
+ install -m 0755 ./$(BIN) ${DESTDIR}$(PREFIX)/bin/$(BIN)
remove:
@printf "\e[32mDeinstalling binaries...\e[0m\n"

View file

@ -0,0 +1,15 @@
$NetBSD: patch-ac,v 1.1 2010/07/07 00:29:32 joerg Exp $
--- examples/Makefile.in.orig 2010-07-07 00:27:14.000000000 +0000
+++ examples/Makefile.in
@@ -15,8 +15,8 @@ clean:
install:
@printf "\e[32mInstalling examples...\e[0m\n"
- mkdir -p $(PREFIX)/share/doc/xml2doc/examples
- cp -f *.xml $(PREFIX)/share/doc/xml2doc/examples
+ mkdir -p ${DESTDIR}$(PREFIX)/share/doc/xml2doc/examples
+ cp -f *.xml ${DESTDIR}$(PREFIX)/share/doc/xml2doc/examples
remove:
@printf "\e[32mDeinstalling examples...\e[0m\n"