687155df6b Merge bitcoin-core/secp256k1#1897: tests: check results before using outputs 8a700a355e Merge bitcoin-core/secp256k1#1907: release cleanup: bump version after 0.8.0 78657bf28b release cleanup: bump version after 0.8.0 6e2c8bc4ec Merge bitcoin-core/secp256k1#1906: release: prepare for 0.8.0 5840c19b4e release: prepare for 0.8.0 3873647bfb Merge bitcoin-core/secp256k1#1904: sha256: cross-check caller supplied compression function c84ea46561 sha256: cross-check caller supplied compression function f8c75f89a5 Merge bitcoin-core/secp256k1#1903: changelog: add entry for #1821 2076b06a42 changelog: add entry for #1821 7fecac74ae Merge bitcoin-core/secp256k1#1709: release-process: Add signing of tarball plus minor improvements 12d9cfd86e release-process: Add attaching output of check-abi.sh to PR b0a0ae8246 release-process: Add "cleaning up" 4a73b1ae27 release-process: Fix nits fae22e777e release-process: Add signing of tarball 34f00ca9d9 release-process: Refactor 1c2933bb87 Merge bitcoin-core/secp256k1#1902: changelog: add entry for #1859 51fc633e3e changelog: add entry for #1859 d77f44e9cd Merge bitcoin-core/secp256k1#1863: ellswift: don't declassify or leave sk in sha256 buffer 0ae17e304e ellswift: don't declassify or leave sk in sha256 buffer 0a9e788901 Merge bitcoin-core/secp256k1#1900: Use SHA256 override for pointers to known aux functions 300c9bb26d Merge bitcoin-core/secp256k1#1901: changelog: Add entry for #1869 44ba8cd7df changelog: Add entry for #1869 4147f8bdf6 header: Add note on SHA256 override and aux functions ed091bc49d ecdsa/ecdh: Use SHA256 override if known noncefp/hashfp is passed 209ed1025b Merge bitcoin-core/secp256k1#1886: Remove deprecated `secp256k1_context_no_precomp` pointer bf435856bb Remove deprecated `secp256k1_context_no_precomp` pointer 528863e61f Merge bitcoin-core/secp256k1#1869: Remove SECP256K1_GNUC_PREREQ macro 3a73d473f2 Merge bitcoin-core/secp256k1#1776: Remove deprecated `secp256k1_schnorrsig_sign` alias e14756bd25 Remove deprecated `secp256k1_schnorrsig_sign` alias 7151e3b843 Merge bitcoin-core/secp256k1#1899: changelog: add missing entries for #1777 and #1860 f52eb393c4 changelog: add missing entries for #1777 and #1860 0f6baf319f Merge bitcoin-core/secp256k1#1896: silentpayments: address #1765 follow-ups, add changelog entry a2ad68cd81 ec: check pubkey sort test results 93280c2291 silentpayments: check test serialization b8de1bc30f musig: check infinity test setup 0618af8131 extrakeys: check test pubkey loads 1d3f72d3fa recovery: check exhaustive API results 564afb0b06 ellswift: check test operation results 658c7edc24 tests: check exhaustive ecmult success d9ac2ee5e6 Add changelog entry for silentpayments module 0fa38f3d29 silentpayments: API docs and internal comment followups ae075d7cbd hash: Include secp256k1.h directly dba4d937a9 include: Remove SECP256K1_GNUC_PREREQ macro 09870e9c54 Use __GNUC__ instead of SECP256K1_GNUC_PREREQ git-subtree-dir: src/secp256k1 git-subtree-split: 687155df6b76f1da1639a6f0923b69e6beaa3a09
7.1 KiB
Release process
This document outlines the process for releasing versions of the form $MAJOR.$MINOR.$PATCH.
We distinguish between two types of releases: regular and maintenance releases. Regular releases are releases of a new major or minor version as well as patches of the most recent release. Maintenance releases, on the other hand, are required for patches of older releases.
You should coordinate with the other maintainers on the release date, if possible. This date will be part of the release entry in CHANGELOG.md and it should match the dates of the remaining steps in the release process (including the date of the tag and the GitHub release). It is best if the maintainers are present during the release, so they can help ensure that the process is followed correctly and, in the case of a regular release, they are aware that they should not modify the master branch between merging the PR in step 1 and the PR in step 3.
This process also assumes that there will be no minor releases for old major releases.
We aim to cut a regular release every 3-4 months, approximately twice as frequent as major Bitcoin Core releases. Every second release should be published one month before the feature freeze of the next major Bitcoin Core release, allowing sufficient time to update the library in Core.
Sanity checks
Perform these checks when reviewing the release PR (see below):
- Ensure
make distcheckdoesn't fail../autogen.sh && ./configure --enable-dev-mode && make distcheck - Check installation with autotools:
dir=$(mktemp -d) ./autogen.sh && ./configure --prefix=$dir && make clean && make install && ls -RlAh $dir gcc -o ecdsa examples/ecdsa.c $(PKG_CONFIG_PATH=$dir/lib/pkgconfig pkg-config --cflags --libs libsecp256k1) -Wl,-rpath,"$dir/lib" && ./ecdsa - Check installation with CMake:
dir=$(mktemp -d) build=$(mktemp -d) cmake -B $build -DCMAKE_INSTALL_PREFIX=$dir && cmake --build $build && cmake --install $build && ls -RlAh $dir gcc -o ecdsa examples/ecdsa.c -I $dir/include -L $dir/lib*/ -l secp256k1 -Wl,-rpath,"$dir/lib",-rpath,"$dir/lib64" && ./ecdsa - Use the
check-abi.shtool to verify that there are no unexpected ABI incompatibilities and that the version number and the release notes accurately reflect all potential ABI changes. To run this tool, theabi-dumperandabi-compliance-checkerpackages are required.tools/check-abi.sh
Preparing and tagging a release
If you're going to sign the release, make sure that your default GPG signing key is the expected one.
You can see your default key by running echo "test" | gpg --sign --verbose > /dev/null.
Regular release
-
Open a PR to the master branch with a commit (using message
"release: prepare for $MAJOR.$MINOR.$PATCH", for example) that- finalizes the release notes in CHANGELOG.md by
- adding a section for the release (make sure that the version number is a link to a diff between the previous and new version),
- removing the
[Unreleased]section header, - ensuring that the release notes are not missing entries
(check the
needs-changeloglabel on GitHub and also go manually through the list of commits since the previous release), and - including an entry for
### ABI Compatibilityif it doesn't exist,
- sets
_PKG_VERSION_IS_RELEASEtotrueinconfigure.ac, and, - if this is not a patch release,
- updates
_PKG_VERSION_*and_LIB_VERSION_*inconfigure.ac, and - updates
project(libsecp256k1 VERSION ...)and${PROJECT_NAME}_LIB_VERSION_*inCMakeLists.txt.
- updates
- finalizes the release notes in CHANGELOG.md by
-
Perform the sanity checks on the PR branch and attach the output of the
check-abitool (screenshot of the generated compatibility HTML report) to the PR description. -
After the PR has been merged, tag the commit, and push the tag:
RELEASE_COMMIT=<merge commit of step 1> git tag -s v$MAJOR.$MINOR.$PATCH -m "libsecp256k1 $MAJOR.$MINOR.$PATCH" $RELEASE_COMMIT git push git@github.com:bitcoin-core/secp256k1.git v$MAJOR.$MINOR.$PATCH -
Open a PR to the master branch with a commit (using message
"release cleanup: bump version after $MAJOR.$MINOR.$PATCH", for example) that- sets
_PKG_VERSION_IS_RELEASEtofalseand increments_PKG_VERSION_PATCHand_LIB_VERSION_REVISIONinconfigure.ac, - increments the
$PATCHcomponent ofproject(libsecp256k1 VERSION ...)and${PROJECT_NAME}_LIB_VERSION_REVISIONinCMakeLists.txt, and - adds an
[Unreleased]section header and a corresponding[Unreleased]link at the bottom of CHANGELOG.md.
If other maintainers are not present to approve the PR, it can be merged without ACKs.
- sets
Maintenance release
Note that bug fixes need to be backported only to releases for which no compatible release without the bug exists.
- If there's no maintenance branch
$MAJOR.$MINOR, create one:git checkout -b $MAJOR.$MINOR v$MAJOR.$MINOR.$((PATCH - 1)) git push git@github.com:bitcoin-core/secp256k1.git $MAJOR.$MINOR - Open a pull request to the
$MAJOR.$MINORbranch that- includes the bug fixes,
- finalizes the release notes similar to a regular release,
- increments
_PKG_VERSION_PATCHand_LIB_VERSION_REVISIONinconfigure.acand the$PATCHcomponent ofproject(libsecp256k1 VERSION ...)and${PROJECT_NAME}_LIB_VERSION_REVISIONinCMakeLists.txt(with commit message"release: bump versions for $MAJOR.$MINOR.$PATCH", for example).
- Perform the sanity checks on the PR branch.
- After the PR has been merged, update the release branch, tag the commit, and push the tag:
git checkout $MAJOR.$MINOR && git pull git tag -s v$MAJOR.$MINOR.$PATCH -m "libsecp256k1 $MAJOR.$MINOR.$PATCH" git push git@github.com:bitcoin-core/secp256k1.git v$MAJOR.$MINOR.$PATCH - Open a PR to the master branch that includes a commit (with commit message
"release notes: add $MAJOR.$MINOR.$PATCH", for example) that adds release notes to CHANGELOG.md. - Get the PR merged to ensure that the CHANGELOG.md file on the master branch is current before announcing the release.
Creating a tarball and announcing the release
- Create a tarball and a detached GPG signature covering it, and check that the signature verifies under the expected key.
git archive --output "libsecp256k1-$MAJOR.$MINOR.$PATCH.tar.gz" --prefix "libsecp256k1-$MAJOR.$MINOR.$PATCH/" v$MAJOR.$MINOR.$PATCH gpg --detach-sign "libsecp256k1-$MAJOR.$MINOR.$PATCH.tar.gz" gpg --verify "libsecp256k1-$MAJOR.$MINOR.$PATCH.tar.gz.sig" - Create a new GitHub release with a link to the corresponding entry in CHANGELOG.md. Attach the tarball and the detached signature.
- Send an announcement email to the bitcoin-dev mailing list.
Cleaning up
- Close the GitHub milestone, and create a new one. Consider moving unresolved issues to the new milestone.
- Remove the
needs-changeloglabel from all merged PRs.