# Generated by rust2rpm 27 %bcond check 1 %global debug_package %{nil} %global crate nng-c-sys Name: rust-nng-c-sys Version: 1.10.1 Release: %autorelease Summary: Bindings nng C library License: BSL-1.0 URL: https://crates.io/crates/nng-c-sys Source: %{crates_source} # Manually created patch for downstream crate metadata changes # * Add bindgen dependency unconditionally. # * Remove dependency on cmake. Patch: nng-c-sys-fix-metadata.diff # * Link to system nng Patch2: rust-nng-c-sys-Use_system_nng.patch # * Fix some test issues due to different nng version? Patch3: rust-nng-c-sys-Fix_test_issues.patch BuildRequires: cargo-rpm-macros >= 24 BuildRequires: nng-devel %global _description %{expand: Bindings nng C library.} %description %{_description} %package devel Summary: %{summary} BuildArch: noarch Requires: nng-devel %description devel %{_description} This package contains library source intended for building other packages which use the "%{crate}" crate. %files devel %license %{crate_instdir}/LICENSE %license %{crate_instdir}/mbedtls-2.28.9/LICENSE %license %{crate_instdir}/nng/LICENSE.txt %doc %{crate_instdir}/README.md %{crate_instdir}/ %package -n %{name}+default-devel Summary: %{summary} BuildArch: noarch %description -n %{name}+default-devel %{_description} This package contains library source intended for building other packages which use the "default" feature of the "%{crate}" crate. %files -n %{name}+default-devel %ghost %{crate_instdir}/Cargo.toml %package -n %{name}+build-bindgen-devel Summary: %{summary} BuildArch: noarch %description -n %{name}+build-bindgen-devel %{_description} This package contains library source intended for building other packages which use the "build-bindgen" feature of the "%{crate}" crate. %files -n %{name}+build-bindgen-devel %ghost %{crate_instdir}/Cargo.toml %package -n %{name}+http-devel Summary: %{summary} BuildArch: noarch %description -n %{name}+http-devel %{_description} This package contains library source intended for building other packages which use the "http" feature of the "%{crate}" crate. %files -n %{name}+http-devel %ghost %{crate_instdir}/Cargo.toml %package -n %{name}+stats-devel Summary: %{summary} BuildArch: noarch %description -n %{name}+stats-devel %{_description} This package contains library source intended for building other packages which use the "stats" feature of the "%{crate}" crate. %files -n %{name}+stats-devel %ghost %{crate_instdir}/Cargo.toml %package -n %{name}+tls-devel Summary: %{summary} BuildArch: noarch %description -n %{name}+tls-devel %{_description} This package contains library source intended for building other packages which use the "tls" feature of the "%{crate}" crate. %files -n %{name}+tls-devel %ghost %{crate_instdir}/Cargo.toml %package -n %{name}+websocket-devel Summary: %{summary} BuildArch: noarch %description -n %{name}+websocket-devel %{_description} This package contains library source intended for building other packages which use the "websocket" feature of the "%{crate}" crate. %files -n %{name}+websocket-devel %ghost %{crate_instdir}/Cargo.toml %prep %autosetup -n %{crate}-%{version} -p1 %cargo_prep # Remove bundled nng and mbedtls rm -rf nng mbedtls-* %generate_buildrequires %cargo_generate_buildrequires %build %cargo_build %install %cargo_install %if %{with check} %check %cargo_test %endif %changelog %autochangelog