diff --git a/.gitignore b/.gitignore index f2a8d9c..634766a 100644 --- a/.gitignore +++ b/.gitignore @@ -257,3 +257,4 @@ thunderbird-langpacks-3.1.2-20100803.tar.bz2 /thunderbird-68.0.source.tar.xz /thunderbird-langpacks-68.0-20190829.tar.xz /lightning-langpacks-68.0.tar.xz +/cbindgen-vendor.tar.xz diff --git a/gen_cbindgen-vendor.sh b/gen_cbindgen-vendor.sh new file mode 100755 index 0000000..01ecc5d --- /dev/null +++ b/gen_cbindgen-vendor.sh @@ -0,0 +1,32 @@ +#!/bin/bash +set -x + +# Dummy Cargo.toml file with cbindgen dependency +cat > Cargo.toml < 28 @@ -192,8 +193,15 @@ Provides: thunderbird-lightning Obsoletes: thunderbird-lightning-gdata <= 1:3.3.0.14 BuildRequires: rust BuildRequires: cargo +%if 0%{?build_with_clang} BuildRequires: clang-devel +%endif BuildRequires: python2-devel +%if !0%{?use_bundled_cbindgen} +BuildRequires: cbindgen +%endif + + Suggests: u2f-hidraw-policy %description @@ -377,6 +385,25 @@ echo "ac_add_options --disable-crashreporter" >> .mozconfig #=============================================================================== %build +%if 0%{?use_bundled_cbindgen} + +mkdir -p my_rust_vendor +cd my_rust_vendor +%{__tar} xf %{SOURCE2} +cd - +mkdir -p .cargo +cat > .cargo/config <