aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/analysis/config
Commit message (Collapse)AuthorAge
* Reorganize Skylark Reference documentation.Gravatar Dmitry Lomov2016-06-29
| | | | | -- MOS_MIGRATED_REVID=126081020
* Disable runfiles on Windows.Gravatar Dmitry Lomov2016-06-21
| | | | | | | | | | | | This adds a new configuration option that allows disabling the creation of symlink forest for runfiles. On Windows, symlink forest is disabled by default; only the runfiles manifest is created. For shell tests, a function 'rlocation' is provided that converts from runfiles location to a real location. Work towards #1212. -- MOS_MIGRATED_REVID=125439553
* Remove BuildConfiguration.addRoots() and the pregrepped includes directory.Gravatar Lukacs Berki2016-06-17
| | | | | | | This is to simplify the contract of BuildConfiguration.Fragment, thus making it simpler to create BuildConfigurations without unnecessary fragments and eventually create configuration fragments from Skylark. -- MOS_MIGRATED_REVID=125137625
* Remove BuildConfiguration.Fragment#declareSkyframeDependencies().Gravatar Lukacs Berki2016-06-15
| | | | | | | It was not used (IIRC the last user was FdoSupport while it lived inside CppConfiguration) -- MOS_MIGRATED_REVID=124938836
* Add --[no]instrument_test_targets option to BlazeGravatar Googler2016-06-14
| | | | | | | | | | | | | | | When true (the default), test rules included by --instrumentation_filter are instrumented. When false, test rules are excluded from instrumentation (whether or not their names would be matched by --instrumentation_filter). This option provides a superior way to exclude test rules from instrumentation, compared to setting --instrumentation_filter exclusions based on test rule naming conventions. Naming conventions vary from language to language and are not always followed. Blaze already has enforced semantics for test targets (test rule build function names _must_ end in "_test", see TargetUtils.isTestRule). In general, when either option is available, it's better to rely on enforced semantics than unenforced conventions. Note that this default preserves present behavior. In the future, I think it would make sense to: * Change the default value of --instrument_test_targets to false. * Change the default value of --instrumentation_filter to an empty string (match everything). RELNOTES: Add --instrument_test_targets option. -- MOS_MIGRATED_REVID=124732226
* Turn --legacy_external_runfiles back on by defaultGravatar Damien Martin-Guillerez2016-06-09
| | | | | | | | | | | | --nolegacy_external_runfiles breaks $(location @repo//) syntax for the runfiles case. This will be fixed when the structure of external repository in the execroot will be the same as in the runfiles tree so let flip that flag back on. Fixes #1356. RELNOTES: Revert of commit bd69849378112c3b05bc218e57cdafca82860710, legacy runfiles tree paths are still supported by default. -- MOS_MIGRATED_REVID=124445792
* Dynamic configurations: trim top-level targets, too.Gravatar Greg Estren2016-06-02
| | | | | | | | | | | | | | | | | | | | | | | Right now, configuration trimming happens in ConfiguredTargetFunction.computeDependencies. This means only the deps of other targets get trimmed. With this change, every ConfiguredTarget gets its configuration accurately trimmed, regardless of where it comes from or what it's used for. In practice, there could still be other code paths that instantiate ConfiguredTargetValue.key without pre-trimming. We'll have to tackle those as we hit them. Also cleaned up some symbol naming in BuildView.update to try to make the logic flow clearer. TESTED: BuildViewTest#testNewActionsAreDifferentAndDontConflict now passes with dynamic configs (among others) -- MOS_MIGRATED_REVID=123807892
* By default, don't create the .runfiles/workspace/external/repo dirsGravatar Kristina Chodorow2016-05-27
| | | | | | | | | | | | RELNOTES[INC]: External runfiles will now be accessible only via their .runfiles/repo/path/to/target path, not .runfiles/workspace-name/external/repo/path/to/target. If code still needs to use the legacy path, it can set --legacy_external_runfiles temporarily, but should transition to using the default location as it is more portable (see https://groups.google.com/d/msg/bazel-discuss/_Xo14sf7fHw/g7wdatTGBgAJ for details). The --legacy_external_runfiles option will be removed for the next release. -- MOS_MIGRATED_REVID=123217489
* Allow use of Exceptions to exit early out of configured-target creation, ↵Gravatar Chris Parsons2016-05-24
| | | | | | | | | | instead of passing and checking null in all helpers. Demonstrates this pattern usage in a few select rules (e.g. AndroidBinary) where this was particularly egregious. There are many places which can benefit from this pattern -- this change doesn't try to fix them all at once. -- MOS_MIGRATED_REVID=123012378
* When BuildOptions.get(Class<T> optionsClass) fails, include whichGravatar Greg Estren2016-05-23
| | | | | | | | | fragment was requested in the NullPointerException message. This helps diagnose dynamic configuration errors. -- MOS_MIGRATED_REVID=122855814
* Update Bazel native rule documentation to use new ${link} syntax.Gravatar David Chen2016-05-20
| | | | | -- MOS_MIGRATED_REVID=122772973
* Dynamic configurations: have HostTransition just clone theGravatar Greg Estren2016-05-11
| | | | | | | | | | | | | | | original options if they're already from the host. This fixes an obscure incompatibility between Bazel's flag invocation policy infrastructure and multiple host configurations. In short, when multiple host configurations are possible, policy settings may not get consistently applied. Bazel invocation policies: https://github.com/bazelbuild/bazel/blo[]d24e2b69789ea54762ab034fdafc205cdcecea5/src/main/protobuf/invocation_policy.proto -- MOS_MIGRATED_REVID=122014371
* Create runfiles at both .runfiles/ws/external/repo and .runfiles/repoGravatar Kristina Chodorow2016-04-26
| | | | | | | | | The major piece of #848. RELNOTES[INC]: All repositories are now directly under the x.runfiles directory in the runfiles tree (previously, external repositories were at x.runfiles/main-repo/external/other-repo. This simplifies handling remote repository runfiles considerably, but will break existing references to external repository runfiles. -- MOS_MIGRATED_REVID=120722312
* Fixed broken link in the documentation.Gravatar Florian Weikert2016-04-25
| | | | | -- MOS_MIGRATED_REVID=120695090
* Updated javadoc that was invalidated by commit ↵Gravatar Florian Weikert2016-04-25
| | | | | | | 0dbe07f017d391aba0613b4e6ca1503b62382ccd -- MOS_MIGRATED_REVID=120687334
* Add a --legacy_external_runfiles optionGravatar Kristina Chodorow2016-04-25
| | | | | | | | This isn't hooked up to anything yet, but is another piece of getting #848 rolled forward. -- MOS_MIGRATED_REVID=120582973
* Remove FileProvider.label.Gravatar Ulf Adams2016-04-22
| | | | | -- MOS_MIGRATED_REVID=120539626
* Automated [] rollback of commit 857cda2c45a5cc68c3fa398311c48c571a64915d and ↵Gravatar Damien Martin-Guillerez2016-04-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | commit 790d2f6009d47fe92cf0cd92a1473bbf0141f32e. *** Reason for rollback *** Broke non-Bazel projects on ci.bazel.io Fixes #1168 *** Original change description *** Move the runfiles for external repositories to under the x.runfiles/ directory This also sets the Bazel workspace name to io_bazel_source. Fixes #848. Relevant to #1116, #1124, RELNOTES[INC]: All repositories are now directly under the x.runfiles directory in the runfiles tree (previously, external repositories were at x.runfiles/main-repo/external/other-repo. This simplifies handling remote repository runfiles considerably, but will break existing references to external repository runfiles.... *** -- MOS_MIGRATED_REVID=120535721
* Remove FilesToRunProvider.label.Gravatar Ulf Adams2016-04-22
| | | | | | | The TransitiveInfoProvider already contains a label, use that instead. -- MOS_MIGRATED_REVID=120443298
* Introduce SplitTransitionProvider, to determine the split transition on an ↵Gravatar Chris Parsons2016-04-20
| | | | | | | attribute based on the Rule itself (the transition may thus be determined based on the values of other attributes of the rule) -- MOS_MIGRATED_REVID=120275649
* Move the runfiles for external repositories to under the x.runfiles/ directoryGravatar Kristina Chodorow2016-04-20
| | | | | | | | | | | | | | | This also sets the Bazel workspace name to io_bazel_source. Fixes #848. Relevant to #1116, #1124, RELNOTES[INC]: All repositories are now directly under the x.runfiles directory in the runfiles tree (previously, external repositories were at x.runfiles/main-repo/external/other-repo. This simplifies handling remote repository runfiles considerably, but will break existing references to external repository runfiles. --- Furthermore, if a Bazel project does not provide a workspace name in the WORKSPACE file, Bazel will now default to using __main__ as the workspace name (instead of "", as previously). The repository's runfiles will appear under x.runfiles/__main__/. -- MOS_MIGRATED_REVID=120224534
* Review a number of action subclasses and update them according to the spec.Gravatar Ulf Adams2016-04-19
| | | | | | | | Consists of adding @Immutable annotations, adding final modifiers, and changing the types of fields to immutable types. -- MOS_MIGRATED_REVID=120221067
* Expose ObjcConfiguration to Skylark as fragment "objc" along with callable ↵Gravatar Erik Abair2016-04-07
| | | | | | | | | methods to return compiler options useful for reflection in aspects. RELNOTES[NEW]: Objective-C compiler information is now available to Skylark. -- MOS_MIGRATED_REVID=119160290
* Remove AspectClass.getDefinitionGravatar Dmitry Lomov2016-04-07
| | | | | | | | | | Aspect becomes a triple (AspectClass, AspectDefinition, AspectParameters) and loses its equals() method. After this CL, SkylarkAspectClass.getDefintion still exists and is deprecated. -- MOS_MIGRATED_REVID=119159653
* Eliminate BuildConfiguration.Fragment#prepareForExecutionPhase().Gravatar Lukacs Berki2016-04-07
| | | | | | | It is only used for FDO, for which purpose it seems to be unnecessary. -- MOS_MIGRATED_REVID=119151709
* Move FDO support to the analysis phase by wrapping FdoSupport in its own ↵Gravatar Lukacs Berki2016-04-07
| | | | | | | | | | | SkyFunction. This removes one of the two reasons for the existence of BuildConfiguration#prepareToBuild() which makes implementing dynamic configurations impossible and also makes FDO support halfway sane; now FDO is exactly as ugly as remote repositories, that is to say, reasonably okay. Ideally, we'd implement the zip extraction as an Action and make it a TreeArtifact, but support for TreeArtifacts is not mature yet enough, so it's not possible at the moment. -- MOS_MIGRATED_REVID=119150223
* Description redacted.Gravatar Googler2016-04-07
| | | | | -- MOS_MIGRATED_REVID=119053259
* Dig out the builtin include file from the filegroup of libc_top instead of ↵Gravatar Lukacs Berki2016-04-04
| | | | | | | | | | | special-casing it in CppConfiguration. This seems to be the most reasonable solution. I was toying with the idea of adding a field to CROSSTOOL but that would fail if you set libc_top to something other than what was specified in that file. If I had a infinite amount of time, I'd create a custom rule called cc_libc where libc_top would point so that this file can be referenced by an attribute, but since I don't, this seems to be workable compromise. Also note that contrary to what you'd glean from the code, we don't actually have "compile" and "link" filegroups for libc. -- MOS_MIGRATED_REVID=118921101
* Remove BuildConfiguration#supportsIncrementalBuild , which is apparently unused.Gravatar Lukacs Berki2016-04-01
| | | | | | | BuildConfiguration.Fragment is much more complicated than it should be. Every little helps. -- MOS_MIGRATED_REVID=118783105
* Reimplement the configuration sanity check as a per-fragment check.Gravatar Ulf Adams2016-03-31
| | | | | | | | | This is conceptually better (because each fragment should be self-contained), and gives us better performance, as we no longer need to load all explicit labels. -- MOS_MIGRATED_REVID=118674470
* Enable the configuration sanity check for a subset of tests.Gravatar Ulf Adams2016-03-31
| | | | | | | | | | | Also remove a try-catch block, which was converting all configuration creation errors to IllegalStateException. This uncovered a bug in CppOptions, which wasn't adding host_grte_top to the set of explicit labels. -- MOS_MIGRATED_REVID=118654358
* Always apply invocation policy when constructing build options.Gravatar Janak Ramakrishnan2016-03-24
| | | | | -- MOS_MIGRATED_REVID=117939121
* Add documentation for fragments type, and add the four fragments (apple, ↵Gravatar Dave MacLachlan2016-03-02
| | | | | | | cpp, java, jvm) to the documentation. -- MOS_MIGRATED_REVID=116092594
* Add some basic print/debugging support to fragment collections.Gravatar Dave MacLachlan2016-03-02
| | | | | | | | | | | For print(fragmentCollection) you get: target: [ 'apple', 'cpp', 'java', 'jvm' ] instead of com.google.devtools.build.lib.analysis.config.FragmentCollection@402dc7f2 -- MOS_MIGRATED_REVID=116045778
* Update ANDROID_DEFAULT_CROSSTOOL to default to //external:android/crosstool. ↵Gravatar Luis Fernando Pino Duque2016-02-25
| | | | | | | Remove the constant. -- MOS_MIGRATED_REVID=115555161
* Replace a few more uses of the Constants.TOOLS_REPOSITORYGravatar Luis Fernando Pino Duque2016-02-15
| | | | | -- MOS_MIGRATED_REVID=114680762
* Properly report loading errors during configuration creation.Gravatar Ulf Adams2016-02-10
| | | | | | | | | | | | | | | | | This only applies to interleaved loading and analysis - the production code is fine. Add tests for the RedirectChaser, the fdoOptimize code path, the XcodeConfig, and the Jvm loader. Unfortunately, the configuration factory we internally create by default contains a mock Jvm loader implementation. Since that is one Yak too many right now, I'm adding a temporary method to the AnalysisMock. I added the tests to BuildViewTest for now; technically, they ought to go into the language-specific test cases, but that would require more refactoring as those don't currently run with interleaved loading and analysis. -- MOS_MIGRATED_REVID=114221476
* Remove the genfilesPath parameter from FdoSupport.prepareToBuild.Gravatar Ulf Adams2016-02-10
| | | | | | | | | | | | | | | | | This makes the fdo support independent of the configuration, and therefore safe to cache. The genfilesPath was only used in AutoFDO builds, which now use the full exec path to look up profiling data. The profile already refers to imported files through their full exec paths, so this approach is more consistent. Furthermore, if we ever have a source file with the same root-relative path as a generated file, these would conflict in the FdoSupport map, potentially leading to errors in the build. This may not be possible right now since such files would conflict in the label namespace and such conflicts are always resolved towards the generated file. -- MOS_MIGRATED_REVID=114204994
* Merge LoadedPackageProvider.Bridge into LoadedPackageProvider.Gravatar Ulf Adams2016-02-09
| | | | | | | | This was the last implementation of the interface, so we don't really need the interface anymore. Also add a comment not to use this class. -- MOS_MIGRATED_REVID=114099495
* Introduce a special CPU for Windows and add msys compiler toolchain.Gravatar Dmitry Lomov2016-02-03
| | | | | | | | We might revisit what the default toolchain for Windows should be, but this CL uses msys to simplify bootstrapping. -- MOS_MIGRATED_REVID=113665255
* Contractually document BuildConfiguration.Fragment as immutable and strengthenGravatar Greg Estren2016-02-01
| | | | | | | | | | | | | | | the immutability interfaces of existing implementations. Eventually we want all implementations to comply, but right now CppConfiguration is a glaring exception due to FDO/LIPO support. We don't want more exceptions to arise. This is prep work for pre-trimming ConfigurationFragment.key's BuildOptions input to just the options needed by the fragment. That implies fragments can be shared across configurations, so that needs to be safe. -- MOS_MIGRATED_REVID=113408041
* Remove unused ${SYNOPSIS} variable from Bazel native rule inline documentation.Gravatar David Chen2016-01-28
| | | | | | | | | | This variable is no longer used because the docgen template directly calls RuleDocumentationAttribte.getSynopsis() instead of using the SYNOPSIS variable, and RuleDocumentationAttribute.getHtmlDocumentation() resolves the SYNOPSIS variable to the empty string. -- MOS_MIGRATED_REVID=113249993
* Always declare dependency on xcode gcov.Gravatar Peter Schmitt2016-01-28
| | | | | | | RELNOTES[INC]: Removes --objc_gcov_binary flag. -- MOS_MIGRATED_REVID=113190035
* Fix typoGravatar Googler2016-01-27
| | | | | -- MOS_MIGRATED_REVID=113139138
* Store data about aspect configurations on Dependencies.Gravatar Michael Staib2016-01-27
| | | | | | | | | | | | | | | | | | | | Dependencies are the data structure which needs to propagate the configuration for each aspect as created by trimConfigurations down to the point where it's actually used. We need this to store different configurations for different aspects in a world where aspects have their own configurations, which may have more fragments than the target they're attached to. That world is on its way. Also in this CL: * Refactor Dependency to be an abstract parent class with separate implementations for Attribute.Transitions and BuildConfigurations, as well as null configurations, to avoid having to check nullness in various places. Users of the API will not see this, but get factory methods instead of constructors. As a consequence of this, refactor Dependency to be its own top-level class instead of a nested class in DependencyResolver. -- MOS_MIGRATED_REVID=113109615
* Make local_repository and new_local_repository work with the limitations of ↵Gravatar Lukacs Berki2016-01-26
| | | | | | | our plans for symlink support on Windows. -- MOS_MIGRATED_REVID=113043269
* RELNOTES[INC]: Set stamping to false by default (i.e., --nostamp)Gravatar Damien Martin-Guillerez2016-01-26
| | | | | | | Stamping make build non-deterministic and should not be the default. -- MOS_MIGRATED_REVID=113040937
* Remove unused ${ATTRIBUTE_DEFINITION} and ${ATTRIBUTE_SIGNATURE} variables fromGravatar David Chen2016-01-25
| | | | | | | | | Bazel native rule inline documentation. These variables are no longer used because the docgen templates now directly generate the table of attributes instead of using ATTRIBUTE_DEFINITION and call RuleDocumentation.getAttributeSignature() instead of using ATTRIBUTE_SIGNATURE. RuleDocumentation.getHtmlDocumentation() currently resolves both of these variables to the empty string. -- MOS_MIGRATED_REVID=112933659
* Fix remaining links in inline native rule docs.Gravatar David Chen2016-01-25
| | | | | -- MOS_MIGRATED_REVID=112931111
* Rename defaultShellEnvironment to localShellEnvironment and clarifyGravatar Han-Wen Nienhuys2016-01-21
| | | | | | | its intended use. -- MOS_MIGRATED_REVID=112598772