Skip to content

Commit 77262b6

Browse files
committed
os/exec: exclude aarch64
aarch64 has no support for the fork ssycall. for now exclude it. Signed-off-by: leongross <[email protected]>
1 parent fe90e5c commit 77262b6

File tree

2 files changed

+22
-1
lines changed

2 files changed

+22
-1
lines changed

src/os/osexec.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
//go:build linux && !baremetal && !darwin && !tinygo.wasm
1+
//go:build linux && !baremetal && !darwin && !tinygo.wasm && !arm64
2+
3+
// arm64 does not have a fork syscall, so ignore it for now
4+
// TODO: add support for arm64 with clone or use musl implementation
25

36
package os
47

src/os/osexec_aarch64.go

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
//go:build linux && !baremetal && !darwin && !tinygo.wasm && aarch64
2+
3+
// arm64 does not have a fork syscall, so ignore it for now
4+
// TODO: add support for arm64 with clone or use musl implementation
5+
6+
package os
7+
8+
import (
9+
"errors"
10+
)
11+
12+
func fork() (pid int, err error) {
13+
return 0, errors.New("fork not supported on aarch64")
14+
}
15+
16+
func execve(pathname string, argv []string, envv []string) (err error) {
17+
return 0, errors.New("execve not supported on aarch64")
18+
}

0 commit comments

Comments
 (0)