From a01bf1fbc1b3ef33ea969c597dd29d86432bdbc0 Mon Sep 17 00:00:00 2001 From: "K. Richard Pixley" Date: Sun, 9 Jun 1991 20:27:20 +0000 Subject: [PATCH] added support for binary comparisons. --- Makefile.in | 41 ++++++++++++++++++++++++----------------- bfd/Makefile.in | 5 +++++ binutils/Makefile.in | 18 +++++++++++------- gas/Makefile.in | 22 ++++++++-------------- 4 files changed, 48 insertions(+), 38 deletions(-) diff --git a/Makefile.in b/Makefile.in index 0d4f78992a8..ea0f3c0a9f1 100644 --- a/Makefile.in +++ b/Makefile.in @@ -1,7 +1,7 @@ # # Makefile for directory with subdirs to build. # -# Last Mod Mon May 27 15:55:09 PDT 1991, by rich@cygint.cygnus.com +# Last Mod Fri May 31 10:35:51 PDT 1991, by rich@cygint.cygnus.com # # $Id$ @@ -26,21 +26,18 @@ all: $(MAKE) subdir_do DO=all "DODIRS=$(SUBDIRS) $(OTHERS)" subdir_do: force - for i in $(DODIRS); \ - do \ - if [ -d $(srcdir)/$$i -o -d $(srcdir)/$$i.$(target) ] ; then \ - if (cd $(srcdir)/$$i`if [ -d $(srcdir)/$$i.$(target) ] ; \ - then echo .$(target) ; fi`$(subdir); \ - $(MAKE) \ - "destdir=$(destdir)" \ - "AR=$(AR)" \ - "AR_FLAGS=$(AR_FLAGS)" \ - "RANLIB=$(RANLIB)" $(DO)) ; \ - then true ; \ - else exit 1 ; \ - fi ;\ - else true; fi ; \ - done + for i in $(DODIRS); do \ + if [ -d $(srcdir)/$$i -o -d $(srcdir)/$$i.$(target) ] ; then \ + if (cd $(srcdir)/$$i`if [ -d $(srcdir)/$$i.$(target) ] ; \ + then echo .$(target) ; fi`$(subdir); \ + $(MAKE) \ + "against=$(against)" \ + "AR=$(AR)" \ + "AR_FLAGS=$(AR_FLAGS)" \ + "RANLIB=$(RANLIB)" $(DO)) ; then true ; \ + else exit 1 ; fi ; \ + else true ; fi ; \ + done bootstrap: $(MAKE) all @@ -48,14 +45,17 @@ bootstrap: $(MAKE) pass "stagepass=stage1" $(MAKE) stage2 $(MAKE) pass "stagepass=stage2" + $(MAKE) comparison bootstrap2: $(MAKE) pass "stagepass=stage1" $(MAKE) stage2 $(MAKE) pass "stagepass=stage2" + $(MAKE) comparison bootstrap3: $(MAKE) pass "stagepass=stage2" + $(MAKE) comparison pass: cp $(srcdir)/gcc`if [ -d $(srcdir)/gcc.$(target) ] ; \ @@ -90,6 +90,10 @@ stage3: stage4: $(MAKE) subdir_do DO=stage4 "DODIRS=$(SUBDIRS)" +against=stage2 + +comparison:; $(MAKE) subdir_do DO=comparison against=$(against) "DODIRS=$(SUBDIRS)" + de-stage1:; $(MAKE) subdir_do DO=de-stage1 "DODIRS=$(SUBDIRS)" de-stage2:; $(MAKE) subdir_do DO=de-stage2 "DODIRS=$(SUBDIRS)" de-stage3:; $(MAKE) subdir_do DO=de-stage3 "DODIRS=$(SUBDIRS)" @@ -132,7 +136,10 @@ Makefile: $(srcdir)/Makefile.in $(srcdir)/configure # # $Log$ -# Revision 1.14 1991/05/31 12:34:55 gnu +# Revision 1.15 1991/06/09 20:27:01 rich +# added support for binary comparisons. +# +# Revision 1.14 1991/05/31 12:34:55 gnu # Avoid error stop from Make if a directory doesn't exist during subdir_do. # # Revision 1.13 1991/05/27 23:03:20 rich diff --git a/bfd/Makefile.in b/bfd/Makefile.in index b7466bcfaa8..9d32e339df5 100644 --- a/bfd/Makefile.in +++ b/bfd/Makefile.in @@ -72,6 +72,11 @@ stage3: force - mkdir stage3 - mv -f $(STAGESTUFF) stage3 +against=stage2 + +comparison: force + for i in *.o ; do cmp $$i $(against)/$$i || exit 1 ; done + de-stage1: force - (cd stage1 ; mv -f $(STAGESTUFF) ..) - rmdir stage1 diff --git a/binutils/Makefile.in b/binutils/Makefile.in index ce378c0b672..9555c865817 100644 --- a/binutils/Makefile.in +++ b/binutils/Makefile.in @@ -33,6 +33,7 @@ NM_PROG=nm OBJDUMP_PROG=objdump PROGS = $(SIZE_PROG) $(COPY_PROG) $(OBJDUMP_PROG) $(NM_PROG) $(AR_PROG) $(STRIP_PROG) $(RANLIB_PROG) +STAGESTUFF = $(PROGS) *.o BASEDIR = $(srcdir)/.. LIBDIR = $(srcdir)/../bfd$(subdir) @@ -104,15 +105,20 @@ $(STRIP_PROG): $(COPY_PROG) stage1: force - mkdir stage1 - - mv -f *.o $(PROGS) stage1 + - mv -f $(STAGESTUFF) stage1 stage2: force - mkdir stage2 - - mv -f *.o $(PROGS) stage2 + - mv -f $(STAGESTUFF) stage2 stage3: force - mkdir stage3 - - mv -f *.o $(PROGS) stage3 + - mv -f $(STAGESTUFF) stage3 + +against=stage2 + +comparison: force + for i in $(STAGESTUFF) ; do cmp $$i $(against)/$$i ; done de-stage1: force - (cd stage1 ; mv -f * ..) @@ -127,7 +133,7 @@ de-stage3: force - rmdir stage3 clean: - -rm -f *.o *~ \#* core $(PROGS) TAGS + -rm -f *.o *~ \#* core $(STAGESTUFF) TAGS etags tags: TAGS @@ -135,7 +141,7 @@ TAGS: force etags $(INCDIR)/*.h $(BFDSRC)/*.[hc] *.[hc] realclean: clean - -rm -f $(PROGS) TAGS + -rm -f $(STAGESTUFF) TAGS install: $(PROGS) for i in $(PROGS) ; do \ @@ -148,10 +154,8 @@ size.o: size.c copy.o: copy.c objdump.o: objdump.c m68k-pinsn.o: m68k-pinsn.c -m68k-pinsn.o: ./m68k-opcode.h i960-pinsn.o: i960-pinsn.c sparc-pinsn.o: sparc-pinsn.c -sparc-pinsn.o: ./sparc-opcode.h nm.o: nm.c ar.o: ar.c getopt.o:getopt.c diff --git a/gas/Makefile.in b/gas/Makefile.in index 7d91bec8437..f812ede359c 100644 --- a/gas/Makefile.in +++ b/gas/Makefile.in @@ -488,17 +488,17 @@ bootstrap: as force $(MAKE) CC="$(CC)" CFLAGS="-O -Bstage1/ $(CFLAGS)" libdir=$(libdir) ALLOCA= as $(MAKE) stage2 $(MAKE) CC="$(CC)" CFLAGS="-O -Bstage2/ $(CFLAGS)" libdir=$(libdir) ALLOCA= as - $(MAKE) stage-last + $(MAKE) comparison against=stage2 bootstrap2: force $(MAKE) CC="$(CC)" CFLAGS="-O -Bstage1/ $(CFLAGS)" libdir=$(libdir) ALLOCA= as $(MAKE) stage2 $(MAKE) CC="$(CC)" CFLAGS="-O -Bstage2/ $(CFLAGS)" libdir=$(libdir) ALLOCA= as - $(MAKE) stage-last + $(MAKE) comparison against-stage2 bootstrap3: force $(MAKE) CC="$(CC)" CFLAGS="-O -Bstage2/ $(CFLAGS)" libdir=$(libdir) ALLOCA= as - $(MAKE) stage-last + $(MAKE) comparison against=stage2 # Copy the object files from a particular stage into a subdirectory. stage1: force @@ -513,6 +513,11 @@ stage3: force -mkdir stage3 -mv $(STAGESTUFF) stage3 +against=stage2 + +comparison: force + for i in $(STAGESTUFF) ; do cmp $$i $(against)/$$i ; done + de-stage1: force - (cd stage1 ; mv -f * ..) - rmdir stage1 @@ -525,9 +530,6 @@ de-stage3: force - (cd stage3 ; mv -f * ..) - rmdir stage3 -stage-last: - for i in *.o; do cmp $$i stage2/$$i; done - # Copy just the executable files from a particular stage into a subdirectory, # and delete the object files. Use this if you're just verifying a version # that is pretty sure to work, and you are short of disk space. @@ -563,14 +565,6 @@ risky-stage4: force .PHONY: stage1 stage2 stage3 stage4 clean realclean TAGS bootstrap .PHONY: risky-stage1 risky-stage2 risky-stage3 risky-stage4 -comparison: clean - $(MAKE) "CC=/usr/local/bin/gcc -Wall" as - $(MAKE) stage1 - - $(MAKE) "CC=/usr/local/bin/gcc -Wall -b$(target) -Bstage1/" as -k - $(MAKE) stage2 - - $(MAKE) "CC=/usr/local/bin/gcc -Wall -b$(target)" as -k - $(MAKE) stage-last - force: Makefile: $(srcdir)/Makefile.in $(srcdir)/configure -- 2.30.2