Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] Added binhost on 17.1 no-multilib and broke GCC
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
matt2kjones
Tux's lil' helper
Tux's lil' helper


Joined: 03 Mar 2004
Posts: 89

PostPosted: Thu Apr 11, 2024 10:26 am    Post subject: [SOLVED] Added binhost on 17.1 no-multilib and broke GCC Reply with quote

Hello,

I've followed the quick guide on setting up gentoo to use a binary host mirror and pull binary packages where possible. After doing this, I've now broken GCC and the system is not able to compile any packages where there is no suitable binary option.

Selected profile:
Code:
[12]  default/linux/amd64/17.1/no-multilib (stable) *


/etc/portage/binrepos.conf/gentoobinhost.conf:
Code:
[binhost]
priority = 9999
sync-uri = https://mirror.bytemark.co.uk/gentoo/releases/amd64/binpackages/17.1/x86-64/


/etc/portage/make.conf:
Code:
CFLAGS="-O2 -pipe"
CXXFLAGS="${CFLAGS}"
CHOST="x86_64-pc-linux-gnu"
USE="-X -dri mmx sse sse2"
PORTDIR="/usr/portage"
DISTDIR="${PORTDIR}/distfiles"
PKGDIR="${PORTDIR}/packages"
MAKEOPTS="-j5"
ACCEPT_LICENSE="*"
PYTHON_TARGETS="python3_9 python3_10 python3_11 python3_12"

FEATURES="${FEATURES} parallel-fetch binpkg-request-signature"
EMERGE_DEFAULT_OPTS="${EMERGE_DEFAULT_OPTS} --getbinpkg --binpkg-respect-use=y --keep-going"


emerge --info:
Code:
Portage 3.0.59 (python 3.10.13-final-0, default/linux/amd64/17.1/no-multilib, gcc-13, glibc-2.38-r11, 4.9.72-gentoo x86_64)
=================================================================
System uname: Linux-4.9.72-gentoo-x86_64-Intel-R-_Core-TM-_i5-4460_CPU_@_3.20GHz-with-glibc2.38
KiB Mem:     8066836 total,   3649044 free
KiB Swap:   16760828 total,  16669612 free
Timestamp of repository gentoo: Wed, 10 Apr 2024 10:30:00 +0000
Head commit of repository gentoo: e7a942c9bfc0d7ea9e8b280f897660a0058222ea
sh bash 5.1_p16-r6
ld GNU ld (Gentoo 2.37_p1 p2) 2.37
app-misc/pax-utils:        1.3.7::gentoo
app-shells/bash:           5.1_p16-r6::gentoo
dev-build/autoconf:        2.71-r6::gentoo
dev-build/automake:        1.16.5-r2::gentoo
dev-build/cmake:           3.27.9::gentoo
dev-build/libtool:         2.4.7-r4::gentoo
dev-build/make:            4.4.1-r1::gentoo
dev-build/meson:           1.3.2::gentoo
dev-lang/perl:             5.38.2-r2::gentoo
dev-lang/python:           3.9.15_p2::gentoo, 3.10.13::gentoo, 3.11.8_p1::gentoo, 3.12.2_p1::gentoo
dev-lang/rust:             1.60.0::gentoo
sys-apps/baselayout:       2.14-r2::gentoo
sys-apps/openrc:           0.54::gentoo
sys-apps/sandbox:          2.38::gentoo
sys-devel/binutils:        2.37_p1-r2::gentoo, 2.38-r2::gentoo, 2.41-r5::gentoo
sys-devel/binutils-config: 5.5::gentoo
sys-devel/gcc:             9.3.0-r1::gentoo, 10.2.0-r5::gentoo, 11.3.0::gentoo, 13.2.1_p20240210::gentoo
sys-devel/gcc-config:      2.11::gentoo
sys-kernel/linux-headers:  6.6-r1::gentoo (virtual/os-headers)
sys-libs/glibc:            2.38-r11::gentoo
Repositories:

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

Binary Repositories:

binhost
    priority: 9999
    sync-uri: https://mirror.bytemark.co.uk/gentoo/releases/amd64/binpackages/17.1/x86-64

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/gentoo-release /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS=" --getbinpkg --binpkg-respect-use=y --keep-going"
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-request-signature buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox pkgdir-index-trusted 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_GB.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LEX="flex"
MAKEOPTS="-j5"
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="acl amd64 bzip2 cli crypt fortran gdbm iconv ipv6 libtirpc mmx ncurses nls openmp pam pcre readline seccomp split-usr sse sse2 ssl test-rust unicode xattr zlib" ABI_X86="64" ADA_TARGET="gcc_12" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_anon authn_dbm authn_file 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 speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="swap snmp df load memory cpu network" CPU_FLAGS_X86="mmx mmxext sse sse2" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 ntrip navcom oceanserver oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 tsip tripmate tnt ublox" INPUT_DEVICES="libinput" KERNEL="linux" LCD_DEVICES="bayrad cfontz glk hd44780 lb216 lcdm001 mtxorb text" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php8-1" POSTGRES_TARGETS="postgres15" PYTHON_SINGLE_TARGET="python3_11" PYTHON_TARGETS="python3_9 python3_10 python3_11 python3_12" RUBY_TARGETS="ruby31" VIDEO_CARDS="amdgpu fbdev intel nouveau radeon radeonsi vesa dummy" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipp2p iface geoip fuzzy condition tarpit sysrq proto logmark ipmark dhcpmac delude chaos account"
Unset:  ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LFLAGS, LIBTOOL, LINGUAS, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PYTHONPATH, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS


I'm using a very old kernel just because it's one of those type of machines that has specific SAS cards and such, so I tend not to upgrade the kernel unless I really need to.

Compiles either fail on configure when testing if gcc can make executables or with gcc errors, examples of both below:

GCC Error:
Code:
2024-04-10 16:46:07,134 root INFO running build_ext
2024-04-10 16:46:07,288 root INFO building '_cffi_backend' extension
2024-04-10 16:46:07,288 root INFO creating /var/tmp/portage/dev-python/cffi-1.16.0/work/cffi-1.16.0-python3_10/build/
2024-04-10 16:46:07,288 root INFO creating /var/tmp/portage/dev-python/cffi-1.16.0/work/cffi-1.16.0-python3_10/build/
2024-04-10 16:46:07,288 root INFO creating /var/tmp/portage/dev-python/cffi-1.16.0/work/cffi-1.16.0-python3_10/build/
2024-04-10 16:46:07,289 root INFO x86_64-pc-linux-gnu-gcc -Wno-unused-result -Wsign-compare -DNDEBUG -O2 -pipe -DNDEBo /var/tmp/portage/dev-python/cffi-1.16.0/work/cffi-1.16.0-python3_10/build/temp.linux-x86_64-cpython-310/src/c/_cffi
2024-04-10 16:46:10,209 root INFO x86_64-pc-linux-gnu-gcc -shared -Wl,-O1 -Wl,--as-needed -O2 -pipe -DNDEBUG /var/tmp/usr/lib64 -lffi -o /var/tmp/portage/dev-python/cffi-1.16.0/work/cffi-1.16.0-python3_10/build/lib.linux-x86_64-cpytho
/usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: /lib64/libc.so.6: unknown type [0x13] sec
/usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /lib64/libc.so.6 wh
/usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: cannot find /lib64/libc.so.6
/usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: /lib64/libc.so.6: unknown type [0x13] sec
/usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /lib64/libc.so.6 wh
/usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: /lib64/ld-linux-x86-64.so.2: unknown type
/usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /lib64/ld-linux-x86
/usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: cannot find /lib64/ld-linux-x86-64.so.2
/usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: /lib64/ld-linux-x86-64.so.2: unknown type
/usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /lib64/ld-linux-x86
collect2: error: ld returned 1 exit status
error: command '/usr/bin/x86_64-pc-linux-gnu-gcc' failed with exit code 1


Configure Error:
Code:
>>> Configuring source in /var/tmp/portage/net-nds/openldap-2.6.4-r1/work/openldap-OPENLDAP_REL_ENG_2_6_4 ...
 * abi_x86_64.amd64: running multilib-minimal_abi_src_configure
 * econf: updating openldap-OPENLDAP_REL_ENG_2_6_4/config.guess with /usr/share/gnuconfig/config.guess
 * econf: updating openldap-OPENLDAP_REL_ENG_2_6_4/build/config.guess with /usr/share/gnuconfig/config.guess
 * econf: updating openldap-OPENLDAP_REL_ENG_2_6_4/build/config.sub with /usr/share/gnuconfig/config.sub
 * econf: updating openldap-OPENLDAP_REL_ENG_2_6_4/config.sub with /usr/share/gnuconfig/config.sub
 * econf: updating openldap-OPENLDAP_REL_ENG_2_6_4/contrib/ldapc++/config.guess with /usr/share/gnuconfig/config.gues
 * econf: updating openldap-OPENLDAP_REL_ENG_2_6_4/contrib/ldapc++/config.sub with /usr/share/gnuconfig/config.sub
 * econf: updating openldap-OPENLDAP_REL_ENG_2_6_4-abi_x86_64.amd64/config.guess with /usr/share/gnuconfig/config.gue
 * econf: updating openldap-OPENLDAP_REL_ENG_2_6_4-abi_x86_64.amd64/build/config.guess with /usr/share/gnuconfig/conf
 * econf: updating openldap-OPENLDAP_REL_ENG_2_6_4-abi_x86_64.amd64/build/config.sub with /usr/share/gnuconfig/config
 * econf: updating openldap-OPENLDAP_REL_ENG_2_6_4-abi_x86_64.amd64/config.sub with /usr/share/gnuconfig/config.sub
 * econf: updating openldap-OPENLDAP_REL_ENG_2_6_4-abi_x86_64.amd64/contrib/ldapc++/config.guess with /usr/share/gnuc
 * econf: updating openldap-OPENLDAP_REL_ENG_2_6_4-abi_x86_64.amd64/contrib/ldapc++/config.sub with /usr/share/gnucon
/var/tmp/portage/net-nds/openldap-2.6.4-r1/work/openldap-OPENLDAP_REL_ENG_2_6_4/configure --prefix=/usr --build=x86_6nfdir=/etc --localstatedir=/var/lib --docdir=/usr/share/doc/openldap-2.6.4-r1 --htmldir=/usr/share/doc/openldap-2.6.4-sharedstatedir=/var/lib --enable-option-checking --disable-debug --enable-dynamic --enable-syslog --enable-ipv6 --ene-slp --disable-wrappers --enable-modules --enable-rlookups --enable-slapi --enable-mdb=yes --enable-asyncmeta=mod --autoca=no --enable-syncprov=yes --disable-argon2 --without-systemd --without-cyrus-sasl --disable-static --enable-sha
Configuring OpenLDAP 2.6.4-Release ...
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking target system type... x86_64-pc-linux-gnu
checking configure arguments... done
checking for x86_64-pc-linux-gnu-gcc... x86_64-pc-linux-gnu-gcc
checking whether the C compiler works... no
configure: error: in `/var/tmp/portage/net-nds/openldap-2.6.4-r1/work/openldap-OPENLDAP_REL_ENG_2_6_4-abi_x86_64.amd6
configure: error: C compiler cannot create executables
See `config.log' for more details


I've tried switching to older GCC's which were built from source and to GCC 13 which was pulled as a binary package, and done . /etc/profile after each change, makes no difference.

I've also tried emerging the @system target to try and pull all binary versions of gcc, glibc, binutils, etc hopeful that if everything came from the bin host, it would resolve itself, but it's still broken.

Any idea's as to what I've done wrong and how I can fix it without the faff of having to use a rescue USB and chrooting in.
Back to top
View user's profile Send private message
matt2kjones
Tux's lil' helper
Tux's lil' helper


Joined: 03 Mar 2004
Posts: 89

PostPosted: Thu Apr 11, 2024 10:35 am    Post subject: Reply with quote

Nevermind!!!

Just realised after reviewing emerge --info, I had an old binutils selected. I did binutils-config -l and selected the latest version and it fixed it.

Not sure if it's worth leaving this here incase others make the same mistake as me, or whether the post gets deleted.
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 21657

PostPosted: Thu Apr 11, 2024 2:47 pm    Post subject: Reply with quote

Threads are usually only deleted for violation of forum rules. A thread such as this, which was made in good faith, and which has a clear answer posted in it, is fine to keep, in my opinion.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum