commit:     5da2c061b86df156649704606962e6b08aa11bb2
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Sat Jan 20 13:03:55 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat Jan 20 13:04:30 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5da2c061

dev-libs/rocm-opencl-runtime: use test-flags-CCLD to cover other linkers

Signed-off-by: Sam James <sam <AT> gentoo.org>

 dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.1.3.ebuild    | 9 ++-------
 dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.3.3-r1.ebuild | 9 ++-------
 dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.4.3-r1.ebuild | 9 ++-------
 dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.5.1.ebuild    | 9 ++-------
 dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.7.1-r1.ebuild | 9 ++-------
 dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-6.0.0.ebuild    | 9 ++-------
 dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-9999.ebuild     | 9 ++-------
 7 files changed, 14 insertions(+), 49 deletions(-)

diff --git a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.1.3.ebuild 
b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.1.3.ebuild
index acf6d1e19593..b9015cd84b13 100644
--- a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.1.3.ebuild
+++ b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.1.3.ebuild
@@ -3,7 +3,7 @@
 
 EAPI=8
 
-inherit cmake edo flag-o-matic toolchain-funcs prefix
+inherit cmake edo flag-o-matic prefix
 
 DESCRIPTION="Radeon Open Compute OpenCL Compatible Runtime"
 HOMEPAGE="https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime";
@@ -60,12 +60,7 @@ src_prepare() {
 
 src_configure() {
        # Fix ld.lld linker error: 
https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/155
-       # ideally we want !tc-ld-is-bfd for best future-proofing, but it needs
-       # https://github.com/gentoo/gentoo/pull/28355
-       # mold needs this too but right now tc-ld-is-mold is also not available
-       if tc-ld-is-lld; then
-               append-ldflags -Wl,--undefined-version
-       fi
+       append-ldflags $(test-flags-CCLD -Wl,--undefined-version)
 
        # Reported upstream: 
https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/120
        append-cflags -fcommon

diff --git a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.3.3-r1.ebuild 
b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.3.3-r1.ebuild
index d8fae3a7c08a..3e7f3d21381e 100644
--- a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.3.3-r1.ebuild
+++ b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.3.3-r1.ebuild
@@ -3,7 +3,7 @@
 
 EAPI=8
 
-inherit cmake edo flag-o-matic toolchain-funcs
+inherit cmake edo flag-o-matic
 
 DESCRIPTION="Radeon Open Compute OpenCL Compatible Runtime"
 HOMEPAGE="https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime";
@@ -47,12 +47,7 @@ src_prepare() {
 
 src_configure() {
        # Fix ld.lld linker error: 
https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/155
-       # ideally we want !tc-ld-is-bfd for best future-proofing, but it needs
-       # https://github.com/gentoo/gentoo/pull/28355
-       # mold needs this too but right now tc-ld-is-mold is also not available
-       if tc-ld-is-lld; then
-               append-ldflags -Wl,--undefined-version
-       fi
+       append-ldflags $(test-flags-CCLD -Wl,--undefined-version)
 
        # Reported upstream: 
https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/120
        append-cflags -fcommon

diff --git a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.4.3-r1.ebuild 
b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.4.3-r1.ebuild
index a5831a2339c3..fea24ac7dafc 100644
--- a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.4.3-r1.ebuild
+++ b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.4.3-r1.ebuild
@@ -3,7 +3,7 @@
 
 EAPI=8
 
-inherit cmake edo flag-o-matic toolchain-funcs
+inherit cmake edo flag-o-matic
 
 DESCRIPTION="Radeon Open Compute OpenCL Compatible Runtime"
 HOMEPAGE="https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime";
@@ -54,12 +54,7 @@ if [[ ${PV} == "9999" ]]; then
 }
 src_prepare() {
        # Fix ld.lld linker error: 
https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/155
-       # ideally we want !tc-ld-is-bfd for best future-proofing, but it needs
-       # https://github.com/gentoo/gentoo/pull/28355
-       # mold needs this too but right now tc-ld-is-mold is also not available
-       if tc-ld-is-lld; then
-               append-ldflags -Wl,--undefined-version
-       fi
+       append-ldflags $(test-flags-CCLD -Wl,--undefined-version)
 
        cmake_src_prepare
 

diff --git a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.5.1.ebuild 
b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.5.1.ebuild
index eca90b34b094..c9a0dfc880b7 100644
--- a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.5.1.ebuild
+++ b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.5.1.ebuild
@@ -3,7 +3,7 @@
 
 EAPI=8
 
-inherit cmake edo flag-o-matic toolchain-funcs
+inherit cmake edo flag-o-matic
 
 DESCRIPTION="Radeon Open Compute OpenCL Compatible Runtime"
 HOMEPAGE="https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime";
@@ -62,12 +62,7 @@ src_prepare() {
 
 src_configure() {
        # Fix ld.lld linker error: 
https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/155
-       # ideally we want !tc-ld-is-bfd for best future-proofing, but it needs
-       # https://github.com/gentoo/gentoo/pull/28355
-       # mold needs this too but right now tc-ld-is-mold is also not available
-       if tc-ld-is-lld; then
-               append-ldflags -Wl,--undefined-version
-       fi
+       append-ldflags $(test-flags-CCLD -Wl,--undefined-version)
 
        # Reported upstream: 
https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/120
        append-cflags -fcommon

diff --git a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.7.1-r1.ebuild 
b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.7.1-r1.ebuild
index ae568be79b96..65314b8b6b38 100644
--- a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.7.1-r1.ebuild
+++ b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-5.7.1-r1.ebuild
@@ -4,7 +4,7 @@
 EAPI=8
 
 ROCM_SKIP_GLOBALS=1
-inherit cmake edo flag-o-matic toolchain-funcs rocm
+inherit cmake edo flag-o-matic rocm
 
 DESCRIPTION="Radeon Open Compute OpenCL Compatible Runtime"
 HOMEPAGE="https://github.com/ROCm-Developer-Tools/clr";
@@ -49,12 +49,7 @@ OB           git-r3_checkout
 
 src_configure() {
        # Fix ld.lld linker error: 
https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/155
-       # ideally we want !tc-ld-is-bfd for best future-proofing, but it needs
-       # https://github.com/gentoo/gentoo/pull/28355
-       # mold needs this too but right now tc-ld-is-mold is also not available
-       if tc-ld-is-lld; then
-               append-ldflags -Wl,--undefined-version
-       fi
+       append-ldflags $(test-flags-CCLD -Wl,--undefined-version)
 
        # Reported upstream: 
https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/120
        append-cflags -fcommon

diff --git a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-6.0.0.ebuild 
b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-6.0.0.ebuild
index 1f792dd4cc24..8a2b71872bdc 100644
--- a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-6.0.0.ebuild
+++ b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-6.0.0.ebuild
@@ -4,7 +4,7 @@
 EAPI=8
 
 ROCM_SKIP_GLOBALS=1
-inherit cmake edo flag-o-matic toolchain-funcs rocm
+inherit cmake edo flag-o-matic rocm
 
 DESCRIPTION="Radeon Open Compute OpenCL Compatible Runtime"
 HOMEPAGE="https://github.com/ROCm-Developer-Tools/clr";
@@ -49,12 +49,7 @@ OB           git-r3_checkout
 
 src_configure() {
        # Fix ld.lld linker error: 
https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/155
-       # ideally we want !tc-ld-is-bfd for best future-proofing, but it needs
-       # https://github.com/gentoo/gentoo/pull/28355
-       # mold needs this too but right now tc-ld-is-mold is also not available
-       if tc-ld-is-lld; then
-               append-ldflags -Wl,--undefined-version
-       fi
+       append-ldflags $(test-flags-CCLD -Wl,--undefined-version)
 
        # Reported upstream: 
https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/120
        append-cflags -fcommon

diff --git a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-9999.ebuild 
b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-9999.ebuild
index fab2b10ec262..878cf8bbc33d 100644
--- a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-9999.ebuild
+++ b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-9999.ebuild
@@ -3,7 +3,7 @@
 
 EAPI=8
 
-inherit cmake edo flag-o-matic toolchain-funcs
+inherit cmake edo flag-o-matic
 
 DESCRIPTION="Radeon Open Compute OpenCL Compatible Runtime"
 HOMEPAGE="https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime";
@@ -60,12 +60,7 @@ src_prepare() {
 
 src_configure() {
        # Fix ld.lld linker error: 
https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/155
-       # ideally we want !tc-ld-is-bfd for best future-proofing, but it needs
-       # https://github.com/gentoo/gentoo/pull/28355
-       # mold needs this too but right now tc-ld-is-mold is also not available
-       if tc-ld-is-lld; then
-               append-ldflags -Wl,--undefined-version
-       fi
+       append-ldflags $(test-flags-CCLD -Wl,--undefined-version)
 
        # Reported upstream: 
https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/120
        append-cflags -fcommon

Reply via email to