1 2 3 4 5 6 7 8 9 10 11 12 13 14
CC = gcc CFLAGS = -Wall OBJS = main.o all: maccalc %.o: %.c $(CC) $(CFLAGS) -c -o $@ $< maccalc: $(OBJS) $(CC) -o $@ $(OBJS) clean: rm -f maccalc *.o