Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 900929 - dev-lang/ruby-3.0.5 and 2.7.7: ebuilds fail to copy libs/binary into image subdir for install phase
Summary: dev-lang/ruby-3.0.5 and 2.7.7: ebuilds fail to copy libs/binary into image su...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal major (vote)
Assignee: Gentoo Ruby Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-03-12 12:14 UTC by Megas of Vecanti
Modified: 2023-04-10 08:21 UTC (History)
2 users (show)

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


Attachments
build.log (build.log,385.36 KB, text/plain)
2023-03-12 12:15 UTC, Megas of Vecanti
Details
Output of 'find /var/tmp/portage/dev-lang/ruby-3.0.5/image' (findoutput.txt,2.57 KB, text/plain)
2023-03-12 12:22 UTC, Megas of Vecanti
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Megas of Vecanti 2023-03-12 12:14:00 UTC
emerging dev-lang/ruby-3.0.5 and dev-lang/ruby-2.7.7 will successfully build the binary and libraries during the compile phase (as found in /var/tmp/portage/dev-lang/ruby-[version]/work) and create most of the relevant directory structure (in /var/tmp/portage/dev-lang/ruby-[version]/image) for installation--but the ruby[version] binary and libraries will not be installed within that structure; only the .bz2 documentation files will be.

As a result, when eselect-ruby is called it will find no interpreter (and everything that comes as a result of that).


Reproducible: Always

Steps to Reproduce:
1. 'ebuild /usr/portage/dev-lang/ruby/ruby-3.0.5.ebuild clean install'
2. 'find /var/tmp/portage/dev-lang/ruby-3.0.5/image'
3. View incomplete directory structure that would be/is installed

(Optionally see /var/tmp/portage/dev-lang/ruby-3.0.5/work for evidence that the libraries and binaries were, in fact, built.)
Actual Results:  
-image/usr/share/doc is both present and populated.
-image/usr/lib is present but not populated.
-image/usr/bin is not present.

Expected Results:  
Complete installation in the image subdir for installation by emerge and selection by eselect-ruby.

build.log and directory structure listing will be attached below.

emerge --info:

Portage 3.0.45.2 (python 3.10.10-final-0, default/linux/amd64/17.1/desktop/plasma, gcc-12, glibc-2.36-r7, 6.0.13-gentoo x86_64)
=================================================================
System uname: Linux-6.0.13-gentoo-x86_64-Intel-R-_Core-TM-_i5-6400_CPU_@_2.70GHz-with-glibc2.36
KiB Mem:    16353680 total,    280028 free
KiB Swap:   33553404 total,  25951740 free
Timestamp of repository gentoo: Sun, 12 Mar 2023 08:00:01 +0000
Head commit of repository gentoo: 4f308144f72b28418fcb34a27ab2563d55b40907
sh bash 5.1_p16-r2
ld GNU ld (Gentoo 2.39 p5) 2.39.0
ccache version 4.7.4 [disabled]
app-misc/pax-utils:        1.3.5::gentoo
app-shells/bash:           5.1_p16-r2::gentoo
dev-java/java-config:      2.3.1::gentoo
dev-lang/perl:             5.36.0-r1::gentoo
dev-lang/python:           3.9.16_p2::gentoo, 3.10.10_p2::gentoo, 3.11.2_p1::gentoo, 3.12.0_alpha6::gentoo
dev-lang/rust:             1.66.1::gentoo
dev-util/ccache:           4.7.4::gentoo
dev-util/cmake:            3.25.3::gentoo
dev-util/meson:            1.0.1::gentoo
sys-apps/baselayout:       2.13-r1::gentoo
sys-apps/openrc:           0.46::gentoo
sys-apps/sandbox:          2.30-r1::gentoo
sys-devel/autoconf:        2.13-r7::gentoo, 2.71-r5::gentoo
sys-devel/automake:        1.16.5::gentoo
sys-devel/binutils:        2.39-r4::gentoo, 2.40-r3::gentoo
sys-devel/binutils-config: 5.5::gentoo
sys-devel/clang:           15.0.6::gentoo
sys-devel/gcc:             11.3.1_p20221209::gentoo, 12.2.1_p20230121-r1::gentoo
sys-devel/gcc-config:      2.10::gentoo
sys-devel/libtool:         2.4.7-r1::gentoo
sys-devel/llvm:            14.0.6-r2::gentoo, 15.0.6::gentoo
sys-devel/make:            4.3::gentoo
sys-kernel/linux-headers:  6.2::gentoo (virtual/os-headers)
sys-libs/glibc:            2.36-r7::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000
    volatile: True
    sync-rsync-verify-metamanifest: yes
    sync-rsync-verify-max-age: 24
    sync-rsync-extra-opts: 
    sync-rsync-verify-jobs: 1

crossdev
    location: /var/db/repos/localrepo-crossdev
    masters: gentoo
    priority: 10
    volatile: False

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* dlj-1.1 skype-eula FUEL Oracle-BCLA-JavaSE RAR Google-TOS google-talkplugin google-chrome AdobeFlash-11.x"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/themes/oxygen-gtk/gtk-2.0"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php8.2/ext-active/ /etc/php/cgi-php8.2/ext-active/ /etc/php/cli-php8.2/ext-active/ /etc/php/fpm-php8.2/ext-active/ /etc/php/phpdbg-php8.2/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/splash /etc/terminfo"
CXXFLAGS="-O2 -pipe"
DISTDIR="/usr/portage/distfiles"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR XDG_STATE_HOME"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs binpkg-multi-instance buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="en_US"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LEX="flex"
LINGUAS="en ja"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
SHELL="/bin/bash"
USE="X a52 aac acl acpi activities alsa amd64 bluetooth branding bzip2 cairo cdda cdr cli crypt cups dbus declarative dri dts dvd dvdr elogind encode exif fbcondecor ffmpeg flac fortran gdbm gif gpm gtk gui iconv icu ipv6 jack jpeg kde kwallet lash lcms libburn libglvnd libnotify libtirpc lvm mad mmx mmxext mng mp3 mp4 mpeg multilib ncurses nls nptl nvidia ogg opengl openmp openrc pam pango pcre pdf plasma png policykit ppds pulseaudio qml qt5 readline screencast sdl seccomp semantic-desktop sound spell split-usr sse sse2 sse3 sse4_1 ssl ssse3 startup-notification svg test-rust tiff truetype udev udisks unicode upower usb vorbis widgets wxwidgets x264 xattr xcb xft xml xulrunner xv xvid zlib" ABI_X86="32 64" ADA_TARGET="gnat_2021" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx mmxext sse sse2 sse3 sse4_1 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="joystick mouse" KERNEL="linux" L10N="ja" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5 php7-0" POSTGRES_TARGETS="postgres12 postgres13" PYTHON_SINGLE_TARGET="python3_10" PYTHON_TARGETS="python3_10 python3_9" RUBY_TARGETS="ruby27 ruby30" USERLAND="GNU" VIDEO_CARDS="nvidia nouveau fbdev v4l vesa" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EMERGE_DEFAULT_OPTS, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LFLAGS, LIBTOOL, MAKE, MAKEFLAGS, MAKEOPTS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS
Comment 1 Megas of Vecanti 2023-03-12 12:15:52 UTC
Created attachment 857393 [details]
build.log

build.log (dev-lang/ruby-3.0.5)
Comment 2 Megas of Vecanti 2023-03-12 12:22:01 UTC
Created attachment 857395 [details]
Output of 'find /var/tmp/portage/dev-lang/ruby-3.0.5/image'

Output of 'find /var/tmp/portage/dev-lang/ruby-3.0.5/image' following ebuild completion.

Note absence of /usr/bin and all files within /usr/lib64/ruby structure.
Comment 3 Megas of Vecanti 2023-03-12 12:23:48 UTC
Added Gentoo Ruby Team (at request of tirnanog on Gentoo IRC)
Comment 4 Chiitoo gentoo-dev 2023-03-15 16:37:43 UTC
Not sure if interesting or not, but from a quick look, while in the configuration summary I have:

'BASERUBY -v: riby 3.0.5p211 [...]'

and later

'BASERUBY = /usr/bin/ruby --disable=gems'

in the log here the summary part doesn't have BASERUBY at all, and later:

'BASERUBY = echo executable host ruby is required.  use --with-baseruby option.; false'

which seems quite weird indeed... or maybe it is normal.  :]
Comment 5 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-04-10 07:36:45 UTC
(In reply to Chiitoo from comment #4)
> Not sure if interesting or not, but from a quick look, while in the
> configuration summary I have:
> 
> 'BASERUBY -v: riby 3.0.5p211 [...]'
> 
> and later
> 
> 'BASERUBY = /usr/bin/ruby --disable=gems'
> 
> in the log here the summary part doesn't have BASERUBY at all, and later:
> 
> 'BASERUBY = echo executable host ruby is required.  use --with-baseruby
> option.; false'
> 
> which seems quite weird indeed... or maybe it is normal.  :]

I've fixed that part at least, it now always uses the just-built ruby.
Comment 6 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-04-10 07:37:29 UTC
>--extout=".ext" --mflags="-j4 -Oline --jobserver-auth=4,5"

I'll be.
Comment 7 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-04-10 08:15:56 UTC
I want to add a sanity check for this but I couldn't reproduce it, but I've seen enough reports and I can see how it'd happen with how Ruby's build system interacts with MAKEOPTS and friends.
Comment 8 Larry the Git Cow gentoo-dev 2023-04-10 08:21:26 UTC
The bug has been closed via the following commit(s):

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

commit e86df55fc08f6fb8ececc9001e9f25187b8d3eff
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2023-04-10 08:16:19 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2023-04-10 08:20:29 +0000

    dev-lang/ruby: filter out -Oline from MAKEOPTS, GNUMAKEFLAGS
    
    Sorry for another revbump in such a short period (although maybe it's not so
    bad given very few people will have upgraded yet).
    
    Newer Portage sets GNUMAKEFLAGS="--output-sync=line" if MAKEOPTS is unset. It looks
    like this sometimes leads to Ruby installing no files (or just docs). Filter it out
    and just parse out --jobs and --load-average from MAKEOPTS.
    
    This is behind at least two reports on Bugzilla and possibly another on the
    forums.
    
    Closes: https://bugs.gentoo.org/728424
    Closes: https://bugs.gentoo.org/900929
    Signed-off-by: Sam James <sam@gentoo.org>

 dev-lang/ruby/{ruby-2.7.8-r2.ebuild => ruby-2.7.8-r3.ebuild} | 11 ++++++++++-
 dev-lang/ruby/{ruby-3.0.6-r1.ebuild => ruby-3.0.6-r2.ebuild} | 11 ++++++++++-
 dev-lang/ruby/{ruby-3.1.4-r1.ebuild => ruby-3.1.4-r2.ebuild} | 11 ++++++++++-
 dev-lang/ruby/{ruby-3.2.2-r1.ebuild => ruby-3.2.2-r2.ebuild} | 11 ++++++++++-
 4 files changed, 40 insertions(+), 4 deletions(-)