sdl2: fix build with --disable-threads
authorFabrice Fontaine <fontaine.fabrice@gmail.com>
Wed, 21 Nov 2018 22:09:23 +0000 (23:09 +0100)
committerThomas Petazzoni <thomas.petazzoni@bootlin.com>
Fri, 23 Nov 2018 21:01:09 +0000 (22:01 +0100)
commit0d896cf007920e01fc9104f98c8f4d3734a6f245
tree61106c974569bae8a3043d2f4bdd4bff7c3f8243
parent75d2073e033bc9d4180ff8c94a4504f1b9d8d9d4
sdl2: fix build with --disable-threads

SDL_LinuxSetThreadPriority() has been added since version 2.0.9 and
https://github.com/SDL-mirror/SDL/commit/f25a7fa870bdceb339e5105973f689606bcb9086

However, this function is used in src/dynapi/SDL_dynapi_procs.h even
when SDL_THREADS_DISABLED

However, when SDL_THREADS_DISABLED is set, SDL_LinuxSetThreadPriority is
not defined because thread/pthread/SDL_systhread.c is not built

So check SDL_THREADS_DISABLED in addition to __LINUX__

Fixes:
 - http://autobuild.buildroot.org/results/539cb9ab6c605dc6be73ebe90debab1a998f2451

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
package/sdl2/0001-fix-build-with-disable-threads.patch [new file with mode: 0644]