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 65314b8b6b380..ade2c6f349f66 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 @@ -48,6 +48,14 @@ OB git-r3_checkout } src_configure() { + # -Werror=strict-aliasing + # https://bugs.gentoo.org/856088 + # https://github.com/ROCm/clr/issues/64 + # + # Do not trust it for LTO either + append-flags -fno-strict-aliasing + filter-lto + # Fix ld.lld linker error: https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/155 append-ldflags $(test-flags-CCLD -Wl,--undefined-version) 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 8a2b71872bdc5..b6912994ddb73 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 @@ -48,6 +48,14 @@ OB git-r3_checkout } src_configure() { + # -Werror=strict-aliasing + # https://bugs.gentoo.org/856088 + # https://github.com/ROCm/clr/issues/64 + # + # Do not trust it for LTO either + append-flags -fno-strict-aliasing + filter-lto + # Fix ld.lld linker error: https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/155 append-ldflags $(test-flags-CCLD -Wl,--undefined-version) 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 878cf8bbc33d9..1ca30c8a10aeb 100644 --- a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-9999.ebuild +++ b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-9999.ebuild @@ -59,6 +59,14 @@ src_prepare() { } src_configure() { + # -Werror=strict-aliasing + # https://bugs.gentoo.org/856088 + # https://github.com/ROCm/clr/issues/64 + # + # Do not trust it for LTO either + append-flags -fno-strict-aliasing + filter-lto + # Fix ld.lld linker error: https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/155 append-ldflags $(test-flags-CCLD -Wl,--undefined-version)