Package: rust-criterion
Version: 0.5.1-6

I hope to upgrade itertools to 0.13 soon, I've just uploaded the
new version to experimental. Criterion depends on itertools.

I looked at the upstream changelog and didn't see anything too
scary and after patching the dependency, and also dealing with
bug #1081878 I was able to succesfully build the package and
run it's autopkgtests against the new version of itertools.

Debdiff is attached
diff -Nru rust-criterion-0.5.1/debian/changelog 
rust-criterion-0.5.1/debian/changelog
--- rust-criterion-0.5.1/debian/changelog       2024-07-30 15:43:20.000000000 
+0000
+++ rust-criterion-0.5.1/debian/changelog       2024-09-21 21:14:45.000000000 
+0000
@@ -1,3 +1,13 @@
+rust-criterion (0.5.1-6.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Don't fail build due to "unexpected cfg" lints introduced in newer versions
+    of rustc (normally these would only be warnings, but this package has 
+    #![deny(warnings)] (Closes: #1081878)
+  * Relax itertools dependency.
+
+ -- Peter Michael Green <plugw...@debian.org>  Sat, 21 Sep 2024 21:14:45 +0000
+
 rust-criterion (0.5.1-6) unstable; urgency=medium
 
   * autopkgtest-depend on dh-rust (not dh-cargo)
diff -Nru rust-criterion-0.5.1/debian/control 
rust-criterion-0.5.1/debian/control
--- rust-criterion-0.5.1/debian/control 2024-07-12 06:39:56.000000000 +0000
+++ rust-criterion-0.5.1/debian/control 2024-09-21 21:14:45.000000000 +0000
@@ -14,7 +14,8 @@
  librust-csv-1+default-dev <!nocheck>,
  librust-futures-0.3+executor-dev <!nocheck>,
  librust-is-terminal-0.4+default-dev <!nocheck>,
- librust-itertools-0.10+default-dev <!nocheck>,
+ librust-itertools+default-dev (>= 0.10) <!nocheck>,
+ librust-itertools+default-dev (<< 0.14) <!nocheck>,
  librust-itertools-num-0.1+default-dev <!nocheck>,
  librust-num-complex-0.4+std-dev <!nocheck>,
  librust-num-traits-0.2+std-dev <!nocheck>,
@@ -54,7 +55,8 @@
  librust-csv-1+default-dev,
  librust-futures-0.3+executor-dev,
  librust-is-terminal-0.4+default-dev,
- librust-itertools-0.10+default-dev,
+ librust-itertools+default-dev (>= 0.10),
+ librust-itertools+default-dev (<< 0.14),
  librust-num-traits-0.2+std-dev,
  librust-once-cell-1+default-dev,
  librust-oorandom-11+default-dev,
diff -Nru rust-criterion-0.5.1/debian/patches/1001_itertools.patch 
rust-criterion-0.5.1/debian/patches/1001_itertools.patch
--- rust-criterion-0.5.1/debian/patches/1001_itertools.patch    1970-01-01 
00:00:00.000000000 +0000
+++ rust-criterion-0.5.1/debian/patches/1001_itertools.patch    2024-09-21 
21:14:45.000000000 +0000
@@ -0,0 +1,30 @@
+Description: Relax itertools dependency.
+Author: Peter Michael Green <plugw...@debian.org>
+Bug-Debian: https://bugs.debian.org/1081878
+
+Index: rust-criterion-0.5.1/Cargo.toml
+===================================================================
+--- rust-criterion-0.5.1.orig/Cargo.toml
++++ rust-criterion-0.5.1/Cargo.toml
+@@ -20,7 +20,7 @@ exclude     = ["book/*"]
+ anes           = "0.1.4"
+ once_cell      = "1.14"
+ criterion-plot = { path = "plot", version = "0.5.0" }
+-itertools      = "0.10"
++itertools      = ">= 0.10, < 0.14"
+ serde          = "1.0"
+ serde_json     = "1.0"
+ serde_derive   = "1.0"
+Index: rust-criterion-0.5.1/plot/Cargo.toml
+===================================================================
+--- rust-criterion-0.5.1.orig/plot/Cargo.toml
++++ rust-criterion-0.5.1/plot/Cargo.toml
+@@ -13,7 +13,7 @@ license = "MIT OR Apache-2.0"
+ 
+ [dependencies]
+ cast = "0.3"
+-itertools = "0.10"
++itertools = ">= 0.10, < 0.14"
+ 
+ [dev-dependencies]
+ itertools-num = "0.1"
diff -Nru 
rust-criterion-0.5.1/debian/patches/2003_dont_file_build_unexpected_cfgs.patch 
rust-criterion-0.5.1/debian/patches/2003_dont_file_build_unexpected_cfgs.patch
--- 
rust-criterion-0.5.1/debian/patches/2003_dont_file_build_unexpected_cfgs.patch  
    1970-01-01 00:00:00.000000000 +0000
+++ 
rust-criterion-0.5.1/debian/patches/2003_dont_file_build_unexpected_cfgs.patch  
    2024-09-21 21:14:45.000000000 +0000
@@ -0,0 +1,17 @@
+Description: Don't fail build due to "unexpected cfg" lints
+ These were introduced in newer versions of rustc (1.80 I think). Normally
+ these would only be warnings, but this package has #![deny(warnings)] turning
+ them into errors. Explicitly allow them.
+Author: Peter Michael Green <plugw...@debian.org>
+Bug-Debian: https://bugs.debian.org/1081878
+
+--- rust-criterion-0.5.1.orig/plot/src/lib.rs
++++ rust-criterion-0.5.1/plot/src/lib.rs
+@@ -363,6 +363,7 @@
+ 
+ #![deny(missing_docs)]
+ #![deny(warnings)]
++#![allow(unexpected_cfgs)]
+ #![deny(bare_trait_objects)]
+ // This lint has lots of false positives ATM, see
+ // https://github.com/Manishearth/rust-clippy/issues/761
diff -Nru rust-criterion-0.5.1/debian/patches/series 
rust-criterion-0.5.1/debian/patches/series
--- rust-criterion-0.5.1/debian/patches/series  2024-07-01 06:41:26.000000000 
+0000
+++ rust-criterion-0.5.1/debian/patches/series  2024-09-21 21:14:45.000000000 
+0000
@@ -1,3 +1,5 @@
 1001_smol.patch
 1001_tempfile.patch
+1001_itertools.patch
 2002_no_unstable_features.patch
+2003_dont_file_build_unexpected_cfgs.patch

Reply via email to