Inside Bitcoin
Opening the selected file…
Inside Bitcoin
Opening the selected file…
The code behind the network, with room to understand it.
Release published 2026-10-28 · Snapshot fetched 2026-11-01. Latest stable release at fetch time; development branches and Git history are excluded. Only the selected code window and visible folders load here.
1Contents2========3This directory contains tools for developers working on this repository.5deterministic-fuzz-coverage6===========================8A tool to check for non-determinism in fuzz coverage. To get the help, run:10```11cargo run --manifest-path ./contrib/devtools/deterministic-fuzz-coverage/Cargo.toml -- --help12```14To execute the tool, compilation has to be done with the build options:16```17-DCMAKE_C_COMPILER='clang' -DCMAKE_CXX_COMPILER='clang++' -DBUILD_FOR_FUZZING=ON -DCMAKE_CXX_FLAGS='-fprofile-instr-generate -fcoverage-mapping'18```20Both llvm-profdata and llvm-cov must be installed. Also, the qa-assets21repository must have been cloned. Finally, a fuzz target has to be picked22before running the tool:24```25cargo run --manifest-path ./contrib/devtools/deterministic-fuzz-coverage/Cargo.toml -- $PWD/build_dir $PWD/qa-assets/fuzz_corpora fuzz_target_name26```28deterministic-unittest-coverage29===========================31A tool to check for non-determinism in unit-test coverage. To get the help, run:33```34cargo run --manifest-path ./contrib/devtools/deterministic-unittest-coverage/Cargo.toml -- --help35```37To execute the tool, compilation has to be done with the build options:39```40-DCMAKE_C_COMPILER='clang' -DCMAKE_CXX_COMPILER='clang++' -DCMAKE_CXX_FLAGS='-fprofile-instr-generate -fcoverage-mapping'41```43Both llvm-profdata and llvm-cov must be installed.45```46cargo run --manifest-path ./contrib/devtools/deterministic-unittest-coverage/Cargo.toml -- $PWD/build_dir <boost unittest filter>47```49clang-format-diff.py50===================52A script to format unified git diffs according to [.clang-format](../../src/.clang-format).54Requires `clang-format`, installed e.g. via `brew install clang-format` on macOS,55or `sudo apt install clang-format` on Debian/Ubuntu.57For instance, to format the last commit with 0 lines of context,58the script should be called from the git root folder as follows.60```61git diff -U0 HEAD~1.. | ./contrib/devtools/clang-format-diff.py -p1 -i -v62```64gen-manpages.py65===============67A small script to automatically create manpages in ../../doc/man by running the release binaries with the -help option.68This requires help2man which can be found at: https://www.gnu.org/software/help2man/70This script assumes a build directory named `build` as suggested by example build documentation.71To use it with a different build directory, set `BUILDDIR`.72For example:74```bash75BUILDDIR=$PWD/my-build-dir contrib/devtools/gen-manpages.py76```78headerssync-params.py79=====================81A script to generate optimal parameters for the headerssync module (stored in src/kernel/chainparams.cpp). It takes no command-line82options, as all its configuration is set at the top of the file. It runs many times faster inside PyPy. Invocation:84```bash85pypy3 contrib/devtools/headerssync-params.py86```88gen-bitcoin-conf.sh89===================91Generates a bitcoin.conf file in `share/examples/` by parsing the output from `bitcoind --help`. This script is run during the92release process to include a bitcoin.conf with the release binaries and can also be run by users to generate a file locally.93When generating a file as part of the release process, make sure to commit the changes after running the script.95This script assumes a build directory named `build` as suggested by example build documentation.96To use it with a different build directory, set `BUILDDIR`.97For example:99```bash100BUILDDIR=$PWD/my-build-dir contrib/devtools/gen-bitcoin-conf.sh101```103circular-dependencies.py104========================106Run this script from the root of the source tree (`src/`) to find circular dependencies in the source code.107This looks only at which files include other files, treating the `.cpp` and `.h` file as one unit.109Example usage:111cd .../src112../contrib/devtools/circular-dependencies.py {*,*/*,*/*/*}.{h,cpp}
Independent explanations by MyBitcoinExplorer. Not affiliated with or endorsed by Bitcoin Core. Guides are educational and do not replace the source or its tests.
Bitcoin Core source © its contributors, distributed under the MIT license. Original notices and bundled third-party licenses are retained in the source tree.