# # Sample makefile for CS70. Comments are kept to a minimum to # reduce clutter. This makefile was discussed extensively in # class. # SHELL = /bin/sh CXXFLAGS = -g -Wall -pedantic CXX = g++ # Compatibility with other versions of make: CCC = $(CXX) CCFLAGS = $(CXXFLAGS) LIBES = -lm OBJECTS = calc.o complex.o all: calc calc: $(OBJECTS) $(CXX) $(CXXFLAGS) -o calc $(OBJECTS) $(LIBES) calc.o: complex.hh complex.o: complex.hh # The following dependencies are automatically inferred by make, so # they're redundant: #calc.o: calc.cc #complex.o: complex.cc # Special targets: install: all cp -p calc $$HOME/bin clean: rm -f calc *.o *~ core