Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F132477037
D24397.id70500.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
7 KB
Referenced Files
None
Subscribers
None
D24397.id70500.diff
View Options
Index: lang/go-devel/Makefile
===================================================================
--- lang/go-devel/Makefile
+++ lang/go-devel/Makefile
@@ -1,129 +1,28 @@
# Created by: Devon H. O'Dell <devon.odell@gmail.com>
# $FreeBSD$
-PORTNAME= go
PORTVERSION= g20200408
-CATEGORIES= lang
+# Always set PORTREVISION and PORTEPOCH explicitly as otherwise it is inherited from lang/go
+PORTREVISION= 1
+PORTEPOCH= 0
MASTER_SITES= https://github.com/dmgk/go-bootstrap/releases/download/${BOOTSTRAP_TAG}/:bootstrap \
LOCAL/dmgk:bootstrap
PKGNAMESUFFIX= -devel
DISTFILES= go-${OPSYS:tl}-${GOARCH_${ARCH}}${GOARM_${ARCH}}-${BOOTSTRAP_TAG}.tar.xz:bootstrap
-MAINTAINER= dmgk@FreeBSD.org
COMMENT= Go programming language (development version)
-LICENSE= BSD3CLAUSE
-LICENSE_FILE= ${WRKSRC}/LICENSE
-
-.ifdef QEMU_EMULATING
-IGNORE= fails to build with qemu-user-static
-.endif
-
-ONLY_FOR_ARCHS= aarch64 amd64 armv6 armv7 i386
-
-RUN_DEPENDS= ${RUN_DEPENDS_${ARCH}}
-# ld.bfd from devel/binutils is needed for working cgo on aarch64
-RUN_DEPENDS_aarch64= binutils>0:devel/binutils
-
-TEST_DEPENDS= ${TEST_DEPENDS_${ARCH}}
-TEST_DEPENDS_aarch64= binutils>0:devel/binutils
-
-USES= shebangfix
-
USE_GITHUB= yes
GH_ACCOUNT= golang
GH_TAGNAME= 96745b980cfde139e8611772e2bc0c59a8e6cdf7
-SHEBANG_FILES= misc/wasm/go_js_wasm_exec \
- src/net/http/cgi/testdata/test.cgi
-SHEBANG_GLOB= *.bash *.pl *.sh
-sh_OLD_CMD= /bin/bash "/usr/bin/env bash"
-sh_CMD= ${SH}
-
CONFLICTS_INSTALL= go
-# Upstream archive contains files with UTF-8 names
-EXTRACT_CMD= ${SETENV} LC_ALL=en_US.UTF-8 ${TAR}
+MASTERDIR= ${.CURDIR}/../go
+PATCHDIR= ${.CURDIR}/files
+DISTINFO_FILE= ${.CURDIR}/distinfo
-OPTIONS_DEFINE_i386= GO387
+post-extract:
+ @[ -f ${WRKSRC}/VERSION ] || ${ECHO_CMD} "devel +${GH_TAGNAME}" > ${WRKSRC}/VERSION
-GO387_DESC= Do not generate code with SSE2 (for old x86 CPU)
-
-GO387_VARS= GO386=387
-
-BINARIES= go gofmt
-BOOTSTRAP_TAG= go1.14
-
-GOARCH_aarch64= arm64
-GOARCH_amd64= amd64
-GOARCH_armv6= arm
-GOARCH_armv7= arm
-GOARCH_i386= 386
-
-GOARM_armv6= 6
-GOARM_armv7= 7
-
-.include <bsd.port.pre.mk>
-
-.if ${ARCH} == aarch64 && ${OSVERSION} < 1200000
-IGNORE= aarch64 support requires FreeBSD 12.0 or newer
-.endif
-
-post-patch:
- @${REINPLACE_CMD} -e 's|^if ulimit -T|false \&\& &|' ${WRKSRC}/src/run.bash
- # Needed only for untagged releases
- # ${ECHO_CMD} "devel +${GH_TAGNAME}" > ${WRKSRC}/VERSION
-
-pre-build:
- # Check that the running kernel has COMPAT_FREEBSD11 required by lang/go{,-devel} post-ino64
- @${SETENV} CC="${CC}" OPSYS="${OPSYS}" OSVERSION="${OSVERSION}" WRKDIR="${WRKDIR}" \
- ${SH} ${SCRIPTSDIR}/rust-compat11-canary.sh
-
-do-build:
- cd ${WRKSRC}/src ; ${SETENV} \
- XDG_CACHE_HOME=${WRKDIR} \
- GOROOT_BOOTSTRAP=${WRKDIR}/go-${OPSYS:tl}-${GOARCH_${ARCH}}${GOARM_${ARCH}}-bootstrap \
- GOROOT=${WRKSRC} \
- GOROOT_FINAL=${PREFIX}/go \
- GOBIN= \
- GOOS=${OPSYS:tl} \
- GOARCH=${GOARCH_${ARCH}} \
- GO386=${GO386} \
- GOARM=${GOARM_${ARCH}} \
- ${SH} make.bash -v
-
-do-install:
- @cd ${WRKSRC} ; \
- ${RM} -r .gitattributes .gitignore .github favicon.ico robots.txt \
- pkg/obj pkg/bootstrap pkg/${OPSYS:tl}_${GOARCH_${ARCH}}/cmd
- @${MKDIR} ${STAGEDIR}${PREFIX}/go
- @${CP} -a ${WRKSRC}/* ${STAGEDIR}${PREFIX}/go
-.for file in ${BINARIES}
- @${LN} -sf ../go/bin/${file} ${STAGEDIR}${PREFIX}/bin/${file}
- @${ECHO_CMD} bin/${file} >> ${TMPPLIST}
-.endfor
- @cd ${STAGEDIR}${PREFIX} && ${FIND} go -type f >> ${TMPPLIST}
-
-do-test:
- cd ${WRKSRC}/src && ${SETENV} \
- GOROOT=${WRKSRC} \
- PATH=${WRKSRC}/bin:${PATH} \
- GOOS=${OPSYS:tl} \
- GOARCH=${GOARCH_${ARCH}} \
- GO386=${GO386} \
- GOARM=${GOARM_${ARCH}} \
- ${SH} run.bash -no-rebuild
-
-.if !defined(_GO_MAKESUM_GUARD)
-makesum:
- ${MAKE} -D_GO_MAKESUM_GUARD makesum ARCH=${ONLY_FOR_ARCHS:O:[1]} DISTINFO_FILE=${DISTINFO_FILE}.tmp
-.for arch in ${ONLY_FOR_ARCHS:O:[2..-1]}
- ${MAKE} -D_GO_MAKESUM_GUARD makesum ARCH=${arch} DISTINFO_FILE=${DISTINFO_FILE}.${arch}
- ${SED} 1d ${DISTINFO_FILE}.${arch} >> ${DISTINFO_FILE}.tmp
- ${RM} ${DISTINFO_FILE}.${arch}
-.endfor
- ${AWK} '!seen[$$0]++' ${DISTINFO_FILE}.tmp > ${DISTINFO_FILE}
- ${RM} ${DISTINFO_FILE}.tmp
-.endif
-
-.include <bsd.port.post.mk>
+.include "${MASTERDIR}/Makefile"
Index: lang/go-devel/distinfo
===================================================================
--- lang/go-devel/distinfo
+++ lang/go-devel/distinfo
@@ -1,4 +1,4 @@
-TIMESTAMP = 1586434201
+TIMESTAMP = 1586789386
SHA256 (go-freebsd-arm64-go1.14.tar.xz) = f8b0cf0d323e581c9e3e0d5c217847a3e0294fcc92dbac92a5b02cea9d97ad8d
SIZE (go-freebsd-arm64-go1.14.tar.xz) = 34944548
SHA256 (golang-go-g20200408-96745b980cfde139e8611772e2bc0c59a8e6cdf7_GH0.tar.gz) = 735e3628aaf06fb2d7fdbbf662650d3633febb4c8bfeff4992a2f4603bd44017
Index: lang/go-devel/files/patch-src_cmd_go_internal_modload_init.go
===================================================================
--- /dev/null
+++ lang/go-devel/files/patch-src_cmd_go_internal_modload_init.go
@@ -0,0 +1,12 @@
+Upstream PR: https://github.com/golang/go/issues/37948
+--- src/cmd/go/internal/modload/init.go.orig 2020-02-25 18:32:50 UTC
++++ src/cmd/go/internal/modload/init.go
+@@ -562,7 +562,7 @@ func checkVendorConsistency() {
+ readVendorList()
+
+ pre114 := false
+- if modFile.Go == nil || semver.Compare("v"+modFile.Go.Version, "v1.14") < 0 {
++ if modFile.Go == nil || semver.Compare("v"+modFile.Go.Version, "v1.14") < 0 || (os.Getenv("GO_NO_VENDOR_CHECKS") == "1" && len(vendorMeta) == 0) {
+ // 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.
Index: lang/go-devel/pkg-descr
===================================================================
--- lang/go-devel/pkg-descr
+++ /dev/null
@@ -1,6 +0,0 @@
-Go is an open source programming environment that makes it easy to build
-simple, reliable, and efficient software.
-
-This ports tracks Go development (master) branch.
-
-WWW: https://golang.org
Index: lang/go/Makefile
===================================================================
--- lang/go/Makefile
+++ lang/go/Makefile
@@ -2,13 +2,14 @@
# $FreeBSD$
PORTNAME= go
-PORTVERSION= 1.14.2
-PORTEPOCH= 1
+PORTVERSION?= 1.14.2
+PORTREVISION?= 0
+PORTEPOCH?= 1
CATEGORIES= lang
-MASTER_SITES= https://golang.org/dl/ \
+MASTER_SITES?= https://golang.org/dl/ \
https://github.com/dmgk/go-bootstrap/releases/download/${BOOTSTRAP_TAG}/:bootstrap \
LOCAL/dmgk:bootstrap
-DISTFILES= go${PORTVERSION}.src.tar.gz \
+DISTFILES?= go${PORTVERSION}.src.tar.gz \
go-${OPSYS:tl}-${GOARCH_${ARCH}}${GOARM_${ARCH}}-${BOOTSTRAP_TAG}.tar.xz:bootstrap
MAINTAINER= dmgk@FreeBSD.org
@@ -35,15 +36,15 @@
SHEBANG_FILES= misc/wasm/go_js_wasm_exec \
src/net/http/cgi/testdata/test.cgi
SHEBANG_GLOB= *.bash *.pl *.sh
-sh_OLD_CMD= /bin/bash "/usr/bin/env bash"
-sh_CMD= ${SH}
-CONFLICTS_INSTALL= go-devel
+CONFLICTS_INSTALL?= go-devel
# Upstream archive contains files with UTF-8 names
EXTRACT_CMD= ${SETENV} LC_ALL=en_US.UTF-8 ${TAR}
+.ifndef MASTERDIR
WRKSRC= ${WRKDIR}/go
+.endif
OPTIONS_DEFINE_i386= GO387
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Oct 18, 6:17 AM (53 m, 33 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
23867337
Default Alt Text
D24397.id70500.diff (7 KB)
Attached To
Mode
D24397: lang/go-devel: Convert to slave of lang/go, apply D24122
Attached
Detach File
Event Timeline
Log In to Comment