split out compression code into new crate 'proxmox-compression'
this removes quite a bit of dependecies of proxmox-async Signed-off-by: Dominik Csapak <d.csapak@proxmox.com> [set proxmox-lang dep to 1.1] Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
This commit is contained in:
parent
d663ff328a
commit
b8bf6a5c81
@ -3,6 +3,7 @@ members = [
|
||||
"proxmox-api-macro",
|
||||
"proxmox-async",
|
||||
"proxmox-borrow",
|
||||
"proxmox-compression",
|
||||
"proxmox-http",
|
||||
"proxmox-io",
|
||||
"proxmox-lang",
|
||||
|
1
Makefile
1
Makefile
@ -4,6 +4,7 @@ CRATES = \
|
||||
proxmox-api-macro \
|
||||
proxmox-async \
|
||||
proxmox-borrow \
|
||||
proxmox-compression \
|
||||
proxmox-http \
|
||||
proxmox-io \
|
||||
proxmox-lang \
|
||||
|
@ -10,18 +10,12 @@ exclude = [ "debian" ]
|
||||
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
bytes = "1.0"
|
||||
crc32fast = "1"
|
||||
endian_trait = { version = "0.6", features = ["arrays"] }
|
||||
flate2 = "1.0"
|
||||
futures = "0.3"
|
||||
lazy_static = "1.4"
|
||||
pin-utils = "0.1.0"
|
||||
tokio = { version = "1.0", features = ["fs", "net", "rt", "rt-multi-thread", "sync"] }
|
||||
walkdir = "2"
|
||||
tokio = { version = "1.0", features = [ "net", "rt", "rt-multi-thread", "sync"] }
|
||||
|
||||
proxmox-io = { path = "../proxmox-io", version = "1", features = [ "tokio" ] }
|
||||
proxmox-time = { path = "../proxmox-time", version = "1" }
|
||||
proxmox-lang = { path = "../proxmox-lang", version = "1.1" }
|
||||
|
||||
[dev-dependencies]
|
||||
|
@ -1,8 +1,6 @@
|
||||
pub mod blocking;
|
||||
pub mod broadcast_future;
|
||||
pub mod compression;
|
||||
pub mod io;
|
||||
pub mod net;
|
||||
pub mod runtime;
|
||||
pub mod stream;
|
||||
pub mod zip;
|
||||
|
27
proxmox-compression/Cargo.toml
Normal file
27
proxmox-compression/Cargo.toml
Normal file
@ -0,0 +1,27 @@
|
||||
[package]
|
||||
name = "proxmox-compression"
|
||||
version = "0.1.0"
|
||||
authors = ["Proxmox Support Team <support@proxmox.com>"]
|
||||
edition = "2018"
|
||||
license = "AGPL-3"
|
||||
description = "contains compression utilitites (such as an Zip Encoder for async rust)"
|
||||
|
||||
exclude = [ "debian" ]
|
||||
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
bytes = "1.0"
|
||||
crc32fast = "1"
|
||||
endian_trait = { version = "0.6" }
|
||||
flate2 = "1.0"
|
||||
futures = "0.3"
|
||||
tokio = { version = "1.6", features = [ "fs", "io-util"] }
|
||||
walkdir = "2"
|
||||
|
||||
proxmox-time = { path = "../proxmox-time", version = "1" }
|
||||
proxmox-io = { path = "../proxmox-io", version = "1", features = [ "tokio" ] }
|
||||
proxmox-lang = { path = "../proxmox-lang", version = "1.1" }
|
||||
|
||||
[dev-dependencies]
|
||||
tokio = { version = "1.6", features = [ "macros" ] }
|
||||
|
5
proxmox-compression/debian/changelog
Normal file
5
proxmox-compression/debian/changelog
Normal file
@ -0,0 +1,5 @@
|
||||
rust-proxmox-compression (0.1.0-1) stable; urgency=medium
|
||||
|
||||
* initial split out of `proxmox-async`
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Fri, 18 Feb 2022 11:59:30 +0100
|
56
proxmox-compression/debian/control
Normal file
56
proxmox-compression/debian/control
Normal file
@ -0,0 +1,56 @@
|
||||
Source: rust-proxmox-compression
|
||||
Section: rust
|
||||
Priority: optional
|
||||
Build-Depends: debhelper (>= 12),
|
||||
dh-cargo (>= 25),
|
||||
cargo:native <!nocheck>,
|
||||
rustc:native <!nocheck>,
|
||||
libstd-rust-dev <!nocheck>,
|
||||
librust-anyhow-1+default-dev <!nocheck>,
|
||||
librust-bytes-1+default-dev <!nocheck>,
|
||||
librust-crc32fast-1+default-dev <!nocheck>,
|
||||
librust-endian-trait-0.6+default-dev <!nocheck>,
|
||||
librust-flate2-1+default-dev <!nocheck>,
|
||||
librust-futures-0.3+default-dev <!nocheck>,
|
||||
librust-proxmox-io-1+default-dev <!nocheck>,
|
||||
librust-proxmox-io-1+tokio-dev <!nocheck>,
|
||||
librust-proxmox-time-1+default-dev <!nocheck>,
|
||||
librust-tokio-1+default-dev <!nocheck>,
|
||||
librust-tokio-1+fs-dev <!nocheck>,
|
||||
librust-tokio-1+io-util-dev <!nocheck>,
|
||||
librust-walkdir-2+default-dev <!nocheck>
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
Standards-Version: 4.5.1
|
||||
Vcs-Git: git://git.proxmox.com/git/proxmox.git
|
||||
Vcs-Browser: https://git.proxmox.com/?p=proxmox.git
|
||||
Rules-Requires-Root: no
|
||||
|
||||
Package: librust-proxmox-compression-dev
|
||||
Architecture: any
|
||||
Multi-Arch: same
|
||||
Depends:
|
||||
${misc:Depends},
|
||||
librust-anyhow-1+default-dev,
|
||||
librust-bytes-1+default-dev,
|
||||
librust-crc32fast-1+default-dev,
|
||||
librust-endian-trait-0.6+default-dev,
|
||||
librust-flate2-1+default-dev,
|
||||
librust-futures-0.3+default-dev,
|
||||
librust-proxmox-io-1+default-dev,
|
||||
librust-proxmox-io-1+tokio-dev,
|
||||
librust-proxmox-time-1+default-dev,
|
||||
librust-tokio-1+default-dev,
|
||||
librust-tokio-1+fs-dev,
|
||||
librust-tokio-1+io-util-dev,
|
||||
librust-walkdir-2+default-dev
|
||||
Provides:
|
||||
librust-proxmox-compression+default-dev (= ${binary:Version}),
|
||||
librust-proxmox-compression-0-dev (= ${binary:Version}),
|
||||
librust-proxmox-compression-0+default-dev (= ${binary:Version}),
|
||||
librust-proxmox-compression-0.1-dev (= ${binary:Version}),
|
||||
librust-proxmox-compression-0.1+default-dev (= ${binary:Version}),
|
||||
librust-proxmox-compression-0.1.0-dev (= ${binary:Version}),
|
||||
librust-proxmox-compression-0.1.0+default-dev (= ${binary:Version})
|
||||
Description: Contains compression utilitites (such as an Zip Encoder for async rust) - Rust source code
|
||||
This package contains the source for the Rust proxmox-compression crate,
|
||||
packaged by debcargo for use with cargo and dh-cargo.
|
16
proxmox-compression/debian/copyright
Normal file
16
proxmox-compression/debian/copyright
Normal file
@ -0,0 +1,16 @@
|
||||
Copyright (C) 2022 Proxmox Server Solutions GmbH
|
||||
|
||||
This software is written by Proxmox Server Solutions GmbH <support@proxmox.com>
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
7
proxmox-compression/debian/debcargo.toml
Normal file
7
proxmox-compression/debian/debcargo.toml
Normal file
@ -0,0 +1,7 @@
|
||||
overlay = "."
|
||||
crate_src_path = ".."
|
||||
maintainer = "Proxmox Support Team <support@proxmox.com>"
|
||||
|
||||
[source]
|
||||
vcs_git = "git://git.proxmox.com/git/proxmox.git"
|
||||
vcs_browser = "https://git.proxmox.com/?p=proxmox.git"
|
4
proxmox-compression/src/lib.rs
Normal file
4
proxmox-compression/src/lib.rs
Normal file
@ -0,0 +1,4 @@
|
||||
mod compression;
|
||||
pub use compression::*;
|
||||
|
||||
pub mod zip;
|
@ -437,7 +437,7 @@ where
|
||||
/// use anyhow::{Error, Result};
|
||||
/// use tokio::fs::File;
|
||||
///
|
||||
/// use proxmox_async::zip::{ZipEncoder, ZipEntry};
|
||||
/// use proxmox_compression::zip::{ZipEncoder, ZipEntry};
|
||||
///
|
||||
/// #[tokio::main]
|
||||
/// async fn main() -> Result<(), Error> {
|
Loading…
Reference in New Issue
Block a user