python312Packages.osmnx: 1.9.3 → 2.0.0 (#360529)
[NixPkgs.git] / pkgs / development / python-modules / pyhepmc / default.nix
blob1186d443a0a18eaff50ca231359269d0a8639266
2   lib,
3   buildPythonPackage,
4   fetchFromGitHub,
5   cmake,
6   setuptools,
7   setuptools-scm,
8   numpy,
9   pybind11,
10   wheel,
11   pytestCheckHook,
12   pythonOlder,
13   graphviz,
16 buildPythonPackage rec {
17   pname = "pyhepmc";
18   version = "2.14.0";
19   format = "pyproject";
21   disabled = pythonOlder "3.8";
23   src = fetchFromGitHub {
24     owner = "scikit-hep";
25     repo = pname;
26     rev = "refs/tags/v${version}";
27     hash = "sha256-yh02Z1nPGjghZYHkPBlClDEztq4VQsW3H+kuco/lBpk=";
28     fetchSubmodules = true;
29   };
31   nativeBuildInputs = [
32     cmake
33     setuptools
34     setuptools-scm
35     wheel
36   ];
38   buildInputs = [ pybind11 ];
40   propagatedBuildInputs = [ numpy ];
42   dontUseCmakeConfigure = true;
44   CMAKE_ARGS = [ "-DEXTERNAL_PYBIND11=ON" ];
46   preBuild = ''
47     export CMAKE_BUILD_PARALLEL_LEVEL="$NIX_BUILD_CORES"
48   '';
50   nativeCheckInputs = [
51     graphviz
52     pytestCheckHook
53   ];
55   pythonImportsCheck = [ "pyhepmc" ];
57   meta = with lib; {
58     description = "Easy-to-use Python bindings for HepMC3";
59     homepage = "https://github.com/scikit-hep/pyhepmc";
60     changelog = "https://github.com/scikit-hep/pyhepmc/releases/tag/v${version}";
61     license = licenses.bsd3;
62     maintainers = with maintainers; [ veprbl ];
63   };