core: after modules are re-indexed also flush the 'module_index' dependency key. Let cached lib file paths depend on that key. Fixes #663