home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Crawly Crypt Collection 1
/
crawlyvol1.bin
/
program
/
compiler
/
nasm20b
/
nasm_src
/
makefile
< prev
next >
Wrap
Makefile
|
1993-01-19
|
10KB
|
351 lines
#NOWARNINGS=-w-
# ----------------------------------------------------------------------
# If you don't have the environment var set, uncomment this
#
#CCDEV=g:\turbo.c
#CCDEV=c:
# ----------------------------------------------------------------------
# Things to change for other OS/Machinery are marked with
# ... ---- look here ----
# Global replace ")\" with ")/" for Unix
# Incorporate data from the various .TLK files into the link commands
TCDEBUG=-y
TDDEBUG=-l -g -y
#YACCDEBUG=-DYACCDEBUG=1
#DEBUG=-DDEBUG=1 -DLOCALDEBUG=1
YFLAGS=-v
AFLAGS=-y
# ... ---- look here ----
# ------------------------------------------------------------------------
# Change these defines according to your installation
# ------------------------------------------------------------------------
# TOS or MSDOS (UNIX maybe)
OS=TOS
EXT=.ttp
# MOTOROLA or INTEL currently
MACHINERY=MOTOROLA
#CC=
#LD=
#AS=
#YACC=
#STRIP=makefast
SRC65=lib\src
INIT=$(LIBDIR)\start.o
LIBS=-c=std65.tlk
INCLUDE=$(INCDIR)
SLOW=-p
CFLAGS=$(TCDEBUG) -i$(INCLUDE) $(NOWARNINGS) -a -D$(OS) -D$(MACHINERY)
IFLAGS=-i$(INCLUDE)
LFLAGS=$(TDDEBUG) -s=32000
.SUFFIXES:
.SUFFIXES: $(EXT) .s .o .i .c .y
.c.o:
$(CC) $(CFLAGS) $<
.o$(EXT):
$(LD) $(LFLAGS) $(INIT) -o=$*$(EXT) $*.o $(LIBS)
$(STRIP) $*$(EXT)
.c.i:
$(CPP) -o=$*.i $(CFLAGS) $<
.i.o:
$(CC) $(CFLAGS) $<
# ------------------------------------------------------------------------
# Until here! Keeping looking for more...
# ------------------------------------------------------------------------
PRGS=nasm65$(EXT) nlink65$(EXT) nlib65$(EXT)
SUPPORT=xtrctbin$(EXT) chkffff$(EXT) demac65$(EXT) disasm65$(EXT) crlf155$(EXT) nasm$(EXT)
ADEPS=main65.o asm65.o ops.o exprasm.o helper.o input.o segment.o \
error.o debug.o if.o symbols.o object.o macro.o process.o \
lexer.o expr.o imm.o immasm.o labels.o ndebug.o errorasm.o \
sym_asm.o stats.o hash.o float.o io.o fix.o version0.o \
p_debug.o
LDEPS=link65.o worker.o err_link.o lsymbols.o sym_link.o imm.o \
lexpr.o error.o exprlink.o lsegment.o debug.o helper.o \
lload.o lreloc.o stats.o load.o hash.o fix.o \
link.o libfix.o libflip.o version0.o lp_debug.o
DDEPS=disasm.o version0.o helper.o dload.o error.o stats.o debug.o
IDEPS=lib65.o libwork.o error.o debug.o helper.o errorlib.o stats.o \
libflip.o libfix.o version0.o
NXDEPS=nasm.o error.o helper.o debug.o stats.o
DEPSI=main65.i asm65.i ops.i exprasm.i helper.i input.i segment.i \
error.i debug.i if.i symbols.i object.i macro.i process.i \
lexer.i expr.i imm.i immasm.i labels.i ndebug.i errorasm.i \
sym_asm.i stats.i hash.i float.i io.i link65.i worker.i \
err_link.i lsymbols.i sym_link.i lexpr.i exprlink.i segment.i \
lload.i lreloc.i lib65.i libwork.i errorlib.i load.i \
libfix.i libflip.i version0.i
ASCII=*.c *.h *.y *.tlk demo\*.[hsl]* doc\* lib\src\*.s65 header\*
TABASCII=makefile makeback.up demo\makefile lib\src\makefile
all: $(PRGS) support
it: nasm65$(EXT) nlink65$(EXT)
install: $(PRGS) support
$(SHELL) cp $(PRGS) $(SUPPORT) $(BINDIR)
backup:
make -f makeback.up backup
restore:
make -f makeback.up restore
to_us: crlf155$(EXT)
crlf155 -s -u $(ASCII)
crlf155 -s $(TABASCII)
untabify: crlf155$(EXT)
crlf155 -s -n -u $(ASCII)
support: $(SUPPORT)
cpp: $(DEPSI) xtrctbin.i chkffff.i de_mac.i disasm.i crlf155.i
# ... ---- look here ----
### ******************** CHANGE THESE ***********************
portable$(EXT): portable.o
$(LD) $(LFLAGS) $(INIT) -o=portable$(EXT) portable.o $(LIBS)
nasm$(EXT): $(NXDEPS)
$(LD) $(LFLAGS) $(INIT) -c=nasm.tlk -o=nasm$(EXT)
# $(STRIP) nasm65$(EXT)
nasm65$(EXT): $(ADEPS)
$(LD) $(LFLAGS) $(INIT) -c=asm65.tlk -o=nasm65$(EXT)
# $(STRIP) nasm65$(EXT)
nlink65$(EXT): $(LDEPS)
$(LD) $(LFLAGS) $(INIT) -c=link65.tlk -o=nlink65$(EXT)
# $(STRIP) nlink65$(EXT)
nlib65$(EXT): $(IDEPS)
$(LD) $(LFLAGS) $(INIT) -c=lib65.tlk -o=nlib65$(EXT)
# $(STRIP) nlib65$(EXT)
disasm65$(EXT): $(DDEPS)
$(LD) $(LFLAGS) $(INIT) -c=disasm65.tlk -o=disasm65$(EXT)
# $(STRIP) disasm65$(EXT)
demac65$(EXT): de_mac.o
$(LD) $(LFLAGS) $(INIT) -o=demac65$(EXT) de_mac.o $(LIBS)
# $(STRIP) demac65$(EXT)
crlf155$(EXT): crlf155.o
$(LD) $(LFLAGS) $(INIT) -o=crlf155$(EXT) crlf155.o $(LIBS)
# $(STRIP) crlf155$(EXT)
xtrctbin$(EXT): xtrctbin.o
$(LD) $(LFLAGS) $(INIT) -o=xtrctbin$(EXT) xtrctbin.o $(LIBS)
# $(STRIP) xtrctbin$(EXT)
chkffff$(EXT): chkffff.o
$(LD) $(LFLAGS) $(INIT) -o=chkffff$(EXT) chkffff.o $(LIBS)
# $(STRIP) chkffff$(EXT)
# ******************* LOOK BELOW FOR MORE *************************
main65.o: main65.c defines.h nmalloc.h buffer.h debug.h
$(CC) $(SLOW) $(CFLAGS) $(DEBUG) $(YACCDEBUG) main65.c
debug.o: debug.c defines.h
$(CC) $(SLOW) $(CFLAGS) $(DEBUG) debug.c
err_link.o: err_link.c defines.h
$(CC) $(SLOW) $(CFLAGS) err_link.c
error.o: error.c defines.h
$(CC) $(SLOW) $(CFLAGS) error.c
errorasm.o: errorasm.c defines.h structs.h y_tab.h buffer.h ops.h
$(CC) $(SLOW) $(CFLAGS) errorasm.c
errorlib.o: errorlib.c err_link.o
$(CC) $(SLOW) $(CFLAGS) errorlib.c
expr.o: expr.c defines.h op.h debug.h labels.h structs.h \
nmalloc.h code.h exprfast.h
$(CC) $(CFLAGS) expr.c
exprasm.o: exprasm.c defines.h debug.h labels.h structs.h code.h \
nmalloc.h exprfast.h op.h
$(CC) $(CFLAGS) exprasm.c
exprlink.o: exprlink.c defines.h debug.h structs.h
$(CC) $(CFLAGS) exprlink.c
fix.o: fix.c defines.h debug.h structs.h nmalloc.h code.h fix.h \
labels.h seg.h
$(CC) $(CFLAGS) fix.c
float.o: float.c defines.h
$(CC) $(SLOW) $(CFLAGS) float.c
# ... ---- look here ----
##### uncomment this if you can't use MAS ####
#hash.o: hash.c defines.h
# $(CC) $(CFLAGS) hash.c
##### and comment this out
hash.o: xhash.s
$(AS) $(AFLAGS) -o=hash.o xhash.s
#####
helper.o: helper.c defines.h debug.h stats.h code.h
$(CC) $(CFLAGS) helper.c
if.o: if.c defines.h labels.h y_tab.h debug.h buffer.h
$(CC) $(CFLAGS) if.c
imm.o: imm.c defines.h debug.h structs.h imm.h nmalloc.h
$(CC) $(CFLAGS) imm.c
immasm.o: immasm.c defines.h debug.h imm.h op.h
$(CC) $(CFLAGS) immasm.c
input.o: input.c defines.h structs.h debug.h nmalloc.h \
buffer.h
$(CC) $(CFLAGS) input.c
io.o: io.c defines.h structs.h debug.h nmalloc.h buffer.h
$(CC) $(SLOW) $(CFLAGS) io.c
labels.o: labels.c defines.h debug.h labels.h structs.h code.h \
fix.h exprfast.h
$(CC) $(CFLAGS) labels.c
lexer.o: lexer.c md_suck.c defines.h y_tab.h structs.h debug.h code.h \
nmalloc.h code.h inputfst.h
$(CC) $(CFLAGS) lexer.c
lexpr.o: lexpr.c expr.o defines.h
$(CC) $(CFLAGS) lexpr.c
p_debug.o: p_debug.c defines.h debug.h structs.h
$(CC) $(CFLAGS) p_debug.c
lp_debug.o: p_debug.o defines.h
$(CC) $(CFLAGS) lp_debug.c
lib65.o: lib65.c defines.h debug.h structs.h object.h lib.h \
nmalloc.h
$(CC) $(CFLAGS) lib65.c
libwork.o: libwork.c defines.h debug.h code.h nmalloc.h structs.h \
object.h lib.h
$(CC) $(CFLAGS) libwork.c
libflip.o: libflip.c defines.h debug.h structs.h object.h lib.h \
code.h
$(CC) $(CFLAGS) libflip.c
libfix.o: libfix.c defines.h debug.h structs.h object.h lib.h \
code.h
$(CC) $(CFLAGS) libfix.c
link.o: link.c defines.h debug.h nmalloc.h labels.h structs.h \
object.h seg.h imm.h process.h exprfast.h
$(CC) $(CFLAGS) link.c
link65.o: link65.c defines.h structs.h debug.h nmalloc.h code.h
$(CC) $(CFLAGS) link65.c
lload.o: lload.c defines.h debug.h nmalloc.h labels.h structs.h \
object.h code.h lib.h
$(CC) $(CFLAGS) lload.c
dload.o: dload.c load.o
$(CC) $(CFLAGS) dload.c
load.o: load.c defines.h debug.h nmalloc.h structs.h object.h \
code.h
$(CC) $(CFLAGS) load.c
lreloc.o: lreloc.c defines.h debug.h seg.h structs.h labels.h imm.h \
process.h
$(CC) $(CFLAGS) lreloc.c
lsymbols.o: lsymbols.c symbols.o
$(CC) $(CFLAGS) lsymbols.c
macro.o: macro.c y_tab.h defines.h labels.h structs.h debug.h nmalloc.h \
buffer.h inputfst.h code.h
$(CC) $(CFLAGS) macro.c
ndebug.o: ndebug.c y_tab.h defines.h structs.h
$(CC) $(SLOW) $(CFLAGS) ndebug.c
object.o: object.c defines.h labels.h structs.h seg.h object.h debug.h \
code.h imm.h
$(CC) $(SLOW) $(CFLAGS) object.c
ops.o: ops.c defines.h ops.h
$(CC) $(SLOW) $(CFLAGS) ops.c
process.o: process.c defines.h structs.h labels.h seg.h op.h \
nmalloc.h object.h fix.h process.h code.h debug.h
$(CC) $(CFLAGS) process.c
lsegment.o: segment.o lsegment.c
$(CC) $(CFLAGS) lsegment.c
segment.o: segment.c defines.h debug.h nmalloc.h structs.h code.h \
seg.h
$(CC) $(CFLAGS) segment.c
stats.o: stats.c defines.h structs.h imm.h seg.h nmalloc.h
$(CC) $(SLOW) $(CFLAGS) stats.c
sym_asm.o: sym_asm.c defines.h debug.h labels.h structs.h \
exprfast.h
$(CC) $(CFLAGS) sym_asm.c
sym_link.o: sym_link.c defines.h debug.h labels.h structs.h
$(CC) $(CFLAGS) sym_link.c
symbols.o: symbols.c defines.h debug.h labels.h structs.h nmalloc.h
$(CC) $(CFLAGS) symbols.c
version0.o: version0.c structs.h object.h defines.h
$(CC) $(SLOW) $(CFLAGS) version0.c
worker.o: worker.c defines.h debug.h nmalloc.h structs.h \
object.h process.h
$(CC) $(SLOW) $(CFLAGS) worker.c
asm65.c: asm65.y
yacc $(YFLAGS) asm65.y
$(SHELL) mv y_tab.c asm65.c
asm65.o: asm65.c defines.h labels.h structs.h code.h buffer.h \
exprfast.h op.h
$(CC) $(CFLAGS) asm65.c
defines.h: localdef.h
$(SHELL) touch defines.h
localdef.h: portable$(EXT)
portable$(EXT) x