Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release workflow improvements #85

Merged
merged 8 commits into from
Mar 22, 2023
Merged

Conversation

qmonnet
Copy link
Member

@qmonnet qmonnet commented Mar 21, 2023

First commit contains some improvements for feature detection (dump stderr output on V=1 to see what's missing when detection fails).

The rest of the PR focuses on the release GitHub workflow, to bring various improvements. Please see individual commits for details.

Cc @mtardy

@qmonnet qmonnet changed the title Pr/release assets Release workflow improvements Mar 21, 2023
@qmonnet
Copy link
Member Author

qmonnet commented Mar 21, 2023

@qmonnet
Copy link
Member Author

qmonnet commented Mar 21, 2023

Hmm I should add a version number in the asset with the source code, probably.

@qmonnet qmonnet force-pushed the pr/release-assets branch 6 times, most recently from aaa0971 to e3550ed Compare March 22, 2023 00:18
With the recent improvements to the feature detection system, it's
trival to keep the stderr output for commands when passing V=1 to the
make invocation. This output is useful for debugging feature detection.

Signed-off-by: Quentin Monnet <quentin@isovalent.com>
We do not need to ship both uncompresed and compressed binaries on
releases. The compressed archives are enough.

One advantage is that we avoid having binaries named "bpftool-<arch>":
all binaries, once the archives are uncompresed, are "bpftool".

Signed-off-by: Quentin Monnet <quentin@isovalent.com>
Add sha256 sum files for the archives produced for releases and
containing bpftool binaries, so that users can make sure that the file
were correctly downloaded.

Signed-off-by: Quentin Monnet <quentin@isovalent.com>
The source code archives generated by GitHub for bpftool releases do not
contain the code for submodules, or the Git submodule configuration
necessary to easily retrieve these modules. This makes it difficult to
build bpftool by simply fetching the sources from releases.

This commit adds a new release asset, an archive containing the code for
bpftool and its submodules (libbpf), stripped from their respective .git
subdirectories.

Signed-off-by: Quentin Monnet <quentin@isovalent.com>
Copy link
Contributor

@mtardy mtardy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks really good, that's nice that you ported the old static build so that it's more efficient!

@qmonnet qmonnet force-pushed the pr/release-assets branch 2 times, most recently from 507d0f4 to c16fb71 Compare March 22, 2023 10:18
Some packages that we install in the Docker container for building the
arm64 binary for releases are not necessary. We can accelerate the
workflow a little by skipping them.

We need libstd++ and zlib, which were likely pulled by one of the
removed packages so far.

Now that clang and llvm-strip are no longer available from $PATH, we
must pass the path to the downloaded versions explicitly so that bpftool
can use it when probing for the clang-bpf-co-re feature.

Signed-off-by: Quentin Monnet <quentin@isovalent.com>
This commit brings some cosmetic changes to the workflow to make it look
more consistent with the older workflows. No functional change, apart
from the additional check on the .skeletons feature when testing
binaries.

Signed-off-by: Quentin Monnet <quentin@isovalent.com>
The CI workflow for static builds against the LLVM binaries would
recompile the LLVM libraries for static linking before building bpftool.
The process is long, and the workflow would take around 80 minutes to
complete.

We can instead download binaries shipped with LLVM releases. The build
works just as well, but the workflow should take around 2 minutes only.

Based after the work from Mahé on the relase workflow.

Signed-off-by: Quentin Monnet <quentin@isovalent.com>
Add a simple script relying on the "gh api" command to update release
assets on GitHub, in order to set labels and make the list of assets
easier to read.

Signed-off-by: Quentin Monnet <quentin@isovalent.com>
@qmonnet qmonnet merged commit 1ac1a89 into libbpf:master Mar 22, 2023
@qmonnet qmonnet deleted the pr/release-assets branch March 22, 2023 10:52
@qmonnet qmonnet mentioned this pull request Mar 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants