Skip to contentSkip to conversation

brltty: new package

PATCH New Mario Lang 2 participants 2 messages Nov 27, 2017 – Dec 17, 2017

lore
Share & tools
lore

Mario Lang

author
#0 lore raw

PATCH v3 1/1 brltty: new package

---
v2 dealt with feedback from Baruch Siach (thanks).
v3: Adds optional dependencies on icu, ncurses and systemd.
Supports NLS.
Adds an option to configure default fallback text table.

 DEVELOPERS                    |  3 ++
 package/Config.in             |  1 +
 package/brltty/Config.in      | 19 +++++++++++
 package/brltty/S10brltty      | 40 +++++++++++++++++++++++
 package/brltty/brltty.hash    |  3 ++
 package/brltty/brltty.mk      | 76 +++++++++++++++++++++++++++++++++++++++++++
 package/brltty/brltty.service | 23 +++++++++++++
 7 files changed, 165 insertions(+)
 create mode 100644 package/brltty/Config.in
 create mode 100644 package/brltty/S10brltty
 create mode 100644 package/brltty/brltty.hash
 create mode 100644 package/brltty/brltty.mk
 create mode 100644 package/brltty/brltty.service
DEVELOPERS +3 -0
index 40123bc38d..f78e303a2a 100644
@@ -1024,6 +1024,9 @@ F:	package/polkit/
 F:	package/sg3_utils/
 F:	package/udisks/
 
+N:	Mario Lang <[email protected]>
+F:	package/brltty/
+
 N:	Mario Rugiero <[email protected]>
 F:	package/ratpoison/
 
package/Config.in +1 -0
index fa6bc19543..73eb3c4d6c 100644
@@ -381,6 +381,7 @@ endmenu
 	source "package/avrdude/Config.in"
 	source "package/bcache-tools/Config.in"
 	source "package/biosdevname/Config.in"
+	source "package/brltty/Config.in"
 	source "package/cbootimage/Config.in"
 	source "package/cc-tool/Config.in"
 	source "package/cdrkit/Config.in"
package/brltty/Config.in new file +19 -0
new file mode 100644
index 0000000000..7c47ea8f9b
@@ -0,0 +1,19 @@
+config BR2_PACKAGE_BRLTTY
+	bool "brltty"
+	depends on BR2_USE_WCHAR
+	depends on BR2_TOOLCHAIN_HAS_THREADS
+	help
+	  A daemon providing access to the Linux console
+	  for a blind person using a refreshable braille display.
+
+	  http://brltty.com/
+
+comment "brltty needs a toolchain w/ threads, wchar"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || !BR2_USE_WCHAR
+
+if BR2_PACKAGE_BRLTTY
+
+config BR2_PACKAGE_BRLTTY_TEXT_TABLE
+	string "text-table"
+
+endif
package/brltty/S10brltty new file +40 -0
new file mode 100644
index 0000000000..18e274dc0f
@@ -0,0 +1,40 @@
+#!/bin/sh
+#
+# brltty        Starts brltty.
+#
+
+start() {
+	printf "Starting brltty: "
+	start-stop-daemon -S -q -p /var/run/brltty.pid \
+		--exec /usr/bin/brltty -- -P /var/run/brltty.pid "$@"
+	[ $? = 0 ] && echo "OK" || echo "FAIL"
+}
+stop() {
+	printf "Stopping brltty: "
+	start-stop-daemon -K -q -p /var/run/brltty.pid
+	[ $? = 0 ] && echo "OK" || echo "FAIL"
+}
+restart() {
+	stop
+	start "$@"
+}
+
+case "$1" in
+  start)
+	start
+	;;
+  stop)
+	stop
+	;;
+  restart|reload)
+	restart
+	;;
+  force-reload)
+	restart
+	;;
+  *)
+	echo "Usage: $0 {start|stop|restart|force-reload}"
+	exit 1
+esac
+
+exit $?
package/brltty/brltty.hash new file +3 -0
new file mode 100644
index 0000000000..3bc2f9cf54
@@ -0,0 +1,3 @@
+sha256 4ebf1df5922df0efccac4795f5bd1c514fc850348c34d9ec0868e2798b565a36 brltty-5.5.tar.xz
+sha256 91df39d1816bfb17a4dda2d3d2c83b1f6f2d38d53e53e41e8f97ad5ac46a0cad LICENSE-GPL
+sha256 d80c9d084ebfb50ea1ed91bfbc2410d6ce542097a32c43b00781b83adcb8c77f LICENSE-LGPL
package/brltty/brltty.mk new file +76 -0

76 lines not on this page · raw message

package/brltty/brltty.service new file +23 -0
new file mode 100644
index 0000000000..070ec94b7c
@@ -0,0 +1,23 @@
+[Unit]
+Description=Braille Device Support
+Documentation=man:brltty(1)
+Documentation=http://brltty.com/
+
+DefaultDependencies=no
+Before=sysinit.target
+After=systemd-udev-settle.service
+Wants=systemd-udev-settle.service
+
+[Service]
+Type=simple
+ExecStart=/usr/bin/brltty --no-daemon
+TimeoutStartSec=5
+TimeoutStopSec=10
+Restart=always
+RestartSec=30
+Nice=-10
+OOMScoreAdjust=-900
+
+[Install]
+WantedBy=sysinit.target
+
Signature · 1 line
2.15.0
#1 lore raw

PATCH v3 1/1 brltty: new package

Hello,

Quoted 6 lines · Mario Lang

---
v2 dealt with feedback from Baruch Siach (thanks).
v3: Adds optional dependencies on icu, ncurses and systemd.
Supports NLS.
Adds an option to configure default fallback text table.

Applied to master with the following changes:

[Thomas:
- wrap too long CONF_OPTS line that disables all the language bindings
- use an intermediate BRLTTY_TEXT_TABLE variable to store the qstripped version of BR2_PACKAGE_BRLTTY_TEXT_TABLE.]

Thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com