mirror of
https://github.com/zebrajr/pytorch.git
synced 2025-12-06 12:20:52 +01:00
Revert "[ROCm] Use -rpath-link to fix libtinfo conflict (#83552)"
This reverts commit a10446c4d8.
Reverted https://github.com/pytorch/pytorch/pull/83552 on behalf of https://github.com/kit1980 due to Broke ios/macos builds https://github.com/pytorch/pytorch/actions/runs/3329991911/jobs/5507911292
This commit is contained in:
parent
701b3dd773
commit
ac0c13f665
|
|
@ -1270,21 +1270,6 @@ endif()
|
|||
|
||||
# ---[ HIP
|
||||
if(USE_ROCM)
|
||||
# This prevents linking in the libtinfo from /opt/conda/lib which conflicts with ROCm libtinfo.
|
||||
# Currently only active for Ubuntu 20.04 and greater versions.
|
||||
if(UNIX)
|
||||
file(STRINGS /etc/os-release OS_RELEASE)
|
||||
string(REGEX REPLACE "NAME=\"([A-Za-z]+).*" "\\1" OS_DISTRO ${OS_RELEASE})
|
||||
string(REGEX REPLACE ".*VERSION_ID=\"([0-9\.]+).*" "\\1" OS_VERSION ${OS_RELEASE})
|
||||
if(OS_DISTRO STREQUAL "Ubuntu" AND OS_VERSION VERSION_GREATER_EQUAL "20.04")
|
||||
find_library(LIBTINFO_LOC tinfo NO_CMAKE_PATH NO_CMAKE_ENVIRONMENT_PATH)
|
||||
if(LIBTINFO_LOC)
|
||||
get_filename_component(LIBTINFO_LOC_PARENT ${LIBTINFO_LOC} DIRECTORY)
|
||||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-rpath-link,${LIBTINFO_LOC_PARENT}")
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
include(${CMAKE_CURRENT_LIST_DIR}/public/LoadHIP.cmake)
|
||||
if(PYTORCH_FOUND_HIP)
|
||||
message(INFO "Compiling with HIP for AMD.")
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user