Skip to content

Commit

Permalink
Merge pull request #291 from andrewwhitehead/fix/darwin-build
Browse files Browse the repository at this point in the history
Fix check for macos major version
  • Loading branch information
andrewwhitehead authored May 27, 2024
2 parents b71ce5c + 6bff7dc commit 9d43f97
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions build-universal.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/sh

# NOTE:
# MacOS universal build currently requires MacOS 11 (Big Sur) for the appropriate SDK,
# MacOS universal build currently requires MacOS 11+ (Big Sur) for the appropriate SDK,
# and `sudo xcode-select --install` must be run to install the command line utilities.
# Rust's `beta` channel must be installed because aarch64 is still a tier-2 target:
# `rustup toolchain install beta`.
Expand Down Expand Up @@ -41,7 +41,7 @@ for target in $MACOS_UNIVERSAL_TARGETS; do
fi
done

MAJOR_VER=`sw_vers | grep ProductVersion | cut -f 2 | cut -f 1 -d .`
MAJOR_VER=`sw_vers -productVersion | cut -f 1 -d .`
if [ "$MAJOR_VER" -lt 11 ]; then
echo "MacOS universal build requires OS 11 (Big Sur) or newer"
TARGET=
Expand Down

0 comments on commit 9d43f97

Please sign in to comment.