mirror of git://gcc.gnu.org/git/gcc.git
re PR bootstrap/29544 (Not building with checking in stage1)
2006-12-19 Paolo Bonzini <bonzini@gnu.org> PR bootstrap/29544 * Makefile.def (flags_to_pass): Add STAGE1_CHECKING. (bootstrap_stage): Add STAGE1_CHECKING to stage1 configure flags, move here comment from Makefile.tpl. * Makefile.tpl: Move some definitions higher in the file. (STAGE1_CHECKING): New. * configure.in: Add --enable-stage1-checking. * configure: Regenerate. * Makefile.in: Regenerate. gcc: 2006-12-19 Paolo Bonzini <bonzini@gnu.org> * gcc/Makefile.in (STAGE1_CHECKING): Rename to... (STAGE1_CHECKING_CFLAGS): ... this. From-SVN: r120048
This commit is contained in:
parent
ed88a7ed92
commit
8efea77549
12
ChangeLog
12
ChangeLog
|
@ -1,3 +1,15 @@
|
|||
2006-12-19 Paolo Bonzini <bonzini@gnu.org>
|
||||
|
||||
PR bootstrap/29544
|
||||
* Makefile.def (flags_to_pass): Add STAGE1_CHECKING.
|
||||
(bootstrap_stage): Add STAGE1_CHECKING to stage1 configure flags,
|
||||
move here comment from Makefile.tpl.
|
||||
* Makefile.tpl: Move some definitions higher in the file.
|
||||
(STAGE1_CHECKING): New.
|
||||
* configure.in: Add --enable-stage1-checking.
|
||||
* configure: Regenerate.
|
||||
* Makefile.in: Regenerate.
|
||||
|
||||
2006-12-19 Paolo Bonzini <bonzini@gnu.org>
|
||||
|
||||
* MAINTAINERS: Add myself as build system maintainer.
|
||||
|
|
10
Makefile.def
10
Makefile.def
|
@ -226,6 +226,7 @@ flags_to_pass = { flag= LDFLAGS ; };
|
|||
flags_to_pass = { flag= LIBCFLAGS ; };
|
||||
flags_to_pass = { flag= LIBCXXFLAGS ; };
|
||||
flags_to_pass = { flag= STAGE1_CFLAGS ; };
|
||||
flags_to_pass = { flag= STAGE1_CHECKING ; };
|
||||
flags_to_pass = { flag= STAGE1_LANGUAGES ; };
|
||||
|
||||
// Target tools
|
||||
|
@ -487,7 +488,14 @@ dependencies = { module=all-target-winsup; on=all-target-libtermcap; };
|
|||
// Toplevel bootstrap
|
||||
bootstrap_stage = {
|
||||
id=1 ;
|
||||
stage_configure_flags='--disable-intermodule \
|
||||
|
||||
// * We force-disable intermodule optimizations, even if
|
||||
// --enable-intermodule was passed, since the installed compiler
|
||||
// probably can't handle them. Luckily, autoconf always respects
|
||||
// the last argument when conflicting --enable arguments are passed.
|
||||
// * Likewise, we force-disable coverage flags, since the installed
|
||||
// compiler probably has never heard of them.
|
||||
stage_configure_flags='--disable-intermodule $(STAGE1_CHECKING) \
|
||||
--disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"' ;
|
||||
stage_make_flags='CFLAGS="$(STAGE1_CFLAGS)" LIBCFLAGS="$(STAGE1_CFLAGS)"' ; };
|
||||
bootstrap_stage = {
|
||||
|
|
70
Makefile.in
70
Makefile.in
|
@ -297,6 +297,16 @@ CXXFLAGS = @CXXFLAGS@
|
|||
LIBCXXFLAGS = $(CXXFLAGS) -fno-implicit-templates
|
||||
PICFLAG =
|
||||
|
||||
# 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. 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_CFLAGS=@stage1_cflags@
|
||||
STAGE1_CHECKING=@stage1_checking@
|
||||
STAGE1_LANGUAGES=@stage1_languages@
|
||||
|
||||
# -----------------------------------------------
|
||||
# Programs producing files for the TARGET machine
|
||||
# -----------------------------------------------
|
||||
|
@ -454,6 +464,7 @@ BASE_FLAGS_TO_PASS = \
|
|||
"LIBCFLAGS=$(LIBCFLAGS)" \
|
||||
"LIBCXXFLAGS=$(LIBCXXFLAGS)" \
|
||||
"STAGE1_CFLAGS=$(STAGE1_CFLAGS)" \
|
||||
"STAGE1_CHECKING=$(STAGE1_CHECKING)" \
|
||||
"STAGE1_LANGUAGES=$(STAGE1_LANGUAGES)" \
|
||||
"AR_FOR_TARGET=$(AR_FOR_TARGET)" \
|
||||
"AS_FOR_TARGET=$(AS_FOR_TARGET)" \
|
||||
|
@ -513,6 +524,16 @@ X11_FLAGS_TO_PASS = \
|
|||
'X11_EXTRA_CFLAGS=$(X11_EXTRA_CFLAGS)' \
|
||||
'X11_EXTRA_LIBS=$(X11_EXTRA_LIBS)'
|
||||
|
||||
# Flags to pass to stage2 and later makes.
|
||||
|
||||
POSTSTAGE1_FLAGS_TO_PASS = \
|
||||
CC="$${CC}" CC_FOR_BUILD="$${CC_FOR_BUILD}" \
|
||||
STAGE_PREFIX="$$r/$(HOST_SUBDIR)/prev-gcc/" \
|
||||
CFLAGS="$(BOOT_CFLAGS)" \
|
||||
LIBCFLAGS="$(BOOT_CFLAGS)" \
|
||||
LDFLAGS="$(BOOT_LDFLAGS)" \
|
||||
"`echo 'ADAFLAGS=$(BOOT_ADAFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`"
|
||||
|
||||
# Flags to pass down to makes which are built with the target environment.
|
||||
# The double $ decreases the length of the command line; those variables
|
||||
# are set in BASE_FLAGS_TO_PASS, and the sub-make will expand them. The
|
||||
|
@ -4473,7 +4494,7 @@ configure-stage1-bfd:
|
|||
$(SHELL) $${libsrcdir}/configure \
|
||||
$(HOST_CONFIGARGS) $${srcdiroption} \
|
||||
\
|
||||
--disable-intermodule --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
--disable-intermodule $(STAGE1_CHECKING) --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
@endif bfd-bootstrap
|
||||
|
||||
.PHONY: configure-stage2-bfd maybe-configure-stage2-bfd
|
||||
|
@ -5228,7 +5249,7 @@ configure-stage1-opcodes:
|
|||
$(SHELL) $${libsrcdir}/configure \
|
||||
$(HOST_CONFIGARGS) $${srcdiroption} \
|
||||
\
|
||||
--disable-intermodule --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
--disable-intermodule $(STAGE1_CHECKING) --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
@endif opcodes-bootstrap
|
||||
|
||||
.PHONY: configure-stage2-opcodes maybe-configure-stage2-opcodes
|
||||
|
@ -5983,7 +6004,7 @@ configure-stage1-binutils:
|
|||
$(SHELL) $${libsrcdir}/configure \
|
||||
$(HOST_CONFIGARGS) $${srcdiroption} \
|
||||
\
|
||||
--disable-intermodule --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
--disable-intermodule $(STAGE1_CHECKING) --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
@endif binutils-bootstrap
|
||||
|
||||
.PHONY: configure-stage2-binutils maybe-configure-stage2-binutils
|
||||
|
@ -11795,7 +11816,7 @@ configure-stage1-gas:
|
|||
$(SHELL) $${libsrcdir}/configure \
|
||||
$(HOST_CONFIGARGS) $${srcdiroption} \
|
||||
\
|
||||
--disable-intermodule --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
--disable-intermodule $(STAGE1_CHECKING) --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
@endif gas-bootstrap
|
||||
|
||||
.PHONY: configure-stage2-gas maybe-configure-stage2-gas
|
||||
|
@ -12550,7 +12571,7 @@ configure-stage1-gcc:
|
|||
$(SHELL) $${libsrcdir}/configure \
|
||||
$(HOST_CONFIGARGS) $${srcdiroption} \
|
||||
\
|
||||
--disable-intermodule --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
--disable-intermodule $(STAGE1_CHECKING) --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
@endif gcc-bootstrap
|
||||
|
||||
.PHONY: configure-stage2-gcc maybe-configure-stage2-gcc
|
||||
|
@ -16077,7 +16098,7 @@ configure-stage1-intl:
|
|||
$(SHELL) $${libsrcdir}/configure \
|
||||
$(HOST_CONFIGARGS) $${srcdiroption} \
|
||||
\
|
||||
--disable-intermodule --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
--disable-intermodule $(STAGE1_CHECKING) --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
@endif intl-bootstrap
|
||||
|
||||
.PHONY: configure-stage2-intl maybe-configure-stage2-intl
|
||||
|
@ -17609,7 +17630,7 @@ configure-stage1-ld:
|
|||
$(SHELL) $${libsrcdir}/configure \
|
||||
$(HOST_CONFIGARGS) $${srcdiroption} \
|
||||
\
|
||||
--disable-intermodule --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
--disable-intermodule $(STAGE1_CHECKING) --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
@endif ld-bootstrap
|
||||
|
||||
.PHONY: configure-stage2-ld maybe-configure-stage2-ld
|
||||
|
@ -18364,7 +18385,7 @@ configure-stage1-libcpp:
|
|||
$(SHELL) $${libsrcdir}/configure \
|
||||
$(HOST_CONFIGARGS) $${srcdiroption} \
|
||||
\
|
||||
--disable-intermodule --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
--disable-intermodule $(STAGE1_CHECKING) --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
@endif libcpp-bootstrap
|
||||
|
||||
.PHONY: configure-stage2-libcpp maybe-configure-stage2-libcpp
|
||||
|
@ -19119,7 +19140,7 @@ configure-stage1-libdecnumber:
|
|||
$(SHELL) $${libsrcdir}/configure \
|
||||
$(HOST_CONFIGARGS) $${srcdiroption} \
|
||||
\
|
||||
--disable-intermodule --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
--disable-intermodule $(STAGE1_CHECKING) --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
@endif libdecnumber-bootstrap
|
||||
|
||||
.PHONY: configure-stage2-libdecnumber maybe-configure-stage2-libdecnumber
|
||||
|
@ -20270,7 +20291,7 @@ configure-stage1-libiberty:
|
|||
$(SHELL) $${libsrcdir}/configure \
|
||||
$(HOST_CONFIGARGS) $${srcdiroption} \
|
||||
\
|
||||
--disable-intermodule --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
--disable-intermodule $(STAGE1_CHECKING) --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
@endif libiberty-bootstrap
|
||||
|
||||
.PHONY: configure-stage2-libiberty maybe-configure-stage2-libiberty
|
||||
|
@ -30112,7 +30133,7 @@ configure-stage1-zlib:
|
|||
$(SHELL) $${libsrcdir}/configure \
|
||||
$(HOST_CONFIGARGS) $${srcdiroption} \
|
||||
\
|
||||
--disable-intermodule --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
--disable-intermodule $(STAGE1_CHECKING) --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)"
|
||||
@endif zlib-bootstrap
|
||||
|
||||
.PHONY: configure-stage2-zlib maybe-configure-stage2-zlib
|
||||
|
@ -41843,36 +41864,9 @@ LEAN = false
|
|||
# 'touch' doesn't work right on some platforms.
|
||||
STAMP = echo timestamp >
|
||||
|
||||
# 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. 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_CFLAGS=@stage1_cflags@
|
||||
STAGE1_LANGUAGES=@stage1_languages@
|
||||
|
||||
# We only want to compare .o files, so set this!
|
||||
objext = .o
|
||||
|
||||
# Flags to pass to stage2 and later makes.
|
||||
POSTSTAGE1_FLAGS_TO_PASS = \
|
||||
CC="$${CC}" CC_FOR_BUILD="$${CC_FOR_BUILD}" \
|
||||
STAGE_PREFIX="$$r/$(HOST_SUBDIR)/prev-gcc/" \
|
||||
CFLAGS="$(BOOT_CFLAGS)" \
|
||||
LIBCFLAGS="$(BOOT_CFLAGS)" \
|
||||
LDFLAGS="$(BOOT_LDFLAGS)" \
|
||||
"`echo 'ADAFLAGS=$(BOOT_ADAFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`"
|
||||
|
||||
# For stage 1:
|
||||
# * We force-disable intermodule optimizations, even if
|
||||
# --enable-intermodule was passed, since the installed compiler probably
|
||||
# can't handle them. Luckily, autoconf always respects
|
||||
# the last argument when conflicting --enable arguments are passed.
|
||||
# * Likewise, we force-disable coverage flags, since the installed compiler
|
||||
# probably has never heard of them.
|
||||
# * We build only C (and possibly Ada).
|
||||
|
||||
|
||||
.PHONY: stage1-start stage1-end
|
||||
|
||||
|
|
47
Makefile.tpl
47
Makefile.tpl
|
@ -300,6 +300,16 @@ CXXFLAGS = @CXXFLAGS@
|
|||
LIBCXXFLAGS = $(CXXFLAGS) -fno-implicit-templates
|
||||
PICFLAG =
|
||||
|
||||
# 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. 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_CFLAGS=@stage1_cflags@
|
||||
STAGE1_CHECKING=@stage1_checking@
|
||||
STAGE1_LANGUAGES=@stage1_languages@
|
||||
|
||||
# -----------------------------------------------
|
||||
# Programs producing files for the TARGET machine
|
||||
# -----------------------------------------------
|
||||
|
@ -431,6 +441,16 @@ X11_FLAGS_TO_PASS = \
|
|||
'X11_EXTRA_CFLAGS=$(X11_EXTRA_CFLAGS)' \
|
||||
'X11_EXTRA_LIBS=$(X11_EXTRA_LIBS)'
|
||||
|
||||
# Flags to pass to stage2 and later makes.
|
||||
|
||||
POSTSTAGE1_FLAGS_TO_PASS = \
|
||||
CC="$${CC}" CC_FOR_BUILD="$${CC_FOR_BUILD}" \
|
||||
STAGE_PREFIX="$$r/$(HOST_SUBDIR)/prev-gcc/" \
|
||||
CFLAGS="$(BOOT_CFLAGS)" \
|
||||
LIBCFLAGS="$(BOOT_CFLAGS)" \
|
||||
LDFLAGS="$(BOOT_LDFLAGS)" \
|
||||
"`echo 'ADAFLAGS=$(BOOT_ADAFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`"
|
||||
|
||||
# Flags to pass down to makes which are built with the target environment.
|
||||
# The double $ decreases the length of the command line; those variables
|
||||
# are set in BASE_FLAGS_TO_PASS, and the sub-make will expand them. The
|
||||
|
@ -1246,36 +1266,9 @@ LEAN = false
|
|||
# 'touch' doesn't work right on some platforms.
|
||||
STAMP = echo timestamp >
|
||||
|
||||
# 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. 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_CFLAGS=@stage1_cflags@
|
||||
STAGE1_LANGUAGES=@stage1_languages@
|
||||
|
||||
# We only want to compare .o files, so set this!
|
||||
objext = .o
|
||||
|
||||
# Flags to pass to stage2 and later makes.
|
||||
POSTSTAGE1_FLAGS_TO_PASS = \
|
||||
CC="$${CC}" CC_FOR_BUILD="$${CC_FOR_BUILD}" \
|
||||
STAGE_PREFIX="$$r/$(HOST_SUBDIR)/prev-gcc/" \
|
||||
CFLAGS="$(BOOT_CFLAGS)" \
|
||||
LIBCFLAGS="$(BOOT_CFLAGS)" \
|
||||
LDFLAGS="$(BOOT_LDFLAGS)" \
|
||||
"`echo 'ADAFLAGS=$(BOOT_ADAFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`"
|
||||
|
||||
# For stage 1:
|
||||
# * We force-disable intermodule optimizations, even if
|
||||
# --enable-intermodule was passed, since the installed compiler probably
|
||||
# can't handle them. Luckily, autoconf always respects
|
||||
# the last argument when conflicting --enable arguments are passed.
|
||||
# * Likewise, we force-disable coverage flags, since the installed compiler
|
||||
# probably has never heard of them.
|
||||
# * We build only C (and possibly Ada).
|
||||
|
||||
[+ FOR bootstrap-stage +]
|
||||
.PHONY: stage[+id+]-start stage[+id+]-end
|
||||
|
||||
|
|
12
configure.in
12
configure.in
|
@ -2428,6 +2428,18 @@ fi
|
|||
|
||||
AC_SUBST(stage1_cflags)
|
||||
|
||||
# Enable --enable-checking in stage1 of the compiler.
|
||||
AC_ARG_ENABLE(stage1-checking,
|
||||
[ --enable-stage1-checking[=all] choose additional checking for stage1
|
||||
of the compiler.],
|
||||
[stage1_checking=--enable-checking=${enable_stage1_checking}],
|
||||
[if test "x$enable_checking" = xno; then
|
||||
stage1_checking=--enable-checking
|
||||
else
|
||||
stage1_checking=--enable-checking${enable_checking+=}$enable_checking
|
||||
fi])
|
||||
AC_SUBST(stage1_checking)
|
||||
|
||||
# Enable -Werror in bootstrap stage2 and later.
|
||||
# Change the default to "no" on release branches.
|
||||
AC_ARG_ENABLE(werror,
|
||||
|
|
|
@ -1,3 +1,9 @@
|
|||
2006-12-19 Paolo Bonzini <bonzini@gnu.org>
|
||||
|
||||
PR bootstrap/29544
|
||||
* gcc/Makefile.in (STAGE1_CHECKING): Rename to...
|
||||
(STAGE1_CHECKING_CFLAGS): ... this.
|
||||
|
||||
2006-12-18 Andrew Pinski <pinskia@gmail.com>
|
||||
|
||||
PR target/29779
|
||||
|
|
|
@ -155,7 +155,7 @@ TCFLAGS =
|
|||
CFLAGS = @CFLAGS@
|
||||
LDFLAGS = @LDFLAGS@
|
||||
STAGE1_CFLAGS = -g @stage1_cflags@
|
||||
STAGE1_CHECKING = -DENABLE_CHECKING -DENABLE_ASSERT_CHECKING
|
||||
STAGE1_CHECKING_CFLAGS = -DENABLE_CHECKING -DENABLE_ASSERT_CHECKING
|
||||
BOOT_CFLAGS = -g -O2
|
||||
|
||||
# Flags to determine code coverage. When coverage is disabled, this will
|
||||
|
@ -4213,7 +4213,7 @@ STAGEFEEDBACK_FLAGS_TO_PASS = \
|
|||
# The stage1 compiler is always built with checking enabled.
|
||||
stage1_build:
|
||||
$(MAKE) CC="$(CC)" libdir=$(libdir) LANGUAGES="$(BOOT_LANGUAGES)" \
|
||||
CFLAGS="$(STAGE1_CFLAGS) $(STAGE1_CHECKING)" \
|
||||
CFLAGS="$(STAGE1_CFLAGS) $(STAGE1_CHECKING_CFLAGS)" \
|
||||
MAKEINFO="$(MAKEINFO)" MAKEINFOFLAGS="$(MAKEINFOFLAGS)" \
|
||||
COVERAGE_FLAGS= OBJS-onestep="$(OBJS)"
|
||||
$(STAMP) stage1_build
|
||||
|
|
Loading…
Reference in New Issue