Bump to rust-difflib 0.4.0 accepted/tizen_9.0_unified accepted/tizen_rust accepted/tizen_unified accepted/tizen_unified_dev accepted/tizen_unified_x tizen tizen_9.0 accepted/tizen/9.0/unified/20241030.233007 accepted/tizen/rust/20240110.224432 accepted/tizen/unified/20240328.121958 accepted/tizen/unified/dev/20240620.001355 accepted/tizen/unified/x/20240328.130618 tizen_9.0_m2_release
authorDongHun Kwak <dh0128.kwak@samsung.com>
Wed, 8 Nov 2023 00:34:32 +0000 (09:34 +0900)
committerDongHun Kwak <dh0128.kwak@samsung.com>
Wed, 8 Nov 2023 00:34:32 +0000 (09:34 +0900)
packaging/LICENSE-MIT [new file with mode: 0644]
packaging/rust-difflib.manifest [new file with mode: 0644]
packaging/rust-difflib.spec [new file with mode: 0644]

diff --git a/packaging/LICENSE-MIT b/packaging/LICENSE-MIT
new file mode 100644 (file)
index 0000000..39df3da
--- /dev/null
@@ -0,0 +1,25 @@
+Copyright (c) 2019 Alan Somers
+
+Permission is hereby granted, free of charge, to any
+person obtaining a copy of this software and associated
+documentation files (the "Software"), to deal in the
+Software without restriction, including without
+limitation the rights to use, copy, modify, merge,
+publish, distribute, sublicense, and/or sell copies of
+the Software, and to permit persons to whom the Software
+is furnished to do so, subject to the following
+conditions:
+
+The above copyright notice and this permission notice
+shall be included in all copies or substantial portions
+of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
+ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
+SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
+IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+DEALINGS IN THE SOFTWARE.
diff --git a/packaging/rust-difflib.manifest b/packaging/rust-difflib.manifest
new file mode 100644 (file)
index 0000000..017d22d
--- /dev/null
@@ -0,0 +1,5 @@
+<manifest>
+ <request>
+    <domain name="_"/>
+ </request>
+</manifest>
diff --git a/packaging/rust-difflib.spec b/packaging/rust-difflib.spec
new file mode 100644 (file)
index 0000000..5d8da26
--- /dev/null
@@ -0,0 +1,65 @@
+# Generated by rust2rpm 23
+%global _rpm_strip_disable 1
+%global debug_package %{nil}
+
+%global crate difflib
+%global real_crate_name difflib
+%global rustc_edition 2015
+
+Name:           rust-difflib
+Version:        0.4.0
+Release:        1
+Summary:        Port of Python's difflib library to Rust
+
+License:        MIT
+URL:            https://crates.io/crates/difflib
+Source:         %{crate}-%{version}.tar.gz
+Source1:        %{name}.manifest
+Source2:        LICENSE-MIT
+
+# ==========================================================
+# BuildRequires
+# specifies build-time dependencies for the package
+# ==========================================================
+BuildRequires:  rust
+
+
+
+%description
+Port of Python's difflib library to Rust.
+
+%prep
+%setup -q
+cp %{SOURCE1} .
+cp %{SOURCE2} .
+
+# ==========================================================
+# 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}} \
+        ./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-MIT
+%{_rust_dylibdir}/lib%{real_crate_name}.so