summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSolomon Peachy <pizza@shaftnet.org>2024-05-08 22:34:59 -0400
committerSolomon Peachy <pizza@shaftnet.org>2024-05-08 22:40:18 -0400
commit54389dcf2f7c0f5f53bb1bfdb4cffde05d002ea2 (patch)
treed408189c851be6f175585dd81f0474509917dafe
parente37cd0f2f59d04b7e18bc4a425c367f92523b1cd (diff)
downloadrockbox-54389dcf2f.tar.gz
rockbox-54389dcf2f.zip
configure: fix test for LD version on non-macos systems
Change-Id: I6296a013def3e55b44cbba781f3a397a94d2c561
-rwxr-xr-xtools/configure11
1 files changed, 5 insertions, 6 deletions
diff --git a/tools/configure b/tools/configure
index be4b0e3902..1a03f3f010 100755
--- a/tools/configure
+++ b/tools/configure
@@ -4409,15 +4409,14 @@ gccver=`$CC -dumpversion`;
# system etc to be able to see it easier
if [ $uname = "Darwin" ]; then
ldver=`$LD -v 2>&1 | sed -e 's/[^0-9.-]//g'`
+ # Convert LD version to a number major*100 + minor
+ ldnum1=`echo $ldver | cut -d . -f1`
+ ldnum2=`echo $ldver | cut -d . -f2`
+ ldnum=`(expr $ldnum1 "*" 100 + $ldnum2) 2>/dev/null`
else
- ldver=`$LD --version | sed -n '1p' | sed -e 's/.* \([0-9]*\)\.\([0-9]*\).*/\1\2/'`
+ ldnum=`$LD --version | sed -n '1p' | sed -e 's/.* \([0-9]*\)\.\([0-9]*\).*/\1\2/'`
fi
-# Convert LD version to a number major*100 + minor
-ldnum1=`echo $ldver | cut -d . -f1`
-ldnum2=`echo $ldver | cut -d . -f2`
-ldnum=`(expr $ldnum1 "*" 100 + $ldnum2) 2>/dev/null`
-
if test "$ldnum" -ge "227"; then
have_nocrossrefs_to="#define HAVE_NOCROSSREFS_TO"
else