Re: ports head -r487783: on armv7 x11/pixman fails to build: /usr/bin/ld: error: can't create dynamic relocation R_ARM_V4BX against local symbol in readonly segment; recompile object files with -fPI
[The update to lld/trunk/ELF/Arch/ARM.cpp will not fix what we have run into.] On 2018-Nov-16, at 19:35, Mark Millard wrote: > Such timing: https://reviews.llvm.org/D53444 indicates > commits to lld/trunk/ELF/Arch/ARM.cpp today (2018-Nov-16) > to support R_ARM_V4BX in lld. > > (No update text below. The above just did not fit well.) > > On 2018-Nov-16, at 18:49, Mark Millard wrote: > > >> On 2018-Nov-16, at 18:15, Mark Millard wrote: >> >>> >>> I finally figured out parts of the issue, I think. >>> At least how the V_ARM_V4BX use is getting there >>> despite lld's status for handling it . . . >>> >>> On armv7: >>> >>> # more test_bx_lr.S >>> .text >>> .arch armv6 >>> .object_arch armv4 >>> .arm >>> .altmacro >>> .p2align 2 >>> .func fname >>> .global fname >>> .hidden fname >>> .type fname, %function >>> fname: >>> bx lr >>> >>> (I got those lines from the failing port's .S files, >>> including includes. Note the .object_arch armv4 use >>> and the forced armv6, not armv7.) >> >> For reference relative to the use of .object_arch armv4 : >> >> # grep -r object_arch >> /wrkdirs/usr/ports/x11/pixman/work/pixman-0.34.0/pixman/ | more >> /wrkdirs/usr/ports/x11/pixman/work/pixman-0.34.0/pixman/pixman-arm-neon-asm.S: >> .object_arch armv4 >> /wrkdirs/usr/ports/x11/pixman/work/pixman-0.34.0/pixman/pixman-arm-simd-asm-scaled.S: >>.object_arch armv4 >> /wrkdirs/usr/ports/x11/pixman/work/pixman-0.34.0/pixman/pixman-arm-neon-asm-bilinear.S:.object_arch >> armv4 >> /wrkdirs/usr/ports/x11/pixman/work/pixman-0.34.0/pixman/pixman-arm-simd-asm.S: >> .object_arch armv4 >> >> Without .object_arch armv4 the assembler involved does not output >> the V_ARM_V4BX *ABS* relocation records (adjusted the small example): >> >> # objdump -x test_bx_lr.o | more >> >> test_bx_lr.o: file format elf32-littlearm >> test_bx_lr.o >> architecture: arm, flags 0x0010: >> HAS_SYMS >> start address 0x >> private flags = 500: [Version5 EABI] >> >> Sections: >> Idx Name Size VMA LMA File off Algn >> 0 .text 0004 0034 2**2 >> CONTENTS, ALLOC, LOAD, READONLY, CODE >> 1 .data 0038 2**0 >> CONTENTS, ALLOC, LOAD, DATA >> 2 .bss 0038 2**0 >> ALLOC >> 3 .ARM.attributes 001b 0038 2**0 >> CONTENTS, READONLY >> SYMBOL TABLE: >> ld .text .text >> ld .data .data >> ld .bss .bss >> ld .ARM.attributes .ARM.attributes >> g F .text .hidden fname >> >> >> >>> # clang -target armv7-unknown-freebsd13.0-gnueabihf -O -pipe >>> -no-integrated-as -MT test_bx_lr.lo -MD -MP -MF test_bx_lr.Tpo -c >>> test_bx_lr.S -fPIC -DPIC -o test_bx_lr.o >>> >>> (The -target is not necessary. I just choose to be explicit.) >>> >>> # objdump -x test_bx_lr.o | more >>> >>> test_bx_lr.o: file format elf32-littlearm >>> test_bx_lr.o >>> architecture: armv4, flags 0x0011: >>> HAS_RELOC, HAS_SYMS >>> start address 0x >>> private flags = 500: [Version5 EABI] >>> >>> Sections: >>> Idx Name Size VMA LMA File off Algn >>> 0 .text 0004 0034 2**2 >>>CONTENTS, ALLOC, LOAD, RELOC, READONLY, CODE >>> 1 .data 0038 2**0 >>>CONTENTS, ALLOC, LOAD, DATA >>> 2 .bss 0038 2**0 >>>ALLOC >>> 3 .ARM.attributes 001b 0038 2**0 >>>CONTENTS, READONLY >>> SYMBOL TABLE: >>> ld .text .text >>> ld .data .data >>> ld .bss .bss >>> ld .ARM.attributes .ARM.attributes >>> g F .text .hidden fname >>> >>> >>> RELOCATION RECORDS FOR [.text]: >>> OFFSET TYPE VALUE >>> R_ARM_V4BX*ABS* >>> >>> >>> truss for that cc command reports looking in many >>> places for as, finally finding /usr/local/bin/as : >>> >>> access("/usr/bin/armv7-unknown-freebsd13.0-gnueabihf-as",X_OK|R_OK) ERR#2 >>> 'No such file or directory' >>> access("/usr/bin/as",X_OK|R_OK) ERR#2 'No such file or >>> directory' >>> >>> (Note: based on WITHOUT_BINUTILS= for buildworld the above would normally >>> not be found. But for WITH_BINUTILS= the host as would be found.) >>> >>> access("/sbin/armv7-unknown-freebsd13.0-gnueabihf-as",X_OK|R_OK) ERR#2 'No >>> such file or directory' >>> access("/bin/armv7-unknown-freebsd13.0-gnueabihf-as",X_OK|R_OK) ERR#2 'No >>> such file or directory' >>> access("/usr/sbin/armv7-unknown-freebsd13.0-
INDEX build failed for 11.x
INDEX build failed with errors: Generating INDEX-11 - please wait..--- describe.accessibility --- --- describe.arabic --- --- describe.archivers --- --- describe.astro --- --- describe.audio --- --- describe.benchmarks --- --- describe.biology --- --- describe.cad --- --- describe.chinese --- --- describe.comms --- --- describe.converters --- --- describe.databases --- --- describe.deskutils --- --- describe.devel --- --- describe.dns --- --- describe.editors --- --- describe.emulators --- --- describe.finance --- --- describe.french --- --- describe.ftp --- [...] --- describe.print --- --- describe.russian --- --- describe.science --- --- describe.security --- --- describe.shells --- --- describe.sysutils --- --- describe.textproc --- --- describe.ukrainian --- --- describe.vietnamese --- --- describe.www --- --- describe.x11 --- --- describe.x11-clocks --- --- describe.x11-drivers --- --- describe.x11-fm --- --- describe.x11-fonts --- --- describe.x11-servers --- --- describe.x11-themes --- --- describe.x11-toolkits --- --- describe.x11-wm --- Done. make_index: /home/indexbuild/tindex/ports/sysutils/desktop-installer: no entry for /home/indexbuild/tindex/ports/wip/auto-admin Committers on the hook: antoine arved fernape joneum jwb ume yuri Most recent SVN update was: Updating '.': Ugraphics/tiff/Makefile Ugraphics/tiff/distinfo Dgraphics/tiff/files/patch-CVE-2017-18013 Dgraphics/tiff/files/patch-CVE-2017-9935 Ugraphics/tiff/files/patch-Makefile.in Ugraphics/tiff/files/patch-tiffcrop.1 Ugraphics/tiff/pkg-plist Usysutils/desktop-installer/Makefile Usysutils/desktop-installer/distinfo Usysutils/desktop-installer/pkg-plist Usysutils/auto-admin/Makefile Usysutils/auto-admin/distinfo Usysutils/auto-admin/pkg-plist Utextproc/retext/Makefile Uaudio/csound6/Makefile Uaudio/csound6/distinfo Daudio/csound6/files/patch-frontends_CsoundAC_ChordSpace.hpp Daudio/csound6/files/patch-frontends_CsoundAC_Counterpoint.cpp Daudio/csound6/files/patch-frontends_CsoundAC_Composition.cpp Daudio/csound6/files/patch-Opcodes_chua_ChuaOscillator.cpp Daudio/csound6/files/patch-frontends_CsoundAC_Counterpoint.hpp Aaudio/csound6/files/patch-CMakeLists.txt Uaudio/csound6/files/patch-InOut_rtalsa.c Aaudio/csound6/files/patch-Opcodes_stk_CMakeLists.txt Uaudio/csound6/files/patch-Top_csound.c Aaudio/csound6/files/patch-cmake_Modules_FindFAUST.cmake Uaudio/csound6/pkg-descr Uaudio/csound6/pkg-plist Usecurity/cyrus-sasl2/Makefile Usecurity/cyrus-sasl2/Makefile.common Usecurity/cyrus-sasl2/distinfo Dsecurity/cyrus-sasl2/files/patch-plugins_srp.c Dsecurity/cyrus-sasl2/files/patch-plugins_ntlm.c Dsecurity/cyrus-sasl2/files/patch-plugins__ldapdb.c Dsecurity/cyrus-sasl2/files/patch-Makefile.am Dsecurity/cyrus-sasl2/files/patch-plugins_passdss.c Dsecurity/cyrus-sasl2/files/patch-crypto-compat.c Dsecurity/cyrus-sasl2/files/patch-crypto-compat.h Dsecurity/cyrus-sasl2/files/patch-saslauthd_Makefile.am Dsecurity/cyrus-sasl2/files/patch-sasldb_db__ndbm.c Dsecurity/cyrus-sasl2/files/patch-libsasl2.pc.in Dsecurity/cyrus-sasl2/files/patch-include__sasl.h Dsecurity/cyrus-sasl2/files/patch-saslauthd_lak.c Dsecurity/cyrus-sasl2/files/patch-plugins_Makefile.am Dsecurity/cyrus-sasl2/files/patch-saslauthd__configure Dsecurity/cyrus-sasl2/files/patch-plugins_otp.c Dsecurity/cyrus-sasl2/files/patch-lib_Makefile.am Dsecurity/cyrus-sasl2/files/patch-saslauthd__saslcache.c Usecurity/cyrus-sasl2/files/patch-configure Usecurity/cyrus-sasl2/files/patch-plugins_gssapi.c Usecurity/cyrus-sasl2/files/pkg-deinstall.in Usecurity/cyrus-sasl2/files/pkg-install.in Usecurity/cyrus-sasl2/pkg-plist Usecurity/cyrus-sasl2-gssapi/Makefile Usecurity/cyrus-sasl2-gssapi/pkg-descr Usecurity/cyrus-sasl2-ldapdb/Makefile Usecurity/cyrus-sasl2-ldapdb/pkg-descr Usecurity/cyrus-sasl2-saslauthd/Makefile Usecurity/cyrus-sasl2-saslauthd/pkg-descr Usecurity/cyrus-sasl2-saslauthd/pkg-plist Usecurity/cyrus-sasl2-sql/pkg-descr Usecurity/cyrus-sasl2-srp/pkg-descr Usecurity/vuxml/vuln.xml Dmisc/freebsd-release-manifests/files/MANIFESTS/powerpc-powerpc-12.0-BETA1 Dmisc/freebsd-release-manifests/files/MANIFESTS/powerpc-powerpc-12.0-BETA2 D misc/freebsd-release-manifests/files/MANIFESTS/powerpc-powerpcspe-12.0-BETA1 D misc/freebsd-release-manifests/files/MANIFESTS/powerpc-powerpcspe-12.0-BETA2 Dmisc/freebsd-release-manifests/files/MANIFESTS/powerpc-powerpc64-12.0-BETA1 Dmisc/freebsd-release-manifests/files/MANIFESTS/powerpc-powerpc64-12.0-BETA2 Dmisc/freebsd-release-manifests/files/MANIFESTS/arm64-aarch64-12.0-BETA1 Dmisc/freebsd-release-manifests/files/MANIFESTS/arm64-aarch64-12.0-BETA2 Dmisc/freebsd-release-manifests/files/MANIFESTS/amd64-amd64-12.0-BETA1 Dmisc/freebsd-release-manifests/files/MANIFESTS/amd64-am
INDEX now builds successfully on 11.x
___ freebsd-ports@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-ports To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"