summary refs log tree commit diff
path: root/pkgs/build-support/gcc-wrapper/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/build-support/gcc-wrapper/default.nix')
-rw-r--r--pkgs/build-support/gcc-wrapper/default.nix11
1 files changed, 9 insertions, 2 deletions
diff --git a/pkgs/build-support/gcc-wrapper/default.nix b/pkgs/build-support/gcc-wrapper/default.nix
index d3fe5a0569f9..5e50a5c7dfb5 100644
--- a/pkgs/build-support/gcc-wrapper/default.nix
+++ b/pkgs/build-support/gcc-wrapper/default.nix
@@ -21,10 +21,11 @@ let
 
   gccVersion = (builtins.parseDrvName gcc.name).version;
   gccName = (builtins.parseDrvName gcc.name).name;
-  
+
+  langGo = if nativeTools then false else gcc ? langGo && gcc.langGo;
 in
 
-stdenv.mkDerivation {
+stdenv.mkDerivation ({
   name =
     (if name != "" then name else gccName + "-wrapper") +
     (if gcc != null && gccVersion != "" then "-" + gccVersion else "");
@@ -90,3 +91,9 @@ stdenv.mkDerivation {
        abort "don't know the name of the dynamic linker for this platform")
     else "";
 }
+#  This go wrapper should be reworked in stdenv-updates.
+// (if langGo then
+{
+  inherit langGo;
+  builder = ./buildergo.sh;
+} else {}))