use init functions to register module types, etc.

Instead of putting all the blueprint registrations in soong_build,
put them all in init() functions.  This puts the registration next
to the implementation.

Change-Id: Ide1a749518f5e9d1367a18ab3bb1d91da3310c76
diff --git a/Android.bp b/Android.bp
index 501e4d5..f001246 100644
--- a/Android.bp
+++ b/Android.bp
@@ -15,6 +15,7 @@
     deps: [
         "blueprint",
         "blueprint-bootstrap",
+        "soong",
         "soong-art",
         "soong-cc",
         "soong-common",
@@ -70,11 +71,24 @@
 }
 
 bootstrap_go_package {
+    name: "soong",
+    pkgPath: "android/soong",
+    deps: [
+        "blueprint",
+    ],
+    srcs: [
+        "doc.go",
+        "register.go",
+    ],
+}
+
+bootstrap_go_package {
     name: "soong-common",
     pkgPath: "android/soong/common",
     deps: [
         "blueprint",
         "blueprint-bootstrap",
+        "soong",
         "soong-env",
         "soong-glob",
     ],
@@ -96,6 +110,7 @@
     deps: [
         "blueprint",
         "blueprint-pathtools",
+        "soong",
         "soong-common",
         "soong-genrule",
     ],
@@ -124,6 +139,7 @@
     deps: [
         "blueprint",
         "blueprint-pathtools",
+        "soong",
         "soong-common",
     ],
     srcs: [
@@ -144,6 +160,7 @@
     deps: [
         "blueprint",
         "blueprint-pathtools",
+        "soong",
         "soong-common",
         "soong-genrule",
     ],