From: Mike Hommey Date: Tue, 28 Jun 2022 22:30:11 +0000 (+0900) Subject: Work around build failure with newer cbindgen. bz#1773259 X-Git-Tag: archive/raspbian/91.11.0esr-1_deb11u1+rpi1^2~1 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=c1c86485ffce0db69aedac6d1e3c0deec65267f4;p=firefox-esr.git Work around build failure with newer cbindgen. bz#1773259 Gbp-Pq: Topic debian-hacks Gbp-Pq: Name Work-around-build-failure-with-newer-cbindgen.-bz-17.patch --- diff --git a/build/moz.configure/bindgen.configure b/build/moz.configure/bindgen.configure index 73e590a397e..3679fddbaec 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 b68b691b6e9..e8378244b51 100644 --- a/gfx/webrender_bindings/webrender_ffi.h +++ b/gfx/webrender_bindings/webrender_ffi.h @@ -77,7 +77,9 @@ struct WrPipelineInfo; struct WrPipelineIdAndEpoch; using WrPipelineIdEpochs = nsTArray; +#ifndef CBINDGEN_0_24 const uint64_t ROOT_CLIP_CHAIN = ~0; +#endif } // namespace wr } // namespace mozilla