summaryrefslogtreecommitdiff
path: root/security/libssh/files/patch-src__threads__CMakeLists.txt
blob: 5250a19396c105bbf25efb52804abdce2447ecc4 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
--- ./src/threads/CMakeLists.txt
+++ ./src/threads/CMakeLists.txt
@@ -24,30 +24,12 @@ if (WITH_STATIC_LIB)
 endif (WITH_STATIC_LIB)
 
 set(LIBSSH_THREADS_LINK_LIBRARIES
-    ${LIBSSH_SHARED_LIBRARY}
-)
-
-set(libssh_threads_SRCS
-)
-
-# build and link pthread
-if (CMAKE_USE_PTHREADS_INIT)
-    set(libssh_threads_SRCS
-        ${libssh_threads_SRCS}
-        pthread.c
-    )
-
-    set(LIBSSH_THREADS_LINK_LIBRARIES
-        ${LIBSSH_THREADS_LINK_LIBRARIES}
-        ${CMAKE_THREAD_LIBS_INIT}
-    )
-endif (CMAKE_USE_PTHREADS_INIT)
-
-set(LIBSSH_THREADS_LINK_LIBRARIES
-  ${LIBSSH_THREADS_LINK_LIBRARIES}
+  ${LIBSSH_SHARED_LIBRARY} ${CMAKE_THREAD_LIBS_INIT}
   CACHE INTERNAL "libssh threads link libraries"
 )
 
+set(libssh_threads_SRCS pthread.c)
+
 include_directories(
   ${LIBSSH_THREADS_PUBLIC_INCLUDE_DIRS}
   ${LIBSSH_THREADS_PRIVATE_INCLUDE_DIRS}