Hide framework-minus-apex

framework-minus-apex is the jar implementing APIs that the non-updatable
part of the framework provides. It shouldn't be used by modules that are
unbundled. Currently, several modules are using it directly because they
haven't finished clearing their private API usages. Until the work is
finished, allow framework-minus-apex only for those known modules.

Bug: 147128803
Test: m
Change-Id: I09204b7d600a4d0cc1f6d248df6c813bfb8bae01
diff --git a/Android.bp b/Android.bp
index 4b82e1d..3c8a1dc 100644
--- a/Android.bp
+++ b/Android.bp
@@ -451,6 +451,16 @@
     // For backwards compatibility.
     stem: "framework",
     apex_available: ["//apex_available:platform"],
+    visibility: [
+        "//frameworks/base",
+        // TODO(b/144149403) remove the below lines
+        "//frameworks/base/apex/appsearch/framework",
+        "//frameworks/base/apex/blobstore/framework",
+        "//frameworks/base/apex/jobscheduler/framework",
+        "//frameworks/base/apex/statsd/service",
+        "//frameworks/base/wifi",
+        "//frameworks/opt/net/wifi/service",
+    ],
 }
 
 // This "framework" module is NOT installed to the device. It's