diff --git a/dev-libs/rocm-core/files/rocm-core-10.1-two-component-version.patch b/dev-libs/rocm-core/files/rocm-core-10.1-two-component-version.patch
index a4176d2..9de6599 100644
--- a/dev-libs/rocm-core/files/rocm-core-10.1-two-component-version.patch
+++ b/dev-libs/rocm-core/files/rocm-core-10.1-two-component-version.patch
@@ -1,12 +1,11 @@
--- a/utils.cmake
+++ b/utils.cmake
-@@ -98,6 +98,9 @@
- #set libpatch version
- if(NOT DEFINED ENV{ROCM_LIBPATCH_VERSION})
- set(ROCM_LIBPATCH_VERSION "${VERSION_MAJOR}")
-+ if(NOT DEFINED VERSION_PATCH)
-+ set(VERSION_PATCH 0)
-+ endif()
- string(LENGTH ${VERSION_MINOR} LENSTR)
- if(LENSTR EQUAL 1) # length of version cannot be zero hence it would be 1 or greater
- set(ROCM_LIBPATCH_VERSION "${ROCM_LIBPATCH_VERSION}0${VERSION_MINOR}")
+@@ -32,6 +32,8 @@
+ list ( GET VERSIONS 2 PATCH )
+ set ( VERSION_PATCH ${PATCH} PARENT_SCOPE )
+ set ( TEMP_VERSION_STRING "${TEMP_VERSION_STRING}.${PATCH}" )
++ else ()
++ set ( VERSION_PATCH 0 PARENT_SCOPE )
+ endif ()
+
+ if ( ${VERSION_COUNT} GREATER 3 )
dev-libs/rocm-core: fix two-component version in parse_rocm_version
The previous patch set VERSION_PATCH locally in set_variables(), so it never reached the top scope and rocm_version.h.in's @VERSION_PATCH@ expanded to empty (compile error in rocm_version.cpp). Set it with PARENT_SCOPE in parse_rocm_version instead, where the other version components are set. Verified: the generated header gets PATCH 0 and the library builds.
c549d79f529d8a90f48e978777c87b6a51e55a15
cjosie <administrator@josie-c.com> · 2026-10-13T23:34 ·
browse files at this commit
parents:
4337089