summaryrefslogtreecommitdiff
path: root/java
AgeCommit message (Collapse)Author
2023-01-19Getting rid of old hacky Libs conversion Alix
Now that libs conversion is happening for the needed module_types, removing if statement with old hacky libs conversion Test: Presubmit Bug: 244210934 Change-Id: I92bb2080eeb7dcb85d087a3ff6054bdf8675ec54
2023-01-19Merge "bp2build support libs for *->android_library_import" Alix Espino
2023-01-17Merge "Replace RuleBuilder usages with static rules in app_import.go" Cole Faust
2023-01-17bp2build support libs for *->android_library_import Alix
Test: bp2build tests Bug: 258688914 Change-Id: Ibeae04e4c006f84f902774821c92f463a7c709eb
2023-01-17support libs for java_plugin -> * Alix
Test: bp2build tests Bug: 244210934 Change-Id: I7dbc820b23c4129485b0991aefb41e00e434d94e
2023-01-17Merge "libs support for android_app->* edge" Alix Espino
2023-01-13Replace RuleBuilder usages with static rules in app_import.go Cole Faust
RuleBuilder creates a new rule in the ninja file every time it's used, but in this case the rules were all exactly the same except that the input/output file paths were different. This can be converted to a single static rule instead. Bug: 262629589 Test: m nothing Change-Id: Iaa887c66a757da13293a3614c000d3be02a2a1b0
2023-01-12Merge "Add java_api_library properties to java_defaults" Jihoon Kang
2023-01-12Merge "Use centralized rules.bzl file for android rules in bp2build." Romain Jobredeaux
2023-01-12libs support for android_app->* edge Alix
Test: bp2build tests Bug: 258688914 Change-Id: I2e24c484019c994b43509f350b3c090a40c3ba6a
2023-01-12Merge "java_binary with kotlin sources" Alix Espino
2023-01-12Merge "Update app tests to set Unbundled_build" Treehugger Robot
2023-01-11Use centralized rules.bzl file for android rules in bp2build. Romain Jobredeaux
Change-Id: I6e4837d8b6715960337d0db9b36f8137efb5673e
2023-01-11Merge "Fix ALLOW_MISSING_DEPENDENCIES builds for prebuilt JNI libraries" Treehugger Robot
2023-01-11Update app tests to set Unbundled_build Harshit Mahajan
Based on the description for UnbundledBuildApps(), UnbundledBuild() should always be true when UnbundledBuildApps() is true. Updating the test to match this condition. More details: https://android-review.git.corp.google.com/c/platform/build/soong/+/2380693/comment/54f172b4_2eee54fa/ Bug: b/227460469 Test: m nothing Change-Id: I3a93edb781522da5af201f6864e157e7bab2195a
2023-01-11Consider only preferred modules for jdeps Inseob Kim
Bug: 263327259 Test: run atest and see modules to be built Change-Id: I208a07e2453b924f8af25db340d970ec039c5f32
2023-01-11Merge "Create a "Toolchain" API surface" Spandan Das
2023-01-10Add java_api_library properties to java_defaults Jihoon Kang
Context - Some Java API surfaces have subset relationships (i.e. public API surface is a subset of system API surface). Thus, simply listing all API files that contributes to hierarchical API surfaces when defining java_api_library modules can lead to repetition of code in Android.bp files. - Utilizing java_defaults can resolve this problem by grouping java_api_contribution modules by API surfaces, and reduce code repetition and enhance readability. Implementation - Modify java_api_library module to utilize java_defaults modules. Test: m Change-Id: I6adead208ca36c21de72ee39c4f532b84af8a153
2023-01-09Move target sdk version enforcement check Harshit Mahajan
Enforce target sdk version flag could only be used by `android_app`, moving the check into a common function `generateAndroidBuildActions`. This would ensure that the `enforce_target_sdk_version` flag can also be set by `android_test` and `android_test_helper_app`. Bug: b/227460469 Test: m nothing Change-Id: I86e0bf684a5083221dae53907d9f548a0390b673
2023-01-09java_binary with kotlin sources Alix
Test: bp2build conversion tests and inspected build file for AnalyzerKt Change-Id: I0f6d5c3d371a9dbd000b74144ad68d5d8bd156cf
2023-01-09Merge "Move art's java_system_modules into a shared inner tree" Spandan Das
2023-01-09Merge "Configure ObsoleteLintCustomCheck lint as fatal" Matt Gilbride
2023-01-07Merge changes I07db8afc,Ia89e0239 Treehugger Robot
* changes: Stop module types being SdkAware Replace usages of SdkAware in sdk module with Module
2023-01-07Merge "Remove SdkAware.SdkMemberComponentName" Treehugger Robot
2023-01-06Merge "Remove IsModuleInVersionedSdk" Paul Duffin
2023-01-06Merge "Dedup checks for module being in versioned sdk snapshot" Paul Duffin
2023-01-06Merge "support libs for android_library" Treehugger Robot
2023-01-05support libs for android_library Alix
adds support for *-> android_library and android_library->* edges Change-Id: I41d4e1d1b8106a17e67951d47e67b59ef3170d17 Test: manually inspected build files for libWallpaperPicker & android-suppor-v4
2023-01-05Configure ObsoleteLintCustomCheck lint as fatal mattgilbride
Lint raises an issue ObsoleteLintCustomCheck if it detects incompatibilities between a custom lint check jar and the lint api itself. This is a warning by default, but in AOSP it should be fatal. Any custom checks are expected to run. If they don't, there is risk of introducing bugs. ObsoleteLintCustomCheck will now cause build breakage so that it will be investigated immediately. Bug: N/A Test: TH Change-Id: I3a46c93d5b53ee0e1add7c287af791bd1b41f1c1
2023-01-05Merge "Revert "R8/D8 should use sdk_version prop to determine API surface ↵ Spandan Das
stability.""
2023-01-04Revert "R8/D8 should use sdk_version prop to determine API surface stability." Spandan Das
This reverts commit daa220ae8ce36c3c155bb35b205a5826c779202c. Reason for revert: Suspected to be a cause for build failure (b/264446640). Will use go/abtd to verify Change-Id: Ibfdf893f2426b1119923467027e0acedd08808c1
2023-01-04Merge "Libs support for * -> java_library_edge with kt sources" Alix Espino
2023-01-04Merge "Allow adding extra tradefed options in the Android.bp file" Cole Faust
2023-01-04Merge "R8/D8 should use sdk_version prop to determine API surface stability." Treehugger Robot
2023-01-04R8/D8 should use sdk_version prop to determine API surface stability. Spandan Das
`min_sdk_version` is used to represent the api_level of the device and its type will eventually become android.ApiLevel. OTOH, `sdk_version` property represents the API surface a module builds against _and_ the version of that API surface. For R8/D8, the additional `--android-platform-build` should be determined using the sdk_version of the soong module and not min_sdk_version, since min_sdk_version will not contain information about the api surface used for compilation. The unit test for `core_platform_app` in TestR8 were passing since min_sdk_version was not set, and therefore it implicitly defaulted to sdk_version. Also created a custom struct to propagate params to the helper dex functions Test: In build/soong, go test ./java Test: TH Bug: 208456999 Change-Id: I08ac6f496444d603557e498c8a1794af665abc7a
2023-01-03Allow adding extra tradefed options in the Android.bp file Cole Faust
Some tests need to add custom tradefed options, but still want to keep most of the soong autogenerated tradefed xml file. Expose a test_options: { tradefed_options: [...] } property that will allow tests to add more options to the autogenerated xml file. Fixes: 184895128 Test: go test, and verified that the ninja files did not change for aosp_arm64 Change-Id: I50d4ad139322e9e207202f1e1a50f5bbb424aa6f
2022-12-29Merge "Create (API) bp2build converters for droidstubs" Spandan Das
2022-12-29Merge "Don't add dexpreopt compat deps to android_library modules" Treehugger Robot
2022-12-28Create a "Toolchain" API surface Spandan Das
This creates a new API surface for the APIs provided by ART to compile other API domains (e.g. this contains LambdaMetaFactory). The scope of this API surface is restricted to compile-time. Unlike the other API surfaces (e.g. public) whose APIs will exist on device in the form of implementation libraries, these classes are not guaranteed to exist on device. This also updates the naming convention map used in Multi-tree API export Bug: 261244752 Test: TH Change-Id: I164714d68618a3c289bac1a695958e36fdbbda5d
2022-12-28Create (API) bp2build converters for droidstubs Spandan Das
- The converter runs for api_bp2build, not bp2build workspace - Since droidstubs is an internal module created by java_sdk_library, the conversion encompasses the latter as well - Since droidstubs do not have an api_surface attribute, this conversion uses naming convention to infer the api_surface represented by the api file e.g. *stubs.source -> publicapi, *stubs.source.system -> systemapi) - Also adds an SdkIntraCore enum to represent the API surface provided by one core module to another There is also ongoing work to check in java_api_contribution modules in Soong. Once we have that, we can update this converter to operate on that module type instead Test: go test ./bp2build Change-Id: Ia85828e04c738d9ffcc524856d7c3034ee29bbf9
2022-12-27Set Java version for java_api_library module Jihoon Kang
Currently, stubs are compiled with Java version 1.8. To align with this, set the java version passed to javac invocation as 1.8 for java_api_library module. Helper function is used to sync the java version of droiddoc module and java_api_library module. Test: m Change-Id: I103b94aed9747a2f2dd65d13de0ae9c0f33db5c0
2022-12-21Don't add dexpreopt compat deps to android_library modules Colin Cross
android_library modules are only dexpreopted when built into an app, and the app will already get the dexpreopt compat dependencies itself. Adding the compat dependencies to android_library modules causes circular dependencies when the android_library is used to build part of the framework, which is then used to build the compat libraries, which is added as a dependency to the andorid_library. Test: TestUsesLibraries Change-Id: I3aca780858c7e5f19d270bcbbe18e6cff8616b43
2022-12-20Merge "Revert "Allow adding extra tradefed options in the Android.bp file"" Jigar Thakkar
2022-12-19Revert "Revert "Include proguard flag files from transitive java_library deps"" Jared Duke
This reverts commit 6f7e288fb5ea2fb01d9093fd57081a82c09a6618. Reason for revert: Downstream proguard usage has been fixed. Change-Id: I3667e7e908eebc62c640b42cb96b04993fc66e45
2022-12-19Fix ALLOW_MISSING_DEPENDENCIES builds for prebuilt JNI libraries Colin Cross
Check for ALLOW_MISSING_DEPENDENCIES before reporting an error with a prebuilt JNI library missing the required architecture. Bug: 263138197 Test: lunch aosp_riscv64-userdebug && m Change-Id: Ifa02c3c690cca1bf7b2b62cf9888f80d96073d71
2022-12-19Revert "Allow adding extra tradefed options in the Android.bp file" Tahsin Loqman
This reverts commit 8ec823cba166a41eb0e9e5ff8fe679e691fec678. Reason for revert: DroidMonitor: Potential culprit for Bug b/262965953 - verifying through ABTD before revert submission. This is part of the standard investigation process, and does not mean your CL will be reverted. Change-Id: I236cc36981d8b30527ca286632727f8ca267e969
2022-12-19Merge "Add test for missing certificate with AllowMissingDependencies" Treehugger Robot
2022-12-17Merge "Allow adding extra tradefed options in the Android.bp file" Treehugger Robot
2022-12-17Merge "Revert "Include proguard flag files from transitive java_library deps"" Colin Cross
2022-12-17Revert "Include proguard flag files from transitive java_library deps" Colin Cross
This reverts commit 9c54f032b9dbef63b9ef235c2219a4e9124f8891. Reason for revert: b/262940536 Bug: b/262940536 Change-Id: I8140eacc7ca8716f799561412cb5cef29df35d29