mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-08-30 23:53:41 +02:00
build: add release-install goal, hash individual binaries
We add a new make goal called release-install that creates the same reproducible binaries as the release script would create, but only for the current OS/architecture. It then installs those binaries to the system's GOBIN directory. To allow easy verification of individual binaries (instead of just the packag tarballs/zips), we also add the hashes of lnd and lncli binaries to the manifest. We do the same in the docker build.
This commit is contained in:
@@ -181,6 +181,10 @@ function build_release() {
|
||||
env CGO_ENABLED=0 GOOS=$os GOARCH=$arch GOARM=$arm go build -v -trimpath -ldflags="${ldflags}" -tags="${buildtags}" ${PKG}/cmd/lncli
|
||||
popd
|
||||
|
||||
# Add the hashes for the individual binaries as well for easy verification
|
||||
# of a single installed binary.
|
||||
sha256sum "${dir}/"* >> "manifest-$tag.txt"
|
||||
|
||||
if [[ $os == "windows" ]]; then
|
||||
reproducible_zip "${dir}"
|
||||
else
|
||||
@@ -188,7 +192,10 @@ function build_release() {
|
||||
fi
|
||||
done
|
||||
|
||||
sha256sum * >manifest-$tag.txt
|
||||
# Add the hash of the packages too, then sort by the second column (name).
|
||||
sha256sum lnd-* vendor* >> "manifest-$tag.txt"
|
||||
LC_ALL=C sort -k2 -o "manifest-$tag.txt" "manifest-$tag.txt"
|
||||
cat "manifest-$tag.txt"
|
||||
}
|
||||
|
||||
# usage prints the usage of the whole script.
|
||||
|
Reference in New Issue
Block a user