python3Packages.pytorch: Avoid duplicating libraries between $lib and $out

This commit is contained in:
Kevin Mehall 2021-11-03 23:39:43 +00:00
parent 9c6aecf304
commit 5045795197

View file

@ -276,7 +276,8 @@ in buildPythonPackage rec {
--replace \''${_IMPORT_PREFIX}/lib "$lib/lib"
mkdir $lib
cp -r $out/${python.sitePackages}/torch/lib $lib/lib
mv $out/${python.sitePackages}/torch/lib $lib/lib
ln -s $lib/lib $out/${python.sitePackages}/torch/lib
'';
postFixup = lib.optionalString stdenv.isDarwin ''