cmake


Log

Author Commit Date CI Message
Anonymous Maarten 78a37516 2022-06-16T16:38:58 cmake+ci: fix+test sdl2-config + sdl2.pc for all supported platforms
Anonymous Maarten 6dcb2868 2022-06-16T19:53:58 cmake: avoid use of possible non-available XEXT_LIB
Anonymous Maarten b19099d5 2022-06-16T19:59:57 cmake: use find_package(SampleRate) to find samplerate + allow targets
Anonymous Maarten 86f50ae7 2022-06-15T06:10:25 ci: Test cmake build script on Android android
Anonymous Maarten 18206446 2022-06-15T17:10:31 cmake: collect SDL_LIBS as list + export PKG_DIRECTFB_LDFLAGS
Anonymous Maarten 32df5aeb 2022-06-15T03:16:28 Check result of FindLibraryAndSONAME before use
Anonymous Maarten afc350ee 2022-06-15T03:03:33 cmake: do 's#set(SOURCE_FILES #list(APPEND SOURCE_FILES #g'
Anonymous Maarten e99a7144 2022-06-13T18:04:51 Use list(APPEND EXTRA_LIBS) everywhere
Anonymous Maarten 5abd6769 2022-06-07T04:28:55 Allow empty default values to the dep_option macro
Anonymous Maarten 9ff8f29f 2022-06-03T20:07:43 cmake: Add mini-SDL2 CMake project to test SDL2 prefixes
ShuangLiu1992 f4fc4719 2022-05-09T18:35:50 fix CheckCOCOA on modern CMake Modern CMake doesn't need "LANGUAGE C" for Objective-C set_source_files_properties(${COCOA_SOURCES} PROPERTIES LANGUAGE C) should be removed fro video/cocoa/*.m as well otherwise project won't compile see also https://github.com/libsdl-org/SDL/commit/d3cc5764c0f66872a6b87c0ffbca66c85dccbea3
Ryan C. Gordon 7d7ec9c9 2022-04-26T16:41:28 x11: Remove XVidMode and Xinerama support. Fixes #1782.
Ethan Lee 13337e17 2022-03-23T13:27:01 wayland: The rest of the wayland-client 1.18 requirement... Git, please
Joao Paulo Magalhaes 57df1dfc 2022-03-23T15:07:52 Video: do not use hardcoded VIVANTE and VDK libraries
Ozkan Sezer 61a93d3c 2022-03-15T23:10:02 minor whitespace cleanup.
Ryan C. Gordon 3ab739af 2022-03-13T12:10:52 cmake: Make test code use proper C main functions. Fixes #5021.
Nick Cao f03215bc 2022-03-07T15:54:24 fix linking with SDL_PULSEAUDIO_SHARED=OFF and SDL_X11_SHARED=OFF
Luke Street 0cb39ed4 2022-02-07T04:11:14 cmake: Fix SDL_LIBUSB_DYNAMIC soname
Ozkan Sezer 94035436 2022-02-05T18:50:00 cmake: enable_language(OBJC) only for APPLE
Ozkan Sezer 3c9ac448 2022-02-05T18:45:50 cmake: enable_language(OBJC) to fix check_objc_source_compiles().
Ozkan Sezer 686a0f34 2022-02-05T18:28:24 cmake: include CheckOBJCSourceCompiles for cmake >= 3.16 c.f. bugs #5011 and #3912
Max Krummenacher c3a7cc34 2022-01-10T21:52:02 cmake: sdlchecks.cmake: pass cflags to the appropriate cmake variable If egl.pc sets at least two macros as the i.MX Vivante driver does, e.g.: | Cflags: -I${includedir} -DLINUX -DWL_EGL_PLATFORM then we get the following error during configuration: | -- Performing Test HAVE_OPENGL_EGL | CMake Error: Parse error in command line argument: WL_EGL_PLATFORM | Should be: VAR:type=value If one changes to add a value to the macro, e.g. | Cflags: -I${includedir} -DLINUX=1 -DWL_EGL_PLATFORM=1 then cmake does not error out but the macro is not passed to the C compiler. CMAKE_REQUIRED_FLAGS is the wrong variable to pass the CFLAGS in, CMAKE_REQUIRED_DEFINITIONS should be used. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
Ozkan Sezer b2656776 2022-01-11T11:33:02 cmake: initial attempt at adding os/2 support.
Ryan C. Gordon 7967c976 2022-01-05T21:02:38 cmake: Do a more thorough test for the old bcm Raspberry Pi libraries. Fixes #5132.
Ozkan Sezer 398c0fdf 2021-12-18T23:56:10 cmake: simplify wayland-scanner 1.15 detection.
Wohlstand 54d24510 2021-12-18T19:58:28 sdlchecks.cmake: Small tune by @sezero
Wohlstand 6c9907dd 2021-12-18T17:15:08 Fixed build on CMake older than 3.7 I found this accidentally when I tried to use CMake 3.0 to build this.
Wohlstand 3861afac 2021-12-18T17:14:32 Fixed build on CMake older than 3.13 Fixes #5096
Ozkan Sezer 03019c91 2021-12-06T20:37:52 autotools, cmake: tighten Xfixes check && explicitly test BarrierEventID Apparently the older versions of libXi doesn't have it. Fixes the build break issue reported at: https://github.com/libsdl-org/SDL/commit/4b42c05ba1eaaaa9a4ef803acea8f13402271039#commitcomment-61427659
Ozkan Sezer 5a0ea7fb 2021-11-27T19:10:10 Check for O_CLOEXEC definition in fcntl.h at configuration time, If not available, define it internally as 0 (in SDL_internal.h). Define it as available for macOS >= 10.7 in SDL_config_macosx.h.
Cameron Gutman 43d1b42a 2021-11-16T17:59:38 cmake: Sync build config options with autotools - SDL_CLOCK_GETTIME now defaults to ON to match autotools build - Add detection of float.h and Xdbe - Fix detection of pthread_setname_np() (requires _GNU_SOURCE) - Move SDL_USE_IME definition into SDL_config.h.cmake
Ozkan Sezer 7d3045f2 2021-11-16T23:51:40 minor whitespace tidy-up.
Ozkan Sezer 68ffd24c 2021-11-16T23:37:20 autotools, cmake: don't define SDL_JOYSTICK_HIDAPI in CheckHIDAPI()
Sam Lantinga bbac1e9a 2021-11-14T20:34:41 Don't include pthreads code when threads are disabled Fixes https://github.com/libsdl-org/SDL/issues/4950
Ozkan Sezer fa3330ba 2021-11-12T12:55:50 autotools, cmake: test Xfixes along with XInput2.h: because we use Xfixes with XIBarrierReleasePointer
Sam Lantinga a0f8afb5 2021-11-11T09:16:44 Separated the HIDAPI subsystem from HIDAPI joysticks You can now disable HIDAPI joysticks while retaining the HIDAPI SDL API
Ethan Lee 4b42c05b 2021-11-08T13:52:48 video: Add SDL_SetWindowMouseRect. This API and implementation comes from the Unreal Engine branch of SDL, which originally called this "SDL_ConfineCursor". Some minor cleanup and changes for consistency with the rest of SDL_video, but there are two major changes: 1. The coordinate system has been changed so that `rect` is _window_ relative and not _screen_ relative, making it easier to implement without having global access to the display. 2. The UE version unset all rects when passing `NULL` as a parameter for `window`, this has been removed as it was an unused feature anyhow. Currently this is only implemented for X, but can be supported on Wayland and Windows at minimum too.
Ozkan Sezer 1739ef3e 2021-11-08T22:00:02 sdlchecks.cmake: remove libusb/hid.c and SDL_hidapi.c additions to srcs
Joel Winarske fdb27e0b 2021-10-25T09:04:07 cmake: Use host wayland-scanner only (#4873)
Ryan C. Gordon ab7910fa 2021-10-05T12:34:29 cmake: Move the old, global add_definitions (etc) to an interface library. Fixes #4150.
Ryan C. Gordon f1793af4 2021-10-05T11:19:30 cmake: removed an add_definitions call.
Ryan C. Gordon 60d59aeb 2021-10-05T10:54:06 cmake: Calculate padding for dislaying options automatically.
Ryan C. Gordon 7850d0cf 2021-10-05T10:43:35 cmake: Prefix all options with "SDL_" This makes it clear which options came from SDL's CMake project when building SDL as a subdirectory of a parent CMake project. Fixes #4139.
Ethan Lee ef8c4d27 2021-09-23T17:43:53 wayland: Require xkbcommon 0.5.0 or newer (2014-10-18) Fixes #4645
Ryan C. Gordon 478f9eed 2021-09-20T10:20:04 x11: Don't include X11/extensions/extutil.h We don't use it, it was a leftover from 1.2, I think, and it doesn't exist on Solaris, so this should hopefully fix the build there. This also means we don't need the configure/cmake checks for SDL_VIDEO_DRIVER_X11_CONST_PARAM_XEXTADDDISPLAY, so that was removed also. Fixes #1666.
Ryan C. Gordon fff421f4 2021-08-23T23:59:54 cmake: fix a bunch of things to properly link without LOADSO enabled. The wrong logic, copy/pasted to a bunch of places, would correctly disable the dynamic loading but fail to specify the libraries that SDL would now need to explicitly link against.
Ozkan Sezer 77c8d111 2021-08-10T20:55:50 configuration updates for dlopen: - cmake, configure (CheckDLOPEN): --enable-sdl-dlopen is now history.. detach the dl api discovery from SDL_LOADSO_DLOPEN functionality. define HAVE_DLOPEN. also define DYNAPI_NEEDS_DLOPEN (CheckDLOPEN is called only for relevant platforms.) - update SDL_config.in and SDL_config.cmake accordingly. - SDL_dynapi.h: set SDL_DYNAMIC_API to 0 if DYNAPI_NEEDS_DLOPEN is defined, but HAVE_DLOPEN is not. - pthread/SDL_systhread.c: conditionalize dl api use to HAVE_DLOPEN - SDL_x11opengl.c, SDL_DirectFB_opengl.c, SDL_naclopengles.c: rely on HAVE_DLOPEN, not SDL_LOADSO_DLOPEN. - SDL_config_android.h, SDL_config_iphoneos.h, SDL_config_macosx.h, SDL_config_pandora.h, and SDL_config_wiz.h: define HAVE_DLOPEN. Closes: https://github.com/libsdl-org/SDL/pull/4351
Ozkan Sezer 5b18ae29 2021-08-03T14:01:02 improvements to libdecor support in cmake this makes it consistent with wayland support, and makes cmake side in line with autotools' libdecor support.
Ozkan Sezer a15ec365 2021-08-03T11:33:50 attempt to fix cmake builds with libdecor
Ryan C. Gordon 74aa4b63 2021-08-03T03:10:14 cmake: don't fail if Wayland is enabled but libdecor isn't found. Instead, just disable libdecor support. This matches what the configure script does.
Christian Rauch 9e6fcbe7 2020-06-11T22:10:28 wayland: client-side decoration
Nicolas Caramelli 6a2af48a 2021-05-06T15:43:16 CMake: Generic check for desktop GL and EGL on Linux systems
Ozkan Sezer 89a2980a 2021-04-23T01:56:10 CMake: fixes to pthreads detection. changes unnecessary check_c_source_runs to check_c_source_compiles, removes the reduntant cross-compile check, and defines _GNU_SOURCE for PTHREAD_MUTEX_RECURSIVE checks just like the autotools version. Fixes: https://github.com/libsdl-org/SDL/issues/4262 Closes: https://github.com/libsdl-org/SDL/pull/4282
Ryan C. Gordon a81fe272 2021-04-04T00:16:30 configure/cmake: Hook up Emscripten threads (disabled by default). Fixes #3795.
vanfanel e213f37a 2021-03-15T12:53:16 [KMSDRM] Enable full OpenGL detection (MESA/libglvnd) on both the make and cmake buildsystems.
Cacodemon345 3853531f 2021-03-15T10:43:14 Fix CMake script on Linux
Cacodemon345 34de3b57 2021-03-11T15:10:29 Fix CMake script on FreeBSD
Ivan Epifanov 47c10516 2020-12-18T16:42:37 Add reversive list join macro
Frank Praznik 2f0b99a7 2021-02-13T11:56:05 audio: Add Pipewire playback/capture sink
Ozkan Sezer 091a4649 2021-01-29T23:11:13 added --enable-xinput switch for windows builds
Ozkan Sezer 23764588 2021-01-23T17:24:28 renamed SDL_JOYSTICK_USBHID_MACHINE_JOYSTICK_H to SDL_HAVE_MACHINE_JOYSTICK_H
Sam Lantinga 351abc58 2021-01-14T14:50:15 Fixed bug 5463 - generated Wayland interfaces are included in the library's ABI Simon McVittie In versions since 1.15, the `code` mode is a deprecated alias for `public-code`, which emits symbols with default visibility, overriding SDL's -fvisibility=hidden option. Use the `private-code` mode instead. This emits symbols with hidden visibility, so they do not affect the ABI of libSDL. See also: https://bugreports.qt.io/browse/QTBUG-73099, https://lists.freedesktop.org/archives/wayland-devel/2018-February/037097.html
Manuel Alfayate Corchete b2449473 2021-01-08T18:57:12 [KMS/DRM] Go back to the LEGACY interface only because using planes breaks compatibility with HW, so no advantage on using ATOMIC.
Manuel Alfayate Corchete 13244de5 2020-12-22T17:17:30 [Buildsystem] Only build KMSDRM support if EGL+OpenGL is detected by CMake.
Sam Lantinga ee180efd 2020-12-20T12:08:49 Fixed bug 5406 - Upstreaming DragonFlyBSD changes from DeltaPorts (patch from David Carlier)
Sam Lantinga f8839289 2020-12-15T12:22:48 Potential fix for bug 5393 - KMSDRM: using atomic mode setting breaks GPU compatibility Substring I was trying the KMSDRM video backend with some very simple programs that were working ok on 2.0.12. The same code won?t work on the current dev branch and I get: DEBUG: check_modesetting: probing ?/dev/dri/card0? DEBUG: /dev/dri/card0 connector, encoder and CRTC counts are: 4 5 6 DEBUG: check_modesetting: probing ?/dev/dri/card0? DEBUG: /dev/dri/card0 connector, encoder and CRTC counts are: 4 5 6 DEBUG: KMSDRM_VideoInit() DEBUG: Opening device /dev/dri/card0 DEBUG: Opened DRM FD (3) DEBUG: no atomic modesetting support. DEBUG: Video subsystem has not been initialized INFO: Using SDL video driver: (null) DEBUG: Video subsystem has not been initialized After carefully checking, the radeon driver doesn?t support atomic modesetting. That?s not the only problem : the same happens with the amdgpu driver if we disable Display Core (kernel parameter amdgpu.dc=0, which is required to get analogue outputs working). This is a major regression in the KMSDRM driver. Using atomic mode setting is great, but having no fallback to the "standard KMS" is bad.
Sam Lantinga bd032c1f 2020-12-09T07:26:59 Fixed bug 5221 - libusb isn't detected correctly in CMake Sven-Hendrik Haase In CMake I currently have trouble activating hidapi support as libusb-1.0 isn't ever correctly detected as it's searched for by the wrong name. configure.ac correctly does this: PKG_CHECK_MODULES([LIBUSB], [libusb-1.0], have_libusb=yes, have_libusb=no) However, sdlchecks.cmake does this: pkg_check_modules(LIBUSB libusb) but it needs to be: pkg_check_modules(LIBUSB libusb-1.0)
Ryan C. Gordon 2b7ce8c5 2020-04-14T18:14:39 cmake: Set HAVE_VIDEO_WAYLAND_QT_TOUCH if appropriate (thanks, Michael!).
Ryan C. Gordon 952bac7c 2020-04-13T15:22:09 cmake: use check_symbol_exists, not check_function_exists (thanks, Manuel!) This fixes the problem where we think iOS has fseeko64, etc, but doesn't. Fixes Bugzilla #4885.
Ryan C. Gordon 377f2d35 2020-04-01T13:43:53 configure: Remove wayland-protocols check from configure and CMake scripts. We ship these with SDL now, don't need the system versions installed.
Sam Lantinga f7c9502d 2020-03-20T12:13:26 Fixed bug 5044 - CMake messes up hidapi path when project directory contains spaces Eric Jing When the project directory path contains spaces, CMake butchers the include path for the hidapi files. I traced the problem to the cmake/sdlchecks.cmake file at line 1091, which sets flags for the build process. I surrounded the problem flag with double quotes, shown below, and CMake works with spaces in the project directory path.
Sam Lantinga c7a739be 2020-03-02T15:24:10 Fixed bug 4643 - Append EGL CFLAGS in CheckOpenGLESX11 Danilo Spinella EGL need -DMESA_EGL_NO_X11_HEADERS in systems without X11 installed. Make CMake checks import EGL CFLAGS. Relevant bug: https://bugzilla.libsdl.org/show_bug.cgi?id=4243
Andrew Eikum e149f4c4 2019-07-31T11:34:00 cmake: Fix locating libusb header at configure-time Removing the CheckUSBHID call is necessary to avoid caching the failed header check result before we find libusb via pkg-config.
Ethan Lee f7d82e56 2019-07-31T12:20:55 hidapi: Add SDL_hidapi.c, allows support for multiple hidapi backends. This is currently supported on Linux and macOS. iOS and Android are not supported at all, Windows support could be added with some changes to the libusb backend. The Visual Studio and Xcode projects do not use this feature. Based on Valve Software's hid.cpp, written in collaboration with Andrew Eikum.
Ryan C. Gordon 66d4d8e2 2019-07-08T16:46:52 cmake: Added HIDAPI support.
Ryan C. Gordon bc57ac27 2018-11-02T21:34:17 mir: Removed mir client support. Fixes Bugzilla #4288.
Ryan C. Gordon 4f5bd53e 2018-06-25T09:37:25 wayland: Keep protocol XML files in-tree. Now you don't need the latest Wayland installed to build with newer protocols supported, as they'll build correctly; even if your system can't use them, we can make intelligent decisions at runtime about what's available on the current machine anyhow. This also simplifies some logic and possible failure cases in the configure and CMake scripts. Fixes Bugzilla #4207.
Ryan C. Gordon c70db0ca 2018-06-24T15:12:18 cmake: Look in popular places for X11 headers, export this info properly. Fixes CMake not being able to find X11 on FreeBSD (which generally has the headers in /usr/local/include/X11). List of other popular places borrowed from CMake's FindX11 module. This worked on the configure script because of magic in the AC_PATH_X macro. Fixes Bugzilla #4815.
Sam Lantinga ba9ede12 2018-02-13T13:25:59 Fixed bug 4027 - CheckLibSampleRate macro in sdlchecks.cmake never defines HAVE_LIBSAMPLERATE{,_SHARED}, so they're always reported as disabled by MESSAGE_TESTED_OPTION macro in macros.cmake
Sam Lantinga 4ff16ba3 2018-02-13T07:59:45 Fixed bug 4081 - sdlchecks.cmake: typo introduced by rev11848 breaks building with wayland support
Guillermo A. Amaral bd0def06 2018-02-07T14:12:26 Set rpath instead of changing environment for RPi Credit goes to Adrian Perez de Castro for the improvement. Signed-off-by: Guillermo A. Amaral <g@maral.me>
Ryan C. Gordon cd532207 2018-02-07T13:13:55 wayland: Add support for xdg-shell protocol (unstable v6). This is meant to be the desktop-enhanced version of wl_shell. Right now we just match what the existing wl_shell code does, but there are other areas of functionality available to us now, that we can fill in later. This uses the "unstable" API, since this is what ships in Ubuntu 17.10 (as part of Wayland 1.10), but Wayland 1.12 promotes this to stable with extremely minor changes. We will add support for the stable version when it makes sense to do so.
Ryan C. Gordon 32d421d4 2018-02-07T13:07:59 cmake: Minor cleanup (reuse a string we already calculated).
Guillermo A. Amaral 35554caf 2018-01-17T13:17:10 Make rpi video cross-compiler friendly. * Stops using fixed path to find GLES/EGL libs. * Tries pkg-config to locate bcm_host. Signed-off-by: Guillermo A. Amaral <g@maral.me>
Ryan C. Gordon c722e58d 2017-08-27T23:25:12 vulkan: Include a copy of vulkan.h and vk_platform.h. Now we can provide Vulkan support in the build even if the build box doesn't have a Vulkan SDK, since we dynamically link to the library anyhow.
Ryan C. Gordon 25e3a1ec 2017-08-27T22:15:57 vulkan: Initial Vulkan support! This work was done by Jacob Lifshay and Mark Callow; I'm just merging it into revision control.
Ryan C. Gordon 80c6c2fa 2017-08-09T22:34:45 cmake: whoops, Sam and I both fixed this bug at the same time. :)
Sam Lantinga d3af447e 2017-08-09T18:47:33 Fixed bug 3590 - CMAKE: typos in CheckMir Martin Gerhardy - list(APPEND EXTRA_CFLAGS ${MIR_TOOLKIT_CFLAGS} ${EGL_CLFAGS} ${XKB_CLFLAGS}) + list(APPEND EXTRA_CFLAGS ${MIR_TOOLKIT_CFLAGS} ${EGL_CFLAGS} ${XKB_CFLAGS}) CFLAGS is spelled wrong in two different ways for EGL and XKB And while you are on it... sdl needs mir >= 0.24 afaik - it fails on travis-ci (ubuntu 14.04 LTS with 0.18 installed and in other environments, too (e.g. https://github.com/urho3d/Urho3D/issues/1685) To fix this one should add a min version check to pkg_check_modules like this - pkg_check_modules(MIR_TOOLKIT mirclient mircommon) + pkg_check_modules(MIR_TOOLKIT mirclient>=0.24 mircommon)
Ryan C. Gordon 1b8117be 2017-08-09T19:50:18 cmake: Don't link directly against a libpthread on Android (thanks, Anthony!). Android has pthreads, but it's just part of their C runtime instead of a separate library like the usual Linux platforms. Fixes Bugzilla #3675.
Sam Lantinga 56363ebf 2017-08-02T10:22:48 Fixed bug 3690 - SDL2 KMS/DRM render context support Manuel The attached patch adds support for KMS/DRM context graphics. It builds with no problem on X86_64 GNU/Linux systems, provided the needed libraries are present, and on ARM GNU/Linux systems that have KMS/DRM support and a GLES2 implementation. Tested on Raspberry Pi: KMS/DRM is what the Raspberry Pi will use as default in the near future, once the propietary DispmanX API by Broadcom is overtaken by open graphics stack, it's possible to boot current Raspbian system in KMS mode by adding "dtoverlay=vc4-kms-v3d" to config.txt on Raspbian's boot partition. X86 systems use KMS right away in every current GNU/Linux system. Simple build instructions: $./autogen.sh $./configure --enable-video-kmsdrm $make
Sam Lantinga 34b29c6a 2017-07-10T18:40:35 Fixed bug 3688 - cmake / pthread check related patch proposal Juha Niemim?ki Fix for PTHREAD_MUTEX_RECURSIVE_NP check and restoring the original flags Two fixes proposed: 1) Looks like there is a copy-paste issue regarding PTHREAD_MUTEX_RECURSIVE_NP check. 2) Compiler flag restoration doesn't look symmetrical regarding if/endif blocks. Moved to an outer block (if PTHREADS).
Olli Kallioinen 2b5a5c51 2017-06-08T22:07:55 Android build fixes -Enabling checking for GCC_ATOMICS also on clang by default. This way all Android ABIs build successfully -Android cmake: Threading was not enabled correctly -Android cmake: Timers and dynamic lib loading were not included in the sources
Ryan C. Gordon d9039f23 2017-06-08T13:27:58 jack: Initial shot at a JACK audio target. http://jackaudio.org/ Fixes Bugzilla #2163. (with several more commits following to improve this code.)
Sam Lantinga df25258a 2017-01-06T20:43:53 Added configure and cmake support for libsamplerate
Ryan C. Gordon 8a0704d1 2016-10-11T16:36:40 cmake: Now generates Wayland protocol source bits like the configure script. Fixes Bugzilla #3430.
Sam Lantinga abefe785 2016-10-07T18:03:08 Fixed bug 3043 - fix alsa configury and cmake checks Ozkan Sezer SDL's alsa uses snd_pcm_recover() which has been available only since alsa-lib-1.0.11.
Jukka Jyl?nki 264e996e 2016-09-13T00:03:50 Fix CMake CMAKE_REQUIRED_FLAGS handling to preserve existing CMake flags required by Emscripten toolchain.
Ryan C. Gordon 9fcf5d7d 2016-01-03T21:48:17 CMake: Don't link directly to libGL on Unix. (we always dynamically load it at runtime when appropriate.)
Philipp Wiesemann 0e45984f 2015-06-21T17:33:46 Fixed crash if initialization of EGL failed but was tried again later. The internal function SDL_EGL_LoadLibrary() did not delete and remove a mostly uninitialized data structure if loading the library first failed. A later try to use EGL then skipped initialization and assumed it was previously successful because the data structure now already existed. This led to at least one crash in the internal function SDL_EGL_ChooseConfig() because a NULL pointer was dereferenced to make a call to eglBindAPI().
Ryan C. Gordon e3f4ca0d 2015-06-08T01:13:51 configure/cmake/x11: Removed SDL_VIDEO_DRIVER_X11_CONST_PARAM_XDATA32 test. This was the only thing that made SDL_config.h generate differently between 32 and 64-bit versions of Linux, so instead we force a function cast in our X11 code to match our dynamic loader version, which removes the compile error on some machines that prompted this test in the first place. Xlib never wrote to this data, so if you're on an older Xlib where this param wasn't const, your data should still be intact when we force the caller to think it was actually const after all. Fixes Bugzilla #1893.