diff options
author | Ray Molenkamp <github@lazydodo.com> | 2019-02-22 00:16:26 +0300 |
---|---|---|
committer | Ray Molenkamp <github@lazydodo.com> | 2019-02-22 00:16:26 +0300 |
commit | 5d5070dd12326478fd5b5651a120264daa004232 (patch) | |
tree | 26712681edfec1b08cd5325eda5d89a7538dfd43 /build_files/build_environment/cmake | |
parent | f1304c973f5eef5169e09d30c0dba82cc7e4c4a1 (diff) |
Windows: Use static pthreads library.
Diffstat (limited to 'build_files/build_environment/cmake')
-rw-r--r-- | build_files/build_environment/cmake/pthreads.cmake | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/build_files/build_environment/cmake/pthreads.cmake b/build_files/build_environment/cmake/pthreads.cmake index 364ccb6cefe..8d605973fa5 100644 --- a/build_files/build_environment/cmake/pthreads.cmake +++ b/build_files/build_environment/cmake/pthreads.cmake @@ -17,7 +17,6 @@ # ***** END GPL LICENSE BLOCK ***** if(WIN32) - set(PTHREAD_XCFLAGS /MD) if(MSVC14) # vs2015 has timespec set(PTHREAD_CPPFLAGS "/I. /DHAVE_CONFIG_H /D_TIMESPEC_DEFINED ") @@ -25,7 +24,7 @@ if(WIN32) set(PTHREAD_CPPFLAGS "/I. /DHAVE_CONFIG_H ") endif() - set(PTHREADS_BUILD cd ${BUILD_DIR}/pthreads/src/external_pthreads/ && cd && nmake VC /e CPPFLAGS=${PTHREAD_CPPFLAGS} /e XCFLAGS=${PTHREAD_XCFLAGS} /e XLIBS=/NODEFAULTLIB:msvcr) + set(PTHREADS_BUILD cd ${BUILD_DIR}/pthreads/src/external_pthreads/ && cd && nmake VC-static /e CPPFLAGS=${PTHREAD_CPPFLAGS} /e XLIBS=/NODEFAULTLIB:msvcr) ExternalProject_Add(external_pthreads URL ${PTHREADS_URI} @@ -35,8 +34,7 @@ if(WIN32) CONFIGURE_COMMAND echo . BUILD_COMMAND ${PTHREADS_BUILD} INSTALL_COMMAND COMMAND - ${CMAKE_COMMAND} -E copy ${BUILD_DIR}/pthreads/src/external_pthreads/pthreadVC3.dll ${LIBDIR}/pthreads/lib/pthreadVC3.dll && - ${CMAKE_COMMAND} -E copy ${BUILD_DIR}/pthreads/src/external_pthreads/pthreadVC3${LIBEXT} ${LIBDIR}/pthreads/lib/pthreadVC3${LIBEXT} && + ${CMAKE_COMMAND} -E copy ${BUILD_DIR}/pthreads/src/external_pthreads/libpthreadVC3${LIBEXT} ${LIBDIR}/pthreads/lib/pthreadVC3${LIBEXT} && ${CMAKE_COMMAND} -E copy ${BUILD_DIR}/pthreads/src/external_pthreads/pthread.h ${LIBDIR}/pthreads/inc/pthread.h && ${CMAKE_COMMAND} -E copy ${BUILD_DIR}/pthreads/src/external_pthreads/sched.h ${LIBDIR}/pthreads/inc/sched.h && ${CMAKE_COMMAND} -E copy ${BUILD_DIR}/pthreads/src/external_pthreads/semaphore.h ${LIBDIR}/pthreads/inc/semaphore.h && |