Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 787137 - dev-lang/ruby-2.7.3-r1 fails to compile
Summary: dev-lang/ruby-2.7.3-r1 fails to compile
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Ruby Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-04-30 13:25 UTC by Agostino Sarubbo
Modified: 2023-04-10 04:53 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,38.44 KB, text/plain)
2021-04-30 13:25 UTC, Agostino Sarubbo
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Agostino Sarubbo gentoo-dev 2021-04-30 13:25:07 UTC
https://blogs.gentoo.org/ago/2020/07/04/gentoo-tinderbox/

Issue: dev-lang/ruby-2.7.3-r1 fails to compile.
Discovered on: amd64 (internal ref: tinderbox)

NOTE:
This machine uses GCC-11: https://gcc.gnu.org/gcc-11/porting_to.html
If you think this is a GCC-11 related issue, please block bug 732706.
Comment 1 Agostino Sarubbo gentoo-dev 2021-04-30 13:25:10 UTC
Created attachment 704436 [details]
build.log

build log and emerge --info
Comment 2 Magnus Granberg gentoo-dev 2021-04-30 21:44:09 UTC
* Package:    dev-lang/ruby-2.7.3-r1
 * Repository: gentoo
 * Maintainer: ruby@gentoo.org
 * USE:        abi_x86_64 amd64 berkdb elibc_glibc gdbm ipv6 kernel_linux rdoc ssl userland_GNU
 * FEATURES:   network-sandbox preserve-libs sandbox userpriv usersandbox
>>> Unpacking source...
>>> Unpacking ruby-2.7.3.tar.xz to /var/tmp/portage/dev-lang/ruby-2.7.3-r1/work
>>> Source unpacked in /var/tmp/portage/dev-lang/ruby-2.7.3-r1/work
>>> Preparing source in /var/tmp/portage/dev-lang/ruby-2.7.3-r1/work/ruby-2.7.3 ...
 * Applying 002-autoconf-2.70.patch ...
 * Applying 003-did-you-mean.patch ...
 * Applying 010-default-gem-location.patch ...
 * Unbundling gems...
 * Removing bundled libraries...
 * Running eautoreconf in '/var/tmp/portage/dev-lang/ruby-2.7.3-r1/work/ruby-2.7.3' ...
 * Running 'aclocal' ...
 * Running 'autoconf --force' ...
 * Running elibtoolize in: ruby-2.7.3/
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/dev-lang/ruby-2.7.3-r1/work/ruby-2.7.3 ...
 * econf: updating ruby-2.7.3/config.guess with /usr/share/gnuconfig/config.guess
 * econf: updating ruby-2.7.3/tool/config.guess with /usr/share/gnuconfig/config.guess
 * econf: updating ruby-2.7.3/tool/config.sub with /usr/share/gnuconfig/config.sub
 * econf: updating ruby-2.7.3/config.sub with /usr/share/gnuconfig/config.sub
>>> Source configured.
>>> Compiling source in /var/tmp/portage/dev-lang/ruby-2.7.3-r1/work/ruby-2.7.3 ...
make: *** [uncommon.mk:1088: miniprelude.c] Error 1
 * ERROR: dev-lang/ruby-2.7.3-r1::gentoo failed (compile phase):

Confirmed on my buildbot tinderbox with gcc 11
Comment 3 Larry the Git Cow gentoo-dev 2021-05-01 06:12:14 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=81f9f39f05b60fc25865aa4d5b103cd90701f4e6

commit 81f9f39f05b60fc25865aa4d5b103cd90701f4e6
Author:     Hans de Graaff <graaff@gentoo.org>
AuthorDate: 2021-05-01 06:12:03 +0000
Commit:     Hans de Graaff <graaff@gentoo.org>
CommitDate: 2021-05-01 06:12:10 +0000

    dev-lang/ruby: fix build during bootstrap
    
    Fix building during a bootstrap situation where no ruby is present yet.
    Normally ruby uses a pregenerated miniprelude.c file for a miniruby that
    is functional enough to assist the build process. Since we now patch
    gem_prelude.rb in f6aa0fc2dcee195658e697026e607dbb91bfd31d the Makefile
    tries to regenerate miniprelude.c, but this first requires a working
    ruby, leading to build failures.
    
    By resetting the date of the patched gem_prelude.c we can avoid this.
    The gem_predule.rb patch is intended to be used in an installed ruby and
    does not affect the miniruby usage.
    
    Closes: https://bugs.gentoo.org/787137
    Package-Manager: Portage-3.0.18, Repoman-3.0.2
    Signed-off-by: Hans de Graaff <graaff@gentoo.org>

 dev-lang/ruby/ruby-2.7.3-r1.ebuild | 4 ++++
 1 file changed, 4 insertions(+)
Comment 4 Larry the Git Cow gentoo-dev 2023-04-10 04:53:19 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cb9cc405d80a17e2b5329672c871e24d82cfb61e

commit cb9cc405d80a17e2b5329672c871e24d82cfb61e
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2023-04-10 04:51:12 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2023-04-10 04:52:35 +0000

    dev-lang/ruby: don't use baseruby; add HPPA-only fix
    
    1. Disable use of baseruby. This causes breakage if a previous Ruby is installed
    without rubygems like in bug #883097. We've had issues like this in the past
    in bug #787137 too.
    
    2. Add a fix which is ifdef'd for HPPA (upstream variant isn't, but let's
    be more conservative until it's merged there) to fix stack size allocation. This
    fixes tests for both Ruby and a bunch of Ruby packages.
    
    Bug: https://bugs.gentoo.org/787137
    Closes: https://bugs.gentoo.org/701494
    Closes: https://bugs.gentoo.org/883097
    Signed-off-by: Sam James <sam@gentoo.org>

 .../files/2.7/902-hppa-pthread-stack-size.patch    |  54 ++++
 .../files/3.0/902-hppa-pthread-stack-size.patch    |  54 ++++
 .../files/3.1/902-hppa-pthread-stack-size.patch    |  54 ++++
 .../files/3.2/902-hppa-pthread-stack-size.patch    |  54 ++++
 dev-lang/ruby/ruby-2.7.8-r1.ebuild                 | 274 +++++++++++++++++++++
 dev-lang/ruby/ruby-3.0.6-r1.ebuild                 | 269 ++++++++++++++++++++
 dev-lang/ruby/ruby-3.1.4-r1.ebuild                 | 253 +++++++++++++++++++
 dev-lang/ruby/ruby-3.2.2-r1.ebuild                 | 272 ++++++++++++++++++++
 8 files changed, 1284 insertions(+)