Skip to content

Commit

Permalink
update go to the current master
Browse files Browse the repository at this point in the history
  • Loading branch information
dmgk committed Oct 29, 2019
1 parent fc5d860 commit 343ceda
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 5,584 deletions.
2 changes: 1 addition & 1 deletion .gitmodules
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[submodule "go"]
path = go
url = https://github.com/golang/go.git
branch = release-branch.go1.13
branch = master
42 changes: 18 additions & 24 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,41 +1,35 @@
# Build Go bootstrap toolchains from the modern source.
# bash is expected to be on PATH
# bash is expected to be on the PATH

GOROOT= /usr/local/go

GOOS= freebsd
GOARCH= amd64 386 arm arm64
GOARM= 6 7

all:
cd ${.CURDIR}/go ; \
git reset --hard ; \
git clean -fd ; \
git apply ${.CURDIR}/arm64/arm64.patch
.for goarch in ${GOARCH}
. if ${goarch} == arm
. for goarm in ${GOARM}
cd ${.CURDIR}/go/src ; \
env GOROOT=${GOROOT} PATH=${GOROOT}/bin:$$PATH \
GOOS=${GOOS} GOARCH=${goarch} GOARM=${goarm} CGO_ENABLED=0 \
../../bootstrap.sh
. endfor
. else
ARCHS= 386 amd64 arm6 arm7 arm64

all: ${ARCHS}

.for arch in ${ARCHS}
${arch}: clean-${arch}
cd ${.CURDIR}/go/src ; \
env GOROOT=${GOROOT} PATH=${GOROOT}/bin:$$PATH \
GOOS=${GOOS} GOARCH=${goarch} GO386=387 CGO_ENABLED=0 \
GOOS=${GOOS} \
GOARCH=${arch:C/^arm.$/arm/} \
GOARM=${arch:Marm?:S/arm//} \
GO386=${arch:M386:S/386/387/} \
CGO_ENABLED=0 \
../../bootstrap.sh
. endif

clean-${arch}:
rm -rf ${.CURDIR}/go-freebsd-${arch}-bootstrap

.PHONY: ${arch} clean-${arch}
.endfor

clean:
cd ${.CURDIR}/go ; \
git reset --hard ; \
git clean -fd
rm -rf go-*-bootstrap go-*.tar.xz

upload:
# todo
# TODO: make Github release and upload assets
cp -pv go-*.tar.xz ~/ports/distfiles

.PHONY: all clean upload
4 changes: 0 additions & 4 deletions arm64/README.md

This file was deleted.

Loading

0 comments on commit 343ceda

Please # to comment.