Closed techmoerror220 closed 3 years ago
Do you happen to have (in some way) pgtk enabled? I had similar issues with pgtk, but afterwards have been fine. I also compiled from head with native comp, and if it makes some difference I am running Arch Linux (with Emacs version 28.0.50)
Yeah, I was aware that EXWM is incompatible with pgtk... I shouldn't have pgtk as I have not requested it on installation and I see that the window system is x11 and the toolkit is GTK3
I've checked that, for me on Ubuntu 20.04, EXWM doesn't work when building Emacs with native comp (no pgtk
at alll) and deploying either of these two cloning operations (both from Emacs master branch' HEAD
):
git clone -b master git://git.sv.gnu.org/emacs.git
git clone git://git.savannah.gnu.org/emacs.git
However, EXWM does work alright when cloning from the GccEmacs's branch:
git clone git://git.savannah.gnu.org/emacs.git -b feature/native-comp
There are quite a few commits differentiating the two. Possibly something else was merged into master
and messes with EXWM. It seems there have been quite a few variables renamed (but mostly verbosity related) and a few Windows changes, which shouldn't affect you. Native comp was also renamed into native-compile
feature, which might be it.
I don't actively follow the commit history of Emacs, but between April 22nd and now, clearly something has changed to affect EXWM (which is a bit obvious to say in retrospect.) Would you mind trying to compile the master
branch with --native-compile
feature?
Ok, I'll try in a while. By the way, are
git clone -b master git://git.sv.gnu.org/emacs.git
git clone git://git.savannah.gnu.org/emacs.git
the same?
Yes. It seems the sv one redirects to the latter. I just cloned both, they are the same.
Okay, i'm on my way... i'll clone git://git.sv.gnu.org/emacs.git
, which is the one referenced in the official web
I'm going to do:
$ ./configure --with-dbus --with-gif ---with-jpeg --with-png --with-rsvg --with-tiff --with-xft --with-xpm --with-gpm=no --with-json --with-mailutils --with-kerberos5 --with-modules --with-imagemagick --with-x --with-x-toolkit=gtk3 --with-cairo --native-compile
Looks good to me. For reference, this is what the PKGBUILD for Arch Linux does:
build() {
cd "$srcdir/emacs-git"
local _conf=(
--prefix=/usr
--sysconfdir=/etc
--libexecdir=/usr/lib
--localstatedir=/var
--mandir=/usr/share/man
--with-gameuser=:games
--with-sound=alsa
--with-modules
# Beware https://debbugs.gnu.org/cgi/bugreport.cgi?bug=25228
# dconf and gconf break font settings you set in ~/.emacs.
# If you insist you'll need to read that bug report in *full*.
# Good luck!
--without-gconf
--without-gsettings
--with-native-compilation
)
You wrote just --native-compile
(which I accidentally wrote earlier)
Oh, you meant with-native-compilation
! Well, that's what I've done already several times and it doesn't work
Yeah, sorry about that. Just for the sake of troubleshooting, can you compile just with the bare minimum + native comp? I believe that is listed as --with-wide-int
on the wiki. Maybe some other option is somehow pulling in pgtk, or another thing that EXWM has issues with?
so you mean ./configure --with-wide-int --with-native-compilation
?
Yes, and let's see if that works. I find this whole scenario quite peculiar, as I have (I believe) the same modules, same version number, and am replying to you from EXWM. So unless someone else has a better initial idea, I'd think it's one of the features your build is configured with.
yes, could be though I'm an expert at getting trapped in "peculiar" problems with Emacs... okay, so now my machine is dealing with make NATIVE_FULL_AOT=1 -j$(nproc)
so time to grab a cuppa tea!
I'm getting tons of libgccjit.so: note: disable pass tree-isolate-paths for functions in the range of [0, 4294967295]
..... don't recall getting these message repeated constantly in my previous builds... any idea what is it about?
Process ended with same result: blank screen with my color theme but can't see the cursor, the mode-line, the minibuffer, anything I type... nothing. Only thing I can do is type commands I know by heart to fire up external processes or to exit Emacs and EXWM altogether... so weird
Very weird. I honestly have no idea what the disable pass tree is about. For now, I know this is avoiding the issue, but can you find a PPA for native-comp on Ubuntu, or stick with the GCCEmacs branch? Maybe work is being done on master right now that is breaking native-comp and EXWM. I don't regularly compile Emacs on my own, so I don't think I can be of much more assistance.
Probably the message pops up because the --with-wide-int
flag? (oh, yes, see here though I use the 64-bit build so another thing I don't know what's going on)...
Oh, well, yes, I'm back to GccEmacs
I can reproduce the issue with the latest master and a config based on doom emacs. It’s weird- seems like emacs is still responsive to some degree. I have ivy-posframe with the trickery to make it a top level window, and when I run find-file the screen does redisplay. However, while ivy is centered on my monitor, my emacs frame is the vanilla starting size instead of full-screen and is positioned in the upper left. If I exit find-file I’m back to blank windows. Exwm does seem to be running though, as my polybar is at the right place at the top of my screen and the emacs frame is shifted down to match. Launching emacs without exwm seems to work just fine as well. I’ll try a few other build configurations and if I’m unsuccessful I guess I’m returning to the native-comp branch too.
Exactly, Emacs without EXWM works alright but with EXWM it doesn't. Only polybar is in its place.
So, first test: rebuilding everything without native comp still produces the same error, so it seems to be a problem on emacs master more generally.
So, first test: rebuilding everything without native comp still produces the same error, so it seems to be a problem on emacs master more generally.
Since there's a clear broken state (HEAD), and a clearly working one (27.1), you can use git bisect to find the problematic commit.
Already in the process now :)
Wow, and there's no pgtk
involved, right? That will surely make EXWM fail but it remains an option that's not by default as far as I know
No pgtk.
I think I’ve found it- double checking what I think is the last good commit, rebuilding my full config, and then once I’ve got a proper environment up I’ll copy the exact commit hash out of magit. It’s a change to expose event handling on gtk3.
https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=483c5e953c12a95382bef4a3b6769a680c32fe86 is first the bad commit I found.
Awesome, thank you! Could you please tell me how could I clone the last good commit before chaos breaks in for EXWM? I'm not that familiar with Git...
I think this issue is related to (or even the same as) this: https://bugs.gnu.org/48268 https://bugs.gnu.org/48413
(which I guess will be fixed soon)
As for how to get to the last good commit, I think this ought to do it:
git checkout master ## just in case
git checkout -b before_chaos 203ee33 ## that is the commit right before 483c5e9
And now do the autogen, configure, etc.
@djeis97 and @rdiaz02, thank you soooooo much! I've reproduced on my system and EXWM works like it used to, i.e., like a charm. You've saved my day and my weekend! :) Thank you!
I think you probably would want to close this issue, since it is solved by using a former commit (and, in fact, I think the commits during yesterday fixed the problem).
Yes, sorry, I forgot. So you think HEAD is no longer dangerous for EXWM?
I compiled HEAD yesterday (ironically I've decided to try out Guix, so I do need to do that now) and it worked perfectly. Not sure at exactly what time I did that though
Until today, I had
EXWM
together withGccEmacs
. However, since native compilation is available from Emacs's master branch, today I decided to uninstall myGccEmacs
and install Emacs from master branch'sHEAD
(GNU Emacs 28.0.50
). Now if I log intoEXWM
, I get an empty, blank screen where I can't see either the cursor, or the mode-line or the minibuffer, nothing. I can use the keybindings I know by heart to, for example, launch Firefox or to log out fromEWXM
altogether. If I log intoUbuntu 20.04
's default desktop, which is Gnome I believe, Emacs is fully functional. So I wonder there is something wrong with the rendering of Emacs when I attempt to useEXWM
, but what is it, given that those very same settings were perfectly okay withGccEmacs
? At its basics, these are:I'ved checked that I have
xelb
andcl-generic
alright and installed from ELPA simultaneously with EXWM.... I wonder if it has to do with my 4k, high dpi monitor... But not seeing the cursor? Not being able to type anything? No response to zooming in/out? I'm puzzled