| Commit message (Collapse) | Author | Age |
|
|
|
| |
PiperOrigin-RevId: 194512971
|
|
|
|
|
|
|
|
|
| |
- New flags to pass in asset deps
- Pass assets into merging in the monolithic action
- Field for asset deps in asset builder action
RELNOTES: none
PiperOrigin-RevId: 193211038
|
|
|
|
|
|
|
| |
Bazel stopped passing it in https://github.com/bazelbuild/bazel/commit/1a6ca6f47aef36d56b5cb2f9da114af75dde583d.
RELNOTES: None
PiperOrigin-RevId: 190064697
|
|
|
|
|
| |
RELNOTES: None
PiperOrigin-RevId: 187185374
|
|
|
|
|
|
|
| |
This zip is the input to the resource shrinker, which currently sometimes chokes on databinding expressions. This should fix that.
RELNOTES: None
PiperOrigin-RevId: 187049578
|
|
|
|
|
|
|
|
|
| |
Because of limitations in Bazel (primarily, Filesets), we always need to filter
on density in execution. As such, remove the deprecated flag that was used to
specify densities that were stamped but not filtered.
RELNOTES: none
PiperOrigin-RevId: 186634496
|
|
|
|
|
|
|
|
|
|
|
|
| |
Filtering only in analysis was neglecting the possibility of resources being in
filesets, the contents of which are not available in analysis. As such, we must
*always* filter in execution, even though it's usually just going to be a
no-op.
Also, add some documentation of same.
RELNOTES: none
PiperOrigin-RevId: 184722564
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Newly discovered bugs indicate that density filtering in analysis does not
cover all cases. Filter in execution as a workaround for these cases. This will
let us turn resource filtering in analysis on and avoid these bugs. (I will
work on actually fixing these bugs in parallel.)
Non-density filtering already runs in execution, even when already filtering in
analysis, due to known limitations of filtering in analysis. (Specifically,
aapt filters more strictly than android_ide_common, and also needs the resource
filters passed anyway to generate pseudolocalized resources.)
RELNOTES: none
PiperOrigin-RevId: 180806206
|
|
|
|
|
| |
RELNOTES: None.
PiperOrigin-RevId: 179425421
|
|
|
|
|
| |
RELNOTES: none
PiperOrigin-RevId: 178369060
|
|
|
|
|
| |
RELNOTES: None
PiperOrigin-RevId: 177048616
|
|
|
|
|
|
|
| |
ShellQuotedParamsFilePreProcessor. This covers all of the tools packaged in the ResourceProcessorBusyBox.
RELNOTES: None.
PiperOrigin-RevId: 172485486
|
|
|
|
|
|
|
| |
Introduces the ResourcesZip class to more easily handle processing merged resources.
RELNOTES: None
PiperOrigin-RevId: 169622715
|
|
|
|
|
| |
RELNOTES: none
PiperOrigin-RevId: 168444499
|
|
|
|
|
|
|
|
|
|
|
| |
Previously, when filtering in analysis, density information was not passed to
execution to avoid wasting time on re-filtering. However, that density
information was also used to add information to the manifest. Add an additional
flag to save density information to the manifest without triggering resource
filtering in execution, and use it when filtering in analysis.
RELNOTES: None
PiperOrigin-RevId: 166891827
|
|
|
|
|
|
|
|
| |
Adds a ManifestContainer interface to centralize the types that provide manifests.
Adds PackagedResources to represent a linked dexless resource apk
RELNOTES: None
PiperOrigin-RevId: 166193049
|
|
|
|
|
|
|
| |
as printing the merge error report. The stack traces duplicated the error report and gave the impression that the error may be an internal error instead of a build error.
RELNOTES: None.
PiperOrigin-RevId: 162755827
|
|
|
|
|
|
|
| |
The option filters proto dependency can be removed from the OptionsParser. This is in response to option parser users that want to avoid the bazel-internal proto file in their dependencies.
RELNOTES: None.
PiperOrigin-RevId: 162249778
|
|
|
|
|
| |
RELNOTES: none
PiperOrigin-RevId: 161831232
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Use the recently added JunctionCreator class in
the Android BusyBox.
Query the current OS's name, where the BusyBox
process runs (using System.getProperty("os.name"))
and instantiate the corresponding JunctionCreator
implementation.
This allows the BusyBox to work around path length
limitations on Windows; see
WindowsJunctionCreator.
See https://github.com/bazelbuild/bazel/issues/3264
Change-Id: Ifc1a3c86971e64c2f42bcec2988b7e9239a1d29a
PiperOrigin-RevId: 161494557
|
|
|
|
|
|
| |
Automated formatting fixes standardize the @Option annotation.
PiperOrigin-RevId: 160567787
|
|
|
|
|
|
|
| |
Since https://github.com/bazelbuild/bazel/issues/2709 was fixed, this CL also enables ParsedAndroidDataTest.
RELNOTES: None
PiperOrigin-RevId: 155155095
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Filtering resources in analysis allows Bazel to save time by not copying
unwanted resources to the execution phase and by having less resource for
execution to process.
However, analysis-phase resource filtering currently happens only for
android_binary targets. android_library dependencies will contain references to
all of their resources in their R and symbol files, even if those resources are
filtered out and not made available to execution.
Eventually, we want to use dynamic configuration to propogate the filters being
used on android_binary targets to android_library dependencies as well, and
filter those in analysis also. Until then, however, we need a way of ignoring
unwanted resources if they don't exist.
This change adds a flag to the AndroidResourceProcessingAction to indicate that
resources were filtered in analysis. If the flag is passed, if a resource
referred to in a parsed symbols file is not actually visible, it will be
ignored (otherwise, the action would go on to merging and eventually crash when
it tried to use the missing resource).
If the flag is passed, execution-time resource filtering by density will also
be skipped (execution-time filtering by other resource qualifiers happens in
aapt, but is a much simpler process).
--
PiperOrigin-RevId: 150752270
MOS_MIGRATED_REVID=150752270
|
|
|
|
|
|
|
|
|
|
|
| |
* Extract merging methods to a static class
* Extract output methods to a static class
* Extract manifest processing methods to a class
* Move ExecutorCloserService to the top level
--
PiperOrigin-RevId: 150219121
MOS_MIGRATED_REVID=150219121
|
|
|
|
|
|
| |
--
PiperOrigin-RevId: 145686107
MOS_MIGRATED_REVID=145686107
|
|
|
|
|
|
| |
--
PiperOrigin-RevId: 144741831
MOS_MIGRATED_REVID=144741831
|
|
|
|
|
|
|
|
|
|
|
| |
Older android_ide_common does not handle BCP 47,
so we update the code to handle that and remove
most of the workarounds. This also pulls in a
fix for 3-letter locales, unblocks resource
shrinking whitelisting, etc.
--
MOS_MIGRATED_REVID=135396457
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Part 3 of the 3 new proposed android_library res
processing actions. Pulls a zip file from the
merging action, unpacks it, and then validates
the results with aapt. Get an R.txt and srcjar
w/ javadocs from aapt. In order to the get the
R.txt, I think you need to ask for the R.java
sources anyway.
Split the processResources() into a runAapt()
function that can be reused.
Hookup in bazel coming separately.
--
MOS_MIGRATED_REVID=131618410
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Part 2 of the 3 new proposed android_library res
processing actions. The primary and deps are all
assumed to be parsed+summarized in a protobuf.
Represent that with a new class (similar to
DependencyAndroidData but w/out R.txt).
Avoid having "manifest" artifacts as deps input,
and instead use "label", since that is only used
in a warning. DepAD still uses the manifest for
#asSymbolFileProvider, so we keep it there.
Move loading the primary out of the merge function
so that we can share the merge function with this
style of primary data, and the existing style of
of primary data (UnvalidatedAndroidData).
This produces an R class.jar and a zip file to
pass along to a future validation action. Images
are stubbed out since they are irrelevant to the
validation action.
--
MOS_MIGRATED_REVID=131604421
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is invoked via the new --dataBindingInfoOut flag.
If specified and the rule has resources, data binding declarations
in layout .xmls are stripped and fed into an aggregated .zip file
under that name. The original (stripped) .xml is then fed into
aapt for normal processing.
If specified and the rule has no resources, an empty file is created.
If not specified, everything works as before.
--
MOS_MIGRATED_REVID=130973265
|
|
|
|
|
| |
--
MOS_MIGRATED_REVID=128074515
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The --splits flag is now --split, since I remembered about how allowMultiple exists.
More importantly, split APKs are now correctly moved to filenames which are fairly
trivially constructed from the input split flags, allowing Bazel to just do a simple
one-character replace on the split flags and know what files the resource processing
action is going to output.
One more step in the quest for world domination, or rather, split APKs for resources.
Next: Actually supporting this in android_binary.
--
MOS_MIGRATED_REVID=126838431
|
|
|
|
|
|
|
|
|
| |
merger that is used (legacy or android) is controlled by the manifest_merger attribute on android_binary and the default is controlled by the --android_manifest_merger flag.
RELNOTES: The Android manifest merger is now available as an option for android_binary rules. The merger will honor tools annotations in AndroidManifest.xml and will perform placeholder substitutions using the values specified in android_binary.manifest_values. The merger may be selected by setting the manifest_merger attribute on android_binary.
--
MOS_MIGRATED_REVID=125603954
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
write R classes directly
NEW: add check that primary R.txt exists before
trying to load its symbols.
Rollback of commit 32c6c15c8b9bc4e203529f60bedbc5cd8a496a36.
*** Reason for rollback ***
Rollforward with check that primary R.txt exists
*** Original change description ***
Automated [] rollback of commit 1f1f207573c7b9c3e2d3ca1ffb0780a8fd592214.
*** Reason for rollback ***
Doesn't handle aapt that doesn't generate R.txt properly.
--
MOS_MIGRATED_REVID=125559472
|
|
|
|
|
|
|
|
|
| |
*** Reason for rollback ***
Doesn't handle aapt that doesn't generate R.txt properly.
--
MOS_MIGRATED_REVID=125405481
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For android_binary rules, we regenerate all of
the R.java of the libraries to get the final
resource IDs. Compiling all of them together can
be slow with the normal JavaBuilder, so add a
specialized class writer.
Example build with many R.java classes:
- R.java -> R.class via JavaBuilder: over 80s
- ErrorProne takes about 40% of that. So turning off
ErrorProne would be projected to be 48s.
Some of ErrorProne slowness is from static field
checks (e.g., on Flag classes), which may look
up the same Type over and over.
In comparison, if we write our own bytecode with ASM:
- ~16s total
- 4.7s to parse R.txt
- 4.8s to write class files
- 5.8s to copy and compress .jar
TODO: clean up SymbolLoader patching (upstream)
This only creates the action. We will need to
separately wire this up in blaze.
NOTE: This also makes the exising R.txt loading
used by live code multi-threaded, since that is
partly I/O-bound. Something to watch out for
(for flakiness, etc.) once this is submitted.
--
MOS_MIGRATED_REVID=125384467
|
|
|
|
|
|
|
|
|
| |
These splits will be passed through to aapt, which will create
additional resource packages (and reduce the set found in the base
ap_) as a result.
--
MOS_MIGRATED_REVID=123995947
|
|
|
|
|
|
|
|
| |
Add bazel support for using the "aapt -D" command to generate a proguard
specification for components which need to be in the main dex.
--
MOS_MIGRATED_REVID=121531584
|
|
|
|
|
|
|
|
|
|
|
| |
This allows a user to turn off png crunching during
the final merge (with crunch_png = 0), but it does
not skip nine-patch processing.
RELNOTES: adds crunch_png attribute to android_binary
--
MOS_MIGRATED_REVID=119986498
|
|
|
|
|
|
|
|
|
| |
and specify --experimental_android_resource_shrinking on the command line.
RELNOTES: Specifying --experimental_android_resource_shrinking on the command line will enable a resource shrinking pass on android_binary targets that already use Proguard.
--
MOS_MIGRATED_REVID=116572863
|
|
|
|
|
|
|
| |
a dead code removal Proguard pass to create an ap_ without unused resources to be used when building android_binary targets.
--
MOS_MIGRATED_REVID=115227385
|
|
|
|
|
|
|
| |
preparation for the ResourceShrinkerAction and move common option flags to AndroidResourceProcessor to prevent duplication in ResourceShrinkerAction.
--
MOS_MIGRATED_REVID=114883341
|
|
|
|
|
|
|
| |
as preparation for the ResourceShrinkerAction which does not require it as part of its aapt invocation.
--
MOS_MIGRATED_REVID=114755551
|
|
|
|
|
|
|
| |
- Changed AndroidResourceProcessingAction to call shutdown() on the thread pool used by AOSP code instead of System.exit() to allow calling the action's main() from inside a test, while maintaining the dangling thread cleanup.
--
MOS_MIGRATED_REVID=114459473
|
|
|
|
|
|
|
| |
Part of this change makes the --no-version-vectors only be propagated if the sdk tools are >= 23.
--
MOS_MIGRATED_REVID=114351246
|
|
|
|
|
|
|
| |
build tools version can be used to determine which features to use.
--
MOS_MIGRATED_REVID=114225514
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
*** Reason for rollback ***
Collect all the temporary directories into one tree that will delete on exit.
*** Original change description ***
Automated [] rollback of commit 30469a9939c14f8d0d2708bd0a91525a2e161cc4.
*** Reason for rollback ***
Breaks density filtering.
*** Original change description ***
Collect all the temporary directories into one tree that will delete on exit.
--
MOS_MIGRATED_REVID=114132492
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
*** Reason for rollback ***
Breaks density filtering.
*** Original change description ***
Collect all the temporary directories into one tree that will delete on exit.
--
MOS_MIGRATED_REVID=114122848
|
|
|
|
|
| |
--
MOS_MIGRATED_REVID=114115143
|
|
|
|
|
|
|
| |
freedom in generating the command line for aapt.
--
MOS_MIGRATED_REVID=113614675
|