aboutsummaryrefslogtreecommitdiffhomepage
Commit message (Collapse)AuthorAge
* Ability to stop using ResourceContainer in various actionsGravatar asteinb2018-04-18
| | | | | | | | | | | | | | | | | | | | | Now that we support decoupled asset and resource processing in the basic pipeline, we can also support it in these actions. ResourceShrinker actions, by design, does not use assets, so the change is trivial. For the AarGenerator, things get a bit more complex: - Simplify needlessly complex code around AAR generation - Move around special resource processing to generate AAR inputs in the case where there are no local resources to go next to normal resource processing - Also, clean up that code - ResourceApk wrapper class has some fields which are non-null even in the case where resources are inherited - Always pass assets and resources seperately to the AarGenerator action RELNOTES: none PiperOrigin-RevId: 193355790
* Fix anchors for docstring sectionGravatar brandjon2018-04-18
| | | | | RELNOTES: None PiperOrigin-RevId: 193354556
* Create pipeline for monolithic data processing with decoupled classesGravatar asteinb2018-04-18
| | | | | | | | | | | The AndroidResourceProcessingAction does all of asset parsing and merging and all of resource parsing, merging, and validation except for R class generation, all in one action. Add class to wrap the intermediate output of this action. It can trigger R class generation to create a full ValidatedAndroidResources object. RELNOTES: none PiperOrigin-RevId: 193350591
* Clean up R class generationGravatar asteinb2018-04-18
| | | | | | | | | | | Remove R class generation from AndroidCommon and instead invoke it just after resource processing. This is much more intuitive, behaves the same, and will make it easier to call into R class generation on the new pipeline. Also, clean up some dead code (including newly-dead code) from AndroidCommon. RELNOTES: none PiperOrigin-RevId: 193345190
* Automated rollback of commit 4465dae23de989f1452e93d0a88ac2a289103dd9.Gravatar buchgr2018-04-18
| | | | | | | | | | | | | | | | | | | | | *** Reason for rollback *** The no-cache tag is not respected (see b/77857812) and thus this breaks remote caching for all projects with symlink outputs. *** Original change description *** Only allow regular files and directories spawn outputs to be uploaded to a remote cache. The remote cache protocol only knows about regular files and directories. Currently, during action output upload, symlinks are resolved into regular files. This means cached "executions" of an action may have different output file types than the original execution, which can be a footgun. This CL bans symlinks from cachable spawn outputs and fixes http... *** PiperOrigin-RevId: 193338629
* windows: GetOutputRoot() returns GetHomeDir()Gravatar Laszlo Csomor2018-04-18
| | | | | | | | | | | | This is an immediate fix for a very nasty bug: https://github.com/bazelbuild/bazel/issues/5038 Change-Id: I5e4f9fa13e5ac785514bc0dc4ce6cba9a88f33bb Closes #5039. Change-Id: I5e4f9fa13e5ac785514bc0dc4ce6cba9a88f33bb PiperOrigin-RevId: 193315571
* Refactor SyntaxTests to not rely on actions/analysis packages arbitrarilyGravatar brandjon2018-04-17
| | | | | | | | | | | | | | | In the process, clean up SkylarkType-related tests. - Factor test of EvalUtils.getSkylarkType logic from SkylarkEvaluationTest and ValidationTest to EvalUtilsTest. - Move test of EvalUtils.getSkylarkType's behavior on lists to SkylarkListTest. - Move other SkylarkType tests from ValidationTest to new SkylarkTypeTest and split them up a little. - Throughout, don't use Bazel types like Artifact as test subjects. RELNOTES: None PiperOrigin-RevId: 193303463
* Automated rollback of commit 3643afad04be41caa4b247d327230e8a1e32bb6a.Gravatar carmi2018-04-17
| | | | | | | | | | | *** Reason for rollback *** Breaks //third_party/java_src/copybara/java/com/google/copybara/config:parser: [] *** Original change description *** PiperOrigin-RevId: 193292991
* PiperOrigin-RevId: 193274137Gravatar carmi2018-04-17
|
* Adds support to go compilation to respect the build_runfile_manifests flag.Gravatar shahan2018-04-17
| | | | PiperOrigin-RevId: 193270108
* Remove JavaSemantics#commonDependencyProcessingGravatar cushon2018-04-17
| | | | PiperOrigin-RevId: 193265266
* Relax the assertion in Desugar for checking the calls to $closeResource(...).Gravatar cnsun2018-04-17
| | | | | | | | It is possible that $closeResource(...) is not used as the calls to it might be eliminated by some optimization tools, such as Proguard. RELNOTES: n/a. PiperOrigin-RevId: 193262552
* Notify Skyframe listeners about additional node states: CHECK_DIRTY, ↵Gravatar felly2018-04-17
| | | | | | INIT_ENV, and COMMIT. PiperOrigin-RevId: 193261989
* 1. Avoid checking the primitive number types in annotations.Gravatar cnsun2018-04-17
| | | | | | | | 2. Remove incorrect assertion in AnnotationVisitor.visit(String, Object), and delegate the checking for arrays to visitArray(String). RELNOTES: n/a. PiperOrigin-RevId: 193256108
* Migrate configuration_field() to SkylarkCallable.Gravatar cparsons2018-04-17
| | | | | | | Previously this was a member of SkylarkAttr, which didn't make much sense, as the function was not under the attr namespace. This moves configuration_field to a new spot for global functions, "SkylarkBuildApiGlobals". RELNOTES: None. PiperOrigin-RevId: 193253435
* Migrate most of SkylarkRuleClassFunctions to use @SkylarkCallableGravatar cparsons2018-04-17
| | | | | | | The only things that remain are Provider subclasses, as they require special treatment. (Namely, they are referencable at the top level as a Provider and not a function.) RELNOTES: None. PiperOrigin-RevId: 193249523
* Add decoupled asset containers to ResourceApk wrapper objectGravatar asteinb2018-04-17
| | | | | | | | | | | The ResourceApk object contains all the processed Android data. When assets are decoupled, pass them in seperately. I'll replace ResourceContainer with the ValidatedAndroidData interface as part of the next review. RELNOTES: none PiperOrigin-RevId: 193223251
* Ability to pass decoupled assets into monolithic resource processing actionGravatar asteinb2018-04-17
| | | | | | | | | - 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
* Clarify 1st arg of load()Gravatar brandjon2018-04-17
| | | | | RELNOTES: None PiperOrigin-RevId: 193206695
* A slight refactoring of RunCommand.Gravatar lberki2018-04-17
| | | | | RELNOTES: None. PiperOrigin-RevId: 193203414
* Make attempting to change --config in invocation policy an error.Gravatar ccalvarin2018-04-17
| | | | | | | It will not work as expected, since config is already expanded by this point in options processing. RELNOTES: None. PiperOrigin-RevId: 193196664
* Push using ruleContext.getFeatures() outside of creating FeatureConfigurationGravatar hlopko2018-04-17
| | | | | | | | The goal is to enable creation of feature configuration without the rule context. This will enable us to have cleaner API for this in Skylark. RELNOTES: None PiperOrigin-RevId: 193195986
* Pass --coverage to all compile and link stepsGravatar Ulf Adams2018-04-17
| | | | | | | | | | | | | | I get failing tests without this flag in coverage mode. Workaround is to pass --linkopt=-fprofile-arcs in Bazel. Here are the steps that work at this time (with this change): bazel coverage --strategy=TestRunner=standalone //my/funky:test genhtml -o report-output-directory/ path/to/coverage.dat Some progress on #1118. PiperOrigin-RevId: 193193164
* Move test_timeout to BuildConfiguration and TargetCompleteEvent.Gravatar Googler2018-04-17
| | | | | | | | - Move test_timeout to BuildConfiguration. - Add test_timeout_seconds field to BEP TargetCompleteEvent. - Deprecate test_timeout field in ExecutionInfo. Data is still written to deprecated field to allow consumer transition. PiperOrigin-RevId: 193192636
* Independently merge assetsGravatar asteinb2018-04-17
| | | | | | | | | | Merges assets using the newly created action. Also, add BusyBoxActionBuilder to collect common boilerplate for spawning an action that invokes the Android busybox. RELNOTES: none PiperOrigin-RevId: 193192621
* Add helpful functionality to CommandLines.Gravatar tomlu2018-04-17
| | | | | | | | | We're mostly adding convenience methods. This will be used by spawn runners and in Spawn construction, but we break it out now to lessen the size of the final CL. We also pull out a CommandLineLimits class instead of using an int. This will partially help with readability, but it also likely that we will add a second constraint (max length of a single argument). RELNOTES: None PiperOrigin-RevId: 193191097
* Add compilation_info in java_common.compile.Gravatar elenairina2018-04-17
| | | | PiperOrigin-RevId: 193185628
* Delete old version of jarjarGravatar Liam Miller-Cushon2018-04-17
| | | | | | | | Follow-up to eec549fafc25d9c713d61bab228b086c0b18346b Change-Id: I100f657ec6ba641d09d70b08a1f748de62837d10 Closes #5029.
* Bump @desugar_jdk_libs dependency, which pulls in build file changes and a ↵Gravatar kmb2018-04-17
| | | | | | | | new class, and adjust its build accordingly. RELNOTES: None. PiperOrigin-RevId: 193177895
* Java: Stops adding CcLinkParamsInfo twice in JavaImport.Gravatar plf2018-04-17
| | | | | | | This provider already gets added through semantics.addProviders(). RELNOTES:none PiperOrigin-RevId: 193176446
* Java: Do not call semantics.addProviers from JavaBinary.java.Gravatar plf2018-04-17
| | | | | | | None of the providers are added anyway. RELNOTES:none PiperOrigin-RevId: 193172437
* Add an info-key for the repository cacheGravatar Klaus Aehlig2018-04-17
| | | | | | | | | | | | Add a key to `bazel info` to obtain the location of the repository cache. As, by default, it is some directory under the bazel output root, its location is not obvious. Moreover, knowing the location is useful to have direct access to the downloaded artifacts for further use (e.g., for prefilling caches on local machines from a CI system). Change-Id: I95b56ed424c261e5b5185f02fcb82c5df72ef83a PiperOrigin-RevId: 193162119
* Fix signedness warnings in cpp tests.Gravatar Benjamin Peterson2018-04-17
| | | | | | | | | | | | | | | | | | | | The compiler infers the type of unsuffixed literals as signed. That causes GCC warnings like this with gtest's ASSERT_EQ if one side is a literal and other is an unsigned type: ``` In file included from src/test/cpp/option_processor_test.cc:23:0: external/com_google_googletest/googletest/include/gtest/gtest.h: In instantiation of 'testing::AssertionResult testing::internal::CmpHelperEQ(const char*, const char*, const T1&, const T2&) [with T1 = int; T2 = long unsigned int]': external/com_google_googletest/googletest/include/gtest/gtest.h:1449:23: required from 'static testing::AssertionResult testing::internal::EqHelper<lhs_is_null_literal>::Compare(const char*, const char*, const T1&, const T2&) [with T1 = int; T2 = long unsigned int; bool lhs_is_null_literal = false]' src/test/cpp/option_processor_test.cc:98:3: required from here external/com_google_googletest/googletest/include/gtest/gtest.h:1421:11: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] if (lhs == rhs) { ~~~~^~~~~~ ``` Closes #4994. Change-Id: Ic40e8714531aaa0e0d748dd59658a6de15bfe12d PiperOrigin-RevId: 193161516
* Change default value of 'tools' attribute to unbound.Gravatar tomlu2018-04-16
| | | | | | | We do not wish to support the attribute being Noneable forever. RELNOTES: None PiperOrigin-RevId: 193139282
* Cleanup Artifact.getPath() usage surrounding Fingerprint.Gravatar shahan2018-04-16
| | | | PiperOrigin-RevId: 193130164
* Create @SkylarkConstructor annotation, to annotate certain global-namespace ↵Gravatar cparsons2018-04-16
| | | | | | | | | | @SkylarkCallable methods as representing constructors of other skylark types. This change also demonstrates the new pattern on the global Label() constructor. As an added bonus, it fixes documentation of that constructor. The old documentation used to read "Label.Label(...)" and the new documentation reads "Label(...)". RELNOTES: None. PiperOrigin-RevId: 193109338
* Update format implementation in ctx.actions.args.Gravatar tomlu2018-04-16
| | | | | | | Since we're only supporting a single %s anyway, make this explicit in the docs, fail in the analysis phase, and use a more efficient format method in the implementation. RELNOTES: None PiperOrigin-RevId: 193099585
* Re-add an accidentally removed line in skylark docgenGravatar cparsons2018-04-16
| | | | | RELNOTES: None. PiperOrigin-RevId: 193093782
* Introduce tools attribute to ctx.actions.run and friends.Gravatar tomlu2018-04-16
| | | | | | | | | This will allow us to stop iterating all inputs in an expensive manner looking for tools so we can add their runfiles. If users specify the 'tools' attribute, it is assumed they know what they are doing and inputs will no longer be scanned for tools. RELNOTES: Introduce 'tools' attribute to ctx.actions.run. PiperOrigin-RevId: 193092258
* Add ValueConstants helper to handle the increasingly complex logic for ↵Gravatar janakr2018-04-16
| | | | | | value-equality-tested constants. Main hurdle is efficiently testing to see if a Collection is a value constant without trying to do work on Collections that can't possibly be value constants. PiperOrigin-RevId: 193085625
* Create @SkylarkGlobalLibrary annotation, allowing classes/interfaces with ↵Gravatar cparsons2018-04-16
| | | | | | | | | global skylark functions to use @SkylarkCallable instead of @SkylarkSignature. Also migrate skylark's global "rule" function to @SkylarkCallable, thus demonstrating the new feature. RELNOTES: None. PiperOrigin-RevId: 193085313
* Provider and dependency container for Android assetsGravatar asteinb2018-04-16
| | | | | | | | | | | | These classes will allow a reasonable asset-only merging action in the next change. The relationship between AndroidAssetsInfo and AssetDependencies is a bit messy; I based it on the existing resource provider and dependencies class rather than come up with something radically different. RELNOTES: none PiperOrigin-RevId: 193085304
* Independently parse assetsGravatar asteinb2018-04-16
| | | | | | | This is the first step in processing assets completely seperately from resources. RELNOTES: none PiperOrigin-RevId: 193076991
* Rollback https://github.com/bazelbuild/bazel/pull/5007Gravatar cparsons2018-04-16
| | | | | | | It breaks downstream rules_nodejs. See https://github.com/bazelbuild/bazel/issues/5028 for details. RELNOTES: None. PiperOrigin-RevId: 193074798
* Implement positional overloads for ctx.actions.args.Gravatar tomlu2018-04-16
| | | | | | | | | | | We now support calls like: args = ctx.action.args() args.add("--foo", value) args.add_all("--foo", values) RELNOTES: Support two-arg overloads for ctx.actions.args (eg. args.add("--foo", val)) PiperOrigin-RevId: 193074060
* Introduce NestedSetCodecWithStore, which serializes NestedSet using a ↵Gravatar cpeyser2018-04-16
| | | | | | process-global bimap of fingerprints to NestedSet contents. PiperOrigin-RevId: 193063717
* Create asset merging actionGravatar asteinb2018-04-16
| | | | | | | | | | | | 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
* repository_ctx.download_and_extract: mention cache in documentationGravatar Klaus Aehlig2018-04-16
| | | | | | | | | Since the repository_cache is now enabled by default, extend the documentation of the download_and_extract method to mention its effect, if a sha256 checksum is specified. Change-Id: I3cb714e60a5957e338ceb83fe4f1a3c6eaf64960 PiperOrigin-RevId: 193053375
* Remove a stale comment: srcs-less java_library rules no longer forward their ↵Gravatar cushon2018-04-16
| | | | | | deps PiperOrigin-RevId: 193053186
* Migrate to the new version of jarjarGravatar cushon2018-04-16
| | | | PiperOrigin-RevId: 193052121