From dacbed530e835aa0403ee49a340fff4370cd028e Mon Sep 17 00:00:00 2001 From: "Sv. Lockal" Date: Sat, 22 Nov 2025 19:29:27 +0800 Subject: [PATCH] dev-util/hip: do not include stdlibc++ file in HIPRTC header When any hip header included with -D__HIPCC_RTC__, it means that compiler was launched with -E -P to produce a preprocessed header. In this case not a single libstdc++ header can be used, otherwise it causes function redefinition on next attempt to include the same header elsewhere. Closes: https://bugs.gentoo.org/966188 Signed-off-by: Sv. Lockal Part-of: https://github.com/gentoo/gentoo/pull/44725 Signed-off-by: Sam James --- dev-util/hip/files/hip-6.4.1-no-glibcxx-assert.patch | 2 +- dev-util/hip/{hip-6.4.3-r1.ebuild => hip-6.4.3-r2.ebuild} | 0 dev-util/hip/{hip-7.0.2.ebuild => hip-7.0.2-r1.ebuild} | 0 dev-util/hip/{hip-7.1.0.ebuild => hip-7.1.0-r1.ebuild} | 0 4 files changed, 1 insertion(+), 1 deletion(-) rename dev-util/hip/{hip-6.4.3-r1.ebuild => hip-6.4.3-r2.ebuild} (100%) rename dev-util/hip/{hip-7.0.2.ebuild => hip-7.0.2-r1.ebuild} (100%) rename dev-util/hip/{hip-7.1.0.ebuild => hip-7.1.0-r1.ebuild} (100%) diff --git a/dev-util/hip/files/hip-6.4.1-no-glibcxx-assert.patch b/dev-util/hip/files/hip-6.4.1-no-glibcxx-assert.patch index b73c5cad8dbb..9a3c673a92e6 100644 --- a/dev-util/hip/files/hip-6.4.1-no-glibcxx-assert.patch +++ b/dev-util/hip/files/hip-6.4.1-no-glibcxx-assert.patch @@ -13,7 +13,7 @@ Bug: https://bugs.gentoo.org/955623 #define __HIP_HAS_GET_PCH ${_pchStatus}\n + +// Workaround for https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115740 -+#if defined(__has_include) && defined(__cplusplus) && defined(__HIP__) ++#if defined(__has_include) && defined(__cplusplus) && defined(__HIP__) && !defined(__HIPCC_RTC__) + #if __has_include(\"bits/c++config.h\") + #include + #undef __glibcxx_assert diff --git a/dev-util/hip/hip-6.4.3-r1.ebuild b/dev-util/hip/hip-6.4.3-r2.ebuild similarity index 100% rename from dev-util/hip/hip-6.4.3-r1.ebuild rename to dev-util/hip/hip-6.4.3-r2.ebuild diff --git a/dev-util/hip/hip-7.0.2.ebuild b/dev-util/hip/hip-7.0.2-r1.ebuild similarity index 100% rename from dev-util/hip/hip-7.0.2.ebuild rename to dev-util/hip/hip-7.0.2-r1.ebuild diff --git a/dev-util/hip/hip-7.1.0.ebuild b/dev-util/hip/hip-7.1.0-r1.ebuild similarity index 100% rename from dev-util/hip/hip-7.1.0.ebuild rename to dev-util/hip/hip-7.1.0-r1.ebuild