aboutsummaryrefslogtreecommitdiff
path: root/shells
diff options
context:
space:
mode:
authorDavid E. O'Brien <obrien@FreeBSD.org>2007-06-28 23:33:44 +0000
committerDavid E. O'Brien <obrien@FreeBSD.org>2007-06-28 23:33:44 +0000
commitcacc031ebcd27d12b515be6a1a965904b3932ae2 (patch)
tree93034671b7915593611ab39a7df0c4c0bf92ea53 /shells
parentabe6aac47f38c0a7e53c8bdbfcf00e7780ab0237 (diff)
downloadports-cacc031ebcd27d12b515be6a1a965904b3932ae2.tar.gz
ports-cacc031ebcd27d12b515be6a1a965904b3932ae2.zip
Support PREFIX=/
PR: 95566 Submitted by: Andrew McNaughton <andrew@scoop.co.nz>
Notes
Notes: svn path=/head/; revision=194422
Diffstat (limited to 'shells')
-rw-r--r--shells/bash/pkg-deinstall4
-rw-r--r--shells/bash/pkg-install4
2 files changed, 4 insertions, 4 deletions
diff --git a/shells/bash/pkg-deinstall b/shells/bash/pkg-deinstall
index 6f49f2c3ca3b..3e19db4b1637 100644
--- a/shells/bash/pkg-deinstall
+++ b/shells/bash/pkg-deinstall
@@ -12,7 +12,7 @@ DEINSTALL)
if grep -qs "^$BASH\$" "$SHELLS"; then
if [ `id -u` -eq 0 ]; then
TMPSHELLS=`mktemp -t shells`
- grep -v "^$BASH\$" "$SHELLS" > "$TMPSHELLS"
+ grep -v "^$(echo "$BASH" | /usr/bin/sed -e 's|//|/|g')\$" "$SHELLS" > "$TMPSHELLS"
cat "$TMPSHELLS" > "$SHELLS"
rm "$TMPSHELLS"
else
@@ -22,7 +22,7 @@ DEINSTALL)
if grep -qs "^$RBASH\$" "$SHELLS"; then
if [ `id -u` -eq 0 ]; then
TMPSHELLS=`mktemp -t shells`
- grep -v "^$RBASH\$" "$SHELLS" > "$TMPSHELLS"
+ grep -v "^$(echo "$RBASH" | /usr/bin/sed -e 's|//|/|g')\$" "$SHELLS" > "$TMPSHELLS"
cat "$TMPSHELLS" > "$SHELLS"
rm "$TMPSHELLS"
else
diff --git a/shells/bash/pkg-install b/shells/bash/pkg-install
index c42db4871432..8aa663d21621 100644
--- a/shells/bash/pkg-install
+++ b/shells/bash/pkg-install
@@ -11,14 +11,14 @@ case $2 in
POST-INSTALL)
if [ -d "${SHELLS%/*}" ] && ! grep -qs "^$BASH\$" "$SHELLS"; then
if [ `id -u` -eq 0 ]; then
- echo "$BASH" >> "$SHELLS"
+ echo "$BASH" | /usr/bin/sed -e 's|//|/|g' >> "$SHELLS"
else
echo "Not root, please add $BASH to $SHELLS manually"
fi
fi
if [ -d "${SHELLS%/*}" ] && ! grep -qs "^$RBASH\$" "$SHELLS"; then
if [ `id -u` -eq 0 ]; then
- echo "$RBASH" >> "$SHELLS"
+ echo "$RBASH" | /usr/bin/sed -e 's|//|/|g' >> "$SHELLS"
else
echo "Not root, please add $RBASH to $SHELLS manually"
fi