Skip to content

Commit 6facbaa

Browse files
authored
[Comgr] Remove find_package(ROCM) (llvm#1526)
With the release of ROCM 6.4, find_pacakge(ROCM) has been deprecated. In this patch, we remove dependencies on the ROCm package, including the calls to rocm_setup_version() and rocm_set_soversion()
1 parent b7d1047 commit 6facbaa

File tree

1 file changed

+3
-14
lines changed

1 file changed

+3
-14
lines changed

amd/comgr/CMakeLists.txt

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,6 @@ if (ROCM_CCACHE_BUILD)
4747
endif() # if (CCACHE_PROGRAM)
4848
endif() # if (ROCM_CCACHE_BUILD)
4949

50-
find_package(ROCM QUIET)
51-
if (ROCM_FOUND)
52-
include(ROCMSetupVersion)
53-
rocm_setup_version(VERSION "${amd_comgr_VERSION}")
54-
endif()
55-
5650
# BUILD_SHARED_LIBS is a frustratingly global variable common to all
5751
# projects. LLVM also defines an option for the same varible with the
5852
# opposite default, which will overwrite our default preference
@@ -143,7 +137,6 @@ message("-----------Clang_DIR: ${Clang_DIR}")
143137
message("--CLANG_INCLUDE_DIRS: ${CLANG_INCLUDE_DIRS}")
144138
message("----LLD_INCLUDE_DIRS: ${LLD_INCLUDE_DIRS}")
145139
message("---AMDDeviceLibs_DIR: ${AMDDeviceLibs_DIR}")
146-
message("------------ROCM_DIR: ${ROCM_DIR}")
147140

148141
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
149142

@@ -249,13 +242,9 @@ set_target_properties(amd_comgr PROPERTIES
249242
CXX_STANDARD 17
250243
CXX_STANDARD_REQUIRED Yes
251244
CXX_EXTENSIONS No)
252-
if (ROCM_FOUND)
253-
rocm_set_soversion(amd_comgr "${amd_comgr_VERSION_MAJOR}.${amd_comgr_VERSION_MINOR}")
254-
else()
255-
set_target_properties(amd_comgr PROPERTIES
256-
SOVERSION "${amd_comgr_VERSION_MAJOR}"
257-
VERSION "${amd_comgr_VERSION_MAJOR}.${amd_comgr_VERSION_MINOR}.${amd_comgr_VERSION_PATCH}")
258-
endif()
245+
set_target_properties(amd_comgr PROPERTIES
246+
SOVERSION "${amd_comgr_VERSION_MAJOR}"
247+
VERSION "${amd_comgr_VERSION_MAJOR}.${amd_comgr_VERSION_MINOR}.${amd_comgr_VERSION_PATCH}")
259248

260249
if (NOT COMGR_BUILD_SHARED_LIBS)
261250
set_target_properties(amd_comgr PROPERTIES POSITION_INDEPENDENT_CODE ON)

0 commit comments

Comments
 (0)