pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/pkgtools/pkg_rolling-replace Prepend ${PREFIX} to defa...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/84cac34b0e63
branches:  trunk
changeset: 528639:84cac34b0e63
user:      tnn <tnn%pkgsrc.org@localhost>
date:      Fri May 11 16:48:55 2007 +0000

description:
Prepend ${PREFIX} to default location of mk.conf if we're using bmake.

diffstat:

 pkgtools/pkg_rolling-replace/Makefile                     |  10 ++++++++--
 pkgtools/pkg_rolling-replace/files/pkg_rolling-replace.8  |   9 +++++----
 pkgtools/pkg_rolling-replace/files/pkg_rolling-replace.sh |   9 ++++-----
 3 files changed, 17 insertions(+), 11 deletions(-)

diffs (76 lines):

diff -r c7b15e11d4da -r 84cac34b0e63 pkgtools/pkg_rolling-replace/Makefile
--- a/pkgtools/pkg_rolling-replace/Makefile     Fri May 11 16:28:11 2007 +0000
+++ b/pkgtools/pkg_rolling-replace/Makefile     Fri May 11 16:48:55 2007 +0000
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.5 2007/05/10 02:55:31 tnn Exp $
+# $NetBSD: Makefile,v 1.6 2007/05/11 16:48:55 tnn Exp $
 
 DISTNAME=      pkg_rolling-replace-0.04
-PKGREVISION=   4
+PKGREVISION=   5
 CATEGORIES=    pkgtools
 MASTER_SITES=  # empty
 DISTFILES=     # empty
@@ -29,6 +29,12 @@
 SUBST_FILES.makepath=  pkg_rolling-replace.sh
 SUBST_SED.makepath=    -e 's,@MAKE@,${MAKE},g'
 
+SUBST_CLASSES+=                makeconf
+SUBST_STAGE.makeconf=  pre-configure
+SUBST_MESSAGE.makeconf=        Recording default path of mk.conf.
+SUBST_FILES.makeconf=  pkg_rolling-replace.sh
+SUBST_SED.makeconf=    -e 's,@MAKECONF@,${MAKE:T:Mbmake:S/bmake/${PREFIX}/g}/etc/mk.conf,g'
+
 .include "../../mk/bsd.prefs.mk"
 
 # target exists only to force check-pkgsrc-patch prior to install
diff -r c7b15e11d4da -r 84cac34b0e63 pkgtools/pkg_rolling-replace/files/pkg_rolling-replace.8
--- a/pkgtools/pkg_rolling-replace/files/pkg_rolling-replace.8  Fri May 11 16:28:11 2007 +0000
+++ b/pkgtools/pkg_rolling-replace/files/pkg_rolling-replace.8  Fri May 11 16:48:55 2007 +0000
@@ -1,5 +1,5 @@
-.\" $NetBSD: pkg_rolling-replace.8,v 1.4 2007/05/10 03:02:20 tnn Exp $
-.Dd May 10, 2007
+.\" $NetBSD: pkg_rolling-replace.8,v 1.5 2007/05/11 16:48:55 tnn Exp $
+.Dd May 11, 2007
 .Dt PKG_ROLLING-REPLACE 8
 .Os
 .Sh NAME
@@ -91,8 +91,9 @@
 .Pa mk.conf .
 Defaults to
 .Pa /etc/mk.conf
-with a fallback to
-.Pa /usr/pkgsrc/etc/mk.conf .
+or
+.Pa ${PREFIX}/etc/mk.conf 
+(if using bmake).
 .It Ev PKGSRCDIR
 Base of pkgsrc tree.
 Defaults to value configured in MAKECONF or
diff -r c7b15e11d4da -r 84cac34b0e63 pkgtools/pkg_rolling-replace/files/pkg_rolling-replace.sh
--- a/pkgtools/pkg_rolling-replace/files/pkg_rolling-replace.sh Fri May 11 16:28:11 2007 +0000
+++ b/pkgtools/pkg_rolling-replace/files/pkg_rolling-replace.sh Fri May 11 16:48:55 2007 +0000
@@ -1,6 +1,6 @@
 #!/bin/sh
 
-# $NetBSD: pkg_rolling-replace.sh,v 1.3 2007/05/10 02:55:31 tnn Exp $
+# $NetBSD: pkg_rolling-replace.sh,v 1.4 2007/05/11 16:48:55 tnn Exp $
 #<license>
 # Copyright (c) 2006 BBN Technologies Corp.  All rights reserved.
 #
@@ -62,12 +62,11 @@
 #
 
 # Substituted by pkgsrc at pre-configure time.
-MAKE=@MAKE@
+MAKE="@MAKE@"
 
 test -z "$PKG_DBDIR" && PKG_DBDIR=/var/db/pkg
-test -z "$MAKECONF" && M=/etc/mk.conf && test -f $M && MAKECONF=$M
-test -z "$MAKECONF" && M=/usr/pkg/etc/mk.conf && test -f $M && MAKECONF=$M
-test -z "$PKGSRCDIR" && test -f "$MAKECONF" && \
+test -z "$MAKECONF" && MAKECONF="@MAKECONF@"
+test -f "$MAKECONF" && test -z "$PKGSRCDIR" && \
     PKGSRCDIR="`$MAKE -f \"$MAKECONF\" BSD_PKG_MK=1 -V PKGSRCDIR`"
 test -z "$PKGSRCDIR" && PKGSRCDIR=/usr/pkgsrc
 



Home | Main Index | Thread Index | Old Index