mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-15 00:24:47 +00:00
python312Packages.mrsqm: fix build (#362775)
This commit is contained in:
commit
8627d7ada9
@ -1,47 +1,73 @@
|
||||
{
|
||||
lib,
|
||||
buildPythonPackage,
|
||||
fetchPypi,
|
||||
fetchFromGitHub,
|
||||
pythonOlder,
|
||||
cython,
|
||||
fftw,
|
||||
pandas,
|
||||
scikit-learn,
|
||||
numpy,
|
||||
pip,
|
||||
setuptools,
|
||||
pytestCheckHook,
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "mrsqm";
|
||||
version = "0.0.7";
|
||||
format = "setuptools";
|
||||
pyproject = true;
|
||||
|
||||
build-system = [
|
||||
setuptools
|
||||
];
|
||||
|
||||
disabled = pythonOlder "3.8";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
hash = "sha256-kZwgRazvPCmARcfhLByh1E8VPurrb8gVZc96hFfDOvs=";
|
||||
src = fetchFromGitHub {
|
||||
owner = "mlgig";
|
||||
repo = "mrsqm";
|
||||
tag = "v.${version}";
|
||||
hash = "sha256-5K6vCU0HExnmYNThZNDCbEtII9bUGauxDtKkJXe/85Q=";
|
||||
};
|
||||
|
||||
buildInputs = [ fftw ];
|
||||
|
||||
nativeBuildInputs = [ cython ];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
dependencies = [
|
||||
pandas
|
||||
scikit-learn
|
||||
numpy
|
||||
pip
|
||||
];
|
||||
|
||||
# Package has no tests
|
||||
doCheck = false;
|
||||
postPatch = ''
|
||||
substituteInPlace setup.py \
|
||||
--replace-fail "'pytest-runner'" ""
|
||||
substituteInPlace pyproject.toml \
|
||||
--replace-fail "numpy==" "numpy>="
|
||||
'';
|
||||
|
||||
preBuild = ''
|
||||
export HOME=$(mktemp -d)
|
||||
'';
|
||||
|
||||
nativeCheckInputs = [
|
||||
pytestCheckHook
|
||||
];
|
||||
|
||||
pytestFlagsArray = [
|
||||
"tests/mrsqm"
|
||||
];
|
||||
|
||||
pythonImportsCheck = [ "mrsqm" ];
|
||||
|
||||
meta = with lib; {
|
||||
meta = {
|
||||
description = "MrSQM (Multiple Representations Sequence Miner) is a time series classifier";
|
||||
homepage = "https://pypi.org/project/mrsqm";
|
||||
changelog = "https://github.com/mlgig/mrsqm/releases/tag/v.${version}";
|
||||
license = licenses.gpl3Only;
|
||||
maintainers = with maintainers; [ mbalatsko ];
|
||||
license = lib.licenses.gpl3Only;
|
||||
maintainers = with lib.maintainers; [ mbalatsko ];
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user