config: only list available modules

Instead of hardcoding modules in `src/config.c` procedurally add modules to config file based on their availability in module path. This makes several `#ifdef`s redundant and frees package maintainers from patching this file according to package contents.