Merge pull request #7266 from Bo98/xcrun

shims/mac/super/xcrun: set DEVELOPER_DIR less often
This commit is contained in:
Bo Anderson 2020-04-03 10:43:14 +01:00 committed by GitHub
commit 4f85398dea
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3,9 +3,8 @@
# work at all (e.g. CLT-only in the Xcode 4.3 era). This script emulates # work at all (e.g. CLT-only in the Xcode 4.3 era). This script emulates
# it and attempts to avoid these issues. # it and attempts to avoid these issues.
# SDKROOT is not used if `--sdk` is supplied. # These could be used in conjunction with `--sdk` which ignores SDKROOT.
# We however don't want to interrupt other uses like `xcrun --find clang`. if [[ "$*" =~ (^| )-?-show-sdk-(path|version|build) ]]; then
if [[ "$*" =~ (^| )-?-sdk ]]; then
export DEVELOPER_DIR=$HOMEBREW_DEVELOPER_DIR export DEVELOPER_DIR=$HOMEBREW_DEVELOPER_DIR
else else
# Some build tools set DEVELOPER_DIR, so discard it # Some build tools set DEVELOPER_DIR, so discard it