summaryrefslogtreecommitdiffstats
path: root/pkgs/development/compilers/gcc/common
diff options
context:
space:
mode:
authorStefan Frijters <sfrijters@gmail.com>2019-09-20 12:05:57 +0200
committerStefan Frijters <sfrijters@gmail.com>2020-05-19 23:06:52 +0200
commitfc9b93d2fc59dbd2bcf0777164db51c5dbf996f4 (patch)
tree2d4074b11e3448d410c4f54ab0707ede00a6477b /pkgs/development/compilers/gcc/common
parent2c37314aaf04283636a36abd52d4091edc817851 (diff)
gdc: init at 9.3.0
Diffstat (limited to 'pkgs/development/compilers/gcc/common')
-rw-r--r--pkgs/development/compilers/gcc/common/configure-flags.nix5
-rw-r--r--pkgs/development/compilers/gcc/common/extra-target-flags.nix8
2 files changed, 9 insertions, 4 deletions
diff --git a/pkgs/development/compilers/gcc/common/configure-flags.nix b/pkgs/development/compilers/gcc/common/configure-flags.nix
index c78a28148951..437042baf413 100644
--- a/pkgs/development/compilers/gcc/common/configure-flags.nix
+++ b/pkgs/development/compilers/gcc/common/configure-flags.nix
@@ -14,6 +14,7 @@
, langC
, langCC
+, langD ? false
, langFortran
, langJava ? false, javaAwtGtk ? false, javaAntlr ? null, javaEcj ? null
, langAda ? false
@@ -114,6 +115,7 @@ let
lib.concatStrings (lib.intersperse ","
( lib.optional langC "c"
++ lib.optional langCC "c++"
+ ++ lib.optional langD "d"
++ lib.optional langFortran "fortran"
++ lib.optional langJava "java"
++ lib.optional langAda "ada"
@@ -174,6 +176,9 @@ let
"libat_cv_have_ifunc=no"
"--disable-gnu-indirect-function"
]
+ ++ lib.optionals (langD) [
+ "--with-target-system-zlib=yes"
+ ]
;
in configureFlags
diff --git a/pkgs/development/compilers/gcc/common/extra-target-flags.nix b/pkgs/development/compilers/gcc/common/extra-target-flags.nix
index bce9a8d47381..f1696f182c04 100644
--- a/pkgs/development/compilers/gcc/common/extra-target-flags.nix
+++ b/pkgs/development/compilers/gcc/common/extra-target-flags.nix
@@ -1,4 +1,4 @@
-{ stdenv, crossStageStatic, libcCross, threadsCross }:
+{ stdenv, crossStageStatic, langD ? false, libcCross, threadsCross }:
let
inherit (stdenv) lib hostPlatform targetPlatform;
@@ -6,13 +6,13 @@ in
{
EXTRA_TARGET_FLAGS = let
- mkFlags = dep: lib.optionals (targetPlatform != hostPlatform && dep != null) ([
+ mkFlags = dep: langD: lib.optionals (targetPlatform != hostPlatform && dep != null && !langD) ([
"-idirafter ${lib.getDev dep}${dep.incdir or "/include"}"
] ++ stdenv.lib.optionals (! crossStageStatic) [
"-B${lib.getLib dep}${dep.libdir or "/lib"}"
]);
- in mkFlags libcCross
- ++ lib.optionals (!crossStageStatic) (mkFlags threadsCross)
+ in mkFlags libcCross langD
+ ++ lib.optionals (!crossStageStatic) (mkFlags threadsCross langD)
;
EXTRA_TARGET_LDFLAGS = let