1 sdl: Fix compilation with libX11 >= 1.5.99.902
2 Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
5 # User Azamat H. Hackimov <azamat.hackimov@gmail.com>
6 # Date 1370184533 -21600
7 # Node ID 91ad7b43317a6387e115ecdf63a49137f47e42c8
8 # Parent f7fd5c3951b9ed922fdf696f7182e71b58a13268
9 Fix compilation with libX11 >= 1.5.99.902.
11 These changes fixes bug #1769 for SDL 1.2
12 (http://bugzilla.libsdl.org/show_bug.cgi?id=1769).
14 diff -r f7fd5c3951b9 -r 91ad7b43317a configure.in
15 --- a/configure.in Wed Apr 17 00:56:53 2013 -0700
16 +++ b/configure.in Sun Jun 02 20:48:53 2013 +0600
17 @@ -1169,6 +1169,17 @@
18 if test x$definitely_enable_video_x11_xrandr = xyes; then
19 AC_DEFINE(SDL_VIDEO_DRIVER_X11_XRANDR)
21 + AC_MSG_CHECKING(for const parameter to _XData32)
22 + have_const_param_xdata32=no
24 + #include <X11/Xlibint.h>
25 + extern int _XData32(Display *dpy,register _Xconst long *data,unsigned len);
28 + have_const_param_xdata32=yes
29 + AC_DEFINE(SDL_VIDEO_DRIVER_X11_CONST_PARAM_XDATA32)
31 + AC_MSG_RESULT($have_const_param_xdata32)
35 diff -r f7fd5c3951b9 -r 91ad7b43317a include/SDL_config.h.in
36 --- a/include/SDL_config.h.in Wed Apr 17 00:56:53 2013 -0700
37 +++ b/include/SDL_config.h.in Sun Jun 02 20:48:53 2013 +0600
39 #undef SDL_VIDEO_DRIVER_WINDIB
40 #undef SDL_VIDEO_DRIVER_WSCONS
41 #undef SDL_VIDEO_DRIVER_X11
42 +#undef SDL_VIDEO_DRIVER_X11_CONST_PARAM_XDATA32
43 #undef SDL_VIDEO_DRIVER_X11_DGAMOUSE
44 #undef SDL_VIDEO_DRIVER_X11_DYNAMIC
45 #undef SDL_VIDEO_DRIVER_X11_DYNAMIC_XEXT
46 diff -r f7fd5c3951b9 -r 91ad7b43317a src/video/x11/SDL_x11sym.h
47 --- a/src/video/x11/SDL_x11sym.h Wed Apr 17 00:56:53 2013 -0700
48 +++ b/src/video/x11/SDL_x11sym.h Sun Jun 02 20:48:53 2013 +0600
52 SDL_X11_MODULE(IO_32BIT)
53 +#if SDL_VIDEO_DRIVER_X11_CONST_PARAM_XDATA32
54 +SDL_X11_SYM(int,_XData32,(Display *dpy,register _Xconst long *data,unsigned len),(dpy,data,len),return)
56 SDL_X11_SYM(int,_XData32,(Display *dpy,register long *data,unsigned len),(dpy,data,len),return)
58 SDL_X11_SYM(void,_XRead32,(Display *dpy,register long *data,long len),(dpy,data,len),)