From 96cbdc70f239a25ea22d49f205c6168b526079df Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Fri, 5 Feb 2016 11:59:18 +0100 Subject: [PATCH] cc-wrapper: fix #10574: old gcc -> cc fallout The part with gcc-wrapper-old changes is rather unimportant, as it's almost unused but I still tested that the sole user `gnat` builds. --- pkgs/build-support/cc-wrapper/add-flags | 6 +++--- pkgs/build-support/gcc-wrapper-old/add-flags | 10 +++++----- pkgs/build-support/gcc-wrapper-old/builder.sh | 4 ++-- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/pkgs/build-support/cc-wrapper/add-flags b/pkgs/build-support/cc-wrapper/add-flags index d4836153904..5634c82aa28 100644 --- a/pkgs/build-support/cc-wrapper/add-flags +++ b/pkgs/build-support/cc-wrapper/add-flags @@ -1,11 +1,11 @@ -# `-B@out@/bin' forces gcc to use ld-wrapper.sh when calling ld. +# `-B@out@/bin' forces cc to use ld-wrapper.sh when calling ld. export NIX_CFLAGS_COMPILE="-B@out@/bin/ $NIX_CFLAGS_COMPILE" if [ -e @out@/nix-support/libc-cflags ]; then export NIX_CFLAGS_COMPILE="$(cat @out@/nix-support/libc-cflags) $NIX_CFLAGS_COMPILE" fi -if [ -e @out@/nix-support/gcc-cflags ]; then +if [ -e @out@/nix-support/cc-cflags ]; then export NIX_CFLAGS_COMPILE="$(cat @out@/nix-support/cc-cflags) $NIX_CFLAGS_COMPILE" fi @@ -17,7 +17,7 @@ if [ -e @out@/nix-support/libc-ldflags ]; then export NIX_LDFLAGS+=" $(cat @out@/nix-support/libc-ldflags)" fi -if [ -e @out@/nix-support/gcc-ldflags ]; then +if [ -e @out@/nix-support/cc-ldflags ]; then export NIX_LDFLAGS+=" $(cat @out@/nix-support/cc-ldflags)" fi diff --git a/pkgs/build-support/gcc-wrapper-old/add-flags b/pkgs/build-support/gcc-wrapper-old/add-flags index 7714a630573..93da917a541 100644 --- a/pkgs/build-support/gcc-wrapper-old/add-flags +++ b/pkgs/build-support/gcc-wrapper-old/add-flags @@ -1,12 +1,12 @@ -# `-B@out@/bin' forces gcc to use ld-wrapper.sh when calling ld. +# `-B@out@/bin' forces cc to use ld-wrapper.sh when calling ld. export NIX_CFLAGS_COMPILE="-B@out@/bin/ $NIX_CFLAGS_COMPILE" if test -e @out@/nix-support/libc-cflags; then export NIX_CFLAGS_COMPILE="$(cat @out@/nix-support/libc-cflags) $NIX_CFLAGS_COMPILE" fi -if test -e @out@/nix-support/gcc-cflags; then - export NIX_CFLAGS_COMPILE="$(cat @out@/nix-support/gcc-cflags) $NIX_CFLAGS_COMPILE" +if test -e @out@/nix-support/cc-cflags; then + export NIX_CFLAGS_COMPILE="$(cat @out@/nix-support/cc-cflags) $NIX_CFLAGS_COMPILE" fi if test -e @out@/nix-support/gnat-cflags; then @@ -17,8 +17,8 @@ if test -e @out@/nix-support/libc-ldflags; then export NIX_LDFLAGS="$NIX_LDFLAGS $(cat @out@/nix-support/libc-ldflags)" fi -if test -e @out@/nix-support/gcc-ldflags; then - export NIX_LDFLAGS="$NIX_LDFLAGS $(cat @out@/nix-support/gcc-ldflags)" +if test -e @out@/nix-support/cc-ldflags; then + export NIX_LDFLAGS="$NIX_LDFLAGS $(cat @out@/nix-support/cc-ldflags)" fi if test -e @out@/nix-support/libc-ldflags-before; then diff --git a/pkgs/build-support/gcc-wrapper-old/builder.sh b/pkgs/build-support/gcc-wrapper-old/builder.sh index 59cdd3f84ad..7bb48709614 100644 --- a/pkgs/build-support/gcc-wrapper-old/builder.sh +++ b/pkgs/build-support/gcc-wrapper-old/builder.sh @@ -45,7 +45,7 @@ else if [ -n "$langVhdl" ]; then gccLDFlags="$gccLDFlags -L$zlib/lib" fi - echo "$gccLDFlags" > $out/nix-support/gcc-ldflags + echo "$gccLDFlags" > $out/nix-support/cc-ldflags # GCC shows $gcc/lib in `gcc -print-search-dirs', but not # $gcc/lib64 (even though it does actually search there...).. @@ -63,7 +63,7 @@ else gnatCFlags="-aI$basePath/adainclude -aO$basePath/adalib" echo "$gnatCFlags" > $out/nix-support/gnat-cflags fi - echo "$gccCFlags" > $out/nix-support/gcc-cflags + echo "$gccCFlags" > $out/nix-support/cc-cflags gccPath="$gcc/bin" # On Illumos/Solaris we might prefer native ld