MDL-40435 require MOODLE_INTERNAL in core_component

We need to include db/subplugins.php when building core_component cache,
there are some MOODLE_INTERNALs there…