summaryrefslogtreecommitdiffstatshomepage
path: root/src
diff options
context:
space:
mode:
author Miodrag Milanovic <mmicko@gmail.com>2017-03-26 09:57:31 +0200
committer Miodrag Milanovic <mmicko@gmail.com>2017-03-26 09:57:31 +0200
commitcc07ecc00e58d349c76ed185b15205de756a49cf (patch)
tree90d838cc9aee1e66b4677fd51d884834a18a90ad /src
parent6cb38b0771d189f412a7efae1e2d095b3cfa9c76 (diff)
Fixed SDL build on win32 and zexall build (nw)
Diffstat (limited to 'src')
-rw-r--r--src/osd/sdl/sdlmain.cpp10
-rw-r--r--src/zexall/main.cpp8
2 files changed, 15 insertions, 3 deletions
diff --git a/src/osd/sdl/sdlmain.cpp b/src/osd/sdl/sdlmain.cpp
index f8bcb231796..80985c4b0c9 100644
--- a/src/osd/sdl/sdlmain.cpp
+++ b/src/osd/sdl/sdlmain.cpp
@@ -181,8 +181,14 @@ extern "C" DECLSPEC void SDLCALL SDL_SetModuleHandle(void *hInst);
#endif
// translated to utf8_main
-int main(int argc, char *argv[])
+#if defined(SDLMAME_WIN32)
+int main(std::vector<std::string> &args)
+{
+#else
+int main(int argc, char** argv)
{
+ std::vector<std::string> args(argv, argv+argc);
+#endif
int res = 0;
// disable I/O buffering
@@ -210,7 +216,7 @@ int main(int argc, char *argv[])
sdl_options options;
sdl_osd_interface osd(options);
osd.register_options();
- res = emulator_info::start_frontend(options, osd, argc, argv);
+ res = emulator_info::start_frontend(options, osd, args);
}
#ifdef SDLMAME_UNIX
diff --git a/src/zexall/main.cpp b/src/zexall/main.cpp
index b4e87ddf299..6c418b77454 100644
--- a/src/zexall/main.cpp
+++ b/src/zexall/main.cpp
@@ -76,7 +76,7 @@ private:
zexall_machine_manager* zexall_machine_manager::m_manager = nullptr;
-int emulator_info::start_frontend(emu_options &options, osd_interface &osd, int argc, char *argv[])
+int emulator_info::start_frontend(emu_options &options, osd_interface &osd, std::vector<std::string> &args)
{
std::string error_string;
options.set_value(OSDOPTION_VIDEO, "none", OPTION_PRIORITY_MAXIMUM, error_string);
@@ -87,6 +87,12 @@ int emulator_info::start_frontend(emu_options &options, osd_interface &osd, int
return 0;
}
+int emulator_info::start_frontend(emu_options &options, osd_interface &osd, int argc, char *argv[])
+{
+ std::vector<std::string> args(argv, argv + argc);
+ return start_frontend(options, osd, args);
+}
+
const char * emulator_info::get_bare_build_version() { return nullptr; }
const char * emulator_info::get_build_version() { return nullptr; }