Fix checkdeps.sh on Mac (#3306)

Update the check_minimum_version function to use numeric comparison (not
string comparison) on components of version numbers. Fixes the following
output:

```
$ make
Checking deps:
ERROR
OSX version '10.11.6' not supported.
Minimum supported version: 10.8
make: *** [checks] Error 1
```
master
tibbes 8 years ago committed by Harshavardhana
parent 273228fafa
commit 33c022fcec
  1. 4
      buildscripts/checkdeps.sh

@ -72,9 +72,9 @@ check_minimum_version() {
IFS='.' read -r -a varray2 <<< "$2" IFS='.' read -r -a varray2 <<< "$2"
for i in "${!varray1[@]}"; do for i in "${!varray1[@]}"; do
if [[ ${varray1[i]} < ${varray2[i]} ]]; then if [[ ${varray1[i]} -lt ${varray2[i]} ]]; then
return 0 return 0
elif [[ ${varray1[i]} > ${varray2[i]} ]]; then elif [[ ${varray1[i]} -gt ${varray2[i]} ]]; then
return 1 return 1
fi fi
done done

Loading…
Cancel
Save