git.iko.soy/typeable/nixpkgs
on master help sign in
pythonPackages.tensorflow: Don't change the rpath to point to gcc4.9

When using cuda, the rpath was set to include GCC lib version 4.9. I am not sure what this was attempting to do, but an effect was to prevent certain python libraries to find the correct (newer) version of the std lib. Also avoid mentions of any specifc version in the propagatedBuildInputs

commit1fdf42d4612b6872a2625b3ba2f8750263281312 authorJean-Philippe Bernardy <jeanphilippe.bernardy@gmail.com> dateMon 29 May 2017, 19:24 (9 years ago) parent1d56c2f
1 file changed+3−6
pkgs/development/python-modules/tensorflow/default.nix+3−6
pkgs/development/python-modules/tensorflow/default.nix+3−6
@@ -5,7 +5,6 @@
55, cudaSupport ? false
66, cudatoolkit ? null
77, cudnn ? null
8−, gcc49 ? null
98, linuxPackages ? null
109, numpy
1110, six
@@ -13,13 +12,11 @@
1312, swig
1413, werkzeug
1514, mock
16−, gcc
1715, zlib
1816}:
1917
2018assert cudaSupport -> cudatoolkit != null
2119 && cudnn != null
22− && gcc49 != null
2320 && linuxPackages != null;
2421
2522# unsupported combination
@@ -98,7 +95,7 @@ buildPythonPackage rec {
9895
9996 propagatedBuildInputs = with stdenv.lib;
10097 [ numpy six protobuf3_2 swig werkzeug mock ]
101− ++ optionals cudaSupport [ cudatoolkit cudnn gcc49 ];
98+ ++ optionals cudaSupport [ cudatoolkit cudnn stdenv.cc ];
10299
103100 # Note that we need to run *after* the fixup phase because the
104101 # libraries are loaded at runtime. If we run in preFixup then
@@ -106,10 +103,10 @@ buildPythonPackage rec {
106103 postFixup = let
107104 rpath = stdenv.lib.makeLibraryPath
108105 (if cudaSupport then
109− [ gcc49.cc.lib zlib cudatoolkit cudnn
106+ [ stdenv.cc.cc.lib zlib cudatoolkit cudnn
110107 linuxPackages.nvidia_x11 ]
111108 else
112− [ gcc.cc.lib zlib ]
109+ [ stdenv.cc.cc.lib zlib ]
113110 );
114111 in
115112 ''