summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYi Zhao <yi.zhao@eng.windriver.com>2024-07-20 22:12:30 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2024-07-21 11:08:11 +0100
commit83e68a5f47dbcf88e2e3c92411079b97e7099621 (patch)
tree85728b3cf35bf63df6336062ba9cfb8ff1861d45
parent85dfbc15c88e20ebaf51d81d283bdb8835ed67d9 (diff)
downloadpoky-83e68a5f47dbcf88e2e3c92411079b97e7099621.tar.gz
util-linux: install lastlog2 volatile file
Install lastlog2 volatile file to create /var/lib/lastlog directory to fix runtime error: $ lastlog2 lastlog2: Couldn't read entries for all users lastlog2: Cannot open database (/var/lib/lastlog/lastlog2.db): unable to open database file (From OE-Core rev: 0b651441363a6195a8d025f8010728bc42ae2ee5) Signed-off-by: Yi Zhao <yi.zhao@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-core/util-linux/util-linux_2.40.1.bb9
1 files changed, 8 insertions, 1 deletions
diff --git a/meta/recipes-core/util-linux/util-linux_2.40.1.bb b/meta/recipes-core/util-linux/util-linux_2.40.1.bb
index b70d97a934..a1aab94055 100644
--- a/meta/recipes-core/util-linux/util-linux_2.40.1.bb
+++ b/meta/recipes-core/util-linux/util-linux_2.40.1.bb
@@ -118,7 +118,8 @@ FILES:${PN}-mount = "${sysconfdir}/default/mountall"
118FILES:${PN}-runuser = "${sysconfdir}/pam.d/runuser*" 118FILES:${PN}-runuser = "${sysconfdir}/pam.d/runuser*"
119FILES:${PN}-su = "${sysconfdir}/pam.d/su-l" 119FILES:${PN}-su = "${sysconfdir}/pam.d/su-l"
120CONFFILES:${PN}-su = "${sysconfdir}/pam.d/su-l" 120CONFFILES:${PN}-su = "${sysconfdir}/pam.d/su-l"
121FILES:${PN}-lastlog2 += "${base_libdir}/security/pam_lastlog2.so" 121FILES:${PN}-lastlog2 += "${base_libdir}/security/pam_lastlog2.so \
122 ${nonarch_libdir}/tmpfiles.d/lastlog2.conf"
122FILES:${PN}-pylibmount = "${PYTHON_SITEPACKAGES_DIR}/libmount/pylibmount.so \ 123FILES:${PN}-pylibmount = "${PYTHON_SITEPACKAGES_DIR}/libmount/pylibmount.so \
123 ${PYTHON_SITEPACKAGES_DIR}/libmount/__init__.* \ 124 ${PYTHON_SITEPACKAGES_DIR}/libmount/__init__.* \
124 ${PYTHON_SITEPACKAGES_DIR}/libmount/__pycache__/*" 125 ${PYTHON_SITEPACKAGES_DIR}/libmount/__pycache__/*"
@@ -205,6 +206,12 @@ do_install:append:class-target () {
205 # otherwise it uses "other", which has "auth pam_deny.so" 206 # otherwise it uses "other", which has "auth pam_deny.so"
206 # and thus prevents the operation. 207 # and thus prevents the operation.
207 ln -s su ${D}${sysconfdir}/pam.d/su-l 208 ln -s su ${D}${sysconfdir}/pam.d/su-l
209
210 if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
211 install -d ${D}${nonarch_libdir}/tmpfiles.d
212 install -m 0644 ${S}/misc-utils/lastlog2-tmpfiles.conf.in \
213 ${D}${nonarch_libdir}/tmpfiles.d/lastlog2.conf
214 fi
208 fi 215 fi
209} 216}
210# nologin causes a conflict with shadow-native 217# nologin causes a conflict with shadow-native