File:  [Research Unix] / researchv10no / cmd / sml / src / runtime / Makefile.mips
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Tue Apr 24 17:21:34 2018 UTC (8 years, 1 month ago) by root
Branches: belllabs, MAIN
CVS tags: researchv10, HEAD
researchv10 Norman

NOTANGLE=notangle
NOWEAVE=noweave
AWK=nawk
CC=cc
CPP=/lib/cpp

WARNS=@echo -n ""	# no warning message by default 

.SUFFIXES: .nw .sml .sig .awk .tex .dvi .s .print 

.nw.sml:
	$(NOTANGLE) $*.nw > $*.sml

.nw.sig:
	$(NOTANGLE) -Rsignature $*.nw > $*.sig

.nw.s:
	$(NOTANGLE) $*.nw > $*.s

.nw.awk:
	$(NOTANGLE) $*.nw > $*.awk

.nw.tex:
	$(NOWEAVE) $*.nw > $*.tex

.tex.dvi:
	tex $*.tex

.nw.dvi:
	$(NOWEAVE) $*.nw > $*.tex
	tex $*.tex


#SUN3
#MACHINE = M68
#DEFS = -DBSD -DSUN3
#CFL = -n -Bstatic -f68881
#ASMBLR = as

#SONY
#MACHINE = M68
#DEFS =  -DBSD
#CFL =
#ASMBLR = /mnt/brown/toe/gas/a68  # the GNU assembler, that is

#SUN4
#MACHINE = SPARC
#DEFS = -DBSD
#CFL = -n -Bstatic
#ASMBLR = as

#ENCORE
#MACHINE = NS32
#DEFS =  -DBSD
#CFL =
#ASMBLR = as -j

#NEXT
#MACHINE = M68
#DEFS = -DBSD -DMACH
#CFL =
#ASMBLR = as

#VAXBSD
#MACHINE = VAX
#DEFS = -DBSD  '-DMODIR="mo.vax"'
#CFL = 
#ASMBLR = as

#VAXV9
#MACHINE = VAX
#DEFS = -DV9
#CFL = 
#ASMBLR = as

#PMAX
MACHINE = MIPS
DEFS = -DBSD '-DMODIR="mo.mips"'
ASMBLR = as
WARNS =@echo 'Expect exactly one warning about a macro instruction using $$at'

DEFINES = -D$(MACHINE) $(DEFS)
CFLAGS = -g $(CFL) $(DEFINES)
#CFLAGS = -O $(CFL) $(DEFINES)

# Other possible #define's:
# PROFILE:  for a run which counts allocs.
# GCDEBUG:  print extra information during garbage collection,
#	    examine the to_space after a collection for stray pointers,
#	    and check create_b and create_s for zero allocation.
# GCPROFILE: for a run which prints out cumulative garbage collector
#	     information as it exits.

run: run.o gc.o callgc.o prim.o prof.o export.o objects.o cstruct.o trace.o allmo.o cache.o
	$(CC) $(CFLAGS) -o run.mips run.o gc.o callgc.o prim.o prof.o export.o objects.o cstruct.o trace.o cache.o -lc allmo.o
	nm run.mips | sort > loadmap

allmo.o: allmo.s
	TMPDIR=/usr/tmp/ ; export TMPDIR ; $(ASMBLR) $(DEFINES) $(CFLAGS) -o allmo.o allmo.s

allmo.s: STUB.allmo.s
	/bin/cp STUB.allmo.s allmo.s

linkdata: linkdata.c
	$(CC) $(CFLAGS) -o linkdata linkdata.c

prim.o: $(MACHINE).prim.s tags.h prof.h ml.h prim.h
	$(CC) $(CFLAGS) -E $(MACHINE).prim.s | sed '/^#.*$$/d' > prim.s
	# make sure there is no line number info; it breaks dbx
	$(WARNS)
	$(ASMBLR) $(CFLAGS) -o prim.o prim.s

callgc.o objects.o gc.o run.o trace.o: descriptor.h tags.h

callgc.o run.o export.o objects.o: ml.h

prof.o: prof.h

clean:
	rm -f *.o lint.out prim.s linkdata allmo.s

lint:
	lint $(DEFINES) run.c gc.c callgc.c prof.c export.c objects.c cstruct.c trace.c | tee lint.out

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.