Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 726416 - www-client/chromium-83.0.4103.61 fails to compile: collect2: error: ld returned 1 exit status
Summary: www-client/chromium-83.0.4103.61 fails to compile: collect2: error: ld retur...
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Chromium Project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-05-31 09:54 UTC by François Valenduc
Modified: 2023-09-26 08:54 UTC (History)
1 user (show)

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


Attachments
dmesg output (dmesg,13.50 KB, text/plain)
2020-06-03 13:28 UTC, François Valenduc
Details

Note You need to log in before you can comment on or make changes to this bug.
Description François Valenduc 2020-05-31 09:54:43 UTC
compilation of chromium fails on the very last step with this error:

[17653/17653] x86_64-pc-linux-gnu-g++ -Wl,--version-script=../../build/linux/chrome.map -fPIC -Wl,-z,noexecstack -Wl,-z,relro -Wl,-z,n -Wl,-z,defs -Wl,--as-needed -rdynamic -pie -Wl,--disable-new-dtags -Wl,-O1 -Wl,--as-needed -o "./chrome" -Wl,--start-group @"./chromesp"  -Wl,--end-group  -latomic -ldl -lpthread -lrt -lX11 -lX11-xcb -lxcb -lxcb-dri3 -lXcomposite -lXcursor -lXdamage -lXext -lXfixes -i -lXrender -lXtst -lgmodule-2.0 -lglib-2.0 -lgobject-2.0 -lgthread-2.0 -licui18n -licuuc -licudata -lsmime3 -lnss3 -lnssutil3 -lplds4lplc4 -lnspr4 -latk-1.0 -latk-bridge-2.0 -lfontconfig -ldbus-1 -lXss -lresolv -lgio-2.0 -lz -lpng16 -lwebpdemux -lwebpmux -lwebp -lfreype -ljpeg -lexpat -lharfbuzz-subset -lharfbuzz -lXrandr -ldrm -lm -lopus -lavcodec -lavformat -lavutil -lopenh264 -lre2 -lpci -lgbm -sound -lsnappy -lpangocairo-1.0 -lpango-1.0 -lcairo -lxml2 -lminizip -latspi -lFLAC -lgtk-3 -lgdk-3 -lcairo-gobject -lgdk_pixbuf-2.0 -slt
FAILED: chrome 
x86_64-pc-linux-gnu-g++ -Wl,--version-script=../../build/linux/chrome.map -fPIC -Wl,-z,noexecstack -Wl,-z,relro -Wl,-z,now -Wl,-z,defsWl,--as-needed -rdynamic -pie -Wl,--disable-new-dtags -Wl,-O1 -Wl,--as-needed -o "./chrome" -Wl,--start-group @"./chrome.rsp"  -Wl,--e-group  -latomic -ldl -lpthread -lrt -lX11 -lX11-xcb -lxcb -lxcb-dri3 -lXcomposite -lXcursor -lXdamage -lXext -lXfixes -lXi -lXrender Xtst -lgmodule-2.0 -lglib-2.0 -lgobject-2.0 -lgthread-2.0 -licui18n -licuuc -licudata -lsmime3 -lnss3 -lnssutil3 -lplds4 -lplc4 -lnspr-latk-1.0 -latk-bridge-2.0 -lfontconfig -ldbus-1 -lXss -lresolv -lgio-2.0 -lz -lpng16 -lwebpdemux -lwebpmux -lwebp -lfreetype -ljpeg -xpat -lharfbuzz-subset -lharfbuzz -lXrandr -ldrm -lm -lopus -lavcodec -lavformat -lavutil -lopenh264 -lre2 -lpci -lgbm -lasound -lsnap -lpangocairo-1.0 -lpango-1.0 -lcairo -lxml2 -lminizip -latspi -lFLAC -lgtk-3 -lgdk-3 -lcairo-gobject -lgdk_pixbuf-2.0 -lxslt
collect2: error: ld returned 1 exit status
distcc[117093] ERROR: compile (null) on localhost failed
ninja: build stopped: subcommand failed.

Does somebody have an idea on this ?
Comment 1 François Valenduc 2020-05-31 10:00:26 UTC
output of emerge --info:

Portage 2.3.99 (python 3.7.7-final-0, default/linux/amd64/17.1/systemd, gcc-9.3.0, glibc-2.30-r8, 5.4.43 x86_64)
=================================================================
System uname: Linux-5.4.43-x86_64-Intel-R-_Core-TM-_i7-6600U_CPU_@_2.60GHz-with-gentoo-2.6
KiB Mem:     8165496 total,   3537848 free
KiB Swap:    1023996 total,   1023732 free
Timestamp of repository gentoo: Tue, 26 May 2020 05:45:01 +0000
Head commit of repository gentoo: 021a1e76d9538fedbda3a37168d4a5bee9ce31cf
sh bash 5.0_p17
ld GNU ld (Gentoo 2.33.1 p2) 2.33.1
distcc 3.3.3 x86_64-pc-linux-gnu [enabled]
app-shells/bash:          5.0_p17::gentoo
dev-java/java-config:     2.2.0-r4::gentoo
dev-lang/perl:            5.30.1::gentoo
dev-lang/python:          2.7.18::gentoo, 3.6.10-r2::gentoo, 3.7.7-r2::gentoo, 3.8.2-r2::gentoo
dev-util/cmake:           3.16.5::gentoo
sys-apps/baselayout:      2.6-r1::gentoo
sys-apps/sandbox:         2.13::gentoo
sys-devel/autoconf:       2.13-r1::gentoo, 2.69-r4::gentoo
sys-devel/automake:       1.16.1-r1::gentoo
sys-devel/binutils:       2.33.1-r1::gentoo
sys-devel/gcc:            9.3.0::gentoo
sys-devel/gcc-config:     2.2.1::gentoo
sys-devel/libtool:        2.4.6-r6::gentoo
sys-devel/make:           4.2.1-r4::gentoo
sys-kernel/linux-headers: 5.4-r1::gentoo (virtual/os-headers)
sys-libs/glibc:           2.30-r8::gentoo
Repositories:

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

local
    location: /usr/local/portage
    masters: gentoo

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="@FREE"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt /usr/share/maven-bin-3.6/conf"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--autounmask y"
ENV_UNSET="DBUS_SESSION_BUS_ADDRESS DISPLAY GOBIN 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 config-protect-if-modified distcc 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="rsync://pc-francois.local/gentoo-distfiles rsync://pc-francois-old.local/gentoo-distfiles http://ftp.free.fr/mirrors/ftp.gentoo.org/"
LANG="fr_BE.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j6 -l4"
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="acl amd64 berkdb bzip2 cli crypt dri fortran gdbm iconv ipv6 libtirpc multilib ncurses nls nptl openmp pam pcre readline seccomp split-usr ssl systemd tcpd udev unicode xattr zlib" 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="actions alias auth_basic authn_alias authn_anon authn_core authn_dbm authn_file authz_core authz_dbm authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir env expires ext_filter file_cache filter headers include info log_config logio mime mime_magic negotiation rewrite setenvif socache_shmcb speling status unique_id unixd userdir usertrack vhost_alias proxy proxy_http proxy_wstunnel" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx mmxext sse sse2" 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="libinput evdev" KERNEL="linux" L10N="fr" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-2" POSTGRES_TARGETS="postgres12" PYTHON_SINGLE_TARGET="python3_7" PYTHON_TARGETS="python3_7" RUBY_TARGETS="ruby24 ruby25" USERLAND="GNU" VIDEO_CARDS="vesa" 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, LINGUAS, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 2 Tomáš Mózes 2020-05-31 10:04:14 UTC
Insufficient memory? Please attach the build log.
Comment 3 François Valenduc 2020-05-31 10:11:00 UTC
full build log is to large, even compressed with xz (1,8 Mb). There is 8 Gb of ram and 1 Gb of swap. Shouldn't that enough ?
Comment 4 François Valenduc 2020-05-31 10:18:29 UTC
Full build log is accessible here: https://drive.google.com/file/d/1I2WtpQgdYDDhtgxUtSin_XGeeAS8A6DE/view?usp=sharing
Comment 5 Tomáš Mózes 2020-05-31 11:18:05 UTC
Emerge info shows 3.5gb free, last time I built on a machine with 10gb of ram I switched to MAKEOPTS="-j2". I know it takes forever, but try with less building threads.
Comment 6 Mike Gilbert gentoo-dev 2020-05-31 13:52:24 UTC
Sorry, but I'm not going to help you troubleshoot this with distcc active.

If you can provide some evidence of a problem in the ebuild, we would be happy to fix it.
Comment 7 François Valenduc 2020-06-03 13:17:35 UTC
It also fails in the same way without distcc.
Comment 8 Stephan Hartmann (RETIRED) gentoo-dev 2020-06-03 13:25:30 UTC
(In reply to François Valenduc from comment #7)
> It also fails in the same way without distcc.

Can you check that you don't run out of RAM? Maybe you see something in dmesg.
Comment 9 François Valenduc 2020-06-03 13:28:28 UTC
Created attachment 643250 [details]
dmesg output

Here the result of dmesg. I see no trace of the OOM killer.
Comment 10 Mike Gilbert gentoo-dev 2020-06-03 15:33:38 UTC
Please provide the build log from the build attempt with distcc disabled.
Comment 11 François Valenduc 2020-06-04 09:10:14 UTC
The full build log without distcc is available here: https://drive.google.com/file/d/178vSrsDh-cekJD0iWnym1NPs9v-8Xbrq/view?usp=sharing
Comment 12 Saayuj Santhoshkumar 2020-06-07 13:51:47 UTC
Looks like chromium here doesn't have sufficient memory for linking.
Try with MAKEOPTS="-j2", that should do it.

Moving on, this might be completely unrelated to your chromium problem. But your CPU_FLAGS_X86 don't really add up considering it's a Skylake(it's missing avx instruction flag for example). Use app-portage/cpuid2cpuflags to find out the correct CPU_FLAGS_X86 and use put those in make.conf 
Read the wiki here: https://wiki.gentoo.org/wiki/CPU_FLAGS_X86 for more info.