Requires: rust-cfg-if
Requires: rust-cipher
+Requires: rust-cpufeatures
# ==========================================================
# dev-dependencies
# crate-type : dylib, proc-macro, cdylib, bin, etc.
# ==========================================================
%build
+%ifarch %{ix86} aarch64 x86_64
+export _RUSTC_EXTERN_PACKAGES_="--extern cpufeatures=%{_rust_dylibdir}/libcpufeatures.so"
+%endif
%{rustc_std_build} --crate-type=dylib \
--crate-name=%{real_crate_name} \
%{?rustc_edition:--edition=%{rustc_edition}} \
- %rust_dylib_extern cipher \
- %rust_dylib_extern cfg_if \
--cfg='feature="hazmat"' \
+ %rust_dylib_extern cfg_if \
+ %rust_dylib_extern cipher \
+ $_RUSTC_EXTERN_PACKAGES_ \
./src/lib.rs
# ==========================================================