public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Fabio Valentini <decathorpe@gmail.com>
To: git-commits@fedoraproject.org
Subject: [rpms/rust-rustsec] f44: Bump platforms dependency from v3 to v4
Date: Wed, 18 Nov 2026 22:29:56 GMT [thread overview]
Message-ID: <179504099699.1.10154329095685000671.rpms-rust-rustsec-8efa3ee890a4@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/rust-rustsec
Branch : f44
Commit : 8efa3ee890a4c04409f21cb730c5708337e37233
Author : Fabio Valentini <decathorpe@gmail.com>
Date : 2026-11-18T23:28:47+01:00
Stats : +138/-2 in 4 file(s)
URL : https://src.fedoraproject.org/rpms/rust-rustsec/c/8efa3ee890a4c04409f21cb730c5708337e37233?branch=f44
Log:
Bump platforms dependency from v3 to v4
---
diff --git a/0001-Port-to-platforms-v4.patch b/0001-Port-to-platforms-v4.patch
new file mode 100644
index 0000000..a764830
--- /dev/null
+++ b/0001-Port-to-platforms-v4.patch
@@ -0,0 +1,132 @@
+From 33cdd04027236022c9f40bcd625e3023dfcb334c Mon Sep 17 00:00:00 2001
+From: Fabio Valentini <decathorpe@gmail.com>
+Date: Wed, 18 Nov 2026 23:26:14 +0100
+Subject: [PATCH] Port to platforms v4
+
+---
+ src/advisory/affected.rs | 4 ++--
+ src/database/query.rs | 6 +++---
+ src/report.rs | 4 ++--
+ tests/advisories.rs | 4 ++--
+ tests/query.rs | 6 +++---
+ 5 files changed, 12 insertions(+), 12 deletions(-)
+
+diff --git a/src/advisory/affected.rs b/src/advisory/affected.rs
+index f17c6cb..c2082de 100644
+--- a/src/advisory/affected.rs
++++ b/src/advisory/affected.rs
+@@ -5,7 +5,7 @@ use crate::{
+ Map,
+ error::{Error, ErrorKind},
+ };
+-use platforms::target::{Arch, OS};
++use platforms::{Arch, Os};
+ use semver::VersionReq;
+ use serde::{Deserialize, Deserializer, Serialize, Serializer, de::Error as DeError};
+ use std::{
+@@ -25,7 +25,7 @@ pub struct Affected {
+
+ /// Operating systems that this vulnerability is specific to
+ #[serde(default)]
+- pub os: Vec<OS>,
++ pub os: Vec<Os>,
+
+ /// Paths to types and/or functions containing vulnerable code, enumerated
+ /// as canonical Rust paths (i.e. starting with the crate name), sans any
+diff --git a/src/database/query.rs b/src/database/query.rs
+index 18fb24c..c99db66 100644
+--- a/src/database/query.rs
++++ b/src/database/query.rs
+@@ -6,7 +6,7 @@ use crate::{
+ collection::Collection,
+ package::{self, Package},
+ };
+-use platforms::target::{Arch, OS};
++use platforms::{Arch, Os};
+ use semver::Version;
+
+ /// Queries against the RustSec database
+@@ -31,7 +31,7 @@ pub struct Query {
+ target_arch: Vec<Arch>,
+
+ /// Target operating system
+- target_os: Vec<OS>,
++ target_os: Vec<Os>,
+
+ /// Year associated with the advisory ID
+ year: Option<u32>,
+@@ -132,7 +132,7 @@ impl Query {
+ }
+
+ /// Set target operating systems
+- pub fn target_os(mut self, os: Vec<OS>) -> Self {
++ pub fn target_os(mut self, os: Vec<Os>) -> Self {
+ self.target_os = os;
+ self
+ }
+diff --git a/src/report.rs b/src/report.rs
+index 600868c..7a9ebd3 100644
+--- a/src/report.rs
++++ b/src/report.rs
+@@ -7,7 +7,7 @@ use crate::{
+ Lockfile, Map, advisory,
+ database::{Database, Query},
+ map,
+- platforms::target::{Arch, OS},
++ platforms::{Arch, Os},
+ vulnerability::Vulnerability,
+ warning::{self, Warning},
+ };
+@@ -63,7 +63,7 @@ pub struct Settings {
+ pub target_arch: Vec<Arch>,
+
+ /// Operating system
+- pub target_os: Vec<OS>,
++ pub target_os: Vec<Os>,
+
+ /// Severity threshold to alert at
+ pub severity: Option<advisory::Severity>,
+diff --git a/tests/advisories.rs b/tests/advisories.rs
+index 064edde..07e9ca9 100644
+--- a/tests/advisories.rs
++++ b/tests/advisories.rs
+@@ -58,8 +58,8 @@ fn parse_metadata() {
+ #[test]
+ fn parse_affected() {
+ let affected = load_advisory("v3").affected.unwrap();
+- assert_eq!(affected.arch[0], platforms::target::Arch::X86);
+- assert_eq!(affected.os[0], platforms::target::OS::Windows);
++ assert_eq!(affected.arch[0], platforms::Arch::X86);
++ assert_eq!(affected.os[0], platforms::Os::Windows);
+
+ let example_function = "base::belongs::All".parse().unwrap();
+ let req = &affected.functions.get(&example_function).unwrap()[0];
+diff --git a/tests/query.rs b/tests/query.rs
+index fc7ccab..001c706 100644
+--- a/tests/query.rs
++++ b/tests/query.rs
+@@ -2,7 +2,7 @@
+
+ #![warn(rust_2018_idioms, unused_qualifications)]
+
+-use platforms::target::{Arch, OS};
++use platforms::{Arch, Os};
+ use rustsec::{advisory::Severity, database::Query, package};
+
+ /// Load example advisory from the filesystem
+@@ -46,10 +46,10 @@ fn matches_severity() {
+ fn matches_target_os() {
+ let advisory = load_advisory();
+
+- let query_matches = Query::new().target_os(vec![OS::Windows, OS::Linux]);
++ let query_matches = Query::new().target_os(vec![Os::Windows, Os::Linux]);
+ assert!(query_matches.matches(&advisory));
+
+- let query_normal = Query::new().target_os(vec![OS::MacOS, OS::FreeBSD]);
++ let query_normal = Query::new().target_os(vec![Os::MacOS, Os::FreeBSD]);
+ assert!(!query_normal.matches(&advisory));
+ }
+
+--
+2.56.1
+
diff --git a/rust-rustsec.spec b/rust-rustsec.spec
index 351de1b..36c255a 100644
--- a/rust-rustsec.spec
+++ b/rust-rustsec.spec
@@ -16,7 +16,9 @@ Source: %{crates_source}
# * drop unused binary-scanning feature with missing dependencies
# * temporarily allow gix 0.83; upstream wants 0.84
# * allow newer gix 0.85: https://github.com/rustsec/rustsec/pull/1620
+# * bump platforms dependency from v3 to v4
Patch: rustsec-fix-metadata.diff
+Patch: 0001-Port-to-platforms-v4.patch
BuildRequires: cargo-rpm-macros >= 24
diff --git a/rust2rpm.toml b/rust2rpm.toml
index 13099e9..45b8258 100644
--- a/rust2rpm.toml
+++ b/rust2rpm.toml
@@ -3,6 +3,7 @@ cargo-toml-patch-comments = [
"drop unused binary-scanning feature with missing dependencies",
"temporarily allow gix 0.83; upstream wants 0.84",
"allow newer gix 0.85: https://github.com/rustsec/rustsec/pull/1620",
+ "bump platforms dependency from v3 to v4",
]
[tests]
diff --git a/rustsec-fix-metadata.diff b/rustsec-fix-metadata.diff
index c79bba1..57101ee 100644
--- a/rustsec-fix-metadata.diff
+++ b/rustsec-fix-metadata.diff
@@ -1,5 +1,5 @@
--- rustsec-0.33.0/Cargo.toml 2006-07-24T01:21:28+00:00
-+++ rustsec-0.33.0/Cargo.toml 2026-06-29T10:57:29.358141+00:00
++++ rustsec-0.33.0/Cargo.toml 2026-11-18T22:19:18.832336+00:00
@@ -66,13 +66,6 @@
]
@@ -52,7 +52,8 @@
-optional = true
-
[dependencies.platforms]
- version = "3"
+-version = "3"
++version = "4"
features = ["serde"]
-
-[dependencies.quitters]
reply other threads:[~2026-11-18 22:29 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=179504099699.1.10154329095685000671.rpms-rust-rustsec-8efa3ee890a4@fedoraproject.org \
--to=decathorpe@gmail.com \
--cc=git-commits@fedoraproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox