From b3613dd8d79940947f649b88e54cda420c7399e1 Mon Sep 17 00:00:00 2001 From: Shamrock Lee <44064051+ShamrockLee@users.noreply.github.com> Date: Sat, 30 Oct 2021 22:42:58 +0000 Subject: [PATCH] gtkd: add possibility to use different D compilers Specify the D compiler to use with argument `dcompiler` Move the specification to all-packages.nix Passthru the `dcompiler` attribute to make it discoverable by reverse deps --- pkgs/development/libraries/gtkd/default.nix | 8 ++++++-- pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/pkgs/development/libraries/gtkd/default.nix b/pkgs/development/libraries/gtkd/default.nix index ed4326527005..18fedb2c17d4 100644 --- a/pkgs/development/libraries/gtkd/default.nix +++ b/pkgs/development/libraries/gtkd/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchzip, fetchpatch, atk, cairo, ldc, gdk-pixbuf, gnome, gst_all_1, librsvg +{ lib, stdenv, fetchzip, fetchpatch, atk, cairo, dcompiler, gdk-pixbuf, gnome, gst_all_1, librsvg , glib, gtk3, gtksourceview4, libgda, libpeas, pango, pkg-config, which, vte }: let @@ -15,7 +15,7 @@ in stdenv.mkDerivation rec { stripRoot = false; }; - nativeBuildInputs = [ ldc pkg-config which ]; + nativeBuildInputs = [ dcompiler pkg-config which ]; propagatedBuildInputs = [ atk cairo gdk-pixbuf glib gstreamer gst-plugins-base gtk3 gtksourceview4 libgda libpeas librsvg pango vte @@ -134,6 +134,10 @@ in stdenv.mkDerivation rec { done ''; + passthru = { + inherit dcompiler; + }; + meta = with lib; { description = "D binding and OO wrapper for GTK"; homepage = "https://gtkd.org"; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index e665d0bdc23d..85ae3447371c 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6703,7 +6703,7 @@ with pkgs; gtdialog = callPackage ../development/libraries/gtdialog {}; - gtkd = callPackage ../development/libraries/gtkd { }; + gtkd = callPackage ../development/libraries/gtkd { dcompiler = ldc; }; gtkgnutella = callPackage ../tools/networking/p2p/gtk-gnutella { };