summaryrefslogtreecommitdiff
path: root/lang
diff options
context:
space:
mode:
authorminskim <minskim@pkgsrc.org>2008-09-21 21:50:31 +0000
committerminskim <minskim@pkgsrc.org>2008-09-21 21:50:31 +0000
commitfde893af5acd55d9a5518d9828e8282ba3843502 (patch)
treeb27290fb21b66e60925938ae75ab446166622232 /lang
parentb98f253a9ed5f7e097302d27e35e39fa4894b7c8 (diff)
downloadpkgsrc-fde893af5acd55d9a5518d9828e8282ba3843502.tar.gz
Make sure the shebang line replacement for Ruby alters only a shebang line.
Previously, it altered lines that did not start with "#!". This, with the recent change in misc/rubygems/rubygems 1.39, broke www/rails.
Diffstat (limited to 'lang')
-rw-r--r--lang/ruby/replace.mk6
1 files changed, 3 insertions, 3 deletions
diff --git a/lang/ruby/replace.mk b/lang/ruby/replace.mk
index 94889c40bbe..22960759db4 100644
--- a/lang/ruby/replace.mk
+++ b/lang/ruby/replace.mk
@@ -1,4 +1,4 @@
-# $NetBSD: replace.mk,v 1.10 2008/09/15 08:40:55 taca Exp $
+# $NetBSD: replace.mk,v 1.11 2008/09/21 21:50:31 minskim Exp $
#
.if !defined(_RUBY_REPLACE_MK)
@@ -46,8 +46,8 @@ replace-ruby-dirs:
${FIND} $$dirs \
-type f ${_REPLACE_RUBY_FIND_ARGS} -print | \
while read f; do \
- ${SED} -e '1s| *[a-z0-9_/\.-][a-z0-9_/\.-]*/env *||g' \
- -e '1s| *[a-z0-9_/\.-]*ruby|${RUBY}|' $$f > $$f.tmp; \
+ ${SED} -e '1s|^#! *[a-z0-9_/\.-][a-z0-9_/\.-]*/env *|#!|g' \
+ -e '1s|^#! *[a-z0-9_/\.-]*ruby|#!${RUBY}|' $$f > $$f.tmp; \
if ${CMP} -s $$f $$f.tmp; then \
${RM} $$f.tmp; \
else \