blob: 063e2466817a8a6d31be666e7d8ba85f76594af4 [file] [log] [blame]
SUMMARY = "Google Hoth Daemon"
DESCRIPTION = "Google Hoth Daemon"
PR = "r1"
PV = "1.0+git${SRCPV}"
LICENSE = "Apache-2.0"
LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
PACKAGECONFIG ??= ""
PACKAGECONFIG[usb] = "-Dusb=enabled,-Dusb=disabled,libusb1 libhoth,libusb1 libhoth"
inherit meson pkgconfig systemd useradd
inherit python3native
DEPENDS += "${PYTHON_PN}-sdbus++-native"
DEPENDS += "sdbusplus"
DEPENDS += "stdplus"
DEPENDS += "phosphor-dbus-interfaces"
DEPENDS += "phosphor-logging"
DEPENDS += "boost"
DEPENDS += "fmt"
DEPENDS += "cli11"
DEPENDS += "${@bb.utils.contains('PACKAGECONFIG', 'usb', ' i2c-tools', '', d)}"
EXTRA_OEMESON += "-Dtests=disabled"
S = "${WORKDIR}/git"
SRC_URI ="git://gbmc.googlesource.com/hothd;protocol=https;branch=master"
SRCREV = "08c451f5a5b5ba8d0c873a03e167a0eabf79bab5"
USERADD_PACKAGES = "${PN}"
USERADD_PARAM:${PN} = "-r -d / -M -s /sbin/nologin hothd"
SYSTEMD_PACKAGES = "${PN}"
SYSTEMD_SERVICE:${PN} += "hothd.service"
SYSTEMD_SERVICE:${PN}:append = "${@bb.utils.contains('PACKAGECONFIG', 'usb', ' hothd-usb@.service google_secured_nvme_usb_reset.service', '', d)}"
RDEPENDS:${PN}:append = "${@bb.utils.contains('PACKAGECONFIG', 'usb', ' bash', '', d)}"
FILES:${PN} += "${datadir}/dbus-1/system.d/hothd.conf"
# Block legacy verify commands for non-legacy SPI flash sizes
do_install:append() {
if [ '${FLASH_SIZE}' -gt 32768 ]; then
sed -i 's,/hothd,/hothd -b,' ${D}${systemd_system_unitdir}/hothd.service
fi
}