summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDongHun Kwak <dh0128.kwak@samsung.com>2024-03-08 14:34:31 +0900
committerDongHun Kwak <dh0128.kwak@samsung.com>2024-03-08 14:34:31 +0900
commit890bb2af9c0b501ce976790400b084d111e51b7c (patch)
treeffb39dfa78f195048b885d1056b44b755f00b556
parent567c3806adaa2f39953c1a9ac32df340eb93fc3a (diff)
downloadrust-clap-v3-master.tar.gz
rust-clap-v3-master.tar.bz2
rust-clap-v3-master.zip
-rw-r--r--packaging/rust-clap-v3.manifest5
-rw-r--r--packaging/rust-clap-v3.spec118
2 files changed, 123 insertions, 0 deletions
diff --git a/packaging/rust-clap-v3.manifest b/packaging/rust-clap-v3.manifest
new file mode 100644
index 0000000..017d22d
--- /dev/null
+++ b/packaging/rust-clap-v3.manifest
@@ -0,0 +1,5 @@
+<manifest>
+ <request>
+ <domain name="_"/>
+ </request>
+</manifest>
diff --git a/packaging/rust-clap-v3.spec b/packaging/rust-clap-v3.spec
new file mode 100644
index 0000000..f8238ae
--- /dev/null
+++ b/packaging/rust-clap-v3.spec
@@ -0,0 +1,118 @@
+# Generated by rust2rpm 23
+%global _rpm_strip_disable 1
+%global debug_package %{nil}
+
+%global crate clap-v3
+%global real_crate_name clap_v3
+%global rustc_edition 2021
+
+Name: rust-clap-v3
+Version: 3.2.22
+Release: 1
+Summary: Simple to use, efficient, and full-featured Command Line Argument Parser
+
+License: MIT OR Apache-2.0
+URL: https://crates.io/crates/clap
+Source: %{crate}-%{version}.tar.gz
+Source1: %{name}.manifest
+
+# ==========================================================
+# BuildRequires
+# specifies build-time dependencies for the package
+# ==========================================================
+BuildRequires: rust
+BuildRequires: rust-atty
+BuildRequires: rust-bitflags
+BuildRequires: rust-clap_derive
+BuildRequires: rust-clap_lex-v2
+BuildRequires: rust-indexmap
+BuildRequires: rust-once_cell
+BuildRequires: rust-regex
+BuildRequires: rust-strsim
+BuildRequires: rust-termcolor
+BuildRequires: rust-terminal_size
+BuildRequires: rust-textwrap
+BuildRequires: rust-unicase
+BuildRequires: rust-yaml-rust
+BuildRequires: rust-os_str_bytes
+
+Requires: rust-atty
+Requires: rust-bitflags
+Requires: rust-clap_lex-v2
+Requires: rust-indexmap
+Requires: rust-once_cell
+Requires: rust-regex
+Requires: rust-strsim
+Requires: rust-termcolor
+Requires: rust-terminal_size
+Requires: rust-textwrap
+Requires: rust-unicase
+Requires: rust-yaml-rust
+Requires: rust-os_str_bytes
+
+# ==========================================================
+# dev-dependencies
+# ==========================================================
+# BuildRequires: rust-humantime
+# BuildRequires: rust-regex
+# BuildRequires: rust-rustversion
+# BuildRequires: rust-shlex
+# BuildRequires: rust-snapbox
+# BuildRequires: rust-static_assertions
+# BuildRequires: rust-trybuild
+# BuildRequires: rust-trycmd
+
+
+%description
+Simple to use, efficient, and full-featured Command Line Argument Parser.
+
+%prep
+%setup -q
+cp %{SOURCE1} .
+
+# ==========================================================
+# build section
+# crate-type : dylib, proc-macro, cdylib, bin, etc.
+# ==========================================================
+%build
+%{rustc_std_build} --crate-type=dylib \
+ --crate-name=%{real_crate_name} \
+ %{?rustc_edition:--edition=%{rustc_edition}} \
+ --cfg='feature="std"' \
+ --cfg='feature="color"' \
+ --cfg='feature="suggestions"' \
+ %rust_dylib_extern atty \
+ %rust_dylib_extern bitflags \
+ %rust_dylib_extern indexmap \
+ %rust_dylib_extern regex \
+ %rust_dylib_extern strsim \
+ %rust_dylib_extern termcolor \
+ %rust_dylib_extern terminal_size \
+ %rust_dylib_extern textwrap \
+ %rust_dylib_extern unicase \
+ %rust_dylib_extern yaml_rust \
+ %rust_dylib_extern os_str_bytes \
+ --extern clap_lex=%{_rust_dylibdir}/libclap_lex_v2.so \
+ ./src/lib.rs
+
+# ==========================================================
+# install section
+# ==========================================================
+%install
+install -d -m 0755 %{buildroot}%{_rust_dylibdir}
+install -m 0644 lib%{real_crate_name}.so %{buildroot}/%{_rust_dylibdir}/lib%{real_crate_name}.so
+
+%clean
+
+%post -p /sbin/ldconfig
+
+%postun -p /sbin/ldconfig
+
+# ==========================================================
+# files section
+# ==========================================================
+%files
+%manifest %{name}.manifest
+%license LICENSE-APACHE
+%license LICENSE-MIT
+%{_rust_dylibdir}/lib%{real_crate_name}.so