Pass lib to modules

Since mkOption, types, etc. are defined there, lib is really part of the interface
Add nixosSubmodule option type

Since NixOS modules expect special arguments, use a hack to provide them