diff options
author | drochner <drochner@pkgsrc.org> | 2004-03-02 15:25:23 +0000 |
---|---|---|
committer | drochner <drochner@pkgsrc.org> | 2004-03-02 15:25:23 +0000 |
commit | 630848934b5c3b703d92f590ba1969e4cb351567 (patch) | |
tree | 8642663e121d1834f83913934fb3e6bf8723d071 /mk/bsd.pkg.mk | |
parent | 0bf07f955ca07daf705945ef5b471f9eebdc53ca (diff) | |
download | pkgsrc-630848934b5c3b703d92f590ba1969e4cb351567.tar.gz |
extend REPLACE_INTERPRETER to accept shell wildcards
Diffstat (limited to 'mk/bsd.pkg.mk')
-rw-r--r-- | mk/bsd.pkg.mk | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk index f17edd761b8..de6593801b5 100644 --- a/mk/bsd.pkg.mk +++ b/mk/bsd.pkg.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.pkg.mk,v 1.1414 2004/02/28 07:12:21 jdolecek Exp $ +# $NetBSD: bsd.pkg.mk,v 1.1415 2004/03/02 15:25:23 drochner Exp $ # # This file is in the public domain. # @@ -2330,11 +2330,12 @@ _CONFIGURE_PREREQ+= replace-interpreter .PHONY: replace-interpreter replace-interpreter: . for lang in ${REPLACE_INTERPRETER} +. for pattern in ${_REPLACE_FILES.${lang}} ${_PKG_SILENT}${_PKG_DEBUG} \ cd ${WRKSRC}; \ - for f in ${_REPLACE_FILES.${lang}}; do \ + for f in ${pattern}; do \ if [ -f $${f} ]; then \ - ${SED} -e 's|#!${_REPLACE.${lang}.old}|#!${_REPLACE.${lang}.new}|' \ + ${SED} -e '1s|^#!${_REPLACE.${lang}.old}|#!${_REPLACE.${lang}.new}|' \ $${f} > $${f}.new; \ if [ -x $${f} ]; then \ ${CHMOD} a+x $${f}.new; \ @@ -2342,6 +2343,7 @@ replace-interpreter: ${MV} -f $${f}.new $${f}; \ fi; \ done +. endfor . endfor .endif |