aboutsummaryrefslogtreecommitdiff
path: root/Mk/Uses/shebangfix.mk
diff options
context:
space:
mode:
authorMark Felder <feld@FreeBSD.org>2017-08-08 01:10:57 +0000
committerMark Felder <feld@FreeBSD.org>2017-08-08 01:10:57 +0000
commit45e556ab892f8996c0ed4ec68cab55384f69e954 (patch)
treef5df69ff81995c40a5dc2203184c3df4e471cb9f /Mk/Uses/shebangfix.mk
parenta10a4258a7cbe73d0de9c5cce40914f743190db0 (diff)
downloadports-45e556ab892f8996c0ed4ec68cab55384f69e954.tar.gz
ports-45e556ab892f8996c0ed4ec68cab55384f69e954.zip
Mk/Uses/shebangfix.mk: Fix SHEBANG_FILES to use find(1)
Ports like net/vmware-vsphere-cli use SHEBANG_FILES with globs like so: SHEBANG_FILES= bin/* ... As of FreeBSD 11.1-RELEASE sed has changed and errors if attempted on non-file objects. In the case of the cited port there are many other files in the bin/ directory which are symlinks for compatibility with old scripts. This causes the port patching to fail. PR: 221229 Differential Revision: https://reviews.freebsd.org/D11853
Notes
Notes: svn path=/head/; revision=447527
Diffstat (limited to 'Mk/Uses/shebangfix.mk')
-rw-r--r--Mk/Uses/shebangfix.mk3
1 files changed, 2 insertions, 1 deletions
diff --git a/Mk/Uses/shebangfix.mk b/Mk/Uses/shebangfix.mk
index c2543e72af90..5cf726ee499e 100644
--- a/Mk/Uses/shebangfix.mk
+++ b/Mk/Uses/shebangfix.mk
@@ -94,7 +94,8 @@ fix-shebang:
.endif
.if defined(SHEBANG_FILES)
@cd ${WRKSRC}; \
- ${ECHO_CMD} ${SHEBANG_FILES} | ${XARGS} ${SED} -i '' ${_SHEBANG_REINPLACE_ARGS}
+ ${FIND} ${SHEBANG_FILES} -type f \
+ -exec ${SED} -i '' ${_SHEBANG_REINPLACE_ARGS} {} +
.endif
.endif