diff --git a/apex/apex.go b/apex/apex.go index bc992f063..446cad8b0 100644 --- a/apex/apex.go +++ b/apex/apex.go @@ -95,26 +95,15 @@ func makeApexAvailableWhitelist() map[string][]string { // m["com.android.adbd"] = []string{ "adbd", - "bcm_object", - "fmtlib", "libadbconnection_server", "libadbd", "libadbd_auth", "libadbd_core", "libadbd_services", "libasyncio", - "libbacktrace_headers", - "libbase", - "libbase_headers", "libbuildversion", - "libc++", "libcap", - "libcrypto", - "libcrypto_utils", - "libcutils", - "libcutils_headers", "libdiagnose_usb", - "liblog_headers", "libmdnssd", "libminijail", "libminijail_gen_constants", @@ -126,8 +115,6 @@ func makeApexAvailableWhitelist() map[string][]string { "libpcre2", "libprocessgroup_headers", "libqemu_pipe", - "libsystem_headers", - "libutils_headers", } // // Module separator @@ -136,7 +123,6 @@ func makeApexAvailableWhitelist() map[string][]string { "art_cmdlineparser_headers", "art_disassembler_headers", "art_libartbase_headers", - "bcm_object", "bionic_libc_platform_headers", "core-repackaged-icu4j", "cpp-define-generator-asm-support", @@ -148,9 +134,7 @@ func makeApexAvailableWhitelist() map[string][]string { "conscrypt.module.intra.core.api.stubs", "dex2oat_headers", "dt_fd_forward_export", - "fmtlib", "icu4c_extra_headers", - "jacocoagent", "javavm_headers", "jni_platform_headers", "libPlatformProperties", @@ -160,15 +144,6 @@ func makeApexAvailableWhitelist() map[string][]string { "libart_runtime_headers_ndk", "libartd-disassembler", "libasync_safe", - "libbacktrace", - "libbase", - "libbase_headers", - "libc++", - "libc++_static", - "libc++abi", - "libc++demangle", - "libc_headers", - "libcrypto", "libdexfile_all_headers", "libdexfile_external_headers", "libdexfile_support", @@ -181,7 +156,6 @@ func makeApexAvailableWhitelist() map[string][]string { "libicuuc_headers", "libicuuc_stubdata", "libjdwp_headers", - "liblog_headers", "liblz4", "liblzma", "libmeminfo", @@ -192,7 +166,6 @@ func makeApexAvailableWhitelist() map[string][]string { "libopenjdkjvmti_headers", "libperfetto_client_experimental", "libprocinfo", - "libprotobuf-cpp-lite", "libunwind_llvm", "libunwindstack", "libv8", @@ -229,13 +202,10 @@ func makeApexAvailableWhitelist() map[string][]string { "android.hidl.token@1.0-utils", "avrcp-target-service", "avrcp_headers", - "bcm_object", "bluetooth-protos-lite", "bluetooth.mapsapi", "com.android.vcard", "dnsresolver_aidl_interface-V2-java", - "fmtlib", - "guava", "ipmemorystore-aidl-interfaces-V5-java", "ipmemorystore-aidl-interfaces-java", "internal_include_headers", @@ -245,9 +215,6 @@ func makeApexAvailableWhitelist() map[string][]string { "libFraunhoferAAC", "libaudio-a2dp-hw-utils", "libaudio-hearing-aid-hw-utils", - "libbacktrace_headers", - "libbase", - "libbase_headers", "libbinder_headers", "libbluetooth", "libbluetooth-types", @@ -269,38 +236,23 @@ func makeApexAvailableWhitelist() map[string][]string { "libbtdevice", "libbte", "libbtif", - "libc++", "libchrome", - "libcrypto", - "libcutils", - "libcutils_headers", "libevent", "libfmq", "libg722codec", "libgtest_prod", "libgui_headers", - "libhidlbase", - "libhidlbase-impl-internal", - "libhidltransport-impl-internal", - "libhwbinder-impl-internal", - "libjsoncpp", - "liblog_headers", "libmedia_headers", "libmodpb64", "libosi", "libprocessgroup", "libprocessgroup_headers", - "libprotobuf-cpp-lite", - "libprotobuf-java-lite", - "libprotobuf-java-micro", "libstagefright_foundation_headers", "libstagefright_headers", "libstatslog", "libstatssocket", - "libsystem_headers", "libtinyxml2", "libudrv-uipc", - "libutils_headers", "libz", "media_plugin_headers", "net-utils-services-common", @@ -320,12 +272,8 @@ func makeApexAvailableWhitelist() map[string][]string { // Module separator // m["com.android.conscrypt"] = []string{ - "bcm_object", "boringssl_self_test", - "libc++", - "libcrypto", "libnativehelper_header_only", - "libssl", "unsupportedappusage", } // @@ -365,28 +313,11 @@ func makeApexAvailableWhitelist() map[string][]string { "android.hidl.memory.token@1.0", "android.hidl.memory@1.0", "android.hidl.safe_union@1.0", - "bcm_object", - "fmtlib", "gemmlowp_headers", "libarect", - "libbacktrace_headers", - "libbase", - "libbase_headers", "libbuildversion", - "libc++", - "libcrypto", - "libcrypto_static", - "libcutils", - "libcutils_headers", "libeigen", "libfmq", - "libhidlbase", - "libhidlbase-impl-internal", - "libhidlmemory", - "libhidltransport-impl-internal", - "libhwbinder-impl-internal", - "libjsoncpp", - "liblog_headers", "libmath", "libneuralnetworks_common", "libneuralnetworks_headers", @@ -394,12 +325,10 @@ func makeApexAvailableWhitelist() map[string][]string { "libprocessgroup_headers", "libprocpartition", "libsync", - "libsystem_headers", "libtextclassifier_hash", "libtextclassifier_hash_headers", "libtextclassifier_hash_static", "libtflite_kernel_utils", - "libutils_headers", "philox_random", "philox_random_headers", "tensorflow_headers", @@ -431,9 +360,7 @@ func makeApexAvailableWhitelist() map[string][]string { "android.hidl.memory@1.0", "android.hidl.token@1.0", "android.hidl.token@1.0-utils", - "bcm_object", "bionic_libc_platform_headers", - "fmtlib", "gl_headers", "libEGL", "libEGL_blobCache", @@ -455,23 +382,14 @@ func makeApexAvailableWhitelist() map[string][]string { "libaudiopolicy", "libaudioutils", "libaudioutils_fixedfft", - "libbacktrace", - "libbacktrace_headers", - "libbase", - "libbase_headers", "libbinder_headers", "libbluetooth-types-header", "libbufferhub", "libbufferhub_headers", "libbufferhubqueue", - "libc++", - "libc_headers", "libc_malloc_debug_backtrace", "libcamera_client", "libcamera_metadata", - "libcrypto", - "libcutils", - "libcutils_headers", "libdexfile_external_headers", "libdexfile_support", "libdvr_headers", @@ -483,14 +401,7 @@ func makeApexAvailableWhitelist() map[string][]string { "libgui", "libgui_headers", "libhardware_headers", - "libhidlbase", - "libhidlbase-impl-internal", - "libhidlmemory", - "libhidltransport-impl-internal", - "libhwbinder-impl-internal", "libinput", - "libjsoncpp", - "liblog_headers", "liblzma", "libmath", "libmedia", @@ -538,11 +449,9 @@ func makeApexAvailableWhitelist() map[string][]string { "libstagefright_mpeg2extractor", "libstagefright_mpeg2support", "libsync", - "libsystem_headers", "libui", "libui_headers", "libunwindstack", - "libutils_headers", "libvibrator", "libvorbisidec", "libwavextractor", @@ -582,7 +491,6 @@ func makeApexAvailableWhitelist() map[string][]string { "android.hidl.safe_union@1.0", "android.hidl.token@1.0", "android.hidl.token@1.0-utils", - "fmtlib", "libEGL", "libFLAC", "libFLAC-config", @@ -599,15 +507,10 @@ func makeApexAvailableWhitelist() map[string][]string { "libavcenc", "libavservices_minijail", "libavservices_minijail", - "libbacktrace", - "libbacktrace_headers", - "libbase", - "libbase_headers", "libbinder_headers", "libbinderthreadstateutils", "libbluetooth-types-header", "libbufferhub_headers", - "libc++", "libc_scudo", "libcap", "libcodec2", @@ -647,8 +550,6 @@ func makeApexAvailableWhitelist() map[string][]string { "libcodec2_soft_vp9dec", "libcodec2_soft_vp9enc", "libcodec2_vndk", - "libcutils", - "libcutils_headers", "libdexfile_support", "libdvr_headers", "libfmq", @@ -664,15 +565,8 @@ func makeApexAvailableWhitelist() map[string][]string { "libhardware_headers", "libhevcdec", "libhevcenc", - "libhidlbase", - "libhidlbase-impl-internal", - "libhidlmemory", - "libhidltransport-impl-internal", - "libhwbinder-impl-internal", "libion", "libjpeg", - "libjsoncpp", - "liblog_headers", "liblzma", "libmath", "libmedia_codecserviceregistrant", @@ -710,11 +604,9 @@ func makeApexAvailableWhitelist() map[string][]string { "libstagefright_m4vh263enc", "libstagefright_mp3dec", "libsync", - "libsystem_headers", "libui", "libui_headers", "libunwindstack", - "libutils_headers", "libvorbisidec", "libvpx", "libyuv", @@ -730,7 +622,6 @@ func makeApexAvailableWhitelist() map[string][]string { "MediaProvider", "MediaProviderGoogle", "fmtlib_ndk", - "guava", "libbase_ndk", "libfuse", "libfuse_jni", @@ -754,7 +645,6 @@ func makeApexAvailableWhitelist() map[string][]string { "kotlinx-coroutines-android-nodeps", "kotlinx-coroutines-core", "kotlinx-coroutines-core-nodeps", - "libprotobuf-java-lite", "permissioncontroller-statsd", } // @@ -762,14 +652,9 @@ func makeApexAvailableWhitelist() map[string][]string { // m["com.android.runtime"] = []string{ "bionic_libc_platform_headers", - "fmtlib", "libarm-optimized-routines-math", "libasync_safe", "libasync_safe_headers", - "libbacktrace_headers", - "libbase", - "libbase_headers", - "libc++", "libc_aeabi", "libc_bionic", "libc_bionic_ndk", @@ -783,7 +668,6 @@ func makeApexAvailableWhitelist() map[string][]string { "libc_freebsd", "libc_freebsd_large_stack", "libc_gdtoa", - "libc_headers", "libc_init_dynamic", "libc_init_static", "libc_jemalloc_wrapper", @@ -798,8 +682,6 @@ func makeApexAvailableWhitelist() map[string][]string { "libc_syscalls", "libc_tzcode", "libc_unwind_static", - "libcutils", - "libcutils_headers", "libdebuggerd", "libdebuggerd_common_headers", "libdebuggerd_handler_core", @@ -812,7 +694,6 @@ func makeApexAvailableWhitelist() map[string][]string { "libjemalloc5", "liblinker_main", "liblinker_malloc", - "liblog_headers", "liblz4", "liblzma", "libprocessgroup_headers", @@ -820,11 +701,9 @@ func makeApexAvailableWhitelist() map[string][]string { "libpropertyinfoparser", "libscudo", "libstdc++", - "libsystem_headers", "libsystemproperties", "libtombstoned_client_static", "libunwindstack", - "libutils_headers", "libz", "libziparchive", } @@ -832,34 +711,19 @@ func makeApexAvailableWhitelist() map[string][]string { // Module separator // m["com.android.resolv"] = []string{ - "bcm_object", "dnsresolver_aidl_interface-unstable-ndk_platform", - "fmtlib", - "libbacktrace_headers", - "libbase", - "libbase_headers", - "libc++", - "libcrypto", - "libcutils", - "libcutils_headers", "libgtest_prod", - "libjsoncpp", - "liblog_headers", "libnativehelper_header_only", "libnetd_client_headers", "libnetd_resolv", "libnetdutils", "libprocessgroup", "libprocessgroup_headers", - "libprotobuf-cpp-lite", - "libssl", "libstatslog_resolv", "libstatspush_compat", "libstatssocket", "libstatssocket_headers", - "libsystem_headers", "libsysutils", - "libutils_headers", "netd_event_listener_interface-ndk_platform", "server_configurable_flags", "stats_proto", @@ -868,28 +732,13 @@ func makeApexAvailableWhitelist() map[string][]string { // Module separator // m["com.android.tethering"] = []string{ - "libbase", - "libc++", "libnativehelper_compat_libc++", "android.hardware.tetheroffload.config@1.0", - "fmtlib", - "libbacktrace_headers", - "libbase_headers", "libcgrouprc", "libcgrouprc_format", - "libcutils", - "libcutils_headers", - "libhidlbase", - "libhidlbase-impl-internal", - "libhidltransport-impl-internal", - "libhwbinder-impl-internal", - "libjsoncpp", - "liblog_headers", "libprocessgroup", "libprocessgroup_headers", - "libsystem_headers", "libtetherutilsjni", - "libutils_headers", "libvndksupport", "tethering-aidl-interfaces-java", } @@ -925,20 +774,9 @@ func makeApexAvailableWhitelist() map[string][]string { "ipmemorystore-aidl-interfaces-V3-java", "ipmemorystore-aidl-interfaces-java", "ksoap2", - "libbacktrace_headers", - "libbase", - "libbase_headers", - "libc++", - "libcutils", - "libcutils_headers", - "liblog_headers", "libnanohttpd", "libprocessgroup", "libprocessgroup_headers", - "libprotobuf-java-lite", - "libprotobuf-java-nano", - "libsystem_headers", - "libutils_headers", "libwifi-jni", "net-utils-services-common", "netd_aidl_interface-V2-java", @@ -966,34 +804,14 @@ func makeApexAvailableWhitelist() map[string][]string { // Module separator // m["com.android.os.statsd"] = []string{ - "libbacktrace_headers", - "libbase_headers", - "libc++", - "libcutils", - "libcutils_headers", - "liblog_headers", "libprocessgroup_headers", "libstatssocket", - "libsystem_headers", - "libutils_headers", } // // Module separator // m[android.AvailableToAnyApex] = []string{ - "crtbegin_dynamic", - "crtbegin_dynamic1", - "crtbegin_so", - "crtbegin_so1", - "crtbegin_static", - "crtbrand", - "crtend_android", - "crtend_so", "libatomic", - "libc++_static", - "libc++abi", - "libc++demangle", - "libc_headers", "libclang_rt", "libgcc_stripped", "libprofile-clang-extras", diff --git a/cc/testing.go b/cc/testing.go index b8a7eab34..e9739ff23 100644 --- a/cc/testing.go +++ b/cc/testing.go @@ -215,6 +215,10 @@ func GatherRequiredDepsForTest(oses ...android.OsType) string { vendor_available: true, recovery_available: true, host_supported: true, + apex_available: [ + "//apex_available:platform", + "//apex_available:anyapex", + ], } cc_library { name: "libc++", @@ -243,6 +247,10 @@ func GatherRequiredDepsForTest(oses ...android.OsType) string { host_supported: false, vendor_available: true, recovery_available: true, + apex_available: [ + "//apex_available:platform", + "//apex_available:anyapex", + ], } cc_library { name: "libunwind_llvm", @@ -254,8 +262,21 @@ func GatherRequiredDepsForTest(oses ...android.OsType) string { recovery_available: true, } + cc_defaults { + name: "crt_defaults", + recovery_available: true, + vendor_available: true, + native_bridge_supported: true, + stl: "none", + apex_available: [ + "//apex_available:platform", + "//apex_available:anyapex", + ], + } + cc_object { name: "crtbegin_so", + defaults: ["crt_defaults"], recovery_available: true, vendor_available: true, native_bridge_supported: true, @@ -264,6 +285,7 @@ func GatherRequiredDepsForTest(oses ...android.OsType) string { cc_object { name: "crtbegin_dynamic", + defaults: ["crt_defaults"], recovery_available: true, vendor_available: true, native_bridge_supported: true, @@ -272,6 +294,7 @@ func GatherRequiredDepsForTest(oses ...android.OsType) string { cc_object { name: "crtbegin_static", + defaults: ["crt_defaults"], recovery_available: true, vendor_available: true, native_bridge_supported: true, @@ -280,6 +303,7 @@ func GatherRequiredDepsForTest(oses ...android.OsType) string { cc_object { name: "crtend_so", + defaults: ["crt_defaults"], recovery_available: true, vendor_available: true, native_bridge_supported: true, @@ -288,6 +312,7 @@ func GatherRequiredDepsForTest(oses ...android.OsType) string { cc_object { name: "crtend_android", + defaults: ["crt_defaults"], recovery_available: true, vendor_available: true, native_bridge_supported: true,