Skip to content

Commit 3bf853d

Browse files
authored
feat(cli.rs): support tauri build on M1 chip (#1915)
1 parent e85472b commit 3bf853d

File tree

3 files changed

+9
-0
lines changed

3 files changed

+9
-0
lines changed

.changes/build-on-m1.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"cli.rs": patch
3+
---
4+
5+
Support `cargo tauri build` on Apple M1 chip.

core/tauri-utils/src/platform.rs

+2
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ pub fn target_triple() -> crate::Result<String> {
2525
"x86_64"
2626
} else if cfg!(target_arch = "arm") {
2727
"armv7"
28+
} else if cfg!(target_arch = "aarch64") {
29+
"aarch64"
2830
} else {
2931
return Err(crate::Error::Architecture);
3032
};

tooling/bundler/src/bundle/platform.rs

+2
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ pub fn target_triple() -> Result<String, crate::Error> {
1818
"x86_64"
1919
} else if cfg!(target_arch = "arm") {
2020
"armv7"
21+
} else if cfg!(target_arch = "aarch64") {
22+
"aarch64"
2123
} else {
2224
return Err(crate::Error::ArchError(String::from(
2325
"Unable to determine target-architecture",

0 commit comments

Comments
 (0)