Skip to content

Commit

Permalink
[secp256k1] Update macOS image for CI
Browse files Browse the repository at this point in the history
Summary:
Backport of [[bitcoin-core/secp256k1#1152 | secp256k1#1152]]:
bitcoin-core/secp256k1@c0ae48c

The second commit is not applicable.

Depends on D12960.

This will unbreak the build on Cirrus CI, following the MacOS Intel deprecation:
https://cirrus-ci.org/blog/2022/11/08/sunsetting-intel-macos-instances/

Test Plan:
See the CI result all green on my forked repo:
https://cirrus-ci.com/build/5534806579085312

Reviewers: #bitcoin_abc, sdulfari

Reviewed By: #bitcoin_abc, sdulfari

Differential Revision: https://reviews.bitcoinabc.org/D12961
  • Loading branch information
sipa authored and Fabcien committed Jan 9, 2023
1 parent 826d64f commit d2be24f
Showing 1 changed file with 10 additions and 42 deletions.
52 changes: 10 additions & 42 deletions .cirrus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,59 +92,27 @@ task:

task:
timeout_in: 120m
name: "x86_64: macOS Catalina"
name: "arm64: macOS Ventura"
macos_instance:
image: catalina-base
image: ghcr.io/cirruslabs/macos-ventura-base:latest
env:
HOMEBREW_NO_AUTO_UPDATE: 1
HOMEBREW_NO_INSTALL_CLEANUP: 1
# Cirrus gives us a fixed number of 12 virtual CPUs. Not that we even have that many jobs at the moment...
MAKEFLAGS: -j13
# Cirrus gives us a fixed number of 4 virtual CPUs. Not that we even have that many jobs at the moment...
MAKEFLAGS: -j5
matrix:
<< : *ENV_MATRIX
env:
ASM: no
WITH_VALGRIND: no
CTIMETEST: no
matrix:
- env:
CC: gcc-9
CC: gcc
- env:
CC: clang
# Update Command Line Tools
# Uncomment this if the Command Line Tools on the CirrusCI macOS image are too old to brew valgrind.
# See https://apple.stackexchange.com/a/195963 for the implementation.
## update_clt_script:
## - system_profiler SPSoftwareDataType
## - touch /tmp/.com.apple.dt.CommandLineTools.installondemand.in-progress
## - |-
## PROD=$(softwareupdate -l | grep "*.*Command Line" | tail -n 1 | awk -F"*" '{print $2}' | sed -e 's/^ *//' | sed 's/Label: //g' | tr -d '\n')
## # For debugging
## - softwareupdate -l && echo "PROD: $PROD"
## - softwareupdate -i "$PROD" --verbose
## - rm /tmp/.com.apple.dt.CommandLineTools.installondemand.in-progress
##
brew_valgrind_pre_script:
- brew config
- brew tap --shallow LouisBrunner/valgrind
# Fetch valgrind source but don't build it yet.
- brew fetch --HEAD LouisBrunner/valgrind/valgrind
brew_valgrind_cache:
# This is $(brew --cellar valgrind) but command substition does not work here.
folder: /usr/local/Cellar/valgrind
# Rebuild cache if ...
fingerprint_script:
# ... macOS version changes:
- sw_vers
# ... brew changes:
- brew config
# ... valgrind changes:
- git -C "$(brew --cache)/valgrind--git" rev-parse HEAD
populate_script:
# If there's no hit in the cache, build and install valgrind.
- brew install --HEAD LouisBrunner/valgrind/valgrind
brew_valgrind_post_script:
# If we have restored valgrind from the cache, tell brew to create symlink to the PATH.
# If we haven't restored from cached (and just run brew install), this is a no-op.
- brew link valgrind
brew_script:
- brew install automake cmake gcc@9 libtool ninja
- brew install automake cmake gcc libtool ninja
test_script:
- ./ci/build_autotools.sh
- ./ci/build_cmake.sh
Expand Down

0 comments on commit d2be24f

Please sign in to comment.