File tree Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -143,10 +143,16 @@ find_package(LibXslt REQUIRED)
143
143
find_package (BZip2 )
144
144
145
145
# PThread
146
+ if (WIN32 )
147
+ find_package (ZLIB REQUIRED )
148
+ find_package (pthread CONFIG REQUIRED )
149
+ set (CMAKE_THREAD_LIBS_INIT ${PThreads4W_LIBRARY} )
150
+ else ()
151
+ find_package (Threads REQUIRED )
152
+ endif ()
146
153
set (CMAKE_THREAD_PREFER_PTHREAD )
147
154
set (THREADS_PREFER_PTHREAD_FLAG )
148
- set (THREADS_USE_PTHREADS_WIN32 true )
149
- find_package (Threads REQUIRED )
155
+ set (THREADS_USE_PTHREADS_WIN32 TRUE )
150
156
check_library_exists (pthread pthread_timedjoin_np "" HAVE_PTHREAD_TIMEDJOIN_NP )
151
157
check_library_exists (pthread pthread_setname_np "" HAVE_PTHREAD_SETNAME_NP )
152
158
check_library_exists (pthread pthread_getname_np "" HAVE_PTHREAD_GETNAME_NP )
Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ image: Visual Studio 2017
7
7
configuration : Release
8
8
clone_folder : c:\projects\openscap
9
9
install :
10
- - cmd : vcpkg install curl libxml2 libxslt bzip2 pcre pthreads
10
+ - cmd : vcpkg install curl libxml2 libxslt bzip2 pcre pthreads zlib
11
11
cache : c:\tools\vcpkg\installed\
12
12
before_build :
13
13
- cmd : >-
You can’t perform that action at this time.
0 commit comments