all: g++ Example.cc -o Example objects = Example.o edit: $(objects) cc -o edit $(objects) $(objects) : Example.h hello.o : Example.h .PHONY : clean clean : -rm edit $(objects)