From 1fe9798ac23e9be70553ba20a37fc32aa4f98f7f Mon Sep 17 00:00:00 2001 From: John Ericson Date: Tue, 5 Dec 2017 13:45:43 -0500 Subject: [PATCH] lib, gcc: No `inherit (platform) gcc;` in {host,build,target}Platform --- lib/systems/examples.nix | 9 +------ .../development/compilers/gcc/4.5/default.nix | 12 +++++----- .../development/compilers/gcc/4.8/default.nix | 24 +++++++++---------- .../development/compilers/gcc/4.9/default.nix | 24 +++++++++---------- pkgs/development/compilers/gcc/5/default.nix | 24 +++++++++---------- pkgs/development/compilers/gcc/6/default.nix | 24 +++++++++---------- pkgs/development/compilers/gcc/7/default.nix | 24 +++++++++---------- .../compilers/gcc/snapshot/default.nix | 24 +++++++++---------- 8 files changed, 79 insertions(+), 86 deletions(-) diff --git a/lib/systems/examples.nix b/lib/systems/examples.nix index e394f43831c..28eb29c977a 100644 --- a/lib/systems/examples.nix +++ b/lib/systems/examples.nix @@ -18,7 +18,6 @@ rec { libc = "glibc"; platform = platforms.sheevaplug; openssl.system = "linux-generic32"; - inherit (platform) gcc; }; raspberryPi = rec { @@ -31,7 +30,6 @@ rec { libc = "glibc"; platform = platforms.raspberrypi; openssl.system = "linux-generic32"; - inherit (platform) gcc; }; armv7l-hf-multiplatform = rec { @@ -44,7 +42,6 @@ rec { libc = "glibc"; platform = platforms.armv7l-hf-multiplatform; openssl.system = "linux-generic32"; - inherit (platform) gcc; }; aarch64-multiplatform = rec { @@ -54,13 +51,11 @@ rec { withTLS = true; libc = "glibc"; platform = platforms.aarch64-multiplatform; - inherit (platform) gcc; }; scaleway-c1 = armv7l-hf-multiplatform // rec { platform = platforms.scaleway-c1; - inherit (platform) gcc; - inherit (gcc) fpu; + inherit (platform.gcc) fpu; }; pogoplug4 = rec { @@ -70,7 +65,6 @@ rec { platform = platforms.pogoplug4; - inherit (platform) gcc; libc = "glibc"; withTLS = true; @@ -86,7 +80,6 @@ rec { libc = "glibc"; platform = platforms.fuloong2f_n32; openssl.system = "linux-generic32"; - inherit (platform) gcc; }; # diff --git a/pkgs/development/compilers/gcc/4.5/default.nix b/pkgs/development/compilers/gcc/4.5/default.nix index c860991b8cf..ad605fdf268 100644 --- a/pkgs/development/compilers/gcc/4.5/default.nix +++ b/pkgs/development/compilers/gcc/4.5/default.nix @@ -65,12 +65,12 @@ let version = "4.5.4"; /* Platform flags */ platformFlags = let - gccArch = targetPlatform.gcc.arch or null; - gccCpu = targetPlatform.gcc.cpu or null; - gccAbi = targetPlatform.gcc.abi or null; - gccFpu = targetPlatform.gcc.fpu or null; - gccFloat = targetPlatform.gcc.float or null; - gccMode = targetPlatform.gcc.mode or null; + gccArch = targetPlatform.platform.gcc.arch or null; + gccCpu = targetPlatform.platform.gcc.cpu or null; + gccAbi = targetPlatform.platform.gcc.abi or null; + gccFpu = targetPlatform.platform.gcc.fpu or null; + gccFloat = targetPlatform.platform.gcc.float or null; + gccMode = targetPlatform.platform.gcc.mode or null; withArch = if gccArch != null then " --with-arch=${gccArch}" else ""; withCpu = if gccCpu != null then " --with-cpu=${gccCpu}" else ""; withAbi = if gccAbi != null then " --with-abi=${gccAbi}" else ""; diff --git a/pkgs/development/compilers/gcc/4.8/default.nix b/pkgs/development/compilers/gcc/4.8/default.nix index aa2160f6db2..15f8c1858f2 100644 --- a/pkgs/development/compilers/gcc/4.8/default.nix +++ b/pkgs/development/compilers/gcc/4.8/default.nix @@ -98,12 +98,12 @@ let version = "4.8.5"; /* Platform flags */ platformFlags = let - gccArch = targetPlatform.gcc.arch or null; - gccCpu = targetPlatform.gcc.cpu or null; - gccAbi = targetPlatform.gcc.abi or null; - gccFpu = targetPlatform.gcc.fpu or null; - gccFloat = targetPlatform.gcc.float or null; - gccMode = targetPlatform.gcc.mode or null; + gccArch = targetPlatform.platform.gcc.arch or null; + gccCpu = targetPlatform.platform.gcc.cpu or null; + gccAbi = targetPlatform.platform.gcc.abi or null; + gccFpu = targetPlatform.platform.gcc.fpu or null; + gccFloat = targetPlatform.platform.gcc.float or null; + gccMode = targetPlatform.platform.gcc.mode or null; withArch = if gccArch != null then " --with-arch=${gccArch}" else ""; withCpu = if gccCpu != null then " --with-cpu=${gccCpu}" else ""; withAbi = if gccAbi != null then " --with-abi=${gccAbi}" else ""; @@ -122,12 +122,12 @@ let version = "4.8.5"; crossMingw = targetPlatform != hostPlatform && targetPlatform.libc == "msvcrt"; crossDarwin = targetPlatform != hostPlatform && targetPlatform.libc == "libSystem"; crossConfigureFlags = let - gccArch = targetPlatform.gcc.arch or null; - gccCpu = targetPlatform.gcc.cpu or null; - gccAbi = targetPlatform.gcc.abi or null; - gccFpu = targetPlatform.gcc.fpu or null; - gccFloat = targetPlatform.gcc.float or null; - gccMode = targetPlatform.gcc.mode or null; + gccArch = targetPlatform.platform.gcc.arch or null; + gccCpu = targetPlatform.platform.gcc.cpu or null; + gccAbi = targetPlatform.platform.gcc.abi or null; + gccFpu = targetPlatform.platform.gcc.fpu or null; + gccFloat = targetPlatform.platform.gcc.float or null; + gccMode = targetPlatform.platform.gcc.mode or null; withArch = if gccArch != null then " --with-arch=${gccArch}" else ""; withCpu = if gccCpu != null then " --with-cpu=${gccCpu}" else ""; withAbi = if gccAbi != null then " --with-abi=${gccAbi}" else ""; diff --git a/pkgs/development/compilers/gcc/4.9/default.nix b/pkgs/development/compilers/gcc/4.9/default.nix index d6e09ca8dac..b46510fe3d9 100644 --- a/pkgs/development/compilers/gcc/4.9/default.nix +++ b/pkgs/development/compilers/gcc/4.9/default.nix @@ -100,12 +100,12 @@ let version = "4.9.4"; /* Platform flags */ platformFlags = let - gccArch = targetPlatform.gcc.arch or null; - gccCpu = targetPlatform.gcc.cpu or null; - gccAbi = targetPlatform.gcc.abi or null; - gccFpu = targetPlatform.gcc.fpu or null; - gccFloat = targetPlatform.gcc.float or null; - gccMode = targetPlatform.gcc.mode or null; + gccArch = targetPlatform.platform.gcc.arch or null; + gccCpu = targetPlatform.platform.gcc.cpu or null; + gccAbi = targetPlatform.platform.gcc.abi or null; + gccFpu = targetPlatform.platform.gcc.fpu or null; + gccFloat = targetPlatform.platform.gcc.float or null; + gccMode = targetPlatform.platform.gcc.mode or null; withArch = if gccArch != null then " --with-arch=${gccArch}" else ""; withCpu = if gccCpu != null then " --with-cpu=${gccCpu}" else ""; withAbi = if gccAbi != null then " --with-abi=${gccAbi}" else ""; @@ -124,12 +124,12 @@ let version = "4.9.4"; crossMingw = targetPlatform != hostPlatform && targetPlatform.libc == "msvcrt"; crossDarwin = targetPlatform != hostPlatform && targetPlatform.libc == "libSystem"; crossConfigureFlags = let - gccArch = targetPlatform.gcc.arch or null; - gccCpu = targetPlatform.gcc.cpu or null; - gccAbi = targetPlatform.gcc.abi or null; - gccFpu = targetPlatform.gcc.fpu or null; - gccFloat = targetPlatform.gcc.float or null; - gccMode = targetPlatform.gcc.mode or null; + gccArch = targetPlatform.platform.gcc.arch or null; + gccCpu = targetPlatform.platform.gcc.cpu or null; + gccAbi = targetPlatform.platform.gcc.abi or null; + gccFpu = targetPlatform.platform.gcc.fpu or null; + gccFloat = targetPlatform.platform.gcc.float or null; + gccMode = targetPlatform.platform.gcc.mode or null; withArch = if gccArch != null then " --with-arch=${gccArch}" else ""; withCpu = if gccCpu != null then " --with-cpu=${gccCpu}" else ""; withAbi = if gccAbi != null then " --with-abi=${gccAbi}" else ""; diff --git a/pkgs/development/compilers/gcc/5/default.nix b/pkgs/development/compilers/gcc/5/default.nix index f6a6a32ab9a..e78e0b251cb 100644 --- a/pkgs/development/compilers/gcc/5/default.nix +++ b/pkgs/development/compilers/gcc/5/default.nix @@ -104,12 +104,12 @@ let version = "5.4.0"; /* Platform flags */ platformFlags = let - gccArch = targetPlatform.gcc.arch or null; - gccCpu = targetPlatform.gcc.cpu or null; - gccAbi = targetPlatform.gcc.abi or null; - gccFpu = targetPlatform.gcc.fpu or null; - gccFloat = targetPlatform.gcc.float or null; - gccMode = targetPlatform.gcc.mode or null; + gccArch = targetPlatform.platform.gcc.arch or null; + gccCpu = targetPlatform.platform.gcc.cpu or null; + gccAbi = targetPlatform.platform.gcc.abi or null; + gccFpu = targetPlatform.platform.gcc.fpu or null; + gccFloat = targetPlatform.platform.gcc.float or null; + gccMode = targetPlatform.platform.gcc.mode or null; withArch = if gccArch != null then " --with-arch=${gccArch}" else ""; withCpu = if gccCpu != null then " --with-cpu=${gccCpu}" else ""; withAbi = if gccAbi != null then " --with-abi=${gccAbi}" else ""; @@ -128,12 +128,12 @@ let version = "5.4.0"; crossMingw = targetPlatform != hostPlatform && targetPlatform.libc == "msvcrt"; crossDarwin = targetPlatform != hostPlatform && targetPlatform.libc == "libSystem"; crossConfigureFlags = let - gccArch = targetPlatform.gcc.arch or null; - gccCpu = targetPlatform.gcc.cpu or null; - gccAbi = targetPlatform.gcc.abi or null; - gccFpu = targetPlatform.gcc.fpu or null; - gccFloat = targetPlatform.gcc.float or null; - gccMode = targetPlatform.gcc.mode or null; + gccArch = targetPlatform.platform.gcc.arch or null; + gccCpu = targetPlatform.platform.gcc.cpu or null; + gccAbi = targetPlatform.platform.gcc.abi or null; + gccFpu = targetPlatform.platform.gcc.fpu or null; + gccFloat = targetPlatform.platform.gcc.float or null; + gccMode = targetPlatform.platform.gcc.mode or null; withArch = if gccArch != null then " --with-arch=${gccArch}" else ""; withCpu = if gccCpu != null then " --with-cpu=${gccCpu}" else ""; withAbi = if gccAbi != null then " --with-abi=${gccAbi}" else ""; diff --git a/pkgs/development/compilers/gcc/6/default.nix b/pkgs/development/compilers/gcc/6/default.nix index 474c8b66de6..947017343e2 100644 --- a/pkgs/development/compilers/gcc/6/default.nix +++ b/pkgs/development/compilers/gcc/6/default.nix @@ -100,12 +100,12 @@ let version = "6.3.0"; /* Platform flags */ platformFlags = let - gccArch = targetPlatform.gcc.arch or null; - gccCpu = targetPlatform.gcc.cpu or null; - gccAbi = targetPlatform.gcc.abi or null; - gccFpu = targetPlatform.gcc.fpu or null; - gccFloat = targetPlatform.gcc.float or null; - gccMode = targetPlatform.gcc.mode or null; + gccArch = targetPlatform.platform.gcc.arch or null; + gccCpu = targetPlatform.platform.gcc.cpu or null; + gccAbi = targetPlatform.platform.gcc.abi or null; + gccFpu = targetPlatform.platform.gcc.fpu or null; + gccFloat = targetPlatform.platform.gcc.float or null; + gccMode = targetPlatform.platform.gcc.mode or null; withArch = if gccArch != null then " --with-arch=${gccArch}" else ""; withCpu = if gccCpu != null then " --with-cpu=${gccCpu}" else ""; withAbi = if gccAbi != null then " --with-abi=${gccAbi}" else ""; @@ -124,12 +124,12 @@ let version = "6.3.0"; crossMingw = targetPlatform != hostPlatform && targetPlatform.libc == "msvcrt"; crossDarwin = targetPlatform != hostPlatform && targetPlatform.libc == "libSystem"; crossConfigureFlags = let - gccArch = targetPlatform.gcc.arch or null; - gccCpu = targetPlatform.gcc.cpu or null; - gccAbi = targetPlatform.gcc.abi or null; - gccFpu = targetPlatform.gcc.fpu or null; - gccFloat = targetPlatform.gcc.float or null; - gccMode = targetPlatform.gcc.mode or null; + gccArch = targetPlatform.platform.gcc.arch or null; + gccCpu = targetPlatform.platform.gcc.cpu or null; + gccAbi = targetPlatform.platform.gcc.abi or null; + gccFpu = targetPlatform.platform.gcc.fpu or null; + gccFloat = targetPlatform.platform.gcc.float or null; + gccMode = targetPlatform.platform.gcc.mode or null; withArch = if gccArch != null then " --with-arch=${gccArch}" else ""; withCpu = if gccCpu != null then " --with-cpu=${gccCpu}" else ""; withAbi = if gccAbi != null then " --with-abi=${gccAbi}" else ""; diff --git a/pkgs/development/compilers/gcc/7/default.nix b/pkgs/development/compilers/gcc/7/default.nix index 3955c2c453e..7d2c0771695 100644 --- a/pkgs/development/compilers/gcc/7/default.nix +++ b/pkgs/development/compilers/gcc/7/default.nix @@ -100,12 +100,12 @@ let version = "7.1.0"; /* Platform flags */ platformFlags = let - gccArch = targetPlatform.gcc.arch or null; - gccCpu = targetPlatform.gcc.cpu or null; - gccAbi = targetPlatform.gcc.abi or null; - gccFpu = targetPlatform.gcc.fpu or null; - gccFloat = targetPlatform.gcc.float or null; - gccMode = targetPlatform.gcc.mode or null; + gccArch = targetPlatform.platform.gcc.arch or null; + gccCpu = targetPlatform.platform.gcc.cpu or null; + gccAbi = targetPlatform.platform.gcc.abi or null; + gccFpu = targetPlatform.platform.gcc.fpu or null; + gccFloat = targetPlatform.platform.gcc.float or null; + gccMode = targetPlatform.platform.gcc.mode or null; withArch = if gccArch != null then " --with-arch=${gccArch}" else ""; withCpu = if gccCpu != null then " --with-cpu=${gccCpu}" else ""; withAbi = if gccAbi != null then " --with-abi=${gccAbi}" else ""; @@ -124,12 +124,12 @@ let version = "7.1.0"; crossMingw = targetPlatform != hostPlatform && targetPlatform.libc == "msvcrt"; crossDarwin = targetPlatform != hostPlatform && targetPlatform.libc == "libSystem"; crossConfigureFlags = let - gccArch = targetPlatform.gcc.arch or null; - gccCpu = targetPlatform.gcc.cpu or null; - gccAbi = targetPlatform.gcc.abi or null; - gccFpu = targetPlatform.gcc.fpu or null; - gccFloat = targetPlatform.gcc.float or null; - gccMode = targetPlatform.gcc.mode or null; + gccArch = targetPlatform.platform.gcc.arch or null; + gccCpu = targetPlatform.platform.gcc.cpu or null; + gccAbi = targetPlatform.platform.gcc.abi or null; + gccFpu = targetPlatform.platform.gcc.fpu or null; + gccFloat = targetPlatform.platform.gcc.float or null; + gccMode = targetPlatform.platform.gcc.mode or null; withArch = if gccArch != null then " --with-arch=${gccArch}" else ""; withCpu = if gccCpu != null then " --with-cpu=${gccCpu}" else ""; withAbi = if gccAbi != null then " --with-abi=${gccAbi}" else ""; diff --git a/pkgs/development/compilers/gcc/snapshot/default.nix b/pkgs/development/compilers/gcc/snapshot/default.nix index 6cb64d2b9ee..c2ac3248661 100644 --- a/pkgs/development/compilers/gcc/snapshot/default.nix +++ b/pkgs/development/compilers/gcc/snapshot/default.nix @@ -100,12 +100,12 @@ let version = "7-20170409"; /* Platform flags */ platformFlags = let - gccArch = targetPlatform.gcc.arch or null; - gccCpu = targetPlatform.gcc.cpu or null; - gccAbi = targetPlatform.gcc.abi or null; - gccFpu = targetPlatform.gcc.fpu or null; - gccFloat = targetPlatform.gcc.float or null; - gccMode = targetPlatform.gcc.mode or null; + gccArch = targetPlatform.platform.gcc.arch or null; + gccCpu = targetPlatform.platform.gcc.cpu or null; + gccAbi = targetPlatform.platform.gcc.abi or null; + gccFpu = targetPlatform.platform.gcc.fpu or null; + gccFloat = targetPlatform.platform.gcc.float or null; + gccMode = targetPlatform.platform.gcc.mode or null; withArch = if gccArch != null then " --with-arch=${gccArch}" else ""; withCpu = if gccCpu != null then " --with-cpu=${gccCpu}" else ""; withAbi = if gccAbi != null then " --with-abi=${gccAbi}" else ""; @@ -124,12 +124,12 @@ let version = "7-20170409"; crossMingw = targetPlatform != hostPlatform && targetPlatform.libc == "msvcrt"; crossDarwin = targetPlatform != hostPlatform && targetPlatform.libc == "libSystem"; crossConfigureFlags = let - gccArch = targetPlatform.gcc.arch or null; - gccCpu = targetPlatform.gcc.cpu or null; - gccAbi = targetPlatform.gcc.abi or null; - gccFpu = targetPlatform.gcc.fpu or null; - gccFloat = targetPlatform.gcc.float or null; - gccMode = targetPlatform.gcc.mode or null; + gccArch = targetPlatform.platform.gcc.arch or null; + gccCpu = targetPlatform.platform.gcc.cpu or null; + gccAbi = targetPlatform.platform.gcc.abi or null; + gccFpu = targetPlatform.platform.gcc.fpu or null; + gccFloat = targetPlatform.platform.gcc.float or null; + gccMode = targetPlatform.platform.gcc.mode or null; withArch = if gccArch != null then " --with-arch=${gccArch}" else ""; withCpu = if gccCpu != null then " --with-cpu=${gccCpu}" else ""; withAbi = if gccAbi != null then " --with-abi=${gccAbi}" else "";