From 10ab40226c4801abcbb6237261d770718ce485d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ma=C3=ADra=20Canal?= Date: Mon, 29 Aug 2022 16:20:31 -0300 Subject: [PATCH] Initial Fedora package MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: MaĆ­ra Canal --- .gitignore | 1 + nu-system-fix-metadata-auto.diff | 59 ++++++++++++++++++++++++ rust-nu-system.spec | 79 ++++++++++++++++++++++++++++++++ sources | 1 + 4 files changed, 140 insertions(+) create mode 100644 .gitignore create mode 100644 nu-system-fix-metadata-auto.diff create mode 100644 rust-nu-system.spec create mode 100644 sources diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..2f457b4 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +./nu-system-0.65.0.crate diff --git a/nu-system-fix-metadata-auto.diff b/nu-system-fix-metadata-auto.diff new file mode 100644 index 0000000..d3ded61 --- /dev/null +++ b/nu-system-fix-metadata-auto.diff @@ -0,0 +1,59 @@ +--- nu-system-0.65.0/Cargo.toml 1970-01-01T00:00:01+00:00 ++++ nu-system-0.65.0/Cargo.toml 1970-01-01T00:00:01+00:00 +@@ -29,56 +29,3 @@ + [target."cfg(any(target_os = \"linux\", target_os = \"android\"))".dependencies.procfs] + version = "0.12.0" + +-[target."cfg(target_os = \"macos\")".dependencies.errno] +-version = "0.2" +- +-[target."cfg(target_os = \"macos\")".dependencies.libc] +-version = "0.2" +- +-[target."cfg(target_os = \"macos\")".dependencies.libproc] +-version = "0.10" +- +-[target."cfg(target_os = \"windows\")".dependencies.chrono] +-version = "0.4" +- +-[target."cfg(target_os = \"windows\")".dependencies.libc] +-version = "0.2" +- +-[target."cfg(target_os = \"windows\")".dependencies.ntapi] +-version = "0.3" +- +-[target."cfg(target_os = \"windows\")".dependencies.once_cell] +-version = "1.0" +- +-[target."cfg(target_os = \"windows\")".dependencies.winapi] +-version = "0.3.9" +-features = [ +- "tlhelp32", +- "fileapi", +- "handleapi", +- "ifdef", +- "ioapiset", +- "minwindef", +- "pdh", +- "psapi", +- "synchapi", +- "sysinfoapi", +- "winbase", +- "winerror", +- "winioctl", +- "winnt", +- "oleauto", +- "wbemcli", +- "rpcdce", +- "combaseapi", +- "objidl", +- "powerbase", +- "netioapi", +- "lmcons", +- "lmaccess", +- "lmapibuf", +- "memoryapi", +- "shellapi", +- "std", +- "securitybaseapi", +-] diff --git a/rust-nu-system.spec b/rust-nu-system.spec new file mode 100644 index 0000000..924df16 --- /dev/null +++ b/rust-nu-system.spec @@ -0,0 +1,79 @@ +# Generated by rust2rpm 22 +%bcond_without check + +%global crate nu-system + +Name: rust-nu-system +Version: 0.65.0 +Release: %autorelease +Summary: Nushell system querying + +License: MIT +URL: https://crates.io/crates/nu-system +Source: %{crates_source} +# Automatically generated patch to strip foreign dependencies +Patch: nu-system-fix-metadata-auto.diff + +ExclusiveArch: %{rust_arches} + +BuildRequires: rust-packaging >= 21 + +%global _description %{expand: +Nushell system querying.} + +%description %{_description} + +%package -n %{crate} +Summary: %{summary} + +%description -n %{crate} %{_description} + +%files -n %{crate} +%license LICENSE +%{_bindir}/ps + +%package devel +Summary: %{summary} +BuildArch: noarch + +%description devel %{_description} + +This package contains library source intended for building other packages which +use the "%{crate}" crate. + +%files devel +%license %{crate_instdir}/LICENSE +%{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 + +%prep +%autosetup -n %{crate}-%{version_no_tilde} -p1 +%cargo_prep + +%generate_buildrequires +%cargo_generate_buildrequires + +%build +%cargo_build + +%install +%cargo_install + +%if %{with check} +%check +%cargo_test +%endif + +%changelog +%autochangelog diff --git a/sources b/sources new file mode 100644 index 0000000..cadc53a --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (nu-system-0.65.0.crate) = bae466ba97e738f82f0dad305fa5cfd910da790302a96543c4fdb6cad697c2d56bd8cafe83cdf9df5f7cb93de02b97d3628d76e4bd09e492d4c36f97839e7bbd