-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
executable file
·37 lines (28 loc) · 930 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# Toggle the following line/comment under windows
LIBS = -lglut -lGLU -lGL -lGLEW -lm
#LIBS = -lglut32 -lGLU32 -lopengl32 -lglew32 -lm
CFLAGS = -Wall -O3 -mfpmath=sse -msse2 #-march=native -mtune=native
CXXFLAGS = -Wall -O3 -mfpmath=sse -msse2 #-march=native -mtune=native
CPPFLAGS = -I$(INCDIR) -I/include -I.
LDFLAGS = -L/usr/X11R6/lib -L/lib
LDLIBS = $(LIBS)
CC = g++
CPP = g++
CIBLE = gmini
SRCS = Camera.cpp Main.cpp Shader.cpp Vertex.cpp Triangle.cpp Mesh.cpp
OBJS = $(SRCS:.cpp=.o)
$(CIBLE): $(OBJS)
g++ $(LDFLAGS) $(LIBS) -o $(CIBLE) $(OBJS)
clean:
rm -f *~ $(OBJS)
veryclean: clean
rm -f $(CIBLE)
dep:
gcc $(CPPFLAGS) -MM $(SRCS)
# Dependencies
Camera.o: Camera.cpp Camera.h Vec3D.h
Mesh.o: Mesh.cpp Mesh.h Vertex.h Vec3D.h Triangle.h Edge.h
Main.o: Main.cpp Shader.h Vec3D.h Vertex.h \
Triangle.h Mesh.h Edge.h Camera.h
Triangle.o: Triangle.cpp Triangle.h
Vertex.o: Vertex.cpp Vertex.h Vec3D.h