aboutsummaryrefslogtreecommitdiffstats
path: root/meta-agl-profile-graphical/recipes-graphics/wayland
diff options
context:
space:
mode:
Diffstat (limited to 'meta-agl-profile-graphical/recipes-graphics/wayland')
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/Readme.weston-ini-conf34
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0001-Resolve-weston-crush-when-repeat-touching-very-quick.patch31
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0001-simple-id-agent-initial-commit.patch264
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0002-ivi-controller-load-id-agent-module.patch69
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0003-ivi-controller-add-resize-setting-suit-to-surface-si.patch62
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/disable-sanitizer-tests.patch13
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/wandboard_fix_build.patch13
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension_1.13.0.bb33
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension_2.0.2.bb31
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/wayland/0001-Change-socket-mode-add-rw-for-group.patch29
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/wayland_%.bbappend6
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf.bb30
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/core.cfg4
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/hdmi-a-1-270.cfg6
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/hdmi-a-1-90.cfg6
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/id-agent.cfg2
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/ivishell.cfg4
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/shell.cfg3
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston-init.bbappend79
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston-init/weston.service.add7
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston-init/weston_tmpfiles.conf6
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0001-Allow-regular-users-to-launch-Weston_2.0.0.patch46
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0001-ivi-shell-rework-goto-labels-to-avoid-memory-leaks.patch66
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0002-ivi-shell-removed-assert.patch11
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0003-ivi-shell-introduction-of-IVI_INVALID_ID.patch18
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0004-layout-interface-added-interface-to-change-surface-id.patch73
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0005-ivi-layout-introcuded-configure_desktop_changed.patch74
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0006-ivi-layout-introcuded-surface_create_and_configure.patch117
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0007-ivi-shell-linked-libweston-desktop-and-added-structs.patch74
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0008-ivi-layout-use-libweston-desktop-api-for-views.patch30
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0009-ivi-shell-added-libweston-desktop-api_implementation.patch166
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0010-ivi-shell-remove-surface_destroy_listener.patch24
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0011-ivi-shell-create-weston-desktop-in_wet_shell_init.patch34
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0012-hmi-controller-register-for-desktop_surface_configured.patch133
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0013-simple-egl-remove-ivi-application-support.patch164
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0014-simple-shm-remove-ivi-application-support.patch107
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0015-window-client-remove-ivi-application-support.patch130
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0016-ivi-shell_add_screen_remove_layer_api.patch82
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston_2.0.0.bbappend23
39 files changed, 2104 insertions, 0 deletions
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/Readme.weston-ini-conf b/meta-agl-profile-graphical/recipes-graphics/wayland/Readme.weston-ini-conf
new file mode 100644
index 000000000..bbd5a80c4
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/Readme.weston-ini-conf
@@ -0,0 +1,34 @@
+##Generate a weston.ini file:
+
+To modify any of the default sections (core, shell, ivi-shell), add a
+do_configure() function to your bbappend:
+
+'''
+do_configure() {
+ echo repaint-window=34 >> ${WORKDIR}/core.cfg
+
+ echo transition-duration=300 >> ${WORKDIR}/ivishell.cfg
+ echo cursor-theme=default >> ${WORKDIR}/ivishell.cfg
+}
+'''
+or:
+'''
+do_configure() {
+ sed -i -e 's/drm-backend/fbdev-backend/' ${WORKDIR}/core.cfg
+}
+'''
+
+To change the display from the default assumption of an HDMI-1-A connected
+screen that needs to be rotated 270 degrees:
+
+'''
+SRC_URI_remove = "file://hdmi-a-1-270.cfg"
+SRC_URI += "file://hdmi-a-1-90.cfg"
+'''
+
+To add new sections just list them in SRC_URI:
+'''
+FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
+
+SRC_URI += "file://dsi.cfg"
+'''
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0001-Resolve-weston-crush-when-repeat-touching-very-quick.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0001-Resolve-weston-crush-when-repeat-touching-very-quick.patch
new file mode 100644
index 000000000..636ecf1b9
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0001-Resolve-weston-crush-when-repeat-touching-very-quick.patch
@@ -0,0 +1,31 @@
+From 97af4843a4705cd7d5b6b69abb9002fd974a5b94 Mon Sep 17 00:00:00 2001
+From: Tadao Tanikawa <tanikawa.tadao@jp.panasonic.com>
+Date: Fri, 12 Jan 2018 01:53:01 +0900
+Subject: [PATCH] Resolve weston cursh when repeat touching very quickly
+
+Weston sometimes crush while the user repeat touching very
+quickly icons/shortcuts on HomeScreen.
+
+Signed-off-by: Tadao Tanikawa <tanikawa.tadao@jp.panasonic.com>
+---
+ ivi-input-modules/ivi-input-controller/src/ivi-input-controller.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/ivi-input-modules/ivi-input-controller/src/ivi-input-controller.c b/ivi-input-modules/ivi-input-controller/src/ivi-input-controller.c
+index b0fe37d..f1a31d0 100644
+--- a/ivi-input-modules/ivi-input-controller/src/ivi-input-controller.c
++++ b/ivi-input-modules/ivi-input-controller/src/ivi-input-controller.c
+@@ -557,6 +557,10 @@ touch_grab_up(struct weston_touch_grab *grab, uint32_t time, int touch_id)
+ const struct ivi_layout_interface *interface =
+ seat->input_ctx->ivi_layout_interface;
+
++ /* if touch device has no focused view, there is nothing to do*/
++ if (grab->touch->focus == NULL)
++ return;
++
+ /* For each surface_ctx, check for focus and send */
+ wl_list_for_each(surf_ctx, &seat->input_ctx->surface_list, link) {
+ struct weston_surface *surf, *send_surf;
+--
+2.7.4
+
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0001-simple-id-agent-initial-commit.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0001-simple-id-agent-initial-commit.patch
new file mode 100644
index 000000000..9e95167ed
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0001-simple-id-agent-initial-commit.patch
@@ -0,0 +1,264 @@
+From 8f67f40f7c6b6f62e094f0bdc5044793ae76b1c7 Mon Sep 17 00:00:00 2001
+From: Emre Ucan <eucan@de.adit-jv.com>
+Date: Fri, 24 Nov 2017 16:24:51 +0100
+Subject: [PATCH 1/2] simple-id-agent: initial commit
+
+it is a very simple id-agent plugin.
+It is possible to configure default surface id
+offset. Assigned ids would start
+from the given id offset.
+
+Please check the example weston.ini for loading
+and configuring the simple-id-agent
+
+Signed-off-by: Emre Ucan <eucan@de.adit-jv.com>
+---
+ CMakeLists.txt | 1 +
+ id-agent-modules/simple-id-agent/CMakeLists.txt | 72 ++++++++++++
+ .../simple-id-agent/src/simple-id-agent.c | 124 +++++++++++++++++++++
+ id-agent-modules/simple-id-agent/weston.ini.in | 11 ++
+ 4 files changed, 208 insertions(+)
+ create mode 100644 id-agent-modules/simple-id-agent/CMakeLists.txt
+ create mode 100644 id-agent-modules/simple-id-agent/src/simple-id-agent.c
+ create mode 100644 id-agent-modules/simple-id-agent/weston.ini.in
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index bad85df..d07abf5 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -35,6 +35,7 @@ add_subdirectory(ivi-layermanagement-api/ilmClient)
+ add_subdirectory(ivi-layermanagement-api/ilmControl)
+ add_subdirectory(ivi-layermanagement-api/test)
+ add_subdirectory(ivi-layermanagement-examples)
++add_subdirectory(id-agent-modules/simple-id-agent)
+
+ if(WITH_ILM_INPUT)
+ add_subdirectory(ivi-input-api/ilmInput)
+diff --git a/id-agent-modules/simple-id-agent/CMakeLists.txt b/id-agent-modules/simple-id-agent/CMakeLists.txt
+new file mode 100644
+index 0000000..8290722
+--- /dev/null
++++ b/id-agent-modules/simple-id-agent/CMakeLists.txt
+@@ -0,0 +1,72 @@
++############################################################################
++#
++# Copyright (C) 2013 DENSO CORPORATION
++# Copyright 2014 BMW Car IT GmbH
++#
++#
++# Licensed under the Apache License, Version 2.0 (the "License");
++# you may not use this file except in compliance with the License.
++# You may obtain a copy of the License at
++#
++# http://www.apache.org/licenses/LICENSE-2.0
++#
++# Unless required by applicable law or agreed to in writing, software
++# distributed under the License is distributed on an "AS IS" BASIS,
++# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++# See the License for the specific language governing permissions and
++# limitations under the License.
++#
++############################################################################
++
++cmake_minimum_required (VERSION 2.6)
++
++project(simple-id-agent)
++
++find_package(PkgConfig REQUIRED)
++pkg_check_modules(WAYLAND_SERVER wayland-server>=1.13.0 REQUIRED)
++pkg_check_modules(WESTON weston>=2.0.0 REQUIRED)
++pkg_check_modules(PIXMAN pixman-1 REQUIRED)
++
++find_package(Threads REQUIRED)
++
++GET_TARGET_PROPERTY(IVI_EXTENSION_INCLUDE_DIRS ivi-extension-protocol INCLUDE_DIRECTORIES)
++
++include_directories(
++ src
++ ${IVI_EXTENSION_INCLUDE_DIRS}
++ ${WAYLAND_SERVER_INCLUDE_DIRS}
++ ${WESTON_INCLUDE_DIRS}
++ ${PIXMAN_INCLUDE_DIRS}
++)
++
++link_directories(
++ ${WAYLAND_SERVER_LIBRARY_DIRS}
++ ${PIXMAN_LIBRARY_DIRS}
++)
++
++add_library(${PROJECT_NAME} MODULE
++ src/simple-id-agent.c
++)
++
++set_target_properties(${PROJECT_NAME} PROPERTIES PREFIX "")
++
++add_dependencies(${PROJECT_NAME}
++ ivi-extension-protocol
++ ${WAYLAND_SERVER_LIBRARIES}
++ ${PIXMAN_LIBRARIES}
++)
++
++set(LIBS
++ ${LIBS}
++ ivi-extension-protocol
++ ${WAYLAND_SERVER_LIBRARIES}
++)
++
++set(CMAKE_C_LDFLAGS "-module -avoid-version")
++
++target_link_libraries(${PROJECT_NAME} ${LIBS})
++
++install (
++ TARGETS ${PROJECT_NAME}
++ LIBRARY DESTINATION lib${LIB_SUFFIX}/weston
++)
+diff --git a/id-agent-modules/simple-id-agent/src/simple-id-agent.c b/id-agent-modules/simple-id-agent/src/simple-id-agent.c
+new file mode 100644
+index 0000000..3c9e989
+--- /dev/null
++++ b/id-agent-modules/simple-id-agent/src/simple-id-agent.c
+@@ -0,0 +1,124 @@
++/*
++ * Copyright (C) 2017 Advanced Driver Information Technology Joint Venture GmbH
++ *
++ * Permission to use, copy, modify, distribute, and sell this software and
++ * its documentation for any purpose is hereby granted without fee, provided
++ * that the above copyright notice appear in all copies and that both that
++ * copyright notice and this permission notice appear in supporting
++ * documentation, and that the name of the copyright holders not be used in
++ * advertising or publicity pertaining to distribution of the software
++ * without specific, written prior permission. The copyright holders make
++ * no representations about the suitability of this software for any
++ * purpose. It is provided "as is" without express or implied warranty.
++ *
++ * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
++ * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
++ * FITNESS, IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY
++ * SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER
++ * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF
++ * CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
++ * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
++ */
++
++#include <stdlib.h>
++#include <stdio.h>
++#include <string.h>
++#include <limits.h>
++
++#include <weston.h>
++#include <weston/ivi-layout-export.h>
++
++struct ivi_id_agent
++{
++ uint32_t default_id_offset;
++ uint32_t last_assigned_id;
++ struct weston_compositor *compositor;
++ const struct ivi_layout_interface *interface;
++ struct wl_listener desktop_surface_configured;
++};
++
++static void
++desktop_surface_event_configure(struct wl_listener *listener,
++ void *data)
++{
++ struct ivi_id_agent *ida = wl_container_of(listener, ida,
++ desktop_surface_configured);
++ struct ivi_layout_surface *layout_surface =
++ (struct ivi_layout_surface *) data;
++ uint32_t tmp_id;
++
++ tmp_id = ++ida->last_assigned_id;
++
++ /* Find an unused id */
++ while(ida->interface->get_surface_from_id(tmp_id)) {
++ weston_log("simple-id-agent: surface id: %d is already used\n", tmp_id);
++ tmp_id++;
++ }
++
++ ida->last_assigned_id = tmp_id;
++
++ if (ida->interface->surface_set_id(layout_surface, ida->last_assigned_id) != 0)
++ weston_log("simple-id-agent: failed to set surface id :%d\n", ida->last_assigned_id);
++}
++
++static void
++deinit(struct ivi_id_agent *ida)
++{
++ wl_list_remove(&ida->desktop_surface_configured.link);
++ free(ida);
++}
++
++static int32_t
++read_config(struct ivi_id_agent *ida)
++{
++ struct weston_config *config = NULL;
++ struct weston_config_section *section = NULL;
++ const char *name = NULL;
++
++ config = wet_get_config(ida->compositor);
++ if (!config)
++ return -1;
++
++ section = weston_config_get_section(config, "id-agent", NULL, NULL);
++
++ if (section) {
++
++ weston_config_section_get_uint(section, "default-id-offset",
++ &ida->default_id_offset, 0);
++
++ } else {
++ ida->default_id_offset = 0;
++ }
++
++ return 0;
++}
++
++WL_EXPORT int32_t
++id_agent_module_init(struct weston_compositor *ec,
++ const struct ivi_layout_interface *interface,
++ size_t interface_version)
++{
++ struct ivi_id_agent *ida;
++
++ ida = calloc(1, sizeof *ida);
++ if (ida == NULL) {
++ weston_log("failed to allocate ivi_id_agent\n");
++ return -1;
++ }
++
++ ida->compositor = ec;
++ ida->interface = interface;
++ ida->desktop_surface_configured.notify = desktop_surface_event_configure;
++ ida->interface->add_listener_configure_desktop_surface(&ida->desktop_surface_configured);
++
++ if(read_config(ida) != 0) {
++ deinit(ida);
++ return -1;
++ }
++
++ ida->last_assigned_id = ida->default_id_offset;
++
++ weston_log("id_agent_module_init: success\n");
++
++ return 0;
++}
+diff --git a/id-agent-modules/simple-id-agent/weston.ini.in b/id-agent-modules/simple-id-agent/weston.ini.in
+new file mode 100644
+index 0000000..b5e5fa1
+--- /dev/null
++++ b/id-agent-modules/simple-id-agent/weston.ini.in
+@@ -0,0 +1,11 @@
++[core]
++shell=ivi-shell.so
++require-input=false
++
++[ivi-shell]
++ivi-module=ivi-controller.so
++ivi-input-module=ivi-input-controller.so
++id-agent-module=simple-id-agent.so
++
++[id-agent]
++default-id-offset=10
+--
+2.13.6
+
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0002-ivi-controller-load-id-agent-module.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0002-ivi-controller-load-id-agent-module.patch
new file mode 100644
index 000000000..f44786a36
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0002-ivi-controller-load-id-agent-module.patch
@@ -0,0 +1,69 @@
+From 26f2f7ce78ba2002809048b227ad9c35921a9cd8 Mon Sep 17 00:00:00 2001
+From: Emre Ucan <eucan@de.adit-jv.com>
+Date: Fri, 24 Nov 2017 16:27:01 +0100
+Subject: [PATCH 2/2] ivi-controller: load id-agent module
+
+Signed-off-by: Emre Ucan <eucan@de.adit-jv.com>
+---
+ weston-ivi-shell/src/ivi-controller.c | 39 +++++++++++++++++++++++++++++++++++
+ 1 file changed, 39 insertions(+)
+
+diff --git a/weston-ivi-shell/src/ivi-controller.c b/weston-ivi-shell/src/ivi-controller.c
+index 312a978..47b6de2 100644
+--- a/weston-ivi-shell/src/ivi-controller.c
++++ b/weston-ivi-shell/src/ivi-controller.c
+@@ -1518,6 +1518,40 @@ load_input_module(struct weston_compositor *ec,
+ return 0;
+ }
+
++static int load_id_agent_module(struct weston_compositor *ec,
++ const struct ivi_layout_interface *interface,
++ size_t interface_version)
++{
++ struct weston_config *config = wet_get_config(ec);
++ struct weston_config_section *section;
++ char *id_agent_module = NULL;
++
++ int (*id_agent_module_init)(struct weston_compositor *ec,
++ const struct ivi_layout_interface *interface,
++ size_t interface_version);
++
++ section = weston_config_get_section(config, "ivi-shell", NULL, NULL);
++
++ if (weston_config_section_get_string(section, "id-agent-module",
++ &id_agent_module, NULL) < 0) {
++ weston_log("ivi-controller: No id-agent-module set\n");
++ return 0;
++ }
++
++ id_agent_module_init = wet_load_module_entrypoint(id_agent_module, "id_agent_module_init");
++ if (!id_agent_module_init)
++ return -1;
++
++ if (id_agent_module_init(ec, interface,
++ sizeof(struct ivi_layout_interface)) != 0) {
++ weston_log("ivi-controller: Initialization of id agent module fails\n");
++ return -1;
++ }
++
++ free(id_agent_module);
++ return 0;
++}
++
+ WL_EXPORT int
+ controller_module_init(struct weston_compositor *compositor,
+ int *argc, char *argv[],
+@@ -1555,5 +1589,10 @@ controller_module_init(struct weston_compositor *compositor,
+ return -1;
+ }
+
++ if (load_id_agent_module(compositor, interface, interface_version) < 0) {
++ free(shell);
++ return -1;
++ }
++
+ return 0;
+ }
+--
+2.13.6
+
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0003-ivi-controller-add-resize-setting-suit-to-surface-si.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0003-ivi-controller-add-resize-setting-suit-to-surface-si.patch
new file mode 100644
index 000000000..d2d027256
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/0003-ivi-controller-add-resize-setting-suit-to-surface-si.patch
@@ -0,0 +1,62 @@
+From 525b5bf65303d661f44c01b11bafd5ba90976850 Mon Sep 17 00:00:00 2001
+From: Wataru Mizuno <wmizuno@jp.adit-jv.com>
+Date: Wed, 6 Dec 2017 19:35:51 +0900
+Subject: [PATCH] ivi-controller: add resize setting suit to surface size
+
+The ivi-controller resizes surface size like desktop usecase.
+
+When window manager swicths the half size window to full size,
+resize was not working correctly.
+This patch fixs this issue by changing surface source region at
+the same timing of destination region is changed.
+
+This patch is not necessary later version of wayland-ivi-extension
+2.0 since this resize function has already been implemented by
+appropriate manner.
+
+Signed-off-by: Wataru Mizuno <wmizuno@jp.adit-jv.com>
+---
+ weston-ivi-shell/src/ivi-controller.c | 17 ++++++++++++++---
+ 1 file changed, 14 insertions(+), 3 deletions(-)
+
+diff --git a/weston-ivi-shell/src/ivi-controller.c b/weston-ivi-shell/src/ivi-controller.c
+index 312a978..9450cf2 100644
+--- a/weston-ivi-shell/src/ivi-controller.c
++++ b/weston-ivi-shell/src/ivi-controller.c
+@@ -1334,7 +1334,7 @@ surface_event_configure(struct wl_listener *listener, void *data)
+ struct ivisurface *ivisurf = NULL;
+ struct ivi_layout_surface *layout_surface =
+ (struct ivi_layout_surface *) data;
+- const struct ivi_layout_surface_properties *prop;
++ struct weston_surface *w_surface;
+
+ ivisurf = get_surface(&shell->list_surface, layout_surface);
+ if (ivisurf == NULL) {
+@@ -1342,11 +1342,22 @@ surface_event_configure(struct wl_listener *listener, void *data)
+ return;
+ }
+
+- prop = lyt->get_properties_of_surface(layout_surface);
++ w_surface = lyt->surface_get_weston_surface(layout_surface);
++ lyt->surface_set_destination_rectangle(layout_surface,
++ ivisurf->prop->dest_x,
++ ivisurf->prop->dest_y,
++ w_surface->width,
++ w_surface->height);
++ lyt->surface_set_source_rectangle(layout_surface,
++ 0,
++ 0,
++ w_surface->width,
++ w_surface->height);
++ lyt->commit_changes();
+
+ wl_resource_for_each(resource, &ivisurf->resource_list) {
+ send_surface_event(resource, ivisurf,
+- prop, IVI_NOTIFICATION_CONFIGURE);
++ ivisurf->prop, IVI_NOTIFICATION_CONFIGURE);
+ }
+ }
+
+--
+2.7.4
+
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/disable-sanitizer-tests.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/disable-sanitizer-tests.patch
new file mode 100644
index 000000000..df5d616fd
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/disable-sanitizer-tests.patch
@@ -0,0 +1,13 @@
+Index: git/ivi-layermanagement-api/test/CMakeLists.txt
+===================================================================
+--- git.orig/ivi-layermanagement-api/test/CMakeLists.txt
++++ git/ivi-layermanagement-api/test/CMakeLists.txt
+@@ -58,7 +58,7 @@ IF(BUILD_ILM_API_TESTS)
+ )
+
+ SET(GCC_SANITIZER_COMPILE_FLAGS "-fsanitize=address -fsanitize=undefined -fno-sanitize-recover -fstack-protector-all")
+- SET( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${GCC_SANITIZER_COMPILE_FLAGS}" )
++ SET( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}" )
+ SET( CMAKE_CXX_LINK_FLAGS "${CMAKE_CXX_LINK_FLAGS} -static-libasan -static-libubsan" )
+
+ ADD_EXECUTABLE(${PROJECT_NAME} ${SRC_FILES})
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/wandboard_fix_build.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/wandboard_fix_build.patch
new file mode 100644
index 000000000..86b448be1
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension/wandboard_fix_build.patch
@@ -0,0 +1,13 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 3610fa9..8b4614d 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -34,7 +34,7 @@ add_subdirectory(ivi-layermanagement-api/ilmCommon)
+ add_subdirectory(ivi-layermanagement-api/ilmClient)
+ add_subdirectory(ivi-layermanagement-api/ilmControl)
+ add_subdirectory(ivi-layermanagement-api/test)
+-add_subdirectory(ivi-layermanagement-examples)
++#add_subdirectory(ivi-layermanagement-examples)
+
+ if(WITH_ILM_INPUT)
+ add_subdirectory(ivi-input-api/ilmInput)
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension_1.13.0.bb b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension_1.13.0.bb
new file mode 100644
index 000000000..68e92adb5
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension_1.13.0.bb
@@ -0,0 +1,33 @@
+SUMMARY = "Wayland IVI Extension"
+DESCRIPTION = "GENIVI Layer Management API based on Wayland IVI Extension"
+HOMEPAGE = "http://projects.genivi.org/wayland-ivi-extension"
+BUGTRACKER = "http://bugs.genivi.org/enter_bug.cgi?product=Wayland%20IVI%20Extension"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=1f1a56bb2dadf5f2be8eb342acf4ed79"
+
+SRCREV = "ede33c1c898eeaf673dd2c275e92763a5aabd066"
+SRC_URI = "git://github.com/GENIVI/${BPN}.git;protocol=http \
+ file://0001-simple-id-agent-initial-commit.patch;patch=1 \
+ file://0002-ivi-controller-load-id-agent-module.patch;patch=1 \
+ file://0003-ivi-controller-add-resize-setting-suit-to-surface-si.patch \
+ file://0001-Resolve-weston-crush-when-repeat-touching-very-quick.patch \
+"
+S = "${WORKDIR}/git"
+
+DEPENDS = "weston virtual/libgles2 pixman wayland-native"
+
+inherit cmake
+
+EXTRA_OECMAKE := "-DWITH_ILM_INPUT=1"
+
+FILES_${PN} += "${libdir}/weston/*"
+FILES_${PN}-dbg += "${libdir}/weston/.debug/*"
+
+EXTRA_OECMAKE += "-DLIB_SUFFIX=${@d.getVar('baselib', True).replace('lib', '')}"
+
+FILESEXTRAPATHS_prepend := ":${THISDIR}/wayland-ivi-extension:"
+
+SRC_URI_append_wandboard = " file://wandboard_fix_build.patch"
+
+# workaround paralellism issue:
+PARALLEL_MAKE = ""
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension_2.0.2.bb b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension_2.0.2.bb
new file mode 100644
index 000000000..ea74e384c
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland-ivi-extension_2.0.2.bb
@@ -0,0 +1,31 @@
+SUMMARY = "Wayland IVI Extension"
+DESCRIPTION = "GENIVI Layer Management API based on Wayland IVI Extension"
+HOMEPAGE = "http://projects.genivi.org/wayland-ivi-extension"
+BUGTRACKER = "http://bugs.genivi.org/enter_bug.cgi?product=Wayland%20IVI%20Extension"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=1f1a56bb2dadf5f2be8eb342acf4ed79"
+
+SRCREV = "ff067a640451de46836200624ece7ac777977c30"
+SRC_URI = "git://github.com/GENIVI/${BPN}.git;branch=2.0;protocol=http \
+ "
+SRC_URI_append_wandboard = " file://wandboard_fix_build.patch"
+
+S = "${WORKDIR}/git"
+
+DEPENDS = "weston virtual/libgles2 pixman wayland-native"
+
+FILESEXTRAPATHS_prepend := ":${THISDIR}/wayland-ivi-extension:"
+
+# workaround paralellism issue:
+PARALLEL_MAKE = ""
+
+inherit cmake
+
+EXTRA_OECMAKE := "-DWITH_ILM_INPUT=1"
+
+FILES_${PN} += "${libdir}/weston/*"
+FILES_${PN} += "${datadir}/wayland-protocols/stable/ivi-application/*"
+
+FILES_${PN}-dbg += "${libdir}/weston/.debug/*"
+
+EXTRA_OECMAKE += "-DLIB_SUFFIX=${@d.getVar('baselib', True).replace('lib', '')}"
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/wayland/0001-Change-socket-mode-add-rw-for-group.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland/0001-Change-socket-mode-add-rw-for-group.patch
new file mode 100644
index 000000000..b04127b57
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland/0001-Change-socket-mode-add-rw-for-group.patch
@@ -0,0 +1,29 @@
+From 9162f7d4cfeec7103474e8703218b3679ca9ed10 Mon Sep 17 00:00:00 2001
+From: Ronan Le Martret <ronan.lemartret@iot.bzh>
+Date: Tue, 18 Apr 2017 13:53:26 +0200
+Subject: [PATCH] Change socket mode:add rw for group
+
+Signed-off-by: Ronan Le Martret <ronan.lemartret@iot.bzh>
+---
+ src/wayland-server.c | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/src/wayland-server.c b/src/wayland-server.c
+index 64d1bec..313c5a0 100644
+--- a/src/wayland-server.c
++++ b/src/wayland-server.c
+@@ -1189,7 +1189,10 @@ _wl_display_add_socket(struct wl_display *display, struct wl_socket *s)
+ wl_log("bind() failed with error: %m\n");
+ return -1;
+ }
+-
++ if (chmod(s->addr.sun_path, 0660) < 0) {
++ wl_log("chmod() failed with error: %m\n");
++ return -1;
++ }
+ if (listen(s->fd, 128) < 0) {
+ wl_log("listen() failed with error: %m\n");
+ return -1;
+--
+2.6.6
+
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/wayland_%.bbappend b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland_%.bbappend
new file mode 100644
index 000000000..7a1a6c6c1
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/wayland_%.bbappend
@@ -0,0 +1,6 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
+
+SRC_URI_append = "\
+ file://0001-Change-socket-mode-add-rw-for-group.patch \
+ "
+EXTRA_OECONF_append = " --enable-ivi-shell"
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf.bb b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf.bb
new file mode 100644
index 000000000..4628f96f8
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf.bb
@@ -0,0 +1,30 @@
+SUMMARY = "Startup script and systemd unit file for the Weston Wayland compositor"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
+
+SRC_URI = "file://core.cfg \
+ file://ivishell.cfg \
+ file://id-agent.cfg \
+ file://shell.cfg \
+ file://hdmi-a-1-270.cfg \
+ "
+
+S = "${WORKDIR}"
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+do_compile() {
+ # Put all of our cfg files together.
+ rm -f ${WORKDIR}/weston.ini
+ for F in ${WORKDIR}/*.cfg; do
+ cat $F >> ${WORKDIR}/weston.ini
+ echo >> ${WORKDIR}/weston.ini
+ done
+ sed -i -e '$ d' ${WORKDIR}/weston.ini
+}
+
+do_install_append() {
+ WESTON_INI_CONFIG=${sysconfdir}/xdg/weston
+ install -d ${D}${WESTON_INI_CONFIG}
+ install -m 0644 ${WORKDIR}/weston.ini ${D}${WESTON_INI_CONFIG}/weston.ini
+}
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/core.cfg b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/core.cfg
new file mode 100644
index 000000000..a0ec1e181
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/core.cfg
@@ -0,0 +1,4 @@
+[core]
+shell=ivi-shell.so
+backend=drm-backend.so
+require-input=false
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/hdmi-a-1-270.cfg b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/hdmi-a-1-270.cfg
new file mode 100644
index 000000000..dffc2b6dd
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/hdmi-a-1-270.cfg
@@ -0,0 +1,6 @@
+# A display is connected to HDMI-A-1 and needs to be rotated 270 degrees
+# to have a proper orientation of the homescreen. For example the various sizes
+# of the GeChic display or the Dell display.
+[output]
+name=HDMI-A-1
+transform=270
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/hdmi-a-1-90.cfg b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/hdmi-a-1-90.cfg
new file mode 100644
index 000000000..88a692a1b
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/hdmi-a-1-90.cfg
@@ -0,0 +1,6 @@
+# A display is connected to HDMI-A-1 and needs to be rotated 90 degrees
+# to have a proper orientation of the homescreen. For example, the 'eGalax'
+# display used in some instances.
+[output]
+name=HDMI-A-1
+transform=90
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/id-agent.cfg b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/id-agent.cfg
new file mode 100644
index 000000000..726fca5f1
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/id-agent.cfg
@@ -0,0 +1,2 @@
+[id-agent]
+default-id-offset=1000
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/ivishell.cfg b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/ivishell.cfg
new file mode 100644
index 000000000..f0548f291
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/ivishell.cfg
@@ -0,0 +1,4 @@
+[ivi-shell]
+ivi-input-module=ivi-input-controller.so
+ivi-module=ivi-controller.so
+id-agent-module=simple-id-agent.so
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/shell.cfg b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/shell.cfg
new file mode 100644
index 000000000..056770427
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-ini-conf/shell.cfg
@@ -0,0 +1,3 @@
+[shell]
+locking=true
+panel-location=none
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston-init.bbappend b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-init.bbappend
new file mode 100644
index 000000000..1ca63b5de
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-init.bbappend
@@ -0,0 +1,79 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
+
+inherit agl-graphical
+
+WESTONSTART ??= "/usr/bin/weston ${WESTONARGS}"
+WESTONSTART_append = " ${@bb.utils.contains("IMAGE_FEATURES", "debug-tweaks", " --log=${DISPLAY_XDG_RUNTIME_DIR}/weston.log", "",d)}"
+
+SRC_URI += " \
+ file://weston_tmpfiles.conf \
+ file://weston.service.add \
+"
+
+do_install_append() {
+ sed -i "/\[Unit\]/aConflicts=getty@tty${WESTONTTY}.service" \
+ ${D}${systemd_system_unitdir}/weston.service
+
+ sed -i "/\[Service\]/r ${S}/weston.service.add" \
+ ${D}${systemd_system_unitdir}/weston.service
+
+ if ! grep -q '^Group=' ${D}${systemd_system_unitdir}/weston.service; then
+ sed -i "/\[Service\]/aGroup=root" ${D}${systemd_system_unitdir}/weston.service
+ fi
+ if ! grep -q '^User=' ${D}${systemd_system_unitdir}/weston.service; then
+ sed -i "/\[Service\]/aUser=root" ${D}${systemd_system_unitdir}/weston.service
+ fi
+
+ sed -e 's,User=root,User=${WESTONUSER},g' \
+ -e 's,Group=root,Group=${WESTONGROUP},g' \
+ -e 's,ExecStart=.*,ExecStart=${WESTONSTART},g' \
+ -e 's,@WESTONTTY@,${WESTONTTY},g' \
+ -e 's,@XDG_RUNTIME_DIR@,${DISPLAY_XDG_RUNTIME_DIR},g' \
+ -i ${D}${systemd_system_unitdir}/weston.service
+
+ # Add a rule to ensure the 'display' user has permissions to
+ # open the graphics device
+ install -d ${D}${sysconfdir}/init.d
+ install -d ${D}${sysconfdir}/udev/rules.d
+ cat >${D}${sysconfdir}/udev/rules.d/zz-dri.rules <<'EOF'
+SUBSYSTEM=="drm", MODE="0660", GROUP="${WESTONGROUP}", SECLABEL{smack}="*", TAG+="systemd", ENV{SYSTEMD_WANTS}="weston.service"
+EOF
+
+ # user 'display' must own /dev/tty${WESTONTTY} for weston to start correctly
+ cat >${D}${sysconfdir}/udev/rules.d/zz-tty.rules <<'EOF'
+SUBSYSTEM=="tty", KERNEL=="tty${WESTONTTY}", OWNER="${WESTONUSER}", SECLABEL{smack}="^", TAG+="systemd", ENV{SYSTEMD_WANTS}="weston.service"
+EOF
+
+ # user 'display' must also be able to access /dev/input/*
+ cat >${D}${sysconfdir}/udev/rules.d/zz-input.rules <<'EOF'
+SUBSYSTEM=="input", MODE="0660", GROUP="input", SECLABEL{smack}="^", TAG+="systemd", ENV{SYSTEMD_WANTS}="weston.service"
+EOF
+
+ # user 'display' must also be able to access /dev/media*, etc.
+ cat >${D}${sysconfdir}/udev/rules.d/zz-remote-display.rules <<'EOF'
+SUBSYSTEM=="media", MODE="0660", GROUP="display", SECLABEL{smack}="*", TAG+="systemd", ENV{SYSTEMD_WANTS}="weston.service"
+SUBSYSTEM=="video4linux", MODE="0660", GROUP="display", SECLABEL{smack}="*", TAG+="systemd", ENV{SYSTEMD_WANTS}="weston.service"
+KERNEL=="uvcs", SUBSYSTEM=="misc", MODE="0660", GROUP="display", SECLABEL{smack}="*"
+KERNEL=="rgnmm", SUBSYSTEM=="misc", MODE="0660", GROUP="display", SECLABEL{smack}="*"
+EOF
+
+ install -d ${D}${sysconfdir}/tmpfiles.d
+ install -Dm755 ${WORKDIR}/weston_tmpfiles.conf ${D}/${libdir}/tmpfiles.d/weston.conf
+
+ sed -e 's,@WESTONUSER@,${WESTONUSER},g' \
+ -e 's,@WESTONGROUP@,${WESTONGROUP},g' \
+ -i ${D}/${libdir}/tmpfiles.d/weston.conf
+}
+
+do_install_append_imx() {
+
+ install -d ${D}${sysconfdir}/udev/rules.d
+ cat >>${D}${sysconfdir}/udev/rules.d/zz-dri.rules <<'EOF'
+SUBSYSTEM=="gpu_class", MODE="0660", GROUP="${WESTONGROUP}", SECLABEL{smack}="*"
+EOF
+
+}
+
+FILES_${PN} += "${libdir}/tmpfiles.d/*.conf"
+
+
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston-init/weston.service.add b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-init/weston.service.add
new file mode 100644
index 000000000..3596e9c39
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-init/weston.service.add
@@ -0,0 +1,7 @@
+Environment="XDG_RUNTIME_DIR=@XDG_RUNTIME_DIR@"
+TTYPath=/dev/tty@WESTONTTY@
+StandardInput=tty
+TTYReset=yes
+TTYVHangup=yes
+TTYVTDisallocate=yes
+UtmpIdentifier=tty@WESTONTTY@
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston-init/weston_tmpfiles.conf b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-init/weston_tmpfiles.conf
new file mode 100644
index 000000000..c4b302faf
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston-init/weston_tmpfiles.conf
@@ -0,0 +1,6 @@
+# This file is distributed to create weston XDG_RUNTIME_DIR (/run/deamon/@WESTONUSER@)
+#
+# See tmpfiles.d(5) for details
+
+d /run/platform/ 0775 root root -
+d /run/platform/@WESTONUSER@ 0770 @WESTONUSER@ @WESTONGROUP@ -
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0001-Allow-regular-users-to-launch-Weston_2.0.0.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0001-Allow-regular-users-to-launch-Weston_2.0.0.patch
new file mode 100644
index 000000000..bd1a72b0f
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0001-Allow-regular-users-to-launch-Weston_2.0.0.patch
@@ -0,0 +1,46 @@
+From 6c145cea35f0b77613d6e3f48679c976b9839d7c Mon Sep 17 00:00:00 2001
+From: Ronan Le Martret <ronan.lemartret@iot.bzh>
+Date: Wed, 31 May 2017 22:48:18 +0000
+Subject: [PATCH] Allow regular users to launch Weston
+
+Signed-off-by: Ronan Le Martret <ronan.lemartret@iot.bzh>
+---
+ configure.ac | 6 ++++++
+ libweston/launcher-direct.c | 2 ++
+ 2 files changed, 8 insertions(+)
+
+diff --git a/configure.ac b/configure.ac
+index 7e84c14..8b3e17e 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -155,6 +155,12 @@ if test x$enable_xkbcommon = xyes; then
+ true)
+ fi
+
++AC_ARG_ENABLE(sys-uid, [ --enable-sys-uid],,
++ enable_sys_uid=no)
++if test x$enable_sys_uid = xyes; then
++ AC_DEFINE(ENABLE_SYS_UID, [1], [Allow regular users to launch Weston])
++fi
++
+ AC_ARG_ENABLE(setuid-install, [ --enable-setuid-install],,
+ enable_setuid_install=yes)
+ AM_CONDITIONAL(ENABLE_SETUID_INSTALL, test x$enable_setuid_install = xyes)
+diff --git a/libweston/launcher-direct.c b/libweston/launcher-direct.c
+index 4fc1c3c..8f16a69 100644
+--- a/libweston/launcher-direct.c
++++ b/libweston/launcher-direct.c
+@@ -275,8 +275,10 @@ launcher_direct_connect(struct weston_launcher **out, struct weston_compositor *
+ {
+ struct launcher_direct *launcher;
+
++#ifndef ENABLE_SYS_UID
+ if (geteuid() != 0)
+ return -EINVAL;
++#endif
+
+ launcher = zalloc(sizeof(*launcher));
+ if (launcher == NULL)
+--
+2.7.4
+
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0001-ivi-shell-rework-goto-labels-to-avoid-memory-leaks.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0001-ivi-shell-rework-goto-labels-to-avoid-memory-leaks.patch
new file mode 100644
index 000000000..449b7a0fd
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0001-ivi-shell-rework-goto-labels-to-avoid-memory-leaks.patch
@@ -0,0 +1,66 @@
+index 67619b8f..e9ddf9a4 100644
+--- a/ivi-shell/ivi-shell.c
++++ b/ivi-shell/ivi-shell.c
+@@ -497,44 +497,53 @@ wet_shell_init(struct weston_compositor *compositor,
+ {
+ struct ivi_shell *shell;
+ struct ivi_shell_setting setting = { };
+- int retval = -1;
+
+ shell = zalloc(sizeof *shell);
+ if (shell == NULL)
+ return -1;
+
+ if (ivi_shell_setting_create(&setting, compositor, argc, argv) != 0)
+- return -1;
++ goto err_shell;
+
+ init_ivi_shell(compositor, shell, &setting);
++ /* TODO deinit_ivi_shell should be implemented, since init_ivi_shell is
++ * initializing multiple lists. */
+
+ shell->destroy_listener.notify = shell_destroy;
+ wl_signal_add(&compositor->destroy_signal, &shell->destroy_listener);
+
+ if (input_panel_setup(shell) < 0)
+- goto out_settings;
++ goto err_settings;
+
+ shell->text_backend = text_backend_init(compositor);
+ if (!shell->text_backend)
+- goto out_settings;
++ goto err_settings;
+
+ if (wl_global_create(compositor->wl_display,
+ &ivi_application_interface, 1,
+ shell, bind_ivi_application) == NULL)
+- goto out_settings;
++ goto err_text_backend;
+
+ ivi_layout_init_with_compositor(compositor);
++ /* TODO ivi_layout_destroy should be implemented, since multiple lists
++ * and signals are initialized.*/
+ shell_add_bindings(compositor, shell);
+
+ /* Call module_init of ivi-modules which are defined in weston.ini */
+ if (load_controller_modules(compositor, setting.ivi_module,
+ argc, argv) < 0)
+- goto out_settings;
++ goto err_text_backend;
++
++ return IVI_SUCCEEDED;
+
+- retval = 0;
++err_text_backend:
++ text_backend_destroy(shell->text_backend);
+
+-out_settings:
++err_settings:
+ free(setting.ivi_module);
+
+- return retval;
++err_shell:
++ free(shell);
++
++ return IVI_FAILED;
+ }
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0002-ivi-shell-removed-assert.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0002-ivi-shell-removed-assert.patch
new file mode 100644
index 000000000..4507e769c
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0002-ivi-shell-removed-assert.patch
@@ -0,0 +1,11 @@
+index e9ddf9a4..f3156d35 100644
+--- a/ivi-shell/ivi-shell.c
++++ b/ivi-shell/ivi-shell.c
+@@ -114,7 +114,6 @@ shell_surface_send_configure(struct weston_surface *surface,
+ struct ivi_shell_surface *shsurf;
+
+ shsurf = get_ivi_shell_surface(surface);
+- assert(shsurf);
+ if (!shsurf)
+ return;
+
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0003-ivi-shell-introduction-of-IVI_INVALID_ID.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0003-ivi-shell-introduction-of-IVI_INVALID_ID.patch
new file mode 100644
index 000000000..6f683ca92
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0003-ivi-shell-introduction-of-IVI_INVALID_ID.patch
@@ -0,0 +1,18 @@
+index 2317d6e9..e1e897ed 100644
+--- a/ivi-shell/ivi-layout-export.h
++++ b/ivi-shell/ivi-layout-export.h
+@@ -56,12 +56,14 @@ extern "C" {
+ #endif /* __cplusplus */
+
+ #include <stdint.h>
++#include <limits.h>
+
+ #include "stdbool.h"
+ #include "compositor.h"
+
+ #define IVI_SUCCEEDED (0)
+ #define IVI_FAILED (-1)
++#define IVI_INVALID_ID UINT_MAX
+
+ struct ivi_layout_layer;
+ struct ivi_layout_screen;
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0004-layout-interface-added-interface-to-change-surface-id.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0004-layout-interface-added-interface-to-change-surface-id.patch
new file mode 100644
index 000000000..6401c5b81
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0004-layout-interface-added-interface-to-change-surface-id.patch
@@ -0,0 +1,73 @@
+index e1e897ed..5b1f12f0 100644
+--- a/ivi-shell/ivi-layout-export.h
++++ b/ivi-shell/ivi-layout-export.h
+@@ -320,6 +320,12 @@ struct ivi_layout_interface {
+ struct ivi_layout_surface *ivisurf,
+ uint32_t duration);
+
++ /**
++ * \brief set id of ivi_layout_surface
++ */
++ int32_t (*surface_set_id)(struct ivi_layout_surface *ivisurf,
++ uint32_t id_surface);
++
+ /**
+ * layer controller interface
+ */
+diff --git a/ivi-shell/ivi-layout.c b/ivi-shell/ivi-layout.c
+index 298e18ea..fa8e75f6 100644
+--- a/ivi-shell/ivi-layout.c
++++ b/ivi-shell/ivi-layout.c
+@@ -1901,6 +1901,44 @@ ivi_layout_surface_set_transition_duration(struct ivi_layout_surface *ivisurf,
+ return 0;
+ }
+
++/*
++ * This interface enables e.g. an id agent to set the id of an ivi-layout
++ * surface, that has been created by a desktop application. This can only be
++ * done once as long as the initial surface id equals IVI_INVALID_ID. Afterwards
++ * two events are emitted, namely surface_created and surface_configured.
++ */
++static int32_t
++ivi_layout_surface_set_id(struct ivi_layout_surface *ivisurf,
++ uint32_t id_surface)
++{
++ struct ivi_layout *layout = get_instance();
++ struct ivi_layout_surface *search_ivisurf = NULL;
++
++ if (!ivisurf) {
++ weston_log("%s: invalid argument\n", __func__);
++ return IVI_FAILED;
++ }
++
++ if (ivisurf->id_surface != IVI_INVALID_ID) {
++ weston_log("surface id can only be set once\n");
++ return IVI_FAILED;
++ }
++
++ search_ivisurf = get_surface(&layout->surface_list, id_surface);
++ if (search_ivisurf) {
++ weston_log("id_surface(%d) is already created\n", id_surface);
++ return IVI_FAILED;
++ }
++
++ ivisurf->id_surface = id_surface;
++
++ wl_signal_emit(&layout->surface_notification.created, ivisurf);
++ wl_signal_emit(&layout->surface_notification.configure_changed,
++ ivisurf);
++
++ return IVI_SUCCEEDED;
++}
++
+ static int32_t
+ ivi_layout_surface_set_transition(struct ivi_layout_surface *ivisurf,
+ enum ivi_layout_transition_type type,
+@@ -2058,6 +2096,7 @@ static struct ivi_layout_interface ivi_layout_interface = {
+ .surface_get_weston_surface = ivi_layout_surface_get_weston_surface,
+ .surface_set_transition = ivi_layout_surface_set_transition,
+ .surface_set_transition_duration = ivi_layout_surface_set_transition_duration,
++ .surface_set_id = ivi_layout_surface_set_id,
+
+ /**
+ * layer controller interfaces
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0005-ivi-layout-introcuded-configure_desktop_changed.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0005-ivi-layout-introcuded-configure_desktop_changed.patch
new file mode 100644
index 000000000..ddd949e35
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0005-ivi-layout-introcuded-configure_desktop_changed.patch
@@ -0,0 +1,74 @@
+index 5b1f12f0..dd0997aa 100644
+--- a/ivi-shell/ivi-layout-export.h
++++ b/ivi-shell/ivi-layout-export.h
+@@ -187,6 +187,16 @@ struct ivi_layout_interface {
+ */
+ int32_t (*add_listener_configure_surface)(struct wl_listener *listener);
+
++ /**
++ * \brief add a listener for notification when desktop_surface is configured
++ *
++ * When an desktop_surface is configured, a signal is emitted
++ * to the listening controller plugins.
++ * The pointer of the configured desktop_surface is sent as the void *data argument
++ * to the wl_listener::notify callback function of the listener.
++ */
++ int32_t (*add_listener_configure_desktop_surface)(struct wl_listener *listener);
++
+ /**
+ * \brief Get all ivi_surfaces which are currently registered and managed
+ * by the services
+diff --git a/ivi-shell/ivi-layout-private.h b/ivi-shell/ivi-layout-private.h
+index 2b8bd472..fe5be01a 100644
+--- a/ivi-shell/ivi-layout-private.h
++++ b/ivi-shell/ivi-layout-private.h
+@@ -104,6 +104,7 @@ struct ivi_layout {
+ struct wl_signal created;
+ struct wl_signal removed;
+ struct wl_signal configure_changed;
++ struct wl_signal configure_desktop_changed;
+ } surface_notification;
+
+ struct weston_layer layout_layer;
+diff --git a/ivi-shell/ivi-layout.c b/ivi-shell/ivi-layout.c
+index fa8e75f6..690af742 100644
+--- a/ivi-shell/ivi-layout.c
++++ b/ivi-shell/ivi-layout.c
+@@ -1040,6 +1040,21 @@ ivi_layout_add_listener_configure_surface(struct wl_listener *listener)
+ return IVI_SUCCEEDED;
+ }
+
++static int32_t
++ivi_layout_add_listener_configure_desktop_surface(struct wl_listener *listener)
++{
++ struct ivi_layout *layout = get_instance();
++
++ if (!listener) {
++ weston_log("ivi_layout_add_listener_configure_desktop_surface: invalid argument\n");
++ return IVI_FAILED;
++ }
++
++ wl_signal_add(&layout->surface_notification.configure_desktop_changed, listener);
++
++ return IVI_SUCCEEDED;
++}
++
+ uint32_t
+ ivi_layout_get_id_of_surface(struct ivi_layout_surface *ivisurf)
+ {
+@@ -2057,6 +2072,7 @@ ivi_layout_init_with_compositor(struct weston_compositor *ec)
+ wl_signal_init(&layout->surface_notification.created);
+ wl_signal_init(&layout->surface_notification.removed);
+ wl_signal_init(&layout->surface_notification.configure_changed);
++ wl_signal_init(&layout->surface_notification.configure_desktop_changed);
+
+ /* Add layout_layer at the last of weston_compositor.layer_list */
+ weston_layer_init(&layout->layout_layer, ec);
+@@ -2081,6 +2097,7 @@ static struct ivi_layout_interface ivi_layout_interface = {
+ .add_listener_create_surface = ivi_layout_add_listener_create_surface,
+ .add_listener_remove_surface = ivi_layout_add_listener_remove_surface,
+ .add_listener_configure_surface = ivi_layout_add_listener_configure_surface,
++ .add_listener_configure_desktop_surface = ivi_layout_add_listener_configure_desktop_surface,
+ .get_surface = shell_get_ivi_layout_surface,
+ .get_surfaces = ivi_layout_get_surfaces,
+ .get_id_of_surface = ivi_layout_get_id_of_surface,
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0006-ivi-layout-introcuded-surface_create_and_configure.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0006-ivi-layout-introcuded-surface_create_and_configure.patch
new file mode 100644
index 000000000..04461a1d4
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0006-ivi-layout-introcuded-surface_create_and_configure.patch
@@ -0,0 +1,117 @@
+index 68ca68ba..c86cbb11 100644
+--- a/ivi-shell/ivi-layout-shell.h
++++ b/ivi-shell/ivi-layout-shell.h
+@@ -39,6 +39,14 @@ struct weston_view;
+ struct weston_surface;
+ struct ivi_layout_surface;
+
++void
++ivi_layout_desktop_surface_configure(struct ivi_layout_surface *ivisurf,
++ int32_t width, int32_t height);
++
++struct ivi_layout_surface*
++ivi_layout_desktop_surface_create(struct weston_surface *wl_surface,
++ uint32_t id_surface);
++
+ void
+ ivi_layout_surface_configure(struct ivi_layout_surface *ivisurf,
+ int32_t width, int32_t height);
+diff --git a/ivi-shell/ivi-layout.c b/ivi-shell/ivi-layout.c
+index 690af742..086d0fd2 100644
+--- a/ivi-shell/ivi-layout.c
++++ b/ivi-shell/ivi-layout.c
+@@ -1995,20 +1995,8 @@ ivi_layout_surface_dump(struct weston_surface *surface,
+ * methods of interaction between ivi-shell with ivi-layout
+ */
+
+-void
+-ivi_layout_surface_configure(struct ivi_layout_surface *ivisurf,
+- int32_t width, int32_t height)
+-{
+- struct ivi_layout *layout = get_instance();
+-
+- /* emit callback which is set by ivi-layout api user */
+- wl_signal_emit(&layout->surface_notification.configure_changed,
+- ivisurf);
+-}
+-
+-struct ivi_layout_surface*
+-ivi_layout_surface_create(struct weston_surface *wl_surface,
+- uint32_t id_surface)
++static struct ivi_layout_surface*
++surface_create(struct weston_surface *wl_surface, uint32_t id_surface)
+ {
+ struct ivi_layout *layout = get_instance();
+ struct ivi_layout_surface *ivisurf = NULL;
+@@ -2018,14 +2006,6 @@ ivi_layout_surface_create(struct weston_surface *wl_surface,
+ return NULL;
+ }
+
+- ivisurf = get_surface(&layout->surface_list, id_surface);
+- if (ivisurf != NULL) {
+- if (ivisurf->surface != NULL) {
+- weston_log("id_surface(%d) is already created\n", id_surface);
+- return NULL;
+- }
+- }
+-
+ ivisurf = calloc(1, sizeof *ivisurf);
+ if (ivisurf == NULL) {
+ weston_log("fails to allocate memory\n");
+@@ -2049,7 +2029,55 @@ ivi_layout_surface_create(struct weston_surface *wl_surface,
+
+ wl_list_insert(&layout->surface_list, &ivisurf->link);
+
+- wl_signal_emit(&layout->surface_notification.created, ivisurf);
++ return ivisurf;
++}
++
++void
++ivi_layout_desktop_surface_configure(struct ivi_layout_surface *ivisurf,
++ int32_t width, int32_t height)
++{
++ struct ivi_layout *layout = get_instance();
++
++ /* emit callback which is set by ivi-layout api user */
++ wl_signal_emit(&layout->surface_notification.configure_desktop_changed,
++ ivisurf);
++}
++
++struct ivi_layout_surface*
++ivi_layout_desktop_surface_create(struct weston_surface *wl_surface,
++ uint32_t id_surface)
++{
++ return surface_create(wl_surface, id_surface);
++}
++
++void
++ivi_layout_surface_configure(struct ivi_layout_surface *ivisurf,
++ int32_t width, int32_t height)
++{
++ struct ivi_layout *layout = get_instance();
++
++ /* emit callback which is set by ivi-layout api user */
++ wl_signal_emit(&layout->surface_notification.configure_changed,
++ ivisurf);
++}
++
++struct ivi_layout_surface*
++ivi_layout_surface_create(struct weston_surface *wl_surface,
++ uint32_t id_surface)
++{
++ struct ivi_layout *layout = get_instance();
++ struct ivi_layout_surface *ivisurf = NULL;
++
++ ivisurf = get_surface(&layout->surface_list, id_surface);
++ if (ivisurf) {
++ weston_log("id_surface(%d) is already created\n", id_surface);
++ return NULL;
++ }
++
++ ivisurf = surface_create(wl_surface, id_surface);
++
++ if (ivisurf)
++ wl_signal_emit(&layout->surface_notification.created, ivisurf);
+
+ return ivisurf;
+ }
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0007-ivi-shell-linked-libweston-desktop-and-added-structs.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0007-ivi-shell-linked-libweston-desktop-and-added-structs.patch
new file mode 100644
index 000000000..9286ba00b
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0007-ivi-shell-linked-libweston-desktop-and-added-structs.patch
@@ -0,0 +1,74 @@
+diff --git a/Makefile.am b/Makefile.am
+index cdf82ab4..d990d400 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -993,6 +993,7 @@ ivi_shell_la_LDFLAGS = -module -avoid-version
+ ivi_shell_la_LIBADD = \
+ libshared.la \
+ libweston-@LIBWESTON_MAJOR@.la \
++ libweston-desktop-@LIBWESTON_MAJOR@.la \
+ $(COMPOSITOR_LIBS)
+ ivi_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
+ ivi_shell_la_SOURCES = \
+diff --git a/ivi-shell/ivi-layout-private.h b/ivi-shell/ivi-layout-private.h
+index fe5be01a..c054130b 100644
+--- a/ivi-shell/ivi-layout-private.h
++++ b/ivi-shell/ivi-layout-private.h
+@@ -30,6 +30,7 @@
+
+ #include "compositor.h"
+ #include "ivi-layout-export.h"
++#include "libweston-desktop/libweston-desktop.h"
+
+ struct ivi_layout_view {
+ struct wl_list link; /* ivi_layout::view_list */
+@@ -52,6 +53,7 @@ struct ivi_layout_surface {
+
+ struct ivi_layout *layout;
+ struct weston_surface *surface;
++ struct weston_desktop_surface *weston_desktop_surface;
+
+ struct ivi_layout_surface_properties prop;
+
+diff --git a/ivi-shell/ivi-shell.c b/ivi-shell/ivi-shell.c
+index f3156d35..84db2c97 100644
+--- a/ivi-shell/ivi-shell.c
++++ b/ivi-shell/ivi-shell.c
+@@ -44,7 +44,7 @@
+
+ #include "ivi-shell.h"
+ #include "ivi-application-server-protocol.h"
+-#include "ivi-layout-export.h"
++#include "ivi-layout-private.h"
+ #include "ivi-layout-shell.h"
+ #include "shared/helpers.h"
+ #include "compositor/weston.h"
+@@ -271,6 +271,8 @@ application_surface_create(struct wl_client *client,
+ return;
+ }
+
++ layout_surface->weston_desktop_surface = NULL;
++
+ ivisurf = zalloc(sizeof *ivisurf);
+ if (ivisurf == NULL) {
+ wl_resource_post_no_memory(resource);
+diff --git a/ivi-shell/ivi-shell.h b/ivi-shell/ivi-shell.h
+index e35f75f2..be430853 100644
+--- a/ivi-shell/ivi-shell.h
++++ b/ivi-shell/ivi-shell.h
+@@ -30,6 +30,7 @@
+ #include <stdint.h>
+
+ #include "compositor.h"
++#include "libweston-desktop/libweston-desktop.h"
+
+ struct ivi_shell
+ {
+@@ -37,6 +38,7 @@ struct ivi_shell
+
+ struct weston_compositor *compositor;
+
++ struct weston_desktop *desktop;
+ struct wl_list ivi_surface_list; /* struct ivi_shell_surface::link */
+
+ struct text_backend *text_backend;
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0008-ivi-layout-use-libweston-desktop-api-for-views.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0008-ivi-layout-use-libweston-desktop-api-for-views.patch
new file mode 100644
index 000000000..e53a8c458
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0008-ivi-layout-use-libweston-desktop-api-for-views.patch
@@ -0,0 +1,30 @@
+index 086d0fd2..6b854503 100644
+--- a/ivi-shell/ivi-layout.c
++++ b/ivi-shell/ivi-layout.c
+@@ -153,7 +153,10 @@ ivi_view_destroy(struct ivi_layout_view *ivi_view)
+ wl_list_remove(&ivi_view->pending_link);
+ wl_list_remove(&ivi_view->order_link);
+
+- weston_view_destroy(ivi_view->view);
++ if (weston_surface_is_desktop_surface(ivi_view->ivisurf->surface))
++ weston_desktop_surface_unlink_view(ivi_view->view);
++ else
++ weston_view_destroy(ivi_view->view);
+
+ free(ivi_view);
+ }
+@@ -170,7 +173,13 @@ ivi_view_create(struct ivi_layout_layer *ivilayer,
+ return NULL;
+ }
+
+- ivi_view->view = weston_view_create(ivisurf->surface);
++ if (weston_surface_is_desktop_surface(ivisurf->surface)) {
++ ivi_view->view = weston_desktop_surface_create_view(
++ ivisurf->weston_desktop_surface);
++ } else {
++ ivi_view->view = weston_view_create(ivisurf->surface);
++ }
++
+ if (ivi_view->view == NULL) {
+ weston_log("fails to allocate memory\n");
+ free(ivi_view);
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0009-ivi-shell-added-libweston-desktop-api_implementation.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0009-ivi-shell-added-libweston-desktop-api_implementation.patch
new file mode 100644
index 000000000..6a72f15d8
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0009-ivi-shell-added-libweston-desktop-api_implementation.patch
@@ -0,0 +1,166 @@
+index 84db2c97..e797e4f9 100644
+--- a/ivi-shell/ivi-shell.c
++++ b/ivi-shell/ivi-shell.c
+@@ -489,6 +489,162 @@ shell_add_bindings(struct weston_compositor *compositor,
+ shell);
+ }
+
++/*
++ * libweston-desktop
++ */
++
++static void
++desktop_surface_ping_timeout(struct weston_desktop_client *client,
++ void *user_data)
++{
++ weston_log("ivi-shell: desktop_surface_ping_timeout is not supported\n");
++}
++
++static void
++desktop_surface_pong(struct weston_desktop_client *client,
++ void *user_data)
++{
++ weston_log("ivi-shell: desktop_surface_pong is not supported\n");
++}
++
++static void
++desktop_surface_added(struct weston_desktop_surface *surface,
++ void *user_data)
++{
++ struct ivi_shell *shell = (struct ivi_shell *) user_data;
++ struct ivi_layout_surface *layout_surface;
++ struct ivi_shell_surface *ivisurf;
++ struct weston_surface *weston_surf =
++ weston_desktop_surface_get_surface(surface);
++
++ layout_surface = ivi_layout_desktop_surface_create(weston_surf,
++ IVI_INVALID_ID);
++ if (!layout_surface) {
++ return;
++ }
++
++ layout_surface->weston_desktop_surface = surface;
++
++ ivisurf = zalloc(sizeof *ivisurf);
++ if (!ivisurf) {
++ return;
++ }
++
++ ivisurf->shell = shell;
++ ivisurf->id_surface = IVI_INVALID_ID;
++
++ ivisurf->width = 0;
++ ivisurf->height = 0;
++ ivisurf->layout_surface = layout_surface;
++ ivisurf->surface = weston_surf;
++
++ weston_desktop_surface_set_user_data(surface, ivisurf);
++}
++
++static void
++desktop_surface_removed(struct weston_desktop_surface *surface,
++ void *user_data)
++{
++ struct ivi_shell_surface *ivisurf = (struct ivi_shell_surface *)
++ weston_desktop_surface_get_user_data(surface);
++
++ assert(ivisurf != NULL);
++
++ if (ivisurf->layout_surface)
++ layout_surface_cleanup(ivisurf);
++}
++
++static void
++desktop_surface_committed(struct weston_desktop_surface *surface,
++ int32_t sx, int32_t sy, void *user_data)
++{
++ struct ivi_shell_surface *ivisurf = (struct ivi_shell_surface *)
++ weston_desktop_surface_get_user_data(surface);
++ struct weston_surface *weston_surf =
++ weston_desktop_surface_get_surface(surface);
++
++ if(!ivisurf)
++ return;
++
++ if (weston_surf->width == 0 || weston_surf->height == 0)
++ return;
++
++ if (ivisurf->width != weston_surf->width ||
++ ivisurf->height != weston_surf->height) {
++ ivisurf->width = weston_surf->width;
++ ivisurf->height = weston_surf->height;
++
++ ivi_layout_desktop_surface_configure(ivisurf->layout_surface,
++ weston_surf->width,
++ weston_surf->height);
++ }
++}
++
++static void
++desktop_surface_move(struct weston_desktop_surface *surface,
++ struct weston_seat *seat, uint32_t serial, void *user_data)
++{
++ weston_log("ivi-shell: desktop_surface_move is not supported\n");
++}
++
++static void
++desktop_surface_resize(struct weston_desktop_surface *surface,
++ struct weston_seat *seat, uint32_t serial,
++ enum weston_desktop_surface_edge edges, void *user_data)
++{
++ weston_log("ivi-shell: desktop_surface_resize is not supported\n");
++}
++
++static void
++desktop_surface_fullscreen_requested(struct weston_desktop_surface *surface,
++ bool fullscreen,
++ struct weston_output *output,
++ void *user_data)
++{
++ weston_log("ivi-shell: desktop_surface_fullscreen_requested is not supported\n");
++}
++
++static void
++desktop_surface_maximized_requested(struct weston_desktop_surface *surface,
++ bool maximized, void *user_data)
++{
++ weston_log("ivi-shell: desktop_surface_maximized_requested is not supported\n");
++}
++
++static void
++desktop_surface_minimized_requested(struct weston_desktop_surface *surface,
++ void *user_data)
++{
++ weston_log("ivi-shell: desktop_surface_minimized_requested is not supported\n");
++}
++
++static void
++desktop_surface_set_xwayland_position(struct weston_desktop_surface *surface,
++ int32_t x, int32_t y, void *user_data)
++{
++ weston_log("ivi-shell: desktop_surface_set_xwayland_position is not supported\n");
++}
++
++static const struct weston_desktop_api shell_desktop_api = {
++ .struct_size = sizeof(struct weston_desktop_api),
++ .ping_timeout = desktop_surface_ping_timeout,
++ .pong = desktop_surface_pong,
++ .surface_added = desktop_surface_added,
++ .surface_removed = desktop_surface_removed,
++ .committed = desktop_surface_committed,
++
++ .move = desktop_surface_move,
++ .resize = desktop_surface_resize,
++ .fullscreen_requested = desktop_surface_fullscreen_requested,
++ .maximized_requested = desktop_surface_maximized_requested,
++ .minimized_requested = desktop_surface_minimized_requested,
++ .set_xwayland_position = desktop_surface_set_xwayland_position,
++};
++
++/*
++ * end of libweston-desktop
++ */
++
+ /*
+ * Initialization of ivi-shell.
+ */
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0010-ivi-shell-remove-surface_destroy_listener.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0010-ivi-shell-remove-surface_destroy_listener.patch
new file mode 100644
index 000000000..b76c35d4f
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0010-ivi-shell-remove-surface_destroy_listener.patch
@@ -0,0 +1,24 @@
+index e797e4f9..5f64e72d 100644
+--- a/ivi-shell/ivi-shell.c
++++ b/ivi-shell/ivi-shell.c
+@@ -162,6 +162,10 @@ layout_surface_cleanup(struct ivi_shell_surface *ivisurf)
+ {
+ assert(ivisurf->layout_surface != NULL);
+
++ /* destroy weston_surface destroy signal. */
++ if (!ivisurf->layout_surface->weston_desktop_surface)
++ wl_list_remove(&ivisurf->surface_destroy_listener.link);
++
+ ivi_layout_surface_destroy(ivisurf->layout_surface);
+ ivisurf->layout_surface = NULL;
+
+@@ -169,9 +173,6 @@ layout_surface_cleanup(struct ivi_shell_surface *ivisurf)
+ ivisurf->surface->committed_private = NULL;
+ weston_surface_set_label_func(ivisurf->surface, NULL);
+ ivisurf->surface = NULL;
+-
+- // destroy weston_surface destroy signal.
+- wl_list_remove(&ivisurf->surface_destroy_listener.link);
+ }
+
+ /*
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0011-ivi-shell-create-weston-desktop-in_wet_shell_init.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0011-ivi-shell-create-weston-desktop-in_wet_shell_init.patch
new file mode 100644
index 000000000..551e449ad
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0011-ivi-shell-create-weston-desktop-in_wet_shell_init.patch
@@ -0,0 +1,34 @@
+index 5f64e72d..dc8e6f1d 100644
+--- a/ivi-shell/ivi-shell.c
++++ b/ivi-shell/ivi-shell.c
+@@ -677,10 +677,14 @@ wet_shell_init(struct weston_compositor *compositor,
+ if (!shell->text_backend)
+ goto err_settings;
+
++ shell->desktop = weston_desktop_create(compositor, &shell_desktop_api, shell);
++ if (!shell->desktop)
++ goto err_text_backend;
++
+ if (wl_global_create(compositor->wl_display,
+ &ivi_application_interface, 1,
+ shell, bind_ivi_application) == NULL)
+- goto err_text_backend;
++ goto err_desktop;
+
+ ivi_layout_init_with_compositor(compositor);
+ /* TODO ivi_layout_destroy should be implemented, since multiple lists
+@@ -690,10 +694,13 @@ wet_shell_init(struct weston_compositor *compositor,
+ /* Call module_init of ivi-modules which are defined in weston.ini */
+ if (load_controller_modules(compositor, setting.ivi_module,
+ argc, argv) < 0)
+- goto err_text_backend;
++ goto err_desktop;
+
+ return IVI_SUCCEEDED;
+
++err_desktop:
++ weston_desktop_destroy(shell->desktop);
++
+ err_text_backend:
+ text_backend_destroy(shell->text_backend);
+
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0012-hmi-controller-register-for-desktop_surface_configured.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0012-hmi-controller-register-for-desktop_surface_configured.patch
new file mode 100644
index 000000000..c5d85bb17
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0012-hmi-controller-register-for-desktop_surface_configured.patch
@@ -0,0 +1,133 @@
+index d5403e06..7b2f2707 100644
+--- a/ivi-shell/hmi-controller.c
++++ b/ivi-shell/hmi-controller.c
+@@ -129,9 +129,9 @@ struct hmi_controller {
+ struct weston_compositor *compositor;
+ struct wl_listener destroy_listener;
+
+- struct wl_listener surface_created;
+ struct wl_listener surface_removed;
+ struct wl_listener surface_configured;
++ struct wl_listener desktop_surface_configured;
+
+ struct wl_client *user_interface;
+ struct ui_setting ui_setting;
+@@ -581,28 +581,6 @@ create_layer(struct weston_output *output,
+ /**
+ * Internal set notification
+ */
+-static void
+-set_notification_create_surface(struct wl_listener *listener, void *data)
+-{
+- struct hmi_controller *hmi_ctrl =
+- wl_container_of(listener, hmi_ctrl,
+- surface_created);
+- struct ivi_layout_surface *ivisurf = data;
+- struct hmi_controller_layer *layer_link =
+- wl_container_of(hmi_ctrl->application_layer_list.prev,
+- layer_link,
+- link);
+- struct ivi_layout_layer *application_layer = layer_link->ivilayer;
+- int32_t ret = 0;
+-
+- /* skip ui widgets */
+- if (is_surf_in_ui_widget(hmi_ctrl, ivisurf))
+- return;
+-
+- ret = ivi_layout_interface->layer_add_surface(application_layer, ivisurf);
+- assert(!ret);
+-}
+-
+ static void
+ set_notification_remove_surface(struct wl_listener *listener, void *data)
+ {
+@@ -670,6 +648,42 @@ set_notification_configure_surface(struct wl_listener *listener, void *data)
+ switch_mode(hmi_ctrl, hmi_ctrl->layout_mode);
+ }
+
++static void
++set_notification_configure_desktop_surface(struct wl_listener *listener, void *data)
++{
++ struct hmi_controller *hmi_ctrl =
++ wl_container_of(listener, hmi_ctrl,
++ desktop_surface_configured);
++ struct ivi_layout_surface *ivisurf = data;
++ struct hmi_controller_layer *layer_link =
++ wl_container_of(hmi_ctrl->application_layer_list.prev,
++ layer_link,
++ link);
++ struct ivi_layout_layer *application_layer = layer_link->ivilayer;
++ struct weston_surface *surface;
++ int32_t ret = 0;
++
++ /* skip ui widgets */
++ if (is_surf_in_ui_widget(hmi_ctrl, ivisurf))
++ return;
++
++ ret = ivi_layout_interface->layer_add_surface(application_layer, ivisurf);
++ assert(!ret);
++
++ /*
++ * if application changes size of wl_buffer. The source rectangle shall be
++ * fit to the size.
++ */
++ surface = ivi_layout_interface->surface_get_weston_surface(ivisurf);
++ if (surface) {
++ ivi_layout_interface->surface_set_source_rectangle(ivisurf, 0,
++ 0, surface->width, surface->height);
++ }
++
++ ivi_layout_interface->commit_changes();
++ switch_mode(hmi_ctrl, hmi_ctrl->layout_mode);
++}
++
+ /**
+ * A hmi_controller used 4 ivi_layers to manage ivi_surfaces. The IDs of
+ * corresponding ivi_layer are defined in weston.ini. Default scene graph
+@@ -852,6 +866,9 @@ hmi_controller_create(struct weston_compositor *ec)
+ hmi_ctrl->surface_configured.notify = set_notification_configure_surface;
+ ivi_layout_interface->add_listener_configure_surface(&hmi_ctrl->surface_configured);
+
++ hmi_ctrl->desktop_surface_configured.notify = set_notification_configure_desktop_surface;
++ ivi_layout_interface->add_listener_configure_desktop_surface(&hmi_ctrl->desktop_surface_configured);
++
+ hmi_ctrl->destroy_listener.notify = hmi_controller_destroy;
+ wl_signal_add(&hmi_ctrl->compositor->destroy_signal,
+ &hmi_ctrl->destroy_listener);
+@@ -1275,13 +1292,6 @@ ivi_hmi_controller_UI_ready(struct wl_client *client,
+ ivi_layout_interface->commit_changes();
+
+ ivi_hmi_controller_add_launchers(hmi_ctrl, 256);
+-
+- /* Add surface_created listener after the initialization of launchers.
+- * Otherwise, surfaces of the launchers will be added to application
+- * layer too.*/
+- hmi_ctrl->surface_created.notify = set_notification_create_surface;
+- ivi_layout_interface->add_listener_create_surface(&hmi_ctrl->surface_created);
+-
+ hmi_ctrl->is_initialized = 1;
+ }
+
+diff --git a/ivi-shell/ivi-layout.c b/ivi-shell/ivi-layout.c
+index 6b854503..22d63708 100644
+--- a/ivi-shell/ivi-layout.c
++++ b/ivi-shell/ivi-layout.c
+@@ -787,9 +787,15 @@ commit_surface_list(struct ivi_layout *layout)
+ ivisurf->pending.prop.transition_type = IVI_LAYOUT_TRANSITION_NONE;
+
+ if (configured && !is_surface_transition(ivisurf)) {
+- shell_surface_send_configure(ivisurf->surface,
+- ivisurf->prop.dest_width,
+- ivisurf->prop.dest_height);
++ if (ivisurf->weston_desktop_surface) {
++ weston_desktop_surface_set_size(ivisurf->weston_desktop_surface,
++ ivisurf->prop.dest_width,
++ ivisurf->prop.dest_height);
++ } else {
++ shell_surface_send_configure(ivisurf->surface,
++ ivisurf->prop.dest_width,
++ ivisurf->prop.dest_height);
++ }
+ }
+ } else {
+ configured = 0;
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0013-simple-egl-remove-ivi-application-support.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0013-simple-egl-remove-ivi-application-support.patch
new file mode 100644
index 000000000..8094f9b85
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0013-simple-egl-remove-ivi-application-support.patch
@@ -0,0 +1,164 @@
+index 23f79dfe..f9c8010b 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -616,9 +616,7 @@ demo_clients += weston-simple-egl
+ weston_simple_egl_SOURCES = clients/simple-egl.c
+ nodist_weston_simple_egl_SOURCES = \
+ protocol/xdg-shell-unstable-v6-protocol.c \
+- protocol/xdg-shell-unstable-v6-client-protocol.h \
+- protocol/ivi-application-protocol.c \
+- protocol/ivi-application-client-protocol.h
++ protocol/xdg-shell-unstable-v6-client-protocol.h
+ weston_simple_egl_CFLAGS = $(AM_CFLAGS) $(SIMPLE_EGL_CLIENT_CFLAGS)
+ weston_simple_egl_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
+ endif
+diff --git a/clients/simple-egl.c b/clients/simple-egl.c
+index dad0f09b..07e7e785 100644
+--- a/clients/simple-egl.c
++++ b/clients/simple-egl.c
+@@ -45,8 +45,6 @@
+ #include "xdg-shell-unstable-v6-client-protocol.h"
+ #include <sys/types.h>
+ #include <unistd.h>
+-#include "ivi-application-client-protocol.h"
+-#define IVI_SURFACE_ID 9000
+
+ #include "shared/helpers.h"
+ #include "shared/platform.h"
+@@ -74,7 +72,6 @@ struct display {
+ EGLConfig conf;
+ } egl;
+ struct window *window;
+- struct ivi_application *ivi_application;
+
+ PFNEGLSWAPBUFFERSWITHDAMAGEEXTPROC swap_buffers_with_damage;
+ };
+@@ -97,7 +94,6 @@ struct window {
+ struct wl_surface *surface;
+ struct zxdg_surface_v6 *xdg_surface;
+ struct zxdg_toplevel_v6 *xdg_toplevel;
+- struct ivi_surface *ivi_surface;
+ EGLSurface egl_surface;
+ struct wl_callback *callback;
+ int fullscreen, opaque, buffer_size, frame_sync, delay;
+@@ -355,27 +351,22 @@ static const struct zxdg_toplevel_v6_listener xdg_toplevel_listener = {
+ };
+
+ static void
+-handle_ivi_surface_configure(void *data, struct ivi_surface *ivi_surface,
+- int32_t width, int32_t height)
++create_surface(struct window *window)
+ {
+- struct window *window = data;
+-
+- wl_egl_window_resize(window->native, width, height, 0, 0);
+-
+- window->geometry.width = width;
+- window->geometry.height = height;
++ struct display *display = window->display;
++ EGLBoolean ret;
+
+- if (!window->fullscreen)
+- window->window_size = window->geometry;
+-}
++ window->surface = wl_compositor_create_surface(display->compositor);
+
+-static const struct ivi_surface_listener ivi_surface_listener = {
+- handle_ivi_surface_configure,
+-};
++ window->native =
++ wl_egl_window_create(window->surface,
++ window->geometry.width,
++ window->geometry.height);
++ window->egl_surface =
++ weston_platform_create_egl_surface(display->egl.dpy,
++ display->egl.conf,
++ window->native, NULL);
+
+-static void
+-create_xdg_surface(struct window *window, struct display *display)
+-{
+ window->xdg_surface = zxdg_shell_v6_get_xdg_surface(display->shell,
+ window->surface);
+ zxdg_surface_v6_add_listener(window->xdg_surface,
+@@ -390,50 +381,6 @@ create_xdg_surface(struct window *window, struct display *display)
+
+ window->wait_for_configure = true;
+ wl_surface_commit(window->surface);
+-}
+-
+-static void
+-create_ivi_surface(struct window *window, struct display *display)
+-{
+- uint32_t id_ivisurf = IVI_SURFACE_ID + (uint32_t)getpid();
+- window->ivi_surface =
+- ivi_application_surface_create(display->ivi_application,
+- id_ivisurf, window->surface);
+-
+- if (window->ivi_surface == NULL) {
+- fprintf(stderr, "Failed to create ivi_client_surface\n");
+- abort();
+- }
+-
+- ivi_surface_add_listener(window->ivi_surface,
+- &ivi_surface_listener, window);
+-}
+-
+-static void
+-create_surface(struct window *window)
+-{
+- struct display *display = window->display;
+- EGLBoolean ret;
+-
+- window->surface = wl_compositor_create_surface(display->compositor);
+-
+- window->native =
+- wl_egl_window_create(window->surface,
+- window->geometry.width,
+- window->geometry.height);
+- window->egl_surface =
+- weston_platform_create_egl_surface(display->egl.dpy,
+- display->egl.conf,
+- window->native, NULL);
+-
+-
+- if (display->shell) {
+- create_xdg_surface(window, display);
+- } else if (display->ivi_application ) {
+- create_ivi_surface(window, display);
+- } else {
+- assert(0);
+- }
+
+ ret = eglMakeCurrent(window->display->egl.dpy, window->egl_surface,
+ window->egl_surface, window->display->egl.ctx);
+@@ -465,8 +412,6 @@ destroy_surface(struct window *window)
+ zxdg_toplevel_v6_destroy(window->xdg_toplevel);
+ if (window->xdg_surface)
+ zxdg_surface_v6_destroy(window->xdg_surface);
+- if (window->display->ivi_application)
+- ivi_surface_destroy(window->ivi_surface);
+ wl_surface_destroy(window->surface);
+
+ if (window->callback)
+@@ -821,10 +766,6 @@ registry_handle_global(void *data, struct wl_registry *registry,
+ fprintf(stderr, "unable to load default left pointer\n");
+ // TODO: abort ?
+ }
+- } else if (strcmp(interface, "ivi_application") == 0) {
+- d->ivi_application =
+- wl_registry_bind(registry, name,
+- &ivi_application_interface, 1);
+ }
+ }
+
+@@ -939,9 +880,6 @@ main(int argc, char **argv)
+ if (display.shell)
+ zxdg_shell_v6_destroy(display.shell);
+
+- if (display.ivi_application)
+- ivi_application_destroy(display.ivi_application);
+-
+ if (display.compositor)
+ wl_compositor_destroy(display.compositor);
+
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0014-simple-shm-remove-ivi-application-support.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0014-simple-shm-remove-ivi-application-support.patch
new file mode 100644
index 000000000..495e50ca2
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0014-simple-shm-remove-ivi-application-support.patch
@@ -0,0 +1,107 @@
+index f9c8010b..c37cd00b 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -574,9 +574,7 @@ nodist_weston_simple_shm_SOURCES = \
+ protocol/xdg-shell-unstable-v6-protocol.c \
+ protocol/xdg-shell-unstable-v6-client-protocol.h \
+ protocol/fullscreen-shell-unstable-v1-protocol.c \
+- protocol/fullscreen-shell-unstable-v1-client-protocol.h \
+- protocol/ivi-application-protocol.c \
+- protocol/ivi-application-client-protocol.h
++ protocol/fullscreen-shell-unstable-v1-client-protocol.h
+ weston_simple_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
+ weston_simple_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
+
+diff --git a/clients/simple-shm.c b/clients/simple-shm.c
+index 9fa2e214..fc2ef001 100644
+--- a/clients/simple-shm.c
++++ b/clients/simple-shm.c
+@@ -40,10 +40,6 @@
+ #include "xdg-shell-unstable-v6-client-protocol.h"
+ #include "fullscreen-shell-unstable-v1-client-protocol.h"
+
+-#include <sys/types.h>
+-#include "ivi-application-client-protocol.h"
+-#define IVI_SURFACE_ID 9000
+-
+ struct display {
+ struct wl_display *display;
+ struct wl_registry *registry;
+@@ -52,7 +48,6 @@ struct display {
+ struct zwp_fullscreen_shell_v1 *fshell;
+ struct wl_shm *shm;
+ bool has_xrgb;
+- struct ivi_application *ivi_application;
+ };
+
+ struct buffer {
+@@ -67,7 +62,6 @@ struct window {
+ struct wl_surface *surface;
+ struct zxdg_surface_v6 *xdg_surface;
+ struct zxdg_toplevel_v6 *xdg_toplevel;
+- struct ivi_surface *ivi_surface;
+ struct buffer buffers[2];
+ struct buffer *prev_buffer;
+ struct wl_callback *callback;
+@@ -165,17 +159,6 @@ static const struct zxdg_toplevel_v6_listener xdg_toplevel_listener = {
+ handle_xdg_toplevel_close,
+ };
+
+-static void
+-handle_ivi_surface_configure(void *data, struct ivi_surface *ivi_surface,
+- int32_t width, int32_t height)
+-{
+- /* Simple-shm is resizable */
+-}
+-
+-static const struct ivi_surface_listener ivi_surface_listener = {
+- handle_ivi_surface_configure,
+-};
+-
+ static struct window *
+ create_window(struct display *display, int width, int height)
+ {
+@@ -213,19 +196,6 @@ create_window(struct display *display, int width, int height)
+ window->surface,
+ ZWP_FULLSCREEN_SHELL_V1_PRESENT_METHOD_DEFAULT,
+ NULL);
+- } else if (display->ivi_application ) {
+- uint32_t id_ivisurf = IVI_SURFACE_ID + (uint32_t)getpid();
+- window->ivi_surface =
+- ivi_application_surface_create(display->ivi_application,
+- id_ivisurf, window->surface);
+- if (window->ivi_surface == NULL) {
+- fprintf(stderr, "Failed to create ivi_client_surface\n");
+- abort();
+- }
+-
+- ivi_surface_add_listener(window->ivi_surface,
+- &ivi_surface_listener, window);
+-
+ } else {
+ assert(0);
+ }
+@@ -407,11 +377,6 @@ registry_handle_global(void *data, struct wl_registry *registry,
+ id, &wl_shm_interface, 1);
+ wl_shm_add_listener(d->shm, &shm_listener, d);
+ }
+- else if (strcmp(interface, "ivi_application") == 0) {
+- d->ivi_application =
+- wl_registry_bind(registry, id,
+- &ivi_application_interface, 1);
+- }
+ }
+
+ static void
+@@ -555,11 +520,6 @@ main(int argc, char **argv)
+
+ fprintf(stderr, "simple-shm exiting\n");
+
+- if (window->display->ivi_application) {
+- ivi_surface_destroy(window->ivi_surface);
+- ivi_application_destroy(window->display->ivi_application);
+- }
+-
+ destroy_window(window);
+ destroy_display(display);
+
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0015-window-client-remove-ivi-application-support.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0015-window-client-remove-ivi-application-support.patch
new file mode 100644
index 000000000..f3d2fe47f
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0015-window-client-remove-ivi-application-support.patch
@@ -0,0 +1,130 @@
+index c37cd00b..f30ddbe9 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -665,8 +665,6 @@ nodist_libtoytoolkit_la_SOURCES = \
+ protocol/viewporter-client-protocol.h \
+ protocol/xdg-shell-unstable-v6-protocol.c \
+ protocol/xdg-shell-unstable-v6-client-protocol.h \
+- protocol/ivi-application-protocol.c \
+- protocol/ivi-application-client-protocol.h \
+ protocol/pointer-constraints-unstable-v1-protocol.c \
+ protocol/pointer-constraints-unstable-v1-client-protocol.h \
+ protocol/relative-pointer-unstable-v1-protocol.c \
+diff --git a/clients/window.c b/clients/window.c
+index 95796d46..aac43abd 100644
+--- a/clients/window.c
++++ b/clients/window.c
+@@ -82,10 +82,6 @@ typedef void *EGLContext;
+
+ #include "window.h"
+
+-#include <sys/types.h>
+-#include "ivi-application-client-protocol.h"
+-#define IVI_SURFACE_ID 9000
+-
+ #define ZWP_RELATIVE_POINTER_MANAGER_V1_VERSION 1
+ #define ZWP_POINTER_CONSTRAINTS_V1_VERSION 1
+
+@@ -107,7 +103,6 @@ struct display {
+ struct wl_data_device_manager *data_device_manager;
+ struct text_cursor_position *text_cursor_position;
+ struct zxdg_shell_v6 *xdg_shell;
+- struct ivi_application *ivi_application; /* ivi style shell */
+ struct zwp_relative_pointer_manager_v1 *relative_pointer_manager;
+ struct zwp_pointer_constraints_v1 *pointer_constraints;
+ EGLDisplay dpy;
+@@ -269,8 +264,6 @@ struct window {
+ struct window *parent;
+ struct window *last_parent;
+
+- struct ivi_surface *ivi_surface;
+-
+ struct window_frame *frame;
+
+ /* struct surface::link, contains also main_surface */
+@@ -1441,19 +1434,6 @@ window_get_display(struct window *window)
+ return window->display;
+ }
+
+-static void
+-handle_ivi_surface_configure(void *data, struct ivi_surface *ivi_surface,
+- int32_t width, int32_t height)
+-{
+- struct window *window = data;
+-
+- window_schedule_resize(window, width, height);
+-}
+-
+-static const struct ivi_surface_listener ivi_surface_listener = {
+- handle_ivi_surface_configure,
+-};
+-
+ static void
+ surface_create_surface(struct surface *surface, uint32_t flags)
+ {
+@@ -1604,9 +1584,6 @@ window_destroy(struct window *window)
+ if (window->xdg_surface)
+ zxdg_surface_v6_destroy(window->xdg_surface);
+
+- if (window->ivi_surface)
+- ivi_surface_destroy(window->ivi_surface);
+-
+ surface_destroy(window->main_surface);
+
+ wl_list_remove(&window->link);
+@@ -5200,7 +5177,7 @@ window_create_internal(struct display *display, int custom)
+ surface = surface_create(window);
+ window->main_surface = surface;
+
+- assert(custom || display->xdg_shell || display->ivi_application);
++ assert(custom || display->xdg_shell);
+
+ window->custom = custom;
+ window->preferred_format = WINDOW_PREFERRED_FORMAT_NONE;
+@@ -5220,7 +5197,6 @@ struct window *
+ window_create(struct display *display)
+ {
+ struct window *window;
+- uint32_t id_ivisurf;
+
+ window = window_create_internal(display, 0);
+
+@@ -5243,16 +5219,6 @@ window_create(struct display *display)
+ window_inhibit_redraw(window);
+
+ wl_surface_commit(window->main_surface->surface);
+- } else if (display->ivi_application) {
+- /* auto generation of ivi_id based on process id + basement of id */
+- id_ivisurf = IVI_SURFACE_ID + (uint32_t)getpid();
+- window->ivi_surface =
+- ivi_application_surface_create(display->ivi_application,
+- id_ivisurf, window->main_surface->surface);
+- fail_on_null(window->ivi_surface, 0, __FILE__, __LINE__);
+-
+- ivi_surface_add_listener(window->ivi_surface,
+- &ivi_surface_listener, window);
+ }
+
+ return window;
+@@ -6013,11 +5979,6 @@ registry_handle_global(void *data, struct wl_registry *registry, uint32_t id,
+ wl_registry_bind(registry, id,
+ &wl_subcompositor_interface, 1);
+ }
+- else if (strcmp(interface, "ivi_application") == 0) {
+- d->ivi_application =
+- wl_registry_bind(registry, id,
+- &ivi_application_interface, 1);
+- }
+
+ if (d->global_handler)
+ d->global_handler(d, id, interface, version, d->user_data);
+@@ -6316,9 +6277,6 @@ display_destroy(struct display *display)
+ if (display->xdg_shell)
+ zxdg_shell_v6_destroy(display->xdg_shell);
+
+- if (display->ivi_application)
+- ivi_application_destroy(display->ivi_application);
+-
+ if (display->shm)
+ wl_shm_destroy(display->shm);
+
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0016-ivi-shell_add_screen_remove_layer_api.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0016-ivi-shell_add_screen_remove_layer_api.patch
new file mode 100644
index 000000000..3e85e93f6
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0016-ivi-shell_add_screen_remove_layer_api.patch
@@ -0,0 +1,82 @@
+From deee858b0b199d8cfa8033a46d7078f30b23725e Mon Sep 17 00:00:00 2001
+From: "Ucan, Emre (ADITG/SW1)" <eucan@de.adit-jv.com>
+Date: Thu, 2 Mar 2017 08:47:33 +0000
+Subject: ivi-shell: add_screen_remove_layer API
+
+It is analagous to layer_remove_surface API.
+The API removes a layer from the render order
+of the screen.
+
+v3:
+add the new vfunc at the end of
+the ivi_layout_interface struct.
+
+Signed-off-by: Emre Ucan <eucan@de.adit-jv.com>
+Reviewed-by: Eugen Friedrich <friedrix@gmail.com>
+Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
+
+diff --git a/ivi-shell/ivi-layout-export.h b/ivi-shell/ivi-layout-export.h
+index 2317d6e..39ffde1 100644
+--- a/ivi-shell/ivi-layout-export.h
++++ b/ivi-shell/ivi-layout-export.h
+@@ -578,6 +578,16 @@ struct ivi_layout_interface {
+ */
+ struct ivi_layout_surface *
+ (*get_surface)(struct weston_surface *surface);
++
++ /**
++ * \brief Remove a ivi_layer to a weston_output which is currently managed
++ * by the service
++ *
++ * \return IVI_SUCCEEDED if the method call was successful
++ * \return IVI_FAILED if the method call was failed
++ */
++ int32_t (*screen_remove_layer)(struct weston_output *output,
++ struct ivi_layout_layer *removelayer);
+ };
+
+ #ifdef __cplusplus
+diff --git a/ivi-shell/ivi-layout.c b/ivi-shell/ivi-layout.c
+index 298e18e..8e4280b 100644
+--- a/ivi-shell/ivi-layout.c
++++ b/ivi-shell/ivi-layout.c
+@@ -1664,6 +1664,27 @@ ivi_layout_screen_add_layer(struct weston_output *output,
+ }
+
+ static int32_t
++ivi_layout_screen_remove_layer(struct weston_output *output,
++ struct ivi_layout_layer *removelayer)
++{
++ struct ivi_layout_screen *iviscrn;
++
++ if (output == NULL || removelayer == NULL) {
++ weston_log("ivi_layout_screen_remove_layer: invalid argument\n");
++ return IVI_FAILED;
++ }
++
++ iviscrn = get_screen_from_output(output);
++
++ wl_list_remove(&removelayer->pending.link);
++ wl_list_init(&removelayer->pending.link);
++
++ iviscrn->order.dirty = 1;
++
++ return IVI_SUCCEEDED;
++}
++
++static int32_t
+ ivi_layout_screen_set_render_order(struct weston_output *output,
+ struct ivi_layout_layer **pLayer,
+ const int32_t number)
+@@ -2088,6 +2109,7 @@ static struct ivi_layout_interface ivi_layout_interface = {
+ */
+ .get_screens_under_layer = ivi_layout_get_screens_under_layer,
+ .screen_add_layer = ivi_layout_screen_add_layer,
++ .screen_remove_layer = ivi_layout_screen_remove_layer,
+ .screen_set_render_order = ivi_layout_screen_set_render_order,
+
+ /**
+--
+cgit v0.10.2
+
+
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston_2.0.0.bbappend b/meta-agl-profile-graphical/recipes-graphics/wayland/weston_2.0.0.bbappend
new file mode 100644
index 000000000..f6f88a6d6
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston_2.0.0.bbappend
@@ -0,0 +1,23 @@
+FILESEXTRAPATHS_append := ":${THISDIR}/${PN}"
+
+SRC_URI_append = "\
+ file://0001-Allow-regular-users-to-launch-Weston_2.0.0.patch \
+ file://0001-ivi-shell-rework-goto-labels-to-avoid-memory-leaks.patch \
+ file://0002-ivi-shell-removed-assert.patch \
+ file://0003-ivi-shell-introduction-of-IVI_INVALID_ID.patch \
+ file://0004-layout-interface-added-interface-to-change-surface-id.patch \
+ file://0005-ivi-layout-introcuded-configure_desktop_changed.patch \
+ file://0006-ivi-layout-introcuded-surface_create_and_configure.patch \
+ file://0007-ivi-shell-linked-libweston-desktop-and-added-structs.patch \
+ file://0008-ivi-layout-use-libweston-desktop-api-for-views.patch \
+ file://0009-ivi-shell-added-libweston-desktop-api_implementation.patch \
+ file://0010-ivi-shell-remove-surface_destroy_listener.patch \
+ file://0011-ivi-shell-create-weston-desktop-in_wet_shell_init.patch \
+ file://0012-hmi-controller-register-for-desktop_surface_configured.patch \
+ file://0013-simple-egl-remove-ivi-application-support.patch \
+ file://0014-simple-shm-remove-ivi-application-support.patch \
+ file://0015-window-client-remove-ivi-application-support.patch \
+ file://0016-ivi-shell_add_screen_remove_layer_api.patch \
+ "
+
+EXTRA_OECONF_append = " --enable-sys-uid"