Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
dev-lang/rust-1.36.0 - linker error: relocation truncated...
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on PPC
View previous topic :: View next topic  
Author Message
MoeDathstern
n00b
n00b


Joined: 01 Aug 2019
Posts: 7

PostPosted: Sun Aug 04, 2019 9:18 am    Post subject: dev-lang/rust-1.36.0 - linker error: relocation truncated... Reply with quote

Hi!

I still try to install www-client/firefox on a PowerBook G4 32-bit PowerPC. Yes the computer is not the fastest.

Now I'm stuck with dev-lang/rust-1.36.0.

The linking of
Code:
rustc_codegen_llvm
aborts with error:
Code:

          PPCInstrInfo.cpp:(.text.startup._GLOBAL__sub_I_PPCInstrInfo.cpp+0x328): relocation truncated to fit: R_PPC_PLTREL24 against symbol `llvm::cl::Option::setArgStr(llvm::StringRef)' defined in .text._ZN4llvm2cl6Option9setArgStrENS_9StringRefE section in /var/tmp/portage/dev-lang/rust-1.36.0/temp/rustco0dLBL/librustc_llvm-2354b1238ed84763.rlib(CommandLine.cpp.o)+8000
          PPCInstrInfo.cpp:(.text.startup._GLOBAL__sub_I_PPCInstrInfo.cpp+0x350): additional relocation overflows omitted from the output
          collect2: error: ld returned 1 exit status


I checked the web but can't find a clear solution. It seems the error has something to do with the linker trying to link objects to addresses beyond the 32-bit address space. How can I fix this?

NB: Is there a way in Gentoo to continue the aborted emerge? Each time I try a new
Code:
emerge --ask www-client/firefox
it starts compiling rust from the beginning means I have to wait at least 12 hours until I get to the not linking rustc_codegen_llvm again. There is for sure only a switch I missed somewhere.

Logfiles:
emerge --info '=dev-lang/rust-1.36.0::gentoo'
Code:

Portage 2.3.69 (python 3.6.5-final-0, default/linux/powerpc/ppc32/17.0, gcc-8.3.0, glibc-2.29-r2, 4.19.57-gentoo ppc)
=================================================================
                         System Settings
=================================================================
System uname: Linux-4.19.57-gentoo-ppc-7447A,_altivec_supported-with-gentoo-2.6
KiB Mem:     2069604 total,    585748 free
KiB Swap:    2648116 total,   2648116 free
Timestamp of repository gentoo: Thu, 01 Aug 2019 08:30:01 +0000
Head commit of repository gentoo: dc225da03b2a3b803cf323eb8f75b39881b60181
sh bash 4.4_p23-r1
ld GNU ld (Gentoo 2.32 p2) 2.32.0
app-shells/bash:          4.4_p23-r1::gentoo
dev-lang/perl:            5.28.2-r1::gentoo
dev-lang/python:          2.7.15::gentoo, 3.6.5::gentoo
dev-util/cmake:           3.14.6::gentoo
sys-apps/baselayout:      2.6-r1::gentoo
sys-apps/openrc:          0.41.2::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.32-r1::gentoo
sys-devel/gcc:            8.3.0-r1::gentoo
sys-devel/gcc-config:     2.0::gentoo
sys-devel/libtool:        2.4.6-r3::gentoo
sys-devel/make:           4.2.1-r4::gentoo
sys-kernel/linux-headers: 4.19::gentoo (virtual/os-headers)
sys-libs/glibc:           2.29-r2::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-verify-jobs: 1
    sync-rsync-verify-metamanifest: yes
    sync-rsync-extra-opts:

ACCEPT_KEYWORDS="ppc"
ACCEPT_LICENSE="@FREE"
CBUILD="powerpc-unknown-linux-gnu"
CFLAGS="-O2 -mcpu=powerpc -mtune=powerpc -pipe"
CHOST="powerpc-unknown-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 -mcpu=powerpc -mtune=powerpc -pipe"
DISTDIR="/usr/portage/distfiles"
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 -mcpu=powerpc -mtune=powerpc -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs 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 sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -mcpu=powerpc -mtune=powerpc -pipe"
GENTOO_MIRRORS="https://mirror.mdfnet.se/gentoo"
LANG="C.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
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 berkdb big-endian bzip2 cli crypt cxx dri fortran gdbm iconv ipv6 ncurses nls nptl openmp pam pcre ppc readline seccomp split-usr ssl tcpd unicode xattr zlib" ABI_PPC="32" ALSA_CARDS="aoa aoa-fabric-layout aoa-onyx aoa-soundbus aoa-soundbus-i2s aoa-tas aoa-toonie powermac usb-audio via82xx" 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" ELIBC="glibc" 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="ieee1275" INPUT_DEVICES="libinput keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" NETBEANS_MODULES="apisupport cnd groovy gsf harness ide identity j2ee java mobility nb php profiler soa visualweb webcommon websvccommon xml" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-2" POSTGRES_TARGETS="postgres10 postgres11" PYTHON_SINGLE_TARGET="python3_6" PYTHON_TARGETS="python2_7 python3_6" RUBY_TARGETS="ruby24" USERLAND="GNU" VIDEO_CARDS="fbdev glint mga nv r128 radeon dummy v4l" 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, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, LINGUAS, MAKEOPTS, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS


emerge -pqv '=dev-lang/rust-1.36.0::gentoo'
Code:

[ebuild  N    ] dev-lang/rust-1.36.0  USE="-clippy -debug -doc -libressl -rls -rustfmt -system-llvm -wasm" LLVM_TARGETS="(PowerPC) -AArch64 -AMDGPU -ARM -BPF -Hexagon -Lanai -MSP430 -Mips -NVPTX -Sparc -SystemZ -WebAssembly -X86 -XCore"


The log
Code:
/var/tmp/portage/dev-lang/rust-1.36.0/temp/build.log
is 1.2MB - to large to append, here is a snippet
Code:

     Running `/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/bootstrap/debug/rustc --edition=2018 --crate-name rustc_code
gen_llvm src/librustc_codegen_llvm/lib.rs --color always --error-format json --crate-type dylib --emit=dep-info,link -C prefer-dynamic -C op
t-level=2 -C metadata=3e6c4c8f16f1c7f2 -C extra-filename=-3e6c4c8f16f1c7f2 --out-dir /var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0
-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps --target powerpc-unknown-linux-gnu -L dependency=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps -L dependency=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/release/deps --extern cc=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/libcc-3fe766a9391847d5.rlib --extern memmap=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/libmemmap-70255617cd2d67aa.rlib --extern num_cpus=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/libnum_cpus-7e2627e1b610d3b8.rlib --extern rustc_demangle=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/librustc_demangle-25bdf27db80084ee.rlib --extern rustc_llvm=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/librustc_llvm-2354b1238ed84763.rlib -L native=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/build/rustc_llvm-39eb6318d51337ec/out -L native=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/llvm/build/lib`
rustc command: "LD_LIBRARY_PATH"="/var/tmp/portage/dev-lang/rust-1.36.0/work/rust-stage0/lib:/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/release/deps:/var/tmp/portage/dev-lang/rust-1.36.0/work/rust-stage0/lib" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rust-stage0/bin/rustc" "--edition=2018" "--crate-name" "rustc_codegen_llvm" "src/librustc_codegen_llvm/lib.rs" "--color" "always" "--crate-type" "dylib" "--emit=dep-info,link" "-C" "prefer-dynamic" "-C" "opt-level=2" "-C" "metadata=3e6c4c8f16f1c7f2-rustc" "-C" "extra-filename=-3e6c4c8f16f1c7f2" "--out-dir" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps" "--target" "powerpc-unknown-linux-gnu" "-L" "dependency=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps" "-L" "dependency=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/release/deps" "--extern" "cc=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/libcc-3fe766a9391847d5.rlib" "--extern" "memmap=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/libmemmap-70255617cd2d67aa.rlib" "--extern" "num_cpus=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/libnum_cpus-7e2627e1b610d3b8.rlib" "--extern" "rustc_demangle=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/librustc_demangle-25bdf27db80084ee.rlib" "--extern" "rustc_llvm=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/librustc_llvm-2354b1238ed84763.rlib" "-L" "native=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/build/rustc_llvm-39eb6318d51337ec/out" "-L" "native=/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/llvm/build/lib" "--cfg" "stage0" "--sysroot" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot" "-Zexternal-macro-backtrace" "-Cprefer-dynamic" "-Clinker=powerpc-unknown-linux-gnu-gcc" "-C" "debug-assertions=n" "-Zunstable-options" "-Z" "force-unstable-if-unmarked" "-Dwarnings" "-Dbare_trait_objects" "-Drust_2018_idioms"
sysroot: "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot"
libdir: "/var/tmp/portage/dev-lang/rust-1.36.0/work/rust-stage0/lib"
error: linking with `powerpc-unknown-linux-gnu-gcc` failed: exit code: 1
  |
  = note: "powerpc-unknown-linux-gnu-gcc" "-Wl,--as-needed" "-Wl,-z,noexecstack" "-m32" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.0.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.1.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.10.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.11.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.12.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.13.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.14.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.15.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.2.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.3.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.4.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.5.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.6.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.7.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.8.rcgu.o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.9.rcgu.o" "-o" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/librustc_codegen_llvm-3e6c4c8f16f1c7f2.so" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.1bovrcl3f75vpjd9.rcgu.o" "-Wl,-zrelro" "-Wl,-znow" "-Wl,-O1" "-nodefaultlibs" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/release/deps" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/build/rustc_llvm-39eb6318d51337ec/out" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/llvm/build/lib" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-Wl,-Bstatic" "-Wl,--whole-archive" "/var/tmp/portage/dev-lang/rust-1.36.0/temp/rustco0dLBL/librustc_llvm-2354b1238ed84763.rlib" "-Wl,--no-whole-archive" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-Wl,-Bdynamic" "-lrustc_codegen_ssa-4317b2509b5d9f6a" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lrustc_codegen_utils-dccf4a547fc90a5f" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lrustc_metadata-427828b7f26f9272" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lsyntax_ext-2bb730f91c60f81c" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lrustc_incremental-6478847666e6b1fc" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lrustc_allocator-43f8505eb54b8904" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lrustc_mir-186c50339f1eb407" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lrustc-60fcd820e9a80e50" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lfmt_macros-621ef36956ee9ead" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lrustc_fs_util-01dad45595af9c1b" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-ltest-2a43eb9c11d6a389" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lterm-fb90907e6eb83b8d" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lsyntax-086d6e57b05e947f" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lrustc_target-eb4945fe0fbdb102" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lrustc_errors-6f8293381a798953" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lsyntax_pos-63fe19b343fc20a3" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-larena-6dba3a175182fad7" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lrustc_data_structures-aad7b4a3ce383455" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lgraphviz-506f95b6c2a925dd" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lrustc_cratesio_shim-804bcaed182c12bb" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lserialize-023585dd610573b9" "-Wl,--start-group" "-L" "/var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-sysroot/lib/rustlib/powerpc-unknown-linux-gnu/lib" "-lstd-32e5078b3606c14e" "-Wl,--end-group" "-Wl,-Bstatic" "/var/tmp/portage/dev-lang/rust-1.36.0/temp/rustco0dLBL/libcompiler_builtins-748eece857f4782a.rlib" "-Wl,-Bdynamic" "-lrt" "-ldl" "-lpthread" "-lm" "-lstdc++" "-lutil" "-lutil" "-ldl" "-lrt" "-lpthread" "-lgcc_s" "-lc" "-lm" "-lrt" "-lpthread" "-lutil" "-lutil" "-shared"
  = note: /usr/lib/gcc/powerpc-unknown-linux-gnu/8.3.0/../../../../powerpc-unknown-linux-gnu/bin/ld: bss-plt forced due to /var/tmp/portage/dev-lang/rust-1.36.0/work/rustc-1.36.0-src/build/powerpc-unknown-linux-gnu/stage0-codegen/powerpc-unknown-linux-gnu/release/deps/rustc_codegen_llvm-3e6c4c8f16f1c7f2.rustc_codegen_llvm.a73573ut-cgu.0.rcgu.o
          /var/tmp/portage/dev-lang/rust-1.36.0/temp/rustco0dLBL/librustc_llvm-2354b1238ed84763.rlib(PPCInstrInfo.cpp.o): in function `_GLOBAL__sub_I_PPCInstrInfo.cpp':
          PPCInstrInfo.cpp:(.text.startup._GLOBAL__sub_I_PPCInstrInfo.cpp+0xec): relocation truncated to fit: R_PPC_PLTREL24 against symbol `llvm::cl::Option::setArgStr(llvm::StringRef)' defined in .text._ZN4llvm2cl6Option9setArgStrENS_9StringRefE section in /var/tmp/portage/dev-lang/rust-1.36.0/temp/rustco0dLBL/librustc_llvm-2354b1238ed84763.rlib(CommandLine.cpp.o)+8000
          PPCInstrInfo.cpp:(.text.startup._GLOBAL__sub_I_PPCInstrInfo.cpp+0x114): relocation truncated to fit: R_PPC_PLTREL24 against symbol `llvm::cl::Option::addArgument()' defined in .text._ZN4llvm2cl6Option11addArgumentEv section in /var/tmp/portage/dev-lang/rust-1.36.0/temp/rustco0dLBL/librustc_llvm-2354b1238ed84763.rlib(CommandLine.cpp.o)+8000
          PPCInstrInfo.cpp:(.text.startup._GLOBAL__sub_I_PPCInstrInfo.cpp+0x12c): relocation truncated to fit: R_PPC_PLTREL24 against symbol `__cxa_atexit@@GLIBC_2.1.3' defined in .text section in /lib/libc.so.6+8000
          PPCInstrInfo.cpp:(.text.startup._GLOBAL__sub_I_PPCInstrInfo.cpp+0x1b0): relocation truncated to fit: R_PPC_PLTREL24 against symbol `llvm::cl::Option::setArgStr(llvm::StringRef)' defined in .text._ZN4llvm2cl6Option9setArgStrENS_9StringRefE section in /var/tmp/portage/dev-lang/rust-1.36.0/temp/rustco0dLBL/librustc_llvm-2354b1238ed84763.rlib(CommandLine.cpp.o)+8000
          PPCInstrInfo.cpp:(.text.startup._GLOBAL__sub_I_PPCInstrInfo.cpp+0x1d8): relocation truncated to fit: R_PPC_PLTREL24 against symbol `llvm::cl::Option::addArgument()' defined in .text._ZN4llvm2cl6Option11addArgumentEv section in /var/tmp/portage/dev-lang/rust-1.36.0/temp/rustco0dLBL/librustc_llvm-2354b1238ed84763.rlib(CommandLine.cpp.o)+8000
          PPCInstrInfo.cpp:(.text.startup._GLOBAL__sub_I_PPCInstrInfo.cpp+0x1e8): relocation truncated to fit: R_PPC_PLTREL24 against symbol `__cxa_atexit@@GLIBC_2.1.3' defined in .text section in /lib/libc.so.6+8000
          PPCInstrInfo.cpp:(.text.startup._GLOBAL__sub_I_PPCInstrInfo.cpp+0x26c): relocation truncated to fit: R_PPC_PLTREL24 against symbol `llvm::cl::Option::setArgStr(llvm::StringRef)' defined in .text._ZN4llvm2cl6Option9setArgStrENS_9StringRefE section in /var/tmp/portage/dev-lang/rust-1.36.0/temp/rustco0dLBL/librustc_llvm-2354b1238ed84763.rlib(CommandLine.cpp.o)+8000
          PPCInstrInfo.cpp:(.text.startup._GLOBAL__sub_I_PPCInstrInfo.cpp+0x294): relocation truncated to fit: R_PPC_PLTREL24 against symbol `llvm::cl::Option::addArgument()' defined in .text._ZN4llvm2cl6Option11addArgumentEv section in /var/tmp/portage/dev-lang/rust-1.36.0/temp/rustco0dLBL/librustc_llvm-2354b1238ed84763.rlib(CommandLine.cpp.o)+8000
          PPCInstrInfo.cpp:(.text.startup._GLOBAL__sub_I_PPCInstrInfo.cpp+0x2a4): relocation truncated to fit: R_PPC_PLTREL24 against symbol `__cxa_atexit@@GLIBC_2.1.3' defined in .text section in /lib/libc.so.6+8000
          PPCInstrInfo.cpp:(.text.startup._GLOBAL__sub_I_PPCInstrInfo.cpp+0x328): relocation truncated to fit: R_PPC_PLTREL24 against symbol `llvm::cl::Option::setArgStr(llvm::StringRef)' defined in .text._ZN4llvm2cl6Option9setArgStrENS_9StringRefE section in /var/tmp/portage/dev-lang/rust-1.36.0/temp/rustco0dLBL/librustc_llvm-2354b1238ed84763.rlib(CommandLine.cpp.o)+8000
          PPCInstrInfo.cpp:(.text.startup._GLOBAL__sub_I_PPCInstrInfo.cpp+0x350): additional relocation overflows omitted from the output
          collect2: error: ld returned 1 exit status
         

error: aborting due to previous error

error: Could not compile `rustc_codegen_llvm`.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54220
Location: 56N 3W

PostPosted: Sun Aug 04, 2019 10:25 am    Post subject: Reply with quote

MoeDathstern,

I don't do PPC but I've tried to build both rust and firefox on a 1G Raspberry Pi with 4G swap and failed.
My workaround was to make a QEMU chroot on a more capable system and build binaries there.
The method is documented on the wiki
Where I have aarch64-unknown-linux-gnu you use powerpc-unknown-linux-gnu everywhere.

To post big logs, wgetpaste is your friend.

Your MAKEOPTS is unset. That means it defaults to MAKEOPTS="-j2" which allows two parallel make threads to run at the same time.
Setting
Code:
MAKEOPTS="-j1"
may help.

There are three ways to do that.
Put it in make.conf but it will apply to everything, which is probably not what you want.
Add it to the emerge command
Code:
MAKEOPTS="-j1" emerge -1 rust
that's OK for testing but its not automatic and you will forget.
Learn to use /etc/portage/env/ and friends so portage does it for you. There is a worked example on the wiki.

To continue an aborted package, you use the ebuild command directly. In effect, emerge runs the required ebuild commands to do all that's needed.
When a build fails, the work to date is saved, unless you set FEATURES to clean it out. That means that /var/tmp/portage can grow without limit.

You need the merge phase.

Try
Code:
ebuild  --help
you will get an error with a list of all the valid commands. Don't be afraid to read the man page.
Code:
ebuild /full/path/to/.ebuild merge
Here, its rust that failed, not firefox. I don't know how to change the environment for running build.

The path of least resistance is to try MAKEOPTS="-j1".
While that runs, prepare a QEMU chroot, in the hope you won't need it.

None of the above is PPC specific, its resource constrained systems general stuff.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
MoeDathstern
n00b
n00b


Joined: 01 Aug 2019
Posts: 7

PostPosted: Sun Aug 04, 2019 1:04 pm    Post subject: Reply with quote

NeddySeagoon wrote:
MoeDathstern,
[...]
To post big logs, wgetpaste is your friend.
[...]

Thanks for the tip. I did not know this tool. It's a handy one. Unfortunately it doesn't help with a 1.2MB logfile.

I fired "emerge --ask app-text/wgetpaste" and got installed version 2.28. This version supports
Code:
# wgetpaste -S
Services supported: (case sensitive):
   Name:    | Url:
   =========|=================
    codepad | http://codepad.org/
    dpaste  | http://dpaste.com/
    gists   | https://api.github.com/gists
   *bpaste  | https://bpaste.net/


codepad and dpaste have already a size limit included in the tool.
Code:

SIZE_codepad="64000 64%KB"
SIZE_dpaste="25000 25%kB"


I tried bpaste and got "ERROR 413: Request Entity Too Large." and gists doesn't seam the right service for this job either.

If someone really needs the whole logfile send me a message.
In the meantime I keep working on your other suggestions.

Moe
Back to top
View user's profile Send private message
MoeDathstern
n00b
n00b


Joined: 01 Aug 2019
Posts: 7

PostPosted: Sun Aug 04, 2019 1:49 pm    Post subject: Reply with quote

NeddySeagoon wrote:
MoeDathstern,
[...]
To continue an aborted package, you use the ebuild command directly. In effect, emerge runs the required ebuild commands to do all that's needed.
When a build fails, the work to date is saved, unless you set FEATURES to clean it out. That means that /var/tmp/portage can grow without limit.

You need the merge phase.

Try
Code:
ebuild  --help
you will get an error with a list of all the valid commands. Don't be afraid to read the man page.
Code:
ebuild /full/path/to/.ebuild merge
Here, its rust that failed, not firefox. I don't know how to change the environment for running build.
[...]


"ebuild --help" doesn't list the commands (anymore?) only some optional arguments. The man page has nevertheless all info needed.
I did a
Code:

cd $(portageq get_repo_path / gentoo)/dev-lang/rust
ebuild rust-1.36.0.ebuild merge

and ebuild picks up at the point of fail. Nice. It's now only 15 min to the error instead of more than 12 hours.
Thanks! This helps debugging a lot.

I keep working on your other suggestions.

Moe
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54220
Location: 56N 3W

PostPosted: Sun Aug 04, 2019 1:56 pm    Post subject: Reply with quote

MoeDathstern,

I'll hold off asking for the entire log while you are doing other things.

After its failed, check dmesg for the Out Of Memory (OOM) manager killing tasks.
You need more RAM and or swap, or to reduce the demand on memory if thats happening.

MAKEOPS="-j1" does that.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 21607

PostPosted: Sun Aug 04, 2019 3:40 pm    Post subject: Reply with quote

We may not need the whole log, but we might well need more log than you can put in the forum. If you get to the point that you need to show the log, post as much of it as the pastebin will take, starting at the end and working backward.
Back to top
View user's profile Send private message
MoeDathstern
n00b
n00b


Joined: 01 Aug 2019
Posts: 7

PostPosted: Mon Aug 05, 2019 5:11 pm    Post subject: Reply with quote

Hi!

NeddySeagoon wrote:
MoeDathstern,

I'll hold off asking for the entire log while you are doing other things.

After its failed, check dmesg for the Out Of Memory (OOM) manager killing tasks.
You need more RAM and or swap, or to reduce the demand on memory if thats happening.

MAKEOPS="-j1" does that.


It seems you really, really want to have the build.log ;-). I fixed little web space. Here it is:
http://dathstern.epizy.com/gentoo/2019-08-05/dev-lang_rust_emerge-build.log

This log comes from the latest try which failed, too:
Code:

MAKEOPTS="-j1" emerge --ask -1 dev-lang/rust


I was present in the moment of failure and checked top. I really don't see a problem with RAM. In the second the build failed the computer had about 1.4GB of 2GB usable and the 2.5GB swap space was never touched (0.0 used). No OOM-killer lines in dmesg either.

The named error can be a 32/64-bit problem as described in
https://www.technovelty.org/c/relocation-truncated-to-fit-wtf.html
But I have no idea where to look or how to fix this if this is the case.

Now it's time for your last suggestion. PPC chroot. My debian amd64 with lots of RAM, disk space and CPU power has no crossdev.
What I can do:

  1. Install a qemu virtual PPC machine with Gentoo and try it there. - No KVM so this will be really slow.
  2. Install a qemu virtual amd64 machine with Gentoo and follow your wiki page with a cross compiling chroot. - KVM for Gentoo but slow PPC emulation for the chroot. And I'm not sure if one can start a qemu in qemu.

Which option would be easier/quicker? I think I start with option 1. Give me about a week for the results.

Moe
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on PPC 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