From 12ba3bc6eb2592d02be952ae8f4114da1ab345d1 Mon Sep 17 00:00:00 2001 From: Dmitry Kalinkin Date: Fri, 17 Dec 2021 12:02:18 -0500 Subject: [PATCH] qt5.qtgamepad: add darwin support --- pkgs/development/libraries/qt-5/5.12/default.nix | 4 +++- pkgs/development/libraries/qt-5/5.14/default.nix | 3 +++ pkgs/development/libraries/qt-5/5.15/default.nix | 4 +++- pkgs/development/libraries/qt-5/modules/qtgamepad.nix | 5 +++-- 4 files changed, 12 insertions(+), 4 deletions(-) diff --git a/pkgs/development/libraries/qt-5/5.12/default.nix b/pkgs/development/libraries/qt-5/5.12/default.nix index a047b5b71081..ec4055d5916f 100644 --- a/pkgs/development/libraries/qt-5/5.12/default.nix +++ b/pkgs/development/libraries/qt-5/5.12/default.nix @@ -162,7 +162,9 @@ let qtconnectivity = callPackage ../modules/qtconnectivity.nix {}; qtdeclarative = callPackage ../modules/qtdeclarative.nix {}; qtdoc = callPackage ../modules/qtdoc.nix {}; - qtgamepad = callPackage ../modules/qtgamepad.nix {}; + qtgamepad = callPackage ../modules/qtgamepad.nix { + inherit (darwin.apple_sdk.frameworks) GameController; + }; qtgraphicaleffects = callPackage ../modules/qtgraphicaleffects.nix {}; qtimageformats = callPackage ../modules/qtimageformats.nix {}; qtlocation = callPackage ../modules/qtlocation.nix {}; diff --git a/pkgs/development/libraries/qt-5/5.14/default.nix b/pkgs/development/libraries/qt-5/5.14/default.nix index c12a20dd4daf..b09826ec9156 100644 --- a/pkgs/development/libraries/qt-5/5.14/default.nix +++ b/pkgs/development/libraries/qt-5/5.14/default.nix @@ -163,6 +163,9 @@ let qtconnectivity = callPackage ../modules/qtconnectivity.nix {}; qtdeclarative = callPackage ../modules/qtdeclarative.nix {}; qtdoc = callPackage ../modules/qtdoc.nix {}; + qtgamepad = callPackage ../modules/qtgamepad.nix { + inherit (darwin.apple_sdk.frameworks) GameController; + }; qtgraphicaleffects = callPackage ../modules/qtgraphicaleffects.nix {}; qtimageformats = callPackage ../modules/qtimageformats.nix {}; qtlocation = callPackage ../modules/qtlocation.nix {}; diff --git a/pkgs/development/libraries/qt-5/5.15/default.nix b/pkgs/development/libraries/qt-5/5.15/default.nix index 0b4fc4f1c5e2..650e4fd32bb9 100644 --- a/pkgs/development/libraries/qt-5/5.15/default.nix +++ b/pkgs/development/libraries/qt-5/5.15/default.nix @@ -125,7 +125,9 @@ let qtconnectivity = callPackage ../modules/qtconnectivity.nix {}; qtdeclarative = callPackage ../modules/qtdeclarative.nix {}; qtdoc = callPackage ../modules/qtdoc.nix {}; - qtgamepad = callPackage ../modules/qtgamepad.nix {}; + qtgamepad = callPackage ../modules/qtgamepad.nix { + inherit (darwin.apple_sdk.frameworks) GameController; + }; qtgraphicaleffects = callPackage ../modules/qtgraphicaleffects.nix {}; qtimageformats = callPackage ../modules/qtimageformats.nix {}; qtlocation = callPackage ../modules/qtlocation.nix {}; diff --git a/pkgs/development/libraries/qt-5/modules/qtgamepad.nix b/pkgs/development/libraries/qt-5/modules/qtgamepad.nix index 2e266060a341..147fb0745dbd 100644 --- a/pkgs/development/libraries/qt-5/modules/qtgamepad.nix +++ b/pkgs/development/libraries/qt-5/modules/qtgamepad.nix @@ -1,8 +1,9 @@ -{ qtModule, qtbase, qtdeclarative, pkg-config }: +{ lib, stdenv, qtModule, qtbase, qtdeclarative, GameController, pkg-config }: qtModule { pname = "qtgamepad"; - qtInputs = [ qtbase qtdeclarative ]; + qtInputs = [ qtbase qtdeclarative ] + ++ lib.optional stdenv.isDarwin GameController; buildInputs = [ ]; nativeBuildInputs = [ pkg-config ]; outputs = [ "out" "dev" "bin" ];