summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/go/go-1.6/armhf-elf-header.patch
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2017-03-07 22:40:22 -0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-03-10 14:50:16 +0000
commit78615e9260fb5d6569de4883521b049717fa4340 (patch)
treeaf9eba2be44d6d2baeed35bbd6c0446d70fd61d1 /meta/recipes-devtools/go/go-1.6/armhf-elf-header.patch
parent056a9da9f3ac2bc175f19243b11864ca90eee28b (diff)
downloadopenembedded-core-contrib-78615e9260fb5d6569de4883521b049717fa4340.tar.gz
go: Add recipes for golang compilers and tools
* This is converging the recipes for go from meta-virtualization and oe-meta-go * Add recipes for go 1.7 * go.bbclass is added to ease out writing recipes for go packages * go-examples: Add an example, helloworld written in go This should serve as temlate for writing go recipes * Disable for musl, at least for now * Disable for x32/ppc32 which is not supported Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/go/go-1.6/armhf-elf-header.patch')
-rw-r--r--meta/recipes-devtools/go/go-1.6/armhf-elf-header.patch23
1 files changed, 23 insertions, 0 deletions
diff --git a/meta/recipes-devtools/go/go-1.6/armhf-elf-header.patch b/meta/recipes-devtools/go/go-1.6/armhf-elf-header.patch
new file mode 100644
index 0000000000..1e3a16b319
--- /dev/null
+++ b/meta/recipes-devtools/go/go-1.6/armhf-elf-header.patch
@@ -0,0 +1,23 @@
+Encode arm EABI ( hard/soft ) calling convention in ELF header
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Pending
+Index: go/src/cmd/link/internal/ld/elf.go
+===================================================================
+--- go.orig/src/cmd/link/internal/ld/elf.go
++++ go/src/cmd/link/internal/ld/elf.go
+@@ -827,7 +827,13 @@
+ // 32-bit architectures
+ case '5':
+ // we use EABI on both linux/arm and freebsd/arm.
+- if HEADTYPE == obj.Hlinux || HEADTYPE == obj.Hfreebsd {
++ if HEADTYPE == obj.Hlinux {
++ if Ctxt.Goarm == 7 {
++ ehdr.flags = 0x5000402 // has entry point, Version5 EABI, hard float
++ } else {
++ ehdr.flags = 0x5000202 // has entry point, Version5 EABI, soft float
++ }
++ } else if HEADTYPE == obj.Hfreebsd {
+ // We set a value here that makes no indication of which
+ // float ABI the object uses, because this is information
+ // used by the dynamic linker to compare executables and