Moved the module manager into its own library.