PLNOBJS = plntest.o material.o plane.o object.o list.o INCLUDE = ray.h rayhdrs.h pixel.h vector.h CFLAGS = plntest: $(PLNOBJS) gcc -Wall -o plntest -g $(PLNOBJS) -lm $(PLNOBJS): $(INCLUDE) makefile SPHOBJS = sphtest.o material.o sphere.o object.o list.o INCLUDE = ray.h rayhdrs.h pixel.h vector.h CFLAGS = sphtest: $(SPHOBJS) gcc -Wall -o sphtest -g $(SPHOBJS) -lm $(SPHOBJS): $(INCLUDE) makefile .c.o: $< -gcc -c -Wall $(CFLAGS) -c -g $< 2> $(@:.o=.err) cat $*.err clean: rm *.o