PROG = shapes

CPP = g++
OFLAG = -o
.SUFFIXES: .cpp .o

.cpp.o :
	$(CPP) $(CPPFLAGS) -c $<

all: $(PROG).exe

clean: 
	rm -f *.o
	rm -f $(PROG).exe

$(PROG).exe : circle.o rect.o shape.o triangle.o main.o
	$(CPP) $(OFLAG) $(PROG).exe circle.o rect.o shape.o triangle.o main.o

circle.o: circle.h circle.cpp shape.h

rect.o: rect.h rect.cpp shape.h

triangle.o: triangle.h triangle.cpp shape.h

shape.o: shape.h shape.cpp

main.o : main.cpp circle.h shape.h rect.h triangle.h
