pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc/mk Since the REPLACE_INTERPRETER is used in more and m...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/1182545ea217
branches:  trunk
changeset: 509385:1182545ea217
user:      rillig <rillig%pkgsrc.org@localhost>
date:      Thu Mar 09 15:58:10 2006 +0000

description:
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:

 mk/bsd.pkg.mk |  18 ++++++++++++++----
 1 files changed, 14 insertions(+), 4 deletions(-)

diffs (35 lines):

diff -r 23a6f4977925 -r 1182545ea217 mk/bsd.pkg.mk
--- a/mk/bsd.pkg.mk     Thu Mar 09 15:43:46 2006 +0000
+++ b/mk/bsd.pkg.mk     Thu Mar 09 15:58:10 2006 +0000
@@ -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 @@
 
 .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:



Home | Main Index | Thread Index | Old Index