1 FILESEXTRAPATHS:append := "${THISDIR}/files:"
4 file://0001-Allow-the-embedder-to-run-as-a-regular-normal-applic.patch \
5 file://0002-shell-configuration-Obey-json-configuration-file.patch \
6 file://0003-shell-configuration-Fixes-to-general-options.patch \
7 file://0004-Add-app-id-command-line-argument.patch \
11 # Upstream is now pinning ivi-homescreen, but if it did need to be pinned
12 # it can be done here.
15 # For now disable gstreamer to avoid needing to enable "commercial"
16 # licenses for the stated ffmpeg dependency.
17 PACKAGECONFIG:remove = "gstreamer"
23 IVI_HOMESCREEN_APP_OVERRIDE = "--b=/usr/share/flutter/gallery --j=/usr/share/flutter/config.json"
25 SERVICE_UNIT = "Requires=agl-compositor.service\nAfter=agl-compositor.service"
26 SERVICE_INSTALL = "WantedBy=agl-session.target"
28 # The "homescreen" naming of the embedder binary conflicts with the
29 # Qt homescreen in meta-agl-demo. At least for now, rename it to
30 # allow running Flutter apps in an image that uses the Qt homescreen
31 # and launcher for testing.
32 SERVICE_EXEC_START = "ExecStart=/usr/bin/flutter --f ${IVI_HOMESCREEN_APP_OVERRIDE} ${SERVICE_EXEC_START_PARAMS}"
34 # we have a regular/agl-driver user, so avoid setting one
35 SERVICE_ENVIRONMENT = ""
36 SERVICE_USER_GROUP = ""
37 SERVICE_RESTART = "Restart=on-failure"
39 # we need to install as user session, not root.
41 # The system level systemd unit is not required in AGL
42 rm -f ${D}{systemd_system_unitdir}/homescreen.service
44 install -d ${D}${systemd_user_unitdir}/agl-session.target.wants
45 install -D -m 0644 ${WORKDIR}/config.json ${D}${datadir}/flutter/config.json
46 install -m 0644 ${WORKDIR}/homescreen.service ${D}${systemd_user_unitdir}/homescreen.service
47 ln -s ../homescreen.service ${D}${systemd_user_unitdir}/agl-session.target.wants/homescreen.service
49 # Rename embedder binary, see explanation above
50 mv ${D}${bindir}/homescreen ${D}${bindir}/flutter
53 # Split the embedder binary into a separate package to allow reusing it
54 # without the generated upstream systemd unit that ATM is still useful
55 # for testing with the agl-image-flutter image. AGL will use either
56 # the applaunchd systemd template or custom units in meta-agl-demo.
57 PACKAGE_BEFORE_PN = "flutter-embedder-${FLUTTER_RUNTIME}"
59 FILES:flutter-embedder-${FLUTTER_RUNTIME} = "${bindir}"
61 FILES:${PN} += "${systemd_user_unitdir} ${datadir}/flutter/config.json"
63 RDEPENDS:${PN} += "flutter-embedder-${FLUTTER_RUNTIME}"
65 RDEPENDS:flutter-embedder-${FLUTTER_RUNTIME} += "flutter-engine-${FLUTTER_RUNTIME}"