Files
nixpkgs/pkgs/development/python-modules/palace/default.nix
T
Ihar Hrachyshka 567e8dfd8e treewide: clean up 'meta = with' pattern
This commit was created by a combination of scripts and tools:
- an ast-grep script to prefix things in meta with `lib.`,
- a modified nixf-diagnose / nixf combination to remove unused `with
lib;`, and
- regular nixfmt.

Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
2025-12-10 18:09:49 +01:00

54 lines
1.1 KiB
Nix

{
lib,
buildPythonPackage,
fetchFromSourcehut,
pythonOlder,
cmake,
cython_0,
setuptools,
alure2,
}:
buildPythonPackage rec {
pname = "palace";
version = "0.2.5";
pyproject = true;
disabled = pythonOlder "3.6";
src = fetchFromSourcehut {
owner = "~cnx";
repo = "palace";
rev = version;
sha256 = "1z0m35y4v1bg6vz680pwdicm9ssryl0q6dm9hfpb8hnifmridpcj";
};
# Nix uses Release CMake configuration instead of what is assumed by palace.
postPatch = ''
substituteInPlace CMakeLists.txt \
--replace-fail IMPORTED_LOCATION_NOCONFIG IMPORTED_LOCATION_RELEASE \
--replace-fail "cmake_minimum_required(VERSION 2.6.0)" "cmake_minimum_required(VERSION 3.10)"
'';
build-system = [
cmake
cython_0
setuptools
];
dontUseCmakeConfigure = true;
propagatedBuildInputs = [ alure2 ];
doCheck = false; # FIXME: tests need an audio device
pythonImportsCheck = [ "palace" ];
meta = {
description = "Pythonic Audio Library and Codecs Environment";
homepage = "https://mcsinyx.gitlab.io/palace";
license = lib.licenses.lgpl3Plus;
maintainers = [ lib.maintainers.McSinyx ];
};
}