diff --git a/rust2rpm/tests/samples/cxx-build-1.0.71.fedora.spec b/rust2rpm/tests/samples/cxx-build-1.0.71.fedora.spec index 6d78909..83e3ff0 100644 --- a/rust2rpm/tests/samples/cxx-build-1.0.71.fedora.spec +++ b/rust2rpm/tests/samples/cxx-build-1.0.71.fedora.spec @@ -1,5 +1,6 @@ # Generated by rust2rpm NNN %bcond_without check +%global debug_package %{nil} %global crate cxx-build %global real_crate cxx-build-1.0.71 @@ -38,18 +39,6 @@ C++ code generator for integrating `cxx` crate into a Cargo build.} %description %{_description} -%package -n %{crate} -Summary: %{summary} - -%description -n %{crate} %{_description} - -%files -n %{crate} -%license LIC1 -%license LIC2 -%doc DOC1 -%doc DOC2 -%{_bindir}/cxx-build - %package devel Summary: %{summary} BuildArch: noarch diff --git a/rust2rpm/tests/samples/cxx-build-1.0.71.json b/rust2rpm/tests/samples/cxx-build-1.0.71.json new file mode 100644 index 0000000..553a574 --- /dev/null +++ b/rust2rpm/tests/samples/cxx-build-1.0.71.json @@ -0,0 +1 @@ +{"packages":[{"name":"cxx-build","version":"1.0.71","id":"cxx-build 1.0.71 (path+file:///home/deca/Downloads/cxx-build-1.0.71)","license":"MIT OR Apache-2.0","license_file":null,"description":"C++ code generator for integrating `cxx` crate into a Cargo build.","source":null,"dependencies":[{"name":"cc","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.49","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"codespan-reporting","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.11","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"once_cell","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.9","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"proc-macro2","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.39","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":["span-locations"],"target":null,"registry":null},{"name":"quote","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":[],"target":null,"registry":null},{"name":"scratch","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"syn","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.95","kind":null,"rename":null,"optional":false,"uses_default_features":false,"features":["parsing","printing","clone-impls","full"],"target":null,"registry":null},{"name":"cxx-gen","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.7","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"pkg-config","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"cxx-build","src_path":"/home/deca/Downloads/cxx-build-1.0.71/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true}],"features":{"experimental-async-fn":[],"parallel":["cc/parallel"]},"manifest_path":"/home/deca/Downloads/cxx-build-1.0.71/Cargo.toml","metadata":{"docs":{"rs":{"targets":["x86_64-unknown-linux-gnu"]}}},"publish":null,"authors":["David Tolnay "],"categories":["development-tools::ffi"],"keywords":["ffi"],"readme":null,"repository":"https://github.com/dtolnay/cxx","homepage":"https://cxx.rs","documentation":null,"edition":"2018","links":null,"default_run":null,"rust_version":"1.48"}],"workspace_members":["cxx-build 1.0.71 (path+file:///home/deca/Downloads/cxx-build-1.0.71)"],"resolve":null,"target_directory":"/home/deca/Downloads/cxx-build-1.0.71/target","version":1,"workspace_root":"/home/deca/Downloads/cxx-build-1.0.71","metadata":null} diff --git a/rust2rpm/tests/samples/cxx-build-1.0.71.mageia.spec b/rust2rpm/tests/samples/cxx-build-1.0.71.mageia.spec index 04e41ab..e24d02c 100644 --- a/rust2rpm/tests/samples/cxx-build-1.0.71.mageia.spec +++ b/rust2rpm/tests/samples/cxx-build-1.0.71.mageia.spec @@ -1,5 +1,6 @@ # Generated by rust2rpm NNN %bcond_without check +%global debug_package %{nil} %global crate cxx-build %global real_crate cxx-build-1.0.71 @@ -42,19 +43,6 @@ C++ code generator for integrating `cxx` crate into a Cargo build.} %description %{_description} -%package -n %{crate} -Summary: %{summary} -Group: # FIXME - -%description -n %{crate} %{_description} - -%files -n %{crate} -%license LIC1 -%license LIC2 -%doc DOC1 -%doc DOC2 -%{_bindir}/cxx-build - %package devel Summary: %{summary} Group: Development/Rust diff --git a/rust2rpm/tests/samples/cxx-build-1.0.71.opensuse.spec b/rust2rpm/tests/samples/cxx-build-1.0.71.opensuse.spec index e6223db..57ee74c 100644 --- a/rust2rpm/tests/samples/cxx-build-1.0.71.opensuse.spec +++ b/rust2rpm/tests/samples/cxx-build-1.0.71.opensuse.spec @@ -17,6 +17,7 @@ # Generated by rust2rpm NNN %bcond_without check +%global debug_package %{nil} %global crate cxx-build %global real_crate cxx-build-1.0.71 @@ -58,19 +59,6 @@ C++ code generator for integrating `cxx` crate into a Cargo build.} %description %{_description} -%package -n %{crate} -Summary: %{summary} -Group: # FIXME - -%description -n %{crate} %{_description} - -%files -n %{crate} -%license LIC1 -%license LIC2 -%doc DOC1 -%doc DOC2 -%{_bindir}/cxx-build - %package devel Summary: %{summary} Group: Development/Libraries/Rust diff --git a/rust2rpm/tests/samples/cxx-build-1.0.71.plain.spec b/rust2rpm/tests/samples/cxx-build-1.0.71.plain.spec index f5745e5..ab779c3 100644 --- a/rust2rpm/tests/samples/cxx-build-1.0.71.plain.spec +++ b/rust2rpm/tests/samples/cxx-build-1.0.71.plain.spec @@ -1,5 +1,6 @@ # Generated by rust2rpm NNN %bcond_without check +%global debug_package %{nil} %global crate cxx-build %global real_crate cxx-build-1.0.71 @@ -40,18 +41,6 @@ C++ code generator for integrating `cxx` crate into a Cargo build.} %description %{_description} -%package -n %{crate} -Summary: %{summary} - -%description -n %{crate} %{_description} - -%files -n %{crate} -%license LIC1 -%license LIC2 -%doc DOC1 -%doc DOC2 -%{_bindir}/cxx-build - %package devel Summary: %{summary} BuildArch: noarch diff --git a/rust2rpm/tests/samples/nix-0.24.1.fedora.spec b/rust2rpm/tests/samples/nix-0.24.1.fedora.spec index 104a0ab..7ee2be1 100644 --- a/rust2rpm/tests/samples/nix-0.24.1.fedora.spec +++ b/rust2rpm/tests/samples/nix-0.24.1.fedora.spec @@ -1,5 +1,6 @@ # Generated by rust2rpm NNN %bcond_without check +%global debug_package %{nil} %global crate nix %global real_crate nix-0.24.1 @@ -30,6 +31,7 @@ BuildRequires: (crate(lazy_static/default) >= 1.2.0 with crate(lazy_static/defa BuildRequires: (crate(parking_lot/default) >= 0.11.2 with crate(parking_lot/default) < 0.12.0~) BuildRequires: (crate(rand/default) >= 0.8.0 with crate(rand/default) < 0.9.0~) BuildRequires: (crate(semver/default) >= 1.0.0 with crate(semver/default) < 2.0.0~) +BuildRequires: (crate(sysctl/default) >= 0.1.0 with crate(sysctl/default) < 0.2.0~) BuildRequires: (crate(tempfile/default) >= 3.2.0 with crate(tempfile/default) < 4.0.0~) %endif @@ -38,18 +40,6 @@ Rust friendly bindings to *nix APIs.} %description %{_description} -%package -n %{crate} -Summary: %{summary} - -%description -n %{crate} %{_description} - -%files -n %{crate} -%license LIC1 -%license LIC2 -%doc DOC1 -%doc DOC2 -%{_bindir}/nix - %package devel Summary: %{summary} BuildArch: noarch diff --git a/rust2rpm/tests/samples/nix-0.24.1.json b/rust2rpm/tests/samples/nix-0.24.1.json new file mode 100644 index 0000000..aa97d7b --- /dev/null +++ b/rust2rpm/tests/samples/nix-0.24.1.json @@ -0,0 +1 @@ +{"packages":[{"name":"nix","version":"0.24.1","id":"nix 0.24.1 (path+file:///home/deca/Downloads/nix-0.24.1)","license":"MIT","license_file":null,"description":"Rust friendly bindings to *nix APIs","source":null,"dependencies":[{"name":"bitflags","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.1","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"cfg-if","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"libc","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2.121","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":["extra_traits"],"target":null,"registry":null},{"name":"assert-impl","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"lazy_static","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.2","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"parking_lot","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.11.2","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"rand","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.8","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"semver","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"tempfile","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3.2.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"caps","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.5.1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":"cfg(any(target_os = \"android\", target_os = \"linux\"))","registry":null},{"name":"memoffset","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.6.3","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":"cfg(not(target_os = \"redox\"))","registry":null},{"name":"sysctl","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":"cfg(target_os = \"freebsd\")","registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"nix","src_path":"/home/deca/Downloads/nix-0.24.1/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test","src_path":"/home/deca/Downloads/nix-0.24.1/test/test.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test-aio-drop","src_path":"/home/deca/Downloads/nix-0.24.1/test/sys/test_aio_drop.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test-clearenv","src_path":"/home/deca/Downloads/nix-0.24.1/test/test_clearenv.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test-lio-listio-resubmit","src_path":"/home/deca/Downloads/nix-0.24.1/test/sys/test_lio_listio_resubmit.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test-mount","src_path":"/home/deca/Downloads/nix-0.24.1/test/test_mount.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test-ptymaster-drop","src_path":"/home/deca/Downloads/nix-0.24.1/test/test_ptymaster_drop.rs","edition":"2018","doc":false,"doctest":false,"test":true}],"features":{"acct":[],"aio":[],"default":["acct","aio","dir","env","event","feature","fs","hostname","inotify","ioctl","kmod","mman","mount","mqueue","net","personality","poll","process","pthread","ptrace","quota","reboot","resource","sched","signal","socket","term","time","ucontext","uio","user","zerocopy"],"dir":["fs"],"env":[],"event":[],"feature":[],"fs":[],"hostname":[],"inotify":[],"ioctl":[],"kmod":[],"memoffset":["dep:memoffset"],"mman":[],"mount":["uio"],"mqueue":["fs"],"net":["socket"],"personality":[],"poll":[],"process":[],"pthread":[],"ptrace":["process"],"quota":[],"reboot":[],"resource":[],"sched":["process"],"signal":["process"],"socket":["memoffset"],"term":[],"time":[],"ucontext":["signal"],"uio":[],"user":["feature"],"zerocopy":["fs","uio"]},"manifest_path":"/home/deca/Downloads/nix-0.24.1/Cargo.toml","metadata":{"docs":{"rs":{"rustdoc-args":["--cfg","docsrs"],"targets":["x86_64-unknown-linux-gnu","aarch64-linux-android","x86_64-apple-darwin","aarch64-apple-ios","x86_64-unknown-freebsd","x86_64-unknown-openbsd","x86_64-unknown-netbsd","x86_64-unknown-dragonfly","x86_64-fuchsia","x86_64-unknown-redox","x86_64-unknown-illumos"]}}},"publish":null,"authors":["The nix-rust Project Developers"],"categories":["os::unix-apis"],"keywords":[],"readme":"README.md","repository":"https://github.com/nix-rust/nix","homepage":null,"documentation":null,"edition":"2018","links":null,"default_run":null,"rust_version":"1.46"}],"workspace_members":["nix 0.24.1 (path+file:///home/deca/Downloads/nix-0.24.1)"],"resolve":null,"target_directory":"/home/deca/Downloads/nix-0.24.1/target","version":1,"workspace_root":"/home/deca/Downloads/nix-0.24.1","metadata":null} diff --git a/rust2rpm/tests/samples/nix-0.24.1.mageia.spec b/rust2rpm/tests/samples/nix-0.24.1.mageia.spec index f2691d9..3efa0c7 100644 --- a/rust2rpm/tests/samples/nix-0.24.1.mageia.spec +++ b/rust2rpm/tests/samples/nix-0.24.1.mageia.spec @@ -1,5 +1,6 @@ # Generated by rust2rpm NNN %bcond_without check +%global debug_package %{nil} %global crate nix %global real_crate nix-0.24.1 @@ -33,6 +34,7 @@ BuildRequires: (crate(lazy_static/default) >= 1.2.0 with crate(lazy_static/defa BuildRequires: (crate(parking_lot/default) >= 0.11.2 with crate(parking_lot/default) < 0.12.0~) BuildRequires: (crate(rand/default) >= 0.8.0 with crate(rand/default) < 0.9.0~) BuildRequires: (crate(semver/default) >= 1.0.0 with crate(semver/default) < 2.0.0~) +BuildRequires: (crate(sysctl/default) >= 0.1.0 with crate(sysctl/default) < 0.2.0~) BuildRequires: (crate(tempfile/default) >= 3.2.0 with crate(tempfile/default) < 4.0.0~) %endif @@ -41,19 +43,6 @@ Rust friendly bindings to *nix APIs.} %description %{_description} -%package -n %{crate} -Summary: %{summary} -Group: # FIXME - -%description -n %{crate} %{_description} - -%files -n %{crate} -%license LIC1 -%license LIC2 -%doc DOC1 -%doc DOC2 -%{_bindir}/nix - %package devel Summary: %{summary} Group: Development/Rust diff --git a/rust2rpm/tests/samples/nix-0.24.1.opensuse.spec b/rust2rpm/tests/samples/nix-0.24.1.opensuse.spec index 8673887..cba3298 100644 --- a/rust2rpm/tests/samples/nix-0.24.1.opensuse.spec +++ b/rust2rpm/tests/samples/nix-0.24.1.opensuse.spec @@ -17,6 +17,7 @@ # Generated by rust2rpm NNN %bcond_without check +%global debug_package %{nil} %global crate nix %global real_crate nix-0.24.1 @@ -50,6 +51,7 @@ BuildRequires: (crate(lazy_static/default) >= 1.2.0 with crate(lazy_static/defa BuildRequires: (crate(parking_lot/default) >= 0.11.2 with crate(parking_lot/default) < 0.12.0~) BuildRequires: (crate(rand/default) >= 0.8.0 with crate(rand/default) < 0.9.0~) BuildRequires: (crate(semver/default) >= 1.0.0 with crate(semver/default) < 2.0.0~) +BuildRequires: (crate(sysctl/default) >= 0.1.0 with crate(sysctl/default) < 0.2.0~) BuildRequires: (crate(tempfile/default) >= 3.2.0 with crate(tempfile/default) < 4.0.0~) %endif @@ -58,19 +60,6 @@ Rust friendly bindings to *nix APIs.} %description %{_description} -%package -n %{crate} -Summary: %{summary} -Group: # FIXME - -%description -n %{crate} %{_description} - -%files -n %{crate} -%license LIC1 -%license LIC2 -%doc DOC1 -%doc DOC2 -%{_bindir}/nix - %package devel Summary: %{summary} Group: Development/Libraries/Rust diff --git a/rust2rpm/tests/samples/nix-0.24.1.plain.spec b/rust2rpm/tests/samples/nix-0.24.1.plain.spec index d493403..aca32ae 100644 --- a/rust2rpm/tests/samples/nix-0.24.1.plain.spec +++ b/rust2rpm/tests/samples/nix-0.24.1.plain.spec @@ -1,5 +1,6 @@ # Generated by rust2rpm NNN %bcond_without check +%global debug_package %{nil} %global crate nix %global real_crate nix-0.24.1 @@ -32,6 +33,7 @@ BuildRequires: (crate(lazy_static/default) >= 1.2.0 with crate(lazy_static/defa BuildRequires: (crate(parking_lot/default) >= 0.11.2 with crate(parking_lot/default) < 0.12.0~) BuildRequires: (crate(rand/default) >= 0.8.0 with crate(rand/default) < 0.9.0~) BuildRequires: (crate(semver/default) >= 1.0.0 with crate(semver/default) < 2.0.0~) +BuildRequires: (crate(sysctl/default) >= 0.1.0 with crate(sysctl/default) < 0.2.0~) BuildRequires: (crate(tempfile/default) >= 3.2.0 with crate(tempfile/default) < 4.0.0~) %endif @@ -40,18 +42,6 @@ Rust friendly bindings to *nix APIs.} %description %{_description} -%package -n %{crate} -Summary: %{summary} - -%description -n %{crate} %{_description} - -%files -n %{crate} -%license LIC1 -%license LIC2 -%doc DOC1 -%doc DOC2 -%{_bindir}/nix - %package devel Summary: %{summary} BuildArch: noarch diff --git a/rust2rpm/tests/samples/tokio-1.19.2.fedora.spec b/rust2rpm/tests/samples/tokio-1.19.2.fedora.spec index 50cd23b..d75c959 100644 --- a/rust2rpm/tests/samples/tokio-1.19.2.fedora.spec +++ b/rust2rpm/tests/samples/tokio-1.19.2.fedora.spec @@ -1,5 +1,6 @@ # Generated by rust2rpm NNN %bcond_without check +%global debug_package %{nil} %global crate tokio %global real_crate tokio-1.19.2 @@ -7,7 +8,7 @@ Name: rust-tokio-1.19.2 Version: 1.19.2 Release: %autorelease -Summary: Event-driven, non-blocking I/O platform for writing asynchronous I/O +Summary: Event-driven, non-blocking I/O platform for writing asynchronous I/O backed applications License: MIT URL: https://crates.io/crates/tokio-1.19.2 @@ -24,35 +25,30 @@ BuildRequires: (crate(async-stream/default) >= 0.3.0 with crate(async-stream/de BuildRequires: (crate(futures/async-await) >= 0.3.0 with crate(futures/async-await) < 0.4.0~) BuildRequires: (crate(futures/default) >= 0.3.0 with crate(futures/default) < 0.4.0~) BuildRequires: (crate(libc/default) >= 0.2.42 with crate(libc/default) < 0.3.0~) +BuildRequires: (crate(loom/checkpoint) >= 0.5.2 with crate(loom/checkpoint) < 0.6.0~) +BuildRequires: (crate(loom/default) >= 0.5.2 with crate(loom/default) < 0.6.0~) +BuildRequires: (crate(loom/futures) >= 0.5.2 with crate(loom/futures) < 0.6.0~) +BuildRequires: (crate(mio-aio/default) >= 0.6.0 with crate(mio-aio/default) < 0.7.0~) +BuildRequires: (crate(mio-aio/tokio) >= 0.6.0 with crate(mio-aio/tokio) < 0.7.0~) BuildRequires: (crate(mockall/default) >= 0.11.1 with crate(mockall/default) < 0.12.0~) BuildRequires: (crate(nix/fs) >= 0.24.0 with crate(nix/fs) < 0.25.0~) BuildRequires: (crate(nix/socket) >= 0.24.0 with crate(nix/socket) < 0.25.0~) +BuildRequires: (crate(ntapi/default) >= 0.3.6 with crate(ntapi/default) < 0.4.0~) BuildRequires: (crate(proptest/default) >= 1.0.0 with crate(proptest/default) < 2.0.0~) BuildRequires: (crate(rand/default) >= 0.8.0 with crate(rand/default) < 0.9.0~) BuildRequires: (crate(socket2/default) >= 0.4.0 with crate(socket2/default) < 0.5.0~) BuildRequires: (crate(tempfile/default) >= 3.1.0 with crate(tempfile/default) < 4.0.0~) BuildRequires: (crate(tokio-stream/default) >= 0.1.0 with crate(tokio-stream/default) < 0.2.0~) BuildRequires: (crate(tokio-test/default) >= 0.4.0 with crate(tokio-test/default) < 0.5.0~) +BuildRequires: (crate(wasm-bindgen-test/default) >= 0.3.0 with crate(wasm-bindgen-test/default) < 0.4.0~) %endif %global _description %{expand: -Event-driven, non-blocking I/O platform for writing asynchronous I/O -backed applications.} +Event-driven, non-blocking I/O platform for writing asynchronous I/O backed +applications.} %description %{_description} -%package -n %{crate} -Summary: %{summary} - -%description -n %{crate} %{_description} - -%files -n %{crate} -%license LIC1 -%license LIC2 -%doc DOC1 -%doc DOC2 -%{_bindir}/tokio - %package devel Summary: %{summary} BuildArch: noarch @@ -369,6 +365,30 @@ use the "tokio-macros" feature of the "%{crate}" crate. %files -n %{name}+tokio-macros-devel %ghost %{crate_instdir}/Cargo.toml +%package -n %{name}+tracing-devel +Summary: %{summary} +BuildArch: noarch + +%description -n %{name}+tracing-devel %{_description} + +This package contains library source intended for building other packages which +use the "tracing" feature of the "%{crate}" crate. + +%files -n %{name}+tracing-devel +%ghost %{crate_instdir}/Cargo.toml + +%package -n %{name}+winapi-devel +Summary: %{summary} +BuildArch: noarch + +%description -n %{name}+winapi-devel %{_description} + +This package contains library source intended for building other packages which +use the "winapi" feature of the "%{crate}" crate. + +%files -n %{name}+winapi-devel +%ghost %{crate_instdir}/Cargo.toml + %prep %autosetup -n %{real_crate}-%{version_no_tilde} -p1 %cargo_prep diff --git a/rust2rpm/tests/samples/tokio-1.19.2.json b/rust2rpm/tests/samples/tokio-1.19.2.json new file mode 100644 index 0000000..551d1e1 --- /dev/null +++ b/rust2rpm/tests/samples/tokio-1.19.2.json @@ -0,0 +1 @@ +{"packages":[{"name":"tokio","version":"1.19.2","id":"tokio 1.19.2 (path+file:///home/deca/Downloads/tokio-1.19.2)","license":"MIT","license_file":null,"description":"An event-driven, non-blocking I/O platform for writing asynchronous I/O\nbacked applications.\n","source":null,"dependencies":[{"name":"bytes","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.0.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"memchr","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^2.2","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"mio","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.8.1","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"num_cpus","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.8.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"once_cell","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.5.2","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"parking_lot","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.12.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"pin-project-lite","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2.0","kind":null,"rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"socket2","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4.4","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":["all"],"target":null,"registry":null},{"name":"tokio-macros","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.7.0","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"async-stream","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"futures","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":["async-await"],"target":null,"registry":null},{"name":"mockall","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.11.1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"tempfile","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^3.1.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"tokio-stream","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"tokio-test","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":null,"registry":null},{"name":"loom","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.5.2","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":["futures","checkpoint"],"target":"cfg(loom)","registry":null},{"name":"proptest","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":"cfg(not(target_arch = \"wasm32\"))","registry":null},{"name":"rand","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.8.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":"cfg(not(target_arch = \"wasm32\"))","registry":null},{"name":"socket2","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.4","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":"cfg(not(target_arch = \"wasm32\"))","registry":null},{"name":"wasm-bindgen-test","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":"cfg(target_arch = \"wasm32\")","registry":null},{"name":"mio-aio","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.6.0","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":["tokio"],"target":"cfg(target_os = \"freebsd\")","registry":null},{"name":"tracing","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.1.25","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":["std"],"target":"cfg(tokio_unstable)","registry":null},{"name":"libc","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2.42","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":"cfg(unix)","registry":null},{"name":"signal-hook-registry","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^1.1.1","kind":null,"rename":null,"optional":true,"uses_default_features":true,"features":[],"target":"cfg(unix)","registry":null},{"name":"libc","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.2.42","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":"cfg(unix)","registry":null},{"name":"nix","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.24","kind":"dev","rename":null,"optional":false,"uses_default_features":false,"features":["fs","socket"],"target":"cfg(unix)","registry":null},{"name":"winapi","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.8","kind":null,"rename":null,"optional":true,"uses_default_features":false,"features":["std","winsock2","mswsock","handleapi","ws2ipdef","ws2tcpip"],"target":"cfg(windows)","registry":null},{"name":"ntapi","source":"registry+https://github.com/rust-lang/crates.io-index","req":"^0.3.6","kind":"dev","rename":null,"optional":false,"uses_default_features":true,"features":[],"target":"cfg(windows)","registry":null}],"targets":[{"kind":["lib"],"crate_types":["lib"],"name":"tokio","src_path":"/home/deca/Downloads/tokio-1.19.2/src/lib.rs","edition":"2018","doc":true,"doctest":true,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"_require_full","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/_require_full.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"async_send_sync","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/async_send_sync.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"buffered","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/buffered.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"fs","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/fs.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"fs_copy","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/fs_copy.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"fs_dir","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/fs_dir.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"fs_file","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/fs_file.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"fs_link","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/fs_link.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_async_fd","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_async_fd.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_async_read","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_async_read.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_buf_reader","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_buf_reader.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_buf_writer","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_buf_writer.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_chain","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_chain.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_copy","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_copy.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_copy_bidirectional","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_copy_bidirectional.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_driver","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_driver.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_driver_drop","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_driver_drop.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_fill_buf","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_fill_buf.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_lines","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_lines.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_mem_stream","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_mem_stream.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_poll_aio","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_poll_aio.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_read","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_read.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_read_buf","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_read_buf.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_read_exact","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_read_exact.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_read_line","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_read_line.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_read_to_end","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_read_to_end.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_read_to_string","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_read_to_string.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_read_until","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_read_until.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_split","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_split.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_take","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_take.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_util_empty","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_util_empty.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_write","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_write.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_write_all","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_write_all.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_write_all_buf","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_write_all_buf.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_write_buf","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_write_buf.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"io_write_int","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/io_write_int.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"join_handle_panic","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/join_handle_panic.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"macros_join","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/macros_join.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"macros_pin","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/macros_pin.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"macros_rename_test","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/macros_rename_test.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"macros_select","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/macros_select.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"macros_test","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/macros_test.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"macros_try_join","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/macros_try_join.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"named_pipe","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/named_pipe.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"net_bind_resource","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/net_bind_resource.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"net_lookup_host","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/net_lookup_host.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"no_rt","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/no_rt.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"process_arg0","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/process_arg0.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"process_issue_2174","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/process_issue_2174.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"process_issue_42","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/process_issue_42.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"process_kill_on_drop","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/process_kill_on_drop.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"process_raw_handle","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/process_raw_handle.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"process_smoke","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/process_smoke.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"rt_basic","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/rt_basic.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"rt_common","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/rt_common.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"rt_handle_block_on","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/rt_handle_block_on.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"rt_metrics","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/rt_metrics.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"rt_threaded","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/rt_threaded.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"signal_ctrl_c","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/signal_ctrl_c.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"signal_drop_recv","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/signal_drop_recv.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"signal_drop_rt","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/signal_drop_rt.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"signal_drop_signal","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/signal_drop_signal.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"signal_multi_rt","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/signal_multi_rt.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"signal_no_rt","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/signal_no_rt.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"signal_notify_both","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/signal_notify_both.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"signal_twice","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/signal_twice.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"signal_usr1","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/signal_usr1.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"sync_barrier","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/sync_barrier.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"sync_broadcast","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/sync_broadcast.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"sync_errors","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/sync_errors.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"sync_mpsc","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/sync_mpsc.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"sync_mutex","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/sync_mutex.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"sync_mutex_owned","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/sync_mutex_owned.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"sync_notify","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/sync_notify.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"sync_once_cell","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/sync_once_cell.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"sync_oneshot","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/sync_oneshot.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"sync_rwlock","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/sync_rwlock.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"sync_semaphore","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/sync_semaphore.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"sync_semaphore_owned","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/sync_semaphore_owned.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"sync_watch","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/sync_watch.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"task_abort","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/task_abort.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"task_blocking","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/task_blocking.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"task_builder","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/task_builder.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"task_join_set","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/task_join_set.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"task_local","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/task_local.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"task_local_set","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/task_local_set.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"tcp_accept","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/tcp_accept.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"tcp_connect","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/tcp_connect.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"tcp_echo","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/tcp_echo.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"tcp_into_split","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/tcp_into_split.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"tcp_into_std","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/tcp_into_std.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"tcp_peek","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/tcp_peek.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"tcp_shutdown","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/tcp_shutdown.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"tcp_socket","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/tcp_socket.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"tcp_split","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/tcp_split.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"tcp_stream","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/tcp_stream.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"test_clock","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/test_clock.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"time_interval","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/time_interval.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"time_pause","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/time_pause.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"time_rt","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/time_rt.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"time_sleep","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/time_sleep.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"time_timeout","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/time_timeout.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"udp","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/udp.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"uds_cred","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/uds_cred.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"uds_datagram","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/uds_datagram.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"uds_split","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/uds_split.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"uds_stream","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/uds_stream.rs","edition":"2018","doc":false,"doctest":false,"test":true},{"kind":["test"],"crate_types":["bin"],"name":"unwindsafe","src_path":"/home/deca/Downloads/tokio-1.19.2/tests/unwindsafe.rs","edition":"2018","doc":false,"doctest":false,"test":true}],"features":{"bytes":["dep:bytes"],"default":[],"fs":[],"full":["fs","io-util","io-std","macros","net","parking_lot","process","rt","rt-multi-thread","signal","sync","time"],"io-std":[],"io-util":["memchr","bytes"],"libc":["dep:libc"],"macros":["tokio-macros"],"memchr":["dep:memchr"],"mio":["dep:mio"],"net":["libc","mio/os-poll","mio/os-ext","mio/net","socket2","winapi/namedpipeapi"],"num_cpus":["dep:num_cpus"],"once_cell":["dep:once_cell"],"parking_lot":["dep:parking_lot"],"process":["bytes","once_cell","libc","mio/os-poll","mio/os-ext","mio/net","signal-hook-registry","winapi/threadpoollegacyapiset"],"rt":["once_cell"],"rt-multi-thread":["num_cpus","rt"],"signal":["once_cell","libc","mio/os-poll","mio/net","mio/os-ext","signal-hook-registry","winapi/consoleapi"],"signal-hook-registry":["dep:signal-hook-registry"],"socket2":["dep:socket2"],"stats":[],"sync":[],"test-util":["rt","sync","time"],"time":[],"tokio-macros":["dep:tokio-macros"],"tracing":["dep:tracing"],"winapi":["dep:winapi"]},"manifest_path":"/home/deca/Downloads/tokio-1.19.2/Cargo.toml","metadata":{"docs":{"rs":{"all-features":true,"rustdoc-args":["--cfg","docsrs","--cfg","tokio_unstable"],"rustc-args":["--cfg","tokio_unstable"]}},"playground":{"features":["full","test-util"]}},"publish":null,"authors":["Tokio Contributors "],"categories":["asynchronous","network-programming"],"keywords":["io","async","non-blocking","futures"],"readme":"README.md","repository":"https://github.com/tokio-rs/tokio","homepage":"https://tokio.rs","documentation":null,"edition":"2018","links":null,"default_run":null,"rust_version":"1.49"}],"workspace_members":["tokio 1.19.2 (path+file:///home/deca/Downloads/tokio-1.19.2)"],"resolve":null,"target_directory":"/home/deca/Downloads/tokio-1.19.2/target","version":1,"workspace_root":"/home/deca/Downloads/tokio-1.19.2","metadata":null} diff --git a/rust2rpm/tests/samples/tokio-1.19.2.mageia.spec b/rust2rpm/tests/samples/tokio-1.19.2.mageia.spec index 89098ab..0560deb 100644 --- a/rust2rpm/tests/samples/tokio-1.19.2.mageia.spec +++ b/rust2rpm/tests/samples/tokio-1.19.2.mageia.spec @@ -1,5 +1,6 @@ # Generated by rust2rpm NNN %bcond_without check +%global debug_package %{nil} %global crate tokio %global real_crate tokio-1.19.2 @@ -7,7 +8,7 @@ Name: rust-tokio-1.19.2 Version: 1.19.2 Release: %mkrel 1 -Summary: Event-driven, non-blocking I/O platform for writing asynchronous I/O +Summary: Event-driven, non-blocking I/O platform for writing asynchronous I/O backed applications Group: Development/Rust License: MIT @@ -27,36 +28,30 @@ BuildRequires: (crate(async-stream/default) >= 0.3.0 with crate(async-stream/de BuildRequires: (crate(futures/async-await) >= 0.3.0 with crate(futures/async-await) < 0.4.0~) BuildRequires: (crate(futures/default) >= 0.3.0 with crate(futures/default) < 0.4.0~) BuildRequires: (crate(libc/default) >= 0.2.42 with crate(libc/default) < 0.3.0~) +BuildRequires: (crate(loom/checkpoint) >= 0.5.2 with crate(loom/checkpoint) < 0.6.0~) +BuildRequires: (crate(loom/default) >= 0.5.2 with crate(loom/default) < 0.6.0~) +BuildRequires: (crate(loom/futures) >= 0.5.2 with crate(loom/futures) < 0.6.0~) +BuildRequires: (crate(mio-aio/default) >= 0.6.0 with crate(mio-aio/default) < 0.7.0~) +BuildRequires: (crate(mio-aio/tokio) >= 0.6.0 with crate(mio-aio/tokio) < 0.7.0~) BuildRequires: (crate(mockall/default) >= 0.11.1 with crate(mockall/default) < 0.12.0~) BuildRequires: (crate(nix/fs) >= 0.24.0 with crate(nix/fs) < 0.25.0~) BuildRequires: (crate(nix/socket) >= 0.24.0 with crate(nix/socket) < 0.25.0~) +BuildRequires: (crate(ntapi/default) >= 0.3.6 with crate(ntapi/default) < 0.4.0~) BuildRequires: (crate(proptest/default) >= 1.0.0 with crate(proptest/default) < 2.0.0~) BuildRequires: (crate(rand/default) >= 0.8.0 with crate(rand/default) < 0.9.0~) BuildRequires: (crate(socket2/default) >= 0.4.0 with crate(socket2/default) < 0.5.0~) BuildRequires: (crate(tempfile/default) >= 3.1.0 with crate(tempfile/default) < 4.0.0~) BuildRequires: (crate(tokio-stream/default) >= 0.1.0 with crate(tokio-stream/default) < 0.2.0~) BuildRequires: (crate(tokio-test/default) >= 0.4.0 with crate(tokio-test/default) < 0.5.0~) +BuildRequires: (crate(wasm-bindgen-test/default) >= 0.3.0 with crate(wasm-bindgen-test/default) < 0.4.0~) %endif %global _description %{expand: -Event-driven, non-blocking I/O platform for writing asynchronous I/O -backed applications.} +Event-driven, non-blocking I/O platform for writing asynchronous I/O backed +applications.} %description %{_description} -%package -n %{crate} -Summary: %{summary} -Group: # FIXME - -%description -n %{crate} %{_description} - -%files -n %{crate} -%license LIC1 -%license LIC2 -%doc DOC1 -%doc DOC2 -%{_bindir}/tokio - %package devel Summary: %{summary} Group: Development/Rust @@ -399,6 +394,32 @@ use the "tokio-macros" feature of the "%{crate}" crate. %files -n %{name}+tokio-macros-devel %ghost %{crate_instdir}/Cargo.toml +%package -n %{name}+tracing-devel +Summary: %{summary} +Group: Development/Rust +BuildArch: noarch + +%description -n %{name}+tracing-devel %{_description} + +This package contains library source intended for building other packages which +use the "tracing" feature of the "%{crate}" crate. + +%files -n %{name}+tracing-devel +%ghost %{crate_instdir}/Cargo.toml + +%package -n %{name}+winapi-devel +Summary: %{summary} +Group: Development/Rust +BuildArch: noarch + +%description -n %{name}+winapi-devel %{_description} + +This package contains library source intended for building other packages which +use the "winapi" feature of the "%{crate}" crate. + +%files -n %{name}+winapi-devel +%ghost %{crate_instdir}/Cargo.toml + %prep %autosetup -n %{real_crate}-%{version_no_tilde} -p1 %cargo_prep diff --git a/rust2rpm/tests/samples/tokio-1.19.2.opensuse.spec b/rust2rpm/tests/samples/tokio-1.19.2.opensuse.spec index f64b1b7..409bc59 100644 --- a/rust2rpm/tests/samples/tokio-1.19.2.opensuse.spec +++ b/rust2rpm/tests/samples/tokio-1.19.2.opensuse.spec @@ -17,6 +17,7 @@ # Generated by rust2rpm NNN %bcond_without check +%global debug_package %{nil} %global crate tokio %global real_crate tokio-1.19.2 @@ -24,7 +25,7 @@ Name: rust-tokio-1.19.2 Version: 1.19.2 Release: 0 -Summary: Event-driven, non-blocking I/O platform for writing asynchronous I/O +Summary: Event-driven, non-blocking I/O platform for writing asynchronous I/O backed applications Group: Development/Libraries/Rust License: MIT @@ -44,36 +45,30 @@ BuildRequires: (crate(async-stream/default) >= 0.3.0 with crate(async-stream/de BuildRequires: (crate(futures/async-await) >= 0.3.0 with crate(futures/async-await) < 0.4.0~) BuildRequires: (crate(futures/default) >= 0.3.0 with crate(futures/default) < 0.4.0~) BuildRequires: (crate(libc/default) >= 0.2.42 with crate(libc/default) < 0.3.0~) +BuildRequires: (crate(loom/checkpoint) >= 0.5.2 with crate(loom/checkpoint) < 0.6.0~) +BuildRequires: (crate(loom/default) >= 0.5.2 with crate(loom/default) < 0.6.0~) +BuildRequires: (crate(loom/futures) >= 0.5.2 with crate(loom/futures) < 0.6.0~) +BuildRequires: (crate(mio-aio/default) >= 0.6.0 with crate(mio-aio/default) < 0.7.0~) +BuildRequires: (crate(mio-aio/tokio) >= 0.6.0 with crate(mio-aio/tokio) < 0.7.0~) BuildRequires: (crate(mockall/default) >= 0.11.1 with crate(mockall/default) < 0.12.0~) BuildRequires: (crate(nix/fs) >= 0.24.0 with crate(nix/fs) < 0.25.0~) BuildRequires: (crate(nix/socket) >= 0.24.0 with crate(nix/socket) < 0.25.0~) +BuildRequires: (crate(ntapi/default) >= 0.3.6 with crate(ntapi/default) < 0.4.0~) BuildRequires: (crate(proptest/default) >= 1.0.0 with crate(proptest/default) < 2.0.0~) BuildRequires: (crate(rand/default) >= 0.8.0 with crate(rand/default) < 0.9.0~) BuildRequires: (crate(socket2/default) >= 0.4.0 with crate(socket2/default) < 0.5.0~) BuildRequires: (crate(tempfile/default) >= 3.1.0 with crate(tempfile/default) < 4.0.0~) BuildRequires: (crate(tokio-stream/default) >= 0.1.0 with crate(tokio-stream/default) < 0.2.0~) BuildRequires: (crate(tokio-test/default) >= 0.4.0 with crate(tokio-test/default) < 0.5.0~) +BuildRequires: (crate(wasm-bindgen-test/default) >= 0.3.0 with crate(wasm-bindgen-test/default) < 0.4.0~) %endif %global _description %{expand: -Event-driven, non-blocking I/O platform for writing asynchronous I/O -backed applications.} +Event-driven, non-blocking I/O platform for writing asynchronous I/O backed +applications.} %description %{_description} -%package -n %{crate} -Summary: %{summary} -Group: # FIXME - -%description -n %{crate} %{_description} - -%files -n %{crate} -%license LIC1 -%license LIC2 -%doc DOC1 -%doc DOC2 -%{_bindir}/tokio - %package devel Summary: %{summary} Group: Development/Libraries/Rust @@ -416,6 +411,32 @@ use the "tokio-macros" feature of the "%{crate}" crate. %files -n %{name}+tokio-macros-devel %ghost %{crate_instdir}/Cargo.toml +%package -n %{name}+tracing-devel +Summary: %{summary} +Group: Development/Libraries/Rust +BuildArch: noarch + +%description -n %{name}+tracing-devel %{_description} + +This package contains library source intended for building other packages which +use the "tracing" feature of the "%{crate}" crate. + +%files -n %{name}+tracing-devel +%ghost %{crate_instdir}/Cargo.toml + +%package -n %{name}+winapi-devel +Summary: %{summary} +Group: Development/Libraries/Rust +BuildArch: noarch + +%description -n %{name}+winapi-devel %{_description} + +This package contains library source intended for building other packages which +use the "winapi" feature of the "%{crate}" crate. + +%files -n %{name}+winapi-devel +%ghost %{crate_instdir}/Cargo.toml + %prep %autosetup -n %{real_crate}-%{version_no_tilde} -p1 %cargo_prep diff --git a/rust2rpm/tests/samples/tokio-1.19.2.plain.spec b/rust2rpm/tests/samples/tokio-1.19.2.plain.spec index 6c7cc84..fbcc013 100644 --- a/rust2rpm/tests/samples/tokio-1.19.2.plain.spec +++ b/rust2rpm/tests/samples/tokio-1.19.2.plain.spec @@ -1,5 +1,6 @@ # Generated by rust2rpm NNN %bcond_without check +%global debug_package %{nil} %global crate tokio %global real_crate tokio-1.19.2 @@ -7,7 +8,7 @@ Name: rust-tokio-1.19.2 Version: 1.19.2 Release: 1%{?dist} -Summary: Event-driven, non-blocking I/O platform for writing asynchronous I/O +Summary: Event-driven, non-blocking I/O platform for writing asynchronous I/O backed applications License: MIT URL: https://crates.io/crates/tokio-1.19.2 @@ -26,35 +27,30 @@ BuildRequires: (crate(async-stream/default) >= 0.3.0 with crate(async-stream/de BuildRequires: (crate(futures/async-await) >= 0.3.0 with crate(futures/async-await) < 0.4.0~) BuildRequires: (crate(futures/default) >= 0.3.0 with crate(futures/default) < 0.4.0~) BuildRequires: (crate(libc/default) >= 0.2.42 with crate(libc/default) < 0.3.0~) +BuildRequires: (crate(loom/checkpoint) >= 0.5.2 with crate(loom/checkpoint) < 0.6.0~) +BuildRequires: (crate(loom/default) >= 0.5.2 with crate(loom/default) < 0.6.0~) +BuildRequires: (crate(loom/futures) >= 0.5.2 with crate(loom/futures) < 0.6.0~) +BuildRequires: (crate(mio-aio/default) >= 0.6.0 with crate(mio-aio/default) < 0.7.0~) +BuildRequires: (crate(mio-aio/tokio) >= 0.6.0 with crate(mio-aio/tokio) < 0.7.0~) BuildRequires: (crate(mockall/default) >= 0.11.1 with crate(mockall/default) < 0.12.0~) BuildRequires: (crate(nix/fs) >= 0.24.0 with crate(nix/fs) < 0.25.0~) BuildRequires: (crate(nix/socket) >= 0.24.0 with crate(nix/socket) < 0.25.0~) +BuildRequires: (crate(ntapi/default) >= 0.3.6 with crate(ntapi/default) < 0.4.0~) BuildRequires: (crate(proptest/default) >= 1.0.0 with crate(proptest/default) < 2.0.0~) BuildRequires: (crate(rand/default) >= 0.8.0 with crate(rand/default) < 0.9.0~) BuildRequires: (crate(socket2/default) >= 0.4.0 with crate(socket2/default) < 0.5.0~) BuildRequires: (crate(tempfile/default) >= 3.1.0 with crate(tempfile/default) < 4.0.0~) BuildRequires: (crate(tokio-stream/default) >= 0.1.0 with crate(tokio-stream/default) < 0.2.0~) BuildRequires: (crate(tokio-test/default) >= 0.4.0 with crate(tokio-test/default) < 0.5.0~) +BuildRequires: (crate(wasm-bindgen-test/default) >= 0.3.0 with crate(wasm-bindgen-test/default) < 0.4.0~) %endif %global _description %{expand: -Event-driven, non-blocking I/O platform for writing asynchronous I/O -backed applications.} +Event-driven, non-blocking I/O platform for writing asynchronous I/O backed +applications.} %description %{_description} -%package -n %{crate} -Summary: %{summary} - -%description -n %{crate} %{_description} - -%files -n %{crate} -%license LIC1 -%license LIC2 -%doc DOC1 -%doc DOC2 -%{_bindir}/tokio - %package devel Summary: %{summary} BuildArch: noarch @@ -251,6 +247,7 @@ Requires: cargo Requires: (crate(mio/net) >= 0.8.1 with crate(mio/net) < 0.9.0~) Requires: (crate(mio/os-ext) >= 0.8.1 with crate(mio/os-ext) < 0.9.0~) Requires: (crate(mio/os-poll) >= 0.8.1 with crate(mio/os-poll) < 0.9.0~) +Requires: (crate(winapi/namedpipeapi) >= 0.3.8 with crate(winapi/namedpipeapi) < 0.4.0~) Requires: crate(tokio) = 1.19.2 Requires: crate(tokio/libc) = 1.19.2 Requires: crate(tokio/socket2) = 1.19.2 @@ -319,6 +316,7 @@ Requires: cargo Requires: (crate(mio/net) >= 0.8.1 with crate(mio/net) < 0.9.0~) Requires: (crate(mio/os-ext) >= 0.8.1 with crate(mio/os-ext) < 0.9.0~) Requires: (crate(mio/os-poll) >= 0.8.1 with crate(mio/os-poll) < 0.9.0~) +Requires: (crate(winapi/threadpoollegacyapiset) >= 0.3.8 with crate(winapi/threadpoollegacyapiset) < 0.4.0~) Requires: crate(tokio) = 1.19.2 Requires: crate(tokio/bytes) = 1.19.2 Requires: crate(tokio/libc) = 1.19.2 @@ -374,6 +372,7 @@ Requires: cargo Requires: (crate(mio/net) >= 0.8.1 with crate(mio/net) < 0.9.0~) Requires: (crate(mio/os-ext) >= 0.8.1 with crate(mio/os-ext) < 0.9.0~) Requires: (crate(mio/os-poll) >= 0.8.1 with crate(mio/os-poll) < 0.9.0~) +Requires: (crate(winapi/consoleapi) >= 0.3.8 with crate(winapi/consoleapi) < 0.4.0~) Requires: crate(tokio) = 1.19.2 Requires: crate(tokio/libc) = 1.19.2 Requires: crate(tokio/once_cell) = 1.19.2 @@ -499,6 +498,43 @@ use the "tokio-macros" feature of the "%{crate}" crate. %files -n %{name}+tokio-macros-devel %ghost %{crate_instdir}/Cargo.toml +%package -n %{name}+tracing-devel +Summary: %{summary} +BuildArch: noarch +Provides: crate(tokio/tracing) = 1.19.2 +Requires: cargo +Requires: (crate(tracing/std) >= 0.1.25 with crate(tracing/std) < 0.2.0~) +Requires: crate(tokio) = 1.19.2 + +%description -n %{name}+tracing-devel %{_description} + +This package contains library source intended for building other packages which +use the "tracing" feature of the "%{crate}" crate. + +%files -n %{name}+tracing-devel +%ghost %{crate_instdir}/Cargo.toml + +%package -n %{name}+winapi-devel +Summary: %{summary} +BuildArch: noarch +Provides: crate(tokio/winapi) = 1.19.2 +Requires: cargo +Requires: (crate(winapi/handleapi) >= 0.3.8 with crate(winapi/handleapi) < 0.4.0~) +Requires: (crate(winapi/mswsock) >= 0.3.8 with crate(winapi/mswsock) < 0.4.0~) +Requires: (crate(winapi/std) >= 0.3.8 with crate(winapi/std) < 0.4.0~) +Requires: (crate(winapi/winsock2) >= 0.3.8 with crate(winapi/winsock2) < 0.4.0~) +Requires: (crate(winapi/ws2ipdef) >= 0.3.8 with crate(winapi/ws2ipdef) < 0.4.0~) +Requires: (crate(winapi/ws2tcpip) >= 0.3.8 with crate(winapi/ws2tcpip) < 0.4.0~) +Requires: crate(tokio) = 1.19.2 + +%description -n %{name}+winapi-devel %{_description} + +This package contains library source intended for building other packages which +use the "winapi" feature of the "%{crate}" crate. + +%files -n %{name}+winapi-devel +%ghost %{crate_instdir}/Cargo.toml + %prep %autosetup -n %{real_crate}-%{version_no_tilde} -p1 %cargo_prep diff --git a/rust2rpm/tests/test_generator.py b/rust2rpm/tests/test_generator.py index 27afb00..69468c2 100644 --- a/rust2rpm/tests/test_generator.py +++ b/rust2rpm/tests/test_generator.py @@ -1,12 +1,12 @@ from importlib import resources import os +from pathlib import Path import re import time import pytest -from cargo2rpm.metadata import Metadata - +from rust2rpm.core.metadata import Metadata as OldMetadata from rust2rpm.generator import to_list, spec_file_render from rust2rpm.__main__ import get_parser, package_name_suffixed, drop_foreign_dependencies @@ -29,23 +29,33 @@ def test_to_list(): FIXED_DATE = time.gmtime(12345) -@pytest.mark.parametrize("filename", ["cxx-build-1.0.71.json", "nix-0.24.1.json", "tokio-1.19.2.json"]) +@pytest.mark.parametrize("filename", ["cxx-build-1.0.71.toml", "nix-0.24.1.toml", "tokio-1.19.2.toml"]) @pytest.mark.parametrize("target", ["plain", "fedora", "mageia", "opensuse"]) -def test_spec_file_render(filename: str, target: str): - crate = filename.removesuffix(".crate") +def test_spec_file_render(filename: str, target: str, tmp_path: Path): + crate = filename.removesuffix(".toml") args = get_parser().parse_args(["foobar", f"--target={target}", "-a" if target == "fedora" else "--no-rpmautospec"]) pkg_name = package_name_suffixed(crate, args.suffix) - metadata = Metadata.from_json(resources.files("rust2rpm.tests.samples").joinpath(filename).read_text()) + real_path = resources.files("rust2rpm.tests.samples").joinpath(filename) + fake_path = tmp_path.joinpath("Cargo.toml") + + with open(real_path) as file, open(fake_path, "w") as fake: + print("Copying", real_path, "to", fake_path) + fake.write(file.read()) + + (tmp_path / "src").mkdir() + (tmp_path / "src" / "lib.rs").write_text("") + + metadata = OldMetadata.from_file(fake_path)[0] rendered = spec_file_render( args=args, pkg_name=pkg_name, crate=crate, metadata=metadata, - patch_file_automatic=None, - patch_file_manual=None, + patch_file_automatic=f"{crate}-patch1.diff", + patch_file_manual=f"{crate}-patch2.diff", packager="Jane Jane ", doc_files=["DOC1", "DOC2"], license_files=["LIC1", "LIC2"],