author | Radek Brich <radek.brich@devl.cz> |
Fri, 14 Dec 2007 16:51:22 +0100 | |
branch | pyrit |
changeset 39 | 7079dcc3bd74 |
parent 29 | 574c34441a1c |
child 40 | 929aad02c5f2 |
permissions | -rw-r--r-- |
22 | 1 |
ifndef $(ROOT) |
2 |
ROOT=$(shell pwd)/.. |
|
3 |
endif |
|
4 |
||
5 |
include $(ROOT)/config.mk |
|
6 |
||
7 |
||
39
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
8 |
### Rules ### |
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
9 |
%.o: %.cc |
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
10 |
$(CXX) -c -o $@ $(CCFLAGS) $(SDL_CCFLAGS) $< $(DEFS) -DPYRIT_DOUBLE |
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
11 |
|
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
12 |
%: %.o |
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
13 |
$(CXX) -o $@ $(ROOT)/bin/libs-double/*.o $< image.o $(LDFLAGS) $(SDL_LDFLAGS) -lpng |
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
14 |
|
22 | 15 |
### Targets ### |
29
574c34441a1c
new C++ demo: realtime_bunny
Radek Brich <radek.brich@devl.cz>
parents:
25
diff
changeset
|
16 |
all: realtime realtime_dragon realtime_bunny spheres_shadow |
22 | 17 |
|
39
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
18 |
realtime: realtime.o libs-double image.o |
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
19 |
realtime_dragon: realtime_dragon.o libs-double image.o |
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
20 |
realtime_bunny: realtime_bunny.o libs-double image.o |
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
21 |
spheres_shadow: spheres_shadow.o libs-double image.o |
24
d0d76e8a5203
new C++ demo: realtime_dragon.cc
Radek Brich <radek.brich@devl.cz>
parents:
22
diff
changeset
|
22 |
|
39
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
23 |
realtime.o: realtime.cc |
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
24 |
realtime_dragon.o: realtime_dragon.cc common_sdl.h common_ply.h |
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
25 |
realtime_bunny.o: realtime_bunny.cc common_sdl.h common_ply.h |
7079dcc3bd74
ccdemos: put the common code to header files, common_ply.h and common_sdl.h
Radek Brich <radek.brich@devl.cz>
parents:
29
diff
changeset
|
26 |
spheres_shadow.o: spheres_shadow.cc |
22 | 27 |
|
28 |
libs-float: |
|
29 |
$(MAKE) -C ../src libs-float |
|
15
a0a3e334744f
C++ demos: prepare infrastructure, add spheres_shadow.cc
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
30 |
|
22 | 31 |
libs-double: |
32 |
$(MAKE) -C ../src libs-double |
|
33 |
||
34 |
image.o: image.c |
|
15
a0a3e334744f
C++ demos: prepare infrastructure, add spheres_shadow.cc
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
35 |
$(CXX) -c -o $@ $*.c |
a0a3e334744f
C++ demos: prepare infrastructure, add spheres_shadow.cc
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
36 |
|
a0a3e334744f
C++ demos: prepare infrastructure, add spheres_shadow.cc
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
37 |
clean: |
29
574c34441a1c
new C++ demo: realtime_bunny
Radek Brich <radek.brich@devl.cz>
parents:
25
diff
changeset
|
38 |
rm -f spheres_shadow realtime realtime_dragon realtime_bunny *.o |