about summary refs log tree commit diff
path: root/pkgs/development/python-modules/pymunk
diff options
context:
space:
mode:
authorAngus Trau <me@angus.ws>2021-07-16 10:19:41 +1000
committerAngus Trau <me@angus.ws>2021-07-16 19:35:36 +1000
commit443a880ccba0eaf78771c586df498a4f3fd8c47f (patch)
tree6658b2cb745feffe3ca7aa44263b210ccc91184e /pkgs/development/python-modules/pymunk
parent7c9470a0612d0e8f4988206794d1e66f1c6bf680 (diff)
python3Packages.pymunk: init at 6.0.0
Diffstat (limited to 'pkgs/development/python-modules/pymunk')
-rw-r--r--pkgs/development/python-modules/pymunk/default.nix36
1 files changed, 36 insertions, 0 deletions
diff --git a/pkgs/development/python-modules/pymunk/default.nix b/pkgs/development/python-modules/pymunk/default.nix
new file mode 100644
index 0000000000000..92918efa8ed88
--- /dev/null
+++ b/pkgs/development/python-modules/pymunk/default.nix
@@ -0,0 +1,36 @@
+{ lib
+, buildPythonPackage
+, fetchPypi
+, python
+, cffi
+, pytestCheckHook
+}:
+
+buildPythonPackage rec {
+  pname = "pymunk";
+  version = "6.0.0";
+
+  src = fetchPypi {
+    inherit pname version;
+    extension = "zip";
+    sha256 = "04jqqd2y0wzzkqppbl08vyzgbcpl5qj946w8da2ilypqdx7j2akp";
+  };
+
+  propagatedBuildInputs = [ cffi ];
+
+  preBuild = ''
+    ${python.interpreter} setup.py build_ext --inplace
+  '';
+
+  checkInputs = [ pytestCheckHook ];
+  pytestFlagsArray = [
+    "pymunk/tests"
+  ];
+
+  meta = with lib; {
+    description = "2d physics library";
+    homepage = "https://www.pymunk.org";
+    license = with licenses; [ mit ];
+    maintainers = with maintainers; [ angustrau ];
+  };
+}