-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
45 lines (37 loc) · 1.57 KB
/
CMakeLists.txt
File metadata and controls
45 lines (37 loc) · 1.57 KB
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
cmake_minimum_required(VERSION 3.22)
project(LuaSTGSub)
#option(LUASTG_RESDIR "Custom configurations" "res")
option(LUASTG_SUPPORTS_WINDOWS_7 "LuaSTG Sub Windows compatibility: Windows 7" ON)
option(LUASTG_LINK_YY_THUNKS "Link to YY_Thunks for older Windows version (not recommended)" OFF)
option(LUASTG_LINK_LUASOCKET "Link to luasocket" OFF)
option(LUASTG_LINK_TRACY_CLIENT "Link to Tracy client" OFF)
option(LUASTG_LINK_STEAM_API "Link to Steam API" OFF)
option(LUASTG_LINK_SPINE_RUNTIME "Link to Spine Runtime" OFF)
if(LUASTG_SUPPORTS_WINDOWS_7)
message(STATUS "[LuaSTG] Windows compatibility: Windows 7")
add_compile_definitions(LUASTG_SUPPORTS_WINDOWS_7)
endif()
if(LUASTG_LINK_SPINE_RUNTIME)
message(STATUS "[LuaSTG] Spine support: ON")
add_compile_definitions(LUASTG_SUPPORTS_SPINE)
endif()
set_property(GLOBAL PROPERTY USE_FOLDERS ON)
include(cmake/TargetCommonOptions.cmake)
include(cmake/options.cmake)
include(cmake/msvc.crt.cmake)
#msvc_hybrid_runtime_library()
msvc_static_runtime_library()
include(cmake/import/all.cmake)
include(cmake/build/all.cmake)
add_subdirectory(external)
include(cmake/packages.lua.cmake)
include(LuaSTG/shaders.cmake)
add_subdirectory(imgui)
add_subdirectory(engine)
target_link_libraries(lua_imgui PUBLIC lua_plus) # TODO: 丑不拉几的
add_subdirectory(tool)
add_subdirectory(LuaSTG)
if (CMAKE_GENERATOR MATCHES "Visual Studio")
message(STATUS "Current CMake generator is Visual Studio, set startup project to LuaSTG")
set_directory_properties(PROPERTY VS_STARTUP_PROJECT LuaSTG)
endif ()