lang/go*: Update to Go 1.22 snapshot

- Add overridable BUILD_DEPENDS on shells/bash, but only for Go 1.22+
- Since lang/go121 also depends on it, allow SHEBANG_FILES to be
  overridden
- Re-roll the patch
- Update lang/go120 to co-exist with lang/go-devel update
- Update lang/go121 to co-exist with lang/go-devel update

PR:		277091
2024Q2
Ashish SHUKLA 2024-02-16 10:28:07 +00:00
parent cfbb908ce2
commit ccd8e6b897
No known key found for this signature in database
5 changed files with 30 additions and 19 deletions

View File

@ -1,5 +1,5 @@
PORTNAME= go
DISTVERSION?= g20230808
DISTVERSION?= g20240208
PORTREVISION?= 0
CATEGORIES= lang
MASTER_SITES?= https://github.com/dmgk/go-bootstrap/releases/download/${BOOTSTRAP_TAG}/:bootstrap \
@ -20,6 +20,7 @@ IGNORE= fails to build with qemu-user-static
ONLY_FOR_ARCHS= aarch64 amd64 armv6 armv7 i386 riscv64
BUILD_DEPENDS?= bash:shells/bash
RUN_DEPENDS= ${RUN_DEPENDS_${ARCH}}
# ld.bfd from devel/binutils is needed for working cgo on aarch64
RUN_DEPENDS_aarch64= binutils>0:devel/binutils
@ -35,16 +36,16 @@ CPE_VENDOR= golang
.ifndef MASTERDIR
USE_GITHUB= yes
GH_ACCOUNT= golang
# go1.21.0
GH_TAGNAME= c19c4c566c63818dfd059b352e52c4710eecf14d
# go1.22
GH_TAGNAME= 20107e05a609b8f2e61a6b5e8dc258237ad046e7
.endif
SHEBANG_FILES= misc/wasm/go_js_wasm_exec \
src/net/http/cgi/testdata/test.cgi
SHEBANG_FILES?= misc/wasm/go_js_wasm_exec misc/wasm/go_wasip1_wasm_exec
SHEBANG_GLOB= *.bash *.pl *.sh
# Upstream archive contains files with UTF-8 names
EXTRACT_CMD= ${SETENV} LC_ALL=en_US.UTF-8 ${TAR}
BASH?= ${LOCALBASE}/bin/bash
OPTIONS_DEFINE_i386= SOFTFLOAT
OPTIONS_DEFAULT_amd64= V1
@ -105,7 +106,7 @@ do-build:
GOARM=${GOARM_${ARCH}} \
GOAMD64=${GOAMD64} \
CC=${CC} \
${SH} make.bash -v
${BASH} make.bash -v
do-install:
@cd ${WRKSRC} ; \

View File

@ -1,8 +1,8 @@
TIMESTAMP = 1691753450
TIMESTAMP = 1707649478
SHA256 (go-freebsd-arm64-go1.20.tar.xz) = 674e0a9bce8b64dcc085b000eb83ae880e96be1ee47dad6ec86c82dbe5550623
SIZE (go-freebsd-arm64-go1.20.tar.xz) = 32640640
SHA256 (golang-go-g20230808-c19c4c566c63818dfd059b352e52c4710eecf14d_GH0.tar.gz) = 1f9ab60c3dba69e1f29ce2e20f0ccfa03e0c7d5106a66b874f881ddc432dde98
SIZE (golang-go-g20230808-c19c4c566c63818dfd059b352e52c4710eecf14d_GH0.tar.gz) = 27148273
SHA256 (golang-go-g20240208-20107e05a609b8f2e61a6b5e8dc258237ad046e7_GH0.tar.gz) = 61f4ed9886864b7b509bc981952f8fb7dbf68c31997af3f0dc1d1c12df53a1d4
SIZE (golang-go-g20240208-20107e05a609b8f2e61a6b5e8dc258237ad046e7_GH0.tar.gz) = 27738771
SHA256 (go-freebsd-amd64-go1.20.tar.xz) = 170f612c4b8a59400f27d642aab37afa831fe2d6df3e7473dec2d4574a59a46c
SIZE (go-freebsd-amd64-go1.20.tar.xz) = 34684360
SHA256 (go-freebsd-arm6-go1.20.tar.xz) = acf99dbb285c6d2b80e0abfe4bffd0d230516ea84d17be0d5bc1045809e3d33a

View File

@ -1,11 +1,11 @@
--- src/cmd/go/internal/modload/vendor.go.orig 2023-08-02 13:51:49 UTC
--- src/cmd/go/internal/modload/vendor.go.orig 2024-02-02 18:09:55 UTC
+++ src/cmd/go/internal/modload/vendor.go
@@ -144,7 +144,7 @@ func checkVendorConsistency(index *modFileIndex, modFi
readVendorList(MainModules.mustGetSingleMainModule())
pre114 := false
- if gover.Compare(index.goVersion, "1.14") < 0 {
+ if gover.Compare(index.goVersion, "1.14") < 0 || os.Getenv("GO_NO_VENDOR_CHECKS") == "1" {
// Go versions before 1.14 did not include enough information in
// vendor/modules.txt to check for consistency.
// If we know that we're on an earlier version, relax the consistency check.
@@ -159,7 +159,7 @@ func checkVendorConsistency(indexes []*modFileIndex, m
panic(fmt.Errorf("not in workspace mode but number of indexes is %v, not 1", len(indexes)))
}
index := indexes[0]
- if gover.Compare(index.goVersion, "1.14") < 0 {
+ if gover.Compare(index.goVersion, "1.14") < 0 || os.Getenv("GO_NO_VENDOR_CHECKS") == "1" {
// Go versions before 1.14 did not include enough information in
// vendor/modules.txt to check for consistency.
// If we know that we're on an earlier version, relax the consistency check.

View File

@ -12,9 +12,14 @@ PATCHFILES=
COMMENT= Go programming language
BUILD_DEPENDS=
MASTERDIR= ${.CURDIR}/../go-devel
PATCHDIR= ${.CURDIR}/files
WRKSRC= ${WRKDIR}/go
DISTINFO_FILE= ${.CURDIR}/distinfo
SHEBANG_FILES= misc/wasm/go_js_wasm_exec \
src/net/http/cgi/testdata/test.cgi
BASH= ${SH}
.include "${MASTERDIR}/Makefile"

View File

@ -12,9 +12,14 @@ PATCHFILES=
COMMENT= Go programming language
BUILD_DEPENDS=
MASTERDIR= ${.CURDIR}/../go-devel
PATCHDIR= ${.CURDIR}/files
WRKSRC= ${WRKDIR}/go
DISTINFO_FILE= ${.CURDIR}/distinfo
SHEBANG_FILES= misc/wasm/go_js_wasm_exec \
src/net/http/cgi/testdata/test.cgi
BASH= ${SH}
.include "${MASTERDIR}/Makefile"