diff --git a/poky/.gitignore b/poky/.gitignore index 261044d..4fd8b73 100644 --- a/poky/.gitignore +++ b/poky/.gitignore @@ -29,6 +29,7 @@ hob-image-*.bb !meta-mender !meta-mender-community !meta-flutter-apps +!meta-flutter-elinux /documentation/*/eclipse/ /documentation/*/*.html /documentation/*/*.pdf diff --git a/poky/meta-flutter-elinux/COPYING.MIT b/poky/meta-flutter-elinux/COPYING.MIT new file mode 100644 index 0000000..fb950dc --- /dev/null +++ b/poky/meta-flutter-elinux/COPYING.MIT @@ -0,0 +1,17 @@ +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/poky/meta-flutter-elinux/README b/poky/meta-flutter-elinux/README new file mode 100644 index 0000000..a207bb0 --- /dev/null +++ b/poky/meta-flutter-elinux/README @@ -0,0 +1,41 @@ +This README file contains information on the contents of the meta-stargazer layer. + +Please see the corresponding sections below for details. + +Dependencies +============ + + URI: + branch: + + URI: + branch: + + . + . + . + +Patches +======= + +Please submit any patches against the meta-stargazer layer to the xxxx mailing list (xxxx@zzzz.org) +and cc: the maintainer: + +Maintainer: XXX YYYYYY + +Table of Contents +================= + + I. Adding the meta-stargazer layer to your build + II. Misc + + +I. Adding the meta-stargazer layer to your build +================================================= + +Run 'bitbake-layers add-layer meta-stargazer' + +II. Misc +======== + +--- replace with specific information about the meta-stargazer layer --- diff --git a/poky/meta-flutter-elinux/conf/layer.conf b/poky/meta-flutter-elinux/conf/layer.conf new file mode 100644 index 0000000..24495d6 --- /dev/null +++ b/poky/meta-flutter-elinux/conf/layer.conf @@ -0,0 +1,13 @@ +# We have a conf and classes directory, add to BBPATH +BBPATH .= ":${LAYERDIR}" + +# We have recipes-* directories, add to BBFILES +BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \ + ${LAYERDIR}/recipes-*/*/*.bbappend" + +BBFILE_COLLECTIONS += "meta-stargazer" +BBFILE_PATTERN_meta-stargazer = "^${LAYERDIR}/" +BBFILE_PRIORITY_meta-stargazer = "6" + +LAYERDEPENDS_meta-stargazer = "core" +LAYERSERIES_COMPAT_meta-stargazer = "kirkstone" diff --git a/poky/meta-flutter-elinux/recipes-connectivity/wpa-supplicant/files/wpa_supplicant-nl80211-wlan0.conf b/poky/meta-flutter-elinux/recipes-connectivity/wpa-supplicant/files/wpa_supplicant-nl80211-wlan0.conf new file mode 100644 index 0000000..b214a2c --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-connectivity/wpa-supplicant/files/wpa_supplicant-nl80211-wlan0.conf @@ -0,0 +1,4 @@ +network={ + ssid="Pixel_8693" + psk=913bb5fe8b91473c9dd1d0d879f43af5f63e884250e3737dcf4b02955ea9f345 +} diff --git a/poky/meta-flutter-elinux/recipes-connectivity/wpa-supplicant/wpa-supplicant_%.bbappend b/poky/meta-flutter-elinux/recipes-connectivity/wpa-supplicant/wpa-supplicant_%.bbappend new file mode 100644 index 0000000..487f422 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-connectivity/wpa-supplicant/wpa-supplicant_%.bbappend @@ -0,0 +1,14 @@ +FILESEXTRAPATHS:prepend := "${THISDIR}/files:" + +SRC_URI += "file://wpa_supplicant-nl80211-wlan0.conf" + +SYSTEMD_AUTO_ENABLE = "enable" +SYSTEMD_SERVICE:${PN}:append = " wpa_supplicant-nl80211@wlan0.service " + +do_install:append () { + install -d ${D}${sysconfdir}/wpa_supplicant/ + install -D -m 600 ${WORKDIR}/wpa_supplicant-nl80211-wlan0.conf ${D}${sysconfdir}/wpa_supplicant/ + + install -d ${D}${sysconfdir}/systemd/system/multi-user.target.wants/ + ln -s ${systemd_unitdir}/system/wpa_supplicant@.service ${D}${sysconfdir}/systemd/system/multi-user.target.wants/wpa_supplicant-nl80211@wlan0.service +} \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/custom-scripts/files/flutter-auto-launch b/poky/meta-flutter-elinux/recipes-core/custom-scripts/files/flutter-auto-launch new file mode 100644 index 0000000..72d4cc3 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/custom-scripts/files/flutter-auto-launch @@ -0,0 +1,2 @@ +#!/usr/bin/env bash +/usr/bin/flutter-auto --b=/flutter/flutter_elinux/3.19.2/release --c --f \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/custom-scripts/flutter-auto-launch_1.00.bb b/poky/meta-flutter-elinux/recipes-core/custom-scripts/flutter-auto-launch_1.00.bb new file mode 100644 index 0000000..26bdc80 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/custom-scripts/flutter-auto-launch_1.00.bb @@ -0,0 +1,9 @@ +LICENSE = "CLOSED" + +SRC_URI:append = " file://flutter-auto-launch " +FILES:${PN} += "/usr/local/bin/flutter-auto-launch" + +do_install:append() { + install -d ${D}/usr/local/bin + install -m 0777 ${WORKDIR}/flutter-auto-launch ${D}/usr/local/bin +} \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/devices/flutter-auto-setup_1.00.bb b/poky/meta-flutter-elinux/recipes-core/devices/flutter-auto-setup_1.00.bb new file mode 100644 index 0000000..30d5c4a --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/devices/flutter-auto-setup_1.00.bb @@ -0,0 +1,9 @@ +LICENSE = "CLOSED" + +IMAGE_INSTALL:append = " flutter-auto flutter-elinux flutter-auto-launch flutter-libraries kernel-image kernel-devicetree liberation-fonts networkmanager dhcpcd iptables iw linux-firmware ca-certificates gstreamer1.0-rtsp-server gstreamer1.0 gstreamer1.0-plugins-base gstreamer1.0-plugins-good gstreamer1.0-plugins-bad gstreamer1.0-plugins-ugly gstreamer1.0-libav libinput libxkbcommon tzdata alsa-utils alsa-lib bcm2835-dev" + +# needed for gstreamer-plugins-ugly: +LICENSE_FLAGS_ACCEPTED = "commercial" + +CORE_IMAGE_EXTRA_INSTALL += "wayland cage" +DISTRO_FEATURES:append = " wayland" \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/devices/flutter-pi-setup_1.00.bb b/poky/meta-flutter-elinux/recipes-core/devices/flutter-pi-setup_1.00.bb new file mode 100644 index 0000000..4f40d2a --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/devices/flutter-pi-setup_1.00.bb @@ -0,0 +1,6 @@ +LICENSE = "CLOSED" + +IMAGE_INSTALL:append = " flutter-pi flutter-elinux flutter-auto-launch flutter-libraries kernel-image kernel-devicetree liberation-fonts networkmanager dhcpcd iptables iw linux-firmware ca-certificates gstreamer1.0-rtsp-server gstreamer1.0 gstreamer1.0-plugins-base gstreamer1.0-plugins-good gstreamer1.0-plugins-bad gstreamer1.0-plugins-ugly gstreamer1.0-libav libinput libxkbcommon tzdata alsa-utils alsa-lib" + +# needed for gstreamer-plugins-ugly: +LICENSE_FLAGS_ACCEPTED = "commercial" \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/devices/pi0w2-setup_1.00.bb b/poky/meta-flutter-elinux/recipes-core/devices/pi0w2-setup_1.00.bb new file mode 100644 index 0000000..e3a933f --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/devices/pi0w2-setup_1.00.bb @@ -0,0 +1,15 @@ +LICENSE = "CLOSED" + +IMAGE_INSTALL:append = " linux-firmware-rpidistro-bcm43436s linux-firmware-bcm43455 bcm2835-dev" + +# meta-raspberry specific configuration for raspberry pi devices +DISABLE_OVERSCAN = "1" +DISABLE_SPLASH = "1" +GPU_MEM = "64" +DISABLE_RPI_BOOT_LOGO = "1" +ENABLE_SPI_BUS = "1" + +RPI_EXTRA_CONFIG = ' \n \ +dtparam=spi=on \n \ +dtparam=audio=on \n \ +' \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/devices/pi4-setup_1.00.bb b/poky/meta-flutter-elinux/recipes-core/devices/pi4-setup_1.00.bb new file mode 100644 index 0000000..b5a06c8 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/devices/pi4-setup_1.00.bb @@ -0,0 +1,15 @@ +LICENSE = "CLOSED" + +IMAGE_INSTALL:append = " linux-firmware-rpidistro-bcm43430 linux-firmware-bcm43455 bcm2835-dev" + +# meta-raspberry specific configuration for raspberry pi devices +DISABLE_OVERSCAN = "1" +DISABLE_SPLASH = "1" +GPU_MEM = "64" +DISABLE_RPI_BOOT_LOGO = "1" +ENABLE_SPI_BUS = "1" + +RPI_EXTRA_CONFIG = ' \n \ +dtparam=spi=on \n \ +dtparam=audio=on \n \ +' \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/flutter-elinux-auto/flutter-elinux-auto_1.00.bb b/poky/meta-flutter-elinux/recipes-core/flutter-elinux-auto/flutter-elinux-auto_1.00.bb new file mode 100644 index 0000000..a85ad4a --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/flutter-elinux-auto/flutter-elinux-auto_1.00.bb @@ -0,0 +1,15 @@ +SUMMARY = "" +DESCRIPTION = "" +LICENSE = "closed" + +FLUTTER_ELINUX_AUTOLAUNCH = "false" + +DEPENDS = "flutter-auto flutter-auto-launch ${@bb.utils.contains('FLUTTER_ELINUX_AUTOLAUNCH', 'true', 'flutter-auto-service', '', d)} flutter-elinux flutter-elinux-rules flutter-user" + + +# Installation task +do_install() { + # Since we only aim to install dependencies, there's + # nothing to install directly for this recipe itself. + : +} \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/flutter-elinux-auto/flutter-elinux-pi_1.00.bb b/poky/meta-flutter-elinux/recipes-core/flutter-elinux-auto/flutter-elinux-pi_1.00.bb new file mode 100644 index 0000000..0d44aa8 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/flutter-elinux-auto/flutter-elinux-pi_1.00.bb @@ -0,0 +1,15 @@ +SUMMARY = "" +DESCRIPTION = "" +LICENSE = "closed" + +FLUTTER_ELINUX_AUTOLAUNCH = "false" + +DEPENDS = "flutter-auto flutter-auto-launch ${@bb.utils.contains('FLUTTER_ELINUX_AUTOLAUNCH', 'true', 'flutter-auto-service', '', d)} flutter-elinux flutter-elinux-rules" + + +# Installation task +do_install() { + # Since we only aim to install dependencies, there's + # nothing to install directly for this recipe itself. + : +} \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/flutter-elinux-rules/files/90-interfaces.rules b/poky/meta-flutter-elinux/recipes-core/flutter-elinux-rules/files/90-interfaces.rules new file mode 100644 index 0000000..48f6cab --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/flutter-elinux-rules/files/90-interfaces.rules @@ -0,0 +1,12 @@ +SUBSYSTEM=="input", GROUP="input", MODE="0660" +SUBSYSTEM=="i2c-dev", GROUP="i2c", MODE="0660" +SUBSYSTEM=="spidev", GROUP="spi", MODE="0660" +SUBSYSTEM=="bcm2835-gpiomem", GROUP="gpio", MODE="0660" + +SUBSYSTEM=="gpio", GROUP="gpio", MODE="0660" +SUBSYSTEM=="gpio*", PROGRAM="/bin/sh -c '\ +chown -R root:gpio /sys/class/gpio && chmod -R 770 /sys/class/gpio;\ +chown -R root:gpio /sys/devices/virtual/gpio && chmod -R 770 +/sys/devices/virtual/gpio;\ +chown -R root:gpio /sys$devpath && chmod -R 770 /sys$devpath\ +'" \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/flutter-elinux-rules/flutter-elinux-rules_1.00.bb b/poky/meta-flutter-elinux/recipes-core/flutter-elinux-rules/flutter-elinux-rules_1.00.bb new file mode 100644 index 0000000..b5d4039 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/flutter-elinux-rules/flutter-elinux-rules_1.00.bb @@ -0,0 +1,11 @@ +LICENSE = "CLOSED" + +SRC_URI:append = " file://90-interfaces.rules" +FILES:${PN} += " /etc/udev/rules.d/90-interfaces.rules" + +do_install:append() { + install -d ${D}${sysconfdir}/udev/rules.d + install -m 0666 ${WORKDIR}/90-interfaces.rules ${D}/etc/udev/rules.d/90-interfaces.rules +} + +PROVIDES = "my-rules" \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/flutter-user/flutter-user_1.00.bb b/poky/meta-flutter-elinux/recipes-core/flutter-user/flutter-user_1.00.bb new file mode 100644 index 0000000..c53d188 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/flutter-user/flutter-user_1.00.bb @@ -0,0 +1,34 @@ +SUMMARY = "Example recipe for using inherit useradd" +DESCRIPTION = "This recipe serves as an example for using features from useradd.bbclass" +SECTION = "examples" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" + +S = "${WORKDIR}" + +EXCLUDE_FROM_WORLD = "1" + +inherit useradd + +USERADD_PACKAGES = "${PN}" + +GROUPADD_PARAM:${PN} = "gpio; spi" + +USERADD_PARAM:${PN} = "-d /home/user1 -G input,video,gpio,spi -r -s /bin/bash user1;" + +do_install () { + install -d -m 755 ${D}${datadir}/user1 + + chown -R user1 ${D}${datadir}/user1 + + install -d -m 711 ${D}/home/user1 + chown -R user1 ${D}/home/user1 + chgrp -R user1 ${D}/home/user1 +} + +FILES:${PN} = "${datadir}/user1/ /home/user1" + +# Prevents do_package failures with: +# debugsources.list: No such file or directory: +INHIBIT_PACKAGE_DEBUG_SPLIT = "1" + diff --git a/poky/meta-flutter-elinux/recipes-core/libraries/files/libflutter_pty.so b/poky/meta-flutter-elinux/recipes-core/libraries/files/libflutter_pty.so new file mode 100755 index 0000000..2a97ee5 Binary files /dev/null and b/poky/meta-flutter-elinux/recipes-core/libraries/files/libflutter_pty.so differ diff --git a/poky/meta-flutter-elinux/recipes-core/libraries/files/libperiphery_arm.so b/poky/meta-flutter-elinux/recipes-core/libraries/files/libperiphery_arm.so new file mode 100644 index 0000000..5940d6a Binary files /dev/null and b/poky/meta-flutter-elinux/recipes-core/libraries/files/libperiphery_arm.so differ diff --git a/poky/meta-flutter-elinux/recipes-core/libraries/files/libperiphery_arm64.so b/poky/meta-flutter-elinux/recipes-core/libraries/files/libperiphery_arm64.so new file mode 100644 index 0000000..5b7e0f3 Binary files /dev/null and b/poky/meta-flutter-elinux/recipes-core/libraries/files/libperiphery_arm64.so differ diff --git a/poky/meta-flutter-elinux/recipes-core/libraries/flutter-libraries_1.00.bb b/poky/meta-flutter-elinux/recipes-core/libraries/flutter-libraries_1.00.bb new file mode 100644 index 0000000..8bdac3b --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/libraries/flutter-libraries_1.00.bb @@ -0,0 +1,18 @@ +DESCRIPTION = "My custom libraries" +LICENSE = "CLOSED" + +SRC_URI = " \ + file://libperiphery_arm64.so \ + file://libflutter_pty.so \ + " + +do_install() { + install -d ${D}/${libdir}/flutter + install -m 0644 ${WORKDIR}/libperiphery_arm64.so ${D}/${libdir}/flutter + install -m 0644 ${WORKDIR}/libflutter_pty.so ${D}/${libdir}/flutter + + ln -sf ${libdir}/flutter/libperiphery_arm64.so ${D}${libdir} + ln -sf ${libdir}/flutter/libflutter_pty.so ${D}${libdir} +} + +FILES:${PN} += "${libdir}/flutter/*.so" \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/systemd-conf/files/en.network b/poky/meta-flutter-elinux/recipes-core/systemd-conf/files/en.network new file mode 100644 index 0000000..b7f5a9a --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/systemd-conf/files/en.network @@ -0,0 +1,10 @@ +[Match] +Name=en* +KernelCommandLine=!nfsroot + +[Network] +DHCP=v4 + +[DHCPv4] +UseHostname=false +EOF \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/systemd-conf/files/eth.network b/poky/meta-flutter-elinux/recipes-core/systemd-conf/files/eth.network new file mode 100644 index 0000000..0fd54f6 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/systemd-conf/files/eth.network @@ -0,0 +1,10 @@ +[Match] +Name=eth* +KernelCommandLine=!nfsroot + +[Network] +DHCP=v4 + +[DHCPv4] +UseHostname=false +EOF \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/systemd-conf/files/wlan.network b/poky/meta-flutter-elinux/recipes-core/systemd-conf/files/wlan.network new file mode 100644 index 0000000..38f8a05 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/systemd-conf/files/wlan.network @@ -0,0 +1,10 @@ +[Match] +Name=wlan* +KernelCommandLine=!nfsroot + +[Network] +DHCP=v4 + +[DHCPv4] +UseHostname=false +EOF \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/systemd-conf/systemd-conf_%.bbappend b/poky/meta-flutter-elinux/recipes-core/systemd-conf/systemd-conf_%.bbappend new file mode 100644 index 0000000..4ff3bc2 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/systemd-conf/systemd-conf_%.bbappend @@ -0,0 +1,20 @@ +FILESEXTRAPATHS:prepend := "${THISDIR}/files:" + +SRC_URI += " \ + file://eth.network \ + file://en.network \ + file://wlan.network \ +" + +FILES:${PN} += " \ + ${sysconfdir}/systemd/network/eth.network \ + ${sysconfdir}/systemd/network/en.network \ + ${sysconfdir}/systemd/network/wlan.network \ +" + +do_install:append() { + install -d ${D}${sysconfdir}/systemd/network + install -m 0644 ${WORKDIR}/eth.network ${D}${sysconfdir}/systemd/network + install -m 0644 ${WORKDIR}/en.network ${D}${sysconfdir}/systemd/network + install -m 0644 ${WORKDIR}/wlan.network ${D}${sysconfdir}/systemd/network +} \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/systemd/files/flutter-auto.service b/poky/meta-flutter-elinux/recipes-core/systemd/files/flutter-auto.service new file mode 100644 index 0000000..f7f876f --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/systemd/files/flutter-auto.service @@ -0,0 +1,44 @@ +[Unit] +Description=Flutter App Service +After=network.target +StartLimitIntervalSec=0 + +Requires=systemd-user-sessions.service +After=systemd-user-sessions.service + +After=plymouth-quit-wait.service + +Wants=dbus.socket +After=dbus.socket + +Before=graphical.target + +ConditionPathExists=/dev/tty0 + +[Service] +Type=simple +Restart=always +RestartSec=1 +ExecStart=/usr/bin/cage /usr/local/bin/flutter-auto-launch + +User=user1 +Group=user1 + +WorkingDirectory=/home/user1 + +PAMName=login + +TTYPath=/dev/tty7 +TTYReset=yes +TTYVHangup=yes +TTYTDisallocate=yes + +StandardInput=tty-fail +StandardOutput=journal +StandardError=journal + +UtmpIdentifier=tty7 +UtmpMode=user + +[Install] +WantedBy=multi-user.target \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/systemd/files/flutter-pi.service b/poky/meta-flutter-elinux/recipes-core/systemd/files/flutter-pi.service new file mode 100644 index 0000000..9bc4b50 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/systemd/files/flutter-pi.service @@ -0,0 +1,44 @@ +[Unit] +Description=Flutter App Service +After=network.target +StartLimitIntervalSec=0 + +Requires=systemd-user-sessions.service +After=systemd-user-sessions.service + +After=plymouth-quit-wait.service + +Wants=dbus.socket +After=dbus.socket + +Before=graphical.target + +ConditionPathExists=/dev/tty0 + +[Service] +Type=simple +Restart=always +RestartSec=1 +ExecStart=/usr/bin/flutter-pi --release /flutter/flutter_elinux/3.19.2/release + +User=user1 +Group=user1 + +WorkingDirectory=/home/user1 + +PAMName=login + +TTYPath=/dev/tty7 +TTYReset=yes +TTYVHangup=yes +TTYTDisallocate=yes + +StandardInput=tty-fail +StandardOutput=journal +StandardError=journal + +UtmpIdentifier=tty7 +UtmpMode=user + +[Install] +WantedBy=multi-user.target \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/systemd/flutter-auto-service_1.00.bb b/poky/meta-flutter-elinux/recipes-core/systemd/flutter-auto-service_1.00.bb new file mode 100644 index 0000000..b527004 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/systemd/flutter-auto-service_1.00.bb @@ -0,0 +1,13 @@ +LICENSE = "CLOSED" +inherit systemd + +SYSTEMD_AUTO_ENABLE = "enable" +SYSTEMD_SERVICE:${PN} = "flutter-auto.service" + +SRC_URI:append = " file://flutter-auto.service " +FILES:${PN} += "${systemd_unitdir}/system/flutter-auto.service" + +do_install:append() { + install -d ${D}/${systemd_unitdir}/system + install -m 0644 ${WORKDIR}/flutter-auto.service ${D}/${systemd_unitdir}/system +} \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/systemd/flutter-pi-service_1.00.bb b/poky/meta-flutter-elinux/recipes-core/systemd/flutter-pi-service_1.00.bb new file mode 100644 index 0000000..afe5799 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/systemd/flutter-pi-service_1.00.bb @@ -0,0 +1,13 @@ +LICENSE = "CLOSED" +inherit systemd + +SYSTEMD_AUTO_ENABLE = "enable" +SYSTEMD_SERVICE:${PN} = "flutter-pi.service" + +SRC_URI:append = " file://flutter-pi.service " +FILES:${PN} += "${systemd_unitdir}/system/flutter-pi.service" + +do_install:append() { + install -d ${D}/${systemd_unitdir}/system + install -m 0644 ${WORKDIR}/flutter-pi.service ${D}/${systemd_unitdir}/system +} \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-core/systemd/systemd_%.bbappend b/poky/meta-flutter-elinux/recipes-core/systemd/systemd_%.bbappend new file mode 100644 index 0000000..54f2c33 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-core/systemd/systemd_%.bbappend @@ -0,0 +1,2 @@ +PACKAGECONFIG:append = " networkd resolved" +RDEPENDS:${PN}:append = " wpa-supplicant " \ No newline at end of file diff --git a/poky/meta-flutter-elinux/recipes-extended/sudo_%.bbappend b/poky/meta-flutter-elinux/recipes-extended/sudo_%.bbappend new file mode 100644 index 0000000..8d3cb50 --- /dev/null +++ b/poky/meta-flutter-elinux/recipes-extended/sudo_%.bbappend @@ -0,0 +1,11 @@ +AUTHORIZED_USER_NAME ?= "user1" + +do_install_append () { + # Add sudo accesses for user. + install -d -m 0710 "${D}/etc/sudoers.d" + echo "${AUTHORIZED_USER_NAME} ALL=(ALL) NOPASSWD: /sbin/shutdown" > "${D}/etc/sudoers.d/0001_${AUTHORIZED_USER_NAME}" + chmod 0644 "${D}/etc/sudoers.d/0001_${AUTHORIZED_USER_NAME}" +} + +FILES_${PN} += "/etc/sudoers.d \ + /etc/sudoers.d/0001_${AUTHORIZED_USER_NAME}" \ No newline at end of file