lzma-sys-0.1.15/Cargo.toml.orig010066400017500001750000000011731352767701400145050ustar0000000000000000[package] name = "lzma-sys" version = "0.1.15" authors = ["Alex Crichton "] build = "build.rs" links = "lzma" license = "MIT/Apache-2.0" repository = "https://github.com/alexcrichton/xz2-rs" homepage = "https://github.com/alexcrichton/xz2-rs" documentation = "https://docs.rs/lzma-sys" description = """ Raw bindings to liblzma which contains an implementation of LZMA and xz stream encoding/decoding. High level Rust bindings are available in the `xz2` crate. """ categories = ["external-ffi-bindings"] edition = "2018" [dependencies] libc = "0.2.51" [build-dependencies] cc = "1.0.34" pkg-config = "0.3.14" lzma-sys-0.1.15/Cargo.toml0000644000000022620000000000000107360ustar00# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO # # When uploading crates to the registry Cargo will automatically # "normalize" Cargo.toml files for maximal compatibility # with all versions of Cargo and also rewrite `path` dependencies # to registry (e.g. crates.io) dependencies # # If you believe there's an error in this file please file an # issue against the rust-lang/cargo repository. If you're # editing this file be aware that the upstream Cargo.toml # will likely look very different (and much more reasonable) [package] edition = "2018" name = "lzma-sys" version = "0.1.15" authors = ["Alex Crichton "] build = "build.rs" links = "lzma" description = "Raw bindings to liblzma which contains an implementation of LZMA and xz stream\nencoding/decoding.\n\nHigh level Rust bindings are available in the `xz2` crate.\n" homepage = "https://github.com/alexcrichton/xz2-rs" documentation = "https://docs.rs/lzma-sys" categories = ["external-ffi-bindings"] license = "MIT/Apache-2.0" repository = "https://github.com/alexcrichton/xz2-rs" [dependencies.libc] version = "0.2.51" [build-dependencies.cc] version = "1.0.34" [build-dependencies.pkg-config] version = "0.3.14" lzma-sys-0.1.15/Cargo.toml.orig0000644000000022630000000000000116760ustar00# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO # # When uploading crates to the registry Cargo will automatically # "normalize" Cargo.toml files for maximal compatibility # with all versions of Cargo and also rewrite `path` dependencies # to registry (e.g., crates.io) dependencies # # If you believe there's an error in this file please file an # issue against the rust-lang/cargo repository. If you're # editing this file be aware that the upstream Cargo.toml # will likely look very different (and much more reasonable) [package] edition = "2018" name = "lzma-sys" version = "0.1.15" authors = ["Alex Crichton "] build = "build.rs" links = "lzma" description = "Raw bindings to liblzma which contains an implementation of LZMA and xz stream\nencoding/decoding.\n\nHigh level Rust bindings are available in the `xz2` crate.\n" homepage = "https://github.com/alexcrichton/xz2-rs" documentation = "https://docs.rs/lzma-sys" categories = ["external-ffi-bindings"] license = "MIT/Apache-2.0" repository = "https://github.com/alexcrichton/xz2-rs" [dependencies.libc] version = "0.2.51" [build-dependencies.cc] version = "1.0.34" [build-dependencies.pkg-config] version = "0.3.14" lzma-sys-0.1.15/LICENSE-APACHE010066400017500001750000000251371267270610500135420ustar0000000000000000 Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. lzma-sys-0.1.15/LICENSE-MIT010066400017500001750000000020411267270610500132370ustar0000000000000000Copyright (c) 2016 Alex Crichton 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. lzma-sys-0.1.15/build.rs010066400017500001750000000052061352767677100132750ustar0000000000000000use std::env; use std::fs; use std::path::PathBuf; const SKIP_FILENAMES: &[&str] = &["crc32_small", "crc64_small"]; fn main() { let target = env::var("TARGET").unwrap(); println!("cargo:rerun-if-env-changed=LZMA_API_STATIC"); let want_static = env::var("LZMA_API_STATIC").is_ok(); if !want_static && pkg_config::probe_library("liblzma").is_ok() { return; } let include_dir = env::current_dir().unwrap().join("xz-5.2/src/liblzma/api"); println!("cargo:include={}", include_dir.display()); let src_files = [ "xz-5.2/src/liblzma/common", "xz-5.2/src/liblzma/lzma", "xz-5.2/src/liblzma/lz", "xz-5.2/src/liblzma/check", "xz-5.2/src/liblzma/delta", "xz-5.2/src/liblzma/rangecoder", "xz-5.2/src/liblzma/simple", ] .iter() .flat_map(|dir| read_dir_files(dir)) .chain(vec![ "xz-5.2/src/common/tuklib_cpucores.c".into(), "xz-5.2/src/common/tuklib_physmem.c".into(), ]); let mut build = cc::Build::new(); build .files(src_files) // all C preproc defines are in `./config.h` .define("HAVE_CONFIG_H", "1") .include("xz-5.2/src/liblzma/api") .include("xz-5.2/src/liblzma/lzma") .include("xz-5.2/src/liblzma/lz") .include("xz-5.2/src/liblzma/check") .include("xz-5.2/src/liblzma/simple") .include("xz-5.2/src/liblzma/delta") .include("xz-5.2/src/liblzma/common") .include("xz-5.2/src/liblzma/rangecoder") .include("xz-5.2/src/common") .include(env::current_dir().unwrap()); if !target.ends_with("msvc") { build.flag("-std=c99").flag("-pthread"); } if let Ok(s) = env::var("CARGO_CFG_TARGET_ENDIAN") { if s == "big" { build.define("WORDS_BIGENDIAN", None); } } build.compile("liblzma.a"); } fn read_dir_files(dir: &str) -> impl Iterator { fs::read_dir(dir) .expect(&format!("failed to read dir {}", dir)) .filter_map(|ent| { let ent = ent.expect("failed to read entry"); if ent.file_type().unwrap().is_dir() { return None; } let path = ent.path(); if path.extension().unwrap() != "c" { return None; } { let file_stem = path.file_stem().unwrap().to_str().unwrap(); if SKIP_FILENAMES.contains(&file_stem) { return None; } if file_stem.ends_with("tablegen") { return None; } } Some(path) }) } lzma-sys-0.1.15/config.h010066400017500001750000000020031341316570600132170ustar0000000000000000// Configuration values for `liblzma` // tell `liblzma` to look for standard C99 headers #define HAVE_STDINT_H 1 #define HAVE_STDBOOL_H 1 #define HAVE_STRING_H 1 // enable encoders/decoders #define HAVE_DECODER_LZMA1 1 #define HAVE_DECODER_LZMA2 1 #define HAVE_ENCODER_LZMA1 1 #define HAVE_ENCODER_LZMA2 1 #define HAVE_DECODER_LZ 1 #define HAVE_ENCODER_LZ 1 #define HAVE_DECODER_DELTA 1 #define HAVE_ENCODER_DELTA 1 #define HAVE_DECODER_SPARC 1 #define HAVE_ENCODER_SPARC 1 #define HAVE_DECODER_X86 1 #define HAVE_ENCODER_X86 1 // enable checksums #define HAVE_CHECK_SHA256 1 #define HAVE_CHECK_CRC64 1 #define HAVE_CHECK_CRC32 1 // enable other liblzma stuff #define HAVE_MF_BT2 1 #define HAVE_MF_BT3 1 #define HAVE_MF_BT4 1 #define HAVE_MF_HC3 1 #define HAVE_MF_HC4 1 #if defined(MSC_VER) || defined(WIN32) || defined(WIN64) || defined(_WIN32) // change to `MYTHREAD_WIN95` if targeting Windows XP or earlier #define MYTHREAD_VISTA 1 #else #define _POSIX_C_SOURCE 199506L #define MYTHREAD_POSIX 1 #endif lzma-sys-0.1.15/src/lib.rs010066400017500001750000000265441345141127700135230ustar0000000000000000#![allow(bad_style)] #![doc(html_root_url = "https://docs.rs/lzma-sys/0.1")] use libc::{c_char, c_uchar, c_void, size_t}; use std::u64; #[cfg(target_env = "msvc")] #[doc(hidden)] pub type __enum_ty = libc::c_int; #[cfg(not(target_env = "msvc"))] #[doc(hidden)] pub type __enum_ty = libc::c_uint; pub type lzma_bool = c_uchar; pub type lzma_ret = __enum_ty; pub type lzma_action = __enum_ty; type lzma_reserved_enum = __enum_ty; pub type lzma_check = __enum_ty; pub type lzma_vli = u64; pub type lzma_mode = __enum_ty; pub type lzma_match_finder = __enum_ty; pub const LZMA_OK: lzma_ret = 0; pub const LZMA_STREAM_END: lzma_ret = 1; pub const LZMA_NO_CHECK: lzma_ret = 2; pub const LZMA_UNSUPPORTED_CHECK: lzma_ret = 3; pub const LZMA_GET_CHECK: lzma_ret = 4; pub const LZMA_MEM_ERROR: lzma_ret = 5; pub const LZMA_MEMLIMIT_ERROR: lzma_ret = 6; pub const LZMA_FORMAT_ERROR: lzma_ret = 7; pub const LZMA_OPTIONS_ERROR: lzma_ret = 8; pub const LZMA_DATA_ERROR: lzma_ret = 9; pub const LZMA_BUF_ERROR: lzma_ret = 10; pub const LZMA_PROG_ERROR: lzma_ret = 11; pub const LZMA_RUN: lzma_action = 0; pub const LZMA_SYNC_FLUSH: lzma_action = 1; pub const LZMA_FULL_FLUSH: lzma_action = 2; pub const LZMA_FULL_BARRIER: lzma_action = 4; pub const LZMA_FINISH: lzma_action = 3; pub const LZMA_CHECK_NONE: lzma_check = 0; pub const LZMA_CHECK_CRC32: lzma_check = 1; pub const LZMA_CHECK_CRC64: lzma_check = 4; pub const LZMA_CHECK_SHA256: lzma_check = 10; pub const LZMA_MODE_FAST: lzma_mode = 1; pub const LZMA_MODE_NORMAL: lzma_mode = 2; pub const LZMA_MF_HC3: lzma_match_finder = 0x03; pub const LZMA_MF_HC4: lzma_match_finder = 0x04; pub const LZMA_MF_BT2: lzma_match_finder = 0x12; pub const LZMA_MF_BT3: lzma_match_finder = 0x13; pub const LZMA_MF_BT4: lzma_match_finder = 0x14; pub const LZMA_TELL_NO_CHECK: u32 = 0x01; pub const LZMA_TELL_UNSUPPORTED_CHECK: u32 = 0x02; pub const LZMA_TELL_ANY_CHECK: u32 = 0x04; pub const LZMA_IGNORE_CHECK: u32 = 0x10; pub const LZMA_CONCATENATED: u32 = 0x08; pub const LZMA_PRESET_DEFAULT: u32 = 6; pub const LZMA_PRESET_LEVEL_MASK: u32 = 0x1f; pub const LZMA_PRESET_EXTREME: u32 = 1 << 31; pub const LZMA_DICT_SIZE_MIN: u32 = 4096; pub const LZMA_DICT_SIZE_DEFAULT: u32 = 1 << 23; pub const LZMA_LCLP_MIN: u32 = 0; pub const LZMA_LCLP_MAX: u32 = 4; pub const LZMA_LC_DEFAULT: u32 = 3; pub const LZMA_LP_DEFAULT: u32 = 0; pub const LZMA_PB_MIN: u32 = 0; pub const LZMA_PB_MAX: u32 = 4; pub const LZMA_PB_DEFAULT: u32 = 2; pub const LZMA_BACKWARD_SIZE_MIN: lzma_vli = 4; pub const LZMA_BACKWARD_SIZE_MAX: lzma_vli = 1 << 34; pub const LZMA_VLI_MAX: lzma_vli = u64::MAX / 2; pub const LZMA_VLI_UNKNOWN: lzma_vli = u64::MAX; pub const LZMA_VLI_BYTES_MAX: usize = 9; pub const LZMA_FILTER_X86: lzma_vli = 0x04; pub const LZMA_FILTER_POWERPC: lzma_vli = 0x05; pub const LZMA_FILTER_IA64: lzma_vli = 0x06; pub const LZMA_FILTER_ARM: lzma_vli = 0x07; pub const LZMA_FILTER_ARMTHUMB: lzma_vli = 0x08; pub const LZMA_FILTER_SPARC: lzma_vli = 0x09; pub const LZMA_FILTER_LZMA1: lzma_vli = 0x4000000000000001; pub const LZMA_FILTER_LZMA2: lzma_vli = 0x21; #[repr(C)] pub struct lzma_allocator { pub alloc: Option *mut c_void>, pub free: Option, pub opaque: *mut c_void, } pub enum lzma_internal {} #[repr(C)] pub struct lzma_stream { pub next_in: *const u8, pub avail_in: size_t, pub total_in: u64, pub next_out: *mut u8, pub avail_out: size_t, pub total_out: u64, pub allocator: *const lzma_allocator, internal: *mut lzma_internal, reserved_ptr1: *mut c_void, reserved_ptr2: *mut c_void, reserved_ptr3: *mut c_void, reserved_ptr4: *mut c_void, reserved_int1: u64, reserved_int2: u64, reserved_int3: size_t, reserved_int4: size_t, reserved_enum1: lzma_reserved_enum, reserved_enum2: lzma_reserved_enum, } #[repr(C)] pub struct lzma_filter { pub id: lzma_vli, pub options: *mut c_void, } #[repr(C)] pub struct lzma_mt { pub flags: u32, pub threads: u32, pub block_size: u64, pub timeout: u32, pub preset: u32, pub filters: *const lzma_filter, pub check: lzma_check, reserved_enum1: lzma_reserved_enum, reserved_enum2: lzma_reserved_enum, reserved_enum3: lzma_reserved_enum, reserved_int1: u32, reserved_int2: u32, reserved_int3: u32, reserved_int4: u32, reserved_int5: u64, reserved_int6: u64, reserved_int7: u64, reserved_int8: u64, reserved_ptr1: *mut c_void, reserved_ptr2: *mut c_void, reserved_ptr3: *mut c_void, reserved_ptr4: *mut c_void, } #[repr(C)] #[derive(Copy, Clone)] pub struct lzma_options_lzma { pub dict_size: u32, pub preset_dict: *const u8, pub preset_dict_size: u32, pub lc: u32, pub lp: u32, pub pb: u32, pub mode: lzma_mode, pub nice_len: u32, pub mf: lzma_match_finder, pub depth: u32, reserved_int1: u32, reserved_int2: u32, reserved_int3: u32, reserved_int4: u32, reserved_int5: u32, reserved_int6: u32, reserved_int7: u32, reserved_int8: u32, reserved_enum1: lzma_reserved_enum, reserved_enum2: lzma_reserved_enum, reserved_enum3: lzma_reserved_enum, reserved_enum4: lzma_reserved_enum, reserved_ptr1: *mut c_void, reserved_ptr2: *mut c_void, } #[repr(C)] pub struct lzma_stream_flags { pub version: u32, pub backward_size: lzma_vli, pub check: lzma_check, reserved_enum1: lzma_reserved_enum, reserved_enum2: lzma_reserved_enum, reserved_enum3: lzma_reserved_enum, reserved_enum4: lzma_reserved_enum, reserved_bool1: lzma_bool, reserved_bool2: lzma_bool, reserved_bool3: lzma_bool, reserved_bool4: lzma_bool, reserved_bool5: lzma_bool, reserved_bool6: lzma_bool, reserved_bool7: lzma_bool, reserved_bool8: lzma_bool, reserved_int1: u32, reserved_int2: u32, } #[repr(C)] pub struct lzma_options_bcj { pub start_offset: u32, } extern "C" { pub fn lzma_code(strm: *mut lzma_stream, action: lzma_action) -> lzma_ret; pub fn lzma_end(strm: *mut lzma_stream); pub fn lzma_get_progress(strm: *mut lzma_stream, progress_in: *mut u64, progress_out: *mut u64); pub fn lzma_memusage(strm: *const lzma_stream) -> u64; pub fn lzma_memlimit_get(strm: *const lzma_stream) -> u64; pub fn lzma_memlimit_set(strm: *mut lzma_stream, memlimit: u64) -> lzma_ret; pub fn lzma_easy_encoder_memusage(preset: u32) -> u64; pub fn lzma_easy_decoder_memusage(preset: u32) -> u64; pub fn lzma_easy_encoder(strm: *mut lzma_stream, preset: u32, check: lzma_check) -> lzma_ret; pub fn lzma_easy_buffer_encode( preset: u32, check: lzma_check, allocator: *const lzma_allocator, input: *const u8, in_size: size_t, out: *mut u8, out_pos: *mut size_t, out_size: size_t, ) -> lzma_ret; pub fn lzma_stream_encoder( strm: *mut lzma_stream, filters: *const lzma_filter, check: lzma_check, ) -> lzma_ret; pub fn lzma_stream_encoder_mt_memusage(options: *const lzma_mt) -> u64; pub fn lzma_stream_encoder_mt(strm: *mut lzma_stream, options: *const lzma_mt) -> lzma_ret; pub fn lzma_alone_encoder( strm: *mut lzma_stream, options: *const lzma_options_lzma, ) -> lzma_ret; pub fn lzma_stream_buffer_bound(uncompressed_size: size_t) -> size_t; pub fn lzma_stream_buffer_encode( filters: *mut lzma_filter, check: lzma_check, allocator: *const lzma_allocator, input: *const u8, in_size: size_t, out: *mut u8, out_pos: *mut size_t, out_size: size_t, ) -> lzma_ret; pub fn lzma_stream_decoder(strm: *mut lzma_stream, memlimit: u64, flags: u32) -> lzma_ret; pub fn lzma_auto_decoder(strm: *mut lzma_stream, memlimit: u64, flags: u32) -> lzma_ret; pub fn lzma_alone_decoder(strm: *mut lzma_stream, memlimit: u64) -> lzma_ret; pub fn lzma_stream_buffer_decode( memlimit: *mut u64, flags: u32, allocator: *const lzma_allocator, input: *const u8, in_pos: *mut size_t, in_size: size_t, out: *mut u8, out_pos: *mut size_t, out_size: size_t, ) -> lzma_ret; pub fn lzma_check_is_supported(check: lzma_check) -> lzma_bool; pub fn lzma_check_size(check: lzma_check) -> u32; pub fn lzma_crc32(buf: *const u8, size: size_t, crc: u32) -> u32; pub fn lzma_crc64(buf: *const u8, size: size_t, crc: u64) -> u64; pub fn lzma_get_check(strm: *const lzma_stream) -> lzma_check; pub fn lzma_filter_encoder_is_supported(id: lzma_vli) -> lzma_bool; pub fn lzma_filter_decoder_is_supported(id: lzma_vli) -> lzma_bool; pub fn lzma_filters_copy( src: *const lzma_filter, dest: *mut lzma_filter, allocator: *const lzma_allocator, ) -> lzma_ret; pub fn lzma_raw_encoder_memusage(filters: *const lzma_filter) -> u64; pub fn lzma_raw_decoder_memusage(filters: *const lzma_filter) -> u64; pub fn lzma_raw_encoder(strm: *mut lzma_stream, filters: *const lzma_filter) -> lzma_ret; pub fn lzma_raw_decoder(strm: *mut lzma_stream, filters: *const lzma_filter) -> lzma_ret; pub fn lzma_filters_update(strm: *mut lzma_stream, filters: *const lzma_filter) -> lzma_ret; pub fn lzma_raw_buffer_encode( filters: *const lzma_filter, allocator: *const lzma_allocator, input: *const u8, in_size: size_t, out: *mut u8, out_pos: *mut size_t, out_size: size_t, ) -> lzma_ret; pub fn lzma_raw_buffer_decode( filters: *const lzma_filter, allocator: *const lzma_allocator, input: *const u8, in_pos: *mut size_t, in_size: size_t, out: *mut u8, out_pos: *mut size_t, out_size: size_t, ) -> lzma_ret; pub fn lzma_properties_size(size: *mut u32, filter: *const lzma_filter) -> lzma_ret; pub fn lzma_properties_encode(filter: *const lzma_filter, props: *mut u8) -> lzma_ret; pub fn lzma_properties_decode( filter: *mut lzma_filter, allocator: *const lzma_allocator, props: *const u8, props_size: size_t, ) -> lzma_ret; pub fn lzma_physmem() -> u64; pub fn lzma_cputhreads() -> u32; pub fn lzma_stream_header_encode(options: *const lzma_stream_flags, out: *mut u8) -> lzma_ret; pub fn lzma_stream_footer_encode(options: *const lzma_stream_flags, out: *mut u8) -> lzma_ret; pub fn lzma_stream_header_decode(options: *mut lzma_stream_flags, input: *const u8) -> lzma_ret; pub fn lzma_stream_footer_decode(options: *mut lzma_stream_flags, input: *const u8) -> lzma_ret; pub fn lzma_stream_flags_compare( a: *const lzma_stream_flags, b: *const lzma_stream_flags, ) -> lzma_ret; pub fn lzma_version_number() -> u32; pub fn lzma_version_string() -> *const c_char; pub fn lzma_vli_encode( vli: lzma_vli, vli_pos: *mut size_t, out: *mut u8, out_pos: *mut size_t, out_size: size_t, ) -> lzma_ret; pub fn lzma_vli_decode( vli: *mut lzma_vli, vli_pos: *mut size_t, input: *const u8, in_pos: *mut size_t, in_size: size_t, ) -> lzma_ret; pub fn lzma_vli_size(vli: lzma_vli) -> u32; pub fn lzma_lzma_preset(options: *mut lzma_options_lzma, preset: u32) -> lzma_bool; pub fn lzma_mf_is_supported(mf: lzma_match_finder) -> lzma_bool; } lzma-sys-0.1.15/.cargo_vcs_info.json0000644000000001120000000000000127300ustar00{ "git": { "sha1": "6a84d8567c7fd2f4b39e85bbe531fea17febb3b6" } }