diff options
| author | Aaron M. Ucko <ucko@debian.org> | 2025-03-30 17:39:57 -0400 |
|---|---|---|
| committer | Albrecht Schlosser <albrechts.fltk@online.de> | 2025-04-01 19:12:10 +0200 |
| commit | 8b28e38942ce8b61966da90af644c9948a007eda (patch) | |
| tree | f8c4c850c5b51c62f95d9dd14d1339da2b77f72c | |
| parent | f4978a014997656b4592c2b3b866865f76d390ea (diff) | |
options.cmake: Check Threads_FOUND, not CMAKE_HAVE_THREADS_LIBRARY
The former's been available since CMake v2.8 and documented since v3.17;
the latter was never documented and quietly went away in CMake v3.24.
| -rw-r--r-- | CMake/options.cmake | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/CMake/options.cmake b/CMake/options.cmake index d2fa392f7..8411b92ec 100644 --- a/CMake/options.cmake +++ b/CMake/options.cmake @@ -739,11 +739,11 @@ if(FLTK_USE_PTHREADS) include(FindThreads) - if(CMAKE_HAVE_THREADS_LIBRARY) + if(Threads_FOUND) add_definitions("-D_THREAD_SAFE -D_REENTRANT") set(USE_THREADS 1) set(FLTK_THREADS_FOUND TRUE) - endif(CMAKE_HAVE_THREADS_LIBRARY) + endif(Threads_FOUND) if(CMAKE_USE_PTHREADS_INIT AND NOT WIN32) set(HAVE_PTHREAD 1) |
