Skip to content

Commit 781d747

Browse files
authored
fix(bundler/rpm): Reduce compression level to gzip/6 (#9840)
1 parent 5d20530 commit 781d747

2 files changed

Lines changed: 8 additions & 1 deletion

File tree

.changes/rpm-compression-level.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
tauri-bundler: patch:enhance
3+
---
4+
5+
Reduced the compression level for rpm bundles from 9 (max) to 6. This has almost no effect on file size but should reduce build time by roughly 25%.

tooling/bundler/src/bundle/linux/rpm.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,9 @@ pub fn bundle_project(settings: &Settings) -> crate::Result<Vec<PathBuf>> {
4747
let license = settings.license().unwrap_or_default();
4848
let mut builder = rpm::PackageBuilder::new(name, version, &license, arch, summary)
4949
.epoch(epoch)
50-
.release(release);
50+
.release(release)
51+
// This matches .deb compression. On a 240MB source binary the bundle will be 100KB larger than rpm's default while reducing build times by ~25%.
52+
.compression(rpm::CompressionWithLevel::Gzip(6));
5153

5254
if let Some(description) = settings.long_description() {
5355
builder = builder.description(description.trim())

0 commit comments

Comments
 (0)