Skip to content

Commit

Permalink
add cross build dep
Browse files Browse the repository at this point in the history
  • Loading branch information
MXWXZ committed Aug 30, 2024
1 parent 995435f commit 0f830f8
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 16 deletions.
16 changes: 0 additions & 16 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,3 @@ resolver = "2"
[profile.release]
lto = true
codegen-units = 1

[workspace.metadata.cross.target.i686-unknown-linux-gnu]
pre-build = [
"curl -LO https://github.com/protocolbuffers/protobuf/releases/download/v27.3/protoc-27.3-linux-x86_32.zip",
"unzip protoc-27.3-linux-x86_32.zip -d $HOME/.local",
"rm protoc-27.3-linux-x86_32.zip",
"mv $HOME/.local/bin/* /usr/bin/",
]

[workspace.metadata.cross.target.aarch64-unknown-linux-gnu]
pre-build = [
"curl -LO https://github.com/protocolbuffers/protobuf/releases/download/v27.3/protoc-27.3-linux-aarch_64.zip",
"unzip protoc-27.3-linux-aarch_64.zip -d $HOME/.local",
"rm protoc-27.3-linux-aarch_64.zip",
"mv $HOME/.local/bin/* /usr/bin/",
]
15 changes: 15 additions & 0 deletions Cross.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
[target.i686-unknown-linux-gnu]
pre-build = [
"curl -LO https://github.com/protocolbuffers/protobuf/releases/download/v27.3/protoc-27.3-linux-x86_32.zip",
"unzip protoc-27.3-linux-x86_32.zip -d $HOME/.local",
"rm protoc-27.3-linux-x86_32.zip",
"mv $HOME/.local/bin/* /usr/bin/",
]

[target.aarch64-unknown-linux-gnu]
pre-build = [
"curl -LO https://github.com/protocolbuffers/protobuf/releases/download/v27.3/protoc-27.3-linux-aarch_64.zip",
"unzip protoc-27.3-linux-aarch_64.zip -d $HOME/.local",
"rm protoc-27.3-linux-aarch_64.zip",
"mv $HOME/.local/bin/* /usr/bin/",
]

0 comments on commit 0f830f8

Please sign in to comment.