Unverified Commit 8650fbe5 authored by TomaSajt's avatar TomaSajt
Browse files

python312Packages.accupy: use pyproject = true

parent 659e3ce3
Loading
Loading
Loading
Loading
+12 −7
Original line number Diff line number Diff line
@@ -3,6 +3,7 @@
, buildPythonPackage
, fetchFromGitHub
, pythonOlder
, setuptools
, mpmath
, numpy
, pybind11
@@ -18,17 +19,19 @@
buildPythonPackage rec {
  pname = "accupy";
  version = "0.3.6";
  format = "setuptools";
  pyproject = true;

  disabled = pythonOlder "3.7";

  src = fetchFromGitHub {
    owner = "nschloe";
    repo = pname;
    repo = "accupy";
    rev = version;
    sha256 = "0sxkwpp2xy2jgakhdxr4nh1cspqv8l89kz6s832h05pbpyc0n767";
    hash = "sha256-xxwLmL/rFgDFQNr8mRBFG1/NArQk9wanelL4Lu7ls2s=";
  };

  nativeBuildInputs = [
  build-system = [
    setuptools
    pybind11
  ];

@@ -36,7 +39,7 @@ buildPythonPackage rec {
    eigen
  ];

  propagatedBuildInputs = [
  dependencies = [
    mpmath
    numpy
    pyfma
@@ -51,7 +54,7 @@ buildPythonPackage rec {

  postConfigure = ''
   substituteInPlace setup.py \
     --replace "/usr/include/eigen3/" "${eigen}/include/eigen3/"
     --replace-fail "/usr/include/eigen3/" "${eigen}/include/eigen3/"
  '';

  preBuild = ''
@@ -66,10 +69,12 @@ buildPythonPackage rec {
  # decouple ourselves from an unnecessary build dep
  preCheck = ''
    for f in test/test*.py ; do
      substituteInPlace $f --replace 'import perfplot' ""
      substituteInPlace $f --replace-quiet 'import perfplot' ""
    done
  '';

  disabledTests = [ "test_speed_comparison1" "test_speed_comparison2" ];

  pythonImportsCheck = [ "accupy" ];

  meta = with lib; {