OSDN Git Service

* Makefile.in (TARGET_TOOLPREFIX): No longer define.
authorlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 18 May 1998 01:24:26 +0000 (01:24 +0000)
committerlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 18 May 1998 01:24:26 +0000 (01:24 +0000)
        (AR_FOR_TARGET, RANLIB_FOR_TARGET): Define to use versions in
        the build tree if they exist.
        (AR, AR_FLAGS, OLDAR, OLDAR_FLAGS, RANLIB, RANLIB_TEST): Update
        appropriately.
        (objdir): Let configure substitute value.
        (FLOAT_H): Let configure select a pre-built version from the
        config subdir.
        * build-make (INSTALL_TARGET, ALL): Disable, no longer needed.
        * configure.in: Substitute for objdir.
* cp/Makefile.in (program_transform_name, objdir): Define.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@19828 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/Makefile.in
gcc/build-make
gcc/configure
gcc/configure.in
gcc/cp/ChangeLog
gcc/cp/Makefile.in

index 94d3c2c..c4dca03 100644 (file)
@@ -1,5 +1,16 @@
 Mon May 18 01:23:33 1998  Jeffrey A Law  (law@cygnus.com)
 
+       * Makefile.in (TARGET_TOOLPREFIX): No longer define.
+       (AR_FOR_TARGET, RANLIB_FOR_TARGET): Define to use versions in
+       the build tree if they exist.
+       (AR, AR_FLAGS, OLDAR, OLDAR_FLAGS, RANLIB, RANLIB_TEST): Update
+       appropriately.
+       (objdir): Let configure substitute value.
+       (FLOAT_H): Let configure select a pre-built version from the
+       config subdir.
+       * build-make (INSTALL_TARGET, ALL): Disable, no longer needed.
+       * configure.in: Substitute for objdir.
+
        * Makefile.in (build_canonical, host_canonical): Let configure
        substitute values for these variables.
        * configure.in: Substitute for build_canonical, host_canonical
index 029ed14..fc58066 100644 (file)
@@ -177,12 +177,49 @@ host_canonical = @host_canonical@
 # These are used because `configure' appends `cross-make'
 # to the makefile when making a cross-compiler.
 
-TARGET_TOOLPREFIX = $(tooldir)/bin/
-AR_FOR_TARGET = $(TARGET_TOOLPREFIX)ar
+# Use the tools from the build tree, if they are available.
+
+# objdir is set by configure.
+objdir = @objdir@
+
+AR_FOR_TARGET = ` \
+  if [ -f $(objdir)/../binutils/ar ] ; then \
+    echo $(objdir)/../binutils/ar ; \
+  else \
+    if [ "$(host_canonical)" = "$(target)" ] ; then \
+      echo ar; \
+    else \
+       t='$(program_transform_name)'; echo ar | sed -e $$t ; \
+    fi; \
+  fi`
 AR_FOR_TARGET_FLAGS = rc
-RANLIB_FOR_TARGET = $(TARGET_TOOLPREFIX)ranlib
-RANLIB_TEST_FOR_TARGET = [ -f $(TARGET_TOOLPREFIX)ranlib ]
-
+RANLIB_FOR_TARGET = ` \
+  if [ -f $(objdir)/../binutils/ranlib ] ; then \
+    echo $(objdir)/../binutils/ranlib ; \
+  else \
+    if [ "$(host_canonical)" = "$(target)" ] ; then \
+      echo ranlib; \
+    else \
+       t='$(program_transform_name)'; echo ranlib | sed -e $$t ; \
+    fi; \
+  fi`
+RANLIB_TEST_FOR_TARGET = \
+  [ -f $(RANLIB_FOR_TARGET) ] \
+  || ( [ "$(host_canonical)" = "$(target)" ] \
+       && [ -f /usr/bin/ranlib -o -f /bin/ranlib ] )
+
+# We always act like a cross-compiler, even when we're
+# compiling native.  This is because we want to use our own tools if
+# we can.  We don't just set RANLIB to a complicated expression,
+# because the top level Makefile.in might override RANLIB_FOR_TARGET.
+# These are from the FSF file "cross-make".
+AR = $(AR_FOR_TARGET)
+AR_FLAGS = $(AR_FOR_TARGET_FLAGS)
+OLDAR = $(AR_FOR_TARGET)
+OLDAR_FLAGS = $(AR_FOR_TARGET_FLAGS)
+RANLIB = $(RANLIB_FOR_TARGET)
+RANLIB_TEST = $(RANLIB_TEST_FOR_TARGET)
+  
 # Dir to search for system headers.  Overridden by cross-make.
 SYSTEM_HEADER_DIR = /usr/include
 
@@ -440,6 +477,9 @@ INSTALL_TARGET=install-normal
 
 # Source for float.h.  Overridden by cross-make.
 FLOAT_H=float.h-nat
+# We do not try to build float.h anymore.  Let configure select the
+# appropriate pre-built float.h file for the target.
+FLOAT_H=$(srcdir)/config/float-@float_format@.h
 
 # Setup the testing framework, if you have one
 EXPECT = `if [ -f $${rootme}/../expect/expect ] ; then \
index 116d579..f9049ae 100644 (file)
@@ -28,8 +28,8 @@ FIXINCLUDES=Makefile.in
 STMP_FIXPROTO =
 
 # Cause installation using install-build. We do nothing here.
-INSTALL_TARGET = install-build
+#INSTALL_TARGET = install-build
 
 # Don't try to compile the things we can't compile or we have made
 # while making gcc with the cross-compiler.
-ALL = all.build
+#ALL = all.build
index c88ad6e..0fad951 100755 (executable)
@@ -5254,6 +5254,10 @@ if [ x$enable_haifa != x ]; then
     done
 fi
 
+# Nothing to do for FLOAT_H, float_format already handled.
+objdir=`pwd`
+
+
 # Process the language and host/target makefile fragments.
 ${CONFIG_SHELL-/bin/sh} $srcdir/configure.frag $srcdir "$subdirs" "$dep_host_xmake_file" "$dep_tmake_file"
 
@@ -5515,6 +5519,7 @@ s%@target_subdir@%$target_subdir%g
 s%@inhibit_libc@%$inhibit_libc%g
 s%@sched_prefix@%$sched_prefix%g
 s%@sched_cflags@%$sched_cflags%g
+s%@objdir@%$objdir%g
 s%@subdirs@%$subdirs%g
 s%@all_languages@%$all_languages%g
 s%@all_boot_languages@%$all_boot_languages%g
index 0ee19c4..41917f4 100644 (file)
@@ -3410,6 +3410,10 @@ if [[ x$enable_haifa != x ]]; then
     done
 fi
 
+# Nothing to do for FLOAT_H, float_format already handled.
+objdir=`pwd`
+AC_SUBST(objdir)
+
 # Process the language and host/target makefile fragments.
 ${CONFIG_SHELL-/bin/sh} $srcdir/configure.frag $srcdir "$subdirs" "$dep_host_xmake_file" "$dep_tmake_file"
 
index 7c7c44f..17701ec 100644 (file)
@@ -1,5 +1,7 @@
 Mon May 18 01:24:08 1998  Jeffrey A Law  (law@cygnus.com)
 
+       * Makefile.in (program_transform_name, objdir): Define.
+
        * Makefile.in (BISON): Use bison from the build tree if it exists.
        (FLEX): Similarly.
 
index 6ce5227..0a53c69 100644 (file)
@@ -83,6 +83,12 @@ GCC_CFLAGS=$(INTERNAL_CFLAGS) $(X_CFLAGS) $(T_CFLAGS) $(CFLAGS)
 # These are used because `configure' appends `cross-make'
 # to the makefile when making a cross-compiler.
 
+# We don't use cross-make.  Instead we use the tools
+# from the build tree, if they are available.
+# program_transform_name and objdir are set by configure.in.
+program_transform_name =
+objdir = .
+
 target=@target@
 xmake_file=@dep_host_xmake_file@
 tmake_file=@dep_tmake_file@