| 23 # POSSIBILITY OF SUCH DAMAGE. |
23 # POSSIBILITY OF SUCH DAMAGE. |
| 24 # |
24 # |
| 25 |
25 |
| 26 include ../../config.mk |
26 include ../../config.mk |
| 27 |
27 |
| 28 BUILD_DIR=$(srcdir)/build/test |
28 BUILD_DIR=$(srcdir)/build/snake |
| 29 LIB_ASCENSION=$(srcdir)/build/lib/libascension.a |
29 LIB_ASCENSION=$(srcdir)/build/lib/libascension.a |
| 30 CFLAGS += -I$(srcdir)/src $(CPPFLAGS) |
30 CFLAGS += -I$(srcdir)/src $(CPPFLAGS) |
| 31 |
31 |
| 32 all: $(BUILD_DIR) $(BUILD_DIR)/snake FORCE |
32 all: $(BUILD_DIR) $(BUILD_DIR)/snake FORCE |
| 33 @echo "Demo game 'snake' successfully built." |
33 @echo "Demo game 'snake' successfully built." |
| |
34 @cp -Ruf $(srcdir)/shader $(BUILD_DIR)/ |
| |
35 @cp -Ruf $(srcdir)/fonts $(BUILD_DIR)/ |
| |
36 @cp -Ruf textures $(BUILD_DIR)/ |
| |
37 @cp -Ruf shader $(BUILD_DIR)/ |
| |
38 @echo "Assets for demo game 'snake' successfully copied." |
| 34 |
39 |
| 35 $(BUILD_DIR): |
40 $(BUILD_DIR): |
| 36 mkdir -p $@ |
41 mkdir -p $@ |
| 37 |
42 |
| 38 $(BUILD_DIR)/snake: $(BUILD_DIR)/snake.o $(LIB_ASCENSION) |
43 $(BUILD_DIR)/snake: $(BUILD_DIR)/snake.o $(LIB_ASCENSION) |
| 51 ../../src/ascension/scene_node.h ../../src/ascension/transform.h \ |
56 ../../src/ascension/scene_node.h ../../src/ascension/transform.h \ |
| 52 ../../src/ascension/camera.h ../../src/ascension/input.h \ |
57 ../../src/ascension/camera.h ../../src/ascension/input.h \ |
| 53 ../../src/ascension/font.h ../../src/ascension/behavior.h \ |
58 ../../src/ascension/font.h ../../src/ascension/behavior.h \ |
| 54 ../../src/ascension/ui.h ../../src/ascension/text.h \ |
59 ../../src/ascension/ui.h ../../src/ascension/text.h \ |
| 55 ../../src/ascension/mesh.h ../../src/ascension/texture.h \ |
60 ../../src/ascension/mesh.h ../../src/ascension/texture.h \ |
| 56 ../../src/ascension/sprite.h ../../src/ascension/2d.h |
61 ../../src/ascension/sprite.h ../../src/ascension/2d.h \ |
| |
62 ../../src/ascension/shader.h |
| 57 @echo "Compiling $<" |
63 @echo "Compiling $<" |
| 58 $(CC) -o $@ $(CFLAGS) -c $< |
64 $(CC) -o $@ $(CFLAGS) -c $< |
| 59 |
65 |