Skip to content

Commit 62667c6

Browse files
authored
Reduce binaries size (#798)
* Use Rust stripped binaries option With the new Rust 1.59 version, it is possible to strip standard library debug symbols directly from Cargo * Update cargo udeps This update is necessary to support the new Rust strip option
1 parent fd348f2 commit 62667c6

File tree

5 files changed

+11
-1
lines changed

5 files changed

+11
-1
lines changed

.taskcluster.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ tasks:
4242
- "curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py && python3 get-pip.py &&
4343
rustup component add clippy rustfmt &&
4444
rustup toolchain install nightly &&
45-
curl -L https://github.com/est31/cargo-udeps/releases/download/v0.1.25/cargo-udeps-v0.1.25-x86_64-unknown-linux-gnu.tar.gz | tar xz -C /usr/local/cargo/bin --strip-components 2 &&
45+
curl -L https://github.com/est31/cargo-udeps/releases/download/v0.1.27/cargo-udeps-v0.1.27-x86_64-unknown-linux-gnu.tar.gz | tar xz -C /usr/local/cargo/bin --strip-components 2 &&
4646
curl -L https://github.com/rustsec/rustsec/releases/download/cargo-audit%2Fv0.16.0/cargo-audit-x86_64-unknown-linux-musl-v0.16.0.tgz | tar xzv -C /usr/local/cargo/bin --strip-components 1 &&
4747
git clone --quiet ${repository} &&
4848
cd rust-code-analysis &&

Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,3 +55,4 @@ codegen-units = 1
5555
panic = "unwind"
5656
incremental = false
5757
overflow-checks = false
58+
strip = "debuginfo"

enums/Cargo.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,6 @@ tree-sitter-preproc = { path = "../tree-sitter-preproc", version = "=0.19.0" }
1818
tree-sitter-ccomment = { path = "../tree-sitter-ccomment", version = "=0.19.0" }
1919
tree-sitter-mozcpp = { path = "../tree-sitter-mozcpp", version = "=0.20.1" }
2020
tree-sitter-mozjs = { path = "../tree-sitter-mozjs", version = "=0.19.0" }
21+
22+
[profile.release]
23+
strip = "debuginfo"

rust-code-analysis-cli/Cargo.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,6 @@ serde_cbor = "^0.11"
2222
serde_json = "^1.0"
2323
serde_yaml = "^0.8"
2424
toml = "^0.5"
25+
26+
[profile.release]
27+
strip = "debuginfo"

rust-code-analysis-web/Cargo.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,6 @@ serde_json = "^1.0"
2323

2424
[dev-dependencies]
2525
pretty_assertions = "^1.0"
26+
27+
[profile.release]
28+
strip = "debuginfo"

0 commit comments

Comments
 (0)