python310Packages.measurement: Fix build
This commit is contained in:
parent
cd5d83212a
commit
864941a5a8
|
@ -1,9 +1,18 @@
|
||||||
{ lib, fetchFromGitHub, buildPythonPackage, isPy3k
|
{ lib
|
||||||
, sympy, pytest, pytest-runner, sphinx, setuptools-scm }:
|
, fetchFromGitHub
|
||||||
|
, buildPythonPackage
|
||||||
|
, isPy3k
|
||||||
|
, flit-core
|
||||||
|
, flit-scm
|
||||||
|
, sympy
|
||||||
|
, pytestCheckHook
|
||||||
|
, sphinx
|
||||||
|
}:
|
||||||
|
|
||||||
buildPythonPackage rec {
|
buildPythonPackage rec {
|
||||||
pname = "measurement";
|
pname = "measurement";
|
||||||
version = "3.2.2";
|
version = "3.2.2";
|
||||||
|
format = "pyproject";
|
||||||
|
|
||||||
disabled = !isPy3k;
|
disabled = !isPy3k;
|
||||||
|
|
||||||
|
@ -14,17 +23,31 @@ buildPythonPackage rec {
|
||||||
hash = "sha256-ULId0W10FaAtSgVY5ctQL3FPETVr+oq6TKWd/W53viM=";
|
hash = "sha256-ULId0W10FaAtSgVY5ctQL3FPETVr+oq6TKWd/W53viM=";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
nativeBuildInputs = [
|
||||||
|
flit-core
|
||||||
|
flit-scm
|
||||||
|
sphinx
|
||||||
|
];
|
||||||
|
|
||||||
|
SETUPTOOLS_SCM_PRETEND_VERSION = version;
|
||||||
|
|
||||||
postPatch = ''
|
postPatch = ''
|
||||||
sed -i 's|use_scm_version=True|version="${version}"|' setup.py
|
substituteInPlace pyproject.toml \
|
||||||
|
--replace "--cov=measurement" ""
|
||||||
'';
|
'';
|
||||||
|
|
||||||
nativeCheckInputs = [ pytest pytest-runner ];
|
propagatedBuildInputs = [
|
||||||
nativeBuildInputs = [ sphinx setuptools-scm ];
|
sympy
|
||||||
propagatedBuildInputs = [ sympy ];
|
];
|
||||||
|
|
||||||
|
nativeCheckInputs = [
|
||||||
|
pytestCheckHook
|
||||||
|
];
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "Use and manipulate unit-aware measurement objects in Python";
|
description = "Use and manipulate unit-aware measurement objects in Python";
|
||||||
homepage = "https://github.com/coddingtonbear/python-measurement";
|
homepage = "https://github.com/coddingtonbear/python-measurement";
|
||||||
|
changelog = "https://github.com/coddingtonbear/python-measurement/releases/tag/${version}";
|
||||||
license = licenses.mit;
|
license = licenses.mit;
|
||||||
maintainers = with maintainers; [ bhipple ];
|
maintainers = with maintainers; [ bhipple ];
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue