From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13257 invoked by alias); 3 Jun 2004 05:00:02 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 13215 invoked from network); 3 Jun 2004 05:00:00 -0000 Received: from unknown (HELO cgf.cx) (66.30.22.40) by sourceware.org with SMTP; 3 Jun 2004 05:00:00 -0000 Received: by cgf.cx (Postfix, from userid 201) id 6BCF4400089; Thu, 3 Jun 2004 01:00:00 -0400 (EDT) Date: Thu, 03 Jun 2004 05:00:00 -0000 From: Christopher Faylor To: binutils@sources.redhat.com, gdb@sources.redhat.com, gcc-patches@gcc.gnu.org Subject: Re: gdb and binutils build broken -- Makefile.def gcc-no-bootstrap change Message-ID: <20040603050000.GA5742@coe.casa.cgf.cx> Mail-Followup-To: binutils@sources.redhat.com, gdb@sources.redhat.com, gcc-patches@gcc.gnu.org References: <20040601145306.5188C4B104@berman.michael-chastain.com> <40BCAFB5.80006@polimi.it> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <40BCAFB5.80006@polimi.it> User-Agent: Mutt/1.4.1i X-SW-Source: 2004-06/txt/msg00017.txt.bz2 On Tue, Jun 01, 2004 at 06:32:53PM +0200, Paolo Bonzini wrote: >Here is the least invasive patch I could do to fix the problem. It is >actually better than the previous solution also because it limits the >number of interacting sed passes to resolve @if's, and it allows >conditionals like "@if as-bootstrap". > >I think it qualifies as an obvious fix but I don't have CVS available >right now, would you please commit it for me to both gcc and src? > >Thank you very much, I apologize. I've taken the liberty of checking this into gcc and src. It affects cygwin builds too, FWIW. This patch is infinitely better than the one I posted on gcc-patches so that one is withdrawn. cgf >2004-06-01 Paolo Bonzini > > * configure.in: Fix --enable-bootstrap breakage > introduced in trees without gcc. > * configure: Regenerate. > >Index: configure.in >=================================================================== >RCS file: /cvs/gcc/gcc/configure.in,v >retrieving revision 1.293 >diff -u -r1.293 configure.in >--- configure.in 1 Jun 2004 07:54:44 -0000 1.293 >+++ configure.in 1 Jun 2004 16:28:30 -0000 >@@ -1730,6 +1730,31 @@ > # to maintain later. In this particular case, you just have to be careful > # not to nest @if/@endif pairs, because configure will not warn you at all. > >+AC_ARG_ENABLE([bootstrap], >+[ --enable-bootstrap Enable bootstrapping [no]],, >+enable_bootstrap=no) >+if test -d ${srcdir}/gcc; then >+ case "$host:$target:$enable_bootstrap" in >+ $build:$build:yes | *:no) ;; >+ *:yes) AC_MSG_ERROR([cannot bootstrap a cross-compiler]) ;; >+ *) AC_MSG_ERROR([invalid option for --enable-bootstrap]) ;; >+ esac >+else >+ if test $enable_bootstrap = yes; then >+ AC_MSG_ERROR([cannot bootstrap without a compiler]) >+ fi >+fi >+ >+case "$enable_bootstrap" in >+ yes) >+ default_target=bootstrap >+ bootstrap_suffix=bootstrap ;; >+ no) >+ default_target=all >+ bootstrap_suffix=no-bootstrap ;; >+esac >+AC_SUBST(default_target) >+ > for module in ${build_modules} ; do > if test -z "${no_recursion}" \ > && test -f ${build_subdir}/${module}/Makefile; then >@@ -1738,7 +1763,9 @@ > fi > extrasub="$extrasub > /^@if build-$module\$/d >-/^@endif build-$module\$/d" >+/^@endif build-$module\$/d >+/^@if build-$module-$bootstrap_suffix\$/d >+/^@endif build-$module-$bootstrap_suffix\$/d" > done > for module in ${configdirs} ; do > if test -z "${no_recursion}" \ >@@ -1748,7 +1775,9 @@ > fi > extrasub="$extrasub > /^@if $module\$/d >-/^@endif $module\$/d" >+/^@endif $module\$/d >+/^@if $module-$bootstrap_suffix\$/d >+/^@endif $module-$bootstrap_suffix\$/d" > done > for module in ${target_configdirs} ; do > if test -z "${no_recursion}" \ >@@ -1758,38 +1787,11 @@ > fi > extrasub="$extrasub > /^@if target-$module\$/d >-/^@endif target-$module\$/d" >+/^@endif target-$module\$/d >+/^@if target-$module-$bootstrap_suffix\$/d >+/^@endif target-$module-$bootstrap_suffix\$/d" > done > >-AC_ARG_ENABLE([bootstrap], >-[ --enable-bootstrap Enable bootstrapping [no]],, >-enable_bootstrap=no) >-if test -d ${srcdir}/gcc; then >- case "$host:$target:$enable_bootstrap" in >- $build:$build:yes | *:no) ;; >- *:yes) AC_MSG_ERROR([cannot bootstrap a cross-compiler]) ;; >- *) AC_MSG_ERROR([invalid option for --enable-bootstrap]) ;; >- esac >-else >- if test $enable_bootstrap = yes; then >- AC_MSG_ERROR([cannot bootstrap without a compiler]) >- fi >-fi >- >-case "$enable_bootstrap" in >- yes) >- default_target=bootstrap >- extrasub="$extrasub >-/^@if gcc-bootstrap\$/d >-/^@endif gcc-bootstrap\$/d" ;; >- no) >- default_target=all >- extrasub="$extrasub >-/^@if gcc-no-bootstrap\$/d >-/^@endif gcc-no-bootstrap\$/d" ;; >-esac >-AC_SUBST(default_target) >- > extrasub="$extrasub > /^@if /,/^@endif /d" >