git: 0e6502295721 - main - devel/jujutsu: fix build on big-endian architectures
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 04 Aug 2024 12:01:14 UTC
The branch main has been updated by pkubaj: URL: https://cgit.FreeBSD.org/ports/commit/?id=0e6502295721b0ee2f56d0482e21477d3e0e6f52 commit 0e6502295721b0ee2f56d0482e21477d3e0e6f52 Author: Piotr Kubaj <pkubaj@FreeBSD.org> AuthorDate: 2024-07-30 20:55:41 +0000 Commit: Piotr Kubaj <pkubaj@FreeBSD.org> CommitDate: 2024-08-04 12:00:29 +0000 devel/jujutsu: fix build on big-endian architectures While functions for converting to LE are suffixed _le, functions for converting to BE don't have any suffix: error[E0599]: no method named `put_i16_be` found for struct `Vec<u8>` in the current scope --> /wrkdirs/usr/ports/devel/jujutsu/work/jj-0.19.0/cargo-crates/serde_bser-0.4.0/src/ser/mod.rs:136:22 | 136 | self.scratch.put_i16_be(v); | ^^^^^^^^^^ | help: there is a method `put_i16_le` with a similar name | 136 | self.scratch.put_i16_le(v); | ~~~~~~~~~~ error[E0599]: no method named `put_i32_be` found for struct `Vec<u8>` in the current scope --- ...h-cargo-crates_serde__bser-0.4.0_src_ser_mod.rs | 38 ++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/devel/jujutsu/files/patch-cargo-crates_serde__bser-0.4.0_src_ser_mod.rs b/devel/jujutsu/files/patch-cargo-crates_serde__bser-0.4.0_src_ser_mod.rs new file mode 100644 index 000000000000..f6c32b1fa564 --- /dev/null +++ b/devel/jujutsu/files/patch-cargo-crates_serde__bser-0.4.0_src_ser_mod.rs @@ -0,0 +1,38 @@ +--- cargo-crates/serde_bser-0.4.0/src/ser/mod.rs.orig 2024-07-30 20:40:15 UTC ++++ cargo-crates/serde_bser-0.4.0/src/ser/mod.rs +@@ -133,7 +133,7 @@ where + #[cfg(target_endian = "little")] + self.scratch.put_i16_le(v); + #[cfg(target_endian = "big")] +- self.scratch.put_i16_be(v); ++ self.scratch.put_i16(v); + } + + #[inline] +@@ -143,7 +143,7 @@ where + #[cfg(target_endian = "little")] + self.scratch.put_i32_le(v); + #[cfg(target_endian = "big")] +- self.scratch.put_i32_be(v); ++ self.scratch.put_i32(v); + } + + #[inline] +@@ -153,7 +153,7 @@ where + #[cfg(target_endian = "little")] + self.scratch.put_i64_le(v); + #[cfg(target_endian = "big")] +- self.scratch.put_i64_be(v); ++ self.scratch.put_i64(v); + } + } + +@@ -255,7 +255,7 @@ where + #[cfg(target_endian = "little")] + self.scratch.put_f64_le(v); + #[cfg(target_endian = "big")] +- self.scratch.put_f64_be(v); ++ self.scratch.put_f64(v); + Ok(()) + } +