c_josie_overlay

ROCm 10.1: trim carried-over patches (drop 8 obsolete, rebase 3)

Every 7.x patch carried into the 10.1 ebuilds was dry-run against the
TheRock 10.1 sources. Drop those whose fix already landed upstream or
whose target code is gone; rebase the three whose target code is present
but whose context moved.

Dropped: rocm-device-libs 7.2.0-llvm-22-compat, rocm-comgr
6.1.0-dont-add-nogpulib, rocr-runtime 7.2.0-fix-libcxx, hip
7.2.0-local-fixes, hip 6.3.0-clr-fix-libcxx, amdsmi 7.1.1-libdrm-compat,
amdsmi 7.0.2-no-git, rocm-smi 5.7.1-no-strip.

Rebased: roct-thunk-interface 7.1.0-functions (libhsakmt.ver context),
rocm-comgr 7.2.0-llvm-22-compat (hunk 1 already upstream; keep the
-no-disable-free -> -disable-free=false hunk), rocm-smi
5.7.1-remove-example (CMakeLists context).

ad2a957bc58e7b59b4cc49ed969b4afe7e6f2dd6
cjosie <administrator@josie-c.com> · 2026-10-14T00:33 · browse files at this commit

parents: c549d79

diff --git a/dev-libs/rocm-comgr/files/rocm-comgr-6.1.0-dont-add-nogpulib.patch b/dev-libs/rocm-comgr/files/rocm-comgr-6.1.0-dont-add-nogpulib.patch
deleted file mode 100644
index 526318f..0000000
--- a/dev-libs/rocm-comgr/files/rocm-comgr-6.1.0-dont-add-nogpulib.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 179ec2e67bf882c6bccb27f81db3d80f7eb9946e Mon Sep 17 00:00:00 2001
-From: Jacob Lambert <jacob.lambert@amd.com>
-Date: Fri, 12 Apr 2024 13:56:42 -0700
-Subject: [PATCH] [Comgr] Don't add -nogpulib option for assembley action
-
-We can omit setting -nogpulib even without a -rocm-path=. option
-when calling the assembly action. This avoids the following warning:
-
-warning: argument unused during compilation: '-nogpulib'
-Change-Id: I66d512befbafd9382f050c45a0d3950985e8ae38
----
- amd/comgr/src/comgr-compiler.cpp | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git a/src/comgr-compiler.cpp b/src/comgr-compiler.cpp
-index 143ab4e4f3db..21b233fa94b2 100644
---- a/src/comgr-compiler.cpp
-+++ b/src/comgr-compiler.cpp
-@@ -1758,6 +1758,9 @@ amd_comgr_status_t AMDGPUCompiler::assembleToRelocatable() {
-   Args.push_back("-x");
-   Args.push_back("assembler");
- 
-+  // -nogpulib option not needed for assembling to relocatable
-+  NoGpuLib = false;
-+
-   return processFiles(AMD_COMGR_DATA_KIND_RELOCATABLE, ".o");
- }
- 
--- 
-2.44.0
-
diff --git a/dev-libs/rocm-comgr/files/rocm-comgr-7.2.0-llvm-22-compat.patch b/dev-libs/rocm-comgr/files/rocm-comgr-7.2.0-llvm-22-compat.patch
index f378f81..d11b430 100644
--- a/dev-libs/rocm-comgr/files/rocm-comgr-7.2.0-llvm-22-compat.patch
+++ b/dev-libs/rocm-comgr/files/rocm-comgr-7.2.0-llvm-22-compat.patch
@@ -2,16 +2,7 @@ LLVM-22 compatibility fixes.
 Partially backports https://github.com/ROCm/llvm-project/commit/0216fcfc5d2a4f3384873f6e9ac70198760d5a52
 --- a/src/comgr-compiler.cpp
 +++ b/src/comgr-compiler.cpp
-@@ -659,7 +659,7 @@ amd_comgr_status_t executeCommand(const Command &Job, raw_ostream &LogS,
- 
-     std::unique_ptr<CompilerInstance> Clang(new CompilerInstance());
-     Clang->setVerboseOutputStream(LogS);
--    Clang->setFileManager(new FileManager(Clang->getFileSystemOpts(), &FS));
-+    Clang->setVirtualFileSystem(&FS);
-     if (!Argv.back()) {
-       Argv.pop_back();
-     }
-@@ -909,8 +909,7 @@ amd_comgr_status_t AMDGPUCompiler::processFile(DataObject *Input,
+@@ -1365,8 +1365,7 @@
    }
  
    // By default clang driver will ask CC1 to leak memory.
@@ -19,5 +10,5 @@ Partially backports https://github.com/ROCm/llvm-project/commit/0216fcfc5d2a4f33
 -  Argv.push_back("-no-disable-free");
 +  Argv.push_back("-disable-free=false");
  
-   Argv.push_back(InputFilePath);
- 
+   // Append options from AMD_COMGR_DRIVER_OPTIONS_APPEND environment variable.
+   // Options are space-separated and appended after all other options.
diff --git a/dev-libs/rocm-comgr/rocm-comgr-10.1.ebuild b/dev-libs/rocm-comgr/rocm-comgr-10.1.ebuild
index e4decbe..e2e4a0b 100644
--- a/dev-libs/rocm-comgr/rocm-comgr-10.1.ebuild
+++ b/dev-libs/rocm-comgr/rocm-comgr-10.1.ebuild
@@ -24,7 +24,6 @@ RESTRICT="!test? ( test )"
 
 PATCHES=(
 	"${FILESDIR}/${PN}-6.4.1-extend-isa-compatibility-check.patch"
-	"${FILESDIR}/${PN}-6.1.0-dont-add-nogpulib.patch"
 	"${FILESDIR}/${PN}-7.2.0-llvm-22-compat.patch"
 )
 
diff --git a/dev-libs/rocm-device-libs/files/rocm-device-libs-7.2.0-llvm-22-compat.patch b/dev-libs/rocm-device-libs/files/rocm-device-libs-7.2.0-llvm-22-compat.patch
deleted file mode 100644
index f4699d3..0000000
--- a/dev-libs/rocm-device-libs/files/rocm-device-libs-7.2.0-llvm-22-compat.patch
+++ /dev/null
@@ -1,233 +0,0 @@
-Fix error: '__builtin_amdgcn_lerp' needs target feature cube-insts.
-
-Copies files from:
-https://github.com/ROCm/llvm-project/blame/amd-staging/amd/device-libs/ockl/src/image.cl
-https://github.com/ROCm/llvm-project/blame/amd-staging/amd/device-libs/ockl/src/media.cl
---- a/ockl/src/image.cl
-+++ b/ockl/src/image.cl
-@@ -13,6 +13,7 @@
- #define EII() __oclc_ISA_version != 9010
- 
- #define RATTR __attribute__((pure))
-+#define CRATTR __attribute__((pure, target("cube-insts")))
- #define ERATTR __attribute__((pure, target("extended-image-insts")))
- #define WATTR
- #define GATTR __attribute__((const))
-@@ -510,14 +511,14 @@ OCKL_MANGLE_T(image_load,3D)(TSHARP i, int4 c)
-     return my_image_load_3d_v4f32_i32(c.x, c.y, c.z, LOAD_TSHARP(i));
- }
- 
--RATTR float4
--OCKL_MANGLE_T(image_load,CM)(TSHARP i, int2 c, int f)
-+CRATTR float4
-+OCKL_MANGLE_T(image_load, CM)(TSHARP i, int2 c, int f)
- {
-     return my_image_load_cube_v4f32_i32(c.x, c.y, f, LOAD_TSHARP(i));
- }
- 
--RATTR float4
--OCKL_MANGLE_T(image_load,CMa)(TSHARP i, int4 c, int f)
-+CRATTR float4
-+OCKL_MANGLE_T(image_load, CMa)(TSHARP i, int4 c, int f)
- {
-     f = LS_ARRAY_FACE(c.z, f);
-     return my_image_load_cube_v4f32_i32(c.x, c.y, f, LOAD_TSHARP(i));
-@@ -565,14 +566,14 @@ OCKL_MANGLE_T(image_load_lod,3D)(TSHARP i, int4 c, int l)
-     return my_image_load_mip_3d_v4f32_i32(c.x, c.y, c.z, l, LOAD_TSHARP(i));
- }
- 
--RATTR float4
--OCKL_MANGLE_T(image_load_lod,CM)(TSHARP i, int2 c, int f, int l)
-+CRATTR float4
-+OCKL_MANGLE_T(image_load_lod, CM)(TSHARP i, int2 c, int f, int l)
- {
-     return my_image_load_mip_cube_v4f32_i32(c.x, c.y, f, l, LOAD_TSHARP(i));
- }
- 
--RATTR float4
--OCKL_MANGLE_T(image_load_lod,CMa)(TSHARP i, int4 c, int f, int l)
-+CRATTR float4
-+OCKL_MANGLE_T(image_load_lod, CMa)(TSHARP i, int4 c, int f, int l)
- {
-     f = LS_ARRAY_FACE(c.z, f);
-     return my_image_load_mip_cube_v4f32_i32(c.x, c.y, f, l, LOAD_TSHARP(i));
-@@ -614,14 +615,14 @@ OCKL_MANGLE_T(image_loadh,3D)(TSHARP i, int4 c)
-     return my_image_load_3d_v4f16_i32(c.x, c.y, c.z, LOAD_TSHARP(i));
- }
- 
--RATTR half4
--OCKL_MANGLE_T(image_loadh,CM)(TSHARP i, int2 c, int f)
-+CRATTR half4
-+OCKL_MANGLE_T(image_loadh, CM)(TSHARP i, int2 c, int f)
- {
-     return my_image_load_cube_v4f16_i32(c.x, c.y, f, LOAD_TSHARP(i));
- }
- 
--RATTR half4
--OCKL_MANGLE_T(image_loadh,CMa)(TSHARP i, int4 c, int f)
-+CRATTR half4
-+OCKL_MANGLE_T(image_loadh, CMa)(TSHARP i, int4 c, int f)
- {
-     f = LS_ARRAY_FACE(c.z, f);
-     return my_image_load_cube_v4f16_i32(c.x, c.y, f, LOAD_TSHARP(i));
-@@ -657,14 +658,14 @@ OCKL_MANGLE_T(image_loadh_lod,3D)(TSHARP i, int4 c, int l)
-     return my_image_load_mip_3d_v4f16_i32(c.x, c.y, c.z, l, LOAD_TSHARP(i));
- }
- 
--RATTR half4
--OCKL_MANGLE_T(image_loadh_lod,CM)(TSHARP i, int2 c, int f, int l)
-+CRATTR half4
-+OCKL_MANGLE_T(image_loadh_lod, CM)(TSHARP i, int2 c, int f, int l)
- {
-     return my_image_load_mip_cube_v4f16_i32(c.x, c.y, f, l, LOAD_TSHARP(i));
- }
- 
--RATTR half4
--OCKL_MANGLE_T(image_loadh_lod,CMa)(TSHARP i, int4 c, int f, int l)
-+CRATTR half4
-+OCKL_MANGLE_T(image_loadh_lod, CMa)(TSHARP i, int4 c, int f, int l)
- {
-     f = LS_ARRAY_FACE(c.z, f);
-     return my_image_load_mip_cube_v4f16_i32(c.x, c.y, f, l, LOAD_TSHARP(i));
-@@ -950,8 +951,8 @@ OCKL_MANGLE_T(image_sample,3D)(TSHARP i, SSHARP s, float4 c)
-         return my_image_sample_3d_v4f32_f32(c.x, c.y, c.z, LOAD_TSHARP(i), LOAD_SSHARP(s));
- }
- 
--RATTR float4
--OCKL_MANGLE_T(image_sample,CM)(TSHARP i, SSHARP s, float4 c)
-+CRATTR float4
-+OCKL_MANGLE_T(image_sample, CM)(TSHARP i, SSHARP s, float4 c)
- {
-     CUBE_PREP(c);
-     if (EII())
-@@ -960,8 +961,8 @@ OCKL_MANGLE_T(image_sample,CM)(TSHARP i, SSHARP s, float4 c)
-         return my_image_sample_cube_v4f32_f32(c.x, c.y, c.z, LOAD_TSHARP(i), LOAD_SSHARP(s));
- }
- 
--RATTR float4
--OCKL_MANGLE_T(image_sample,CMa)(TSHARP i, SSHARP s, float4 c)
-+CRATTR float4
-+OCKL_MANGLE_T(image_sample, CMa)(TSHARP i, SSHARP s, float4 c)
- {
-     CUBE_PREP(c);
-     c.z = SAMPLE_ARRAY_FACE(c.w, c.z);
-@@ -1068,15 +1069,15 @@ OCKL_MANGLE_T(image_sample_lod,3D)(TSHARP i, SSHARP s, float4 c, float l)
-     return my_image_sample_l_3d_v4f32_f32(c.x, c.y, c.z, l, LOAD_TSHARP(i), LOAD_SSHARP(s));
- }
- 
--RATTR float4
--OCKL_MANGLE_T(image_sample_lod,CM)(TSHARP i, SSHARP s, float4 c, float l)
-+CRATTR float4
-+OCKL_MANGLE_T(image_sample_lod, CM)(TSHARP i, SSHARP s, float4 c, float l)
- {
-     CUBE_PREP(c);
-     return my_image_sample_l_cube_v4f32_f32(c.x, c.y, c.z, l, LOAD_TSHARP(i), LOAD_SSHARP(s));
- }
- 
--RATTR float4
--OCKL_MANGLE_T(image_sample_lod,CMa)(TSHARP i, SSHARP s, float4 c, float l)
-+CRATTR float4
-+OCKL_MANGLE_T(image_sample_lod, CMa)(TSHARP i, SSHARP s, float4 c, float l)
- {
-     CUBE_PREP(c);
-     c.z = SAMPLE_ARRAY_FACE(c.w, c.z);
-@@ -1135,8 +1136,8 @@ OCKL_MANGLE_T(image_sampleh,3D)(TSHARP i, SSHARP s, float4 c)
-         return my_image_sample_3d_v4f16_f32(c.x, c.y, c.z, LOAD_TSHARP(i), LOAD_SSHARP(s));
- }
- 
--RATTR half4
--OCKL_MANGLE_T(image_sampleh,CM)(TSHARP i, SSHARP s, float4 c)
-+CRATTR half4
-+OCKL_MANGLE_T(image_sampleh, CM)(TSHARP i, SSHARP s, float4 c)
- {
-     CUBE_PREP(c);
-     if (EII())
-@@ -1145,8 +1146,8 @@ OCKL_MANGLE_T(image_sampleh,CM)(TSHARP i, SSHARP s, float4 c)
-         return my_image_sample_cube_v4f16_f32(c.x, c.y, c.z, LOAD_TSHARP(i), LOAD_SSHARP(s));
- }
- 
--RATTR half4
--OCKL_MANGLE_T(image_sampleh,CMa)(TSHARP i, SSHARP s, float4 c)
-+CRATTR half4
-+OCKL_MANGLE_T(image_sampleh, CMa)(TSHARP i, SSHARP s, float4 c)
- {
-     CUBE_PREP(c);
-     c.z = SAMPLE_ARRAY_FACE(c.w, c.z);
-@@ -1225,15 +1226,15 @@ OCKL_MANGLE_T(image_sampleh_lod,3D)(TSHARP i, SSHARP s, float4 c, float l)
-     return my_image_sample_l_3d_v4f16_f32(c.x, c.y, c.z, l, LOAD_TSHARP(i), LOAD_SSHARP(s));
- }
- 
--RATTR half4
--OCKL_MANGLE_T(image_sampleh_lod,CM)(TSHARP i, SSHARP s, float4 c, float l)
-+CRATTR half4
-+OCKL_MANGLE_T(image_sampleh_lod, CM)(TSHARP i, SSHARP s, float4 c, float l)
- {
-     CUBE_PREP(c);
-     return my_image_sample_l_cube_v4f16_f32(c.x, c.y, c.z, l, LOAD_TSHARP(i), LOAD_SSHARP(s));
- }
- 
--RATTR half4
--OCKL_MANGLE_T(image_sampleh_lod,CMa)(TSHARP i, SSHARP s, float4 c, float l)
-+CRATTR half4
-+OCKL_MANGLE_T(image_sampleh_lod, CMa)(TSHARP i, SSHARP s, float4 c, float l)
- {
-     CUBE_PREP(c);
-     c.z = SAMPLE_ARRAY_FACE(c.w, c.z);
---- a/ockl/src/media.cl
-+++ b/ockl/src/media.cl
-@@ -11,6 +11,9 @@
- #pragma OPENCL EXTENSION cl_khr_fp16 : enable
- 
- #define CATTR __attribute__((const))
-+#define LCATTR __attribute__((const, target("lerp-inst")))
-+#define QCATTR __attribute__((const, target("qsad-insts")))
-+#define SCATTR __attribute__((const, target("sad-insts")))
- #define AS_UCHAR4(X) __builtin_astype(X, uchar4)
- 
- CATTR uint
-@@ -44,7 +47,7 @@ OCKL_MANGLE_U32(bytealign)(uint a, uint b, uint c)
-     return __builtin_amdgcn_alignbyte(a, b, c);
- }
- 
--CATTR uint
-+LCATTR uint
- OCKL_MANGLE_U32(lerp)(uint a, uint b, uint c)
- {
-     return __builtin_amdgcn_lerp(a, b, c);
-@@ -155,13 +158,13 @@ OCKL_MANGLE_U32(pack)(float4 a)
-                  __builtin_amdgcn_cvt_pk_u8_f32(a.s0, 0, 0))));
- }
- 
--CATTR ulong
-+QCATTR ulong
- OCKL_MANGLE_U64(qsad)(ulong a, uint b, ulong c)
- {
-     return __builtin_amdgcn_qsad_pk_u16_u8(a, b, c);
- }
- 
--CATTR uint
-+SCATTR uint
- OCKL_MANGLE_U32(sad)(uint a, uint b, uint c)
- {
-     return __builtin_amdgcn_sad_u8(a, b, c);
-@@ -174,13 +177,13 @@ OCKL_MANGLE_U32(sadd)(uint a, uint b, uint c)
-     return (a > b ? a : b) - (a < b ? a : b) + c;
- }
- 
--CATTR uint
-+SCATTR uint
- OCKL_MANGLE_U32(sadhi)(uint a, uint b, uint c)
- {
-     return __builtin_amdgcn_sad_hi_u8(a, b, c);
- }
- 
--CATTR uint
-+SCATTR uint
- OCKL_MANGLE_U32(sadw)(uint a, uint b, uint c)
- {
-     return __builtin_amdgcn_sad_u16(a, b, c);
-@@ -213,4 +216,3 @@ OCKL_MANGLE_F32(unpack3)(uint a)
-     uchar4 v = AS_UCHAR4(a);
-     return (float)v.s3;
- }
--
diff --git a/dev-libs/rocm-device-libs/rocm-device-libs-10.1.ebuild b/dev-libs/rocm-device-libs/rocm-device-libs-10.1.ebuild
index 44e7769..ec7da24 100644
--- a/dev-libs/rocm-device-libs/rocm-device-libs-10.1.ebuild
+++ b/dev-libs/rocm-device-libs/rocm-device-libs-10.1.ebuild
@@ -39,7 +39,6 @@ CMAKE_BUILD_TYPE=Release
 
 PATCHES=(
 	"${FILESDIR}/${PN}-6.2.0-test-bitcode-dir.patch"
-	"${FILESDIR}/${PN}-7.2.0-llvm-22-compat.patch"
 )
 
 src_unpack() {
diff --git a/dev-libs/rocr-runtime/files/rocr-runtime-7.2.0-fix-libcxx.patch b/dev-libs/rocr-runtime/files/rocr-runtime-7.2.0-fix-libcxx.patch
deleted file mode 100644
index e79e6fc..0000000
--- a/dev-libs/rocr-runtime/files/rocr-runtime-7.2.0-fix-libcxx.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-Fix libc++ error: no matching function for call to object of type 'const std::less<void>'.
-libstdc++ compiles due too loose standard following, allowing to compare some structs without a comparator.
-Upstream bug: https://github.com/ROCm/rocm-systems/issues/3307
---- a/runtime/hsa-runtime/core/inc/amd_gpu_agent.h
-+++ b/runtime/hsa-runtime/core/inc/amd_gpu_agent.h
-@@ -575,8 +575,14 @@ class GpuAgent : public GpuAgentInt {
-   // @brief Current short duration scratch memory size.
-   size_t scratch_used_large_;
- 
-+  struct HsaSignalLess {
-+    bool operator()(const hsa_signal_t& lhs, const hsa_signal_t& rhs) const {
-+      return lhs.handle < rhs.handle;
-+    }
-+  };
-+
-   // @brief Notifications for scratch release.
--  std::map<hsa_signal_t, hsa_signal_value_t> scratch_notifiers_;
-+  std::map<hsa_signal_t, hsa_signal_value_t, HsaSignalLess> scratch_notifiers_;
- 
-   // @brief Default scratch size per queue.
-   size_t queue_scratch_len_;
diff --git a/dev-libs/rocr-runtime/rocr-runtime-10.1.ebuild b/dev-libs/rocr-runtime/rocr-runtime-10.1.ebuild
index 8be032f..a7f3e47 100644
--- a/dev-libs/rocr-runtime/rocr-runtime-10.1.ebuild
+++ b/dev-libs/rocr-runtime/rocr-runtime-10.1.ebuild
@@ -40,7 +40,6 @@ BDEPEND="app-editors/vim-core"
 
 PATCHES=(
 	"${FILESDIR}/${PN}-7.2.0-use-system-hsakmt.patch"
-	"${FILESDIR}/${PN}-7.2.0-fix-libcxx.patch"
 )
 
 # skip false positive detection in samples, bug #958188
diff --git a/dev-libs/roct-thunk-interface/files/roct-thunk-interface-7.1.0-functions.patch b/dev-libs/roct-thunk-interface/files/roct-thunk-interface-7.1.0-functions.patch
index da600e5..29064cd 100644
--- a/dev-libs/roct-thunk-interface/files/roct-thunk-interface-7.1.0-functions.patch
+++ b/dev-libs/roct-thunk-interface/files/roct-thunk-interface-7.1.0-functions.patch
@@ -1,10 +1,10 @@
 https://github.com/ROCm/rocm-systems/issues/284
---- a/src/libhsakmt.ver	2025-10-23 22:15:14.000000000 -0000
-+++ b/src/libhsakmt.ver	2025-11-08 08:09:20.103216984 -0000
-@@ -90,6 +90,9 @@
- hsaKmtPcSamplingStop;
- hsaKmtPcSamplingSupport;
- hsaKmtAisReadWriteFile;
+--- a/src/libhsakmt.ver
++++ b/src/libhsakmt.ver
+@@ -112,6 +112,9 @@
+ hsaKmtMemoryCpuMap;
+ hsaKmtSetSigbusDelay;
+ hsaKmtGetAmdGPUDeviceFd;
 +hsaKmtCreateQueueExt;
 +hsaKmtRegisterGraphicsHandleToNodesExt;
 +hsaKmtModelEnabled;
diff --git a/dev-util/amdsmi/amdsmi-10.1.ebuild b/dev-util/amdsmi/amdsmi-10.1.ebuild
index 8a17933..e52d7b1 100644
--- a/dev-util/amdsmi/amdsmi-10.1.ebuild
+++ b/dev-util/amdsmi/amdsmi-10.1.ebuild
@@ -41,11 +41,6 @@ RDEPEND="
 	${PYTHON_DEPS}
 "
 
-PATCHES=(
-	"${FILESDIR}"/${PN}-7.0.2-no-git.patch
-	"${FILESDIR}"/${PN}-7.1.1-libdrm-compat.patch
-)
-
 CONFIG_CHECK="~HSA_AMD ~DRM_AMDGPU"
 
 src_prepare() {
diff --git a/dev-util/amdsmi/files/amdsmi-7.0.2-no-git.patch b/dev-util/amdsmi/files/amdsmi-7.0.2-no-git.patch
deleted file mode 100644
index 9892705..0000000
--- a/dev-util/amdsmi/files/amdsmi-7.0.2-no-git.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-Should not check and update esmi_ib_library in network isolation
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -39,7 +39,7 @@ find_package(PkgConfig)
- generic_add_rocm()
- 
- # provide git to utilities
--find_program(GIT NAMES git)
-+# find_program(GIT NAMES git)
- 
- ## Setup the package version based on git tags.
- set(PKG_VERSION_GIT_TAG_PREFIX "amdsmi_pkg_ver")
-@@ -126,7 +126,7 @@ if(ENABLE_ESMI_LIB)
-         message(STATUS "Adding esmi_ib_library...")
-         execute_process(COMMAND git clone --depth=1 -b ${current_esmi_tag} https://github.com/amd/esmi_ib_library.git
-                                 ${PROJECT_SOURCE_DIR}/esmi_ib_library)
--    else()
-+    elseif(FALSE)
-         message(STATUS "esmi_ib_library already installed, checking version...")
- 
-         # Grab latest commit and get the tag
diff --git a/dev-util/amdsmi/files/amdsmi-7.1.1-libdrm-compat.patch b/dev-util/amdsmi/files/amdsmi-7.1.1-libdrm-compat.patch
deleted file mode 100644
index 3e08e3a..0000000
--- a/dev-util/amdsmi/files/amdsmi-7.1.1-libdrm-compat.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-Fix compatibility with x11-libs/libdrm-2.4.130
-
-Bug: https://bugs.gentoo.org/967246
-Upstream PR: https://github.com/ROCm/amdsmi/pull/165
---- a/include/amd_smi/impl/amdgpu_drm.h
-+++ b/include/amd_smi/impl/amdgpu_drm.h
-@@ -1625,15 +1625,6 @@ struct drm_amdgpu_info_uq_metadata {
- #define AMDGPU_FAMILY_GC_11_5_0			150 /* GC 11.5.0 */
- #define AMDGPU_FAMILY_GC_12_0_0			152 /* GC 12.0.0 */
- 
--/* FIXME wrong namespace! */
--struct drm_color_ctm_3x4 {
--	/*
--	 * Conversion matrix with 3x4 dimensions in S31.32 sign-magnitude
--	 * (not two's complement!) format.
--	 */
--	__u64 matrix[12];
--};
--
- #if defined(__cplusplus)
- }
- #endif
diff --git a/dev-util/hip/files/hip-6.3.0-clr-fix-libcxx.patch b/dev-util/hip/files/hip-6.3.0-clr-fix-libcxx.patch
deleted file mode 100644
index 3052e25..0000000
--- a/dev-util/hip/files/hip-6.3.0-clr-fix-libcxx.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-Fix compilation with libc++ (ROCM/clr part)
---- a/hipamd/include/hip/amd_detail/amd_hip_runtime.h
-+++ b/hipamd/include/hip/amd_detail/amd_hip_runtime.h
-@@ -386,15 +386,26 @@ hc_get_workitem_absolute_id(int dim)
- #pragma push_macro("__CUDA__")
- #define __CUDA__
- #include <__clang_cuda_math_forward_declares.h>
-+// __clang_cuda_complex_builtins wants ::max
-+#include <__clang_hip_math.h>
- #include <__clang_cuda_complex_builtins.h>
- // Workaround for using libc++ with HIP-Clang.
- // The following headers requires clang include path before standard C++ include path.
- // However libc++ include path requires to be before clang include path.
- // To workaround this, we pass -isystem with the parent directory of clang include
- // path instead of the clang include path itself.
-+
-+// libc++: <include/cuda_wrappers/complex> transitively includes <queue>, which uses __local
-+#define ORIGINAL__LOCAL __local
-+#undef __local
-+
- #include <include/cuda_wrappers/algorithm>
- #include <include/cuda_wrappers/complex>
- #include <include/cuda_wrappers/new>
-+
-+#define __local ORIGINAL__LOCAL
-+#undef ORIGINAL__LOCAL
-+
- #undef __CUDA__
- #pragma pop_macro("__CUDA__")
- #endif // !_OPENMP || __HIP_ENABLE_CUDA_WRAPPER_FOR_OPENMP__
diff --git a/dev-util/hip/files/hip-7.2.0-local-fixes.patch b/dev-util/hip/files/hip-7.2.0-local-fixes.patch
deleted file mode 100644
index 1d1a5c2..0000000
--- a/dev-util/hip/files/hip-7.2.0-local-fixes.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-Defining __local before inclusion of libc++ <ranges> or <deque> causes compilation errors.
-
-Upstream bug: https://github.com/ROCm/rocm-systems/issues/1874
---- a/hipamd/include/hip/amd_detail/device_library_decls.h
-+++ b/hipamd/include/hip/amd_detail/device_library_decls.h
-@@ -120,6 +120,15 @@ extern "C" __device__ __hip_uint64_t __ockl_fprintf_append_string_n(__hip_uint64
-                                                                     __hip_uint64_t length,
-                                                                     __hip_uint32_t is_last);
- 
-+// libc++ <ranges> uses __local as function name; include one file, before defining __local macro
-+#if defined(__cplusplus) && defined(_LIBCPP_VERSION) && defined(__has_include)
-+#  if __has_include (<__ranges/join_view.h>)
-+#    include <__ranges/join_view.h>
-+#  endif
-+// Deque also uses __local function name; include should be safe, as it is autoincluded anyways
-+#  include <deque>
-+#endif
-+
- // Introduce local address space
- #define __local __attribute__((address_space(3)))
- 
diff --git a/dev-util/hip/hip-10.1.ebuild b/dev-util/hip/hip-10.1.ebuild
index 8311a45..f2bbd6d 100644
--- a/dev-util/hip/hip-10.1.ebuild
+++ b/dev-util/hip/hip-10.1.ebuild
@@ -86,10 +86,8 @@ RDEPEND="${DEPEND}
 
 PATCHES=(
 	"${FILESDIR}/${PN}-6.3.0-no-isystem-usr-include.patch"
-	"${FILESDIR}/${PN}-6.3.0-clr-fix-libcxx.patch"
 	"${FILESDIR}/${PN}-7.1.0-no-hipother-install.patch"
 	"${FILESDIR}/${PN}-7.2.0-noinline-fixes.patch"
-	"${FILESDIR}/${PN}-7.2.0-local-fixes.patch"
 )
 
 QA_FLAGS_IGNORED="usr/lib.*/libhiprtc-builtins.*"
diff --git a/dev-util/rocm-smi/files/rocm-smi-5.7.1-no-strip.patch b/dev-util/rocm-smi/files/rocm-smi-5.7.1-no-strip.patch
deleted file mode 100644
index 0779629..0000000
--- a/dev-util/rocm-smi/files/rocm-smi-5.7.1-no-strip.patch
+++ /dev/null
@@ -1,36 +0,0 @@
---- a/oam/CMakeLists.txt
-+++ b/oam/CMakeLists.txt
-@@ -82,15 +82,6 @@ set_property(TARGET ${OAM_TARGET} PROPERTY
- set_property(TARGET ${OAM_TARGET} PROPERTY
-              VERSION "${SO_VERSION_STRING}")
- 
--## If the library is a release, strip the target library
--if ("${CMAKE_BUILD_TYPE}" STREQUAL Release)
--    if(${BUILD_SHARED_LIBS}) #striping only for .so
--        add_custom_command(
--             TARGET ${OAM_TARGET}
--             POST_BUILD COMMAND ${CMAKE_STRIP} lib${OAM_TARGET}.so)
--    endif()
--endif ()
--
- # use the target_include_directories() command to specify the include directories for the target
- target_include_directories(${OAM_TARGET}
-                            PUBLIC
---- a/rocm_smi/CMakeLists.txt
-+++ b/rocm_smi/CMakeLists.txt
-@@ -103,15 +103,6 @@ set_property(TARGET ${ROCM_SMI_TARGET} PROPERTY
- set_property(TARGET ${ROCM_SMI_TARGET} PROPERTY
-              VERSION "${SO_VERSION_STRING}")
- 
--## If the library is a release, strip the target library
--if ("${CMAKE_BUILD_TYPE}" STREQUAL Release)
--  if(${BUILD_SHARED_LIBS}) #stripping only for .so
--    add_custom_command(
--          TARGET ${ROCM_SMI_TARGET}
--          POST_BUILD COMMAND ${CMAKE_STRIP} lib${ROCM_SMI_TARGET}.so.${SO_VERSION_STRING})
--  endif()
--endif ()
--
- #file reorganization changes
- #rocm_smi.py moved to libexec/rocm_smi. so creating rocm-smi symlink
- file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/bin)
diff --git a/dev-util/rocm-smi/files/rocm-smi-5.7.1-remove-example.patch b/dev-util/rocm-smi/files/rocm-smi-5.7.1-remove-example.patch
index 18e1f4c..131938e 100644
--- a/dev-util/rocm-smi/files/rocm-smi-5.7.1-remove-example.patch
+++ b/dev-util/rocm-smi/files/rocm-smi-5.7.1-remove-example.patch
@@ -1,7 +1,7 @@
 Remove example; unused, only generates not important QA warnings
 --- a/rocm_smi/CMakeLists.txt
 +++ b/rocm_smi/CMakeLists.txt
-@@ -76,8 +76,10 @@ set(SMI_INC_LIST "")
+@@ -79,8 +79,10 @@
  
  set(SMI_EXAMPLE_EXE "rocm_smi_ex")
  
@@ -9,6 +9,6 @@ Remove example; unused, only generates not important QA warnings
  add_executable(${SMI_EXAMPLE_EXE} "example/rocm_smi_example.cc")
  target_link_libraries(${SMI_EXAMPLE_EXE} ${ROCM_SMI_TARGET})
 +endif()
- add_library(${ROCM_SMI_TARGET}  ${CMN_SRC_LIST} ${SMI_SRC_LIST}
-                                               ${CMN_INC_LIST} ${SMI_INC_LIST})
- target_link_libraries(${ROCM_SMI_TARGET} pthread rt)
+ add_library(${ROCM_SMI_TARGET} ${CMN_SRC_LIST} ${SMI_SRC_LIST} ${CMN_INC_LIST} ${SMI_INC_LIST})
+ target_link_libraries(${ROCM_SMI_TARGET} PRIVATE pthread rt dl)
+ target_include_directories(
diff --git a/dev-util/rocm-smi/rocm-smi-10.1.ebuild b/dev-util/rocm-smi/rocm-smi-10.1.ebuild
index edb3b4e..d2cbe7b 100644
--- a/dev-util/rocm-smi/rocm-smi-10.1.ebuild
+++ b/dev-util/rocm-smi/rocm-smi-10.1.ebuild
@@ -32,7 +32,6 @@ DEPEND="${RDEPEND}
 "
 
 PATCHES=(
-	"${FILESDIR}"/${PN}-5.7.1-no-strip.patch
 	"${FILESDIR}"/${PN}-5.7.1-remove-example.patch
 )