mirror of
https://github.com/RustPython/RustPython.git
synced 2026-10-29 03:04:38 +08:00
optional bz2
This commit is contained in:
1 parent
b17c891115
commit
da9c98675b
3 files changed
+8
-3
No files matched your search
@@ -27,6 +27,7 @@ jit = ["rustpython-vm/jit"]
|
||||
threading = ["rustpython-vm/threading", "rustpython-stdlib/threading"]
|
||||
pylib = ["rustpython-vm/pylib"]
|
||||
zlib = ["stdlib", "rustpython-stdlib/zlib"]
|
||||
bz2 = ["stdlib", "rustpython-stdlib/bz2"]
|
||||
ssl = ["rustpython-stdlib/ssl"]
|
||||
ssl-vendor = ["rustpython-stdlib/ssl-vendor"]
|
||||
|
||||
|
||||
+2
-1
@@ -41,7 +41,7 @@ unic-ucd-ident = "0.9.0"
|
||||
adler32 = "1.2.0"
|
||||
crc32fast = "1.3.2"
|
||||
flate2 = "1.0.23"
|
||||
bzip2 = "0.4"
|
||||
bzip2 = { version = "0.4", optional = true }
|
||||
|
||||
num-complex = "0.4.0"
|
||||
num-bigint = "0.4.3"
|
||||
@@ -86,6 +86,7 @@ compiler = ["rustpython-vm/compiler"]
|
||||
# parser = ["rustpython-parser", "ast"]
|
||||
|
||||
zlib = ["libz-sys", "flate2/zlib"]
|
||||
bz2 = ["bzip2"]
|
||||
ssl = ["openssl", "openssl-sys", "foreign-types-shared"]
|
||||
ssl-vendor = ["ssl", "openssl/vendored", "openssl-probe"]
|
||||
|
||||
|
||||
+5
-2
@@ -25,7 +25,7 @@ mod random;
|
||||
mod statistics;
|
||||
// TODO: maybe make this an extension module, if we ever get those
|
||||
// mod re;
|
||||
#[cfg(not(any(target_arch = "wasm32")))]
|
||||
#[cfg(feature = "bz2")]
|
||||
mod bz2;
|
||||
#[cfg(not(target_arch = "wasm32"))]
|
||||
pub mod socket;
|
||||
@@ -117,12 +117,15 @@ pub fn get_module_inits() -> impl Iterator<Item = (Cow<'static, str>, StdlibInit
|
||||
"select" => select::make_module,
|
||||
"_socket" => socket::make_module,
|
||||
"faulthandler" => faulthandler::make_module,
|
||||
"_bz2" => bz2::make_module,
|
||||
}
|
||||
#[cfg(feature = "ssl")]
|
||||
{
|
||||
"_ssl" => ssl::make_module,
|
||||
}
|
||||
#[cfg(feature = "bz2")]
|
||||
{
|
||||
"_bz2" => bz2::make_module,
|
||||
}
|
||||
// Unix-only
|
||||
#[cfg(unix)]
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user