diff options
author | Brian Bidulock | 2017-06-26 04:52:23 -0600 |
---|---|---|
committer | Brian Bidulock | 2017-06-26 04:52:23 -0600 |
commit | 5b2903cfbc149f3c197db8ed813dce3c4e7fdeec (patch) | |
tree | c20eec033a907282c1dea15fb78c498e2916647c | |
download | aur-5b2903cfbc149f3c197db8ed813dce3c4e7fdeec.tar.gz |
initial version
-rw-r--r-- | .SRCINFO | 15 | ||||
-rw-r--r-- | PKGBUILD | 17 | ||||
-rw-r--r-- | fbcon.hook | 10 | ||||
-rw-r--r-- | fbcon.install | 17 |
4 files changed, 59 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..3220151288eb --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,15 @@ +pkgbase = mkinitcpio-fbcon + pkgdesc = A hook to rotate the console at startup. + pkgver = 1.0 + pkgrel = 1 + url = http://www.archlinux.org/ + arch = any + license = GPL + depends = bash + source = fbcon.hook + source = fbcon.install + md5sums = c03097e0e22d539b58476e67a8cea1d9 + md5sums = 40d8ecd9880d72cd515c446be033f0fd + +pkgname = mkinitcpio-fbcon + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..34a8e68ed7bb --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,17 @@ +# Maintainer: Brian Bidulock <bidulock@openss7.org> +pkgname=mkinitcpio-fbcon +pkgver=1.0 +pkgrel=1 +pkgdesc="A hook to rotate the console at startup." +arch=('any') +url="http://www.archlinux.org/" +license=('GPL') +depends=('bash') +source=(fbcon.hook fbcon.install) +md5sums=('c03097e0e22d539b58476e67a8cea1d9' + '40d8ecd9880d72cd515c446be033f0fd') + +package() { + install -Dm644 fbcon.install "$pkgdir/usr/lib/initcpio/install/fbcon" + install -Dm644 fbcon.hook "$pkgdir/usr/lib/initcpio/hooks/fbcon" +} diff --git a/fbcon.hook b/fbcon.hook new file mode 100644 index 000000000000..53a54f15ba5a --- /dev/null +++ b/fbcon.hook @@ -0,0 +1,10 @@ +#!/usr/bin/ash + +run_hook() { + if [ -z "${rotate_all}" ] || ! [ "${rotate_all}" -ge 0 -a "${rotate_all}" -le 3 ]; then + rotate_all=0 + fi + echo "${rotate_all}" >/sys/class/graphics/fbcon/rotate_all || : +} + +# vim: set ft=sh ts=4 sw=4 et: diff --git a/fbcon.install b/fbcon.install new file mode 100644 index 000000000000..a38d0114274c --- /dev/null +++ b/fbcon.install @@ -0,0 +1,17 @@ +#!/bin/bash + +build() { + add_runscript +} + +help() { + cat <<HELPEOF +This hook causes the init process to write a number to rotate all frame-buffer +consoles by the specified amount: 0, none; 1, right; 2, invert; 3, left. The +default is none(0). If a rotate_all= command line parameter is specified, the +value of the parameter is used for the rotation. This is because kernel-magic +associated with this function does not work. +HELPEOF +} + +# vim: set ft=sh ts=4 sw=4 et: |