Patch Go for issue #9102 in build env (fixes #1112)

This commit is contained in:
Jakob Borg
2014-12-13 10:38:05 +01:00
parent b2ed32b118
commit 1c43587d7d
3 changed files with 34 additions and 3 deletions

View File

@@ -6,7 +6,7 @@ ENV GOLANG_VERSION 1.4
# SCMs for "go get", gcc for cgo
RUN apt-get update && apt-get install -y \
ca-certificates curl gcc libc6-dev make \
bzr git mercurial unzip \
bzr git mercurial unzip patch \
--no-install-recommends \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
@@ -29,7 +29,16 @@ RUN go get github.com/calmh/gonative \
&& rm -rf go \
&& gonative -version $GOLANG_VERSION
# Rebuild the special and missing versions
# Rebuild the special and missing versions, using patches as appropriate
RUN mkdir /tmp/patches
ADD *.patch /tmp/patches/
RUN bash -xec '\
cd /usr/local/go ; \
for patch in /tmp/patches/*.patch ; do \
patch -p0 < "$patch" ; \
done \
'
RUN bash -xec '\
cd /usr/local/go/src; \