# Makefile ################################################################# # File dependencies and instructions for building EAL assembler # # Authorship and Revision History: # # V0.0: Douglas W. Jones, June 26, 2003 # # V1.0: Douglas W. Jones, June 16, 2004 # #MP1# # V2.0: Douglas W. Jones, June 28, 2004 # #MP2# # # # Instructions: # # make -- builds eal, the assembler # # make eal -- builds eal explicitly # # make clean -- deletes eal and all intermediate files # # make shar -- builds eal.shar, for archive or export # # # ################################################################# VERSION = "\"V2.0\"" AUTHOR = "\"Douglas W. Jones\"" ################################################################# # Configuration constants # # you may need to change some of these! # ################################################################# # what C compiler to use (HP-UX choices are c89, gcc, CC, g++, cc -Aa) CC = cc # maximum length of an output file name NAMELEN = 80 # maximum length of an input line LINELEN = 80 # number of symbol table entries permitted SYMSIZE = 64 # size of string pool POOLSIZE = 256 ################################################################# # File dependencies # ################################################################# OBJECTS = main.o parser.o lexical.o objectcode.o symboltable.o stringpool.o eal: $(OBJECTS) $(CC) -o eal $(OBJECTS) MAINDEFS = -DNAMELEN=$(NAMELEN) -DVERSION=$(VERSION) -DAUTHOR=$(AUTHOR) main.o: main.c Makefile main.o: parser.h lexical.h objectcode.h symboltable.h stringpool.h main.o: exception.h boolean.h $(CC) -c $(MAINDEFS) main.c parser.o: parser.c Makefile parser.o: parser.h lexical.h objectcode.h symboltable.h parser.o: stringpool.h exception.h $(CC) -c -DSYMSIZE=$(SYMSIZE) parser.c LEXDEFS = -DLINELEN=$(LINELEN) -DVERSION=$(VERSION) -DAUTHOR=$(AUTHOR) lexical.o: lexical.c Makefile lexical.o: lexical.h objectcode.h symboltable.h boolean.h $(CC) -c $(LEXDEFS) lexical.c objectcode.o: objectcode.c boolean.h $(CC) -c objectcode.c symboltable.o: symboltable.c Makefile symboltable.o: symboltable.h stringpool.h exception.h $(CC) -c -DSYMSIZE=$(SYMSIZE) symboltable.c stringpool.o: stringpool.c Makefile stringpool.o: stringpool.h exception.h $(CC) -c -DPOOLSIZE=$(POOLSIZE) stringpool.c clean: rm -f *.o eal shar: shar README Makefile *.c *.h > eal.shar