Skip to content
Snippets Groups Projects
  1. Jan 18, 2024
  2. Jan 16, 2024
    • Jihoon Kang's avatar
      Add aconfig declarations to f/b droidstubs · c537cba7
      Jihoon Kang authored
      This change pass the aconfig_declaration modules defined in
      AconfigFlags.bp to the *-api-stubs-docs-non-updatable droidstubs module,
      so that the "exportable" stubs (i.e. the stubs only containing the
      flagged apis that are enabled by the release configuration) can be
      generated.
      
      Test: m api-stubs-docs-non-updatable && m checkapi
      Bug: 317290555
      Merged-In: I944d336e474b9ed61f4554fc9325a8df3a9cf40b
      Change-Id: I944d336e474b9ed61f4554fc9325a8df3a9cf40b
      c537cba7
  3. Jan 11, 2024
    • Mårten Kongstad's avatar
      (Temporarily) hide Lint 101 errors · e2da2d62
      Mårten Kongstad authored
      When building SDKs that include some, but not all @FlaggedApis, a few
      Javadoc @see/@link references will point to objects that are
      inaccessible, which will trigger Lint 101 errors.
      
      The correct fix is to update the Javadoc. However, to unblock the SDK
      build for now, temporarily hide Lint 101 errors.
      
      Bug: 319541666
      Test: m sdk dist
      Change-Id: Icbd1d99d5fcd6cee37bf588ef45443e7e946f742
      e2da2d62
    • Jihoon Kang's avatar
      Define exportable full api surface stubs · 059b9493
      Jihoon Kang authored
      The two major roles of the full api surface stubs (i.e.
      android_*_stubs_current) are:
      - Appended to classpath when a module sets sdk_version
      - Input to generating hiddenapi flags and determine the accessibility of
        the api at runtime
      
      With Trunk Stable, all flagged apis that are not enabled should not be
      accessible at runtime. In other words, the currently existing full api
      surface stubs that include both non flagged and flagged apis should not
      be used to generate the hiddenapi flags.
      
      To resolve this problem, this change introduces full api surface stubs
      of the "exportable" stubs (i.e. non flagged apis + flagged apis enabled
      by release configuration).
      
      The new modules are named similarly to the currently existing full api
      surface stubs, but appends the "_exportable" prefix to differentiate
      with the currently existing modules. These modules are solely used for
      hiddenapi flags generation, and the currently existing modules continue
      to serve the first aforementioned role.
      
      The new modules will toggle between the from-text stubs module and the
      from-source stubs module when the exportable stubs can be generated from
      the from-text stubs generating `java_api_library` module. For now, these
      modules are always built from source.
      
      Test: m android_stubs_current_exportable
      Bug: 317426356
      Change-Id: I1f6f738ae9c5ebf151a1554aa1e357ef0092c89c
      059b9493
  4. Jan 10, 2024
    • Harshit Mahajan's avatar
      Add combined_api_defaults module type · b52adbcd
      Harshit Mahajan authored
      Allow specifying default combined api properties. This would be currently used to control the enablement of new mainline modules
      
      Bug:b/289203818
      Test: verified locally
      Change-Id: I9415140453ce04efd5461cb8684c70e987810ecc
      b52adbcd
  5. Jan 08, 2024
    • Cole Faust's avatar
      Update path in comment · 24e730fc
      Cole Faust authored
      This android.bp file was moved, and the comment needs to be updated
      to reflect that.
      
      Test: Presubmits
      Change-Id: I225690505ccbf0f2234e65cbc668ade9bfbd5e17
      24e730fc
  6. Jan 05, 2024
    • Paul Duffin's avatar
      Copy system version of the api-versions.xml file to dist · 75f63607
      Paul Duffin authored
      Copies the system version of the `api-versions.xml` file to a file
      `api-versions_system.xml` in the top level dist directory.
      
      Bug: 190665366
      Test: m sdk dist
            # Check to make sure that the file exists.
      Change-Id: Ie139f81a819eb5f389363ffdefa7bc42d36804e0
      75f63607
  7. Jan 02, 2024
    • Nelson Li's avatar
      Convert .PHONY target of `checkapi ` to Android.bp · cb9a5dd7
      Nelson Li authored
      Since Soong has been able to correctly add dependencies to .PHONY
      targets since aosp/2884366, it is now possible to directly use
      `phony_deps` to add the genrules used by `checkapi` to its dependencies
      and convert them to Android.bp.
      
      Bug: 309730110
      Test: m checkapi
      Change-Id: Ideb9f647415423a5864d221b85442b995ac67906
      cb9a5dd7
  8. Dec 19, 2023
    • Paul Duffin's avatar
      Remove unnecessary --api-lint-ignore-prefix options · 48fefdd2
      Paul Duffin authored
      The `--api-lint-ignore-prefix` option adds a package prefix within
      which API lint checks will be ignored. However, the options are
      not actually necessary. That is because they are only used in the
      `android-non-updatable-stubs-defaults` and the non updatable code does
      not include any source classes from those packages.
      
      While modules that do use `android-non-updatable-stubs-defaults` do
      include classes from those packages on the classpath they are already
      excluded from having API lint checks performed on them as they do not
      contribute to the API surface being generated by those modules.
      
      Bug: 311690008
      Test: m checkapi
      Change-Id: Ife750c586edc2b5af92c0b5e9211b23345083f69
      48fefdd2
  9. Dec 14, 2023
    • Yiming Pan's avatar
      Rename to match internal storage format. · 990fd8dd
      Yiming Pan authored
      Bug: 312784289
      Test: mmm -j frameworks/base/api/coverage/tools/:extract-flagged-apis
            extract-flagged-apis <input api.text file> <output pb file>
      Change-Id: Ibc2e1af9c3346543365ce42058b6e5913161da9f
      990fd8dd
  10. Dec 08, 2023
    • Yiming Pan's avatar
      Change API format in the map file. · 090155e8
      Yiming Pan authored
      * Parameter list should be a part of the API signature.
      * Package, class, and method names are stored separately so they don't
        need to be parsed when being read.
      
      Bug: 315412454
      Test: mmm -j frameworks/base/api/coverage/tools/:extract-flagged-apis
            extract-flagged-apis <input api.text file> <output pb file>
      Change-Id: I769cc10831f1c50c71e71cbaadec355f21258baf
      090155e8
    • Colin Cross's avatar
      Remove bp2build from frameworks/base/api/ · c6420766
      Colin Cross authored
      Bug: 315353489
      Test: m blueprint_tests
      Change-Id: I50d938017203ad12198d8a6373c9aef80a8535c6
      c6420766
  11. Nov 20, 2023
    • Yiming Pan's avatar
      Build flag to API mapping files. · ea84fc81
      Yiming Pan authored
      Flag to API mapping files will be built and uploaded to `droid` target.
      
      Test: m flag-api-mapping-PublicApi
            m flag-api-mapping-SystemApi
            m flag-api-mapping-ModuleLibApi
            m flag-api-mapping-SystemServerApi
      Bug; 311059624
      
      Change-Id: Ibb872e2c1f7772af59427bcec3ce6f6551a8dd17
      ea84fc81
    • Yiming Pan's avatar
      Extract flagged APIs in the nested classes. · 74068a17
      Yiming Pan authored
      Test: mmm -j frameworks/base/api/coverage/tools/:extract-flagged-apis
            extract-flagged-apis <input api.text file> <output pb file>
      Bug: 311059624
      Change-Id: I7db4296e4ee78268b886b83cd822d8ebe151c4a5
      74068a17
  12. Nov 17, 2023
  13. Nov 16, 2023
    • Yiming Pan's avatar
      Extract the mapping of flags to APIs. · a95134ca
      Yiming Pan authored
      This CL creates a binary that extracts flagged APIs from an API
      signature file, and writes the mapping of flags to APIs to a pb file.
      
      Bug: 311059624
      Test: mmm -j frameworks/base/api/coverage/tools/:extract-flagged-apis
            extract-flagged-apis <input api.text file> <output pb file>
      Change-Id: I9b6f45bd126cd6a5b2ed1e9f83bdaa12dd580480
      a95134ca
  14. Nov 15, 2023
    • Harshit Mahajan's avatar
      Revert "[CrashRecovery] Add module lib to Android SDK" · ed0743da
      Harshit Mahajan authored
      Revert submission 2789412-cherrypicker-L65800000963076834:N61100001405784943
      
      Reason for revert: Leading to merge conflict
      Bug: b/311082270
      
      Reverted changes: /q/submissionid:2789412-cherrypicker-L65800000963076834:N61100001405784943
      
      Change-Id: Ic80afd7a8e09cf2e0cf6e453cbe004db0c9fcbd7
      Merged-In: I5c65d85d50b214926f5473908694070b4e896201
      ed0743da
  15. Nov 08, 2023
  16. Nov 06, 2023
    • Anton Hansson's avatar
      Share list of libs to depend on for APIs · 648b0db8
      Anton Hansson authored
      The non-updatable part of the API has a few deps on module APIs. Extract
      the list of libs to satisfy those deps into a variable so that it can be
      shared between the stubs_default and the java_library.
      
      Test: m
      Change-Id: Id416d294150131b477fc9c73a2d5811cfbf7012f
      648b0db8
  17. Nov 01, 2023
  18. Oct 30, 2023
  19. Oct 26, 2023
  20. Oct 23, 2023
    • Mark White's avatar
      Created empty framework-location non-updatable module · 3cc5e00e
      Mark White authored
      Note that this is a re-cherry-pick of the original CL that is closer
      to the original CL than the first CP, to minimize the number of
      conflicts in Android.bp files.
      
      Bug: 289776578
      Test: presubmit
      Merged-In: I721fc4ae5c62cf1eada9bb6b4e5b3f1a4c9db21a
      Change-Id: Ibf98f37cb795bc7f627a485546b6ce8ec23b3a9e
      3cc5e00e
    • Mark White's avatar
      SdkTestCore for non-updatable modules · e35b1384
      Mark White authored
      Provides SdkTestCore/test_core_current sdk_version for non-updatable
      modules that have their test scope dependent on test apis from
      framework-minus-apex.
      
      Ignore-AOSP-First: Change in topic with internal-first projects
      Bug: 289776578
      Test: m checkapi
      
      Merged-In: I855346c01bb609e81b14dbdc13330315badc339e
      Change-Id: I855346c01bb609e81b14dbdc13330315badc339e
      e35b1384
    • Adrian Roos's avatar
      FlaggedApi: enable enforcement for all non-updatable APIs · 36d19aea
      Adrian Roos authored
      (cherry pick of 7da1d255
       and 38dd161e)
      
      Bug: 297362755
      Test: make checkapi
      Merged-In: If7333ead86d9028ab0a1cc8f25fc534cb13a1858
      Merged-In: I4d384efac8a8d3b183d9b207b195ad5489db9e55
      Change-Id: I4d384efac8a8d3b183d9b207b195ad5489db9e55
      36d19aea
    • Anton Hansson's avatar
      Migrate droidstubs/droiddoc to flags · 84a0e71a
      Anton Hansson authored
      The args attribute does not work well with defaults as it's just a
      string, which cannot be extended. Migrate to the flags attribute.
      
      Bug: 306806877
      Test: diff ninja file before/after
      Change-Id: Ifd1d503d2da29bf1cdf2664201f9c8276f9480a4
      84a0e71a
    • Adrian Roos's avatar
      FlaggedApi: enable enforcement for all non-updatable APIs · 440f3cf2
      Adrian Roos authored
      (cherry pick of 7da1d255
       and 38dd161e)
      
      Bug: 297362755
      Test: make checkapi
      Merged-In: If7333ead86d9028ab0a1cc8f25fc534cb13a1858
      Merged-In: I4d384efac8a8d3b183d9b207b195ad5489db9e55
      Change-Id: I4d384efac8a8d3b183d9b207b195ad5489db9e55
      440f3cf2
  21. Oct 20, 2023
    • Anton Hansson's avatar
      Explain the -hide params passed to doclava · 82eef15a
      Anton Hansson authored
      The reason certain checks are disabled in doclava is that they have been
      implemented in metalava instead. Clarify that.
      
      Test: presubmit
      Change-Id: I32c32783dea59a63d95d14b4ad636159536c2944
      82eef15a
  22. Oct 17, 2023
    • Jihoon Kang's avatar
      Fix discrepancy between from text vs source android_test_frameworks_core_stubs_current · beeb35a8
      Jihoon Kang authored
      Just like all other android_*_stubs_current modules,
      android_test_frameworks_core_stubs_current is added to classpath of the
      javac compilation of its reverse dependencies, and its static libs is
      dynamically switched between the ".from-source" suffixed from-source
      stub compiling java_library module and the ".from-text" suffixed
      from-text stub compiling java_api_library module.
      
      Other than the origin of the stubs, the two modules are expected to
      contain (mostly) identical APIs. However, the two static libs of
      android_test_frameworks_core_stubs_current currently do not follow this
      principle as the from-source java_library module does not add the
      "private-stub-annotation-jar" as static lib, while the from-text
      java_api_library does. This discrepancy lead to compilation error of the
      reverse dependencies when defaulting build to from-text stub generation.
      
      This change fixes the discrepancy between the two modules by removing
      "private-stub-annotation-jar" from the static lib of the from-source
      module and making the two modules behave more similarly.
      
      Test: patch on internal main and run `m framework-location.stubs.test.from-source --build-from-text-stub`
      Bug: 301522358
      Change-Id: I821b7bb25a8f7ec7f9977a01ebdfbd5f1b25cf5e
      beeb35a8
  23. Oct 16, 2023
    • Paul Duffin's avatar
      Use lint database from api_version_system · dd97b784
      Paul Duffin authored
      Droidstubs now support using the api-versions.xml from another
      droidstubs module, so reuse the one from `api_versions_system`
      in `framework-doc-system-stubs`.
      
      Test: m framework-docs-system-stubs
            # Diff stubs before and after
      Change-Id: I0aa3a74664e2a9343e90d91b7520ce8bbcadfac5
      dd97b784
    • Harshit Mahajan's avatar
      [CrashRecovery] Add module lib to Android SDK · 9c3742af
      Harshit Mahajan authored
      Adding the module libraries to combined_apis for them to be added to
      Android SDK.
      Also adding bootclasspath-fragment to platform-bootclasspath.
      
      Bug: b/289203818
      Test: m
      
      Change-Id: Ica9b0bddc2f9cb6621a01dcd3859c39357144b5f
      9c3742af
    • Paul Duffin's avatar
      Remove unused `extensions_info_file` property from framework-doc-stubs · 3cfb89b1
      Paul Duffin authored
      The `droidstubs.extensions_info_file` property is only used when
      `api_levels_annotations_enabled: true`. The `framwork-doc-stubs` uses
      `api_levels_module` instead and so does not need `extensions_info_file`
      any more.
      
      Bug: 305688818
      Test: m framework-doc-stubs
            # Before and after and check output to confirm that it does not change
      Change-Id: I4ad3f5b24e998eb9d5d47fa2240d2281fa9d6fc6
      3cfb89b1
  24. Oct 13, 2023
    • Jihoon Kang's avatar
      Disable validations for full api surface stub java_api_library · d67ac471
      Jihoon Kang authored
      java_api_library modules run validation to check the sanity of the API
      text files by default when generating the stubs from txt files. However,
      this leads to circular dependency issue when the validations are added
      to the full api surface stub java_api_library modules as droidstubs may
      set sdk_version property. Therefore, disable the validation for full api
      surface java_api_library (e.g. android_*_stubs_current) modules.
      
      Test: m nothing --build-from-text-stub
      Bug: 288624417
      Change-Id: Ib1b7b804736ef4e4cd2ea979aabea211af1927af
      d67ac471
  25. Oct 11, 2023
    • Jihoon Kang's avatar
      Add module lib and test union java_api_library module · 4683b14c
      Jihoon Kang authored
      Currently, hiddenapi_modular defines test api surface as a subset of
      module lib api surface, causing hiddenapi check failure in from-text
      stub build. In order to mitigate this and enable the hiddenapi check in
      from-text stub build, this change introduces a java_api_library module
      that generates the stub jar that contains both test and module lib
      api contributions. The module will not be available for consumption, but
      will only be used in hiddenapi check.
      
      Test: m android_test_module_lib_stubs_current.from-text --build-from-text-stub
      Bug: 191644675
      Change-Id: I2b6c9f75d9ebcfd75fa5b509dbef14aa0f88ac97
      4683b14c
    • Anton Hansson's avatar
      Cleanup obsolete doc build targets · 2e6a904a
      Anton Hansson authored
      - the *-check-docs target doesn't do anything the other targets don't
      - online-* are, I think, the old d.a.c targets but the ds-* targets are
        what's currently used
      - the hidden-* target isn't meaningfully different from others, either
      
      Test: presubmit
      Change-Id: Icab977d40917aa14c629629965c6126e20f4f3ee
      2e6a904a
    • Anton Hansson's avatar
      Remove framework-doc-only-libs · ba8f3c25
      Anton Hansson authored
      They don't seem to do anything. All the docs compile without them
      and I don't see any additional warnings/errors being printed.
      
      If they actually do something, the list is almost certainly incomplete
      anyway.
      
      Test: m docs
      Change-Id: I1bda7c4cc1d882d80cfe38ee734643c9eed030dc
      ba8f3c25
    • Anton Hansson's avatar
      Don't link the framework impl in docs build · 65370ed5
      Anton Hansson authored
      This gives the docs build access to hidden symbols, which hides issues
      in the documentation.
      
      Baseline the newly discovered issues.
      
      Bug: 217734059
      Test: m docs
      Merged-In: I357f5a341a170a37152d836861a330039a83886c
      Change-Id: I357f5a341a170a37152d836861a330039a83886c
      65370ed5
  26. Oct 05, 2023
  27. Oct 04, 2023
    • Anton Hansson's avatar
      Specify lint-baseline for docs builds · 0a71550e
      Anton Hansson authored
      This file is passed to doclava to baselining existing errors in the
      documentation. The contents of this baseline will be added in follow up
      changes (and will be different in AOSP and internal).
      
      Bug: 217734059
      Test: m docs
      Change-Id: Ibb5571fd9e55fb4f04e79e015462812e01d1ca80
      0a71550e
  28. Oct 03, 2023
    • Chris Parsons's avatar
      assign labels to merged_txt modules with defs · 3b7e34ba
      Chris Parsons authored
      This is groundwork for allowlist v2, and ensures that rdeps of
      merged_txt targets appropriately reflect that these targets exist.
      
      Fixes: 302061007
      Test: Unit test update
      Change-Id: I1d64635bb3db50ee525f1a557fd4b73d50dba879
      3b7e34ba
Loading