From mboxrd@z Thu Jan 1 00:00:00 1970 From: hjl@lucon.org (H.J. Lu) To: egcs@cygnus.com Subject: A bootstrap-ultralean patch Date: Fri, 16 Jan 1998 02:26:00 -0000 Message-id: X-SW-Source: 1998-01/msg00527.html Hi, I made this patch to allow # make bootstrap-ultralean which only builds the C compiler for stage 1. It saves both CPU time and disk space. Thanks. -- H.J. Lu (hjl@gnu.org) -- Thu Jan 15 17:00:42 1998 H.J. Lu (hjl@gnu.org) * Makefile.in (bootstrap-ultralean): New target. Index: gcc/Makefile.in =================================================================== RCS file: /home/work/cvs/gnu/egcs/gcc/Makefile.in,v retrieving revision 1.1.1.17 diff -u -r1.1.1.17 Makefile.in --- gcc/Makefile.in 1998/01/14 03:09:43 1.1.1.17 +++ gcc/Makefile.in 1998/01/16 01:48:18 @@ -2662,7 +2669,7 @@ $(LANG_DIFF_EXCLUDES) \ gcc-$(oldversion) gcc-$(version) > diffs -bootstrap bootstrap-lean: force +bootstrap bootstrap-lean bootstrap-ultralean: force # 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. @@ -2673,9 +2680,12 @@ # To prevent `make install' from compiling alloca.o and then relinking cc1 # because alloca.o is newer, we permit these recursive makes to compile # alloca.o. Then cc1 is newer, so it won't have to be relinked. - $(MAKE) CC="stage1/xgcc -Bstage1/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) STAGE_PREFIX=stage1/ LANGUAGES="$(LANGUAGES)" + if test $@ = bootstrap-ultralean; then \ + languages="$(BOOT_LANGUAGES)"; else \ + languages="$(LANGUAGES)"; fi; \ + $(MAKE) CC="stage1/xgcc -Bstage1/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) STAGE_PREFIX=stage1/ LANGUAGES="$$languages" $(MAKE) stage2 - -if test $@ = bootstrap-lean; then rm -rf stage1; else true; fi + -if test $@ = bootstrap; then true; else rm -rf stage1; fi $(MAKE) CC="stage2/xgcc -Bstage2/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) STAGE_PREFIX=stage2/ LANGUAGES="$(LANGUAGES)" bootstrap2: force Thu Jan 15 17:37:23 1998 H.J. Lu (hjl@gnu.org) * Makefile.in (bootstrap-ultralean): New target. Index: Makefile.in =================================================================== RCS file: /home/work/cvs/gnu/egcs/Makefile.in,v retrieving revision 1.1.1.8 diff -u -r1.1.1.8 Makefile.in --- Makefile.in 1997/12/08 17:03:45 1.1.1.8 +++ Makefile.in 1998/01/16 01:43:34 @@ -1290,8 +1290,8 @@ # In theory, on an SMP all those dependencies can be resolved # in parallel. # -.PHONY: bootstrap bootstrap-lean bootstrap2 bootstrap3 bootstrap4 -bootstrap bootstrap-lean bootstrap2 bootstrap3 bootstrap4: all-texinfo all-bison all-byacc all-binutils all-gas all-ld +.PHONY: bootstrap bootstrap-lean bootstrap-ultralean bootstrap2 bootstrap3 bootstrap4 +bootstrap bootstrap-lean bootstrap-ultralean bootstrap2 bootstrap3 bootstrap4: all-texinfo all-bison all-byacc all-binutils all-gas all-ld @r=`pwd`; export r; \ s=`cd $(srcdir); pwd`; export s; \ $(SET_LIB_PATH) \ @@ -1302,7 +1302,7 @@ case "$@" in \ *bootstrap4 ) msg="Comparing stage3 and stage4 of the compiler"; \ compare=compare3 ;; \ - *-lean ) msg="Comparing stage2 and stage3 of the compiler"; \ + *-lean | *-ultralean ) msg="Comparing stage2 and stage3 of the compiler"; \ compare=compare-lean ;; \ * ) msg="Comparing stage2 and stage3 of the compiler"; \ compare=compare ;; \