Bladeren bron

Don't try to use SDL platform macros in configure-time checks

At the point that we run this, nothing SDL-specific is set up yet.
__APPLE__ is a compiler predefined macro that forms part of the API on
Apple platforms, so it's fine to rely on it.

This partially reverts commit 31d133db.

Fixes: 31d133db "Define SDL_PLATFORM_* macros instead of underscored ones (#8875)"
Signed-off-by: Simon McVittie <smcv@collabora.com>
Simon McVittie 1 jaar geleden
bovenliggende
commit
a06ee5b98d
1 gewijzigde bestanden met toevoegingen van 1 en 1 verwijderingen
  1. 1 1
      cmake/sdlchecks.cmake

+ 1 - 1
cmake/sdlchecks.cmake

@@ -849,7 +849,7 @@ macro(CheckPTHREAD)
         check_c_source_compiles("
             #include <pthread.h>
             int main(int argc, char **argv) {
-              #ifdef SDL_PLATFORM_APPLE
+              #ifdef __APPLE__
               pthread_setname_np(\"\");
               #else
               pthread_setname_np(pthread_self(),\"\");