aboutsummaryrefslogtreecommitdiff
path: root/contrib
AgeCommit message (Collapse)Author
2023-10-10docs: fix typovuittont60
2023-10-05headerssync: update params for 26.xfanquake
2023-10-05Merge bitcoin/bitcoin#25970: Add headerssync tuning parameters optimization ↵fanquake
script to repo 3d420d8f28f2d351abf8b0afe90848110e15d50c Add instructions for headerssync-params.py to release-process.md (Pieter Wuille) 53d7d35b5899685cd1577156250068e0cab502f4 Update parameters in headerssync.cpp (Pieter Wuille) 7899402cff708319b1c5181242a97557eefe1ae7 Add headerssync-params.py script to the repository (Pieter Wuille) Pull request description: Builds upon #25946, as it incorporates changes based on the selected values there. This adds the headerssync tuning parameters optimization script from https://gist.github.com/sipa/016ae445c132cdf65a2791534dfb7ae1 to the repository, updates the parameters based on its output, and adds release process instructions for doing this update in the future. A few considerations: * It would be a bit cleaner to have these parameters be part of `CChainParams`, but due to the nature of the approach, it really only applies to chains with unforgeable proof-of-work, which we really can only reasonably expect from mainnet, so I think it's fine to keep them local to `headerssync.cpp`. Keeping them as compile-time evaluatable constants also has a (likely negligible) performance impact (avoiding runtime modulo operations). * If we want to make sure the chainparams and headerssync params don't go out of date, it could be possible to run the script in CI, and and possibly even have the parameters be generated automatically at build time. I think that's overkill for how unfrequently these need to change, and running the script has non-trivial cost (~minutes in the normal python interpreter). * A viable alternative is just leaving this out-of-repo entirely, and just do ad-hoc updating from time to time. Having it in the repo and release notes does make sure it's not forgotten, though adds a cost to contributors/maintainers who follow the process. ACKs for top commit: ajtowns: reACK 3d420d8f28f2d351abf8b0afe90848110e15d50c Tree-SHA512: 03188301c20423c72c1cbd008ccce89b93e2898edcbeecc561b2928a0d64e9a829ab0744dc3b017c23de8b02f3c107ae31e694302d3931f4dc3540e184de1963
2023-10-03Merge bitcoin/bitcoin#28507: contrib/bash-completions: use package naming ↵fanquake
conventions 360b917674e63c1e95119040463b3f50976bf331 contrib/bash-completions: use package naming conventions (Erik Arvstedt) Pull request description: #### Copy of commit msg This naming scheme supports auto-detection and on-demand loading of completions. See https://github.com/scop/bash-completion/blob/ba109693ee2284f6a82f8f0e1563baf071252df9/README.md#faq, section "Where should I put it to be sure that interactive bash shells will find it and source it", keyword `foo.bash`. Previously, distro package maintainers had to rename these files manually. ACKs for top commit: willcl-ark: ACK 360b917674e63c1e95119040463b3f50976bf331 Tree-SHA512: 6dd1f62309e877402fac2f7aec785d3053a1fd3fdeae38abc961c3f61269eb664a2489b6fa8294bd706d8ac387c7af3ac66cd7a852810f69371fa8ae991afacb
2023-09-30contrib: add script to demo/test assumeutxoJames O'Beirne
Add the script to the shellcheck exception list since the quoted variables rule needs to be violated in order to get bitcoind to pick up on $CHAIN_HACK_FLAGS.
2023-09-28Add headerssync-params.py script to the repositoryPieter Wuille
2023-09-19contrib/bash-completions: use package naming conventionsErik Arvstedt
This naming scheme supports auto-detection and on-demand loading of completions. See https://github.com/scop/bash-completion/blob/ba109693ee2284f6a82f8f0e1563baf071252df9/README.md#faq, section "Where should I put it to be sure that interactive bash shells will find it and source it". Previously, distro package maintainers had to rename these files manually.
2023-09-15build: remove dmg dependenciesfanquake
2023-09-15macdeploy: remove DMG generation from deploy scriptfanquake
2023-09-15build: produce a .zip for macOS distributionHennadii Stepanov
Instead of a .dmg. Co-authored-by: fanquake <fanquake@gmail.com>
2023-09-15build: add -zip option to macdeployqtplusfanquake
This zips the app bundle in /dist.
2023-09-07doc: s/--no-substitute/--no-substitutes in guix/INSTALLfanquake
2023-08-30guix: remove GCC 10 workaround from NSISfanquake
Fixed upstream in 3.06, see https://github.com/kichik/nsis/commit/229b6136c41ba5caba25936f4927476d20aa283f. https://sourceforge.net/p/nsis/bugs/1248/
2023-08-27guix: use clang-toolchain-15 for macOS compilationfanquake
2023-08-24security: restrict abis in bitcoind.serviceCharlie
It's recommended to restrict the possible application binary interfaces that can be used when setting `MemoryDenyWriteExecute=true` to ensure it cannot be circumvented.
2023-08-24guix: drop Windows broken-longjmp.patchfanquake
This is no-longer required, now that we are building using GCC 10.4.0.
2023-08-24guix: drop NSIS patch now that we use 3.09fanquake
See https://sourceforge.net/p/nsis/bugs/1283/.
2023-08-24guix: use cross-* keyword argumentsfanquake
Using the new time-machine results in warnings about consistently using keyword arguments: ```bash guix environment: warning: 'cross-kernel-headers' must be used with keyword arguments guix environment: warning: 'cross-libc' must be used with keyword arguments ```
2023-08-24guix: update time-machine to 160f78a4d92205df986ed9efcce7d3aac188cb24fanquake
In our time-machine environment this changes the following: GCC 10.3.0 -> 10.4.0 Binutils 2.37 -> 2.38 Linux Libre Headers 5.15.37 -> 5.15.127 git 2.36.0 -> 2.41.0 mingw-w64 8.0.0 -> 11.0.1 NSIS 3.05 -> 3.09 xorriso 1.5.2 -> 1.5.6.pl02 Python 3.9 -> 3.10.7 Python-asn1crypto 1.4.0 -> 1.5.1 GCC 12.3.0 becomes available. LLVM 15.0.7 becomes available.
2023-08-24guix: update python-oscrypto to 1.3.0fanquake
This is required for bumping the time-machine, for compatibility with OpenSSL: oscrypto: openssl backend, 1.2.1, /tmp/guix-build-python-oscrypto-1.2.1.drv-0/source/oscrypto Traceback (most recent call last): File "/tmp/guix-build-python-oscrypto-1.2.1.drv-0/source/oscrypto/_openssl/_libcrypto_ctypes.py", line 304, in <module> libcrypto.EVP_PKEY_size.argtypes = [ File "/gnu/store/9dkl9fnidcdpw19ncw5pk0p7dljx7ijb-python-3.10.7/lib/python3.10/ctypes/__init__.py", line 387, in __getattr__ func = self.__getitem__(name) File "/gnu/store/9dkl9fnidcdpw19ncw5pk0p7dljx7ijb-python-3.10.7/lib/python3.10/ctypes/__init__.py", line 392, in __getitem__ func = self._FuncPtr((name_or_ordinal, self)) AttributeError: /gnu/store/2hr7w64zhr6jjznidyc2xi40d5ynhj9c-openssl-3.0.8/lib/libcrypto.so.3: undefined symbol: EVP_PKEY_size. Did you mean: 'EVP_PKEY_free'?
2023-08-24guix: backport glibc patch to fix powerpc buildfanquake
Do this prior to bumping the time-machine, to avoid the following build failure: ```bash /tmp/guix-build-glibc-cross-powerpc64le-linux-gnu-2.27.drv-0/build/string/memset-power8.o.dt -MT /tmp/guix-build-glibc-cross-powerpc64le-linux-gnu-2.27.drv-0/build/string/memset-power8.o ../sysdeps/powerpc/powerpc64/power4/memcmp.S: Assembler messages: ../sysdeps/powerpc/powerpc64/power4/memcmp.S:87: Error: unrecognized opcode: `ldbrx' ../sysdeps/powerpc/powerpc64/power4/memcmp.S:88: Error: unrecognized opcode: `ldbrx' ../sysdeps/powerpc/powerpc64/power4/memcmp.S:112: Error: unrecognized opcode: `ldbrx' ``` See: https://sourceware.org/git/?p=glibc.git;a=commit;h=9250e6610fdb0f3a6f238d2813e319a41fb7a810. https://github.com/gcc-mirror/gcc/commit/e154242724b084380e3221df7c08fcdbd8460674.
2023-08-22guix: consolidate Linux GCC packagefanquake
Refactor our Linux GCC to be a single 'package', and avoid the use of `package-with-extra-configure-variable`.
2023-08-22guix: consolidate glibc 2.27 packagefanquake
Refactor our glibc 2.27 to be a single 'package', and avoid the use of `package-with-extra-configure-variable`. This also lets us drop the `enable_werror` workaround, and just use --disable-werror directly. Employ the same workaround as the Guix glibc, to avoid a "permission denied" failure during build: ```bash make subdir=sunrpc -C sunrpc ..=../ subdir_install make[2]: Entering directory '/tmp/guix-build-glibc-cross-x86_64-linux-gnu-2.27.drv-0/source/sunrpc' .././scripts/mkinstalldirs /gnu/store/ga8jciqrd5lh52m572x3mk4q1smf5agq-glibc-cross-x86_64-linux-gnu-2.27/include/rpc mkdir -p -- /gnu/store/ga8jciqrd5lh52m572x3mk4q1smf5agq-glibc-cross-x86_64-linux-gnu-2.27/include/rpc /gnu/store/kvpvk5wh70wdbjnr83hh85rg22ysxm9h-coreutils-8.32/bin/install -c -m 644 rpc/netdb.h /gnu/store/ga8jciqrd5lh52m572x3mk4q1smf5agq-glibc-cross-x86_64-linux-gnu-2.27/include/rpc/netdb.h .././scripts/mkinstalldirs /gnu/store/ga8jciqrd5lh52m572x3mk4q1smf5agq-glibc-cross-x86_64-linux-gnu-2.27/include/nfs mkdir -p -- /gnu/store/ga8jciqrd5lh52m572x3mk4q1smf5agq-glibc-cross-x86_64-linux-gnu-2.27/include/nfs /gnu/store/kvpvk5wh70wdbjnr83hh85rg22ysxm9h-coreutils-8.32/bin/install -c -m 644 ../sysdeps/unix/sysv/linux/nfs/nfs.h /gnu/store/ga8jciqrd5lh52m572x3mk4q1smf5agq-glibc-cross-x86_64-linux-gnu-2.27/include/nfs/nfs.h /gnu/store/kvpvk5wh70wdbjnr83hh85rg22ysxm9h-coreutils-8.32/bin/install -c -m 644 /tmp/guix-build-glibc-cross-x86_64-linux-gnu-2.27.drv-0/build/gnu/lib-names-64.h /gnu/store/ga8jciqrd5lh52m572x3mk4q1smf5agq-glibc-cross-x86_64-linux-gnu-2.27/include/gnu/lib-names-64.h /gnu/store/kvpvk5wh70wdbjnr83hh85rg22ysxm9h-coreutils-8.32/bin/install -c -m 644 etc.rpc /etc/rpc /gnu/store/kvpvk5wh70wdbjnr83hh85rg22ysxm9h-coreutils-8.32/bin/install: cannot create regular file '/etc/rpc': Permission denied make[2]: *** [Makefile:197: /etc/rpc] Error 1 ```
2023-08-18guix: pre time-machine bump changes (Windows)fanquake
Split out of #27897. This is some refactoring to the Windows Guix build that facilitates bumping our Guix time-machine. Namely, avoiding `package-with-extra-configure-variable`, which is non-functional in the newer time-machine, see https://issues.guix.gnu.org/64436. At the same time, consolidate our Windows GCC build into mingw-w64-base-gcc. Rename `gcc-10-remap-guix-store.patch` to avoid changing it whenever GCC changes. We move the old `building-on` inside `explicit-cross-configure`, so that non-windows builds continue to work. Note that `explicit-cross-configure` will be going away entirely (see #27897).
2023-08-18Merge bitcoin/bitcoin#28237: refactor: Enforce C-str fmt strings in ↵fanquake
WalletLogPrintf() fa60fa3b0cba4a30726af8e0e9d1e84e14849eda bitcoin-tidy: Apply bitcoin-unterminated-logprintf to spkm as well (MarcoFalke) faa11434fe38aa82892802adb6d879d112ae1675 refactor: Enable all clang-tidy plugin bitcoin tests (MarcoFalke) fa6dc57760e0a04dbb2e365ca7ad9fd8171ebfdb refactor: Enforce C-str fmt strings in WalletLogPrintf() (MarcoFalke) fa244f3321de7884f530bb38493a8d0a0cec86ab doc: Fix bitcoin-unterminated-logprintf tidy comments (MarcoFalke) Pull request description: All fmt functions only accept a raw C-string as argument. There should never be a need to pass a format string that is not a compile-time string literal, so disallow it in `WalletLogPrintf()` to avoid accidentally introducing it. Apart from consistency, this also fixes the clang-tidy plugin bug https://github.com/bitcoin/bitcoin/pull/26296#discussion_r1286821141. ACKs for top commit: theuni: ACK fa60fa3b0cba4a30726af8e0e9d1e84e14849eda Tree-SHA512: fa6f4984c50f9b34e850bdfee7236706af586e512d866cc869cf0cdfaf9aa707029c210ca72d91f85e75fcbd8efe0d77084701de8c3d2004abfd7e46b6fa9072
2023-08-16bitcoin-tidy: Apply bitcoin-unterminated-logprintf to spkm as wellMarcoFalke
2023-08-14Merge bitcoin/bitcoin#28258: bitcoin-tidy: fix macOS buildfanquake
bb3263d3e3d9f9d4db86dde679f469e7278bf737 bitcoin-tidy: fix macOS build (Cory Fields) Pull request description: [LLVM uses these options](https://github.com/llvm/llvm-project/blob/main/llvm/cmake/modules/HandleLLVMOptions.cmake#L178) for building as well, so there's precedent. Also fix the shared library extension which was incorrectly being set to dylib. Thanks to jonatack for reporting and debugging. ACKs for top commit: jonatack: ACK bb3263d3e3d9f9d4db86dde679f469e7278bf737 tested with arm64 macos 13.5, llvm 16.0.6 and cmake 3.27.2 Tree-SHA512: de7bfd497f38f1565a14d217d0b057cbfa788bdda702b5942b7f0b55947ae5e1c05af13e7d6a073ed036bc4db57035868f180034508b6e084ab9b901a5baaf2f
2023-08-10bitcoin-tidy: fix macOS buildCory Fields
LLVM uses these options for building as well, so there's precedent. Also fix the shared library extension which was incorrectly being set to dylib
2023-08-10doc: use llvm-config for bitcoin-tidy examplefanquake
An LLVM installation will have `llvm-config` available to query for info. Ask it for the `--cmakedir`, and use that in our bitcoin-tidy example, rather than listing multiple different (potential) paths per distro/OS etc.
2023-08-08refactor: Enforce C-str fmt strings in WalletLogPrintf()MarcoFalke
2023-08-08doc: Fix bitcoin-unterminated-logprintf tidy commentsMarcoFalke
* Move module description from test to LogPrintfCheck * Add test doc * Remove unused comment, see https://github.com/bitcoin/bitcoin/pull/26296/files#r1279351539
2023-08-03tidy: Integrate bicoin-tidy clang-tidy pluginfanquake
Enable `bitcoin-unterminated-logprintf`. Co-authored-by: Cory Fields <cory-nospam-@coryfields.com>
2023-07-25valgrind: add suppression for bug 472219fanquake
Now that https://bugs.kde.org/show_bug.cgi?id=472219 has been fixed upstream in: https://sourceware.org/git/?p=valgrind.git;a=commit;h=6ce0979884a8f246c80a098333ceef1a7b7f694d Add a supression to ignore the bug until we are using a fixed version of Valgrind. Related to #28072.
2023-07-18contrib: move user32.dll from bitcoind.exe libsfanquake
The user interface library is no-longer needed by `bitcoind.exe`, or utils, only `bitcoin-qt.exe`. Add missing lib doc.
2023-07-12guix: backport glibc patch to prevent redundant librt linkfanquake
2023-07-12contrib: remove librt from release depsfanquake
2023-06-30Merge bitcoin/bitcoin#27999: contrib: add macOS test for fixup_chains usagefanquake
7f96638723a08edf4341a2f4c06b2aa41378fcf7 contrib: add macOS fixup_chains check to security-check (fanquake) 3dca683cb738fccd2dcd6f85033d92979a072284 build: support -no_fixup_chains in ld64 (fanquake) Pull request description: Followup to #27676, adding the check for chained fixups. Somewhat annoyingly, we have to patch support for `-no_fixup_chains` into ld64. As it doesn't seem to have been added [until a later version](https://github.com/apple-oss-distributions/ld64/blob/59a99ab60399c5e6c49e6945a9e1049c42b71135/src/ld/Options.cpp#L4172). Guix Build: ```bash 0e17d462808f86aa7157e27a957da88fd1adeb491ad6c01138aca93e5ad1d018 guix-build-7f96638723a0/output/arm64-apple-darwin/SHA256SUMS.part ceb208e6374f5d7367b73128e90ca6eaeea15d50c69e49c8cf75b47212525ad7 guix-build-7f96638723a0/output/arm64-apple-darwin/bitcoin-7f96638723a0-arm64-apple-darwin-unsigned.dmg e31663554cfde8a37a9f3438c9c895dde94b90ff87e28f12f78be71ef6421d93 guix-build-7f96638723a0/output/arm64-apple-darwin/bitcoin-7f96638723a0-arm64-apple-darwin-unsigned.tar.gz 68a7bbc42418641eab391a85725b5c2f3c46d38a7acc07e7a8cef98909be07ec guix-build-7f96638723a0/output/arm64-apple-darwin/bitcoin-7f96638723a0-arm64-apple-darwin.tar.gz 38d966ad93e7384f4f1ce16faded003a675ecce7be1987e6c4eee8e4b82c0432 guix-build-7f96638723a0/output/dist-archive/bitcoin-7f96638723a0.tar.gz 9d314f595d897a715a321a9fba0d552220fbd4bf69aff84eb8c0001cdb48234f guix-build-7f96638723a0/output/x86_64-apple-darwin/SHA256SUMS.part c218ebfd0e96348c4912e6d522492b621bb043ef45b75105ff1fde979d1004d0 guix-build-7f96638723a0/output/x86_64-apple-darwin/bitcoin-7f96638723a0-x86_64-apple-darwin-unsigned.dmg 1c5ff7fa82f5c76d7d8b9582ad5202f4a82a917102ecafdc3c1fb7b783f6bc3e guix-build-7f96638723a0/output/x86_64-apple-darwin/bitcoin-7f96638723a0-x86_64-apple-darwin-unsigned.tar.gz 15fb01e5afcc842db6a3e793b42c70c05ce07bec79e0d2d605e241901ff9f639 guix-build-7f96638723a0/output/x86_64-apple-darwin/bitcoin-7f96638723a0-x86_64-apple-darwin.tar.gz ``` ACKs for top commit: theuni: utACK 7f96638723a08edf4341a2f4c06b2aa41378fcf7. hebasto: ACK 7f96638723a08edf4341a2f4c06b2aa41378fcf7, I have reviewed the code and the patch, and they look OK. TheCharlatan: ACK 7f96638723a08edf4341a2f4c06b2aa41378fcf7 Tree-SHA512: 7f94710460f54b2afe3c9f5d57107b71436c59b799b15f78e5e3011c3c4f6b23a3acc1008eccea9c22226a200774c82900bad6c6236ab6c5c48a17dec3f2d5a2
2023-06-30Merge bitcoin/bitcoin#28009: script, test: python typing and linter updatesfanquake
6c97757a480b6e71a0750330d69ff18ac7cc6127 script: appease spelling linter (Jon Atack) 1316119ce7ba3de4135bbf1e5ac28c9ea26f62e1 script: update ignored-words.txt (Jon Atack) 146c861da2e4236997bee3eed6110a5016a8b86b script: update linter dependencies (Jon Atack) 92408224a4cb2f454465d5ff8445c247f2c4318a test: fix PEP484 no implicit optional argument types errors (Jon Atack) f86a3014338de6a2204bbdda10795b75ef6654c0 script, test: add missing python type annotations (Jon Atack) Pull request description: With these updates, `./test/lint/lint-python.py` and `./test/lint/lint-spelling.py` should be green again for developers using relatively recent Python dependencies, in particular mypy 0.991 (released 11/2022) and later. Please see the commit messages for details. ACKs for top commit: fanquake: ACK 6c97757a480b6e71a0750330d69ff18ac7cc6127 Tree-SHA512: 8a46a4d36d5978affdcecf4f2ace20ca1b52d483e098304911a2169afe60ccb9b042fa90c04b762d94f3ce53d2cafe6f24476ae839867a770c7f31e7e7242d99
2023-06-30doc: Fix verify-binaries link in contrib READMETheCharlatan
2023-06-29script, test: add missing python type annotationsJon Atack
Fix warnings for these files when ./test/lint/lint-python.py is run using mypy 0.991 (released 11/2022) and later: "By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]" For details, see: https://mypy-lang.blogspot.com/2022/11/mypy-0990-released.html
2023-06-29contrib: add macOS fixup_chains check to security-checkfanquake
Followup to #27676.
2023-06-28guix: Specify symbols in modules explicitlyHennadii Stepanov
This change improves the maintainability of the manifest: (1) It allows to remove the module when the specified symbols are no longer used. (2) It prevents accidental use of other symbols, such as `bash` instead of `bash-minimal`.
2023-06-28guix: Drop unneeded modulesHennadii Stepanov
2023-06-28guix: Unify fetch methodsHennadii Stepanov
2023-06-28Merge bitcoin/bitcoin#27813: guix: Update `python-lief` package to 0.13.2fanquake
529c92e837b28169b501562efe7b5b7120a2ebbb guix: Update `python-lief` package to 0.13.2 (Hennadii Stepanov) Pull request description: The Guix's `python-lief` package is going to move to using external deps, rather than the bundled ones (https://lists.gnu.org/archive/html/guix-patches/2023-05/msg01302.html). We want to continue using our own package indefinitely, to keep the build simpler, and allow for easier updating. Changes in `contrib/devtools/security-check.py` are caused by https://github.com/lief-project/LIEF/commit/6357c6370bf102b580b8d65c3aad1c3010b0e07d. Also see: https://github.com/bitcoin/bitcoin/pull/27507. ACKs for top commit: fanquake: ACK 529c92e837b28169b501562efe7b5b7120a2ebbb Tree-SHA512: ad81111b090a39b380fe25bb27b54a339e78a158f462c7adda25d5ee55f0d654107b1486b29b9687ad0808e27b01e04f53a0e8ffc6600b79103d6bd0dfec64ef
2023-06-23guix: Update `python-lief` package to 0.13.2Hennadii Stepanov
2023-06-22contrib: remove macOS lazy_bind checkfanquake
In future, this will be replaced by a check for fixup_chains usage.
2023-06-22depends: Bump MacOS minimum runtime requirement to 11.0Cory Fields
This is necessary as the new fixup_chains linker behavior is only valid when the runtime target is >=11.0.
2023-06-22depends: bump darwin clang to 11.1Cory Fields
Unfortunately clang 10 does not understand "-mmacosx-version-min=11.0", as it expects to see only 10.x. Bump minimally to 11.1 to fix that problem. This will likely be our last binary toolchain bump, as it will soon be replaced with usage of upstream vanilla llvm.
2023-06-12Use `int32_t` type for most transaction size/weight valuesHennadii Stepanov
This change gets rid of a few casts and makes the following commit diff smaller.