Correctly link against pthreads, solution from https://stackoverflow.com/questions/5395309/how-do-i-force-cmake-to-include-pthread-option-during-compilation
parent
f11edff29a
commit
3764f78811
|
|
@ -8,7 +8,10 @@ set(LLPLUGIN_INCLUDE_DIRS
|
|||
if (LINUX)
|
||||
# In order to support using ld.gold on linux, we need to explicitely
|
||||
# specify all libraries that llplugin uses.
|
||||
set(LLPLUGIN_LIBRARIES llplugin)
|
||||
set(CMAKE_THREAD_PREFER_PTHREAD TRUE)
|
||||
set(THREADS_PREFER_PTHREAD_FLAG TRUE)
|
||||
find_package( Threads )
|
||||
set(LLPLUGIN_LIBRARIES llplugin Threads::Threads)
|
||||
else (LINUX)
|
||||
set(LLPLUGIN_LIBRARIES llplugin)
|
||||
endif (LINUX)
|
||||
|
|
|
|||
Loading…
Reference in New Issue