aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/tools/android/java/com/google/devtools/build/android/BUILD
Commit message (Collapse)AuthorAge
* Enable proguarded Android builds with --experimental_desugar_java8_libs in BazelGravatar kmb2018-05-16
| | | | | | RELNOTES: Bazel supports including select Java 8 APIs into Android apps targeting pre-Nougat Android devices with --experimental_desugar_java8_libs PiperOrigin-RevId: 196833987
* Filter out non-.flat files while linking.Gravatar corysmith2018-03-06
| | | | | RELNOTES: None PiperOrigin-RevId: 188121571
* Update aapt2 to recent version from git_pi-release.Gravatar Googler2017-12-13
| | | | | | | | Changes: - Package names must contain at least one dot. - XML files under res/values/ must have the extension ".xml". - ARSC format updated. PiperOrigin-RevId: 178952283
* Create merge action and data deserializer for aapt2 compiled resources.Gravatar Googler2017-11-15
| | | | | RELNOTES: None PiperOrigin-RevId: 175858467
* Open source ZipFilterBuilder for android_instrumentation_testGravatar jingwen2017-11-13
| | | | | | | GITHUB: #903 RELNOTES: None. PiperOrigin-RevId: 175600267
* Open source ZipFilterAction for use in Android testing.Gravatar ajmichael2017-11-01
| | | | | | | https://github.com/bazelbuild/bazel/issues/903 RELNOTES: None PiperOrigin-RevId: 174079202
* Busybox all the Bazel Android tools.Gravatar ajmichael2017-08-25
| | | | | | | | | This change reduces the size taken up in the bazel binary by Android tools deploy jars from 38.2 mb to 9.8 mb, which is 15% of the bazel binary size. Also, some minor cleanups of our BUILD files. https://github.com/bazelbuild/bazel/issues/2385 RELNOTES: None PiperOrigin-RevId: 166373241
* Adds aapt2.ResourceCompiler and CompileLibraryResourcesAction.Gravatar corysmith2017-08-11
| | | | | | | | | | Refactorings: * Change data binding to have configurable archive generation * Extract a ZipBuilder class from the ZipBuilderVisitor to provide a general purpose archiving class. * Small changes to visibility AaptCommandLineBuilder for reuse in the aapt2 code. RELNOTES: None PiperOrigin-RevId: 164880571
* Remove old intellij aspect code bundled with BazelGravatar Googler2017-07-31
| | | | PiperOrigin-RevId: 163538636
* Make the @Option annotation depend on the java version of the tagging enums.Gravatar ccalvarin2017-07-18
| | | | | | | 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
* Windows, Android BusyBox: create JunctionCreatorGravatar Laszlo Csomor2017-07-10
| | | | | | | | | | | Introduce the JunctionCreator classes that the Android BusyBox can use to work around path length limitations on Windows. See https://github.com/bazelbuild/bazel/issues/3264 Change-Id: Ia5ee39f0635dcc2690ffb1755dc56d21e7bc7536 PiperOrigin-RevId: 161378422
* Add the default category and tag to all options.Gravatar ccalvarin2017-06-28
| | | | | | | | Move the default from the annotation to every mention. This makes the incompleteness explicit. Will add the defaults to test targets in a separate change. Once all dependencies are cleaned up, the Option annotation will no longer allow options without the documentationCategory or effectTag, to prevent new options being added without categories while we migrate to the new option categorization. PiperOrigin-RevId: 160281252
* Remove mobile-install stub app targets from BUILD files.Gravatar Adam Michael2017-02-23
| | | | | | | | | | | These targets are unneeded and do not build without an android_sdk_repository set up. This issue was identified in https://github.com/bazelbuild/bazel/issues/2559. -- PiperOrigin-RevId: 148251416 MOS_MIGRATED_REVID=148251416
* Open source java 8 desugarer.Gravatar Adam Michael2017-02-10
| | | | | | | | | | Fixes https://github.com/bazelbuild/bazel/issues/2222. RELNOTES: Support for Java 8 lambdas, method references, type annotations and repeated annotations in Android builds with --experimental_desugar_for_android. -- PiperOrigin-RevId: 147109786 MOS_MIGRATED_REVID=147109786
* Use //third_party/protobuf:protobuf_java instead of ↵Gravatar Carmi Grushko2017-02-09
| | | | | | | | | | | | //third_party/protobuf:protobuf to refer to the Java proto runtime. (second attempt) This is the name in the upstream protobuf repo. -- PiperOrigin-RevId: 147057949 MOS_MIGRATED_REVID=147057949
* Rollback of commit 602a98cbebeff2ba1c2d8605a9552b2c8f5622ae.Gravatar Googler2017-02-09
| | | | | | | | | | | | | | | | *** Reason for rollback *** Rolling forward with fixes for the incremental tool. *** Original change description *** Automated [] rollback of commit d11d510c571b10787856395709f9ad945ca70bb2. *** Reason for rollback *** -- PiperOrigin-RevId: 146940409 MOS_MIGRATED_REVID=146940409
* Rollback of commit d11d510c571b10787856395709f9ad945ca70bb2.Gravatar Alex Humesky2017-02-08
| | | | | | | | *** Reason for rollback *** -- PiperOrigin-RevId: 146820790 MOS_MIGRATED_REVID=146820790
* Move all the resource processing tools into a "busybox".Gravatar Googler2017-02-08
| | | | | | | | | This makes the code simpler as well as reducing the number of targets to build. It also makes testing and profiling different action strategies vastly easier. -- PiperOrigin-RevId: 146812659 MOS_MIGRATED_REVID=146812659
* Create LibraryRClassGeneratorAction for generating R classes outside of theGravatar Googler2017-01-17
| | | | | | | | AndroidResourceMergingAction. -- PiperOrigin-RevId: 144726723 MOS_MIGRATED_REVID=144726723
* Switch Bazel to use ResourceUsageAnalyzer.java instead of ResourceShrinker.java.Gravatar Andrew Pellegrini2016-12-19
| | | | | | -- PiperOrigin-RevId: 142484589 MOS_MIGRATED_REVID=142484589
* Rollback of commit 27cd7f6bb4a02f56f9ad73e57e71e69a1c00d5ea.Gravatar Adam Michael2016-12-15
| | | | | | | | | | | | *** Reason for rollback *** Rolling forward, intentionally breaking loading phase (and therefore `bazel fetch`) for android_binary in Bazel if no android_sdk_repository is set up. Will not submit until Tensorflow's use case is cleaned up in https://github.com/tensorflow/tensorflow/pull/6225. -- PiperOrigin-RevId: 142068703 MOS_MIGRATED_REVID=142068703
* Update android_ide_common to 25.0.0 and clean up FolderConfigsGravatar Googler2016-10-07
| | | | | | | | | | | 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
* Rollback of commit af8ebca2b88a0ee1129b72b4ce825f6489c31e67.Gravatar Damien Martin-Guillerez2016-10-05
| | | | | | | | | | | | | | | | | | | | *** Reason for rollback *** Break `bazel fetch ...` Discovered by bisecting `bazel fetch tensorflow/...`, see attached bug for more information Fixes https://github.com/bazelbuild/bazel/issues/1880 *** Original change description *** Open source dex merging tools for incremental dexing. Tested with bazel build --incremental_dexing_binary_types=monodex,multidex_unsharded,multidex_sharded -- //examples/android/java/bazel:hello_world -- MOS_MIGRATED_REVID=135220785
* Open source dex merging tools for incremental dexing.Gravatar Adam Michael2016-09-30
| | | | | | | | Tested with bazel build --incremental_dexing_binary_types=monodex,multidex_unsharded,multidex_sharded -- //examples/android/java/bazel:hello_world -- MOS_MIGRATED_REVID=134690103
* Add a resource validator action for android_libraryGravatar Googler2016-08-30
| | | | | | | | | | | | | | | | | | 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
* Add a lightweight resource merge action.Gravatar Googler2016-08-30
| | | | | | | | | | | | | | | | | | | | | | | | | | 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
* Adds data binding support to the Android resource processor.Gravatar Greg Estren2016-08-23
| | | | | | | | | | | | | | | | 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
* Use the native java_proto_library instead of the macro defined in genproto.bzl.Gravatar Carmi Grushko2016-08-02
| | | | | -- MOS_MIGRATED_REVID=128992760
* Add a resource parsing action.Gravatar Googler2016-07-28
| | | | | | | | | | | | | | | | | | | | | | Part of 3 proposed new actions: - parsing action - merging action - validating action Dependencies (directData and transitiveData) expect the symbol files. If the merge action produces the symbol files, then each merge action depends on each other. Instead, produce it in an action with just source resources as prereqs to allow more parallelism. Technically, we don't need a manifest as part of the parameters. I debated about whether to introduce a basic version of UnvalidatedAndroidData or not. -- MOS_MIGRATED_REVID=128599714
* Remove a few unused methods from {Dep,Unvalidated}AndroidDataGravatar Googler2016-07-26
| | | | | | | | | | | The new merger doesn't use addToResourceSet(), modify(), etc. Also, since modify() is unused, remove the DirectoryModifier objects and reduce BUILD deps. -- MOS_MIGRATED_REVID=128387448
* Rollback of commit 80d1e16b7ae1d04fa2fa4c561588fe9fdbaefc41.Gravatar Carmi Grushko2016-07-14
| | | | | | | | | | | | | *** Reason for rollback *** Breaks Bazel's CI because the current release (0.3.0) is used to query some targets, which doesn't have java_proto_library yet. *** Original change description *** Use the native java_proto_library instead of the macro defined in genproto.bzl. -- MOS_MIGRATED_REVID=127431334
* Use the native java_proto_library instead of the macro defined in genproto.bzl.Gravatar Carmi Grushko2016-07-14
| | | | | -- MOS_MIGRATED_REVID=127324151
* More pieces of RClassGeneratorActionGravatar Googler2016-07-08
| | | | | | | | | | | | Add the rclass_generator.sh, and fill in the boiler-plate for mock tools, etc. Mostly cargo- culting references to resources_processor.sh. Rename earlier pieces to use RClassGenerator prefix instead of AndroidResourceCompilation. -- MOS_MIGRATED_REVID=126831848
* Roll forward of commit 1f1f207573c7b9c3e2d3ca1ffb0780a8fd592214: action to ↵Gravatar Googler2016-06-23
| | | | | | | | | | | | | | | | | | | | | | | | 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
* Rollback of commit 1f1f207573c7b9c3e2d3ca1ffb0780a8fd592214.Gravatar Googler2016-06-21
| | | | | | | | | *** Reason for rollback *** Doesn't handle aapt that doesn't generate R.txt properly. -- MOS_MIGRATED_REVID=125405481
* Add action to write android_binary and lib R.classes directlyGravatar Googler2016-06-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* Fix the srcs filegroup in BazelGravatar Damien Martin-Guillerez2016-04-22
| | | | | | | | | This broke tools/cpp/test/... due to missing files. Unfortunately those tests uses docker and until we can run docker in userland, we cannot run those on Jenkins. -- MOS_MIGRATED_REVID=120445118
* Adds new ManifestMergerAction to replace existing python merger script. ↵Gravatar Andrew Pellegrini2016-04-21
| | | | | | | Replacement will occur in a followup cl. New action uses the Gradle manifest merger through AndroidResourceProcessor. -- MOS_MIGRATED_REVID=120359118
* Fix incorrect package path.Gravatar Alex Humesky2016-04-20
| | | | | -- MOS_MIGRATED_REVID=120282869
* 4 of 5: Serialization of UnwrittenMergedAndroidData.Gravatar Googler2016-04-20
| | | | | | | | | | | Adding AndroidDataSerializer, the serialize_format proto, and KeyValueConsumers (utility class for keeping consumers straight). The serializtion is a bit more manual as previous experience has proven to me that simply writing all the resources into a proto map and pulling them out is not performant in the least. So, the serializer stores each message independent, the keys and then the values allowing for potential lazy loading and other optimizations in the future. Also adds tests for parsing and writing style resources. -- MOS_MIGRATED_REVID=120274904
* Add Python protobuf to Bazel third_party and move all protobuf targets intoGravatar David Chen2016-03-17
| | | | | | | //third_party/protobuf. -- MOS_MIGRATED_REVID=117336377
* Add xml subpackage to the BUILD file.Gravatar Googler2016-03-08
| | | | | -- MOS_MIGRATED_REVID=116653232
* Add a bazel-srcs target to the top-level package containing all Bazel sourcesGravatar Damien Martin-Guillerez2016-02-29
| | | | | | | | This target include all non tests targets of Bazel to do integration tests of bootstrapping. -- MOS_MIGRATED_REVID=115830741
* Rename proto dependencies to include a _java component in them.Gravatar Julio Merino2016-02-23
| | | | | | | | While doing this, homogenize the two dependencies on build.proto (via build_proto and build_proto_v2) into a single build_java_proto. -- MOS_MIGRATED_REVID=115328219
* Adds the ResourceShrinkerAction. Uses the results of resource processing and ↵Gravatar Andrew Pellegrini2016-02-23
| | | | | | | 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
* ASwB aspect: parse java packages during executionGravatar Googler2015-12-03
| | | | | -- MOS_MIGRATED_REVID=109305952
* Added ResourceShrinker - strips unused resources from final APK.Gravatar Googler2015-11-18
| | | | | -- MOS_MIGRATED_REVID=108039800
* Pre-compile Android tools that are embedded in the Bazel binary.Gravatar Lukacs Berki2015-10-27
| | | | | | | | | This makes Android builds slightly faster and avoids the "Modification date is in the future" warnings by javac and removes the sources of devtools/common/options from the binary. incrementaldeployment is not pre-compiled yet. -- MOS_MIGRATED_REVID=106391321
* Separate BUILD file for options and docgen.Gravatar Han-Wen Nienhuys2015-10-16
| | | | | -- MOS_MIGRATED_REVID=105511114
* Open source AarGeneratorAction and AndroidResourceProcessingAction.Gravatar Andrew Pellegrini2015-06-26
-- MOS_MIGRATED_REVID=96883818