diff mbox

Continue toplevel cleanup (GCC library handling for unsupported targets etc.)

Message ID Pine.LNX.4.64.1103292045250.2595@digraph.polyomino.org.uk
State New
Headers show

Commit Message

Joseph Myers March 29, 2011, 8:55 p.m. UTC
This patch continues cleaning up the toplevel configure.ac, in particular 
as regards cases handling GCC libraries for targets where GCC is no longer 
(or never was) supported.

The principle there, as discussed for the original deprecated targets 
removal patch, is that in the absence of GCC support for a target it 
doesn't matter exactly how toplevel is configured to build GCC libraries 
(or other GCC-related directories) for that target - builds will and 
should fail if GCC is included in the source tree - so toplevel 
configure.ac should be set up for maximal simplicity.  In most cases that 
means no explicit mention of GCC libraries for such a target; in some 
cases it means removing the target entry altogether so that another case 
becomes active instead (possibly the *-*-* case that disables libgcj 
only).

In general cases just disabling libgcj are redundant with the *-*-* case 
unless they prevent some other case being active for the target, and so 
are removed.  There were also a couple of removed cases for targets with 
no support in GCC or src at all (romp-*-*, vax-*-vms) - if there's no 
support in GCC or src, it's right that a build should fail trying to build 
whatever sources you have there, and silly for toplevel to try disabling 
everything because nothing is supported.

Other cleanups here: noconfigdirs="$noconfigdirs" is completely useless 
and was removed; c54x*-*-* is always mapped to tic54x-*-* by config.sub so 
that case can be simplified; cris*-*-none acts just like cris*-*-elf in 
config.gcc so it's appropriate to make the "*" subcase of cris*-*-* act 
like the -elf case; mmix-*-* disabled "libgloss", i.e. libgloss for the 
host, which is never built anyway.

OK to commit?

2011-03-29  Joseph Myers  <joseph@codesourcery.com>

	* configure.ac (*-*-chorusos): Don't disable libgcj.
	(*-*-freebsd[[12]] | *-*-freebsd[[12]].* | *-*-freebsd*aout*):
	Remove case.
	(*-*-kaos*): Don't disable GCC libraries, zlib or fastjar.
	(arm-*-coff): Don't disable libgcj.
	(arm*-*-linux-gnueabi): Remove useless assignment.
	(arm-*-riscix*): Don't disable libgcj.
	(bfin-*-*): Don't enable target-bsp and target-cygmon depending on
	configuration.
	(c4x-*-* | tic4x-*-*): Don't disable GCC libraries.
	(c54x*-*-*): Remove case.
	(tic54x-*-*): Don't disable GCC or GCC libraries.
	(cris-*-* | crisv32-*-*): Don't handle *-*-aout.  Change *-*-elf
	to *.
	(d10v-*-*): Don't disable GCC libraries.
	(d30v-*-*): Don't disable libgcj.
	(h8500-*-*): Don't disable GCC libraries.
	(i960-*-*): Don't disable libgcj.
	(i[[3456789]]86-*-linux*): Don't handle *-*-*libc1*.
	(i[[3456789]]86-*-sco3.2v5*, i[[3456789]]86-*-sco*,
	i[[3456789]]86-*-sysv4*, i[[3456789]]86-*-beos*): Don't disable
	libgcj.
	(m68k-*-coff*): Remove case.
	(mmix-*-*): Don't disable libgloss on host.
	(mn10200-*-*, mn10300-*-*): Remove cases.
	(powerpc*-*-winnt* | powerpc*-*-pe*, powerpcle-*-solaris*,
	powerpc-*-beos*, m68k-apollo-*, mips*-*-irix5*, mips*-*-bsd*):
	Don't disable libgcj.
	(romp-*-*): Remove case.
	(sparclite-*-*, sparc-*-sunos4*): Don't disable libgcj.
	(sparc-*-solaris2.[[0-6]] | sparc-*-solaris2.[[0-6]].*): Remove
	case.
	(v810-*-*): Don't disable GCC libraries.
	(v850*-*-*, vax-*-vms, xtensa*-*-*): Remove cases.
	(ip2k-*-*): Don't disable GCC libraries.
	* configure: Regenerate.

Comments

Joseph Myers March 29, 2011, 9:10 p.m. UTC | #1
On Tue, 29 Mar 2011, Joseph S. Myers wrote:

> Other cleanups here:

Also: bfin-*-* had code relating to target-bsp and target-cygmon, but 
there is no actual Makefile.* support for building those, so the code 
relating to them in configure.ac is removed.
Ralf Wildenhues March 30, 2011, 5:37 a.m. UTC | #2
* Joseph S. Myers wrote on Tue, Mar 29, 2011 at 10:55:41PM CEST:
> --- configure.ac	(revision 171675)
> +++ configure.ac	(working copy)

> @@ -565,9 +562,7 @@
>      ;;
>    *-*-kaos*)
>      # Remove unsupported stuff on all kaOS configurations.
> -    skipdirs="target-libiberty ${libgcj} target-libstdc++-v3"
> -    skipdirs="$skipdirs target-libobjc"
> -    skipdirs="$skipdirs zlib fastjar target-libjava target-boehm-gc target-zlib"
> +    skipdirs="target-libiberty"

This error existed before your patch, but it might be a good idea to fix
it while at it: skipdirs should only be appended to here, not
overridden.

>      noconfigdirs="$noconfigdirs target-libgloss"
>      ;;
>    *-*-netbsd*)

Other than that, I don't see issues with the patch; but again, I'm not
really qualified to judge CPU portability issues.

Thanks,
Ralf
Richard Earnshaw March 30, 2011, 2:39 p.m. UTC | #3
On Tue, 2011-03-29 at 20:55 +0000, Joseph S. Myers wrote:
> This patch continues cleaning up the toplevel configure.ac, in particular 
> as regards cases handling GCC libraries for targets where GCC is no longer 
> (or never was) supported.
> 
> The principle there, as discussed for the original deprecated targets 
> removal patch, is that in the absence of GCC support for a target it 
> doesn't matter exactly how toplevel is configured to build GCC libraries 
> (or other GCC-related directories) for that target - builds will and 
> should fail if GCC is included in the source tree - so toplevel 
> configure.ac should be set up for maximal simplicity.  In most cases that 
> means no explicit mention of GCC libraries for such a target; in some 
> cases it means removing the target entry altogether so that another case 
> becomes active instead (possibly the *-*-* case that disables libgcj 
> only).
> 
> In general cases just disabling libgcj are redundant with the *-*-* case 
> unless they prevent some other case being active for the target, and so 
> are removed.  There were also a couple of removed cases for targets with 
> no support in GCC or src at all (romp-*-*, vax-*-vms) - if there's no 
> support in GCC or src, it's right that a build should fail trying to build 
> whatever sources you have there, and silly for toplevel to try disabling 
> everything because nothing is supported.
> 
> Other cleanups here: noconfigdirs="$noconfigdirs" is completely useless 
> and was removed; c54x*-*-* is always mapped to tic54x-*-* by config.sub so 
> that case can be simplified; cris*-*-none acts just like cris*-*-elf in 
> config.gcc so it's appropriate to make the "*" subcase of cris*-*-* act 
> like the -elf case; mmix-*-* disabled "libgloss", i.e. libgloss for the 
> host, which is never built anyway.
> 
> OK to commit?
> 
> 2011-03-29  Joseph Myers  <joseph@codesourcery.com>
> 

> 	(arm-*-coff): Don't disable libgcj.
> 	(arm*-*-linux-gnueabi): Remove useless assignment.
> 	(arm-*-riscix*): Don't disable libgcj.


RISC iX support was removed from GCC years ago.  Looks like a tiny
fragment left over that wasn't cleaned up.  The other bits are fine with
me.

R.
Joseph Myers March 30, 2011, 3:28 p.m. UTC | #4
On Wed, 30 Mar 2011, Richard Earnshaw wrote:

> > 2011-03-29  Joseph Myers  <joseph@codesourcery.com>
> > 
> 
> > 	(arm-*-coff): Don't disable libgcj.
> > 	(arm*-*-linux-gnueabi): Remove useless assignment.
> > 	(arm-*-riscix*): Don't disable libgcj.
> 
> 
> RISC iX support was removed from GCC years ago.  Looks like a tiny
> fragment left over that wasn't cleaned up.  The other bits are fine with
> me.

The RISC iX case is much like the Solaris/PowerPC one I commented on in 
<http://gcc.gnu.org/ml/gcc-patches/2011-03/msg01744.html>: it appears 
there is still assembler support.  What I'm doing here is simply cleaning 
things up by removing mentions of *GCC* directories for targets without 
GCC support (often ones where GCC support was removed long ago).

It's quite possible that some obsolete targets should have their binutils 
(and newlib) support removed, leading to further toplevel simplification 
(gdb has been more active in pruning unmaintained targets - but it's also 
the case that a proliferation of targets is more likely to cause problems 
there than in binutils and newlib).  But I think it's really for the 
binutils maintainers to work out what they think is worth removing.
Hans-Peter Nilsson March 31, 2011, 1:05 a.m. UTC | #5
On Tue, 29 Mar 2011, Joseph S. Myers wrote:
> Other cleanups here:

> cris*-*-none acts just like cris*-*-elf in
> config.gcc so it's appropriate to make the "*" subcase of cris*-*-* act
> like the -elf case;

'k.

> mmix-*-* disabled "libgloss", i.e. libgloss for the
> host, which is never built anyway.

Whoops, my bad.  Odd that it worked anyway, but I'm not certain
I added that due to actual breakage.

All bits fine by me.

brgds, H-P
diff mbox

Patch

Index: configure.ac
===================================================================
--- configure.ac	(revision 171675)
+++ configure.ac	(working copy)
@@ -521,7 +521,7 @@ 
 
 case "${target}" in
   *-*-chorusos)
-    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs target-newlib target-libgloss"
     ;;
   powerpc-*-darwin*)
     noconfigdirs="$noconfigdirs ld gas gdb gprof"
@@ -543,9 +543,6 @@ 
   *-*-dragonfly*)
     noconfigdirs="$noconfigdirs target-newlib target-libgloss"
     ;;
-  *-*-freebsd[[12]] | *-*-freebsd[[12]].* | *-*-freebsd*aout*)
-    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
-    ;;
   *-*-freebsd*)
     noconfigdirs="$noconfigdirs target-newlib target-libgloss"
     if test "x$with_gmp" = x && test "x$with_gmp_dir" = x \
@@ -565,9 +562,7 @@ 
     ;;
   *-*-kaos*)
     # Remove unsupported stuff on all kaOS configurations.
-    skipdirs="target-libiberty ${libgcj} target-libstdc++-v3"
-    skipdirs="$skipdirs target-libobjc"
-    skipdirs="$skipdirs zlib fastjar target-libjava target-boehm-gc target-zlib"
+    skipdirs="target-libiberty"
     noconfigdirs="$noconfigdirs target-libgloss"
     ;;
   *-*-netbsd*)
@@ -636,7 +631,6 @@ 
     noconfigdirs="$noconfigdirs target-libgloss"
     ;;
   arm-*-coff)
-    noconfigdirs="$noconfigdirs ${libgcj}"
     libgloss_dir=arm
     ;;
   arm-*-elf* | arm*-*-eabi* )
@@ -644,7 +638,6 @@ 
     libgloss_dir=arm
     ;;
   arm*-*-linux-gnueabi)
-    noconfigdirs="$noconfigdirs"
     case ${with_newlib} in
       no) noconfigdirs="$noconfigdirs target-newlib target-libgloss"
     esac
@@ -658,7 +651,7 @@ 
     noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
   arm-*-riscix*)
-    noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs ld target-libgloss"
     ;;
   avr-*-*)
     noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj} target-libssp"
@@ -666,15 +659,12 @@ 
   bfin-*-*)
     unsupported_languages="$unsupported_languages java"
     noconfigdirs="$noconfigdirs target-boehm-gc"
-    if test x${is_cross_compiler} != xno ; then
-      target_configdirs="${target_configdirs} target-bsp target-cygmon"
-    fi
     ;;
   c4x-*-* | tic4x-*-*)
-    noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs target-libgloss"
     ;;
-  c54x*-*-* | tic54x-*-*)
-    noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj} gcc gdb"
+  tic54x-*-*)
+    noconfigdirs="$noconfigdirs target-libgloss gdb"
     ;;
   cr16-*-*)
     noconfigdirs="$noconfigdirs ${libgcj} gdb"
@@ -682,24 +672,18 @@ 
   cris-*-* | crisv32-*-*)
     unsupported_languages="$unsupported_languages java"
     case "${target}" in
-      *-*-aout)
-	unsupported_languages="$unsupported_languages fortran"
-	noconfigdirs="$noconfigdirs target-libffi target-boehm-gc";;
-      *-*-elf) # See PR46792 regarding target-libffi.
-	noconfigdirs="$noconfigdirs target-libffi target-boehm-gc";;
       *-*-linux*)
 	noconfigdirs="$noconfigdirs target-newlib target-libgloss";;
-      *)
-	unsupported_languages="$unsupported_languages fortran"
-	noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss";;
+      *) # See PR46792 regarding target-libffi.
+	noconfigdirs="$noconfigdirs target-libffi target-boehm-gc";;
     esac
     libgloss_dir=cris
     ;;
   d10v-*-*)
-    noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs target-libgloss"
     ;;
   d30v-*-*)
-    noconfigdirs="$noconfigdirs ${libgcj} gdb"
+    noconfigdirs="$noconfigdirs gdb"
     ;;
   fr30-*-elf*)
     noconfigdirs="$noconfigdirs ${libgcj} gdb"
@@ -715,7 +699,7 @@ 
     noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
   h8500-*-*)
-    noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs target-libgloss"
     ;;
   hppa1.1-*-osf* | hppa1.1-*-bsd* )
     ;;
@@ -745,7 +729,7 @@ 
     noconfigdirs="$noconfigdirs ld ${libgcj}"
     ;;
   i960-*-*)
-    noconfigdirs="$noconfigdirs ${libgcj} gdb"
+    noconfigdirs="$noconfigdirs gdb"
     ;;
   ia64*-*-elf*)
     # No gdb support yet.
@@ -764,13 +748,6 @@ 
     libgloss_dir=i386
     ;;
   i[[3456789]]86-*-linux*)
-    # The GCC port for glibc1 has no MD_FALLBACK_FRAME_STATE_FOR, so let's
-    # not build java stuff by default.
-    case "${target}" in
-      *-*-*libc1*)
-	noconfigdirs="$noconfigdirs ${libgcj}";;
-    esac
-
     # This section makes it possible to build newlib natively on linux.
     # If we are using a cross compiler then don't configure newlib.
     if test x${is_cross_compiler} != xno ; then
@@ -810,19 +787,19 @@ 
   i[[3456789]]86-*-sco3.2v5*)
     # The linker does not yet know about weak symbols in COFF,
     # and is not configured to handle mixed ELF and COFF.
-    noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs ld target-libgloss"
     ;;
   i[[3456789]]86-*-sco*)
-    noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs gprof target-libgloss"
     ;;
   i[[3456789]]86-*-solaris2*)
     noconfigdirs="$noconfigdirs target-libgloss"
     ;;
   i[[3456789]]86-*-sysv4*)
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs target-libgloss"
     ;;
   i[[3456789]]86-*-beos*)
-    noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
     ;;
   i[[3456789]]86-*-rdos*)
     noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
@@ -837,22 +814,13 @@ 
   m68k-*-elf*)
     noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  m68k-*-coff*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    ;;
   m68*-*-* | fido-*-*)
     libgloss_dir=m68k
     ;;
   mmix-*-*)
-    noconfigdirs="$noconfigdirs target-libffi target-boehm-gc gdb libgloss"
+    noconfigdirs="$noconfigdirs target-libffi target-boehm-gc gdb"
     unsupported_languages="$unsupported_languages fortran java"
     ;;
-  mn10200-*-*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    ;;
-  mn10300-*-*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    ;;
   mt-*-*)
     noconfigdirs="$noconfigdirs sim"
     ;;
@@ -865,17 +833,17 @@ 
     ;;
   powerpc*-*-winnt* | powerpc*-*-pe*)
     target_configdirs="$target_configdirs target-winsup"
-    noconfigdirs="$noconfigdirs gdb tcl tk target-libgloss itcl ${libgcj}"
+    noconfigdirs="$noconfigdirs gdb tcl tk target-libgloss itcl"
     # always build newlib.
     skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
     ;;
     # This is temporary until we can link against shared libraries
   powerpcle-*-solaris*)
-    noconfigdirs="$noconfigdirs gdb sim tcl tk itcl ${libgcj}"
+    noconfigdirs="$noconfigdirs gdb sim tcl tk itcl"
     libgloss_dir=rs6000
     ;;
   powerpc-*-beos*)
-    noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
     ;;
   powerpc-*-eabi)
     noconfigdirs="$noconfigdirs ${libgcj}"
@@ -894,7 +862,7 @@ 
     noconfigdirs="$noconfigdirs gprof ${libgcj}"
     ;;
   m68k-apollo-*)
-    noconfigdirs="$noconfigdirs ld binutils gprof target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs ld binutils gprof target-libgloss"
     ;;
   microblaze*)
     noconfigdirs="$noconfigdirs gprof target-libssp ${libgcj}"
@@ -908,7 +876,7 @@ 
     libgloss_dir=mips
     ;;
   mips*-*-irix5*)
-    noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs gprof target-libgloss"
     ;;
   mips*-*-irix6*)
     # Linking libjava exceeds command-line length limits on at least
@@ -918,7 +886,7 @@ 
     noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
     ;;
   mips*-*-bsd*)
-    noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs gprof target-libgloss"
     ;;
   mips*-*-linux*)
     noconfigdirs="$noconfigdirs target-newlib target-libgloss"
@@ -927,9 +895,6 @@ 
     noconfigdirs="$noconfigdirs gprof ${libgcj}"
     libgloss_dir=mips
     ;;
-  romp-*-*)
-    noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes target-libgloss ${libgcj}"
-    ;;
   sh-*-* | sh64-*-*)
     case "${target}" in
       sh*-*-elf)
@@ -949,42 +914,28 @@ 
     libgloss_dir=sparc
     ;;
   sparclite-*-*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
     libgloss_dir=sparc
     ;;
   sparc-*-sunos4*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
     if test x${is_cross_compiler} != xno ; then
            noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
     else
            use_gnu_ld=no
     fi
     ;;
-  sparc-*-solaris2.[[0-6]] | sparc-*-solaris2.[[0-6]].*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    ;;
   sparc-*-solaris* | sparc64-*-solaris* | sparcv9-*-solaris*)
     ;;
   tic6x-*-*)
     noconfigdirs="$noconfigdirs gdb sim ${libgcj}"
     ;;
   v810-*-*)
-    noconfigdirs="$noconfigdirs bfd binutils gas gcc gdb ld target-libstdc++-v3 opcodes target-libgloss ${libgcj}"
+    noconfigdirs="$noconfigdirs bfd binutils gas gdb ld opcodes target-libgloss"
     ;;
-  v850*-*-*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    ;;
-  vax-*-vms)
-    noconfigdirs="$noconfigdirs bfd binutils gdb ld target-newlib opcodes target-libgloss ${libgcj}"
-    ;;
   vax-*-*)
     noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
     ;;
-  xtensa*-*-*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    ;;
   ip2k-*-*)
-    noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
+    noconfigdirs="$noconfigdirs target-libiberty"
     ;;
   *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
     noconfigdirs="$noconfigdirs target-newlib target-libgloss"