summaryrefslogtreecommitdiff
path: root/Makefile.SH
diff options
context:
space:
mode:
authorEric Brine <ikegami@adaelis.com>2013-04-18 20:57:54 -0700
committerRicardo Signes <rjbs@cpan.org>2013-04-23 10:15:20 -0400
commit6bc4329f7ec30de04fc201cb3990673e81becde3 (patch)
treea34a4fdda187e40bd8890df80f5258a83d45edbd /Makefile.SH
parent4a6672dc1c5bd3aa60e465bc6fdf74927620f064 (diff)
downloadperl-6bc4329f7ec30de04fc201cb3990673e81becde3.tar.gz
Avoid use of $(...) as backticks in SH code
Avoid use of $(...) as backticks in SH code as it is not supported by all /bin/sh. RT#115708.
Diffstat (limited to 'Makefile.SH')
-rwxr-xr-xMakefile.SH11
1 files changed, 6 insertions, 5 deletions
diff --git a/Makefile.SH b/Makefile.SH
index 93c7385b09..171eb2af90 100755
--- a/Makefile.SH
+++ b/Makefile.SH
@@ -1,7 +1,7 @@
#!/bin/sh
# quote() - Creates a shell literal
-# Usage: echo "...$( quote "..." )..."
+# Usage: echo "...` quote "..." `..."
quote() {
case "$1" in
'') echo "''" ;;
@@ -37,6 +37,7 @@ case "$0" in
*/*) cd `expr X$0 : 'X\(.*\)/'` ;;
esac
+pwd="`pwd`"
linklibperl='$(LIBPERL)'
linklibperl_nonshr=''
shrpldflags='$(LDDLFLAGS)'
@@ -48,8 +49,8 @@ true)
# Prefix all runs of 'miniperl' and 'perl' with
# $ldlibpth so that ./perl finds *this* shared libperl.
case "$LD_LIBRARY_PATH" in
- '') ldlibpth="LD_LIBRARY_PATH=$( quote "`pwd`" )" ;;
- *) ldlibpth="LD_LIBRARY_PATH=$( quote "`pwd`" ):$( quote "$LD_LIBRARY_PATH" )" ;;
+ '') ldlibpth="LD_LIBRARY_PATH=` quote "$pwd" `" ;;
+ *) ldlibpth="LD_LIBRARY_PATH=` quote "$pwd" `:` quote "$LD_LIBRARY_PATH" `" ;;
esac
pldlflags="$cccdlflags"
@@ -131,8 +132,8 @@ true)
eval "ldlibpthval=\"\$$ldlibpthname\""
case "$ldlibpthval" in
- '') ldlibpth="$ldlibpthname=$( quote "`pwd`" )" ;;
- *) ldlibpth="$ldlibpthname=$( quote "`pwd`" ):$( quote "$ldlibpthval" )" ;;
+ '') ldlibpth="$ldlibpthname=` quote "$pwd" `" ;;
+ *) ldlibpth="$ldlibpthname=` quote "$pwd" `:` quote "$ldlibpthval" `" ;;
esac
;;