* [PATCH 1/2] configure: Use -print-libgcc-file-name to detect compiler runtime
@ 2017-03-16 5:22 Khem Raj
2017-03-16 5:22 ` [PATCH 2/2] configure: Remove -lgcc_eh from LIBCC Khem Raj
2017-03-25 18:11 ` [PATCH 1/2] configure: Use -print-libgcc-file-name to detect compiler runtime Dmitry Golovin
0 siblings, 2 replies; 3+ messages in thread
From: Khem Raj @ 2017-03-16 5:22 UTC (permalink / raw)
To: musl; +Cc: Khem Raj
This uses compiler to provide the path to its default runtime
library libgcc/compiler-rt, when using clang we can set
CC="clang --rtlib={compiler-rt|libgcc}" and it will find
the right compiler runtime when autodetecting it
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
configure | 2 ++
1 file changed, 2 insertions(+)
diff --git a/configure b/configure
index c2db298c..0c670dd8 100755
--- a/configure
+++ b/configure
@@ -587,6 +587,8 @@ tryldflag LDFLAGS_AUTO -Wl,--exclude-libs=ALL
tryldflag LDFLAGS_AUTO -Wl,-Bsymbolic-functions
# Find compiler runtime library
+test -z "$LIBCC" && try_libcc=`$CC -print-libgcc-file-name 2>/dev/null` \
+ && tryldflag LIBCC "$try_libcc"
test -z "$LIBCC" && tryldflag LIBCC -lgcc && tryldflag LIBCC -lgcc_eh
test -z "$LIBCC" && tryldflag LIBCC -lcompiler_rt
test -z "$LIBCC" && try_libcc=`$CC -print-file-name=libpcc.a 2>/dev/null` \
--
2.12.0
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH 2/2] configure: Remove -lgcc_eh from LIBCC
2017-03-16 5:22 [PATCH 1/2] configure: Use -print-libgcc-file-name to detect compiler runtime Khem Raj
@ 2017-03-16 5:22 ` Khem Raj
2017-03-25 18:11 ` [PATCH 1/2] configure: Use -print-libgcc-file-name to detect compiler runtime Dmitry Golovin
1 sibling, 0 replies; 3+ messages in thread
From: Khem Raj @ 2017-03-16 5:22 UTC (permalink / raw)
To: musl; +Cc: Khem Raj
-lgcc_eh was needed with old gcc/arm toolchain where
div0 function in libgcc invoked an exception and
inturn pulled in eh
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
configure | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/configure b/configure
index 0c670dd8..ca9a588f 100755
--- a/configure
+++ b/configure
@@ -589,7 +589,7 @@ tryldflag LDFLAGS_AUTO -Wl,-Bsymbolic-functions
# Find compiler runtime library
test -z "$LIBCC" && try_libcc=`$CC -print-libgcc-file-name 2>/dev/null` \
&& tryldflag LIBCC "$try_libcc"
-test -z "$LIBCC" && tryldflag LIBCC -lgcc && tryldflag LIBCC -lgcc_eh
+test -z "$LIBCC" && tryldflag LIBCC -lgcc && tryldflag LIBCC
test -z "$LIBCC" && tryldflag LIBCC -lcompiler_rt
test -z "$LIBCC" && try_libcc=`$CC -print-file-name=libpcc.a 2>/dev/null` \
&& tryldflag LIBCC "$try_libcc"
--
2.12.0
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH 1/2] configure: Use -print-libgcc-file-name to detect compiler runtime
2017-03-16 5:22 [PATCH 1/2] configure: Use -print-libgcc-file-name to detect compiler runtime Khem Raj
2017-03-16 5:22 ` [PATCH 2/2] configure: Remove -lgcc_eh from LIBCC Khem Raj
@ 2017-03-25 18:11 ` Dmitry Golovin
1 sibling, 0 replies; 3+ messages in thread
From: Dmitry Golovin @ 2017-03-25 18:11 UTC (permalink / raw)
To: musl
[-- Attachment #1: Type: text/html, Size: 3507 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-03-25 18:11 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-03-16 5:22 [PATCH 1/2] configure: Use -print-libgcc-file-name to detect compiler runtime Khem Raj
2017-03-16 5:22 ` [PATCH 2/2] configure: Remove -lgcc_eh from LIBCC Khem Raj
2017-03-25 18:11 ` [PATCH 1/2] configure: Use -print-libgcc-file-name to detect compiler runtime Dmitry Golovin
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/musl/
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 NNTP newsgroup(s).