Skip to content

backport: bitcoin#29994, bitcoin#29120, bitcoin#30519, bitcoin#29876 - #8165

Merged
PastaPastaPasta merged 4 commits into
dashpay:developfrom
thepastaclaw:backport-0.28-b009-src
Nov 16, 2026
Merged

PastaPastaPasta merged 4 commits into
dashpay:developfrom
thepastaclaw:backport-0.28-b009-src

Conversation

@DCG-Claude

Copy link
Copy Markdown
Collaborator

Issue being fixed or feature implemented

Backports 4 Bitcoin Core v0.28 pull request(s) to Dash.

What was done?

How Has This Been Tested?

Breaking Changes

None beyond the upstream changes themselves.

Checklist:

  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation
  • I have assigned this pull request to a milestone (for repository code-owners and collaborators only)

… connect automatically

95897ff doc: removed help text saying that peers may not connect automatically (kevkevin)

Pull request description:

  Introduced in bitcoin#23542 and released in version 23.0 there has been significant time since this change (2 years).

  This should be removed as it is no longer relevant

ACKs for top commit:
  stickies-v:
    ACK 95897ff
  tdb3:
    ACK for 95897ff.
  vasild:
    ACK 95897ff
  jonatack:
    ACK 95897ff
  kristapsk:
    ACK 95897ff. According to https://bitnodes.io/dashboard/#user-agents stats, most nodes on the network are v23+.

Tree-SHA512: 9e35194f8a1e06f1447450af2ea30cdc43722665c2d2e4b7aa9a52afac5c1e83fed744742c836743a555cc180c90f9eebdc6637eba6190010d693eef9c5834f7

Dash adaptations:
- src/init.cpp: -port help text lists Dash's devnet default port instead of signet, as the existing Dash line already did
e504b1f test: Add test case for spending bare multisig (Brandon Odiwuor)

Pull request description:

  Fixes bitcoin#29113

ACKs for top commit:
  ajtowns:
    ACK e504b1f ; LGTM and just checking the 1-of-3 case seems fine
  maflcko:
    utACK e504b1f
  achow101:
    ACK e504b1f
  willcl-ark:
    reACK e504b1f

Tree-SHA512: 641a12599efa34e1a3eb65b125318df326628fef3e6886410ea9e63a044664fad7bcad46d1d6f41ddc59630746b9963cedb569c2682b5940b32b9225883da8f2

Dash adaptations:
- src/init.cpp: only the -permitbaremultisig help text changes; Dash registers -mempoolfullrbf elsewhere in SetupServerArgs, so the upstream neighbouring line is not duplicated
- test/functional/mempool_accept.py: signs with sign_input, the name Dash's backport of bitcoin#28025 gave upstream's sign_input_legacy
- test/functional/mempool_accept.py: spend output uses script_to_p2sh_script instead of script_to_p2wsh_script (Dash has no segwit)
…TSAN (libc++) job

e3edacc ci: add _LIBCPP_REMOVE_TRANSITIVE_INCLUDES to TSAN job (fanquake)
6e78616 refactor: fix missing includes (fanquake)

Pull request description:

  Add `_LIBCPP_REMOVE_TRANSITIVE_INCLUDES` to one of the libc++ CI jobs, to catch missing includes, that are otherwise hidden by transitive includes inside libc++. A more appropriate place for this might be the tidy job, but that does not use libc++.

  See https://libcxx.llvm.org/DesignDocs/HeaderRemovalPolicy.html for more information.

ACKs for top commit:
  maflcko:
    re-ACK e3edacc

Tree-SHA512: 3fb2e9bbbf4bb1570633d52939875ee674d934b645a4037a309643f84ab69edf0fb5b6cfcbd02fa7d92052a64fa63f31979a58fede23593c4df7c33a8cb2953a

Dash adaptations:
- ci/test/00_setup_env_native_tsan.sh: -D_LIBCPP_REMOVE_TRANSITIVE_INCLUDES added to Dash's separate CPPFLAGS export (Dash keeps CPPFLAGS out of BITCOIN_CONFIG)
- src/init.h: keeps Dash's #include <context.h> (Dash's replacement for <any>, which bitcoind.cpp relies on for CoreContext); drops <memory>/<string> like upstream
e3dc64f build: add -Wundef (fanquake)
82b4395 refactor: use #ifdef HAVE_SOCKADDR_UN (fanquake)
40cd758 randomenv: use ifdef over if (fanquake)
7839503 zmq: use #ifdef ENABLE_ZMQ (fanquake)
79e197b build: Suppress warnings from boost and capnproto in multiprocess code (Ryan Ofsky)

Pull request description:

  Turn on `-Wundef`.

  [> Warn if an undefined identifier is evaluated in an #if directive. Such identifiers are replaced with zero.](https://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html#index-Wundef).

  Note that this is still beneficial with CMake, and may even be nice to have enabled prior, to catch any change in behaviour.

  If we end up with this enabled, it should probably be enough to fix bitcoin#16419.

ACKs for top commit:
  hebasto:
    ACK e3dc64f, I have reviewed the code and it looks OK.

Tree-SHA512: 73436ead07f3a09ba0d30f7105df50d9b2ec8452f11e866bc1c7ebc10c005772ee77fedaa125f444175663c04dfc472f98c2699c63711da356089b66a8cc3e0a

Dash adaptations:
- src/init.cpp: #if→#ifdef on ENABLE_ZMQ/HAVE_SOCKADDR_UN guards applied around Dash-only code (devnet -port help, wallet CoinJoin/evo/governance/masternode RPC registration, Dash zmq args)
- src/netbase.cpp: #if HAVE_SOCKADDR_UN→#ifdef applied to Dash's CreateSockOS(sa_family_t), including its extra AF_UNIX protocol guard
- src/rpc/mining.cpp, src/rpc/client.cpp, src/test/rpc_tests.cpp: Dash-only `#if ENABLE_MINER` changed to `#ifdef`, as --disable-miner (Dash's win64/macOS CI) leaves it undefined under -Wundef
@DCG-Claude

Copy link
Copy Markdown
Collaborator Author

Maintainer controls

Tick a box; backportsys acts within a few minutes, then clears it. For other requests, leave a review comment.

  • 🔒 Hands off — stop every automated update to this branch
  • 🔄 Rebase onto current develop
  • ❌ Close — abandon this batch and release its items

Hands off persists after its box clears: no automated branch updates until operator release (not tracker Release hold). Close abandons the batch and releases its items.

Review effort

🔴 careful overall (2 quick, 2 careful).

🟢 identical to upstream, or small declared differences in docs, tests or build scripts · 🟡 a few lines of Dash code differ or were placed differently, upstream code skipped as not needed, an undeclared omission, or release plumbing (depends, guix, workflows, test framework) differs · 🔴 larger code differences, any difference in consensus, key or Dash-subsystem code, or a decision below. The adapting lane's explanations are in the PR description and each commit body.

Upstream Effort Where it differs from upstream
bitcoin#30519 🔴 careful Dash code differs from upstream in src/init.h; docs/tests/build differ in ci/test/00_setup_env_native_tsan.sh; same lines as upstream in src/crypto/sha256.cpp; placement unchecked (adapted pick)
bitcoin#29876 🔴 careful Dash code differs from upstream in src/crypto/x11/sph_types.h, src/netbase.cpp, src/rpc/client.cpp, src/rpc/mining.cpp; docs/tests/build differ in src/test/rpc_tests.cpp; same lines as upstream, placement adapted for Dash in src/init.cpp; same lines as upstream in src/randomenv.cpp; placement unchecked (adapted pick)
bitcoin#29994 🟡 quick Dash code differs from upstream in src/init.cpp
bitcoin#29120 🟡 quick docs/tests/build differ in test/functional/mempool_accept.py; same lines as upstream, placement adapted for Dash in src/init.cpp

Needs maintainer input

Nothing. Reviewing means checking the differences listed above.

Local checks without a pass or fail result (fork CI's full run covers these):

Fork gate: thepastaclaw#146 at 0c23850 (CI green).

@thepastaclaw

thepastaclaw commented Nov 16, 2026 •

Copy link
Copy Markdown
Collaborator

✅ Final review complete — no blockers (commit 0c23850) · triage: normal

@coderabbitai

coderabbitai Bot commented Nov 16, 2026

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The changes update compiler flags and header handling, and change several preprocessor guards to test whether feature macros are defined. They also revise option help text and add a functional test for a signed spend from a confirmed bare-multisig output.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Merge Risk: Minimal · up to 0c238

This backport changes build flags, preprocessor guards, help text, and adds one functional test. No runtime defect was identified. The only failing check is the missing PR milestone, which can be fixed by setting one.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names four upstream Bitcoin Core PRs being backported. The changeset includes the -Wundef build change, the libc++ TSAN include flag, the help text updates, and the bare multisig test. The t…
Description check Passed The description states that the PR backports four Bitcoin Core v0.28 pull requests to Dash. It lists each upstream PR and the Dash-specific adaptations. The files it names match the raw summary, inclu…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names four upstream Bitcoin Core PRs being backported. The changeset includes the -Wundef build change, the libc++ TSAN include flag, the help text updates, and the bare multisig test. The title is a list of PR numbers only. It identifies the change set accurately but does not name the main change. This is partially related, so the check passes.

Full details: Description check

Explanation

The description states that the PR backports four Bitcoin Core v0.28 pull requests to Dash. It lists each upstream PR and the Dash-specific adaptations. The files it names match the raw summary, including ci/test/00_setup_env_native_tsan.sh, src/init.cpp, src/netbase.cpp, src/rpc/mining.cpp, and test/functional/mempool_accept.py. The description is directly related to the changeset.

Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: fe1e8454-9cac-4267-bfab-0f2b26d35e20
Commits

Reviewing files that changed from the base of the PR and between ebbd1c2 and 0c23850.

Files selected for processing: 13

  • ci/test/00_setup_env_native_tsan.sh
  • configure.ac
  • src/Makefile.am
  • src/crypto/sha256.cpp
  • src/crypto/x11/sph_types.h
  • src/init.cpp
  • src/init.h
  • src/netbase.cpp
  • src/randomenv.cpp
  • src/rpc/client.cpp
  • src/rpc/mining.cpp
  • src/test/rpc_tests.cpp
  • test/functional/mempool_accept.py
Files with no reviewable changes: 1

  • src/init.h

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 1 remain after this review.

@thepastaclaw thepastaclaw left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Final validation — Phase 1 + Phase 2

The reviewed range faithfully implements the four stated Bitcoin Core backports with the documented Dash-specific adaptations. No actionable correctness, security, build, test, or architecture issues were found; completed build and lint checks passed, while several test jobs remain in progress and the milestone check failure is procedural rather than code-related.

Review provenance

Source: reviewer 1: muse-spark-1.3-contributor (agent: phase1-reviewer, role: general); reviewer 2: gpt-6.1-sol (agent: phase2-reviewer, role: general); reviewer 3: gpt-6.1-sol (agent: phase2-reviewer, role: backport-reviewer); reviewer 4: gpt-6.1-sol (agent: phase2-reviewer, role: dash-core-commit-history); reviewer 5: gpt-6.1-sol (agent: phase2-reviewer, role: general); reviewer 6: gpt-6.1-sol (agent: phase2-reviewer, role: backport-reviewer); reviewer 7: gpt-6.1-sol (agent: phase2-reviewer, role: dash-core-commit-history); final verifier: gpt-6.1-sol (agent: sol-verifier, role: final-verifier)

  • Triage: normal by gpt-6.1-sol (effort low) — This is a cross-cutting backport spanning build configuration, compiler-warning fixes, CI, documentation, and functional tests, but it does not itself alter consensus, funds movement, cryptography, networking deserialization, or storage.
  • Phase 1 reviewers: muse-spark-1.3-contributor — general (completed, effort xhigh); agent phase1-reviewer
  • Phase 1 model: muse-spark-1.3-contributor — not quota-gated; passed over gemini-3.8-flash-high (antigravity quota lookup failed), glm-5.3-flash (not used above high effort; tier asks max)
  • Second Phase-2 pass: on this first full review every Phase-2 reviewer also ran a second, independent time, and the verifier weighed both sets
  • Fresh verifier: gpt-6.1-sol — final-verifier; agent sol-verifier
  • Phase 2 reviewers: gpt-6.1-sol — general (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — backport-reviewer (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — dash-core-commit-history (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — general (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — backport-reviewer (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — dash-core-commit-history (completed, effort high); agent phase2-reviewer

@thepastaclaw thepastaclaw added the pastaclaw:approved thepastaclaw's latest review approved this PR label Nov 16, 2026
@PastaPastaPasta PastaPastaPasta added this to the 24.1 milestone Nov 16, 2026

@PastaPastaPasta PastaPastaPasta left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK

@PastaPastaPasta
PastaPastaPasta merged commit 00a6dcf into dashpay:develop Nov 16, 2026
49 of 50 checks passed
@thepastaclaw thepastaclaw removed the pastaclaw:approved thepastaclaw's latest review approved this PR label Nov 16, 2026
PastaPastaPasta added a commit that referenced this pull request Nov 16, 2026
…itcoin#30664, bitcoin#31013, bitcoin#31395)

bc908d1 partial Merge bitcoin#30664: build: Remove Autotools-based build system (pasta)
69db231 doc: describe the CMake build (pasta)
e162a2a guix: make the build-id check reliable and report its failures (pasta)
2584f0b guix: build releases with CMake (pasta)
0feb3b3 ci: build and test every job with CMake (pasta)
1ac032c Merge bitcoin#31013: depends: For mingw cross compile use -gcc-posix to prevent library conflict (laanwj)
22ee095 Merge bitcoin#31395: build: Set shared linker flags in toolchain file (TheCharlatan)
313e982 build: adapt the CMake build to Dash (pasta)
a4176c8 partial Merge bitcoin#30454: build: Introduce CMake-based build system (merge-script)

Pull request description:

  ## Issue being fixed or feature implemented

  Bitcoin Core replaced Autotools with CMake (bitcoin#30454 added the CMake build and switched CI, Guix and the documentation; bitcoin#30664 removed Autotools). Since then every upstream backport carries build-system changes that Dash cannot apply, and keeping two build systems in step would double the maintenance for every source, flag or dependency change.

  This PR switches Dash Core to CMake and removes the Autotools build.

  ## What was done?

  The series is nine commits, in this order:

  1. **`partial Merge bitcoin#30454`** imports upstream's CMake tree at merge commit `338bc2cd261`: the top-level `CMakeLists.txt`, the `cmake/` modules, the per-directory `CMakeLists.txt` and `depends/toolchain.cmake.in`, with source lists and target names changed to the Dash tree.
  2. **`build: adapt the CMake build to Dash`** brings it to parity with the Autotools build it replaces:
     - Dash feature detection: the miner, the X11 SSSE3/AES-NI/ARM sources, stacktraces and crash hooks, zstd.
     - Version reporting, executable names, Windows resources and the NSIS installer.
     - The public `libdashconsensus` with its existing `.so.0` soname.
     - dashbls compiled from Dash's source list, with blst from depends.
     - The Dash Platform GUI (`-DENABLE_PLATFORM_GUI`, enabled by depends' `PLATFORM_GUI`).
     - Dash source lists, WERROR builds, and the `check-symbols`, `check-security`, `check-stdlib-paths` and `osx_debug` maintenance targets.
     - Linux binaries keep their `-Wl,--build-id=sha1` build-id, which the Guix release script needs to match them to their split debug files.
     - `ctest` runs what `make check` ran, including the dashbls and minisketch tests.
  3. **`Merge bitcoin#31395`** applies depends' linker flags to shared libraries too, so the cross-compiled `libdashconsensus` links with the depends linker.
  4. **`Merge bitcoin#31013`** uses the posix variant of the mingw C compiler as well as the C++ one. When both variants are installed and win32 is the default, as in the CI image, CMake otherwise links the win32 libstdc++, and `test_dash.exe` deadlocks.
  5. **`ci:`**
     - `ci/dash/build_src.sh` configures every job with CMake, keeping the `build-ci/dashcore-$BUILD_TARGET` layout the workflows bundle from. Jobs built on depends use its toolchain file. The ASan job builds against system libraries (#8106), so it has no toolchain file to turn on UPnP, NAT-PMP, zstd and USDT and names them in its own options.
     - `test_unittests.sh` runs `ctest`.
     - Every `ci/test/00_setup_env_*.sh` maps its configure flags to CMake options, with extra flags passed through `APPEND_CPPFLAGS`, `APPEND_CFLAGS`, `APPEND_CXXFLAGS` and `APPEND_LDFLAGS`.
     - The fuzz and MSan jobs keep the standard-library debug defines of their `DEBUG=1` depends build. The toolchain file applies those to Debug builds only, so the jobs pass them in `APPEND_CPPFLAGS`.
     - The tidy job uses CMake's `compile_commands.json` instead of Bear.
     - Functional tests run from the build directory, as upstream does.
  6. **`guix: build releases with CMake`**: `contrib/guix/libexec/build.sh` configures, builds, checks, installs and deploys with CMake, following upstream's e821f0a. macOS releases keep their dSYM debug archives, and Windows releases still disable the miner. The Debian packaging and the GitHub Actions deploy image use CMake too.
  7. **`guix: make the build-id check reliable`**: the check reads all of `readelf`'s output, so binaries with USDT probe notes are no longer misreported as lacking a build-id under `pipefail`, and it prints the binaries that fail instead of exiting silently.
  8. **`doc:`** The build guides, developer notes, depends, test and fuzzing docs and the agent guide describe the CMake workflow. `doc/release-notes-7481.md` announces the switch.
  9. **`partial Merge bitcoin#30664`** removes Autotools:
     - `autogen.sh`, `configure.ac`, every `Makefile.am`, the `src/Makefile.*.include` fragments and `build-aux/m4`.
     - `share/genbuild.sh`, depends' `config.site.in`, `src/.bear-tidy-config`, `src/univalue/sources.mk`.
     - The convenience Makefiles in `src/`, `src/qt` and `src/test`, and the `.gitignore` entries for in-tree build products.
     - Leftover references in comments, scripts and `.editorconfig`.

  The vendored subtrees keep their own build files, and depends packages keep their upstream Autotools builds.

  Not carried over:
  - From upstream: `vcpkg.json`, `CMakePresets.json` (MSVC presets only) and the MSVC build guide. Dash Core does not build with MSVC, and CMake stops with an error there, so they would describe a build that cannot run. They can come back with MSVC support.
  - From upstream: test and fuzz registrations whose source files Dash does not have, because the upstream change is not backported yet or belongs to a feature Dash does not adopt.
  - From Autotools: the experimental shared `libdashkernel` (`--with-experimental-kernel-lib --enable-shared`), which the CMake build does not provide, so the nowallet CI job no longer builds it.
  - From Autotools: `--enable-suppress-external-warnings` has no CMake equivalent; vendored headers are included as system headers instead.
  - The win64 CI job builds `install` instead of `deploy`. The CI image has no `makensis`, and Autotools skipped the installer silently, so CI never built it. Guix still does.

  ## How Has This Been Tested?

  CI at the PR head covers every job: cross builds, sanitizers, fuzzing, multiprocess, tidy, `ctest` and the full functional suite.

  Before the final history cleanup, on a tree that differs from this head only by the points listed below:
  - The Guix build passed on all 7 hosts, which exercises `check-security`, `check-symbols`, `check-stdlib-paths`, the macOS dSYM archives, the NSIS installer and the build-id debug split.
  - Locally on x86_64 Linux: built depends with `PLATFORM_GUI=1`, configured with `-DWERROR=ON -DBUILD_BENCH=ON -DBUILD_FUZZ_BINARY=ON -DENABLE_EXTERNAL_SIGNER=ON -DWITH_ZMQ=ON` and built everything, including dash-qt with the Platform SDK. `ctest` passed 183/183, and `build/test/functional/test_runner.py` passed wallet_basic, wallet_descriptor, tool_wallet, rpc_blockchain, mining_basic, feature_dip3_deterministicmns and feature_llmq_signing.

  Changed since then: the MSVC files were dropped, the minisketch test was added to `ctest`, the fuzz and MSan jobs got their debug defines back, and `gen-dash-conf.sh` and `ci/dash/build-docker.sh` default to `build/`. After #8136 merged, its new `span_tests.cpp` was added to the unit-test list, and after #8072 merged, its new `package_eval.cpp` was added to the fuzz target list; those rebases were not built locally. After #7679 merged, the dashbls target picked up its new sources, `dashbls_runtest` gained `test_secure.cpp`, and `dashbls_runbench` was added; on macOS arm64 those three targets build with `-Wall -Wextra -Werror` from `cmake/dashbls.cmake` in a small wrapper project, and `dashbls_runtest` passes. After #8165 merged (`-Wundef`, with the X11 headers fixed for it), the CMake build stopped downgrading `-Wundef` under `WERROR`, and the TSan job passes `-D_LIBCPP_REMOVE_TRANSITIVE_INCLUDES`; on macOS arm64 that head builds with `-DWERROR=ON` (no GUI), and `crypto_tests`, `hash_tests`, `netbase_tests`, `bls_tests` and `dashbls_runtest` pass. On macOS arm64 the tree configures with CMake, and the new `libminisketch_test` builds and passes.

  ## Breaking Changes

  Building from source now requires CMake 3.22 or later: `cmake -B build && cmake --build build`, with `--toolchain depends/<host>/toolchain.cmake` for depends builds. `./autogen.sh` and `./configure` no longer exist. Functional tests are run as `build/test/functional/test_runner.py`. Release artifacts and executable names are unchanged.

  ## Checklist:
  - [x] I have performed a self-review of my own code
  - [x] I have made corresponding changes to the documentation
  - [ ] I have assigned this pull request to a milestone _(if you have permission to set one)_

  🤖 Generated with [Claude Code](https://claude.com/claude-code)

Top commit has no ACKs.

Tree-SHA512: b719a9ceb5081a1aeec09afb9fe303bbb4f9a180aee5d5cbd8cae4955c8b31451be341f9873c02d4ef36b2fbd991170477ee053994e89b598f864a2182bdad85
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants