|
|
1.1 root 1: #
2: #
3: # $Header: /na/franz/franz/vax/RCS/Makefile,v 1.3 83/03/23 22:33:01 jkf Exp $
4: #
5: # Franz Lisp C coded kernel
6: #
7: #-- Default Paths:
8: # see ../../ReadMe for a explaination of what LibDir and CopyTo mean
9: # D is the directory used for holding intermediate files during
10: # compilation
11: #-- Options:
12: # there is one compile time options which can be set in this file
13: # * do profiling (ala the unix prof(1) command)
14: #
15: # The selection of this options is made below
16: # Other options can be selected by editing h/config.h or via
17: # ../../lispconf
18: #
19: AS = unixas # Generate VMS object files
20: LD = unixld # Generate VMS object files
21: CFLAGS = -DEUNICE_UNIX_OBJECT_FILE_CFASL # enable UNIX object CFASL
22:
23: LibDir = /usr/lib/lisp
24: ObjDir = /usr/ucb
25: CopyTo = /dev/null
26: Liszt = liszt
27: Lisp = lisp
28: # if you change this you must recompile rlc.c
29: # (and change the value in ../Makefile)
30: #
31: HOLE=2097152
32:
33: .DEFAULT: nlisp
34:
35: MipSrc1= ../low.c
36: MipSrc2= ../alloc.c ../data.c
37: MipSrc3=
38: MipSrc4= ../lisp.c ../eval.c ../eval2.c ../inits.c ../io.c ../error.c \
39: ../sysat.c ../lam1.c ../lam2.c ../lam3.c ../lam4.c ../lam5.c\
40: ../lam6.c ../lam7.c ../lam8.c ../lam9.c ../lamr.c ../lamp.c \
41: ../fex1.c ../fex2.c ../fex3.c ../fex4.c ../fexr.c\
42: ../fpipe.c \
43: ../subbig.c ../pbignum.c ../divbig.c \
44: ../ffasl.c ../fasl.c \
45: ../trace.c ../evalf.c ../frame.c ../lamgc.c
46:
47: MipSrc = ${MipSrc1} ${MipSrc2} ${MipSrc3} ${MipSrc4}
48:
49: MipObj1= ../low.o
50: MipObj2= ../alloc.o ../data.o
51: HoleMipObj2 = ../Salloc.o ../Sdata.o
52: HoleMipObj3 =
53: MipObj4= ../lisp.o ../eval.o ../eval2.o ../inits.o ../io.o ../error.o \
54: ../sysat.o ../lam1.o ../lam2.o ../lam3.o ../lam4.o ../lam5.o\
55: ../lam6.o ../lam7.o ../lam8.o ../lam9.o ../lamr.o ../lamp.o \
56: ../fex1.o ../fex2.o ../fex3.o ../fex4.o ../fexr.o\
57: ../fpipe.o \
58: ../subbig.o ../pbignum.o ../divbig.o \
59: ../ffasl.o ../fasl.o \
60: ../trace.o ../evalf.o ../frame.o ../lamgc.o
61:
62: # this list must contain all the include files, not just those used
63: # in the vax version. The include filenames are relative to ..
64: #
65: Includes = h/config.h h/global.h h/oaout.h h/vaxframe.h \
66: h/catchfram.h h/dfuncs.h h/gtabs.h h/sigtab.h \
67: h/chars.h h/frame.h h/lfuncs.h h/structs.h \
68: h/chkrtab.h h/gc.h h/naout.h h/types.h \
69: h/lconf.h h/ltypes.h
70:
71: #------ Options
72:
73: #--- profiling selection
74: # If the lisp system is to run with profiling, this must be done:
75: # 1) remove the # (comment character) from the ProfFlag and
76: # ProfFlag2 definitions below (also do it in ../Makefile)
77: # 2) remove all .o files and do a make.
78: #
79: ProfFlag = # -XP
80: ProfFlag2 = # -DPROF
81:
82:
83: # The order of loading of certain files is important.
84: # low.o must be first and lowaux second.
85: #
86: BottomObj = ${MipObj1} ../lowaux.o
87: HBottomObj = ${MipObj1} hlowaux.o
88:
89: # Different objects are required depending on whether there is to be
90: # a hole between text and data space.
91: #
92: NoHoleObj = ${MipObj2}
93: HoleObj = ${HoleMipObj2} ${HoleMipObj3}
94:
95: VaxObj = bigmath.o qfuncl.o vax.o prealloc.o
96:
97: VaxSrc = bigmath.c qfuncl.c vax.c crt0.s hcrt0.s lowaux.s
98:
99: # AllSrc does not (and should not) include ${Includes}
100:
101: AllSrc = Makefile fixmask.c fixpbig.e ${VaxSrc} ${MipSrc}
102:
103:
104: .SUFFIXES : .c.l
105: #
106: # use temporary files rather than pipes to keep the number of procs. down
107: # thus, users with low process quotas on VMS can still build lisp
108: #
109: .c.o :
110: @csh -cfe "echo cc -c $*.c;\
111: rm -f $*.o;\
112: /lib/cpp ${CFLAGS} $< -I../h > $*.tm0;\
113: /lib/ccom ${ProfFlag} $*.tm0 $*.tm1;\
114: fixmask <$*.tm1 >$*.tm2;\
115: sed -f fixpbig.e <$*.tm2 >$*.tm3;\
116: /lib/c2 $*.tm3 >$*.tms;\
117: ${AS} -o $*.o $*.tms;\
118: rm $*.tms $*.tm0 $*.tm1 $*.tm2 $*.tm3"
119:
120: .l.o :
121: liszt $< > #resc
122: @echo liszt $< done
123:
124: # one special case:
125: # add -DPROF if you want to profile the assembler code
126:
127: # EXPLICITLY USE "unixcpp" SO THAT "$"s IN ASSEMBLER CODE WORK!
128: qfuncl.o: qfuncl.c
129: /lib/unixcpp -I../h ${ProfFlag2} qfuncl.c | ${AS} -o qfuncl.o
130:
131: bigmath.o: bigmath.c
132: /lib/unixcpp -I../h ${ProfFlag2} bigmath.c | ${AS} -o bigmath.o
133:
134: ../rlc.o: ../rlc.c
135: cc -S -O ${CFLAGS} -DHOLE=${HOLE} ../rlc.c
136: ${AS} -o rlc.o rlc.s
137: rm rlc.s
138: mv rlc.o ../rlc.o
139:
140: ../low.o: ../low.c
141: cc ${CFLAGS} -I../h -R -S ../low.c
142: ${AS} -R -o low.o low.s
143: rm low.s
144: mv low.o ../low.o
145:
146: ../Salloc.o: ../alloc.c
147: (echo "# define HOLE ${HOLE}"; cat ../alloc.c) > Salloc.c;\
148: make Salloc.o; mv Salloc.o .. < /dev/null ; rm Salloc.c
149:
150: ../Sdata.o: ../data.c
151: (echo "# define HOLE ${HOLE}"; cat ../data.c) > Sdata.c;\
152: make Sdata.o; mv Sdata.o .. < /dev/null ; rm Sdata.c
153:
154: fixmask: fixmask.c
155: cc -O -o fixmask fixmask.c
156:
157: # rawlisp is the standard raw lisp system.
158:
159: rawlisp: fixmask fixpbig.e \
160: ${BottomObj} ${NoHoleObj} ${MipObj4} ${VaxObj}
161: rm -f rawlisp
162: ld -noshare -nop0bufs -x -o rawlisp ${BottomObj} /lib/crt0.o \
163: ${NoHoleObj} ${VaxObj} ${MipObj4} \
164: /lib/fastexecp.o -lm -lc -ltermlib
165: ls -l rawlisp
166:
167:
168: # hlisp is a raw lisp system with a hole between text and data
169:
170: rawhlisp: fixmask fixpbig.e ${HBottomObj} ${HoleObj} ${MipObj4} ${VaxObj}
171: rm -f rawhlisp
172: ld -noshare -nop0bufs -x -o rawhlisp ${HBottomObj} \
173: /lib/crt0.o ${HoleObj} \
174: ${VaxObj} ${MipObj4} \
175: /lib/fastexecp.o -lm -lc -ltermlib
176: ls -l rawhlisp
177:
178: hlowaux.o: ../lowaux.s
179: sed "s/holbeg:/holbeg: .space ${HOLE}/" <../lowaux.s >hlowaux.s
180: ${AS} -o hlowaux.o hlowaux.s
181: rm -f hlowaux.s
182:
183:
184: clean:
185: rm -f *.o
186:
187: lint:
188: lint h/*.h *.c
189:
190: install: nlisp
191: -rm -f ${ObjDir}/lisp
192: mv nlisp ${ObjDir}/lisp
193: @echo lisp installed
194:
195: nlisp: rawlisp ${LibDir}
196: -rm -f nlisp
197: (cd ${LibDir} ; make Liszt=${Liszt} required)
198: echo "(progn (setq build:map 'map \
199: build:lisp-type 'franz \
200: lisp-library-directory '${LibDir} \
201: build:dir '${LibDir} \
202: lisp-object-directory '${ObjDir}) \
203: (load '${LibDir}/buildlisp)\
204: (dumplisp nlisp))" | rawlisp
205: ${LibDir}/tackon map nlisp
206: @echo nlisp built
207:
208:
209: donlisp:
210: -rm -f nlisp
211: make LibDir=${LibDir} Liszt=${Liszt} ObjDir=${ObjDir} nlisp
212:
213: #--- snlisp: create a totally interpreted lisp.
214: # dump as snlisp
215: snlisp: rawlisp
216: echo "(progn (setq build:load t \
217: build:lisp-type 'franz \
218: build:dir '${LibDir} \
219: lisp-object-directory '${ObjDir}\
220: lisp-library-directory '${LibDir})\
221: (load '${LibDir}/buildlisp)\
222: (dumplisp snlisp))" | rawlisp
223:
224:
225: tags:
226: ctags $(VaxSrc) ${MipSrc}
227:
228: #--- copysource : copy source files to another directory
229: # called via make CopyTo=/xx/yyy/zz copysource
230: #
231: copysource: ${AllSrc}
232: (tar cf - ${AllSrc} | (cd ${CopyTo} ; tar xf -))
233:
234: copyobjects: ${AllObj}
235: (tar cf - ${AllObj} | (cd ${CopyTo} ; tar xf -))
236:
237: scriptcatall: ${AllSrc}
238: @../../scriptcat . franz/vax ${AllSrc}
239: @../../scriptcat .. franz ${Includes}
240:
241:
242: #--- prealloc.o: the "C" runtime startup for EUNICE with data structure
243: # preallocation and restart capabilities
244: # NFILES - # file descriptors of data structure to allocate
245: # RESTART - allow restart from saved image
246: #
247: prealloc.o: Makefile
248: /lib/cpp -DNFILES=20 -DRESTART /usr/include/eunice/prealloc.c prealloc.tm0
249: /lib/ccom prealloc.tm0 prealloc.tm1
250: /lib/c2 prealloc.tm1 prealloc.tm2
251: sed -f /usr/include/eunice/sedfixup.e <prealloc.tm2 >prealloc.tm3
252: ${AS} -o prealloc.o prealloc.tm3
253: rm prealloc.tm0 prealloc.tm1 prealloc.tm2 prealloc.tm3
254:
255: totxtfile: totxtfile.c
256: cc -O totxtfile.c -o totxtfile
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.