forked from vinniefalco/LuaBridge
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCMakeLists.txt
78 lines (58 loc) · 1.59 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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
set (LUABRIDGE_TEST_SOURCE_FILES
Source/IssueTests.cpp
Source/LegacyTests.cpp
Source/ListTests.cpp
Source/LuaRefTests.cpp
Source/MapTests.cpp
Source/PerformanceTests.cpp
Source/Tests.cpp
Source/TestBase.h
Source/TestsMain.cpp
Source/VectorTests.cpp
)
source_group ("Source" FILES ${LUABRIDGE_TEST_SOURCE_FILES})
set (LUABRIDGE_TEST_JUICE_FILES
JuceLibraryCode/AppConfig.h
JuceLibraryCode/BinaryData.h
JuceLibraryCode/BinaryData.cpp
JuceLibraryCode/JuceHeader.h
)
add_library (JuceLibraryCode ${LUABRIDGE_TEST_JUICE_FILES})
# Lua 5.1
file (GLOB_RECURSE LUABRIDGE_TEST_LUA51_FILES
LuaLibrary.h
Lua/LuaLibrary5.1.5.cpp
)
add_library (Lua51 ${LUABRIDGE_TEST_LUA51_FILES})
target_compile_options (Lua51 PUBLIC -DLUABRIDGEDEMO_LUA_VERSION=501)
target_include_directories (Lua51 PRIVATE .)
add_executable (LuaBridgeTests51
${LUABRIDGE_TEST_SOURCE_FILES}
)
target_include_directories (LuaBridgeTests51 PRIVATE . Source)
target_link_libraries (LuaBridgeTests51
LuaBridge
Lua51
gtest
JuceLibraryCode
)
# Lua 5.2
file (GLOB_RECURSE LUABRIDGE_TEST_LUA52_FILES
Lua/LuaLibrary.h
Lua/LuaLibrary5.2.0.cpp
)
add_library (Lua52 ${LUABRIDGE_TEST_LUA52_FILES})
target_compile_options (Lua52 PUBLIC -DLUABRIDGEDEMO_LUA_VERSION=502)
target_include_directories (Lua52 PRIVATE .)
add_executable (LuaBridgeTests52
${LUABRIDGE_TEST_SOURCE_FILES}
)
target_include_directories (LuaBridgeTests52 PRIVATE . Source)
target_link_libraries (LuaBridgeTests52
LuaBridge
Lua52
gtest
JuceLibraryCode
)
# Fix runtime library link options by gtest macro
fix_default_compiler_settings_()