diff --git a/pkgs/development/interpreters/python/cpython/3.5/default.nix b/pkgs/development/interpreters/python/cpython/3.5/default.nix index d67cc7286942..c6d572aca164 100644 --- a/pkgs/development/interpreters/python/cpython/3.5/default.nix +++ b/pkgs/development/interpreters/python/cpython/3.5/default.nix @@ -67,6 +67,12 @@ in stdenv.mkDerivation { patches = [ ./no-ldconfig.patch ./ld_library_path.patch + ] ++ optionals stdenv.isDarwin [ + # Fix for https://bugs.python.org/issue24658 + (fetchpatch { + url = "https://bugs.python.org/file45178/issue24658-3-3.6.diff"; + sha256 = "1x060hs80nl34mcl2ji2i7l4shxkmxwgq8h8lcmav8rjqqz1nb4a"; + }) ] ++ optionals (x11Support && stdenv.isDarwin) [ ./use-correct-tcl-tk-on-darwin.patch ]; diff --git a/pkgs/development/interpreters/python/cpython/3.6/default.nix b/pkgs/development/interpreters/python/cpython/3.6/default.nix index ee9a0df9a8c4..e5e05c0ac7a3 100644 --- a/pkgs/development/interpreters/python/cpython/3.6/default.nix +++ b/pkgs/development/interpreters/python/cpython/3.6/default.nix @@ -69,6 +69,12 @@ in stdenv.mkDerivation { patches = [ ./no-ldconfig.patch + ] ++ optionals stdenv.isDarwin [ + # Fix for https://bugs.python.org/issue24658 + (fetchpatch { + url = "https://bugs.python.org/file45178/issue24658-3-3.6.diff"; + sha256 = "1x060hs80nl34mcl2ji2i7l4shxkmxwgq8h8lcmav8rjqqz1nb4a"; + }) ] ++ optionals (x11Support && stdenv.isDarwin) [ ./use-correct-tcl-tk-on-darwin.patch ];