# Generated by rust2rpm 24 %bcond_without check %global debug_package %{nil} %global crate libssh2-sys Name: rust-libssh2-sys0.3 Version: 0.3.0 Release: %autorelease Summary: Native bindings to the libssh2 library # Upstream license specification: MIT/Apache-2.0 # https://github.com/alexcrichton/ssh2-rs/issues/75 License: MIT OR Apache-2.0 URL: https://crates.io/crates/libssh2-sys Source: %{crates_source} # Automatically generated patch to strip foreign dependencies Patch0: libssh2-sys-fix-metadata-auto.diff # Doesn't seem to be upstreamable Patch1: 0001-build.rs-always-use-pkg-config.patch BuildRequires: rust-packaging >= 21 %global _description %{expand: Native bindings to the libssh2 library.} %description %{_description} %package devel Summary: %{summary} BuildArch: noarch Requires: pkgconfig(libssh2) %description devel %{_description} This package contains library source intended for building other packages which use the "%{crate}" crate. %files devel %{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}+openssl-on-win32-devel Summary: %{summary} BuildArch: noarch %description -n %{name}+openssl-on-win32-devel %{_description} This package contains library source intended for building other packages which use the "openssl-on-win32" feature of the "%{crate}" crate. %files -n %{name}+openssl-on-win32-devel %ghost %{crate_instdir}/Cargo.toml %package -n %{name}+vendored-openssl-devel Summary: %{summary} BuildArch: noarch %description -n %{name}+vendored-openssl-devel %{_description} This package contains library source intended for building other packages which use the "vendored-openssl" feature of the "%{crate}" crate. %files -n %{name}+vendored-openssl-devel %ghost %{crate_instdir}/Cargo.toml %package -n %{name}+zlib-ng-compat-devel Summary: %{summary} BuildArch: noarch %description -n %{name}+zlib-ng-compat-devel %{_description} This package contains library source intended for building other packages which use the "zlib-ng-compat" feature of the "%{crate}" crate. %files -n %{name}+zlib-ng-compat-devel %ghost %{crate_instdir}/Cargo.toml %prep %autosetup -n %{crate}-%{version_no_tilde} -p1 # No bundled deps rm -vrf libssh2/ find -type f -perm /111 -exec chmod -c -x '{}' '+' %cargo_prep %generate_buildrequires %cargo_generate_buildrequires echo 'pkgconfig(libssh2)' %build %cargo_build %install %cargo_install %if %{with check} %check %cargo_test %endif %changelog %autochangelog