Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/guedou/cargo-strip
Strip Rust binaries created with cargo
https://github.com/guedou/cargo-strip
binary cargo rust strip
Last synced: 7 days ago
JSON representation
Strip Rust binaries created with cargo
- Host: GitHub
- URL: https://github.com/guedou/cargo-strip
- Owner: guedou
- License: mit
- Created: 2019-12-28T14:53:44.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2022-03-28T20:25:57.000Z (almost 3 years ago)
- Last Synced: 2024-12-20T09:05:59.760Z (14 days ago)
- Topics: binary, cargo, rust, strip
- Language: Rust
- Homepage:
- Size: 27.3 KB
- Stars: 88
- Watchers: 4
- Forks: 2
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# cargo-strip
[![crates.io badge](https://img.shields.io/crates/v/cargo-strip.svg)](https://crates.io/crates/cargo-strip)
![CI](https://github.com/guedou/cargo-strip/workflows/CI/badge.svg)
[![Twitter Follow](https://img.shields.io/twitter/follow/guedou.svg?style=social)](https://twitter.com/intent/follow?screen_name=guedou)As of Rust 1.59, the `cargo` command is now able to [strip a binary](https://doc.rust-lang.org/beta/cargo/reference/profiles.html#strip). This can be enabled in your `Cargo.toml` in the following way:
```
[package]
# ...[profile.release]
strip="debuginfo"
```---
A cargo subcommand that reduces the size of Rust binaries using the `strip` command.
## Installation & Usage
Run the following command:
```
cargo install --force cargo-strip
```Simply strip your binary with:
```
cargo strip
```When cross-compiling, the `--target` could be used to strip the binary, such as:
```
cargo strip --target armv7-unknown-linux-gnueabihf
```