summaryrefslogtreecommitdiff
path: root/.azure-pipelines.yml
blob: 91451198fae2b30cce22f2339a10a40dfad05784 (plain)
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
#***************************************************************************
#                                  _   _ ____  _
#  Project                     ___| | | |  _ \| |
#                             / __| | | | |_) | |
#                            | (__| |_| |  _ <| |___
#                             \___|\___/|_| \_\_____|
#
# Copyright (C) 1998 - 2020, Daniel Stenberg, <daniel@haxx.se>, et al.
#
# This software is licensed as described in the file COPYING, which
# you should have received as part of this distribution. The terms
# are also available at https://curl.haxx.se/docs/copyright.html.
#
# You may opt to use, copy, modify, merge, publish, distribute and/or sell
# copies of the Software, and permit persons to whom the Software is
# furnished to do so, under the terms of the COPYING file.
#
# This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
# KIND, either express or implied.
#
###########################################################################
# Starter pipeline
# Start with a minimal pipeline that you can customize to build and deploy your code.
# Add steps that build, run tests, deploy, and more:
# https://aka.ms/yaml

trigger:
  branches:
    include:
    - 'master'
    - '*/ci'

pr:
  branches:
    include:
    - 'master'

stages:

##########################################
### Linux jobs first
##########################################

- stage: linux
  dependsOn: []
  jobs:
  - job: ubuntu
    # define defaults to make sure variables are always expanded/replaced
    variables:
      install: ''
      configure: ''
      tflags: ''
    timeoutInMinutes: 60
    pool:
      vmImage: 'ubuntu-latest'
    strategy:
      matrix:
        default:
          name: default
          configure: --enable-debug --enable-werror
        disable_ipv6:
          name: w/o IPv6
          configure: --disable-ipv6
        disable_http_smtp_imap:
          name: w/o HTTP/SMTP/IMAP
          configure: --disable-http --disable-smtp --disable-imap
        disable_thredres:
          name: sync resolver
          configure: --disable-threaded-resolver
        http_only:
          name: HTTP only
          configure: --disable-dict --disable-file --disable-ftp --disable-gopher --disable-imap --disable-ldap --disable-pop3 --disable-rtmp --disable-rtsp --disable-scp --disable-sftp --disable-smb --disable-smtp --disable-telnet --disable-tftp
        torture:
          name: torture
          install: libnghttp2-dev
          configure: --enable-debug --disable-shared --disable-threaded-resolver --enable-alt-svc
          tflags: -n -t --shallow=40 !FTP
    steps:
    - script: sudo apt-get update && sudo apt-get install -y stunnel4 python-impacket libzstd-dev libbrotli-dev $(install)
      displayName: 'apt install'

    - script: ./buildconf && ./configure $(configure)
      displayName: 'configure $(name)'

    - script: make
      displayName: 'make'

    - script: make test-nonflaky
      displayName: 'test'
      env:
        AZURE_ACCESS_TOKEN: "$(System.AccessToken)"
        TFLAGS: "$(tflags)"

##########################################
### Windows jobs below
##########################################

- stage: windows
  dependsOn: []
  variables:
    agent.preferPowerShellOnContainers: true
  jobs:
  - job: windows
    # define defaults to make sure variables are always expanded/replaced
    variables:
      container_img: ''
      container_cmd: ''
      configure: ''
      tflags: ''
    timeoutInMinutes: 90
    pool:
      vmImage: 'windows-2019'
    strategy:
      matrix:
        msys2_mingw32_debug_openssl:
          name: 32-bit OpenSSL and MQTT
          container_img: mback2k/curl-docker-winbuildenv-msys2-mingw32:ltsc2019
          container_cmd: C:\msys64\usr\bin\sh
          configure: --host=i686-w64-mingw32 --build=i686-w64-mingw32 --prefix=/mingw32 --enable-debug --enable-werror --enable-mqtt
          tflags: ~1056 ~1299
        msys2_mingw64_debug_openssl:
          name: 64-bit OpenSSL and MQTT
          container_img: mback2k/curl-docker-winbuildenv-msys2-mingw64:ltsc2019
          container_cmd: C:\msys64\usr\bin\sh
          configure: --host=x86_64-w64-mingw32 --build=x86_64-w64-mingw32 --prefix=/mingw64 --enable-debug --enable-werror --enable-mqtt
          tflags: ~1056 ~1299
        msys1_mingw_debug_openssl:
          name: 32-bit OpenSSL (legacy)
          container_img: mback2k/curl-docker-winbuildenv-msys1-mingw:ltsc2019
          container_cmd: C:\MinGW\msys\1.0\bin\sh
          configure: --host=i686-pc-mingw32 --build=i686-pc-mingw32 --prefix=/mingw --enable-debug
          tflags: ~203 ~1056 ~1143
        msys1_mingw32_debug_openssl:
          name: 32-bit OpenSSL w/o zlib
          container_img: mback2k/curl-docker-winbuildenv-msys1-mingw32:ltsc2019
          container_cmd: C:\MinGW\msys\1.0\bin\sh
          configure: --host=i686-w64-mingw32 --build=i686-w64-mingw32 --prefix=/mingw32 --enable-debug --enable-werror --without-zlib
          tflags: ~203 ~1056 ~1143 ~1299
        msys1_mingw64_debug_openssl:
          name: 64-bit OpenSSL w/o zlib
          container_img: mback2k/curl-docker-winbuildenv-msys1-mingw64:ltsc2019
          container_cmd: C:\MinGW\msys\1.0\bin\sh
          configure: --host=x86_64-w64-mingw32 --build=x86_64-w64-mingw32 --prefix=/mingw64 --enable-debug --enable-werror --without-zlib
          tflags: ~203 ~1056 ~1143 ~1299
        msys2_mingw32_debug_schannel:
          name: 32-bit Schannel/SSPI/WinIDN
          container_img: mback2k/curl-docker-winbuildenv-msys2-mingw32:ltsc2019
          container_cmd: C:\msys64\usr\bin\sh
          configure: --host=i686-w64-mingw32 --build=i686-w64-mingw32 --prefix=/mingw32 --enable-debug --enable-werror --enable-sspi --without-ssl --with-schannel --with-winidn
          tflags: ~165 ~310 ~1013 ~1056 ~1299 ~1448 ~2034 ~2037 ~2041 ~2046 ~2047 ~3000 ~3001
        msys2_mingw64_debug_schannel:
          name: 64-bit Schannel/SSPI/WinIDN
          container_img: mback2k/curl-docker-winbuildenv-msys2-mingw64:ltsc2019
          container_cmd: C:\msys64\usr\bin\sh
          configure: --host=x86_64-w64-mingw32 --build=x86_64-w64-mingw32 --prefix=/mingw64 --enable-debug --enable-werror --enable-sspi --without-ssl --with-schannel --with-winidn
          tflags: ~165 ~310 ~1013 ~1056 ~1299 ~1448 ~2034 ~2037 ~2041 ~2046 ~2047 ~3000 ~3001
        msys1_mingw_debug_schannel:
          name: 32-bit Schannel/SSPI/WinIDN (legacy)
          container_img: mback2k/curl-docker-winbuildenv-msys1-mingw:ltsc2019
          container_cmd: C:\MinGW\msys\1.0\bin\sh
          configure: --host=i686-pc-mingw32 --build=i686-pc-mingw32 --prefix=/mingw --enable-debug --enable-sspi --without-ssl --with-schannel --with-winidn
          tflags: ~203 ~305 ~310 ~311 ~312 ~313 ~404 ~1013 ~1056 ~1143 ~2034 ~2035 ~2037 ~2038 ~2041 ~2042 ~2048 ~3000 ~3001
        msys1_mingw32_debug_schannel:
          name: 32-bit Schannel/SSPI/WinIDN w/o zlib
          container_img: mback2k/curl-docker-winbuildenv-msys1-mingw32:ltsc2019
          container_cmd: C:\MinGW\msys\1.0\bin\sh
          configure: --host=i686-w64-mingw32 --build=i686-w64-mingw32 --prefix=/mingw32 --enable-debug --enable-werror --enable-sspi --without-ssl --with-schannel --with-winidn --without-zlib
          tflags: ~203 ~310 ~1013 ~1056 ~1143 ~1299 ~2034 ~2037 ~2041 ~3000 ~3001
        msys1_mingw64_debug_schannel:
          name: 64-bit Schannel/SSPI/WinIDN w/o zlib
          container_img: mback2k/curl-docker-winbuildenv-msys1-mingw64:ltsc2019
          container_cmd: C:\MinGW\msys\1.0\bin\sh
          configure: --host=x86_64-w64-mingw32 --build=x86_64-w64-mingw32 --prefix=/mingw64  --enable-debug --enable-werror --enable-sspi --without-ssl --with-schannel --with-winidn --without-zlib
          tflags: ~203 ~310 ~1013 ~1056 ~1143 ~1299 ~2034 ~2037 ~2041 ~3000 ~3001
    container:
      image: $(container_img)
      env:
        MSYS2_PATH_TYPE: inherit
    steps:
    - script: $(container_cmd) -l -c "cd $(echo '%cd%') && ./buildconf && ./configure $(configure)"
      displayName: 'configure $(name)'

    - script: $(container_cmd) -l -c "cd $(echo '%cd%') && make"
      displayName: 'make'

    - script: $(container_cmd) -l -c "cd $(echo '%cd%') && make test-nonflaky"
      displayName: 'test'
      env:
        AZURE_ACCESS_TOKEN: "$(System.AccessToken)"
        TFLAGS: "$(tflags)"