Makefile
e00cf938
 # All *sort.c files result in a *sort program, and optionally a *sort.s
 # assembly listing.
 SRCS = $(wildcard *sort.c)
 PROGS = $(patsubst %.c,%,$(SRCS))
 ASMS =  $(patsubst %.c,%.s,$(SRCS))
 
 CC=gcc
 RM=rm -f
 CFLAGS=-Wall -g
 
 
 all: $(PROGS)
 
 asm: $(ASMS)
 
 clean:
 	$(RM) $(PROGS) ${ASMS}
 
 %sort: %sort.c common.c
 	$(CC) $(CFLAGS) -o $@ $<
 
 %sort.s: %sort.c common.c
 	${CC} ${CFLAGS} -S -o $@ $<