# Generated by rust2rpm 20
# * tests use internal cc shim and are broken when overriding CC / CXX
%bcond_with check
%global debug_package %{nil}
%global crate cc
Name: rust-%{crate}
Version: 1.0.73
Release: %autorelease
Summary: Build-time dependency for Cargo build scripts to invoke the native C compiler
# Upstream license specification: MIT/Apache-2.0
License: MIT or ASL 2.0
URL: https://crates.io/crates/cc
Source: %{crates_source}
# Initial patched metadata
# * disable building the internal / test-only cc/cxx shim
Patch0: cc-fix-metadata.diff
ExclusiveArch: %{rust_arches}
BuildRequires: rust-packaging
%global _description %{expand:
Build-time dependency for Cargo build scripts to assist in invoking the native
C compiler to compile native C code into a static archive to be linked into
Rust code.}
%description %{_description}
%package devel
Summary: %{summary}
BuildArch: noarch
Requires: /usr/bin/g++
Requires: /usr/bin/gcc
%description devel %{_description}
This package contains library source intended for building other packages which
use the "%{crate}" crate.
%files devel
%license LICENSE-APACHE LICENSE-MIT
%doc README.md
%{cargo_registry}/%{crate}-%{version_no_tilde}/
%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 %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml
%package -n %{name}+jobserver-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+jobserver-devel %{_description}
This package contains library source intended for building other packages which
use the "jobserver" feature of the "%{crate}" crate.
%files -n %{name}+jobserver-devel
%ghost %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml
%package -n %{name}+parallel-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+parallel-devel %{_description}
This package contains library source intended for building other packages which
use the "parallel" feature of the "%{crate}" crate.
%files -n %{name}+parallel-devel
%ghost %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml
%prep
%autosetup -n %{crate}-%{version_no_tilde} -p1
%cargo_prep
%generate_buildrequires
%cargo_generate_buildrequires
echo '/usr/bin/g++'
echo '/usr/bin/gcc'
%build
%cargo_build
%install
%cargo_install
%if %{with check}
%check
%cargo_test
%endif
%changelog
%autochangelog