From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carlo Wood To: richard.earnshaw@arm.com Cc: egcs@cygnus.com (egcs@cygnus.com) Subject: Re: building a cross libf2c Date: Sat, 27 Jun 1998 10:50:00 -0000 Message-id: <199806270106.DAA23719@jolan.ppro> References: <199806261302.OAA27990@sun52.NIS.cambridge> X-SW-Source: 1998-06/msg01000.html Hey that would be great. Renaming `libraries' to the target name is exactly what is needed to solve the "lookfor_dir_with_trigger" problem with dejagnu. It would be a logical change too imho. If this patch is adopted, then isn't it possible to use the target name anyway, also in a native build ? | The following patch (or something like it) is needed to allow | cross-building of libf2c to succeed, since the "libraries" subdir doesn't | exist for a cross build. | | Richard Earnshaw (rearnsha@arm.com) | | * Makefile.in (BASE_FLAGS_TO_PASS): Pass TARGET_SUBDIR to submakes. | | * libf2c/Makefile.in (TARGET_SUBDIR): Provide default definition. | (FLAGS_TO_PASS): Use TARGET_SUBDIR in definition of G2C_H_DIR. | | | | --==_Exmh_16473424540 | Content-Type: application/x-patch ; name="f2cmake.patch" | Content-Description: f2cmake.patch | Content-Disposition: attachment; filename="f2cmake.patch" | | Index: Makefile.in | =================================================================== | RCS file: /egcs/carton/cvsfiles/egcs/Makefile.in,v | retrieving revision 1.25 | diff -p -r1.25 Makefile.in | *** Makefile.in 1998/06/19 05:42:13 1.25 | --- Makefile.in 1998/06/26 12:49:38 | *************** BASE_FLAGS_TO_PASS = \ | *** 352,357 **** | --- 352,358 ---- | "EXPECT=$(EXPECT)" \ | "RUNTEST=$(RUNTEST)" \ | "RUNTESTFLAGS=$(RUNTESTFLAGS)" \ | + "TARGET_SUBDIR=$(TARGET_SUBDIR)" \ | "WINDRES_FOR_TARGET=$(WINDRES_FOR_TARGET)" \ | "YACC=$(YACC)" \ | "exec_prefix=$(exec_prefix)" \ | Index: libf2c/Makefile.in | =================================================================== | RCS file: /egcs/carton/cvsfiles/egcs/libf2c/Makefile.in,v | retrieving revision 1.9 | diff -p -r1.9 Makefile.in | *** Makefile.in 1998/06/24 06:16:17 1.9 | --- Makefile.in 1998/06/26 12:49:38 | *************** CC = gcc | *** 58,63 **** | --- 58,66 ---- | CFLAGS = -g | LIBCFLAGS = $(CFLAGS) | | + # This is correct for a native build, but will be overridden for a cross build | + TARGET_SUBDIR = libraries | + | # List of variables to pass to sub-makes. This should not be needed' | # by GNU make or Sun make (both of which pass command-line variable' | # overrides thouh $(MAKE)) but may be needed by older versions.' | *************** FLAGS_TO_PASS= \ | *** 66,72 **** | "CC=$(CC)" \ | "CFLAGS=$(CFLAGS)" \ | "F2C_H_DIR=$(s)/libf2c" \ | ! "G2C_H_DIR=$(r)/libraries/libf2c" \ | "GCC_H_DIR=$(s)/include" \ | "LIBCFLAGS=$(LIBCFLAGS)" \ | "PICFLAG=$(PICFLAG)" \ | --- 69,75 ---- | "CC=$(CC)" \ | "CFLAGS=$(CFLAGS)" \ | "F2C_H_DIR=$(s)/libf2c" \ | ! "G2C_H_DIR=$(r)/$(TARGET_SUBDIR)/libf2c" \ | "GCC_H_DIR=$(s)/include" \ | "LIBCFLAGS=$(LIBCFLAGS)" \ | "PICFLAG=$(PICFLAG)" \ -- Carlo Wood