diff options
| author | Laytan Laats <laytanlaats@hotmail.com> | 2024-05-30 01:53:38 +0200 |
|---|---|---|
| committer | Laytan Laats <laytanlaats@hotmail.com> | 2024-05-30 01:53:38 +0200 |
| commit | eeb057b76d8689dcff9d0bee44fbfcdfb07e8bc7 (patch) | |
| tree | 982e78d1d20b2d67db1b6c9b1eeffbcc625b8de8 /build_odin.sh | |
| parent | 75f1215ed283e29dda4b8c84ac8929d7d54189e5 (diff) | |
darwin: fix sysroot retrieval for some systems
Got a report on Discord that the current way didn't work for a user,
this change did work and I confirmed with @harold-b (who initially added
this) that it also works for them and is actually a better way.
Diffstat (limited to 'build_odin.sh')
| -rwxr-xr-x | build_odin.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/build_odin.sh b/build_odin.sh index ec65bb49d..d2f865e24 100755 --- a/build_odin.sh +++ b/build_odin.sh @@ -71,8 +71,8 @@ Darwin) fi darwin_sysroot= - if [ $(which xcode-select) ]; then - darwin_sysroot="--sysroot $(xcode-select -p)/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk" + if [ $(which xcrun) ]; then + darwin_sysroot="--sysroot $(xcrun --sdk macosx --show-sdk-path)" elif [[ -e "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk" ]]; then darwin_sysroot="--sysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk" else |