Hacker News new | ask | show | jobs
by md8z 1689 days ago
I really don't understand this line of thinking or what you are trying to accomplish. If you are dropping things from the X protocol to the point where it's only XInput2.2, SHM and DRI3, and then farming the rest out to Xephyr, then it's no longer X anymore. That is pretty much entirely what Wayland already is. So you might as well just build it as a Wayland server and call it a day.
1 comments

I'm not doing this, it's a thought experiment. I'm happy to stay with X for a long time if necessary.

But what you list is not enough, though. There are enough extra bits that goes well beyond what Wayland provides today, like ability to write a standalone wm without having to build a whole compositor, for example, that you'd end up with something quite substantially unlike Wayland if you went down that route and looked at which pieces of X11+extensions people are actually using. It'd be far less than full on legacy X11, but far more than just Wayland.

It doesn't matter if it's not X. Nobody but extreme purists would care if it's not exactly X. What will matter is if you lose capabilities.

E.g currently my preferred wm (bspwm) doesn't have a Wayland alternative, so a Wayland compositor isn't a viable option for me without changing my workflow. Sway might be nice, but it's different and I have no compelling reason to put in the effort to make a switch until running Xorg starts becoming problematic. One day, maybe I'll feel compelled to switch but it won't be soon.

Even so, Xorg will hang around for decades in the form of XWayland because of old X apps people still use (e.g. none of the terminals I have installed on my system except for gnome-terminal supports Wayland).

I still see no purpose to do that, with a lot of hacking it would be also possible to make XWayland work with window managers. But that also would be pretty pointless to do because those other parts of the X protocol are also bad and need to be replaced, you might as well just rewrite the window manager.

If you liked bspwm then you might want to try this: https://github.com/riverwm/river

And I see no purpose in switching to Wayland as long as Xorg keeps working just fine.

> If you liked bspwm then you might want to try this: https://github.com/riverwm/river

If I wanted to spend time redoing my configuration, maybe, but I have better things to spend my time on. So in however many years it takes before getting Xorg running starts taking more effort than switching. I'm not expecting that to happen anytime soon.

It doesn't really work fine though, there are numerous really old bugs that never got fixed. Here's a sample:

https://gitlab.freedesktop.org/xorg/xserver/-/issues/386

https://gitlab.freedesktop.org/xorg/xserver/-/issues/333

https://gitlab.freedesktop.org/xorg/xserver/-/issues/380

https://gitlab.freedesktop.org/xorg/xserver/-/issues/249

https://gitlab.freedesktop.org/xorg/xserver/-/issues/260

https://gitlab.freedesktop.org/xorg/xserver/-/issues/258

And I'm sure you could find plenty more. All this stuff is fixed or is trivially fixable in Wayland, by the way.

"If I wanted to spend time redoing my configuration, maybe, but I have better things to spend my time on"

I don't understand, you were just talking about spending significantly more time rewriting the X server...

> It doesn't really work fine though, there are numerous really old bugs that never got fixed. Here's a sample:

It works fine for me. I gave my reason for why I won't consider switching to some Wayland compositor. None of the bugs you list affect me, so your suggestion I look at a Wayland compositor which would require me to spend time changing my entire config only to be left running XWayland anyway because the terminals I use are X11 based.

It would be a massive waste of my time for no benefit whatsoever.

And this is why X will stay around for a long time: There are lots of us with dependencies like this and no reasons to change things until things starts breaking.

> I don't understand, you were just talking about spending significantly more time rewriting the X server...

Read again. I have not once suggested I'm planning on rewriting an X server. I pointed out doing so would have been a better choice than starting over from scratch, and that the choice to start over from scratch is the reason people are still sticking with X.

I guess you can consider yourself lucky that you're not affected by those bugs? Things are ostensibly already broken and have been for quite some time, some of those bugs are over 15 years old. If you only care about bugs that affect you then it's not even worth having a discussion about this, you can't expect everyone to wait to make changes until it's personally convenient for you. And if that's not what you meant then the other stuff is still there if you change your mind and decide to switch.

"I pointed out doing so would have been a better choice than starting over from scratch, and that the choice to start over from scratch is the reason people are still sticking with X."

I would urge you to look into how much work it would take to actually fix those bugs and push out incompatible server/libraries/etc to people and then come back and see if you'd like to revise this statement. Because that is what we are looking at here. Remember what you are asking here is for every toolkit and program to do a "if x12 then dostuff elseif x11 then do otherstuff" and weigh that versus "if wayland then dostuff elseif x11 then do otherstuff".