From 22ffab00cc1a200debf8336b938c407b3393cf37 Mon Sep 17 00:00:00 2001 From: Dima Date: Mon, 25 Nov 2019 20:30:14 +0100 Subject: [PATCH] pythonPackages.m2crypto: conditional `typing` dep Since python 3.5 typing is included in the stdlib and as such this library should not be included and propagated for >=3.5. --- pkgs/development/python-modules/m2crypto/default.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/m2crypto/default.nix b/pkgs/development/python-modules/m2crypto/default.nix index cd9781dbc889..56e1de49f20a 100644 --- a/pkgs/development/python-modules/m2crypto/default.nix +++ b/pkgs/development/python-modules/m2crypto/default.nix @@ -1,7 +1,9 @@ { stdenv +, lib , fetchpatch , buildPythonPackage , fetchPypi +, pythonOlder , swig2 , openssl , typing @@ -28,7 +30,7 @@ buildPythonPackage rec { nativeBuildInputs = [ swig2 ]; buildInputs = [ swig2 openssl ]; - propagatedBuildInputs = [ typing ]; + propagatedBuildInputs = lib.optional (pythonOlder "3.5") typing; preConfigure = '' substituteInPlace setup.py --replace "self.openssl = '/usr'" "self.openssl = '${openssl.dev}'"