about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/canmatrix/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/canmatrix/default.nix')
-rw-r--r--nixpkgs/pkgs/development/python-modules/canmatrix/default.nix45
1 files changed, 45 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/canmatrix/default.nix b/nixpkgs/pkgs/development/python-modules/canmatrix/default.nix
new file mode 100644
index 000000000000..3e07188986d0
--- /dev/null
+++ b/nixpkgs/pkgs/development/python-modules/canmatrix/default.nix
@@ -0,0 +1,45 @@
+{ lib
+, buildPythonPackage
+, fetchFromGitHub
+, python
+, lxml
+, xlwt
+, xlrd
+, XlsxWriter
+, pyyaml
+, future }:
+
+buildPythonPackage rec {
+  pname = "canmatrix";
+  version = "0.6";
+
+  # uses fetchFromGitHub as PyPi release misses test/ dir
+  src = fetchFromGitHub {
+    owner = "ebroecker";
+    repo = pname;
+    rev = version;
+    sha256 = "1lb0krhchja2jqfsh5lsfgmqcchs1pd38akvc407jfmll96f4yqz";
+  };
+
+  checkPhase = ''
+    cd test
+    ${python.interpreter} ./test.py
+  '';
+
+  propagatedBuildInputs =
+    [ lxml
+      xlwt
+      xlrd
+      XlsxWriter
+      pyyaml
+      future
+    ];
+
+  meta = with lib; {
+    homepage = https://github.com/ebroecker/canmatrix;
+    description = "Support and convert several CAN (Controller Area Network) database formats .arxml .dbc .dbf .kcd .sym fibex xls(x)";
+    license = licenses.bsd2;
+    maintainers = with maintainers; [ sorki ];
+  };
+}
+