annotate examples/CMakeLists.txt @ 261:bfde372bf152

core: prefix utilities with util_
author David Demelier <markand@malikania.fr>
date Sun, 06 Dec 2020 23:06:34 +0100
parents 16be1ad3ddba
children cd5bdb995052
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
125
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
1 #
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
2 # CMakeLists.txt -- CMake build system for molko
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
3 #
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
4 # Copyright (c) 2020 David Demelier <markand@malikania.fr>
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
5 #
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
6 # Permission to use, copy, modify, and/or distribute this software for any
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
7 # purpose with or without fee is hereby granted, provided that the above
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
8 # copyright notice and this permission notice appear in all copies.
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
9 #
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
10 # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
11 # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
12 # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
13 # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
14 # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
15 # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
16 # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
17 #
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
18
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
19 project(examples)
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
20
209
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
21 set(
210
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
22 ASSETS_IMAGES
230
86b71e1f9dd5 rpg: add movements in battle
David Demelier <markand@malikania.fr>
parents: 218
diff changeset
23 ${examples_SOURCE_DIR}/assets/images/battle-background.png
209
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
24 ${examples_SOURCE_DIR}/assets/images/black-cat.png
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
25 ${examples_SOURCE_DIR}/assets/images/haunted-wood.png
210
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
26 )
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
27
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
28 set(
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
29 ASSETS_MUSIC
209
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
30 ${examples_SOURCE_DIR}/assets/music/vabsounds-romance.ogg
210
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
31 )
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
32
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
33 set(
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
34 ASSETS_SOUNDS
209
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
35 ${examples_SOURCE_DIR}/assets/sounds/fire.wav
210
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
36 )
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
37
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
38 set(
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
39 ASSETS_SPRITES
209
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
40 ${examples_SOURCE_DIR}/assets/sprites/chest.png
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
41 ${examples_SOURCE_DIR}/assets/sprites/cursor.png
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
42 ${examples_SOURCE_DIR}/assets/sprites/explosion.png
210
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
43 ${examples_SOURCE_DIR}/assets/sprites/john.png
230
86b71e1f9dd5 rpg: add movements in battle
David Demelier <markand@malikania.fr>
parents: 218
diff changeset
44 ${examples_SOURCE_DIR}/assets/sprites/john-sword.png
86b71e1f9dd5 rpg: add movements in battle
David Demelier <markand@malikania.fr>
parents: 218
diff changeset
45 ${examples_SOURCE_DIR}/assets/sprites/john-walk.png
209
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
46 ${examples_SOURCE_DIR}/assets/sprites/numbers.png
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
47 ${examples_SOURCE_DIR}/assets/sprites/people.png
163
4bbfcd9180a8 core: add window_set_cursor function, closes #2502
David Demelier <markand@malikania.fr>
parents: 160
diff changeset
48 )
4bbfcd9180a8 core: add window_set_cursor function, closes #2502
David Demelier <markand@malikania.fr>
parents: 160
diff changeset
49
210
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
50 set(
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
51 ASSETS
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
52 ${ASSETS_IMAGES}
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
53 ${ASSETS_MUSIC}
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
54 ${ASSETS_SOUNDS}
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
55 ${ASSETS_SPRITES}
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
56 )
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
57
209
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
58 # Can't use an interface library as examples live in subdirectories.
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
59 file(WRITE ${examples_BINARY_DIR}/none.c "void molko() {}")
154
2252f9efac9a ui: remove style from debug_report, closes #2499
David Demelier <markand@malikania.fr>
parents: 151
diff changeset
60
209
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
61 molko_define_library(
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
62 TARGET libexamples
151
b19d076856d2 ui: cleanup theme module, closes #2498
David Demelier <markand@malikania.fr>
parents: 148
diff changeset
63 FOLDER examples
215
64f24b482722 rpg: implement tilesets separately, closes #2515 @4h
David Demelier <markand@malikania.fr>
parents: 210
diff changeset
64 SOURCES
64f24b482722 rpg: implement tilesets separately, closes #2515 @4h
David Demelier <markand@malikania.fr>
parents: 210
diff changeset
65 ${examples_BINARY_DIR}/none.c
64f24b482722 rpg: implement tilesets separately, closes #2515 @4h
David Demelier <markand@malikania.fr>
parents: 210
diff changeset
66 ${ASSETS}
209
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
67 ASSETS ${ASSETS}
125
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
68 )
d59efa737fcc cmake: add examples and fix
David Demelier <markand@malikania.fr>
parents:
diff changeset
69
209
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
70 add_subdirectory(example-action)
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
71 add_subdirectory(example-animation)
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
72 add_subdirectory(example-audio)
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
73 add_subdirectory(example-battle)
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
74 add_subdirectory(example-cursor)
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
75 add_subdirectory(example-debug)
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
76 add_subdirectory(example-drawable)
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
77 add_subdirectory(example-font)
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
78 add_subdirectory(example-gridmenu)
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
79 add_subdirectory(example-label)
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
80 add_subdirectory(example-message)
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
81 add_subdirectory(example-sprite)
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
82 add_subdirectory(example-trace)
23a844fdc911 examples: move all into subdirectories, closes #2513
David Demelier <markand@malikania.fr>
parents: 203
diff changeset
83 add_subdirectory(example-ui)
141
4eeeccf2b732 core: add trace/vtrace functions, closes #2493
David Demelier <markand@malikania.fr>
parents: 136
diff changeset
84
210
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
85 source_group("assets/images" FILES ${ASSETS_IMAGES})
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
86 source_group("assets/music" FILES ${ASSETS_MUSIC})
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
87 source_group("assets/sounds" FILES ${ASSETS_SOUNDS})
70e6ed74940d rpg: attempt of collide detection in map
David Demelier <markand@malikania.fr>
parents: 209
diff changeset
88 source_group("assets/sprites" FILES ${ASSETS_SPRITES})