nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5 psutil,
6 unittestCheckHook,
7 setuptools,
8}:
9
10buildPythonPackage rec {
11 pname = "pyperf";
12 version = "2.9.0";
13 pyproject = true;
14
15 src = fetchPypi {
16 inherit pname version;
17 hash = "sha256-2+D+747BpGXfGRu6JXYUl2LRWoyZhcn+qTq2Jdh1w2I=";
18 };
19
20 nativeBuildInputs = [ setuptools ];
21
22 propagatedBuildInputs = [ psutil ];
23
24 nativeCheckInputs = [ unittestCheckHook ];
25
26 unittestFlagsArray = [
27 "-s"
28 "pyperf/tests/"
29 "-v"
30 ];
31
32 pythonImportsCheck = [ "pyperf" ];
33
34 meta = {
35 description = "Python module to generate and modify perf";
36 mainProgram = "pyperf";
37 homepage = "https://pyperf.readthedocs.io/";
38 changelog = "https://github.com/psf/pyperf/releases/tag/${version}";
39 license = lib.licenses.mit;
40 maintainers = [ ];
41 };
42}