Hey!
This patch replaces the native OpenSSL dependency with the pure Rust implementation.
When possible I try to do that in my projects to reduce usage of system dependencies
and because I think RustTLS is mature enough.
After applying this patch, you can check with `cargo tree` that openssl is now nowhere.
What do you think? This patch was not discussed so totally fine if you decide
to discard it :)
I've only compiled so no guarantees I didn't break anything :) I think now you
can remove openssl also from the .build.yml
p.s. I've checked the build file for this project and found some interesting bits
that I'll steal for my projects, thanks!
p.p.s. I'm also on IRC
jman (1):
Use RustTLS instead of native OpenSSL
Cargo.toml | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--
2.35.1
[PATCH rss-email 1/1] Use RustTLS instead of native OpenSSL
On 16.08.22 01:35, jman wrote:
>This patch replaces the native OpenSSL dependency with the pure Rust>implementation.
Good idea, I've been struggling with cross-compilation with OpenSSL so
rustls is welcome!
>I've only compiled so no guarantees I didn't break anything :)
I just tested and can verify this is still working!
I should add tests in the near future, too, so contributing is easier.
>I think now you can remove openssl also from the .build.yml
Right! I forgot about it just now, but I'll do that, too.
>p.s. I've checked the build file for this project and found some>interesting bits that I'll steal for my projects, thanks!
Haha you're welcome! I'm wondering whether I should remove the step
running `cargo clippy` as that takes a while and adds to the build time
dramatically (I already feel build for build times approaching 1 minute,
currently the CI takes *9 minutes*). It is quite important though, so
I'm not sure if/how I can improve the build times for the CI.
The build failed as I was verifying signatures on git commits from my
PGP key, so I removed it for now. Sorry about that!
Thanks for the small contribution! I applied it to upstream.
P.S.: Did you mean to send this to " m.mustermann@organization.org"?
--
witcher
https://wiredspace.de
> I'm wondering whether I should remove the step> running `cargo clippy` as that takes a while and adds to the build time> dramatically (I already feel build for build times approaching 1 minute,> currently the CI takes *9 minutes*). It is quite important though, so
I've investigated a little bit, You're building the artifacts twice: one in
debug mode (for tests, which I believe you don't have right now) and
one for release mode (the final application binaries). Then you run
cargo clippy over the debug artifacts.
I think you can avoid one build with this workflow:
```
cargo build --release
(cargo test --release)
cargo clippy --release -- -D warnings
```
and just reuse the existing release artifacts. You'll shave off 2'36" for
basically free.
Also, I'm not sure the "--no-deps" for clippy flag is useful here.
Unless you have a workspace I think it does not help, see here:
https://github.com/rust-lang/rust-clippy/blob/master/README.md#workspaces> I'm not sure if/how I can improve the build times for the CI.
Beside some slight improvements playing with compile flags, I can't
think of anything really useful. Ideally the CI should be able to fetch
pre-compiled cached artifacts from somewhere if the dependencies never
change and just build your application. Something I didn't investigate
yet.
I would keep the release build optimized for performace and size, which
goes in the opposite direction of optimizing for build time.
> Thanks for the small contribution! I applied it to upstream.
Cool. Glad to help!
On 20.08.22 01:28, jman wrote:
>You're building the artifacts twice
I've eventually noticed that, seems I forgot about fixing it. Oops!
Thanks for the reminder.
>You'll shave off 2'36" for basically free.
~2.5m is quite a bit of time. Glad I'm shaving that off of the CI
with simple fixes.
--
witcher