Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create rule to generate the exportable api files when checkapi is dis…
…abled WITHOUT_CHECK_API environment variable enables the checkapi to be removed from the critical path. The variable is rarely used within AOSP, but the downstream vendors may depend on it, in order to improve the build performance given that the api signature file through metalava is a resource costly task. Currently, the exportable api files / removed api files are not generated when checkapi is disabled, but a module may depend on the exportable api files when a checkapi is disabled. In order to prevent the missing build rules error in this case, generate the rule to copy the checked in api file / removed api file to the exportable api file / removed api file to prevent build errors. This change also fixes the error message when the OutputFiles(string) api file is null, to correctly inform the user the error. Test: m BUILD_FROM_SOURCE_STUB=true WITHOUT_CHECK_API=true && inspect ninja path and verify that "non-updatable-exportable-current.txt" depends on the generated exportable api file. Bug: 329374072 (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:2d4074a022c0d836c712a6606b5c6e2cb376e07a) Merged-In: I24f88d450fb46b6ea9d5920d83617d8228edd34b Change-Id: I24f88d450fb46b6ea9d5920d83617d8228edd34b
- Loading branch information