commit:     a489c482123d205d65a1c604bcaeb1eb49aee8f7
Author:     Hans de Graaff <graaff <AT> gentoo <DOT> org>
AuthorDate: Fri Apr 25 17:35:02 2025 +0000
Commit:     Hans de Graaff <graaff <AT> gentoo <DOT> org>
CommitDate: Fri Apr 25 17:36:32 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a489c482

dev-lang/ruby: use -std=gnu17

This avoids a compilation issue in ext/io/console.c when using certain
CFLAGS.

Bug: https://bugs.gentoo.org/945643
Signed-off-by: Hans de Graaff <graaff <AT> gentoo.org>

 dev-lang/ruby/ruby-3.3.8.ebuild | 4 ++++
 dev-lang/ruby/ruby-3.4.3.ebuild | 4 ++++
 2 files changed, 8 insertions(+)

diff --git a/dev-lang/ruby/ruby-3.3.8.ebuild b/dev-lang/ruby/ruby-3.3.8.ebuild
index 16215bb014ea..75988aaaaf0b 100644
--- a/dev-lang/ruby/ruby-3.3.8.ebuild
+++ b/dev-lang/ruby/ruby-3.3.8.ebuild
@@ -162,6 +162,10 @@ src_configure() {
        # as it's risky with newer compilers to leave it as it is.
        append-flags -fno-strict-aliasing
 
+       # Avoid a compile error with certain USE flag combinations when
+       # using std=gnu23, bug #945643.
+       append-flags -std=gnu17
+
        # Workaround for bug #938302
        if use systemtap && has_version 
"dev-debug/systemtap[-dtrace-symlink(+)]" ; then
                export DTRACE="${BROOT}"/usr/bin/stap-dtrace

diff --git a/dev-lang/ruby/ruby-3.4.3.ebuild b/dev-lang/ruby/ruby-3.4.3.ebuild
index b08126005b70..5099c6df0e76 100644
--- a/dev-lang/ruby/ruby-3.4.3.ebuild
+++ b/dev-lang/ruby/ruby-3.4.3.ebuild
@@ -176,6 +176,10 @@ src_configure() {
        # as it's risky with newer compilers to leave it as it is.
        append-flags -fno-strict-aliasing
 
+       # Avoid a compile error with certain USE flag combinations when
+       # using std=gnu23, bug #945643.
+       append-flags -std=gnu17
+
        # Workaround for bug #938302
        if use systemtap && has_version 
"dev-debug/systemtap[-dtrace-symlink(+)]" ; then
                export DTRACE="${BROOT}"/usr/bin/stap-dtrace

Reply via email to