* [PATCH] cc/gcc: fix gcc 4.8 build for C library without threads support
@ 2014-01-03 9:57 Niels Penneman
2014-01-03 11:30 ` Yann E. MORIN
2014-01-03 11:40 ` [PATCH] " Yann E. MORIN
0 siblings, 2 replies; 3+ messages in thread
From: Niels Penneman @ 2014-01-03 9:57 UTC (permalink / raw)
To: crossgcc
# HG changeset patch
# User Niels Penneman <niels@penneman.org>
# Date 1388743068 -3600
# Fri Jan 03 10:57:48 2014 +0100
# Node ID 309df93f4354c80e05c950ded710d111c50d7b26
# Parent 8e2077dfc250877b2182f31cac97bd1292e01026
cc/gcc: fix gcc 4.8 build for C library without threads support
Signed-off-by: Niels Penneman <niels@penneman.org>
diff -r 8e2077dfc250 -r 309df93f4354 scripts/build/cc/gcc.sh
--- a/scripts/build/cc/gcc.sh Fri Jan 03 00:13:15 2014 +0100
+++ b/scripts/build/cc/gcc.sh Fri Jan 03 10:57:48 2014 +0100
@@ -643,6 +643,11 @@
if [ -n "${CT_CC_ENABLE_CXX_FLAGS}" ]; then
extra_config+=("--enable-cxx-flags=${CT_CC_ENABLE_CXX_FLAGS}")
fi
+ if [ "${CT_CC_GCC_4_8_or_later}" = "y" ]; then
+ if [ "${CT_THREADS}" = "none" ]; then
+ extra_config+=(--disable-libatomic)
+ fi
+ fi
if [ "${CT_CC_GCC_LIBMUDFLAP}" = "y" ]; then
extra_config+=(--enable-libmudflap)
else
--
For unsubscribe information see http://sourceware.org/lists.html#faq
^ permalink raw reply [flat|nested] 3+ messages in thread
* cc/gcc: fix gcc 4.8 build for C library without threads support
2014-01-03 9:57 [PATCH] cc/gcc: fix gcc 4.8 build for C library without threads support Niels Penneman
@ 2014-01-03 11:30 ` Yann E. MORIN
2014-01-03 11:40 ` [PATCH] " Yann E. MORIN
1 sibling, 0 replies; 3+ messages in thread
From: Yann E. MORIN @ 2014-01-03 11:30 UTC (permalink / raw)
To: Niels Penneman; +Cc: crossgcc
Niels, All,
Your patch:
cc/gcc: fix gcc 4.8 build for C library without threads support
has been applied as: #6bf3336283c2
http://crosstool-ng.org/hg/crosstool-ng/rev/6bf3336283c2
Thank you!
Regards,
Yann E. MORIN.
--
For unsubscribe information see http://sourceware.org/lists.html#faq
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] cc/gcc: fix gcc 4.8 build for C library without threads support
2014-01-03 9:57 [PATCH] cc/gcc: fix gcc 4.8 build for C library without threads support Niels Penneman
2014-01-03 11:30 ` Yann E. MORIN
@ 2014-01-03 11:40 ` Yann E. MORIN
1 sibling, 0 replies; 3+ messages in thread
From: Yann E. MORIN @ 2014-01-03 11:40 UTC (permalink / raw)
To: Niels Penneman; +Cc: crossgcc
Niels, All,
On 2014-01-03 10:58 +0100, Niels Penneman spake thusly:
> # HG changeset patch
> # User Niels Penneman <niels@penneman.org>
> # Date 1388743068 -3600
> # Fri Jan 03 10:57:48 2014 +0100
> # Node ID 309df93f4354c80e05c950ded710d111c50d7b26
> # Parent 8e2077dfc250877b2182f31cac97bd1292e01026
> cc/gcc: fix gcc 4.8 build for C library without threads support
> Signed-off-by: Niels Penneman <niels@penneman.org>
Usually, we add an empty line after the subject. This scheme is canon
for DVCS (Hg, git) to separate the 'subject' from the 'body' of the
commit log, and display them correctly. That's a minor nit, I've fixed
it here.
Also, for this patch, the change is not obvious, so would have needed a
bit of explanations in the commit log, eg.:
cc/gcc: fix gcc 4.8 build for C library without threads support
libatomic calls the pthread primitives, which are not present if
the C library lacks threads support, and the build breaks.
In this case, just disable the build of libatomic.
Signed-off-by: you@there
I had to look at libatomic to understand why it would not build without
threads. Granted, that was kind of easy, but not obvious.
In a commit log that fixes a problem, you have to explain:
- what breaks
- why it breaks
- how you fixed it
Anyway, I've applied it nonetheless.
Thank you! :-)
Regards,
Yann E. MORIN.
> diff -r 8e2077dfc250 -r 309df93f4354 scripts/build/cc/gcc.sh
> --- a/scripts/build/cc/gcc.sh Fri Jan 03 00:13:15 2014 +0100
> +++ b/scripts/build/cc/gcc.sh Fri Jan 03 10:57:48 2014 +0100
> @@ -643,6 +643,11 @@
> if [ -n "${CT_CC_ENABLE_CXX_FLAGS}" ]; then
> extra_config+=("--enable-cxx-flags=${CT_CC_ENABLE_CXX_FLAGS}")
> fi
> + if [ "${CT_CC_GCC_4_8_or_later}" = "y" ]; then
> + if [ "${CT_THREADS}" = "none" ]; then
> + extra_config+=(--disable-libatomic)
> + fi
> + fi
> if [ "${CT_CC_GCC_LIBMUDFLAP}" = "y" ]; then
> extra_config+=(--enable-libmudflap)
> else
>
> --
> For unsubscribe information see http://sourceware.org/lists.html#faq
>
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
--
For unsubscribe information see http://sourceware.org/lists.html#faq
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-01-03 11:40 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-01-03 9:57 [PATCH] cc/gcc: fix gcc 4.8 build for C library without threads support Niels Penneman
2014-01-03 11:30 ` Yann E. MORIN
2014-01-03 11:40 ` [PATCH] " Yann E. MORIN
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).