summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorrillig <rillig>2006-03-09 15:58:10 +0000
committerrillig <rillig>2006-03-09 15:58:10 +0000
commit330bd637a9559c16bdd62c741d6f094e4c8dbef9 (patch)
tree431f88eaef8b52c8bcb081dcce9e37ff49392753 /mk
parent0051869fb599604971de0b0a0547901d97def97a (diff)
downloadpkgsrc-330bd637a9559c16bdd62c741d6f094e4c8dbef9.tar.gz
Since the REPLACE_INTERPRETER is used in more and more packages, it is
not good style to make the package author define variables from the pkgsrc-internal namespace. The variables REPLACE.* and REPLACE_FILES.* can now be used as replacements for _REPLACE.* and _REPLACE_FILES.*. Support for the old variable names will be removed after 2006Q2.
Diffstat (limited to 'mk')
-rw-r--r--mk/bsd.pkg.mk18
1 files changed, 14 insertions, 4 deletions
diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk
index 2575ce8c719..798faea29aa 100644
--- a/mk/bsd.pkg.mk
+++ b/mk/bsd.pkg.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.pkg.mk,v 1.1802 2006/03/09 00:20:27 jlam Exp $
+# $NetBSD: bsd.pkg.mk,v 1.1803 2006/03/09 15:58:10 rillig Exp $
#
# This file is in the public domain.
#
@@ -1506,12 +1506,22 @@ SUBST_SED.pkglocaledir= \
.if defined(REPLACE_PERL)
REPLACE_INTERPRETER+= perl
-_REPLACE.perl.old= .*/bin/perl
-_REPLACE.perl.new= ${PERL5}
-_REPLACE_FILES.perl= ${REPLACE_PERL}
+REPLACE.perl.old= .*/bin/perl
+REPLACE.perl.new= ${PERL5}
+REPLACE_FILES.perl= ${REPLACE_PERL}
.endif
.if defined(REPLACE_INTERPRETER)
+
+# After 2006Q2, all instances of _REPLACE.* and _REPLACE_FILES.* should
+# have been replaced with REPLACE.* and REPLACE_FILES.*. This code is
+# then no longer needed.
+. for _lang_ in ${REPLACE_INTERPRETER}
+REPLACE.${_lang_}.old?= ${_REPLACE.${_lang_}.old}
+REPLACE.${_lang_}.new?= ${_REPLACE.${_lang_}.new}
+REPLACE_FILES.${_lang_}?= ${_REPLACE_FILES.${_lang_}}
+. endfor
+
_CONFIGURE_PREREQ+= replace-interpreter
.PHONY: replace-interpreter
replace-interpreter: