view Makefile @ 65:8ad746efa4f8

*** empty log message ***
author kono
date Thu, 20 Feb 2003 08:56:29 +0900
parents 129f4802b027
children 0b068058dd67
line wrap: on
line source

CC = gcc
CFLAGS = -g -Wall -I.
BASE=0
STAGE=1
MFLAGS=$(MFALGS) BASE=$(BASE) STAGE=$(STAGE)
MC=mc
PRINTF= # printf.c
CONVERTER=conv/c.o conv/c2cbc.o conv/cbc2c.o conv/null.o

all: mc 

mc : mc-parse.o mc-codegen.o mc-code-ia32.o mc-tree.o $(CONVERTER)
	$(CC) -g mc-parse.o mc-codegen.o mc-code-ia32.o \
		mc-tree.o $(CONVERTER) -o $@

tar :
	make clean
	tar cBf - . | gzip > ../comp.tgz 

depend :
	makedepend mc-parse.c mc-nop-386.c mc-tree.c

clean :
	-rm -f *.s *.o mc mc1 a.out *~ core* */*.o

mc1 : b00.s b01.s mc-codegen.o mc-tree.o $CONVERTER
	$(CC) -g -o $@ $(PRINTF) b00.s b01.s mc-codegen.o mc-tree.o $CONVERTER
b00.s : mc-parse.c mc
	./mc -s -ob00.s mc-parse.c
b01.s : mc-code-ia32.c mc
	./mc -s -ob01.s mc-code-ia32.c 
b10.s : mc-parse.c mc1
	./mc1 -s -ob10.s mc-parse.c
b11.s : mc-code-ia32.c $(PRINTF) mc1
	./mc1 -s -ob11.s mc-code-ia32.c 

diff :  b00.s b01.s b10.s b11.s
	-diff b00.s b10.s
	-diff b01.s b11.s
# DO NOT DELETE

mc-parse.o: mc.h stdio.h
mc-nop-386.o: mc.h stdio.h
mc-tree.o: mc.h stdio.h