-
Notifications
You must be signed in to change notification settings - Fork 0
/
buildProjects.lua
77 lines (63 loc) · 1.61 KB
/
buildProjects.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
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
require("config")
local module_name = "v8"
local os_names = {windows="win32",macosx="osx",linux="linux"}
local function setTarget(targetName)
targetname(targetName)
if os.get()=="windows" and config.out then
postbuildcommands{"move /Y ..\\build\\windows\\"..targetName..'.dll "'..config.out..'"'}
end
end
solution("gmodscripts-module")
language("C++")
kind("SharedLib")
location("proj-"..os.get() .."-".._ACTION)
defines{"GMMODULE"}
flags{"Symbols","NoEditAndContinue","NoPCH","StaticRuntime","EnableSSE"}
--From relese config
defines{"NDEBUG"}
flags{"Optimize","FloatFast"}
includedirs{"include/",config.source_sdk_dir.."mp/src/public/",config.v8_dir.."include/"}
libdirs{config.source_sdk_dir.."mp/src/lib/public/",config.v8_dir.."lib/"}
links{ --Not sure what libs we need. Will it hurt to link to them all?
"appframework",
"bitmap",
"choreoobjects",
"dmxloader",
"fgdlib",
"libprotobuf",
"libz",
"mathlib",
"matsys_controls",
"nvtristrip",
"particles",
"raytrace",
"shaderlib",
"steam_api",
"tier0",
"tier1",
"tier2",
"tier3",
"vgui_controls",
"vmpi",
"vstdlib",
"vtf",
--V8
"v8_base",
"v8_snapshot",
"v8_libbase",
--"v8_libplatform", not needed?
"icuuc",
"icui18n",
--Windows dependency of V8 (wtf)
"winmm"
}
targetdir("build/"..os.get().."/")
configurations{
"1-ServerModule","2-ClientModule"
}
configuration("1-ServerModule")
setTarget("gmsv_"..module_name.."_"..os_names[os.get()])
configuration("2-ClientModule")
setTarget("gmcl_"..module_name.."_"..os_names[os.get()])
project("gmodscripts-module")
files{"src/**.*","include/**.*"}