Your message dated Wed, 06 Jan 2016 04:49:30 +0000 with message-id <[email protected]> and subject line Bug#807136: fixed in golang 2:1.5.2-1 has caused the Debian Bug report #807136, regarding golang: FTBFS due to new binutils relocations to be marked as done.
This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact [email protected] immediately.) -- 807136: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=807136 Debian Bug Tracking System Contact [email protected] with problems
--- Begin Message ---Package: golang Version: 2:1.5.1-4 Severity: normal Tags: upstream patch Building golang fails with these errors: ... # cmd/trace /build/golang-1.5.1/pkg/linux_amd64/runtime/cgo.a(_all.o): unknown relocation type 42; compiled without -fpic? /build/golang-1.5.1/pkg/linux_amd64/runtime/cgo.a(_all.o): unknown relocation type 42; compiled without -fpic? /build/golang-1.5.1/pkg/linux_amd64/runtime/cgo.a(_all.o): unknown relocation type 42; compiled without -fpic? runtime/cgo(.text): unexpected relocation type 298 runtime/cgo(.text): unexpected relocation type 298 runtime/cgo(.text): unexpected relocation type 298 # cmd/pprof /build/golang-1.5.1/pkg/linux_amd64/runtime/cgo.a(_all.o): unknown relocation type 42; compiled without -fpic? /build/golang-1.5.1/pkg/linux_amd64/runtime/cgo.a(_all.o): unknown relocation type 42; compiled without -fpic? /build/golang-1.5.1/pkg/linux_amd64/runtime/cgo.a(_all.o): unknown relocation type 42; compiled without -fpic? runtime/cgo(.text): unexpected relocation type 298 runtime/cgo(.text): unexpected relocation type 298 runtime/cgo(.text): unexpected relocation type 298 # cmd/go /build/golang-1.5.1/pkg/linux_amd64/runtime/cgo.a(_all.o): unknown relocation type 42; compiled without -fpic? /build/golang-1.5.1/pkg/linux_amd64/runtime/cgo.a(_all.o): unknown relocation type 42; compiled without -fpic? /build/golang-1.5.1/pkg/linux_amd64/runtime/cgo.a(_all.o): unknown relocation type 42; compiled without -fpic? runtime/cgo(.text): unexpected relocation type 298 runtime/cgo(.text): unexpected relocation type 298 runtime/cgo(.text): unexpected relocation type 298 debian/rules:62: recipe for target 'override_dh_auto_build-arch' failed make[1]: *** [override_dh_auto_build-arch] Error 2 make[1]: Leaving directory '/build/golang-1.5.1' debian/rules:15: recipe for target 'build' failed make: *** [build] Error 2 dpkg-buildpackage: error: debian/rules build gave error exit status 2 The problem is fixed upstream here: https://github.com/golang/go/commit/914db9f060b1fd3eb1f74d48f3bd46a73d4ae9c7 but that commit does not apply cleanly to the current Debian version. I've attached an equivalent patch that does, but I didn't manage to preserve the original author, date, etc. Please use the original metadata from the github commit if you decide to apply this. -- System Information: Debian Release: stretch/sid APT prefers testing APT policy: (500, 'testing'), (400, 'unstable'), (1, 'experimental') Architecture: amd64 (x86_64) Kernel: Linux 4.2.0-1-amd64 (SMP w/8 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) Versions of packages golang depends on: ii golang-doc 2:1.5.1-4 ii golang-go 2:1.5.1-4 ii golang-src 2:1.5.1-4 golang recommends no packages. golang suggests no packages. -- no debconf information>From 716b8354f9fba9e67543c07c91438fa382046023 Mon Sep 17 00:00:00 2001 From: Eric Cooper <[email protected]> Date: Sat, 5 Dec 2015 15:19:25 -0500 Subject: [PATCH 3/3] The GNU binutils recently picked up support for new 386/amd64 relocations. Add support for them in the Go linker when doing an internal link. The 386 relocation R_386_GOT32X was proposed in https://groups.google.com/forum/#!topic/ia32-abi/GbJJskkid4I . It can be treated as identical to the R_386_GOT32 relocation. The amd64 relocations R_X86_64_GOTPCRELX and R_X86_64_REX_GOTPCRELX were proposed in https://groups.google.com/forum/#!topic/x86-64-abi/n9AWHogmVY0 . They can both be treated as identical to the R_X86_64_GOTPCREL relocation. The purpose of the new relocations is to permit additional linker relaxations in some cases. We do not attempt to support those cases. While we're at it, remove the unused and in some cases out of date _COUNT names from ld/elf.go. Fixes #13114. Change-Id: I34ef07f6fcd00cdd2996038ecf46bb77a49e968b Reviewed-on: https://go-review.googlesource.com/16529 Reviewed-by: Minux Ma <[email protected]> Signed-off-by: Eric Cooper <[email protected]> --- src/cmd/link/internal/amd64/asm.go | 2 +- src/cmd/link/internal/ld/elf.go | 141 +++++++++++++++++++++---------------- src/cmd/link/internal/ld/ldelf.go | 3 + src/cmd/link/internal/x86/asm.go | 2 +- 4 files changed, 86 insertions(+), 62 deletions(-) diff --git a/src/cmd/link/internal/amd64/asm.go b/src/cmd/link/internal/amd64/asm.go index 74ec9dd..4eb2092 100644 --- a/src/cmd/link/internal/amd64/asm.go +++ b/src/cmd/link/internal/amd64/asm.go @@ -141,7 +141,7 @@ func adddynrel(s *ld.LSym, r *ld.Reloc) { return - case 256 + ld.R_X86_64_GOTPCREL: + case 256 + ld.R_X86_64_GOTPCREL, 256 + ld.R_X86_64_GOTPCRELX, 256 + ld.R_X86_64_REX_GOTPCRELX: if targ.Type != obj.SDYNIMPORT { // have symbol if r.Off >= 2 && s.P[r.Off-2] == 0x8b { diff --git a/src/cmd/link/internal/ld/elf.go b/src/cmd/link/internal/ld/elf.go index 508f055..66ac543 100644 --- a/src/cmd/link/internal/ld/elf.go +++ b/src/cmd/link/internal/ld/elf.go @@ -324,31 +324,48 @@ const ( * Relocation types. */ const ( - R_X86_64_NONE = 0 - R_X86_64_64 = 1 - R_X86_64_PC32 = 2 - R_X86_64_GOT32 = 3 - R_X86_64_PLT32 = 4 - R_X86_64_COPY = 5 - R_X86_64_GLOB_DAT = 6 - R_X86_64_JMP_SLOT = 7 - R_X86_64_RELATIVE = 8 - R_X86_64_GOTPCREL = 9 - R_X86_64_32 = 10 - R_X86_64_32S = 11 - R_X86_64_16 = 12 - R_X86_64_PC16 = 13 - R_X86_64_8 = 14 - R_X86_64_PC8 = 15 - R_X86_64_DTPMOD64 = 16 - R_X86_64_DTPOFF64 = 17 - R_X86_64_TPOFF64 = 18 - R_X86_64_TLSGD = 19 - R_X86_64_TLSLD = 20 - R_X86_64_DTPOFF32 = 21 - R_X86_64_GOTTPOFF = 22 - R_X86_64_TPOFF32 = 23 - R_X86_64_COUNT = 24 + R_X86_64_NONE = 0 + R_X86_64_64 = 1 + R_X86_64_PC32 = 2 + R_X86_64_GOT32 = 3 + R_X86_64_PLT32 = 4 + R_X86_64_COPY = 5 + R_X86_64_GLOB_DAT = 6 + R_X86_64_JMP_SLOT = 7 + R_X86_64_RELATIVE = 8 + R_X86_64_GOTPCREL = 9 + R_X86_64_32 = 10 + R_X86_64_32S = 11 + R_X86_64_16 = 12 + R_X86_64_PC16 = 13 + R_X86_64_8 = 14 + R_X86_64_PC8 = 15 + R_X86_64_DTPMOD64 = 16 + R_X86_64_DTPOFF64 = 17 + R_X86_64_TPOFF64 = 18 + R_X86_64_TLSGD = 19 + R_X86_64_TLSLD = 20 + R_X86_64_DTPOFF32 = 21 + R_X86_64_GOTTPOFF = 22 + R_X86_64_TPOFF32 = 23 + R_X86_64_PC64 = 24 + R_X86_64_GOTOFF64 = 25 + R_X86_64_GOTPC32 = 26 + R_X86_64_GOT64 = 27 + R_X86_64_GOTPCREL64 = 28 + R_X86_64_GOTPC64 = 29 + R_X86_64_GOTPLT64 = 30 + R_X86_64_PLTOFF64 = 31 + R_X86_64_SIZE32 = 32 + R_X86_64_SIZE64 = 33 + R_X86_64_GOTPC32_TLSDEC = 34 + R_X86_64_TLSDESC_CALL = 35 + R_X86_64_TLSDESC = 36 + R_X86_64_IRELATIVE = 37 + R_X86_64_PC32_BND = 40 + R_X86_64_GOTPCRELX = 41 + R_X86_64_REX_GOTPCRELX = 42 + R_AARCH64_ABS64 = 257 R_AARCH64_ABS32 = 258 R_AARCH64_CALL26 = 283 @@ -382,7 +399,7 @@ const ( R_ALPHA_GLOB_DAT = 25 R_ALPHA_JMP_SLOT = 26 R_ALPHA_RELATIVE = 27 - R_ALPHA_COUNT = 28 + R_ARM_NONE = 0 R_ARM_PC24 = 1 R_ARM_ABS32 = 2 @@ -422,39 +439,44 @@ const ( R_ARM_RABS32 = 253 R_ARM_RPC24 = 254 R_ARM_RBASE = 255 - R_ARM_COUNT = 38 - R_386_NONE = 0 - R_386_32 = 1 - R_386_PC32 = 2 - R_386_GOT32 = 3 - R_386_PLT32 = 4 - R_386_COPY = 5 - R_386_GLOB_DAT = 6 - R_386_JMP_SLOT = 7 - R_386_RELATIVE = 8 - R_386_GOTOFF = 9 - R_386_GOTPC = 10 - R_386_TLS_TPOFF = 14 - R_386_TLS_IE = 15 - R_386_TLS_GOTIE = 16 - R_386_TLS_LE = 17 - R_386_TLS_GD = 18 - R_386_TLS_LDM = 19 - R_386_TLS_GD_32 = 24 - R_386_TLS_GD_PUSH = 25 - R_386_TLS_GD_CALL = 26 - R_386_TLS_GD_POP = 27 - R_386_TLS_LDM_32 = 28 - R_386_TLS_LDM_PUSH = 29 - R_386_TLS_LDM_CALL = 30 - R_386_TLS_LDM_POP = 31 - R_386_TLS_LDO_32 = 32 - R_386_TLS_IE_32 = 33 - R_386_TLS_LE_32 = 34 - R_386_TLS_DTPMOD32 = 35 - R_386_TLS_DTPOFF32 = 36 - R_386_TLS_TPOFF32 = 37 - R_386_COUNT = 38 + + R_386_NONE = 0 + R_386_32 = 1 + R_386_PC32 = 2 + R_386_GOT32 = 3 + R_386_PLT32 = 4 + R_386_COPY = 5 + R_386_GLOB_DAT = 6 + R_386_JMP_SLOT = 7 + R_386_RELATIVE = 8 + R_386_GOTOFF = 9 + R_386_GOTPC = 10 + R_386_TLS_TPOFF = 14 + R_386_TLS_IE = 15 + R_386_TLS_GOTIE = 16 + R_386_TLS_LE = 17 + R_386_TLS_GD = 18 + R_386_TLS_LDM = 19 + R_386_TLS_GD_32 = 24 + R_386_TLS_GD_PUSH = 25 + R_386_TLS_GD_CALL = 26 + R_386_TLS_GD_POP = 27 + R_386_TLS_LDM_32 = 28 + R_386_TLS_LDM_PUSH = 29 + R_386_TLS_LDM_CALL = 30 + R_386_TLS_LDM_POP = 31 + R_386_TLS_LDO_32 = 32 + R_386_TLS_IE_32 = 33 + R_386_TLS_LE_32 = 34 + R_386_TLS_DTPMOD32 = 35 + R_386_TLS_DTPOFF32 = 36 + R_386_TLS_TPOFF32 = 37 + R_386_TLS_GOTDESC = 39 + R_386_TLS_DESC_CALL = 40 + R_386_TLS_DESC = 41 + R_386_IRELATIVE = 42 + R_386_GOT32X = 43 + R_PPC_NONE = 0 R_PPC_ADDR32 = 1 R_PPC_ADDR24 = 2 @@ -492,7 +514,6 @@ const ( R_PPC_SECTOFF_LO = 34 R_PPC_SECTOFF_HI = 35 R_PPC_SECTOFF_HA = 36 - R_PPC_COUNT = 37 R_PPC_TLS = 67 R_PPC_DTPMOD32 = 68 R_PPC_TPREL16 = 69 diff --git a/src/cmd/link/internal/ld/ldelf.go b/src/cmd/link/internal/ld/ldelf.go index 3efdb75..7ff37ad 100644 --- a/src/cmd/link/internal/ld/ldelf.go +++ b/src/cmd/link/internal/ld/ldelf.go @@ -1001,12 +1001,15 @@ func reltype(pn string, elftype int, siz *uint8) int { '6' | R_X86_64_PC32<<24, '6' | R_X86_64_PLT32<<24, '6' | R_X86_64_GOTPCREL<<24, + '6' | R_X86_64_GOTPCRELX<<24, + '6' | R_X86_64_REX_GOTPCRELX<<24, '8' | R_386_32<<24, '8' | R_386_PC32<<24, '8' | R_386_GOT32<<24, '8' | R_386_PLT32<<24, '8' | R_386_GOTOFF<<24, '8' | R_386_GOTPC<<24, + '8' | R_386_GOT32X<<24, '9' | R_PPC64_REL24<<24: *siz = 4 diff --git a/src/cmd/link/internal/x86/asm.go b/src/cmd/link/internal/x86/asm.go index d30bd48..6495385 100644 --- a/src/cmd/link/internal/x86/asm.go +++ b/src/cmd/link/internal/x86/asm.go @@ -78,7 +78,7 @@ func adddynrel(s *ld.LSym, r *ld.Reloc) { return - case 256 + ld.R_386_GOT32: + case 256 + ld.R_386_GOT32, 256 + ld.R_386_GOT32X: if targ.Type != obj.SDYNIMPORT { // have symbol if r.Off >= 2 && s.P[r.Off-2] == 0x8b { -- 2.6.2
--- End Message ---
--- Begin Message ---Source: golang Source-Version: 2:1.5.2-1 We believe that the bug you reported is fixed in the latest version of golang, which is due to be installed in the Debian FTP archive. A summary of the changes between this version and the previous one is attached. Thank you for reporting the bug, which will now be closed. If you have further comments please address them to [email protected], and the maintainer will reopen the bug report if appropriate. Debian distribution maintenance software pp. Tianon Gravi <[email protected]> (supplier of updated golang package) (This message was generated automatically at their request; if you believe that there is a problem with it please contact the archive administrators by mailing [email protected]) -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA512 Format: 1.8 Date: Tue, 05 Jan 2016 19:59:22 -0800 Source: golang Binary: golang-go golang-src golang-doc golang Architecture: source all amd64 Version: 2:1.5.2-1 Distribution: unstable Urgency: medium Maintainer: Go Compiler Team <[email protected]> Changed-By: Tianon Gravi <[email protected]> Description: golang - Go programming language compiler - metapackage golang-doc - Go programming language - documentation golang-go - Go programming language compiler, linker, compiled stdlib golang-src - Go programming language - source files Closes: 807136 Changes: golang (2:1.5.2-1) unstable; urgency=medium . * Update to 1.5.2 upstream release (Closes: #807136) Checksums-Sha1: 477263462b8256ccf5b1a7f604c1390f64542e98 2299 golang_1.5.2-1.dsc c7d78ba4df574b5f9a9bb5d17505f40c4d89b81c 12056199 golang_1.5.2.orig.tar.gz d2e687111126824bcc6869cf93abdd0764fea762 36932 golang_1.5.2-1.debian.tar.xz f35a00c44995519dc70d4aee248a65a459d6c8dd 2364158 golang-doc_1.5.2-1_all.deb fbeab7c4717504b858e60e6dd2564764e0dcb804 27150542 golang-go_1.5.2-1_amd64.deb 2a44695457cef7a291faea936ac63b5cf7d727f1 6362854 golang-src_1.5.2-1_amd64.deb 6c625a36ad6d5155d5184b16e22a209ffc138fbb 26334 golang_1.5.2-1_all.deb Checksums-Sha256: 69005e4ffaf13094e1f2ff7017d1164b7b98f434f5d5e6a0eac89b8bcc0d6e69 2299 golang_1.5.2-1.dsc f3ddd624c00461641ce3d3a8d8e3c622392384ca7699e901b370a4eac5987a74 12056199 golang_1.5.2.orig.tar.gz 00d4c6f31429fbe1a89c9ab7a70ee42aeff4bd1e75112adfbca170aa216840a3 36932 golang_1.5.2-1.debian.tar.xz 9652574f2162dc22371bdf32658a8da4d3d5c2976b828a05a06cf5b29449388a 2364158 golang-doc_1.5.2-1_all.deb 8df2542006a8169acff9bf4569d4efcdc982039a76480f84c968c51fc85f85f0 27150542 golang-go_1.5.2-1_amd64.deb bc7bd33b0e247a454759abbcce4d1b85570c678afdfb76234dd1c5b5188b6c0e 6362854 golang-src_1.5.2-1_amd64.deb d4cbdc1a0273eaa528e26123a50d4648f73853937b6bace3ef37443d098a17ae 26334 golang_1.5.2-1_all.deb Files: 684ee2707ab27a046f1f6c5ca3046760 2299 devel optional golang_1.5.2-1.dsc 38fed22e7b80672291e7cba7fb9c3475 12056199 devel optional golang_1.5.2.orig.tar.gz b1bb7b7831e964e2b72f76238a1fed45 36932 devel optional golang_1.5.2-1.debian.tar.xz 2fd865ae865f7b639c07c5ebef202437 2364158 doc optional golang-doc_1.5.2-1_all.deb 564d93aa9bc92ac2bc4fbe5930c191d1 27150542 devel optional golang-go_1.5.2-1_amd64.deb c38076431e9a6114d00c0045fd161559 6362854 devel optional golang-src_1.5.2-1_amd64.deb 36c60dc6cc9c1bbaeb7c625e2efc8c0a 26334 devel optional golang_1.5.2-1_all.deb -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBCgAGBQJWjJiTAAoJEANqnCW/NX3UiM8QAJ7rO7umGz80jByBFp3qAikR +Qj5pFJo5j+UTi2LfdElQEzW6R3zaUDODYWXIaFtowJM2912wwSUls/1zHG9R40N nySO4xlQoLIvWBSvywZ39ZYaEaICcv9PlCmB7RhtsCYcIvuy25gRwdKRiDEsDozB ryO0hgahD7+8+gYmr/5xsZwNqycx8ebnh6EAbybmWF6VnLH5kuiknZsac776Gvrf 7XmTsyijSNvhWQ7Vu1PEE6XISfXnva4/jnBTshgII8ChZK1cmM2upg0NF72st/sH KwVWTdG0ts8e7Jvo5vA3lu+GCkr9+WqoO8A81A56t1VpOF4V8ME9Hs+8MdXWkOwf yUIJRmW2ditB8tS9Zo3b/uYIjxcjUEwo/YpfDJwzPIfSOoKhU440iKlGrZPO3RBX cI4me3hjVCfnu+ZZiZNzdesltgR1SBKXJY8aO75WkiGayhvHVMraYahpimPCqrnO VkUctKtlJV8PovjiMoBg0gqBBqvneS+OctupQTiY5JIrhDl4l0mCFnlu9GqEWVnf IEpVOe3YYLauD+f74efwdjvy6py/e2+ise/sf/3dpGIvfFPQvkya5YAIUR8Ak9A4 UAKx0p1uz0omqmfj3PvumaoeyvASoxnVYdqrlQu3Vi8NRDVYSfzj8G8cUVqFiwgH /1HYw92mY1AjIetyMvDW =PTpL -----END PGP SIGNATURE-----
--- End Message ---

