CFLAGS=-g -Wall -Wa,-adhln

# -g:    enable debugging
# -Wall: print all warning messages
# -Wa:   pass comma separated options to the assembler
# -a:    turn on listings
# -h:    include high level source
# -l;    include assembly

all: hello

hello.s: hello.c
	$(CC) $(CFLAGS) -S  $? 

hello.o: hello.s
	$(CC) $(CFLAGS) -c -o $@ $? > hello.lst

hello: hello.o
	$(CC) -o $@ $?

.PHONY:
clean:
	$(RM) *.o *.s *.lst *~ hello
