From 1e4cbbc65c2d2f09c4be843b6e178a471969dc96 Mon Sep 17 00:00:00 2001 From: arvidn Date: Thu, 20 Aug 2015 22:33:20 +0200 Subject: [PATCH 01/11] enable just 64 bit builds (appveyor). fetch both 32 and 64 bit build of openssl. always overwrite in 7z command --- appveyor.yml | 36 ++++++++++++++++++++++-------------- 1 file changed, 22 insertions(+), 14 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index 26f0a1224..369c5e128 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -8,19 +8,24 @@ environment: matrix: - variant: test_debug compiler: msvc-12.0 - linkflags: '"/LIBPATH:C:\\OpenSSL-Win32\\lib"' + linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' + linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' - variant: test_debug compiler: msvc-10.0 - linkflags: '"/LIBPATH:C:\\OpenSSL-Win32\\lib"' + linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' + linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' - variant: test_debug compiler: msvc-14.0 - linkflags: '"/LIBPATH:C:\\OpenSSL-Win32\\lib"' + linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' + linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' - variant: test_barebones compiler: msvc-12.0 - linkflags: '"/LIBPATH:C:\\OpenSSL-Win32\\lib"' + linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' + linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' - variant: test_release compiler: msvc-12.0 - linkflags: '"/LIBPATH:C:\\OpenSSL-Win32\\lib"' + linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' + linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' # mingw and boost.random don't like each other. Comment this back in once there # is support @@ -33,11 +38,13 @@ install: - git submodule update --init --recursive - set ROOT_DIRECTORY=%CD% - cd %ROOT_DIRECTORY% -- if not exist c:\OpenSSL-Win32\nul ( - appveyor DownloadFile https://strcpy.net/packages/Win32OpenSSL-1_0_2a.exe - && Win32OpenSSL-1_0_2a.exe /silent /verysilent /sp- /suppressmsgboxes ) -- copy c:\OpenSSL-Win32\ssleay32.dll %WINDIR%\system32 -- copy c:\OpenSSL-Win32\libeay32.dll %WINDIR%\system32 +- if not exist c:\openssl-1.0.1p-vs2013\nul ( + appveyor DownloadFile http://www.npcglib.org/~stathis/downloads/openssl-1.0.1p-vs2013.7z + && 7z x -oc:\ -aoa openssl-1.0.1p-vs2013.7z + && copy c:\openssl-1.0.1p-vs2013\lib64\ssleay32MT.lib c:\openssl-1.0.1p-vs2013\lib64\ssleay32.lib + && copy c:\openssl-1.0.1p-vs2013\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2013\lib64\libeay32.lib + && copy c:\openssl-1.0.1p-vs2013\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2013\lib\ssleay32.lib + && copy c:\openssl-1.0.1p-vs2013\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2013\lib\libeay32.lib ) - cd %ROOT_DIRECTORY% - set BOOST_ROOT=c:\Libraries\boost - set BOOST_BUILD_PATH=%BOOST_ROOT%\tools\build @@ -55,14 +62,15 @@ install: - python --version - echo %ROOT_DIRECTORY% cache: -- C:\OpenSSL-Win32 +- C:\openssl-1.0.1p-vs2013 build_script: - cd %ROOT_DIRECTORY%\examples -- b2.exe --hash -j2 %compiler% variant=%variant% linkflags=%linkflags% include="C:\\OpenSSL-Win32\\include" +- b2.exe --hash -j2 %compiler% variant=%variant% linkflags=%linkflags32% include="c:\\openssl-1.0.1p-vs2013\\include" - cd %ROOT_DIRECTORY%\test -- b2.exe --hash -j2 address-model=32 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags% include="C:\\OpenSSL-Win32\\include" +- b2.exe --hash -j2 address-model=32 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags32% include="c:\\openssl-1.0.1p-vs2013\\include" +- b2.exe --hash -j2 address-model=64 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags64% include="c:\\openssl-1.0.1p-vs2013\\include" - cd %ROOT_DIRECTORY%\bindings\python -- b2.exe --hash -j2 %compiler% variant=%variant% linkflags=%linkflags% include="C:\\OpenSSL-Win32\\include" stage_module +- b2.exe --hash -j2 %compiler% stage_module variant=%variant% linkflags=%linkflags32% include="c:\\openssl-1.0.1p-vs2013\\include" - python test.py - if %variant% == "test_debug" ( cd %ROOT_DIRECTORY%\simulation From 2854e340ab1e2470ab31fefd82de5234e1d79610 Mon Sep 17 00:00:00 2001 From: arvidn Date: Fri, 21 Aug 2015 13:45:24 +0200 Subject: [PATCH 02/11] use dedicated openssl binaries for msvc 2010 --- appveyor.yml | 40 +++++++++++++++++++++++++++------------- 1 file changed, 27 insertions(+), 13 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index 369c5e128..e32674573 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -10,22 +10,27 @@ environment: compiler: msvc-12.0 linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' + include: '"c:\\openssl-1.0.1p-vs2013\\include"' - variant: test_debug compiler: msvc-10.0 - linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' - linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' + linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2010\\lib"' + linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2010\\lib64"' + include: '"c:\\openssl-1.0.1p-vs2010\\include"' - variant: test_debug compiler: msvc-14.0 linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' + include: '"c:\\openssl-1.0.1p-vs2013\\include"' - variant: test_barebones compiler: msvc-12.0 linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' + include: '"c:\\openssl-1.0.1p-vs2013\\include"' - variant: test_release compiler: msvc-12.0 linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' + include: '"c:\\openssl-1.0.1p-vs2013\\include"' # mingw and boost.random don't like each other. Comment this back in once there # is support @@ -45,6 +50,13 @@ install: && copy c:\openssl-1.0.1p-vs2013\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2013\lib64\libeay32.lib && copy c:\openssl-1.0.1p-vs2013\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2013\lib\ssleay32.lib && copy c:\openssl-1.0.1p-vs2013\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2013\lib\libeay32.lib ) +- if not exist c:\openssl-1.0.1p-vs2010\nul ( + appveyor DownloadFile http://www.npcglib.org/~stathis/downloads/openssl-1.0.1p-vs2010.7z + && 7z x -oc:\ -aoa openssl-1.0.1p-vs2010.7z + && copy c:\openssl-1.0.1p-vs2010\lib64\ssleay32MT.lib c:\openssl-1.0.1p-vs2010\lib64\ssleay32.lib + && copy c:\openssl-1.0.1p-vs2010\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2010\lib64\libeay32.lib + && copy c:\openssl-1.0.1p-vs2010\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2010\lib\ssleay32.lib + && copy c:\openssl-1.0.1p-vs2010\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2010\lib\libeay32.lib ) - cd %ROOT_DIRECTORY% - set BOOST_ROOT=c:\Libraries\boost - set BOOST_BUILD_PATH=%BOOST_ROOT%\tools\build @@ -63,16 +75,18 @@ install: - echo %ROOT_DIRECTORY% cache: - C:\openssl-1.0.1p-vs2013 +- C:\openssl-1.0.1p-vs2010 build_script: -- cd %ROOT_DIRECTORY%\examples -- b2.exe --hash -j2 %compiler% variant=%variant% linkflags=%linkflags32% include="c:\\openssl-1.0.1p-vs2013\\include" -- cd %ROOT_DIRECTORY%\test -- b2.exe --hash -j2 address-model=32 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags32% include="c:\\openssl-1.0.1p-vs2013\\include" -- b2.exe --hash -j2 address-model=64 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags64% include="c:\\openssl-1.0.1p-vs2013\\include" -- cd %ROOT_DIRECTORY%\bindings\python -- b2.exe --hash -j2 %compiler% stage_module variant=%variant% linkflags=%linkflags32% include="c:\\openssl-1.0.1p-vs2013\\include" -- python test.py -- if %variant% == "test_debug" ( - cd %ROOT_DIRECTORY%\simulation - && b2.exe --hash -j2 crypto=built-in %compiler% ) +- type "C:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\vcvarsall.bat" x86_amd64 +#- cd %ROOT_DIRECTORY%\examples +#- b2.exe --hash -j2 %compiler% variant=%variant% linkflags=%linkflags32% include=%include% +#- cd %ROOT_DIRECTORY%\test +#- b2.exe --hash -j2 address-model=32 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags32% include=%include% +#- b2.exe --hash -j2 address-model=64 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags64% include=%include% +#- cd %ROOT_DIRECTORY%\bindings\python +#- b2.exe --hash -j2 %compiler% stage_module variant=%variant% linkflags=%linkflags32% include=%include% +#- python test.py +#- if %variant% == "test_debug" ( +# cd %ROOT_DIRECTORY%\simulation +# && b2.exe --hash -j2 crypto=built-in %compiler% ) From 99148542281deca0d9527b4d9480f333548eedda Mon Sep 17 00:00:00 2001 From: arvidn Date: Sun, 23 Aug 2015 17:33:41 +0200 Subject: [PATCH 03/11] don't build x64 build on msvc-10, since appveyor doesn't seem to have that toolst installed --- appveyor.yml | 31 +++++++++++++++++++------------ 1 file changed, 19 insertions(+), 12 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index e32674573..77f424c17 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -8,6 +8,8 @@ environment: matrix: - variant: test_debug compiler: msvc-12.0 + x64: 1 + sim: 1 linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' include: '"c:\\openssl-1.0.1p-vs2013\\include"' @@ -23,11 +25,13 @@ environment: include: '"c:\\openssl-1.0.1p-vs2013\\include"' - variant: test_barebones compiler: msvc-12.0 + x64: 1 linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' include: '"c:\\openssl-1.0.1p-vs2013\\include"' - variant: test_release compiler: msvc-12.0 + x64: 1 linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' include: '"c:\\openssl-1.0.1p-vs2013\\include"' @@ -77,16 +81,19 @@ cache: - C:\openssl-1.0.1p-vs2013 - C:\openssl-1.0.1p-vs2010 build_script: -- type "C:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\vcvarsall.bat" x86_amd64 -#- cd %ROOT_DIRECTORY%\examples -#- b2.exe --hash -j2 %compiler% variant=%variant% linkflags=%linkflags32% include=%include% -#- cd %ROOT_DIRECTORY%\test -#- b2.exe --hash -j2 address-model=32 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags32% include=%include% -#- b2.exe --hash -j2 address-model=64 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags64% include=%include% -#- cd %ROOT_DIRECTORY%\bindings\python -#- b2.exe --hash -j2 %compiler% stage_module variant=%variant% linkflags=%linkflags32% include=%include% -#- python test.py -#- if %variant% == "test_debug" ( -# cd %ROOT_DIRECTORY%\simulation -# && b2.exe --hash -j2 crypto=built-in %compiler% ) +- cd %ROOT_DIRECTORY%\examples +- b2.exe --hash -j2 %compiler% variant=%variant% linkflags=%linkflags32% include=%include% +- cd %ROOT_DIRECTORY%\test +- b2.exe --hash -j2 address-model=32 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags32% include=%include% +- if defined x64 ( + b2.exe --hash -j2 address-model=64 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags64% include=%include% + ) +- cd %ROOT_DIRECTORY%\bindings\python +- b2.exe --hash -j2 %compiler% stage_module variant=%variant% linkflags=%linkflags32% include=%include% +- python test.py +- if defined sim ( + cd %ROOT_DIRECTORY%\simulation + && b2.exe --hash -j2 crypto=built-in %compiler% + ) + From 27c62a4929c33c1ff4c9cf07f709aa3f08f4ee03 Mon Sep 17 00:00:00 2001 From: arvidn Date: Sun, 23 Aug 2015 21:32:28 +0200 Subject: [PATCH 04/11] download separate 2015 openssl binaries. cache zipfile instead of uncompressed files --- appveyor.yml | 48 +++++++++++++++++++++++++++++------------------- 1 file changed, 29 insertions(+), 19 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index 77f424c17..e38684a03 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -20,9 +20,9 @@ environment: include: '"c:\\openssl-1.0.1p-vs2010\\include"' - variant: test_debug compiler: msvc-14.0 - linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' - linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' - include: '"c:\\openssl-1.0.1p-vs2013\\include"' + linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2015\\lib"' + linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2015\\lib64"' + include: '"c:\\openssl-1.0.1p-vs2015\\include"' - variant: test_barebones compiler: msvc-12.0 x64: 1 @@ -47,20 +47,30 @@ install: - git submodule update --init --recursive - set ROOT_DIRECTORY=%CD% - cd %ROOT_DIRECTORY% -- if not exist c:\openssl-1.0.1p-vs2013\nul ( +- if not exist openssl-1.0.1p-vs2013.7z ( appveyor DownloadFile http://www.npcglib.org/~stathis/downloads/openssl-1.0.1p-vs2013.7z - && 7z x -oc:\ -aoa openssl-1.0.1p-vs2013.7z - && copy c:\openssl-1.0.1p-vs2013\lib64\ssleay32MT.lib c:\openssl-1.0.1p-vs2013\lib64\ssleay32.lib - && copy c:\openssl-1.0.1p-vs2013\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2013\lib64\libeay32.lib - && copy c:\openssl-1.0.1p-vs2013\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2013\lib\ssleay32.lib - && copy c:\openssl-1.0.1p-vs2013\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2013\lib\libeay32.lib ) -- if not exist c:\openssl-1.0.1p-vs2010\nul ( + ) +- 7z x -oc:\ -aoa openssl-1.0.1p-vs2013.7z +- copy c:\openssl-1.0.1p-vs2013\lib64\ssleay32MT.lib c:\openssl-1.0.1p-vs2013\lib64\ssleay32.lib +- copy c:\openssl-1.0.1p-vs2013\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2013\lib64\libeay32.lib +- copy c:\openssl-1.0.1p-vs2013\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2013\lib\ssleay32.lib +- copy c:\openssl-1.0.1p-vs2013\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2013\lib\libeay32.lib +- if not exist openssl-1.0.1p-vs2010.7z ( appveyor DownloadFile http://www.npcglib.org/~stathis/downloads/openssl-1.0.1p-vs2010.7z - && 7z x -oc:\ -aoa openssl-1.0.1p-vs2010.7z - && copy c:\openssl-1.0.1p-vs2010\lib64\ssleay32MT.lib c:\openssl-1.0.1p-vs2010\lib64\ssleay32.lib - && copy c:\openssl-1.0.1p-vs2010\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2010\lib64\libeay32.lib - && copy c:\openssl-1.0.1p-vs2010\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2010\lib\ssleay32.lib - && copy c:\openssl-1.0.1p-vs2010\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2010\lib\libeay32.lib ) + ) +- 7z x -oc:\ -aoa openssl-1.0.1p-vs2010.7z +- copy c:\openssl-1.0.1p-vs2010\lib64\ssleay32MT.lib c:\openssl-1.0.1p-vs2010\lib64\ssleay32.lib +- copy c:\openssl-1.0.1p-vs2010\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2010\lib64\libeay32.lib +- copy c:\openssl-1.0.1p-vs2010\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2010\lib\ssleay32.lib +- copy c:\openssl-1.0.1p-vs2010\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2010\lib\libeay32.lib +- if not exist openssl-1.0.1p-vs2015.7z ( + appveyor DownloadFile http://www.npcglib.org/~stathis/downloads/openssl-1.0.1p-vs2015.7z + ) +- 7z x -oc:\ -aoa openssl-1.0.1p-vs2015.7z +- copy c:\openssl-1.0.1p-vs2015\lib64\ssleay32MT.lib c:\openssl-1.0.1p-vs2015\lib64\ssleay32.lib +- copy c:\openssl-1.0.1p-vs2015\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2015\lib64\libeay32.lib +- copy c:\openssl-1.0.1p-vs2015\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2015\lib\ssleay32.lib +- copy c:\openssl-1.0.1p-vs2015\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2015\lib\libeay32.lib - cd %ROOT_DIRECTORY% - set BOOST_ROOT=c:\Libraries\boost - set BOOST_BUILD_PATH=%BOOST_ROOT%\tools\build @@ -78,15 +88,16 @@ install: - python --version - echo %ROOT_DIRECTORY% cache: -- C:\openssl-1.0.1p-vs2013 -- C:\openssl-1.0.1p-vs2010 +- openssl-1.0.1p-vs2010.7z +- openssl-1.0.1p-vs2013.7z +- openssl-1.0.1p-vs2015.7z build_script: - cd %ROOT_DIRECTORY%\examples - b2.exe --hash -j2 %compiler% variant=%variant% linkflags=%linkflags32% include=%include% - cd %ROOT_DIRECTORY%\test - b2.exe --hash -j2 address-model=32 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags32% include=%include% - if defined x64 ( - b2.exe --hash -j2 address-model=64 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags64% include=%include% + b2.exe --hash -j2 address-model=64 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags64% include=%include% ) - cd %ROOT_DIRECTORY%\bindings\python - b2.exe --hash -j2 %compiler% stage_module variant=%variant% linkflags=%linkflags32% include=%include% @@ -96,4 +107,3 @@ build_script: && b2.exe --hash -j2 crypto=built-in %compiler% ) - From 2d1bb2449015d9f6e52dbf09308ac24e95490551 Mon Sep 17 00:00:00 2001 From: arvidn Date: Sun, 23 Aug 2015 22:22:20 +0200 Subject: [PATCH 05/11] attempt to only download/extract the version of openssl that we're using --- appveyor.yml | 48 +++++++++++++++++++++++++++--------------------- 1 file changed, 27 insertions(+), 21 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index e38684a03..d715a2240 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -47,30 +47,36 @@ install: - git submodule update --init --recursive - set ROOT_DIRECTORY=%CD% - cd %ROOT_DIRECTORY% -- if not exist openssl-1.0.1p-vs2013.7z ( - appveyor DownloadFile http://www.npcglib.org/~stathis/downloads/openssl-1.0.1p-vs2013.7z +- if %compiler% == msvc-12.0 ( + if not exist openssl-1.0.1p-vs2013.7z ( + appveyor DownloadFile http://www.npcglib.org/~stathis/downloads/openssl-1.0.1p-vs2013.7z + ) + & 7z x -oc:\ -aoa openssl-1.0.1p-vs2013.7z + & copy c:\openssl-1.0.1p-vs2013\lib64\ssleay32MT.lib c:\openssl-1.0.1p-vs2013\lib64\ssleay32.lib + & copy c:\openssl-1.0.1p-vs2013\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2013\lib64\libeay32.lib + & copy c:\openssl-1.0.1p-vs2013\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2013\lib\ssleay32.lib + & copy c:\openssl-1.0.1p-vs2013\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2013\lib\libeay32.lib ) -- 7z x -oc:\ -aoa openssl-1.0.1p-vs2013.7z -- copy c:\openssl-1.0.1p-vs2013\lib64\ssleay32MT.lib c:\openssl-1.0.1p-vs2013\lib64\ssleay32.lib -- copy c:\openssl-1.0.1p-vs2013\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2013\lib64\libeay32.lib -- copy c:\openssl-1.0.1p-vs2013\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2013\lib\ssleay32.lib -- copy c:\openssl-1.0.1p-vs2013\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2013\lib\libeay32.lib -- if not exist openssl-1.0.1p-vs2010.7z ( - appveyor DownloadFile http://www.npcglib.org/~stathis/downloads/openssl-1.0.1p-vs2010.7z +- if %compiler% == msvc-10.0 ( + if not exist openssl-1.0.1p-vs2010.7z ( + appveyor DownloadFile http://www.npcglib.org/~stathis/downloads/openssl-1.0.1p-vs2010.7z + ) + & 7z x -oc:\ -aoa openssl-1.0.1p-vs2010.7z + & copy c:\openssl-1.0.1p-vs2010\lib64\ssleay32MT.lib c:\openssl-1.0.1p-vs2010\lib64\ssleay32.lib + & copy c:\openssl-1.0.1p-vs2010\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2010\lib64\libeay32.lib + & copy c:\openssl-1.0.1p-vs2010\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2010\lib\ssleay32.lib + & copy c:\openssl-1.0.1p-vs2010\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2010\lib\libeay32.lib ) -- 7z x -oc:\ -aoa openssl-1.0.1p-vs2010.7z -- copy c:\openssl-1.0.1p-vs2010\lib64\ssleay32MT.lib c:\openssl-1.0.1p-vs2010\lib64\ssleay32.lib -- copy c:\openssl-1.0.1p-vs2010\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2010\lib64\libeay32.lib -- copy c:\openssl-1.0.1p-vs2010\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2010\lib\ssleay32.lib -- copy c:\openssl-1.0.1p-vs2010\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2010\lib\libeay32.lib -- if not exist openssl-1.0.1p-vs2015.7z ( - appveyor DownloadFile http://www.npcglib.org/~stathis/downloads/openssl-1.0.1p-vs2015.7z +- if %compiler% == msvc-14.0 ( + if not exist openssl-1.0.1p-vs2015.7z ( + appveyor DownloadFile http://www.npcglib.org/~stathis/downloads/openssl-1.0.1p-vs2015.7z + ) + & 7z x -oc:\ -aoa openssl-1.0.1p-vs2015.7z + & copy c:\openssl-1.0.1p-vs2015\lib64\ssleay32MT.lib c:\openssl-1.0.1p-vs2015\lib64\ssleay32.lib + & copy c:\openssl-1.0.1p-vs2015\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2015\lib64\libeay32.lib + & copy c:\openssl-1.0.1p-vs2015\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2015\lib\ssleay32.lib + & copy c:\openssl-1.0.1p-vs2015\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2015\lib\libeay32.lib ) -- 7z x -oc:\ -aoa openssl-1.0.1p-vs2015.7z -- copy c:\openssl-1.0.1p-vs2015\lib64\ssleay32MT.lib c:\openssl-1.0.1p-vs2015\lib64\ssleay32.lib -- copy c:\openssl-1.0.1p-vs2015\lib64\libeay32MT.lib c:\openssl-1.0.1p-vs2015\lib64\libeay32.lib -- copy c:\openssl-1.0.1p-vs2015\lib\ssleay32MT.lib c:\openssl-1.0.1p-vs2015\lib\ssleay32.lib -- copy c:\openssl-1.0.1p-vs2015\lib\libeay32MT.lib c:\openssl-1.0.1p-vs2015\lib\libeay32.lib - cd %ROOT_DIRECTORY% - set BOOST_ROOT=c:\Libraries\boost - set BOOST_BUILD_PATH=%BOOST_ROOT%\tools\build From 376126d04d3981e499e3fae03215a06da25a9193 Mon Sep 17 00:00:00 2001 From: arvidn Date: Sun, 23 Aug 2015 23:19:18 +0200 Subject: [PATCH 06/11] msvc-12 doesn't support default move constructors (simulator requires that). use msvc-14 --- appveyor.yml | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index d715a2240..5fb8afd72 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -7,9 +7,15 @@ clone_depth: 1 environment: matrix: - variant: test_debug - compiler: msvc-12.0 + compiler: msvc-14.0 x64: 1 sim: 1 + linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2015\\lib"' + linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2015\\lib64"' + include: '"c:\\openssl-1.0.1p-vs2015\\include"' + - variant: test_debug + compiler: msvc-12.0 + x64: 1 linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' include: '"c:\\openssl-1.0.1p-vs2013\\include"' @@ -18,11 +24,6 @@ environment: linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2010\\lib"' linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2010\\lib64"' include: '"c:\\openssl-1.0.1p-vs2010\\include"' - - variant: test_debug - compiler: msvc-14.0 - linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2015\\lib"' - linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2015\\lib64"' - include: '"c:\\openssl-1.0.1p-vs2015\\include"' - variant: test_barebones compiler: msvc-12.0 x64: 1 @@ -110,6 +111,6 @@ build_script: - python test.py - if defined sim ( cd %ROOT_DIRECTORY%\simulation - && b2.exe --hash -j2 crypto=built-in %compiler% + && b2.exe --hash -j2 link=shared crypto=built-in %compiler% ) From 434be2bd837fa8cdcf75cc6d5873b73ae5de64ac Mon Sep 17 00:00:00 2001 From: arvidn Date: Wed, 26 Aug 2015 07:35:44 -0400 Subject: [PATCH 07/11] add more logging around the test failure --- src/thread.cpp | 2 +- test/swarm_suite.cpp | 14 +++++++++++--- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/src/thread.cpp b/src/thread.cpp index 1dd80c748..42736c69d 100644 --- a/src/thread.cpp +++ b/src/thread.cpp @@ -167,7 +167,7 @@ namespace libtorrent l.lock(); --m_num_waiters; } - + void condition_variable::wait_for(mutex::scoped_lock& l, time_duration rel_time) { TORRENT_ASSERT(l.locked()); diff --git a/test/swarm_suite.cpp b/test/swarm_suite.cpp index 2f3efd19a..1535f00d9 100644 --- a/test/swarm_suite.cpp +++ b/test/swarm_suite.cpp @@ -211,23 +211,31 @@ void test_swarm(int flags) alert const* ret; while ((ret = ses1.wait_for_alert(seconds(2)))) { + fprintf(stderr, "wait returned: %d ms\n" + , total_milliseconds(clock_type::now() - start)); std::vector alerts; ses1.pop_alerts(&alerts); for (std::vector::iterator i = alerts.begin() , end(alerts.end()); i != end; ++i) { - std::cerr << ret->message() << std::endl; + fprintf(stderr, "%s\n", ret->message().c_str()); } start = clock_type::now(); } + fprintf(stderr, "loop returned: %d ms\n" + , total_milliseconds(clock_type::now() - start)); + // this allows shutting down the sessions in parallel p1 = ses1.abort(); p2 = ses2.abort(); p3 = ses3.abort(); - TEST_CHECK(clock_type::now() - start < seconds(3)); - TEST_CHECK(clock_type::now() - start >= seconds(2)); + time_point end = clock_type::now(); + + fprintf(stderr, "time: %d ms\n", total_milliseconds(end - start)); + TEST_CHECK(end - start < seconds(3)); + TEST_CHECK(end - start >= seconds(2)); TEST_CHECK(!exists("tmp1_swarm/temporary")); TEST_CHECK(!exists("tmp2_swarm/temporary")); From 8830d61ccab3d7bb24c4e45c3b4c6ac74b9edea4 Mon Sep 17 00:00:00 2001 From: arvidn Date: Wed, 26 Aug 2015 21:06:02 -0400 Subject: [PATCH 08/11] exclude test_utp to be run on appveyor --- test/Jamfile | 1 - 1 file changed, 1 deletion(-) diff --git a/test/Jamfile b/test/Jamfile index 364baf59f..0379bb67f 100644 --- a/test/Jamfile +++ b/test/Jamfile @@ -193,7 +193,6 @@ test-suite libtorrent : alias win-tests : test_primitives test_pe_crypto - test_utp test_remap_files test_auto_unchoke test_torrent From e3591c3a1cca7805f433f48301d67e820a10a3a1 Mon Sep 17 00:00:00 2001 From: arvidn Date: Wed, 26 Aug 2015 21:47:20 -0400 Subject: [PATCH 09/11] attempt to log more and potentially fix wait_for_downloading in unit tests --- test/setup_transfer.cpp | 10 +++++++++- test/swarm_suite.cpp | 6 +++--- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/test/setup_transfer.cpp b/test/setup_transfer.cpp index 4779171ed..f535d1d26 100644 --- a/test/setup_transfer.cpp +++ b/test/setup_transfer.cpp @@ -335,14 +335,22 @@ bool downloading_alert(libtorrent::alert const* a) void wait_for_downloading(lt::session& ses, char const* name) { + time_point start = clock_type::now(); downloading_done = false; alert const* a = 0; do { print_alerts(ses, name, true, true, true, &downloading_alert, false); if (downloading_done) break; - a = ses.wait_for_alert(milliseconds(500)); + if (total_seconds(clock_type::now() - start) > 10) break; + a = ses.wait_for_alert(seconds(2)); } while (a); + if (!downloading_done) + { + fprintf(stderr, "did not receive a state_changed_alert indicating " + "the torrent is downloading. waited: %d ms\n" + , int(total_milliseconds(clock_type::now() - start))); + } } void print_ses_rate(float time diff --git a/test/swarm_suite.cpp b/test/swarm_suite.cpp index 1535f00d9..d8c781443 100644 --- a/test/swarm_suite.cpp +++ b/test/swarm_suite.cpp @@ -212,7 +212,7 @@ void test_swarm(int flags) while ((ret = ses1.wait_for_alert(seconds(2)))) { fprintf(stderr, "wait returned: %d ms\n" - , total_milliseconds(clock_type::now() - start)); + , int(total_milliseconds(clock_type::now() - start))); std::vector alerts; ses1.pop_alerts(&alerts); for (std::vector::iterator i = alerts.begin() @@ -224,7 +224,7 @@ void test_swarm(int flags) } fprintf(stderr, "loop returned: %d ms\n" - , total_milliseconds(clock_type::now() - start)); + , int(total_milliseconds(clock_type::now() - start))); // this allows shutting down the sessions in parallel p1 = ses1.abort(); @@ -233,7 +233,7 @@ void test_swarm(int flags) time_point end = clock_type::now(); - fprintf(stderr, "time: %d ms\n", total_milliseconds(end - start)); + fprintf(stderr, "time: %d ms\n", int(total_milliseconds(end - start))); TEST_CHECK(end - start < seconds(3)); TEST_CHECK(end - start >= seconds(2)); From 1cd6fe6c0136876c89157ccfd9a9a754519f5ae9 Mon Sep 17 00:00:00 2001 From: arvidn Date: Wed, 26 Aug 2015 23:51:31 -0400 Subject: [PATCH 10/11] attempt to split out x64 tests since appveyor only allows 40 minutes of runtime --- appveyor.yml | 29 +++++++++++++++++++---------- 1 file changed, 19 insertions(+), 10 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index 5fb8afd72..48b549d10 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -8,14 +8,18 @@ environment: matrix: - variant: test_debug compiler: msvc-14.0 - x64: 1 sim: 1 linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2015\\lib"' linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2015\\lib64"' include: '"c:\\openssl-1.0.1p-vs2015\\include"' - variant: test_debug - compiler: msvc-12.0 + compiler: msvc-14.0 x64: 1 + linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2015\\lib"' + linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2015\\lib64"' + include: '"c:\\openssl-1.0.1p-vs2015\\include"' + - variant: test_debug + compiler: msvc-12.0 linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' include: '"c:\\openssl-1.0.1p-vs2013\\include"' @@ -24,6 +28,11 @@ environment: linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2010\\lib"' linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2010\\lib64"' include: '"c:\\openssl-1.0.1p-vs2010\\include"' + - variant: test_barebones + compiler: msvc-12.0 + linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' + linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' + include: '"c:\\openssl-1.0.1p-vs2013\\include"' - variant: test_barebones compiler: msvc-12.0 x64: 1 @@ -32,7 +41,6 @@ environment: include: '"c:\\openssl-1.0.1p-vs2013\\include"' - variant: test_release compiler: msvc-12.0 - x64: 1 linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' include: '"c:\\openssl-1.0.1p-vs2013\\include"' @@ -99,18 +107,19 @@ cache: - openssl-1.0.1p-vs2013.7z - openssl-1.0.1p-vs2015.7z build_script: -- cd %ROOT_DIRECTORY%\examples -- b2.exe --hash -j2 %compiler% variant=%variant% linkflags=%linkflags32% include=%include% - cd %ROOT_DIRECTORY%\test -- b2.exe --hash -j2 address-model=32 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags32% include=%include% - if defined x64 ( b2.exe --hash -j2 address-model=64 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags64% include=%include% + ) else ( + b2.exe --hash -j2 address-model=32 win-tests %compiler% variant=%variant% link=shared linkflags=%linkflags32% include=%include% + & cd %ROOT_DIRECTORY%\examples + & b2.exe --hash -j2 %compiler% variant=%variant% linkflags=%linkflags32% include=%include% + & cd %ROOT_DIRECTORY%\bindings\python + & b2.exe --hash -j2 %compiler% stage_module variant=%variant% linkflags=%linkflags32% include=%include% + & python test.py ) -- cd %ROOT_DIRECTORY%\bindings\python -- b2.exe --hash -j2 %compiler% stage_module variant=%variant% linkflags=%linkflags32% include=%include% -- python test.py - if defined sim ( cd %ROOT_DIRECTORY%\simulation - && b2.exe --hash -j2 link=shared crypto=built-in %compiler% + & b2.exe --hash -j2 link=shared crypto=built-in %compiler% ) From 293b60075e55188f1230396797a4bf7ffac58954 Mon Sep 17 00:00:00 2001 From: arvidn Date: Sat, 29 Aug 2015 16:38:45 -0400 Subject: [PATCH 11/11] try to switch to 64 bit build of bjam. build 64 bit only under msvc-12 for now --- appveyor.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index 48b549d10..033854abf 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -13,11 +13,11 @@ environment: linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2015\\lib64"' include: '"c:\\openssl-1.0.1p-vs2015\\include"' - variant: test_debug - compiler: msvc-14.0 + compiler: msvc-12.0 x64: 1 - linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2015\\lib"' - linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2015\\lib64"' - include: '"c:\\openssl-1.0.1p-vs2015\\include"' + linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"' + linkflags64: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib64"' + include: '"c:\\openssl-1.0.1p-vs2013\\include"' - variant: test_debug compiler: msvc-12.0 linkflags32: '"/LIBPATH:C:\\openssl-1.0.1p-vs2013\\lib"'