File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -1210,11 +1210,13 @@ if(NOT WIN32)
12101210 if (HAVE_WORDEXP)
12111211 target_compile_definitions (libfastfetch PRIVATE FF_HAVE_WORDEXP=1)
12121212 endif ()
1213- if (ENABLE_THREADS)
1213+ if (ENABLE_THREADS AND CMAKE_USE_PTHREADS_INIT )
12141214 CHECK_INCLUDE_FILE("pthread_np.h" HAVE_PTHREAD_NP)
12151215 if (HAVE_PTHREAD_NP)
12161216 target_compile_definitions (libfastfetch PRIVATE FF_HAVE_PTHREAD_NP=1)
1217+ set (CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES} pthread_np.h)
12171218 endif ()
1219+ set (CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} Threads::Threads)
12181220 check_function_exists("pthread_timedjoin_np" HAVE_TIMEDJOIN_NP)
12191221 if (HAVE_TIMEDJOIN_NP)
12201222 target_compile_definitions (libfastfetch PRIVATE FF_HAVE_TIMEDJOIN_NP=1)
You can’t perform that action at this time.
0 commit comments