Refine release process #1310
pull jonasnick wants to merge 4 commits into bitcoin-core:master from jonasnick:refine-release-process changing 1 files +33 −6-
jonasnick commented at 2:21 pm on May 12, 2023: contributorFixes #1176
-
in doc/release-process.md:33 in 74826e857b outdated
28+gcc -o ecdsa ecdsa.c -I $dir/include -L $dir/lib64/ -l secp256k1 29+``` 30+3. Check installation with CMake: 31+``` 32+dir=$(mktemp -d) 33+mkdir build && cd build && cmake -DCMAKE_INSTALL_PREFIX=$dir .. && make install && ls -l $dir/include $dir/lib64
real-or-random commented at 2:28 pm on May 12, 2023:0mkdir build && cmake -B build -DCMAKE_INSTALL_PREFIX=$dir && cmake --build build --target install && ls -l $dir/include $dir/lib*
jonasnick force-pushed on May 12, 2023jonasnick marked this as ready for review on May 12, 2023in doc/release-process.md:28 in c0751c0115 outdated
23+``` 24+2. Check installation with autotools: 25+```shell 26+dir=$(mktemp -d) 27+./configure --prefix=$dir && make install && ls -l $dir/include $dir/lib 28+gcc -o ecdsa examples/ecdsa.c -I $dir/include -L $dir/lib/ -l secp256k1 && ./ecdsa
real-or-random commented at 3:36 pm on May 12, 2023:0gcc -o ecdsa examples/ecdsa.c -I $dir/include -L $dir/lib/ -static -l secp256k1 && ./ecdsa
real-or-random commented at 3:41 pm on May 12, 2023:0gcc -o ecdsa examples/ecdsa.c -I $dir/include -L $dir/lib/ -static -l secp256k1 && ./ecdsa
hebasto commented at 10:21 pm on May 12, 2023:We could test the
libsecp256k1.pc
file as well:0gcc -o ecdsa examples/ecdsa.c $(PKG_CONFIG_PATH=$dir/lib/pkgconfig pkg-config --cflags --libs libsecp256k1) && ./ecdsa
in doc/release-process.md:33 in c0751c0115 outdated
28+gcc -o ecdsa examples/ecdsa.c -I $dir/include -L $dir/lib/ -l secp256k1 && ./ecdsa 29+``` 30+3. Check installation with CMake: 31+```shell 32+dir=$(mktemp -d) 33+mkdir build && cmake -B build -DCMAKE_INSTALL_PREFIX=$dir && cmake --build build --target install && ls -l $dir/include $dir/lib*
real-or-random commented at 3:41 pm on May 12, 2023:0mkdir build && cmake -B build -DCMAKE_INSTALL_PREFIX=$dir -DBUILD_SHARED_LIBS=OFF && cmake --build build --target install && ls -l $dir/include $dir/lib*
hebasto commented at 9:03 am on May 15, 2023:cmake -B build ...
creates thebuild
directory if needed. So, it seem the only purpose ofmkdir build
is to prevent building in a non-clear binary tree. Perhaps we can userm -rf build
for that purpose (which I use in my everyday CMake workflow)?
jonasnick commented at 2:15 pm on May 23, 2023:I don’t want torm -rf
the user’s files.
jonasnick commented at 2:17 pm on May 23, 2023:@real-or-random why wouldn’t we want to build the shared library?
real-or-random commented at 3:51 pm on May 23, 2023:Since #1230, our CMake builds are either shared or static (but not both), because that’s more common and simpler in CMake. And variable
BUILD_SHARED_LIBS
is the CMake convention for this. So-DBUILD_SHARED_LIBS=OFF
doesn’t only enable static libs, it enables static builds. ButBut yeah, the
rpath
thing does the job as well and is probably a bit cleaner.
real-or-random commented at 1:09 pm on May 24, 2023:I don’t want to
rm -rf
the user’s files.nit: If you want to touch this again, what about this variant for additional convenience?
0build=$(mktemp -d) 1cmake -B $build -DCMAKE_INSTALL_PREFIX=$dir && cmake --build $build --target install && ls -l $dir/include $dir/lib*```
in doc/release-process.md:32 in eb057be9d5 outdated
27+``` 28+3. Check installation with CMake: 29+```shell 30+dir=$(mktemp -d) 31+mkdir build && cmake -B build -DCMAKE_INSTALL_PREFIX=$dir && cmake --build build --target install && ls -l $dir/include $dir/lib* 32+gcc -o ecdsa examples/ecdsa.c -I $dir/include -L $dir/lib*/ -l secp256k1 && ./ecdsa
hebasto commented at 9:59 pm on May 12, 2023:The last command,./ecdsa
, needs theLD_LIBRARY_PATH
variable to specify the path to thelibsecp256k1.so.2
library.
real-or-random commented at 8:24 am on May 13, 2023:Right, that’s the alternative to static linking I suggested above.
Maybe all of this sanity-checking should go to a small script that then can also runs on CI then?
hebasto commented at 9:39 am on May 13, 2023:in doc/release-process.md:27 in c0751c0115 outdated
22+make distcheck 23+``` 24+2. Check installation with autotools: 25+```shell 26+dir=$(mktemp -d) 27+./configure --prefix=$dir && make install && ls -l $dir/include $dir/lib
hebasto commented at 10:06 pm on May 12, 2023:0./autogen.sh && ./configure --prefix=$dir && make install && ls -l $dir/include $dir/lib
hebasto cross-referenced this on May 12, 2023 from issue release: Prepare for 0.3.2 by real-or-randomin doc/release-process.md:22 in c0751c0115 outdated
17+## Sanity Checks 18+Perform these checks before creating a release: 19+ 20+1. Ensure `make distcheck` doesn't fail. 21+```shell 22+make distcheck
hebasto commented at 10:47 pm on May 12, 2023:0./autogen.sh && ./configure && make distcheck
in doc/release-process.md:42 in c0751c0115 outdated
38 39 1. Open a PR to the master branch with a commit (using message `"release: prepare for $MAJOR.$MINOR.$PATCH"`, for example) that 40- * finalizes the release notes in [CHANGELOG.md](../CHANGELOG.md) (make sure to include an entry for `### ABI Compatibility`), 41+ * finalizes the release notes in [CHANGELOG.md](../CHANGELOG.md) by 42+ * adding a section for the release (make sure that the version number is a link to a diff between the previous and new version) and 43+ * including an entry for `### ABI Compatibility` if it doesn't exist,
hebasto commented at 10:54 pm on May 12, 2023:Speaking of ABI compatibility, does it make sense to specify SONAME on Linux, for examplelibsecp256k1.so.2
?
real-or-random commented at 8:30 am on May 13, 2023:You mean, saying that the shared library is
libsecp256k1.so.2
? I like this idea. It makes the ABI version very explicit.Then we probably want to say bikeshed a bit about the exact phrasing; Does this apply to macOS, too? Do we want to say something for Windows? Etc… (So that should not hold up 0.3.2 now, I think.)
hebasto commented at 9:27 am on May 13, 2023:You mean, saying that the shared library is
libsecp256k1.so.2
?To be pedantic, the shared library’s soname is
libsecp256k1.so.2
.I like this idea. It makes the ABI version very explicit.
That is my point :)
Then we probably want to say bikeshed a bit about the exact phrasing; Does this apply to macOS, too? Do we want to say something for Windows? Etc… (So that should not hold up 0.3.2 now, I think.)
I’d skip them for now. While an ABI version is a part of DYLIB and DLL names, AFAIK, linking processes on macOS and Windows do not rely on it.
in doc/release-process.md:34 in c0751c0115 outdated
29+``` 30+3. Check installation with CMake: 31+```shell 32+dir=$(mktemp -d) 33+mkdir build && cmake -B build -DCMAKE_INSTALL_PREFIX=$dir && cmake --build build --target install && ls -l $dir/include $dir/lib* 34+gcc -o ecdsa examples/ecdsa.c -I $dir/include -L $dir/lib*/ -l secp256k1 && ./ecdsa
jonasnick commented at 2:16 pm on May 23, 2023:I added this variant, but without$ORIGIN
because$dir
already specifies a full path.real-or-random commented at 6:10 pm on May 13, 2023: contributorWe could include the following: remove the[Unreleased]
section header in Changelog in the preparation PR, and readd it in the PR after the release. We did this for 0.3.2, and I think it makes sense.real-or-random added this to the milestone 0.3.3 (or 0.4.0) on May 13, 2023jonasnick force-pushed on May 23, 2023jonasnick commented at 2:18 pm on May 23, 2023: contributorUpdated the branch. Thanks @hebasto @real-or-random for the suggestions.in doc/release-process.md:22 in 699c812767 outdated
17+## Sanity Checks 18+Perform these checks before creating a release: 19+ 20+1. Ensure `make distcheck` doesn't fail. 21+```shell 22+./autogen.sh && ./configure && make distcheck
real-or-random commented at 3:58 pm on May 23, 2023:0./autogen.sh && ./configure --enable-dev-mode && make distcheck
This would enable all modules, which would make the distcheck cover them. If you are concerned that dev mode is not the right thing here, we could also check once with and without
--enable-dev-mode
.in doc/release-process.md:34 in 699c812767 outdated
29+``` 30+3. Check installation with CMake: 31+```shell 32+dir=$(mktemp -d) 33+mkdir build && cmake -B build -DCMAKE_INSTALL_PREFIX=$dir -DBUILD_SHARED_LIBS=OFF && cmake --build build --target install && ls -l $dir/include $dir/lib* 34+gcc -o ecdsa examples/ecdsa.c -I $dir/include -L $dir/lib*/ -l secp256k1 -Wl,-rpath,"$dir/lib" && ./ecdsa
real-or-random commented at 4:00 pm on May 23, 2023:Okay, I think
-DBUILD_SHARED_LIBS=OFF
(= static library) together with-rpath
(= search path for dynamic linker) does not make sense.I think we should just stick either to the shared library for both build systems, or, if we want some more variety in the sanity checks, use the static library here. (And drop the rpath then.)
jonasnick commented at 4:15 pm on May 23, 2023:The current PR uses the shared library for both build systems.
real-or-random commented at 4:34 pm on May 23, 2023:The current PR uses the shared library for both build systems.
Are you sure? I don’t think so. These CMake commands here shouldn’t build a shared library.
jonasnick commented at 4:51 pm on May 23, 2023:Oh sorry, I thought I had removed the-DBUILD_SHARED_LIBS=OFF
after testing it.
jonasnick commented at 4:52 pm on May 23, 2023:Fixed nowreal-or-random commented at 4:01 pm on May 23, 2023: contributorACK mod nits.
I still need to test the sanity check instructions. I will do once the nits have been addressed.
jonasnick force-pushed on May 23, 2023in doc/release-process.md:34 in fcb2b6e2ef outdated
29+``` 30+3. Check installation with CMake: 31+```shell 32+dir=$(mktemp -d) 33+mkdir build && cmake -B build -DCMAKE_INSTALL_PREFIX=$dir && cmake --build build --target install && ls -l $dir/include $dir/lib* 34+gcc -o ecdsa examples/ecdsa.c -I $dir/include -L $dir/lib*/ -l secp256k1 -Wl,-rpath,"$dir/lib" && ./ecdsa
hebasto commented at 8:53 am on May 24, 2023:Add$dir/lib64
to-rpath
as well?hebasto approvedhebasto commented at 8:53 am on May 24, 2023: memberACK fcb2b6e2effffc8d9898de44bee72162c57aaf71jonasnick force-pushed on May 24, 2023hebasto approvedhebasto commented at 12:39 pm on May 24, 2023: memberre-ACK aeb6fc40cee2f21b15ff69acf0d2adb63b9a3b6d, tested on Ubuntu 22.04 and Fedora 38.in doc/release-process.md:27 in aeb6fc40ce outdated
22+./autogen.sh && ./configure --enable-dev-mode && make distcheck 23+``` 24+2. Check installation with autotools: 25+```shell 26+dir=$(mktemp -d) 27+./autogen.sh && ./configure --prefix=$dir && make install && ls -l $dir/include $dir/lib
real-or-random commented at 1:00 pm on May 24, 2023:I need this when I run step 2 immediately following step 1:
0./autogen.sh && ./configure --prefix=$dir && make clean && make install && ls -l $dir/include $dir/lib
Everything else works fine for me.
hebasto commented at 1:26 pm on May 24, 2023:Maybe usegit clean -xdff
to start from the clean repo?
real-or-random commented at 1:29 pm on May 24, 2023:Maybe use
git clean -xdff
to start from the clean repo?I think this will potentially kill some files that people still need (the same reason why @jonasnick didn’t like
rm -rf build
. We could start in a fresh clone or worktree, but that may be overkill.
jonasnick commented at 1:42 pm on May 24, 2023:I hope that this will solve itself once it runs as part of CI.
jonasnick commented at 1:43 pm on May 24, 2023:Addedmake clean
real-or-random commented at 1:09 pm on May 24, 2023: contributorACK mod nitsrelease process: add sanity checks 165206789brelease process: mention targeted release schedule 79fa50b082release process: fix process for maintenance release 6348bc7eeerelease process: clarify change log updates ad84603297jonasnick force-pushed on May 24, 2023real-or-random approvedreal-or-random commented at 1:46 pm on May 24, 2023: contributorACK ad846032973cc1afd360613626c4e475bba66f56
(We could rerun CI here to make it green but whatever, this PR touches only an .md file…)
hebasto approvedhebasto commented at 1:49 pm on May 24, 2023: memberre-ACK ad846032973cc1afd360613626c4e475bba66f56real-or-random merged this on May 24, 2023real-or-random closed this on May 24, 2023
vmta referenced this in commit e1120c94a1 on Jun 4, 2023sipa referenced this in commit 901336eee7 on Jun 21, 2023vmta referenced this in commit 8f03457eed on Jul 1, 2023hebasto referenced this in commit 270d2b37b8 on Jul 21, 2023jonasnick cross-referenced this on Jul 26, 2023 from issue Upstream PRs 1314, 1317, 1318, 1316, 1327, 1310, 1328, 1333, 1330, 1334, 1337, 1341, 1339, 1350, 1349, 1338, 1129, 1347, 1336, 1295, 1354, 1355, 1356 by jonasnick
jonasnick real-or-random hebastoMilestone
0.3.3 (or 0.4.0)
github-metadata-mirror
This is a metadata mirror of the GitHub repository bitcoin-core/secp256k1. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-11-24 13:15 UTC
This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me