This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: 970922 problems building cross-compiler


>>>>> "Jeffrey" == Jeffrey A Law <law@hurl.cygnus.com> writes:

 Jeffrey> In message <9709261741.AA06506@kona.>you write:
 >> I tried building on sparc-solaris for mips64-elf.  Did a configure
 >> then a "make cross".  Result is the failure below.  I thought it
 >> might be pilot error so I nuked the build directory and restarted
 >> from scratch... same result.
 Jeffrey> Building the Fortran & Objc runtime for cross targets
 Jeffrey> doesn't work well (if at all).

 Jeffrey> This is a problem we want to begin to address after the
 Jeffrey> first release; the major change will be to move the Fortran
 Jeffrey> and Objc runtime into their own toplevel directory and have
 Jeffrey> them built after the compiler.

 Jeffrey> Until then, your best bet is to avoid building Fortran and
 Jeffrey> Objc by using the toplevel "make cross" target or via
 Jeffrey> LANGUAGES="c c++"

 Jeffrey> jeff

Unfortunately, LANGUAGES="c c++" didn't help.

I believe I've tracked down the problem, a missing check for languages
selection in gcc/f/Make-lang.in .  Below is a patch.  This is my first
attempt at creating one, so if I did it wrong, please straighten me
out... :-)

(By the way, it would help novices such as me if someone could put a
paragraph or two in some "README-creating-patches" file.  Trying to
guess the right "diff" switches was a bit tricky.)

--- Make-lang.in.orig	Thu Sep 18 18:06:05 1997
+++ Make-lang.in	Mon Sep 29 12:23:05 1997
@@ -278,22 +278,26 @@
   $(GCC_PARTS)
 # The make "stage?" in compiler spec. is fully qualified as above
 	rm -f stmp-f2c.h
-	top=`pwd`; \
+	case "$(LANGUAGES)" in \
+	*f77*) top=`pwd`; \
 	src=`cd $(srcdir); pwd`; \
 	  cd f/runtime; \
 	  CC="`case '$(GCC_FOR_TARGET)' in \
 	     './xgcc -B./') echo $${top}/xgcc -B$${top}/;; \
 	     *) echo '$(GCC_FOR_TARGET)';; esac`" \
 	  $(F77_FLAGS_TO_PASS) CONFIG_SITE=/dev/null $(SHELL) \
-	  $${src}/f/runtime/configure --srcdir=$${src}/f/runtime
-	top=`pwd`; \
+	  $${src}/f/runtime/configure --srcdir=$${src}/f/runtime ;; \
+	esac
+	case "$(LANGUAGES)" in \
+	*f77*) top=`pwd`; \
 	src=`cd $(srcdir); pwd`; \
 	  cd f/runtime/libU77; \
 	  CC="`case '$(GCC_FOR_TARGET)' in \
 	     './xgcc -B./') echo $${top}/xgcc -B$${top}/;; \
 	     *) echo '$(GCC_FOR_TARGET)';; esac`" \
 	  $(F77_FLAGS_TO_PASS) CONFIG_SITE=/dev/null $(SHELL) \
-	  $${src}/f/runtime/libU77/configure --srcdir=$${src}/f/runtime/libU77
+	  $${src}/f/runtime/libU77/configure --srcdir=$${src}/f/runtime/libU77 ;; \
+	esac
 	touch stmp-f2c.h
 
 # Support parallel build.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]