lxc: delete empty lxc state directory

lxc systemd service [1] defines a StateDirectory to ensure that
the /var/lib/lxc directory is automatically created and managed
by systemd during service startup.
Do not create lxc directory at build time for systemd.

[1] f9ff9ea2a9/config/init/systemd/lxc.service.in (L16)

Signed-off-by: Vishwas Udupa <vudupa@qti.qualcomm.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
This commit is contained in:
Vishwas Udupa 2025-12-04 12:13:29 +05:30 committed by Bruce Ashfield
parent 9d98a3a8e9
commit 03fe48aa5c

View File

@ -141,7 +141,7 @@ do_install:append() {
if "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}"; then if "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}"; then
# nothing special for systemd at the moment # nothing special for systemd at the moment
true (cd ${D}${localstatedir}; [ -d lib/lxc ] && rmdir -v --parents lib/lxc)
else else
# with meson, these aren't built unless sysvinit is the enabled # with meson, these aren't built unless sysvinit is the enabled
# init system. # init system.