summaryrefslogtreecommitdiffstatshomepage
path: root/scripts/src
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/src')
-rw-r--r--scripts/src/3rdparty.lua73
-rw-r--r--scripts/src/main.lua3
2 files changed, 69 insertions, 7 deletions
diff --git a/scripts/src/3rdparty.lua b/scripts/src/3rdparty.lua
index 16b86dcbe21..ef46f1cab24 100644
--- a/scripts/src/3rdparty.lua
+++ b/scripts/src/3rdparty.lua
@@ -398,6 +398,8 @@ end
configuration { }
defines {
"LUA_COMPAT_ALL",
+ "LUA_COMPAT_5_1",
+ "LUA_COMPAT_5_2",
}
if not (_OPTIONS["targetos"]=="windows") and not (_OPTIONS["targetos"]=="asmjs") then
defines {
@@ -458,20 +460,19 @@ links {
end
--------------------------------------------------
--- sqlite3 lua library objects
+-- small lua library objects
--------------------------------------------------
-project "lsqlite3"
+project "lualibs"
uuid "1d84edab-94cf-48fb-83ee-b75bc697660e"
kind "StaticLib"
- -- options {
- -- "ForceCPP",
- -- }
-
configuration { "vs*" }
buildoptions {
"/wd4244", -- warning C4244: 'argument' : conversion from 'xxx' to 'xxx', possible loss of data
+ "/wd4055", -- warning C4055: 'type cast': from data pointer 'void *' to function pointer 'xxx'
+ "/wd4152", -- warning C4152: nonstandard extension, function/data pointer conversion in expression
+ "/wd4130", -- warning C4130: '==': logical operation on address of string constant
}
configuration { }
@@ -487,9 +488,69 @@ project "lsqlite3"
MAME_DIR .. "3rdparty/lua/src",
}
end
+ if _OPTIONS["with-bundled-zlib"] then
+ includedirs {
+ MAME_DIR .. "3rdparty/zlib",
+ }
+ end
files {
MAME_DIR .. "3rdparty/lsqlite3/lsqlite3.c",
+ MAME_DIR .. "3rdparty/lua-zlib/lua_zlib.c",
+ MAME_DIR .. "3rdparty/luafilesystem/src/lfs.c",
+ }
+
+--------------------------------------------------
+-- luv lua library objects
+--------------------------------------------------
+
+project "luv"
+ uuid "d98ec5ca-da2a-4a50-88a2-52061ca53871"
+ kind "StaticLib"
+
+ if _OPTIONS["targetos"]=="windows" then
+ defines {
+ "_WIN32_WINNT=0x0600",
+ }
+ end
+ configuration { "vs*" }
+ buildoptions {
+ "/wd4244", -- warning C4244: 'argument' : conversion from 'xxx' to 'xxx', possible loss of data
+ }
+
+ configuration { "gmake" }
+ buildoptions_c {
+ "-Wno-unused-function",
+ "-Wno-strict-prototypes",
+ "-Wno-unused-variable",
+ "-Wno-maybe-uninitialized",
+ "-Wno-undef",
+ }
+
+ configuration { "vs2015" }
+ buildoptions {
+ "/wd4701", -- warning C4701: potentially uninitialized local variable 'xxx' used
+ "/wd4703", -- warning C4703: potentially uninitialized local pointer variable 'xxx' used
+ }
+
+ configuration { }
+ defines {
+ "LUA_COMPAT_ALL",
+ }
+
+ includedirs {
+ MAME_DIR .. "3rdparty/lua/src",
+ MAME_DIR .. "3rdparty/libuv/include",
+ }
+ if _OPTIONS["with-bundled-lua"] then
+ includedirs {
+ MAME_DIR .. "3rdparty/luv/deps/lua/src",
+ }
+ end
+
+ files {
+ MAME_DIR .. "3rdparty/luv/src/luv.c",
+ MAME_DIR .. "3rdparty/luv/src/luv.h",
}
--------------------------------------------------
diff --git a/scripts/src/main.lua b/scripts/src/main.lua
index 2397a489e00..9d0d9a9d9e1 100644
--- a/scripts/src/main.lua
+++ b/scripts/src/main.lua
@@ -128,7 +128,8 @@ end
"jpeg",
"7z",
"lua",
- "lsqlite3",
+ "lualibs",
+ "luv",
"uv",
"http-parser",
}