29 buildPythonPackage rec {
31 version = "0.5.0.post1";
34 src = fetchFromGitHub {
37 rev = "refs/tags/v${version}";
38 fetchSubmodules = true;
39 hash = "sha256-Fpayc+MOpDUCdpoyJaIqSbMzuO0jYb6UN5ARFaxxOHk=";
42 patches = [ ./cmake-nanobind.patch ];
49 dontUseCmakeConfigure = true;
52 "--config=cmake.define.USE_SYSTEM_LIBSOXR=ON"
62 ++ lib.optionals (pythonOlder "3.11") [
68 ++ lib.optionals stdenv.hostPlatform.isDarwin [
69 # error: aligned deallocation function of type 'void (void *, std::align_val_t) noexcept' is only available on macOS 10.13 or newer
70 (darwinMinVersionHook "10.13")
74 dependencies = [ numpy ];
76 pythonImportsCheck = [ "soxr" ];
78 nativeCheckInputs = [ pytestCheckHook ];
81 description = "High quality, one-dimensional sample-rate conversion library";
82 homepage = "https://github.com/dofuuz/python-soxr/tree/main";
83 license = licenses.lgpl21Plus;
84 maintainers = with maintainers; [ hexa ];