python3Packages.tensorflowWithCuda: fix patchelf failures

This commit is contained in:
Thomas Watson
2021-11-26 16:26:50 +00:00
parent 449c0a1d22
commit f5798c8f3d
2 changed files with 6 additions and 3 deletions
@@ -1,5 +1,5 @@
{ stdenv, bazel_3, buildBazelPackage, isPy3k, lib, fetchFromGitHub, symlinkJoin
, addOpenGLRunpath, fetchpatch
, addOpenGLRunpath, fetchpatch, patchelfUnstable
# Python deps
, buildPythonPackage, pythonOlder, python
# Python libraries
@@ -465,7 +465,8 @@ in buildPythonPackage {
tensorflow-tensorboard
];
nativeBuildInputs = lib.optional cudaSupport addOpenGLRunpath;
# remove patchelfUnstable once patchelf 0.14 with https://github.com/NixOS/patchelf/pull/256 becomes the default
nativeBuildInputs = lib.optional cudaSupport [ addOpenGLRunpath patchelfUnstable ];
postFixup = lib.optionalString cudaSupport ''
find $out -type f \( -name '*.so' -or -name '*.so.*' \) | while read lib; do