Updated modello script and configuration for weston 39/33439/1
authorImran Zaman <imran.zaman@intel.com>
Fri, 9 Jan 2015 13:45:39 +0000 (15:45 +0200)
committerImran Zaman <imran.zaman@intel.com>
Fri, 9 Jan 2015 13:46:00 +0000 (15:46 +0200)
Change-Id: Ia0cae21028637c8cd88c343b4d557bed5adf34ac
Signed-off-by: Imran Zaman <imran.zaman@intel.com>
18 files changed:
data/tizen-ivi/etc/session.d/genivi-session-modello [new file with mode: 0755]
data/tizen-ivi/etc/session.d/genivi-session-multiseat
data/tizen-ivi/etc/session.d/genivi-session-singleseat
data/tizen-ivi/etc/tlm-singleseat-modello.conf
data/tizen-ivi/etc/xdg/weston/weston-genivi-modello.ini [new file with mode: 0644]
data/tizen-ivi/etc/xdg/weston/weston-genivi-vtc1010.ini [new file with mode: 0644]
data/tizen-ivi/etc/xdg/weston/weston-genivi.ini [new file with mode: 0644]
data/tizen-ivi/etc/xdg/weston/weston-user-modello.ini [new file with mode: 0644]
data/tizen-ivi/etc/xdg/weston/weston-user.ini [new file with mode: 0644]
data/tizen-ivi/weston-genivi-vtc1010.ini [deleted file]
data/tizen-ivi/weston-genivi.ini [deleted file]
data/tizen-ivi/weston-user-modello.ini [deleted file]
data/tizen-ivi/weston-user.ini [deleted file]
dists/rpm/tizen/packaging/tlm.spec
packaging/tlm.spec
src/daemon/tlm-main.c
src/sessiond/main.c
src/sessiond/tlm-session.c

diff --git a/data/tizen-ivi/etc/session.d/genivi-session-modello b/data/tizen-ivi/etc/session.d/genivi-session-modello
new file mode 100755 (executable)
index 0000000..eb8b009
--- /dev/null
@@ -0,0 +1,9 @@
+#!/bin/sh
+#
+#WESTON_LAUNCH=/usr/bin/tlm-weston-launch
+WESTON_LAUNCH=weston-launch
+export WAYLAND_SERVER_DIR=/tmp
+export WAYLAND_SERVER_GROUP=weston-launch
+export WAYLAND_SERVER_MODE=0660
+export WESTON_CONFIG=/etc/xdg/weston/weston-genivi-modello.ini
+$WESTON_LAUNCH -- -i0 --log=/tmp/genivi-weston.log
index 4d75a62bdd0512debbad32cde3fa5e68275e4998..4d97f529e366cfe81ef550a81ae866dbc55c1744 100755 (executable)
@@ -6,4 +6,4 @@ export WAYLAND_SERVER_DIR=/tmp
 export WAYLAND_SERVER_GROUP=weston-launch
 export WAYLAND_SERVER_MODE=0660
 export WESTON_CONFIG=/etc/xdg/weston/weston-genivi.ini
-$WESTON_LAUNCH -- -i0 --current-mode --log=/tmp/genivi-weston.log --shell=desktop-shell.so
+$WESTON_LAUNCH -- -i0 --log=/tmp/genivi-weston.log --shell=desktop-shell.so
index 2adafdd2004182eb0ecade9e556b888881c76bb4..440edbee4de056c67c1bd6f3f228cf262d2b8706 100755 (executable)
@@ -6,4 +6,4 @@ export WAYLAND_SERVER_DIR=/tmp
 export WAYLAND_SERVER_GROUP=weston-launch
 export WAYLAND_SERVER_MODE=0660
 export WESTON_CONFIG=/etc/xdg/weston/weston-genivi.ini
-$WESTON_LAUNCH -- -i0 --current-mode --log=/tmp/genivi-weston.log
+$WESTON_LAUNCH -- -i0 --log=/tmp/genivi-weston.log
index 52963820194cdbd22e2cdbf811665090ddba29e9..0369ae77d2ce3d707bd44f2b9ef6025383b3e944 100644 (file)
@@ -63,7 +63,7 @@ NSEATS=2
 DEFAULT_USER=genivi
 SETUP_TERMINAL=1
 VTNR=7
-SESSION_CMD=/etc/session.d/genivi-session-singleseat
+SESSION_CMD=/etc/session.d/genivi-session-modello
 DEFAULT_PAM_SERVICE=tlm-system-login
 SETUP_RUNTIME_DIR=1
 #
diff --git a/data/tizen-ivi/etc/xdg/weston/weston-genivi-modello.ini b/data/tizen-ivi/etc/xdg/weston/weston-genivi-modello.ini
new file mode 100644 (file)
index 0000000..8d0acfa
--- /dev/null
@@ -0,0 +1,42 @@
+[core]
+#modules=cms-colord.so
+shell=fullscreen-shell.so
+
+[shell]
+background-image=/usr/share/backgrounds/gnome/Aqua.jpg
+background-color=0xff248bd1
+background-type=tile
+panel-color=0xff2a3c4a
+locking=true
+animation=zoom
+startup-animation=fade
+
+[output]
+name=VGA1
+mode=off
+
+[output]
+name=DP1
+mode=1280x720@60.0
+transform=90
+
+#[output]
+#name=LVDS1
+#mode=1680x1050
+#transform=90
+#icc_profile=/usr/share/color/icc/colord/Bluish.icc
+
+#[output]
+#name=VGA1
+#mode=173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
+#transform=flipped
+
+#[output]
+#name=X1
+#mode=1024x768
+#transform=flipped-270
+
+#[touchpad]
+#constant_accel_factor = 50
+#min_accel_factor = 0.16
+#max_accel_factor = 1.0
diff --git a/data/tizen-ivi/etc/xdg/weston/weston-genivi-vtc1010.ini b/data/tizen-ivi/etc/xdg/weston/weston-genivi-vtc1010.ini
new file mode 100644 (file)
index 0000000..8e17529
--- /dev/null
@@ -0,0 +1,41 @@
+[core]
+#modules=cms-colord.so
+shell=fullscreen-shell.so
+
+[shell]
+background-image=/usr/share/backgrounds/gnome/Aqua.jpg
+background-color=0xff248bd1
+background-type=tile
+panel-color=0xff2a3c4a
+locking=true
+animation=zoom
+startup-animation=fade
+
+[output]
+name=VGA1
+seat=seat1
+
+[output]
+name=DP1
+seat=seat2
+
+#[output]
+#name=LVDS1
+#mode=1680x1050
+#transform=90
+#icc_profile=/usr/share/color/icc/colord/Bluish.icc
+
+#[output]
+#name=VGA1
+#mode=173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
+#transform=flipped
+
+#[output]
+#name=X1
+#mode=1024x768
+#transform=flipped-270
+
+#[touchpad]
+#constant_accel_factor = 50
+#min_accel_factor = 0.16
+#max_accel_factor = 1.0
diff --git a/data/tizen-ivi/etc/xdg/weston/weston-genivi.ini b/data/tizen-ivi/etc/xdg/weston/weston-genivi.ini
new file mode 100644 (file)
index 0000000..bd39824
--- /dev/null
@@ -0,0 +1,33 @@
+[core]
+#modules=cms-colord.so
+shell=fullscreen-shell.so
+
+[shell]
+background-image=/usr/share/backgrounds/gnome/Aqua.jpg
+background-color=0xff248bd1
+background-type=tile
+panel-color=0xff2a3c4a
+locking=true
+animation=zoom
+startup-animation=fade
+
+#[output]
+#name=LVDS1
+#mode=1680x1050
+#transform=90
+#icc_profile=/usr/share/color/icc/colord/Bluish.icc
+
+#[output]
+#name=VGA1
+#mode=173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
+#transform=flipped
+
+#[output]
+#name=X1
+#mode=1024x768
+#transform=flipped-270
+
+#[touchpad]
+#constant_accel_factor = 50
+#min_accel_factor = 0.16
+#max_accel_factor = 1.0
diff --git a/data/tizen-ivi/etc/xdg/weston/weston-user-modello.ini b/data/tizen-ivi/etc/xdg/weston/weston-user-modello.ini
new file mode 100644 (file)
index 0000000..5ea66f3
--- /dev/null
@@ -0,0 +1,46 @@
+[core]
+#modules=cms-colord.so
+#shell=desktop-shell.so
+
+[shell]
+background-image=/usr/share/backgrounds/gnome/Aqua.jpg
+background-color=0xff248bd1
+background-type=tile
+panel-color=0xff2a3c4a
+locking=true
+animation=zoom
+startup-animation=fade
+panel-location=none
+
+[input-method]
+path=/bin/weekeyboard
+
+[keyboard]
+keymap_layout=wkb
+
+#[output]
+#name=LVDS1
+#mode=1680x1050
+#transform=90
+#icc_profile=/usr/share/color/icc/colord/Bluish.icc
+
+#[output]
+#name=VGA1
+#mode=173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
+#transform=flipped
+
+#[output]
+#name=X1
+#mode=1024x768
+#transform=flipped-270
+
+#[touchpad]
+#constant_accel_factor = 50
+#min_accel_factor = 0.16
+#max_accel_factor = 1.0
+
+#[output]
+#name=DP1
+#mode=1280x720@60
+#transform=90
+
diff --git a/data/tizen-ivi/etc/xdg/weston/weston-user.ini b/data/tizen-ivi/etc/xdg/weston/weston-user.ini
new file mode 100644 (file)
index 0000000..09ad156
--- /dev/null
@@ -0,0 +1,39 @@
+[core]
+#modules=cms-colord.so
+#shell=fullscreen-shell.so
+
+[shell]
+background-image=/usr/share/backgrounds/gnome/Aqua.jpg
+background-color=0xff248bd1
+background-type=tile
+panel-color=0xff2a3c4a
+locking=true
+animation=zoom
+startup-animation=fade
+
+[input-method]
+path=/bin/weekeyboard
+
+[keyboard]
+keymap_layout=wkb
+
+#[output]
+#name=LVDS1
+#mode=1680x1050
+#transform=90
+#icc_profile=/usr/share/color/icc/colord/Bluish.icc
+
+#[output]
+#name=VGA1
+#mode=173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
+#transform=flipped
+
+#[output]
+#name=X1
+#mode=1024x768
+#transform=flipped-270
+
+#[touchpad]
+#constant_accel_factor = 50
+#min_accel_factor = 0.16
+#max_accel_factor = 1.0
diff --git a/data/tizen-ivi/weston-genivi-vtc1010.ini b/data/tizen-ivi/weston-genivi-vtc1010.ini
deleted file mode 100644 (file)
index 8e17529..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-[core]
-#modules=cms-colord.so
-shell=fullscreen-shell.so
-
-[shell]
-background-image=/usr/share/backgrounds/gnome/Aqua.jpg
-background-color=0xff248bd1
-background-type=tile
-panel-color=0xff2a3c4a
-locking=true
-animation=zoom
-startup-animation=fade
-
-[output]
-name=VGA1
-seat=seat1
-
-[output]
-name=DP1
-seat=seat2
-
-#[output]
-#name=LVDS1
-#mode=1680x1050
-#transform=90
-#icc_profile=/usr/share/color/icc/colord/Bluish.icc
-
-#[output]
-#name=VGA1
-#mode=173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
-#transform=flipped
-
-#[output]
-#name=X1
-#mode=1024x768
-#transform=flipped-270
-
-#[touchpad]
-#constant_accel_factor = 50
-#min_accel_factor = 0.16
-#max_accel_factor = 1.0
diff --git a/data/tizen-ivi/weston-genivi.ini b/data/tizen-ivi/weston-genivi.ini
deleted file mode 100644 (file)
index bd39824..0000000
+++ /dev/null
@@ -1,33 +0,0 @@
-[core]
-#modules=cms-colord.so
-shell=fullscreen-shell.so
-
-[shell]
-background-image=/usr/share/backgrounds/gnome/Aqua.jpg
-background-color=0xff248bd1
-background-type=tile
-panel-color=0xff2a3c4a
-locking=true
-animation=zoom
-startup-animation=fade
-
-#[output]
-#name=LVDS1
-#mode=1680x1050
-#transform=90
-#icc_profile=/usr/share/color/icc/colord/Bluish.icc
-
-#[output]
-#name=VGA1
-#mode=173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
-#transform=flipped
-
-#[output]
-#name=X1
-#mode=1024x768
-#transform=flipped-270
-
-#[touchpad]
-#constant_accel_factor = 50
-#min_accel_factor = 0.16
-#max_accel_factor = 1.0
diff --git a/data/tizen-ivi/weston-user-modello.ini b/data/tizen-ivi/weston-user-modello.ini
deleted file mode 100644 (file)
index 8a1902e..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
-[core]
-#modules=cms-colord.so
-#shell=desktop-shell.so
-
-[shell]
-background-image=/usr/share/backgrounds/gnome/Aqua.jpg
-background-color=0xff248bd1
-background-type=tile
-panel-color=0xff2a3c4a
-locking=true
-animation=zoom
-startup-animation=fade
-panel-location=none
-
-[input-method]
-path=/bin/weekeyboard
-
-#[output]
-#name=LVDS1
-#mode=1680x1050
-#transform=90
-#icc_profile=/usr/share/color/icc/colord/Bluish.icc
-
-#[output]
-#name=VGA1
-#mode=173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
-#transform=flipped
-
-#[output]
-#name=X1
-#mode=1024x768
-#transform=flipped-270
-
-#[touchpad]
-#constant_accel_factor = 50
-#min_accel_factor = 0.16
-#max_accel_factor = 1.0
-
-[output]
-name=DP1
-mode=1280x720@60
-transform=90
-
diff --git a/data/tizen-ivi/weston-user.ini b/data/tizen-ivi/weston-user.ini
deleted file mode 100644 (file)
index 09ad156..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-[core]
-#modules=cms-colord.so
-#shell=fullscreen-shell.so
-
-[shell]
-background-image=/usr/share/backgrounds/gnome/Aqua.jpg
-background-color=0xff248bd1
-background-type=tile
-panel-color=0xff2a3c4a
-locking=true
-animation=zoom
-startup-animation=fade
-
-[input-method]
-path=/bin/weekeyboard
-
-[keyboard]
-keymap_layout=wkb
-
-#[output]
-#name=LVDS1
-#mode=1680x1050
-#transform=90
-#icc_profile=/usr/share/color/icc/colord/Bluish.icc
-
-#[output]
-#name=VGA1
-#mode=173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
-#transform=flipped
-
-#[output]
-#name=X1
-#mode=1024x768
-#transform=flipped-270
-
-#[touchpad]
-#constant_accel_factor = 50
-#min_accel_factor = 0.16
-#max_accel_factor = 1.0
index 4011e813da315fb630eb831ec0f5afe65e70f44a..bf7da0fcc575e19417b836645ff24dd9e1fe4839 100644 (file)
@@ -183,7 +183,7 @@ install -m 755 -d %{buildroot}%{_sysconfdir}/session.d
 install -m 755 -d %{buildroot}%{_sysconfdir}/xdg/weston
 install -m 644 data/tizen-ivi/etc/tlm*.conf %{buildroot}%{_sysconfdir}
 install -m 755 data/tizen-ivi/etc/session.d/* %{buildroot}%{_sysconfdir}/session.d/
-install -m 644 data/tizen-ivi/weston-*.ini %{buildroot}%{_sysconfdir}/xdg/weston/
+install -m 644 data/tizen-ivi/etc/xdg/weston/*.ini %{buildroot}%{_sysconfdir}/xdg/weston/
 install -m 755 -d %{buildroot}%{_sysconfdir}/udev/rules.d
 install -m 644 data/tizen-ivi/10-multiseat-vtc1010.rules %{buildroot}%{_sysconfdir}/udev/rules.d/
 install -m 755 -d %{buildroot}%{_sysconfdir}/profile.d
@@ -374,9 +374,9 @@ fi
 %defattr(-,root,root,-)
 %manifest %{name}.manifest
 %config(noreplace) %{_sysconfdir}/tlm-singleseat-modello.conf
-%config(noreplace) %{_sysconfdir}/session.d/genivi-session-singleseat
+%config(noreplace) %{_sysconfdir}/session.d/genivi-session-modello
 %config(noreplace) %{_sysconfdir}/session.d/user-session-modello
-%config(noreplace) %{_sysconfdir}/xdg/weston/weston-genivi.ini
+%config(noreplace) %{_sysconfdir}/xdg/weston/weston-genivi-modello.ini
 %config(noreplace) %{_sysconfdir}/xdg/weston/weston-user-modello.ini
 %config(noreplace) %{_sysconfdir}/profile.d/weston-env-ivi.sh
 
index 4011e813da315fb630eb831ec0f5afe65e70f44a..bf7da0fcc575e19417b836645ff24dd9e1fe4839 100644 (file)
@@ -183,7 +183,7 @@ install -m 755 -d %{buildroot}%{_sysconfdir}/session.d
 install -m 755 -d %{buildroot}%{_sysconfdir}/xdg/weston
 install -m 644 data/tizen-ivi/etc/tlm*.conf %{buildroot}%{_sysconfdir}
 install -m 755 data/tizen-ivi/etc/session.d/* %{buildroot}%{_sysconfdir}/session.d/
-install -m 644 data/tizen-ivi/weston-*.ini %{buildroot}%{_sysconfdir}/xdg/weston/
+install -m 644 data/tizen-ivi/etc/xdg/weston/*.ini %{buildroot}%{_sysconfdir}/xdg/weston/
 install -m 755 -d %{buildroot}%{_sysconfdir}/udev/rules.d
 install -m 644 data/tizen-ivi/10-multiseat-vtc1010.rules %{buildroot}%{_sysconfdir}/udev/rules.d/
 install -m 755 -d %{buildroot}%{_sysconfdir}/profile.d
@@ -374,9 +374,9 @@ fi
 %defattr(-,root,root,-)
 %manifest %{name}.manifest
 %config(noreplace) %{_sysconfdir}/tlm-singleseat-modello.conf
-%config(noreplace) %{_sysconfdir}/session.d/genivi-session-singleseat
+%config(noreplace) %{_sysconfdir}/session.d/genivi-session-modello
 %config(noreplace) %{_sysconfdir}/session.d/user-session-modello
-%config(noreplace) %{_sysconfdir}/xdg/weston/weston-genivi.ini
+%config(noreplace) %{_sysconfdir}/xdg/weston/weston-genivi-modello.ini
 %config(noreplace) %{_sysconfdir}/xdg/weston/weston-user-modello.ini
 %config(noreplace) %{_sysconfdir}/profile.d/weston-env-ivi.sh
 
index a8877175ec04616018261fec252b5cf051541c40..dfd92ec12f2fed2706834ff284b90db47c566e85 100644 (file)
@@ -3,7 +3,7 @@
 /*
  * This file is part of tlm (Tizen Login Manager)
  *
- * Copyright (C) 2013-2014 Intel Corporation.
+ * Copyright (C) 2013-2015 Intel Corporation.
  *
  * Contact: Amarnath Valluri <amarnath.valluri@linux.intel.com>
  *          Jussi Laako <jussi.laako@linux.intel.com>
@@ -24,6 +24,9 @@
  * 02110-1301 USA
  */
 
+#include <string.h>
+#include <signal.h>
+#include <errno.h>
 #include <glib.h>
 #include <gio/gio.h>
 #include <glib-unix.h>
@@ -51,7 +54,7 @@ _on_manager_stopped_cb (TlmManager *manager, gpointer user_data)
 static gboolean
 _on_sigterm_cb (gpointer data)
 {
-    DBG ("SIGTERM/SIGINT");
+    DBG ("SIGTERM");
 
     TlmManager *manager = TLM_MANAGER(data);
 
@@ -78,8 +81,10 @@ _on_sighup_cb (gpointer data)
 static void
 _setup_unix_signal_handlers (TlmManager *manager)
 {
+    if (signal (SIGINT, SIG_IGN) == SIG_ERR)
+        WARN ("failed ignore SIGINT: %s", strerror(errno));
+
     g_unix_signal_add (SIGTERM, _on_sigterm_cb, (gpointer) manager);
-    g_unix_signal_add (SIGINT, _on_sigterm_cb, (gpointer) manager);
     g_unix_signal_add (SIGHUP, _on_sighup_cb, (gpointer) manager);
 }
 
index e0fa033835cab23988760960443200a07d9b435b..a8ab1090dfb578e03cba33fca6070c1f72f7b641 100644 (file)
@@ -3,7 +3,7 @@
 /*
  * This file is part of tlm
  *
- * Copyright (C) 2014 Intel Corporation.
+ * Copyright (C) 2014-2015 Intel Corporation.
  *
  * Contact: Imran Zaman <imran.zaman@intel.com>
  *
@@ -28,6 +28,7 @@
 #include <signal.h>
 #include <string.h>
 #include <stdio.h>
+#include <errno.h>
 #include <glib-unix.h>
 #include <glib.h>
 #include <gio/gio.h>
@@ -37,7 +38,7 @@
 #include "tlm-session-daemon.h"
 
 static TlmSessionDaemon *_daemon = NULL;
-static guint _sig_source_id[3];
+static guint _sig_source_id[2];
 
 static void
 _on_daemon_closed (gpointer data, GObject *server)
@@ -65,6 +66,9 @@ _install_sighandlers (GMainLoop *main_loop)
     GSource *source = NULL;
     GMainContext *ctx = g_main_loop_get_context (main_loop);
 
+    if (signal (SIGINT, SIG_IGN) == SIG_ERR)
+        WARN ("failed to ignore SIGINT: %s", strerror(errno));
+
     source = g_unix_signal_source_new (SIGTERM);
     g_source_set_callback (source,
                            _handle_quit_signal,
@@ -72,19 +76,12 @@ _install_sighandlers (GMainLoop *main_loop)
                            NULL);
     _sig_source_id[0] = g_source_attach (source, ctx);
 
-    source = g_unix_signal_source_new (SIGINT);
-    g_source_set_callback (source,
-                           _handle_quit_signal,
-                           main_loop,
-                           NULL);
-    _sig_source_id[1] = g_source_attach (source, ctx);
-
     source = g_unix_signal_source_new (SIGHUP);
     g_source_set_callback (source,
                            _handle_quit_signal,
                            main_loop,
                            NULL);
-    _sig_source_id[2] = g_source_attach (source, ctx);
+    _sig_source_id[1] = g_source_attach (source, ctx);
 
     if (prctl(PR_SET_PDEATHSIG, SIGHUP))
         WARN ("failed to set parent death signal");
index 3bbb401617139b8ad169ff2cd60f8968c085b86e..afdaa1b71af2c50bad5adcc9e15e45ee18017259 100644 (file)
@@ -33,6 +33,7 @@
 #include <grp.h>
 #include <stdio.h>
 #include <signal.h>
+#include <errno.h>
 #include <termios.h>
 #include <libintl.h>
 #include <sys/types.h>
@@ -561,6 +562,7 @@ _exec_user_session (
     /* ==================================
      * this is child process here onwards
      * ================================== */
+
     gint open_max;
     gint fd;
 
@@ -568,7 +570,7 @@ _exec_user_session (
     open_max = sysconf (_SC_OPEN_MAX);
     for (fd = 3; fd < open_max; fd++) {
         if (fcntl (fd, F_SETFD, FD_CLOEXEC) < -1) {
-            WARN("Failed to close desriptor '%d', error: %s",
+            WARN ("Failed to close desriptor '%d', error: %s",
                 fd, strerror(errno));
         }
     }
@@ -687,6 +689,9 @@ _exec_user_session (
         args[1] = g_strdup ("--user");
     }
 
+    if (signal (SIGINT, SIG_DFL) == SIG_ERR)
+        WARN ("failed reset SIGINT: %s", strerror(errno));
+
     DBG ("executing: ");
     args_iter = args;
     while (args_iter && *args_iter) {