This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Patch for libgfortran cross-build
- From: Steve Ellcey <sje at cup dot hp dot com>
- To: fortran at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org
- Date: Mon, 6 Dec 2004 11:29:32 -0800 (PST)
- Subject: Patch for libgfortran cross-build
- Reply-to: sje at cup dot hp dot com
I don't know if anyone else has tried to cross-build a Fortran compiler
but when I tried it, the build of libgfortran failed. This patch fixes
it by copying the setting of AM_MAKEFLAGS that the libstdc++-v3 and
libffi Makefiles have and putting into the libgfortran Makefile.am.
Tested on a HP-UX HPPA to IA64 cross-build. OK for checkin?
Steve Ellcey
sje@cup.hp.com
2004-12-06 Steve Ellcey <sje@cup.hp.com>
* libgfortran/Makefile.am (AM_MAKEFLAGS): New.
* libgfortran/Makefile.in: Regenerate
*** gcc.orig/libgfortran/Makefile.am Mon Dec 6 11:20:12 2004
--- gcc/libgfortran/Makefile.am Mon Dec 6 11:16:35 2004
*************** endif
*** 513,515 ****
--- 513,561 ----
EXTRA_DIST = $(m4_files)
+ ## ################################################################
+
+ ##
+ ## This section is for make and multilib madness. (copied from libffi)
+ ##
+
+ # Work around what appears to be a GNU make bug handling MAKEFLAGS
+ # values defined in terms of make variables, as is the case for CC and
+ # friends when we are called from the top level Makefile.
+ AM_MAKEFLAGS = \
+ "AR_FLAGS=$(AR_FLAGS)" \
+ "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
+ "CFLAGS=$(CFLAGS)" \
+ "CXXFLAGS=$(CXXFLAGS)" \
+ "CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
+ "CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
+ "INSTALL=$(INSTALL)" \
+ "INSTALL_DATA=$(INSTALL_DATA)" \
+ "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
+ "INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \
+ "LDFLAGS=$(LDFLAGS)" \
+ "LIBCFLAGS=$(LIBCFLAGS)" \
+ "LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \
+ "MAKE=$(MAKE)" \
+ "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \
+ "PICFLAG=$(PICFLAG)" \
+ "PICFLAG_FOR_TARGET=$(PICFLAG_FOR_TARGET)" \
+ "RUNTESTFLAGS=$(RUNTESTFLAGS)" \
+ "SHELL=$(SHELL)" \
+ "exec_prefix=$(exec_prefix)" \
+ "infodir=$(infodir)" \
+ "libdir=$(libdir)" \
+ "prefix=$(prefix)" \
+ "AR=$(AR)" \
+ "AS=$(AS)" \
+ "CC=$(CC)" \
+ "CXX=$(CXX)" \
+ "LD=$(LD)" \
+ "LIBCFLAGS=$(LIBCFLAGS)" \
+ "NM=$(NM)" \
+ "NM_FOR_BUILD=$(NM_FOR_BUILD)" \
+ "NM_FOR_TARGET=$(NM_FOR_TARGET)" \
+ "PICFLAG=$(PICFLAG)" \
+ "RANLIB=$(RANLIB)" \
+ "DESTDIR=$(DESTDIR)"
+