Commit dc6e80e2 by Edward Thomson

ci: perform clang builds on Linux

parent 6eb97b6b
...@@ -2,8 +2,8 @@ resources: ...@@ -2,8 +2,8 @@ resources:
- repo: self - repo: self
phases: phases:
- phase: linux_trusty_openssl - phase: linux_trusty_gcc_openssl
displayName: 'Linux (Trusty; OpenSSL)' displayName: 'Linux (Trusty; GCC; OpenSSL)'
queue: queue:
name: 'Hosted Linux Preview' name: 'Hosted Linux Preview'
steps: steps:
...@@ -26,13 +26,79 @@ phases: ...@@ -26,13 +26,79 @@ phases:
volumes: | volumes: |
$(Build.SourcesDirectory):/src $(Build.SourcesDirectory):/src
$(Build.BinariesDirectory):/build $(Build.BinariesDirectory):/build
envVars: |
CC=gcc
LEAK_CHECK=valgrind
workDir: '/build'
containerCommand: '/src/ci/test.sh'
detached: false
- phase: linux_trusty_gcc_mbedtls
displayName: 'Linux (Trusty; GCC; mbedTLS)'
queue:
name: 'Hosted Linux Preview'
steps:
- task: Docker@0
displayName: Build
inputs:
action: 'Run an image'
imageName: 'ethomson/libgit2-trusty-mbedtls:latest'
volumes: |
$(Build.SourcesDirectory):/src
$(Build.BinariesDirectory):/build
envVars: |
CC=gcc
CMAKE_OPTIONS=-DUSE_HTTPS=mbedTLS -DSHA1_BACKEND=mbedTLS
LEAK_CHECK=valgrind
workDir: '/build'
containerCommand: '/src/ci/build.sh'
detached: false
- task: Docker@0
displayName: Test
inputs:
action: 'Run an image'
imageName: 'ethomson/libgit2-trusty-mbedtls:latest'
volumes: |
$(Build.SourcesDirectory):/src
$(Build.BinariesDirectory):/build
envVars: 'LEAK_CHECK=valgrind' envVars: 'LEAK_CHECK=valgrind'
workDir: '/build' workDir: '/build'
containerCommand: '/src/ci/test.sh' containerCommand: '/src/ci/test.sh'
detached: false detached: false
- phase: linux_trusty_mbedtls - phase: linux_trusty_clang_openssl
displayName: 'Linux (Trusty; mbedTLS)' displayName: 'Linux (Trusty; Clang; OpenSSL)'
queue:
name: 'Hosted Linux Preview'
steps:
- task: Docker@0
displayName: Build
inputs:
action: 'Run an image'
imageName: 'ethomson/libgit2-trusty-openssl:latest'
volumes: |
$(Build.SourcesDirectory):/src
$(Build.BinariesDirectory):/build
workDir: '/build'
containerCommand: '/src/ci/build.sh'
detached: false
- task: Docker@0
displayName: Test
inputs:
action: 'Run an image'
imageName: 'ethomson/libgit2-trusty-openssl:latest'
volumes: |
$(Build.SourcesDirectory):/src
$(Build.BinariesDirectory):/build
envVars: |
CC=clang
LEAK_CHECK=valgrind
workDir: '/build'
containerCommand: '/src/ci/test.sh'
detached: false
- phase: linux_trusty_clang_mbedtls
displayName: 'Linux (Trusty; Clang; mbedTLS)'
queue: queue:
name: 'Hosted Linux Preview' name: 'Hosted Linux Preview'
steps: steps:
...@@ -44,7 +110,10 @@ phases: ...@@ -44,7 +110,10 @@ phases:
volumes: | volumes: |
$(Build.SourcesDirectory):/src $(Build.SourcesDirectory):/src
$(Build.BinariesDirectory):/build $(Build.BinariesDirectory):/build
envVars: 'CMAKE_OPTIONS=-DUSE_HTTPS=mbedTLS -DSHA1_BACKEND=mbedTLS' envVars: |
CC=clang
CMAKE_OPTIONS=-DUSE_HTTPS=mbedTLS -DSHA1_BACKEND=mbedTLS
LEAK_CHECK=valgrind
workDir: '/build' workDir: '/build'
containerCommand: '/src/ci/build.sh' containerCommand: '/src/ci/build.sh'
detached: false detached: false
......
...@@ -9,6 +9,7 @@ set -e ...@@ -9,6 +9,7 @@ set -e
SOURCE_DIR=${SOURCE_DIR:-$( cd "$( dirname "${BASH_SOURCE[0]}" )" && dirname $( pwd ) )} SOURCE_DIR=${SOURCE_DIR:-$( cd "$( dirname "${BASH_SOURCE[0]}" )" && dirname $( pwd ) )}
BUILD_DIR=$(pwd) BUILD_DIR=$(pwd)
CC=${CC:-cc}
indent() { sed "s/^/ /"; } indent() { sed "s/^/ /"; }
...@@ -20,7 +21,7 @@ uname -a 2>&1 | indent ...@@ -20,7 +21,7 @@ uname -a 2>&1 | indent
echo "CMake version:" echo "CMake version:"
cmake --version 2>&1 | indent cmake --version 2>&1 | indent
echo "Compiler version:" echo "Compiler version:"
gcc --version 2>&1 | indent $CC --version 2>&1 | indent
echo "" echo ""
echo "##############################################################################" echo "##############################################################################"
......
...@@ -3,6 +3,6 @@ ...@@ -3,6 +3,6 @@
set -x set -x
apt-get update apt-get update
apt-get -y install build-essential pkg-config cmake openssl libssl-dev libssh2-1-dev libcurl4-gnutls-dev openssh-server apt-get -y install build-essential pkg-config clang cmake openssl libssl-dev libssh2-1-dev libcurl4-gnutls-dev openssh-server
mkdir -p /var/run/sshd mkdir -p /var/run/sshd
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment