Commit Graph

139 Commits

Author SHA1 Message Date
MarcoFalke 78d93effd0
ci: Checkout latest merged pulls
Github-Pull: #33303
Rebased-From: fa8f081af3
2025-09-23 15:26:10 +01:00
will 4a034cbeb4
ci: reduce runner sizes on various jobs
Github-Pull: #33319
Rebased-From: 5eeb2facbb

These jobs can use reduced runner size to avoid wasting CPU, as much of
the long-running part of the job is single-threaded.

Suggested in: https://github.com/bitcoin/bitcoin/pull/32989#discussion_r2321775620

Co-authored-by: MarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz>
2025-09-23 15:26:09 +01:00
will c7f290b826
ci: dynamically match makejobs with cores
Github-Pull: #32989
Rebased-From: 3f339e99e0

Previously jobs were running on a large multi-core server where 10 jobs
as default made sense (or may even have been on the low side).

Using hosted runners with fixed (and lower) numbers of vCPUs we should
adapt compilation to match the number of cpus we have dynamically.

This is cross-platform compatible with macos and linux only.
2025-09-23 15:26:05 +01:00
will 06424fb004
ci: port lint
Github-Pull: #32989
Rebased-From: bc41848d00

Co-authored-by: Max Edwards <youwontforgetthis@gmail.com>
2025-09-23 15:26:03 +01:00
will 0f0378fe3c
ci: port msan-depends
Github-Pull: #32989
Rebased-From: d290a8e6ea

Co-authored-by: Max Edwards <youwontforgetthis@gmail.com>
2025-09-23 15:26:02 +01:00
will 643385b22d
ci: port tsan-depends
Github-Pull: #32989
Rebased-From: 9bbae61e3b

Co-authored-by: Max Edwards <youwontforgetthis@gmail.com>
2025-09-23 15:26:01 +01:00
will 3b2dcc8b9a
ci: port tidy
Github-Pull: #32989
Rebased-From: bf7d536452

Co-authored-by: Max Edwards <youwontforgetthis@gmail.com>
2025-09-23 15:26:00 +01:00
will b4286cf354
ci: port centos-depends-gui
Github-Pull: #32989
Rebased-From: 549074bc64

Co-authored-by: Max Edwards <youwontforgetthis@gmail.com>
2025-09-23 15:25:59 +01:00
will 5057b9a6ff
ci: port previous-releases-depends-debug
Github-Pull: #32989
Rebased-From: 58e38c3a04

Co-authored-by: Max Edwards <youwontforgetthis@gmail.com>
2025-09-23 15:25:58 +01:00
will 85ec6c6882
ci: port fuzzer-address-undefined-integer-nodepends
Github-Pull: #32989
Rebased-From: 341196d75c

Co-authored-by: Max Edwards <youwontforgetthis@gmail.com>
2025-09-23 15:25:57 +01:00
will 544f902b2a
ci: port i686-multiprocess-DEBUG
Github-Pull: #32989
Rebased-From: f2068f26c1

Co-authored-by: Max Edwards <youwontforgetthis@gmail.com>
2025-09-23 15:25:56 +01:00
will e826c3daa5
ci: port nowallet-libbitcoinkernel
Github-Pull: #32989
Rebased-From: 2a00b12d73

Co-authored-by: Max Edwards <youwontforgetthis@gmail.com>
2025-09-23 15:25:55 +01:00
will 835b5b8bb1
ci: port mac-cross-gui-notests
Github-Pull: #32989
Rebased-From: 9c2514de53

Co-authored-by: Max Edwards <youwontforgetthis@gmail.com>
2025-09-23 15:25:54 +01:00
will 819ee09af3
ci: update asan-lsan-ubsan
Github-Pull: #32989
Rebased-From: 884251441b

Co-authored-by: Max Edwards <youwontforgetthis@gmail.com>
2025-09-23 15:25:52 +01:00
will 894a3cbe42
ci: update windows-cross job
Github-Pull: #32989
Rebased-From: 04e7bfbceb

Co-authored-by: Max Edwards <youwontforgetthis@gmail.com>
2025-09-23 15:25:51 +01:00
will 82c60a3151
ci: port arm 32-bit job
Github-Pull: #32989
Rebased-From: f253031cb8

Co-authored-by: Max Edwards <youwontforgetthis@gmail.com>
2025-09-23 15:25:50 +01:00
will 849993377d
ci: add job to determine runner type
Github-Pull: #32989
Rebased-From: cc1735d777

To remove multiple occurances of the respository name, against which we
compare `${{ github.repository }}` to check if we should use Cirrus
Runners, introduce a helper job which can check a single environment
variable and output this as an input to subsequent jobs.

Forks can maintain a trivial patch of their repo name against the
`REPO_USE_CIRRUS_RUNNERS` variable in ci.yml if they have Cirrus Runners
of their own, which will then enable cache actions and docker build
cache to use Cirrus Cache.

It's not possible to use `${{ env.USE_CIRRUS_RUNNERS }}` in the
`runs-on:` directive as the context is not supported by GitHub.

If it was, this job would no longer be necessary.
2025-09-23 15:25:49 +01:00
will f9f3e8b686
ci: add Cirrus cache host
Github-Pull: #32989
Rebased-From: 020069e6b7

Whilst the action cirruslabs/actions/cache will automatically set this
host, the docker `gha` build cache backend will not be aware of it.

Set the value here, which will later be used in the docker build args to
enable docker build cache on the cirrus cache.
2025-09-23 15:25:48 +01:00
will 1faf918a16
ci: add configure-docker action
Github-Pull: #32989
Rebased-From: fdf64e5532

Another action to reduce boilerplate in the main ci.yml file.

This action will set up a docker builder compatible with caching build
layers to a container registry using the `gha` build driver.

It will then configure the docker build cache args.
2025-09-23 15:25:44 +01:00
will 954c1a55e4
ci: add REPO_USE_CIRRUS_RUNNERS
Github-Pull: #32989
Rebased-From: 33ba073df7

If set, Cirrus runners will be used on pushes to, and pull requests
against, this repository.

Forks can set this if they have their own cirrus runners.
2025-09-23 15:25:43 +01:00
will 301aa5d814
ci: add caching actions
Github-Pull: #32989
Rebased-From: b232b0fa5e

Add "Restore" and "Save" caching actions.

These actions reduce boilerplate in the main ci.yml configuration file.

These actions are implemented so that caches will be saved on `push`
only.

When a pull request is opened it will cache hit on the caches from the
lastest push, or in the case of depends will hit on any matching depends
hash, falling back to partial matches.

Depends caches are hashed using
`$(git ls-tree HEAD depends "ci/test/$FILE_ENV" | sha256sum | cut -d' ' -f1)`
and this hash is passed in as an input to the actions. This means we
direct cache hit in cases where depends would not be re-built, otherwise
falling back to a partial match.

Previous releases cache is hashed similarly to depends, but using the
test/get_previous_releases.py file.

The cirruslabs cache action will fallback transparently to GitHub's
cache in the case that the job is not being run on a Cirrus Runner,
making these compatible with running on forks (on free GH hardware).
2025-09-23 15:25:42 +01:00
will f63b8e960d
ci: add configure environment action
Github-Pull: #32989
Rebased-From: b8fcc9fcbc
2025-09-23 15:25:41 +01:00
Hennadii Stepanov 64552c83b2
ci: Add workaround for vcpkg's libevent package
This change is necessary for Windows GHA images, which provide
CMake >= 4.0.

Github-Pull: #32184
Rebased-From: ef00a28414
2025-05-06 18:04:27 +01:00
Hennadii Stepanov 026bb226e9
cmake: Set top-level target output locations
This change:
1. Collects build artifacts in dedicated locations.
2. Allows running bitcoin-chainstate.exe with bitcoinkernel.dll directly
from the build tree on Windows.
2025-02-20 22:18:51 +00:00
Ryan Ofsky 8fa10edcd1
Merge bitcoin/bitcoin#31428: ci: Allow build dir on CI host
8888ee4403 ci: Allow build dir on CI host (MarcoFalke)

Pull request description:

  This is required to pass cross builds on to a different machine after the build.

  See for example https://github.com/bitcoin/bitcoin/pull/31176, but this pull will also allow someone to implement it outside this repo.

ACKs for top commit:
  davidgumberg:
    lgtm ACK 8888ee4403
  hebasto:
    re-ACK 8888ee4403.

Tree-SHA512: a1e2c32bc1b95efbd0b48287ac5b49e0e1bacbf5a5800845be5352bbdd3e17fa478e90348b2e94e95cf3ae863cdf75ab444089376588f6f8eec438f73a4b5b97
2025-01-30 19:34:00 -05:00
espi3 1681c08d42 doc: update links in ci.yml
Updated three GitHub links to avoid redirects.
2025-01-27 18:59:28 -08:00
MarcoFalke 1111b0ac19
ci: Add missing --combinedlogslen to test-each-commit task 2025-01-21 15:34:39 +01:00
Adlai Chandrasekhar 160c27ec07 doc: Update dependency installation for Debian/Ubuntu and CI
According to the description for pkg-config, "pkgconf is a
replacement for pkg-config, providing additional functionality
while also maintaining compatibility. This package only provides
a dependency link to the pkgconf package to help with package
upgrades. It can be safely removed."

Thus several scripts and markdown files are updated.
2025-01-16 17:31:13 +02:00
MarcoFalke fa029a7878
doc: Clarify min macOS and Xcode version 2025-01-06 12:30:55 +01:00
MarcoFalke 8888ee4403
ci: Allow build dir on CI host 2025-01-06 09:45:03 +01:00
Hennadii Stepanov e2f2698395
ci, macos: Install `pkgconf` Homebrew's package
The updated GHA image `20241125.556` is now fully deployed, enabling the
installation of `pkgconf` as documented in `doc/build-osx.md`.
2024-12-01 10:58:15 +00:00
Ava Chow 72ab35a6d0
Merge bitcoin/bitcoin#31221: ci: Split out native fuzz jobs for macOS and windows (take 2)
b031b7910d [ci] Split out native fuzz jobs for macOS and windows (dergoegge)

Pull request description:

  Split out two new CI jobs (for native macOS and windows) that run the fuzz tests on the qa-assets input corpora.

  In both jobs the fuzz binary is built with `-DBUILD_FOR_FUZZING` to enable `Assume` assertions as well as `FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION`.

ACKs for top commit:
  maflcko:
    re-lgtm ACK b031b7910d
  achow101:
    ACK b031b7910d
  hebasto:
    ACK b031b7910d.

Tree-SHA512: 7d0dc5a9cb299f6f4596dd9a5526b6aaf82efc6eba308bdc9d8b0a45f79dea87204fb6cd4b2ea2a1bd952466b2e958d64021999296d110d7a83c1667f4de51fe
2024-11-26 13:29:59 -05:00
dergoegge b031b7910d [ci] Split out native fuzz jobs for macOS and windows 2024-11-25 10:41:17 +00:00
fanquake fe3457ccff
ci: note that we should install pkgconf in future
As pkg-config is now just redirected to the later, but changing this likely
depends on the GHA image being updated first.
2024-11-21 11:08:02 +00:00
Sjors Provoost 8610bcef9d
ci: skip Github CI on branch pushes for forks
Consistent with Cirrus behavior introduced in e9bfbb5414.
2024-11-12 12:14:34 +01:00
furszy 36a22e5683
ci: make ctest stop on failure
Wastes less resources and notifies the developer faster when
a failure occurs.
2024-11-08 13:06:51 -05:00
Ryan Ofsky 03cff2c142
Merge bitcoin/bitcoin#31191: build: Make G_FUZZING constexpr, require -DBUILD_FOR_FUZZING=ON to fuzz
fafbf8acf4 Make G_FUZZING constexpr, require -DBUILD_FOR_FUZZING=ON to execute a fuzz target (MarcoFalke)
fae3cf0ffa ci: Temporarily disable macOS/Windows fuzz step (MarcoFalke)

Pull request description:

  `g_fuzzing` is used inside `Assume` at runtime, causing significant overhead in hot paths. See https://github.com/bitcoin/bitcoin/issues/31178

  One could simply remove the `g_fuzzing` check from the `Assume`, but this would make fuzzing a bit less useful. Also, it would be unclear if `g_fuzzing` adds a runtime overhead in other code paths today or in the future.

  Fix all issues by making `G_FUZZING` equal to the build option `BUILD_FOR_FUZZING`, and for consistency in fuzzing, require it to be set when executing any fuzz target.

  Fixes https://github.com/bitcoin/bitcoin/issues/31178

  Temporarily this drops fuzzing from two CI tasks, but they can be re-added in a follow-up with something like https://github.com/bitcoin/bitcoin/pull/31073

ACKs for top commit:
  marcofleon:
    Tested ACK fafbf8acf4
  davidgumberg:
    I still ACK fafbf8acf4 for fixing the regression measured in #31178.
  ryanofsky:
    Code review ACK fafbf8acf4 but approach -0, because this approach means libraries built for fuzz testing do not function correctly if used in a release, and libraries built for releases are mostly useless for fuzz testing. So I would like to at least consider other solutions to this problem even if we go with this one.
  dergoegge:
    utACK fafbf8acf4

Tree-SHA512: 124fc2e8b35e0c4df414436556a7a0a36cd1bec4b3000b40dcf2ab8c85f32e0610bf7f70d2fd79223d62f3c3665b6c09da21241654c7b9859461b8ca340d5421
2024-11-05 06:05:27 -05:00
MarcoFalke fae3cf0ffa
ci: Temporarily disable macOS/Windows fuzz step
The fuzz binary is still compiled. This is required for the next commit.
2024-10-31 13:51:13 +01:00
Sergi Delgado Segura 54d07dd37d ci: Do not error on unused-member-function in test each commit 2024-10-30 13:58:52 -04:00
Antoine Poinsot 94ad614482
ci: remove UPnP options 2024-10-25 09:27:12 -04:00
furszy 8523d8c0fc
ci: display logs of failed tests automatically 2024-10-24 10:36:02 -03:00
MarcoFalke fa1cffacae
ci: Install missing nproc in macos task
This avoids special-casing macos
2024-10-07 12:28:23 +02:00
MarcoFalke faf7a2bccc
ci: Add missing -DWERROR=ON to test-each-commit 2024-10-07 12:28:23 +02:00
laanwj 5c7cacf649 ci: Remove natpmp build option and libnatpmp dependency 2024-09-30 11:37:56 +02:00
Hennadii Stepanov d01b85bfec
ci: Use `ninja` to build in macOS native CI job 2024-09-17 15:43:48 +01:00
merge-script bdbc90f29a
Merge bitcoin/bitcoin#30902: Remove Autotools packages from CI (and depends doc)
7a8a6a0667 doc: Fix comment in `contrib/devtools/check-deps.sh` script (Hennadii Stepanov)
712d105e09 depends, doc: Do not install Autotools packages (Hennadii Stepanov)
b786449e66 ci: Do not install Autotools packages (Hennadii Stepanov)

Pull request description:

  This PR is a follow-up to https://github.com/bitcoin/bitcoin/pull/30752 and addresses https://github.com/bitcoin/bitcoin/pull/30752#discussion_r1758594864.

ACKs for top commit:
  kevkevinpal:
    ACK [7a8a6a0](7a8a6a0667)

Tree-SHA512: ac701b34ebf1621be355a5b576032d30a342a5667eff47d858587ac3c60011d77bd469e524d69dae90a932f14269227886e3d170a63a2e855b29ef4fa5b9e5a4
2024-09-17 15:19:18 +01:00
MarcoFalke fa8f35d786
ci: Use macos-14 GHA image 2024-09-17 09:37:44 +02:00
Hennadii Stepanov b786449e66
ci: Do not install Autotools packages 2024-09-14 13:09:11 +01:00
Hennadii Stepanov e07a3ede52
ci: Add missed configuration options to "Win64 native" job 2024-09-06 12:19:26 +01:00
MarcoFalke 8888beea8d
scripted-diff: fuzz: Rename fuzz_seed_corpus to fuzz_corpora
-BEGIN VERIFY SCRIPT-
 ren() { sed -i "s:\<$1\>:$2:g" $( git grep -l "$1" ) ; }
 ren fuzz_seed_corpus     fuzz_corpora
 ren FUZZ_SEED_CORPUS_DIR FUZZ_CORPORA_DIR
-END VERIFY SCRIPT-
2024-09-03 20:40:35 +02:00