scrclean on lua scripts (nw)

This commit is contained in:
Miodrag Milanovic 2016-03-29 08:49:47 +02:00
parent 3fb7f61cfc
commit 9b3788035c
25 changed files with 376 additions and 376 deletions

View File

@ -19,48 +19,48 @@ local extlibs = {
-- system lib options -- system lib options
newoption { newoption {
trigger = 'with-system-expat', trigger = 'with-system-expat',
description = 'Use system Expat library', description = 'Use system Expat library',
} }
newoption { newoption {
trigger = 'with-system-zlib', trigger = 'with-system-zlib',
description = 'Use system Zlib library', description = 'Use system Zlib library',
} }
newoption { newoption {
trigger = 'with-system-jpeg', trigger = 'with-system-jpeg',
description = 'Use system JPEG library', description = 'Use system JPEG library',
} }
newoption { newoption {
trigger = 'with-system-flac', trigger = 'with-system-flac',
description = 'Use system FLAC library', description = 'Use system FLAC library',
} }
newoption { newoption {
trigger = 'with-system-sqlite3', trigger = 'with-system-sqlite3',
description = 'Use system SQLite library', description = 'Use system SQLite library',
} }
newoption { newoption {
trigger = 'with-system-portmidi', trigger = 'with-system-portmidi',
description = 'Use system PortMidi library', description = 'Use system PortMidi library',
} }
newoption { newoption {
trigger = 'with-system-portaudio', trigger = 'with-system-portaudio',
description = 'Use system PortAudio library', description = 'Use system PortAudio library',
} }
newoption { newoption {
trigger = "with-system-lua", trigger = "with-system-lua",
description = "Use system LUA library", description = "Use system LUA library",
} }
newoption { newoption {
trigger = 'with-system-uv', trigger = 'with-system-uv',
description = 'Use system uv library', description = 'Use system uv library',
} }
-- build helpers -- build helpers

View File

@ -2,8 +2,8 @@
-- copyright-holders:MAMEdev Team -- copyright-holders:MAMEdev Team
newoption { newoption {
trigger = 'build-dir', trigger = 'build-dir',
description = 'Build directory name', description = 'Build directory name',
} }
premake.check_paths = true premake.check_paths = true
@ -32,23 +32,23 @@ function str_to_version(str)
val = val + tonumber(word) * cnt val = val + tonumber(word) * cnt
cnt = cnt / 100 cnt = cnt / 100
end end
return val return val
end end
function findfunction(x) function findfunction(x)
assert(type(x) == "string") assert(type(x) == "string")
local f=_G local f=_G
for v in x:gmatch("[^%.]+") do for v in x:gmatch("[^%.]+") do
if type(f) ~= "table" then if type(f) ~= "table" then
return nil, "looking for '"..v.."' expected table, not "..type(f) return nil, "looking for '"..v.."' expected table, not "..type(f)
end end
f=f[v] f=f[v]
end end
if type(f) == "function" then if type(f) == "function" then
return f return f
else else
return nil, "expected function, not "..type(f) return nil, "expected function, not "..type(f)
end end
end end
function layoutbuildtask(_folder, _name) function layoutbuildtask(_folder, _name)
@ -57,9 +57,9 @@ function layoutbuildtask(_folder, _name)
end end
function precompiledheaders() function precompiledheaders()
configuration { "not xcode4" } configuration { "not xcode4" }
pchheader("emu.h") pchheader("emu.h")
configuration { } configuration { }
end end
function addprojectflags() function addprojectflags()
@ -101,13 +101,13 @@ newoption {
trigger = "targetos", trigger = "targetos",
description = "Choose target OS", description = "Choose target OS",
allowed = { allowed = {
{ "android", "Android" }, { "android", "Android" },
{ "asmjs", "Emscripten/asm.js" }, { "asmjs", "Emscripten/asm.js" },
{ "freebsd", "FreeBSD" }, { "freebsd", "FreeBSD" },
{ "netbsd", "NetBSD" }, { "netbsd", "NetBSD" },
{ "openbsd", "OpenBSD" }, { "openbsd", "OpenBSD" },
{ "pnacl", "Native Client - PNaCl" }, { "pnacl", "Native Client - PNaCl" },
{ "linux", "Linux" }, { "linux", "Linux" },
{ "ios", "iOS" }, { "ios", "iOS" },
{ "macosx", "OSX" }, { "macosx", "OSX" },
{ "windows", "Windows" }, { "windows", "Windows" },
@ -120,15 +120,15 @@ newoption {
} }
newoption { newoption {
trigger = 'with-bundled-sdl2', trigger = 'with-bundled-sdl2',
description = 'Build bundled SDL2 library', description = 'Build bundled SDL2 library',
} }
newoption { newoption {
trigger = "distro", trigger = "distro",
description = "Choose distribution", description = "Choose distribution",
allowed = { allowed = {
{ "generic", "generic" }, { "generic", "generic" },
{ "debian-stable", "debian-stable" }, { "debian-stable", "debian-stable" },
{ "ubuntu-intrepid", "ubuntu-intrepid" }, { "ubuntu-intrepid", "ubuntu-intrepid" },
}, },
@ -246,7 +246,7 @@ newoption {
trigger = "DEPRECATED", trigger = "DEPRECATED",
description = "Generate deprecation warnings during compilation.", description = "Generate deprecation warnings during compilation.",
allowed = { allowed = {
{ "0", "Disabled" }, { "0", "Disabled" },
{ "1", "Enabled" }, { "1", "Enabled" },
} }
} }
@ -255,7 +255,7 @@ newoption {
trigger = "LTO", trigger = "LTO",
description = "Clang link time optimization.", description = "Clang link time optimization.",
allowed = { allowed = {
{ "0", "Disabled" }, { "0", "Disabled" },
{ "1", "Enabled" }, { "1", "Enabled" },
} }
} }
@ -264,7 +264,7 @@ newoption {
trigger = "SSE2", trigger = "SSE2",
description = "SSE2 optimized code and SSE2 code generation.", description = "SSE2 optimized code and SSE2 code generation.",
allowed = { allowed = {
{ "0", "Disabled" }, { "0", "Disabled" },
{ "1", "Enabled" }, { "1", "Enabled" },
} }
} }
@ -273,7 +273,7 @@ newoption {
trigger = "SSE3", trigger = "SSE3",
description = "SSE3 optimized code and SSE3 code generation.", description = "SSE3 optimized code and SSE3 code generation.",
allowed = { allowed = {
{ "0", "Disabled" }, { "0", "Disabled" },
{ "1", "Enabled" }, { "1", "Enabled" },
} }
} }
@ -282,7 +282,7 @@ newoption {
trigger = "OPENMP", trigger = "OPENMP",
description = "OpenMP optimized code.", description = "OpenMP optimized code.",
allowed = { allowed = {
{ "0", "Disabled" }, { "0", "Disabled" },
{ "1", "Enabled" }, { "1", "Enabled" },
} }
} }
@ -291,7 +291,7 @@ newoption {
trigger = "FASTDEBUG", trigger = "FASTDEBUG",
description = "Fast DEBUG.", description = "Fast DEBUG.",
allowed = { allowed = {
{ "0", "Disabled" }, { "0", "Disabled" },
{ "1", "Enabled" }, { "1", "Enabled" },
} }
} }
@ -300,7 +300,7 @@ newoption {
trigger = "SEPARATE_BIN", trigger = "SEPARATE_BIN",
description = "Use separate bin folders.", description = "Use separate bin folders.",
allowed = { allowed = {
{ "0", "Disabled" }, { "0", "Disabled" },
{ "1", "Enabled" }, { "1", "Enabled" },
} }
} }
@ -314,7 +314,7 @@ newoption {
trigger = "SHADOW_CHECK", trigger = "SHADOW_CHECK",
description = "Shadow checks.", description = "Shadow checks.",
allowed = { allowed = {
{ "0", "Disabled" }, { "0", "Disabled" },
{ "1", "Enabled" }, { "1", "Enabled" },
} }
} }
@ -323,7 +323,7 @@ newoption {
trigger = "STRIP_SYMBOLS", trigger = "STRIP_SYMBOLS",
description = "Symbols stripping.", description = "Symbols stripping.",
allowed = { allowed = {
{ "0", "Disabled" }, { "0", "Disabled" },
{ "1", "Enabled" }, { "1", "Enabled" },
} }
} }
@ -333,7 +333,7 @@ newoption {
trigger = "SHLIB", trigger = "SHLIB",
description = "Generate shared libs.", description = "Generate shared libs.",
allowed = { allowed = {
{ "0", "Static libs" }, { "0", "Static libs" },
{ "1", "Shared libs" }, { "1", "Shared libs" },
} }
} }
@ -347,7 +347,7 @@ newoption {
trigger = "FORCE_VERSION_COMPILE", trigger = "FORCE_VERSION_COMPILE",
description = "Force compiling of version.c file.", description = "Force compiling of version.c file.",
allowed = { allowed = {
{ "0", "Disabled" }, { "0", "Disabled" },
{ "1", "Enabled" }, { "1", "Enabled" },
} }
} }
@ -361,7 +361,7 @@ newoption {
trigger = "USE_LIBUV", trigger = "USE_LIBUV",
description = "Use libuv.", description = "Use libuv.",
allowed = { allowed = {
{ "0", "Disabled" }, { "0", "Disabled" },
{ "1", "Enabled" }, { "1", "Enabled" },
} }
} }
@ -426,15 +426,15 @@ configurations {
} }
if _ACTION == "xcode4" then if _ACTION == "xcode4" then
platforms { platforms {
"x64", "x64",
} }
else else
platforms { platforms {
"x32", "x32",
"x64", "x64",
"Native", -- for targets where bitness is not specified "Native", -- for targets where bitness is not specified
} }
end end
language "C++" language "C++"
@ -476,7 +476,7 @@ end
if _OPTIONS["targetos"] == "android" then if _OPTIONS["targetos"] == "android" then
_OPTIONS["with-bundled-sdl2"] = "1" _OPTIONS["with-bundled-sdl2"] = "1"
end end
configuration {} configuration {}
msgcompile ("Compiling $(subst ../,,$<)...") msgcompile ("Compiling $(subst ../,,$<)...")
@ -789,7 +789,7 @@ if _OPTIONS["OPTIMIZE"] then
-- windows native mingw GCC 5.2 fails with -flto=x with x > 1. bug unfixed as of this commit -- windows native mingw GCC 5.2 fails with -flto=x with x > 1. bug unfixed as of this commit
"-flto=1", "-flto=1",
-- if ld fails, just buy more RAM or uncomment this! -- if ld fails, just buy more RAM or uncomment this!
-- "-Wl,-no-keep-memory", -- "-Wl,-no-keep-memory",
"-Wl,-v", "-Wl,-v",
-- silence redefine warnings from discrete.c. -- silence redefine warnings from discrete.c.
"-Wl,-allow-multiple-definition", "-Wl,-allow-multiple-definition",
@ -801,17 +801,17 @@ if _OPTIONS["OPTIMIZE"] then
"-flto-odr-type-merging", "-flto-odr-type-merging",
"-Wodr", "-Wodr",
"-flto-compression-level=0", -- lto doesn't work with anything <9 on linux with < 12G RAM, much slower if <> 0 "-flto-compression-level=0", -- lto doesn't work with anything <9 on linux with < 12G RAM, much slower if <> 0
-- "-flto-report", -- if you get an error in lto after [WPA] stage, but before [LTRANS] stage, you need more memory! -- "-flto-report", -- if you get an error in lto after [WPA] stage, but before [LTRANS] stage, you need more memory!
-- "-fmem-report-wpa","-fmem-report","-fpre-ipa-mem-report","-fpost-ipa-mem-report","-flto-report-wpa","-fmem-report", -- "-fmem-report-wpa","-fmem-report","-fpre-ipa-mem-report","-fpost-ipa-mem-report","-flto-report-wpa","-fmem-report",
-- this six flag combo lets MAME compile with LTO=1 on linux with no errors and ~2% speed boost, but compile time is much longer -- this six flag combo lets MAME compile with LTO=1 on linux with no errors and ~2% speed boost, but compile time is much longer
-- if you are going to wait on lto, you might as well enable these for GCC -- if you are going to wait on lto, you might as well enable these for GCC
-- "-fdevirtualize-at-ltrans","-fgcse-sm","-fgcse-las", -- "-fdevirtualize-at-ltrans","-fgcse-sm","-fgcse-las",
-- "-fipa-pta","-fipa-icf","-fvariable-expansion-in-unroller", -- "-fipa-pta","-fipa-icf","-fvariable-expansion-in-unroller",
} }
-- same flags are needed by linker -- same flags are needed by linker
linkoptions { linkoptions {
"-flto=1", "-flto=1",
-- "-Wl,-no-keep-memory", -- "-Wl,-no-keep-memory",
"-Wl,-v", "-Wl,-v",
"-Wl,-allow-multiple-definition", "-Wl,-allow-multiple-definition",
"-fuse-linker-plugin", "-fuse-linker-plugin",
@ -819,12 +819,12 @@ if _OPTIONS["OPTIMIZE"] then
"-flto-odr-type-merging", "-flto-odr-type-merging",
"-Wodr", "-Wodr",
"-flto-compression-level=0", -- lto doesn't work with anything <9 on linux with < 12G RAM, much slower if <> 0 "-flto-compression-level=0", -- lto doesn't work with anything <9 on linux with < 12G RAM, much slower if <> 0
-- "-flto-report", -- if you get an error in lto after [WPA] stage, but before [LTRANS] stage, you need more memory! -- "-flto-report", -- if you get an error in lto after [WPA] stage, but before [LTRANS] stage, you need more memory!
-- "-fmem-report-wpa","-fmem-report","-fpre-ipa-mem-report","-fpost-ipa-mem-report","-flto-report-wpa","-fmem-report", -- "-fmem-report-wpa","-fmem-report","-fpre-ipa-mem-report","-fpost-ipa-mem-report","-flto-report-wpa","-fmem-report",
-- this six flag combo lets MAME compile with LTO=1 on linux with no errors and ~2% speed boost, but compile time is much longer -- this six flag combo lets MAME compile with LTO=1 on linux with no errors and ~2% speed boost, but compile time is much longer
-- if you are going to wait on lto, you might as well enable these for GCC -- if you are going to wait on lto, you might as well enable these for GCC
-- "-fdevirtualize-at-ltrans","-fgcse-sm","-fgcse-las", -- "-fdevirtualize-at-ltrans","-fgcse-sm","-fgcse-las",
-- "-fipa-pta","-fipa-icf","-fvariable-expansion-in-unroller", -- "-fipa-pta","-fipa-icf","-fvariable-expansion-in-unroller",
} }
@ -971,7 +971,7 @@ end
} }
end end
end end
if (_OPTIONS["PLATFORM"]=="arm") then if (_OPTIONS["PLATFORM"]=="arm") then
buildoptions { buildoptions {
"-Wno-cast-align", "-Wno-cast-align",
@ -982,7 +982,7 @@ if (_OPTIONS["PLATFORM"]=="arm64") then
buildoptions { buildoptions {
"-Wno-cast-align", "-Wno-cast-align",
} }
defines { defines {
"PTR64=1", "PTR64=1",
} }
end end
@ -1029,7 +1029,7 @@ configuration { "android-arm64" }
buildoptions { buildoptions {
"-Wno-asm-operand-widths", "-Wno-asm-operand-widths",
} }
configuration { "pnacl" } configuration { "pnacl" }
buildoptions { buildoptions {
"-std=gnu89", "-std=gnu89",
@ -1058,17 +1058,17 @@ configuration { "linux-* or rpi or ci20"}
configuration { "steamlink" } configuration { "steamlink" }
links { links {
"dl", "dl",
"EGL", "EGL",
"GLESv2", "GLESv2",
"SDL2", "SDL2",
} }
defines { defines {
"EGL_API_FB", "EGL_API_FB",
} }
configuration { "rpi" } configuration { "rpi" }
links { links {
"SDL2", "SDL2",
"fontconfig", "fontconfig",
"X11", "X11",
"GLESv2", "GLESv2",
@ -1077,17 +1077,17 @@ configuration { "rpi" }
"vcos", "vcos",
"vchiq_arm", "vchiq_arm",
"pthread", "pthread",
} }
configuration { "ci20" } configuration { "ci20" }
links { links {
"SDL2", "SDL2",
"asound", "asound",
"fontconfig", "fontconfig",
"freetype", "freetype",
"pthread", "pthread",
} }
configuration { "osx* or xcode4" } configuration { "osx* or xcode4" }
@ -1117,7 +1117,7 @@ configuration { "mingw-clang" }
linkoptions { linkoptions {
"-pthread", "-pthread",
} }
configuration { "vs*" } configuration { "vs*" }
defines { defines {
@ -1141,7 +1141,7 @@ configuration { "vs*" }
} }
buildoptions { buildoptions {
"/WX", -- Treats all compiler warnings as errors. "/WX", -- Treats all compiler warnings as errors.
"/wd4025", -- warning C4025: 'number' : based pointer passed to function with variable arguments: parameter number "/wd4025", -- warning C4025: 'number' : based pointer passed to function with variable arguments: parameter number
"/wd4003", -- warning C4003: not enough actual parameters for macro 'xxx' "/wd4003", -- warning C4003: not enough actual parameters for macro 'xxx'
"/wd4018", -- warning C4018: 'x' : signed/unsigned mismatch "/wd4018", -- warning C4018: 'x' : signed/unsigned mismatch
@ -1205,38 +1205,38 @@ configuration { "vs*" }
} }
if _OPTIONS["vs"]=="intel-15" then if _OPTIONS["vs"]=="intel-15" then
buildoptions { buildoptions {
"/Qwd9", -- remark #9: nested comment is not allowed "/Qwd9", -- remark #9: nested comment is not allowed
"/Qwd82", -- remark #82: storage class is not first "/Qwd82", -- remark #82: storage class is not first
"/Qwd111", -- remark #111: statement is unreachable "/Qwd111", -- remark #111: statement is unreachable
"/Qwd128", -- remark #128: loop is not reachable "/Qwd128", -- remark #128: loop is not reachable
"/Qwd177", -- remark #177: function "xxx" was declared but never referenced "/Qwd177", -- remark #177: function "xxx" was declared but never referenced
"/Qwd181", -- remark #181: argument of type "UINT32={unsigned int}" is incompatible with format "%d", expecting argument of type "int" "/Qwd181", -- remark #181: argument of type "UINT32={unsigned int}" is incompatible with format "%d", expecting argument of type "int"
"/Qwd185", -- remark #185: dynamic initialization in unreachable code "/Qwd185", -- remark #185: dynamic initialization in unreachable code
"/Qwd280", -- remark #280: selector expression is constant "/Qwd280", -- remark #280: selector expression is constant
"/Qwd344", -- remark #344: typedef name has already been declared (with same type) "/Qwd344", -- remark #344: typedef name has already been declared (with same type)
"/Qwd411", -- remark #411: class "xxx" defines no constructor to initialize the following "/Qwd411", -- remark #411: class "xxx" defines no constructor to initialize the following
"/Qwd869", -- remark #869: parameter "xxx" was never referenced "/Qwd869", -- remark #869: parameter "xxx" was never referenced
"/Qwd2545", -- remark #2545: empty dependent statement in "else" clause of if - statement "/Qwd2545", -- remark #2545: empty dependent statement in "else" clause of if - statement
"/Qwd2553", -- remark #2553: nonstandard second parameter "TCHAR={WCHAR = { __wchar_t } } **" of "main", expected "char *[]" or "char **" extern "C" int _tmain(int argc, TCHAR **argv) "/Qwd2553", -- remark #2553: nonstandard second parameter "TCHAR={WCHAR = { __wchar_t } } **" of "main", expected "char *[]" or "char **" extern "C" int _tmain(int argc, TCHAR **argv)
"/Qwd2557", -- remark #2557: comparison between signed and unsigned operands "/Qwd2557", -- remark #2557: comparison between signed and unsigned operands
"/Qwd3280", -- remark #3280: declaration hides member "attotime::seconds" (declared at line 126) static attotime from_seconds(INT32 seconds) { return attotime(seconds, 0); } "/Qwd3280", -- remark #3280: declaration hides member "attotime::seconds" (declared at line 126) static attotime from_seconds(INT32 seconds) { return attotime(seconds, 0); }
"/Qwd170", -- error #170: pointer points outside of underlying object "/Qwd170", -- error #170: pointer points outside of underlying object
"/Qwd188", -- error #188: enumerated type mixed with another type "/Qwd188", -- error #188: enumerated type mixed with another type
"/Qwd63", -- warning #63: shift count is too large "/Qwd63", -- warning #63: shift count is too large
"/Qwd177", -- warning #177: label "xxx" was declared but never referenced "/Qwd177", -- warning #177: label "xxx" was declared but never referenced
"/Qwd186", -- warning #186: pointless comparison of unsigned integer with zero "/Qwd186", -- warning #186: pointless comparison of unsigned integer with zero
"/Qwd488", -- warning #488: template parameter "_FunctionClass" is not used in declaring the parameter types of function template "device_delegate<_Signature>::device_delegate<_FunctionClass>(delegate<_Signature>: "/Qwd488", -- warning #488: template parameter "_FunctionClass" is not used in declaring the parameter types of function template "device_delegate<_Signature>::device_delegate<_FunctionClass>(delegate<_Signature>:
"/Qwd1478", -- warning #1478: function "xxx" (declared at line yyy of "zzz") was declared deprecated "/Qwd1478", -- warning #1478: function "xxx" (declared at line yyy of "zzz") was declared deprecated
"/Qwd1879", -- warning #1879: unimplemented pragma ignored "/Qwd1879", -- warning #1879: unimplemented pragma ignored
"/Qwd3291", -- warning #3291: invalid narrowing conversion from "double" to "int" "/Qwd3291", -- warning #3291: invalid narrowing conversion from "double" to "int"
"/Qwd1195", -- error #1195: conversion from integer to smaller pointer "/Qwd1195", -- error #1195: conversion from integer to smaller pointer
"/Qwd47", -- error #47: incompatible redefinition of macro "xxx" "/Qwd47", -- error #47: incompatible redefinition of macro "xxx"
"/Qwd265", -- error #265: floating-point operation result is out of range "/Qwd265", -- error #265: floating-point operation result is out of range
-- these occur on a release build, while we can increase the size limits instead some of the files do require extreme amounts -- these occur on a release build, while we can increase the size limits instead some of the files do require extreme amounts
"/Qwd11074", -- remark #11074: Inlining inhibited by limit max-size / remark #11074: Inlining inhibited by limit max-total-size "/Qwd11074", -- remark #11074: Inlining inhibited by limit max-size / remark #11074: Inlining inhibited by limit max-total-size
"/Qwd11075", -- remark #11075: To get full report use -Qopt-report:4 -Qopt-report-phase ipo "/Qwd11075", -- remark #11075: To get full report use -Qopt-report:4 -Qopt-report-phase ipo
} }
end end
@ -1248,7 +1248,7 @@ end
} }
configuration { "vs2015" } configuration { "vs2015" }
buildoptions { buildoptions {
"/wd4334", -- warning C4334: '<<': result of 32-bit shift implicitly converted to 64 bits (was 64-bit shift intended?) "/wd4334", -- warning C4334: '<<': result of 32-bit shift implicitly converted to 64 bits (was 64-bit shift intended?)
"/wd4456", -- warning C4456: declaration of 'xxx' hides previous local declaration "/wd4456", -- warning C4456: declaration of 'xxx' hides previous local declaration
"/wd4457", -- warning C4457: declaration of 'xxx' hides function parameter "/wd4457", -- warning C4457: declaration of 'xxx' hides function parameter
"/wd4458", -- warning C4458: declaration of 'xxx' hides class member "/wd4458", -- warning C4458: declaration of 'xxx' hides class member
@ -1308,7 +1308,7 @@ findfunction("createProjects_" .. _OPTIONS["target"] .. "_" .. _OPTIONS["subtarg
group "emulator" group "emulator"
dofile(path.join("src", "main.lua")) dofile(path.join("src", "main.lua"))
if (_OPTIONS["SOURCES"] == nil) then if (_OPTIONS["SOURCES"] == nil) then
if (_OPTIONS["target"] == _OPTIONS["subtarget"]) then if (_OPTIONS["target"] == _OPTIONS["subtarget"]) then
startproject (_OPTIONS["target"]) startproject (_OPTIONS["target"])
else else
@ -1320,7 +1320,7 @@ if (_OPTIONS["SOURCES"] == nil) then
end end
else else
startproject (_OPTIONS["subtarget"]) startproject (_OPTIONS["subtarget"])
end end
mainProject(_OPTIONS["target"],_OPTIONS["subtarget"]) mainProject(_OPTIONS["target"],_OPTIONS["subtarget"])
strip() strip()

View File

@ -26,10 +26,10 @@ project "expat"
} }
if _OPTIONS["vs"]=="intel-15" then if _OPTIONS["vs"]=="intel-15" then
buildoptions { buildoptions {
"/Qwd111", -- remark #111: statement is unreachable "/Qwd111", -- remark #111: statement is unreachable
"/Qwd1879", -- warning #1879: unimplemented pragma ignored "/Qwd1879", -- warning #1879: unimplemented pragma ignored
"/Qwd2557", -- remark #2557: comparison between signed and unsigned operands "/Qwd2557", -- remark #2557: comparison between signed and unsigned operands
"/Qwd869", -- remark #869: parameter "xxx" was never referenced "/Qwd869", -- remark #869: parameter "xxx" was never referenced
} }
end end
configuration { "vs2015" } configuration { "vs2015" }
@ -76,8 +76,8 @@ project "zlib"
} }
if _OPTIONS["vs"]=="intel-15" then if _OPTIONS["vs"]=="intel-15" then
buildoptions { buildoptions {
"/Qwd111", -- remark #111: statement is unreachable "/Qwd111", -- remark #111: statement is unreachable
"/Qwd280", -- remark #280: selector expression is constant "/Qwd280", -- remark #280: selector expression is constant
} }
end end
configuration "Debug" configuration "Debug"
@ -137,7 +137,7 @@ project "softfloat"
} }
if _OPTIONS["vs"]=="intel-15" then if _OPTIONS["vs"]=="intel-15" then
buildoptions { buildoptions {
"/Qwd2557", -- remark #2557: comparison between signed and unsigned operands "/Qwd2557", -- remark #2557: comparison between signed and unsigned operands
} }
end end
configuration { } configuration { }
@ -165,7 +165,7 @@ project "jpeg"
} }
if _OPTIONS["vs"]=="intel-15" then if _OPTIONS["vs"]=="intel-15" then
buildoptions { buildoptions {
"/Qwd869", -- remark #869: parameter "xxx" was never referenced "/Qwd869", -- remark #869: parameter "xxx" was never referenced
} }
end end
@ -243,11 +243,11 @@ project "flac"
} }
if _OPTIONS["vs"]=="intel-15" then if _OPTIONS["vs"]=="intel-15" then
buildoptions { buildoptions {
"/Qwd111", -- remark #111: statement is unreachable "/Qwd111", -- remark #111: statement is unreachable
"/Qwd177", -- remark #177: function "xxx" was declared but never referenced "/Qwd177", -- remark #177: function "xxx" was declared but never referenced
"/Qwd181", -- remark #181: argument of type "UINT32={unsigned int}" is incompatible with format "%d", expecting argument of type "int" "/Qwd181", -- remark #181: argument of type "UINT32={unsigned int}" is incompatible with format "%d", expecting argument of type "int"
"/Qwd188", -- error #188: enumerated type mixed with another type "/Qwd188", -- error #188: enumerated type mixed with another type
"/Qwd869", -- remark #869: parameter "xxx" was never referenced "/Qwd869", -- remark #869: parameter "xxx" was never referenced
} }
end end
@ -330,7 +330,7 @@ project "7z"
} }
if _OPTIONS["vs"]=="intel-15" then if _OPTIONS["vs"]=="intel-15" then
buildoptions { buildoptions {
"/Qwd869", -- remark #869: parameter "xxx" was never referenced "/Qwd869", -- remark #869: parameter "xxx" was never referenced
} }
end end
configuration { "vs2015" } configuration { "vs2015" }
@ -381,7 +381,7 @@ project "lua"
-- In addition comment out the "extern "C"" -- In addition comment out the "extern "C""
-- in lua.hpp and do the same in luaengine.c line 47 -- in lua.hpp and do the same in luaengine.c line 47
--options { --options {
-- "ForceCPP", -- "ForceCPP",
--} --}
configuration { "gmake" } configuration { "gmake" }
@ -524,8 +524,8 @@ project "sqlite3"
} }
if _OPTIONS["vs"]=="intel-15" then if _OPTIONS["vs"]=="intel-15" then
buildoptions { buildoptions {
"/Qwd869", -- remark #869: parameter "xxx" was never referenced "/Qwd869", -- remark #869: parameter "xxx" was never referenced
"/Qwd2557", -- remark #2557: comparison between signed and unsigned operands "/Qwd2557", -- remark #2557: comparison between signed and unsigned operands
} }
end end
configuration { "pnacl" } configuration { "pnacl" }
@ -587,10 +587,10 @@ project "portmidi"
} }
if _OPTIONS["vs"]=="intel-15" then if _OPTIONS["vs"]=="intel-15" then
buildoptions { buildoptions {
"/Qwd188", -- error #188: enumerated type mixed with another type "/Qwd188", -- error #188: enumerated type mixed with another type
"/Qwd344", -- remark #344: typedef name has already been declared (with same type) "/Qwd344", -- remark #344: typedef name has already been declared (with same type)
"/Qwd869", -- remark #869: parameter "xxx" was never referenced "/Qwd869", -- remark #869: parameter "xxx" was never referenced
"/Qwd2557", -- remark #2557: comparison between signed and unsigned operands "/Qwd2557", -- remark #2557: comparison between signed and unsigned operands
} }
end end
@ -668,9 +668,9 @@ project "bgfx"
} }
if _OPTIONS["vs"]=="intel-15" then if _OPTIONS["vs"]=="intel-15" then
buildoptions { buildoptions {
"/Qwd906", -- message #906: effect of this "#pragma pack" directive is local to function "xxx" "/Qwd906", -- message #906: effect of this "#pragma pack" directive is local to function "xxx"
"/Qwd1879", -- warning #1879: unimplemented pragma ignored "/Qwd1879", -- warning #1879: unimplemented pragma ignored
"/Qwd82", -- remark #82: storage class is not first "/Qwd82", -- remark #82: storage class is not first
} }
end end
configuration { } configuration { }
@ -819,10 +819,10 @@ project "portaudio"
} }
if _OPTIONS["vs"]=="intel-15" then if _OPTIONS["vs"]=="intel-15" then
buildoptions { buildoptions {
"/Qwd869", -- remark #869: parameter "xxx" was never referenced "/Qwd869", -- remark #869: parameter "xxx" was never referenced
"/Qwd1478", -- warning #1478: function "xxx" (declared at line yyy of "zzz") was declared deprecated "/Qwd1478", -- warning #1478: function "xxx" (declared at line yyy of "zzz") was declared deprecated
"/Qwd2544", -- message #2544: empty dependent statement in if-statement "/Qwd2544", -- message #2544: empty dependent statement in if-statement
"/Qwd1879", -- warning #1879: unimplemented pragma ignored "/Qwd1879", -- warning #1879: unimplemented pragma ignored
} }
end end
configuration { "vs2015" } configuration { "vs2015" }
@ -1021,7 +1021,7 @@ project "uv"
"WIN32_LEAN_AND_MEAN", "WIN32_LEAN_AND_MEAN",
"_WIN32_WINNT=0x0502", "_WIN32_WINNT=0x0502",
} }
if _ACTION == "vs2013" then if _ACTION == "vs2013" then
files { files {
MAME_DIR .. "3rdparty/libuv/src/win/snprintf.c", MAME_DIR .. "3rdparty/libuv/src/win/snprintf.c",
} }
@ -1106,7 +1106,7 @@ project "uv"
MAME_DIR .. "3rdparty/libuv/src/unix/proctitle.c", MAME_DIR .. "3rdparty/libuv/src/unix/proctitle.c",
} }
end end
if _OPTIONS["targetos"]=="android" then if _OPTIONS["targetos"]=="android" then
defines { defines {
"_GNU_SOURCE", "_GNU_SOURCE",
@ -1124,7 +1124,7 @@ project "uv"
MAME_DIR .. "3rdparty/libuv/src/unix/android-ifaddrs.c", MAME_DIR .. "3rdparty/libuv/src/unix/android-ifaddrs.c",
} }
end end
if _OPTIONS["targetos"]=="solaris" then if _OPTIONS["targetos"]=="solaris" then
defines { defines {
"__EXTENSIONS__", "__EXTENSIONS__",
@ -1177,7 +1177,7 @@ end
if _OPTIONS["with-bundled-sdl2"] then if _OPTIONS["with-bundled-sdl2"] then
project "SDL2" project "SDL2"
uuid "caab3327-574f-4abf-b25b-74d5238ae59b" uuid "caab3327-574f-4abf-b25b-74d5238ae59b"
if _OPTIONS["targetos"]=="android" then if _OPTIONS["targetos"]=="android" then
kind "SharedLib" kind "SharedLib"
targetextension ".so" targetextension ".so"
targetprefix "lib" targetprefix "lib"
@ -1189,8 +1189,8 @@ if _OPTIONS["targetos"]=="android" then
linkoptions { linkoptions {
"-Wl,-soname,liSDL2.so" "-Wl,-soname,liSDL2.so"
} }
if _OPTIONS["SEPARATE_BIN"]~="1" then if _OPTIONS["SEPARATE_BIN"]~="1" then
if _OPTIONS["PLATFORM"]=="arm" then if _OPTIONS["PLATFORM"]=="arm" then
targetdir(MAME_DIR .. "android-project/app/src/main/libs/armeabi-v7a") targetdir(MAME_DIR .. "android-project/app/src/main/libs/armeabi-v7a")
end end
@ -1209,11 +1209,11 @@ if _OPTIONS["targetos"]=="android" then
if _OPTIONS["PLATFORM"]=="x64" then if _OPTIONS["PLATFORM"]=="x64" then
targetdir(MAME_DIR .. "android-project/app/src/main/libs/x86_64") targetdir(MAME_DIR .. "android-project/app/src/main/libs/x86_64")
end end
end end
else else
kind "StaticLib" kind "StaticLib"
end end
files { files {
MAME_DIR .. "3rdparty/SDL2/include/begin_code.h", MAME_DIR .. "3rdparty/SDL2/include/begin_code.h",
MAME_DIR .. "3rdparty/SDL2/include/close_code.h", MAME_DIR .. "3rdparty/SDL2/include/close_code.h",
@ -1287,8 +1287,8 @@ end
MAME_DIR .. "3rdparty/SDL2/include/SDL_types.h", MAME_DIR .. "3rdparty/SDL2/include/SDL_types.h",
MAME_DIR .. "3rdparty/SDL2/include/SDL_version.h", MAME_DIR .. "3rdparty/SDL2/include/SDL_version.h",
MAME_DIR .. "3rdparty/SDL2/include/SDL_video.h", MAME_DIR .. "3rdparty/SDL2/include/SDL_video.h",
MAME_DIR .. "3rdparty/SDL2/src/atomic/SDL_atomic.c", MAME_DIR .. "3rdparty/SDL2/src/atomic/SDL_atomic.c",
MAME_DIR .. "3rdparty/SDL2/src/atomic/SDL_spinlock.c", MAME_DIR .. "3rdparty/SDL2/src/atomic/SDL_spinlock.c",
MAME_DIR .. "3rdparty/SDL2/src/audio/disk/SDL_diskaudio.c", MAME_DIR .. "3rdparty/SDL2/src/audio/disk/SDL_diskaudio.c",
@ -1457,13 +1457,13 @@ end
MAME_DIR .. "3rdparty/SDL2/src/render/opengles/SDL_glesfuncs.h", MAME_DIR .. "3rdparty/SDL2/src/render/opengles/SDL_glesfuncs.h",
} }
end end
if _OPTIONS["targetos"]=="android" then if _OPTIONS["targetos"]=="android" then
files { files {
MAME_DIR .. "3rdparty/SDL2/src/audio/android/SDL_androidaudio.c", MAME_DIR .. "3rdparty/SDL2/src/audio/android/SDL_androidaudio.c",
MAME_DIR .. "3rdparty/SDL2/src/audio/android/SDL_androidaudio.h", MAME_DIR .. "3rdparty/SDL2/src/audio/android/SDL_androidaudio.h",
MAME_DIR .. "3rdparty/SDL2/src/core/android/SDL_android.c", MAME_DIR .. "3rdparty/SDL2/src/core/android/SDL_android.c",
MAME_DIR .. "3rdparty/SDL2/src/core/android/SDL_android.h", MAME_DIR .. "3rdparty/SDL2/src/core/android/SDL_android.h",
MAME_DIR .. "3rdparty/SDL2/src/filesystem/android/SDL_sysfilesystem.c", MAME_DIR .. "3rdparty/SDL2/src/filesystem/android/SDL_sysfilesystem.c",
MAME_DIR .. "3rdparty/SDL2/src/haptic/dummy/SDL_syshaptic.c", MAME_DIR .. "3rdparty/SDL2/src/haptic/dummy/SDL_syshaptic.c",
MAME_DIR .. "3rdparty/SDL2/src/joystick/android/SDL_sysjoystick.c", MAME_DIR .. "3rdparty/SDL2/src/joystick/android/SDL_sysjoystick.c",
@ -1497,7 +1497,7 @@ end
MAME_DIR .. "3rdparty/SDL2/src/video/android/SDL_androidwindow.h", MAME_DIR .. "3rdparty/SDL2/src/video/android/SDL_androidwindow.h",
} }
end end
if _OPTIONS["targetos"]=="macosx" then if _OPTIONS["targetos"]=="macosx" then
files { files {
MAME_DIR .. "3rdparty/SDL2/src/audio/coreaudio/SDL_coreaudio.c", MAME_DIR .. "3rdparty/SDL2/src/audio/coreaudio/SDL_coreaudio.c",
@ -1510,7 +1510,7 @@ end
MAME_DIR .. "3rdparty/SDL2/src/joystick/darwin/SDL_sysjoystick.c", MAME_DIR .. "3rdparty/SDL2/src/joystick/darwin/SDL_sysjoystick.c",
MAME_DIR .. "3rdparty/SDL2/src/joystick/darwin/SDL_sysjoystick_c.h", MAME_DIR .. "3rdparty/SDL2/src/joystick/darwin/SDL_sysjoystick_c.h",
MAME_DIR .. "3rdparty/SDL2/src/loadso/dlopen/SDL_sysloadso.c", MAME_DIR .. "3rdparty/SDL2/src/loadso/dlopen/SDL_sysloadso.c",
MAME_DIR .. "3rdparty/SDL2/src/power/macosx/SDL_syspower.c", MAME_DIR .. "3rdparty/SDL2/src/power/macosx/SDL_syspower.c",
MAME_DIR .. "3rdparty/SDL2/src/thread/pthread/SDL_syscond.c", MAME_DIR .. "3rdparty/SDL2/src/thread/pthread/SDL_syscond.c",
MAME_DIR .. "3rdparty/SDL2/src/thread/pthread/SDL_sysmutex.c", MAME_DIR .. "3rdparty/SDL2/src/thread/pthread/SDL_sysmutex.c",
MAME_DIR .. "3rdparty/SDL2/src/thread/pthread/SDL_sysmutex_c.h", MAME_DIR .. "3rdparty/SDL2/src/thread/pthread/SDL_sysmutex_c.h",
@ -1605,25 +1605,25 @@ end
MAME_DIR .. "3rdparty/SDL2/src/main/windows/version.rc", MAME_DIR .. "3rdparty/SDL2/src/main/windows/version.rc",
} }
end end
configuration { "vs*" } configuration { "vs*" }
files { files {
MAME_DIR .. "3rdparty/SDL2/src/audio/xaudio2/SDL_xaudio2.c", MAME_DIR .. "3rdparty/SDL2/src/audio/xaudio2/SDL_xaudio2.c",
} }
buildoptions { buildoptions {
"/wd4200", -- warning C4200: nonstandard extension used: zero-sized array in struct/union "/wd4200", -- warning C4200: nonstandard extension used: zero-sized array in struct/union
"/wd4055", -- warning C4055: 'type cast': from data pointer 'void *' to function pointer 'xxx' "/wd4055", -- warning C4055: 'type cast': from data pointer 'void *' to function pointer 'xxx'
"/wd4152", -- warning C4152: nonstandard extension, function/data pointer conversion in expression "/wd4152", -- warning C4152: nonstandard extension, function/data pointer conversion in expression
"/wd4057", -- warning C4057: 'function': 'xxx' differs in indirection to slightly different base types from 'xxx' "/wd4057", -- warning C4057: 'function': 'xxx' differs in indirection to slightly different base types from 'xxx'
"/wd4701", -- warning C4701: potentially uninitialized local variable 'xxx' used "/wd4701", -- warning C4701: potentially uninitialized local variable 'xxx' used
"/wd4204", -- warning C4204: nonstandard extension used: non-constant aggregate initializer "/wd4204", -- warning C4204: nonstandard extension used: non-constant aggregate initializer
"/wd4054", -- warning C4054: 'type cast': from function pointer 'xxx' to data pointer 'xxx' "/wd4054", -- warning C4054: 'type cast': from function pointer 'xxx' to data pointer 'xxx'
} }
defines { defines {
"HAVE_LIBC", "HAVE_LIBC",
} }
configuration { "mingw*"} configuration { "mingw*"}
includedirs { includedirs {
MAME_DIR .. "3rdparty/SDL2-override/mingw", MAME_DIR .. "3rdparty/SDL2-override/mingw",
@ -1635,21 +1635,21 @@ end
"-Wno-bad-function-cast", "-Wno-bad-function-cast",
"-Wno-discarded-qualifiers", "-Wno-discarded-qualifiers",
"-Wno-unused-but-set-variable", "-Wno-unused-but-set-variable",
} }
configuration { "osx*"} configuration { "osx*"}
buildoptions { buildoptions {
"-Wno-undef", "-Wno-undef",
} }
buildoptions_objc { buildoptions_objc {
"-x objective-c", "-x objective-c",
"-std=c99", "-std=c99",
} }
buildoptions_c { buildoptions_c {
"-Wno-bad-function-cast", "-Wno-bad-function-cast",
} }
configuration { "android-*"} configuration { "android-*"}
defines { defines {
"GL_GLEXT_PROTOTYPES", "GL_GLEXT_PROTOTYPES",
@ -1659,8 +1659,8 @@ end
"-Wno-incompatible-pointer-types-discards-qualifiers", "-Wno-incompatible-pointer-types-discards-qualifiers",
"-Wno-unneeded-internal-declaration", "-Wno-unneeded-internal-declaration",
"-Wno-unused-const-variable", "-Wno-unused-const-variable",
} }
configuration { } configuration { }
includedirs { includedirs {
MAME_DIR .. "3rdparty/SDL2/include", MAME_DIR .. "3rdparty/SDL2/include",

View File

@ -45,13 +45,13 @@ project "benchmark"
project("benchmarks") project("benchmarks")
uuid ("a9750a48-d283-4a6d-b126-31c7ce049af1") uuid ("a9750a48-d283-4a6d-b126-31c7ce049af1")
kind "ConsoleApp" kind "ConsoleApp"
flags { flags {
"Symbols", -- always include minimum symbols for executables "Symbols", -- always include minimum symbols for executables
} }
if _OPTIONS["SEPARATE_BIN"]~="1" then if _OPTIONS["SEPARATE_BIN"]~="1" then
targetdir(MAME_DIR) targetdir(MAME_DIR)
end end

View File

@ -35,7 +35,7 @@ if (CPUS["SH2"]~=null or CPUS["MIPS"]~=null or CPUS["POWERPC"]~=null or CPUS["RS
MAME_DIR .. "src/devices/cpu/drcbex64.cpp", MAME_DIR .. "src/devices/cpu/drcbex64.cpp",
MAME_DIR .. "src/devices/cpu/drcbex64.h", MAME_DIR .. "src/devices/cpu/drcbex64.h",
MAME_DIR .. "src/devices/cpu/drcumlsh.h", MAME_DIR .. "src/devices/cpu/drcumlsh.h",
MAME_DIR .. "src/devices/cpu/x86emit.h", MAME_DIR .. "src/devices/cpu/x86emit.h",
} }
end end
@ -86,7 +86,7 @@ if (CPUS["ARCOMPACT"]~=null) then
MAME_DIR .. "src/devices/cpu/arcompact/arcompact_common.h", MAME_DIR .. "src/devices/cpu/arcompact/arcompact_common.h",
} }
dependency { dependency {
{ MAME_DIR .. "src/devices/cpu/arcompact/arcompact.cpp", GEN_DIR .. "emu/cpu/arcompact/arcompact.inc" }, { MAME_DIR .. "src/devices/cpu/arcompact/arcompact.cpp", GEN_DIR .. "emu/cpu/arcompact/arcompact.inc" },
{ MAME_DIR .. "src/devices/cpu/arcompact/arcompact_execute.cpp", GEN_DIR .. "emu/cpu/arcompact/arcompact.inc" }, { MAME_DIR .. "src/devices/cpu/arcompact/arcompact_execute.cpp", GEN_DIR .. "emu/cpu/arcompact/arcompact.inc" },
} }
@ -577,7 +577,7 @@ if (CPUS["H8"]~=null) then
MAME_DIR .. "src/devices/cpu/h8/h8_sci.cpp", MAME_DIR .. "src/devices/cpu/h8/h8_sci.cpp",
MAME_DIR .. "src/devices/cpu/h8/h8_sci.h", MAME_DIR .. "src/devices/cpu/h8/h8_sci.h",
} }
dependency { dependency {
{ MAME_DIR .. "src/devices/cpu/h8/h8.cpp", GEN_DIR .. "emu/cpu/h8/h8.inc" }, { MAME_DIR .. "src/devices/cpu/h8/h8.cpp", GEN_DIR .. "emu/cpu/h8/h8.inc" },
{ MAME_DIR .. "src/devices/cpu/h8/h8h.cpp", GEN_DIR .. "emu/cpu/h8/h8h.inc" }, { MAME_DIR .. "src/devices/cpu/h8/h8h.cpp", GEN_DIR .. "emu/cpu/h8/h8h.inc" },
@ -950,7 +950,7 @@ end
if (CPUS["I960"]~=null) then if (CPUS["I960"]~=null) then
files { files {
MAME_DIR .. "src/devices/cpu/i960/i960.cpp", MAME_DIR .. "src/devices/cpu/i960/i960.cpp",
MAME_DIR .. "src/devices/cpu/i960/i960.h", MAME_DIR .. "src/devices/cpu/i960/i960.h",
} }
end end
@ -1163,7 +1163,7 @@ if (CPUS["M37710"]~=null) then
MAME_DIR .. "src/devices/cpu/m37710/m37710cm.h", MAME_DIR .. "src/devices/cpu/m37710/m37710cm.h",
MAME_DIR .. "src/devices/cpu/m37710/m37710il.h", MAME_DIR .. "src/devices/cpu/m37710/m37710il.h",
MAME_DIR .. "src/devices/cpu/m37710/m37710op.h", MAME_DIR .. "src/devices/cpu/m37710/m37710op.h",
MAME_DIR .. "src/devices/cpu/m37710/m7700ds.h", MAME_DIR .. "src/devices/cpu/m37710/m7700ds.h",
} }
end end
@ -1233,7 +1233,7 @@ if (CPUS["M6502"]~=null) then
MAME_DIR .. "src/devices/cpu/m6502/m5074x.cpp", MAME_DIR .. "src/devices/cpu/m6502/m5074x.cpp",
MAME_DIR .. "src/devices/cpu/m6502/m5074x.h", MAME_DIR .. "src/devices/cpu/m6502/m5074x.h",
} }
dependency { dependency {
{ MAME_DIR .. "src/devices/cpu/m6502/deco16.cpp", GEN_DIR .. "emu/cpu/m6502/deco16.inc" }, { MAME_DIR .. "src/devices/cpu/m6502/deco16.cpp", GEN_DIR .. "emu/cpu/m6502/deco16.inc" },
{ MAME_DIR .. "src/devices/cpu/m6502/m4510.cpp", GEN_DIR .. "emu/cpu/m6502/m4510.inc" }, { MAME_DIR .. "src/devices/cpu/m6502/m4510.cpp", GEN_DIR .. "emu/cpu/m6502/m4510.inc" },
@ -1432,14 +1432,14 @@ end
-------------------------------------------------- --------------------------------------------------
if (CPUS["PATINHOFEIO"]~=null) then if (CPUS["PATINHOFEIO"]~=null) then
files { files {
MAME_DIR .. "src/devices/cpu/patinhofeio/patinho_feio.cpp", MAME_DIR .. "src/devices/cpu/patinhofeio/patinho_feio.cpp",
MAME_DIR .. "src/devices/cpu/patinhofeio/patinho_feio.h", MAME_DIR .. "src/devices/cpu/patinhofeio/patinho_feio.h",
} }
end end
if (CPUS["PATINHOFEIO"]~=null or _OPTIONS["with-tools"]) then if (CPUS["PATINHOFEIO"]~=null or _OPTIONS["with-tools"]) then
table.insert(disasm_files , MAME_DIR .. "src/devices/cpu/patinhofeio/patinho_feio_dasm.cpp") table.insert(disasm_files , MAME_DIR .. "src/devices/cpu/patinhofeio/patinho_feio_dasm.cpp")
end end
-------------------------------------------------- --------------------------------------------------
@ -1612,7 +1612,7 @@ if (CPUS["MINX"]~=null) then
MAME_DIR .. "src/devices/cpu/minx/minxfunc.h", MAME_DIR .. "src/devices/cpu/minx/minxfunc.h",
MAME_DIR .. "src/devices/cpu/minx/minxopce.h", MAME_DIR .. "src/devices/cpu/minx/minxopce.h",
MAME_DIR .. "src/devices/cpu/minx/minxopcf.h", MAME_DIR .. "src/devices/cpu/minx/minxopcf.h",
MAME_DIR .. "src/devices/cpu/minx/minxops.h", MAME_DIR .. "src/devices/cpu/minx/minxops.h",
} }
end end
@ -1696,7 +1696,7 @@ if (CPUS["SATURN"]~=null) then
MAME_DIR .. "src/devices/cpu/saturn/saturn.cpp", MAME_DIR .. "src/devices/cpu/saturn/saturn.cpp",
MAME_DIR .. "src/devices/cpu/saturn/saturn.h", MAME_DIR .. "src/devices/cpu/saturn/saturn.h",
MAME_DIR .. "src/devices/cpu/saturn/satops.inc", MAME_DIR .. "src/devices/cpu/saturn/satops.inc",
MAME_DIR .. "src/devices/cpu/saturn/sattable.inc", MAME_DIR .. "src/devices/cpu/saturn/sattable.inc",
} }
end end
@ -2043,7 +2043,7 @@ if (CPUS["TMS57002"]~=null) then
{ MAME_DIR .. "src/devices/cpu/tms57002/tms57kdec.cpp", GEN_DIR .. "emu/cpu/tms57002/tms57002.inc" }, { MAME_DIR .. "src/devices/cpu/tms57002/tms57kdec.cpp", GEN_DIR .. "emu/cpu/tms57002/tms57002.inc" },
{ MAME_DIR .. "src/devices/cpu/tms57002/tms57002.cpp", GEN_DIR .. "emu/cpu/tms57002/tms57002.inc" }, { MAME_DIR .. "src/devices/cpu/tms57002/tms57002.cpp", GEN_DIR .. "emu/cpu/tms57002/tms57002.inc" },
} }
custombuildtask { custombuildtask {
{ MAME_DIR .. "src/devices/cpu/tms57002/tmsinstr.lst" , GEN_DIR .. "emu/cpu/tms57002/tms57002.inc", { MAME_DIR .. "src/devices/cpu/tms57002/tmsmake.py" }, {"@echo Generating TMS57002 source file...", PYTHON .. " $(1) $(<) $(@)" } } { MAME_DIR .. "src/devices/cpu/tms57002/tmsinstr.lst" , GEN_DIR .. "emu/cpu/tms57002/tms57002.inc", { MAME_DIR .. "src/devices/cpu/tms57002/tmsmake.py" }, {"@echo Generating TMS57002 source file...", PYTHON .. " $(1) $(<) $(@)" } }
} }
end end

View File

@ -280,7 +280,7 @@ files {
MAME_DIR .. "src/emu/ui/starimg.h", MAME_DIR .. "src/emu/ui/starimg.h",
MAME_DIR .. "src/emu/ui/toolbar.h", MAME_DIR .. "src/emu/ui/toolbar.h",
MAME_DIR .. "src/emu/ui/utils.cpp", MAME_DIR .. "src/emu/ui/utils.cpp",
MAME_DIR .. "src/emu/ui/utils.h", MAME_DIR .. "src/emu/ui/utils.h",
MAME_DIR .. "src/emu/validity.cpp", MAME_DIR .. "src/emu/validity.cpp",
MAME_DIR .. "src/emu/validity.h", MAME_DIR .. "src/emu/validity.h",
MAME_DIR .. "src/emu/video.cpp", MAME_DIR .. "src/emu/video.cpp",

View File

@ -10,7 +10,7 @@
--------------------------------------------------------------------------- ---------------------------------------------------------------------------
function mainProject(_target, _subtarget) function mainProject(_target, _subtarget)
if (_OPTIONS["SOURCES"] == nil) then if (_OPTIONS["SOURCES"] == nil) then
if (_target == _subtarget) then if (_target == _subtarget) then
project (_target) project (_target)
else else
@ -19,13 +19,13 @@ if (_OPTIONS["SOURCES"] == nil) then
else else
project (_target .. _subtarget) project (_target .. _subtarget)
end end
end end
else else
project (_subtarget) project (_subtarget)
end end
uuid (os.uuid(_target .."_" .. _subtarget)) uuid (os.uuid(_target .."_" .. _subtarget))
kind "ConsoleApp" kind "ConsoleApp"
configuration { "android*" } configuration { "android*" }
targetprefix "lib" targetprefix "lib"
targetname "main" targetname "main"
@ -39,7 +39,7 @@ end
"GLESv1_CM", "GLESv1_CM",
"GLESv2", "GLESv2",
"SDL2", "SDL2",
} }
configuration { "pnacl" } configuration { "pnacl" }
kind "ConsoleApp" kind "ConsoleApp"
targetextension ".pexe" targetextension ".pexe"
@ -53,7 +53,7 @@ end
addprojectflags() addprojectflags()
flags { flags {
"NoManifest", "NoManifest",
"Symbols", -- always include minimum symbols for executables "Symbols", -- always include minimum symbols for executables
} }
if _OPTIONS["SYMBOLS"] then if _OPTIONS["SYMBOLS"] then
@ -63,7 +63,7 @@ end
"$(SILENT) objdump --section=.text --line-numbers --syms --demangle $(TARGET) >$(subst .exe,.sym,$(TARGET))" "$(SILENT) objdump --section=.text --line-numbers --syms --demangle $(TARGET) >$(subst .exe,.sym,$(TARGET))"
} }
end end
configuration { "vs*" } configuration { "vs*" }
flags { flags {
"Unicode", "Unicode",
@ -112,7 +112,7 @@ end
targetextension "" targetextension ""
configuration { "asmjs" } configuration { "asmjs" }
targetextension ".bc" targetextension ".bc"
if os.getenv("EMSCRIPTEN") then if os.getenv("EMSCRIPTEN") then
local emccopts = "" local emccopts = ""
emccopts = emccopts .. " -O3" emccopts = emccopts .. " -O3"
@ -141,12 +141,12 @@ end
includedirs { includedirs {
MAME_DIR .. "3rdparty/SDL2/include", MAME_DIR .. "3rdparty/SDL2/include",
} }
files { files {
MAME_DIR .. "3rdparty/SDL2/src/main/android/SDL_android_main.c", MAME_DIR .. "3rdparty/SDL2/src/main/android/SDL_android_main.c",
} }
targetsuffix "" targetsuffix ""
if _OPTIONS["SEPARATE_BIN"]~="1" then if _OPTIONS["SEPARATE_BIN"]~="1" then
if _OPTIONS["PLATFORM"]=="arm" then if _OPTIONS["PLATFORM"]=="arm" then
targetdir(MAME_DIR .. "android-project/app/src/main/libs/armeabi-v7a") targetdir(MAME_DIR .. "android-project/app/src/main/libs/armeabi-v7a")
end end
@ -167,11 +167,11 @@ end
end end
end end
else else
if _OPTIONS["SEPARATE_BIN"]~="1" then if _OPTIONS["SEPARATE_BIN"]~="1" then
targetdir(MAME_DIR) targetdir(MAME_DIR)
end end
end end
findfunction("linkProjects_" .. _OPTIONS["target"] .. "_" .. _OPTIONS["subtarget"])(_OPTIONS["target"], _OPTIONS["subtarget"]) findfunction("linkProjects_" .. _OPTIONS["target"] .. "_" .. _OPTIONS["subtarget"])(_OPTIONS["target"], _OPTIONS["subtarget"])
links { links {
"osd_" .. _OPTIONS["osd"], "osd_" .. _OPTIONS["osd"],
@ -201,7 +201,7 @@ end
} }
if _OPTIONS["USE_LIBUV"]=="1" then if _OPTIONS["USE_LIBUV"]=="1" then
links { links {
ext_lib("uv"), ext_lib("uv"),
"http-parser", "http-parser",
} }
@ -221,9 +221,9 @@ end
"bgfx", "bgfx",
"ocore_" .. _OPTIONS["osd"], "ocore_" .. _OPTIONS["osd"],
} }
override_resources = false; override_resources = false;
maintargetosdoptions(_target,_subtarget) maintargetosdoptions(_target,_subtarget)
includedirs { includedirs {
@ -273,7 +273,7 @@ end
dependency { dependency {
{ "$(OBJDIR)/mame.res" , GEN_DIR .. "resource/" .. rctarget .. "vers.rc", true }, { "$(OBJDIR)/mame.res" , GEN_DIR .. "resource/" .. rctarget .. "vers.rc", true },
} }
end end
end end
local mainfile = MAME_DIR .. "src/".._target .."/" .. _subtarget ..".cpp" local mainfile = MAME_DIR .. "src/".._target .."/" .. _subtarget ..".cpp"
@ -285,12 +285,12 @@ end
MAME_DIR .. "src/version.cpp", MAME_DIR .. "src/version.cpp",
GEN_DIR .. _target .. "/" .. _subtarget .."/drivlist.cpp", GEN_DIR .. _target .. "/" .. _subtarget .."/drivlist.cpp",
} }
if (_OPTIONS["SOURCES"] == nil) then if (_OPTIONS["SOURCES"] == nil) then
if os.isfile(MAME_DIR .. "src/".._target .."/" .. _subtarget ..".flt") then if os.isfile(MAME_DIR .. "src/".._target .."/" .. _subtarget ..".flt") then
dependency { dependency {
{ {
GEN_DIR .. _target .. "/" .. _subtarget .."/drivlist.cpp", MAME_DIR .. "src/".._target .."/" .. _target ..".lst", true }, GEN_DIR .. _target .. "/" .. _subtarget .."/drivlist.cpp", MAME_DIR .. "src/".._target .."/" .. _target ..".lst", true },
} }
custombuildtask { custombuildtask {
@ -303,7 +303,7 @@ if (_OPTIONS["SOURCES"] == nil) then
} }
else else
dependency { dependency {
{ {
GEN_DIR .. _target .. "/" .. _target .."/drivlist.cpp", MAME_DIR .. "src/".._target .."/" .. _target ..".lst", true }, GEN_DIR .. _target .. "/" .. _target .."/drivlist.cpp", MAME_DIR .. "src/".._target .."/" .. _target ..".lst", true },
} }
custombuildtask { custombuildtask {
@ -311,11 +311,11 @@ if (_OPTIONS["SOURCES"] == nil) then
} }
end end
end end
end end
if (_OPTIONS["SOURCES"] ~= nil) then if (_OPTIONS["SOURCES"] ~= nil) then
dependency { dependency {
{ {
GEN_DIR .. _target .. "/" .. _subtarget .."/drivlist.cpp", MAME_DIR .. "src/".._target .."/" .. _target ..".lst", true }, GEN_DIR .. _target .. "/" .. _subtarget .."/drivlist.cpp", MAME_DIR .. "src/".._target .."/" .. _target ..".lst", true },
} }
custombuildtask { custombuildtask {
@ -331,17 +331,17 @@ if _OPTIONS["FORCE_VERSION_COMPILE"]=="1" then
} }
end end
configuration { "mingw*" } configuration { "mingw*" }
custombuildtask { custombuildtask {
{ MAME_DIR .. "src/version.cpp" , GEN_DIR .. "resource/" .. rctarget .. "vers.rc", { MAME_DIR .. "scripts/build/verinfo.py" }, {"@echo Emitting " .. rctarget .. "vers.rc" .. "...", PYTHON .. " $(1) -r -b " .. rctarget .. " $(<) > $(@)" }}, { MAME_DIR .. "src/version.cpp" , GEN_DIR .. "resource/" .. rctarget .. "vers.rc", { MAME_DIR .. "scripts/build/verinfo.py" }, {"@echo Emitting " .. rctarget .. "vers.rc" .. "...", PYTHON .. " $(1) -r -b " .. rctarget .. " $(<) > $(@)" }},
} }
configuration { "vs*" } configuration { "vs*" }
prebuildcommands { prebuildcommands {
"mkdir " .. path.translate(GEN_DIR .. "resource/","\\") .. " 2>NUL", "mkdir " .. path.translate(GEN_DIR .. "resource/","\\") .. " 2>NUL",
"@echo Emitting ".. rctarget .. "vers.rc...", "@echo Emitting ".. rctarget .. "vers.rc...",
PYTHON .. " " .. path.translate(MAME_DIR .. "scripts/build/verinfo.py","\\") .. " -r -b " .. rctarget .. " " .. path.translate(MAME_DIR .. "src/version.cpp","\\") .. " > " .. path.translate(GEN_DIR .. "resource/" .. rctarget .. "vers.rc", "\\") , PYTHON .. " " .. path.translate(MAME_DIR .. "scripts/build/verinfo.py","\\") .. " -r -b " .. rctarget .. " " .. path.translate(MAME_DIR .. "src/version.cpp","\\") .. " > " .. path.translate(GEN_DIR .. "resource/" .. rctarget .. "vers.rc", "\\") ,
} }
configuration { } configuration { }
debugdir (MAME_DIR) debugdir (MAME_DIR)

View File

@ -68,7 +68,7 @@ project "netlist"
MAME_DIR .. "src/lib/netlist/analog/nld_opamps.h", MAME_DIR .. "src/lib/netlist/analog/nld_opamps.h",
MAME_DIR .. "src/lib/netlist/solver/nld_solver.cpp", MAME_DIR .. "src/lib/netlist/solver/nld_solver.cpp",
MAME_DIR .. "src/lib/netlist/solver/nld_solver.h", MAME_DIR .. "src/lib/netlist/solver/nld_solver.h",
MAME_DIR .. "src/lib/netlist/solver/nld_matrix_solver.h", MAME_DIR .. "src/lib/netlist/solver/nld_matrix_solver.h",
MAME_DIR .. "src/lib/netlist/solver/nld_ms_direct.h", MAME_DIR .. "src/lib/netlist/solver/nld_ms_direct.h",
MAME_DIR .. "src/lib/netlist/solver/nld_ms_direct1.h", MAME_DIR .. "src/lib/netlist/solver/nld_ms_direct1.h",
MAME_DIR .. "src/lib/netlist/solver/nld_ms_direct2.h", MAME_DIR .. "src/lib/netlist/solver/nld_ms_direct2.h",
@ -78,7 +78,7 @@ project "netlist"
MAME_DIR .. "src/lib/netlist/solver/mat_cr.h", MAME_DIR .. "src/lib/netlist/solver/mat_cr.h",
MAME_DIR .. "src/lib/netlist/solver/nld_ms_sm.h", MAME_DIR .. "src/lib/netlist/solver/nld_ms_sm.h",
MAME_DIR .. "src/lib/netlist/solver/nld_ms_direct_lu.h", MAME_DIR .. "src/lib/netlist/solver/nld_ms_direct_lu.h",
MAME_DIR .. "src/lib/netlist/solver/vector_base.h", MAME_DIR .. "src/lib/netlist/solver/vector_base.h",
MAME_DIR .. "src/lib/netlist/devices/nld_4020.cpp", MAME_DIR .. "src/lib/netlist/devices/nld_4020.cpp",
MAME_DIR .. "src/lib/netlist/devices/nld_4020.h", MAME_DIR .. "src/lib/netlist/devices/nld_4020.h",
MAME_DIR .. "src/lib/netlist/devices/nld_4066.cpp", MAME_DIR .. "src/lib/netlist/devices/nld_4066.cpp",
@ -168,5 +168,5 @@ project "netlist"
MAME_DIR .. "src/lib/netlist/macro/nlm_opamp.cpp", MAME_DIR .. "src/lib/netlist/macro/nlm_opamp.cpp",
MAME_DIR .. "src/lib/netlist/macro/nlm_opamp.h", MAME_DIR .. "src/lib/netlist/macro/nlm_opamp.h",
MAME_DIR .. "src/lib/netlist/macro/nlm_other.cpp", MAME_DIR .. "src/lib/netlist/macro/nlm_other.cpp",
MAME_DIR .. "src/lib/netlist/macro/nlm_other.h", MAME_DIR .. "src/lib/netlist/macro/nlm_other.h",
} }

View File

@ -10,7 +10,7 @@
--------------------------------------------------------------------------- ---------------------------------------------------------------------------
function string.starts(String,Start) function string.starts(String,Start)
return string.sub(String,1,string.len(Start))==Start return string.sub(String,1,string.len(Start))==Start
end end
function addlibfromstring(str) function addlibfromstring(str)
@ -127,7 +127,7 @@ function osdmodulesbuild()
"__STDC_FORMAT_MACROS", "__STDC_FORMAT_MACROS",
"__STDC_CONSTANT_MACROS", "__STDC_CONSTANT_MACROS",
} }
files { files {
MAME_DIR .. "src/osd/modules/render/drawbgfx.cpp", MAME_DIR .. "src/osd/modules/render/drawbgfx.cpp",
MAME_DIR .. "src/osd/modules/render/binpacker.cpp", MAME_DIR .. "src/osd/modules/render/binpacker.cpp",
@ -202,7 +202,7 @@ function qtdebuggerbuild()
removeflags { removeflags {
"SingleOutputDir", "SingleOutputDir",
} }
local version = str_to_version(_OPTIONS["gcc_version"]) local version = str_to_version(_OPTIONS["gcc_version"])
if _OPTIONS["gcc"]~=nil and (string.find(_OPTIONS["gcc"], "clang") or string.find(_OPTIONS["gcc"], "asmjs")) then if _OPTIONS["gcc"]~=nil and (string.find(_OPTIONS["gcc"], "clang") or string.find(_OPTIONS["gcc"], "asmjs")) then
configuration { "gmake" } configuration { "gmake" }
if (version >= 30600) then if (version >= 30600) then
@ -276,14 +276,14 @@ function qtdebuggerbuild()
custombuildtask { custombuildtask {
{ MAME_DIR .. "src/osd/modules/debugger/qt/debuggerview.h", GEN_DIR .. "osd/modules/debugger/qt/debuggerview.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }}, { MAME_DIR .. "src/osd/modules/debugger/qt/debuggerview.h", GEN_DIR .. "osd/modules/debugger/qt/debuggerview.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }},
{ MAME_DIR .. "src/osd/modules/debugger/qt/windowqt.h", GEN_DIR .. "osd/modules/debugger/qt/windowqt.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }}, { MAME_DIR .. "src/osd/modules/debugger/qt/windowqt.h", GEN_DIR .. "osd/modules/debugger/qt/windowqt.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }},
{ MAME_DIR .. "src/osd/modules/debugger/qt/logwindow.h", GEN_DIR .. "osd/modules/debugger/qt/logwindow.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }}, { MAME_DIR .. "src/osd/modules/debugger/qt/logwindow.h", GEN_DIR .. "osd/modules/debugger/qt/logwindow.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }},
{ MAME_DIR .. "src/osd/modules/debugger/qt/dasmwindow.h", GEN_DIR .. "osd/modules/debugger/qt/dasmwindow.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }}, { MAME_DIR .. "src/osd/modules/debugger/qt/dasmwindow.h", GEN_DIR .. "osd/modules/debugger/qt/dasmwindow.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }},
{ MAME_DIR .. "src/osd/modules/debugger/qt/mainwindow.h", GEN_DIR .. "osd/modules/debugger/qt/mainwindow.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }}, { MAME_DIR .. "src/osd/modules/debugger/qt/mainwindow.h", GEN_DIR .. "osd/modules/debugger/qt/mainwindow.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }},
{ MAME_DIR .. "src/osd/modules/debugger/qt/memorywindow.h", GEN_DIR .. "osd/modules/debugger/qt/memorywindow.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }}, { MAME_DIR .. "src/osd/modules/debugger/qt/memorywindow.h", GEN_DIR .. "osd/modules/debugger/qt/memorywindow.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }},
{ MAME_DIR .. "src/osd/modules/debugger/qt/breakpointswindow.h", GEN_DIR .. "osd/modules/debugger/qt/breakpointswindow.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }}, { MAME_DIR .. "src/osd/modules/debugger/qt/breakpointswindow.h", GEN_DIR .. "osd/modules/debugger/qt/breakpointswindow.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }},
{ MAME_DIR .. "src/osd/modules/debugger/qt/deviceswindow.h", GEN_DIR .. "osd/modules/debugger/qt/deviceswindow.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }}, { MAME_DIR .. "src/osd/modules/debugger/qt/deviceswindow.h", GEN_DIR .. "osd/modules/debugger/qt/deviceswindow.moc.cpp", { }, { MOC .. "$(MOCINCPATH) $(<) -o $(@)" }},
{ MAME_DIR .. "src/osd/modules/debugger/qt/deviceinformationwindow.h", GEN_DIR .. "osd/modules/debugger/qt/deviceinformationwindow.moc.cpp", { },{ MOC .. "$(MOCINCPATH) $(<) -o $(@)" }}, { MAME_DIR .. "src/osd/modules/debugger/qt/deviceinformationwindow.h", GEN_DIR .. "osd/modules/debugger/qt/deviceinformationwindow.moc.cpp", { },{ MOC .. "$(MOCINCPATH) $(<) -o $(@)" }},
} }

View File

@ -41,9 +41,9 @@ project ("osd_" .. _OPTIONS["osd"])
removeflags { removeflags {
"SingleOutputDir", "SingleOutputDir",
} }
dofile("osdmini_cfg.lua") dofile("osdmini_cfg.lua")
includedirs { includedirs {
MAME_DIR .. "src/emu", MAME_DIR .. "src/emu",
MAME_DIR .. "src/osd", MAME_DIR .. "src/osd",
@ -94,24 +94,24 @@ project ("osd_" .. _OPTIONS["osd"])
MAME_DIR .. "src/osd/modules/input/input_windows.h", MAME_DIR .. "src/osd/modules/input/input_windows.h",
MAME_DIR .. "src/osd/modules/input/input_xinput.cpp", MAME_DIR .. "src/osd/modules/input/input_xinput.cpp",
} }
project ("ocore_" .. _OPTIONS["osd"]) project ("ocore_" .. _OPTIONS["osd"])
uuid (os.uuid("ocore_" .. _OPTIONS["osd"])) uuid (os.uuid("ocore_" .. _OPTIONS["osd"]))
kind (LIBTYPE) kind (LIBTYPE)
removeflags { removeflags {
"SingleOutputDir", "SingleOutputDir",
} }
dofile("osdmini_cfg.lua") dofile("osdmini_cfg.lua")
includedirs { includedirs {
MAME_DIR .. "src/emu", MAME_DIR .. "src/emu",
MAME_DIR .. "src/osd", MAME_DIR .. "src/osd",
MAME_DIR .. "src/lib", MAME_DIR .. "src/lib",
MAME_DIR .. "src/lib/util", MAME_DIR .. "src/lib/util",
} }
files { files {
MAME_DIR .. "src/osd/osdnet.cpp", MAME_DIR .. "src/osd/osdnet.cpp",
MAME_DIR .. "src/osd/osdnet.h", MAME_DIR .. "src/osd/osdnet.h",

View File

@ -89,7 +89,7 @@ function maintargetosdoptions(_target,_subtarget)
configuration { "x64", "vs*" } configuration { "x64", "vs*" }
libdirs { libdirs {
path.join(_OPTIONS["SDL_INSTALL_ROOT"],"lib","x64") path.join(_OPTIONS["SDL_INSTALL_ROOT"],"lib","x64")
} }
end end
links { links {
"psapi", "psapi",
@ -116,15 +116,15 @@ function maintargetosdoptions(_target,_subtarget)
"psapi" "psapi"
} }
configuration { } configuration { }
if _OPTIONS["targetos"]=="macosx" then if _OPTIONS["targetos"]=="macosx" then
if _OPTIONS["with-bundled-sdl2"]~=nil then if _OPTIONS["with-bundled-sdl2"]~=nil then
links { links {
"SDL2", "SDL2",
} }
end end
end end
end end
@ -145,8 +145,8 @@ newoption {
} }
newoption { newoption {
trigger = "SDL_INI_PATH", trigger = "SDL_INI_PATH",
description = "Default search path for .ini files", description = "Default search path for .ini files",
} }
newoption { newoption {
@ -255,22 +255,22 @@ if BASE_TARGETOS=="unix" then
"-framework QuartzCore", "-framework QuartzCore",
"-framework OpenGL", "-framework OpenGL",
} }
if os_version>=101100 then if os_version>=101100 then
linkoptions { linkoptions {
"-weak_framework Metal", "-weak_framework Metal",
} }
end end
if _OPTIONS["with-bundled-sdl2"]~=nil then if _OPTIONS["with-bundled-sdl2"]~=nil then
linkoptions { linkoptions {
"-framework AudioUnit", "-framework AudioUnit",
"-framework CoreAudio", "-framework CoreAudio",
"-framework Carbon", "-framework Carbon",
"-framework ForceFeedback", "-framework ForceFeedback",
"-framework IOKit", "-framework IOKit",
"-framework CoreVideo", "-framework CoreVideo",
} }
else else
if _OPTIONS["USE_LIBSDL"]~="1" then if _OPTIONS["USE_LIBSDL"]~="1" then
linkoptions { linkoptions {
@ -303,8 +303,8 @@ if BASE_TARGETOS=="unix" then
local str = backtick(sdlconfigcmd() .. " --libs") local str = backtick(sdlconfigcmd() .. " --libs")
addlibfromstring(str) addlibfromstring(str)
addoptionsfromstring(str) addoptionsfromstring(str)
end end
if _OPTIONS["targetos"]~="haiku" and _OPTIONS["targetos"]~="android" then if _OPTIONS["targetos"]~="haiku" and _OPTIONS["targetos"]~="android" then
links { links {
"m", "m",

View File

@ -19,9 +19,9 @@ if _OPTIONS["NO_OPENGL"]~="1" and _OPTIONS["USE_DISPATCH_GL"]~="1" and _OPTIONS[
end end
if _OPTIONS["SDL_INI_PATH"]~=nil then if _OPTIONS["SDL_INI_PATH"]~=nil then
defines { defines {
"'INI_PATH=\"" .. _OPTIONS["SDL_INI_PATH"] .. "\"'", "'INI_PATH=\"" .. _OPTIONS["SDL_INI_PATH"] .. "\"'",
} }
end end
if _OPTIONS["NO_X11"]=="1" then if _OPTIONS["NO_X11"]=="1" then
@ -74,20 +74,20 @@ if BASE_TARGETOS=="unix" then
"SDLMAME_UNIX", "SDLMAME_UNIX",
} }
if _OPTIONS["targetos"]=="macosx" then if _OPTIONS["targetos"]=="macosx" then
if _OPTIONS["with-bundled-sdl2"]==nil then if _OPTIONS["with-bundled-sdl2"]==nil then
if _OPTIONS["USE_LIBSDL"]~="1" then if _OPTIONS["USE_LIBSDL"]~="1" then
buildoptions { buildoptions {
"-F" .. _OPTIONS["SDL_FRAMEWORK_PATH"], "-F" .. _OPTIONS["SDL_FRAMEWORK_PATH"],
} }
else else
defines { defines {
"MACOSX_USE_LIBSDL", "MACOSX_USE_LIBSDL",
} }
buildoptions { buildoptions {
backtick(sdlconfigcmd() .. " --cflags | sed 's:/SDL::'"), backtick(sdlconfigcmd() .. " --cflags | sed 's:/SDL::'"),
} }
end end
end end
else else
buildoptions { buildoptions {
backtick(sdlconfigcmd() .. " --cflags"), backtick(sdlconfigcmd() .. " --cflags"),

View File

@ -275,10 +275,10 @@ if _OPTIONS["with-tools"] then
kind "ConsoleApp" kind "ConsoleApp"
flags { flags {
"Symbols", -- always include minimum symbols for executables "Symbols", -- always include minimum symbols for executables
} }
if _OPTIONS["SEPARATE_BIN"]~="1" then if _OPTIONS["SEPARATE_BIN"]~="1" then
targetdir(MAME_DIR) targetdir(MAME_DIR)
end end
@ -289,7 +289,7 @@ if _OPTIONS["with-tools"] then
includedirs { includedirs {
MAME_DIR .. "src/osd", MAME_DIR .. "src/osd",
} }
files { files {
MAME_DIR .. "src/osd/windows/ledutil.cpp", MAME_DIR .. "src/osd/windows/ledutil.cpp",
} }

View File

@ -81,7 +81,7 @@ if (SOUNDS["DISCRETE"]~=null) then
MAME_DIR .. "src/devices/sound/disc_mth.inc", MAME_DIR .. "src/devices/sound/disc_mth.inc",
MAME_DIR .. "src/devices/sound/disc_sys.inc", MAME_DIR .. "src/devices/sound/disc_sys.inc",
MAME_DIR .. "src/devices/sound/disc_wav.h", MAME_DIR .. "src/devices/sound/disc_wav.h",
MAME_DIR .. "src/devices/sound/disc_wav.inc", MAME_DIR .. "src/devices/sound/disc_wav.inc",
} }
end end
@ -135,8 +135,8 @@ end
if (SOUNDS["TIA"]~=null) then if (SOUNDS["TIA"]~=null) then
files { files {
MAME_DIR .. "src/devices/sound/tiasound.cpp", MAME_DIR .. "src/devices/sound/tiasound.cpp",
MAME_DIR .. "src/devices/sound/tiasound.h", MAME_DIR .. "src/devices/sound/tiasound.h",
MAME_DIR .. "src/devices/sound/tiaintf.cpp", MAME_DIR .. "src/devices/sound/tiaintf.cpp",
MAME_DIR .. "src/devices/sound/tiaintf.h", MAME_DIR .. "src/devices/sound/tiaintf.h",
} }
@ -483,7 +483,7 @@ end
--------------------------------------------------- ---------------------------------------------------
-- L7A1045 L6028 DSP-A -- L7A1045 L6028 DSP-A
--@src/devices/sound/l7a1045_l6028_dsp_a.h,SOUNDS["L7A1045"] = true --@src/devices/sound/l7a1045_l6028_dsp_a.h,SOUNDS["L7A1045"] = true
--------------------------------------------------- ---------------------------------------------------
@ -730,8 +730,8 @@ end
if (SOUNDS["QSOUND"]~=null) then if (SOUNDS["QSOUND"]~=null) then
files { files {
MAME_DIR .. "src/devices/sound/qsound.cpp", MAME_DIR .. "src/devices/sound/qsound.cpp",
MAME_DIR .. "src/devices/sound/qsound.h", MAME_DIR .. "src/devices/sound/qsound.h",
MAME_DIR .. "src/devices/cpu/dsp16/dsp16.cpp", MAME_DIR .. "src/devices/cpu/dsp16/dsp16.cpp",
MAME_DIR .. "src/devices/cpu/dsp16/dsp16.h", MAME_DIR .. "src/devices/cpu/dsp16/dsp16.h",
MAME_DIR .. "src/devices/cpu/dsp16/dsp16dis.cpp", MAME_DIR .. "src/devices/cpu/dsp16/dsp16dis.cpp",
@ -1154,8 +1154,8 @@ if (SOUNDS["YM2413"]~=null) then
} }
end end
if (SOUNDS["YM2203"]~=null or SOUNDS["YM2608"]~=null or SOUNDS["YM2610"]~=null or SOUNDS["YM2610B"]~=null or SOUNDS["YM2612"]~=null or SOUNDS["YM3438"]~=null) then if (SOUNDS["YM2203"]~=null or SOUNDS["YM2608"]~=null or SOUNDS["YM2610"]~=null or SOUNDS["YM2610B"]~=null or SOUNDS["YM2612"]~=null or SOUNDS["YM3438"]~=null) then
--if (SOUNDS["YM2203"]~=null) then --if (SOUNDS["YM2203"]~=null) then
files { files {
MAME_DIR .. "src/devices/sound/2203intf.cpp", MAME_DIR .. "src/devices/sound/2203intf.cpp",
MAME_DIR .. "src/devices/sound/2203intf.h", MAME_DIR .. "src/devices/sound/2203intf.h",
@ -1169,12 +1169,12 @@ if (SOUNDS["YM2203"]~=null or SOUNDS["YM2608"]~=null or SOUNDS["YM2610"]~=null o
--if (SOUNDS["YM2608"]~=null) then --if (SOUNDS["YM2608"]~=null) then
files { files {
MAME_DIR .. "src/devices/sound/2608intf.cpp", MAME_DIR .. "src/devices/sound/2608intf.cpp",
MAME_DIR .. "src/devices/sound/2608intf.h", MAME_DIR .. "src/devices/sound/2608intf.h",
MAME_DIR .. "src/devices/sound/ay8910.cpp", MAME_DIR .. "src/devices/sound/ay8910.cpp",
MAME_DIR .. "src/devices/sound/ay8910.h", MAME_DIR .. "src/devices/sound/ay8910.h",
MAME_DIR .. "src/devices/sound/fm.cpp", MAME_DIR .. "src/devices/sound/fm.cpp",
MAME_DIR .. "src/devices/sound/fm.h", MAME_DIR .. "src/devices/sound/fm.h",
MAME_DIR .. "src/devices/sound/ymdeltat.cpp", MAME_DIR .. "src/devices/sound/ymdeltat.cpp",
MAME_DIR .. "src/devices/sound/ymdeltat.h", MAME_DIR .. "src/devices/sound/ymdeltat.h",
} }
@ -1182,12 +1182,12 @@ if (SOUNDS["YM2203"]~=null or SOUNDS["YM2608"]~=null or SOUNDS["YM2610"]~=null o
--if (SOUNDS["YM2610"]~=null or SOUNDS["YM2610B"]~=null) then --if (SOUNDS["YM2610"]~=null or SOUNDS["YM2610B"]~=null) then
files { files {
MAME_DIR .. "src/devices/sound/2610intf.cpp", MAME_DIR .. "src/devices/sound/2610intf.cpp",
MAME_DIR .. "src/devices/sound/2610intf.h", MAME_DIR .. "src/devices/sound/2610intf.h",
MAME_DIR .. "src/devices/sound/ay8910.cpp", MAME_DIR .. "src/devices/sound/ay8910.cpp",
MAME_DIR .. "src/devices/sound/ay8910.h", MAME_DIR .. "src/devices/sound/ay8910.h",
MAME_DIR .. "src/devices/sound/fm.cpp", MAME_DIR .. "src/devices/sound/fm.cpp",
MAME_DIR .. "src/devices/sound/fm.h", MAME_DIR .. "src/devices/sound/fm.h",
MAME_DIR .. "src/devices/sound/ymdeltat.cpp", MAME_DIR .. "src/devices/sound/ymdeltat.cpp",
MAME_DIR .. "src/devices/sound/ymdeltat.h", MAME_DIR .. "src/devices/sound/ymdeltat.h",
} }
@ -1195,10 +1195,10 @@ if (SOUNDS["YM2203"]~=null or SOUNDS["YM2608"]~=null or SOUNDS["YM2610"]~=null o
--if (SOUNDS["YM2612"]~=null or SOUNDS["YM3438"]~=null) then --if (SOUNDS["YM2612"]~=null or SOUNDS["YM3438"]~=null) then
files { files {
MAME_DIR .. "src/devices/sound/2612intf.cpp", MAME_DIR .. "src/devices/sound/2612intf.cpp",
MAME_DIR .. "src/devices/sound/2612intf.h", MAME_DIR .. "src/devices/sound/2612intf.h",
MAME_DIR .. "src/devices/sound/ay8910.cpp", MAME_DIR .. "src/devices/sound/ay8910.cpp",
MAME_DIR .. "src/devices/sound/ay8910.h", MAME_DIR .. "src/devices/sound/ay8910.h",
MAME_DIR .. "src/devices/sound/fm2612.cpp", MAME_DIR .. "src/devices/sound/fm2612.cpp",
} }
--end --end
@ -1207,10 +1207,10 @@ end
if (SOUNDS["YM3812"]~=null or SOUNDS["YM3526"]~=null or SOUNDS["Y8950"]~=null) then if (SOUNDS["YM3812"]~=null or SOUNDS["YM3526"]~=null or SOUNDS["Y8950"]~=null) then
--if (SOUNDS["YM3812"]~=null) then --if (SOUNDS["YM3812"]~=null) then
files { files {
MAME_DIR .. "src/devices/sound/3812intf.cpp", MAME_DIR .. "src/devices/sound/3812intf.cpp",
MAME_DIR .. "src/devices/sound/3812intf.h", MAME_DIR .. "src/devices/sound/3812intf.h",
MAME_DIR .. "src/devices/sound/fmopl.cpp", MAME_DIR .. "src/devices/sound/fmopl.cpp",
MAME_DIR .. "src/devices/sound/fmopl.h", MAME_DIR .. "src/devices/sound/fmopl.h",
MAME_DIR .. "src/devices/sound/ymdeltat.cpp", MAME_DIR .. "src/devices/sound/ymdeltat.cpp",
MAME_DIR .. "src/devices/sound/ymdeltat.h", MAME_DIR .. "src/devices/sound/ymdeltat.h",
} }
@ -1218,10 +1218,10 @@ if (SOUNDS["YM3812"]~=null or SOUNDS["YM3526"]~=null or SOUNDS["Y8950"]~=null) t
--if (SOUNDS["YM3526"]~=null) then --if (SOUNDS["YM3526"]~=null) then
files { files {
MAME_DIR .. "src/devices/sound/3526intf.cpp", MAME_DIR .. "src/devices/sound/3526intf.cpp",
MAME_DIR .. "src/devices/sound/3526intf.h", MAME_DIR .. "src/devices/sound/3526intf.h",
MAME_DIR .. "src/devices/sound/fmopl.cpp", MAME_DIR .. "src/devices/sound/fmopl.cpp",
MAME_DIR .. "src/devices/sound/fmopl.h", MAME_DIR .. "src/devices/sound/fmopl.h",
MAME_DIR .. "src/devices/sound/ymdeltat.cpp", MAME_DIR .. "src/devices/sound/ymdeltat.cpp",
MAME_DIR .. "src/devices/sound/ymdeltat.h", MAME_DIR .. "src/devices/sound/ymdeltat.h",
} }
@ -1229,10 +1229,10 @@ if (SOUNDS["YM3812"]~=null or SOUNDS["YM3526"]~=null or SOUNDS["Y8950"]~=null) t
--if (SOUNDS["Y8950"]~=null) then --if (SOUNDS["Y8950"]~=null) then
files { files {
MAME_DIR .. "src/devices/sound/8950intf.cpp", MAME_DIR .. "src/devices/sound/8950intf.cpp",
MAME_DIR .. "src/devices/sound/8950intf.h", MAME_DIR .. "src/devices/sound/8950intf.h",
MAME_DIR .. "src/devices/sound/fmopl.cpp", MAME_DIR .. "src/devices/sound/fmopl.cpp",
MAME_DIR .. "src/devices/sound/fmopl.h", MAME_DIR .. "src/devices/sound/fmopl.h",
MAME_DIR .. "src/devices/sound/ymdeltat.cpp", MAME_DIR .. "src/devices/sound/ymdeltat.cpp",
MAME_DIR .. "src/devices/sound/ymdeltat.h", MAME_DIR .. "src/devices/sound/ymdeltat.h",
} }
@ -1241,8 +1241,8 @@ end
if (SOUNDS["YMF262"]~=null) then if (SOUNDS["YMF262"]~=null) then
files { files {
MAME_DIR .. "src/devices/sound/ymf262.cpp", MAME_DIR .. "src/devices/sound/ymf262.cpp",
MAME_DIR .. "src/devices/sound/ymf262.h", MAME_DIR .. "src/devices/sound/ymf262.h",
MAME_DIR .. "src/devices/sound/262intf.cpp", MAME_DIR .. "src/devices/sound/262intf.cpp",
MAME_DIR .. "src/devices/sound/262intf.h", MAME_DIR .. "src/devices/sound/262intf.h",
} }
@ -1283,8 +1283,8 @@ end
if (SOUNDS["YMZ770"]~=null) then if (SOUNDS["YMZ770"]~=null) then
files { files {
MAME_DIR .. "src/devices/sound/ymz770.cpp", MAME_DIR .. "src/devices/sound/ymz770.cpp",
MAME_DIR .. "src/devices/sound/ymz770.h", MAME_DIR .. "src/devices/sound/ymz770.h",
MAME_DIR .. "src/devices/sound/mpeg_audio.cpp", MAME_DIR .. "src/devices/sound/mpeg_audio.cpp",
MAME_DIR .. "src/devices/sound/mpeg_audio.h", MAME_DIR .. "src/devices/sound/mpeg_audio.h",
} }

View File

@ -25,7 +25,7 @@ project "gtest"
configuration { "vs*" } configuration { "vs*" }
if _OPTIONS["vs"]=="intel-15" then if _OPTIONS["vs"]=="intel-15" then
buildoptions { buildoptions {
"/Qwd1195", -- error #1195: conversion from integer to smaller pointer "/Qwd1195", -- error #1195: conversion from integer to smaller pointer
} }
end end
@ -42,13 +42,13 @@ end
project("mametests") project("mametests")
uuid ("66d4c639-196b-4065-a411-7ee9266564f5") uuid ("66d4c639-196b-4065-a411-7ee9266564f5")
kind "ConsoleApp" kind "ConsoleApp"
flags { flags {
"Symbols", -- always include minimum symbols for executables "Symbols", -- always include minimum symbols for executables
} }
if _OPTIONS["SEPARATE_BIN"]~="1" then if _OPTIONS["SEPARATE_BIN"]~="1" then
targetdir(MAME_DIR) targetdir(MAME_DIR)
end end

View File

@ -529,27 +529,27 @@ uuid ("7c5396d1-2a1a-4c93-bed6-6b8fa182054a")
kind "ConsoleApp" kind "ConsoleApp"
flags { flags {
"Symbols", -- always include minimum symbols for executables "Symbols", -- always include minimum symbols for executables
} }
if _OPTIONS["SEPARATE_BIN"]~="1" then if _OPTIONS["SEPARATE_BIN"]~="1" then
targetdir(MAME_DIR) targetdir(MAME_DIR)
end end
links { links {
"utils", "utils",
"ocore_" .. _OPTIONS["osd"], "ocore_" .. _OPTIONS["osd"],
"netlist", "netlist",
} }
includedirs { includedirs {
MAME_DIR .. "src/osd", MAME_DIR .. "src/osd",
MAME_DIR .. "src/lib/util", MAME_DIR .. "src/lib/util",
MAME_DIR .. "src/lib/netlist", MAME_DIR .. "src/lib/netlist",
} }
files { files {
MAME_DIR .. "src/lib/netlist/prg/nlwav.cpp", MAME_DIR .. "src/lib/netlist/prg/nlwav.cpp",
MAME_DIR .. "src/emu/emucore.cpp", MAME_DIR .. "src/emu/emucore.cpp",
} }

View File

@ -513,9 +513,9 @@ if (VIDEOS["MOS6566"]~=null) then
end end
files { files {
MAME_DIR .. "src/devices/video/cgapal.cpp", MAME_DIR .. "src/devices/video/cgapal.cpp",
MAME_DIR .. "src/devices/video/cgapal.h", MAME_DIR .. "src/devices/video/cgapal.h",
} }
-------------------------------------------------- --------------------------------------------------

View File

@ -56,7 +56,7 @@ function createProjects_ldplayer_ldplayer(_target, _subtarget)
targetsubdir(_target .."_" .. _subtarget) targetsubdir(_target .."_" .. _subtarget)
kind (LIBTYPE) kind (LIBTYPE)
uuid (os.uuid("drvldplayer")) uuid (os.uuid("drvldplayer"))
includedirs { includedirs {
MAME_DIR .. "src/osd", MAME_DIR .. "src/osd",
MAME_DIR .. "src/emu", MAME_DIR .. "src/emu",
@ -78,7 +78,7 @@ function createProjects_ldplayer_ldplayer(_target, _subtarget)
custombuildtask { custombuildtask {
layoutbuildtask("ldplayer/layout", "pr8210"), layoutbuildtask("ldplayer/layout", "pr8210"),
} }
end end
function linkProjects_ldplayer_ldplayer(_target, _subtarget) function linkProjects_ldplayer_ldplayer(_target, _subtarget)

View File

@ -3238,7 +3238,7 @@ files {
MAME_DIR .. "src/mame/machine/n64.cpp", MAME_DIR .. "src/mame/machine/n64.cpp",
MAME_DIR .. "src/mame/video/n64.cpp", MAME_DIR .. "src/mame/video/n64.cpp",
MAME_DIR .. "src/mame/video/n64types.h", MAME_DIR .. "src/mame/video/n64types.h",
MAME_DIR .. "src/mame/video/rdpfiltr.inc", MAME_DIR .. "src/mame/video/rdpfiltr.inc",
MAME_DIR .. "src/mame/video/n64.h", MAME_DIR .. "src/mame/video/n64.h",
MAME_DIR .. "src/mame/video/rdpblend.cpp", MAME_DIR .. "src/mame/video/rdpblend.cpp",
MAME_DIR .. "src/mame/video/rdpblend.h", MAME_DIR .. "src/mame/video/rdpblend.h",

View File

@ -19,7 +19,7 @@ function createProjects_mame_dummy(_target, _subtarget)
uuid (os.uuid("drv-mame_dummy")) uuid (os.uuid("drv-mame_dummy"))
addprojectflags() addprojectflags()
precompiledheaders() precompiledheaders()
includedirs { includedirs {
MAME_DIR .. "src/osd", MAME_DIR .. "src/osd",
MAME_DIR .. "src/emu", MAME_DIR .. "src/emu",

View File

@ -14,7 +14,7 @@ dofile("mess.lua")
function createProjects_mame_mame(_target, _subtarget) function createProjects_mame_mame(_target, _subtarget)
createProjects_mame_arcade(_target, _subtarget) createProjects_mame_arcade(_target, _subtarget)
createProjects_mame_mess(_target, _subtarget) createProjects_mame_mess(_target, _subtarget)
end end
function linkProjects_mame_mame(_target, _subtarget) function linkProjects_mame_mame(_target, _subtarget)

View File

@ -2880,7 +2880,7 @@ files {
createMESSProjects(_target, _subtarget, "usp") createMESSProjects(_target, _subtarget, "usp")
files { files {
MAME_DIR .. "src/mame/drivers/patinho_feio.cpp", MAME_DIR .. "src/mame/drivers/patinho_feio.cpp",
} }
createMESSProjects(_target, _subtarget, "veb") createMESSProjects(_target, _subtarget, "veb")
@ -3110,8 +3110,8 @@ files {
MAME_DIR .. "src/mame/drivers/lft.cpp", MAME_DIR .. "src/mame/drivers/lft.cpp",
MAME_DIR .. "src/mame/drivers/lg-dvd.cpp", MAME_DIR .. "src/mame/drivers/lg-dvd.cpp",
MAME_DIR .. "src/mame/drivers/lola8a.cpp", MAME_DIR .. "src/mame/drivers/lola8a.cpp",
MAME_DIR .. "src/mame/drivers/m79152pc.cpp", MAME_DIR .. "src/mame/drivers/m79152pc.cpp",
MAME_DIR .. "src/mame/drivers/marywu.cpp", MAME_DIR .. "src/mame/drivers/marywu.cpp",
MAME_DIR .. "src/mame/drivers/mccpm.cpp", MAME_DIR .. "src/mame/drivers/mccpm.cpp",
MAME_DIR .. "src/mame/drivers/mes.cpp", MAME_DIR .. "src/mame/drivers/mes.cpp",
MAME_DIR .. "src/mame/drivers/mice.cpp", MAME_DIR .. "src/mame/drivers/mice.cpp",

View File

@ -84,7 +84,7 @@ function createProjects_mame_nl(_target, _subtarget)
targetsubdir(_target .."_" .. _subtarget) targetsubdir(_target .."_" .. _subtarget)
kind (LIBTYPE) kind (LIBTYPE)
uuid (os.uuid("drv-mame-nl")) uuid (os.uuid("drv-mame-nl"))
includedirs { includedirs {
MAME_DIR .. "src/osd", MAME_DIR .. "src/osd",
MAME_DIR .. "src/emu", MAME_DIR .. "src/emu",

View File

@ -82,7 +82,7 @@ function createProjects_mame_tiny(_target, _subtarget)
uuid (os.uuid("drv-mame-tiny")) uuid (os.uuid("drv-mame-tiny"))
addprojectflags() addprojectflags()
precompiledheaders() precompiledheaders()
includedirs { includedirs {
MAME_DIR .. "src/osd", MAME_DIR .. "src/osd",
MAME_DIR .. "src/emu", MAME_DIR .. "src/emu",

View File

@ -35,8 +35,8 @@ newoption {
{ "osx-clang", "OSX (Clang compiler)" }, { "osx-clang", "OSX (Clang compiler)" },
{ "pnacl", "Native Client - PNaCl" }, { "pnacl", "Native Client - PNaCl" },
{ "rpi", "RaspberryPi" }, { "rpi", "RaspberryPi" },
{ "solaris", "Solaris" }, { "solaris", "Solaris" },
{ "steamlink", "Steam Link" }, { "steamlink", "Steam Link" },
{ "ci20", "Creator-Ci20" }, { "ci20", "Creator-Ci20" },
}, },
} }
@ -46,12 +46,12 @@ newoption {
value = "toolset", value = "toolset",
description = "Choose VS toolset", description = "Choose VS toolset",
allowed = { allowed = {
{ "intel-14", "Intel C++ Compiler XE 14.0" }, { "intel-14", "Intel C++ Compiler XE 14.0" },
{ "intel-15", "Intel C++ Compiler XE 15.0" }, { "intel-15", "Intel C++ Compiler XE 15.0" },
{ "vs2013-clang", "Clang 3.6" }, { "vs2013-clang", "Clang 3.6" },
{ "vs2015-clang", "Clang 3.6" }, { "vs2015-clang", "Clang 3.6" },
{ "vs2013-xp", "Visual Studio 2013 targeting XP" }, { "vs2013-xp", "Visual Studio 2013 targeting XP" },
{ "vs2015-xp", "Visual Studio 2015 targeting XP" }, { "vs2015-xp", "Visual Studio 2015 targeting XP" },
{ "winphone8", "Windows Phone 8.0" }, { "winphone8", "Windows Phone 8.0" },
{ "winphone81", "Windows Phone 8.1" }, { "winphone81", "Windows Phone 8.1" },
{ "winstore81", "Windows Store 8.1" }, { "winstore81", "Windows Store 8.1" },
@ -100,7 +100,7 @@ function toolchain(_buildDir, _subDir)
if _OPTIONS["with-ios"] then if _OPTIONS["with-ios"] then
iosPlatform = _OPTIONS["with-ios"] iosPlatform = _OPTIONS["with-ios"]
end end
local windowsPlatform = "10.0.10240.0" local windowsPlatform = "10.0.10240.0"
if _OPTIONS["with-windows"] then if _OPTIONS["with-windows"] then
windowsPlatform = _OPTIONS["with-windows"] windowsPlatform = _OPTIONS["with-windows"]
@ -119,7 +119,7 @@ function toolchain(_buildDir, _subDir)
print("Set ANDROID_NDK_ARM and ANDROID_NDK_ROOT envrionment variables.") print("Set ANDROID_NDK_ARM and ANDROID_NDK_ROOT envrionment variables.")
end end
premake.gcc.cc = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe" premake.gcc.cc = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe"
premake.gcc.cxx = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang++.exe" premake.gcc.cxx = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang++.exe"
premake.gcc.ar = "$(ANDROID_NDK_ARM)/bin/arm-linux-androideabi-ar" premake.gcc.ar = "$(ANDROID_NDK_ARM)/bin/arm-linux-androideabi-ar"
premake.gcc.llvm = true premake.gcc.llvm = true
@ -132,59 +132,59 @@ function toolchain(_buildDir, _subDir)
print("Set ANDROID_NDK_ARM64 and ANDROID_NDK_ROOT envrionment variables.") print("Set ANDROID_NDK_ARM64 and ANDROID_NDK_ROOT envrionment variables.")
end end
premake.gcc.cc = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe" premake.gcc.cc = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe"
premake.gcc.cxx = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang++.exe" premake.gcc.cxx = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang++.exe"
premake.gcc.ar = "$(ANDROID_NDK_ARM64)/bin/aarch64-linux-android-ar.exe" premake.gcc.ar = "$(ANDROID_NDK_ARM64)/bin/aarch64-linux-android-ar.exe"
premake.gcc.llvm = true premake.gcc.llvm = true
location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-android-arm64") location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-android-arm64")
end end
if "android-mips" == _OPTIONS["gcc"] then if "android-mips" == _OPTIONS["gcc"] then
if not os.getenv("ANDROID_NDK_MIPS") or not os.getenv("ANDROID_NDK_ROOT") then if not os.getenv("ANDROID_NDK_MIPS") or not os.getenv("ANDROID_NDK_ROOT") then
print("Set ANDROID_NDK_MIPS and ANDROID_NDK_ROOT envrionment variables.") print("Set ANDROID_NDK_MIPS and ANDROID_NDK_ROOT envrionment variables.")
end end
premake.gcc.cc = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe" premake.gcc.cc = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe"
premake.gcc.cxx = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang++.exe" premake.gcc.cxx = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang++.exe"
premake.gcc.ar = "$(ANDROID_NDK_MIPS)/bin/mipsel-linux-android-ar" premake.gcc.ar = "$(ANDROID_NDK_MIPS)/bin/mipsel-linux-android-ar"
premake.gcc.llvm = true premake.gcc.llvm = true
location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-android-mips") location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-android-mips")
end end
if "android-mips64" == _OPTIONS["gcc"] then if "android-mips64" == _OPTIONS["gcc"] then
if not os.getenv("ANDROID_NDK_MIPS64") or not os.getenv("ANDROID_NDK_ROOT") then if not os.getenv("ANDROID_NDK_MIPS64") or not os.getenv("ANDROID_NDK_ROOT") then
print("Set ANDROID_NDK_MIPS64 and ANDROID_NDK_ROOT envrionment variables.") print("Set ANDROID_NDK_MIPS64 and ANDROID_NDK_ROOT envrionment variables.")
end end
premake.gcc.cc = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe" premake.gcc.cc = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe"
premake.gcc.cxx = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang++.exe" premake.gcc.cxx = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang++.exe"
premake.gcc.ar = "$(ANDROID_NDK_MIPS64)/bin/mips64el-linux-android-ar.exe" premake.gcc.ar = "$(ANDROID_NDK_MIPS64)/bin/mips64el-linux-android-ar.exe"
premake.gcc.llvm = true premake.gcc.llvm = true
location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-android-mips64") location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-android-mips64")
end end
if "android-x86" == _OPTIONS["gcc"] then if "android-x86" == _OPTIONS["gcc"] then
if not os.getenv("ANDROID_NDK_X86") or not os.getenv("ANDROID_NDK_ROOT") then if not os.getenv("ANDROID_NDK_X86") or not os.getenv("ANDROID_NDK_ROOT") then
print("Set ANDROID_NDK_X86 and ANDROID_NDK_ROOT envrionment variables.") print("Set ANDROID_NDK_X86 and ANDROID_NDK_ROOT envrionment variables.")
end end
premake.gcc.cc = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe" premake.gcc.cc = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe"
premake.gcc.cxx = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang++.exe" premake.gcc.cxx = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang++.exe"
premake.gcc.ar = "$(ANDROID_NDK_X86)/bin/i686-linux-android-ar" premake.gcc.ar = "$(ANDROID_NDK_X86)/bin/i686-linux-android-ar"
premake.gcc.llvm = true premake.gcc.llvm = true
location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-android-x86") location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-android-x86")
end end
if "android-x64" == _OPTIONS["gcc"] then if "android-x64" == _OPTIONS["gcc"] then
if not os.getenv("ANDROID_NDK_X64") or not os.getenv("ANDROID_NDK_ROOT") then if not os.getenv("ANDROID_NDK_X64") or not os.getenv("ANDROID_NDK_ROOT") then
print("Set ANDROID_NDK_X64 and ANDROID_NDK_ROOT envrionment variables.") print("Set ANDROID_NDK_X64 and ANDROID_NDK_ROOT envrionment variables.")
end end
premake.gcc.cc = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe" premake.gcc.cc = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe"
premake.gcc.cxx = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang++.exe" premake.gcc.cxx = "$(ANDROID_NDK_ROOT)/toolchains/llvm/prebuilt/windows-x86_64/bin/clang++.exe"
premake.gcc.ar = "$(ANDROID_NDK_X64)/bin/x86_64-linux-android-ar.exe" premake.gcc.ar = "$(ANDROID_NDK_X64)/bin/x86_64-linux-android-ar.exe"
premake.gcc.llvm = true premake.gcc.llvm = true
@ -396,15 +396,15 @@ function toolchain(_buildDir, _subDir)
if "winstore82" == _OPTIONS["vs"] then if "winstore82" == _OPTIONS["vs"] then
premake.vstudio.toolset = "v140" premake.vstudio.toolset = "v140"
premake.vstudio.storeapp = "8.2" premake.vstudio.storeapp = "8.2"
-- If needed, depending on GENie version, enable file-level configuration -- If needed, depending on GENie version, enable file-level configuration
if enablefilelevelconfig ~= nil then if enablefilelevelconfig ~= nil then
enablefilelevelconfig() enablefilelevelconfig()
end end
local action = premake.action.current() local action = premake.action.current()
action.vstudio.windowsTargetPlatformVersion = windowsPlatform action.vstudio.windowsTargetPlatformVersion = windowsPlatform
platforms { "ARM" } platforms { "ARM" }
location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-winstore82") location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-winstore82")
end end
@ -423,7 +423,7 @@ function toolchain(_buildDir, _subDir)
premake.vstudio.toolset = ("v120_xp") premake.vstudio.toolset = ("v120_xp")
location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-xp") location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-xp")
end end
if ("vs2015-xp") == _OPTIONS["vs"] then if ("vs2015-xp") == _OPTIONS["vs"] then
premake.vstudio.toolset = ("v140_xp") premake.vstudio.toolset = ("v140_xp")
location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-xp") location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-xp")
@ -568,7 +568,7 @@ function toolchain(_buildDir, _subDir)
} }
defines { defines {
"__VCCOREVER__=0x04000000", -- There is no special prefedined compiler symbol to detect RaspberryPi, faking it. "__VCCOREVER__=0x04000000", -- There is no special prefedined compiler symbol to detect RaspberryPi, faking it.
} }
linkoptions { linkoptions {
"-Wl,--gc-sections", "-Wl,--gc-sections",
} }
@ -594,10 +594,10 @@ function toolchain(_buildDir, _subDir)
"$(CI20_SYSROOT)/mipsel-r2-hard/usr/include/mipsel-linux-gnu/c++/4.9", "$(CI20_SYSROOT)/mipsel-r2-hard/usr/include/mipsel-linux-gnu/c++/4.9",
"$(CI20_SYSROOT)/mipsel-r2-hard/usr/include/c++/4.9/backward", "$(CI20_SYSROOT)/mipsel-r2-hard/usr/include/c++/4.9/backward",
"$(CI20_SYSROOT)/mipsel-r2-hard/usr/lib/gcc/mipsel-linux-gnu/4.9/include", "$(CI20_SYSROOT)/mipsel-r2-hard/usr/lib/gcc/mipsel-linux-gnu/4.9/include",
"$(CI20_SYSROOT)/mipsel-r2-hard/usr/local/include", "$(CI20_SYSROOT)/mipsel-r2-hard/usr/local/include",
"$(CI20_SYSROOT)/mipsel-r2-hard/usr/lib/gcc/mipsel-linux-gnu/4.9/include-fixed", "$(CI20_SYSROOT)/mipsel-r2-hard/usr/lib/gcc/mipsel-linux-gnu/4.9/include-fixed",
"$(CI20_SYSROOT)/mipsel-r2-hard/usr/include/mipsel-linux-gnu", "$(CI20_SYSROOT)/mipsel-r2-hard/usr/include/mipsel-linux-gnu",
"$(CI20_SYSROOT)/mipsel-r2-hard/usr/include", "$(CI20_SYSROOT)/mipsel-r2-hard/usr/include",
} }
links { links {
"c", "c",
@ -607,7 +607,7 @@ function toolchain(_buildDir, _subDir)
"stdc++", "stdc++",
"gcc_s", "gcc_s",
} }
buildoptions { buildoptions {
"--sysroot=$(CI20_SYSROOT)", "--sysroot=$(CI20_SYSROOT)",
"-Wno-pragmas", "-Wno-pragmas",
@ -879,7 +879,7 @@ function toolchain(_buildDir, _subDir)
"$(ANDROID_NDK_ROOT)/platforms/" .. androidPlatform .. "/arch-arm64/usr/lib/crtend_so.o", "$(ANDROID_NDK_ROOT)/platforms/" .. androidPlatform .. "/arch-arm64/usr/lib/crtend_so.o",
"-target aarch64-none-linux-android", "-target aarch64-none-linux-android",
} }
configuration { "android-mips" } configuration { "android-mips" }
targetdir (_buildDir .. "android-mips" .. "/bin") targetdir (_buildDir .. "android-mips" .. "/bin")
objdir (_buildDir .. "android-mips" .. "/obj") objdir (_buildDir .. "android-mips" .. "/obj")
@ -901,7 +901,7 @@ function toolchain(_buildDir, _subDir)
"$(ANDROID_NDK_ROOT)/platforms/" .. androidPlatform .. "/arch-mips/usr/lib/crtbegin_so.o", "$(ANDROID_NDK_ROOT)/platforms/" .. androidPlatform .. "/arch-mips/usr/lib/crtbegin_so.o",
"$(ANDROID_NDK_ROOT)/platforms/" .. androidPlatform .. "/arch-mips/usr/lib/crtend_so.o", "$(ANDROID_NDK_ROOT)/platforms/" .. androidPlatform .. "/arch-mips/usr/lib/crtend_so.o",
} }
configuration { "android-mips64" } configuration { "android-mips64" }
androidPlatform = "android-21" -- supported from API 21 androidPlatform = "android-21" -- supported from API 21
targetdir (_buildDir .. "android-mips64" .. "/bin") targetdir (_buildDir .. "android-mips64" .. "/bin")
@ -971,7 +971,7 @@ function toolchain(_buildDir, _subDir)
"$(ANDROID_NDK_ROOT)/platforms/" .. androidPlatform .. "/arch-x86_64/usr/lib64/crtbegin_so.o", "$(ANDROID_NDK_ROOT)/platforms/" .. androidPlatform .. "/arch-x86_64/usr/lib64/crtbegin_so.o",
"$(ANDROID_NDK_ROOT)/platforms/" .. androidPlatform .. "/arch-x86_64/usr/lib64/crtend_so.o", "$(ANDROID_NDK_ROOT)/platforms/" .. androidPlatform .. "/arch-x86_64/usr/lib64/crtend_so.o",
} }
configuration { "asmjs" } configuration { "asmjs" }
targetdir (_buildDir .. "asmjs" .. "/bin") targetdir (_buildDir .. "asmjs" .. "/bin")
objdir (_buildDir .. "asmjs" .. "/obj") objdir (_buildDir .. "asmjs" .. "/obj")
@ -1002,7 +1002,7 @@ function toolchain(_buildDir, _subDir)
"-ffunction-sections", "-ffunction-sections",
"-Wunused-value", "-Wunused-value",
} }
configuration { "pnacl" } configuration { "pnacl" }
buildoptions { buildoptions {
"-Wno-tautological-undefined-compare", "-Wno-tautological-undefined-compare",