summary refs log tree commit diff
path: root/pkgs/development/python-modules/lxml
diff options
context:
space:
mode:
authorJonathan Ringer <jonringer117@gmail.com>2019-10-21 08:57:20 -0700
committerFrederik Rietdijk <freddyrietdijk@fridh.nl>2019-10-22 08:54:48 +0200
commite1b6b9056d4001030b65ccea649b75b58c1e77d8 (patch)
treea1eb7744c5064104bc4d7a264488d454727a850f /pkgs/development/python-modules/lxml
parent5c388dcf85a44ef2825137cfcb283c99de89f530 (diff)
downloadnixpkgs-e1b6b9056d4001030b65ccea649b75b58c1e77d8.tar
nixpkgs-e1b6b9056d4001030b65ccea649b75b58c1e77d8.tar.gz
nixpkgs-e1b6b9056d4001030b65ccea649b75b58c1e77d8.tar.bz2
nixpkgs-e1b6b9056d4001030b65ccea649b75b58c1e77d8.tar.lz
nixpkgs-e1b6b9056d4001030b65ccea649b75b58c1e77d8.tar.xz
nixpkgs-e1b6b9056d4001030b65ccea649b75b58c1e77d8.tar.zst
nixpkgs-e1b6b9056d4001030b65ccea649b75b58c1e77d8.zip
pythonPackages.lxml: 4.3.3 -> 4.4.1
reduce closure size by not propagating native dependencies
Diffstat (limited to 'pkgs/development/python-modules/lxml')
-rw-r--r--pkgs/development/python-modules/lxml/default.nix32
1 files changed, 19 insertions, 13 deletions
diff --git a/pkgs/development/python-modules/lxml/default.nix b/pkgs/development/python-modules/lxml/default.nix
index f054f26a527..f2cc1663041 100644
--- a/pkgs/development/python-modules/lxml/default.nix
+++ b/pkgs/development/python-modules/lxml/default.nix
@@ -1,28 +1,34 @@
-{ stdenv
-, buildPythonPackage
-, fetchPypi
+{ stdenv, buildPythonPackage, fetchFromGitHub
+, cython
 , libxml2
 , libxslt
+, zlib
 }:
 
 buildPythonPackage rec {
   pname = "lxml";
-  version = "4.3.5";
+  version = "4.4.1";
 
-  src = fetchPypi {
-    inherit pname version;
-    sha256 = "738862e9724d201f1aa8394cb666d8136d666198e97d6e1e5c9876ad884a86b3";
+  src = fetchFromGitHub {
+    owner = pname;
+    repo = pname;
+    rev = "${pname}-${version}";
+    sha256 = "1hkl3bhbwiwwfb57nq9lr24rkp782ymfvqrdf9x1wifc79ivlbxw";
   };
 
-  nativeBuildInputs = [ libxml2.dev libxslt.dev ];
-  propagatedBuildInputs = [ libxml2 libxslt ];
+  # setuptoolsBuildPhase needs dependencies to be passed through nativeBuildInputs
+  nativeBuildInputs = [ libxml2.dev libxslt.dev cython ];
+  buildInputs = [ libxml2 libxslt zlib ];
 
-  hardeningDisable = stdenv.lib.optional stdenv.isDarwin "format";
+  # tests are meant to be ran "in-place" in the same directory as src
+  doCheck = false;
 
-  meta = {
+  pythonImportsCheck = [ "lxml" "lxml.etree" ];
+
+  meta = with stdenv.lib; {
     description = "Pythonic binding for the libxml2 and libxslt libraries";
     homepage = https://lxml.de;
-    license = stdenv.lib.licenses.bsd3;
-    maintainers = with stdenv.lib.maintainers; [ sjourdois ];
+    license = licenses.bsd3;
+    maintainers = with maintainers; [ jonringer sjourdois ];
   };
 }