diff --git a/scripts/genie.lua b/scripts/genie.lua index 1c2a7a020f8..170e7e8e8ed 100644 --- a/scripts/genie.lua +++ b/scripts/genie.lua @@ -726,23 +726,25 @@ configuration { "linux-*" } configuration { "osx*" } links { + "SDL2.framework", "Cocoa.framework", "OpenGL.framework", "CoreAudio.framework", "CoreMIDI.framework", - "SDL2.framework", "pthread", } + buildoptions { + "-F/Library/Frameworks/", + } + linkoptions { + "-F/Library/Frameworks/", + } configuration { "mingw*" } - defines { - "main=utf8_main", - } linkoptions { "-static-libgcc", "-static-libstdc++", - "-municode", } if _OPTIONS["osd"]=="sdl" then links { @@ -769,9 +771,6 @@ end } configuration { "vs*" } - defines { - "main=utf8_main", - } defines { "XML_STATIC", "WIN32", diff --git a/scripts/src/osd/sdl.lua b/scripts/src/osd/sdl.lua index 1dfd43a13d6..1942f70bc73 100644 --- a/scripts/src/osd/sdl.lua +++ b/scripts/src/osd/sdl.lua @@ -1,25 +1,28 @@ function maintargetosdoptions(_target) - if (USE_QT == 1) then - if _OPTIONS["targetos"]=="windows" then + if _OPTIONS["targetos"]=="windows" then + linkoptions{ + "-municode", + } + if (USE_QT == 1) then linkoptions{ "-L$(shell qmake -query QT_INSTALL_LIBS)", } - links { "qtmain", "QtGui4", "QtCore4", } end - - if _OPTIONS["targetos"]=="linux" then + end + if _OPTIONS["targetos"]=="linux" then + if (USE_QT == 1) then links { - 'QtGui', - 'QtCore', + "QtGui", + "QtCore", } linkoptions { - '$(shell pkg-config --libs QtGui)', + "$(shell pkg-config --libs QtGui)", } end end @@ -30,6 +33,7 @@ function maintargetosdoptions(_target) configuration { } end + configuration { "mingw*" } linkoptions { "-Wl,--allow-multiple-definition", diff --git a/scripts/src/osd/sdl_cfg.lua b/scripts/src/osd/sdl_cfg.lua index 3b2702ff6d8..a405ee2131e 100644 --- a/scripts/src/osd/sdl_cfg.lua +++ b/scripts/src/osd/sdl_cfg.lua @@ -13,6 +13,7 @@ if _OPTIONS["targetos"]=="windows" then "USE_OPENGL=1", "USE_QTDEBUG=" .. USE_QT, "SDLMAME_NET_PCAP", + "main=utf8_main", } buildoptions { diff --git a/scripts/src/osd/windows.lua b/scripts/src/osd/windows.lua index 6cdc4009b11..26b9b34826f 100644 --- a/scripts/src/osd/windows.lua +++ b/scripts/src/osd/windows.lua @@ -1,4 +1,8 @@ function maintargetosdoptions(_target) + linkoptions { + "-municode", + } + local rcfile = MAME_DIR .. "src/" .. _target .. "/osd/windows/" .. _target ..".rc" if os.isfile(rcfile) then diff --git a/scripts/src/osd/windows_cfg.lua b/scripts/src/osd/windows_cfg.lua index 90944ecbb4f..50775976b01 100644 --- a/scripts/src/osd/windows_cfg.lua +++ b/scripts/src/osd/windows_cfg.lua @@ -12,4 +12,5 @@ defines { "USE_DISPATCH_GL=1", "DIRECTINPUT_VERSION=0x0800", "SDLMAME_NET_PCAP", + "main=utf8_main", }