-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathxmake.lua
45 lines (35 loc) · 1.18 KB
/
xmake.lua
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
includes("Xmake/**.lua")
includes("**/xmake.lua")
add_rules("mode.debug", "mode.release")
set_allowedmodes("debug", "release")
set_defaultmode("debug")
set_project("Elos")
set_version("1.0.0")
set_languages("c17", "cxx23")
set_policy("build.warning", true)
set_warnings("all", "extra")
set_policy("run.autobuild", true)
set_allowedarchs("windows|x64")
--set_runtimes(is_mode("debug") and "MDd" or "MD")
if is_mode("debug") then
set_policy("preprocessor.linemarkers", true) -- Enable preprocessor markers in debug mode
add_defines("ELOS_BUILD_DEBUG=1")
set_symbols("debug", "edit") -- Enable hot reloading
end
if is_mode("release") then
set_symbols("hidden")
add_defines("ELOS_BUILD_DEBUG=0")
set_strip("all")
end
add_defines("UNICODE", "_UNICODE", "NOMINMAX", "NOMCX", "NOSERVICE", "NOHELP", "WIN32_LEAN_AND_MEAN")
add_tests("CompileSuccess", { build_should_pass = true, group = "Compilation" })
add_requires("directxtk")
add_packages("directxtk")
target("Elos")
set_group("Elos")
add_rules("ExportAPI")
add_includedirs(".", { public = true })
add_files("**.cpp")
add_headerfiles("(Elos/**.h)", { install = true })
add_links("user32", "gdi32", "dwmapi", "shcore", "Comctl32")
target_end()