briansmith / ring

Safe, fast, small crypto using Rust
Other
3.65k stars 684 forks source link

Use only predefined environment variables to compute name prefixes. #1975

Closed briansmith closed 4 months ago

briansmith commented 4 months ago

Instead of having build.rs set a custom environment variable, just compute the value directly from environment variables that are guaranteed to be set. This way, non-Cargo build systems can avoid duplicating this custom logic.

Move the consistency check of links and the package version so that the check is also done during pregeneration.

Use read_env_var() for the relevant environment variables so that build.rs emits cargo:rerun-if-env-changed, as it was noticed that Cargo otherwise doesn't seem to rerun the build script when the Cargo.toml values are changed.

codecov[bot] commented 4 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 96.29%. Comparing base (cecbbd9) to head (22bbb3b).

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #1975 +/- ## ======================================= Coverage 96.29% 96.29% ======================================= Files 136 136 Lines 20677 20677 Branches 226 226 ======================================= Hits 19910 19910 Misses 733 733 Partials 34 34 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.