-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
48 lines (27 loc) · 1013 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
39
40
41
42
43
44
45
46
#------------------------------------------------------------------------------
OBJECT=Panorama.o Point2D.o Point3D.o Edge2D.o Edge3D.o Vector3D.o Matrix3x3.o Face3D.o Object.o ObjFile.o Universe.o Vision3D.o main.o
MYPROGRAM=vision3d
MYINCLUDES=.
MYLIBRARIES=
CC=g++
#CFLAGS=-Wall -std=c++0x
#CFLAGS=-Wall -std=c++11
#CFLAGS=-Wall -std=c++14
CFLAGS=-Wall -std=c++17
LDFLAGS=
#DEFVAR=-DNOT_DISPLAY_CONSTRUCTOR -DDEBUG -DREF_OR_PTR
#DEFVAR=-DDISPLAY_CONSTRUCTOR -DDEBUG
#DEFVAR=-DDISPLAY_CONSTRUCTOR
DEFVAR=-DDEBUG_BUILD -DDISPLAY_CONSTRUCTOR -DCHECK_MEMORY
#------------------------------------------------------------------------------
# strange: i do not really understand which rule make the main.o compilation, default not written perheaps
all: $(MYPROGRAM)
%.o: %.cpp %.hpp
@echo COMPILING $<
$(CC) -c -o $@ $< $(CFLAGS) -I$(MYINCLUDES) $(DEFVAR)
$(MYPROGRAM): $(OBJECT)
@echo
@echo LINKING $(OBJECT)
$(CC) $(LDFLAGS) -o $@ $^ #-l$(MYLIBRARIES)
clean:
rm -f $(MYPROGRAM) *~ *.o