Loading Android.bp +51 −160 Original line number Original line Diff line number Diff line Loading @@ -14,122 +14,81 @@ // limitations under the License. // limitations under the License. // // // The network stack can be compiled using system_current (non-finalized) SDK, or finalized system_X java_library { // SDK. There is also a variant that uses system_current SDK and runs in the system process name: "captiveportal-lib", // (InProcessNetworkStack). The following structure is used to create the build rules: srcs: ["common/**/*.java"], // libs: [ // NetworkStackAndroidLibraryDefaults <-- common defaults for android libs "androidx.annotation_annotation", // / \ ], // +NetworkStackApiStableShims --> / \ <-- +NetworkStackApiCurrentShims // +NetworkStackApiStableLevel / \ +NetworkStackApiCurrentLevel // +jarjar apistub.api[latest].* / \ +module src/ // to apistub.* / \ // / \ // NetworkStackApiStableDependencies \ // / \ android libs w/ all code // +module src/ --> / \ (also used in unit tests) // / \ | // NetworkStackApiStableLib NetworkStackApiCurrentLib <--* // | | // | <-- +NetworkStackAppDefaults --> | // | (APK build params) | // | | // | <-- +NetworkStackApiStableLevel | <-- +NetworkStackApiCurrentLevel // | | // | | // NetworkStackApiStable NetworkStack, InProcessNetworkStack, <-- APKs // TestNetworkStack // Common defaults to define SDK level java_defaults { name: "NetworkStackApiCurrentLevel", sdk_version: "system_current", sdk_version: "system_current", min_sdk_version: "28", } } java_defaults { java_defaults { name: "NetworkStackApiStableLevel", name: "NetworkStackCommon", sdk_version: "system_29", sdk_version: "system_current", min_sdk_version: "28", min_sdk_version: "28", } } // Filegroups for the API shims // Library including the network stack, used to compile both variants of the network stack filegroup { android_library { name: "NetworkStackApiCurrentShims", name: "NetworkStackBase", srcs: [ defaults: ["NetworkStackCommon"], "apishim/common/**/*.java", "apishim/29/**/*.java", "apishim/current/**/*.java", ":net-module-utils-srcs", ], } // API stable shims only include the compat package, but it is jarjared to replace the non-compat // package filegroup { name: "NetworkStackApiStableShims", srcs: [ "apishim/common/**/*.java", "apishim/29/**/*.java", ":net-module-utils-srcs", ], } // Common defaults for android libraries containing network stack code, used to compile variants of // the network stack in the system process and in the network_stack process java_defaults { name: "NetworkStackAndroidLibraryDefaults", srcs: [ srcs: [ "src/**/*.java", ":framework-networkstack-shared-srcs", ":framework-networkstack-shared-srcs", ":services-networkstack-shared-srcs", ":services-networkstack-shared-srcs", ":statslog-networkstack-java-gen", ":statslog-networkstack-java-gen", ], ], static_libs: [ static_libs: [ "androidx.annotation_annotation", "androidx.annotation_annotation", "ipmemorystore-client", "netd_aidl_interface-V2-java", "netd_aidl_interface-V2-java", "networkstack-client", "networkstack-aidl-interfaces-V3-java", "datastallprotosnano", "datastallprotosnano", "networkstackprotosnano", "networkstackprotosnano", "captiveportal-lib", "captiveportal-lib", ], ], plugins: ["java_api_finder"], } // The versions of the android library containing network stack code compiled for each SDK variant // API current uses the sources of the API current shims directly. // This allows API current code to be treated identically to code in src/ (it will be moved // there eventually), and to use the compat shim as fallback on older devices. android_library { name: "NetworkStackApiCurrentLib", defaults: ["NetworkStackApiCurrentLevel", "NetworkStackAndroidLibraryDefaults"], srcs: [":NetworkStackApiCurrentShims", "src/**/*.java"], manifest: "AndroidManifestBase.xml", manifest: "AndroidManifestBase.xml", plugins: ["java_api_finder"], } } // For API stable, first build the dependencies using jarjar compat rules, then build the sources cc_library_shared { // linking with the dependencies. name: "libnetworkstackutilsjni", java_library { srcs: [ name: "NetworkStackApiStableDependencies", "jni/network_stack_utils_jni.cpp" defaults: ["NetworkStackApiStableLevel", "NetworkStackAndroidLibraryDefaults"], ], srcs: [":NetworkStackApiStableShims"], sdk_version: "current", jarjar_rules: "apishim/jarjar-rules-compat.txt", shared_libs: [ } "liblog", "libnativehelper_compat_libc++", ], android_library { // We cannot use plain "libc++" here to link libc++ dynamically because it results in: name: "NetworkStackApiStableLib", // java.lang.UnsatisfiedLinkError: dlopen failed: library "libc++_shared.so" not found defaults: ["NetworkStackApiStableLevel"], // even if "libc++" is added into jni_libs below. Adding "libc++_shared" into jni_libs doesn't srcs: ["src/**/*.java"], // build because soong complains of: // API stable uses a jarjared version of the shims // module NetworkStack missing dependencies: libc++_shared static_libs: [ // "NetworkStackApiStableDependencies", // So, link libc++ statically. This means that we also need to ensure that all the C++ libraries // we depend on do not dynamically link libc++. This is currently the case, because liblog is // C-only and libnativehelper_compat_libc also uses stl: "c++_static". // // TODO: find a better solution for this in R. stl: "c++_static", cflags: [ "-Wall", "-Werror", "-Wno-unused-parameter", ], ], manifest: "AndroidManifestBase.xml", } } // Common defaults for compiling the actual APK, based on the NetworkStackApiXBase android libraries java_defaults { java_defaults { name: "NetworkStackAppDefaults", name: "NetworkStackAppCommon", defaults: ["NetworkStackCommon"], privileged: true, privileged: true, static_libs: [ "NetworkStackBase", ], jni_libs: [ jni_libs: [ "libnativehelper_compat_libc++", "libnativehelper_compat_libc++", "libnetworkstackutilsjni", "libnetworkstackutilsjni", Loading @@ -137,7 +96,6 @@ java_defaults { // Resources already included in NetworkStackBase // Resources already included in NetworkStackBase resource_dirs: [], resource_dirs: [], jarjar_rules: "jarjar-rules-shared.txt", jarjar_rules: "jarjar-rules-shared.txt", use_embedded_native_libs: true, optimize: { optimize: { proguard_flags_files: ["proguard.flags"], proguard_flags_files: ["proguard.flags"], }, }, Loading @@ -146,12 +104,11 @@ java_defaults { // Non-updatable network stack running in the system server process for devices not using the module // Non-updatable network stack running in the system server process for devices not using the module android_app { android_app { name: "InProcessNetworkStack", name: "InProcessNetworkStack", defaults: [ "NetworkStackAppDefaults", "NetworkStackApiCurrentLevel"], defaults: ["NetworkStackAppCommon"], static_libs: ["NetworkStackApiCurrentLib"], certificate: "platform", certificate: "platform", manifest: "AndroidManifest_InProcess.xml", manifest: "AndroidManifest_InProcess.xml", // InProcessNetworkStack is a replacement for NetworkStack // InProcessNetworkStack is a replacement for NetworkStack overrides: ["NetworkStack", "NetworkStackNext"], overrides: ["NetworkStack"], // The permission configuration *must* be included to ensure security of the device // The permission configuration *must* be included to ensure security of the device // The InProcessNetworkStack goes together with the PlatformCaptivePortalLogin, which replaces // The InProcessNetworkStack goes together with the PlatformCaptivePortalLogin, which replaces // the default CaptivePortalLogin. // the default CaptivePortalLogin. Loading @@ -159,65 +116,16 @@ android_app { } } // Updatable network stack packaged as an application // Updatable network stack packaged as an application android_app { name: "NetworkStackNext", defaults: ["NetworkStackAppDefaults", "NetworkStackApiCurrentLevel"], static_libs: ["NetworkStackApiCurrentLib"], certificate: "networkstack", manifest: "AndroidManifest.xml", // The permission configuration *must* be included to ensure security of the device required: ["NetworkPermissionConfig"], } // Updatable network stack for finalized API android_app { android_app { name: "NetworkStack", name: "NetworkStack", defaults: ["NetworkStackAppDefaults", "NetworkStackApiStableLevel"], defaults: ["NetworkStackAppCommon"], static_libs: ["NetworkStackApiStableLib"], certificate: "networkstack", certificate: "networkstack", manifest: "AndroidManifest.xml", manifest: "AndroidManifest.xml", use_embedded_native_libs: true, // The permission configuration *must* be included to ensure security of the device // The permission configuration *must* be included to ensure security of the device required: ["NetworkPermissionConfig"], required: ["NetworkPermissionConfig"], } } // Android library to derive test APKs for integration tests android_library { name: "TestNetworkStackLib", defaults: ["NetworkStackAppDefaults", "NetworkStackApiCurrentLevel"], static_libs: ["NetworkStackApiCurrentLib"], manifest: "AndroidManifest.xml", } cc_library_shared { name: "libnetworkstackutilsjni", srcs: [ "jni/network_stack_utils_jni.cpp" ], sdk_version: "current", shared_libs: [ "liblog", "libnativehelper_compat_libc++", ], // We cannot use plain "libc++" here to link libc++ dynamically because it results in: // java.lang.UnsatisfiedLinkError: dlopen failed: library "libc++_shared.so" not found // even if "libc++" is added into jni_libs below. Adding "libc++_shared" into jni_libs doesn't // build because soong complains of: // module NetworkStack missing dependencies: libc++_shared // // So, link libc++ statically. This means that we also need to ensure that all the C++ libraries // we depend on do not dynamically link libc++. This is currently the case, because liblog is // C-only and libnativehelper_compat_libc also uses stl: "c++_static". // // TODO: find a better solution for this in R. stl: "c++_static", cflags: [ "-Wall", "-Werror", "-Wno-unused-parameter", ], } genrule { genrule { name: "statslog-networkstack-java-gen", name: "statslog-networkstack-java-gen", tools: ["stats-log-api-gen"], tools: ["stats-log-api-gen"], Loading @@ -225,20 +133,3 @@ genrule { " --javaPackage com.android.networkstack.metrics --javaClass NetworkStackStatsLog", " --javaPackage com.android.networkstack.metrics --javaClass NetworkStackStatsLog", out: ["com/android/networkstack/metrics/NetworkStackStatsLog.java"], out: ["com/android/networkstack/metrics/NetworkStackStatsLog.java"], } } genrule { name: "NetworkStackTestAndroidManifest", srcs: ["AndroidManifest.xml"], out: ["TestAndroidManifest.xml"], cmd: "sed 's/versionCode=\".*\"/versionCode=\"300000000\"/' $(in) > $(out)", } android_app { name: "TestNetworkStack", defaults: ["NetworkStackAppDefaults", "NetworkStackApiCurrentLevel"], static_libs: ["NetworkStackApiCurrentLib"], certificate: "networkstack", manifest: ":NetworkStackTestAndroidManifest", // The permission configuration *must* be included to ensure security of the device required: ["NetworkPermissionConfig"], } AndroidManifest.xml +2 −4 Original line number Original line Diff line number Diff line Loading @@ -43,10 +43,8 @@ <uses-permission android:name="android.permission.MAINLINE_NETWORK_STACK" /> <uses-permission android:name="android.permission.MAINLINE_NETWORK_STACK" /> <application <application android:extractNativeLibs="false" android:extractNativeLibs="false" android:persistent="true" android:persistent="true"> android:process="com.android.networkstack.process"> <service android:name="com.android.server.NetworkStackService"> <service android:name="com.android.server.NetworkStackService" android:permission="android.permission.MAINLINE_NETWORK_STACK"> <intent-filter> <intent-filter> <action android:name="android.net.INetworkStackConnector"/> <action android:name="android.net.INetworkStackConnector"/> </intent-filter> </intent-filter> Loading AndroidManifest_InProcess.xml +1 −3 Original line number Original line Diff line number Diff line Loading @@ -22,9 +22,7 @@ android:process="system"> android:process="system"> <uses-sdk android:minSdkVersion="28" android:targetSdkVersion="28" /> <uses-sdk android:minSdkVersion="28" android:targetSdkVersion="28" /> <application> <application> <service android:name="com.android.server.NetworkStackService" <service android:name="com.android.server.NetworkStackService" android:process="system"> android:process="system" android:permission="android.permission.MAINLINE_NETWORK_STACK"> <intent-filter> <intent-filter> <action android:name="android.net.INetworkStackConnector.InProcess"/> <action android:name="android.net.INetworkStackConnector.InProcess"/> </intent-filter> </intent-filter> Loading CleanSpec.mkdeleted 100644 → 0 +0 −53 Original line number Original line Diff line number Diff line # Copyright (C) 2019 The Android Open Source Project # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # # If you don't need to do a full clean build but would like to touch # a file or delete some intermediate files, add a clean step to the end # of the list. These steps will only be run once, if they haven't been # run before. # # E.g.: # $(call add-clean-step, touch -c external/sqlite/sqlite3.h) # $(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/STATIC_LIBRARIES/libz_intermediates) # # Always use "touch -c" and "rm -f" or "rm -rf" to gracefully deal with # files that are missing or have been moved. # # Use $(PRODUCT_OUT) to get to the "out/target/product/blah/" directory. # Use $(OUT_DIR) to refer to the "out" directory. # # If you need to re-do something that's already mentioned, just copy # the command and add it to the bottom of the list. E.g., if a change # that you made last week required touching a file and a change you # made today requires touching the same file, just copy the old # touch step and add it to the end of the list. # # ***************************************************************** # NEWER CLEAN STEPS MUST BE AT THE END OF THE LIST ABOVE THE BANNER # ***************************************************************** # For example: #$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/APPS/AndroidTests_intermediates) #$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/core_intermediates) #$(call add-clean-step, find $(OUT_DIR) -type f -name "IGTalkSession*" -print0 | xargs -0 rm -f) #$(call add-clean-step, rm -rf $(PRODUCT_OUT)/data/*) $(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/app/CaptivePortalLogin) $(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/priv-app/NetworkStack) $(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/priv-app/NetworkStackApiStable) # ****************************************************************** # NEWER CLEAN STEPS MUST BE AT THE END OF THE LIST ABOVE THIS BANNER # ****************************************************************** OWNERS +4 −5 Original line number Original line Diff line number Diff line codewiz@google.com set noparent jchalard@google.com junyulai@google.com lorenzo@google.com lorenzo@google.com reminv@google.com baligh@google.com satk@google.com delphij@google.com Loading
Android.bp +51 −160 Original line number Original line Diff line number Diff line Loading @@ -14,122 +14,81 @@ // limitations under the License. // limitations under the License. // // // The network stack can be compiled using system_current (non-finalized) SDK, or finalized system_X java_library { // SDK. There is also a variant that uses system_current SDK and runs in the system process name: "captiveportal-lib", // (InProcessNetworkStack). The following structure is used to create the build rules: srcs: ["common/**/*.java"], // libs: [ // NetworkStackAndroidLibraryDefaults <-- common defaults for android libs "androidx.annotation_annotation", // / \ ], // +NetworkStackApiStableShims --> / \ <-- +NetworkStackApiCurrentShims // +NetworkStackApiStableLevel / \ +NetworkStackApiCurrentLevel // +jarjar apistub.api[latest].* / \ +module src/ // to apistub.* / \ // / \ // NetworkStackApiStableDependencies \ // / \ android libs w/ all code // +module src/ --> / \ (also used in unit tests) // / \ | // NetworkStackApiStableLib NetworkStackApiCurrentLib <--* // | | // | <-- +NetworkStackAppDefaults --> | // | (APK build params) | // | | // | <-- +NetworkStackApiStableLevel | <-- +NetworkStackApiCurrentLevel // | | // | | // NetworkStackApiStable NetworkStack, InProcessNetworkStack, <-- APKs // TestNetworkStack // Common defaults to define SDK level java_defaults { name: "NetworkStackApiCurrentLevel", sdk_version: "system_current", sdk_version: "system_current", min_sdk_version: "28", } } java_defaults { java_defaults { name: "NetworkStackApiStableLevel", name: "NetworkStackCommon", sdk_version: "system_29", sdk_version: "system_current", min_sdk_version: "28", min_sdk_version: "28", } } // Filegroups for the API shims // Library including the network stack, used to compile both variants of the network stack filegroup { android_library { name: "NetworkStackApiCurrentShims", name: "NetworkStackBase", srcs: [ defaults: ["NetworkStackCommon"], "apishim/common/**/*.java", "apishim/29/**/*.java", "apishim/current/**/*.java", ":net-module-utils-srcs", ], } // API stable shims only include the compat package, but it is jarjared to replace the non-compat // package filegroup { name: "NetworkStackApiStableShims", srcs: [ "apishim/common/**/*.java", "apishim/29/**/*.java", ":net-module-utils-srcs", ], } // Common defaults for android libraries containing network stack code, used to compile variants of // the network stack in the system process and in the network_stack process java_defaults { name: "NetworkStackAndroidLibraryDefaults", srcs: [ srcs: [ "src/**/*.java", ":framework-networkstack-shared-srcs", ":framework-networkstack-shared-srcs", ":services-networkstack-shared-srcs", ":services-networkstack-shared-srcs", ":statslog-networkstack-java-gen", ":statslog-networkstack-java-gen", ], ], static_libs: [ static_libs: [ "androidx.annotation_annotation", "androidx.annotation_annotation", "ipmemorystore-client", "netd_aidl_interface-V2-java", "netd_aidl_interface-V2-java", "networkstack-client", "networkstack-aidl-interfaces-V3-java", "datastallprotosnano", "datastallprotosnano", "networkstackprotosnano", "networkstackprotosnano", "captiveportal-lib", "captiveportal-lib", ], ], plugins: ["java_api_finder"], } // The versions of the android library containing network stack code compiled for each SDK variant // API current uses the sources of the API current shims directly. // This allows API current code to be treated identically to code in src/ (it will be moved // there eventually), and to use the compat shim as fallback on older devices. android_library { name: "NetworkStackApiCurrentLib", defaults: ["NetworkStackApiCurrentLevel", "NetworkStackAndroidLibraryDefaults"], srcs: [":NetworkStackApiCurrentShims", "src/**/*.java"], manifest: "AndroidManifestBase.xml", manifest: "AndroidManifestBase.xml", plugins: ["java_api_finder"], } } // For API stable, first build the dependencies using jarjar compat rules, then build the sources cc_library_shared { // linking with the dependencies. name: "libnetworkstackutilsjni", java_library { srcs: [ name: "NetworkStackApiStableDependencies", "jni/network_stack_utils_jni.cpp" defaults: ["NetworkStackApiStableLevel", "NetworkStackAndroidLibraryDefaults"], ], srcs: [":NetworkStackApiStableShims"], sdk_version: "current", jarjar_rules: "apishim/jarjar-rules-compat.txt", shared_libs: [ } "liblog", "libnativehelper_compat_libc++", ], android_library { // We cannot use plain "libc++" here to link libc++ dynamically because it results in: name: "NetworkStackApiStableLib", // java.lang.UnsatisfiedLinkError: dlopen failed: library "libc++_shared.so" not found defaults: ["NetworkStackApiStableLevel"], // even if "libc++" is added into jni_libs below. Adding "libc++_shared" into jni_libs doesn't srcs: ["src/**/*.java"], // build because soong complains of: // API stable uses a jarjared version of the shims // module NetworkStack missing dependencies: libc++_shared static_libs: [ // "NetworkStackApiStableDependencies", // So, link libc++ statically. This means that we also need to ensure that all the C++ libraries // we depend on do not dynamically link libc++. This is currently the case, because liblog is // C-only and libnativehelper_compat_libc also uses stl: "c++_static". // // TODO: find a better solution for this in R. stl: "c++_static", cflags: [ "-Wall", "-Werror", "-Wno-unused-parameter", ], ], manifest: "AndroidManifestBase.xml", } } // Common defaults for compiling the actual APK, based on the NetworkStackApiXBase android libraries java_defaults { java_defaults { name: "NetworkStackAppDefaults", name: "NetworkStackAppCommon", defaults: ["NetworkStackCommon"], privileged: true, privileged: true, static_libs: [ "NetworkStackBase", ], jni_libs: [ jni_libs: [ "libnativehelper_compat_libc++", "libnativehelper_compat_libc++", "libnetworkstackutilsjni", "libnetworkstackutilsjni", Loading @@ -137,7 +96,6 @@ java_defaults { // Resources already included in NetworkStackBase // Resources already included in NetworkStackBase resource_dirs: [], resource_dirs: [], jarjar_rules: "jarjar-rules-shared.txt", jarjar_rules: "jarjar-rules-shared.txt", use_embedded_native_libs: true, optimize: { optimize: { proguard_flags_files: ["proguard.flags"], proguard_flags_files: ["proguard.flags"], }, }, Loading @@ -146,12 +104,11 @@ java_defaults { // Non-updatable network stack running in the system server process for devices not using the module // Non-updatable network stack running in the system server process for devices not using the module android_app { android_app { name: "InProcessNetworkStack", name: "InProcessNetworkStack", defaults: [ "NetworkStackAppDefaults", "NetworkStackApiCurrentLevel"], defaults: ["NetworkStackAppCommon"], static_libs: ["NetworkStackApiCurrentLib"], certificate: "platform", certificate: "platform", manifest: "AndroidManifest_InProcess.xml", manifest: "AndroidManifest_InProcess.xml", // InProcessNetworkStack is a replacement for NetworkStack // InProcessNetworkStack is a replacement for NetworkStack overrides: ["NetworkStack", "NetworkStackNext"], overrides: ["NetworkStack"], // The permission configuration *must* be included to ensure security of the device // The permission configuration *must* be included to ensure security of the device // The InProcessNetworkStack goes together with the PlatformCaptivePortalLogin, which replaces // The InProcessNetworkStack goes together with the PlatformCaptivePortalLogin, which replaces // the default CaptivePortalLogin. // the default CaptivePortalLogin. Loading @@ -159,65 +116,16 @@ android_app { } } // Updatable network stack packaged as an application // Updatable network stack packaged as an application android_app { name: "NetworkStackNext", defaults: ["NetworkStackAppDefaults", "NetworkStackApiCurrentLevel"], static_libs: ["NetworkStackApiCurrentLib"], certificate: "networkstack", manifest: "AndroidManifest.xml", // The permission configuration *must* be included to ensure security of the device required: ["NetworkPermissionConfig"], } // Updatable network stack for finalized API android_app { android_app { name: "NetworkStack", name: "NetworkStack", defaults: ["NetworkStackAppDefaults", "NetworkStackApiStableLevel"], defaults: ["NetworkStackAppCommon"], static_libs: ["NetworkStackApiStableLib"], certificate: "networkstack", certificate: "networkstack", manifest: "AndroidManifest.xml", manifest: "AndroidManifest.xml", use_embedded_native_libs: true, // The permission configuration *must* be included to ensure security of the device // The permission configuration *must* be included to ensure security of the device required: ["NetworkPermissionConfig"], required: ["NetworkPermissionConfig"], } } // Android library to derive test APKs for integration tests android_library { name: "TestNetworkStackLib", defaults: ["NetworkStackAppDefaults", "NetworkStackApiCurrentLevel"], static_libs: ["NetworkStackApiCurrentLib"], manifest: "AndroidManifest.xml", } cc_library_shared { name: "libnetworkstackutilsjni", srcs: [ "jni/network_stack_utils_jni.cpp" ], sdk_version: "current", shared_libs: [ "liblog", "libnativehelper_compat_libc++", ], // We cannot use plain "libc++" here to link libc++ dynamically because it results in: // java.lang.UnsatisfiedLinkError: dlopen failed: library "libc++_shared.so" not found // even if "libc++" is added into jni_libs below. Adding "libc++_shared" into jni_libs doesn't // build because soong complains of: // module NetworkStack missing dependencies: libc++_shared // // So, link libc++ statically. This means that we also need to ensure that all the C++ libraries // we depend on do not dynamically link libc++. This is currently the case, because liblog is // C-only and libnativehelper_compat_libc also uses stl: "c++_static". // // TODO: find a better solution for this in R. stl: "c++_static", cflags: [ "-Wall", "-Werror", "-Wno-unused-parameter", ], } genrule { genrule { name: "statslog-networkstack-java-gen", name: "statslog-networkstack-java-gen", tools: ["stats-log-api-gen"], tools: ["stats-log-api-gen"], Loading @@ -225,20 +133,3 @@ genrule { " --javaPackage com.android.networkstack.metrics --javaClass NetworkStackStatsLog", " --javaPackage com.android.networkstack.metrics --javaClass NetworkStackStatsLog", out: ["com/android/networkstack/metrics/NetworkStackStatsLog.java"], out: ["com/android/networkstack/metrics/NetworkStackStatsLog.java"], } } genrule { name: "NetworkStackTestAndroidManifest", srcs: ["AndroidManifest.xml"], out: ["TestAndroidManifest.xml"], cmd: "sed 's/versionCode=\".*\"/versionCode=\"300000000\"/' $(in) > $(out)", } android_app { name: "TestNetworkStack", defaults: ["NetworkStackAppDefaults", "NetworkStackApiCurrentLevel"], static_libs: ["NetworkStackApiCurrentLib"], certificate: "networkstack", manifest: ":NetworkStackTestAndroidManifest", // The permission configuration *must* be included to ensure security of the device required: ["NetworkPermissionConfig"], }
AndroidManifest.xml +2 −4 Original line number Original line Diff line number Diff line Loading @@ -43,10 +43,8 @@ <uses-permission android:name="android.permission.MAINLINE_NETWORK_STACK" /> <uses-permission android:name="android.permission.MAINLINE_NETWORK_STACK" /> <application <application android:extractNativeLibs="false" android:extractNativeLibs="false" android:persistent="true" android:persistent="true"> android:process="com.android.networkstack.process"> <service android:name="com.android.server.NetworkStackService"> <service android:name="com.android.server.NetworkStackService" android:permission="android.permission.MAINLINE_NETWORK_STACK"> <intent-filter> <intent-filter> <action android:name="android.net.INetworkStackConnector"/> <action android:name="android.net.INetworkStackConnector"/> </intent-filter> </intent-filter> Loading
AndroidManifest_InProcess.xml +1 −3 Original line number Original line Diff line number Diff line Loading @@ -22,9 +22,7 @@ android:process="system"> android:process="system"> <uses-sdk android:minSdkVersion="28" android:targetSdkVersion="28" /> <uses-sdk android:minSdkVersion="28" android:targetSdkVersion="28" /> <application> <application> <service android:name="com.android.server.NetworkStackService" <service android:name="com.android.server.NetworkStackService" android:process="system"> android:process="system" android:permission="android.permission.MAINLINE_NETWORK_STACK"> <intent-filter> <intent-filter> <action android:name="android.net.INetworkStackConnector.InProcess"/> <action android:name="android.net.INetworkStackConnector.InProcess"/> </intent-filter> </intent-filter> Loading
CleanSpec.mkdeleted 100644 → 0 +0 −53 Original line number Original line Diff line number Diff line # Copyright (C) 2019 The Android Open Source Project # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # # If you don't need to do a full clean build but would like to touch # a file or delete some intermediate files, add a clean step to the end # of the list. These steps will only be run once, if they haven't been # run before. # # E.g.: # $(call add-clean-step, touch -c external/sqlite/sqlite3.h) # $(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/STATIC_LIBRARIES/libz_intermediates) # # Always use "touch -c" and "rm -f" or "rm -rf" to gracefully deal with # files that are missing or have been moved. # # Use $(PRODUCT_OUT) to get to the "out/target/product/blah/" directory. # Use $(OUT_DIR) to refer to the "out" directory. # # If you need to re-do something that's already mentioned, just copy # the command and add it to the bottom of the list. E.g., if a change # that you made last week required touching a file and a change you # made today requires touching the same file, just copy the old # touch step and add it to the end of the list. # # ***************************************************************** # NEWER CLEAN STEPS MUST BE AT THE END OF THE LIST ABOVE THE BANNER # ***************************************************************** # For example: #$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/APPS/AndroidTests_intermediates) #$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/core_intermediates) #$(call add-clean-step, find $(OUT_DIR) -type f -name "IGTalkSession*" -print0 | xargs -0 rm -f) #$(call add-clean-step, rm -rf $(PRODUCT_OUT)/data/*) $(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/app/CaptivePortalLogin) $(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/priv-app/NetworkStack) $(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/priv-app/NetworkStackApiStable) # ****************************************************************** # NEWER CLEAN STEPS MUST BE AT THE END OF THE LIST ABOVE THIS BANNER # ******************************************************************
OWNERS +4 −5 Original line number Original line Diff line number Diff line codewiz@google.com set noparent jchalard@google.com junyulai@google.com lorenzo@google.com lorenzo@google.com reminv@google.com baligh@google.com satk@google.com delphij@google.com