summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichel Alexandre Salim <salimma@fedoraproject.org>2022-04-04 16:19:38 -0700
committerMichel Alexandre Salim <salimma@fedoraproject.org>2022-04-04 16:19:38 -0700
commitdd984d290c52edb45b5224bd57c29e72c03e940d (patch)
tree016113071d575ed339786f61a3ac12cef5cc520b
parentf8f48b395481d167e1b7cc0007c6747162a31c2f (diff)
downloadspecs-dd984d290c52edb45b5224bd57c29e72c03e940d.tar.gz
specs-dd984d290c52edb45b5224bd57c29e72c03e940d.tar.xz
specs-dd984d290c52edb45b5224bd57c29e72c03e940d.zip
+ sys-locale (for nu-protocol)
Signed-off-by: Michel Alexandre Salim <salimma@fedoraproject.org>
-rw-r--r--rust/rust-sys-locale.spec18
-rw-r--r--rust/sys-locale-fix-metadata.diff19
2 files changed, 29 insertions, 8 deletions
diff --git a/rust/rust-sys-locale.spec b/rust/rust-sys-locale.spec
index 6920ecf..fc74c17 100644
--- a/rust/rust-sys-locale.spec
+++ b/rust/rust-sys-locale.spec
@@ -1,11 +1,11 @@
-# Generated by rust2rpm 20
+# Generated by rust2rpm 21
%bcond_without check
%global debug_package %{nil}
%global crate sys-locale
Name: rust-%{crate}
-Version: 0.1.0
+Version: 0.2.0
Release: %autorelease
Summary: Small and lightweight library to obtain the active system locale
@@ -13,12 +13,12 @@ Summary: Small and lightweight library to obtain the active system locale
License: MIT or ASL 2.0
URL: https://crates.io/crates/sys-locale
Source: %{crates_source}
-# Initial patched metadata
+# Drop dependencies for non-Linux targets
Patch0: sys-locale-fix-metadata.diff
ExclusiveArch: %{rust_arches}
-BuildRequires: rust-packaging
+BuildRequires: rust-packaging >= 21
%global _description %{expand:
Small and lightweight library to obtain the active system locale.}
@@ -35,9 +35,11 @@ This package contains library source intended for building other packages which
use the "%{crate}" crate.
%files devel
-%license LICENSE-APACHE LICENSE-MIT
-%doc CHANGELOG.md README.md
-%{cargo_registry}/%{crate}-%{version_no_tilde}/
+%license %{crate_instdir}/LICENSE-APACHE
+%license %{crate_instdir}/LICENSE-MIT
+%doc %{crate_instdir}/CHANGELOG.md
+%doc %{crate_instdir}/README.md
+%{crate_instdir}/
%package -n %{name}+default-devel
Summary: %{summary}
@@ -49,7 +51,7 @@ 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
+%ghost %{crate_instdir}/Cargo.toml
%prep
%autosetup -n %{crate}-%{version_no_tilde} -p1
diff --git a/rust/sys-locale-fix-metadata.diff b/rust/sys-locale-fix-metadata.diff
new file mode 100644
index 0000000..96c95d7
--- /dev/null
+++ b/rust/sys-locale-fix-metadata.diff
@@ -0,0 +1,19 @@
+--- sys-locale-0.2.0/Cargo.toml 1970-01-01T00:00:01+00:00
++++ sys-locale-0.2.0/Cargo.toml 2022-04-04T23:17:37.714971+00:00
+@@ -20,16 +20,4 @@
+ repository = "https://github.com/1Password/sys-locale"
+ [build-dependencies.cc]
+ version = "1.0"
+-[target."cfg(any(target_os = \"macos\", target_os = \"ios\"))".dependencies.cstr_core]
+-version = "0.2"
+
+-[target."cfg(any(target_os = \"macos\", target_os = \"ios\"))".dependencies.libc]
+-version = "0.2"
+-[target."cfg(target_arch = \"wasm32\")".dependencies.web-sys]
+-version = "0.3"
+-features = ["Window", "Navigator"]
+-[target."cfg(target_os = \"android\")".dependencies.libc]
+-version = "0.2"
+-[target."cfg(windows)".dependencies.winapi]
+-version = "0.3"
+-features = ["winnls"]