-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
38 lines (27 loc) · 906 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
38
# definition des cibles particulieres
.PHONY: clean
# definition des variables
CXX = g++
CXXFLAGS = -O2 -Wall -Wextra -pg -std=c++11
OBJ = main.o ClasseLapins.o LapinManager.o Student.o
OBJI = mainI.o ClasseLapinsI.o LapinManagerI.o Student.o
GameOfRabbits : $(OBJ)
$(CXX) $^ -o ./$@ $(CXXFLAGS) -lm
main.o : main.cpp
$(CXX) -c $< -o $@ $(CXXFLAGS)
ClasseLapins.o : ClasseLapins.cpp ClasseLapins.h
$(CXX) -c $< -o $@ $(CXXFLAGS)
LapinManager.o : LapinManager.cpp LapinManager.h
$(CXX) -c $< -o $@ $(CXXFLAGS)
Student.o : Student.cpp Student.h
$(CXX) -c $< -o $@ $(CXXFLAGS)
GameOfRabbitsI : $(OBJI)
$(CXX) $^ -o ./$@ $(CXXFLAGS) -lm
mainI.o : mainI.cpp
$(CXX) -c $< -o $@ $(CXXFLAGS)
ClasseLapinsI.o : ClasseLapinsI.cpp ClasseLapinsI.h
$(CXX) -c $< -o $@ $(CXXFLAGS)
LapinManagerI.o : LapinManagerI.cpp LapinManagerI.h
$(CXX) -c $< -o $@ $(CXXFLAGS)
clean :
rm -rf *.bak; rm -rf *.o