aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2020-11-21 09:27:05 -0500
committerJack Lloyd <[email protected]>2020-11-21 09:27:05 -0500
commitc9b5d0c7f84d4264b2ae9cf13946d72de78c87f7 (patch)
treeeced370f5a40291b31ebeab18ef6acf4310afe5c
parent4cef74f10c79870d62d01fcb915c9d666bd64126 (diff)
parent051fe3bc92c9ca7e856136408f605e7fa3e2a5c8 (diff)
Merge GH #2503 Move coverage CI build to Github Actions
-rw-r--r--.github/workflows/ci.yml3
-rwxr-xr-xsrc/scripts/ci/setup_gh_actions.sh34
-rwxr-xr-xsrc/scripts/ci/setup_travis.sh2
-rw-r--r--src/scripts/ci/travis.yml6
4 files changed, 23 insertions, 22 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index c0d5a9b80..964d7a8fe 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -18,6 +18,9 @@ jobs:
matrix:
include:
+ - target: coverage
+ compiler: gcc
+ host_os: ubuntu-20.04
- target: shared
compiler: gcc
host_os: ubuntu-20.04
diff --git a/src/scripts/ci/setup_gh_actions.sh b/src/scripts/ci/setup_gh_actions.sh
index 12e6f4da0..1de04301b 100755
--- a/src/scripts/ci/setup_gh_actions.sh
+++ b/src/scripts/ci/setup_gh_actions.sh
@@ -7,63 +7,67 @@
command -v shellcheck > /dev/null && shellcheck "$0" # Run shellcheck on this if available
-set -ev
+set -ex
TARGET=$1
if type -p "apt-get"; then
sudo apt-get -qq update
- sudo apt-get install ccache
+ sudo apt-get -qq install ccache
if [ "$TARGET" = "valgrind" ]; then
- sudo apt-get install valgrind
+ sudo apt-get -qq install valgrind
elif [ "$TARGET" = "clang" ]; then
- sudo apt-get install clang
+ sudo apt-get -qq install clang
elif [ "$TARGET" = "cross-i386" ]; then
- sudo apt-get install g++-multilib linux-libc-dev libc6-dev-i386
+ sudo apt-get -qq install g++-multilib linux-libc-dev libc6-dev-i386
elif [ "$TARGET" = "cross-win64" ]; then
- sudo apt-get install wine-development g++-mingw-w64-x86-64
+ sudo apt-get -qq install wine-development g++-mingw-w64-x86-64
elif [ "$TARGET" = "cross-arm32" ]; then
sudo dpkg --add-architecture armhf
+ # need to re-update after --add-architecture
sudo apt-get -qq update
- sudo apt-get install g++-arm-linux-gnueabihf
- sudo apt-get install -o APT::Immediate-Configure=0 libc6:armhf libstdc++6:armhf
+ sudo apt-get -qq install g++-arm-linux-gnueabihf
+ sudo apt-get -qq install -o APT::Immediate-Configure=0 libc6:armhf libstdc++6:armhf
elif [ "$TARGET" = "cross-arm64" ]; then
- sudo apt-get install qemu-user g++-aarch64-linux-gnu
+ sudo apt-get -qq install qemu-user g++-aarch64-linux-gnu
elif [ "$TARGET" = "cross-ppc64" ]; then
- sudo apt-get install qemu-user g++-powerpc64le-linux-gnu
+ sudo apt-get -qq install qemu-user g++-powerpc64le-linux-gnu
elif [ "$TARGET" = "cross-android-arm32" ] || [ "$TARGET" = "cross-android-arm64" ]; then
wget -nv https://dl.google.com/android/repository/"$ANDROID_NDK"-linux-x86_64.zip
unzip -qq "$ANDROID_NDK"-linux-x86_64.zip
elif [ "$TARGET" = "baremetal" ]; then
- sudo apt-get install gcc-arm-none-eabi libstdc++-arm-none-eabi-newlib
+ sudo apt-get -qq install gcc-arm-none-eabi libstdc++-arm-none-eabi-newlib
echo 'extern "C" void __sync_synchronize() {}' >> src/tests/main.cpp
echo 'extern "C" void __sync_synchronize() {}' >> src/cli/main.cpp
elif [ "$TARGET" = "lint" ]; then
- sudo apt-get install pylint
+ sudo apt-get -qq install pylint
elif [ "$TARGET" = "coverage" ]; then
- sudo apt-get install g++-8 softhsm2 libtspi-dev lcov python-coverage libboost-all-dev gdb
+ sudo apt-get -qq install g++-8 softhsm2 libtspi-dev lcov python-coverage libboost-all-dev gdb
pip install --user codecov
- git clone --depth 1 --branch runner-changes-golang1.10 https://github.com/randombit/boringssl.git
+ echo "$HOME/.local/bin" >> $GITHUB_PATH
+
+ git clone --depth 1 --branch runner-changes https://github.com/randombit/boringssl.git
sudo chgrp -R "$(id -g)" /var/lib/softhsm/ /etc/softhsm
sudo chmod g+w /var/lib/softhsm/tokens
softhsm2-util --init-token --free --label test --pin 123456 --so-pin 12345678
+
elif [ "$TARGET" = "docs" ]; then
- sudo apt-get install doxygen python-docutils python3-sphinx
+ sudo apt-get -qq install doxygen python-docutils python3-sphinx
fi
else
HOMEBREW_NO_AUTO_UPDATE=1 brew install ccache
diff --git a/src/scripts/ci/setup_travis.sh b/src/scripts/ci/setup_travis.sh
index a9138fa88..bd43cfc9e 100755
--- a/src/scripts/ci/setup_travis.sh
+++ b/src/scripts/ci/setup_travis.sh
@@ -7,7 +7,7 @@
command -v shellcheck > /dev/null && shellcheck "$0" # Run shellcheck on this if available
-set -ev
+set -ex
if [ "$TRAVIS_OS_NAME" = "linux" ]; then
diff --git a/src/scripts/ci/travis.yml b/src/scripts/ci/travis.yml
index 8abec49de..46736d0ff 100644
--- a/src/scripts/ci/travis.yml
+++ b/src/scripts/ci/travis.yml
@@ -5,12 +5,6 @@ compiler: gcc
jobs:
include:
- - name: Coverage (GCC)
- env:
- - TARGET="coverage"
- - CCACHE_MAXSIZE=2G
- - PKCS11_LIB=/usr/lib/softhsm/libsofthsm2.so
-
- name: Linux ppc64le (GCC)
arch: ppc64le
env: