summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/go/go-1.9/0007-ld-add-soname-to-shareable-objects.patch
diff options
context:
space:
mode:
authorMatt Madison <matt@madison.systems>2017-09-13 14:54:10 -0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-09-14 11:35:46 +0100
commit41c51dc28e881f8a12c62725a4d823db804a5cb1 (patch)
tree247fcae541237ec3afbf2a323442d34f622f0536 /meta/recipes-devtools/go/go-1.9/0007-ld-add-soname-to-shareable-objects.patch
parente6542356b461b510f913eecd3850c075764acc3a (diff)
downloadpoky-41c51dc28e881f8a12c62725a4d823db804a5cb1.tar.gz
go: update to go 1.9
* Rebased patches - dropped armhf-elf patch, should no longer be needed - dropped syslog patch which should not have been imported to begin with - reworked other patches as needed for the updated code base * Updated native, cross, cross-canadian .inc files to remove some testdata directories that contain .a files that strip chokes on during sysroot staging (From OE-Core rev: f2ccf56778433ec16f44eecaa10a610a6630df50) Signed-off-by: Matt Madison <matt@madison.systems> Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/go/go-1.9/0007-ld-add-soname-to-shareable-objects.patch')
-rw-r--r--meta/recipes-devtools/go/go-1.9/0007-ld-add-soname-to-shareable-objects.patch46
1 files changed, 46 insertions, 0 deletions
diff --git a/meta/recipes-devtools/go/go-1.9/0007-ld-add-soname-to-shareable-objects.patch b/meta/recipes-devtools/go/go-1.9/0007-ld-add-soname-to-shareable-objects.patch
new file mode 100644
index 0000000000..6459782d81
--- /dev/null
+++ b/meta/recipes-devtools/go/go-1.9/0007-ld-add-soname-to-shareable-objects.patch
@@ -0,0 +1,46 @@
1From e957c3458d53e37bf416f51d2f8bf54c195e50f5 Mon Sep 17 00:00:00 2001
2From: Matt Madison <matt@madison.systems>
3Date: Wed, 13 Sep 2017 08:27:02 -0700
4Subject: [PATCH 7/7] ld: add soname to shareable objects
5
6Shared library handling in OE depends on the inclusion
7of an soname header, so update the go linker to add that
8header for both internal and external linking.
9
10Upstream-Status: Pending
11
12Signed-off-by: Matt Madison <matt@madison.systems>
13---
14 src/cmd/link/internal/ld/lib.go | 3 +++
15 1 file changed, 3 insertions(+)
16
17diff --git a/src/cmd/link/internal/ld/lib.go b/src/cmd/link/internal/ld/lib.go
18index 0234105..0b9e2d0 100644
19--- a/src/cmd/link/internal/ld/lib.go
20+++ b/src/cmd/link/internal/ld/lib.go
21@@ -1124,12 +1124,14 @@ func (l *Link) hostlink() {
22 // Pass -z nodelete to mark the shared library as
23 // non-closeable: a dlclose will do nothing.
24 argv = append(argv, "-shared", "-Wl,-z,nodelete")
25+ argv = append(argv, fmt.Sprintf("-Wl,-soname,%s", filepath.Base(*flagOutfile)))
26 }
27 case BuildmodeShared:
28 if UseRelro() {
29 argv = append(argv, "-Wl,-z,relro")
30 }
31 argv = append(argv, "-shared")
32+ argv = append(argv, fmt.Sprintf("-Wl,-soname,%s", filepath.Base(*flagOutfile)))
33 case BuildmodePlugin:
34 if Headtype == objabi.Hdarwin {
35 argv = append(argv, "-dynamiclib")
36@@ -1138,6 +1140,7 @@ func (l *Link) hostlink() {
37 argv = append(argv, "-Wl,-z,relro")
38 }
39 argv = append(argv, "-shared")
40+ argv = append(argv, fmt.Sprintf("-Wl,-soname,%s", filepath.Base(*flagOutfile)))
41 }
42 }
43
44--
452.7.4
46