Patrick Williams | ac13d5f | 2023-11-24 18:59:46 -0600 | [diff] [blame] | 1 | SUMMARY = "Y2038 safe version of lastlog" |
| 2 | HOMEPAGE = "https://github.com/thkukuk/lastlog2" |
| 3 | DESCRIPTION = "lastlog reports the last login of a given user or of all users who did ever login on a system." |
| 4 | LICENSE = "BSD-2-Clause" |
| 5 | LIC_FILES_CHKSUM = "file://LICENSE;md5=020090a00b69dd2af9ab82eb0003ea2c" |
| 6 | SECTION = "libs" |
| 7 | |
| 8 | SRCREV = "6138dff6f2a5216065fa4833a223b56d98cb62f3" |
| 9 | |
| 10 | SRC_URI = "git://github.com/thkukuk/lastlog2.git;branch=main;protocol=https \ |
| 11 | file://0001-remove-lto-to-fix-link-error-of-clang.patch \ |
| 12 | " |
| 13 | |
| 14 | S = "${WORKDIR}/git" |
| 15 | |
| 16 | inherit meson pkgconfig systemd features_check |
| 17 | |
| 18 | DEPENDS += " ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)} sqlite3 " |
| 19 | REQUIRED_DISTRO_FEATURES = "pam" |
| 20 | |
| 21 | SYSTEMD_SERVICE:${PN} = "lastlog2-import.service" |
| 22 | |
| 23 | EXTRA_OEMESON = " -Dpamlibdir=${libdir}" |
| 24 | |
| 25 | do_install:append () { |
| 26 | if [ -d ${D}${prefix}/lib/systemd -a ${D}${prefix}/lib != `dirname ${D}${systemd_unitdir}` ]; then |
| 27 | # Fix makefile hardcoded path assumptions for systemd (assumes $prefix) |
| 28 | # without usrmerge distro feature enabled |
| 29 | install -d `dirname ${D}${systemd_unitdir}` |
| 30 | mv ${D}${prefix}/lib/systemd `dirname ${D}${systemd_unitdir}` |
| 31 | fi |
| 32 | } |
| 33 | |
| 34 | FILES:${PN} += " ${systemd_system_unitdir} " |
| 35 | FILES:${PN} += " ${libdir} " |
| 36 | FILES:${PN} += " ${nonarch_libdir}/tmpfiles.d/* " |