#Created by Shaun D. Ramsey on June 3, 2005 # $@ is the name of the target # $< the file that was the dependency # $* the part that was matched with % # $? - list of dependencies since last time make was invoked # %.c %.cpp % # OBJECTS = file.o CFLAGS = -Wall -g CC = g++ library.a: $(OBJECTS) ar rcs library.a $(OBJECTS) %.o: %.cpp $(CC) $(CFLAGS) -c -o $@ $< clean: rm -f library.a; rm -f *.o