FreeBSD Bugzilla – Attachment 248506 Details for
Bug 277091
lang/go*: Introduce port Go 1.22
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Update diff
go.diff (text/plain), 9.38 KB, created by
Ashish SHUKLA
on 2024-02-16 11:14:13 UTC
(
hide
)
Description:
Update diff
Filename:
MIME Type:
Creator:
Ashish SHUKLA
Created:
2024-02-16 11:14:13 UTC
Size:
9.38 KB
patch
obsolete
>From b3d9fe6e181252b93c38920a350f5701a59c8bd2 Mon Sep 17 00:00:00 2001 >From: Ashish SHUKLA <ashish@FreeBSD.org> >Date: Fri, 16 Feb 2024 10:28:07 +0000 >Subject: [PATCH 1/2] 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 >--- > lang/go-devel/Makefile | 13 ++++++------ > lang/go-devel/distinfo | 6 +++--- > ...atch-src_cmd_go_internal_modload_vendor.go | 20 +++++++++---------- > lang/go120/Makefile | 5 +++++ > lang/go121/Makefile | 5 +++++ > 5 files changed, 30 insertions(+), 19 deletions(-) > >diff --git a/lang/go-devel/Makefile b/lang/go-devel/Makefile >index 3d8664fe..0882e9f8 100644 >--- a/lang/go-devel/Makefile >+++ b/lang/go-devel/Makefile >@@ -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} ; \ >diff --git a/lang/go-devel/distinfo b/lang/go-devel/distinfo >index 14509dc3..5258ab22 100644 >--- a/lang/go-devel/distinfo >+++ b/lang/go-devel/distinfo >@@ -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 >diff --git a/lang/go-devel/files/patch-src_cmd_go_internal_modload_vendor.go b/lang/go-devel/files/patch-src_cmd_go_internal_modload_vendor.go >index 9d228852..ba3f9722 100644 >--- a/lang/go-devel/files/patch-src_cmd_go_internal_modload_vendor.go >+++ b/lang/go-devel/files/patch-src_cmd_go_internal_modload_vendor.go >@@ -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. >diff --git a/lang/go120/Makefile b/lang/go120/Makefile >index afcc7f35..8ef862e7 100644 >--- a/lang/go120/Makefile >+++ b/lang/go120/Makefile >@@ -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" >diff --git a/lang/go121/Makefile b/lang/go121/Makefile >index 9ca84939..71bdd142 100644 >--- a/lang/go121/Makefile >+++ b/lang/go121/Makefile >@@ -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" >-- >2.43.0 > > >From 352e82fd8a8de4297fcd20bcb63850cd48bb5a16 Mon Sep 17 00:00:00 2001 >From: Ashish SHUKLA <ashish@FreeBSD.org> >Date: Sun, 11 Feb 2024 10:42:41 +0000 >Subject: [PATCH 2/2] New Port: lang/go122 > >--- > lang/go122/Makefile | 19 +++++++++++++++++++ > lang/go122/distinfo | 15 +++++++++++++++ > ...atch-src_cmd_go_internal_modload_vendor.go | 11 +++++++++++ > 3 files changed, 45 insertions(+) > create mode 100644 lang/go122/Makefile > create mode 100644 lang/go122/distinfo > create mode 100644 lang/go122/files/patch-src_cmd_go_internal_modload_vendor.go > >diff --git a/lang/go122/Makefile b/lang/go122/Makefile >new file mode 100644 >index 00000000..9178ebee >--- /dev/null >+++ b/lang/go122/Makefile >@@ -0,0 +1,19 @@ >+DISTVERSION= 1.22.0 >+# Always set PORTREVISION explicitly as otherwise they are inherited from lang/go-devel >+PORTREVISION= 0 >+MASTER_SITES= https://golang.org/dl/ \ >+ https://github.com/dmgk/go-bootstrap/releases/download/${BOOTSTRAP_TAG}/:bootstrap \ >+ LOCAL/dmgk:bootstrap >+DISTFILES= go${DISTVERSION}.src.tar.gz \ >+ go-${OPSYS:tl}-${GOARCH_${ARCH}}${GOARM_${ARCH}}-${BOOTSTRAP_TAG}.tar.xz:bootstrap >+ >+# Avoid conflicting patch files >+PATCHFILES= >+ >+COMMENT= Go programming language >+ >+MASTERDIR= ${.CURDIR}/../go-devel >+WRKSRC= ${WRKDIR}/go >+DISTINFO_FILE= ${.CURDIR}/distinfo >+ >+.include "${MASTERDIR}/Makefile" >diff --git a/lang/go122/distinfo b/lang/go122/distinfo >new file mode 100644 >index 00000000..32b76772 >--- /dev/null >+++ b/lang/go122/distinfo >@@ -0,0 +1,15 @@ >+TIMESTAMP = 1707648070 >+SHA256 (go1.22.0.src.tar.gz) = 4d196c3d41a0d6c1dfc64d04e3cc1f608b0c436bd87b7060ce3e23234e1f4d5c >+SIZE (go1.22.0.src.tar.gz) = 27544122 >+SHA256 (go-freebsd-arm64-go1.20.tar.xz) = 674e0a9bce8b64dcc085b000eb83ae880e96be1ee47dad6ec86c82dbe5550623 >+SIZE (go-freebsd-arm64-go1.20.tar.xz) = 32640640 >+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 >+SIZE (go-freebsd-arm6-go1.20.tar.xz) = 33418476 >+SHA256 (go-freebsd-arm7-go1.20.tar.xz) = 12dd61c802eada70380f0b4755656d82dbf228575c056775c682456380be5039 >+SIZE (go-freebsd-arm7-go1.20.tar.xz) = 33346596 >+SHA256 (go-freebsd-386-go1.20.tar.xz) = 34e888a37153270b33503a23885ea4c85ba4bd09849d2c937fc9d312c0f49983 >+SIZE (go-freebsd-386-go1.20.tar.xz) = 35448892 >+SHA256 (go-freebsd-riscv64-go1.20.tar.xz) = 010921013d24124ff31f4b1965456349547acf936572fc6e0bcf95a0542794bd >+SIZE (go-freebsd-riscv64-go1.20.tar.xz) = 33807544 >diff --git a/lang/go122/files/patch-src_cmd_go_internal_modload_vendor.go b/lang/go122/files/patch-src_cmd_go_internal_modload_vendor.go >new file mode 100644 >index 00000000..ba3f9722 >--- /dev/null >+++ b/lang/go122/files/patch-src_cmd_go_internal_modload_vendor.go >@@ -0,0 +1,11 @@ >+--- src/cmd/go/internal/modload/vendor.go.orig 2024-02-02 18:09:55 UTC >++++ src/cmd/go/internal/modload/vendor.go >+@@ -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. >-- >2.43.0 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 277091
: 248506 |
248513