Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 789981 - www-client/seamonkey-2.53.7.1-r1 fails to build when rust >= 1.52.0, due to packed_simd requesting bootstrap
Summary: www-client/seamonkey-2.53.7.1-r1 fails to build when rust >= 1.52.0, due to p...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Lars Wendler (Polynomial-C) (RETIRED)
URL: http://www.wg9s.com/comm-253/patches/...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-05-13 14:42 UTC by Joseph
Modified: 2021-05-14 10:17 UTC (History)
3 users (show)

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


Attachments
build.log (compressed) (build.log.xz,98.03 KB, application/x-xz)
2021-05-13 14:42 UTC, Joseph
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Joseph 2021-05-13 14:42:23 UTC
For security reasons, Rust no longer allows packages to bootstrap themselves. If they need bootstrap, it has to be requested via an external environment variable.[1]

This may be fixed in the most recent version of packed_simd; apparently the old cargo.io maintainer is gone, and the new ones don't have access.[2] This is likely worth fixing generally.


[1] https://www.linuxfromscratch.org/blfs/view/svn/xsoft/seamonkey.html
[2] https://github.com/hsivonen/packed_simd/blob/master/README.md

Reproducible: Always

Steps to Reproduce:
1. {,re-}emerge seamonkey
2. wait for it to fail
3. sift through the ashes of the ruins of your aspirations of running Seamonkey
Actual Results:  
error: Cannot set `RUSTC_BOOTSTRAP=1` from build script of `packed_simd v0.3.4 (https://github.com/hsivonen/packed_simd?rev=0917fe780032a6bbb23d71be545f9c1834128d75#0917fe78)`.
note: Crates cannot set `RUSTC_BOOTSTRAP` themselves, as doing so would subvert the stability guarantees of Rust for your project.
help: If you're sure you want to do this in your project, set the environment variable `RUSTC_BOOTSTRAP=packed_simd` before running cargo instead.
warning: build failed, waiting for other jobs to finish...


Expected Results:  
Shiny new Seamonkey build

Portage 3.0.18 (python 3.9.5-final-0, default/linux/amd64/17.1/desktop/gnome/systemd, gcc-11.1.0, glibc-2.33, 5.11.16-gentoo x86_64)
=================================================================
System uname: Linux-5.11.16-gentoo-x86_64-Intel-R-_Core-TM-_i7-8550U_CPU_@_1.80GHz-with-glibc2.33
KiB Mem:    32762680 total,   5301816 free
KiB Swap:   46624764 total,  46201340 free
Timestamp of repository gentoo: Thu, 13 May 2021 13:30:01 +0000
Head commit of repository gentoo: 3ea23796f28d7ddf0d6e2077cec7d6479902b204
sh bash 5.1_p8
ld GNU ld (Gentoo 2.36.1 p3) 2.36.1
app-shells/bash:          5.1_p8::gentoo
dev-java/java-config:     2.3.1::gentoo
dev-lang/perl:            5.32.1::gentoo
dev-lang/python:          2.7.18_p10::gentoo, 3.7.10_p4::gentoo, 3.8.10_p1::gentoo, 3.9.5_p1::gentoo, 3.10.0_beta1::gentoo
dev-lang/rust:            1.52.1::gentoo
dev-util/cmake:           3.20.2::gentoo
dev-util/pkgconfig:       0.29.2::gentoo
sys-apps/baselayout:      2.7-r2::gentoo
sys-apps/sandbox:         2.24::gentoo
sys-devel/autoconf:       2.13-r1::gentoo, 2.69-r5::gentoo
sys-devel/automake:       1.16.3-r1::gentoo
sys-devel/binutils:       2.36.1-r1::gentoo
sys-devel/gcc:            11.1.0::gentoo
sys-devel/gcc-config:     2.4::gentoo
sys-devel/libtool:        2.4.6-r6::gentoo
sys-devel/make:           4.3::gentoo
sys-kernel/linux-headers: 5.12::gentoo (virtual/os-headers)
sys-libs/glibc:           2.33::gentoo
Repositories:

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

ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="@FREE"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe -march=native"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /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 /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-O2 -pipe -march=native"
DISTDIR="/usr/portage/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"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs binpkg-multi-instance 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="de_DE.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="en en_US de de_DE"
MAKEOPTS="-j9"
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"
USE="X a52 aac acl acpi alsa amd64 audit avahi bash-completion berkdb bluetooth branding bzip2 cairo caps cdda cddb cdr cli colord cracklib crypt cryptsetup css cups dbus directfb dri dts dv dvd dvdr eds emacs emboss encode evo exif fbcon filecaps flac fortran gdbm geoip geolocation gif gimp git gnome gnome-keyring gnome-online-accounts gnuplot gpg gphoto2 gpm gstreamer gtk gui guile gzip iconv icu idn imap inotify introspection ipv6 jpeg jpeg2k lcms libffi libglvnd libnotify libsecret libtirpc lm_sensors lua lzma lzo mad maildir mime mng modplug mp3 mp4 mpeg multilib nautilus ncurses networkmanager nls nntp nptl ocaml offensive ofx ogg opengl openmp pam pango pch pcre pdf perl png policykit postscript ppds pulseaudio python raw readline rss scanner sctp sdl seccomp session skey smartcard smp sound spell split-usr sqlite ssl startup-notification svg syslog sysprof systemd taglib tcpd theora threads tiff timidity tracker truetype udev udisks unicode upnp upnp-av upower usb v4l vaapi vala vdpau vim-syntax vorbis wayland webp wifi wxwidgets x264 xattr xcb xcomposite xinerama xml xmlrpc xmpp xv xvid zeroconf zlib zsh-completion" ABI_X86="64" ADA_TARGET="gnat_2018" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" 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="aes avx avx2 f16c fma3 mmx mmxext pclmul popcnt sse sse2 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="evdev keyboard mouse synaptics" KERNEL="linux" L10N="en en_US de de_DE" 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-3 php7-4" POSTGRES_TARGETS="postgres10 postgres11" PYTHON_SINGLE_TARGET="python3_9" PYTHON_TARGETS="python3_9" RUBY_TARGETS="ruby30" USERLAND="GNU" VIDEO_CARDS="intel fbdev 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:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RUSTFLAGS
Comment 1 Joseph 2021-05-13 14:42:49 UTC
Created attachment 708075 [details]
build.log (compressed)
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-05-13 14:45:06 UTC
CCing rust@ out of precaution.
Comment 3 Georgy Yakovlev archtester gentoo-dev 2021-05-13 17:18:07 UTC
https://github.com/rust-lang/cargo/pull/6608/files

yeah, it's normally not required for crates, but mozilla being mozilla using some unstable/forbidden features.

exporting or setting RUSTC_BOOTSTRAP=encoding_rs,packed_simd before build should allow this to work.
Comment 4 Georgy Yakovlev archtester gentoo-dev 2021-05-13 17:22:32 UTC
explanation, setting RUSTC_BOOTSTRAP allows to use -Z flags (nightly unstable flags) without compiler being marked as nightly channel.

rust's build sets it when it bootstraps compiler itself, as compiler can and has to rely on unstable features when building itself.

some crates, being part of rust itself, also have this toggle, to be able to be bootstrapped with compiler.

idk why seamonkey uses that though.
Comment 5 Larry the Git Cow gentoo-dev 2021-05-14 10:17:42 UTC
The bug has been closed via the following commit(s):

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

commit 648a93817f39a990a40b9b9ab16863d89e784468
Author:     Lars Wendler <polynomial-c@gentoo.org>
AuthorDate: 2021-05-14 10:17:00 +0000
Commit:     Lars Wendler <polynomial-c@gentoo.org>
CommitDate: 2021-05-14 10:17:36 +0000

    www-client/seamonkey: Fixed build with =dev-lang/rust-1.52*
    
    Closes: https://bugs.gentoo.org/789981
    Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>

 .../files/seamonkey-2.53.7.1-rust-1.52.patch       | 52 ++++++++++++++++++++++
 www-client/seamonkey/seamonkey-2.53.7.1-r1.ebuild  |  2 +
 2 files changed, 54 insertions(+)