Properly register submodules.