# Set software versions
PREFERRED_VERSION_dpdk = "17%"
+PREFERRED_VERSION_kubernetes = "1.14%"
GOVERSION = "1.12%"
# Set preferred providers
--- /dev/null
+#
+# Copyright (C) 2019 Wind River Systems, Inc.
+#
+
+require recipes-containers/kubernetes/kubernetes_git.bb
+
+SRC_URI = " \
+ git://github.com/kubernetes/kubernetes.git;branch=${SRC_BRANCH};name=kubernetes \
+ file://0001-hack-lib-golang.sh-use-CC-from-environment.patch \
+ file://0001-cross-don-t-build-tests-by-default.patch \
+ "
--- /dev/null
+From fa912b53186a047d787c8c456156b9dbdcdf040d Mon Sep 17 00:00:00 2001
+From: Bruce Ashfield <bruce.ashfield@windriver.com>
+Date: Thu, 1 Nov 2018 10:21:10 -0400
+Subject: [PATCH] cross: don't build tests by default
+
+The hack/* build infrastructure doesn't respect the WHAT= commands
+that the make infrastructure provides to limit what is built.
+
+In our case, we are cross building and can't build the server test
+components without error. As such, we patch the targets out of the
+script to allow a successful build.
+
+Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
+---
+ hack/make-rules/cross.sh | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/import/hack/make-rules/cross.sh b/hack/make-rules/cross.sh
+index 8e1e938..0898c5c 100755
+--- a/src/import/hack/make-rules/cross.sh
++++ b/src/import/hack/make-rules/cross.sh
+@@ -33,6 +33,6 @@ make all WHAT="${KUBE_NODE_TARGETS[*]}" KUBE_BUILD_PLATFORMS="${KUBE_NODE_PLATFO
+
+ make all WHAT="${KUBE_CLIENT_TARGETS[*]}" KUBE_BUILD_PLATFORMS="${KUBE_CLIENT_PLATFORMS[*]}"
+
+-make all WHAT="${KUBE_TEST_TARGETS[*]}" KUBE_BUILD_PLATFORMS="${KUBE_TEST_PLATFORMS[*]}"
++#make all WHAT="${KUBE_TEST_TARGETS[*]}" KUBE_BUILD_PLATFORMS="${KUBE_TEST_PLATFORMS[*]}"
+
+-make all WHAT="${KUBE_TEST_SERVER_TARGETS[*]}" KUBE_BUILD_PLATFORMS="${KUBE_TEST_SERVER_PLATFORMS[*]}"
++#make all WHAT="${KUBE_TEST_SERVER_TARGETS[*]}" KUBE_BUILD_PLATFORMS="${KUBE_TEST_SERVER_PLATFORMS[*]}"
+--
+2.7.4
+
--- /dev/null
+From 9cbb2d523d481053d405ebac830c2074b00d3417 Mon Sep 17 00:00:00 2001
+From: Koen Kooi <koen.kooi@linaro.org>
+Date: Mon, 23 Jul 2018 15:28:02 +0200
+Subject: [PATCH] hack/lib/golang.sh: use CC from environment
+
+Toolchain tupples differs, especially when using vendor provides ones.
+
+Upstream-status: Inappropriate [embedded specific]
+Signed-off-by: Koen Kooi <koen.kooi@linaro.org>
+---
+ hack/lib/golang.sh | 4 ----
+ 1 file changed, 4 deletions(-)
+
+diff --git a/hack/lib/golang.sh b/hack/lib/golang.sh
+index c5d4634..563e2b4b 100755
+--- a/src/import/hack/lib/golang.sh
++++ b/src/import/hack/lib/golang.sh
+@@ -278,19 +278,15 @@ kube::golang::set_platform_envs() {
+ case "${platform}" in
+ "linux/arm")
+ export CGO_ENABLED=1
+- export CC=arm-linux-gnueabihf-gcc
+ ;;
+ "linux/arm64")
+ export CGO_ENABLED=1
+- export CC=aarch64-linux-gnu-gcc
+ ;;
+ "linux/ppc64le")
+ export CGO_ENABLED=1
+- export CC=powerpc64le-linux-gnu-gcc
+ ;;
+ "linux/s390x")
+ export CGO_ENABLED=1
+- export CC=s390x-linux-gnu-gcc
+ ;;
+ esac
+ fi
+--
+2.9.5
+
--- /dev/null
+#
+# Copyright (C) 2019 Wind River Systems, Inc.
+#
+
+require kubernetes.inc
+
+PV = "1.13.5+git${SRCREV_kubernetes}"
+SRCREV_kubernetes = "2166946f41b36dea2c4626f90a77706f426cdea2"
+SRC_BRANCH = "release-1.13"
--- /dev/null
+#
+# Copyright (C) 2019 Wind River Systems, Inc.
+#
+
+require kubernetes.inc
+
+PV = "1.13.9+git${SRCREV_kubernetes}"
+SRCREV_kubernetes = "3e4f6a92de5f259ef313ad876bb008897f6a98f0"
+SRC_BRANCH = "release-1.13"
--- /dev/null
+#
+# Copyright (C) 2019 Wind River Systems, Inc.
+#
+
+require kubernetes.inc
+
+PV = "1.14.1+git${SRCREV_kubernetes}"
+SRCREV_kubernetes = "b7394102d6ef778017f2ca4046abbaa23b88c290"
+SRC_BRANCH = "release-1.14"
--- /dev/null
+#
+# Copyright (C) 2019 Wind River Systems, Inc.
+#
+
+require kubernetes.inc
+
+PV = "1.14.5+git${SRCREV_kubernetes}"
+SRCREV_kubernetes = "0e9fcb426b100a2aea5ed5c25b3d8cfbb01a8acf"
+SRC_BRANCH = "release-1.14"
--- /dev/null
+#
+# Copyright (C) 2019 Wind River Systems, Inc.
+#
+
+require kubernetes.inc
+
+PV = "1.15.2+git${SRCREV_kubernetes}"
+SRCREV_kubernetes = "f6278300bebbb750328ac16ee6dd3aa7d3549568"
+SRC_BRANCH = "release-1.15"
+
+do_compile_prepend() {
+ unset GOCACHE
+}