-
Notifications
You must be signed in to change notification settings - Fork 32
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
ci: build binary artifacts for pushes/PRs #506
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
e001e8c
to
ae38c18
Compare
This shook out some useful findings:
In the end I was able to get a repo working with a simple C application that spits out One place for improvement: I had to lift some of the
This seems to be unrelated but still needs to be debugged:
|
91efb3e
to
f5e0234
Compare
Oh! I think that has also been happening for rustls-libssl. |
Looks like it 😓 Here's a fix PR: rustls/rustls-openssl-compat#45 |
f5e0234
to
7629416
Compare
Tidied up my commit history & added testing to the workflow. |
7629416
to
c75692b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. Do you want to move the rustls-ffi-test
repo into the rustls org at some point?
Thanks for taking a look 🙇
Good question - I think with a bit of I'll make a follow-up issue for that 📝 Edit: #519 |
* Windows (x86_64 MSVC) * Linux (x86_64 GNU glibc) * Apple (ARM64 and x86_64) Binary artifacts are built in release mode using stable rust, with the default crypto provider (aws-lc-rs) and cert compression enabled. Linux binaries are built on ubuntu-20.04 for greatest compatibility. Users will need glibc 2.31 or greater. For now I've opted not to include a statically linked musl build. For FIPS, no cert-compression, the ring crypto provider, debug builds, or other customization you will need to build from source. Users of the `.pc` files will need to override the `prefix` to wherever they extract the archive, or use `cargo cinstall` from src. Package config files in an archive aren't relocatable.
Uses a small script (`debian/build.sh`) to massage the output of cargo-c's build into a `.deb` that can be installed on Debian/Ubuntu systems.
Uses the cpu/rustls-ffi-test repo and the artifacts produced by earlier stages of the workflow to smoke-test the builds.
c75692b
to
c4cc238
Compare
I removed the Instead I realized we could use the |
@ctz (No pressure) would you like to review this or should I merge based on Jsha's +1? |
This branch adds a CI job for all pushes & PRs that builds binary artifacts for
rustls-ffi
for:Binary artifacts are built in release mode using stable rust, with the default crypto provider (aws-lc-rs) and cert compression enabled.
Linux binaries are built on ubuntu-20.04 for greatest compatibility. Users will need glibc 2.31 or greater. For now I've opted not to include a statically linked musl build.
For FIPS, no cert-compression, the ring crypto provider, debug builds, or other customization you will need to build from source.
Users of the
.pc
files from the bare archive will need to override theprefix
to wherever they extract the archive, or usecargo cinstall
from src. Package config files in an archive aren't relocatable. The.deb
for Debian/Ubuntu has the correct.pc
prefix already.The build library zips are automatically added to the CI run as artifacts. This has the advantage that we don't need any special write permissions and can manually attach binary artifacts to the releases we publish as appropriate. For now I'd like to avoid automating the release process. Artifact links associated with a branch are valid for ~90d.
You can see the artifacts produced for this PR here, under the annotations.
See an example of a simple C test application built using
cmake
andpkg-config
from the distributed binary releases here: https://github.com/cpu/rustls-ffi-test It's used by testing CI stages that run after the packaging step for each OS/output.Unpacking the archives gives structure like:
The
.deb
displays the following:Resolves #218