mirror of
https://github.com/therootcompany/golib.git
synced 2026-03-02 23:57:59 +00:00
feat(monorel): expand default build matrix to all practical CGO_ENABLED=0 targets
Replace linux/windows/darwin with the full CGO_ENABLED=0 goos list: aix, darwin, dragonfly, freebsd, illumos, js, linux, netbsd, openbsd, plan9, solaris, wasip1, windows Add commented-out stanzas for each binary for platforms that require extra tooling: - iOS (CGO_ENABLED=1, Xcode toolchain required) - Android (CGO_ENABLED=0 arm64-only; NDK required for full CGO builds) Archive formats unchanged (tar.gz + tar.zst / zip + tar.gz for Windows).
This commit is contained in:
parent
1289f3e5b6
commit
445a6e9c07
@ -1255,7 +1255,41 @@ func goreleaserYAML(projectName string, bins []binary) string {
|
|||||||
" -X main.commit={{.Commit}}" +
|
" -X main.commit={{.Commit}}" +
|
||||||
" -X main.date={{.Date}}" +
|
" -X main.date={{.Date}}" +
|
||||||
" -X main.builtBy=goreleaser\n")
|
" -X main.builtBy=goreleaser\n")
|
||||||
w(" goos:\n - linux\n - windows\n - darwin\n")
|
w(" goos:\n")
|
||||||
|
w(" - aix\n")
|
||||||
|
w(" - darwin\n")
|
||||||
|
w(" - dragonfly\n")
|
||||||
|
w(" - freebsd\n")
|
||||||
|
w(" - illumos\n")
|
||||||
|
w(" - js\n")
|
||||||
|
w(" - linux\n")
|
||||||
|
w(" - netbsd\n")
|
||||||
|
w(" - openbsd\n")
|
||||||
|
w(" - plan9\n")
|
||||||
|
w(" - solaris\n")
|
||||||
|
w(" - wasip1\n")
|
||||||
|
w(" - windows\n")
|
||||||
|
|
||||||
|
// iOS requires CGO and Xcode toolchain — commented out by default.
|
||||||
|
wf(" # iOS requires CGO_ENABLED=1 and the Xcode toolchain.\n")
|
||||||
|
wf(" #- id: %s-ios\n", bin.name)
|
||||||
|
wf(" # binary: %s\n", bin.name)
|
||||||
|
if bin.mainPath != "." {
|
||||||
|
wf(" # main: %s\n", bin.mainPath)
|
||||||
|
}
|
||||||
|
w(" # env:\n # - CGO_ENABLED=1\n")
|
||||||
|
w(" # goos:\n # - ios\n")
|
||||||
|
|
||||||
|
// Android: CGO_ENABLED=0 supports arm64 only; full CGO requires the NDK.
|
||||||
|
wf(" # Android CGO_ENABLED=0 builds arm64 only; CGO builds require the NDK.\n")
|
||||||
|
wf(" #- id: %s-android\n", bin.name)
|
||||||
|
wf(" # binary: %s\n", bin.name)
|
||||||
|
if bin.mainPath != "." {
|
||||||
|
wf(" # main: %s\n", bin.mainPath)
|
||||||
|
}
|
||||||
|
w(" # env:\n # - CGO_ENABLED=0\n")
|
||||||
|
w(" # goos:\n # - android\n")
|
||||||
|
w(" # goarch:\n # - arm64\n")
|
||||||
}
|
}
|
||||||
|
|
||||||
w("\narchives:\n")
|
w("\narchives:\n")
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user