From 0b91cbfa2da8cecb4c1ab803861aa8529ce545ee Mon Sep 17 00:00:00 2001 From: marcus Date: Sat, 15 Jan 2005 03:47:48 +0000 Subject: Run the mtree command at package install time to fix leftover file warnings on the package build machines. Reported by: GNOME Tinderbox git-svn-id: svn://creme-brulee.marcuscom.com/ports/trunk@3437 df743ca5-7f9a-e211-a948-0013205c9059 --- misc/gnomehier/Makefile | 13 +++++++++++-- misc/gnomehier/files/pkg-install.in | 8 ++++++++ 2 files changed, 19 insertions(+), 2 deletions(-) create mode 100644 misc/gnomehier/files/pkg-install.in (limited to 'misc') diff --git a/misc/gnomehier/Makefile b/misc/gnomehier/Makefile index d8d8cfcea..ce72cb7b5 100644 --- a/misc/gnomehier/Makefile +++ b/misc/gnomehier/Makefile @@ -7,7 +7,7 @@ PORTNAME= gnomehier PORTVERSION= 2.0 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= misc gnome MASTER_SITES= # none DISTFILES= # none @@ -17,11 +17,14 @@ COMMENT= A utility port that creates the GNOME directory tree NO_BUILD= yes PLIST?= ${WRKDIR}/pkg-plist +PKGINSTALL= ${WRKDIR}/pkg-install GNOME_MTREE= BSD.gnome-x11.dist USE_X_PREFIX= yes +GNOME_MTREE_ARGS=${MTREE_ARGS:S|${MTREE_FILE}|${WRKDIR}/${GNOME_MTREE}|} + do-fetch: @${DO_NADA} @@ -38,6 +41,8 @@ pre-install: do \ ${MKDIR} ${WRKSRC}/$${dir}; \ done + @${SED} -e 's|%%MTREE_ARGS%%|${GNOME_MTREE_ARGS}|' \ + < ${FILESDIR}/pkg-install.in > ${PKGINSTALL} pre-su-install: ${CHGRP} games ${WRKSRC}/share/gnome/games @@ -48,8 +53,12 @@ pre-su-install: > ${WRKDIR}/${GNOME_MTREE} do-install: - ${MTREE_CMD} ${MTREE_ARGS:S|${MTREE_FILE}|${WRKDIR}/${GNOME_MTREE}|} ${PREFIX} ${MKDIR} ${PREFIX}/etc/mtree ${INSTALL_DATA} ${WRKDIR}/${GNOME_MTREE} ${PREFIX}/etc/mtree +post-install: +.if !defined(PACKAGE_BUILDING) + @${SETENV} PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL +.endif + .include diff --git a/misc/gnomehier/files/pkg-install.in b/misc/gnomehier/files/pkg-install.in new file mode 100644 index 000000000..20e30328e --- /dev/null +++ b/misc/gnomehier/files/pkg-install.in @@ -0,0 +1,8 @@ +#!/bin/sh + +case $2 in +POST-INSTALL) + /usr/sbin/mtree %%MTREE_ARGS%% ${PKG_PREFIX} + exit 0 + ;; +esac -- cgit v1.2.3