Can nix use packages from other distributions like deb, rpm, etc

can nix use packages from other distributions like deb, rpm, etc.?

I use a lot of small packages since about 20 y. (for ex. the html-editor composer, didiwiki, jwm, rox-filer, xsane, tesseract-ocr, gImageReader, MagicPoint, granule, gprolog, gforth, xli, setxkbmap, full access to keyboard settings and RECORDING THEM for us intl, kor, in, and in tam, as well as copy more *ttf files in /usr/share/fonts and more dictionaries in /usr/share/hunspell) being not always available in each distro, so it is important for me to learn if can add them easily. And there are packages I don’t like at all (firefox, VLC, mono, VI as I prefer nano or leafpad, pcmanfm) so it is also important for me to learn if can remove them easily if they are part of the installation.

Where can I learn about that?

Kind regards

1 Like

Package and system management concepts are fairly different in nixos than other Linux distros. My recommendation would be to try nixos in a VM first and see if you are willing to invest the time it takes to learn to work in a different paradigm.

The packages you can add easily are the ones you find here:
https://nixos.org/nixos/packages.html?channel=nixos-20.03

Anything else, may require some research and/or work to get working. Some things are very difficult to get working on nixos.

Excluding the core files needed to run the system, the installation won’t include applications like that unless you have included them.

1 Like

I agree with the first part, but the only example for the second that comes to mind is startx (in the sense of per-user custom X session). @dalto do you have anything else that is really a pain in the ass to get going? @oui no reason to be discouraged by these IME extreme outliers. In almost a year of regular use I had only a few things that were really a lot of hassle that was due to the limitations of NixOS or the package collection, and oftentimes I came back weeks later to see it having been fixed.

Technically IIRC that is not true for vi, which is included in the minimal installation image. But NixOS is the only distro I know where it is literally easy to create custom images which are as stripped down as you like.

The thing that comes to mind for me is VMWare Workstation Pro. It is possible that it is my lack nixos experience that drives this but I have seen posts where other people have tried and failed to get it working. There are probably other things but this is the one thing which forces me to run a mixed environment since I have a hard requirement on it.

Were we talking about the actual image or the resultant install of the OS? I remember after doing my first nixos install being surprised to find I didn’t have any form of vi installed. :smile:

Also, if my first post seems negative, it wasn’t my intention. I think nixos is great. I just also think it requires a willingness to really invest in learning how to do things differently. If you don’t want to make that investment, it is more likely to frustrate you than impress you.

1 Like

In a technical way you can use packages from other distributions, but only as archives. Etcher does that in its derivation but that’s more because building Electron stuff has been tough in Nix for a bit – we’ll probably get around to doing it here. As you can see, you still have to specify the dependencies and how to install it, so it’s not like you’re able to install a Debian package – you just don’t have to build it, that’s all.

For the rare packages that aren’t in Nixpkgs, you might be lucky and there’s a Flatpak package available as a fallback. If not, there’s also the steam-run hack that allows you to run a program as if it’s in a LSB environment.

Docker should be brought here, because you can build your workflow with a several Linux distros and use your apps in containers. :man_shrugging: