https://github.com/Kitware/CMake
Raw File
Tip revision: 00677703d00f94702ef94d8dd07387c8405a3caf authored by Brad King on 29 March 2022, 15:02:43 UTC
CMake 3.23.0
Tip revision: 0067770
CheckForPthreads.c
#include <pthread.h>

void* start_routine(void* args)
{
  return args;
}

int main(void)
{
  /* This is a compile and link test, no code to actually run things. */
  pthread_t thread;
  pthread_create(&thread, 0, start_routine, 0);
  pthread_join(thread, 0);
  return 0;
}
back to top