From fe0163a2479cb19c427e68923938b930e000c2a4 Mon Sep 17 00:00:00 2001 From: Michael Stapelberg Date: Mon, 19 Aug 2013 22:36:24 +0200 Subject: compile golang-go-linux-* for each arch MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Before this commit, golang-go-* were Architecture: all, meaning that they are built only once on — typically — either an amd64 or i386 machine. However, cgo is only available when building natively, meaning that when building on amd64, only golang-go-linux-amd64 had cgo enabled, or when building on i386, only golang-go-linux-386 had cgo enabled. Given that the packages behave differently depending on which architecture they are compiled, “Architecture: all” is obviously wrong. For golang-go-*-* where * is !linux, this is not a concern, since these packages can _only_ be used when cross-compiling anyway. When golang-go becomes available on more architectures, this needs to be changed. --- debian/changelog | 7 +++++++ debian/control | 6 +++--- debian/control.cross | 2 +- debian/rules | 4 +++- 4 files changed, 14 insertions(+), 5 deletions(-) (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index 0dfdda20d..eaddc3dcb 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +golang (2:1.1.2-2) unstable; urgency=low + + * Build golang-go-linux-* for each architecture (Thanks James Page) + (Closes: #719611) + + -- Michael Stapelberg Mon, 19 Aug 2013 22:40:54 +0200 + golang (2:1.1.2-1) unstable; urgency=low * New upstream release. diff --git a/debian/control b/debian/control index cbd1206e3..f21e99f80 100644 --- a/debian/control +++ b/debian/control @@ -125,7 +125,7 @@ Description: Go programming language - Vim highlighting syntax files in Google's Go programming language. Package: golang-go-linux-amd64 -Architecture: all +Architecture: i386 amd64 armel armhf Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends} Breaks: golang-go (<< 2:1.1-2) Replaces: golang-go (<< 2:1.1-2) @@ -143,7 +143,7 @@ Description: Go standard library compiled for linux_amd64 linux_amd64, even though you are executing the Go compiler on linux_386. Package: golang-go-linux-arm -Architecture: all +Architecture: i386 amd64 armel armhf Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends} Breaks: golang-go (<< 2:1.1-2) Replaces: golang-go (<< 2:1.1-2) @@ -161,7 +161,7 @@ Description: Go standard library compiled for linux_arm linux_amd64, even though you are executing the Go compiler on linux_386. Package: golang-go-linux-386 -Architecture: all +Architecture: i386 amd64 armel armhf Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends} Breaks: golang-go (<< 2:1.1-2) Replaces: golang-go (<< 2:1.1-2) diff --git a/debian/control.cross b/debian/control.cross index db6d1a6fc..592b4f94a 100644 --- a/debian/control.cross +++ b/debian/control.cross @@ -1,6 +1,6 @@ Package: golang-go-@OS@-@ARCH@ -Architecture: all +Architecture: @BUILDARCHS@ Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends} Breaks: golang-go (<< 2:1.1-2) Replaces: golang-go (<< 2:1.1-2) diff --git a/debian/rules b/debian/rules index 694ddfee9..7798cb0c9 100755 --- a/debian/rules +++ b/debian/rules @@ -49,7 +49,9 @@ gencontrol: echo "# DO NOT EDIT THIS FILE. EDIT debian/control.* instead!" > debian/control.tmp cat debian/control.base >> debian/control.tmp ${FOR_GO_ARCH} \ - sed -e "s,@OS@,$$os,g; s,@ARCH@,$$arch,g" debian/control.cross >> debian/control.tmp; \ + BUILDARCHS=all; \ + [ "$$os" = "linux" ] && BUILDARCHS="i386 amd64 armel armhf"; \ + sed -e "s,@OS@,$$os,g; s,@ARCH@,$$arch,g; s,@BUILDARCHS@,$$BUILDARCHS,g" debian/control.cross >> debian/control.tmp; \ ${FOR_GO_ARCH_END} mv debian/control.tmp debian/control -- cgit v1.2.3