Merge pull request #15666 from carlocab/make-shim

shims/mac: handle usage of Homebrew `make`
This commit is contained in:
Carlo Cabrera 2023-07-12 10:51:52 +08:00 committed by GitHub
commit ae7b791a21
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 5 deletions

View File

@ -1,4 +0,0 @@
#!/bin/bash
export HOMEBREW_CCCFG="O${HOMEBREW_CCCFG}"
exec xcrun bsdmake "$@"

View File

@ -0,0 +1 @@
make

View File

@ -1,4 +1,12 @@
#!/bin/bash
export HOMEBREW_CCCFG="O${HOMEBREW_CCCFG}"
exec xcrun "make" "$@"
SHIM_FILE="${0##*/}"
if xcrun --find "${SHIM_FILE}" &>/dev/null
then
exec xcrun "${SHIM_FILE}" "$@"
else
exec xcrun make "$@"
fi