Files
PhotonMF/Makefile

37 lines
945 B
Makefile
Raw Normal View History

2016-12-25 21:47:28 -04:00
CXX = g++
2017-03-01 12:41:28 -04:00
TARGET = ray pviewer
PVDIR = PhotonViewer
OBJECTS = main.o sampling.o camera.o environment.o disk.o plane.o sphere.o \
phong_brdf.o hsa_brdf.o directional_light.o point_light.o \
spot_light.o sphere_area_light.o disk_area_light.o scene.o tracer.o \
2017-02-21 17:00:49 -04:00
path_tracer.o whitted_tracer.o rgbe.o kd_tree.o photon_tracer.o
2017-01-02 04:41:50 -04:00
DEPENDS = $(OBJECTS:.o=.d)
2017-05-21 12:21:39 -04:00
CXXFLAGS = -std=c++11 -pedantic -Wall -DGLM_FORCE_RADIANS -fopenmp -DUSE_CPP11_RANDOM #-DENABLE_KD_TREE
LDLIBS = -lfreeimage -ljson_spirit
2016-12-25 21:47:28 -04:00
.PHONY: all
2017-02-28 14:49:47 -04:00
all: CXXFLAGS += -O3 -DNDEBUG
2016-12-25 21:47:28 -04:00
all: $(TARGET)
2017-01-02 04:41:50 -04:00
.PHONY: debug
debug: CXXFLAGS += -g
debug: $(TARGET)
2017-03-01 12:41:28 -04:00
ray: $(OBJECTS)
$(CXX) -o $@ $^ $(CXXFLAGS) $(LDLIBS)
2016-12-26 15:41:29 -04:00
2017-01-02 04:41:50 -04:00
-include $(DEPENDS)
2017-01-02 04:41:50 -04:00
%.o: %.cpp
$(CXX) -c $(CXXFLAGS) $*.cpp -o $*.o
$(CXX) -MM $(CXXFLAGS) $*.cpp > $*.d
2017-01-02 04:23:48 -04:00
2017-03-01 12:41:28 -04:00
.PHONY: pviewer
pviewer:
$(MAKE) $(MFLAGS) -C $(PVDIR)
2016-12-25 21:47:28 -04:00
.PHONY: clean
clean:
2017-03-01 12:41:28 -04:00
$(RM) ray $(OBJECTS) $(DEPENDS)
$(MAKE) $(MFLAGS) -C $(PVDIR) clean