Files
packages/utils/lxc/patches/020-lxc-checkconfig.patch
John Audia 3e331ddcc0 lxc: update to 6.0.1
Changelog: https://discuss.linuxcontainers.org/t/lxc-6-0-lts-has-been-released/19567

Required libdbus as a depends for liblxc.  I verified that both
lxc-create and lxc-checkconfig work with the rebases to the
following patches but do please review:

  020-lxc-checkconfig.patch
  025-remove-unsupported-option.patch

Build system: x86/64
Build-tested: x86/64/AMD Cezanne
Run-tested: x86/64/AMD Cezanne

Signed-off-by: John Audia <therealgraysky@proton.me>
2024-06-29 11:56:46 -07:00

20 lines
555 B
Diff

--- a/src/lxc/cmd/lxc-checkconfig.in
+++ b/src/lxc/cmd/lxc-checkconfig.in
@@ -7,6 +7,16 @@ export LANGUAGE=en
# Allow environment variables to override config
: "${CONFIG:=/proc/config.gz}"
: "${MODNAME:=configs}"
+: ${ZGREP:=zgrep}
+: ${GUNZIP:=gunzip}
+
+if [ -z $(command -v $ZGREP) ] && ! [ -z $(command -v $GUNZIP) ] && [ -x $(command -v $GUNZIP) ] && [ -f $CONFIG ] && [ "$CONFIG" == "/proc/config.gz" ] ; then
+ CONFIG_NEW="/tmp/config-$(uname -r)"
+ $GUNZIP -c $CONFIG > $CONFIG_NEW
+ CONFIG=$CONFIG_NEW
+
+ GREP=grep
+fi
GREP="grep"