summaryrefslogtreecommitdiffstats
path: root/Tests/FindThreads/C-only/CMakeLists.txt
blob: ab4ca0dddf0653ba24b3efcc78ad57ab262155d2 (plain)
1
2
3
4
5
6
7
8
9
10
cmake_minimum_required(VERSION 3.3 FATAL_ERROR)
project(FindThreads_C-only C)

set(CMAKE_THREAD_PREFER_PTHREAD On)
find_package(Threads REQUIRED)

if (NOT WIN32)
  add_executable(thr ${CMAKE_CURRENT_SOURCE_DIR}/../../../Modules/CheckForPthreads.c)
  target_link_libraries(thr Threads::Threads)
endif ()