diff options
author | Marius Bakke <marius@gnu.org> | 2022-07-13 23:34:58 +0200 |
---|---|---|
committer | Marius Bakke <marius@gnu.org> | 2022-07-13 23:34:58 +0200 |
commit | 4442a5db773f79e05c37e014c63b4298e7de666b (patch) | |
tree | 880a6fdce7b288eaa506828b9b500191ca60ce24 /gnu/packages/patches/python-pytorch-runpath.patch | |
parent | 5b48591176a08bddfd0147bd854785fb4f6a62ba (diff) | |
parent | b160795a0b65d67ff5d64447f1b97c2f009517a0 (diff) | |
download | guix-4442a5db773f79e05c37e014c63b4298e7de666b.tar.gz |
Merge branch 'master' into staging
Diffstat (limited to 'gnu/packages/patches/python-pytorch-runpath.patch')
-rw-r--r-- | gnu/packages/patches/python-pytorch-runpath.patch | 25 |
1 files changed, 15 insertions, 10 deletions
diff --git a/gnu/packages/patches/python-pytorch-runpath.patch b/gnu/packages/patches/python-pytorch-runpath.patch index 6f270ef9b1..7f95b88a2b 100644 --- a/gnu/packages/patches/python-pytorch-runpath.patch +++ b/gnu/packages/patches/python-pytorch-runpath.patch @@ -2,6 +2,21 @@ Libraries (such as 'libtorch_cpu.so') and executables (such as 'torch_shm_manage get installed, quite surprisingly, to 'lib/python3.8/site-packages/{bin,lib}'. Make sure RUNPATH matches that. +diff --git a/caffe2/CMakeLists.txt b/caffe2/CMakeLists.txt +index 5b5622f0..30d27e57 100644 +--- a/caffe2/CMakeLists.txt ++++ b/caffe2/CMakeLists.txt +@@ -1909,7 +1909,7 @@ if(BUILD_PYTHON) + if(${BUILDING_WITH_TORCH_LIBS}) + # site-packages/caffe2/python/caffe2_pybind11_state + # site-packages/torch/lib +- set(caffe2_pybind11_rpath "${_rpath_portable_origin}/../../torch/lib") ++ set(caffe2_pybind11_rpath $ORIGIN/../../torch/lib) + endif(${BUILDING_WITH_TORCH_LIBS}) + + # Must also include `CMAKE_SHARED_LINKER_FLAGS` in linker flags for +diff --git a/cmake/Dependencies.cmake b/cmake/Dependencies.cmake +index ee9cf410..f190e69b 100644 --- a/cmake/Dependencies.cmake +++ b/cmake/Dependencies.cmake @@ -4,7 +4,7 @@ if(APPLE) @@ -13,13 +28,3 @@ Make sure RUNPATH matches that. endif(APPLE) # Use separate rpaths during build and install phases set(CMAKE_SKIP_BUILD_RPATH FALSE) - ---- a/caffe2/CMakeLists.txt -+++ b/caffe2/CMakeLists.txt -@@ -1797,5 +1797,5 @@ if(BUILD_PYTHON) - if(${BUILDING_WITH_TORCH_LIBS}) - # site-packages/caffe2/python/caffe2_pybind11_state - # site-packages/torch/lib -- set(caffe2_pybind11_rpath "${_rpath_portable_origin}/../../torch/lib") -+ set(caffe2_pybind11_rpath $ORIGIN/../../torch/lib) - endif(${BUILDING_WITH_TORCH_LIBS}) |