summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2018-12-03 10:44:32 +0800
committer最萌小汐 <sumneko@hotmail.com>2018-12-03 10:44:32 +0800
commit1d3b6f8c0194c5da4f80793da1828c034c4daeef (patch)
tree0294c46a10307670172fd8a4e3440cc471eaeffc
parente9137c6077c7de01018f46181c97ab8fe235df4c (diff)
downloadlua-language-server-1d3b6f8c0194c5da4f80793da1828c034c4daeef.zip
编译模块
-rw-r--r--.vscode/launch.json21
-rw-r--r--server/bin/bee.dllbin142336 -> 185856 bytes
-rw-r--r--server/bin/lua.exebin15872 -> 15872 bytes
-rw-r--r--server/bin/lua54.dllbin254976 -> 254976 bytes
-rw-r--r--server/compile.lua28
5 files changed, 47 insertions, 2 deletions
diff --git a/.vscode/launch.json b/.vscode/launch.json
index 71f55595..780687c2 100644
--- a/.vscode/launch.json
+++ b/.vscode/launch.json
@@ -12,9 +12,9 @@
"env": {
"PATH": "${workspaceRoot}\\server\\bin\\"
},
- "luaRuntime": "5.3 32bit",
+ "luaRuntime": "5.4 32bit",
"luaexe": "${workspaceRoot}\\server\\bin\\lua.exe",
- "luadll": "${workspaceRoot}\\server\\bin\\lua53.dll",
+ "luadll": "${workspaceRoot}\\server\\bin\\lua54.dll",
"path": "${workspaceRoot}/server/bin/?.lua",
"cpath": "${workspaceRoot}/server/bin/?.dll;",
"arg": [
@@ -33,6 +33,23 @@
"port": 546858
},
{
+ "name": "编译",
+ "type": "lua",
+ "request": "launch",
+ "stopOnEntry": false,
+ "program": "${workspaceRoot}/server/compile.lua",
+ "cwd": "${workspaceRoot}/server",
+ "luaRuntime": "5.4 32bit",
+ "luaexe": "${workspaceRoot}/server/bee.lua/make/luamake/lua.exe",
+ "luadll": "${workspaceRoot}/server/bee.lua/make/luamake/lua54.dll",
+ "path": "${workspaceRoot}/server/bee.lua/make/luamake/?.lua",
+ "cpath": "${workspaceRoot}/server/bee.lua/make/luamake/?.dll;",
+ "arg": [
+ ],
+ "consoleCoding": "utf8",
+ "sourceCoding": "utf8"
+ },
+ {
"type": "extensionHost",
"request": "launch",
"name": "Launch Client",
diff --git a/server/bin/bee.dll b/server/bin/bee.dll
index 40bc0943..44c1c1d3 100644
--- a/server/bin/bee.dll
+++ b/server/bin/bee.dll
Binary files differ
diff --git a/server/bin/lua.exe b/server/bin/lua.exe
index 4b0f560d..13dba1f4 100644
--- a/server/bin/lua.exe
+++ b/server/bin/lua.exe
Binary files differ
diff --git a/server/bin/lua54.dll b/server/bin/lua54.dll
index 461038b7..c33a5125 100644
--- a/server/bin/lua54.dll
+++ b/server/bin/lua54.dll
Binary files differ
diff --git a/server/compile.lua b/server/compile.lua
new file mode 100644
index 00000000..aab58cd6
--- /dev/null
+++ b/server/compile.lua
@@ -0,0 +1,28 @@
+local fs = require 'bee.filesystem'
+local root = fs.current_path()
+
+local function compileRelease()
+ local msvc = require 'msvc'
+ if not msvc:initialize(141, 'utf8') then
+ error('Cannot found Visual Studio Toolset.')
+ end
+
+ local property = {
+ Configuration = 'Release',
+ Platform = 'x86'
+ }
+ msvc:compile('build', root / 'bee.lua' / 'project' / 'bee.sln', property)
+end
+
+local function copyFile()
+ local source = root / 'bee.lua' / 'bin' / 'x86' / 'Release'
+ local target = root / 'bin'
+ for _, name in ipairs {'bee.dll', 'lua.exe', 'lua54.dll'} do
+ fs.copy_file(source / name, target / name, true)
+ end
+end
+
+compileRelease()
+copyFile()
+
+print 'make complete.'