summaryrefslogtreecommitdiffstats
path: root/meta-app-framework/recipes-core/af-main/af-main
diff options
context:
space:
mode:
authorJosé Bollo <jose.bollo@iot.bzh>2017-03-14 13:07:12 +0100
committerStephane Desneux <stephane.desneux@iot.bzh>2017-03-27 15:33:40 +0200
commit685a4613bcfc3231066d66263e198399d78cea44 (patch)
tree19a5dcfaa3d8caa12e356fd4bff5739de53493a1 /meta-app-framework/recipes-core/af-main/af-main
parent9c4109e9a477d52de86cac22c5b1e62edfd93795 (diff)
Move to AGL framework on top of systemd
This new version of the framework leverages systemd features to launch its applications. Some of the advantages are: - possible use of systemd features (namespace, cgroups, autostart, dependency resolution, socket activation, ...) - more feature are let open to integrator's design Some of the drawbacks are: - not more possible to launch an other instance of an application already launched - pause/resume is no more available by the framework - the remote mode is to be redefined This commit integrates the first version of the framework on top of systemd. More work is to come. None of the current drawback is definitive. Bug-AGL: SPEC-138, SPEC-425, SPEC-426, SPEC-427 Change-Id: Idfb98761c0db23562bb783bed1b03aeb956fc587 Signed-off-by: José Bollo <jose.bollo@iot.bzh> Signed-off-by: Stephane Desneux <stephane.desneux@iot.bzh>
Diffstat (limited to 'meta-app-framework/recipes-core/af-main/af-main')
-rw-r--r--meta-app-framework/recipes-core/af-main/af-main/add-qt-wayland-shell-integration.patch21
-rw-r--r--meta-app-framework/recipes-core/af-main/af-main/init-afm-dirs.service15
-rw-r--r--meta-app-framework/recipes-core/af-main/af-main/init-afm-dirs.sh7
3 files changed, 11 insertions, 32 deletions
diff --git a/meta-app-framework/recipes-core/af-main/af-main/add-qt-wayland-shell-integration.patch b/meta-app-framework/recipes-core/af-main/af-main/add-qt-wayland-shell-integration.patch
index 8e21678be..c92415b80 100644
--- a/meta-app-framework/recipes-core/af-main/af-main/add-qt-wayland-shell-integration.patch
+++ b/meta-app-framework/recipes-core/af-main/af-main/add-qt-wayland-shell-integration.patch
@@ -1,11 +1,12 @@
-diff --git a/conf/afm-user-daemon.service b/conf/afm-user-daemon.service
-index 6b5c1d8..e0f6799 100644
---- a/conf/afm-user-daemon.service
-+++ b/conf/afm-user-daemon.service
-@@ -7,6 +7,7 @@ BusName=org.AGL.afm.user
- ExecStart=/usr/bin/afm-user-daemon --user-dbus=unix:path=%t/bus
- Environment=AFM_APP_INSTALL_DIR=%%r
- Environment=LD_PRELOAD=/usr/lib/libEGL.so
+diff --git a/conf/afm-unit.conf b/conf/afm-unit.conf
+index 82113ef..2fbc9e2 100644
+--- a/conf/afm-unit.conf
++++ b/conf/afm-unit.conf
+@@ -127,6 +127,7 @@ SuccessExitStatus=0 SIGKILL
+ WorkingDirectory=-{{&#metadata.app-data-dir}}/{{id}}
+ ExecStartPre=/bin/mkdir -p {{&#metadata.app-data-dir}}/{{id}}
+ Environment=AFM_APP_INSTALL_DIR={{:#metadata.install-dir}}
+Environment=QT_WAYLAND_SHELL_INTEGRATION=ivi-shell
- Restart=on-failure
- RestartSec=5
+
+ %systemd-unit user
+ {{#required-permission.urn:AGL:permission::public:hidden}}\
diff --git a/meta-app-framework/recipes-core/af-main/af-main/init-afm-dirs.service b/meta-app-framework/recipes-core/af-main/af-main/init-afm-dirs.service
deleted file mode 100644
index 7e3b9e4e8..000000000
--- a/meta-app-framework/recipes-core/af-main/af-main/init-afm-dirs.service
+++ /dev/null
@@ -1,15 +0,0 @@
-#
-# Install security-manager DB to /var
-
-[Unit]
-Description=Deploy AFM directories to /var
-After=sysinit.target
-Before=afm-system-daemon.service
-Before=afm-user-daemon.service
-
-[Install]
-WantedBy=default.target
-
-[Service]
-Type=oneshot
-ExecStart=/usr/bin/init-afm-dirs.sh
diff --git a/meta-app-framework/recipes-core/af-main/af-main/init-afm-dirs.sh b/meta-app-framework/recipes-core/af-main/af-main/init-afm-dirs.sh
deleted file mode 100644
index 97cf272f2..000000000
--- a/meta-app-framework/recipes-core/af-main/af-main/init-afm-dirs.sh
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/sh
-
-if [ ! -e "/var/lib/afm" ]; then
- mkdir -p /var/lib
- cp -ra /usr/share/afm /var/lib
-fi
-