main/postmarketos-ui-buffyboard: new aport (MR 6127)
[ci:skip-build] Already built fine in the CI once
This commit is contained in:
parent
84b19f67f3
commit
0337bb4b35
8 changed files with 115 additions and 0 deletions
43
main/postmarketos-ui-buffyboard/APKBUILD
Normal file
43
main/postmarketos-ui-buffyboard/APKBUILD
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
# Reference: https://postmarketos.org/uipkg
|
||||
# Based On: postmarketos-ui-fbkeyboard
|
||||
pkgname=postmarketos-ui-buffyboard
|
||||
pkgver=1
|
||||
pkgrel=0
|
||||
pkgdesc="Plain framebuffer console with modern touchscreen keyboard support"
|
||||
url="https://gitlab.postmarketos.org/postmarketOS/buffybox"
|
||||
arch="all"
|
||||
license="GPL-3.0-or-later"
|
||||
depends="
|
||||
dnsmasq
|
||||
buffyboard
|
||||
postmarketos-base-ui
|
||||
postmarketos-base-ui-networkmanager
|
||||
"
|
||||
subpackages="$pkgname-openrc $pkgname-systemd"
|
||||
source="buffyboard.init buffyboard.service"
|
||||
options="!check" # No tests
|
||||
|
||||
package() {
|
||||
install -Dm755 "$srcdir"/buffyboard.init "$pkgdir"/etc/init.d/buffyboard
|
||||
install -Dm644 "$srcdir"/buffyboard.service -t "$pkgdir"/usr/lib/systemd/system
|
||||
}
|
||||
|
||||
openrc() {
|
||||
install_if="$pkgname=$pkgver-r$pkgrel openrc"
|
||||
install="$subpkgname.post-install $subpkgname.pre-deinstall $subpkgname.post-upgrade"
|
||||
depends="
|
||||
networkmanager-openrc
|
||||
"
|
||||
|
||||
mkdir -p "$subpkgdir"
|
||||
}
|
||||
|
||||
systemd() {
|
||||
install="$subpkgname.post-install $subpkgname.pre-deinstall"
|
||||
default_systemd
|
||||
}
|
||||
|
||||
sha512sums="
|
||||
81178d6f86dbe24c8ddfd0c1c29504f12941232f11124d21aedde54d2a82c34e03fba8e82e5bbc285d94e216e812763291787e086b51e8eb258562714e4dadcd buffyboard.init
|
||||
0bf529465d5d882e64f1804c0a809bc38c1fbadaf52b276848708c761d53014c8d302c2573200d2f831090d6833abc6da6f89f28e9b309dc63f9ca10d148b4b2 buffyboard.service
|
||||
"
|
||||
25
main/postmarketos-ui-buffyboard/buffyboard.init
Normal file
25
main/postmarketos-ui-buffyboard/buffyboard.init
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
#!/sbin/openrc-run
|
||||
|
||||
name="buffyboard"
|
||||
command="/usr/bin/buffyboard"
|
||||
pidfile="/var/run/buffyboard.pid"
|
||||
command_background=true
|
||||
|
||||
depend()
|
||||
{
|
||||
after consolefont
|
||||
keyword -docker -lxc -openvz -prefix -systemd-nspawn -uml -vserver -xenu
|
||||
}
|
||||
|
||||
start_pre()
|
||||
{
|
||||
# Setup kernel support for user level drivers (input subsystem)
|
||||
if [ ! -e /dev/uinput ]; then
|
||||
if ! modprobe -q uinput; then
|
||||
eerror "The uinput module needs to be loaded by " \
|
||||
"the buffyboard service or built in."
|
||||
fi
|
||||
fi
|
||||
# save energy
|
||||
echo 0 >/sys/class/graphics/fbcon/cursor_blink
|
||||
}
|
||||
16
main/postmarketos-ui-buffyboard/buffyboard.service
Normal file
16
main/postmarketos-ui-buffyboard/buffyboard.service
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
[Unit]
|
||||
Description=Buffyboard UI service
|
||||
ConditionPathExists=/dev/tty0
|
||||
After=getty@tty1.service
|
||||
|
||||
[Service]
|
||||
Type=exec
|
||||
ExecStart=/usr/bin/buffyboard
|
||||
ExecStartPre=-modprobe uinput
|
||||
ExecStartPre=-/bin/sh -c "echo 0 > /sys/class/graphics/fbcon/cursor_blink"
|
||||
Restart=always
|
||||
RestartSec=1s
|
||||
PIDFile=/run/buffyboard.pid
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
#!/bin/sh
|
||||
|
||||
rc-update add buffyboard default
|
||||
rc-update add networkmanager default
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
#!/bin/sh
|
||||
|
||||
rc-update add buffyboard default
|
||||
rc-update add networkmanager default
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
#!/bin/sh
|
||||
|
||||
rc-update del buffyboard
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
#!/bin/sh
|
||||
|
||||
# This file is forcefully included into CI shellcheck by:
|
||||
# $(find . -path './main/postmarketos-ui-*/*.post-install')
|
||||
# in .ci/shellcheck.sh. Silence it here to avoid error:
|
||||
# SC1091 (info): Not following: /usr/lib/systemd/systemd-apk-macros.sh:
|
||||
# openBinaryFile: does not exist (No such file or directory)
|
||||
# shellcheck disable=SC1091
|
||||
. /usr/lib/systemd/systemd-apk-macros.sh
|
||||
systemd_service_post_install system buffyboard
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
#!/bin/sh
|
||||
|
||||
# This file is forcefully included into CI shellcheck by:
|
||||
# $(find . -path './main/postmarketos-ui-*/*.pre-deinstall')
|
||||
# in .ci/shellcheck.sh. Silence it here to avoid error:
|
||||
# SC1091 (info): Not following: /usr/lib/systemd/systemd-apk-macros.sh:
|
||||
# openBinaryFile: does not exist (No such file or directory)
|
||||
# shellcheck disable=SC1091
|
||||
. /usr/lib/systemd/systemd-apk-macros.sh
|
||||
systemd_service_pre_deinstall system buffyboard
|
||||
Loading…
Add table
Add a link
Reference in a new issue