From 54809f955cd9aa6d77ca7695b80952f95770cb39 Mon Sep 17 00:00:00 2001 From: linsui Date: Tue, 9 Jul 2024 19:53:08 +0800 Subject: [PATCH 1/3] friture: format --- pkgs/applications/audio/friture/default.nix | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/audio/friture/default.nix b/pkgs/applications/audio/friture/default.nix index b42cfb05c7fa..d8eff7fa7768 100644 --- a/pkgs/applications/audio/friture/default.nix +++ b/pkgs/applications/audio/friture/default.nix @@ -1,4 +1,9 @@ -{ lib, fetchFromGitHub, python3Packages, wrapQtAppsHook }: +{ + lib, + fetchFromGitHub, + python3Packages, + wrapQtAppsHook, +}: python3Packages.buildPythonApplication rec { pname = "friture"; @@ -11,8 +16,13 @@ python3Packages.buildPythonApplication rec { sha256 = "sha256-xKgyBV/Qc+9PgXyxcT0xG1GXLC6KnjavJ/0SUE+9VSY="; }; - nativeBuildInputs = (with python3Packages; [ numpy cython scipy ]) ++ - [ wrapQtAppsHook ]; + nativeBuildInputs = + (with python3Packages; [ + numpy + cython + scipy + ]) + ++ [ wrapQtAppsHook ]; propagatedBuildInputs = with python3Packages; [ sounddevice @@ -53,6 +63,9 @@ python3Packages.buildPythonApplication rec { homepage = "https://friture.org/"; license = licenses.gpl3; platforms = platforms.linux; # fails on Darwin - maintainers = with maintainers; [ laikq alyaeanyx ]; + maintainers = with maintainers; [ + laikq + alyaeanyx + ]; }; } From b393dadc923a231b973662a315181f3ac8fa0486 Mon Sep 17 00:00:00 2001 From: linsui Date: Tue, 9 Jul 2024 19:55:29 +0800 Subject: [PATCH 2/3] friture: 0.49 -> 0.49-unstable-2024-06-02 --- pkgs/applications/audio/friture/default.nix | 25 +++++++++++-------- .../pyopengl-accelerate/default.nix | 1 - pkgs/top-level/all-packages.nix | 4 +-- 3 files changed, 17 insertions(+), 13 deletions(-) diff --git a/pkgs/applications/audio/friture/default.nix b/pkgs/applications/audio/friture/default.nix index d8eff7fa7768..a0649dd72803 100644 --- a/pkgs/applications/audio/friture/default.nix +++ b/pkgs/applications/audio/friture/default.nix @@ -2,27 +2,37 @@ lib, fetchFromGitHub, python3Packages, - wrapQtAppsHook, + qt5, }: python3Packages.buildPythonApplication rec { pname = "friture"; - version = "0.49"; + version = "0.49-unstable-2024-06-02"; + pyproject = true; src = fetchFromGitHub { owner = "tlecomte"; repo = pname; - rev = "v${version}"; - sha256 = "sha256-xKgyBV/Qc+9PgXyxcT0xG1GXLC6KnjavJ/0SUE+9VSY="; + rev = "405bffa585ece0cb535c32d0f4f6ace932b40103"; + hash = "sha256-4xvIlRuJ7WCFj1dEyvO9UOsye70nFlWjb9XU0owwgiM="; }; + pythonRelaxDeps = true; + + postPatch = '' + sed -i -e '/packages=\[/a "friture.playback",' pyproject.toml + ''; + nativeBuildInputs = (with python3Packages; [ numpy cython scipy + setuptools ]) - ++ [ wrapQtAppsHook ]; + ++ (with qt5; [ wrapQtAppsHook ]); + + buildInputs = with qt5; [ qtquickcontrols2 ]; propagatedBuildInputs = with python3Packages; [ sounddevice @@ -36,11 +46,6 @@ python3Packages.buildPythonApplication rec { rtmixer ]; - postPatch = '' - # Remove version constraints from Python dependencies in setup.py - sed -i -E "s/\"([A-Za-z0-9]+)(=|>|<)=[0-9\.]+\"/\"\1\"/g" setup.py - ''; - preFixup = '' makeWrapperArgs+=("''${qtWrapperArgs[@]}") ''; diff --git a/pkgs/development/python-modules/pyopengl-accelerate/default.nix b/pkgs/development/python-modules/pyopengl-accelerate/default.nix index d452ff22af1e..f32d555d7589 100644 --- a/pkgs/development/python-modules/pyopengl-accelerate/default.nix +++ b/pkgs/development/python-modules/pyopengl-accelerate/default.nix @@ -1,7 +1,6 @@ { lib, buildPythonPackage, - pythonAtLeast, fetchPypi, cython, numpy, diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index d48e0156367b..d31347f808e5 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -30899,8 +30899,8 @@ with pkgs; freerdpUnstable = freerdp; - friture = libsForQt5.callPackage ../applications/audio/friture { - python3Packages = python39Packages; + friture = callPackage ../applications/audio/friture { + python3Packages = python311Packages; }; g933-utils = callPackage ../tools/misc/g933-utils { }; From 74d3ca7f57d5f570da6d2dbcad59be978f6f8a2e Mon Sep 17 00:00:00 2001 From: linsui Date: Tue, 9 Jul 2024 20:00:31 +0800 Subject: [PATCH 3/3] friture: move to by-name --- .../friture/default.nix => by-name/fr/friture/package.nix} | 0 pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) rename pkgs/{applications/audio/friture/default.nix => by-name/fr/friture/package.nix} (100%) diff --git a/pkgs/applications/audio/friture/default.nix b/pkgs/by-name/fr/friture/package.nix similarity index 100% rename from pkgs/applications/audio/friture/default.nix rename to pkgs/by-name/fr/friture/package.nix diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index d31347f808e5..ecbf6b3645a6 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -30899,7 +30899,7 @@ with pkgs; freerdpUnstable = freerdp; - friture = callPackage ../applications/audio/friture { + friture = callPackage ../by-name/fr/friture/package.nix { python3Packages = python311Packages; };