GNU bug report logs -
#44204
Emacs --with-xwidgets complains under Ubuntu 20.04
Previous Next
To reply to this bug, email your comments to 44204 AT debbugs.gnu.org.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Sun, 25 Oct 2020 00:01:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Paul Eggert <eggert <at> cs.ucla.edu>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Sun, 25 Oct 2020 00:01:01 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
Under Ubuntu 20.04.1 LTS x86-64, when I use './configure --with-xwidgets' and
run Emacs in the default windowing environment (which is Gnome under Wayland),
simple xwidgets functions do not seem to work. For example:
(make-xwidget 'webkit "title" 500 500 '())
causes the following to appear on stderr:
(emacs:139090): Gdk-WARNING **: 16:53:59.652:
../../../../../gdk/x11/gdkwindow-x11.c:5633 drawable is not a native X11 window
(emacs:139090): Gdk-WARNING **: 16:53:59.652:
../../../../../gdk/x11/gdkwindow-x11.c:5633 drawable is not a native X11 window
(emacs:139090): Gdk-WARNING **: 16:53:59.652:
../../../../../gdk/x11/gdkwindow-x11.c:5633 drawable is not a native X11 window
Apparently the Emacs xwidgets code assumes native X11, but Emacs is running
under Wayland, not native X11.
I observe the problem when running Emacs 26.3, Emacs 27.1, and Emacs savannah
master, so it's not a new problem.
A simple workaround is to not use --with-xwidgets; this is now Debian and Ubuntu
build the Emacs 26.3 that they distribute, at any rate.
Changed bug title to 'Emacs --with-xwidgets complains under Ubuntu 20.04' from 'Emacs --with-xwidgets complains under Wayland'
Request was from
Paul Eggert <eggert <at> cs.ucla.edu>
to
control <at> debbugs.gnu.org
.
(Sun, 25 Oct 2020 00:20:02 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Sun, 25 Oct 2020 00:25:01 GMT)
Full text and
rfc822 format available.
Message #10 received at 44204 <at> debbugs.gnu.org (full text, mbox):
Oops, I now see that I am not running under Gnome under Wayland. At least,
$ echo $XDG_SESSION_TYPE
outputs "x11". So, forget all my comments about Wayland. It's the default Ubuntu
20.04 Gnome windowing manager.
But we still have a bug here. Why is the Emacs xwidgets code complaining about
not having native x11 access?
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Sun, 25 Oct 2020 00:28:02 GMT)
Full text and
rfc822 format available.
Message #13 received at 44204 <at> debbugs.gnu.org (full text, mbox):
No further comment, so I installed the WebKit sandboxing patch into the emacs-27
branch on Savannah
<https://git.savannah.gnu.org/cgit/emacs.git/commit/?h=emacs-27&id=71661b287297f328c2c5ad67e180a760f80850cb>.
After the next merge from emacs-27 to master, this patch should appear in the
master branch. I am closing Bug#43071.
While testing the fix, I ran into a problem with xwidgets and filed Bug#44204
"Emacs --with-xwidgets complains under Ubuntu 20.04" which you can see here:
https://bugs.gnu.org/44204
Has anyone had luck running Emacs --with-xwidgets under Ubuntu 20.04 or later?
I'll cc. this to 44204 <at> debbugs.gnu.org to try to move that part of the
discussion there.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Sun, 25 Oct 2020 05:52:02 GMT)
Full text and
rfc822 format available.
Message #16 received at 44204 <at> debbugs.gnu.org (full text, mbox):
On Sun, 25 Oct 2020 at 05:31, Paul Eggert <eggert <at> cs.ucla.edu> wrote:
>
> Under Ubuntu 20.04.1 LTS x86-64, when I use './configure --with-xwidgets' and
> run Emacs in the default windowing environment (which is Gnome under Wayland),
> simple xwidgets functions do not seem to work. For example:
>
> (make-xwidget 'webkit "title" 500 500 '())
> […]
I tried executing the above line in the *scratch* buffer, nothing
happens (emacs -Q). Is it expected behavior? I don't see any errors in
the terminal as well. I'm running under wayland on GNOME 3.36.7 and
Fedora 32.
In GNU Emacs 27.1 (build 1, x86_64-redhat-linux-gnu, GTK+ Version
3.24.21, cairo version 1.16.0)
of 2020-08-21 built on buildvm-x86-24.iad2.fedoraproject.org
Windowing system distributor 'Fedora Project', version 11.0.12009000
System Description: Fedora 32 (Workstation Edition)
Configured using:
'configure --build=x86_64-redhat-linux-gnu
--host=x86_64-redhat-linux-gnu --program-prefix=
--disable-dependency-tracking --prefix=/usr --exec-prefix=/usr
--bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc
--datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64
--libexecdir=/usr/libexec --localstatedir=/var
--sharedstatedir=/var/lib --mandir=/usr/share/man
--infodir=/usr/share/info --with-dbus --with-gif --with-jpeg --with-png
--with-rsvg --with-tiff --with-xft --with-xpm --with-x-toolkit=gtk3
--with-gpm=no --with-xwidgets --with-modules --with-harfbuzz
--with-cairo --with-json build_alias=x86_64-redhat-linux-gnu
host_alias=x86_64-redhat-linux-gnu 'CFLAGS=-DMAIL_USE_LOCKF -O2 -g
-pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2
-Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong
-grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1
-specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic
-fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection'
LDFLAGS=-Wl,-z,relro
PKG_CONFIG_PATH=:/usr/lib64/pkgconfig:/usr/share/pkgconfig'
Configured features:
XPM JPEG TIFF GIF PNG RSVG CAIRO SOUND DBUS GSETTINGS GLIB NOTIFY
INOTIFY ACL LIBSELINUX GNUTLS LIBXML2 FREETYPE HARFBUZZ M17N_FLT LIBOTF
ZLIB TOOLKIT_SCROLL_BARS GTK3 X11 XDBE XIM MODULES THREADS XWIDGETS
LIBSYSTEMD JSON PDUMPER GMP
--
Warm Regards,
Bhavin Gandhi (bhavin192) | https://geeksocket.in
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Sun, 25 Oct 2020 13:20:01 GMT)
Full text and
rfc822 format available.
Message #19 received at 44204 <at> debbugs.gnu.org (full text, mbox):
Paul Eggert <eggert <at> cs.ucla.edu> writes:
> Under Ubuntu 20.04.1 LTS x86-64, when I use './configure
> --with-xwidgets' and run Emacs in the default windowing environment
> (which is Gnome under Wayland), simple xwidgets functions do not seem
> to work. For example:
>
> (make-xwidget 'webkit "title" 500 500 '())
>
> causes the following to appear on stderr:
>
> (emacs:139090): Gdk-WARNING **: 16:53:59.652:
> ../../../../../gdk/x11/gdkwindow-x11.c:5633 drawable is not a native
> X11 window
Just a data point: Under Debian bullseye (Gnome/Xorg), this warning is
not issued.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Sun, 25 Oct 2020 17:26:01 GMT)
Full text and
rfc822 format available.
Message #22 received at 44204 <at> debbugs.gnu.org (full text, mbox):
On 10/24/20 10:51 PM, Bhavin Gandhi wrote:
>> (make-xwidget 'webkit "title" 500 500 '())
>
> I tried executing the above line in the *scratch* buffer, nothing
> happens (emacs -Q). Is it expected behavior?
Yes, it's just a trivial example that doesn't do anything. The point is that the
xwidget startup causes the diagnostics that I mentioned, on Ubuntu 20.04.
> I don't see any errors in
> the terminal as well. I'm running under wayland on GNOME 3.36.7 and
> Fedora 32.
Yes, I was wrong when I fingered Wayland in the original bug report. I've
retitled the bug report to say "under Ubuntu 20.04" rather than "under Wayland".
For what it's worth, Ubuntu 20.04 ships Emacs 26.3 without enabling xwidgets, so
the bug is not present in /usr/bin/emacs.
Also, I have not tested the Emacs 27.1 that Ubuntu makes available as a snap,
but that snap outputs such a blizzard of other diagnostics, that I expect nobody
would care anyway. See:
https://bugs.launchpad.net/ubuntu/+source/emacs/+bug/1898083
I am getting the impression that Ubuntu no longer cares about Emacs; if that's
true, I suppose I should stop using Ubuntu.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Sun, 25 Oct 2020 17:36:01 GMT)
Full text and
rfc822 format available.
Message #25 received at 44204 <at> debbugs.gnu.org (full text, mbox):
Paul Eggert <eggert <at> cs.ucla.edu> writes:
> On 10/24/20 10:51 PM, Bhavin Gandhi wrote:
>
>>> (make-xwidget 'webkit "title" 500 500 '())
>>
>> I tried executing the above line in the *scratch* buffer, nothing
>> happens (emacs -Q). Is it expected behavior?
>
> Yes, it's just a trivial example that doesn't do anything. The point
> is that the xwidget startup causes the diagnostics that I mentioned,
> on Ubuntu 20.04.
I mean "nothing happens" as in "there's no errors". :-) Sorry for
being unclear.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Wed, 08 Dec 2021 20:24:01 GMT)
Full text and
rfc822 format available.
Message #28 received at 44204 <at> debbugs.gnu.org (full text, mbox):
Paul Eggert <eggert <at> cs.ucla.edu> writes:
> On 10/24/20 10:51 PM, Bhavin Gandhi wrote:
>
>>> (make-xwidget 'webkit "title" 500 500 '())
>>
>> I tried executing the above line in the *scratch* buffer, nothing
>> happens (emacs -Q). Is it expected behavior?
>
> Yes, it's just a trivial example that doesn't do anything. The point is that the
> xwidget startup causes the diagnostics that I mentioned, on Ubuntu 20.04.
(I am also not seeing any of these diagnostics on current master,
running Debian stable/bullseye.)
I guess someone running Ubuntu 20.04 could try reproducing this again
given that there has been a lot of activity on the xwidget branch
recently.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Wed, 08 Dec 2021 21:13:01 GMT)
Full text and
rfc822 format available.
Message #31 received at 44204 <at> debbugs.gnu.org (full text, mbox):
On 12/8/21 12:23, Stefan Kangas wrote:
> I guess someone running Ubuntu 20.04 could try reproducing this again
> given that there has been a lot of activity on the xwidget branch
> recently.
I just now checked the current Emacs master (commit
00d107ebead8d710cbe339d9af717e6eb2f9f2ff) on Ubuntu 21.10 with patches
current as of today, and things have gotten a bit worse.
Configuring with './configure --with-xwidgets', building and then
starting with 'emacs -Q', and typing this:
(make-xwidget 'webkit "title" 500 500 '())
followed by C-j, causes the following text to be output to stderr:
-----
Overriding existing handler for signal 10. Set JSC_SIGNAL_FOR_GC if you
want WebKit to use a different signal
(emacs:66402): Gdk-WARNING **: 13:05:22.877:
../../../../../gdk/x11/gdkwindow-x11.c:5653 drawable is not a native X11
window
(emacs:66402): Gdk-WARNING **: 13:05:22.880:
../../../../../gdk/x11/gdkwindow-x11.c:5653 drawable is not a native X11
window
(emacs:66402): Gdk-WARNING **: 13:05:22.880:
../../../../../gdk/x11/gdkwindow-x11.c:5653 drawable is not a native X11
window
-----
and the following text to be put into Emacs *Messages* buffer:
-----
<xwidget-event> is undefined [4 times]
-----
I am using the default Ubuntu window manager. The command "env | grep
'^XDG' | sort" outputs:
XDG_CONFIG_DIRS=/etc/xdg/xdg-ubuntu-xorg:/etc/xdg
XDG_CURRENT_DESKTOP=ubuntu:GNOME
XDG_DATA_DIRS=/usr/share/ubuntu-xorg:/usr/local/share/:/usr/share/:/var/lib/snapd/desktop
XDG_MENU_PREFIX=gnome-
XDG_RUNTIME_DIR=/run/user/1000
XDG_SESSION_CLASS=user
XDG_SESSION_DESKTOP=ubuntu-xorg
XDG_SESSION_TYPE=x11
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Wed, 08 Dec 2021 22:08:02 GMT)
Full text and
rfc822 format available.
Message #34 received at 44204 <at> debbugs.gnu.org (full text, mbox):
Paul Eggert <eggert <at> cs.ucla.edu> writes:
> On 12/8/21 12:23, Stefan Kangas wrote:
>> I guess someone running Ubuntu 20.04 could try reproducing this again
>> given that there has been a lot of activity on the xwidget branch
>> recently.
(I shouldn't have said "branch", as this all takes place on master.)
> I just now checked the current Emacs master (commit
> 00d107ebead8d710cbe339d9af717e6eb2f9f2ff) on Ubuntu 21.10 with patches
> current as of today, and things have gotten a bit worse.
Thanks. I'm copying in Po Lu, who has done work in this area recently.
Maybe he'll be interested in taking a look.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Thu, 09 Dec 2021 00:34:01 GMT)
Full text and
rfc822 format available.
Message #37 received at 44204 <at> debbugs.gnu.org (full text, mbox):
Stefan Kangas <stefan <at> marxist.se> writes:
> Paul Eggert <eggert <at> cs.ucla.edu> writes:
>
>> On 12/8/21 12:23, Stefan Kangas wrote:
>>> I guess someone running Ubuntu 20.04 could try reproducing this again
>>> given that there has been a lot of activity on the xwidget branch
>>> recently.
>
> (I shouldn't have said "branch", as this all takes place on master.)
>
>> I just now checked the current Emacs master (commit
>> 00d107ebead8d710cbe339d9af717e6eb2f9f2ff) on Ubuntu 21.10 with patches
>> current as of today, and things have gotten a bit worse.
>
> Thanks. I'm copying in Po Lu, who has done work in this area recently.
> Maybe he'll be interested in taking a look.
Thanks. It works here (on both X11 and Xwayland), but I'm using Fedora
35.
Paul, could you tell me what version of WebKitGTK you are using?
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Thu, 09 Dec 2021 01:36:02 GMT)
Full text and
rfc822 format available.
Message #40 received at 44204 <at> debbugs.gnu.org (full text, mbox):
On 12/8/21 16:32, Po Lu wrote:
> It works here (on both X11 and Xwayland), but I'm using Fedora
> 35.
That's odd, as I observe some of the problem on Fedora 35 x86-64, using
the default GNOME login. I built current Emacs master (commit
63f07ea22f3954c2154d831017caf494911cb515) with './configure
--with-xwidgets --enable-gcc-warnings', then run 'src/emacs -Q', then in
the *scratch* buffer type:
(make-xwidget 'webkit "title" 500 500 '())
followed by C-j. On stderr I see this string:
Overriding existing handler for signal 10. Set JSC_SIGNAL_FOR_GC if you
want WebKit to use a different signal
and in the *Messages* buffer I see:
<xwidget-event> is undefined [4 times]
On this platform, the shell command "env | grep '^XDG' | sort" outputs:
XDG_CURRENT_DESKTOP=GNOME
XDG_DATA_DIRS=/home/eggert/.local/share/flatpak/exports/share:/var/lib/flatpak/exports/share:/usr/local/share/:/usr/share/
XDG_MENU_PREFIX=gnome-
XDG_RUNTIME_DIR=/run/user/1000
XDG_SESSION_CLASS=user
XDG_SESSION_DESKTOP=gnome
XDG_SESSION_TYPE=wayland
> Paul, could you tell me what version of WebKitGTK you are using?
On Fedora 35, 'dnf info' reports:
Name : webkit2gtk3
Version : 2.34.1
Release : 2.fc35
On my Ubuntu 20.04.3 LTS x86-64 platform, where I observe both the above
issues and the Gdk-WARNINGs I mentioned previously, 'dpkg -s
libwebkit2gtk-4.0-37' reports:
Version: 2.34.1-0ubuntu0.20.04.1
and "env | grep '^XDG' | sort" outputs:
XDG_CONFIG_DIRS=/etc/xdg/xdg-ubuntu:/etc/xdg
XDG_CURRENT_DESKTOP=ubuntu:GNOME
XDG_DATA_DIRS=/usr/share/ubuntu:/usr/local/share/:/usr/share/:/var/lib/snapd/desktop
XDG_MENU_PREFIX=gnome-
XDG_RUNTIME_DIR=/run/user/1000
XDG_SESSION_CLASS=user
XDG_SESSION_DESKTOP=ubuntu
XDG_SESSION_TYPE=x11
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Thu, 09 Dec 2021 02:21:02 GMT)
Full text and
rfc822 format available.
Message #43 received at 44204 <at> debbugs.gnu.org (full text, mbox):
Paul Eggert <eggert <at> cs.ucla.edu> writes:
> That's odd, as I observe some of the problem on Fedora 35 x86-64,
> using the default GNOME login. I built current Emacs master (commit
> 63f07ea22f3954c2154d831017caf494911cb515) with './configure
> --with-xwidgets --enable-gcc-warnings', then run 'src/emacs -Q', then
> in the *scratch* buffer type:
>
> (make-xwidget 'webkit "title" 500 500 '())
>
> followed by C-j. On stderr I see this string:
>
> Overriding existing handler for signal 10. Set JSC_SIGNAL_FOR_GC if
> you want WebKit to use a different signal
That's a completely different error, caused by JavaScriptCore overriding
the SIGUSR1 handler to stop threads for GC.
This is only done on systems running the Linux kernel, and once the JSC
developers add the programmatic interface that allows programs to change
the signal used, I plan to change it to their recommended workaround
signal, SIGRTMIN, on such systems.
> <xwidget-event> is undefined [4 times]
You are supposed to (require 'xwidget) before running any xwidget
functions. For some reason that isn't enforced.
> On my Ubuntu 20.04.3 LTS x86-64 platform, where I observe both the
> above issues and the Gdk-WARNINGs I mentioned previously, 'dpkg -s
> libwebkit2gtk-4.0-37' reports:
> XDG_CONFIG_DIRS=/etc/xdg/xdg-ubuntu:/etc/xdg
> XDG_CURRENT_DESKTOP=ubuntu:GNOME
> XDG_DATA_DIRS=/usr/share/ubuntu:/usr/local/share/:/usr/share/:/var/lib/snapd/desktop
> XDG_MENU_PREFIX=gnome-
> XDG_RUNTIME_DIR=/run/user/1000
> XDG_SESSION_CLASS=user
> XDG_SESSION_DESKTOP=ubuntu
> XDG_SESSION_TYPE=x11
That is very odd, but I will look into this. Thanks.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44204
; Package
emacs
.
(Sun, 12 Dec 2021 10:57:02 GMT)
Full text and
rfc822 format available.
Message #46 received at 44204 <at> debbugs.gnu.org (full text, mbox):
Paul Eggert <eggert <at> cs.ucla.edu> writes:
> On my Ubuntu 20.04.3 LTS x86-64 platform, where I observe both the
> above issues and the Gdk-WARNINGs I mentioned previously, 'dpkg -s
> libwebkit2gtk-4.0-37' reports:
>
> Version: 2.34.1-0ubuntu0.20.04.1
>
> and "env | grep '^XDG' | sort" outputs:
>
> XDG_CONFIG_DIRS=/etc/xdg/xdg-ubuntu:/etc/xdg
> XDG_CURRENT_DESKTOP=ubuntu:GNOME
> XDG_DATA_DIRS=/usr/share/ubuntu:/usr/local/share/:/usr/share/:/var/lib/snapd/desktop
> XDG_MENU_PREFIX=gnome-
> XDG_RUNTIME_DIR=/run/user/1000
> XDG_SESSION_CLASS=user
> XDG_SESSION_DESKTOP=ubuntu
> XDG_SESSION_TYPE=x11
Could you please install the debug information and source packages for
GDK 3 on that Ubuntu system, run Emacs under GDB with
`G_DEBUG=fatal-warnings', trigger the warning, and then print a
backtrace?
I want to know what is calling `gdk_x11_window_get_xid', and if it is
being called on the offscreen window.
Thanks.
This bug report was last modified 2 years and 136 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.