summaryrefslogtreecommitdiffstats
path: root/meta/recipes-graphics/wayland/weston-init/weston-start
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-graphics/wayland/weston-init/weston-start')
-rwxr-xr-xmeta/recipes-graphics/wayland/weston-init/weston-start26
1 files changed, 26 insertions, 0 deletions
diff --git a/meta/recipes-graphics/wayland/weston-init/weston-start b/meta/recipes-graphics/wayland/weston-init/weston-start
index dc2b1efc78..4aa7c66d3b 100755
--- a/meta/recipes-graphics/wayland/weston-init/weston-start
+++ b/meta/recipes-graphics/wayland/weston-init/weston-start
@@ -9,6 +9,19 @@ usage() {
9EOF 9EOF
10} 10}
11 11
12## Module support
13modules_dir=@DATADIR@/weston-start
14
15# Add weston extra argument
16add_weston_argument() {
17 weston_args="$weston_args $1"
18}
19
20# Add openvt extra argument
21add_openvt_argument() {
22 openvt_args="$openvt_args $1"
23}
24
12if test $# -lt 2; then 25if test $# -lt 2; then
13 usage 26 usage
14 exit 1 27 exit 1
@@ -32,6 +45,19 @@ done
32 45
33weston_args=$* 46weston_args=$*
34 47
48# Load and run modules
49if [ -d "$modules_dir" ]; then
50 for m in "$modules_dir"/*; do
51 # Skip backup files
52 if [ "`echo $m | sed -e 's/\~$//'`" != "$m" ]; then
53 continue
54 fi
55
56 # process module
57 . $m
58 done
59fi
60
35if test -z "$XDG_RUNTIME_DIR"; then 61if test -z "$XDG_RUNTIME_DIR"; then
36 export XDG_RUNTIME_DIR=/run/user/`id -u` 62 export XDG_RUNTIME_DIR=/run/user/`id -u`
37 mkdir --parents $XDG_RUNTIME_DIR 63 mkdir --parents $XDG_RUNTIME_DIR