diff options
author | Vladimír Čunát <vcunat@gmail.com> | 2016-04-01 10:06:01 +0200 |
---|---|---|
committer | Vladimír Čunát <vcunat@gmail.com> | 2016-04-01 10:06:01 +0200 |
commit | ab15a62c68bf7bf3b02e3bab00d121cc1426733c (patch) | |
tree | 398a82403b04bfa0bae8cadf1c5a64cf83145965 /pkgs/build-support/cc-wrapper/gnat-wrapper.sh | |
parent | c643ccaa8c91f78b8c89eb87589886b8906d5b38 (diff) | |
parent | a26357eefe017964448b5bb464163646b927a267 (diff) | |
download | nixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.tar nixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.tar.gz nixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.tar.bz2 nixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.tar.lz nixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.tar.xz nixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.tar.zst nixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.zip |
Merge branch 'master' into closure-size
Beware that stdenv doesn't build. It seems something more will be needed than just resolution of merge conflicts.
Diffstat (limited to 'pkgs/build-support/cc-wrapper/gnat-wrapper.sh')
-rw-r--r-- | pkgs/build-support/cc-wrapper/gnat-wrapper.sh | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/pkgs/build-support/cc-wrapper/gnat-wrapper.sh b/pkgs/build-support/cc-wrapper/gnat-wrapper.sh index 06858da512a7..0d74527dd8ad 100644 --- a/pkgs/build-support/cc-wrapper/gnat-wrapper.sh +++ b/pkgs/build-support/cc-wrapper/gnat-wrapper.sh @@ -62,7 +62,7 @@ if [ "$NIX_ENFORCE_PURITY" = 1 -a -n "$NIX_STORE" ]; then elif [ "${p:0:4}" = -aO/ ] && badPath "${p:3}"; then skip $p else - rest=("${rest[@]}" "$p") + rest+=("$p") fi n=$((n + 1)) done @@ -70,6 +70,20 @@ if [ "$NIX_ENFORCE_PURITY" = 1 -a -n "$NIX_STORE" ]; then fi +# Clear march/mtune=native -- they bring impurity. +if [ "$NIX_ENFORCE_NO_NATIVE" = 1 ]; then + rest=() + for i in "${params[@]}"; do + if [[ "$i" = -m*=native ]]; then + skip $i + else + rest+=("$i") + fi + done + params=("${rest[@]}") +fi + + # Add the flags for the GNAT compiler proper. extraAfter=($NIX_GNATFLAGS_COMPILE) extraBefore=() |