weston-init: support system's configuration file

Look for OPTARGS variable in /etc/default/weston
and set it as weston's service default options.

This can be used to force system's supported backend.

Change-Id: I0562c9326df5b46226093199873ef58d77aeae75
(From OE-Core rev: 8ffcdcc53bac64c62478fbb72d817c842dde8b28)

Signed-off-by: Philippe Coval <philippe.coval@open.eurogiciel.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Philippe Coval 2015-05-08 15:56:40 +02:00 committed by Richard Purdie
parent 54870dcddd
commit 5179d7cd6e
1 changed files with 5 additions and 1 deletions

View File

@ -8,6 +8,10 @@
# Default-Stop: 0 1 6
### END INIT INFO
if test -e /etc/default/weston ; then
. /etc/default/weston
fi
killproc() {
pid=`/bin/pidof $1`
[ "$pid" != "" ] && kill $pid
@ -34,7 +38,7 @@ case "$1" in
chmod 0700 $XDG_RUNTIME_DIR
fi
openvt -s weston
openvt -s weston -- $OPTARGS
;;
stop)