Skip to content

Instantly share code, notes, and snippets.

@susilolab
Created October 22, 2023 13:18
Show Gist options
  • Save susilolab/d19a8bf7127ebc09c7ec35a6887e9f31 to your computer and use it in GitHub Desktop.
Save susilolab/d19a8bf7127ebc09c7ec35a6887e9f31 to your computer and use it in GitHub Desktop.
Compile rust secara static binary
#!/bin/bash
RUSTFLAGS='-C target-feature=+crt-static' cargo build --release --target x86_64-unknown-linux-musl
# hasil compile diatas akan bisa dieksekusi disemua os linux
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment