aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFranz Sirl <Franz.Sirl-kernel@lauterbach.com>2001-04-13 10:14:47 +0000
committerFranz Sirl <sirl@gcc.gnu.org>2001-04-13 10:14:47 +0000
commit78faa32d14d4979ccdac3f398396b1fdded71401 (patch)
treee68b5195c272e71ac8a74fa3790dd2ef1896ad66
parent948421e0c986f6ff4040a792f69ad3018aeac4fb (diff)
downloadgcc-78faa32d14d4979ccdac3f398396b1fdded71401.zip
gcc-78faa32d14d4979ccdac3f398396b1fdded71401.tar.gz
gcc-78faa32d14d4979ccdac3f398396b1fdded71401.tar.bz2
Makefile.in (STAGE1_CFLAGS): Pass down.
2000-04-13 Franz Sirl <Franz.Sirl-kernel@lauterbach.com> * Makefile.in (STAGE1_CFLAGS): Pass down. gcc/ * Makefile.in (CFLAGS, BOOT_CFLAGS): Partly revert 2000-10-27 patch. (stage1_build): Instead pass down STAGE1_CFLAGS here. Pass down. MAKEINFO and MAKEINFOFLAGS too. (stage4_build): Correctly order -B flags. From-SVN: r41335
-rw-r--r--ChangeLog4
-rw-r--r--Makefile.in1
-rw-r--r--gcc/Makefile.in25
3 files changed, 21 insertions, 9 deletions
diff --git a/ChangeLog b/ChangeLog
index cd35f1d..b94ded2 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2001-04-13 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
+
+ * Makefile.in (STAGE1_CFLAGS): Pass down.
+
2001-04-13 Alan Modra <amodra@one.net.au>
* config.guess: Add hppa64-linux support. Note for next import that
diff --git a/Makefile.in b/Makefile.in
index dcdb6cd..959d730 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -475,6 +475,7 @@ EXTRA_GCC_FLAGS = \
"`echo 'LIBGCC2_DEBUG_CFLAGS=$(LIBGCC2_DEBUG_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'LIBGCC2_INCLUDES=$(LIBGCC2_INCLUDES)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'ENQUIRE=$(ENQUIRE)' | sed -e s/.*=$$/XFOO=/`" \
+ "`echo 'STAGE1_CFLAGS=$(STAGE1_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'BOOT_CFLAGS=$(BOOT_CFLAGS)' | sed -e s/.*=$$/XFOO=/`"
GCC_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_GCC_FLAGS)
diff --git a/gcc/Makefile.in b/gcc/Makefile.in
index 6e640c7..93c77bc 100644
--- a/gcc/Makefile.in
+++ b/gcc/Makefile.in
@@ -59,17 +59,20 @@ INTL_TARGETS = intl.all intl.install
BOOT_LANGUAGES = c @all_boot_languages@
# Various ways of specifying flags for compilations:
-# CFLAGS is for the user to override to, e.g., do a bootstrap with -O2.
-# BOOT_CFLAGS is the value of CFLAGS to pass to the stage2 and stage3
-# compilations.
+# CFLAGS is for the user to override to, e.g., do a cross build with -O2.
+# For recursive bootstrap builds CFLAGS is used to pass in STAGE1_CFLAGS
+# or BOOT_CFLAGS
+# STAGE1_CFLAGS is set by configure on some targets or passed from toplevel
+# and sets the CFLAGS passed to stage1 of a bootstrap compilation.
+# BOOT_CFLAGS is the value of CFLAGS to pass to the stage2, stage3 and stage4
+# bootstrap compilations.
# XCFLAGS is used for most compilations but not when using the GCC just built.
# TCFLAGS is used for compilations with the GCC just built.
-# STAGE1_CFLAGS is set by configure on some targets.
XCFLAGS =
TCFLAGS =
-BOOT_CFLAGS = -g -O2
+CFLAGS = -g
STAGE1_CFLAGS = -g @stage1_cflags@
-CFLAGS = $(STAGE1_CFLAGS)
+BOOT_CFLAGS = -g -O2
# The warning flags are separate from BOOT_CFLAGS because people tend to
# override optimization flags and we'd like them to still have warnings
@@ -2942,9 +2945,13 @@ STAGE2_FLAGS_TO_PASS = \
# Only build the C compiler for stage1, because that is the only one that
# we can guarantee will build with the native compiler, and also it is the
-# only thing useful for building stage2.
+# only thing useful for building stage2. STAGE1_CFLAGS (via CFLAGS),
+# MAKEINFO and MAKEINFOFLAGS are explicitly passed here to make them
+# overrideable (for a bootstrap build stage1 also builds gcc.info).
stage1_build:
- $(MAKE) CC="$(CC)" libdir=$(libdir) LANGUAGES="$(BOOT_LANGUAGES)"
+ $(MAKE) CC="$(CC)" libdir=$(libdir) LANGUAGES="$(BOOT_LANGUAGES)" \
+ CFLAGS="$(STAGE1_CFLAGS)" MAKEINFO="$(MAKEINFO)" \
+ MAKEINFOFLAGS="$(MAKEINFOFLAGS)"
touch stage1_build
echo stage1_build > stage_last
@@ -2979,7 +2986,7 @@ stage3_copy: stage3_build
echo stage4_build > stage_last
stage4_build: stage3_copy
- $(MAKE) CC="stage3/xgcc$(exeext) -B$(build_tooldir)/bin/ -Bstage3/" \
+ $(MAKE) CC="stage3/xgcc$(exeext) -Bstage3/ -B$(build_tooldir)/bin/" \
STAGE_PREFIX=stage3/ \
$(STAGE2_FLAGS_TO_PASS)
touch stage4_build