Various changes and fixes with the general aim to support netbooting NixOS

by serving NixOS images from a NixOS machine to anything supporting PXE.

The described concept works alright, but the main piece of code is far from being ready for the general public (ugly hacks), but I got tired of rebasing and stashing these changes.
Isn't this in RPATH anyway? Maybe it should be fixed by patchelf, not by wrapping?