X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=recipes-graphics%2Fweb-runtime%2Fweb-runtime%2Fweb-runtime;h=39f3781bbca5c6e5f81f3a0fa3325f042fff929e;hb=c60877d5323111e090dbfe6ae0a0a394c333722a;hp=80685eb81e464aaf3ae2f06dd856ede6888530ee;hpb=f0b5fd39013abe170222051f91589a6db6616770;p=AGL%2Fmeta-agl-demo.git diff --git a/recipes-graphics/web-runtime/web-runtime/web-runtime b/recipes-graphics/web-runtime/web-runtime/web-runtime index 80685eb81..39f3781bb 100755 --- a/recipes-graphics/web-runtime/web-runtime/web-runtime +++ b/recipes-graphics/web-runtime/web-runtime/web-runtime @@ -1,2 +1,18 @@ -#!/bin/sh -exec /usr/bin/qt5/qmlscene "$1" /usr/bin/web-runtime.qml +#!/bin/bash +export -n QT_WAYLAND_SHELL_INTEGRATION +port=$(echo -n "$1" | sed 's,.*local.*:\([^/]*\)/.*,\1,') +token=$(echo -n "$1" | sed 's,.*token=,,') +export AFM_APP_INSTALL_DIR=$(mktemp -d) +cat << EOC > $AFM_APP_INSTALL_DIR/runxdg.toml +[application] +role = "WebBrowser" +method = "POSIX" +path = "/usr/bin/qt5/qmlscene" +params = [ + "$1", + "/usr/bin/web-runtime.qml" +] +EOC +export LD_PRELOAD=/usr/lib/libEGL.so +/usr/bin/runxdg "$port" "$token" +rm -rf $AFM_APP_INSTALL_DIR