Support Soong-generated module-info.json entries

Allow Soong modules to generate their own module-info.json entries
by merging Soong's module-info.json file into the one generated in
Make.

Skip collecting unnecessary ALL_MODULES.$(my_register_name).*
that are only used for module-info.json if the module was already
handled by Soong via the LOCAL_SOONG_MODULE_INFO_JSON property.

Bug: 309006256
Test: Compare module-info.json
Change-Id: I2c9db3c7c7bae7bd6cb889d7ebc2e383c278c82d
diff --git a/core/definitions.mk b/core/definitions.mk
index 019d36b..1f2d011 100644
--- a/core/definitions.mk
+++ b/core/definitions.mk
@@ -37,6 +37,8 @@
 # sub-variables.
 ALL_MODULES:=
 
+ALL_MAKE_MODULE_INFO_JSON_MODULES:=
+
 # The relative paths of the non-module targets in the system.
 ALL_NON_MODULES:=
 NON_MODULES_WITHOUT_LICENSE_METADATA:=