summaryrefslogtreecommitdiff
path: root/m4/xcode_version.m4
diff options
context:
space:
mode:
authorViktor Dukhovni <ietf-dane@dukhovni.org>2021-11-30 17:46:10 -0500
committerMarge Bot <ben+marge-bot@smart-cactus.org>2021-12-01 03:13:34 -0500
commitd3c7f9be47ac99637ac0ede0759f77da320afaad (patch)
tree9de585d534ef2643106b37657c036d94ffd95ec1 /m4/xcode_version.m4
parentf124f2a0ca3ba2b80839d8f107763ffe3b48b6e0 (diff)
downloadhaskell-d3c7f9be47ac99637ac0ede0759f77da320afaad.tar.gz
Use POSIX shell syntax to redirect stdout/err
FreeBSD (and likely NetBSD) /bin/sh does not support '>& word' to redirect stdout + stderr. (Also the preferred syntax in bash would be '&> word' to avoid surprises when `word` is "-" or a number). Resolves: #20760
Diffstat (limited to 'm4/xcode_version.m4')
-rw-r--r--m4/xcode_version.m42
1 files changed, 1 insertions, 1 deletions
diff --git a/m4/xcode_version.m4 b/m4/xcode_version.m4
index e59604d6b8..af2916eb1d 100644
--- a/m4/xcode_version.m4
+++ b/m4/xcode_version.m4
@@ -5,7 +5,7 @@ AC_DEFUN([XCODE_VERSION],[
if test "$TargetVendor_CPP" = "apple"
then
AC_MSG_CHECKING(Xcode version)
- XcodeVersion=`(xcode-select -p >& /dev/null && xcodebuild -version) | grep Xcode | sed "s/Xcode //"`
+ XcodeVersion=`(xcode-select -p > /dev/null 2>&1 && xcodebuild -version) | grep Xcode | sed "s/Xcode //"`
# Old Xcode versions don't actually give the Xcode version
if test "$XcodeVersion" = ""
then