man-db: create man db index file
PATCH 1/1 man-db: create man db index file
The man db index file doesn't exist, it causes commands whatis, apropos and 'man -f' don't work as expect:
| root@qemux86-64:# whatis hosts
| hosts: nothing appropriate.
Run command mandb to create man db index file when first boot.
--- meta/recipes-extended/man-db/man-db_2.8.2.bb | 4 ++++ 1 file changed, 4 insertions(+)
meta/recipes-extended/man-db/man-db_2.8.2.bb +4 -0
@@ -21,6 +21,10 @@ do_install_append_libc-musl() { rm -f ${D}${libdir}/charset.alias } +pkg_postinst_ontarget_${PN} () { + ${bindir}/mandb -q +} + FILES_${PN} += "${prefix}/lib/tmpfiles.d" FILES_${PN}-dev += "${libdir}/man-db/libman.so ${libdir}/${BPN}/libmandb.so"
Signature · 1 line
2.11.0
meta/recipes-extended/man-db/man-db_2.8.2.bb do_install_append_libc-musl() { · line 27
Quoted 4 lines · Kai Kang
meta/recipes-extended/man-db/man-db_2.8.2.bb +4
-0+pkg_postinst_ontarget_${PN} () { + ${bindir}/mandb -q +} +
man-db is only the tools for manpages, but not the actual pages. So this will not work as expected when installing or removing packages that contain manpages. It should be added to classes/manpages.bbclass instead, with a RDEPENDS += "man-db". You can also fix man-pages_4.14.bb to inherit the class at the same time.
Oh, and you can also take qemu into use, so that this works also for read only rootfs, and doesn't add to first boot time, like this:
https://git.yoctoproject.org/cgit/cgit.cgi/poky-contrib/commit/?h=akanavin/package-version-updates&id=b42a7a733c7a6b51118ccb3fe6e33c35ac12b4ae
Alex
Quoted 9 lines · Alexander Kanavin
meta/recipes-extended/man-db/man-db_2.8.2.bb do_install_append_libc-musl() { · line 27
Quoted 4 lines · Kai Kang
meta/recipes-extended/man-db/man-db_2.8.2.bb +4
-0+pkg_postinst_ontarget_${PN} () { + ${bindir}/mandb -q +} +man-db is only the tools for manpages, but not the actual pages. So this will not work as expected when installing or removing packages that contain manpages. It should be added to classes/manpages.bbclass instead, with a RDEPENDS += "man-db". You can also fix man-pages_4.14.bb to inherit the class at the same time.
Quoted 6 lines
Oh, and you can also take qemu into use, so that this works also for read only rootfs, and doesn't add to first boot time, like this:
https://git.yoctoproject.org/cgit/cgit.cgi/poky-contrib/commit/?h=akanavin/package-version-updates&id=b42a7a733c7a6b51118ccb3fe6e33c35ac12b4aeAlex
Hi Alex,
Thanks a lot. I'll try it.
Signature · 2 lines
Regards, Neil | Kai Kang