Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 631398 - dev-util/android-tools-6.0.1_p79 - /usr/lib64/ruby/2.1.0/rubygems.rb:15:in `require': cannot load such file -- rubygems/compatibility (LoadError)
Summary: dev-util/android-tools-6.0.1_p79 - /usr/lib64/ruby/2.1.0/rubygems.rb:15:in `r...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Zac Medico
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-09-19 09:08 UTC by Dennis Schridde
Modified: 2017-09-19 19:40 UTC (History)
0 users

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


Attachments
build.log (build.log,2.76 KB, text/x-log)
2017-09-19 09:08 UTC, Dennis Schridde
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Dennis Schridde 2017-09-19 09:08:29 UTC
Created attachment 495390 [details]
build.log

>>> Compiling source in /var/tmp/portage/dev-util/android-tools-6.0.1_p79/work ...         
/usr/lib64/ruby/2.1.0/rubygems.rb:15:in `require': cannot load such file -- rubygems/compatibility (LoadError)                                                                        
    from /usr/lib64/ruby/2.1.0/rubygems.rb:15:in `<top (required)>'                        
    from <internal:gem_prelude>:1:in `require'                                             
    from <internal:gem_prelude>:1:in `<compiled>'

# emerge --info android-tools rubygems
Portage 2.3.8 (python 2.7.13-final-42, default/linux/amd64/13.0/desktop/plasma/systemd, gcc-6.4.0, glibc-2.25-r5, 4.13.2-gentoo x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-4.13.2-gentoo-x86_64-AMD_A10-7800_Radeon_R7,_12_Compute_Cores_4C+8G-with-gentoo-2.4.1
KiB Mem:    14352760 total,   3307284 free
KiB Swap:          0 total,         0 free
Timestamp of repository gentoo: Tue, 19 Sep 2017 06:45:01 +0000
Head commit of repository gentoo: 70c0da4c651c629eba8f740f5cae47f3e3d630f9
sh bash 4.4_p12
ld GNU ld (Gentoo 2.28.1 p1.0) 2.28.1
ccache version 3.3.4 [disabled]
app-shells/bash:          4.4_p12::gentoo
dev-java/java-config:     2.2.0-r3::gentoo
dev-lang/perl:            5.24.2::gentoo
dev-lang/python:          2.7.13-r100::sage-on-gentoo, 3.4.6::gentoo, 3.5.3::gentoo, 3.6.1-r1::gentoo
dev-util/ccache:          3.3.4-r1::gentoo
dev-util/cmake:           3.9.2::gentoo
dev-util/pkgconfig:       0.29.2::gentoo
sys-apps/baselayout:      2.4.1-r2::gentoo
sys-apps/sandbox:         2.10-r4::gentoo
sys-devel/autoconf:       2.13::gentoo, 2.69-r4::gentoo
sys-devel/automake:       1.11.6-r2::gentoo, 1.13.4-r1::gentoo, 1.15.1-r1::gentoo
sys-devel/binutils:       2.28.1::gentoo, 2.29::gentoo
sys-devel/gcc:            5.4.0-r3::gentoo, 6.4.0::gentoo
sys-devel/gcc-config:     1.8-r1::gentoo
sys-devel/libtool:        2.4.6-r4::gentoo
sys-devel/make:           4.2.1-r1::gentoo
sys-kernel/linux-headers: 4.13::gentoo (virtual/os-headers)
sys-libs/glibc:           2.25-r5::gentoo
Repositories:

gentoo
    location: /var/cache/portage/gentoo
    sync-type: rsync
    sync-uri: rsync://rsync.de.gentoo.org/gentoo-portage
    priority: -1000

atom
    location: /var/lib/layman/atom
    sync-type: laymansync
    sync-uri: https://github.com/elprans/atom-overlay.git
    masters: gentoo
    priority: 50

flatpak-overlay
    location: /var/lib/layman/flatpak-overlay
    sync-type: laymansync
    sync-uri: git://github.com/fosero/flatpak-overlay.git
    masters: gentoo
    priority: 50

kde
    location: /var/lib/layman/kde
    sync-type: laymansync
    sync-uri: git://anongit.gentoo.org/proj/kde.git
    masters: gentoo
    priority: 50

sage-on-gentoo
    location: /var/lib/layman/sage-on-gentoo
    sync-type: laymansync
    sync-uri: git://github.com/cschwan/sage-on-gentoo.git
    masters: gentoo science
    priority: 50

science
    location: /var/lib/layman/science
    sync-type: laymansync
    sync-uri: git://anongit.gentoo.org/proj/sci.git
    masters: gentoo
    priority: 50

steam-overlay
    location: /var/lib/layman/steam-overlay
    sync-type: laymansync
    sync-uri: https://github.com/anyc/steam-overlay.git
    masters: gentoo
    priority: 50

local
    location: /var/cache/portage/local
    masters: gentoo
    priority: 100

ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-pipe -O2 -march=bdver3"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php7.1/ext-active/ /etc/php/cgi-php7.1/ext-active/ /etc/php/cli-php7.1/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-pipe -O2 -march=bdver3"
DISTDIR="/var/cache/portage/distfiles"
EMERGE_DEFAULT_OPTS="--keep-going --nospinner --verbose-conflicts"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs buildsyspkg cgroup compressdebug config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch parallel-install preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://ftp.spline.inf.fu-berlin.de/mirrors/gentoo/ http://ftp-stud.hs-esslingen.de/pub/Mirrors/gentoo/ http://distfiles.gentoo.org"
LANG="en_GB.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,--hash-style=gnu"
MAKEOPTS="-j3"
PKGDIR="/var/cache/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"
USE="X a52 aac aacplus aacs acl acpi activities alsa amd64 appindicator appstream archive audit avahi bash-completion bdplus berkdb bluetooth bluray branding bs2b bzip2 cairo caps cdda cddb cdio cdr celt chromaprint cjk clang cli colord colorio conntrack cracklib crypt cups cxx d3d9 dbus declarative dirac djvu dri dts dvb dvd dvdr egl emboss encode epub exif fam fax fbcon ffmpeg fftw firefox fish-completion fits flac fontconfig fortran fribidi gdbm geoclue geolocation gif git glamor gles gmp google googledrive gpm graphicsmagick gstreamer gtk gtk3 harfbuzz ibus iconv icu idn imlib inotify introspection ipv6 jemalloc jpeg jpeg2k kde kipi kwallet ladspa latex lcms ldap libidn2 libinput libnotify libproxy libsecret libsoxr lua_target_lua5-2 lv2 lz4 lzma lzo mad mercurial metis mjpeg mng mobi modemmanager modplug modules mp3 mp4 mpeg mplayer mtp multilib mysql ncurses netlink networkmanager nls nptl office ogg openal opencl opencv openexr opengl openh264 openmax openmp opus pam pango pcap pch pcre pcre2 pdf phonon plasma png policykit postscript ppds prison pulseaudio python qml qt3support qt4 qt5 raw readline rtmp samba scanner schroedinger sctp sdl seccomp semantic-desktop session sparse speech speex spell ssl startup-notification svg systemd tbb tcpd teamd telepathy tga theora threads tiff timezone truetype tslib udev udisks unicode unwind upnp upnp-av upower usb v4l v4l2 vaapi vdpau vorbis vpx vulkan wavpack wayland webp widgets x264 x265 xattr xcb xcomposite xinerama xkb xml xmp xrandr xscreensaver xv xvid xwayland xz zeroconf zlib" ABI_X86="64" ALSA_CARDS="hda-intel" 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_EXPERIMENTAL_FEATURES="stage" CALLIGRA_FEATURES="words sheets karbon plan" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx f16c fma3 fma4 mmx mmxext popcnt sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 xop" ELIBC="glibc" ENLIGHTENMENT_MODULES="*" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" GRUB_PLATFORMS="efi-64" INPUT_DEVICES="joystick libinput" KERNEL="linux" L10N="de en en-GB ar fa tr ja ko zh zh-CN zh-TW" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="de en en_GB ar fa tr" LIRC_DEVICES="devinput" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-6" POSTGRES_TARGETS="postgres9_5" PYTHON_SINGLE_TARGET="python3_4" PYTHON_TARGETS="python2_7 python3_4 python3_5 pypy pypy3" RUBY_TARGETS="ruby22" STEAMGAMES="dirt_rally dont_starve portal source_engine te120 trine2 witcher2" USERLAND="GNU" VIDEO_CARDS="amdgpu" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

=================================================================
                        Package Settings
=================================================================

dev-util/android-tools-6.0.1_p79::gentoo was built with the following:
USE="-libressl" ABI_X86="(64)"


dev-ruby/rubygems-2.6.13::gentoo was built with the following:
USE="-server -test" ABI_X86="(64)" RUBY_TARGETS="ruby22 -ruby23 -ruby24"
Comment 1 Dennis Schridde 2017-09-19 09:12:14 UTC
bug #585528 comment #4 might contain a clue how to fix this.
Comment 2 Zac Medico gentoo-dev 2017-09-19 17:37:57 UTC
I had this problem and it turned the reason was that I needed to use eselect ruby  to select the new version of ruby. You can check your installed versions of ruby with this command:

eselect ruby list

I think this command fixed it for me:

eselect ruby set ruby22
Comment 3 Dennis Schridde 2017-09-19 18:24:35 UTC
(In reply to Zac Medico from comment #2)
> I had this problem and it turned the reason was that I needed to use eselect
> ruby  to select the new version of ruby. You can check your installed
> versions of ruby with this command:
> 
> eselect ruby list
> 
> I think this command fixed it for me:
> 
> eselect ruby set ruby22

In bug #585528 comment #4 it was mentioned that the ebuild could fix this by depending on virtual/rubygems[${SAME_RUBY_VERSIONS_AS_THIS_PACKAGE}].
Comment 4 Zac Medico gentoo-dev 2017-09-19 18:36:17 UTC
(In reply to Dennis Schridde from comment #3)
> (In reply to Zac Medico from comment #2)
> > I had this problem and it turned the reason was that I needed to use eselect
> > ruby  to select the new version of ruby. You can check your installed
> > versions of ruby with this command:
> > 
> > eselect ruby list
> > 
> > I think this command fixed it for me:
> > 
> > eselect ruby set ruby22
> 
> In bug #585528 comment #4 it was mentioned that the ebuild could fix this by
> depending on virtual/rubygems[${SAME_RUBY_VERSIONS_AS_THIS_PACKAGE}].

The thing is, I had virtual/rubygems[ruby22] installed when I hit this problem, so I had to manually run `eselect ruby set ruby22` in order to solve it. Later on the same day, dev-lang/ruby-2.1.9 got removed by emerge --depclean, so that might have solved it too.
Comment 5 Dennis Schridde 2017-09-19 18:50:30 UTC
(In reply to Zac Medico from comment #4)
> (In reply to Dennis Schridde from comment #3)
> > (In reply to Zac Medico from comment #2)
> > > I had this problem and it turned the reason was that I needed to use eselect
> > > ruby  to select the new version of ruby. You can check your installed
> > > versions of ruby with this command:
> > > 
> > > eselect ruby list
> > > 
> > > I think this command fixed it for me:
> > > 
> > > eselect ruby set ruby22
> > 
> > In bug #585528 comment #4 it was mentioned that the ebuild could fix this by
> > depending on virtual/rubygems[${SAME_RUBY_VERSIONS_AS_THIS_PACKAGE}].
> 
> The thing is, I had virtual/rubygems[ruby22] installed when I hit this
> problem, so I had to manually run `eselect ruby set ruby22` in order to
> solve it. Later on the same day, dev-lang/ruby-2.1.9 got removed by emerge
> --depclean, so that might have solved it too.

Is it possible to make the package use a specific Ruby binary? Otherwise I see no way to prevent more people running into this.
Comment 6 Zac Medico gentoo-dev 2017-09-19 18:57:05 UTC
I suppose the most robust approach would be for the ebuild to try with each available version of ruby, until it finds one that's not broken.
Comment 7 Dennis Schridde 2017-09-19 19:11:30 UTC
I believe Ruby 2.1 is not actually broken, it is just missing RubyGems. That's at least what eselect claims. And at least the latest RubyGems seems to support only Ruby >=2.2. So the suggestion of depending on rubygems and using one of the versions of Ruby that have RubyGems installed seems to be a viable route.
Comment 8 Larry the Git Cow gentoo-dev 2017-09-19 19:37:37 UTC
The bug has been closed via the following commit(s):

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

commit 107da21cdbb7f32f52206dd9f46a9eb0b2553588
Author:     Zac Medico <zmedico@gentoo.org>
AuthorDate: 2017-09-19 19:31:42 +0000
Commit:     Zac Medico <zmedico@gentoo.org>
CommitDate: 2017-09-19 19:37:31 +0000

    dev-util/android-tools: detect rubygems interpreter for bug 631398
    
    Fixes: https://bugs.gentoo.org/631398
    Package-Manager: Portage-2.3.8, Repoman-2.3.3

 dev-util/android-tools/android-tools-6.0.1_p79.ebuild | 14 +++++++++++---
 1 file changed, 11 insertions(+), 3 deletions(-)
Comment 9 Zac Medico gentoo-dev 2017-09-19 19:40:40 UTC
(In reply to Dennis Schridde from comment #7)
> I believe Ruby 2.1 is not actually broken, it is just missing RubyGems.

Seems that it used to work with Ruby 2.1 though, so I guess something has changed. I'd prefer not to break backward compatibility.

> That's at least what eselect claims. And at least the latest RubyGems seems
> to support only Ruby >=2.2. So the suggestion of depending on rubygems and
> using one of the versions of Ruby that have RubyGems installed seems to be a
> viable route.

I've updated it to depend on virtual/rubygems, and try all available ruby interpreters.