[Pkg-rust-maintainers] Bug#988025: 988025 at bugs.debian.org

peter green plugwash at p10link.net
Tue May 4 11:13:49 BST 2021


tags 988025 +patch
thanks

I was able to bisect to find the upstream commit that fixed this. A debdiff is attached.
If someone wants to negotiate with the release team about getting it uploaded feel free,
I probablly won't bother to do so myself.
-------------- next part --------------
diff -Nru rust-rustyline-3.0.0/debian/changelog rust-rustyline-3.0.0/debian/changelog
--- rust-rustyline-3.0.0/debian/changelog	2019-02-03 20:19:06.000000000 +0000
+++ rust-rustyline-3.0.0/debian/changelog	2021-05-04 09:27:11.000000000 +0000
@@ -1,3 +1,11 @@
+rust-rustyline (3.0.0-2+deb10u1) buster; urgency=medium
+
+  * Team upload.
+  * Apply upstream patch to fix build with newer rustc.
+    (Closes: 988025)
+
+ -- Peter Michael Green <plugwash at debian.org>  Tue, 04 May 2021 09:27:11 +0000
+
 rust-rustyline (3.0.0-2) unstable; urgency=medium
 
   * Package rustyline 3.0.0 from crates.io using debcargo 2.2.10
diff -Nru rust-rustyline-3.0.0/debian/patches/newer-rustc.patch rust-rustyline-3.0.0/debian/patches/newer-rustc.patch
--- rust-rustyline-3.0.0/debian/patches/newer-rustc.patch	1970-01-01 00:00:00.000000000 +0000
+++ rust-rustyline-3.0.0/debian/patches/newer-rustc.patch	2021-05-04 09:26:41.000000000 +0000
@@ -0,0 +1,49 @@
+commit e383956f3fc9f313d8cf979f1a9772bea9eb1eb8
+Author: gwenn <gtreguier at gmail.com>
+Date:   Fri May 17 19:20:14 2019 +0200
+
+    Try to fix nightly build
+    
+    See #217
+
+diff --git a/examples/example.rs b/examples/example.rs
+index 8bb2e7e..204791f 100644
+--- a/examples/example.rs
++++ b/examples/example.rs
+@@ -80,8 +80,8 @@ fn main() {
+     loop {
+         let readline = rl.readline(PROMPT);
+         match readline {
+-            Ok(line) => {
+-                rl.add_history_entry(line.as_ref());
++            Ok(ref line) => {
++                rl.add_history_entry(line);
+                 println!("Line: {}", line);
+             }
+             Err(ReadlineError::Interrupted) => {
+diff --git a/src/history.rs b/src/history.rs
+index b1cb596..b7cc317 100644
+--- a/src/history.rs
++++ b/src/history.rs
+@@ -148,7 +148,7 @@ impl History {
+         let file = File::open(&path)?;
+         let rdr = BufReader::new(file);
+         for line in rdr.lines() {
+-            self.add(line?.as_ref()); // TODO truncate to MAX_LINE
++            self.add(line?); // TODO truncate to MAX_LINE
+         }
+         Ok(())
+     }
+diff --git a/src/lib.rs b/src/lib.rs
+index 4f6162b..54672fb 100644
+--- a/src/lib.rs
++++ b/src/lib.rs
+@@ -624,7 +624,7 @@ fn readline_raw<H: Helper>(
+     let user_input = readline_edit(prompt, initial, editor, &original_mode);
+     if editor.config.auto_add_history() {
+         if let Ok(ref line) = user_input {
+-            editor.add_history_entry(line.as_ref());
++            editor.add_history_entry(line);
+         }
+     }
+     drop(guard); // disable_raw_mode(original_mode)?;
diff -Nru rust-rustyline-3.0.0/debian/patches/series rust-rustyline-3.0.0/debian/patches/series
--- rust-rustyline-3.0.0/debian/patches/series	2019-02-03 20:19:06.000000000 +0000
+++ rust-rustyline-3.0.0/debian/patches/series	2021-05-04 09:27:05.000000000 +0000
@@ -1 +1,2 @@
 relax-dep-version.patch
+newer-rustc.patch


More information about the Pkg-rust-maintainers mailing list