appveyor.yml 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. image:
  2. - Visual Studio 2017
  3. platform:
  4. - x64
  5. - x86
  6. environment:
  7. fast_finish: true
  8. matrix:
  9. - VSVER: 15
  10. configuration:
  11. - shared
  12. - plain
  13. - minimal
  14. before_build:
  15. - ps: >-
  16. Install-Module VSSetup -Scope CurrentUser
  17. - ps: >-
  18. Get-VSSetupInstance -All
  19. - ps: >-
  20. If ($env:Platform -Match "x86") {
  21. $env:VCVARS_PLATFORM="x86"
  22. $env:TARGET="VC-WIN32 no-asm --strict-warnings"
  23. } Else {
  24. $env:VCVARS_PLATFORM="amd64"
  25. $env:TARGET="VC-WIN64A-masm"
  26. }
  27. - ps: >-
  28. If ($env:Configuration -Match "shared") {
  29. $env:CONFIG_OPTS=""
  30. } ElseIf ($env:Configuration -Match "minimal") {
  31. $env:CONFIG_OPTS="no-bulk no-asm -DOPENSSL_SMALL_FOOTPRINT"
  32. } Else {
  33. $env:CONFIG_OPTS="no-shared"
  34. }
  35. - call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" %VCVARS_PLATFORM%
  36. - mkdir _build
  37. - cd _build
  38. - perl ..\Configure %TARGET% no-makedepend %CONFIG_OPTS%
  39. - perl configdata.pm --dump
  40. - cd ..
  41. - ps: >-
  42. If (-not $env:APPVEYOR_PULL_REQUEST_NUMBER`
  43. -or (&git log -1 $env:APPVEYOR_PULL_REQUEST_HEAD_COMMIT |
  44. Select-String "\[extended tests\]") ) {
  45. $env:EXTENDED_TESTS="yes"
  46. }
  47. - ps: >-
  48. If ($env:BUILDONLY -or $env:MAKEVERBOSE) {
  49. $env:NMAKE="nmake"
  50. } Else {
  51. $env:NMAKE="nmake /S"
  52. }
  53. - ps: >-
  54. gci env:* | sort-object name
  55. build_script:
  56. - cd _build
  57. - ps: >-
  58. If ($env:Configuration -Match "shared" -or $env:EXTENDED_TESTS) {
  59. cmd /c "%NMAKE% build_all_generated 2>&1"
  60. # Unfortunately, CL=/MP would not have parallelizing effect
  61. cmd /c "%NMAKE% PERL=no-perl 2>&1"
  62. }
  63. - cd ..
  64. test_script:
  65. - cd _build
  66. - ps: >-
  67. If ($env:Configuration -Match "shared" -or $env:EXTENDED_TESTS) {
  68. # Unfortunately, HARNESS_JOBS=4 would not have parallelizing effect
  69. if ($env:EXTENDED_TESTS) {
  70. cmd /c "%NMAKE% test HARNESS_VERBOSE_FAILURE=yes 2>&1"
  71. } Else {
  72. cmd /c "%NMAKE% test HARNESS_VERBOSE_FAILURE=yes TESTS=-test_fuzz 2>&1"
  73. }
  74. }
  75. - ps: >-
  76. if ($env:EXTENDED_TESTS) {
  77. mkdir ..\_install
  78. cmd /c "%NMAKE% install DESTDIR=..\_install 2>&1"
  79. }
  80. - cd ..