diff --git a/pkgs/applications/networking/maestral-qt/default.nix b/pkgs/applications/networking/maestral-qt/default.nix index 9b87073f3f41..2e6ab8bd01f6 100644 --- a/pkgs/applications/networking/maestral-qt/default.nix +++ b/pkgs/applications/networking/maestral-qt/default.nix @@ -5,21 +5,41 @@ , nixosTests }: -python3.pkgs.buildPythonApplication rec { +let + inherit (pypkgs) makePythonPath; + + pypkgs = (python3.override { + packageOverrides = self: super: { + # Use last available version of maestral that still supports PyQt5 + # Remove this override when PyQt6 is available + maestral = super.maestral.overridePythonAttrs (old: rec { + version = "1.5.3"; + src = fetchFromGitHub { + owner = "SamSchott"; + repo = "maestral"; + rev = "refs/tags/v${version}"; + hash = "sha256-Uo3vcYez2qSq162SSKjoCkwygwR5awzDceIq8/h3dao="; + }; + }); + }; + }).pkgs; + +in +pypkgs.buildPythonApplication rec { pname = "maestral-qt"; version = "1.5.3"; - disabled = python3.pkgs.pythonOlder "3.6"; + disabled = pypkgs.pythonOlder "3.6"; src = fetchFromGitHub { owner = "SamSchott"; repo = "maestral-qt"; - rev = "v${version}"; + rev = "refs/tags/v${version}"; sha256 = "sha256-zaG9Zwz9S/SVb7xDa7eXkjLNt1BhA1cQ3I18rVt+8uQ="; }; format = "pyproject"; - propagatedBuildInputs = with python3.pkgs; [ + propagatedBuildInputs = with pypkgs; [ click markdown2 maestral @@ -36,8 +56,8 @@ python3.pkgs.buildPythonApplication rec { "\${qtWrapperArgs[@]}" # Add the installed directories to the python path so the daemon can find them - "--prefix" "PYTHONPATH" ":" "${lib.concatStringsSep ":" (map (p: p + "/lib/${python3.libPrefix}/site-packages") (python3.pkgs.requiredPythonModules python3.pkgs.maestral.propagatedBuildInputs))}" - "--prefix" "PYTHONPATH" ":" "${python3.pkgs.maestral}/lib/${python3.libPrefix}/site-packages" + "--prefix PYTHONPATH : ${makePythonPath (pypkgs.requiredPythonModules pypkgs.maestral.propagatedBuildInputs)}" + "--prefix PYTHONPATH : ${makePythonPath [ pypkgs.maestral ]}" ]; # no tests