Skip to content

Commit 1ae366e

Browse files
author
MarcoFalke
committed
Merge #18569: ci: Add big endian native s390x build
6136a96 ci: Rename RUN_CI_ON_HOST to DANGER_RUN_CI_ON_HOST (Hennadii Stepanov) 97ba77a ci: Add native s390x (Hennadii Stepanov) Pull request description: Unlike the Docker wrapped solution (#17591) this PR suggests running on host system directly. This approach makes builds quick and stable (see: #18106). The excerpt from the Travis log: ``` ... Running on host system without docker wrapper ... Byte Order: Big Endian ... ``` ACKs for top commit: MarcoFalke: ACK 6136a96 Tree-SHA512: 1b591de13e38d10a35217e1de11cbd648a359d18d16eed166fac18ea5788b58cc9fc6d407086ed342b99e57e479efd951a0ea693710177e500eb116316b9a788
2 parents 87374d8 + 6136a96 commit 1ae366e

File tree

5 files changed

+47
-8
lines changed

5 files changed

+47
-8
lines changed

.cirrus.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ task:
3737
timeout_in: 60m
3838
env:
3939
MAKEJOBS: "-j9"
40-
RUN_CI_ON_HOST: "1"
40+
DANGER_RUN_CI_ON_HOST: "1"
4141
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
4242
CCACHE_SIZE: "200M"
4343
CCACHE_DIR: "/tmp/ccache_dir"

.travis.yml

Lines changed: 28 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,6 @@ cache:
3838
- $TRAVIS_BUILD_DIR/depends/sdk-sources
3939
- $TRAVIS_BUILD_DIR/ci/scratch/.ccache
4040
- $TRAVIS_BUILD_DIR/releases/$HOST
41-
# macOS
42-
- $HOME/Library/Caches/Homebrew
43-
- /usr/local/Homebrew
4441
before_cache:
4542
- if [ "${TRAVIS_OS_NAME}" = "osx" ]; then brew cleanup; fi
4643
stages:
@@ -91,6 +88,26 @@ jobs:
9188
FILE_ENV="./ci/test/00_setup_env_arm.sh"
9289
QEMU_USER_CMD=""
9390
91+
- stage: test
92+
name: 's390x native BE [GOAL: install] [bionic] [no depends, no GUI]'
93+
arch: s390x
94+
dist: bionic
95+
addons:
96+
apt:
97+
packages:
98+
- bsdmainutils
99+
- libboost-filesystem-dev
100+
- libboost-system-dev
101+
- libboost-test-dev
102+
- libboost-thread-dev
103+
- libdb++-dev
104+
- libdb-dev
105+
- libevent-dev
106+
env: >-
107+
DANGER_RUN_CI_ON_HOST=true
108+
CI_USE_APT_INSTALL=no
109+
FILE_ENV="./ci/test/00_setup_env_s390x_host.sh"
110+
94111
# s390 build was disabled temporarily because of disk space issues on the Travis VM
95112
#
96113
# - stage: test
@@ -158,6 +175,12 @@ jobs:
158175
# Xcode 11.3.1, macOS 10.14, SDK 10.15
159176
# https://docs.travis-ci.com/user/reference/osx/#macos-version
160177
osx_image: xcode11.3
178+
cache:
179+
directories:
180+
- $TRAVIS_BUILD_DIR/ci/scratch/.ccache
181+
- $TRAVIS_BUILD_DIR/releases/$HOST
182+
- $HOME/Library/Caches/Homebrew
183+
- /usr/local/Homebrew
161184
addons:
162185
homebrew:
163186
packages:
@@ -171,4 +194,6 @@ jobs:
171194
- ccache
172195
- zeromq
173196
env: >-
197+
DANGER_RUN_CI_ON_HOST=true
198+
CI_USE_APT_INSTALL=no
174199
FILE_ENV="./ci/test/00_setup_env_mac_host.sh"

ci/test/00_setup_env_mac_host.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ export LC_ALL=C.UTF-8
88

99
export HOST=x86_64-apple-darwin16
1010
export PIP_PACKAGES="zmq"
11-
export RUN_CI_ON_HOST=true
1211
export RUN_UNIT_TESTS=true
1312
export RUN_FUNCTIONAL_TESTS=false
1413
export GOAL="install"

ci/test/00_setup_env_s390x_host.sh

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
#!/usr/bin/env bash
2+
#
3+
# Copyright (c) 2019 The Bitcoin Core developers
4+
# Distributed under the MIT software license, see the accompanying
5+
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
6+
7+
export LC_ALL=C.UTF-8
8+
9+
export HOST=s390x-linux-gnu
10+
export NO_DEPENDS=1
11+
export BITCOIN_CONFIG="--with-incompatible-bdb --enable-reduce-exports"
12+
export RUN_UNIT_TESTS=true
13+
export RUN_FUNCTIONAL_TESTS=true
14+
export GOAL="install"

ci/test/04_install.sh

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ fi
3535

3636
export P_CI_DIR="$PWD"
3737

38-
if [ -z "$RUN_CI_ON_HOST" ]; then
38+
if [ -z "$DANGER_RUN_CI_ON_HOST" ]; then
3939
echo "Creating $DOCKER_NAME_TAG container to run in"
4040
${CI_RETRY_EXE} docker pull "$DOCKER_NAME_TAG"
4141

@@ -66,7 +66,7 @@ fi
6666
if [[ $DOCKER_NAME_TAG == centos* ]]; then
6767
${CI_RETRY_EXE} DOCKER_EXEC yum -y install epel-release
6868
${CI_RETRY_EXE} DOCKER_EXEC yum -y install $DOCKER_PACKAGES $PACKAGES
69-
elif [ "$TRAVIS_OS_NAME" != "osx" ]; then
69+
elif [ "$CI_USE_APT_INSTALL" != "no" ]; then
7070
${CI_RETRY_EXE} DOCKER_EXEC apt-get update
7171
${CI_RETRY_EXE} DOCKER_EXEC apt-get install --no-install-recommends --no-upgrade -y $PACKAGES $DOCKER_PACKAGES
7272
fi
@@ -77,6 +77,7 @@ if [ "$TRAVIS_OS_NAME" == "osx" ]; then
7777
else
7878
DOCKER_EXEC free -m -h
7979
DOCKER_EXEC echo "Number of CPUs \(nproc\):" \$\(nproc\)
80+
DOCKER_EXEC echo $(lscpu | grep Endian)
8081
DOCKER_EXEC echo "Free disk space:"
8182
DOCKER_EXEC df -h
8283
fi
@@ -90,7 +91,7 @@ export DIR_FUZZ_IN=${DIR_QA_ASSETS}/fuzz_seed_corpus/
9091

9192
DOCKER_EXEC mkdir -p "${BASE_SCRATCH_DIR}/sanitizer-output/"
9293

93-
if [ -z "$RUN_CI_ON_HOST" ]; then
94+
if [ -z "$DANGER_RUN_CI_ON_HOST" ]; then
9495
echo "Create $BASE_ROOT_DIR"
9596
DOCKER_EXEC rsync -a /ro_base/ $BASE_ROOT_DIR
9697
fi

0 commit comments

Comments
 (0)