diff --git a/pkgs/build-support/gcc-wrapper/default.nix b/pkgs/build-support/gcc-wrapper/default.nix index 22d02395129..c48ee635f37 100644 --- a/pkgs/build-support/gcc-wrapper/default.nix +++ b/pkgs/build-support/gcc-wrapper/default.nix @@ -27,7 +27,7 @@ stdenv.mkDerivation { langCC = if nativeTools then true else gcc.langCC; langF77 = if nativeTools then false else gcc.langF77; shell = if shell == "" then stdenv.shell else shell; - meta = if gcc != null then gcc.meta else + meta = if gcc != null && (gcc ? meta) then gcc.meta else { description = "System C compiler wrapper"; }; -} +} \ No newline at end of file diff --git a/pkgs/stdenv/linux/default.nix b/pkgs/stdenv/linux/default.nix index 3fc3c16e01f..25c72be5cb7 100644 --- a/pkgs/stdenv/linux/default.nix +++ b/pkgs/stdenv/linux/default.nix @@ -101,7 +101,7 @@ rec { args = ./scripts/builder-stdenv-initial.sh; inherit staticTools; } // { - mkDerivation = attrs: derivation (attrs // { + mkDerivation = attrs: derivation ((removeAttrs attrs ["meta"]) // { builder = ./tools/bash; args = ["-e" attrs.builder]; stdenv = body;