From: ceriel Date: Wed, 16 Oct 1991 13:07:28 +0000 (+0000) Subject: generate Version.c X-Git-Tag: release-5-5~729 X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=147bb196b206ab2350b0884f0b98b3505290c28f;p=ack.git generate Version.c --- diff --git a/lang/cem/cemcom.ansi/Makefile b/lang/cem/cemcom.ansi/Makefile index 694b54d09..6c0caf7cd 100644 --- a/lang/cem/cemcom.ansi/Makefile +++ b/lang/cem/cemcom.ansi/Makefile @@ -1,1113 +1,5 @@ -# $Header$ -# M A K E F I L E F O R A C K C - C O M P I L E R - -# Machine and environ dependent definitions -EMHOME = ../../.. -CC = cc -CFLOW = cflow -MKDEP = $(EMHOME)/bin/mkdep -PRID = $(EMHOME)/bin/prid -CID = $(EMHOME)/bin/cid - -# Libraries and EM interface definitions -SYSLIB = $(EMHOME)/modules/lib/libsystem.a -EMKLIB = $(EMHOME)/modules/lib/libemk.a $(EMHOME)/lib/em_data.a -EMELIB = $(EMHOME)/modules/lib/libeme.a $(EMHOME)/lib/em_data.a -STRLIB = $(EMHOME)/modules/lib/libstring.a -PRTLIB = $(EMHOME)/modules/lib/libprint.a -FLTLIB = $(EMHOME)/modules/lib/libflt.a -EMMESLIB = $(EMHOME)/modules/lib/libem_mes.a -EMMESOLIB = $(EMHOME)/modules/lib/libem_mesO.a -EMMESCELIB = $(EMHOME)/modules/lib/libem_mesCE.a -MACH = sun3 -EMCELIB = $(EMHOME)/lib/$(MACH)/ce.a \ - $(EMHOME)/lib/$(MACH)/back.a \ - $(EMHOME)/modules/lib/libflt.a \ - $(EMHOME)/modules/lib/libobject.a $(EMHOME)/lib/em_data.a -EMOCELIB = $(EMHOME)/modules/lib/libCEopt.a $(EMHOME)/lib/$(MACH)/ce.a \ - $(EMHOME)/lib/$(MACH)/back.a \ - $(EMHOME)/modules/lib/libflt.a \ - $(EMHOME)/modules/lib/libobject.a $(EMHOME)/lib/em_data.a -INPLIB = $(EMHOME)/modules/lib/libinput.a -ALLOCLIB = $(EMHOME)/modules/lib/liballoc.a -MALLOC = $(EMHOME)/modules/lib/malloc.o -LIBS = $(INPLIB) $(EMMESLIB) $(EMKLIB) $(PRTLIB) $(STRLIB) \ - $(ALLOCLIB) $(MALLOC) $(SYSLIB) $(FLTLIB) -ELIBS = $(INPLIB) $(EMMESLIB) $(EMELIB) $(PRTLIB) $(STRLIB) \ - $(ALLOCLIB) $(MALLOC) $(SYSLIB) $(FLTLIB) -OLIBS = $(INPLIB) $(EMMESOLIB) $(EMOCELIB) $(PRTLIB) $(STRLIB) \ - $(ALLOCLIB) $(MALLOC) $(SYSLIB) -CELIBS = $(INPLIB) $(EMMESCELIB) $(EMCELIB) $(PRTLIB) $(STRLIB) \ - $(ALLOCLIB) $(MALLOC) $(SYSLIB) -LLIBS = $(INPLIB) $(EMMESLIB) $(PRTLIB) $(STRLIB) \ - $(ALLOCLIB) $(MALLOC) $(SYSLIB) $(FLTLIB) -LIB_INCLUDES = -I$(EMHOME)/modules/h -I$(EMHOME)/modules/pkg -EM_INCLUDES = -I$(EMHOME)/h -SYSLLIB = $(EMHOME)/modules/lib/llib-lsystem.ln -EMKLLIB = $(EMHOME)/modules/lib/llib-lemk.ln -EMELLIB = $(EMHOME)/modules/lib/llib-leme.ln -STRLLIB = $(EMHOME)/modules/lib/llib-lstring.ln -PRTLLIB = $(EMHOME)/modules/lib/llib-lprint.ln -EMMESLLIB = $(EMHOME)/modules/lib/llib-lem_mes.ln -INPLLIB = $(EMHOME)/modules/lib/llib-linput.ln -ALLOCLLIB = $(EMHOME)/modules/lib/llib-lalloc.ln -#LINTLIBS = -LINTLIBS = $(EMMESLLIB) $(EMKLLIB) $(PRTLLIB) $(STRLLIB) $(ALLOCLLIB) $(SYSLLIB) -CURRDIR = - -COPTIONS = - -# What parser generator to use and how -GEN = $(EMHOME)/bin/LLgen -GENOPTIONS = #-vvvx - -# tabgen -TABGEN = $(EMHOME)/bin/tabgen - -# Special #defines during compilation -PROF = #-pg -CDEFS = $(EM_INCLUDES) $(LIB_INCLUDES) -CFLAGS = $(CDEFS) $(COPTIONS) $(PROF) -O -LDFLAGS = $(PROF) - -# Grammar files and their objects -LSRC = tokenfile.g declar.g statement.g expression.g program.g ival.g -LCSRC = tokenfile.c declar.c statement.c expression.c program.c Lpars.c ival.c -LOBJ = tokenfile.o declar.o statement.o expression.o program.o Lpars.o ival.o - -# Objects of hand-written C files -CSRC = main.c idf.c declarator.c decspecs.c struct.c \ - expr.c ch3.c ch3bin.c cstoper.c fltcstoper.c arith.c \ - code.c dumpidf.c error.c field.c\ - tokenname.c LLlex.c LLmessage.c \ - input.c domacro.c replace.c init.c options.c \ - skip.c stack.c type.c ch3mon.c label.c eval.c \ - switch.c conversion.c util.c proto.c \ - pragma.c blocks.c dataflow.c Version.c stab.c\ - l_lint.c l_states.c l_misc.c l_ev_ord.c l_outdef.c l_comment.c -COBJ = main.o idf.o declarator.o decspecs.o struct.o \ - expr.o ch3.o ch3bin.o cstoper.o fltcstoper.o arith.o \ - code.o dumpidf.o error.o field.o\ - tokenname.o LLlex.o LLmessage.o \ - input.o domacro.o replace.o init.o options.o \ - skip.o stack.o type.o ch3mon.o label.o eval.o \ - switch.o conversion.o util.o proto.o \ - pragma.o blocks.o dataflow.o Version.o stab.o \ - l_lint.o l_states.o l_misc.o l_ev_ord.o l_outdef.o l_comment.o - -# Objects of other generated C files -GCSRC = char.c symbol2str.c next.c -GOBJ = char.o symbol2str.o next.o - -# Extra object for generating peephole-optimizer-code-expander version. -# The Sun-3 version is faster when the text-size exceeds 180K! ARRGH -EXTRA_O = - -STRSRC = code.str declar.str def.str expr.str field.str \ - estack.str util.str proto.str replace.str \ - idf.str macro.str stack.str stmt.str struct.str switch.str type.str \ - l_brace.str l_state.str l_outdef.str -# generated source files -GHSTRSRC = code.h declar.h def.h expr.h field.h \ - estack.h util.h proto.h replace.h \ - idf.h macro.h stack.h stmt.h struct.h switch.h type.h \ - l_brace.h l_state.h l_outdef.h -GSRC = $(GCSRC) $(GHSTRSRC) - -# .h files generated by `make hfiles LLfiles'; PLEASE KEEP THIS UP-TO-DATE! -GHSRC = botch_free.h dataflow.h debug.h density.h errout.h \ - idfsize.h ifdepth.h inputtype.h macbuf.h lint.h \ - nobitfield.h nopp.h nocross.h \ - nparams.h numsize.h parbufsize.h pathlength.h Lpars.h \ - strsize.h trgt_sizes.h textsize.h use_tmp.h spec_arith.h static.h \ - regcount.h dbsymtab.h - -HSRC = LLlex.h align.h arith.h assert.h atw.h class.h \ - input.h interface.h label.h level.h mes.h sizes.h specials.h \ - file_info.h tokenname.h l_em.h l_lint.h decspecs.h - -HFILES = $(HSRC) $(GHSRC) $(GHSTRSRC) - -# generated files, for 'make clean' only -GENERATED = tokenfile.g Lpars.h LLfiles LL.output lint.out \ - print hfiles Cfiles $(GHSRC) $(GSRC) longnames $(LCSRC) - -# include files containing ALLOCDEF specifications -OBJ = $(COBJ) $(LOBJ) $(GOBJ) $(EXTRA_O) -SRC = $(CSRC) $(LCSRC) $(GCSRC) - -LINT = /usr/bin/lint -LINTFLAGS = - -#EXCLEXCLEXCLEXCL - -.SUFFIXES: .str .h -.str.h: - ./make.allocd <$*.str >$*.h - -Main: Cfiles - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "EMHOME="$(EMHOME) $(CURRDIR)main ; else EMHOME=$(EMHOME); export EMHOME; ./Resolve main ; fi' - @rm -f nmclash.o a.out - -Emain: Cfiles - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "EMHOME="$(EMHOME) $(CURRDIR)emain ; else EMHOME=$(EMHOME); export EMHOME; ./Resolve emain ; fi' - @rm -f nmclash.o a.out - -Omain: Cfiles - rm -f *.o - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "MACH="$(MACH) "EXTRA_O="$(EXTRA_O) "EMHOME="$(EMHOME) "COPTIONS="-DPEEPHOLE $(CURRDIR)omain ; else EMHOME=$(EMHOME); export EMHOME; mach=$(MACH); export mach; ./Resolve omain ; fi' - @rm -f nmclash.o a.out - -CEmain: Cfiles - rm -f *.o - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "MACH="$(MACH) "EMHOME="$(EMHOME) "COPTIONS="-DCODE_EXPANDER $(CURRDIR)cemain ; else EMHOME=$(EMHOME); export EMHOME; mach=$(MACH); export mach; ./Resolve cemain ; fi' - @rm -f nmclash.o a.out - -Lnt: Cfiles - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "EMHOME="$(EMHOME) $(CURRDIR)lnt ; else EMHOME=$(EMHOME); export EMHOME; ./Resolve lnt ; fi' - @rm -f nmclash.o a.out - -install: Main - rm -f $(EMHOME)/lib/em_cemcom.ansi -# rm -f $(EMHOME)/man/em_cemcom.6 - cp $(CURRDIR)main $(EMHOME)/lib/em_cemcom.ansi -# cp $(CURRDIR)cemcom.1 $(EMHOME)/man/em_cemcom.6 - -Oinstall: Omain - cp $(CURRDIR)omain $(EMHOME)/lib/em_cemcomO - -cmp: Main - -cmp $(CURRDIR)main $(EMHOME)/lib/em_cemcom.ansi - -cmp $(CURRDIR)cemcom.1 $(EMHOME)/man/em_cemcom.6 - -pr: - @pr Makefile make.* char.tab Parameters $(HSRC) $(STRSRC) $(LSRC) $(CSRC) - -opr: - make pr | opr - -clean: - rm -f $(OBJ) - rm -f $(GENERATED) main - (cd .. ; rm -rf Xsrc) - -cflow: Cfiles - $(CFLOW) $(CDEFS) $(SRC) - -lint: Cfiles - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "EMHOME="$(EMHOME) LINT=$(LINT) LINTFLAGS=$(LINTFLAGS) Xlint ; else sh Resolve Xlint ; fi' - @rm -f nmclash.o a.out - -longnames: $(SRC) $(HFILES) - sh -c 'if test -f longnames ; then : ; else touch longnames ; fi ; $(PRID) -l7 longnames $? > Xlongnames ; mv Xlongnames longnames' - -# entry points not to be used directly - -Cfiles: hfiles LLfiles $(GENCFILES) $(GSRC) $(GHSRC) Makefile - echo $(SRC) $(HFILES) > Cfiles - -hfiles: ./make.hfiles Parameters - ./make.hfiles Parameters - @touch hfiles - -LLfiles: $(LSRC) - $(GEN) $(GENOPTIONS) $(LSRC) - @touch LLfiles - -tokenfile.g: tokenname.c make.tokfile - tokenfile.g - -symbol2str.c: tokenname.c make.tokcase - symbol2str.c - -char.c: char.tab - $(TABGEN) -fchar.tab >char.c - -next.c: make.next $(STRSRC) - ./make.next $(STRSRC) >next.c - -code.h: make.allocd -declar.h: make.allocd -def.h: make.allocd -expr.h: make.allocd -field.h: make.allocd -idf.h: make.allocd -macro.h: make.allocd -stack.h: make.allocd -stmt.h: make.allocd -struct.h: make.allocd -switch.h: make.allocd -type.h: make.allocd -estack.h: make.allocd -util.h: make.allocd -l_brace.h: make.allocd -l_state.h: make.allocd -l_outdef.h: make.allocd - -depend: Cfiles - sed '/^#AUTOAUTO/,$$d' Makefile >Makefile.new - echo '#AUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTO' >>Makefile.new - $(MKDEP) $(SRC) | sed 's/\.c:/.o:/' >>Makefile.new - mv Makefile Makefile.old - mv Makefile.new Makefile - -#INCLINCLINCLINCL - -$(CURRDIR)main: $(OBJ) $(CURRDIR)Makefile - $(CC) $(COPTIONS) $(LDFLAGS) $(OBJ) $(LIBS) -o $(CURRDIR)main - size $(CURRDIR)main - -$(CURRDIR)emain: $(OBJ) $(CURRDIR)Makefile - $(CC) $(COPTIONS) $(LDFLAGS) $(OBJ) $(ELIBS) -o $(CURRDIR)emain - size $(CURRDIR)emain - -$(CURRDIR)omain: $(OBJ) $(CURRDIR)Makefile - $(CC) $(COPTIONS) $(LDFLAGS) $(OBJ) $(OLIBS) -o $(CURRDIR)omain - size $(CURRDIR)omain - -$(CURRDIR)cemain: $(OBJ) $(CURRDIR)Makefile - $(CC) $(COPTIONS) $(LDFLAGS) $(OBJ) $(CELIBS) -o $(CURRDIR)cemain - size $(CURRDIR)cemain - -$(CURRDIR)lnt: $(OBJ) $(CURRDIR)Makefile - $(CC) $(COPTIONS) $(LDFLAGS) $(OBJ) $(LLIBS) -o $(CURRDIR)lnt - size $(CURRDIR)lnt - -Xlint: $(SRC) - $(LINT) $(CDEFS) $(LINTFLAGS) $(SRC) - -#AUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTO -main.o: LLlex.h -main.o: Lpars.h -main.o: align.h -main.o: arith.h -main.o: assert.h -main.o: dbsymtab.h -main.o: debug.h -main.o: declar.h -main.o: file_info.h -main.o: idf.h -main.o: input.h -main.o: inputtype.h -main.o: level.h -main.o: lint.h -main.o: macro.h -main.o: nobitfield.h -main.o: nocross.h -main.o: nopp.h -main.o: proto.h -main.o: sizes.h -main.o: spec_arith.h -main.o: specials.h -main.o: tokenname.h -main.o: trgt_sizes.h -main.o: type.h -main.o: use_tmp.h -idf.o: LLlex.h -idf.o: Lpars.h -idf.o: align.h -idf.o: arith.h -idf.o: assert.h -idf.o: botch_free.h -idf.o: dbsymtab.h -idf.o: debug.h -idf.o: declar.h -idf.o: decspecs.h -idf.o: def.h -idf.o: file_info.h -idf.o: idf.h -idf.o: idfsize.h -idf.o: label.h -idf.o: level.h -idf.o: lint.h -idf.o: nobitfield.h -idf.o: nocross.h -idf.o: nopp.h -idf.o: nparams.h -idf.o: proto.h -idf.o: sizes.h -idf.o: spec_arith.h -idf.o: specials.h -idf.o: stack.h -idf.o: struct.h -idf.o: trgt_sizes.h -idf.o: type.h -declarator.o: Lpars.h -declarator.o: arith.h -declarator.o: botch_free.h -declarator.o: dbsymtab.h -declarator.o: debug.h -declarator.o: declar.h -declarator.o: def.h -declarator.o: expr.h -declarator.o: idf.h -declarator.o: label.h -declarator.o: level.h -declarator.o: lint.h -declarator.o: nobitfield.h -declarator.o: nocross.h -declarator.o: nopp.h -declarator.o: proto.h -declarator.o: sizes.h -declarator.o: spec_arith.h -declarator.o: trgt_sizes.h -declarator.o: type.h -decspecs.o: Lpars.h -decspecs.o: arith.h -decspecs.o: assert.h -decspecs.o: dbsymtab.h -decspecs.o: debug.h -decspecs.o: decspecs.h -decspecs.o: def.h -decspecs.o: level.h -decspecs.o: lint.h -decspecs.o: nobitfield.h -decspecs.o: spec_arith.h -decspecs.o: type.h -struct.o: LLlex.h -struct.o: Lpars.h -struct.o: align.h -struct.o: arith.h -struct.o: assert.h -struct.o: botch_free.h -struct.o: dbsymtab.h -struct.o: debug.h -struct.o: def.h -struct.o: field.h -struct.o: file_info.h -struct.o: idf.h -struct.o: level.h -struct.o: lint.h -struct.o: nobitfield.h -struct.o: nocross.h -struct.o: nopp.h -struct.o: proto.h -struct.o: sizes.h -struct.o: spec_arith.h -struct.o: stack.h -struct.o: struct.h -struct.o: trgt_sizes.h -struct.o: type.h -expr.o: LLlex.h -expr.o: Lpars.h -expr.o: arith.h -expr.o: assert.h -expr.o: botch_free.h -expr.o: dbsymtab.h -expr.o: debug.h -expr.o: declar.h -expr.o: decspecs.h -expr.o: def.h -expr.o: expr.h -expr.o: file_info.h -expr.o: idf.h -expr.o: label.h -expr.o: level.h -expr.o: lint.h -expr.o: nobitfield.h -expr.o: nocross.h -expr.o: nopp.h -expr.o: sizes.h -expr.o: spec_arith.h -expr.o: trgt_sizes.h -expr.o: type.h -expr.o: use_tmp.h -ch3.o: Lpars.h -ch3.o: arith.h -ch3.o: assert.h -ch3.o: dbsymtab.h -ch3.o: debug.h -ch3.o: def.h -ch3.o: expr.h -ch3.o: file_info.h -ch3.o: idf.h -ch3.o: label.h -ch3.o: lint.h -ch3.o: nobitfield.h -ch3.o: nopp.h -ch3.o: proto.h -ch3.o: spec_arith.h -ch3.o: struct.h -ch3.o: type.h -ch3bin.o: Lpars.h -ch3bin.o: arith.h -ch3bin.o: botch_free.h -ch3bin.o: dbsymtab.h -ch3bin.o: debug.h -ch3bin.o: expr.h -ch3bin.o: idf.h -ch3bin.o: label.h -ch3bin.o: lint.h -ch3bin.o: nobitfield.h -ch3bin.o: nocross.h -ch3bin.o: nopp.h -ch3bin.o: sizes.h -ch3bin.o: spec_arith.h -ch3bin.o: struct.h -ch3bin.o: trgt_sizes.h -ch3bin.o: type.h -cstoper.o: Lpars.h -cstoper.o: arith.h -cstoper.o: assert.h -cstoper.o: dbsymtab.h -cstoper.o: debug.h -cstoper.o: expr.h -cstoper.o: idf.h -cstoper.o: label.h -cstoper.o: nobitfield.h -cstoper.o: nocross.h -cstoper.o: nopp.h -cstoper.o: sizes.h -cstoper.o: spec_arith.h -cstoper.o: trgt_sizes.h -cstoper.o: type.h -fltcstoper.o: Lpars.h -fltcstoper.o: arith.h -fltcstoper.o: assert.h -fltcstoper.o: dbsymtab.h -fltcstoper.o: debug.h -fltcstoper.o: expr.h -fltcstoper.o: idf.h -fltcstoper.o: label.h -fltcstoper.o: nobitfield.h -fltcstoper.o: nocross.h -fltcstoper.o: nopp.h -fltcstoper.o: sizes.h -fltcstoper.o: spec_arith.h -fltcstoper.o: trgt_sizes.h -fltcstoper.o: type.h -arith.o: Lpars.h -arith.o: arith.h -arith.o: assert.h -arith.o: dbsymtab.h -arith.o: debug.h -arith.o: expr.h -arith.o: field.h -arith.o: idf.h -arith.o: label.h -arith.o: lint.h -arith.o: mes.h -arith.o: nobitfield.h -arith.o: nocross.h -arith.o: nopp.h -arith.o: proto.h -arith.o: sizes.h -arith.o: spec_arith.h -arith.o: trgt_sizes.h -arith.o: type.h -code.o: LLlex.h -code.o: Lpars.h -code.o: arith.h -code.o: assert.h -code.o: atw.h -code.o: botch_free.h -code.o: code.h -code.o: dataflow.h -code.o: dbsymtab.h -code.o: debug.h -code.o: declar.h -code.o: decspecs.h -code.o: def.h -code.o: expr.h -code.o: file_info.h -code.o: idf.h -code.o: l_em.h -code.o: l_lint.h -code.o: label.h -code.o: level.h -code.o: lint.h -code.o: nobitfield.h -code.o: nocross.h -code.o: nopp.h -code.o: sizes.h -code.o: spec_arith.h -code.o: specials.h -code.o: stack.h -code.o: stmt.h -code.o: trgt_sizes.h -code.o: type.h -code.o: use_tmp.h -dumpidf.o: Lpars.h -dumpidf.o: arith.h -dumpidf.o: dbsymtab.h -dumpidf.o: debug.h -dumpidf.o: declar.h -dumpidf.o: def.h -dumpidf.o: expr.h -dumpidf.o: field.h -dumpidf.o: idf.h -dumpidf.o: label.h -dumpidf.o: lint.h -dumpidf.o: nobitfield.h -dumpidf.o: nopp.h -dumpidf.o: proto.h -dumpidf.o: spec_arith.h -dumpidf.o: stack.h -dumpidf.o: static.h -dumpidf.o: struct.h -dumpidf.o: type.h -error.o: LLlex.h -error.o: arith.h -error.o: debug.h -error.o: def.h -error.o: errout.h -error.o: expr.h -error.o: file_info.h -error.o: l_em.h -error.o: label.h -error.o: lint.h -error.o: nopp.h -error.o: spec_arith.h -error.o: tokenname.h -field.o: Lpars.h -field.o: align.h -field.o: arith.h -field.o: assert.h -field.o: code.h -field.o: dbsymtab.h -field.o: debug.h -field.o: expr.h -field.o: field.h -field.o: idf.h -field.o: label.h -field.o: lint.h -field.o: nobitfield.h -field.o: nocross.h -field.o: nopp.h -field.o: sizes.h -field.o: spec_arith.h -field.o: trgt_sizes.h -field.o: type.h -tokenname.o: LLlex.h -tokenname.o: Lpars.h -tokenname.o: arith.h -tokenname.o: file_info.h -tokenname.o: idf.h -tokenname.o: nopp.h -tokenname.o: spec_arith.h -tokenname.o: tokenname.h -LLlex.o: LLlex.h -LLlex.o: Lpars.h -LLlex.o: arith.h -LLlex.o: assert.h -LLlex.o: class.h -LLlex.o: debug.h -LLlex.o: def.h -LLlex.o: file_info.h -LLlex.o: idf.h -LLlex.o: idfsize.h -LLlex.o: input.h -LLlex.o: lint.h -LLlex.o: macro.h -LLlex.o: nocross.h -LLlex.o: nopp.h -LLlex.o: numsize.h -LLlex.o: sizes.h -LLlex.o: spec_arith.h -LLlex.o: strsize.h -LLlex.o: trgt_sizes.h -LLmessage.o: LLlex.h -LLmessage.o: Lpars.h -LLmessage.o: arith.h -LLmessage.o: file_info.h -LLmessage.o: idf.h -LLmessage.o: nopp.h -LLmessage.o: spec_arith.h -input.o: dbsymtab.h -input.o: file_info.h -input.o: input.h -input.o: inputtype.h -input.o: nopp.h -domacro.o: LLlex.h -domacro.o: Lpars.h -domacro.o: arith.h -domacro.o: assert.h -domacro.o: botch_free.h -domacro.o: class.h -domacro.o: dbsymtab.h -domacro.o: debug.h -domacro.o: file_info.h -domacro.o: idf.h -domacro.o: idfsize.h -domacro.o: ifdepth.h -domacro.o: input.h -domacro.o: macbuf.h -domacro.o: macro.h -domacro.o: nopp.h -domacro.o: nparams.h -domacro.o: parbufsize.h -domacro.o: replace.h -domacro.o: spec_arith.h -domacro.o: textsize.h -replace.o: LLlex.h -replace.o: arith.h -replace.o: assert.h -replace.o: class.h -replace.o: debug.h -replace.o: file_info.h -replace.o: idf.h -replace.o: idfsize.h -replace.o: input.h -replace.o: macbuf.h -replace.o: macro.h -replace.o: nopp.h -replace.o: nparams.h -replace.o: numsize.h -replace.o: pathlength.h -replace.o: replace.h -replace.o: spec_arith.h -replace.o: static.h -replace.o: strsize.h -init.o: class.h -init.o: idf.h -init.o: macro.h -init.o: nopp.h -options.o: align.h -options.o: arith.h -options.o: botch_free.h -options.o: class.h -options.o: dataflow.h -options.o: dbsymtab.h -options.o: idf.h -options.o: idfsize.h -options.o: lint.h -options.o: macro.h -options.o: nobitfield.h -options.o: nocross.h -options.o: nopp.h -options.o: sizes.h -options.o: spec_arith.h -options.o: trgt_sizes.h -options.o: use_tmp.h -skip.o: LLlex.h -skip.o: arith.h -skip.o: class.h -skip.o: file_info.h -skip.o: input.h -skip.o: nopp.h -skip.o: spec_arith.h -stack.o: Lpars.h -stack.o: arith.h -stack.o: botch_free.h -stack.o: dbsymtab.h -stack.o: debug.h -stack.o: def.h -stack.o: idf.h -stack.o: l_em.h -stack.o: level.h -stack.o: lint.h -stack.o: mes.h -stack.o: nobitfield.h -stack.o: nopp.h -stack.o: spec_arith.h -stack.o: stack.h -stack.o: struct.h -stack.o: type.h -type.o: Lpars.h -type.o: align.h -type.o: arith.h -type.o: botch_free.h -type.o: dbsymtab.h -type.o: debug.h -type.o: decspecs.h -type.o: def.h -type.o: idf.h -type.o: lint.h -type.o: nobitfield.h -type.o: nocross.h -type.o: nopp.h -type.o: proto.h -type.o: sizes.h -type.o: spec_arith.h -type.o: trgt_sizes.h -type.o: type.h -ch3mon.o: Lpars.h -ch3mon.o: arith.h -ch3mon.o: botch_free.h -ch3mon.o: dbsymtab.h -ch3mon.o: debug.h -ch3mon.o: def.h -ch3mon.o: expr.h -ch3mon.o: idf.h -ch3mon.o: label.h -ch3mon.o: lint.h -ch3mon.o: nobitfield.h -ch3mon.o: nocross.h -ch3mon.o: nopp.h -ch3mon.o: sizes.h -ch3mon.o: spec_arith.h -ch3mon.o: trgt_sizes.h -ch3mon.o: type.h -label.o: Lpars.h -label.o: arith.h -label.o: dbsymtab.h -label.o: def.h -label.o: idf.h -label.o: label.h -label.o: level.h -label.o: lint.h -label.o: nobitfield.h -label.o: nopp.h -label.o: spec_arith.h -label.o: type.h -eval.o: Lpars.h -eval.o: align.h -eval.o: arith.h -eval.o: assert.h -eval.o: atw.h -eval.o: code.h -eval.o: dataflow.h -eval.o: dbsymtab.h -eval.o: debug.h -eval.o: def.h -eval.o: expr.h -eval.o: idf.h -eval.o: label.h -eval.o: level.h -eval.o: lint.h -eval.o: mes.h -eval.o: nobitfield.h -eval.o: nocross.h -eval.o: nopp.h -eval.o: sizes.h -eval.o: spec_arith.h -eval.o: specials.h -eval.o: stack.h -eval.o: trgt_sizes.h -eval.o: type.h -switch.o: Lpars.h -switch.o: arith.h -switch.o: assert.h -switch.o: botch_free.h -switch.o: code.h -switch.o: dbsymtab.h -switch.o: debug.h -switch.o: density.h -switch.o: expr.h -switch.o: idf.h -switch.o: l_em.h -switch.o: label.h -switch.o: lint.h -switch.o: nobitfield.h -switch.o: nocross.h -switch.o: nopp.h -switch.o: sizes.h -switch.o: spec_arith.h -switch.o: switch.h -switch.o: trgt_sizes.h -switch.o: type.h -conversion.o: Lpars.h -conversion.o: arith.h -conversion.o: dbsymtab.h -conversion.o: lint.h -conversion.o: nobitfield.h -conversion.o: nocross.h -conversion.o: sizes.h -conversion.o: spec_arith.h -conversion.o: trgt_sizes.h -conversion.o: type.h -util.o: Lpars.h -util.o: align.h -util.o: debug.h -util.o: def.h -util.o: l_em.h -util.o: lint.h -util.o: nocross.h -util.o: regcount.h -util.o: sizes.h -util.o: stack.h -util.o: trgt_sizes.h -util.o: use_tmp.h -util.o: util.h -proto.o: Lpars.h -proto.o: align.h -proto.o: arith.h -proto.o: assert.h -proto.o: botch_free.h -proto.o: dbsymtab.h -proto.o: debug.h -proto.o: declar.h -proto.o: decspecs.h -proto.o: def.h -proto.o: expr.h -proto.o: idf.h -proto.o: idfsize.h -proto.o: label.h -proto.o: level.h -proto.o: lint.h -proto.o: nobitfield.h -proto.o: nocross.h -proto.o: nopp.h -proto.o: nparams.h -proto.o: proto.h -proto.o: spec_arith.h -proto.o: stack.h -proto.o: struct.h -proto.o: trgt_sizes.h -proto.o: type.h -pragma.o: debug.h -pragma.o: idf.h -pragma.o: nopp.h -blocks.o: Lpars.h -blocks.o: align.h -blocks.o: arith.h -blocks.o: atw.h -blocks.o: label.h -blocks.o: lint.h -blocks.o: nocross.h -blocks.o: sizes.h -blocks.o: spec_arith.h -blocks.o: stack.h -blocks.o: trgt_sizes.h -dataflow.o: dataflow.h -stab.o: LLlex.h -stab.o: Lpars.h -stab.o: dbsymtab.h -stab.o: def.h -stab.o: field.h -stab.o: file_info.h -stab.o: idf.h -stab.o: level.h -stab.o: lint.h -stab.o: nobitfield.h -stab.o: nopp.h -stab.o: stack.h -stab.o: struct.h -stab.o: type.h -l_lint.o: LLlex.h -l_lint.o: Lpars.h -l_lint.o: arith.h -l_lint.o: assert.h -l_lint.o: code.h -l_lint.o: dbsymtab.h -l_lint.o: debug.h -l_lint.o: def.h -l_lint.o: expr.h -l_lint.o: file_info.h -l_lint.o: idf.h -l_lint.o: interface.h -l_lint.o: l_lint.h -l_lint.o: l_outdef.h -l_lint.o: l_state.h -l_lint.o: label.h -l_lint.o: level.h -l_lint.o: lint.h -l_lint.o: nobitfield.h -l_lint.o: nopp.h -l_lint.o: spec_arith.h -l_lint.o: stack.h -l_lint.o: type.h -l_states.o: LLlex.h -l_states.o: Lpars.h -l_states.o: arith.h -l_states.o: assert.h -l_states.o: code.h -l_states.o: dbsymtab.h -l_states.o: debug.h -l_states.o: def.h -l_states.o: expr.h -l_states.o: file_info.h -l_states.o: idf.h -l_states.o: interface.h -l_states.o: l_brace.h -l_states.o: l_comment.h -l_states.o: l_lint.h -l_states.o: l_outdef.h -l_states.o: l_state.h -l_states.o: label.h -l_states.o: level.h -l_states.o: lint.h -l_states.o: nobitfield.h -l_states.o: nopp.h -l_states.o: spec_arith.h -l_states.o: stack.h -l_states.o: type.h -l_misc.o: LLlex.h -l_misc.o: Lpars.h -l_misc.o: arith.h -l_misc.o: code.h -l_misc.o: dbsymtab.h -l_misc.o: def.h -l_misc.o: expr.h -l_misc.o: file_info.h -l_misc.o: idf.h -l_misc.o: interface.h -l_misc.o: l_state.h -l_misc.o: label.h -l_misc.o: level.h -l_misc.o: lint.h -l_misc.o: nobitfield.h -l_misc.o: nopp.h -l_misc.o: spec_arith.h -l_misc.o: stack.h -l_misc.o: type.h -l_ev_ord.o: LLlex.h -l_ev_ord.o: Lpars.h -l_ev_ord.o: arith.h -l_ev_ord.o: assert.h -l_ev_ord.o: code.h -l_ev_ord.o: dbsymtab.h -l_ev_ord.o: debug.h -l_ev_ord.o: def.h -l_ev_ord.o: expr.h -l_ev_ord.o: file_info.h -l_ev_ord.o: idf.h -l_ev_ord.o: interface.h -l_ev_ord.o: l_lint.h -l_ev_ord.o: l_state.h -l_ev_ord.o: label.h -l_ev_ord.o: level.h -l_ev_ord.o: lint.h -l_ev_ord.o: nobitfield.h -l_ev_ord.o: nopp.h -l_ev_ord.o: spec_arith.h -l_ev_ord.o: stack.h -l_ev_ord.o: type.h -l_outdef.o: LLlex.h -l_outdef.o: Lpars.h -l_outdef.o: arith.h -l_outdef.o: assert.h -l_outdef.o: code.h -l_outdef.o: dbsymtab.h -l_outdef.o: debug.h -l_outdef.o: declar.h -l_outdef.o: decspecs.h -l_outdef.o: def.h -l_outdef.o: expr.h -l_outdef.o: field.h -l_outdef.o: file_info.h -l_outdef.o: idf.h -l_outdef.o: interface.h -l_outdef.o: l_class.h -l_outdef.o: l_comment.h -l_outdef.o: l_lint.h -l_outdef.o: l_outdef.h -l_outdef.o: label.h -l_outdef.o: level.h -l_outdef.o: lint.h -l_outdef.o: nobitfield.h -l_outdef.o: nopp.h -l_outdef.o: spec_arith.h -l_outdef.o: stack.h -l_outdef.o: struct.h -l_outdef.o: type.h -l_comment.o: arith.h -l_comment.o: interface.h -l_comment.o: l_comment.h -l_comment.o: l_state.h -l_comment.o: lint.h -l_comment.o: spec_arith.h -tokenfile.o: Lpars.h -declar.o: LLlex.h -declar.o: Lpars.h -declar.o: arith.h -declar.o: code.h -declar.o: dbsymtab.h -declar.o: debug.h -declar.o: declar.h -declar.o: decspecs.h -declar.o: def.h -declar.o: expr.h -declar.o: field.h -declar.o: file_info.h -declar.o: idf.h -declar.o: l_lint.h -declar.o: label.h -declar.o: level.h -declar.o: lint.h -declar.o: nobitfield.h -declar.o: nocross.h -declar.o: nopp.h -declar.o: proto.h -declar.o: sizes.h -declar.o: spec_arith.h -declar.o: struct.h -declar.o: trgt_sizes.h -declar.o: type.h -statement.o: LLlex.h -statement.o: Lpars.h -statement.o: arith.h -statement.o: botch_free.h -statement.o: code.h -statement.o: dbsymtab.h -statement.o: debug.h -statement.o: def.h -statement.o: expr.h -statement.o: file_info.h -statement.o: idf.h -statement.o: l_em.h -statement.o: l_lint.h -statement.o: label.h -statement.o: lint.h -statement.o: nobitfield.h -statement.o: nopp.h -statement.o: spec_arith.h -statement.o: stack.h -statement.o: type.h -expression.o: LLlex.h -expression.o: Lpars.h -expression.o: arith.h -expression.o: code.h -expression.o: dbsymtab.h -expression.o: debug.h -expression.o: expr.h -expression.o: file_info.h -expression.o: idf.h -expression.o: label.h -expression.o: lint.h -expression.o: nobitfield.h -expression.o: nocross.h -expression.o: nopp.h -expression.o: sizes.h -expression.o: spec_arith.h -expression.o: trgt_sizes.h -expression.o: type.h -program.o: LLlex.h -program.o: Lpars.h -program.o: arith.h -program.o: code.h -program.o: dbsymtab.h -program.o: debug.h -program.o: declar.h -program.o: decspecs.h -program.o: def.h -program.o: expr.h -program.o: file_info.h -program.o: idf.h -program.o: l_lint.h -program.o: label.h -program.o: lint.h -program.o: nobitfield.h -program.o: nopp.h -program.o: spec_arith.h -program.o: type.h -Lpars.o: Lpars.h -ival.o: LLlex.h -ival.o: Lpars.h -ival.o: arith.h -ival.o: assert.h -ival.o: dbsymtab.h -ival.o: debug.h -ival.o: def.h -ival.o: estack.h -ival.o: expr.h -ival.o: field.h -ival.o: file_info.h -ival.o: idf.h -ival.o: l_em.h -ival.o: l_lint.h -ival.o: label.h -ival.o: level.h -ival.o: lint.h -ival.o: nobitfield.h -ival.o: nocross.h -ival.o: nopp.h -ival.o: proto.h -ival.o: sizes.h -ival.o: spec_arith.h -ival.o: struct.h -ival.o: trgt_sizes.h -ival.o: type.h -char.o: class.h -symbol2str.o: Lpars.h -next.o: debug.h +distr: + echo '#ifndef lint' > Version.c + echo 'char Version[] = "ACK ANSI C compiler Version XXX";' | \ + sed "s/XXX/`RC -i`/" >> Version.c + echo '#endif lint' >> Version.c diff --git a/lang/cem/cemcom/Makefile b/lang/cem/cemcom/Makefile index b87df0140..f08fdd212 100644 --- a/lang/cem/cemcom/Makefile +++ b/lang/cem/cemcom/Makefile @@ -1,1026 +1,5 @@ -# $Header$ -# M A K E F I L E F O R A C K C - C O M P I L E R - -# Machine and environ dependent definitions -EMHOME = ../../.. -MKDEP = $(EMHOME)/bin/mkdep -PRID = $(EMHOME)/bin/prid -CID = $(EMHOME)/bin/cid - -# Libraries and EM interface definitions -SYSLIB = $(EMHOME)/modules/lib/libsystem.a -EMKLIB = $(EMHOME)/modules/lib/libemk.a $(EMHOME)/lib/em_data.a -EMELIB = $(EMHOME)/modules/lib/libeme.a $(EMHOME)/lib/em_data.a -STRLIB = $(EMHOME)/modules/lib/libstring.a -PRTLIB = $(EMHOME)/modules/lib/libprint.a -EMMESLIB = $(EMHOME)/modules/lib/libem_mes.a -EMMESOLIB = $(EMHOME)/modules/lib/libem_mesO.a -EMMESCELIB = $(EMHOME)/modules/lib/libem_mesCE.a -MACH = sun3 -EMCELIB = $(EMHOME)/lib/$(MACH)/ce.a \ - $(EMHOME)/lib/$(MACH)/back.a \ - $(EMHOME)/modules/lib/libflt.a \ - $(EMHOME)/modules/lib/libobject.a $(EMHOME)/lib/em_data.a -EMOCELIB = $(EMHOME)/modules/lib/libCEopt.a $(EMHOME)/lib/$(MACH)/ce.a \ - $(EMHOME)/lib/$(MACH)/back.a \ - $(EMHOME)/modules/lib/libflt.a \ - $(EMHOME)/modules/lib/libobject.a $(EMHOME)/lib/em_data.a -INPLIB = $(EMHOME)/modules/lib/libinput.a -ALLOCLIB = $(EMHOME)/modules/lib/liballoc.a -MALLOC = $(EMHOME)/modules/lib/malloc.o -LIBS = $(INPLIB) $(EMMESLIB) $(EMKLIB) $(PRTLIB) $(STRLIB) \ - $(ALLOCLIB) $(MALLOC) $(SYSLIB) -ELIBS = $(INPLIB) $(EMMESLIB) $(EMELIB) $(PRTLIB) $(STRLIB) \ - $(ALLOCLIB) $(MALLOC) $(SYSLIB) -OLIBS = $(INPLIB) $(EMMESOLIB) $(EMOCELIB) $(PRTLIB) $(STRLIB) \ - $(ALLOCLIB) $(MALLOC) $(SYSLIB) -CELIBS = $(INPLIB) $(EMMESCELIB) $(EMCELIB) $(PRTLIB) $(STRLIB) \ - $(ALLOCLIB) $(MALLOC) $(SYSLIB) -LLIBS = $(INPLIB) $(EMMESLIB) $(PRTLIB) $(STRLIB) \ - $(ALLOCLIB) $(MALLOC) $(SYSLIB) -LIB_INCLUDES = -I$(EMHOME)/modules/h -I$(EMHOME)/modules/pkg -EM_INCLUDES = -I$(EMHOME)/h -SYSLLIB = $(EMHOME)/modules/lib/llib-lsystem.ln -EMKLLIB = $(EMHOME)/modules/lib/llib-lemk.ln -EMELLIB = $(EMHOME)/modules/lib/llib-leme.ln -STRLLIB = $(EMHOME)/modules/lib/llib-lstring.ln -PRTLLIB = $(EMHOME)/modules/lib/llib-lprint.ln -EMMESLLIB = $(EMHOME)/modules/lib/llib-lem_mes.ln -INPLLIB = $(EMHOME)/modules/lib/llib-linput.ln -ALLOCLLIB = $(EMHOME)/modules/lib/llib-lalloc.ln -#LINTLIBS = -LINTLIBS = $(EMMESLLIB) $(EMKLLIB) $(PRTLLIB) $(STRLLIB) $(ALLOCLLIB) $(SYSLLIB) -CURRDIR = - -COPTIONS = - -# What parser generator to use and how -GEN = $(EMHOME)/bin/LLgen -GENOPTIONS = -v - -# tabgen -TABGEN = $(EMHOME)/bin/tabgen - -# Special #defines during compilation -PROF = #-pg -CDEFS = $(EM_INCLUDES) $(LIB_INCLUDES) -CFLAGS = $(CDEFS) $(COPTIONS) -O $(PROF) -LDFLAGS = $(PROF) - -# Grammar files and their objects -LSRC = tokenfile.g declar.g statement.g expression.g program.g ival.g -LCSRC = tokenfile.c declar.c statement.c expression.c program.c Lpars.c ival.c -LOBJ = tokenfile.o declar.o statement.o expression.o program.o Lpars.o ival.o - -# Objects of hand-written C files -CSRC = main.c idf.c declarator.c decspecs.c struct.c \ - expr.c ch7.c ch7bin.c cstoper.c arith.c \ - asm.c code.c dumpidf.c error.c field.c\ - tokenname.c LLlex.c LLmessage.c \ - input.c domacro.c replace.c init.c options.c \ - scan.c skip.c stack.c type.c ch7mon.c label.c eval.c \ - switch.c conversion.c util.c \ - blocks.c dataflow.c Version.c \ - l_lint.c l_states.c l_misc.c l_ev_ord.c l_outdef.c l_comment.c -COBJ = main.o idf.o declarator.o decspecs.o struct.o \ - expr.o ch7.o ch7bin.o cstoper.o arith.o \ - asm.o code.o dumpidf.o error.o field.o\ - tokenname.o LLlex.o LLmessage.o \ - input.o domacro.o replace.o init.o options.o \ - scan.o skip.o stack.o type.o ch7mon.o label.o eval.o \ - switch.o conversion.o util.o \ - blocks.o dataflow.o Version.o \ - l_lint.o l_states.o l_misc.o l_ev_ord.o l_outdef.o l_comment.o - -# Objects of other generated C files -GCSRC = char.c symbol2str.c next.c -GOBJ = char.o symbol2str.o next.o - -# Extra object for generating peephole-optimizer-code-expander version. -# The Sun-3 version is faster when the text-size exceeds 180K! ARRGH -EXTRA_O = - -STRSRC = code.str declar.str decspecs.str def.str expr.str field.str \ - estack.str util.str \ - idf.str macro.str stack.str stmt.str struct.str switch.str type.str \ - l_brace.str l_state.str l_outdef.str -# generated source files -GHSTRSRC = code.h declar.h decspecs.h def.h expr.h field.h \ - estack.h util.h \ - idf.h macro.h stack.h stmt.h struct.h switch.h type.h \ - l_brace.h l_state.h l_outdef.h -GSRC = $(GCSRC) $(GHSTRSRC) - -# .h files generated by `make hfiles LLfiles'; PLEASE KEEP THIS UP-TO-DATE! -GHSRC = botch_free.h dataflow.h debug.h density.h errout.h \ - idfsize.h ifdepth.h inputtype.h lapbuf.h lint.h \ - nobitfield.h nofloat.h nopp.h noRoption.h nocross.h \ - nparams.h numsize.h parbufsize.h pathlength.h Lpars.h \ - strsize.h target_sizes.h textsize.h use_tmp.h spec_arith.h static.h \ - regcount.h - -HSRC = LLlex.h align.h arith.h assert.h atw.h class.h \ - input.h interface.h label.h level.h mes.h sizes.h specials.h \ - file_info.h tokenname.h l_em.h l_lint.h - -HFILES = $(HSRC) $(GHSRC) $(GHSTRSRC) - -# generated files, for 'make clean' only -GENERATED = tokenfile.g Lpars.h LLfiles LL.output lint.out \ - print hfiles Cfiles $(GHSRC) $(GSRC) longnames $(LCSRC) - -OBJ = $(COBJ) $(LOBJ) $(GOBJ) $(EXTRA_O) -SRC = $(CSRC) $(LCSRC) $(GCSRC) - -LINT = /usr/bin/lint -LINTFLAGS = - -#EXCLEXCLEXCLEXCL - -.SUFFIXES: .str .h -.str.h: - ./make.allocd <$*.str >$*.h - -Main: Cfiles - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "EMHOME="$(EMHOME) $(CURRDIR)main ; else EMHOME=$(EMHOME); export EMHOME; ./Resolve main ; fi' - @rm -f nmclash.o a.out - -Emain: Cfiles - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "EMHOME="$(EMHOME) $(CURRDIR)emain ; else EMHOME=$(EMHOME); export EMHOME; ./Resolve emain ; fi' - @rm -f nmclash.o a.out - -Omain: Cfiles - rm -f *.o - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "MACH="$(MACH) "EMHOME="$(EMHOME) "COPTIONS="-DPEEPHOLE "EXTRA_O="$(EXTRA_O) $(CURRDIR)omain ; else mach=$(MACH); export mach; EMHOME=$(EMHOME); export EMHOME; ./Resolve omain ; fi' - @rm -f nmclash.o a.out - -CEmain: Cfiles - rm -f *.o - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "MACH="$(MACH) "EMHOME="$(EMHOME) "COPTIONS="-DCODE_EXPANDER $(CURRDIR)cemain ; else mach=$(MACH); export mach; EMHOME=$(EMHOME); export EMHOME; ./Resolve cemain ; fi' - @rm -f nmclash.o a.out - -Lnt: Cfiles - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "EMHOME="$(EMHOME) $(CURRDIR)lnt ; else EMHOME=$(EMHOME); export EMHOME; ./Resolve lnt ; fi' - @rm -f nmclash.o a.out - -install: Main - rm -f $(EMHOME)/lib/em_cemcom $(EMHOME)/man/em_cemcom.6 - cp $(CURRDIR)main $(EMHOME)/lib/em_cemcom - cp $(CURRDIR)cemcom.1 $(EMHOME)/man/em_cemcom.6 - -cmp: Main - -cmp $(CURRDIR)main $(EMHOME)/lib/em_cemcom - -cmp $(CURRDIR)cemcom.1 $(EMHOME)/man/em_cemcom.6 - -pr: - @pr Makefile make.* char.tab Parameters $(HSRC) $(STRSRC) $(LSRC) $(CSRC) - -opr: - make pr | opr - -clean: - rm -f $(OBJ) - rm -f $(GENERATED) main - (cd .. ; rm -rf Xsrc) - -lint: Cfiles - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "EMHOME="$(EMHOME) LINT=$(LINT) Xlint ; else sh Resolve Xlint ; fi' - @rm -f nmclash.o a.out - -longnames: $(SRC) $(HFILES) - sh -c 'if test -f longnames ; then : ; else touch longnames ; fi ; $(PRID) -l7 longnames $? > Xlongnames ; mv Xlongnames longnames' - -# entry points not to be used directly - -Cfiles: hfiles LLfiles $(GENCFILES) $(GSRC) $(GHSRC) Makefile - echo $(SRC) $(HFILES) > Cfiles - -hfiles: ./make.hfiles Parameters - ./make.hfiles Parameters - @touch hfiles - -LLfiles: $(LSRC) - $(GEN) $(GENOPTIONS) $(LSRC) - @touch LLfiles - -tokenfile.g: tokenname.c make.tokfile - tokenfile.g - -symbol2str.c: tokenname.c make.tokcase - symbol2str.c - -char.c: char.tab - $(TABGEN) -fchar.tab >char.c - -next.c: make.next $(STRSRC) - ./make.next $(STRSRC) >next.c - -code.h: make.allocd -declar.h: make.allocd -decspecs.h: make.allocd -def.h: make.allocd -expr.h: make.allocd -field.h: make.allocd -idf.h: make.allocd -macro.h: make.allocd -stack.h: make.allocd -stmt.h: make.allocd -struct.h: make.allocd -switch.h: make.allocd -type.h: make.allocd -estack.h: make.allocd -util.h: make.allocd -l_brace.h: make.allocd -l_state.h: make.allocd -l_outdef.h: make.allocd - -depend: Cfiles - sed '/^#AUTOAUTO/,$$d' Makefile >Makefile.new - echo '#AUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTO' >>Makefile.new - $(MKDEP) $(SRC) | sed 's/\.c:/.o:/' >>Makefile.new - mv Makefile Makefile.old - mv Makefile.new Makefile - -#INCLINCLINCLINCL - -$(CURRDIR)main: $(OBJ) $(CURRDIR)Makefile - $(CC) $(COPTIONS) $(LDFLAGS) $(OBJ) $(LIBS) -o $(CURRDIR)main - size $(CURRDIR)main - -$(CURRDIR)emain: $(OBJ) $(CURRDIR)Makefile - $(CC) $(COPTIONS) $(LDFLAGS) $(OBJ) $(ELIBS) -o $(CURRDIR)emain - size $(CURRDIR)emain - -$(CURRDIR)omain: $(OBJ) $(CURRDIR)Makefile - $(CC) $(COPTIONS) $(LDFLAGS) $(OBJ) $(OLIBS) -o $(CURRDIR)omain - size $(CURRDIR)omain - -$(CURRDIR)cemain: $(OBJ) $(CURRDIR)Makefile - $(CC) $(COPTIONS) $(LDFLAGS) $(OBJ) $(CELIBS) -o $(CURRDIR)cemain - size $(CURRDIR)cemain - -$(CURRDIR)lnt: $(OBJ) $(CURRDIR)Makefile - $(CC) $(COPTIONS) $(LDFLAGS) $(OBJ) $(LLIBS) -o $(CURRDIR)lnt - size $(CURRDIR)lnt - -Xlint: $(SRC) - $(LINT) $(CDEFS) $(LINTFLAGS) $(SRC) - - -#AUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTO -main.o: LLlex.h -main.o: Lpars.h -main.o: align.h -main.o: arith.h -main.o: assert.h -main.o: debug.h -main.o: declar.h -main.o: file_info.h -main.o: idf.h -main.o: input.h -main.o: inputtype.h -main.o: level.h -main.o: lint.h -main.o: macro.h -main.o: noRoption.h -main.o: nobitfield.h -main.o: nocross.h -main.o: nofloat.h -main.o: nopp.h -main.o: sizes.h -main.o: spec_arith.h -main.o: specials.h -main.o: target_sizes.h -main.o: tokenname.h -main.o: type.h -main.o: use_tmp.h -idf.o: LLlex.h -idf.o: Lpars.h -idf.o: align.h -idf.o: arith.h -idf.o: assert.h -idf.o: botch_free.h -idf.o: debug.h -idf.o: declar.h -idf.o: decspecs.h -idf.o: def.h -idf.o: file_info.h -idf.o: idf.h -idf.o: idfsize.h -idf.o: label.h -idf.o: level.h -idf.o: lint.h -idf.o: noRoption.h -idf.o: nobitfield.h -idf.o: nocross.h -idf.o: nofloat.h -idf.o: nopp.h -idf.o: sizes.h -idf.o: spec_arith.h -idf.o: specials.h -idf.o: stack.h -idf.o: struct.h -idf.o: target_sizes.h -idf.o: type.h -declarator.o: Lpars.h -declarator.o: arith.h -declarator.o: botch_free.h -declarator.o: declar.h -declarator.o: expr.h -declarator.o: idf.h -declarator.o: label.h -declarator.o: nobitfield.h -declarator.o: nocross.h -declarator.o: nofloat.h -declarator.o: nopp.h -declarator.o: sizes.h -declarator.o: spec_arith.h -declarator.o: target_sizes.h -declarator.o: type.h -decspecs.o: Lpars.h -decspecs.o: arith.h -decspecs.o: assert.h -decspecs.o: debug.h -decspecs.o: decspecs.h -decspecs.o: def.h -decspecs.o: level.h -decspecs.o: lint.h -decspecs.o: noRoption.h -decspecs.o: nobitfield.h -decspecs.o: nofloat.h -decspecs.o: spec_arith.h -decspecs.o: type.h -struct.o: LLlex.h -struct.o: Lpars.h -struct.o: align.h -struct.o: arith.h -struct.o: assert.h -struct.o: botch_free.h -struct.o: debug.h -struct.o: def.h -struct.o: field.h -struct.o: file_info.h -struct.o: idf.h -struct.o: level.h -struct.o: lint.h -struct.o: noRoption.h -struct.o: nobitfield.h -struct.o: nocross.h -struct.o: nofloat.h -struct.o: nopp.h -struct.o: sizes.h -struct.o: spec_arith.h -struct.o: stack.h -struct.o: struct.h -struct.o: target_sizes.h -struct.o: type.h -expr.o: LLlex.h -expr.o: Lpars.h -expr.o: arith.h -expr.o: botch_free.h -expr.o: declar.h -expr.o: decspecs.h -expr.o: def.h -expr.o: expr.h -expr.o: file_info.h -expr.o: idf.h -expr.o: label.h -expr.o: level.h -expr.o: lint.h -expr.o: noRoption.h -expr.o: nobitfield.h -expr.o: nocross.h -expr.o: nofloat.h -expr.o: nopp.h -expr.o: sizes.h -expr.o: spec_arith.h -expr.o: target_sizes.h -expr.o: type.h -expr.o: use_tmp.h -ch7.o: Lpars.h -ch7.o: arith.h -ch7.o: assert.h -ch7.o: debug.h -ch7.o: def.h -ch7.o: expr.h -ch7.o: idf.h -ch7.o: label.h -ch7.o: lint.h -ch7.o: nobitfield.h -ch7.o: nofloat.h -ch7.o: nopp.h -ch7.o: spec_arith.h -ch7.o: struct.h -ch7.o: type.h -ch7bin.o: Lpars.h -ch7bin.o: arith.h -ch7bin.o: botch_free.h -ch7bin.o: expr.h -ch7bin.o: idf.h -ch7bin.o: label.h -ch7bin.o: lint.h -ch7bin.o: noRoption.h -ch7bin.o: nobitfield.h -ch7bin.o: nofloat.h -ch7bin.o: nopp.h -ch7bin.o: spec_arith.h -ch7bin.o: struct.h -ch7bin.o: type.h -cstoper.o: Lpars.h -cstoper.o: arith.h -cstoper.o: assert.h -cstoper.o: debug.h -cstoper.o: expr.h -cstoper.o: idf.h -cstoper.o: label.h -cstoper.o: nobitfield.h -cstoper.o: nocross.h -cstoper.o: nofloat.h -cstoper.o: nopp.h -cstoper.o: sizes.h -cstoper.o: spec_arith.h -cstoper.o: target_sizes.h -cstoper.o: type.h -arith.o: Lpars.h -arith.o: arith.h -arith.o: expr.h -arith.o: field.h -arith.o: idf.h -arith.o: label.h -arith.o: lint.h -arith.o: mes.h -arith.o: noRoption.h -arith.o: nobitfield.h -arith.o: nofloat.h -arith.o: nopp.h -arith.o: spec_arith.h -arith.o: type.h -code.o: Lpars.h -code.o: arith.h -code.o: assert.h -code.o: atw.h -code.o: botch_free.h -code.o: code.h -code.o: dataflow.h -code.o: debug.h -code.o: declar.h -code.o: decspecs.h -code.o: def.h -code.o: expr.h -code.o: file_info.h -code.o: idf.h -code.o: l_em.h -code.o: l_lint.h -code.o: label.h -code.o: level.h -code.o: lint.h -code.o: noRoption.h -code.o: nobitfield.h -code.o: nocross.h -code.o: nofloat.h -code.o: nopp.h -code.o: sizes.h -code.o: spec_arith.h -code.o: specials.h -code.o: stack.h -code.o: stmt.h -code.o: target_sizes.h -code.o: type.h -code.o: use_tmp.h -dumpidf.o: Lpars.h -dumpidf.o: arith.h -dumpidf.o: debug.h -dumpidf.o: def.h -dumpidf.o: expr.h -dumpidf.o: field.h -dumpidf.o: idf.h -dumpidf.o: label.h -dumpidf.o: lint.h -dumpidf.o: nobitfield.h -dumpidf.o: nofloat.h -dumpidf.o: nopp.h -dumpidf.o: spec_arith.h -dumpidf.o: stack.h -dumpidf.o: static.h -dumpidf.o: struct.h -dumpidf.o: type.h -error.o: LLlex.h -error.o: arith.h -error.o: debug.h -error.o: def.h -error.o: errout.h -error.o: expr.h -error.o: file_info.h -error.o: l_em.h -error.o: label.h -error.o: lint.h -error.o: nofloat.h -error.o: nopp.h -error.o: spec_arith.h -error.o: tokenname.h -field.o: Lpars.h -field.o: align.h -field.o: arith.h -field.o: assert.h -field.o: code.h -field.o: debug.h -field.o: expr.h -field.o: field.h -field.o: idf.h -field.o: label.h -field.o: lint.h -field.o: nobitfield.h -field.o: nocross.h -field.o: nofloat.h -field.o: nopp.h -field.o: sizes.h -field.o: spec_arith.h -field.o: target_sizes.h -field.o: type.h -tokenname.o: LLlex.h -tokenname.o: Lpars.h -tokenname.o: arith.h -tokenname.o: file_info.h -tokenname.o: idf.h -tokenname.o: nofloat.h -tokenname.o: nopp.h -tokenname.o: spec_arith.h -tokenname.o: tokenname.h -LLlex.o: LLlex.h -LLlex.o: Lpars.h -LLlex.o: arith.h -LLlex.o: assert.h -LLlex.o: class.h -LLlex.o: debug.h -LLlex.o: def.h -LLlex.o: file_info.h -LLlex.o: idf.h -LLlex.o: idfsize.h -LLlex.o: input.h -LLlex.o: lint.h -LLlex.o: nocross.h -LLlex.o: nofloat.h -LLlex.o: nopp.h -LLlex.o: numsize.h -LLlex.o: sizes.h -LLlex.o: spec_arith.h -LLlex.o: strsize.h -LLlex.o: target_sizes.h -LLmessage.o: LLlex.h -LLmessage.o: Lpars.h -LLmessage.o: arith.h -LLmessage.o: file_info.h -LLmessage.o: idf.h -LLmessage.o: nofloat.h -LLmessage.o: nopp.h -LLmessage.o: spec_arith.h -input.o: file_info.h -input.o: input.h -input.o: inputtype.h -input.o: nopp.h -domacro.o: LLlex.h -domacro.o: Lpars.h -domacro.o: arith.h -domacro.o: assert.h -domacro.o: botch_free.h -domacro.o: class.h -domacro.o: debug.h -domacro.o: file_info.h -domacro.o: idf.h -domacro.o: idfsize.h -domacro.o: ifdepth.h -domacro.o: input.h -domacro.o: interface.h -domacro.o: macro.h -domacro.o: nofloat.h -domacro.o: nopp.h -domacro.o: nparams.h -domacro.o: parbufsize.h -domacro.o: spec_arith.h -domacro.o: textsize.h -replace.o: LLlex.h -replace.o: arith.h -replace.o: assert.h -replace.o: class.h -replace.o: debug.h -replace.o: file_info.h -replace.o: idf.h -replace.o: input.h -replace.o: interface.h -replace.o: macro.h -replace.o: nofloat.h -replace.o: nopp.h -replace.o: pathlength.h -replace.o: spec_arith.h -replace.o: static.h -replace.o: strsize.h -init.o: class.h -init.o: idf.h -init.o: interface.h -init.o: macro.h -init.o: nopp.h -options.o: align.h -options.o: arith.h -options.o: botch_free.h -options.o: class.h -options.o: dataflow.h -options.o: idf.h -options.o: idfsize.h -options.o: lint.h -options.o: macro.h -options.o: noRoption.h -options.o: nobitfield.h -options.o: nocross.h -options.o: nofloat.h -options.o: nopp.h -options.o: sizes.h -options.o: spec_arith.h -options.o: target_sizes.h -options.o: use_tmp.h -scan.o: class.h -scan.o: file_info.h -scan.o: idf.h -scan.o: input.h -scan.o: interface.h -scan.o: lapbuf.h -scan.o: macro.h -scan.o: nopp.h -scan.o: nparams.h -skip.o: LLlex.h -skip.o: arith.h -skip.o: class.h -skip.o: file_info.h -skip.o: input.h -skip.o: interface.h -skip.o: nofloat.h -skip.o: nopp.h -skip.o: spec_arith.h -stack.o: Lpars.h -stack.o: arith.h -stack.o: botch_free.h -stack.o: debug.h -stack.o: def.h -stack.o: idf.h -stack.o: l_em.h -stack.o: level.h -stack.o: lint.h -stack.o: mes.h -stack.o: noRoption.h -stack.o: nobitfield.h -stack.o: nofloat.h -stack.o: nopp.h -stack.o: spec_arith.h -stack.o: stack.h -stack.o: struct.h -stack.o: type.h -type.o: Lpars.h -type.o: align.h -type.o: arith.h -type.o: botch_free.h -type.o: def.h -type.o: idf.h -type.o: lint.h -type.o: nobitfield.h -type.o: nocross.h -type.o: nofloat.h -type.o: nopp.h -type.o: sizes.h -type.o: spec_arith.h -type.o: target_sizes.h -type.o: type.h -ch7mon.o: Lpars.h -ch7mon.o: arith.h -ch7mon.o: botch_free.h -ch7mon.o: def.h -ch7mon.o: expr.h -ch7mon.o: idf.h -ch7mon.o: label.h -ch7mon.o: lint.h -ch7mon.o: nobitfield.h -ch7mon.o: nofloat.h -ch7mon.o: nopp.h -ch7mon.o: spec_arith.h -ch7mon.o: type.h -label.o: Lpars.h -label.o: arith.h -label.o: def.h -label.o: idf.h -label.o: label.h -label.o: level.h -label.o: lint.h -label.o: noRoption.h -label.o: nobitfield.h -label.o: nofloat.h -label.o: nopp.h -label.o: spec_arith.h -label.o: type.h -eval.o: Lpars.h -eval.o: align.h -eval.o: arith.h -eval.o: assert.h -eval.o: atw.h -eval.o: code.h -eval.o: dataflow.h -eval.o: debug.h -eval.o: def.h -eval.o: expr.h -eval.o: idf.h -eval.o: label.h -eval.o: level.h -eval.o: lint.h -eval.o: mes.h -eval.o: nobitfield.h -eval.o: nocross.h -eval.o: nofloat.h -eval.o: nopp.h -eval.o: sizes.h -eval.o: spec_arith.h -eval.o: specials.h -eval.o: stack.h -eval.o: target_sizes.h -eval.o: type.h -switch.o: Lpars.h -switch.o: arith.h -switch.o: assert.h -switch.o: botch_free.h -switch.o: code.h -switch.o: debug.h -switch.o: density.h -switch.o: expr.h -switch.o: idf.h -switch.o: l_em.h -switch.o: label.h -switch.o: lint.h -switch.o: noRoption.h -switch.o: nobitfield.h -switch.o: nofloat.h -switch.o: nopp.h -switch.o: spec_arith.h -switch.o: switch.h -switch.o: type.h -conversion.o: Lpars.h -conversion.o: arith.h -conversion.o: lint.h -conversion.o: nobitfield.h -conversion.o: nocross.h -conversion.o: nofloat.h -conversion.o: sizes.h -conversion.o: spec_arith.h -conversion.o: target_sizes.h -conversion.o: type.h -util.o: Lpars.h -util.o: align.h -util.o: def.h -util.o: l_em.h -util.o: lint.h -util.o: nocross.h -util.o: nofloat.h -util.o: regcount.h -util.o: sizes.h -util.o: stack.h -util.o: target_sizes.h -util.o: use_tmp.h -util.o: util.h -blocks.o: Lpars.h -blocks.o: align.h -blocks.o: arith.h -blocks.o: atw.h -blocks.o: label.h -blocks.o: lint.h -blocks.o: nocross.h -blocks.o: nofloat.h -blocks.o: sizes.h -blocks.o: spec_arith.h -blocks.o: stack.h -blocks.o: target_sizes.h -dataflow.o: dataflow.h -l_lint.o: LLlex.h -l_lint.o: Lpars.h -l_lint.o: arith.h -l_lint.o: assert.h -l_lint.o: code.h -l_lint.o: debug.h -l_lint.o: def.h -l_lint.o: expr.h -l_lint.o: file_info.h -l_lint.o: idf.h -l_lint.o: interface.h -l_lint.o: l_lint.h -l_lint.o: l_outdef.h -l_lint.o: l_state.h -l_lint.o: label.h -l_lint.o: level.h -l_lint.o: lint.h -l_lint.o: nobitfield.h -l_lint.o: nofloat.h -l_lint.o: nopp.h -l_lint.o: spec_arith.h -l_lint.o: stack.h -l_lint.o: type.h -l_states.o: LLlex.h -l_states.o: Lpars.h -l_states.o: arith.h -l_states.o: assert.h -l_states.o: code.h -l_states.o: debug.h -l_states.o: def.h -l_states.o: expr.h -l_states.o: file_info.h -l_states.o: idf.h -l_states.o: interface.h -l_states.o: l_brace.h -l_states.o: l_comment.h -l_states.o: l_lint.h -l_states.o: l_outdef.h -l_states.o: l_state.h -l_states.o: label.h -l_states.o: level.h -l_states.o: lint.h -l_states.o: nobitfield.h -l_states.o: nofloat.h -l_states.o: nopp.h -l_states.o: spec_arith.h -l_states.o: stack.h -l_states.o: type.h -l_misc.o: LLlex.h -l_misc.o: Lpars.h -l_misc.o: arith.h -l_misc.o: code.h -l_misc.o: def.h -l_misc.o: expr.h -l_misc.o: file_info.h -l_misc.o: idf.h -l_misc.o: interface.h -l_misc.o: l_state.h -l_misc.o: label.h -l_misc.o: level.h -l_misc.o: lint.h -l_misc.o: nobitfield.h -l_misc.o: nofloat.h -l_misc.o: nopp.h -l_misc.o: spec_arith.h -l_misc.o: stack.h -l_misc.o: type.h -l_ev_ord.o: LLlex.h -l_ev_ord.o: Lpars.h -l_ev_ord.o: arith.h -l_ev_ord.o: assert.h -l_ev_ord.o: code.h -l_ev_ord.o: debug.h -l_ev_ord.o: def.h -l_ev_ord.o: expr.h -l_ev_ord.o: file_info.h -l_ev_ord.o: idf.h -l_ev_ord.o: interface.h -l_ev_ord.o: l_lint.h -l_ev_ord.o: l_state.h -l_ev_ord.o: label.h -l_ev_ord.o: level.h -l_ev_ord.o: lint.h -l_ev_ord.o: nobitfield.h -l_ev_ord.o: nofloat.h -l_ev_ord.o: nopp.h -l_ev_ord.o: spec_arith.h -l_ev_ord.o: stack.h -l_ev_ord.o: type.h -l_outdef.o: LLlex.h -l_outdef.o: Lpars.h -l_outdef.o: arith.h -l_outdef.o: assert.h -l_outdef.o: code.h -l_outdef.o: debug.h -l_outdef.o: declar.h -l_outdef.o: decspecs.h -l_outdef.o: def.h -l_outdef.o: expr.h -l_outdef.o: field.h -l_outdef.o: file_info.h -l_outdef.o: idf.h -l_outdef.o: interface.h -l_outdef.o: l_class.h -l_outdef.o: l_comment.h -l_outdef.o: l_lint.h -l_outdef.o: l_outdef.h -l_outdef.o: label.h -l_outdef.o: level.h -l_outdef.o: lint.h -l_outdef.o: nobitfield.h -l_outdef.o: nofloat.h -l_outdef.o: nopp.h -l_outdef.o: spec_arith.h -l_outdef.o: stack.h -l_outdef.o: struct.h -l_outdef.o: type.h -l_comment.o: arith.h -l_comment.o: interface.h -l_comment.o: l_comment.h -l_comment.o: l_state.h -l_comment.o: lint.h -l_comment.o: spec_arith.h -tokenfile.o: Lpars.h -declar.o: LLlex.h -declar.o: Lpars.h -declar.o: arith.h -declar.o: code.h -declar.o: debug.h -declar.o: declar.h -declar.o: decspecs.h -declar.o: def.h -declar.o: expr.h -declar.o: field.h -declar.o: file_info.h -declar.o: idf.h -declar.o: l_lint.h -declar.o: label.h -declar.o: level.h -declar.o: lint.h -declar.o: nobitfield.h -declar.o: nocross.h -declar.o: nofloat.h -declar.o: nopp.h -declar.o: sizes.h -declar.o: spec_arith.h -declar.o: struct.h -declar.o: target_sizes.h -declar.o: type.h -statement.o: LLlex.h -statement.o: Lpars.h -statement.o: arith.h -statement.o: botch_free.h -statement.o: code.h -statement.o: debug.h -statement.o: def.h -statement.o: expr.h -statement.o: file_info.h -statement.o: idf.h -statement.o: l_em.h -statement.o: l_lint.h -statement.o: label.h -statement.o: lint.h -statement.o: nobitfield.h -statement.o: nofloat.h -statement.o: nopp.h -statement.o: spec_arith.h -statement.o: stack.h -statement.o: type.h -expression.o: LLlex.h -expression.o: Lpars.h -expression.o: arith.h -expression.o: code.h -expression.o: expr.h -expression.o: file_info.h -expression.o: idf.h -expression.o: label.h -expression.o: noRoption.h -expression.o: nobitfield.h -expression.o: nofloat.h -expression.o: nopp.h -expression.o: spec_arith.h -expression.o: type.h -program.o: LLlex.h -program.o: Lpars.h -program.o: arith.h -program.o: code.h -program.o: declar.h -program.o: decspecs.h -program.o: def.h -program.o: expr.h -program.o: file_info.h -program.o: idf.h -program.o: l_lint.h -program.o: label.h -program.o: lint.h -program.o: nobitfield.h -program.o: nofloat.h -program.o: nopp.h -program.o: spec_arith.h -program.o: type.h -Lpars.o: Lpars.h -ival.o: LLlex.h -ival.o: Lpars.h -ival.o: arith.h -ival.o: assert.h -ival.o: debug.h -ival.o: def.h -ival.o: estack.h -ival.o: expr.h -ival.o: field.h -ival.o: file_info.h -ival.o: idf.h -ival.o: l_em.h -ival.o: l_lint.h -ival.o: label.h -ival.o: level.h -ival.o: lint.h -ival.o: noRoption.h -ival.o: nobitfield.h -ival.o: nocross.h -ival.o: nofloat.h -ival.o: nopp.h -ival.o: sizes.h -ival.o: spec_arith.h -ival.o: struct.h -ival.o: target_sizes.h -ival.o: type.h -char.o: class.h -symbol2str.o: Lpars.h +distr: + echo '#ifndef lint' > Version.c + echo 'char Version[] = "ACK C compiler Version XXX";' | \ + sed "s/XXX/`RC -i`/" >> Version.c + echo '#endif lint' >> Version.c diff --git a/lang/m2/comp/Makefile b/lang/m2/comp/Makefile index 75c2c04c2..ba2909626 100644 --- a/lang/m2/comp/Makefile +++ b/lang/m2/comp/Makefile @@ -1,600 +1,5 @@ -# make modula-2 "compiler" -EMHOME = ../../.. -MDIR = $(EMHOME)/modules -MHDIR = $(MDIR)/h -PKGDIR = $(MDIR)/pkg -LIBDIR = $(MDIR)/lib -LLGEN = $(EMHOME)/bin/LLgen -MKDEP = $(EMHOME)/bin/mkdep -PRID = $(EMHOME)/bin/prid -CID = $(EMHOME)/bin/cid -CURRDIR = -LINT = lint -MACH = sun3 -BACK = back - -MALLOC = $(LIBDIR)/malloc.o -EMELIB = $(LIBDIR)/libem_mes.a $(LIBDIR)/libeme.a -EMKLIB = $(LIBDIR)/libem_mes.a $(LIBDIR)/libemk.a -MODLIB = $(LIBDIR)/libinput.a \ - $(LIBDIR)/libassert.a \ - $(LIBDIR)/liballoc.a \ - $(MALLOC) \ - $(LIBDIR)/libflt.a \ - $(LIBDIR)/libprint.a \ - $(LIBDIR)/libstring.a \ - $(LIBDIR)/libsystem.a -EMCELIB = $(LIBDIR)/libem_mesCE.a \ - $(EMHOME)/lib/$(MACH)/ce.a \ - $(EMHOME)/lib/$(MACH)/$(BACK).a \ - $(LIBDIR)/libobject.a \ - $(EMHOME)/lib/em_data.a -EMOCELIB = $(LIBDIR)/libem_mesO.a \ - $(LIBDIR)/libCEopt.a \ - $(EMHOME)/lib/$(MACH)/ce.a \ - $(EMHOME)/lib/$(MACH)/$(BACK).a \ - $(LIBDIR)/libobject.a \ - $(EMHOME)/lib/em_data.a - -LIBS = $(EMKLIB) $(MODLIB) -CELIBS = $(EMCELIB) $(MODLIB) -OLIBS = $(EMOCELIB) $(MODLIB) - -GF = program.g declar.g expression.g statement.g -GENGFILES= tokenfile.g -GFILES = $(GENGFILES) $(GF) -LLGENOPTIONS = -v -PROFILE = -COPTIONS = -INCLUDES = -I$(MHDIR) -I$(EMHOME)/h -I$(PKGDIR) -OPTIM = -O -CFLAGS = $(PROFILE) $(INCLUDES) $(COPTIONS) $(OPTIM) -LINTFLAGS = -LDFLAGS = $(PROFILE) - -LSRC = tokenfile.c program.c declar.c expression.c statement.c -LOBJ = tokenfile.o program.o declar.o expression.o statement.o -CSRC = LLlex.c LLmessage.c error.c main.c \ - tokenname.c idf.c input.c type.c def.c \ - misc.c enter.c defmodule.c typequiv.c node.c \ - cstoper.c chk_expr.c options.c walk.c desig.c \ - code.c lookup.c Version.c stab.c -COBJ = LLlex.o LLmessage.o char.o error.o main.o \ - symbol2str.o tokenname.o idf.o input.o type.o def.o \ - scope.o misc.o enter.o defmodule.o typequiv.o node.o \ - cstoper.o chk_expr.o options.o walk.o casestat.o desig.o \ - code.o tmpvar.o lookup.o Version.o stab.o next.o -GENC= $(LSRC) symbol2str.c char.c Lpars.c casestat.c tmpvar.c scope.c next.c -SRC = $(CSRC) $(GENC) - -# Extra object for generating peephole-optimizer-code-expander version. -# The Sun-3 version is faster when the text-size exceeds 180K! ARRGH -EXTRA_O = - -OBJ = $(COBJ) $(LOBJ) Lpars.o $(EXTRA_O) - -GENH = errout.h \ - idfsize.h numsize.h strsize.h target_sizes.h bigresult.h \ - inputtype.h density.h squeeze.h nocross.h nostrict.h \ - def.h debugcst.h type.h Lpars.h node.h strict3rd.h real.h \ - use_insert.h dbsymtab.h uns_arith.h -HFILES =LLlex.h \ - chk_expr.h class.h debug.h desig.h f_info.h idf.h \ - input.h main.h misc.h scope.h standards.h tokenname.h \ - walk.h warning.h SYSTEM.h $(GENH) -# -GENFILES = $(GENGFILES) $(GENC) $(GENH) -NEXTFILES = def.H type.H node.H real.H scope.C tmpvar.C casestat.C - -#EXCLEXCLEXCLEXCL - -all: Cfiles - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "EMHOME="$(EMHOME) $(CURRDIR)main ; else EMHOME=$(EMHOME); export EMHOME; sh Resolve main ; fi' - @rm -f nmclash.o a.out - -Omain: Cfiles - rm -f *.o - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "MACH="$(MACH) "EMHOME="$(EMHOME) "COPTIONS="-DPEEPHOLE "EXTRA_O="$(EXTRA_O) "BACK="$(BACK) $(CURRDIR)omain ; else MACH=$(MACH); export MACH; EMHOME=$(EMHOME); export EMHOME; ./Resolve omain ; fi' - @rm -f nmclash.o a.out - -CEmain: Cfiles - rm -f *.o - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "MACH="$(MACH) "EMHOME="$(EMHOME) "COPTIONS="-DCODE_EXPANDER "BACK="$(BACK) $(CURRDIR)cemain ; else MACH=$(MACH); export MACH; EMHOME=$(EMHOME); export EMHOME; ./Resolve cemain ; fi' - @rm -f nmclash.o a.out - -install: all - cp $(CURRDIR)main $(EMHOME)/lib/em_m2 - rm -f $(EMHOME)/man/em_m2.6 $(EMHOME)/man/modula-2.1 - cp $(CURRDIR)em_m2.6 $(CURRDIR)modula-2.1 $(EMHOME)/man - -cmp: all - -cmp $(CURRDIR)main $(EMHOME)/lib/em_m2 - -cmp $(CURRDIR)em_m2.6 $(EMHOME)/man/em_m2.6 - -cmp $(CURRDIR)modula-2.1 $(EMHOME)/man/modula-2.1 - -opr: - make pr | opr - -pr: - @pr Makefile Resolve Parameters $(GF) *.H $(HFILES) *.C $(CSRC) - -clean: - rm -f $(OBJ) $(GENFILES) LLfiles hfiles Cfiles clashes \ - $(CURRDIR)main LL.output - (cd .. ; rm -rf Xsrc) - -lint: Cfiles - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "EMHOME="$(EMHOME) Xlint ; else EMHOME=$(EMHOME); export EMHOME; sh Resolve Xlint ; fi' - @rm -f nmclash.o a.out - -longnames: $(SRC) $(HFILES) - sh -c 'if test -f longnames ; then $(PRID) -l7 longnames $? > Xlongnames ; mv Xlongnames longnames ; else $(PRID) -l7 $? > longnames ; fi' - -# entry points not to be used directly - -Cfiles: hfiles LLfiles $(GENC) $(GENH) Makefile - echo $(SRC) $(HFILES) > Cfiles - -LLfiles: $(GFILES) - $(LLGEN) $(LLGENOPTIONS) $(GFILES) - @touch LLfiles - -hfiles: Parameters make.hfiles - make.hfiles Parameters - touch hfiles - -tokenfile.g: tokenname.c make.tokfile - make.tokfile tokenfile.g - -symbol2str.c: tokenname.c make.tokcase - make.tokcase symbol2str.c - -.SUFFIXES: .H .h -.H.h: - ./make.allocd < $*.H > $*.h - -.SUFFIXES: .C .c -.C.c: - ./make.allocd < $*.C > $*.c - -def.h: make.allocd -type.h: make.allocd -real.h: make.allocd -node.h: make.allocd -scope.c: make.allocd -tmpvar.c: make.allocd -casestat.c: make.allocd - -next.c: $(NEXTFILES) ./make.next - ./make.next $(NEXTFILES) > next.c - -char.c: char.tab - $(EMHOME)/bin/tabgen -fchar.tab >char.c - -depend: Cfiles - sed '/^#AUTOAUTO/,$$d' Makefile > Makefile.new - echo '#AUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTO' >> Makefile.new - $(MKDEP) $(SRC) |\ - sed 's/\.c:/\.o:/' >> Makefile.new - mv Makefile Makefile.old - mv Makefile.new Makefile - -#INCLINCLINCLINCL - -Xlint: - $(LINT) $(INCLUDES) $(LINTFLAGS) $(SRC) \ - $(LIBDIR)/llib-lem_mes.ln \ - $(LIBDIR)/llib-lemk.ln \ - $(LIBDIR)/llib-linput.ln \ - $(LIBDIR)/llib-lassert.ln \ - $(LIBDIR)/llib-lalloc.ln \ - $(LIBDIR)/llib-lflt.ln \ - $(LIBDIR)/llib-lprint.ln \ - $(LIBDIR)/llib-lstring.ln \ - $(LIBDIR)/llib-lsystem.ln - -$(CURRDIR)main: $(OBJ) $(CURRDIR)Makefile - $(CC) $(LDFLAGS) $(OBJ) $(LIBS) -o $(CURRDIR)main - -size $(CURRDIR)main - -$(CURRDIR)omain: $(OBJ) #$(CURRDIR)Makefile - $(CC) $(LDFLAGS) $(OBJ) $(OLIBS) -o $(CURRDIR)omain - -size $(CURRDIR)omain - -$(CURRDIR)cemain: $(OBJ) #$(CURRDIR)Makefile - $(CC) $(LDFLAGS) $(OBJ) $(CELIBS) -o $(CURRDIR)cemain - -size $(CURRDIR)cemain - - -#AUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTO -LLlex.o: LLlex.h -LLlex.o: Lpars.h -LLlex.o: class.h -LLlex.o: dbsymtab.h -LLlex.o: debug.h -LLlex.o: debugcst.h -LLlex.o: def.h -LLlex.o: f_info.h -LLlex.o: idf.h -LLlex.o: idfsize.h -LLlex.o: input.h -LLlex.o: inputtype.h -LLlex.o: nocross.h -LLlex.o: numsize.h -LLlex.o: real.h -LLlex.o: strsize.h -LLlex.o: target_sizes.h -LLlex.o: type.h -LLlex.o: warning.h -LLmessage.o: LLlex.h -LLmessage.o: Lpars.h -LLmessage.o: idf.h -LLmessage.o: real.h -error.o: LLlex.h -error.o: debug.h -error.o: debugcst.h -error.o: errout.h -error.o: f_info.h -error.o: input.h -error.o: inputtype.h -error.o: main.h -error.o: node.h -error.o: nostrict.h -error.o: real.h -error.o: strict3rd.h -error.o: warning.h -main.o: LLlex.h -main.o: Lpars.h -main.o: SYSTEM.h -main.o: dbsymtab.h -main.o: debug.h -main.o: debugcst.h -main.o: def.h -main.o: f_info.h -main.o: idf.h -main.o: input.h -main.o: inputtype.h -main.o: nocross.h -main.o: node.h -main.o: real.h -main.o: scope.h -main.o: standards.h -main.o: strict3rd.h -main.o: target_sizes.h -main.o: tokenname.h -main.o: type.h -main.o: warning.h -tokenname.o: Lpars.h -tokenname.o: idf.h -tokenname.o: tokenname.h -idf.o: idf.h -input.o: f_info.h -input.o: input.h -input.o: inputtype.h -type.o: LLlex.h -type.o: chk_expr.h -type.o: dbsymtab.h -type.o: debug.h -type.o: debugcst.h -type.o: def.h -type.o: idf.h -type.o: nocross.h -type.o: node.h -type.o: nostrict.h -type.o: real.h -type.o: scope.h -type.o: squeeze.h -type.o: target_sizes.h -type.o: type.h -type.o: walk.h -type.o: warning.h -def.o: LLlex.h -def.o: Lpars.h -def.o: dbsymtab.h -def.o: debug.h -def.o: debugcst.h -def.o: def.h -def.o: idf.h -def.o: main.h -def.o: nocross.h -def.o: node.h -def.o: real.h -def.o: scope.h -def.o: target_sizes.h -def.o: type.h -def.o: warning.h -misc.o: LLlex.h -misc.o: f_info.h -misc.o: idf.h -misc.o: misc.h -misc.o: node.h -misc.o: real.h -enter.o: LLlex.h -enter.o: dbsymtab.h -enter.o: debug.h -enter.o: debugcst.h -enter.o: def.h -enter.o: f_info.h -enter.o: idf.h -enter.o: main.h -enter.o: misc.h -enter.o: nocross.h -enter.o: node.h -enter.o: real.h -enter.o: scope.h -enter.o: target_sizes.h -enter.o: type.h -defmodule.o: LLlex.h -defmodule.o: Lpars.h -defmodule.o: dbsymtab.h -defmodule.o: debug.h -defmodule.o: debugcst.h -defmodule.o: def.h -defmodule.o: f_info.h -defmodule.o: idf.h -defmodule.o: input.h -defmodule.o: inputtype.h -defmodule.o: main.h -defmodule.o: misc.h -defmodule.o: nocross.h -defmodule.o: node.h -defmodule.o: real.h -defmodule.o: scope.h -defmodule.o: target_sizes.h -defmodule.o: type.h -typequiv.o: LLlex.h -typequiv.o: dbsymtab.h -typequiv.o: debug.h -typequiv.o: debugcst.h -typequiv.o: def.h -typequiv.o: idf.h -typequiv.o: main.h -typequiv.o: nocross.h -typequiv.o: node.h -typequiv.o: real.h -typequiv.o: strict3rd.h -typequiv.o: target_sizes.h -typequiv.o: type.h -typequiv.o: warning.h -node.o: LLlex.h -node.o: dbsymtab.h -node.o: debug.h -node.o: debugcst.h -node.o: def.h -node.o: main.h -node.o: nocross.h -node.o: node.h -node.o: real.h -node.o: target_sizes.h -node.o: type.h -cstoper.o: LLlex.h -cstoper.o: Lpars.h -cstoper.o: dbsymtab.h -cstoper.o: debug.h -cstoper.o: debugcst.h -cstoper.o: idf.h -cstoper.o: nocross.h -cstoper.o: node.h -cstoper.o: real.h -cstoper.o: standards.h -cstoper.o: target_sizes.h -cstoper.o: type.h -cstoper.o: uns_arith.h -cstoper.o: warning.h -chk_expr.o: LLlex.h -chk_expr.o: Lpars.h -chk_expr.o: chk_expr.h -chk_expr.o: dbsymtab.h -chk_expr.o: debug.h -chk_expr.o: debugcst.h -chk_expr.o: def.h -chk_expr.o: idf.h -chk_expr.o: main.h -chk_expr.o: misc.h -chk_expr.o: nocross.h -chk_expr.o: node.h -chk_expr.o: nostrict.h -chk_expr.o: real.h -chk_expr.o: scope.h -chk_expr.o: standards.h -chk_expr.o: strict3rd.h -chk_expr.o: target_sizes.h -chk_expr.o: type.h -chk_expr.o: warning.h -options.o: class.h -options.o: dbsymtab.h -options.o: idfsize.h -options.o: main.h -options.o: nocross.h -options.o: nostrict.h -options.o: squeeze.h -options.o: strict3rd.h -options.o: target_sizes.h -options.o: type.h -options.o: warning.h -walk.o: LLlex.h -walk.o: Lpars.h -walk.o: bigresult.h -walk.o: chk_expr.h -walk.o: dbsymtab.h -walk.o: debug.h -walk.o: debugcst.h -walk.o: def.h -walk.o: desig.h -walk.o: f_info.h -walk.o: idf.h -walk.o: main.h -walk.o: misc.h -walk.o: nocross.h -walk.o: node.h -walk.o: real.h -walk.o: scope.h -walk.o: squeeze.h -walk.o: strict3rd.h -walk.o: target_sizes.h -walk.o: type.h -walk.o: use_insert.h -walk.o: walk.h -walk.o: warning.h -desig.o: LLlex.h -desig.o: dbsymtab.h -desig.o: debug.h -desig.o: debugcst.h -desig.o: def.h -desig.o: desig.h -desig.o: nocross.h -desig.o: node.h -desig.o: real.h -desig.o: scope.h -desig.o: squeeze.h -desig.o: target_sizes.h -desig.o: type.h -desig.o: walk.h -desig.o: warning.h -code.o: LLlex.h -code.o: Lpars.h -code.o: bigresult.h -code.o: dbsymtab.h -code.o: debug.h -code.o: debugcst.h -code.o: def.h -code.o: desig.h -code.o: nocross.h -code.o: node.h -code.o: real.h -code.o: scope.h -code.o: squeeze.h -code.o: standards.h -code.o: target_sizes.h -code.o: type.h -code.o: walk.h -lookup.o: LLlex.h -lookup.o: dbsymtab.h -lookup.o: debug.h -lookup.o: debugcst.h -lookup.o: def.h -lookup.o: idf.h -lookup.o: misc.h -lookup.o: nocross.h -lookup.o: node.h -lookup.o: real.h -lookup.o: scope.h -lookup.o: target_sizes.h -lookup.o: type.h -stab.o: LLlex.h -stab.o: dbsymtab.h -stab.o: def.h -stab.o: idf.h -stab.o: main.h -stab.o: nocross.h -stab.o: real.h -stab.o: scope.h -stab.o: target_sizes.h -stab.o: type.h -tokenfile.o: Lpars.h -program.o: LLlex.h -program.o: Lpars.h -program.o: dbsymtab.h -program.o: debug.h -program.o: debugcst.h -program.o: def.h -program.o: f_info.h -program.o: idf.h -program.o: main.h -program.o: misc.h -program.o: nocross.h -program.o: node.h -program.o: real.h -program.o: scope.h -program.o: strict3rd.h -program.o: target_sizes.h -program.o: type.h -program.o: warning.h -declar.o: LLlex.h -declar.o: Lpars.h -declar.o: chk_expr.h -declar.o: dbsymtab.h -declar.o: debug.h -declar.o: debugcst.h -declar.o: def.h -declar.o: idf.h -declar.o: main.h -declar.o: misc.h -declar.o: nocross.h -declar.o: node.h -declar.o: nostrict.h -declar.o: real.h -declar.o: scope.h -declar.o: strict3rd.h -declar.o: target_sizes.h -declar.o: type.h -declar.o: warning.h -expression.o: LLlex.h -expression.o: Lpars.h -expression.o: chk_expr.h -expression.o: dbsymtab.h -expression.o: debug.h -expression.o: debugcst.h -expression.o: def.h -expression.o: idf.h -expression.o: nocross.h -expression.o: node.h -expression.o: real.h -expression.o: target_sizes.h -expression.o: type.h -expression.o: warning.h -statement.o: LLlex.h -statement.o: Lpars.h -statement.o: dbsymtab.h -statement.o: def.h -statement.o: idf.h -statement.o: nocross.h -statement.o: node.h -statement.o: real.h -statement.o: scope.h -statement.o: target_sizes.h -statement.o: type.h -symbol2str.o: Lpars.h -char.o: class.h -Lpars.o: Lpars.h -casestat.o: LLlex.h -casestat.o: Lpars.h -casestat.o: chk_expr.h -casestat.o: dbsymtab.h -casestat.o: debug.h -casestat.o: debugcst.h -casestat.o: def.h -casestat.o: density.h -casestat.o: desig.h -casestat.o: nocross.h -casestat.o: node.h -casestat.o: real.h -casestat.o: squeeze.h -casestat.o: target_sizes.h -casestat.o: type.h -casestat.o: walk.h -tmpvar.o: LLlex.h -tmpvar.o: dbsymtab.h -tmpvar.o: debug.h -tmpvar.o: debugcst.h -tmpvar.o: def.h -tmpvar.o: main.h -tmpvar.o: nocross.h -tmpvar.o: real.h -tmpvar.o: scope.h -tmpvar.o: target_sizes.h -tmpvar.o: type.h -scope.o: LLlex.h -scope.o: dbsymtab.h -scope.o: debug.h -scope.o: debugcst.h -scope.o: def.h -scope.o: idf.h -scope.o: nocross.h -scope.o: node.h -scope.o: real.h -scope.o: scope.h -scope.o: target_sizes.h -scope.o: type.h -next.o: debug.h -next.o: debugcst.h +distr: + echo '#ifndef lint' > Version.c + echo 'char Version[] = "ACK Modula-2 compiler Version XXX";' | \ + sed "s/XXX/`RC -i`/" >> Version.c + echo '#endif lint' >> Version.c diff --git a/lang/m2/m2mm/Makefile b/lang/m2/m2mm/Makefile index a2f013ea4..d4a1643fd 100644 --- a/lang/m2/m2mm/Makefile +++ b/lang/m2/m2mm/Makefile @@ -1,149 +1,5 @@ -# -EMHOME = ../../.. -MHDIR = $(EMHOME)/modules/h -PKGDIR = $(EMHOME)/modules/pkg -LIBDIR = $(EMHOME)/modules/lib -LLGEN = $(EMHOME)/bin/LLgen -MKDEP = $(EMHOME)/bin/mkdep - -INCLUDES = -I$(MHDIR) -I$(PKGDIR) -I$(EMHOME)/h - -GF = program.g declar.g expression.g statement.g -GENGFILES= tokenfile.g -GFILES =$(GENGFILES) $(GF) -LLGENOPTIONS = -PROFILE = -M2COMPILER = m2 -DEFDIR = lib/m2 -HOMEDIR = -CFLAGS = -O $(PROFILE) $(INCLUDES) -DM2COMPILER=\"$(M2COMPILER)\" -DDEF_DIR=\"$(DEFDIR)\" $(HOMEDIR) -LINTFLAGS = -DNORCSID -MALLOC = $(LIBDIR)/malloc.o -LDFLAGS = $(PROFILE) -LSRC = tokenfile.c program.c declar.c expression.c statement.c -LOBJ = tokenfile.o program.o declar.o expression.o statement.o -CSRC = LLlex.c LLmessage.c error.c main.c lib.c \ - tokenname.c idf.c input.c misc.c options.c Version.c -COBJ = LLlex.o LLmessage.o error.o main.o lib.o \ - tokenname.o idf.o input.o misc.o options.o char.o symbol2str.o Version.o -GENC= $(LSRC) symbol2str.c char.c Lpars.c -SRC = $(CSRC) $(GENC) -OBJ = $(COBJ) $(LOBJ) Lpars.o -GENH = Lpars.h -HSRC = main.h LLlex.h class.h f_info.h idf.h input.h tokenname.h -HFILES =$(GENH) $(HSRC) -# -GENFILES = $(GENGFILES) $(GENC) $(GENH) - -all: Cfiles - make "EMHOME="$(EMHOME) "DEFDIR="$(DEFDIR) "HOMEDIR="$(HOMEDIR) "M2COMPILER="$(M2COMPILER) m2mm - -install: all - cp m2mm $(EMHOME)/bin - cp m2mm.1 $(EMHOME)/man - -cmp: all - -cmp m2mm $(EMHOME)/bin/m2mm - -cmp m2mm.1 $(EMHOME)/man/m2mm.1 - -opr: - make "EMHOME="$(EMHOME) pr | opr - -pr: - @pr Makefile $(GF) $(HFILES) $(CSRC) - -clean: - rm -f $(OBJ) $(GENFILES) LLfiles Cfiles LL.output m2mm - -lint: Cfiles - lint $(INCLUDES) $(LINTFLAGS) $(SRC) \ - $(LIBDIR)/llib-linput.ln \ - $(LIBDIR)/llib-lalloc.ln \ - $(LIBDIR)/llib-lprint.ln \ - $(LIBDIR)/llib-lstring.ln \ - $(LIBDIR)/llib-lsystem.ln - -# entry points not to be used directly -Cfiles: LLfiles $(GENC) $(GENH) Makefile - -LLfiles: $(GFILES) - $(LLGEN) $(LLGENOPTIONS) $(GFILES) - @touch LLfiles - -tokenfile.g: tokenname.c make.tokfile - make.tokfile tokenfile.g - -symbol2str.c: tokenname.c make.tokcase - make.tokcase symbol2str.c - -char.c: char.tab - $(EMHOME)/bin/tabgen -fchar.tab >char.c - -depend: Cfiles - sed '/^#AUTOAUTO/,$$d' Makefile > Makefile.new - echo '#AUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTO' >> Makefile.new - $(MKDEP) $(SRC) |\ - sed 's/\.c:/\.o:/' >> Makefile.new - mv Makefile Makefile.old - mv Makefile.new Makefile - -m2mm: $(OBJ) - $(CC) $(LDFLAGS) $(OBJ) $(LIBDIR)/libinput.a $(LIBDIR)/liballoc.a $(MALLOC) $(LIBDIR)/libprint.a $(LIBDIR)/libstring.a $(LIBDIR)/libsystem.a -o m2mm - -size m2mm - -#AUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTO -LLlex.o: LLlex.h -LLlex.o: Lpars.h -LLlex.o: class.h -LLlex.o: f_info.h -LLlex.o: file_list.h -LLlex.o: idf.h -LLlex.o: idfsize.h -LLlex.o: input.h -LLlex.o: inputtype.h -LLmessage.o: LLlex.h -LLmessage.o: Lpars.h -LLmessage.o: file_list.h -LLmessage.o: idf.h -error.o: LLlex.h -error.o: f_info.h -error.o: input.h -error.o: inputtype.h -main.o: LLlex.h -main.o: Lpars.h -main.o: f_info.h -main.o: file_list.h -main.o: idf.h -main.o: input.h -main.o: inputtype.h -main.o: tokenname.h -tokenname.o: Lpars.h -tokenname.o: file_list.h -tokenname.o: idf.h -tokenname.o: tokenname.h -idf.o: file_list.h -idf.o: idf.h -input.o: f_info.h -input.o: input.h -input.o: inputtype.h -misc.o: LLlex.h -misc.o: f_info.h -misc.o: file_list.h -misc.o: idf.h -options.o: main.h -tokenfile.o: Lpars.h -program.o: LLlex.h -program.o: Lpars.h -program.o: f_info.h -program.o: file_list.h -program.o: idf.h -program.o: main.h -declar.o: Lpars.h -expression.o: Lpars.h -statement.o: LLlex.h -statement.o: Lpars.h -statement.o: file_list.h -statement.o: idf.h -symbol2str.o: Lpars.h -char.o: class.h -Lpars.o: Lpars.h +distr: + echo '#ifndef lint' > Version.c + echo 'char Version[] = "ACK Modula-2 Makefile generator Version XXX";' | \ + sed "s/XXX/`RC -i`/" >> Version.c + echo '#endif lint' >> Version.c diff --git a/lang/pc/comp/Makefile b/lang/pc/comp/Makefile index e1d49d9a2..15622705e 100644 --- a/lang/pc/comp/Makefile +++ b/lang/pc/comp/Makefile @@ -1,563 +1,5 @@ -# make iso-pascal "compiler" -EMHOME = ../../.. -MDIR = $(EMHOME)/modules -MHDIR = $(MDIR)/h -PKGDIR = $(MDIR)/pkg -LIBDIR = $(MDIR)/lib -LLGEN = $(EMHOME)/bin/LLgen -MKDEP = $(EMHOME)/bin/mkdep -PRID = $(EMHOME)/bin/prid -CID = $(EMHOME)/bin/cid -OPR = opr -CURRDIR = -CC = fcc -CC = cc -LINT = lint -MACH = sun3 -BACK = back - -MALLOC = $(LIBDIR)/malloc.o -EMELIB = $(LIBDIR)/libem_mes.a \ - $(LIBDIR)/libeme.a \ - $(EMHOME)/lib/em_data.a -EMKLIB = $(LIBDIR)/libem_mes.a $(LIBDIR)/libemk.a -MODLIB = $(LIBDIR)/libinput.a \ - $(LIBDIR)/libassert.a \ - $(LIBDIR)/liballoc.a \ - $(MALLOC) \ - $(LIBDIR)/libprint.a \ - $(LIBDIR)/libstring.a \ - $(LIBDIR)/libsystem.a -EMCELIB = $(LIBDIR)/libem_mesCE.a \ - $(EMHOME)/lib/$(MACH)/ce.a \ - $(EMHOME)/lib/$(MACH)/$(BACK).a \ - $(LIBDIR)/libflt.a \ - $(LIBDIR)/libobject.a \ - $(EMHOME)/lib/em_data.a -EMOCELIB = $(LIBDIR)/libem_mesO.a \ - $(LIBDIR)/libCEopt.a \ - $(EMHOME)/lib/$(MACH)/ce.a \ - $(EMHOME)/lib/$(MACH)/$(BACK).a \ - $(LIBDIR)/libflt.a \ - $(LIBDIR)/libobject.a \ - $(EMHOME)/lib/em_data.a - -LIBS = $(EMKLIB) $(MODLIB) -CELIBS = $(EMCELIB) $(MODLIB) -OLIBS = $(EMOCELIB) $(MODLIB) - -GFILES = tokenfile.g declar.g expression.g program.g statement.g -LLGENOPTIONS = -PROFILE = -COPTIONS = -INCLUDES = -I$(MHDIR) -I$(EMHOME)/h -I$(PKGDIR) -OPTIM= -O -CFLAGS = $(PROFILE) $(INCLUDES) $(OPTIM) $(COPTIONS) -DSTATIC= -LINTFLAGS = -DSTATIC= -DNORCSID -LDFLAGS = $(PROFILE) - -LSRC = declar.c expression.c program.c statement.c tokenfile.c -LOBJ = declar.o expression.o program.o statement.o tokenfile.o -CSRC = LLlex.c LLmessage.c body.c chk_expr.c code.c\ - cstoper.c def.c desig.c enter.c error.c idf.c input.c label.c\ - lookup.c main.c misc.c node.c options.c readwrite.c\ - scope.c symbol2str.c tokenname.c type.c typequiv.c progs.c stab.c -COBJ = LLlex.o LLmessage.o body.o casestat.o char.o chk_expr.o code.o\ - cstoper.o def.o desig.o enter.o error.o idf.o input.o label.o\ - lookup.o main.o misc.o next.o node.o options.o readwrite.o scope.o\ - symbol2str.o tmpvar.o tokenname.o type.o typequiv.o progs.o stab.o - -# Extra object for generating peephole-optimizer-code-expander version. -# The Sun-3 version is faster when the text-size exceeds 180K! ARRGH -EXTRA_O = - -OBJ = Lpars.o $(COBJ) $(LOBJ) $(EXTRA_O) - -# Keep the next entries up to date! -GENCFILES= $(LSRC) Lpars.c symbol2str.c casestat.c tmpvar.c char.c next.c -SRC = $(CSRC) $(GENCFILES) -GENGFILES= tokenfile.g -GENHFILES= Lpars.h debugcst.h density.h errout.h idfsize.h inputtype.h\ - numsize.h strsize.h def.h type.h desig.h scope.h node.h\ - target_sizes.h nocross.h dbsymtab.h -HFILES= LLlex.h chk_expr.h class.h const.h debug.h\ - f_info.h idf.h input.h main.h misc.h required.h\ - tokenname.h $(GENHFILES) -# -GENFILES = $(GENGFILES) $(GENCFILES) $(GENHFILES) -NEXTFILES = def.H desig.H node.H scope.H type.H casestat.C tmpvar.C - -#EXCLEXCLEXCLEXCL - -all: Cfiles - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "EMHOME="$(EMHOME) $(CURRDIR)main ; else EMHOME=$(EMHOME); export EMHOME; sh Resolve main ; fi' - @rm -f nmclash.o a.out - -Omain: Cfiles - rm -f *.o - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "MACH="$(MACH) "EMHOME="$(EMHOME) "COPTIONS="-DPEEPHOLE "EXTRA_O="$(EXTRA_O) "BACK="$(BACK) $(CURRDIR)omain ; else MACH=$(MACH); export MACH; EMHOME=$(EMHOME); export EMHOME; ./Resolve omain ; fi' - @rm -f nmclash.o a.out - -CEmain: Cfiles - rm -f *.o - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "MACH="$(MACH) "EMHOME="$(EMHOME) "COPTIONS="-DCODE_EXPANDER "BACK="$(BACK) $(CURRDIR)cemain ; else MACH=$(MACH); export MACH; EMHOME=$(EMHOME); export EMHOME; ./Resolve cemain ; fi' - @rm -f nmclash.o a.out - -install: all - cp $(CURRDIR)main $(EMHOME)/lib/em_pc - -cmp: all - -cmp $(CURRDIR)main $(EMHOME)/lib/em_pc - -opr: - make pr | $(OPR) - -pr: - @pr Makefile Resolve Parameters $(GFILES) *.H $(HFILES) *.C $(CSRC) - -clean: - rm -f $(OBJ) $(CURRDIR)main $(GENFILES) hfiles Cfiles LLfiles clashes \ - LL.output - (cd .. ; rm -rf Xsrc) - -lint: Cfiles - sh -c 'if $(CC) nmclash.c > /dev/null 2>&1 ; then make "EMHOME="$(EMHOME) Xlint ; else EMHOME=$(EMHOME); export EMHOME; sh Resolve Xlint ; fi' - @rm -f nmclash.o a.out - -longnames: $(SRC) $(HFILES) - sh -c 'if test -f longnames ; then $(PRID) -l7 longnames $? > Xlongnames ; mv Xlongnames longnames ; else $(PRID) -l7 $? > longnames ; fi' - -# entry points not to be used directly - -Cfiles: hfiles LLfiles $(GENCFILES) $(GENHFILES) Makefile - echo $(SRC) $(HFILES) > Cfiles - -LLfiles: $(GFILES) - $(LLGEN) $(LLGENOPTIONS) $(GFILES) - @touch LLfiles - -hfiles: Parameters make.hfiles - make.hfiles Parameters - touch hfiles - -tokenfile.g: tokenname.c make.tokfile - make.tokfile < tokenname.c > tokenfile.g - -symbol2str.c: tokenname.c make.tokcase - make.tokcase < tokenname.c > symbol2str.c - -.SUFFIXES: .H .h -.H.h: - ./make.allocd < $*.H > $*.h - -.SUFFIXES: .C .c -.C.c: - ./make.allocd < $*.C > $*.c - -def.h: make.allocd -type.h: make.allocd -node.h: make.allocd -scope.h: make.allocd -desig.h: make.allocd -casestat.c: make.allocd -tmpvar.c: make.allocd - -next.c: $(NEXTFILES) ./make.next - ./make.next $(NEXTFILES) > next.c - -char.c: char.tab - $(EMHOME)/bin/tabgen -fchar.tab > char.c - -depend: Cfiles - sed '/^#AUTOAUTO/,$$d' Makefile > Makefile.new - echo '#AUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTO' >> Makefile.new - $(MKDEP) $(SRC) |\ - sed 's/\.c:/\.o:/' >> Makefile.new - mv Makefile Makefile.old - mv Makefile.new Makefile - -print: $(CSRC) $(GFILES) $(HFILES) # print recently changed files - pr -t $? | $(OPR) - @touch print - -xref: - ctags -x $(CSRC) $(HFILES) | sed "s/).*/)/">Xref - -#INCLINCLINCLINCL - -Xlint: - $(LINT) $(INCLUDES) $(LINTFLAGS) $(SRC) \ - $(LIBDIR)/llib-lem_mes.ln \ - $(LIBDIR)/llib-lemk.ln \ - $(LIBDIR)/llib-linput.ln \ - $(LIBDIR)/llib-lassert.ln \ - $(LIBDIR)/llib-lalloc.ln \ - $(LIBDIR)/llib-lprint.ln \ - $(LIBDIR)/llib-lstring.ln \ - $(LIBDIR)/llib-lsystem.ln - -$(CURRDIR)main: $(OBJ) $(CURRDIR)Makefile - -mv $(CURRDIR)main $(CURRDIR)main.old - $(CC) $(LDFLAGS) $(OBJ) $(LIBS) -o $(CURRDIR)main - -size $(CURRDIR)main.old - size $(CURRDIR)main - -$(CURRDIR)omain: $(OBJ) #$(CURRDIR)Makefile - $(CC) $(LDFLAGS) $(OBJ) $(OLIBS) -o $(CURRDIR)omain - -size $(CURRDIR)omain - -$(CURRDIR)cemain: $(OBJ) #$(CURRDIR)Makefile - $(CC) $(LDFLAGS) $(OBJ) $(CELIBS) -o $(CURRDIR)cemain - -size $(CURRDIR)cemain - -#AUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTO -LLlex.o: LLlex.h -LLlex.o: Lpars.h -LLlex.o: class.h -LLlex.o: const.h -LLlex.o: dbsymtab.h -LLlex.o: debug.h -LLlex.o: debugcst.h -LLlex.o: f_info.h -LLlex.o: idf.h -LLlex.o: idfsize.h -LLlex.o: input.h -LLlex.o: inputtype.h -LLlex.o: main.h -LLlex.o: nocross.h -LLlex.o: numsize.h -LLlex.o: strsize.h -LLlex.o: target_sizes.h -LLlex.o: type.h -LLmessage.o: LLlex.h -LLmessage.o: Lpars.h -LLmessage.o: dbsymtab.h -LLmessage.o: idf.h -LLmessage.o: nocross.h -LLmessage.o: target_sizes.h -LLmessage.o: type.h -body.o: LLlex.h -body.o: chk_expr.h -body.o: dbsymtab.h -body.o: debug.h -body.o: debugcst.h -body.o: def.h -body.o: desig.h -body.o: idf.h -body.o: main.h -body.o: misc.h -body.o: nocross.h -body.o: node.h -body.o: scope.h -body.o: target_sizes.h -body.o: type.h -chk_expr.o: LLlex.h -chk_expr.o: Lpars.h -chk_expr.o: chk_expr.h -chk_expr.o: const.h -chk_expr.o: dbsymtab.h -chk_expr.o: debug.h -chk_expr.o: debugcst.h -chk_expr.o: def.h -chk_expr.o: idf.h -chk_expr.o: main.h -chk_expr.o: misc.h -chk_expr.o: nocross.h -chk_expr.o: node.h -chk_expr.o: required.h -chk_expr.o: scope.h -chk_expr.o: target_sizes.h -chk_expr.o: type.h -code.o: LLlex.h -code.o: Lpars.h -code.o: dbsymtab.h -code.o: debug.h -code.o: debugcst.h -code.o: def.h -code.o: desig.h -code.o: f_info.h -code.o: idf.h -code.o: main.h -code.o: misc.h -code.o: nocross.h -code.o: node.h -code.o: required.h -code.o: scope.h -code.o: target_sizes.h -code.o: type.h -cstoper.o: LLlex.h -cstoper.o: Lpars.h -cstoper.o: const.h -cstoper.o: dbsymtab.h -cstoper.o: debug.h -cstoper.o: debugcst.h -cstoper.o: nocross.h -cstoper.o: node.h -cstoper.o: required.h -cstoper.o: target_sizes.h -cstoper.o: type.h -def.o: LLlex.h -def.o: dbsymtab.h -def.o: debug.h -def.o: debugcst.h -def.o: def.h -def.o: idf.h -def.o: main.h -def.o: misc.h -def.o: nocross.h -def.o: node.h -def.o: scope.h -def.o: target_sizes.h -def.o: type.h -desig.o: LLlex.h -desig.o: dbsymtab.h -desig.o: debug.h -desig.o: debugcst.h -desig.o: def.h -desig.o: desig.h -desig.o: idf.h -desig.o: main.h -desig.o: nocross.h -desig.o: node.h -desig.o: scope.h -desig.o: target_sizes.h -desig.o: type.h -enter.o: LLlex.h -enter.o: dbsymtab.h -enter.o: def.h -enter.o: idf.h -enter.o: main.h -enter.o: nocross.h -enter.o: node.h -enter.o: scope.h -enter.o: target_sizes.h -enter.o: type.h -error.o: LLlex.h -error.o: debug.h -error.o: debugcst.h -error.o: errout.h -error.o: f_info.h -error.o: input.h -error.o: inputtype.h -error.o: main.h -error.o: node.h -idf.o: idf.h -input.o: f_info.h -input.o: idf.h -input.o: input.h -input.o: inputtype.h -label.o: LLlex.h -label.o: dbsymtab.h -label.o: def.h -label.o: idf.h -label.o: main.h -label.o: nocross.h -label.o: node.h -label.o: scope.h -label.o: target_sizes.h -label.o: type.h -lookup.o: LLlex.h -lookup.o: dbsymtab.h -lookup.o: def.h -lookup.o: idf.h -lookup.o: misc.h -lookup.o: nocross.h -lookup.o: node.h -lookup.o: scope.h -lookup.o: target_sizes.h -lookup.o: type.h -main.o: LLlex.h -main.o: Lpars.h -main.o: class.h -main.o: const.h -main.o: dbsymtab.h -main.o: debug.h -main.o: debugcst.h -main.o: def.h -main.o: f_info.h -main.o: idf.h -main.o: input.h -main.o: inputtype.h -main.o: main.h -main.o: nocross.h -main.o: node.h -main.o: required.h -main.o: scope.h -main.o: target_sizes.h -main.o: tokenname.h -main.o: type.h -misc.o: LLlex.h -misc.o: f_info.h -misc.o: idf.h -misc.o: main.h -misc.o: misc.h -misc.o: node.h -node.o: LLlex.h -node.o: dbsymtab.h -node.o: debug.h -node.o: debugcst.h -node.o: nocross.h -node.o: node.h -node.o: target_sizes.h -node.o: type.h -options.o: class.h -options.o: const.h -options.o: dbsymtab.h -options.o: idfsize.h -options.o: main.h -options.o: nocross.h -options.o: target_sizes.h -options.o: type.h -readwrite.o: LLlex.h -readwrite.o: dbsymtab.h -readwrite.o: debug.h -readwrite.o: debugcst.h -readwrite.o: def.h -readwrite.o: idf.h -readwrite.o: main.h -readwrite.o: misc.h -readwrite.o: nocross.h -readwrite.o: node.h -readwrite.o: scope.h -readwrite.o: target_sizes.h -readwrite.o: type.h -scope.o: LLlex.h -scope.o: dbsymtab.h -scope.o: debug.h -scope.o: debugcst.h -scope.o: def.h -scope.o: idf.h -scope.o: misc.h -scope.o: nocross.h -scope.o: node.h -scope.o: scope.h -scope.o: target_sizes.h -scope.o: type.h -symbol2str.o: Lpars.h -tokenname.o: Lpars.h -tokenname.o: idf.h -tokenname.o: tokenname.h -type.o: LLlex.h -type.o: const.h -type.o: dbsymtab.h -type.o: debug.h -type.o: debugcst.h -type.o: def.h -type.o: idf.h -type.o: main.h -type.o: nocross.h -type.o: node.h -type.o: scope.h -type.o: target_sizes.h -type.o: type.h -typequiv.o: LLlex.h -typequiv.o: dbsymtab.h -typequiv.o: debug.h -typequiv.o: debugcst.h -typequiv.o: def.h -typequiv.o: nocross.h -typequiv.o: node.h -typequiv.o: target_sizes.h -typequiv.o: type.h -progs.o: LLlex.h -progs.o: dbsymtab.h -progs.o: debug.h -progs.o: debugcst.h -progs.o: def.h -progs.o: main.h -progs.o: nocross.h -progs.o: scope.h -progs.o: target_sizes.h -progs.o: type.h -stab.o: LLlex.h -stab.o: const.h -stab.o: dbsymtab.h -stab.o: def.h -stab.o: idf.h -stab.o: main.h -stab.o: nocross.h -stab.o: node.h -stab.o: scope.h -stab.o: target_sizes.h -stab.o: type.h -declar.o: LLlex.h -declar.o: Lpars.h -declar.o: chk_expr.h -declar.o: dbsymtab.h -declar.o: debug.h -declar.o: debugcst.h -declar.o: def.h -declar.o: idf.h -declar.o: main.h -declar.o: misc.h -declar.o: nocross.h -declar.o: node.h -declar.o: scope.h -declar.o: target_sizes.h -declar.o: type.h -expression.o: LLlex.h -expression.o: Lpars.h -expression.o: chk_expr.h -expression.o: dbsymtab.h -expression.o: debug.h -expression.o: debugcst.h -expression.o: def.h -expression.o: idf.h -expression.o: main.h -expression.o: misc.h -expression.o: nocross.h -expression.o: node.h -expression.o: scope.h -expression.o: target_sizes.h -expression.o: type.h -program.o: LLlex.h -program.o: Lpars.h -program.o: dbsymtab.h -program.o: def.h -program.o: f_info.h -program.o: idf.h -program.o: main.h -program.o: node.h -program.o: scope.h -statement.o: LLlex.h -statement.o: Lpars.h -statement.o: chk_expr.h -statement.o: dbsymtab.h -statement.o: def.h -statement.o: desig.h -statement.o: f_info.h -statement.o: idf.h -statement.o: main.h -statement.o: misc.h -statement.o: nocross.h -statement.o: node.h -statement.o: scope.h -statement.o: target_sizes.h -statement.o: type.h -tokenfile.o: Lpars.h -Lpars.o: Lpars.h -symbol2str.o: Lpars.h -casestat.o: LLlex.h -casestat.o: Lpars.h -casestat.o: chk_expr.h -casestat.o: dbsymtab.h -casestat.o: debug.h -casestat.o: debugcst.h -casestat.o: density.h -casestat.o: main.h -casestat.o: nocross.h -casestat.o: node.h -casestat.o: target_sizes.h -casestat.o: type.h -tmpvar.o: dbsymtab.h -tmpvar.o: debug.h -tmpvar.o: debugcst.h -tmpvar.o: def.h -tmpvar.o: main.h -tmpvar.o: nocross.h -tmpvar.o: scope.h -tmpvar.o: target_sizes.h -tmpvar.o: type.h -char.o: class.h -next.o: debug.h -next.o: debugcst.h +distr: + echo '#ifndef lint' > Version.c + echo 'char Version[] = "ACK Pascal compiler Version XXX";' | \ + sed "s/XXX/`RC -i`/" >> Version.c + echo '#endif lint' >> Version.c diff --git a/util/cpp/Makefile b/util/cpp/Makefile index 2cae78011..dfa1cf0f8 100644 --- a/util/cpp/Makefile +++ b/util/cpp/Makefile @@ -1,252 +1,5 @@ -# MAKEFILE FOR (STAND_ALONE) CEM PREPROCESSOR - -EMHOME=../.. -MODULES=$(EMHOME)/modules -MODULESLIB=$(MODULES)/lib -BIN=$(EMHOME)/lib -MANDIR=$(EMHOME)/man - -# Some paths - -# Libraries -SYSLIB = $(MODULESLIB)/libsystem.a -STRLIB = $(MODULESLIB)/libstring.a -PRTLIB = $(MODULESLIB)/libprint.a -ALLOCLIB = $(MODULESLIB)/liballoc.a -ASSERTLIB = $(MODULESLIB)/libassert.a -MALLOC = $(MODULESLIB)/malloc.o -LIBS = $(PRTLIB) $(STRLIB) $(ALLOCLIB) $(MALLOC) $(ASSERTLIB) $(SYSLIB) -LIB_INCLUDES = -I$(MODULES)/h -I$(MODULES)/pkg - -# Where to install the preprocessor -CEMPP = $(BIN)/cpp - -# What C compiler to use and how -CC = cc -COPTIONS = -LDFLAGS = - -# What parser generator to use and how -GEN = $(EMHOME)/bin/LLgen -GENOPTIONS = - -# Special #defines during compilation -CDEFS = $(LIB_INCLUDES) -CFLAGS = $(CDEFS) $(COPTIONS) -O# # we cannot pass the COPTIONS to lint! - -# Grammar files and their objects -LSRC = tokenfile.g expression.g -LCSRC = tokenfile.c expression.c Lpars.c -LOBJ = tokenfile.o expression.o Lpars.o - -# Objects of hand-written C files -CSRC = LLlex.c LLmessage.c ch7bin.c ch7mon.c domacro.c \ - error.c idf.c init.c input.c main.c options.c Version.c \ - preprocess.c replace.c scan.c skip.c tokenname.c next.c expr.c -COBJ = LLlex.o LLmessage.o ch7bin.o ch7mon.o domacro.o \ - error.o idf.o init.o input.o main.o options.o Version.o \ - preprocess.o replace.o scan.o skip.o tokenname.o next.o expr.o - -PRFILES = Makefile Parameters \ - make.hfiles make.tokcase make.tokfile LLlex.h bits.h file_info.h \ - idf.h input.h interface.h macro.h \ - class.h char.tab expression.g $(CSRC) - -# Objects of other generated C files -GOBJ = char.o symbol2str.o - -# generated source files -GSRC = char.c symbol2str.c - -# .h files generated by `make hfiles'; PLEASE KEEP THIS UP-TO-DATE! -GHSRC = errout.h idfsize.h ifdepth.h lapbuf.h \ - nparams.h numsize.h obufsize.h \ - parbufsize.h pathlength.h strsize.h textsize.h \ - botch_free.h debug.h inputtype.h dobits.h line_prefix.h - -# Other generated files, for 'make clean' only -GENERATED = tokenfile.g Lpars.h LLfiles LL.output lint.out \ - Xref hfiles cfiles charoffset.h - -all: cc - -cc: hfiles LLfiles - make "EMHOME="$(EMHOME) cpp - -hfiles: Parameters char.c charoffset.h - ./make.hfiles Parameters - @touch hfiles - -charoffset.h char.c: char.tab - $(EMHOME)/bin/tabgen -fchar.tab > char.c - -LLfiles: $(LSRC) - $(GEN) $(GENOPTIONS) $(LSRC) - @touch LLfiles - -tokenfile.g: tokenname.c make.tokfile - tokenfile.g - -symbol2str.c: tokenname.c make.tokcase - symbol2str.c - -# Objects needed for 'cpp' -OBJ = $(COBJ) $(LOBJ) $(GOBJ) -SRC = $(CSRC) $(LCSRC) $(GSRC) - -cpp: $(OBJ) Makefile - $(CC) $(COPTIONS) $(LDFLAGS) $(OBJ) $(LIBS) -o cpp - -size cpp - -cfiles: hfiles LLfiles $(GSRC) - @touch cfiles - -install: all - rm -f $(CEMPP) - cp cpp $(CEMPP) - rm -f $(MANDIR)/cpp.6 - cp cpp.6 $(MANDIR)/cpp.6 - -cmp: all - -cmp cpp $(CEMPP) - -cmp cpp.6 $(MANDIR)/cpp.6 - -pr: - @pr $(PRFILES) - -opr: - make pr | opr - -tags: cfiles - ctags $(SRC) - -depend: cfiles - sed '/^#AUTOAUTO/,$$d' Makefile >Makefile.new - echo '#AUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTO' >>Makefile.new - $(EMHOME)/bin/mkdep $(SRC) | \ - sed 's/\.c:/.o:/' >>Makefile.new - mv Makefile Makefile.old - mv Makefile.new Makefile - -xref: - ctags -x `grep "\.[ch]" Files`|sed "s/).*/)/">Xref - -lint: cfiles - lint -bx $(CDEFS) $(SRC) >lint.out - -clean: - rm -f $(LCSRC) $(OBJ) $(GENERATED) $(GSRC) $(GHSRC) cpp Out - -#AUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTOAUTO -LLlex.o: LLlex.h -LLlex.o: Lpars.h -LLlex.o: bits.h -LLlex.o: charoffset.h -LLlex.o: class.h -LLlex.o: dobits.h -LLlex.o: file_info.h -LLlex.o: idf.h -LLlex.o: idfsize.h -LLlex.o: input.h -LLlex.o: inputtype.h -LLlex.o: numsize.h -LLlex.o: strsize.h -LLmessage.o: LLlex.h -LLmessage.o: Lpars.h -LLmessage.o: file_info.h -ch7bin.o: Lpars.h -ch7mon.o: Lpars.h -domacro.o: LLlex.h -domacro.o: Lpars.h -domacro.o: bits.h -domacro.o: botch_free.h -domacro.o: charoffset.h -domacro.o: class.h -domacro.o: debug.h -domacro.o: dobits.h -domacro.o: file_info.h -domacro.o: idf.h -domacro.o: idfsize.h -domacro.o: ifdepth.h -domacro.o: input.h -domacro.o: inputtype.h -domacro.o: interface.h -domacro.o: macro.h -domacro.o: nparams.h -domacro.o: parbufsize.h -domacro.o: textsize.h -error.o: LLlex.h -error.o: errout.h -error.o: file_info.h -idf.o: idf.h -init.o: charoffset.h -init.o: class.h -init.o: idf.h -init.o: interface.h -init.o: macro.h -input.o: file_info.h -input.o: input.h -input.o: inputtype.h -main.o: file_info.h -main.o: idf.h -main.o: idfsize.h -main.o: macro.h -options.o: charoffset.h -options.o: class.h -options.o: idf.h -options.o: idfsize.h -options.o: macro.h -preprocess.o: LLlex.h -preprocess.o: bits.h -preprocess.o: charoffset.h -preprocess.o: class.h -preprocess.o: dobits.h -preprocess.o: file_info.h -preprocess.o: idf.h -preprocess.o: idfsize.h -preprocess.o: input.h -preprocess.o: inputtype.h -preprocess.o: line_prefix.h -preprocess.o: obufsize.h -replace.o: LLlex.h -replace.o: charoffset.h -replace.o: class.h -replace.o: debug.h -replace.o: file_info.h -replace.o: idf.h -replace.o: input.h -replace.o: inputtype.h -replace.o: interface.h -replace.o: macro.h -replace.o: pathlength.h -replace.o: textsize.h -scan.o: charoffset.h -scan.o: class.h -scan.o: file_info.h -scan.o: idf.h -scan.o: input.h -scan.o: inputtype.h -scan.o: interface.h -scan.o: lapbuf.h -scan.o: macro.h -scan.o: nparams.h -skip.o: LLlex.h -skip.o: charoffset.h -skip.o: class.h -skip.o: file_info.h -skip.o: input.h -skip.o: inputtype.h -tokenname.o: LLlex.h -tokenname.o: Lpars.h -tokenname.o: file_info.h -tokenname.o: idf.h -next.o: debug.h -expr.o: Lpars.h -tokenfile.o: Lpars.h -expression.o: LLlex.h -expression.o: Lpars.h -expression.o: file_info.h -Lpars.o: Lpars.h -char.o: charoffset.h -char.o: class.h -symbol2str.o: Lpars.h +distr: + echo '#ifndef lint' > Version.c + echo 'char Version[] = "ACK C preprocessor Version XXX";' | \ + sed "s/XXX/`RC -i`/" >> Version.c + echo '#endif lint' >> Version.c