cc-wrapper: Use MacOS compatible mktemp command
The commit 6f2b3ba027
introduced a
`mktemp` invokation that uses the `--tmpdir` flag, which is not
available on MacOS.
This changes the invokation to a portable one based on the following
StackOverflow answer https://stackoverflow.com/a/31397073/841562 .
This commit is contained in:
parent
96a8a16dac
commit
13a4690d0d
1 changed files with 1 additions and 1 deletions
|
@ -246,7 +246,7 @@ if [[ -e @out@/nix-support/cc-wrapper-hook ]]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if (( "${NIX_CC_USE_RESPONSE_FILE:-@use_response_file_by_default@}" >= 1 )); then
|
if (( "${NIX_CC_USE_RESPONSE_FILE:-@use_response_file_by_default@}" >= 1 )); then
|
||||||
responseFile=$(mktemp --tmpdir cc-params.XXXXXX)
|
responseFile=$(mktemp "${TMPDIR:-/tmp}/cc-params.XXXXXX")
|
||||||
trap 'rm -f -- "$responseFile"' EXIT
|
trap 'rm -f -- "$responseFile"' EXIT
|
||||||
printf "%q\n" \
|
printf "%q\n" \
|
||||||
${extraBefore+"${extraBefore[@]}"} \
|
${extraBefore+"${extraBefore[@]}"} \
|
||||||
|
|
Loading…
Reference in a new issue