From 0ca391c1c20125fbe0385058c1db0be04539275b Mon Sep 17 00:00:00 2001 From: Chen Qi Date: Wed, 7 Aug 2019 09:14:44 +0800 Subject: runc: add PACKAGECONFIG to allow building as static or not Add a new PACKAGECONFIG, static, which when enabled will build runc as static. Default to enable it. We need this because we should allow users to build runc as not static so that when docker's cgroup driver is set to systemd, we don't get error. Signed-off-by: Chen Qi Signed-off-by: Bruce Ashfield --- recipes-containers/runc/runc.inc | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'recipes-containers/runc/runc.inc') diff --git a/recipes-containers/runc/runc.inc b/recipes-containers/runc/runc.inc index 46fd09dc..41ea41be 100644 --- a/recipes-containers/runc/runc.inc +++ b/recipes-containers/runc/runc.inc @@ -14,8 +14,10 @@ inherit go inherit goarch inherit pkgconfig -PACKAGECONFIG ??= "" +PACKAGECONFIG ??= "static" PACKAGECONFIG[seccomp] = "seccomp,,libseccomp" +# This PACKAGECONFIG serves the purpose of whether building runc as static or not +PACKAGECONFIG[static] = "" PROVIDES += "virtual/runc" RPROVIDES_${PN} = "virtual/runc" @@ -54,7 +56,11 @@ do_compile() { export CFLAGS="" export LDFLAGS="" - oe_runmake static + if ${@bb.utils.contains('PACKAGECONFIG', 'static', 'true', 'false', d)}; then + oe_runmake static + else + oe_runmake runc + fi } do_install() { -- cgit v1.2.3-54-g00ecf