Cluster support fixes
[AGL/meta-agl-demo.git] / recipes-demo / cluster-dashboard / cluster-dashboard_git.bb
1 SUMMARY     = "Instrument Cluster Dashboard application"
2 DESCRIPTION = "AGL demonstration instrument cluster dashboard application"
3 HOMEPAGE    = "https://gerrit.automotivelinux.org/gerrit/#/admin/projects/apps/agl-cluster-demo-dashboard"
4 SECTION     = "apps"
5
6 LICENSE     = "Apache-2.0 & BSD-3-Clause"
7 LIC_FILES_CHKSUM = "file://LICENSE;md5=ae6497158920d9524cf208c09cc4c984 \
8                     file://app/cluster-gauges.qml;beginline=9;endline=48;md5=54187d50b29429abee6095fe8b7c1a78"
9
10 DEPENDS = " \
11     qtquickcontrols2 \
12     libqtappfw \
13     glib-2.0 \
14     wayland wayland-native \
15     qtwayland qtwayland-native \
16 "
17
18 PV = "1.0+git${SRCPV}"
19
20 SRC_URI = "git://gerrit.automotivelinux.org/gerrit/apps/agl-cluster-demo-dashboard;protocol=https;branch=${AGL_BRANCH} \
21            file://cluster-dashboard.service \
22            file://cluster-dashboard.conf \
23            file://cluster-dashboard.token \
24 "
25 SRCREV  = "137144c447d8adb618f5acbcbafd65f50264d6eb"
26
27 S  = "${WORKDIR}/git"
28
29 inherit pkgconfig cmake_qt5 systemd
30
31 CLUSTER_DEMO_VSS_HOSTNAME ??= "192.168.10.2"
32
33 SYSTEMD_SERVICE:${PN} = "${BPN}.service"
34
35 do_install:append() {
36     install -D -m 0644 ${WORKDIR}/${BPN}.service ${D}${systemd_system_unitdir}/${BPN}.service
37
38     # VIS authorization token file for KUKSA.val should ideally not
39     # be readable by other users, but currently that's not doable
40     # until a packaging/sandboxing/MAC scheme is (re)implemented or
41     # something like OAuth is plumbed in as an alternative.
42     install -d ${D}${sysconfdir}/xdg/AGL/cluster-dashboard
43     install -m 0644 ${WORKDIR}/cluster-dashboard.conf ${D}${sysconfdir}/xdg/AGL/
44     sed -i "s/^server = .*/server = \"${CLUSTER_DEMO_VSS_HOSTNAME}\"/" ${D}${sysconfdir}/xdg/AGL/cluster-dashboard.conf
45     install -m 0644 ${WORKDIR}/cluster-dashboard.token ${D}${sysconfdir}/xdg/AGL/cluster-dashboard/
46 }
47
48 RDEPENDS:${PN} += " \
49     qtwayland \
50     qtbase-qmlplugins \
51     qtquickcontrols \
52     qtquickcontrols-qmlplugins \
53     qtquickcontrols2 \
54     qtquickcontrols2-qmlplugins \
55     qtgraphicaleffects-qmlplugins \
56     qtsvg-plugins \
57 "