Skip to content

Commit c67caee

Browse files
bzip2 support needed for benchmark test
1 parent cfe9120 commit c67caee

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

benches/extract.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ use std::path::Path;
99
use zip::result::ZipResult;
1010
use zip::ZipArchive;
1111

12-
#[cfg(all(feature = "parallelism", unix))]
12+
#[cfg(all(feature = "parallelism", feature = "bzip2", unix))]
1313
use zip::read::{split_extract, ExtractionParameters};
1414

1515
/* This archive has a set of entries repeated 20x:
@@ -47,10 +47,10 @@ fn extract_basic(bench: &mut Bencher) {
4747
});
4848
}
4949

50-
#[cfg(all(feature = "parallelism", unix))]
50+
#[cfg(all(feature = "parallelism", feature = "bzip2", unix))]
5151
const DECOMPRESSION_THREADS: usize = 8;
5252

53-
#[cfg(all(feature = "parallelism", unix))]
53+
#[cfg(all(feature = "parallelism", feature = "bzip2", unix))]
5454
fn extract_split(bench: &mut Bencher) {
5555
let readable_archive = get_test_archive().unwrap();
5656
let total_size: u64 = readable_archive
@@ -77,10 +77,10 @@ fn extract_split(bench: &mut Bencher) {
7777
});
7878
}
7979

80-
#[cfg(not(all(feature = "parallelism", unix)))]
80+
#[cfg(not(all(feature = "parallelism", feature = "bzip2", unix)))]
8181
benchmark_group!(benches, extract_basic);
8282

83-
#[cfg(all(feature = "parallelism", unix))]
83+
#[cfg(all(feature = "parallelism", feature = "bzip2", unix))]
8484
benchmark_group!(benches, extract_basic, extract_split);
8585

8686
benchmark_main!(benches);

0 commit comments

Comments
 (0)