From 94c4df6f57e8a89b3e2890fb67b4235629b99108 Mon Sep 17 00:00:00 2001 From: Florian Franzen Date: Thu, 14 Feb 2019 20:26:05 +0100 Subject: [PATCH 1/2] maintainers: add FlorianFranzen (Florian Franzen) --- maintainers/maintainer-list.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index a56c8819dddd..9827766f1fba 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -1535,6 +1535,11 @@ github = "flokli"; name = "Florian Klink"; }; + FlorianFranzen = { + email = "Florian.Franzen@gmail.com"; + github = "FlorianFranzen"; + name = "Florian Franzen"; + }; florianjacob = { email = "projects+nixos@florianjacob.de"; github = "florianjacob"; From c62202c2d8f4818a797e840554b747a6aaa80063 Mon Sep 17 00:00:00 2001 From: Florian Franzen Date: Thu, 14 Feb 2019 20:17:00 +0100 Subject: [PATCH 2/2] pythonPackages.scikit-build: init at 0.8.1 --- .../python-modules/scikit-build/default.nix | 43 +++++++++++++++++++ .../scikit-build/fix_pytestrunner_req.patch | 13 ++++++ pkgs/top-level/python-packages.nix | 2 + 3 files changed, 58 insertions(+) create mode 100644 pkgs/development/python-modules/scikit-build/default.nix create mode 100644 pkgs/development/python-modules/scikit-build/fix_pytestrunner_req.patch diff --git a/pkgs/development/python-modules/scikit-build/default.nix b/pkgs/development/python-modules/scikit-build/default.nix new file mode 100644 index 000000000000..b0300744b5cc --- /dev/null +++ b/pkgs/development/python-modules/scikit-build/default.nix @@ -0,0 +1,43 @@ +{ lib, buildPythonPackage, fetchPypi, wheel, setuptools, packaging +, cmake, ninja, cython, codecov, coverage, six, virtualenv, pathpy +, pytest, pytestcov, pytest-virtualenv, pytest-mock, pytestrunner +, requests, flake8 }: + +buildPythonPackage rec { + pname = "scikit-build"; + version = "0.8.1"; + + src = fetchPypi { + inherit pname version; + sha256 = "1hh275lj98wgwi53mr9fqk8wh1dajjksch52xjax6a79gld4391a"; + }; + + # Fixes incorrect specified requirement (part of next release) + patches = [ ./fix_pytestrunner_req.patch ]; + + propagatedBuildInputs = [ wheel setuptools packaging ]; + checkInputs = [ + cmake ninja cython codecov coverage six virtualenv pathpy + pytest pytestcov pytest-mock pytest-virtualenv pytestrunner + requests flake8 + ]; + + disabledTests = lib.concatMapStringsSep " and " (s: "not " + s) ([ + "test_hello_develop" # tries setuptools develop install + "test_wheel" # pip has no way to install missing dependencies + "test_fortran_compiler" # passes if gfortran is available + "test_install_command" # tries to alter out path + "test_test_command" # tries to alter out path + ]); + + checkPhase = '' + py.test -k '${disabledTests}' + ''; + + meta = with lib; { + homepage = http://scikit-build.org/; + description = "Improved build system generator for CPython C/C++/Fortran/Cython extensions"; + license = with licenses; [ mit bsd2 ]; # BSD due to reuses of PyNE code + maintainers = [ maintainers.FlorianFranzen ]; + }; +} diff --git a/pkgs/development/python-modules/scikit-build/fix_pytestrunner_req.patch b/pkgs/development/python-modules/scikit-build/fix_pytestrunner_req.patch new file mode 100644 index 000000000000..e8e19f84a5d4 --- /dev/null +++ b/pkgs/development/python-modules/scikit-build/fix_pytestrunner_req.patch @@ -0,0 +1,13 @@ +diff --git a/setup.py b/setup.py +index dd348fa..4de89c6 100755 +--- a/setup.py ++++ b/setup.py +@@ -22,7 +22,7 @@ with open('requirements-dev.txt', 'r') as fp: + dev_requirements = list(filter(bool, (line.strip() for line in fp))) + + # Require pytest-runner only when running tests +-pytest_runner = (['pytest-runner>=2.0,<3dev'] ++pytest_runner = (['pytest-runner>=2.0'] + if any(arg in sys.argv for arg in ('pytest', 'test')) + else []) + diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 46f5e6c7f100..e1980cb6faff 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -3987,6 +3987,8 @@ in { scikit-bio = callPackage ../development/python-modules/scikit-bio { }; + scikit-build = callPackage ../development/python-modules/scikit-build { }; + scp = callPackage ../development/python-modules/scp {}; seaborn = callPackage ../development/python-modules/seaborn { };