Skip to content

Commit fc1040a

Browse files
committed
Merge #17176: ci: Cleanup macOS runs
fa677d1 ci: Remove redundant check for TRAVIS_OS_NAME (MarcoFalke) fadccb2 doc: Document that GNU tools are required for linters (MarcoFalke) 4444704 ci: Cleanup macOS runs (MarcoFalke) Pull request description: * Remove a commented out cleanup task in `before_cache` * Remove the linter run on macOS, and document that GNU tools are required to run the linters ACKs for top commit: Sjors: Code review ACK fa677d1 laanwj: ACK fa677d1 ryanofsky: Code review ACK fa677d1 for new third commit replacing TRAVIS_OS_NAME check with NO_DEPENDS setting Tree-SHA512: 9122a63bbe7887d9e379123152ea4ba44324cb18033b9e6b45bfdb1af665c10ea598564b9fcd57330d208a08e4696e41b4d6175f05f0843a3a76530da114f8c6
2 parents 0d6b6b7 + fa677d1 commit fc1040a

File tree

5 files changed

+20
-58
lines changed

5 files changed

+20
-58
lines changed

.travis.yml

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,6 @@ cache:
3939
- /usr/local/Homebrew
4040
before_cache:
4141
- if [ "${TRAVIS_OS_NAME}" = "osx" ]; then brew cleanup; fi
42-
# Cache only .git files under "/usr/local/Homebrew" so "brew update" does not take 5min every build
43-
# - if [ "${TRAVIS_OS_NAME}" = "osx" ]; then find /usr/local/Homebrew \! -regex ".+\.git.+" -delete; fi
4442
stages:
4543
- lint
4644
- test
@@ -95,28 +93,6 @@ jobs:
9593
script:
9694
- set -o errexit; source ./ci/extended_lint/06_script.sh
9795

98-
- stage: extended-lint
99-
name: 'lint macOS 10.12 (compat)'
100-
os: osx
101-
# Use the earliest macOS that can build our lint dependencies:
102-
# Xcode 8.3.3, macOS 10.12, JDK 1.8.0_112-b16
103-
# https://docs.travis-ci.com/user/reference/osx/#macos-version
104-
osx_image: xcode8.3
105-
# TODO: if you're updating osx_image, try using "rvm:" to supply the
106-
# version of ruby required by homebrew. Despite this "rvm:" declaration,
107-
# brew update installs ruby 2.3.7 as its first action.
108-
language: ruby
109-
rvm:
110-
- 2.3.7
111-
env:
112-
cache: false
113-
install:
114-
- set -o errexit; source ./ci/lint/04_install.sh
115-
before_script:
116-
- set -o errexit; source ./ci/lint/05_before_script.sh
117-
script:
118-
- set -o errexit; source ./ci/lint/06_script.sh
119-
12096
- stage: test
12197
name: 'ARM [GOAL: install] [unit tests, no functional tests]'
12298
env: >-

ci/lint/04_install.sh

Lines changed: 4 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -6,22 +6,9 @@
66

77
export LC_ALL=C
88

9-
if [ "$TRAVIS_OS_NAME" == "osx" ]; then
10-
# update first to install required ruby dependency
11-
travis_retry brew update
12-
travis_retry brew reinstall git -- --with-pcre2 # for --perl-regexp
13-
travis_retry brew install grep # gnu grep for --perl-regexp support
14-
PATH="$(brew --prefix grep)/libexec/gnubin:$PATH"
15-
travis_retry brew install shellcheck
16-
travis_retry brew upgrade python
17-
PATH="$(brew --prefix python)/bin:$PATH"
18-
export PATH
19-
else
20-
SHELLCHECK_VERSION=v0.6.0
21-
travis_retry curl --silent "https://storage.googleapis.com/shellcheck/shellcheck-${SHELLCHECK_VERSION}.linux.x86_64.tar.xz" | tar --xz -xf - --directory /tmp/
22-
PATH="/tmp/shellcheck-${SHELLCHECK_VERSION}:${PATH}"
23-
export PATH
24-
fi
25-
269
travis_retry pip3 install codespell==1.15.0
2710
travis_retry pip3 install flake8==3.7.8
11+
12+
SHELLCHECK_VERSION=v0.6.0
13+
curl -s "https://storage.googleapis.com/shellcheck/shellcheck-${SHELLCHECK_VERSION}.linux.x86_64.tar.xz" | tar --xz -xf - --directory /tmp/
14+
export PATH="/tmp/shellcheck-${SHELLCHECK_VERSION}:${PATH}"

ci/test/00_setup_env_mac_functional.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,11 @@ export LC_ALL=C.UTF-8
99
export HOST=x86_64-apple-darwin14
1010
export BREW_PACKAGES="automake berkeley-db4 libtool boost miniupnpc pkg-config protobuf qt qrencode python3 ccache zeromq"
1111
export PIP_PACKAGES="zmq"
12-
export OSX_SDK=10.11
1312
export RUN_CI_ON_HOST=true
1413
export RUN_UNIT_TESTS=true
1514
export RUN_FUNCTIONAL_TESTS=true
1615
export GOAL="install"
1716
export BITCOIN_CONFIG="--enable-gui --enable-bip70 --enable-reduce-exports --enable-werror"
17+
# Run without depends
1818
export NO_DEPENDS=1
19+
export OSX_SDK=""

ci/test/05_before_script.sh

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,17 @@ else
1313
DOCKER_EXEC echo \> \$HOME/.bitcoin
1414
fi
1515

16-
if [ "$TRAVIS_OS_NAME" != "osx" ]; then
17-
18-
mkdir -p depends/SDKs depends/sdk-sources
19-
20-
if [ -n "$OSX_SDK" ] && [ ! -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then
21-
curl --location --fail $SDK_URL/MacOSX${OSX_SDK}.sdk.tar.gz -o depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz
22-
fi
23-
if [ -n "$OSX_SDK" ] && [ -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then
24-
tar -C depends/SDKs -xf depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz
25-
fi
26-
if [[ $HOST = *-mingw32 ]]; then
27-
DOCKER_EXEC update-alternatives --set $HOST-g++ \$\(which $HOST-g++-posix\)
28-
fi
29-
if [ -z "$NO_DEPENDS" ]; then
30-
DOCKER_EXEC CONFIG_SHELL= make $MAKEJOBS -C depends HOST=$HOST $DEP_OPTS
31-
fi
16+
mkdir -p depends/SDKs depends/sdk-sources
3217

18+
if [ -n "$OSX_SDK" ] && [ ! -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then
19+
curl --location --fail $SDK_URL/MacOSX${OSX_SDK}.sdk.tar.gz -o depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz
20+
fi
21+
if [ -n "$OSX_SDK" ] && [ -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then
22+
tar -C depends/SDKs -xf depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz
23+
fi
24+
if [[ $HOST = *-mingw32 ]]; then
25+
DOCKER_EXEC update-alternatives --set $HOST-g++ \$\(which $HOST-g++-posix\)
26+
fi
27+
if [ -z "$NO_DEPENDS" ]; then
28+
DOCKER_EXEC CONFIG_SHELL= make $MAKEJOBS -C depends HOST=$HOST $DEP_OPTS
3329
fi

test/lint/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ Check for missing documentation of command line options.
77
commit-script-check.sh
88
======================
99
Verification of [scripted diffs](/doc/developer-notes.md#scripted-diffs).
10+
Scripted diffs are only assumed to run on the latest LTS release of Ubuntu. Running them on other operating systems
11+
might require installing GNU tools, such as GNU sed.
1012

1113
git-subtree-check.sh
1214
====================

0 commit comments

Comments
 (0)