Remove a few unused HAVE_FOO's and make the SDL check global.

ulong is not a standard type.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5649 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
Soren Jorvang 2010-06-11 08:51:46 +00:00
parent b7c2e523b3
commit e7f7eff2b6
6 changed files with 9 additions and 22 deletions

View file

@ -275,8 +275,7 @@ if sys.platform == 'darwin':
conf.CheckMacports()
conf.CheckFink()
env['HAVE_SDL'] = conf.CheckSDL('1.0.0')
if not env['HAVE_SDL']:
if not conf.CheckSDL('1.0.0'):
print "SDL is required"
Exit(1)
@ -405,16 +404,13 @@ if not sys.platform == 'win32' and not sys.platform == 'darwin':
print "Must have CgGl to build"
Exit(1)
env['HAVE_ZLIB'] = conf.CheckPKG('z')
if not ['HAVE_ZLIB']:
if not conf.CheckPKG('z'):
print "zlib is required"
Exit(1)
# Check for GTK 2.0 or newer
env['HAVE_GTK2'] = 0
if sys.platform == 'linux2':
env['HAVE_GTK2'] = env['HAVE_WX'] and conf.CheckPKG('gtk+-2.0')
if env['HAVE_WX'] and not env['HAVE_GTK2']:
if env['HAVE_WX'] and not conf.CheckPKG('gtk+-2.0'):
print "gtk+-2.0 developement headers not detected"
print "gtk+-2.0 is required to build the WX GUI"
Exit(1)
@ -426,7 +422,6 @@ if env['nojit']:
conf.Define('NOJIT', env['NOJIT'])
# Creating config.h defines
conf.Define('HAVE_SDL', env['HAVE_SDL'])
conf.Define('HAVE_BLUEZ', env['HAVE_BLUEZ'])
conf.Define('HAVE_AO', env['HAVE_AO'])
conf.Define('HAVE_OPENCL', env['HAVE_OPENCL'])

View file

@ -26,7 +26,7 @@
#define CREG_RIP(ctx) (ctx)->gregs[REG_RIP]
#define CREG_EAX(ctx) (ctx)->gregs[REG_EAX]
#define CREG_EIP(ctx) (ctx)->gregs[REG_EIP]
#else
#elif defined(__APPLE__)
#define CREG_RAX(ctx) (*(ctx))->__ss.__rax
#define CREG_RIP(ctx) (*(ctx))->__ss.__rip
#define CREG_EAX(ctx) (*(ctx))->__ss.__eax

View file

@ -8,6 +8,7 @@ files = [
'InputCommon.cpp',
'SDL_Util.cpp',
'ControllerInterface/ControllerInterface.cpp',
'ControllerInterface/SDL/SDL.cpp'
]
if env['HAVE_X11']:
@ -20,11 +21,6 @@ if env['HAVE_WX']:
"WXInputBase.cpp",
]
if env['HAVE_SDL']:
files += [
'ControllerInterface/SDL/SDL.cpp'
]
if sys.platform == 'darwin':
files += [
'ControllerInterface/OSX/OSX.mm',

View file

@ -6,10 +6,6 @@ import sys
name = "Plugin_GCPad"
padenv = env.Clone()
if not env['HAVE_SDL']:
print name + " must have SDL to be build"
Return()
files = [
'Config.cpp',
'GCPad.cpp',

View file

@ -224,9 +224,9 @@ THREAD_RETURN XEventThread(void *pArg)
s_backbuffer_height = GLWin.height;
break;
case ClientMessage:
if ((ulong) event.xclient.data.l[0] == XInternAtom(GLWin.dpy, "WM_DELETE_WINDOW", False))
if ((unsigned long) event.xclient.data.l[0] == XInternAtom(GLWin.dpy, "WM_DELETE_WINDOW", False))
g_VideoInitialize.pCoreMessage(WM_USER_STOP);
if ((ulong) event.xclient.data.l[0] == XInternAtom(GLWin.dpy, "RESIZE", False))
if ((unsigned long) event.xclient.data.l[0] == XInternAtom(GLWin.dpy, "RESIZE", False))
XMoveResizeWindow(GLWin.dpy, GLWin.win, event.xclient.data.l[1],
event.xclient.data.l[2], event.xclient.data.l[3], event.xclient.data.l[4]);
break;

View file

@ -416,9 +416,9 @@ void OpenGL_Update()
s_backbuffer_height = GLWin.height;
break;
case ClientMessage:
if ((ulong) event.xclient.data.l[0] == XInternAtom(GLWin.dpy, "WM_DELETE_WINDOW", False))
if ((unsigned long) event.xclient.data.l[0] == XInternAtom(GLWin.dpy, "WM_DELETE_WINDOW", False))
g_VideoInitialize.pCoreMessage(WM_USER_STOP);
if ((ulong) event.xclient.data.l[0] == XInternAtom(GLWin.dpy, "RESIZE", False))
if ((unsigned long) event.xclient.data.l[0] == XInternAtom(GLWin.dpy, "RESIZE", False))
XMoveResizeWindow(GLWin.dpy, GLWin.win, event.xclient.data.l[1],
event.xclient.data.l[2], event.xclient.data.l[3], event.xclient.data.l[4]);
return;