Skip to content

Commit

Permalink
Merge pull request ROCm#58 from ROCm-Developer-Tools/rocmaster-backport
Browse files Browse the repository at this point in the history
Rocmaster backport
  • Loading branch information
jsjodin authored Dec 12, 2019
2 parents 8f6f0c1 + e057ba8 commit 75b29d3
Showing 1 changed file with 18 additions and 1 deletion.
19 changes: 18 additions & 1 deletion openmp/libomptarget/plugins/hsa/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,25 @@ find_path (
NAMES
libhsa-runtime64.so
PATHS
${ROCM_DIR}/hsa/lib
$ENV{HSA_RUNTIME_PATH}/lib
$ENV{HOME}/rocm/aomp/lib
$ENV{ROCM_DIR}/lib
/opt/rocm/aomp/lib
/opt/rocm/lib
/usr/lib/rocm/lib
)

find_path (
LIBOMPTARGET_DEP_LIBHSAKMT_LIBRARIES_DIRS
NAMES
libhsakmt.so
PATHS
${ROCM_DIR}/lib64
${ROCM_DIR}/lib
$ENV{HSA_RUNTIME_PATH}/lib
$ENV{HOME}/rocm/aomp/lib
$ENV{ROCM_DIR}/lib
/opt/rocm/aomp/lib
/opt/rocm/lib
/usr/lib/rocm/lib
Expand Down Expand Up @@ -135,7 +152,7 @@ install(TARGETS omptarget.rtl.hsa LIBRARY DESTINATION "lib${OPENMP_LIBDIR_SUFFIX
target_link_libraries(
omptarget.rtl.hsa
-L${AOMP_LIBDIR}${OPENMP_LIBDIR_SUFFIX} -latmi_runtime -Wl,-rpath,${AOMP_LIBDIR}${OPENMP_LIBDIR_SUFFIX}
-L${LIBOMPTARGET_DEP_LIBHSA_LIBRARIES_DIRS} -lhsa-runtime64 -lhsakmt -Wl,-rpath,${LIBOMPTARGET_DEP_LIBHSA_LIBRARIES_DIRS}
-L${LIBOMPTARGET_DEP_LIBHSA_LIBRARIES_DIRS} -L${LIBOMPTARGET_DEP_LIBHSAKMT_LIBRARIES_DIRS} -lhsa-runtime64 -lhsakmt -Wl,-rpath,${LIBOMPTARGET_DEP_LIBHSA_LIBRARIES_DIRS},-rpath,${LIBOMPTARGET_DEP_LIBHSAKMT_LIBRARIES_DIRS}
-L${AOMP_LIBDIR} -lLLVMAMDGPUDesc -lLLVMAMDGPUUtils -lLLVMMC -lLLVMCore -lLLVMSupport -Wl,-rpath,${AOMP_LIBDIR}
-lelf
"-Wl,--version-script=${CMAKE_CURRENT_SOURCE_DIR}/../exports"
Expand Down

0 comments on commit 75b29d3

Please sign in to comment.