This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: proposed bootstrap changes



> though I don't know why you have the -f.

Me neither.  I took it out.

I also added a "bubblestage" which (for lack of a better name) bubbles
the stage directories back to . one at a time and rebuilds them.  Also
added "unstageN" style commands, which unroll a bootstrap back to a
specific point (options for whether later stages are removed or not).
Comments?

unstage1-norm unstage2-norm unstage3-norm unstage4-norm:
	-set -vx; stage=`echo $@ | sed -e 's/un//' -e 's/-norm//'`; \
	if test -d $$stage; then \
	  mv $$stage/* . 2>/dev/null; \
	  for i in `cd $$stage; echo *` ; do \
	    if test -d $$stage/$$i; then \
	      mv $$stage/$$i/* $$i/. 2>/dev/null; \
	    else \
	      mv $$stage/$$i .; \
	    fi \
	  done \
	fi ; \
	rm -f $${stage}_build $${stage}_copy ;\
	echo $${stage}_build > stage_last ;\
	rm -rf $$stage

unstage1: unstage1-norm
	-rm -rf stage2 stage3 stage4
unstage2: unstage2-norm
	-rm -rf stage3 stage4
unstage3: unstage3-norm
	-rm -rf stage4
unstage4: unstage4-norm
	@true

restage1: unstage1
	$(MAKE) stage1_build

restage2: unstage2
	$(MAKE) LANGUAGES="$(LANGUAGES)" stage2_build

restage3: unstage3
	$(MAKE) LANGUAGES="$(LANGUAGES)" stage3_build

restage4: unstage4
	$(MAKE) LANGUAGES="$(LANGUAGES)" stage4_build

bubblestrap:
	if test -f stage3_build; then true; else \
	  echo; echo You must \"make bootstrap\" first.; \
	  exit 1; \
	fi
	for i in stage3 \
		unstage1-norm stage1_build stage1_copy \
		unstage2-norm stage2_build stage2_copy \
		unstage3-norm stage3_build ; \
	do \
	  $(MAKE) LANGUAGES="$(LANGUAGES)" $$i || exit 1 ; \
	done


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]