blob: 3d2e4a73f13360d30a7860b51e2c6682924023bf [file] [log] [blame]
Andrew Geissler7e0e3c02022-02-25 20:34:39 +00001SUMMARY = "Diagnostic Log and Trace"
2DESCRIPTION = "This component provides a standardised log and trace interface, \
3based on the standardised protocol specified in the AUTOSAR standard 4.0 DLT. \
Patrick Williamsb542dec2023-06-09 01:26:37 -05004This component can be used by COVESA components and other applications as \
Andrew Geissler7e0e3c02022-02-25 20:34:39 +00005logging facility providing: \
6- the DLT shared library \
7- the DLT daemon, including startup scripts \
8- the DLT daemon adaptors- the DLT client console utilities \
9- the DLT test applications"
Patrick Williamsb542dec2023-06-09 01:26:37 -050010HOMEPAGE = "https://www.covesa.global/"
Andrew Geissler7e0e3c02022-02-25 20:34:39 +000011SECTION = "console/utils"
Andrew Geissler9aee5002022-03-30 16:27:02 +000012LICENSE = "MPL-2.0"
Andrew Geissler7e0e3c02022-02-25 20:34:39 +000013LIC_FILES_CHKSUM = "file://LICENSE;md5=8184208060df880fe3137b93eb88aeea"
14
15DEPENDS = "zlib gzip-native json-c"
16
Patrick Williamsb542dec2023-06-09 01:26:37 -050017SRC_URI = "git://github.com/COVESA/${BPN}.git;protocol=https;branch=master \
Andrew Geissler7e0e3c02022-02-25 20:34:39 +000018 file://0002-Don-t-execute-processes-as-a-specific-user.patch \
19 file://0004-Modify-systemd-config-directory.patch \
Andrew Geissler20137392023-10-12 04:59:14 -060020 file://544.patch \
Patrick Williamsac13d5f2023-11-24 18:59:46 -060021 file://567.patch \
Andrew Geissler7e0e3c02022-02-25 20:34:39 +000022 "
Andrew Geissler5082cc72023-09-11 08:41:39 -040023SRCREV = "0f2d4cfffada6f8448a2cb27995b38eb4271044f"
Andrew Geissler7e0e3c02022-02-25 20:34:39 +000024
25S = "${WORKDIR}/git"
26
Andrew Geissler20137392023-10-12 04:59:14 -060027PACKAGECONFIG ?= "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', ' systemd systemd-watchdog systemd-journal ', '', d)} \
28 dlt-examples dlt-adaptor dlt-adaptor-stdin dlt-adaptor-udp dlt-console \
Andrew Geissler7e0e3c02022-02-25 20:34:39 +000029 udp-connection dlt-system dlt-filetransfer "
30# dlt-dbus
31
32# General options
Andrew Geissler20137392023-10-12 04:59:14 -060033PACKAGECONFIG[dlt-examples] = "-DWITH_DLT_EXAMPLES=ON,-DWITH_DLT_EXAMPLES=OFF"
Andrew Geissler7e0e3c02022-02-25 20:34:39 +000034
35# Linux options
36PACKAGECONFIG[systemd] = "-DWITH_SYSTEMD=ON,-DWITH_SYSTEMD=OFF -DWITH_DLT_SYSTEM=OFF,systemd"
37PACKAGECONFIG[systemd-watchdog] = "-DWITH_SYSTEMD_WATCHDOG=ON,-DWITH_SYSTEMD_WATCHDOG=OFF,systemd,libsystemd"
38PACKAGECONFIG[systemd-journal] = "-DWITH_SYSTEMD_JOURNAL=ON,-DWITH_SYSTEMD_JOURNAL=OFF,systemd,libsystemd"
39PACKAGECONFIG[dlt-dbus] = "-DWITH_DLT_DBUS=ON,-DWITH_DLT_DBUS=OFF,dbus,dbus-lib"
40PACKAGECONFIG[udp-connection] = "-DWITH_UDP_CONNECTION=ON,-DWITH_UDP_CONNECTION=OFF"
41
42# Command line options
43PACKAGECONFIG[dlt-system] = "-DWITH_DLT_SYSTEM=ON,-DWITH_DLT_SYSTEM=OFF"
Andrew Geissler20137392023-10-12 04:59:14 -060044PACKAGECONFIG[dlt-adaptor] = "-DWITH_DLT_ADAPTOR=ON,-DWITH_DLT_ADAPTOR=OFF"
45PACKAGECONFIG[dlt-adaptor-stdin] = "-DWITH_DLT_ADAPTOR_STDIN=ON,-DWITH_DLT_ADAPTOR_STDIN=OFF"
46PACKAGECONFIG[dlt-adaptor-udp] = "-DWITH_DLT_ADAPTOR_UDP=ON,-DWITH_DLT_ADAPTOR_UDP=OFF"
Andrew Geissler7e0e3c02022-02-25 20:34:39 +000047PACKAGECONFIG[dlt-filetransfer] = "-DWITH_DLT_FILETRANSFER=ON,-DWITH_DLT_FILETRANSFER=OFF"
Andrew Geissler20137392023-10-12 04:59:14 -060048PACKAGECONFIG[dlt-console] = "-DWITH_DLT_CONSOLE=ON,-DWITH_DLT_CONSOLE=OFF"
Andrew Geissler7e0e3c02022-02-25 20:34:39 +000049
50inherit autotools gettext cmake pkgconfig systemd
51
Andrew Geissler20137392023-10-12 04:59:14 -060052# -DWITH_DLT_COREDUMPHANDLER=ON this feature is too experimental, disable for now
53#FILES:${PN} += "${libdir}/sysctl.d"
Andrew Geissler5082cc72023-09-11 08:41:39 -040054EXTRA_OECMAKE += "-DWITH_DLT_LOGSTORAGE_GZIP=ON -DWITH_EXTENDED_FILTERING=ON -DSYSTEMD_UNITDIR=${systemd_system_unitdir}"
Andrew Geissler7e0e3c02022-02-25 20:34:39 +000055
56PACKAGES += "${PN}-systemd"
57SYSTEMD_PACKAGES = "${PN} ${PN}-systemd"
58SYSTEMD_SERVICE:${PN} = " ${@bb.utils.contains('PACKAGECONFIG', 'systemd', 'dlt.service', '', d)} \
Andrew Geissler20137392023-10-12 04:59:14 -060059 ${@bb.utils.contains('PACKAGECONFIG', 'systemd dlt-system', 'dlt-system.service', '', d)} \
60 ${@bb.utils.contains('PACKAGECONFIG', 'systemd dlt-dbus', 'dlt-dbus.service', '', d)}"
Andrew Geissler7e0e3c02022-02-25 20:34:39 +000061SYSTEMD_AUTO_ENABLE:${PN} = "enable"
62SYSTEMD_SERVICE:${PN}-systemd = " \
Andrew Geissler20137392023-10-12 04:59:14 -060063 ${@bb.utils.contains('PACKAGECONFIG', 'systemd dlt-adaptor-udp', 'dlt-adaptor-udp.service', '', d)} \
64 ${@bb.utils.contains('PACKAGECONFIG', 'systemd dlt-examples', 'dlt-example-user.service', '', d)} \
65 ${@bb.utils.contains('PACKAGECONFIG', 'systemd dlt-examples dlt-console', 'dlt-receive.service', '', d)} \
Andrew Geissler7e0e3c02022-02-25 20:34:39 +000066"
67SYSTEMD_AUTO_ENABLE:${PN}-systemd = "disable"
68
69FILES:${PN}-doc += "${datadir}/dlt-filetransfer"
70
71do_install:append() {
72 rm -f ${D}${bindir}/dlt-test-*
73}