summaryrefslogtreecommitdiffstatshomepage
path: root/scripts/genie.lua
diff options
context:
space:
mode:
author Miodrag Milanovic <mmicko@gmail.com>2016-12-09 13:00:51 +0100
committer Miodrag Milanovic <mmicko@gmail.com>2016-12-09 13:00:51 +0100
commita877c987fb45ed3efac5ff50b426933f5ca59cbb (patch)
tree9d983fabb3cafd377bbff49673367a66d55af981 /scripts/genie.lua
parent33aa3d1a62c267ab86eee267d545ee3410e9c54b (diff)
detect if SOURCES file do not exist (nw)
Diffstat (limited to 'scripts/genie.lua')
-rw-r--r--scripts/genie.lua7
1 files changed, 7 insertions, 0 deletions
diff --git a/scripts/genie.lua b/scripts/genie.lua
index 653c8b69e37..e905e3b6aef 100644
--- a/scripts/genie.lua
+++ b/scripts/genie.lua
@@ -1317,6 +1317,13 @@ configuration { "Debug", "gmake" }
configuration { }
if (_OPTIONS["SOURCES"] ~= nil) then
+ local str = _OPTIONS["SOURCES"]
+ for word in string.gmatch(str, '([^,]+)') do
+ if (not os.isfile(path.join(MAME_DIR ,word))) then
+ print("File " .. word.. " does not exist")
+ os.exit()
+ end
+ end
OUT_STR = os.outputof( PYTHON .. " " .. MAME_DIR .. "scripts/build/makedep.py " .. MAME_DIR .. " " .. _OPTIONS["SOURCES"] .. " target " .. _OPTIONS["subtarget"])
load(OUT_STR)()
os.outputof( PYTHON .. " " .. MAME_DIR .. "scripts/build/makedep.py " .. MAME_DIR .. " " .. _OPTIONS["SOURCES"] .. " drivers " .. _OPTIONS["subtarget"] .. " > ".. GEN_DIR .. _OPTIONS["target"] .. "/" .. _OPTIONS["subtarget"]..".flt")