aboutsummaryrefslogtreecommitdiff
path: root/src/internal/syscall
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@golang.org>2023-07-31 11:13:35 -0700
committerGopher Robot <gobot@golang.org>2023-08-08 04:43:24 +0000
commit87fe5faffca1bce0db513a3c1bb640ccf6a04bc7 (patch)
treecd0440a89627da74daa767d12bb888746c66622d /src/internal/syscall
parent3393155abf77e460fe661ffccb0b21c500290613 (diff)
downloadgo-87fe5faffca1bce0db513a3c1bb640ccf6a04bc7.tar.xz
internal/syscall/unix: don't define libc_getentropy_trampoline on ios
It is only used on Darwin. This fixes "go vet" on ios. Fixes #61667 Change-Id: Iaf00fcee5d89eb8e454f75bb1c0ea62c3950b684 Reviewed-on: https://go-review.googlesource.com/c/go/+/514495 Reviewed-by: Bryan Mills <bcmills@google.com> Reviewed-by: Ian Lance Taylor <iant@google.com> Auto-Submit: Ian Lance Taylor <iant@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Run-TryBot: Ian Lance Taylor <iant@google.com> Run-TryBot: Ian Lance Taylor <iant@golang.org>
Diffstat (limited to 'src/internal/syscall')
-rw-r--r--src/internal/syscall/unix/asm_darwin.s1
-rw-r--r--src/internal/syscall/unix/getentropy_darwin.s9
2 files changed, 9 insertions, 1 deletions
diff --git a/src/internal/syscall/unix/asm_darwin.s b/src/internal/syscall/unix/asm_darwin.s
index 8662c2846f..10d16ce87f 100644
--- a/src/internal/syscall/unix/asm_darwin.s
+++ b/src/internal/syscall/unix/asm_darwin.s
@@ -4,7 +4,6 @@
#include "textflag.h"
-TEXT ·libc_getentropy_trampoline(SB),NOSPLIT,$0-0; JMP libc_getentropy(SB)
TEXT ·libc_getaddrinfo_trampoline(SB),NOSPLIT,$0-0; JMP libc_getaddrinfo(SB)
TEXT ·libc_freeaddrinfo_trampoline(SB),NOSPLIT,$0-0; JMP libc_freeaddrinfo(SB)
TEXT ·libc_getnameinfo_trampoline(SB),NOSPLIT,$0-0; JMP libc_getnameinfo(SB)
diff --git a/src/internal/syscall/unix/getentropy_darwin.s b/src/internal/syscall/unix/getentropy_darwin.s
new file mode 100644
index 0000000000..f41e0fe97b
--- /dev/null
+++ b/src/internal/syscall/unix/getentropy_darwin.s
@@ -0,0 +1,9 @@
+// Copyright 2021 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+//go:build darwin && !ios
+
+#include "textflag.h"
+
+TEXT ·libc_getentropy_trampoline(SB),NOSPLIT,$0-0; JMP libc_getentropy(SB)