Repository navigation
fix(cli): THIRD-PARTY-LICENSES.txt in every release archive, from cargo about and the PATENTS files - #63
Merged
Conversation
…go about and the PATENTS files The archives carried the project's two licence texts and nothing for the crates compiled into the binary. `tools/notices.sh` now writes the file for one target: `cargo about` with the shared `about.toml` and `about.hbs`, then every PATENTS file a crate ships, a grant that travels with the licence and that `cargo about` has no slot for. The release build runs it for its target through the dist build-setup steps and `include` in `dist-workspace.toml` puts the file in the archive; `pack.sh` runs it for the npm package, which gains the rav1e grant; the native job of `ci.yml` runs it for its target and checks the result. `cargo-about` comes from one composite action on every runner. The native tier's C and C++ libraries are clarified under the crates that vendor them, with the notices of the third-party code their build compiles: libwebp, libaom with libyuv, fastfeat, SVT-AV1, vector and x86inc, libavif, and libjxl twice, through jpegxl-src for gamut-jxl-sys and inside jpegli-sys with libjpeg-turbo, highway, brotli and skcms. Build dependencies stay in the graph for jpegxl-src's sake. The gamut crates and siphasher are clarified like the package's crates were. Closes #62 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
|
…out installs on Windows The scan took every package cargo metadata resolves, which is every workspace member's, dev dependencies included, and with the features of every platform at once: on musl it listed the JPEG XL grants the musl binary does not carry. It now takes the crate set from cargo tree for the target, over normal and build dependencies, and uses cargo metadata only to find each crate's directory. The composite action extracted into RUNNER_TEMP, a Windows path Git Bash's tar cannot open; it extracts into a mktemp directory and installs next to cargo. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
… have bash 3.2 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #62, the other half of #54: the release archives get the same file the npm package got in #61, one per target, and both get something #61 missed.
One script does the work for both,
tools/notices.sh <manifest> <target> <features> <out>. It runscargo aboutwithabout.tomlandabout.hbs, now at the repository root with a header that fits a binary and a module, and fails on any warning, aspack.shdid. Then it appends every PATENTS file a crate of the tree ships, found by name up to four levels deep, because a patent grant travels with the licence andcargo abouthas no slot for it: aLicenseRefin a clarification renders the wrong file and never the grant, tried. That is howrav1e's grant reaches the npm package too, which #61 did not carry;rav1eships it in Windows-1252, so the script transcodes to keep the file UTF-8.The native tier's C and C++ libraries are the bulk of
about.toml's growth. Each is clarified under the crate that vendors it, with the library's own notice and the notices of the third-party code its build compiles:libwebp;libaomwith libyuv, fastfeat, SVT-AV1 (Clear BSD), vector and x86inc;libavif; and libjxl twice, throughjpegxl-srcforgamut-jxl-sysand insidejpegli-syswith libjpeg-turbo (IJG), highway, brotli and skcms.IJGandBSD-3-Clause-Clearjoin the accepted list for those files alone;deny.tomlnever sees them, since they are not crate licences.jpegxl-srcis a build dependency, so build dependencies stay in the graph now; the price is a dozen build-only crates such asccandcmakein both files, which the header words as "built from". The fourgamutcrates andsiphasherare clarified the way #61 did the package's crates.Checked locally: the script for wasm32, x86_64 Linux, musl and Windows, with the clarified blocks inspected one by one;
pack.shend to end;dist generatewith--checkanddist plan. The archive itself is only built on a tag, so the first real run of the build-setup step is the next release; the native CI job runs the same script on the same runners, which is the rehearsal.Not changed:
simd_helpers,zune-inflateand the MIT bindings oflibwebp-sysstay on the bare licence text, with no notice anywhere to carry.🤖 Generated with Claude Code