about go build -ldflags -H=windowsgui
#1936
-
It's me again, I got some errors and don't know why, hope to get help .os : mac m1 code like this: package main
import (
"github.com/hajimehoshi/ebiten/v2"
)
type Game struct {
}
func (g Game) Update() error {
return nil
}
func (g Game) Draw(screen *ebiten.Image) {
return
}
func (g Game) Layout(outsideWidth, outsideHeight int) (screenWidth, screenHeight int) {
return
}
func NewGame() ebiten.Game {
return &Game{}
}
func main() {
g := NewGame()
err := ebiten.RunGame(g)
if err != nil {
panic(err)
}
} output go build -ldflags -H=windowsgui test.go
# command-line-arguments
libc_open: initialize bounds (0 < 8)
libc_close: initialize bounds (0 < 8)
libc_write: initialize bounds (0 < 8)
libc_error: initialize bounds (0 < 8)
libc_read: initialize bounds (0 < 8)
libc_pipe: initialize bounds (0 < 8)
libc_exit: initialize bounds (0 < 8)
libc_getpid: initialize bounds (0 < 8)
libc_kill: initialize bounds (0 < 8)
libc_mmap: initialize bounds (0 < 8)
libc_munmap: initialize bounds (0 < 8)
libc_madvise: initialize bounds (0 < 8)
libc_mlock: initialize bounds (0 < 8)
libc_clock_gettime: initialize bounds (0 < 8)
libc_mach_absolute_time: initialize bounds (0 < 8)
libc_mach_timebase_info: initialize bounds (0 < 8)
libc_pthread_sigmask: initialize bounds (0 < 8)
libc_sigaction: initialize bounds (0 < 8)
libc_usleep: initialize bounds (0 < 8)
libc_sysctl: initialize bounds (0 < 8)
libc_sysctlbyname: initialize bounds (0 < 8)
/opt/homebrew/Cellar/go/1.17.2/libexec/pkg/tool/darwin_arm64/link: too many errors |
Beta Was this translation helpful? Give feedback.
Answered by
hajimehoshi
Jan 7, 2022
Replies: 1 comment
-
This option is for Windows, not for macOS. |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
aprchen
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This option is for Windows, not for macOS.