Skip to content

Commit

Permalink
Update build script with latest support GOOS+GOARCH combinations
Browse files Browse the repository at this point in the history
GOOS+GOARCH combinations are from:

    go tool dist list

With the manual removal of linux-riscv64, as that doesn't compile
Dio properly yet:

    # golang.org/x/sys/unix
    ../vendor/golang.org/x/sys/unix/syscall_linux_gc.go:10:6: missing function body
    ../vendor/golang.org/x/sys/unix/syscall_linux_gc.go:14:6: missing function body
    ../vendor/golang.org/x/sys/unix/syscall_unix_gc.go:12:6: missing function body
    ../vendor/golang.org/x/sys/unix/syscall_unix_gc.go:13:6: missing function body
    ../vendor/golang.org/x/sys/unix/syscall_unix_gc.go:14:6: missing function body
    ../vendor/golang.org/x/sys/unix/syscall_unix_gc.go:15:6: missing function body
  • Loading branch information
justinclift committed Jun 1, 2020
1 parent 17f9564 commit 9b6db88
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 17 deletions.
1 change: 1 addition & 0 deletions misc/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
dio*
49 changes: 32 additions & 17 deletions misc/build_binaries.sh
Original file line number Diff line number Diff line change
@@ -1,35 +1,50 @@
#!/bin/sh

# This is just a small sh script to generate the Dio release binaries
export GOOS=darwin
export GOARCH=unknown
for GOARCH in 386 amd64; do
echo Building Dio for ${GOOS} + ${GOARCH}

export GOARCH=386
for GOOS in android darwin freebsd netbsd openbsd plan9 windows linux; do
echo Building Dio for ${GOOS}-${GOARCH}
go build -o dio-${GOOS}-x86 ..
sha256sum dio-${GOOS}-x86 > dio-${GOOS}-x86.SHA256
done

export GOARCH=amd64
for GOOS in android darwin freebsd netbsd openbsd plan9 solaris windows linux; do
echo Building Dio for ${GOOS}-${GOARCH}
go build -o dio-${GOOS}-${GOARCH} ..
sha256sum dio-${GOOS}-${GOARCH} > dio-${GOOS}-${GOARCH}.SHA256
sha256sum dio-${GOOS}-${GOARCH} > dio-${GOOS}-x86.SHA256
done

GOOS=freebsd
for GOARCH in 386 amd64; do
echo Building Dio for ${GOOS} + ${GOARCH}
export GOARCH=arm
for GOOS in android darwin freebsd netbsd openbsd plan9 windows linux; do
echo Building Dio for ${GOOS}-${GOARCH}
go build -o dio-${GOOS}-${GOARCH} ..
sha256sum dio-${GOOS}-${GOARCH} > dio-${GOOS}-${GOARCH}.SHA256
sha256sum dio-${GOOS}-${GOARCH} > dio-${GOOS}-x86.SHA256
done

GOOS=windows
for GOARCH in 386 amd64; do
echo Building Dio for ${GOOS} + ${GOARCH}
go build -o dio-${GOOS}-${GOARCH}.exe ..
sha256sum dio-${GOOS}-${GOARCH}.exe > dio-${GOOS}-${GOARCH}.exe.SHA256
export GOARCH=arm64
for GOOS in android darwin freebsd illumos netbsd openbsd linux; do
echo Building Dio for ${GOOS}-${GOARCH}
go build -o dio-${GOOS}-${GOARCH} ..
sha256sum dio-${GOOS}-${GOARCH} > dio-${GOOS}-x86.SHA256
done

GOOS=linux
for GOARCH in 386 amd64 arm64 ppc64 ppc64le s390x; do
echo Building Dio for ${GOOS} + ${GOARCH}
for GOARCH in mips mips64 mips64le mipsle ppc64 ppc64le s390x; do
echo Building Dio for ${GOOS}-${GOARCH}
go build -o dio-${GOOS}-${GOARCH} ..
sha256sum dio-${GOOS}-${GOARCH} > dio-${GOOS}-${GOARCH}.SHA256
done

echo Building Dio for ${GOOS} + ARMv6
echo Building Dio for ${GOOS}-ARMv6
GOARCH=arm GOARM=6 go build -o dio-${GOOS}-armv6 ..
sha256sum dio-${GOOS}-armv6 > dio-${GOOS}-armv6.SHA256

echo Building Dio for aix-ppc64
go build -o dio-aix-ppc64 ..
sha256sum dio-aix-ppc64 > dio-aix-ppc64.SHA256

echo Building Dio for js-wasm
go build -o dio-js-wasm ..
sha256sum dio-js-wasm > dio-js-wasm.SHA256

0 comments on commit 9b6db88

Please sign in to comment.