Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] package/crun: support crun as runtime in containerd
@ 2022-10-06 14:07 TIAN Yuanhao
  2022-11-21 15:08 ` Christian Stewart via buildroot
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: TIAN Yuanhao @ 2022-10-06 14:07 UTC (permalink / raw)
  To: buildroot; +Cc: TIAN Yuanhao

Create runc symlink to crun when runc is missing.

See: https://github.com/containerd/containerd/discussions/6162

Signed-off-by: TIAN Yuanhao <tianyuanhao3@163.com>
---
 package/containerd/Config.in | 2 +-
 package/crun/crun.mk         | 7 +++++++
 2 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/package/containerd/Config.in b/package/containerd/Config.in
index 0e3a55ef39..e69dd6768a 100644
--- a/package/containerd/Config.in
+++ b/package/containerd/Config.in
@@ -5,7 +5,7 @@ config BR2_PACKAGE_CONTAINERD
 	depends on BR2_TOOLCHAIN_HAS_THREADS
 	depends on !BR2_TOOLCHAIN_USES_UCLIBC # runc
 	depends on BR2_USE_MMU # util-linux
-	select BR2_PACKAGE_RUNC # runtime dependency
+	select BR2_PACKAGE_RUNC if !BR2_PACKAGE_CRUN # runtime dependency
 	select BR2_PACKAGE_UTIL_LINUX # runtime dependency
 	select BR2_PACKAGE_UTIL_LINUX_BINARIES
 	select BR2_PACKAGE_UTIL_LINUX_PIVOT_ROOT
diff --git a/package/crun/crun.mk b/package/crun/crun.mk
index 4a0c150594..19dda71a9f 100644
--- a/package/crun/crun.mk
+++ b/package/crun/crun.mk
@@ -36,4 +36,11 @@ else
 CRUN_CONF_OPTS += --disable-systemd
 endif
 
+ifeq ($(BR2_PACKAGE_RUNC),)
+define CRUN_CREATE_SYMLINK
+	ln -sf crun $(TARGET_DIR)/usr/bin/runc
+endef
+CRUN_POST_INSTALL_TARGET_HOOKS += CRUN_CREATE_SYMLINK
+endif
+
 $(eval $(autotools-package))
-- 
2.25.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-01-08 16:12 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-10-06 14:07 [Buildroot] [PATCH 1/1] package/crun: support crun as runtime in containerd TIAN Yuanhao
2022-11-21 15:08 ` Christian Stewart via buildroot
2022-12-21  1:23 ` tianyuanhao3
2023-01-08  2:40 ` Christian Stewart via buildroot
2023-01-08 16:12 ` Yann E. MORIN

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox