mirror of
https://github.com/dashpay/dash.git
synced 2024-12-24 11:32:46 +01:00
Merge #20339: ci: Run more ci configs on cirrus
77777c8b5e3d0edbe1178d982a778b7cc9964b70 ci: Run windows ci config on cirrus (MarcoFalke) 3333d6942e8c5d823b97ea51ef88c8a0791742c6 ci: Run macos ci config on cirrus (MarcoFalke) fa8b1114e60100f503673ccc7ef5618851c0c9e3 ci: Run arm ci config on cirrus (MarcoFalke) fa0795f54dc5268bacc6acdfdbe23f9952a0e7d8 ci: Replace TRAVIS_OS_NAME with CI_OS_NAME (MarcoFalke) fafce1a13a65cc3ae0cd5351648bb0290f9bfe8c ci: Move documentation to correct config file (MarcoFalke) Pull request description: ACKs for top commit: hebasto: ACK 77777c8b5e3d0edbe1178d982a778b7cc9964b70 Tree-SHA512: 581d3bdb2c3e3da20bd8492c6b23d90f3b4f7f9300ade384667e41de9fbbe42bbcef26dd99328839dc0b49be6e303c4c6d1b66ceb5d8009800c52c97685f9080
This commit is contained in:
parent
c295a13ac6
commit
b18a58b4f7
32
.cirrus.yml
32
.cirrus.yml
@ -8,7 +8,7 @@ container:
|
|||||||
memory: 8G # Set to 8GB to avoid OOM. https://cirrus-ci.org/guide/linux/#linux-containers
|
memory: 8G # Set to 8GB to avoid OOM. https://cirrus-ci.org/guide/linux/#linux-containers
|
||||||
kvm: true # Use kvm to avoid spurious CI failures in the default virtualization cluster, see https://github.com/bitcoin/bitcoin/issues/20093
|
kvm: true # Use kvm to avoid spurious CI failures in the default virtualization cluster, see https://github.com/bitcoin/bitcoin/issues/20093
|
||||||
env:
|
env:
|
||||||
PACKAGE_MANAGER_INSTALL : "apt-get update && apt-get install -y"
|
PACKAGE_MANAGER_INSTALL: "apt-get update && apt-get install -y"
|
||||||
MAKEJOBS: "-j4"
|
MAKEJOBS: "-j4"
|
||||||
DANGER_RUN_CI_ON_HOST: "1" # Containers will be discarded after the run, so there is no risk that the ci scripts modify the system
|
DANGER_RUN_CI_ON_HOST: "1" # Containers will be discarded after the run, so there is no risk that the ci scripts modify the system
|
||||||
TEST_RUNNER_PORT_MIN: "14000" # Must be larger than 12321, which is used for the http cache. See https://cirrus-ci.org/guide/writing-tasks/#http-cache
|
TEST_RUNNER_PORT_MIN: "14000" # Must be larger than 12321, which is used for the http cache. See https://cirrus-ci.org/guide/writing-tasks/#http-cache
|
||||||
@ -38,6 +38,22 @@ global_task_template: &GLOBAL_TASK_TEMPLATE
|
|||||||
- ./ci/test_run_all.sh
|
- ./ci/test_run_all.sh
|
||||||
|
|
||||||
|
|
||||||
|
task:
|
||||||
|
name: 'ARM [GOAL: install] [buster] [unit tests, no functional tests]'
|
||||||
|
<< : *GLOBAL_TASK_TEMPLATE
|
||||||
|
container:
|
||||||
|
image: debian:buster
|
||||||
|
env:
|
||||||
|
FILE_ENV: "./ci/test/00_setup_env_arm.sh"
|
||||||
|
|
||||||
|
task:
|
||||||
|
name: 'Win64 [GOAL: deploy] [unit tests, no gui, no boost::process, no functional tests]'
|
||||||
|
<< : *GLOBAL_TASK_TEMPLATE
|
||||||
|
container:
|
||||||
|
image: ubuntu:bionic
|
||||||
|
env:
|
||||||
|
FILE_ENV: "./ci/test/00_setup_env_win64.sh"
|
||||||
|
|
||||||
task:
|
task:
|
||||||
name: 'x86_64 Linux [GOAL: install] [focal] [previous releases, uses qt5 dev package and some depends packages] [unsigned char]'
|
name: 'x86_64 Linux [GOAL: install] [focal] [previous releases, uses qt5 dev package and some depends packages] [unsigned char]'
|
||||||
<< : *GLOBAL_TASK_TEMPLATE
|
<< : *GLOBAL_TASK_TEMPLATE
|
||||||
@ -104,3 +120,17 @@ task:
|
|||||||
image: ubuntu:focal
|
image: ubuntu:focal
|
||||||
env:
|
env:
|
||||||
FILE_ENV: "./ci/test/00_setup_env_mac.sh"
|
FILE_ENV: "./ci/test/00_setup_env_mac.sh"
|
||||||
|
|
||||||
|
task:
|
||||||
|
name: 'macOS 10.14 native [GOAL: install] [GUI] [no depends]'
|
||||||
|
macos_brew_addon_script:
|
||||||
|
- brew install boost libevent berkeley-db4 qt miniupnpc ccache zeromq qrencode sqlite libtool automake pkg-config gnu-getopt
|
||||||
|
<< : *GLOBAL_TASK_TEMPLATE
|
||||||
|
osx_instance:
|
||||||
|
# Use latest image, but hardcode version to avoid silent upgrades (and breaks)
|
||||||
|
image: catalina-xcode-12.1 # https://cirrus-ci.org/guide/macOS
|
||||||
|
env:
|
||||||
|
DANGER_RUN_CI_ON_HOST: "true"
|
||||||
|
CI_USE_APT_INSTALL: "no"
|
||||||
|
PACKAGE_MANAGER_INSTALL: "echo" # Nothing to do
|
||||||
|
FILE_ENV: "./ci/test/00_setup_env_mac_host.sh"
|
||||||
|
32
.travis.yml
32
.travis.yml
@ -185,39 +185,7 @@ after_success:
|
|||||||
script:
|
script:
|
||||||
- set -o errexit; source ./ci/lint/06_script.sh
|
- set -o errexit; source ./ci/lint/06_script.sh
|
||||||
|
|
||||||
- stage: test
|
|
||||||
name: 'ARM [GOAL: install] [focal] [unit tests, no functional tests]'
|
|
||||||
arch: arm64 # Can disable QEMU_USER_CMD and run the tests natively without qemu
|
|
||||||
env: >-
|
|
||||||
FILE_ENV="./ci/test/00_setup_env_arm.sh"
|
|
||||||
QEMU_USER_CMD=""
|
|
||||||
|
|
||||||
- stage: test
|
|
||||||
name: 'Win64 [GOAL: deploy] [unit tests, no gui, no boost::process, no functional tests]'
|
|
||||||
env: >-
|
|
||||||
FILE_ENV="./ci/test/00_setup_env_win64.sh"
|
|
||||||
|
|
||||||
- stage: test
|
- stage: test
|
||||||
name: 'x86_64 Linux [GOAL: install] [focal] [no wallet]'
|
name: 'x86_64 Linux [GOAL: install] [focal] [no wallet]'
|
||||||
env: >-
|
env: >-
|
||||||
FILE_ENV="./ci/test/00_setup_env_native_nowallet.sh"
|
FILE_ENV="./ci/test/00_setup_env_native_nowallet.sh"
|
||||||
|
|
||||||
- stage: test
|
|
||||||
name: 'macOS 10.14 native [GOAL: install] [GUI] [no depends]'
|
|
||||||
os: osx
|
|
||||||
# Use the most recent version:
|
|
||||||
# Xcode 11.3.1, macOS 10.14, SDK 10.15
|
|
||||||
# https://docs.travis-ci.com/user/reference/osx/#macos-version
|
|
||||||
osx_image: xcode11.3
|
|
||||||
addons:
|
|
||||||
homebrew:
|
|
||||||
packages:
|
|
||||||
- berkeley-db4
|
|
||||||
- miniupnpc
|
|
||||||
- qrencode
|
|
||||||
- ccache
|
|
||||||
- zeromq
|
|
||||||
env: >-
|
|
||||||
DANGER_RUN_CI_ON_HOST=true
|
|
||||||
CI_USE_APT_INSTALL=no
|
|
||||||
FILE_ENV="./ci/test/00_setup_env_mac_host.sh"
|
|
||||||
|
@ -11,12 +11,9 @@ export HOST=x86_64-apple-darwin
|
|||||||
export PIP_PACKAGES="zmq lief"
|
export PIP_PACKAGES="zmq lief"
|
||||||
export GOAL="install"
|
export GOAL="install"
|
||||||
export BITCOIN_CONFIG="--with-gui --enable-reduce-exports --disable-miner --enable-werror --with-boost-process"
|
export BITCOIN_CONFIG="--with-gui --enable-reduce-exports --disable-miner --enable-werror --with-boost-process"
|
||||||
|
export CI_OS_NAME="macos"
|
||||||
export NO_DEPENDS=1
|
export NO_DEPENDS=1
|
||||||
export OSX_SDK=""
|
export OSX_SDK=""
|
||||||
export CCACHE_SIZE=300M
|
export CCACHE_SIZE=300M
|
||||||
|
|
||||||
export RUN_SECURITY_TESTS="true"
|
export RUN_SECURITY_TESTS="true"
|
||||||
if [ "$TRAVIS_REPO_SLUG" != "dashpay/dash" ]; then
|
|
||||||
export RUN_FUNCTIONAL_TESTS="false"
|
|
||||||
export EXPECTED_TESTS_DURATION_IN_SECONDS=200
|
|
||||||
fi
|
|
||||||
|
@ -8,7 +8,7 @@ export LC_ALL=C.UTF-8
|
|||||||
|
|
||||||
export CONTAINER_NAME=ci_win64
|
export CONTAINER_NAME=ci_win64
|
||||||
export HOST=x86_64-w64-mingw32
|
export HOST=x86_64-w64-mingw32
|
||||||
export PACKAGES="python3 nsis g++-mingw-w64-x86-64 wine-binfmt wine64"
|
export PACKAGES="python3 nsis g++-mingw-w64-x86-64 wine-binfmt wine64 file"
|
||||||
export DPKG_ADD_ARCH="i386"
|
export DPKG_ADD_ARCH="i386"
|
||||||
export RUN_FUNCTIONAL_TESTS=false
|
export RUN_FUNCTIONAL_TESTS=false
|
||||||
export RUN_SECURITY_TESTS="false"
|
export RUN_SECURITY_TESTS="false"
|
||||||
|
@ -13,8 +13,8 @@ if [[ $QEMU_USER_CMD == qemu-s390* ]]; then
|
|||||||
export LC_ALL=C
|
export LC_ALL=C
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$TRAVIS_OS_NAME" == "osx" ]; then
|
if [ "$CI_OS_NAME" == "macos" ]; then
|
||||||
${CI_RETRY_EXE} pip3 install $PIP_PACKAGES
|
IN_GETOPT_BIN="/usr/local/opt/gnu-getopt/bin/getopt" ${CI_RETRY_EXE} pip3 install --user $PIP_PACKAGES
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Create folders that are mounted into the docker
|
# Create folders that are mounted into the docker
|
||||||
@ -26,9 +26,7 @@ export LSAN_OPTIONS="suppressions=${BASE_BUILD_DIR}/test/sanitizer_suppressions/
|
|||||||
export TSAN_OPTIONS="suppressions=${BASE_BUILD_DIR}/test/sanitizer_suppressions/tsan:halt_on_error=1"
|
export TSAN_OPTIONS="suppressions=${BASE_BUILD_DIR}/test/sanitizer_suppressions/tsan:halt_on_error=1"
|
||||||
export UBSAN_OPTIONS="suppressions=${BASE_BUILD_DIR}/test/sanitizer_suppressions/ubsan:print_stacktrace=1:halt_on_error=1:report_error_type=1"
|
export UBSAN_OPTIONS="suppressions=${BASE_BUILD_DIR}/test/sanitizer_suppressions/ubsan:print_stacktrace=1:halt_on_error=1:report_error_type=1"
|
||||||
env | grep -E '^(BASE_|QEMU_|CCACHE_|LC_ALL|BOOST_TEST_RANDOM|DEBIAN_FRONTEND|CONFIG_SHELL|(ASAN|LSAN|TSAN|UBSAN)_OPTIONS|PREVIOUS_RELEASES_DIR))' | tee /tmp/env
|
env | grep -E '^(BASE_|QEMU_|CCACHE_|LC_ALL|BOOST_TEST_RANDOM|DEBIAN_FRONTEND|CONFIG_SHELL|(ASAN|LSAN|TSAN|UBSAN)_OPTIONS|PREVIOUS_RELEASES_DIR))' | tee /tmp/env
|
||||||
if [[ $HOST = *-mingw32 ]]; then
|
if [[ $BITCOIN_CONFIG = *--with-sanitizers=*address* ]]; then # If ran with (ASan + LSan), Docker needs access to ptrace (https://github.com/google/sanitizers/issues/764)
|
||||||
DOCKER_ADMIN="--cap-add SYS_ADMIN"
|
|
||||||
elif [[ $BITCOIN_CONFIG = *--with-sanitizers=*address* ]]; then # If ran with (ASan + LSan), Docker needs access to ptrace (https://github.com/google/sanitizers/issues/764)
|
|
||||||
DOCKER_ADMIN="--cap-add SYS_PTRACE"
|
DOCKER_ADMIN="--cap-add SYS_PTRACE"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@ -72,16 +70,16 @@ elif [ "$CI_USE_APT_INSTALL" != "no" ]; then
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$TRAVIS_OS_NAME" == "osx" ]; then
|
if [ "$CI_OS_NAME" == "macos" ]; then
|
||||||
top -l 1 -s 0 | awk ' /PhysMem/ {print}'
|
top -l 1 -s 0 | awk ' /PhysMem/ {print}'
|
||||||
echo "Number of CPUs: $(sysctl -n hw.logicalcpu)"
|
echo "Number of CPUs: $(sysctl -n hw.logicalcpu)"
|
||||||
else
|
else
|
||||||
DOCKER_EXEC free -m -h
|
DOCKER_EXEC free -m -h
|
||||||
DOCKER_EXEC echo "Number of CPUs \(nproc\):" \$\(nproc\)
|
DOCKER_EXEC echo "Number of CPUs \(nproc\):" \$\(nproc\)
|
||||||
DOCKER_EXEC echo $(lscpu | grep Endian)
|
DOCKER_EXEC echo $(lscpu | grep Endian)
|
||||||
DOCKER_EXEC echo "Free disk space:"
|
|
||||||
DOCKER_EXEC df -h
|
|
||||||
fi
|
fi
|
||||||
|
DOCKER_EXEC echo "Free disk space:"
|
||||||
|
DOCKER_EXEC df -h
|
||||||
|
|
||||||
if [ ! -d ${DIR_QA_ASSETS} ]; then
|
if [ ! -d ${DIR_QA_ASSETS} ]; then
|
||||||
if [ "$RUN_FUZZ_TESTS" = "true" ]; then
|
if [ "$RUN_FUZZ_TESTS" = "true" ]; then
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
export LC_ALL=C.UTF-8
|
export LC_ALL=C.UTF-8
|
||||||
|
|
||||||
# Make sure default datadir does not exist and is never read by creating a dummy file
|
# Make sure default datadir does not exist and is never read by creating a dummy file
|
||||||
if [ "$TRAVIS_OS_NAME" == "osx" ]; then
|
if [ "$CI_OS_NAME" == "macos" ]; then
|
||||||
echo > $HOME/Library/Application\ Support/DashCore
|
echo > $HOME/Library/Application\ Support/DashCore
|
||||||
else
|
else
|
||||||
DOCKER_EXEC echo \> \$HOME/.dashcore
|
DOCKER_EXEC echo \> \$HOME/.dashcore
|
||||||
|
20
ci/test/wrap-wine.sh
Executable file
20
ci/test/wrap-wine.sh
Executable file
@ -0,0 +1,20 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
#
|
||||||
|
# Copyright (c) 2020 The Bitcoin Core developers
|
||||||
|
# Distributed under the MIT software license, see the accompanying
|
||||||
|
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||||
|
|
||||||
|
export LC_ALL=C.UTF-8
|
||||||
|
|
||||||
|
for b_name in {"${BASE_OUTDIR}/bin"/*,src/secp256k1/*tests,src/univalue/{no_nul,test_json,unitester,object}}.exe; do
|
||||||
|
# shellcheck disable=SC2044
|
||||||
|
for b in $(find "${BASE_ROOT_DIR}" -executable -type f -name "$(basename $b_name)"); do
|
||||||
|
if (file "$b" | grep "Windows"); then
|
||||||
|
echo "Wrap $b ..."
|
||||||
|
mv "$b" "${b}_orig"
|
||||||
|
echo '#!/usr/bin/env bash' > "$b"
|
||||||
|
echo "wine64 \"${b}_orig\" \"\$@\"" >> "$b"
|
||||||
|
chmod +x "$b"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
done
|
Loading…
Reference in New Issue
Block a user