summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2001-11-30 03:48:14 +0000
committerjlam <jlam@pkgsrc.org>2001-11-30 03:48:14 +0000
commitb7c7ffb871a11027de76729695ef7e79d9b17caa (patch)
tree42fe223d3ab41fd22946504de7f43b53ca9502be /mk
parentb3f21f3c6862227ca7a26e68e5d195ecbace78fc (diff)
downloadpkgsrc-b7c7ffb871a11027de76729695ef7e79d9b17caa.tar.gz
Move the REPLACE_PERL code into a separate configure pre-requisite target
"replace-perl", instead of keeping it as part of the do-patch target. Now, a "make patch" will result in just the patched sources.
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)