gecko-dev/third_party/rust/bzip2-sys/lib.rs
Andreas Tolfsen 318d3094c5 Bug 1414254 - Vendor Rust dependencies r=jgraham
MozReview-Commit-ID: CnT3DLl2KBR

--HG--
rename : third_party/rust/base64-0.5.2/LICENSE-APACHE => third_party/rust/cc/LICENSE-APACHE
rename : third_party/rust/gcc-0.3.42/LICENSE-MIT => third_party/rust/cc/LICENSE-MIT
rename : third_party/rust/gcc-0.3.42/src/bin/gcc-shim.rs => third_party/rust/cc/src/bin/gcc-shim.rs
rename : third_party/rust/gcc-0.3.42/src/registry.rs => third_party/rust/cc/src/registry.rs
rename : third_party/rust/clap/.cargo-checksum.json => third_party/rust/clap-2.25.0/.cargo-checksum.json
rename : third_party/rust/clap-2.24.2/.clog.toml => third_party/rust/clap-2.25.0/.clog.toml
rename : third_party/rust/clap-2.24.2/.github/CONTRIBUTING.md => third_party/rust/clap-2.25.0/.github/CONTRIBUTING.md
rename : third_party/rust/clap-2.24.2/.github/ISSUE_TEMPLATE.md => third_party/rust/clap-2.25.0/.github/ISSUE_TEMPLATE.md
rename : third_party/rust/clap-2.24.2/.travis.yml => third_party/rust/clap-2.25.0/.travis.yml
rename : third_party/rust/clap/CHANGELOG.md => third_party/rust/clap-2.25.0/CHANGELOG.md
rename : third_party/rust/clap-2.24.2/CONTRIBUTORS.md => third_party/rust/clap-2.25.0/CONTRIBUTORS.md
rename : third_party/rust/clap/Cargo.toml => third_party/rust/clap-2.25.0/Cargo.toml
rename : third_party/rust/clap-2.24.2/LICENSE-MIT => third_party/rust/clap-2.25.0/LICENSE-MIT
rename : third_party/rust/clap/README.md => third_party/rust/clap-2.25.0/README.md
rename : third_party/rust/clap-2.24.2/index.html => third_party/rust/clap-2.25.0/index.html
rename : third_party/rust/clap-2.24.2/justfile => third_party/rust/clap-2.25.0/justfile
rename : third_party/rust/clap-2.24.2/rustfmt.toml => third_party/rust/clap-2.25.0/rustfmt.toml
rename : third_party/rust/clap/src/app/help.rs => third_party/rust/clap-2.25.0/src/app/help.rs
rename : third_party/rust/clap/src/app/macros.rs => third_party/rust/clap-2.25.0/src/app/macros.rs
rename : third_party/rust/clap-2.24.2/src/app/meta.rs => third_party/rust/clap-2.25.0/src/app/meta.rs
rename : third_party/rust/clap-2.24.2/src/app/mod.rs => third_party/rust/clap-2.25.0/src/app/mod.rs
rename : third_party/rust/clap/src/app/parser.rs => third_party/rust/clap-2.25.0/src/app/parser.rs
rename : third_party/rust/clap/src/app/settings.rs => third_party/rust/clap-2.25.0/src/app/settings.rs
rename : third_party/rust/clap/src/app/validator.rs => third_party/rust/clap-2.25.0/src/app/validator.rs
rename : third_party/rust/clap-2.24.2/src/args/any_arg.rs => third_party/rust/clap-2.25.0/src/args/any_arg.rs
rename : third_party/rust/clap-2.24.2/src/args/arg.rs => third_party/rust/clap-2.25.0/src/args/arg.rs
rename : third_party/rust/clap-2.24.2/src/args/arg_builder/base.rs => third_party/rust/clap-2.25.0/src/args/arg_builder/base.rs
rename : third_party/rust/clap-2.24.2/src/args/arg_builder/flag.rs => third_party/rust/clap-2.25.0/src/args/arg_builder/flag.rs
rename : third_party/rust/clap-2.24.2/src/args/arg_builder/mod.rs => third_party/rust/clap-2.25.0/src/args/arg_builder/mod.rs
rename : third_party/rust/clap-2.24.2/src/args/arg_builder/option.rs => third_party/rust/clap-2.25.0/src/args/arg_builder/option.rs
rename : third_party/rust/clap/src/args/arg_builder/positional.rs => third_party/rust/clap-2.25.0/src/args/arg_builder/positional.rs
rename : third_party/rust/clap-2.24.2/src/args/arg_builder/switched.rs => third_party/rust/clap-2.25.0/src/args/arg_builder/switched.rs
rename : third_party/rust/clap-2.24.2/src/args/arg_builder/valued.rs => third_party/rust/clap-2.25.0/src/args/arg_builder/valued.rs
rename : third_party/rust/clap-2.24.2/src/args/arg_matcher.rs => third_party/rust/clap-2.25.0/src/args/arg_matcher.rs
rename : third_party/rust/clap-2.24.2/src/args/arg_matches.rs => third_party/rust/clap-2.25.0/src/args/arg_matches.rs
rename : third_party/rust/clap-2.24.2/src/args/matched_arg.rs => third_party/rust/clap-2.25.0/src/args/matched_arg.rs
rename : third_party/rust/clap-2.24.2/src/args/mod.rs => third_party/rust/clap-2.25.0/src/args/mod.rs
rename : third_party/rust/clap-2.24.2/src/args/subcommand.rs => third_party/rust/clap-2.25.0/src/args/subcommand.rs
rename : third_party/rust/clap-2.24.2/src/completions/bash.rs => third_party/rust/clap-2.25.0/src/completions/bash.rs
rename : third_party/rust/clap-2.24.2/src/completions/fish.rs => third_party/rust/clap-2.25.0/src/completions/fish.rs
rename : third_party/rust/clap-2.24.2/src/completions/macros.rs => third_party/rust/clap-2.25.0/src/completions/macros.rs
rename : third_party/rust/clap-2.24.2/src/completions/mod.rs => third_party/rust/clap-2.25.0/src/completions/mod.rs
rename : third_party/rust/clap-2.24.2/src/completions/shell.rs => third_party/rust/clap-2.25.0/src/completions/shell.rs
rename : third_party/rust/clap-2.24.2/src/completions/zsh.rs => third_party/rust/clap-2.25.0/src/completions/zsh.rs
rename : third_party/rust/clap/src/lib.rs => third_party/rust/clap-2.25.0/src/lib.rs
rename : third_party/rust/clap/src/macros.rs => third_party/rust/clap-2.25.0/src/macros.rs
rename : third_party/rust/clap-2.24.2/src/osstringext.rs => third_party/rust/clap-2.25.0/src/osstringext.rs
rename : third_party/rust/clap-2.24.2/src/strext.rs => third_party/rust/clap-2.25.0/src/strext.rs
rename : third_party/rust/clap/src/suggestions.rs => third_party/rust/clap-2.25.0/src/suggestions.rs
rename : third_party/rust/clap-2.24.2/src/usage_parser.rs => third_party/rust/clap-2.25.0/src/usage_parser.rs
rename : third_party/rust/gcc-0.3.42/LICENSE-APACHE => third_party/rust/libc-0.2.30/LICENSE-APACHE
rename : third_party/rust/log-0.3.6/LICENSE-MIT => third_party/rust/libc-0.2.30/LICENSE-MIT
rename : third_party/rust/num-integer/.cargo-checksum.json => third_party/rust/num-integer-0.1.33/.cargo-checksum.json
rename : third_party/rust/num-integer/Cargo.toml => third_party/rust/num-integer-0.1.33/Cargo.toml
rename : third_party/rust/log-0.3.6/LICENSE-APACHE => third_party/rust/num-integer-0.1.33/LICENSE-APACHE
rename : third_party/rust/num-traits-0.1.37/LICENSE-MIT => third_party/rust/num-integer-0.1.33/LICENSE-MIT
rename : third_party/rust/num-integer/src/lib.rs => third_party/rust/num-integer-0.1.33/src/lib.rs
rename : third_party/rust/num-traits/.cargo-checksum.json => third_party/rust/num-traits-0.1.39/.cargo-checksum.json
rename : third_party/rust/num-traits/Cargo.toml => third_party/rust/num-traits-0.1.39/Cargo.toml
rename : third_party/rust/num-traits-0.1.37/LICENSE-APACHE => third_party/rust/num-traits-0.1.39/LICENSE-APACHE
rename : third_party/rust/regex-0.2.1/LICENSE-MIT => third_party/rust/num-traits-0.1.39/LICENSE-MIT
rename : third_party/rust/num-traits-0.1.37/src/float.rs => third_party/rust/num-traits-0.1.39/src/float.rs
rename : third_party/rust/num-traits-0.1.37/src/int.rs => third_party/rust/num-traits-0.1.39/src/int.rs
rename : third_party/rust/num-traits-0.1.37/src/ops/mod.rs => third_party/rust/num-traits-0.1.39/src/ops/mod.rs
rename : third_party/rust/num-traits-0.1.37/src/ops/saturating.rs => third_party/rust/num-traits-0.1.39/src/ops/saturating.rs
rename : third_party/rust/num-traits-0.1.37/src/pow.rs => third_party/rust/num-traits-0.1.39/src/pow.rs
rename : third_party/rust/num_cpus-1.2.1/.travis.yml => third_party/rust/num_cpus-1.6.2/.travis.yml
rename : third_party/rust/num_cpus-1.2.1/LICENSE-APACHE => third_party/rust/num_cpus-1.6.2/LICENSE-APACHE
rename : third_party/rust/num_cpus-1.2.1/LICENSE-MIT => third_party/rust/num_cpus-1.6.2/LICENSE-MIT
rename : third_party/rust/textwrap/.appveyor.yml => third_party/rust/textwrap-0.6.0/.appveyor.yml
rename : third_party/rust/textwrap/.cargo-checksum.json => third_party/rust/textwrap-0.6.0/.cargo-checksum.json
rename : third_party/rust/textwrap/.travis.yml => third_party/rust/textwrap-0.6.0/.travis.yml
rename : third_party/rust/textwrap/Cargo.toml => third_party/rust/textwrap-0.6.0/Cargo.toml
rename : third_party/rust/textwrap/README.md => third_party/rust/textwrap-0.6.0/README.md
rename : third_party/rust/textwrap/benches/linear.rs => third_party/rust/textwrap-0.6.0/benches/linear.rs
rename : third_party/rust/textwrap/examples/layout.rs => third_party/rust/textwrap-0.6.0/examples/layout.rs
rename : third_party/rust/textwrap/examples/termwidth.rs => third_party/rust/textwrap-0.6.0/examples/termwidth.rs
rename : third_party/rust/textwrap/src/lib.rs => third_party/rust/textwrap-0.6.0/src/lib.rs
extra : rebase_source : 75ee4cb067c477d9bd7921594fd0138355392635
2017-11-03 13:39:05 +00:00

76 lines
2.3 KiB
Rust

#![doc(html_root_url = "https://docs.rs/bzip2-sys/0.1")]
extern crate libc;
use libc::{c_int, c_uint, c_void, c_char};
pub const BZ_RUN: c_int = 0;
pub const BZ_FLUSH: c_int = 1;
pub const BZ_FINISH: c_int = 2;
pub const BZ_OK: c_int = 0;
pub const BZ_RUN_OK: c_int = 1;
pub const BZ_FLUSH_OK: c_int = 2;
pub const BZ_FINISH_OK: c_int = 3;
pub const BZ_STREAM_END: c_int = 4;
pub const BZ_SEQUENCE_ERROR: c_int = -1;
pub const BZ_PARAM_ERROR: c_int = -2;
pub const BZ_MEM_ERROR: c_int = -3;
pub const BZ_DATA_ERROR: c_int = -4;
pub const BZ_DATA_ERROR_MAGIC: c_int = -5;
pub const BZ_IO_ERROR: c_int = -6;
pub const BZ_UNEXPECTED_EOF: c_int = -7;
pub const BZ_OUTBUFF_FULL: c_int = -8;
pub const BZ_CONFIG_ERROR: c_int = -9;
#[repr(C)]
pub struct bz_stream {
pub next_in: *mut c_char,
pub avail_in: c_uint,
pub total_in_lo32: c_uint,
pub total_in_hi32: c_uint,
pub next_out: *mut c_char,
pub avail_out: c_uint,
pub total_out_lo32: c_uint,
pub total_out_hi32: c_uint,
pub state: *mut c_void,
pub bzalloc: Option<extern fn(*mut c_void, c_int, c_int) -> *mut c_void>,
pub bzfree: Option<extern fn(*mut c_void, *mut c_void)>,
pub opaque: *mut c_void,
}
macro_rules! abi_compat {
($(pub fn $name:ident($($arg:ident: $t:ty),*) -> $ret:ty,)*) => {
#[cfg(windows)]
extern "system" {
$(pub fn $name($($arg: $t),*) -> $ret;)*
}
#[cfg(any(unix, target_os = "redox"))]
extern {
$(pub fn $name($($arg: $t),*) -> $ret;)*
}
}
}
abi_compat! {
pub fn BZ2_bzCompressInit(stream: *mut bz_stream,
blockSize100k: c_int,
verbosity: c_int,
workFactor: c_int) -> c_int,
pub fn BZ2_bzCompress(stream: *mut bz_stream, action: c_int) -> c_int,
pub fn BZ2_bzCompressEnd(stream: *mut bz_stream) -> c_int,
pub fn BZ2_bzDecompressInit(stream: *mut bz_stream,
verbosity: c_int,
small: c_int) -> c_int,
pub fn BZ2_bzDecompress(stream: *mut bz_stream) -> c_int,
pub fn BZ2_bzDecompressEnd(stream: *mut bz_stream) -> c_int,
}
#[no_mangle]
pub fn bz_internal_error(errcode: c_int) {
panic!("bz internal error: {}", errcode);
}