-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCMakeLists.txt
60 lines (51 loc) · 1.15 KB
/
CMakeLists.txt
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
add_library(
ovis-emscripten
include/ovis/emscripten/canvas.hpp src/canvas.cpp
include/ovis/emscripten/key_codes.hpp src/key_codes.cpp
)
add_library(ovis::emscripten ALIAS ovis-emscripten)
target_include_directories(
ovis-emscripten
PUBLIC
${CMAKE_CURRENT_SOURCE_DIR}/include
)
target_link_libraries(
ovis-emscripten
PUBLIC
ovis::core
ovis::graphics
ovis::input
stb::truetype
)
target_add_assets(
ovis-emscripten
# path/to/asset
)
# if (OVIS_BUILD_TESTS)
# add_executable(
# ovis-emscripten-test
# # ...
# )
# target_link_libraries(
# ovis-emscripten-test
# PRIVATE
# ovis::emscripten
# ovis::test
# )
# target_add_assets(
# ovis-emscripten-test
# # path/to/asset
# )
# target_embed_assets(ovis-emscripten-test)
# if (OVIS_EMSCRIPTEN)
# add_test(
# ovis-emscripten-test
# ${NODE_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/ovis-emscripten-test.js
# )
# else ()
# add_test(
# NAME ovis-emscripten-test
# COMMAND ovis-emscripten-test --assets-directory ${CMAKE_CURRENT_BINARY_DIR}/assets/ovis-emscripten-test/
# )
# endif ()
# endif ()