Date: Tue, 22 Sep 2015 12:57:07 -0700 From: Sean Bruno <sbruno@freebsd.org> To: freebsd-mips@freebsd.org Subject: MIPS Clang Update Message-ID: <5601B293.7090804@freebsd.org>
next in thread | raw e-mail | index | archive | help
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA512 With the help of Daniel Sanders at Imagination Tech, we got most of the required bits committed to llvm/clang that are required to compile libc. The only require diff is here: https://people.freebsd.org/~sbruno/clang_mips.diff MIPS32 in clang/llvm is a bit of a trainwreck. clang/llvm assumes that MIPS-III is 64bit only, so I'm skipping further testing until some resolution of this matter is found. MIPS64 on the other hand is workable. Using the following make.conf and src.conf, I can get to the final linking stage of libc. Clang/llvm appears to be generating objects that our base system binutils doesn't understand. I've attempted to remove ELF entries one at a time to resolve this linking issue to no avail. Basically, I'm stuck and don't see a way out. /var/tmp/mips.mips64/usr/home/sbruno/fbsd_head/tmp/usr/bin/ld: /var/tmp/mips.mips64/usr/home/sbruno/fbsd_head/tmp/usr/lib/crtbeginS.o: CALL16 reloc at 0x8 not against global symbol /var/tmp/mips.mips64/usr/home/sbruno/fbsd_head/tmp/usr/lib/crtbeginS.o: could not read symbols: Bad value clang-3.8: error: linker command failed with exit code 1 (use -v to see invocation) Upstream binutils is even worse in this matter and I've come to the conclusion that its unworkable. Our intree gcc generates an object that has the following ELF informatio n: https://people.freebsd.org/~sbruno/gcc_crtbeginS.o.txt Whereas clang/trunk generates: https://people.freebsd.org/~sbruno/clang_crtbeginS.o.txt Any advice and suggestions would be gladly accepted here. More or less, I'm stuck and can't progress with my limited understanding of the linker. - -- MALLOC_PRODUCTION=y NO_WERROR=y TARGET=mips TARGET_ARCH=mips64 XCFLAGS+=-Wno-typedef-redefinition XCC=/home/sbruno/clang/build/bin/clang XCPP=/home/sbruno/clang/build/bin/clang-cpp XCXX=/home/sbruno/clang/build/bin/clang++ LDFLAGS+=-v - -- WITHOUT_KERBEROS="YES" WITHOUT_KERBEROS_SUPPORT="YES" WITHOUT_NIS="YES" WITHOUT_NDIS="YES" WITHOUT_IPX="YES" WITHOUT_ATM="YES" WITHOUT_ICONV="YES" #WITHOUT_CLANG_IS_CC="YES" WITHOUT_CASPER="YES" WITHOUT_CAPSICUM="YES" WITHOUT_TESTS="YES" WITHOUT_GAMES="YES" WITHOUT_DOCS="YES" WITHOUT_MAN="YES" WITHOUT_INFO="YES" WITHOUT_LOCALES="YES" WITHOUT_NLS="YES" WITHOUT_EXAMPLES="YES" WITHOUT_ZFS="YES" WITHOUT_RCS="YES" WITHOUT_CLANG="YES" WITHOUT_CLANG_EXTRAS="YES" WITHOUT_CLANG_FULL="YES" WITHOUT_CLANG_BOOTSTRAP="YES" WITHOUT_GCC="YES" WITHOUT_GDB="YES" - -- -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQF8BAEBCgBmBQJWAbKPXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXRCQUFENDYzMkU3MTIxREU4RDIwOTk3REQx MjAxRUZDQTFFNzI3RTY0AAoJEBIB78oecn5kbmYH/1bfUwIumQSO9aY87QwuYDuY bDax/Ujwt0WhEUlZdtuA5KJ8XWGRq1Qm2r5foX0/k4JZA0XembJ9KTAIkdxOsXpn FcciN2R8pb4TvI3gfgNpT+dw8S+JJCTd3B5UsvmWA7gHGMS9iAFBNmhkzbh1HGHg 52U5MjSaAwIuar2pdMFBteGPpUmTPwH+DyM+rI3yixB2kUddTf8ay906rkT5PpBg 6n2CcE69LHqwal0b/g5OXAm9dL49btEaQQgV8zvmoygE+2xIcYQ4HbsbI/PKdniW ZCG7EkRtVL7CLl73NYSZvFB7Q9OEhAayr024ao5FIbHcVZDDsabuyryY4onYZ0s= =kJqd -----END PGP SIGNATURE-----
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5601B293.7090804>