Bug 2310497
Summary: | Review Request: rust-rdrand - Rust library for x86 RDRAND/RDSEED instructions | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Tyler Fanelli <tfanelli> |
Component: | Package Review | Assignee: | Fabio Valentini <decathorpe> |
Status: | CLOSED ERRATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | rawhide | CC: | decathorpe, package-review |
Target Milestone: | --- | Flags: | decathorpe:
fedora-review+
|
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
URL: | https://crates.io/crates/rdrand | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2024-10-24 19:10:25 UTC | Type: | --- |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Tyler Fanelli
2024-09-06 20:15:47 UTC
Copr build: https://copr.fedorainfracloud.org/coprs/build/7990258 (failed) Build log: https://download.copr.fedorainfracloud.org/results/@fedora-review/fedora-review-2310497-rust-rdrand/fedora-rawhide-x86_64/07990258-rust-rdrand/builder-live.log.gz Please make sure the package builds successfully at least for Fedora Rawhide. - If the build failed for unrelated reasons (e.g. temporary network unavailability), please ignore it. - If the build failed because of missing BuildRequires, please make sure they are listed in the "Depends On" field --- This comment was created by the fedora-review-service https://github.com/FrostyX/fedora-review-service If you want to trigger a new Copr build, add a comment containing new Spec and SRPM URLs or [fedora-review-service-build] string. This doesn't build due to a missing dependency (criterion ^0.3). However, this is a benchmark-only dependency, you can patch it out (with "rust2rpm -p") without negative consequences, since benchmarks are neither compiled nor run during package builds. Spec URL: https://raw.githubusercontent.com/tylerfanelli/rust-rdrand-f42/refs/heads/main/rust-rdrand.spec SRPM URL: https://github.com/tylerfanelli/rust-rdrand-f42/raw/refs/heads/main/rust-rdrand-0.8.3-1.fc42.src.rpm Description: Rust library for x86 RDRAND/RDSEED instructions Fedora Account System Username: tfanelli Copr build: https://copr.fedorainfracloud.org/coprs/build/8091462 (failed) Build log: https://download.copr.fedorainfracloud.org/results/@fedora-review/fedora-review-2310497-rust-rdrand/fedora-rawhide-x86_64/08091462-rust-rdrand/builder-live.log.gz Please make sure the package builds successfully at least for Fedora Rawhide. - If the build failed for unrelated reasons (e.g. temporary network unavailability), please ignore it. - If the build failed because of missing BuildRequires, please make sure they are listed in the "Depends On" field --- This comment was created by the fedora-review-service https://github.com/FrostyX/fedora-review-service If you want to trigger a new Copr build, add a comment containing new Spec and SRPM URLs or [fedora-review-service-build] string. (In reply to Fabio Valentini from comment #2) > This doesn't build due to a missing dependency (criterion ^0.3). > > However, this is a benchmark-only dependency, you can patch it out (with > "rust2rpm -p") without negative consequences, since benchmarks are neither > compiled nor run during package builds. Hi Fabio, I ran "rust2rpm -p" to generate the spec file posted, and "fedpkg --release f42 mockbuild" to generate the RPM. However, with the latest build log I'm met with: Problem: nothing provides requested (crate(criterion/default) >= 0.3.0 with crate(criterion/default) < 0.4.0~) Am I generating the RPM wrongly? It looks like you used the wrong version of the .spec file. It doesn't contain the patch. Spec URL: https://raw.githubusercontent.com/tylerfanelli/rust-rdrand-f42/refs/heads/main/rust-rdrand.spec SRPM URL: https://github.com/tylerfanelli/rust-rdrand-f42/raw/refs/heads/main/rust-rdrand-0.8.3-1.fc42.src.rpm Description: Rust library for x86 RDRAND/RDSEED instructions Fedora Account System Username: tfanelli Successful with patched spec file. Koji build: https://koji.fedoraproject.org/koji/taskinfo?taskID=124802928 Spec URL: https://raw.githubusercontent.com/tylerfanelli/rust-rdrand-f42/refs/heads/main/rust-rdrand.spec SRPM URL: https://github.com/tylerfanelli/rust-rdrand-f42/raw/refs/heads/main/rust-rdrand-0.8.3-1.fc42.src.rpm Description: Rust library for x86 RDRAND/RDSEED instructions Fedora Account System Username: tfanelli Hm, it seems the Fedora Review Service is not rebuilding the rpm now? Fabio, is there a way to manually enable the service to rebuild? You can follow the instructions in Comment#1, but it looks like the service is just having an outage. The review posted by the bot isn't a requirement though, it's just a nice-to-have. I'll continue with the review regardless. > ExclusiveArch: x86_64
This is the correct way to handle architecture-specific stuff for *applications*, but for Rust crates, they're a bit different ...
Due to the way repositories are set up in koji, noarch packages are present in repos for *all* architectures.
And since Rust library packages (rust-*-devel) *are* noarch packages, they need to have satisfiable dependencies regardless of architecture.
In this case, I would recommend to use a rust2rpm.toml config file (see rust2rpm.toml(5) man page) with these contents, and to regenerate the package:
```
[package]
supported-arches = ["x86_64"]
```
That setting causes rust2rpm to generate a .spec file that builds the library on all architectures, but only actually runs "cargo build" and "cargo test" on supported architectures. This works around the problem of architecture-independent noarch packages in fedora infrastructure, and avoids creating broken dependencies.
Thanks, I've made the recommended changes. Successful koji build: https://koji.fedoraproject.org/koji/taskinfo?taskID=124892123 Spec URL: https://raw.githubusercontent.com/tylerfanelli/rust-rdrand-f42/refs/heads/main/rust-rdrand.spec SRPM URL: https://github.com/tylerfanelli/rust-rdrand-f42/raw/refs/heads/main/rust-rdrand-0.8.3-2.fc42.src.rpm Description: Rust library for x86 RDRAND/RDSEED instructions Fedora Account System Username: tfanelli Copr build: https://copr.fedorainfracloud.org/coprs/build/8148532 (succeeded) Review template: https://download.copr.fedorainfracloud.org/results/@fedora-review/fedora-review-2310497-rust-rdrand/fedora-rawhide-x86_64/08148532-rust-rdrand/fedora-review/review.txt Found issues: - Upstream MD5sum check error, diff is in /var/lib/copr-rpmbuild/results/rust-rdrand/diff.txt Read more: https://docs.fedoraproject.org/en-US/packaging-guidelines/SourceURL/ Please know that there can be false-positives. --- This comment was created by the fedora-review-service https://github.com/FrostyX/fedora-review-service If you want to trigger a new Copr build, add a comment containing new Spec and SRPM URLs or [fedora-review-service-build] string. Looks good to me now, thank you! You might want to shorten the generated Summary, it's too long (>80 characters). Something like this should be OK: "Random number generator based on rdrand and rdseed instructions" You can also set this in the rust2rpm.toml config file so it's not lost when updating / regenerating the package. === Package was generated with rust2rpm, simplifying the review. ✅ package contains only permissible content ✅ package builds and installs without errors on rawhide ✅ test suite is run and all unit tests pass ✅ latest version of the crate is packaged ✅ license matches upstream specification and is acceptable for Fedora ✅ license file is included with %license in %files ✅ package complies with Rust Packaging Guidelines Package APPROVED. === Recommended post-import rust-sig tasks: - set up package on release-monitoring.org: project: $crate homepage: https://crates.io/crates/$crate backend: crates.io version scheme: semantic version (*NOT* pre-release) filter: alpha;beta;rc;pre distro: Fedora Package: rust-$crate - add @rust-sig with "commit" access as package co-maintainer (should happen automatically) - set bugzilla assignee overrides to @rust-sig (optional) - track package in koschei for all built branches (should happen automatically once rust-sig is co-maintainer) The Pagure repository was created at https://src.fedoraproject.org/rpms/rust-rdrand FEDORA-2024-615dc0a95f (rust-rdrand-0.8.3-1.fc42) has been submitted as an update to Fedora 42. https://bodhi.fedoraproject.org/updates/FEDORA-2024-615dc0a95f FEDORA-2024-615dc0a95f (rust-rdrand-0.8.3-1.fc42) has been pushed to the Fedora 42 stable repository. If problem still persists, please make note of it in this bug report. |