mirror of
https://github.com/holub/mame
synced 2025-07-08 11:21:56 +03:00
Restore NO_OPENGL and USE_DISPATCH_GL
This commit is contained in:
parent
9a2c6d95c8
commit
dbc99041c3
8
makefile
8
makefile
@ -328,6 +328,14 @@ endif
|
||||
endif
|
||||
PARAMS += --USE_QT=$(USE_QT)
|
||||
|
||||
ifdef NO_OPENGL
|
||||
PARAMS += --NO_OPENGL='$(NO_OPENGL)'
|
||||
endif
|
||||
|
||||
ifdef USE_DISPATCH_GL
|
||||
PARAMS += --USE_DISPATCH_GL='$(USE_DISPATCH_GL)'
|
||||
endif
|
||||
|
||||
ifdef NO_X11
|
||||
PARAMS += --NO_X11='$(NO_X11)'
|
||||
endif
|
||||
|
@ -697,7 +697,6 @@ configuration { "nacl*" }
|
||||
configuration { "linux-*" }
|
||||
links {
|
||||
"dl",
|
||||
"GL",
|
||||
}
|
||||
defines
|
||||
{
|
||||
@ -727,7 +726,6 @@ configuration { "mingw*" }
|
||||
}
|
||||
if _OPTIONS["osd"]=="sdl" then
|
||||
links {
|
||||
"opengl32",
|
||||
"SDL2",
|
||||
"imm32",
|
||||
"version",
|
||||
|
@ -23,12 +23,22 @@ function maintargetosdoptions(_target)
|
||||
"SDL_ttf",
|
||||
}
|
||||
end
|
||||
if _OPTIONS["NO_OPENGL"]~="1" and _OPTIONS["USE_DISPATCH_GL"]~="1" then
|
||||
links {
|
||||
"GL"
|
||||
}
|
||||
end
|
||||
linkoptions {
|
||||
string.gsub(os.outputof("pkg-config --libs fontconfig"), '[\r\n]+', ' '),
|
||||
}
|
||||
end
|
||||
|
||||
if _OPTIONS["targetos"]=="windows" then
|
||||
if _OPTIONS["NO_OPENGL"]~="1" and _OPTIONS["USE_DISPATCH_GL"]~="1" then
|
||||
links {
|
||||
"opengl32"
|
||||
}
|
||||
end
|
||||
configuration { "mingw*" }
|
||||
linkoptions{
|
||||
"-municode",
|
||||
@ -44,7 +54,6 @@ function maintargetosdoptions(_target)
|
||||
configuration { "vs*" }
|
||||
links {
|
||||
"SDL2",
|
||||
"opengl32",
|
||||
}
|
||||
configuration {}
|
||||
|
||||
@ -103,6 +112,40 @@ function sdlconfigcmd()
|
||||
end
|
||||
|
||||
|
||||
newoption {
|
||||
trigger = "NO_OPENGL",
|
||||
description = "Disable use of OpenGL",
|
||||
allowed = {
|
||||
{ "0", "Enable OpenGL" },
|
||||
{ "1", "Disable OpenGL" },
|
||||
},
|
||||
}
|
||||
|
||||
if not _OPTIONS["NO_OPENGL"] then
|
||||
if _OPTIONS["targetos"]=="os2" then
|
||||
_OPTIONS["NO_OPENGL"] = "1"
|
||||
else
|
||||
_OPTIONS["NO_OPENGL"] = "0"
|
||||
end
|
||||
end
|
||||
|
||||
newoption {
|
||||
trigger = "USE_DISPATCH_GL",
|
||||
description = "Use GL-dispatching",
|
||||
allowed = {
|
||||
{ "0", "Link to OpenGL library" },
|
||||
{ "1", "Use GL-dispatching" },
|
||||
},
|
||||
}
|
||||
|
||||
if not _OPTIONS["USE_DISPATCH_GL"] then
|
||||
if USE_BGFX == 1 then
|
||||
_OPTIONS["USE_DISPATCH_GL"] = "0"
|
||||
else
|
||||
_OPTIONS["USE_DISPATCH_GL"] = "1"
|
||||
end
|
||||
end
|
||||
|
||||
newoption {
|
||||
trigger = "NO_X11",
|
||||
description = "Disable use of X11",
|
||||
@ -365,13 +408,10 @@ project ("osd_" .. _OPTIONS["osd"])
|
||||
MAME_DIR .. "src/osd/sdl/watchdog.c",
|
||||
MAME_DIR .. "src/osd/modules/lib/osdobj_common.c",
|
||||
MAME_DIR .. "src/osd/modules/render/drawsdl.c",
|
||||
MAME_DIR .. "src/osd/modules/render/drawogl.c",
|
||||
MAME_DIR .. "src/osd/modules/debugger/none.c",
|
||||
MAME_DIR .. "src/osd/modules/debugger/debugint.c",
|
||||
MAME_DIR .. "src/osd/modules/debugger/debugwin.c",
|
||||
MAME_DIR .. "src/osd/modules/debugger/debugqt.c",
|
||||
MAME_DIR .. "src/osd/modules/opengl/gl_shader_tool.c",
|
||||
MAME_DIR .. "src/osd/modules/opengl/gl_shader_mgr.c",
|
||||
MAME_DIR .. "src/osd/modules/font/font_sdl.c",
|
||||
MAME_DIR .. "src/osd/modules/font/font_windows.c",
|
||||
MAME_DIR .. "src/osd/modules/font/font_osx.c",
|
||||
@ -386,6 +426,13 @@ project ("osd_" .. _OPTIONS["osd"])
|
||||
MAME_DIR .. "src/osd/modules/sound/sdl_sound.c",
|
||||
MAME_DIR .. "src/osd/modules/sound/none.c",
|
||||
}
|
||||
if _OPTIONS["NO_OPENGL"]~="1" then
|
||||
files {
|
||||
MAME_DIR .. "src/osd/modules/render/drawogl.c",
|
||||
MAME_DIR .. "src/osd/modules/opengl/gl_shader_tool.c",
|
||||
MAME_DIR .. "src/osd/modules/opengl/gl_shader_mgr.c",
|
||||
}
|
||||
end
|
||||
if _OPTIONS["SDL_LIBVER"]=="sdl2" then
|
||||
files {
|
||||
MAME_DIR .. "src/osd/modules/render/draw13.c",
|
||||
|
@ -2,6 +2,22 @@ forcedincludes {
|
||||
MAME_DIR .. "src/osd/sdl/sdlprefix.h"
|
||||
}
|
||||
|
||||
if _OPTIONS["NO_OPENGL"]=="1" then
|
||||
defines {
|
||||
"USE_OPENGL=0",
|
||||
}
|
||||
else
|
||||
defines {
|
||||
"USE_OPENGL=1",
|
||||
}
|
||||
if _OPTIONS["USE_DISPATCH_GL"]=="1" then
|
||||
defines {
|
||||
"USE_DISPATCH_GL=1",
|
||||
}
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
if _OPTIONS["NO_X11"]=="1" then
|
||||
defines {
|
||||
"SDLMAME_NO_X11",
|
||||
@ -94,7 +110,6 @@ if _OPTIONS["targetos"]=="windows" then
|
||||
"SDLMAME_WIN32",
|
||||
"UNICODE",
|
||||
"_UNICODE",
|
||||
"USE_OPENGL=1",
|
||||
"USE_QTDEBUG=" .. USE_QT,
|
||||
"SDLMAME_NET_PCAP",
|
||||
"main=utf8_main",
|
||||
@ -114,7 +129,6 @@ if _OPTIONS["targetos"]=="windows" then
|
||||
|
||||
elseif _OPTIONS["targetos"]=="linux" then
|
||||
defines {
|
||||
"USE_OPENGL=1",
|
||||
"USE_QTDEBUG=" .. USE_QT,
|
||||
"SDLMAME_NET_TAPTUN",
|
||||
}
|
||||
@ -125,7 +139,6 @@ elseif _OPTIONS["targetos"]=="macosx" then
|
||||
defines {
|
||||
"SDLMAME_MACOSX",
|
||||
"SDLMAME_DARWIN",
|
||||
"USE_OPENGL=1",
|
||||
"USE_QTDEBUG=0",
|
||||
"SDLMAME_NET_PCAP",
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user