%global debug_package %{nil} Name: bindgen Version: 0.63.0 Release: 1%{?dist} Summary: Automatically generates Rust FFI bindings to C (and some C++) libraries. License: MIT URL: https://github.com/rust-lang/rust-bindgen Source: %{url}/archive/v%{version}.tar.gz BuildRequires: gcc pkg-config %description Automatically generates Rust FFI bindings to C (and some C++) libraries. %prep %autosetup -n rust-%{name}-%{version} # install rust if [ ! -d $HOME/.cargo ]; then curl https://sh.rustup.rs -sSf | sh -s -- -y fi %build $HOME/.cargo/bin/cargo build --release %install install -pDm755 target/release/%{name} %{buildroot}%{_bindir}/%{name} %check %files %{_bindir}/%{name} %changelog