at master 1.1 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 rustPlatform, 6 pytestCheckHook, 7 8 numpy, 9}: 10 11buildPythonPackage rec { 12 pname = "pcodec"; 13 version = "0.4.6"; 14 pyproject = true; 15 16 src = fetchFromGitHub { 17 owner = "pcodec"; 18 repo = "pcodec"; 19 tag = "v${version}"; 20 hash = "sha256-5NB+PoCS6yGT8N+MD4mdMRRMKCmlQcqdFPTW924UVgU="; 21 }; 22 23 cargoDeps = rustPlatform.fetchCargoVendor { 24 inherit pname version src; 25 hash = "sha256-vHADxRV9DOYhUg3IOm1HNk3RHB0/WKluD2PH3Hg8k7s="; 26 }; 27 28 buildAndTestSubdir = "pco_python"; 29 30 dependencies = [ numpy ]; 31 32 nativeBuildInputs = [ 33 rustPlatform.cargoSetupHook 34 rustPlatform.maturinBuildHook 35 ]; 36 37 nativeCheckInputs = [ 38 pytestCheckHook 39 ]; 40 41 pythonImportsCheck = [ "pcodec" ]; 42 43 meta = { 44 description = "Lossless codec for numerical data"; 45 homepage = "https://github.com/pcodec/pcodec"; 46 changelog = "https://github.com/pcodec/pcodec/releases/tag/v${version}"; 47 license = lib.licenses.asl20; 48 maintainers = with lib.maintainers; [ 49 flokli 50 ]; 51 badPlatforms = [ 52 # Illegal instruction: 4 53 "x86_64-darwin" 54 ]; 55 }; 56}