From fb73942a4e04861eb75d32435fef5ff70e956e29 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fabi=C3=A1n=20Heredia=20Montiel?= Date: Fri, 15 Apr 2022 22:32:32 -0500 Subject: [PATCH] qt5: inherit stdenv for modules and override gcc version for qt512 and qt514 --- pkgs/development/libraries/qt-5/5.12/default.nix | 2 +- pkgs/development/libraries/qt-5/5.14/default.nix | 2 +- pkgs/development/libraries/qt-5/5.15/default.nix | 2 +- pkgs/top-level/all-packages.nix | 10 ++++++++-- 4 files changed, 11 insertions(+), 5 deletions(-) diff --git a/pkgs/development/libraries/qt-5/5.12/default.nix b/pkgs/development/libraries/qt-5/5.12/default.nix index 01b65eb3e43a..2b8dccf162c9 100644 --- a/pkgs/development/libraries/qt-5/5.12/default.nix +++ b/pkgs/development/libraries/qt-5/5.12/default.nix @@ -146,7 +146,7 @@ let } { inherit self srcs patches; }; - callPackage = self.newScope { inherit qtCompatVersion qtModule srcs; }; + callPackage = self.newScope { inherit qtCompatVersion qtModule srcs stdenv; }; in { inherit callPackage qtCompatVersion qtModule srcs; diff --git a/pkgs/development/libraries/qt-5/5.14/default.nix b/pkgs/development/libraries/qt-5/5.14/default.nix index 8afff5f0a4b9..b95d49fef876 100644 --- a/pkgs/development/libraries/qt-5/5.14/default.nix +++ b/pkgs/development/libraries/qt-5/5.14/default.nix @@ -144,7 +144,7 @@ let } { inherit self srcs patches; }; - callPackage = self.newScope { inherit qtCompatVersion qtModule srcs; }; + callPackage = self.newScope { inherit qtCompatVersion qtModule srcs stdenv; }; in { inherit callPackage qtCompatVersion qtModule srcs; diff --git a/pkgs/development/libraries/qt-5/5.15/default.nix b/pkgs/development/libraries/qt-5/5.15/default.nix index 5943a80a701e..763bfc675cbe 100644 --- a/pkgs/development/libraries/qt-5/5.15/default.nix +++ b/pkgs/development/libraries/qt-5/5.15/default.nix @@ -101,7 +101,7 @@ let } { inherit self srcs patches; }; - callPackage = self.newScope { inherit qtCompatVersion qtModule srcs; }; + callPackage = self.newScope { inherit qtCompatVersion qtModule srcs stdenv; }; in { inherit callPackage qtCompatVersion qtModule srcs; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 00110a4e0674..3c7bafc39f53 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -19839,19 +19839,25 @@ with pkgs; qt512 = recurseIntoAttrs (makeOverridable (import ../development/libraries/qt-5/5.12) { inherit newScope; - inherit lib stdenv fetchurl fetchpatch fetchFromGitHub makeSetupHook makeWrapper; + inherit lib fetchurl fetchpatch fetchFromGitHub makeSetupHook makeWrapper; inherit bison cups dconf harfbuzz libGL perl gtk3; inherit (gst_all_1) gstreamer gst-plugins-base; inherit darwin; + stdenv = if stdenv.cc.isGNU + then (if (stdenv.targetPlatform.isx86_64) then gcc10Stdenv else gcc9Stdenv) + else stdenv; }); qt514 = recurseIntoAttrs (makeOverridable (import ../development/libraries/qt-5/5.14) { inherit newScope; - inherit lib stdenv fetchurl fetchpatch fetchFromGitHub makeSetupHook makeWrapper; + inherit lib fetchurl fetchpatch fetchFromGitHub makeSetupHook makeWrapper; inherit bison cups dconf harfbuzz libGL perl gtk3; inherit (gst_all_1) gstreamer gst-plugins-base; inherit darwin; + stdenv = if stdenv.cc.isGNU + then (if (stdenv.targetPlatform.isx86_64) then gcc10Stdenv else gcc9Stdenv) + else stdenv; }); qt515 = recurseIntoAttrs (makeOverridable