What is the purpose of nixpkgs-wayland?

I have put some effort in using NVidia proprietary drivers lately, which was especially painful because my WM is Sway (yes, the WM that, up to not so far ago had a --my-next-gpu-wont-be-nvidia option to enable a (buggy) compatibility with proprietary drivers…). However, apparently NVidia drivers have become open source, so their support has increased and, in the end, I was able to successfully make it work (although there is still some flickering, once in a while).

While doing all this, I stumbled upon a project called nixpkgs-wayland, which describes itself as “Automated, pre-built packages for Wayland (sway/wlroots) tools for NixOS (nixos-unstable channel)”, so I said myself: “ah, cool, I work with Wayland, I use sway on NixOS with nixpkgs-unstable. I don’t know what that is, but if there is one kind of user who must find this useful, it’s me.” Ok, so at that pointed I looked at the installation section, under the Flakes subsection, and followed the instructions, and now I’m stuck in this situation where I still don’t know what was the purpose of this whole project to begin with. I mean, they say they have prebuilt packages for Wayland, and in the list of the packages they provide, I found a lot I use myself (such as sway, swaylock, swayidle, swaybar, imv, dunst, i3status-rs, …) but I never had to compile these (in the sense that they were always available directly from NixOS’ binary cache).

So, well, I have the impression that everything that is packaged in nixpkgs-wayland is already packaged in nixpkgs, and similarly for the binary cache, so why does it exist? What is its purpose?

Subsidiary question: why is not nixpkgs-wayland “merged” with nixpkgs? If it’s true they package stuff to be compatible with wayland, I would have expected to have a single package in nixpkgs having an option like waylandSupport or something like that that one could override.


I believe that by automated, they mean that the packages are automatically updated to their latest development versions. Nixpkgs prefers stable versions of software when available.

1 Like

Even nixpkgs-unstable?

Yes, nixpkgs-unstable just means you get the changes as soon as all the tests defined for it pass. From time to time you will also encounter some bugs which often get fixed by people running the unstable channel.

1 Like