Skip to contentSkip to conversation

go: define a hidden boolean to specify if CGO linking is supported

PATCH New Vicente Olivert Riera 2 participants 4 messages Jul 6, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/3 go: define a hidden boolean to specify if CGO linking is supported

---
 package/go/Config.in.host | 8 ++++++++
 1 file changed, 8 insertions(+)
package/go/Config.in.host +8 -0
index e1b13c0..d6d35dc 100644
@@ -5,3 +5,11 @@ config BR2_PACKAGE_HOST_GO_ARCH_SUPPORTS
 	depends on !BR2_ARM_CPU_ARMV4
 	# MIPS R6 support in Go has not yet been developed.
 	depends on !BR2_mips_64r6
+
+config BR2_PACKAGE_HOST_GO_CGO_LINKING_SUPPORTS
+	bool
+	default y
+	depends on BR2_PACKAGE_HOST_GO_ARCH_SUPPORTS
+	# Go doesn't support CGO linking on MIPS64x platforms
+	# See: https://github.com/karalabe/xgo/issues/46
+	depends on !BR2_mips64 && !BR2_mips64el
Signature · 1 line
2.7.3
#1 lore raw

PATCH 2/3 flannel: depends on CGO linking being supported

---
 package/flannel/Config.in | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
package/flannel/Config.in +3 -1
index cfdb909..134111b 100644
@@ -1,10 +1,12 @@
 comment "flannel needs a toolchain w/ threads"
-	depends on BR2_PACKAGE_HOST_GO_ARCH_SUPPORTS
+	depends on BR2_PACKAGE_HOST_GO_ARCH_SUPPORTS && \
+		BR2_PACKAGE_HOST_GO_CGO_LINKING_SUPPORTS
 	depends on !BR2_TOOLCHAIN_HAS_THREADS
 
 config BR2_PACKAGE_FLANNEL
 	bool "flannel"
 	depends on BR2_PACKAGE_HOST_GO_ARCH_SUPPORTS
+	depends on BR2_PACKAGE_HOST_GO_CGO_LINKING_SUPPORTS
 	depends on BR2_TOOLCHAIN_HAS_THREADS
 	help
 	  Flannel is a virtual network that gives a subnet to each
Signature · 1 line
2.7.3
#2 lore raw

PATCH 3/3 runc: depends on CGO linking being supported

In reply to Vicente Olivert Riera
---
 package/runc/Config.in | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
package/runc/Config.in +3 -1
index 1802e59..fd5dee7 100644
@@ -1,6 +1,7 @@
 config BR2_PACKAGE_RUNC
 	bool "runc"
 	depends on BR2_PACKAGE_HOST_GO_ARCH_SUPPORTS
+	depends on BR2_PACKAGE_HOST_GO_CGO_LINKING_SUPPORTS
 	depends on BR2_TOOLCHAIN_HAS_THREADS
 	help
 	  runC is a CLI tool for spawning and running containers
@@ -9,5 +10,6 @@ config BR2_PACKAGE_RUNC
 	  https://github.com/opencontainers/runc
 
 comment "runc needs a toolchain w/ threads"
-	depends on BR2_PACKAGE_HOST_GO_ARCH_SUPPORTS
+	depends on BR2_PACKAGE_HOST_GO_ARCH_SUPPORTS && \
+		BR2_PACKAGE_HOST_GO_CGO_LINKING_SUPPORTS
 	depends on !BR2_TOOLCHAIN_HAS_THREADS
Signature · 1 line
2.7.3
#3 lore raw

PATCH 1/3 go: define a hidden boolean to specify if CGO linking is supported

In reply to Vicente Olivert Riera

Hello,

Quoted 4 lines · Vicente Olivert Riera
---
 package/go/Config.in.host | 8 ++++++++
 1 file changed, 8 insertions(+)

All patches applied. I've added autobuilder failure references to patches 2/3 and 3/3, as discussed on IRC.

Thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com