| Commit message (Collapse) | Author | Age |
|
|
|
| |
PiperOrigin-RevId: 195100125
|
|
|
|
|
|
|
|
|
|
|
|
| |
This action is a trimmed-down version of the resource merging action (no
resources or manifests).
Also, create a base class to collect boilerplate action code, and a new
Exception to indicate that we should exit an action immediately (rather than
throw and print the stack trace).
RELNOTES: none
PiperOrigin-RevId: 193054422
|
|
|
|
|
|
|
|
| |
Until we properly support checking the contents of these files, don't try to do
so.
RELNOTES: none
PiperOrigin-RevId: 188192286
|
|
|
|
|
| |
RELNOTES:None
PiperOrigin-RevId: 185553306
|
|
|
|
|
| |
RELNOTES: None.
PiperOrigin-RevId: 179425421
|
|
|
|
|
| |
RELNOTES: None
PiperOrigin-RevId: 175858467
|
|
|
|
|
| |
RELNOTES: None
PiperOrigin-RevId: 174502289
|
|
|
|
|
| |
RELNOTES: None
PiperOrigin-RevId: 174485947
|
|
|
|
|
| |
RELNOTES: None
PiperOrigin-RevId: 172754760
|
|
|
|
|
| |
RELNOTES: none
PiperOrigin-RevId: 161831232
|
|
|
|
|
|
|
|
|
| |
This includes some refactoring:
* Move the symbol deserialization our of the merger and into the ParsedAndroidData (probably move again.)
* Change the FailedFutureAggregator generics to work more callables
RELNOTES: None
PiperOrigin-RevId: 156863698
|
|
|
|
|
|
|
| |
Fixes https://github.com/bazelbuild/bazel/issues/2709
RELNOTES: None.
PiperOrigin-RevId: 155097576
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
| |
do different (if similar) things and had no common code whatsoever.
--
PiperOrigin-RevId: 149942714
MOS_MIGRATED_REVID=149942714
|
|
|
|
|
|
|
|
|
| |
overwrites.
Record the sources are overwritten during merging.
--
MOS_MIGRATED_REVID=140654137
|
|
|
|
|
|
|
|
| |
The DataSource object will then be used to track which values have been
overwritten and avoid incorrect merge warnings.
--
MOS_MIGRATED_REVID=137159260
|
|
|
|
|
|
|
|
|
|
|
| |
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 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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Avoid writing the non-values IdXmlResourceValues
to the merged values.xml file. It's redundant
since the merged resources will include the src
layout / menu, etc. file. E.g., adds 25KB out
of 250KB to some merged values.xml.
It can also change the way R.fields are initialized
(ids from values.xml are numbered before other
sources), that would have changed the numbering in
AndroidIntegratinoTest#testAndroidBinaryResourceShrinking
and in AndroidResourceClassWriterAaptTest.
--
MOS_MIGRATED_REVID=130789333
|
|
|
|
|
| |
--
MOS_MIGRATED_REVID=128202272
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
To be used by a later CL where we use this more
complete picture of all the resource items to
generate our own R.java/class without invoking
AAPT (and split out AAPT to a separate action
that is off the java builder critical path).
Technically aapt creates R.id.foo for attr
<enum name="foo" ... /> and flag as well, but
I haven't seen code that actually relies on that.
Currently off-by-default (only exercised by tests).
--
MOS_MIGRATED_REVID=126407838
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
resources are combined for the primary writing.
Example:
transitive resource: styleable/RubADubDub has an attr of butcher
direct resource: styleable/RubADubDub has an attr of baker
primary resource: styleable/RubADubDub has an attr of candlestickmaker
The merged resources should have:
transitive resource: <no matching key>
primary resource: styleable/RubADubDub has attrs of butcher, baker, candlestickmaker
--
MOS_MIGRATED_REVID=122453026
|
|
|
|
|
|
|
|
|
| |
* Adds threading to the AndroidDataWriter and AndroidDataSerializer.
* Changes to a BufferedWriter for the Writer (turns out it's faster for string writing.)
* Added buffers to the serializer reading.
--
MOS_MIGRATED_REVID=122280993
|
|
|
|
|
| |
--
MOS_MIGRATED_REVID=121863653
|
|
|
|
|
|
|
|
|
| |
* Merge conflicts are now bright red warnings, as the previous merger was simultaneously stricter and looser than expected.
* Legacy resource rules are now detected and cause bright red warnings.
* Merge conflicts will test for equality either of file contents or parsed xml
--
MOS_MIGRATED_REVID=121510152
|
|
|
|
|
|
|
|
|
|
|
|
| |
AndroidDataSet becomes ParsedAndroidData, reflecting the placement in the current AndroidData lifecycle:
UnvalidatedAndroidData -> ParsedAndroidData -> UnwrittenMergedAndroidData -> MergeAndroidData -> DensityFilteredAndroidData -> DependencyAndroidData
DataResourceFile becomes DataValueFile reflecting it's dual roles of DataAsset and DataResource.
XmlDataResource becomes DataResourceXml for consistancy.
--
MOS_MIGRATED_REVID=118689441
|
|
|
|
|
|
|
|
|
| |
Introduces two new interfaces:
DataValue, which compliments DataKey and allows a cleaner interface MergeConflict
AndroidDataSet.KeyValueConsumer, abstraction that allows a common interface for consuming parsed resources, which is a lot cleanr for DataValue as well.
--
MOS_MIGRATED_REVID=118466739
|
|
|
|
|
|
|
|
|
|
| |
Removes ResourceMap from AndroidDataSet, now the merge operates directly on the AndroidDataSet instances.
Change tests to use Map<DataKey, Data?> instead of List<Data?>.
Add tests for finding conflicts during AndroidDataSet creation.
Make MergeConflict more test friendly by sorting Paths on creation.
--
MOS_MIGRATED_REVID=118240635
|
|
|
|
|
|
|
|
|
| |
The end goal is to remove ResourceMap and separate the DataKey from the DataResource and DataAsset.
This moves the resource map to AndroidDataSet and switches the generation to the Resource and Asset visitors. Which is nice, because it removes a traversal of the overwritable resources and assets.
--
MOS_MIGRATED_REVID=118071238
|
|
|
|
|
|
|
| |
Adds support for parsing and merging assets. This introduces the DataKey and DataAsset interfaces which allow reuse of the FileDataResource for assets, the RelativeAssetPath which acts as a DataKey for assets (the relative asset path is the path that the asset will reside inside the final apk.) It also extends the AndroidDataSetBuilder to handle the creation of assets, and cleans up the interface a little.
--
MOS_MIGRATED_REVID=118060379
|
|
Introduces the AndroidDataMerger, MergeConflict, and UnwrittenMergedAndroidData which is the entry point in the AndroidResourceProcessing *AndroidData lifecycle.
Also, refactors the AndroidDataSet parsing of resources, making it functionally immutable.
--
MOS_MIGRATED_REVID=117492690
|