* [crosstool-ng/crosstool-ng] 52203d: Fix sh4-unknown-linux-gnu sample.
@ 2015-10-20 3:05 Bryan Hundven
0 siblings, 0 replies; only message in thread
From: Bryan Hundven @ 2015-10-20 3:05 UTC (permalink / raw)
To: crossgcc
[-- Attachment #1: Type: text/plain, Size: 2157 bytes --]
Branch: refs/heads/master
Home: https://github.com/crosstool-ng/crosstool-ng
Commit: 52203df900d210b4c3d8741c5e1f61995e8bcc90
https://github.com/crosstool-ng/crosstool-ng/commit/52203df900d210b4c3d8741c5e1f61995e8bcc90
Author: Alexey Neyman <stilor@att.net>
Date: 2015-10-15 (Thu, 15 Oct 2015)
Changed paths:
M samples/sh4-unknown-linux-gnu/crosstool.config
Log Message:
-----------
Fix sh4-unknown-linux-gnu sample.
The issue with this sample is that the sh4-* targets in GCC do not
implement __builtin_trap() function. Starting with release 5.1,
GCC inserts abort() calls where NULL pointers are dereferenced. The
elf/dl-conflict.c in glibc is one such place: it calls elf_machine_rela
with NULL `sym' pointer. This causes an undefined `abort' symbol to
appear in the object file and as a result, pulls in some files during
the linking of the dynamic loader that are not supposed to. Eventually,
it results in link error due to multiple definitions of _itoa and some
other symbols.
The right fix would be to implement __builtin_trap() for sh4 in GCC.
A workaround would be adding -fno-delete-null-pointer-checks to
CFLAGS-dl-conflict.c in elf/Makefile. Until either of these happens,
though, pin the GCC version to 4.9.3 - the last that did not generate
`abort' calls. Note that the version where GCC started to generate
`abort' calls is apparently different for different architectures;
the issue in [1] was reported against GCC 4.9.
References:
[1] https://www.sourceware.org/ml/libc-alpha/2014-10/msg00807.html
(similar issue on HP-PA which was resolved by implementing
__builtin_trap)
Commit: 1b29d4e8f649b121372fe25919e881a87f15e5bd
https://github.com/crosstool-ng/crosstool-ng/commit/1b29d4e8f649b121372fe25919e881a87f15e5bd
Author: Bryan Hundven <bryanhundven@gmail.com>
Date: 2015-10-19 (Mon, 19 Oct 2015)
Changed paths:
M samples/sh4-unknown-linux-gnu/crosstool.config
Log Message:
-----------
Merge pull request #196 from stilor/sh4-fix-abort
Restore sh4-unknown-linux-gnu sample.
Compare: https://github.com/crosstool-ng/crosstool-ng/compare/8433e9914d33...1b29d4e8f649
[-- Attachment #2: Type: text/plain, Size: 71 bytes --]
--
For unsubscribe information see http://sourceware.org/lists.html#faq
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2015-10-20 3:05 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-20 3:05 [crosstool-ng/crosstool-ng] 52203d: Fix sh4-unknown-linux-gnu sample Bryan Hundven
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).