Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 881157 - www-client/firefox-106.0.5 - Rust is using LLVM version 15 but ld.lld version belongs to LLVM version 14
Summary: www-client/firefox-106.0.5 - Rust is using LLVM version 15 but ld.lld version...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Mozilla Gentoo Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-11-13 02:49 UTC by immolo
Modified: 2022-11-15 09:19 UTC (History)
2 users (show)

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


Attachments
build.log and additional system infomation (firefox.build.log,6.65 KB, text/x-log)
2022-11-13 02:51 UTC, immolo
Details

Note You need to log in before you can comment on or make changes to this bug.
Description immolo 2022-11-13 02:49:03 UTC
With the version bump to Rust-1.65.0 I was unable to compile Firefox anymore as ld.lld was compiled for LLVM-15 but the Firefox ebuild wants to use llvm-14.

I followed the steps listed in the error but the only thing that fixed it was changing the LLVM slot to 15 in the Firefox ebuild and then I had a successful compile and have not found any issues using Firefox so far with this change.

This is my findings and solution however I'm not sure how this could effect other systems and arches so suggestions for a better fix is welcome.    

Reproducible: Always

Steps to Reproduce:
From clean stage3:
1. Add ACCEPT_KEYWORDS="~amd64" to make.conf
2. run emerge -vauDN @world
3. emerge firefox
Actual Results:  
Build failure - Rust is using LLVM version 15 but ld.lld version belongs to LLVM version 14


I've currently tested this on an ~amd64 LTO enabled GLIBC system and have a similar MUSL system testing this now.
Comment 1 immolo 2022-11-13 02:49:35 UTC
emerge --info
Portage 3.0.38.1 (python 3.10.8-final-0, default/linux/amd64/17.1/desktop, gcc-12, glibc-2.36-r5, 5.19.16-gentoo-dist x86_64)
=================================================================
System uname: Linux-5.19.16-gentoo-dist-x86_64-Intel-R-_Core-TM-_i7-6700K_CPU_@_4.00GHz-with-glibc2.36
KiB Mem:    16349072 total,  10899400 free
KiB Swap:   16777212 total,  16190716 free
Head commit of repository gentoo: b14315d85f599afd00c1343732dcb175fe4a9ffc

Timestamp of repository steam-overlay: Thu, 20 Oct 2022 06:32:14 +0000
Head commit of repository steam-overlay: f40a22632e77a46be0153821f4a7f7847029533b

sh bash 5.1_p16-r2
ld GNU ld (Gentoo 2.39 p5) 2.39.0
distcc 3.4 x86_64-pc-linux-gnu [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.10.8_p3::gentoo, 3.11.0_p2::gentoo, 3.12.0_alpha1_p2::gentoo
dev-lang/rust:             1.65.0::gentoo
dev-util/cmake:            3.24.3::gentoo
dev-util/meson:            0.64.0::gentoo
sys-apps/baselayout:       2.9::gentoo
sys-apps/openrc:           0.45.2-r1::gentoo
sys-apps/sandbox:          2.29::gentoo
sys-devel/autoconf:        2.13-r7::gentoo, 2.71-r4::gentoo
sys-devel/automake:        1.16.5::gentoo
sys-devel/binutils:        2.39-r4::gentoo
sys-devel/binutils-config: 5.4.1::gentoo
sys-devel/clang:           14.0.6-r1::gentoo, 15.0.4::gentoo
sys-devel/gcc:             12.2.1_p20221008::gentoo
sys-devel/gcc-config:      2.8::gentoo
sys-devel/libtool:         2.4.7::gentoo
sys-devel/lld:             14.0.6-r1::gentoo, 15.0.4::gentoo
sys-devel/llvm:            14.0.6-r2::gentoo, 15.0.4::gentoo
sys-devel/make:            4.4::gentoo
sys-kernel/linux-headers:  6.0::gentoo (virtual/os-headers)
sys-libs/glibc:            2.36-r5::gentoo
Repositories:

gentoo
    location: /var/db/repos/gentoo
    sync-type: git
    sync-uri: https://github.com/gentoo/gentoo.git
    sync-user: portage:portage
    priority: -1000

cinnamon
    location: /var/db/repos/cinnamon
    masters: gentoo

steam-overlay
    location: /var/db/repos/steam-overlay
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/steam-overlay.git
    masters: gentoo

ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -pipe -fgraphite-identity -floop-nest-optimize -flto=8 -fuse-linker-plugin -falign-functions=32"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /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/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=native -O2 -pipe -fgraphite-identity -floop-nest-optimize -flto=8 -fuse-linker-plugin -falign-functions=32"
DISTDIR="/var/cache/distfiles"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY 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="-march=native -O2 -pipe -fgraphite-identity -floop-nest-optimize -flto=8 -fuse-linker-plugin -falign-functions=32"
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="-march=native -O2 -pipe -fgraphite-identity -floop-nest-optimize -flto=8 -fuse-linker-plugin -falign-functions=32"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="en_GB.utf8"
LDFLAGS="-fuse-ld=mold -Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j8"
PKGDIR="/var/cache/binpkgs"
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="/home/portage"
RUSTFLAGS="-C target-cpu=native"
SHELL="/bin/bash"
USE="X a52 aac acl acpi alsa amd64 bluetooth branding bzip2 cairo cdda cdr cli crypt cups d3d9 dbus dist-kernel dri dts dvd dvdr elogind encode evdev exif flac fortran gdbm gif gpm graphite gtk gtk3 gui iconv icu introspection ipv6 jpeg lcms libglvnd libnotify libtirpc lto mad mng mp3 mp4 mpeg multilib ncurses nls nptl ogg opengl openmp pam pango pcre pdf pgo png policykit ppds pulseaudio readline sdl seccomp spell split-usr ssl startup-notification svg test-rust tiff truetype udev udisks unicode upower usb vaapi vdpau vorbis vulkan vulkan-overlay wxwidgets x264 xattr xcb xinerama xml xv xvid zlib" ABI_X86="64 32" ADA_TARGET="gnat_2020" 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 aes avx avx2 f16c fma3 pclmul popcnt rdrand sse3 sse4_1 sse4_2 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="lininput evdev joystick" KERNEL="linux" L10N="en en-GB" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LLVM_TARGETS="X86" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-4 php8-0" POSTGRES_TARGETS="postgres12 postgres13" PYTHON_SINGLE_TARGET="python3_10" PYTHON_TARGETS="python3_10" QEMU_SOFTMMU_TARGETS="ppc ppc64le mips mipsel mips64 x86_64 i386" QEMU_USER_TARGETS="i386 ppc64le ppc ppc64 riscv32 riscv64 x86_64 mips mipsel mips64" RUBY_TARGETS="ruby27" USERLAND="GNU" VIDEO_CARDS="nvidia intel" 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, LEX, LFLAGS, LIBTOOL, LINGUAS, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RANLIB, READELF, SIZE, STRINGS, STRIP, YACC, YFLAGS
Comment 2 immolo 2022-11-13 02:51:43 UTC
Created attachment 832205 [details]
build.log and additional system infomation
Comment 3 immolo 2022-11-13 14:17:56 UTC
Update:

Doesn't currently seem to trigger on my Musl system and the www-client/firefox-106.0.5 update completed without any fixes.

I'll include the emerge --info for this system in the hopes it sheds some light.

# emerge --info
Portage 3.0.38.1 (python 3.10.8-final-0, default/linux/amd64/17.0/musl, gcc-12, musl-1.2.3-r5, 5.19.11-gentoo-x86_64 x86_64)
=================================================================
System uname: Linux-5.19.11-gentoo-x86_64-x86_64-Intel-R-_Core-TM-_i5-5300U_CPU_@_2.30GHz-with-libc
KiB Mem:     8018444 total,   3673244 free
KiB Swap:    8388604 total,   8319484 free
Timestamp of repository gentoo: Sun, 13 Nov 2022 14:00:01 +0000
Head commit of repository gentoo: 5b116edf081f24bcd36914ba92d8269c2a480ac0
Timestamp of repository musl: Thu, 10 Nov 2022 17:16:47 +0000
Head commit of repository musl: 0ef60ce275097b4532736951914849ac11cafeed

sh bash 5.1_p16-r2
ld GNU ld (Gentoo 2.39 p5) 2.39.0
app-misc/pax-utils:        1.3.5::gentoo
app-shells/bash:           5.1_p16-r2::gentoo
dev-lang/perl:             5.36.0-r1::gentoo
dev-lang/python:           3.10.8_p3::gentoo, 3.11.0_p2::gentoo
dev-lang/rust:             1.65.0::gentoo
dev-util/cmake:            3.24.3::gentoo
dev-util/meson:            0.64.0::gentoo
sys-apps/baselayout:       2.9::gentoo
sys-apps/openrc:           0.45.2-r1::gentoo
sys-apps/sandbox:          2.29::gentoo
sys-devel/autoconf:        2.13-r7::gentoo, 2.71-r4::gentoo
sys-devel/automake:        1.16.5::gentoo
sys-devel/binutils:        2.39-r4::gentoo
sys-devel/binutils-config: 5.4.1::gentoo
sys-devel/clang:           14.0.6-r1::gentoo, 15.0.4::gentoo
sys-devel/gcc:             12.2.1_p20221008::gentoo
sys-devel/gcc-config:      2.8::gentoo
sys-devel/libtool:         2.4.7::gentoo
sys-devel/llvm:            14.0.6-r2::gentoo, 15.0.4::gentoo
sys-devel/make:            4.4::gentoo
sys-kernel/linux-headers:  6.0::gentoo (virtual/os-headers)
sys-libs/musl:             1.2.3-r5::gentoo
Repositories:

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

musl
    location: /var/db/repos/musl
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/musl.git
    masters: gentoo

ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-gentoo-linux-musl"
CFLAGS="-march=broadwell -O2 -pipe -fgraphite-identity -floop-nest-optimize -flto=4 -fuse-linker-plugin -falign-functions=32"
CHOST="x86_64-gentoo-linux-musl"
CONFIG_PROTECT="/etc /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/sandbox.d /etc/terminfo"
CXXFLAGS="-march=broadwell -O2 -pipe -fgraphite-identity -floop-nest-optimize -flto=4 -fuse-linker-plugin -falign-functions=32"
DISTDIR="/var/cache/distfiles"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY 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="-march=broadwell -O2 -pipe -fgraphite-identity -floop-nest-optimize -flto=4 -fuse-linker-plugin -falign-functions=32"
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 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="-march=broadwell -O2 -pipe -fgraphite-identity -floop-nest-optimize -flto=4 -fuse-linker-plugin -falign-functions=32"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
INSTALL_MASK="charset.alias /usr/share/locale/locale.alias"
LANG="C.UTF8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j4"
PKGDIR="/var/cache/binpkgs"
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"
RUSTFLAGS="-C target-cpu=native"
SHELL="/bin/bash"
USE="X acl amd64 bluetooth bzip2 cairo cli crypt d3d9 dbus dri elogind fortran gif gnome-keyring graphite gtk iconv ipv6 libglvnd libtirpc logrotate lto ncurses networkmanager nls nptl openmp pam pcre pgo pulseaudio readline seccomp spell split-usr ssl startup-notification test-rust udisks unicode vulkan xattr zlib" ABI_X86="64" ADA_TARGET="gnat_2020" 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" ELIBC="musl" 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="libinput" KERNEL="linux" L10N="en en-GB" 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="php7-4 php8-0" POSTGRES_TARGETS="postgres12 postgres13" PYTHON_SINGLE_TARGET="python3_10" PYTHON_TARGETS="python3_10" RUBY_TARGETS="ruby27" USERLAND="GNU" VIDEO_CARDS="intel" 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, LC_ALL, LD, LEX, LFLAGS, LIBTOOL, LINGUAS, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RANLIB, READELF, SIZE, STRINGS, STRIP, YACC, YFLAGS
Comment 4 Joonas Niilola gentoo-dev 2022-11-14 15:08:10 UTC
Well, this bug is INVALID - the check is working right as it should. Unfortunately every time rust bumps its llvm compat it's a mess for these rust-llvm-sensitive projects (mozilla...)

To fix it, it'd require a revbump to Firefox. A revbump would also force people who have previously successfully installed the browser to rebuild it. Then again not revbumping could cause issues that are slightly harder to debug, and would require users to do manual steps working around those issues. So the best option is really to wait for the next browser releases from upstream - which should happen tomorrow.

We really need to figure some way of tackling this problem, but it's really a hard one to solve.
Comment 5 immolo 2022-11-14 15:23:25 UTC
Fair point on the INVALID, I wasn't sure how to report this one so went for the one people would end up searching.

107 should be out in a few weeks to solve this fully but at least this lists the workaround needed for those that want it in the meantime or when it will be officially solved.

> We really need to figure some way of tackling this problem, but it's really a hard one to solve.

With how many times I've seen it mentioned from previous versions I think really hard is an understatement.
Comment 6 Joonas Niilola gentoo-dev 2022-11-14 15:57:32 UTC
(In reply to immolo from comment #5)
> Fair point on the INVALID, I wasn't sure how to report this one so went for
> the one people would end up searching.

Yep, that's why I also left it open

> 
> 107 should be out in a few weeks to solve this fully 

* few hours ;) yeah it should solve issues with rust-1.65. Until the next bump...
Comment 7 immolo 2022-11-14 16:03:35 UTC
That quick? Thanks for all you (and team) do as that is pretty impressive for a turnaround time from how it was explained to me to test it.
Comment 8 Larry the Git Cow gentoo-dev 2022-11-15 09:19:17 UTC
The bug has been closed via the following commit(s):

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

commit 7d23d45fa5b8d455d06731db5aa81a5e2235ef4a
Author:     Joonas Niilola <juippis@gentoo.org>
AuthorDate: 2022-11-15 09:13:19 +0000
Commit:     Joonas Niilola <juippis@gentoo.org>
CommitDate: 2022-11-15 09:19:15 +0000

    www-client/firefox: add 107.0
    
     - depend on newly created virtual/rust:0/llvm-* in order to try and avoid
       mixing these sensitive rust-llvm-lld mismatches - esr and tb will follow,
     - update LLVM compatibility to 15.
    
    Closes: https://bugs.gentoo.org/881157
    Signed-off-by: Joonas Niilola <juippis@gentoo.org>

 www-client/firefox/Manifest             |   99 +++
 www-client/firefox/firefox-107.0.ebuild | 1324 +++++++++++++++++++++++++++++++
 2 files changed, 1423 insertions(+)