summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author김명운/Tizen Platform Lab(SR)/삼성전자 <myoungwoon.kim@samsung.com>2023-06-05 11:01:05 +0900
committerGitHub Enterprise <noreply-CODE@samsung.com>2023-06-05 11:01:05 +0900
commit3e05970d9fb4aa8c45977c364387ae546666b4a3 (patch)
tree0fa835e24a14c485a3e5e6cd8319df01842e26ad
parent9b0184d1d683db46152d56aa5f4e86fdb917404c (diff)
parent5b027a58a22929865c9ad9d178bddd4c51432631 (diff)
downloadrust-serial_test_derive-tizen.tar.gz
rust-serial_test_derive-tizen.tar.bz2
rust-serial_test_derive-tizen.zip
Merge pull request #1 from myoungwoon-kim/devaccepted/tizen/rust/20231016.021909tizenaccepted/tizen_rust
Bump to rust-serial_test_derive 2.0.0
-rw-r--r--packaging/rust-serial_test_derive.manifest5
-rw-r--r--packaging/rust-serial_test_derive.spec89
2 files changed, 94 insertions, 0 deletions
diff --git a/packaging/rust-serial_test_derive.manifest b/packaging/rust-serial_test_derive.manifest
new file mode 100644
index 0000000..017d22d
--- /dev/null
+++ b/packaging/rust-serial_test_derive.manifest
@@ -0,0 +1,5 @@
+<manifest>
+ <request>
+ <domain name="_"/>
+ </request>
+</manifest>
diff --git a/packaging/rust-serial_test_derive.spec b/packaging/rust-serial_test_derive.spec
new file mode 100644
index 0000000..87b3846
--- /dev/null
+++ b/packaging/rust-serial_test_derive.spec
@@ -0,0 +1,89 @@
+# Generated by rust2rpm 23
+%global _rpm_strip_disable 1
+%global debug_package %{nil}
+
+%global crate serial_test_derive
+%global real_crate_name serial_test_derive
+%global rustc_edition 2018
+
+Name: rust-serial_test_derive
+Version: 2.0.0
+Release: 1
+Summary: Helper crate for serial_test
+
+License: MIT
+URL: https://crates.io/crates/serial_test_derive
+Source: %{crate}-%{version}.tar.gz
+Source1: %{name}.manifest
+
+# ==========================================================
+# BuildRequires
+# specifies build-time dependencies for the package
+# ==========================================================
+BuildRequires: rust
+BuildRequires: rust-proc-macro2
+BuildRequires: rust-quote
+BuildRequires: rust-syn
+
+# ==========================================================
+# dev-dependencies
+# ==========================================================
+%if 0%{?run_tests}
+BuildRequires: rust-env_logger
+%endif
+
+
+%description
+Helper crate for serial_test.
+
+%prep
+%setup -q
+cp %{SOURCE1} .
+
+# ==========================================================
+# build section
+# crate-type : dylib, proc-macro, cdylib, bin, etc.
+# ==========================================================
+%build
+%{rustc_std_build} --crate-type=proc-macro \
+ --crate-name=%{real_crate_name} \
+ %{?rustc_edition:--edition=%{rustc_edition}} \
+ %rust_dylib_extern proc_macro2 \
+ %rust_dylib_extern syn \
+ %rust_dylib_extern quote \
+ ./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
+
+%check
+%if 0%{?run_tests}
+%{rustc_std_build} --test --crate-type=proc-macro \
+ --crate-name=%{real_crate_name} \
+ %{?rustc_edition:--edition=%{rustc_edition}} \
+ %rust_dylib_extern proc_macro2 \
+ %rust_dylib_extern syn \
+ %rust_dylib_extern quote \
+ %rust_dylib_extern env_logger \
+ ./src/lib.rs
+
+./%{real_crate_name}
+%endif
+
+%clean
+
+%post -p /sbin/ldconfig
+
+%postun -p /sbin/ldconfig
+
+# ==========================================================
+# files section
+# ==========================================================
+%files
+%manifest %{name}.manifest
+%license LICENSE
+%{_rust_dylibdir}/lib%{real_crate_name}.so