Skip to content

Commit 065dd23

Browse files
committed
Update/fix build tags, Dockerfile, and release.sh for proper building and releasing of linux/386 and linux/arm cross-compiled client binaries
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
1 parent 45dd051 commit 065dd23

31 files changed

+51
-23
lines changed

Dockerfile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,9 @@ ENV GOPATH /go:/go/src/github.com/dotcloud/docker/vendor
6868
RUN cd /usr/local/go/src && ./make.bash --no-clean 2>&1
6969

7070
# Compile Go for cross compilation
71-
ENV DOCKER_CROSSPLATFORMS darwin/amd64 darwin/386
72-
# TODO add linux/386 and linux/arm
71+
ENV DOCKER_CROSSPLATFORMS linux/386 linux/arm darwin/amd64 darwin/386
72+
# (set an explicit GOARM of 5 for maximum compatibility)
73+
ENV GOARM 5
7374
RUN cd /usr/local/go/src && bash -xc 'for platform in $DOCKER_CROSSPLATFORMS; do GOOS=${platform%/*} GOARCH=${platform##*/} ./make.bash --no-clean 2>&1; done'
7475

7576
# Grab Go's cover tool for dead-simple code coverage testing
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
// +build: !linux !amd64
1+
// +build !linux !amd64
2+
23
package archive
34

45
import "syscall"

execdriver/lxc/lxc_init_linux.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
// +build amd64
2+
13
package lxc
24

35
import (

execdriver/lxc/lxc_init_unsupported.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
// +build: !linux !amd64
1+
// +build !linux !amd64
2+
23
package lxc
34

45
func setHostname(hostname string) error {

graphdriver/aufs/mount_linux.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
// +build amd64
2+
13
package aufs
24

35
import "syscall"

graphdriver/aufs/mount_unsupported.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
// +build: !linux !amd64
1+
// +build !linux !amd64
2+
23
package aufs
34

45
import "errors"

graphdriver/btrfs/btrfs.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// +build linux
1+
// +build linux,amd64
22

33
package btrfs
44

graphdriver/devmapper/attach_loopback.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// +build linux
1+
// +build linux,amd64
22

33
package devmapper
44

graphdriver/devmapper/deviceset.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// +build linux
1+
// +build linux,amd64
22

33
package devmapper
44

graphdriver/devmapper/devmapper.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// +build linux
1+
// +build linux,amd64
22

33
package devmapper
44

0 commit comments

Comments
 (0)