This is the mail archive of the gcc-patches@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]
Other format: [Raw text]

Re: libada cross-compilation


Richard Earnshaw wrote:
On Fri, 2005-02-25 at 09:47, Nick Burrett wrote:

I found the following patch was required to allow for the successful building of the gnattools for a cross-compiler. Without this patch, we would be using a mix of the built cross-compiler and the host's gnattool -set.

Built on i686-pc-linux-gnu and cross-compiled to arm-unknown-elf.

If this is OK, can somebody commit it as I don't have write-access.


<date> Nick Burrett <nick@sqrt.co.uk>


* Makefile.in (gnattools-cross): Use native CC.

______________________________________________________________________
--- /home/nick/riscos-aof/masters/gcc-4.0/libada/Makefile.in	2004-05-30 09:51:07.000000000 +0100
+++ libada/Makefile.in	2005-02-25 09:42:01.142391312 +0000
@@ -164,6 +164,7 @@
gnattools-cross: gnatlib
	$(MAKE)  -C $(GCC_DIR)/ada $(FLAGS_TO_PASS) $(ADA_FLAGS_TO_PASS) \
	  ADA_INCLUDES="-I$(RTS_DIR)../adainclude -I$(RTS_DIR)" \
+	  CC="gcc" \
	  GNATMAKE="gnatmake" \
	  GNATBIND="gnatbind" \
	  GNATLINK="gnatlink" \


This can't be right.  It's never correct to hard-bind CC to a specific
compiler name (with the exception of the compiler we've just built).

Perhaps you mean $(CC_FOR_BUILD)?

I agree with what you're saying, but we already hard-bind GNATMAKE, GNATBIND and GNATLINK. We have to pick up the CC that is in the same path as GNATBIND otherwise we get build-inconsistencies.


If we were to use CC_FOR_BUILD, then there should be a GNATBIND_FOR_BUILD, GNATMAKE_FOR_BUILD and GNATLINK_FOR_BUILD.

I don't like it.

Nick.


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