summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorhongxu <hongxu.jia@eng.windriver.com>2025-02-10 15:46:58 +0800
committerBruce Ashfield <bruce.ashfield@gmail.com>2025-02-18 19:30:57 +0000
commit2b0e119d5ce4106e78c214babfc1c6fe02f636b2 (patch)
tree024089dc3a0e1e7ca728d357404cc03e54a76da3
parentc0fac810d979d9330e4b41c82f2b76796f303bd4 (diff)
downloadmeta-virtualization-2b0e119d5ce4106e78c214babfc1c6fe02f636b2.tar.gz
nerdctl: fix do_compile failed
Using latest poky + meta-virtualization + meta-openembedded, build multlib failed ...local.conf... MACHINE = "qemux86-64" require conf/multilib.conf MULTILIBS = "multilib:lib32" DEFAULTTUNE:virtclass-multilib-lib32 = "x86" $ bitbake lib32-nerdctl ... -buildmode=pie requires external (cgo) linking, but cgo is not enabled make: *** [Makefile:63: nerdctl] Error 1 ... Get back the patch to allow external specification of build settings and rebase to v2.0.2 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
-rw-r--r--recipes-containers/nerdctl/nerdctl/0001-Makefile-allow-external-specification-of-build-setti.patch28
-rw-r--r--recipes-containers/nerdctl/nerdctl_git.bb1
2 files changed, 18 insertions, 11 deletions
diff --git a/recipes-containers/nerdctl/nerdctl/0001-Makefile-allow-external-specification-of-build-setti.patch b/recipes-containers/nerdctl/nerdctl/0001-Makefile-allow-external-specification-of-build-setti.patch
index ca7b3042..cf7037f3 100644
--- a/recipes-containers/nerdctl/nerdctl/0001-Makefile-allow-external-specification-of-build-setti.patch
+++ b/recipes-containers/nerdctl/nerdctl/0001-Makefile-allow-external-specification-of-build-setti.patch
@@ -6,20 +6,26 @@ Subject: [PATCH] Makefile: allow external specification of build settings
6Upstream-Status: Inappropriate [embedded specific] 6Upstream-Status: Inappropriate [embedded specific]
7 7
8Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com> 8Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
9
10Rebase to v2.0.2
11Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
9--- 12---
10 Makefile | 3 ++- 13 src/import/Makefile | 2 +-
11 1 file changed, 2 insertions(+), 1 deletion(-) 14 1 file changed, 1 insertion(+), 1 deletion(-)
12 15
13Index: nerdctl-v2.0.0-beta.1/src/import/Makefile 16diff --git a/src/import/Makefile b/src/import/Makefile
14=================================================================== 17index ae4e18c..eb22f9f 100644
15--- nerdctl-v2.0.0-beta.1.orig/src/import/Makefile 18--- a/src/import/Makefile
16+++ nerdctl-v2.0.0-beta.1/src/import/Makefile 19+++ b/src/import/Makefile
17@@ -38,7 +38,7 @@ 20@@ -45,7 +45,7 @@ endif
18 21
19 GO_BUILD_LDFLAGS ?= -s -w 22 GO_BUILD_LDFLAGS ?= -s -w
20 GO_BUILD_FLAGS ?= 23 GO_BUILD_FLAGS ?=
21-export GO_BUILD=GO111MODULE=on CGO_ENABLED=0 GOOS=$(GOOS) $(GO) build -ldflags "$(GO_BUILD_LDFLAGS) -X $(PACKAGE)/pkg/version.Version=$(VERSION) -X $(PACKAGE)/pkg/version.Revision=$(REVISION)" 24-export GO_BUILD=CGO_ENABLED=0 GOOS=$(GOOS) $(GO) -C $(MAKEFILE_DIR) build -ldflags "$(GO_BUILD_LDFLAGS) $(VERBOSE_FLAG) -X $(PACKAGE)/pkg/version.Version=$(VERSION) -X $(PACKAGE)/pkg/version.Revision=$(REVISION)"
22+export GO_BUILD=$(GO) build -ldflags "$(GO_BUILD_LDFLAGS) -X $(PACKAGE)/pkg/version.Version=$(VERSION) -X $(PACKAGE)/pkg/version.Revision=$(REVISION)" 25+export GO_BUILD=GOOS=$(GOOS) $(GO) -C $(MAKEFILE_DIR) build -ldflags "$(GO_BUILD_LDFLAGS) $(VERBOSE_FLAG) -X $(PACKAGE)/pkg/version.Version=$(VERSION) -X $(PACKAGE)/pkg/version.Revision=$(REVISION)"
26
27 recursive_wildcard=$(wildcard $1$2) $(foreach e,$(wildcard $1*),$(call recursive_wildcard,$e/,$2))
23 28
24 ifdef VERBOSE 29--
25 VERBOSE_FLAG := -v 302.34.1
31
diff --git a/recipes-containers/nerdctl/nerdctl_git.bb b/recipes-containers/nerdctl/nerdctl_git.bb
index 63b96846..84734c9f 100644
--- a/recipes-containers/nerdctl/nerdctl_git.bb
+++ b/recipes-containers/nerdctl/nerdctl_git.bb
@@ -19,6 +19,7 @@ include src_uri.inc
19 19
20# patches and config 20# patches and config
21SRC_URI += " \ 21SRC_URI += " \
22 file://0001-Makefile-allow-external-specification-of-build-setti.patch \
22 file://modules.txt \ 23 file://modules.txt \
23 " 24 "
24 25