public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* sh-*-linux build failure
@ 2015-03-08  8:14 Yoshinori Sato
  2015-03-08 13:14 ` Oleg Endo
  0 siblings, 1 reply; 7+ messages in thread
From: Yoshinori Sato @ 2015-03-08  8:14 UTC (permalink / raw)
  To: gcc-patches

Bootstrap failed in following configuration.

configure --target=sh-unknown-linux --enable-languages=c --disable-libatomic --disable-threads --disable-shared --disable-libssp --disable-libquadmath --disable-libgomp

xgcc: error: SH2a does not support little-endian

So add build exception for SH2A.

diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index ce183a0..1fb2344 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,7 @@
+2015-03-08  Yoshinori Sato <ysato@users.sourceforge.jp>
+
+	* config/sh/t-linux: Add exception for SH2A.
+
 2015-03-05  Jan Hubicka  <hubicka@ucw.cz>
 
 	PR ipa/65316
diff --git a/gcc/config/sh/t-linux b/gcc/config/sh/t-linux
index d33c638..22b8e3e 100644
--- a/gcc/config/sh/t-linux
+++ b/gcc/config/sh/t-linux
@@ -1,2 +1,3 @@
 MULTILIB_DIRNAMES= 
-MULTILIB_MATCHES = 
+MULTILIB_MATCHES =
+MULTILIB_EXCEPTIONS = m2a m2a/ml

-- 
Yoshinori Sato
<ysato@users.sourceforge.jp>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: sh-*-linux build failure
  2015-03-08  8:14 sh-*-linux build failure Yoshinori Sato
@ 2015-03-08 13:14 ` Oleg Endo
  2015-03-08 14:14   ` Kaz Kojima
  0 siblings, 1 reply; 7+ messages in thread
From: Oleg Endo @ 2015-03-08 13:14 UTC (permalink / raw)
  To: Yoshinori Sato; +Cc: gcc-patches, Kaz Kojima

On Sun, 2015-03-08 at 17:14 +0900, Yoshinori Sato wrote:
> Bootstrap failed in following configuration.
> 
> configure --target=sh-unknown-linux --enable-languages=c
> --disable-libatomic --disable-threads --disable-shared --disable-libssp
> --disable-libquadmath --disable-libgomp
> 
> xgcc: error: SH2a does not support little-endian
> 
> So add build exception for SH2A.
> 
> diff --git a/gcc/ChangeLog b/gcc/ChangeLog
> index ce183a0..1fb2344 100644
> --- a/gcc/ChangeLog
> +++ b/gcc/ChangeLog
> @@ -1,3 +1,7 @@
> +2015-03-08  Yoshinori Sato <ysato@users.sourceforge.jp>
> +
> +	* config/sh/t-linux: Add exception for SH2A.
> +
>  2015-03-05  Jan Hubicka  <hubicka@ucw.cz>
>  
>  	PR ipa/65316
> diff --git a/gcc/config/sh/t-linux b/gcc/config/sh/t-linux
> index d33c638..22b8e3e 100644
> --- a/gcc/config/sh/t-linux
> +++ b/gcc/config/sh/t-linux
> @@ -1,2 +1,3 @@
>  MULTILIB_DIRNAMES= 
> -MULTILIB_MATCHES = 
> +MULTILIB_MATCHES =
> +MULTILIB_EXCEPTIONS = m2a m2a/ml

This disables SH2A completely?  AFAIK SH2A big-endian Linux is a valid
configuration.  It should be 'm2a/ml' only, as in t-sh.  Although all of
that will probably not work if --with-endian=little,big or
--with-endian=little is specified as configure option.

Cheers,
Oleg

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: sh-*-linux build failure
  2015-03-08 13:14 ` Oleg Endo
@ 2015-03-08 14:14   ` Kaz Kojima
  2015-03-09  8:38     ` Yoshinori Sato
  0 siblings, 1 reply; 7+ messages in thread
From: Kaz Kojima @ 2015-03-08 14:14 UTC (permalink / raw)
  To: oleg.endo; +Cc: ysato, gcc-patches

Oleg Endo <oleg.endo@t-online.de> wrote:
>> diff --git a/gcc/config/sh/t-linux b/gcc/config/sh/t-linux
>> index d33c638..22b8e3e 100644
>> --- a/gcc/config/sh/t-linux
>> +++ b/gcc/config/sh/t-linux
>> @@ -1,2 +1,3 @@
>>  MULTILIB_DIRNAMES= 
>> -MULTILIB_MATCHES = 
>> +MULTILIB_MATCHES =
>> +MULTILIB_EXCEPTIONS = m2a m2a/ml
> 
> This disables SH2A completely?  AFAIK SH2A big-endian Linux is a valid
> configuration.  It should be 'm2a/ml' only, as in t-sh.  Although all of
> that will probably not work if --with-endian=little,big or
> --with-endian=little is specified as configure option.

How about a bit modified patch below?

Regards,
	kaz
--
	* config/sh/t-linux (MULTILIB_EXCEPTIONS): Define for m2a cases.

diff --git a/config/sh/t-linux b/config/sh/t-linux
index d33c638..a30ab2e 100644
--- a/config/sh/t-linux
+++ b/config/sh/t-linux
@@ -1,2 +1,9 @@
 MULTILIB_DIRNAMES= 
 MULTILIB_MATCHES = 
+
+DEFAULT_ENDIAN = $(word 1,$(TM_ENDIAN_CONFIG))
+ifeq ($(DEFAULT_ENDIAN),ml)
+MULTILIB_EXCEPTIONS = m2a m2a/ml
+else
+MULTILIB_EXCEPTIONS = ml/m2a
+endif

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: sh-*-linux build failure
  2015-03-08 14:14   ` Kaz Kojima
@ 2015-03-09  8:38     ` Yoshinori Sato
  2015-03-09 23:19       ` Kaz Kojima
  0 siblings, 1 reply; 7+ messages in thread
From: Yoshinori Sato @ 2015-03-09  8:38 UTC (permalink / raw)
  To: Kaz Kojima; +Cc: oleg.endo, gcc-patches

At Sun, 08 Mar 2015 23:14:10 +0900 (JST),
Kaz Kojima wrote:
> 
> Oleg Endo <oleg.endo@t-online.de> wrote:
> >> diff --git a/gcc/config/sh/t-linux b/gcc/config/sh/t-linux
> >> index d33c638..22b8e3e 100644
> >> --- a/gcc/config/sh/t-linux
> >> +++ b/gcc/config/sh/t-linux
> >> @@ -1,2 +1,3 @@
> >>  MULTILIB_DIRNAMES= 
> >> -MULTILIB_MATCHES = 
> >> +MULTILIB_MATCHES =
> >> +MULTILIB_EXCEPTIONS = m2a m2a/ml
> > 
> > This disables SH2A completely?  AFAIK SH2A big-endian Linux is a valid
> > configuration.  It should be 'm2a/ml' only, as in t-sh.  Although all of
> > that will probably not work if --with-endian=little,big or
> > --with-endian=little is specified as configure option.
> 
> How about a bit modified patch below?
> 
> Regards,
> 	kaz
> --
> 	* config/sh/t-linux (MULTILIB_EXCEPTIONS): Define for m2a cases.
> 
> diff --git a/config/sh/t-linux b/config/sh/t-linux
> index d33c638..a30ab2e 100644
> --- a/config/sh/t-linux
> +++ b/config/sh/t-linux
> @@ -1,2 +1,9 @@
>  MULTILIB_DIRNAMES= 
>  MULTILIB_MATCHES = 
> +
> +DEFAULT_ENDIAN = $(word 1,$(TM_ENDIAN_CONFIG))
> +ifeq ($(DEFAULT_ENDIAN),ml)
> +MULTILIB_EXCEPTIONS = m2a m2a/ml
> +else
> +MULTILIB_EXCEPTIONS = ml/m2a
> +endif

It works fine.
Thanks.

-- 
Yoshinori Sato
<ysato@users.sourceforge.jp>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: sh-*-linux build failure
  2015-03-09  8:38     ` Yoshinori Sato
@ 2015-03-09 23:19       ` Kaz Kojima
  2015-03-10  9:05         ` Oleg Endo
  0 siblings, 1 reply; 7+ messages in thread
From: Kaz Kojima @ 2015-03-09 23:19 UTC (permalink / raw)
  To: ysato; +Cc: oleg.endo, gcc-patches

Yoshinori Sato <ysato@users.sourceforge.jp> wrote:
>> 	* config/sh/t-linux (MULTILIB_EXCEPTIONS): Define for m2a cases.
[snip]
> It works fine.

Thanks for checking.  I've committed it on trunk as revision 221287.

Regards,
	kaz

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: sh-*-linux build failure
  2015-03-09 23:19       ` Kaz Kojima
@ 2015-03-10  9:05         ` Oleg Endo
  2015-03-10 11:06           ` Kaz Kojima
  0 siblings, 1 reply; 7+ messages in thread
From: Oleg Endo @ 2015-03-10  9:05 UTC (permalink / raw)
  To: Kaz Kojima; +Cc: ysato, gcc-patches

[-- Attachment #1: Type: text/plain, Size: 645 bytes --]

On Tue, 2015-03-10 at 08:19 +0900, Kaz Kojima wrote:
> Yoshinori Sato <ysato@users.sourceforge.jp> wrote:
> >> 	* config/sh/t-linux (MULTILIB_EXCEPTIONS): Define for m2a cases.
> [snip]
> > It works fine.
> 
> Thanks for checking.  I've committed it on trunk as revision 221287.
> 
> Regards,
> 	kaz
> 

I think the same should be done in t-sh and in t-linux we could add the
SH1 little endian exception, too ... just in case (see attached patch).
I'm not sure whether TM_MULTILIB_EXCEPTIONS_CONFIG is needed in t-linux
or not.  Moreover, I don't understand why t-linux doesn't pick up
MULTILIB_EXCEPTIONS from t-sh.... any ideas?

Cheers,
Oleg

[-- Attachment #2: sh_multilib_sh1_sh2a_ml.patch --]
[-- Type: text/x-patch, Size: 1128 bytes --]

Index: gcc/config/sh/t-linux
===================================================================
--- gcc/config/sh/t-linux	(revision 221308)
+++ gcc/config/sh/t-linux	(working copy)
@@ -1,9 +1,9 @@
 MULTILIB_DIRNAMES= 
 MULTILIB_MATCHES = 
 
-DEFAULT_ENDIAN = $(word 1,$(TM_ENDIAN_CONFIG))
+# SH1 and SH2A support big endian only.
 ifeq ($(DEFAULT_ENDIAN),ml)
-MULTILIB_EXCEPTIONS = m2a m2a/ml
+MULTILIB_EXCEPTIONS = m1 ml/m1 m2a* ml/m2a* $(TM_MULTILIB_EXCEPTIONS_CONFIG)
 else
-MULTILIB_EXCEPTIONS = ml/m2a
+MULTILIB_EXCEPTIONS = ml/m1 ml/m2a* $(TM_MULTILIB_EXCEPTIONS_CONFIG)
 endif
Index: gcc/config/sh/t-sh
===================================================================
--- gcc/config/sh/t-sh	(revision 221308)
+++ gcc/config/sh/t-sh	(working copy)
@@ -63,8 +63,12 @@
     done \
   done)
 
-# SH1 only supports big endian.
+# SH1 and SH2A support big endian only.
+ifeq ($(DEFAULT_ENDIAN),ml)
+MULTILIB_EXCEPTIONS = m1 ml/m1 m2a* ml/m2a* $(TM_MULTILIB_EXCEPTIONS_CONFIG)
+else
 MULTILIB_EXCEPTIONS = ml/m1 ml/m2a* $(TM_MULTILIB_EXCEPTIONS_CONFIG)
+endif
 
 MULTILIB_OSDIRNAMES = \
 	$(OTHER_ENDIAN)=!$(OTHER_ENDIAN) \

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: sh-*-linux build failure
  2015-03-10  9:05         ` Oleg Endo
@ 2015-03-10 11:06           ` Kaz Kojima
  0 siblings, 0 replies; 7+ messages in thread
From: Kaz Kojima @ 2015-03-10 11:06 UTC (permalink / raw)
  To: oleg.endo; +Cc: ysato, gcc-patches

Oleg Endo <oleg.endo@t-online.de> wrote:
> I think the same should be done in t-sh and in t-linux we could add the
> SH1 little endian exception, too ... just in case (see attached patch).
> I'm not sure whether TM_MULTILIB_EXCEPTIONS_CONFIG is needed in t-linux
> or not.  Moreover, I don't understand why t-linux doesn't pick up
> MULTILIB_EXCEPTIONS from t-sh.... any ideas?

Your patch looks OK, though I guess that the current t-linux would
be enough.  sh-linux compiler requires libc implementation and some
combinations aren't practical for t-linux in the first place.

Regards,
	kaz

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2015-03-10 11:06 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-08  8:14 sh-*-linux build failure Yoshinori Sato
2015-03-08 13:14 ` Oleg Endo
2015-03-08 14:14   ` Kaz Kojima
2015-03-09  8:38     ` Yoshinori Sato
2015-03-09 23:19       ` Kaz Kojima
2015-03-10  9:05         ` Oleg Endo
2015-03-10 11:06           ` Kaz Kojima

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).