[The problem during buildworld via aarch64-xtoolchain-gcc still occurs
for -r322287 of head and -r447082 of /usr/ports. It is because of using
the default static-link of devel/aarch64-binutils utilities, including
/usr/local/bin/aarch64-freebsd-ld . A non-default devel/aarch64-binutils
is required.]

FYI:

# pkg info | grep aarch64
aarch64-binutils-2.28,1        GNU binutils for AArch64 cross-development
aarch64-gcc-6.3.0              Cross GNU Compiler Collection for aarch64
aarch64-xtoolchain-gcc-0.2     Pre seeded toolchain to cross build FreeBSD base

For aarch64-binutils-2.28,1 :

Configuration Options
===> The following configuration options are available for 
aarch64-binutils-2.28,1:
     RELRO=off: enable -z relro in ELF linker by default
     STATIC=on: Build static executables and/or libraries
===> Use 'make config' to modify these settings

It build aarch64-binutils as static by default as of 2017-Feb-22:

This is required to build Arm64 packages using QEMU.  Poudriere copies
the native ld from the host into the jail and uses that during the build.
This only works if ld is static.

Reported by:    krion
Approved by:    bapt


But for aarch64-xtoolchain-gcc related use the default blocks buildworld :



building shared library libc.so.7
/usr/local/bin/aarch64-freebsd-ld: 
/usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/liblto_plugin.so: 
error loading plugin: Service unavailable
collect2: error: ld returned 1 exit status
*** [libc.so.7.full] Error code 1

make[4]: stopped in /usr/src/lib/libc
.ERROR_TARGET='libc.so.7.full'
.ERROR_META_FILE='/usr/obj/cortexA53_xtoolchain-gcc/arm64.aarch64/usr/src/lib/libc/libc.so.7.full.meta'
.MAKE.LEVEL='4'
MAKEFILE=''
. . .

# file /usr/local/bin/aarch64-freebsd-ld
/usr/local/bin/aarch64-freebsd-ld: ELF 64-bit LSB executable, x86-64, version 1 
(FreeBSD), statically linked, for FreeBSD 12.0 (1200036), FreeBSD-style, not 
stripped

# ls -lt /usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/
total 43913
drwxr-xr-x  2 root  wheel         3 Jun 28 17:51 plugin
drwxr-xr-x  2 root  wheel         6 Jun 28 17:51 install-tools
-r-xr-xr-x  1 root  wheel   1422072 Jun 28 17:51 lto-wrapper
-r-xr-xr-x  1 root  wheel   1229416 Jun 28 17:51 collect2
-r-xr-xr-x  1 root  wheel  28472516 Jun 28 17:51 lto1
-r-xr-xr-x  1 root  wheel  32125603 Jun 28 17:51 cc1plus
-r-xr-xr-x  1 root  wheel  29707472 Jun 28 17:51 cc1
lrwxr-xr-x  1 root  wheel        22 Jun 28 17:51 liblto_plugin.so -> 
liblto_plugin.so.0.0.0
lrwxr-xr-x  1 root  wheel        22 Jun 28 17:51 liblto_plugin.so.0 -> 
liblto_plugin.so.0.0.0
-rwxr-xr-x  1 root  wheel    253310 Jun 28 17:51 liblto_plugin.so.0.0.0

# file /usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/*
/usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/cc1:                   
 ELF 64-bit LSB executable, x86-64, version 1 (FreeBSD), dynamically linked, 
interpreter /libexec/ld-elf.so.1, for FreeBSD 12.0 (1200036), FreeBSD-style, 
not stripped
/usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/cc1plus:               
 ELF 64-bit LSB executable, x86-64, version 1 (FreeBSD), dynamically linked, 
interpreter /libexec/ld-elf.so.1, for FreeBSD 12.0 (1200036), FreeBSD-style, 
not stripped
/usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/collect2:              
 ELF 64-bit LSB executable, x86-64, version 1 (FreeBSD), dynamically linked, 
interpreter /libexec/ld-elf.so.1, for FreeBSD 12.0 (1200036), FreeBSD-style, 
not stripped
/usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/install-tools:         
 directory
/usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/liblto_plugin.so:      
 symbolic link to liblto_plugin.so.0.0.0
/usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/liblto_plugin.so.0:    
 symbolic link to liblto_plugin.so.0.0.0
/usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/liblto_plugin.so.0.0.0:
 ELF 64-bit LSB shared object, x86-64, version 1 (FreeBSD), dynamically linked, 
not stripped
/usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/lto-wrapper:           
 ELF 64-bit LSB executable, x86-64, version 1 (FreeBSD), dynamically linked, 
interpreter /libexec/ld-elf.so.1, for FreeBSD 12.0 (1200036), FreeBSD-style, 
not stripped
/usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/lto1:                  
 ELF 64-bit LSB executable, x86-64, version 1 (FreeBSD), dynamically linked, 
interpreter /libexec/ld-elf.so.1, for FreeBSD 12.0 (1200036), FreeBSD-style, 
not stripped
/usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/plugin:                
 directory

# ldd /usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/liblto_plugin.so
/usr/local/libexec/gcc/aarch64-unknown-freebsd12.0/6.3.0/liblto_plugin.so:
        libc.so.7 => /lib/libc.so.7 (0x800825000)

# svnlite info /usr/ports/ | grep "Re[plv]"
Relative URL: ^/head
Repository Root: svn://svn.freebsd.org/ports
Repository UUID: 35697150-7ecd-e111-bb59-0022644237b5
Revision: 447082
Last Changed Rev: 447082



===
Mark Millard
markmi at dsl-only.net

_______________________________________________
freebsd-toolchain@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-toolchain
To unsubscribe, send any mail to "freebsd-toolchain-unsubscr...@freebsd.org"

Reply via email to