aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/packages
Commit message (Collapse)AuthorAge
* Style edits for ActionsProvider and provider constructorsGravatar Jon Brandvein2016-12-12
| | | | | | -- PiperOrigin-RevId: 141769552 MOS_MIGRATED_REVID=141769552
* Global cleanup change.Gravatar Googler2016-12-07
| | | | | | -- PiperOrigin-RevId: 141307853 MOS_MIGRATED_REVID=141307853
* Add 'aspect_id' for to identify aspects that has been applied to the target.Gravatar Dmitry Lomov2016-12-05
| | | | | | | | | | | | | | | | | | | Add a concept of aspect_id: an unique string that identifies a propagating aspect (aspect class + parameters). This string is designed to be: - Unique for each aspect - human-readable for debugging purposes - not easily parsable. Skylark API: - `ctx.aspect_id` returns an identifier of the current aspect inside aspect implementation function - `Target.aspect_ids` return a list of aspect ids for aspects applied to a given Target (https://www.bazel.io/versions/master/docs/skylark/lib/Target.html) -- PiperOrigin-RevId: 141057865 MOS_MIGRATED_REVID=141057865
* Allow dicts to contain non-comparable objects as keysGravatar Vladimir Moskva2016-12-05
| | | | | | | | | RELNOTES: Skylark dicts internally don't rely on keys order anymore and accept any hashable values (i.e. structs with immutable values) as keys. Iteration order of dictionaries is no longer specified. -- PiperOrigin-RevId: 141055080 MOS_MIGRATED_REVID=141055080
* Move constraint enforcement policy into attribute definitions.Gravatar Greg Estren2016-12-02
| | | | | | | | | This makes is easier to understand and change which attributes are checked. Also turn off checking for "data" and java_* "resources" attributes. -- MOS_MIGRATED_REVID=140771015
* Replace UnixGlob's package glob prefetching functionality with anGravatar Googler2016-12-02
| | | | | | | | optional method in FileSystem. Custom FileSystem implementations can use this to provide their own implementation of glob prefetching. -- MOS_MIGRATED_REVID=140736304
* Rollback of commit c182908910a370b490e7e027b867e11f9f2fb086.Gravatar Michajlo Matijkiw2016-12-01
| | | | | | | *** Reason for rollback *** -- MOS_MIGRATED_REVID=140687884
* Initial commit of cc_proto_library.Gravatar Carmi Grushko2016-12-01
| | | | | | | RELNOTES: cc_proto_library generates C++ code from proto_library rules. -- MOS_MIGRATED_REVID=140680034
* Allow aspects to specify multiple sets of required providers to match ↵Gravatar Rumou Duan2016-12-01
| | | | | | | against rules. Aspects can attach to a rule if at least one set of required providers are present on the rule. -- MOS_MIGRATED_REVID=140605023
* Allow dicts to contain non-comparable objects as keysGravatar Vladimir Moskva2016-11-30
| | | | | | | | RELNOTES: Skylark dicts internally don't rely on keys order anymore and accept any hashable values (i.e. structs with immutable values) as keys. Iteration order of dictionaries is no longer specified. -- MOS_MIGRATED_REVID=140591710
* Support multiple mirror URLs for external reposGravatar Justine Tunney2016-11-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change improves upon 4c67807964e37cfd55bbcda4c6374fcc480bcecc. - A urls attribute has been added to the native workspace rules, with the exception of maven_jar and git_repository. The Skylark repository API also supports multiple URLs now. - The earlier mirrors in the list are preferred. Failover will happen automatically in parallel. - The first 32kB of data is checked before choosing a mirror in order to evade captive portals. - If one's Internet goes down or a download times out, then the download will resume automatically where it left off, provided the server supports RFC7233 for that particular file. Please note that GitHub does not support this for archive snapshots. Files should always be mirrored to a CDN, e.g. GCS, because they support this. - A semaphore is now used on downloads so only 8 can happen at once. Fixes #1814 Fixes #2131 Fixes #2008 Fixes #1968 Fixes #1717 Fixes #943 Wont fix #1194 Fixes tensorflow/tensorflow#5933 Fixes tensorflow/tensorflow#5924 Fixes tensorflow/tensorflow#5924 Fixes tensorflow/tensorflow#5432 See #1607 See #821 See tensorflow/tensorflow#5080 See tensorflow/tensorflow#5029 See tensorflow/tensorflow#4583 See tensorflow/tensorflow#4058 RELNOTES: A urls attribute has been added to repository rules to support multiple mirror URLs for reliably downloading files. -- MOS_MIGRATED_REVID=140495736
* Provide AspectDescriptor to ConfiguredAspect.Gravatar Dmitry Lomov2016-11-29
| | | | | | | | Also clean up the setting of aspect name in ConfiguredAspect and AspectDefintion - it is now obtained from the AspectClass. -- MOS_MIGRATED_REVID=140357052
* Make SkylarkAttr.Descriptor thread-safe.Gravatar Dmitry Lomov2016-11-24
| | | | | | | Also fixes thread-unsafety in AttributeBuilder.build. -- MOS_MIGRATED_REVID=140118866
* Implement structural equality for structsGravatar Vladimir Moskva2016-11-21
| | | | | | | RELNOTES: Structs in Skylark are tested for structural equality instead of reference equality. -- MOS_MIGRATED_REVID=139583726
* Move Bazel-specific functions in a separate file.Gravatar Laurent Le Brun2016-11-21
| | | | | | | | "type", "set" and "select" should not be part of the standalone Skylark library. -- MOS_MIGRATED_REVID=139578095
* Implement build tag filtering.Gravatar Lukacs Berki2016-11-11
| | | | | | | If the --build_tag_filters option is specified, targets built will be filtered according to their tags (at least one included, none excluded) -- MOS_MIGRATED_REVID=138856195
* Expose aspect-related information in the extra-action proto that Bazel hands ↵Gravatar Carmi Grushko2016-11-11
| | | | | | | | | to action_listener() rules. RELNOTES: Extra actions now contain aspect-related information. -- MOS_MIGRATED_REVID=138832922
* When --experimental_extra_action_top_level_only, Bazel to report ↵Gravatar Carmi Grushko2016-11-09
| | | | | | | | | | | extra-actions for actions registered by Aspects injected by a top-level rule. Because we can't know whether an aspect was injected by a top-level target or one of its children, we approximate it by only reporting extra-actions from Aspects that the top-level target could have injected. RELNOTES: When --experimental_extra_action_top_level_only, Bazel reports extra-actions for actions registered by Aspects injected by a top-level rule (approximately). -- MOS_MIGRATED_REVID=138570606
* bazel query: Gravatar Greg Estren2016-10-28
| | | | | | | | | - Extend https://github.com/bazelbuild/bazel/commit/83ffb5e7bc034ea2dd1e957249079b3884a9450d to --output=xml, --output=proto, too. This makes query much more resilient against freezing / OOMing from "select() + select() + select() + ..." patterns. - Make the above logic accessible to any output type. - Move AggregatingAttributeMapper.flattenAttributeValues to ProtoOutputFormatter, since this is really a utility method for ProtoOutputFormatter. -- MOS_MIGRATED_REVID=137429116
* Move ToolsRepository out of EnvironmentGravatar Laurent Le Brun2016-10-27
| | | | | | | | | Other fields will follow (is_skylark, phase, callerLabel). The goal is to make Environment (and more generally Skylark) less dependent on Bazel. -- MOS_MIGRATED_REVID=137386248
* Cleanup in Environment, remove unused lookup functionGravatar Laurent Le Brun2016-10-27
| | | | | -- MOS_MIGRATED_REVID=137266170
* bazel query --output=xml: avoid iterating over all possible values forGravatar Greg Estren2016-10-26
| | | | | | | | attr = select({"a": LABEL_LIST, "b": LABEL_LIST, ...}). This can be exponential (w.r.t. the # of select conditions) and produce OOMs. -- MOS_MIGRATED_REVID=137200979
* Add new skyframe function to lookup the repository given a path, and use thatGravatar John Cater2016-10-25
| | | | | | | to report invalid package references. Fixes #1592. -- MOS_MIGRATED_REVID=137164164
* Allow bypassing input file discovery in package buildingGravatar Michajlo Matijkiw2016-10-19
| | | | | -- MOS_MIGRATED_REVID=136594531
* Make query return dependencies contributed by aspects on rules that don't ↵Gravatar Lukacs Berki2016-10-18
| | | | | | | advertise and providers. -- MOS_MIGRATED_REVID=136452596
* Cleanup, remove differences between Build and Skylark environments.Gravatar Laurent Le Brun2016-10-14
| | | | | | | | | | | | | The only visible difference for users is that a few more functions are available in BUILD files. That's fine, this difference was not even documented. RELNOTES: A few functions are added to BUILD files for consistency (hash, dir, hasattr, getattr) with .bzl files, although they are not very useful. -- MOS_MIGRATED_REVID=136151633
* Fix IllegalStateException when reloading several time the same extensionGravatar Damien Martin-Guillerez2016-10-14
| | | | | | | | | Fixes #1469. -- Change-Id: I3ffc18208ba346e03658ebeb4d2bb5938113a476 Reviewed-on: https://bazel-review.googlesource.com/6615 MOS_MIGRATED_REVID=136073702
* Fix-up for last sandbox change, forgot to add "block-*" to the execution ↵Gravatar Philipp Wollermann2016-10-07
| | | | | | | info filter. -- MOS_MIGRATED_REVID=135471769
* Rollback of commit 5c071429e83b5c6d872c755d3da21ad934638111.Gravatar Damien Martin-Guillerez2016-10-07
| | | | | | | | | | | | | | | | | | | | | | *** Reason for rollback *** Breaks rules_go Found by bisecting (bazel build src:bazel && cd ../rules_go && ../bazel/bazel-bin/src/bazel query 'tests(//...)') See http://ci.bazel.io/job/rules_go/BAZEL_VERSION=HEAD,PLATFORM_NAME=linux-x86_64/370/console *** Original change description *** Allow repositories to refer to the local repository by repo name For example, if the main repository is named @foo, other repositories can refer to targets in it as @foo//path/to:target (instead of @//path/to:target). Fixes #1248. -- MOS_MIGRATED_REVID=135471434
* Change allowedRuleClasses/mandatoryProviders semantics to "either-or" ↵Gravatar Dmitry Lomov2016-10-07
| | | | | | | | | | instead of "and". Also allow native rules to require declared providers on their dependencies. -- MOS_MIGRATED_REVID=135454750
* Improve memory overhead of calculating all computed default valuesGravatar Michajlo Matijkiw2016-10-07
| | | | | | | | Instead of copying the accumulator map each call, reuse the same map, overwriting previous values and taking snapshots in the base case. -- MOS_MIGRATED_REVID=135394631
* Allow repositories to refer to the local repository by repo nameGravatar Kristina Chodorow2016-10-07
| | | | | | | | | | For example, if the main repository is named @foo, other repositories can refer to targets in it as @foo//path/to:target (instead of @//path/to:target). Fixes #1248. -- MOS_MIGRATED_REVID=135382972
* Add cc_common.link_params declared provider.Gravatar Dmitry Lomov2016-10-07
| | | | | -- MOS_MIGRATED_REVID=135346927
* Extract java/javalite proto compilation args to command-line flags.Gravatar Carmi Grushko2016-10-06
| | | | | | | Addresses https://github.com/bazelbuild/bazel/issues/1718 -- MOS_MIGRATED_REVID=135274306
* Add the option --experimental_max_directories_to_eagerly_visit_in_globbing. ↵Gravatar Janak Ramakrishnan2016-10-05
| | | | | | | The first legacy glob that a package requires will, if this option is enabled, cause up to that many directories to be eagerly visited by a glob(['**']). The results are thrown away for memory reasons. -- MOS_MIGRATED_REVID=135148361
* Implement Skylark syntax to propagate an aspect to all attributes.Gravatar Dmitry Lomov2016-10-04
| | | | | -- MOS_MIGRATED_REVID=134793032
* If Label syntax is wrong, actual offense is now reported in error message.Gravatar Andreas Bergmeier2016-09-30
| | | | | | | | Closes #1633. -- Reviewed-on: https://github.com/bazelbuild/bazel/pull/1633 MOS_MIGRATED_REVID=134774446
* Add an actions provider for testing Skylark rules.Gravatar Jon Brandvein2016-09-30
| | | | | | | The new provider gathers actions generated by any Skylark-based RuleConfiguredTarget, so long as the rule definition has _skylark_test=True set. For the moment this flag is under the user's control, but the intention is that it will be set by a test runner. -- MOS_MIGRATED_REVID=134687396
* Allow aspects to propagate to all attributes.Gravatar Dmitry Lomov2016-09-27
| | | | | -- MOS_MIGRATED_REVID=134378592
* Native declared providers are automatically exported.Gravatar Dmitry Lomov2016-09-26
| | | | | -- MOS_MIGRATED_REVID=134221884
* Rollback of commit 5c548f11e20c0b75203e9fe4ab682ed0418064cf.Gravatar Carmi Grushko2016-09-23
| | | | | | | | | | | | | | | | | | | | | | | *** Reason for rollback *** Fixed depot issues. *** Original change description *** Automated [] rollback of commit 2e5ec0fd99ac4bfd930da99f6089dc5faf778464. *** Reason for rollback *** Breaks some targets in the nightly: see [] *** Original change description *** Make java_proto_library's strict_deps default to true. Remove package-level attribute to set the default of strict_deps. Change the semantics to --strict_deps_java_protos to mean force strict deps of all Java protos to be true regardless of their strict_deps attribute. -- MOS_MIGRATED_REVID=133981754
* Rollback of commit 2e5ec0fd99ac4bfd930da99f6089dc5faf778464.Gravatar Tobias Werth2016-09-22
| | | | | | | | | | | | | | | *** Reason for rollback *** Breaks some targets in the nightly: see [] *** Original change description *** Make java_proto_library's strict_deps default to true. Remove package-level attribute to set the default of strict_deps. Change the semantics to --strict_deps_java_protos to mean force strict deps of all Java protos to be true regardless of their strict_deps attribute. -- MOS_MIGRATED_REVID=133938648
* Be honest about type in Type#visitLabelsGravatar Michajlo Matijkiw2016-09-22
| | | | | | | | | | We avoided referencing Label directly, but as the code evolved it became inevitable. Also fix a typo I introduced earlier. -- MOS_MIGRATED_REVID=133831955
* Make java_proto_library's strict_deps default to true.Gravatar Carmi Grushko2016-09-21
| | | | | | | | Remove package-level attribute to set the default of strict_deps. Change the semantics to --strict_deps_java_protos to mean force strict deps of all Java protos to be true regardless of their strict_deps attribute. -- MOS_MIGRATED_REVID=133789725
* Implement label visitation using visitorGravatar Michajlo Matijkiw2016-09-21
| | | | | | | | | As opposed to building up a collection. These collections, and all their iterators, add up creating a lot of garbage. This saves us at least an ImmutableList + Iterator per label. -- MOS_MIGRATED_REVID=133754998
* Use Object for what instead of StringGravatar Michajlo Matijkiw2016-09-21
| | | | | | | | | | | | | The string is only used for error messaging on failure. Instead of constructing lots of strings allow passing in a generic Object whos toString is used for the error message. This allows us to bypass a lot of garbage string generation, at th expense of a little indirection. Chose Object over some specialized type, since we use inline strings frequently as well. -- MOS_MIGRATED_REVID=133741724
* Rollback of commit 82d43279f93d95e4c41b4bc598a3cc05ddd1ae1a.Gravatar Laszlo Csomor2016-09-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | *** Reason for rollback *** Breaks TensorFlow and other Bazel jobs on ci.bazel.io *** Original change description *** Change execution root for external repositories to be ../repo Some of the important aspect of this change: * Remote repos in the execution root are under output_base/execroot/repo_name, so the prefix is ../repo_name (to escape the local workspace name). * Package roots for external repos were previously "output_base/", they are now output_base/external/repo_name (which means source artifacts always have a relative path from their repository). * Outputs are under bazel-bin/external/repo_name/ (or similarly under genfiles). Note that this is a bit of a change from how this was implemented in the previous cl. Fixes #1262. RELNOTES[INC]: Previously, an external repository would be symlinked into the execution root at execroot/local_repo/external/remote_repo. This changes it to be at execroot/remote_repo. This may break genrules/Skylark actions that hardcode execution root paths. If this causes breakages for you, ensure that genrules are using $(location :target) to access files and Skylark rules are using http://bazel.io/docs/skylark/lib/File.html's path, dirname, etc. functions. Roll forward of bdfd58a. -- MOS_MIGRATED_REVID=133709658
* Change execution root for external repositories to be ../repoGravatar Kristina Chodorow2016-09-20
| | | | | | | | | | | | | | | | | | | | | | | Some of the important aspect of this change: * Remote repos in the execution root are under output_base/execroot/repo_name, so the prefix is ../repo_name (to escape the local workspace name). * Package roots for external repos were previously "output_base/", they are now output_base/external/repo_name (which means source artifacts always have a relative path from their repository). * Outputs are under bazel-bin/external/repo_name/ (or similarly under genfiles). Note that this is a bit of a change from how this was implemented in the previous cl. Fixes #1262. RELNOTES[INC]: Previously, an external repository would be symlinked into the execution root at execroot/local_repo/external/remote_repo. This changes it to be at execroot/remote_repo. This may break genrules/Skylark actions that hardcode execution root paths. If this causes breakages for you, ensure that genrules are using $(location :target) to access files and Skylark rules are using http://bazel.io/docs/skylark/lib/File.html's path, dirname, etc. functions. Roll forward of bdfd58a. -- MOS_MIGRATED_REVID=133606309
* Rollback of commit 4381a1d6e8f711957f430aac0c301acec6dfa0eb.Gravatar Damien Martin-Guillerez2016-09-14
| | | | | | | | | | | | | *** Reason for rollback *** Breaks all projects using Bazel, see https://ci.bazel.io *** Original change description *** Deprecated and removed HOST_CFG and DATA_CFG global variables. -- MOS_MIGRATED_REVID=133005398
* Global cleanup change.Gravatar Vladimir Moskva2016-09-13
| | | | | -- MOS_MIGRATED_REVID=132976702