Skip to content

Commit 3a26f23

Browse files
authored
Add documentation for using upx (#20)
1 parent cc1521c commit 3a26f23

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,17 @@ Available starting `1.45.0-nightly (2020-05-28)`,
4949
$ cargo +nightly build -Z strip=symbols
5050
```
5151

52+
# Compress the binary
53+
54+
[`uxp`](https://github.com/upx/upx) is a powerful tool for creating a self contained, compressed binary with no addition
55+
runtime requirements. It claims to typically reduce file size by 50-70% but the actual result depends on your
56+
executable. For our example we see a respectable 23% reduction.
57+
58+
```bash
59+
$ uxp --best --lzma target/release/min-sized-rust
60+
```
61+
62+
5263
# Optimize For Size
5364

5465
![Minimum Rust: 1.28](https://img.shields.io/badge/Minimum%20Rust%20Version-1.28-brightgreen.svg)

0 commit comments

Comments
 (0)