diff options
author | jlam <jlam@pkgsrc.org> | 2004-10-07 13:42:26 +0000 |
---|---|---|
committer | jlam <jlam@pkgsrc.org> | 2004-10-07 13:42:26 +0000 |
commit | b74c7e347308f54bf7768c4b08eeb9d6df44cd22 (patch) | |
tree | d43e3a64512e962519f785c23f06d5e10a00822c /mk/bsd.prefs.mk | |
parent | 1819c05e8da584b8d58ef76bf7e7fda3b4211edc (diff) | |
download | pkgsrc-b74c7e347308f54bf7768c4b08eeb9d6df44cd22.tar.gz |
Make PKGSRCDIR a read-only value. This avoids problems where the user
decides to set PKGSRCDIR to a relative path as seen in several old PRs
and which prompted the original switch to make PKGSRCDIR private in
revision 1.881 of bsd.pkg.mk.
Diffstat (limited to 'mk/bsd.prefs.mk')
-rw-r--r-- | mk/bsd.prefs.mk | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/mk/bsd.prefs.mk b/mk/bsd.prefs.mk index 16ff0fa956d..32eecf1fa78 100644 --- a/mk/bsd.prefs.mk +++ b/mk/bsd.prefs.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.prefs.mk,v 1.172 2004/10/07 03:03:09 jlam Exp $ +# $NetBSD: bsd.prefs.mk,v 1.173 2004/10/07 13:42:26 jlam Exp $ # # Make file, included to get the site preferences, if any. Should # only be included by package Makefiles before any .if defined() @@ -464,10 +464,11 @@ PKG_FAIL_REASON+= 'for more details.' .endif PKGPATH?= ${.CURDIR:C|.*/([^/]*/[^/]*)$|\1|} -.if !defined(PKGSRCDIR) -PKGSRCDIR!= cd ${_PKGSRC_TOPDIR} && ${PWD_CMD} -MAKEFLAGS+= PKGSRCDIR=${PKGSRCDIR:Q} +.if !defined(_PKGSRCDIR) +_PKGSRCDIR!= cd ${_PKGSRC_TOPDIR} && ${PWD_CMD} +MAKEFLAGS+= _PKGSRCDIR=${_PKGSRCDIR:Q} .endif +PKGSRCDIR= ${_PKGSRCDIR} DISTDIR?= ${PKGSRCDIR}/distfiles PACKAGES?= ${PKGSRCDIR}/packages |