Merge pull request #5451 from pks-t/pks/docker-curl azure: fix errors due to curl and removal of old VM images
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 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399
diff --git a/azure-pipelines.yml b/azure-pipelines.yml
index 2575f47..20335b3 100644
--- a/azure-pipelines.yml
+++ b/azure-pipelines.yml
@@ -9,7 +9,7 @@ jobs:
- job: linux_amd64_xenial_gcc_openssl
displayName: 'Linux (amd64; Xenial; GCC; OpenSSL)'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- template: azure-pipelines/docker.yml
parameters:
@@ -25,7 +25,7 @@ jobs:
- job: linux_amd64_xenial_gcc_mbedtls
displayName: 'Linux (amd64; Xenial; GCC; mbedTLS)'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- template: azure-pipelines/docker.yml
parameters:
@@ -41,7 +41,7 @@ jobs:
- job: linux_amd64_xenial_clang_openssl
displayName: 'Linux (amd64; Xenial; Clang; OpenSSL)'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- template: azure-pipelines/docker.yml
parameters:
@@ -57,7 +57,7 @@ jobs:
- job: linux_amd64_xenial_clang_mbedtls
displayName: 'Linux (amd64; Xenial; Clang; mbedTLS)'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- template: azure-pipelines/docker.yml
parameters:
@@ -71,9 +71,9 @@ jobs:
GITTEST_NEGOTIATE_PASSWORD=${{ variables.GITTEST_NEGOTIATE_PASSWORD }}
- job: macos
- displayName: 'macOS'
+ displayName: 'macOS (amd64; 10.15)'
pool:
- vmImage: 'macOS 10.13'
+ vmImage: 'macOS-10.15'
steps:
- bash: . '$(Build.SourcesDirectory)/azure-pipelines/setup-osx.sh'
displayName: Setup
@@ -89,31 +89,34 @@ jobs:
- job: windows_vs_amd64
displayName: 'Windows (amd64; Visual Studio)'
- pool: Hosted
+ pool:
+ vmImage: 'vs2017-win2016'
steps:
- template: azure-pipelines/bash.yml
parameters:
environmentVariables:
- CMAKE_GENERATOR: Visual Studio 12 2013 Win64
- CMAKE_OPTIONS: -DMSVC_CRTDBG=ON -DDEPRECATE_HARD=ON
+ CMAKE_GENERATOR: Visual Studio 15 2017
+ CMAKE_OPTIONS: -A x64 -DMSVC_CRTDBG=ON -DDEPRECATE_HARD=ON
SKIP_SSH_TESTS: true
SKIP_NEGOTIATE_TESTS: true
- job: windows_vs_x86
displayName: 'Windows (x86; Visual Studio)'
- pool: Hosted
+ pool:
+ vmImage: 'vs2017-win2016'
steps:
- template: azure-pipelines/bash.yml
parameters:
environmentVariables:
- CMAKE_GENERATOR: Visual Studio 12 2013
- CMAKE_OPTIONS: -DMSVC_CRTDBG=ON -DDEPRECATE_HARD=ON -DUSE_SHA1=HTTPS
+ CMAKE_GENERATOR: Visual Studio 15 2017
+ CMAKE_OPTIONS: -A Win32 -DMSVC_CRTDBG=ON -DDEPRECATE_HARD=ON -DUSE_SHA1=HTTPS
SKIP_SSH_TESTS: true
SKIP_NEGOTIATE_TESTS: true
- job: windows_mingw_amd64
displayName: 'Windows (amd64; MinGW)'
- pool: Hosted
+ pool:
+ vmImage: 'vs2017-win2016'
steps:
- bash: . '$(Build.SourcesDirectory)\azure-pipelines\setup-mingw.sh'
displayName: Setup
@@ -131,7 +134,8 @@ jobs:
- job: windows_mingw_x86
displayName: 'Windows (x86; MinGW)'
- pool: Hosted
+ pool:
+ vmImage: 'vs2017-win2016'
steps:
- bash: . '$(Build.SourcesDirectory)\azure-pipelines\setup-mingw.sh'
displayName: Setup
@@ -151,7 +155,7 @@ jobs:
- job: documentation
displayName: 'Generate Documentation'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- script: |
cd $(Build.SourcesDirectory)/azure-pipelines/docker
diff --git a/azure-pipelines/coverity.sh b/azure-pipelines/coverity.sh
index 14faadc..c68b6f8 100755
--- a/azure-pipelines/coverity.sh
+++ b/azure-pipelines/coverity.sh
@@ -25,7 +25,7 @@ TOOL_DIR=${BUILD_DIR}/coverity-tools
if ! test -d "$TOOL_DIR"
then
mkdir -p "$TOOL_DIR"
- curl --silent --location --data "project=libgit2&token=$COVERITY_TOKEN" "$SCAN_TOOL" |
+ curl --silent --show-error --location --data "project=libgit2&token=$COVERITY_TOKEN" "$SCAN_TOOL" |
tar -xzC "$TOOL_DIR"
ln -s "$(find "$TOOL_DIR" -type d -name 'cov-analysis*')" "$TOOL_DIR"/cov-analysis
fi
@@ -44,7 +44,7 @@ COVERITY_UNSUPPORTED=1 \
tar -czf libgit2.tgz cov-int
REVISION=$(cd ${SOURCE_DIR} && git rev-parse --short HEAD)
HTML="$(curl \
- --silent \
+ --silent --show-error \
--write-out "\n%{http_code}" \
--form token="$COVERITY_TOKEN" \
--form email=libgit2@gmail.com \
diff --git a/azure-pipelines/coverity.yml b/azure-pipelines/coverity.yml
index 10450af..a8747db 100644
--- a/azure-pipelines/coverity.yml
+++ b/azure-pipelines/coverity.yml
@@ -5,7 +5,7 @@ jobs:
- job: coverity
displayName: 'Coverity'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- script: |
cd $(Build.SourcesDirectory)/azure-pipelines/docker
diff --git a/azure-pipelines/docker/bionic b/azure-pipelines/docker/bionic
index 33175a0..65a1406 100644
--- a/azure-pipelines/docker/bionic
+++ b/azure-pipelines/docker/bionic
@@ -25,9 +25,7 @@ RUN apt-get update && \
FROM apt AS mbedtls
RUN cd /tmp && \
- curl --location http://secure.globalsign.com/cacert/gsrsaovsslca2018.crt | openssl x509 -inform der -out /tmp/cacert.pem && \
- curl --location https://curl.haxx.se/ca/cacert.pem >> /tmp/cacert.pem && \
- curl --location --silent https://tls.mbed.org/download/mbedtls-2.16.2-apache.tgz --cacert /tmp/cacert.pem | \
+ curl --location --silent --show-error https://tls.mbed.org/download/mbedtls-2.16.2-apache.tgz | \
tar -xz && \
cd mbedtls-2.16.2 && \
scripts/config.pl set MBEDTLS_MD4_C 1 && \
diff --git a/azure-pipelines/docker/docurium b/azure-pipelines/docker/docurium
index 15d10a7..54a4202 100644
--- a/azure-pipelines/docker/docurium
+++ b/azure-pipelines/docker/docurium
@@ -1,6 +1,3 @@
-FROM debian:jessie-slim
-ARG CACHEBUST=1
-RUN apt-get update
-RUN apt install -y cmake pkg-config ruby ruby-dev llvm libclang-3.5-dev libssl-dev python-pygments
-ARG CACHEBUST=1
+FROM ubuntu:bionic
+RUN apt update && apt install -y cmake pkg-config ruby ruby-dev llvm libclang-dev libssl-dev python-pygments
RUN gem install docurium
diff --git a/azure-pipelines/docker/xenial b/azure-pipelines/docker/xenial
index 475956f..bfb96d9 100644
--- a/azure-pipelines/docker/xenial
+++ b/azure-pipelines/docker/xenial
@@ -29,9 +29,7 @@ RUN apt-get update && \
FROM apt AS mbedtls
RUN cd /tmp && \
- curl --location http://secure.globalsign.com/cacert/gsrsaovsslca2018.crt | openssl x509 -inform der -out /tmp/cacert.pem && \
- curl --location https://curl.haxx.se/ca/cacert.pem >> /tmp/cacert.pem && \
- curl --location --silent https://tls.mbed.org/download/mbedtls-2.16.2-apache.tgz --cacert /tmp/cacert.pem | \
+ curl --location --silent --show-error https://tls.mbed.org/download/mbedtls-2.16.2-apache.tgz | \
tar -xz && \
cd mbedtls-2.16.2 && \
scripts/config.pl set MBEDTLS_MD4_C 1 && \
@@ -42,7 +40,7 @@ RUN cd /tmp && \
FROM mbedtls AS libssh2
RUN cd /tmp && \
- curl --location --silent https://www.libssh2.org/download/libssh2-1.8.2.tar.gz | \
+ curl --insecure --location --silent --show-error https://www.libssh2.org/download/libssh2-1.8.2.tar.gz | \
tar -xz && \
cd libssh2-1.8.2 && \
CFLAGS=-fPIC cmake -G Ninja -DBUILD_SHARED_LIBS=ON -DCRYPTO_BACKEND=Libgcrypt . && \
@@ -52,7 +50,7 @@ RUN cd /tmp && \
FROM libssh2 AS valgrind
RUN cd /tmp && \
- curl --location --silent https://sourceware.org/pub/valgrind/valgrind-3.15.0.tar.bz2 | \
+ curl --insecure --location --silent --show-error https://sourceware.org/pub/valgrind/valgrind-3.15.0.tar.bz2 | \
tar -xj && \
cd valgrind-3.15.0 && \
./configure && \
diff --git a/azure-pipelines/nightly.yml b/azure-pipelines/nightly.yml
index a193747..a75a9cc 100644
--- a/azure-pipelines/nightly.yml
+++ b/azure-pipelines/nightly.yml
@@ -5,7 +5,7 @@ jobs:
- job: linux_amd64_xenial_gcc_openssl
displayName: 'Linux (amd64; Xenial; GCC; OpenSSL)'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- template: docker.yml
parameters:
@@ -21,7 +21,7 @@ jobs:
- job: linux_amd64_xenial_gcc_mbedtls
displayName: 'Linux (amd64; Xenial; GCC; mbedTLS)'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- template: docker.yml
parameters:
@@ -37,7 +37,7 @@ jobs:
- job: linux_amd64_xenial_clang_openssl
displayName: 'Linux (amd64; Xenial; Clang; OpenSSL)'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- template: docker.yml
parameters:
@@ -53,7 +53,7 @@ jobs:
- job: linux_amd64_xenial_clang_mbedtls
displayName: 'Linux (amd64; Xenial; Clang; mbedTLS)'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- template: docker.yml
parameters:
@@ -67,9 +67,9 @@ jobs:
RUN_INVASIVE_TESTS=true
- job: macos
- displayName: 'macOS'
+ displayName: 'macOS (amd64; 10.15)'
pool:
- vmImage: 'macOS 10.13'
+ vmImage: 'macOS-10.15'
steps:
- bash: . '$(Build.SourcesDirectory)/azure-pipelines/setup-osx.sh'
displayName: Setup
@@ -85,31 +85,34 @@ jobs:
- job: windows_vs_amd64
displayName: 'Windows (amd64; Visual Studio)'
- pool: Hosted
+ pool:
+ vmImage: 'vs2017-win2016'
steps:
- template: bash.yml
parameters:
environmentVariables:
- CMAKE_GENERATOR: Visual Studio 12 2013 Win64
- CMAKE_OPTIONS: -DMSVC_CRTDBG=ON -DDEPRECATE_HARD=ON
+ CMAKE_GENERATOR: Visual Studio 15 2017
+ CMAKE_OPTIONS: -A x64 -DMSVC_CRTDBG=ON -DDEPRECATE_HARD=ON
RUN_INVASIVE_TESTS: true
SKIP_SSH_TESTS: true
- job: windows_vs_x86
displayName: 'Windows (x86; Visual Studio)'
- pool: Hosted
+ pool:
+ vmImage: 'vs2017-win2016'
steps:
- template: bash.yml
parameters:
environmentVariables:
- CMAKE_GENERATOR: Visual Studio 12 2013
- CMAKE_OPTIONS: -DMSVC_CRTDBG=ON -DDEPRECATE_HARD=ON -DUSE_SHA1=HTTPS
+ CMAKE_GENERATOR: Visual Studio 15 2017
+ CMAKE_OPTIONS: -A Win32 -DMSVC_CRTDBG=ON -DDEPRECATE_HARD=ON -DUSE_SHA1=HTTPS
RUN_INVASIVE_TESTS: true
SKIP_SSH_TESTS: true
- job: windows_mingw_amd64
displayName: 'Windows (amd64; MinGW)'
- pool: Hosted
+ pool:
+ vmImage: 'vs2017-win2016'
steps:
- bash: . '$(Build.SourcesDirectory)\azure-pipelines\setup-mingw.sh'
displayName: Setup
@@ -127,7 +130,8 @@ jobs:
- job: windows_mingw_x86
displayName: 'Windows (x86; MinGW)'
- pool: Hosted
+ pool:
+ vmImage: 'vs2017-win2016'
steps:
- bash: . '$(Build.SourcesDirectory)\azure-pipelines\setup-mingw.sh'
displayName: Setup
@@ -147,7 +151,7 @@ jobs:
- job: linux_x86_bionic_gcc_openssl
displayName: 'Linux (x86; Bionic; GCC; OpenSSL)'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- template: docker.yml
parameters:
@@ -164,7 +168,7 @@ jobs:
- job: linux_x86_bionic_clang_openssl
displayName: 'Linux (x86; Bionic; Clang; OpenSSL)'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- template: docker.yml
parameters:
@@ -181,7 +185,7 @@ jobs:
- job: linux_arm32_bionic_gcc_openssl
displayName: 'Linux (arm32; Bionic; GCC; OpenSSL)'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- template: docker.yml
parameters:
@@ -199,7 +203,7 @@ jobs:
- job: linux_arm64_bionic_gcc_openssl
displayName: 'Linux (arm64; Bionic; GCC; OpenSSL)'
pool:
- vmImage: 'Ubuntu 16.04'
+ vmImage: 'ubuntu-18.04'
steps:
- template: docker.yml
parameters:
diff --git a/azure-pipelines/test.sh b/azure-pipelines/test.sh
index 96832d6..2b43ba1 100755
--- a/azure-pipelines/test.sh
+++ b/azure-pipelines/test.sh
@@ -85,7 +85,7 @@ if [ -z "$SKIP_GITDAEMON_TESTS" ]; then
fi
if [ -z "$SKIP_PROXY_TESTS" ]; then
- curl --location --silent https://github.com/ethomson/poxyproxy/releases/download/v0.7.0/poxyproxy-0.7.0.jar >poxyproxy.jar
+ curl --location --silent --show-error https://github.com/ethomson/poxyproxy/releases/download/v0.7.0/poxyproxy-0.7.0.jar >poxyproxy.jar
echo ""
echo "Starting HTTP proxy (Basic)..."
@@ -97,7 +97,7 @@ if [ -z "$SKIP_PROXY_TESTS" ]; then
fi
if [ -z "$SKIP_NTLM_TESTS" ]; then
- curl --location --silent https://github.com/ethomson/poxygit/releases/download/v0.4.0/poxygit-0.4.0.jar >poxygit.jar
+ curl --location --silent --show-error https://github.com/ethomson/poxygit/releases/download/v0.4.0/poxygit-0.4.0.jar >poxygit.jar
echo ""
echo "Starting HTTP server..."
diff --git a/deps/ntlmclient/CMakeLists.txt b/deps/ntlmclient/CMakeLists.txt
index 66e96d6..0a13397 100644
--- a/deps/ntlmclient/CMakeLists.txt
+++ b/deps/ntlmclient/CMakeLists.txt
@@ -7,6 +7,8 @@ DISABLE_WARNINGS(implicit-fallthrough)
IF (HTTPS_BACKEND STREQUAL "SecureTransport")
ADD_DEFINITIONS(-DCRYPT_COMMONCRYPTO)
SET(SRC_NTLMCLIENT_CRYPTO "crypt_commoncrypto.c")
+ # CC_MD4 has been deprecated in macOS 10.15.
+ SET_SOURCE_FILES_PROPERTIES("crypt_commoncrypto.c" COMPILE_FLAGS "-Wno-deprecated")
ELSEIF (HTTPS_BACKEND STREQUAL "OpenSSL")
ADD_DEFINITIONS(-DCRYPT_OPENSSL)
INCLUDE_DIRECTORIES(${OPENSSL_INCLUDE_DIR})
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 1915e8a..3dfb69c 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -300,6 +300,10 @@ FILE(GLOB SRC_GIT2 *.c *.h
streams/*.c streams/*.h
transports/*.c transports/*.h
xdiff/*.c xdiff/*.h)
+IF(APPLE)
+ # The old Secure Transport API has been deprecated in macOS 10.15.
+ SET_SOURCE_FILES_PROPERTIES(streams/stransport.c PROPERTIES COMPILE_FLAGS -Wno-deprecated)
+ENDIF()
# the xdiff dependency is not (yet) warning-free, disable warnings as
# errors for the xdiff sources until we've sorted them out