Automatically generating deb packages from nixpkgs

Note that tgunnoe pointed in the above issue:

There’s already support for toDeb and toRpm in the official bundlers (which also use nix-bundle): GitHub - NixOS/bundlers

I checked the code and it’s actually recreating the /nix/store files (thanks to fpm to recreate deb/rpm/…). So it’s certainly more reliable than my unpatching solution, but it does not benefit from the system’s library (and is therefore closer to an AppImage/flatpack that packs all libraries).

@frostbyte what do you prefer? A more reliable solution that packs everything, or a more experimental approach that integrates with the host?

A solution that is able to integrate with the host OS would be best for what I’m trying to do. It might have the potential to not work some of the time, but having integration with package managers is more valuable in this case. Especially, given that a lot of the packages I want to do this with have the same dependencies.