Makefile 754 B

123456789101112131415161718192021222324252627282930313233
  1. all: example1 example2
  2. igl_lib=../../
  3. eigen_lib=/opt/local/include/eigen3/
  4. CFLAGS=-g
  5. inc=-I$(igl_lib)/include -I$(eigen_lib)
  6. lib=-L$(igl_lib)/lib -ligl
  7. matlab_inc=-I$(MATLAB)/extern/include
  8. matlab_lib=-L$(MATLAB)/bin/maci64/ -leng -lmx
  9. example1: example1.o
  10. g++ $(CFLAGS) -o example1 example1.o -framework OpenGL -framework GLUT $(lib)
  11. rm example1.o
  12. example1.o: example1.cpp
  13. g++ $(CFLAGS) -c example1.cpp -o example1.o $(inc)
  14. example2: example2.o
  15. g++ $(CFLAGS) $(matlab_lib) -o example2 example2.o -framework OpenGL -framework GLUT $(lib)
  16. rm example2.o
  17. example2.o: example2.cpp
  18. g++ $(CFLAGS) $(matlab_inc) -c example2.cpp -o example2.o $(inc)
  19. clean:
  20. rm -f example1.o
  21. rm -f example1
  22. rm -f example2.o
  23. rm -f example2
  24. rm -f bunny_out.off