summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
Diffstat (limited to 'mk')
-rw-r--r--mk/bsd.pkg.mk24
1 files changed, 15 insertions, 9 deletions
diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk
index e529fef19fc..dc3aaff2ac9 100644
--- a/mk/bsd.pkg.mk
+++ b/mk/bsd.pkg.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.pkg.mk,v 1.869 2001/11/30 03:19:04 jlam Exp $
+# $NetBSD: bsd.pkg.mk,v 1.870 2001/11/30 03:48:14 jlam Exp $
#
# This file is in the public domain.
#
@@ -1507,23 +1507,29 @@ do-patch: uptodate-digest
fi; \
fi; \
fi
+.endif
+
+# Configure
-. if defined(REPLACE_PERL)
-. for f in ${REPLACE_PERL}
- ${_PKG_SILENT}${_PKG_DEBUG}cd ${WRKSRC}; if [ -f ${f} ]; then \
+_CONFIGURE_PREREQ+= replace-perl
+replace-perl:
+.if defined(REPLACE_PERL)
+. for f in ${REPLACE_PERL}
+ ${_PKG_SILENT}${_PKG_DEBUG} \
+ cd ${WRKSRC}; \
+ if [ -f ${f} ]; then \
${SED} "s,#!.*/bin/perl,#!${PERL5}," \
- ${f} > ${f}.new; \
+ ${f} > ${f}.new; \
if [ -x ${f} ]; then \
${CHMOD} a+x ${f}.new; \
fi; \
${MV} -f ${f}.new ${f}; \
fi
-. endfor
-. endif
+. endfor
+.else
+ ${_PKG_SILENT}${_PKG_DEBUG}${TRUE}
.endif
-# Configure
-
_CONFIGURE_PREREQ+= do-ltconfig-override
do-ltconfig-override:
.if defined(USE_LIBTOOL) && defined(LTCONFIG_OVERRIDE)