igalia / cog Goto Github PK
View Code? Open in Web Editor NEWWPE launcher and webapp container
License: MIT License
WPE launcher and webapp container
License: MIT License
By default WebKit already keeps cookies in transient storage around (otherwise many websites would not work), but it would be good to allow enabling persistent storage of the cookies. In general, it would be great to expose the functionality of WebKitCookieManager:
$XDG_CONFIG_HOME
).Because it is just much better to have tests.
I install cog and wpebackend-rdk on raspberrypi 3 using buildroot. Everything works fine, but
I don't know how to set up encoding correctly. Czech characters are not displayed properly (ě ř dispay as squares and other ščžýáíé is displayed correctly.) i try set system locales to en_US.UTF-8 and cz_CZ.UTF-8, load local html files in utf-8 and ascii encoding and problem still persist.
Don't you know what I'm doing wrong?
Thanks for help.
After #38 it can happen that the checks succeed, yet building the FDO platform module won't be possible due wayland-egl
. It would be interesting to use CHECK_FUNCTION_EXISTS() to make sure that the needed functions can be linked in. Probably checking for wl_egl_create_window()
is enough — I would expect that if that is usable, the other ones will be available as well.
Is transparent background supported with the Cog Launcher?
I'm trying to run application on the imx6 where gstreamer is sending video to the /dev/fb0 and I need to have a transparent UI that would be drawn on the /dev/fb1.
Currently, even if a platform plug-in is loaded (e.g. passing --platform=fdo
in the command line), it is still needed to have around a libWPEBackend-default.so
shared object, which typically is a symlink to the actual WPE backend being used.
Ideally, when using a Cog platform plug-in, libWPEBackend-default.so
should not be needed at all — though of course it could be still be used when running without any platform plug-in.
It would be interesting for quick prototyping/testing to have a CLI option to specify a directory from which to load Web Extensions, e.g. --web-extensions-dir=PATH
.
Support for WebDriver is present in WPE WebKit, but currently cannot be used. Cog needs to support being launched in “automation mode”, e.g. with an --automation
command line flag.
With #84 Cog gained initial support for granting site permission requests; it added the following command line option:
--set-permissions=all
— grants any permission that any website requests.--set-permissions=none
— denies all permissions for any website.It would be desirable to allow specifying which permissions are to be automatically granted and for which domains. The idea is to reuse --set-permissions=
passing it a value different than all
or none
:
--set-permissions=spec[;spec[;…]]
.domain:permission[,permission[,…]]
element.where domain
can be:
gist.github.com
).*
) meaning “any domain”.*github.com
) meaning “the github.com domain or any of its subdomains”.*.github.com
) meaning “any subdomain of github.com but not github.com itself”.and permission
can be:
geolocation
(corresponding to WebKitGeolocationPermissionRequest).install-missing-media-plugin
(for WebKitInstallMissingMediaPluginsPermissionRequest).notification
(for WebKitNotificationPermissionRequest).audio
(for WebKitUserMediaPermissionRequest with is-for-audio-device
set to TRUE
).video
(for WebKitUserMediaPermissionRequest with is-for-video-device
set to TRUE
).Currently, the FDO platform plug-in hardcodes a set of key bindings (e.g. Alt+Left
and Alt+Right
to navigate back and forth, see #20 for example), but the correct thing to do would be to provide API in libcogcore
to install a set of key bindings in a generic way.
(cog:1490): GLib-GObject-WARNING **: ../../glib-2.46.2/gobject/gsignal.c:2516: signal 'web-process-crashed' is invalid for instance '0x18a80c8' of type 'WebKitWebView'
Hello!
I am experiencing a memory leak in Cog. It's memory usage grows by about 25 MB/hour. The attached graph shows the available system memory along with with the memory consumed by Cog, WPEWebProcess and WPENetworkProcess individually, over a period of about 20 hours.
I am running a Qualcomm Snapdragon SD-410, with the latest Cog and WPE from meta-webkit as of yesterday (b12d42). This means commit 063df1 of Cog and version 2.22.0-r0 of WPEWebKit.
I am starting cog with these variables and arguments
[Service]
Environment=XDG_RUNTIME_DIR=/data/xdg_runtime_dir
Environment=COG_PLATFORM_FDO_VIEW_FULLSCREEN=1
Environment=WEBKIT_INSPECTOR_SERVER=0.0.0.0:2999
Environment=WPE_RAM_SIZE=128m
Environment=WPE_POLL_MAX_MEMORY=databaseprocess:50m,networkprocess:100m,webprocess:300m,rpcprocess:50m
Environment=MSE_MAX_BUFFER_SIZE=audio:2m,video:15m,text:1m
ExecStart=/usr/bin/cog -P fdo --enable-write-console-messages-to-stdout=true <url>
The page being displayed is of relatively low-resolution images scrolling horizontally using canvas, but the issue has also been observed when using css transforms.
Any help in finding the source of this problem is greatly appreciated!
Now that #60 is merged, and we are using libwpe
's support to set the name of the library that contains the backend implementation, it would be good to move the fall-back code that instantiates the default WPE backend as fall-back (in cog.c
, function on_create_view
) into its own platform plug-in, which sets the implementation library to libWPEBackend-default.so
.
Some ideas and notes on how this could be (IMHO) nicely done:
WebKitSettings
, we could derive the keys allowed in the configuration file from GObject
properties.GObject
properties of a certain class, e.g. [websettings]
applies to the properties of WebKitSettings
, [general]
could apply to CogSettings
(which of course does not exist at the moment), and so on.Hi, I'm trying to open Youtube links e.g. cog -P fdo https://www.youtube.com/watch?v=-6_0XRRHAFU
but am getting this error on the Youtube page:
Your browser does not currently recognize any of the video formats available
I'm using WPE Webkit compiled from the 2.24.2 tarball, with these enabled features:
-- Enabled features:
-- ENABLE_ACCELERATED_2D_CANVAS ........... OFF
-- ENABLE_ENCRYPTED_MEDIA OFF
-- ENABLE_GTKDOC .......................... OFF
-- ENABLE_MEDIA_SOURCE ON
-- ENABLE_VIDEO ........................... ON
-- ENABLE_WEBDRIVER ON
-- ENABLE_WEB_AUDIO ....................... ON
-- ENABLE_WEB_CRYPTO ON
-- ENABLE_WPE_QT_API ...................... OFF
-- ENABLE_XSLT ON
-- USE_OPENJPEG ........................... ON
-- USE_WOFF2 ON
Is there some other setting required to make Youtube playback work?
Something like WebKitGTK's MiniBrowser would be nice to have, along with a --help-websettings
option.
Use-case: cog -P fdo http://foo:[email protected]
Expected behavior: Page displays
Current behavior: White page
The problem is that in cog_uri_guess_from_user_input
we use soup_uri_to_string()
which, as documented, strips the password out.
I would like to startup a webpage using COG, if the page doesn't load or stops loading due to;
Is there a flag, to retry or refresh? If not, I can test prior but it would be nice.
Most likely the best approach would be to use GTK-Doc.
Currently Cog supports only a single web view, and it would be interesting to provide support for more than one. In my mind, the minimum that needs to be done is:
CogShell
to contain more than a single web view, one of them considered to be the “active” one.CogShell
to:
CogLauncher
.cogctl
for managing multiple web views.The simplest implementation (on the platform plug-in side) would be to only display frames coming from the active view, and keeping around the most recent frame from the other views, so it can be used as the first frame shown when the active view is changed.
There is one problem: when using the fall-back WPE “default” view backend (that is: no platform plug-in is used), we cannot know what the WPE backend implementation will do, therefore in that case I think the safest approach would be disallow creating more than one web view.
This would be useful for hardening Cog in installations where only fixed set of services is allowed to be used. Enforcing this would reduce the risk e.g. of accidentally leaking information to servers outside of the allowed set.
While the best way to go about this would be having support for “content extensions” in WebKit (see bug #167941, it is already possible today by using WebKitWebPage::send-request in a Web Extension.
Instead of installing platforms modules (e.g. libcogplatform-fdo.so
) into $PREFIX/lib/
as if they were shared libraries, we should be installing them into their own subdir, e.g. $PREFIX/lib/cog-$APIVERSION/
.
Attempting to build cog against trunk I got this error since yesterday:
| FAILED: CMakeFiles/cog.dir/cog.c.o
| /home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-gcc -DCOG_INSIDE_COG__=1 -DG_LOG_DOMAIN=\"Cog\" -I. -I/home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/git/core -I/home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot/usr/include/wpe-webkit-0.1 -I/home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot/usr/include/libsoup-2.4 -I/home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot/usr/include/libxml2 -I/home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot/usr/include/glib-2.0 -I/home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot/usr/lib/glib-2.0/include -I/home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot/usr/include/wpe-0.2 -march=armv7-a -mthumb -mfpu=neon -mfloat-abi=hard -fstack-protector-strong -D_FORTIFY_SOURCE=2 -Wformat -Wformat-security -Werror=format-security --sysroot=/home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot -O2 -pipe -g -feliminate-unused-debug-types -fdebug-prefix-map=/home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0=/usr/src/debug/cog/gitAUTOINC-r0 -fdebug-prefix-map=/home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot= -fdebug-prefix-map=/home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot-native= -march=armv7-a -mthumb -mfpu=neon -mfloat-abi=hard -fstack-protector-strong -D_FORTIFY_SOURCE=2 -Wformat -Wformat-security -Werror=format-security --sysroot=/home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot -pthread -std=gnu99 -MD -MT CMakeFiles/cog.dir/cog.c.o -MF CMakeFiles/cog.dir/cog.c.o.d -o CMakeFiles/cog.dir/cog.c.o -c /home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/git/cog.c
| In file included from /home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot/usr/include/wpe-webkit-0.1/wpe/webkit.h:72,
| from /home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/git/core/cog-webkit-utils.h:20,
| from /home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/git/core/cog.h:15,
| from /home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/git/cog.c:12:
| /home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot/usr/include/wpe-webkit-0.1/wpe/WebKitUserContentFilterStore.h:27:2: error: #error "Only <webkit2/webkit2.h> can be included directly."
| #error "Only <webkit2/webkit2.h> can be included directly."
| ^~~~~
| /home/igalia/psaavedra/yocto-wandboard-wpe/builds/wandboard-mesa-wpe-nightly/tmp/work/armv7at2hf-neon-poky-linux-gnueabi/cog/gitAUTOINC-r0/recipe-sysroot/usr/include/wpe-webkit-0.1/wpe/WebKitUserContentFilterStore.h:34:10: fatal error: webkit2/WebKitDefines.h: No such file or directory
| #include <webkit2/WebKitDefines.h>
| ^~~~~~~~~~~~~~~~~~~~~~~~~
| compilation terminated.
When trying to use cog to load a raw video file fails.
Example
$ cog https://people.igalia.com/clopez/wkbug/video/big_buck_bunny.mp4
Cog-Message: <https://people.igalia.com/clopez/wkbug/video/big_buck_bunny.mp4> Load started.
Cog-Message: <https://people.igalia.com/clopez/wkbug/video/big_buck_bunny.mp4> Loading...
(cog:31588): Cog-WARNING **: <https://people.igalia.com/clopez/wkbug/video/big_buck_bunny.mp4> Page load error: Plug-in handled load
Cog-Message: <https://people.igalia.com/clopez/wkbug/video/big_buck_bunny.mp4> Loaded successfully.
Cog-Message: <https://people.igalia.com/clopez/wkbug/video/big_buck_bunny.mp4> Load started.
Cog-Message: <https://people.igalia.com/clopez/wkbug/video/big_buck_bunny.mp4> Loading...
Cog-Message: <https://people.igalia.com/clopez/wkbug/video/big_buck_bunny.mp4> Loaded successfully.
On the screen you first see the video for a brief moment (~1 second) and then an error page appears (Page load error: Plug-in handled load).
Needless to say that loading this (a video file directly) with other WebKit based launchers/browsers works fine.
Steps to reproduce:
% cmake -G 'Unix Makefiles' . && make
...
[ 52%] Generating WaylandProtocols.dir/fullscreen-shell-unstable-v1-client.h
Could not open output file: No such file or directory
make[2]: *** [CMakeFiles/cogplatform-fdo.dir/build.make:74: WaylandProtocols.dir/fullscreen-shell-unstable-v1-client.h] Error 1
make[1]: *** [CMakeFiles/Makefile2:109: CMakeFiles/cogplatform-fdo.dir/all] Error 2
(Issue reported by @bertogg — thanks!)
Using a command-line option maybe?
Igalia/meta-webkit#18 (comment)
Is it possible yet to disable the WebKit cache from cog?
It would be nice to have a command-line option for this. And also one to be able to specify the default window size.
Using Alt+Left
:
** (cog:10901): CRITICAL **: 15:21:39.085: void webkit_web_view_go_back(WebKitWebView*): assertion 'WEBKIT_IS_WEB_VIEW(webView)' failed
Conversely, with Alt+Right
:
** (cog:10901): CRITICAL **: 15:21:39.745: void webkit_web_view_go_forward(WebKitWebView*): assertion 'WEBKIT_IS_WEB_VIEW(webView)' failed
Version: v0.3.0
Related to: 6b91559
Currently hardcoded to 0.1.0. Should be 0.3.2 ? Would be nice to have an indication at runtime that we run a git snapshot or not, using cog --version
.
By default an error page should be loaded when the WebProcess crashes, but currently crashing page remains on screen, seems like the UI process keeps the last frame before the crash happened.
I'm getting a Segmentation fault
when trying to launch cog. I've built for a RPi3B+ using Buildroot's next
branch. Wayland launches successfully, then the error occurs when launching cog in a second SSH session.
SSH1
export XDG_RUNTIME_DIR=run/user
chmod 0700 run/user
weston --backend=fbdev-backend.so --tty=1 --device=/dev/fb0
# Launches Weston/Wayland successfully
SSH2
export XDG_RUNTIME_DIR=run/user
cog -P fdo http://google.com
# Fails
Wayland: Got a wl_compositor interface
Wayland: Got an xdg_shell interface
Wayland: Got a wl_shell interface
Segmentation fault
Versions are:
I've attached Buildroot's .config if that's any help.
Not sure if this was caused by 17cfde0 or it was a previous issue.
I'm testing with ae3e565 and wpebackend-rdk/wayland-egl and cog is currently broken unless a "-P randomstring is passed".
Simply starting cog without parameters fails with:
root@qemux86-64:~# cog http://igalia.com
(cog:2550): Cog-DEBUG: platform_setup: Platform name: (null)
(cog:2550): Cog-DEBUG: platform_setup: Platform = (nil)
(cog:2550): Cog-CRITICAL **: cog_platform_get_view_backend: assertion 'platform != NULL' failed
**
Cog:ERROR:/usr/src/debug/cog/20180514-r0/git/cog.c:301:on_create_web_view: 'error' should not be NULL
Aborted
Starting it with a random invalid platform plugin name however works
root@qemux86-64:~# cog -P nonexistent http://igalia.com
(cog:2557): Cog-DEBUG: platform_setup: Platform name: nonexistent
(cog:2557): Cog-DEBUG: platform_setup: Platform plugin: libcogplatform-nonexistent.so
(cog:2557): Cog-WARNING **: Could not load: libcogplatform-nonexistent.so (possible cause: Socket operation on non-socket).
(cog:2557): Cog-DEBUG: Instantiating default WPE backend as fall-back.
xkbcommon: ERROR: couldn't find a Compose file for locale "C"
Cog-Message: <http://igalia.com/> Load started.
Cog-Message: <http://www.igalia.com/> Redirected.
Cog-Message: <https://www.igalia.com/> Redirected.
Cog-Message: <https://www.igalia.com/> Loading...
Cog-Message: <https://www.igalia.com/> Loaded successfully.
When I start cog with a local file as the url I get the raw html text instead of the rendered html.
This is how I'm launching cog:
/bin/cog --platform=fdo file:///var/www/frontend/index.html
Is this a bug or am I launching cog with the wrong options?
Our FDO platform plugin should use export_fdo_egl_image
instead of export_egl_image
and perform some buffer caching.
Just a suggestion anyway :)
Plainly using eglGetDisplay(EGL_DEFAULT_DISPLAY)
can be problematic in certain setups. Similar improvements have been done in other projects before, for example:
Code style more or less follows that of GLib. It would be good to make sure that all the files are formatted accordingly. For example platform/cog-platform-fdo.c
has many instances of missing spaces between function names and the opening parenthesis for the argument list.
Instead of including C headers and source code in the repository for Wayland protocols, depend on the wayland-protocols
package and use wayland-scanner
to generate the needed headers and source files at build time.
The plan for this is to use a CI provider that integrates with GitHub and supports using custom container images. Then we can provide base images which already include builds of WPEBackend, WPEBackend-fdo, and WPE WebKit. The following CI services look good for this approach:
Both are free of charge for Open Source projects. I am leaning towards Cirrus because it allows configuring it with a YAML file inside the repository and it will build PRs by default as well, which makes the workflow quite similar to the very popular Travis-CI.
We are experimenting with using cog using the wpe-fdo backend, and we are experiencing a file descriptor leak:
listing the file descriptors at about 1 / second
# ls -l /proc/709/fd | wc -l
625
# ls -l /proc/709/fd | wc -l
627
# ls -l /proc/709/fd | wc -l
631
# ls -l /proc/709/fd | wc -l
631
# ls -l /proc/709/fd | wc -l
635
# ls -l /proc/709/fd | wc -l
635
# ls -l /proc/709/fd | wc -l
639
listing of the file descriptors:
lrwx------ 1 root root 64 Apr 10 21:30 81 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 810 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 811 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 812 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 813 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 814 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 815 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 816 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 817 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 818 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 819 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 82 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 820 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 821 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 822 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 823 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 824 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 825 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 826 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 827 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 828 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 829 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 83 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 830 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 831 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 832 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 833 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 834 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 835 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 836 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 837 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:33 838 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 84 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 85 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 86 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 87 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 88 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 89 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:29 9 -> anon_inode:[eventfd]
lrwx------ 1 root root 64 Apr 10 21:30 90 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 91 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 92 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 93 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 94 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 95 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 96 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 97 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 98 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 10 21:30 99 -> anon_inode:dmabuf
Is there anything we might be doing wrong? Maybe an incorrect configuration?
Right now, CogLauncher inherits from GApplication, which is convenient for Cog because it moves all the useful logic into libcogcore, simplifying the actual program and make it play well on Freedesktop.org systems.
However, in platforms where the features brought in by GApplication are not needed, this inheritance becomes a problem, making libcogcore less flexible to systems outside Freedesktop.org.
The solution would be making CogLauncher not inherit from GApplication, and implement the GApplication logic in cog.c instead.
It would be nice to instruct CMake to pass -Wall
as a compiler flag for those compilers which support it (GCC and Clang).
This will need some work in WebKit as well, see upstream bug #164509 for more information. Once WebKit has the needed bits, Cog will be able to use the API to decide which client certificate(s) are to be presented to a server for authentication.
Right now if the FDO platform module fails to load or initialize it may not be clear what happened. It would be better to at least produce some debugging output (via g_debug
, for example).
Hi All,
I have a linux based system with 7 inch touch screen display .
For UI, I am using cog 0.3.0 + WPEWebkit 2.24 + wpebackend-fdo 1.2.0 + wayland.
I see that every touch event generates new fd in "/proc/ < cogpid > /fd" .
The problem is that these fd never get recycled. They keep on increasing unless it reaches 1024 at which point the cog application crashes.
cat /proc/ < cog pid > /limits show that the allowed number of Max open files is 1024. So cog crashes when the limit of 1024 file descriptors is breached .
Here is a look at the fd list :
root@imx8m-kopera-polar0:/# ls -l /proc/1170/fd | less
dr-x------ 2 root root 0 Apr 4 03:52 .
dr-xr-xr-x 8 root root 0 Apr 4 03:52 ..
lr-x------ 1 root root 64 Apr 4 03:52 0 -> /dev/null
lrwx------ 1 root root 64 Apr 4 03:52 1 -> socket:[6498]
lrwx------ 1 root root 64 Apr 4 03:52 10 -> socket:[8223]
lrwx------ 1 root root 64 Apr 4 03:52 100 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 101 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 102 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 103 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 104 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 105 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 106 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 107 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 108 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 109 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 11 -> anon_inode:[eventfd]
lrwx------ 1 root root 64 Apr 4 03:52 110 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 111 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 112 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 113 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 114 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 115 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 116 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 117 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 118 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 119 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 12 -> socket:[3831]
lrwx------ 1 root root 64 Apr 4 03:52 120 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 121 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 122 -> anon_inode:dmabuf
lrwx------ 1 root root 64 Apr 4 03:52 123 -> anon_inode:dmabuf
the list goes on ....

When the system crashes I see the following print from cog :
Cog:ERROR:/mnt/workspace/beta/3/polar-yocto/build/default/tmp/work/aarch64-kopera-linux/cog/gitAUTOINC-r0/git/platform/cog-platform-fdo.c:1060:on_export_egl_image: 'wpe_view_data.buffer' should not be NULL
Aborted
I also found that the same bug has been reported in wayland
https://bugs.freedesktop.org/show_bug.cgi?id=100298
But, they marked it as "RESOLVED NOTOURBUG".
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.