diff options
author | Remi NGUYEN VAN <reminv@google.com> | 2019-03-25 07:40:33 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2019-03-25 07:40:33 +0000 |
commit | 2fef7f76f4cc7731f9fc0bd10f850bd2a764c9d1 (patch) | |
tree | 7608eb86e965f025e6290eb8d75e9e91f77c8407 | |
parent | be867b67c601817c2b8bb9b290f1962f75d9a6f7 (diff) | |
parent | 4036956bbf75d2e72ad487fd858b8f39d5c6e309 (diff) |
Merge "Compile NetworkStack resources only once"
-rw-r--r-- | Android.bp | 37 |
1 files changed, 20 insertions, 17 deletions
@@ -14,11 +14,16 @@ // limitations under the License. // +java_defaults { + name: "NetworkStackCommon", + sdk_version: "system_current", + min_sdk_version: "28", +} + // Library including the network stack, used to compile both variants of the network stack android_library { name: "NetworkStackBase", - sdk_version: "system_current", - min_sdk_version: "28", + defaults: ["NetworkStackCommon"], srcs: [ "src/**/*.java", ":framework-networkstack-shared-srcs", @@ -34,34 +39,32 @@ android_library { manifest: "AndroidManifestBase.xml", } -// Non-updatable in-process network stack for devices not using the module -android_app { - name: "InProcessNetworkStack", - sdk_version: "system_current", - min_sdk_version: "28", - certificate: "platform", +java_defaults { + name: "NetworkStackAppCommon", + defaults: ["NetworkStackCommon"], privileged: true, static_libs: [ "NetworkStackBase", ], + // Resources already included in NetworkStackBase + resource_dirs: [], jarjar_rules: "jarjar-rules-shared.txt", // The permission configuration *must* be included to ensure security of the device required: ["NetworkStackPermissionStub"], +} + +// Non-updatable network stack running in the system server process for devices not using the module +android_app { + name: "InProcessNetworkStack", + defaults: ["NetworkStackAppCommon"], + certificate: "platform", manifest: "AndroidManifest_InProcess.xml", } // Updatable network stack packaged as an application android_app { name: "NetworkStack", - sdk_version: "system_current", - min_sdk_version: "28", + defaults: ["NetworkStackAppCommon"], certificate: "networkstack", - privileged: true, - static_libs: [ - "NetworkStackBase" - ], - jarjar_rules: "jarjar-rules-shared.txt", - // The permission configuration *must* be included to ensure security of the device - required: ["NetworkStackPermissionStub"], manifest: "AndroidManifest.xml", } |