--- gforth/Attic/Makefile 1994/06/17 13:28:31 1.5 +++ gforth/Attic/Makefile 1994/08/25 15:25:18 1.12 @@ -2,13 +2,14 @@ RM = echo 'Trying to remove' GCC = gcc +FORTH = gforth CC = gcc -SWITCHES = -D_POSIX_VERSION -DDEFAULTBIN='"'$(PWD)'"' #-DUSE_TOS -DUSE_FTOS # -DDIRECT_THREADED +SWITCHES = -D_POSIX_VERSION -DUSE_FTOS -DDEFAULTBIN='"'`pwd`'"' -DDIRECT_THREADED -fcaller-saves #-DNDEBUG #turn off assertions CFLAGS = -O4 -Wall -g $(SWITCHES) #-Xlinker -n puts text and data into the same 256M region #John Wavrik should use -Xlinker -N to get a writable text (executable) -LDFLAGS = -g # -Xlinker -N +LDFLAGS = -g -Xlinker -N LDLIBS = -lm EMACS = emacs @@ -26,7 +27,7 @@ SOURCES = Makefile primitives primitives RCS_FILES = $(SOURCES) INSTALL ToDo model high-level -GEN = ansforth +GEN = gforth GEN_PRECIOUS = primitives.i prim_labels.i primitives.b prim_alias.4th aliases.fs @@ -34,9 +35,9 @@ OBJECTS = engine.o io.o main.o # things that need a working forth system to be generated # this is used for antidependences, -FORTH_GEN = primitives.i prim_labels.i prim_alias.4th kernal.32limg +FORTH_GEN = primitives.i prim_labels.i prim_alias.4th kernl32l.fi kernl32b.fi -all: ansforth aliases.fs +all: gforth aliases.fs #from the gcc Makefile: #"Deletion of files made during compilation. @@ -60,16 +61,21 @@ realclean: distclean current: $(RCS_FILES) -ansforth: $(OBJECTS) $(FORTH_GEN) - -cp ansforth ansforth.old +gforth: $(OBJECTS) $(FORTH_GEN) + -cp gforth gforth.old $(GCC) $(LDFLAGS) $(OBJECTS) $(LDLIBS) -o $@ -kernal.32limg: search-order.fs cross.fs aliases.fs vars.fs add.fs \ - environ.fs errore.fs kernal.fs extend.fs tools.fs toolsext.fs \ - $(FORTH_GEN) - -cp kernal.32limg kernal.32limg.old - ansforth "include main.fs" - +kernl32l.fi: main.fs search-order.fs cross.fs aliases.fs vars.fs add.fs \ + errore.fs kernal.fs extend.fs tools.fs toolsext.fs \ + machine32l.fs $(FORTH_GEN) + -cp kernl32l.fi kernl32l.fi.old + $(FORTH) -e 's" machine32l.fs" r/o open-file throw' main.fs + +kernl32b.fi: main.fs search-order.fs cross.fs aliases.fs vars.fs add.fs \ + errore.fs kernal.fs extend.fs tools.fs toolsext.fs \ + machine32b.fs $(FORTH_GEN) + -cp kernl32b.fi kernl32b.fi.old + $(FORTH) -e 's" machine32b.fs" r/o open-file throw' main.fs engine.s: engine.c primitives.i prim_labels.i machine.h $(INCLUDES) $(GCC) $(CFLAGS) -S engine.c @@ -80,22 +86,20 @@ primitives.b: primitives m4 primitives >$@ primitives.i : primitives.b prims2x.fs - ansforth "include prims2x.fs s\" primitives.b\" ' output-c process-file bye" | awk -f from-cut-here >$@ + $(FORTH) prims2x.fs -e "s\" primitives.b\" ' output-c process-file bye" >$@ prim_labels.i : primitives.b prims2x.fs - ansforth "include prims2x.fs s\" primitives.b\" ' output-label process-file bye" | awk -f from-cut-here >$@ - -prim_alias.4th: primitives.b prims2x.fs - ansforth "include prims2x.fs s\" primitives.b\" ' output-alias process-file bye" | awk -f from-cut-here >$@ + $(FORTH) prims2x.fs -e "s\" primitives.b\" ' output-label process-file bye" >$@ -aliases.fs: prim_alias.4th - cp prim_alias.4th $@ +aliases.fs: primitives.b prims2x.fs + $(FORTH) prims2x.fs -e "s\" primitives.b\" ' output-alias process-file bye" >$@ #primitives.4th: primitives.b primitives2c.el # $(EMACS) -batch -load primitives2c.el -funcall make-forth #GNU make default rules -% :: RCS/%,v - co $@ -%.o : %.c $(INCLUDES) - $(CC) $(CFLAGS) -c $< -o $@ +#% :: RCS/%,v +# co $@ +#%.o : %.c $(INCLUDES) +# $(CC) $(CFLAGS) -c $< -o $@ +