summaryrefslogtreecommitdiff
path: root/librewolf/debian/patches/debian-hacks/Work-around-build-failure-with-newer-cbindgen.-bz-17.patch
diff options
context:
space:
mode:
authorB. Stack <bgstack15@gmail.com>2022-07-04 11:15:48 -0400
committerB. Stack <bgstack15@gmail.com>2022-07-04 11:15:48 -0400
commit58c28f62226cff0c897ed608fb74134e4ebd1602 (patch)
tree7f730c1d1e7970d77c9595d8333f43fcdd9c874d /librewolf/debian/patches/debian-hacks/Work-around-build-failure-with-newer-cbindgen.-bz-17.patch
parentMerge branch 'librewolf-bump' into 'master' (diff)
downloadstackrpms-58c28f62226cff0c897ed608fb74134e4ebd1602.tar.gz
stackrpms-58c28f62226cff0c897ed608fb74134e4ebd1602.tar.bz2
stackrpms-58c28f62226cff0c897ed608fb74134e4ebd1602.zip
lw 102.0 rc1
Diffstat (limited to 'librewolf/debian/patches/debian-hacks/Work-around-build-failure-with-newer-cbindgen.-bz-17.patch')
-rw-r--r--librewolf/debian/patches/debian-hacks/Work-around-build-failure-with-newer-cbindgen.-bz-17.patch43
1 files changed, 43 insertions, 0 deletions
diff --git a/librewolf/debian/patches/debian-hacks/Work-around-build-failure-with-newer-cbindgen.-bz-17.patch b/librewolf/debian/patches/debian-hacks/Work-around-build-failure-with-newer-cbindgen.-bz-17.patch
new file mode 100644
index 0000000..75d20d6
--- /dev/null
+++ b/librewolf/debian/patches/debian-hacks/Work-around-build-failure-with-newer-cbindgen.-bz-17.patch
@@ -0,0 +1,43 @@
+From: Mike Hommey <mh@glandium.org>
+Date: Wed, 29 Jun 2022 07:30:11 +0900
+Subject: Work around build failure with newer cbindgen. bz#1773259
+
+---
+ build/moz.configure/bindgen.configure | 9 +++++++++
+ gfx/webrender_bindings/webrender_ffi.h | 2 ++
+ 2 files changed, 11 insertions(+)
+
+diff --git a/build/moz.configure/bindgen.configure b/build/moz.configure/bindgen.configure
+index 193e1ad..660090a 100644
+--- a/build/moz.configure/bindgen.configure
++++ b/build/moz.configure/bindgen.configure
+@@ -91,6 +91,15 @@ def cbindgen(cbindgen_override, bootstrap_search_path, rust_search_path):
+
+ set_config("CBINDGEN", cbindgen)
+
++set_define(
++ "CBINDGEN_0_24",
++ True,
++ when=depends(cbindgen)(
++ lambda c: Version(check_cmd_output(c, "--version").strip().split(" ")[1])
++ >= "0.24.0"
++ ),
++)
++
+ # Bindgen can use rustfmt to format Rust file, but it's not required.
+ option(env="RUSTFMT", nargs=1, help="Path to the rustfmt program")
+
+diff --git a/gfx/webrender_bindings/webrender_ffi.h b/gfx/webrender_bindings/webrender_ffi.h
+index b1d67b1..ab3cfef 100644
+--- a/gfx/webrender_bindings/webrender_ffi.h
++++ b/gfx/webrender_bindings/webrender_ffi.h
+@@ -73,7 +73,9 @@ struct WrPipelineInfo;
+ struct WrPipelineIdAndEpoch;
+ using WrPipelineIdEpochs = nsTArray<WrPipelineIdAndEpoch>;
+
++#ifndef CBINDGEN_0_24
+ const uint64_t ROOT_CLIP_CHAIN = ~0;
++#endif
+
+ } // namespace wr
+ } // namespace mozilla
bgstack15