From 7f39b2a738b2585fa383704ac420091b45e4f28c Mon Sep 17 00:00:00 2001 From: scheffle Date: Sun, 10 Nov 2024 13:20:24 +0100 Subject: [PATCH] fix linux linker error regarding pthread_create --- vstgui/CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/vstgui/CMakeLists.txt b/vstgui/CMakeLists.txt index e640c10cb..efa6ce246 100644 --- a/vstgui/CMakeLists.txt +++ b/vstgui/CMakeLists.txt @@ -52,6 +52,8 @@ endfunction(vstgui_source_group_by_folder) ########################################################################################## if(LINUX) + set(THREADS_PREFER_PTHREAD_FLAG ON) + find_package(Threads REQUIRED) find_package(X11 REQUIRED) find_package(Freetype REQUIRED) find_package(PkgConfig REQUIRED) @@ -80,6 +82,7 @@ if(LINUX) ${CAIRO_LIBRARIES} ${PANGO_LIBRARIES} ${FONTCONFIG_LIBRARIES} + Threads::Threads dl ) endif()