aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/build_defs
Commit message (Collapse)AuthorAge
* Add a missing argument to the code in ↵Gravatar lberki2017-10-16
| | | | | | | | | https://github.com/bazelbuild/bazel/commit/aee6fb8d21e17c855025f0db6bb52e2cd7a2f642. Progress towards #3424. RELNOTES: None. PiperOrigin-RevId: 172293805
* Update the Apple rules according to the new API because it was deemed better toGravatar lberki2017-10-12
| | | | | | | | | put the environment data behind apple_common as opposed to xcode_config. Progress towards https://github.com/bazelbuild/bazel/issues/3424 . RELNOTES: None. PiperOrigin-RevId: 171931324
* Add tests for the Skylark-based implementation of git repository rules.Gravatar John Cater2017-10-11
| | | | | | | Fixes #3825. Change-Id: I59cb0edb50af30991153a1a684e613853df22dd2 PiperOrigin-RevId: 171687620
* Make the Apple Skylark rule be able to fetch environment data from theGravatar lberki2017-10-06
| | | | | | | | | | | | xcode_config rule in addition to ctx.fragments.apple . Subsequent Bazel versions won't support these methods on ctx.fragments.apple and thus need to be updated. Progress towards https://github.com/bazelbuild/bazel/issues/3424 . RELNOTES: None. PiperOrigin-RevId: 171021097
* tools/build_defs/pkg/pkg.bzl: move load statement to the beginningGravatar Klaus Aehlig2017-10-02
| | | | | | | | ...so that bazel does not complain about internal files when run with --all_incompatible_changes. Change-Id: I9a12a7ab0cd6a92351fe17addd601d531f203aff PiperOrigin-RevId: 170694212
* Make gzipped pkg_tar outputs repeatableGravatar Philipp Schrader2017-09-27
| | | | | | | | | | | | | | | The current implementation allows the gzip module to use the current time as a timestamp. Python2 unfortunately doesn't expose this in the tarfile module so it's easy to overlook. This patch separates the gzip process by creating a separate file object manually and bypassing the gzip compression in the tarfile module. Fixes #1844 Change-Id: I19b265bf55314d38bdd53ccf20c49ecfe6d7618b PiperOrigin-RevId: 170077036
* Make control.tar.gz in pkg_deb repeatableGravatar Philipp Schrader2017-09-25
| | | | | | | | | | | This patch sets the mtime attribute of gzip explicitly to zero. Python2 doesn't expose this via the tarfile module so we have to create an explicit gzip instance. Fixes #3723 Change-Id: I4ce38a317bb92481562b67075d1272f1aebdf9d6 PiperOrigin-RevId: 169881504
* docker_pull: rely on the main repository docker_buildGravatar Damien Martin-Guillerez2017-09-22
| | | | | | | | | | | | | The legacy docker_build was removed from bazel_tools but we need to use it for our integration test so refer to the one in the main repository. Also restore the visibility, just excluding it from bazel_tools is enough and docker_pull needs to call it from other repository. Change-Id: I8a8a5781859960030ae996db95fbaf9c54ec596a PiperOrigin-RevId: 169664916
* Automated rollback of commit ca216f5eb4b1f1892219db0f578495bbbdbaa875.Gravatar philwo2017-09-15
| | | | | | | | | | | | | | | *** Reason for rollback *** Breaks Bazel building itself on FreeBSD, also #3739. *** Original change description *** Introduce empty "toolchain_category" rule for labels that will be used as categories of toolchains for the purpose of toolchain selection. Up to now, we've used the native toolchain_type rule for this purpose. That rule depends on a number of configuration fragments that supply build variables - we don't want toolchains to need to depend on those fragments as well. E.g. toolchain_type depends on JvmConfiguration, but we would like toolchains to work with --experimental_disable_jvm. PiperOrigin-RevId: 168810566
* Remove docker rules from @bazel_toolsGravatar Googler2017-09-14
| | | | | | | | | ... and lock down the visibility to only the Bazel project, please see https://github.com/bazelbuild/rules_docker instead. RELNOTES[INC]: @bazel_tools//tools/build_defs/docker:docker.bzl is no longer available, please see https://github.com/bazelbuild/rules_docker. PiperOrigin-RevId: 168650438
* Introduce empty "toolchain_category" rule for labels that will be used asGravatar cpeyser2017-09-14
| | | | | | | | categories of toolchains for the purpose of toolchain selection. Up to now, we've used the native toolchain_type rule for this purpose. That rule depends on a number of configuration fragments that supply build variables - we don't want toolchains to need to depend on those fragments as well. E.g. toolchain_type depends on JvmConfiguration, but we would like toolchains to work with --experimental_disable_jvm. PiperOrigin-RevId: 168577759
* Remove swift_library and tests, lives in the apple rules repo now.Gravatar thomasvl2017-09-11
| | | | | RELNOTES: The swift_library rule that is distributed with Bazel has been deleted. Users who wish to compile Swift should use the rules in https://github.com/bazelbuild/rules_apple instead. PiperOrigin-RevId: 168032330
* Remove the old copy of apple_genrule. It lives in apple rules.Gravatar thomasvl2017-09-11
| | | | | RELNOTES: The apple_genrule rule that is distributed with Bazel has been deleted. Users who wish to use genrules with Xcode's DEVELOPER_DIR set should use the rules in https://github.com/bazelbuild/rules_apple instead. PiperOrigin-RevId: 168027826
* Update the url for creating spec filesGravatar Tyler Rockwood2017-09-06
| | | | | | Closes #3640. PiperOrigin-RevId: 167578762
* Automated rollback of commit afed47daac8812154196403a30f89aaf0ccca2b2.Gravatar Googler2017-09-04
| | | | | | | *** Reason for rollback *** Change-Id: Ib90ce99cc2e229bbe749130dbde517a075d6e333 PiperOrigin-RevId: 167319258
* Automated rollback of commit 36178dddc45ee39e302516232c83b0fbc4c5dc37.Gravatar Googler2017-09-01
| | | | | | | | | *** Reason for rollback *** fix the downstream breaks that led to the initial rollback Change-Id: Ib90ce99cc2e229bbe749130dbde517a075d6e333 PiperOrigin-RevId: 167247311
* Remove an obsolete TODOGravatar dmishe2017-08-29
| | | | | | | | | | * Xcode's Swift 2.3 toolchain was an artifact of the Swift migration period and doesn't seem to be present in newer versions. Spending time on a likely unused feature isn't worth the time anymore. PiperOrigin-RevId: 166851949
* Automated rollback of commit 39448ebab889a6b5b1ceabcf932adfec9098dfe7.Gravatar dmarting2017-08-28
| | | | | | | | | | | | | *** Reason for rollback *** Break docker builds *** Original change description *** Don't prepend ./ to filenames in pkg_tar rule Change-Id: Ib90ce99cc2e229bbe749130dbde517a075d6e333 PiperOrigin-RevId: 166679861
* Don't prepend ./ to filenames in pkg_tar ruleGravatar Jeff Grafton2017-08-28
| | | | | Change-Id: Ib90ce99cc2e229bbe749130dbde517a075d6e333 PiperOrigin-RevId: 166677549
* Improve pkg_tar warning message.Gravatar Benjamin Peterson2017-08-23
| | | | | | | | Put the label of the target in the warning message. Without it, it's hard to figure out which target one should fix. Change-Id: I694737e80ed74250ea793402443eaf5d2a13d622 PiperOrigin-RevId: 166184377
* Remove tests from //tools/build_defs/dockerGravatar Jeff Grafton2017-08-22
| | | | | | | | | | | | | The real docker rules are in a separate repo now; docker_build is maintained here solely for the //src/test/docker tests. The tests under //tools/build_defs/docker are incompatible with some desired changes to pkg_tar, and since they now live in a separate repo, fixing the tests here is not worth the effort, so just remove them instead. Change-Id: I642bcdb57382eea1884713ae39f5b55ad5133139 PiperOrigin-RevId: 166031190
* More explicit warning for pkg_tar's filesGravatar Damien Martin-Guillerez2017-08-22
| | | | | | | | | So that the user knows the real action to do. Fixes #3401 Change-Id: I1f7ab258b22f832f31c35c83ff52b33bddf0732a PiperOrigin-RevId: 165931509
* Prepare .bzl files to the new semantics of += on listsGravatar vladmos2017-08-17
| | | | | | | | In the future += on lists will work like .extend (by mutating the list) instead of copying the list items to a new list (current behavior). Some .bzl files need to be cleaned up to be compatible with both behaviors. PiperOrigin-RevId: 165528261
* Update files attribute on pkg_tar.Gravatar John Cater2017-08-10
| | | | | Change-Id: I37bb40cae9d8a6ca99460df83b33541972926766 PiperOrigin-RevId: 164726294
* Introduce java_import_externalGravatar jart2017-08-09
| | | | | | | | This Skylark rule is a replacement for maven_jar. See also #1410 PiperOrigin-RevId: 164642813
* Use ctx.label instead of ctx in progress messagesGravatar vladmos2017-08-03
| | | | | | | String representation of ctx will soon be changed, ctx.label should be used explicitly. PiperOrigin-RevId: 164016232
* Rename set to depsetGravatar vladmos2017-07-27
| | | | | | The `set` constructor is obsolete and will be removed in the future. PiperOrigin-RevId: 163331591
* Normalize paths when adding them to the tarball.Gravatar Googler2017-07-24
| | | | PiperOrigin-RevId: 162742684
* Change `files` attr of `pkg_tar` to a dict.Gravatar John Millikin2017-07-12
| | | | | | | | | | The existing support for including a flat list of labels was moved to the `srcs` attribute. See https://github.com/bazelbuild/bazel/issues/3317 for context and motivation. Closes #3318. PiperOrigin-RevId: 161645944
* Fix lint errors in git.bzl and change ctx.fail to the correct fail.Gravatar jcater2017-06-09
| | | | PiperOrigin-RevId: 158397972
* Name generated BUILD files `BUILD.bazel` to avoid name conflicts.Gravatar John Millikin2017-06-08
| | | | | | | | | | | | This allows `new_git_repository` to depend on codebases with pre-existing `BUILD` files from other tools, or `build/` directories in case-insensitive file systems. Fixes #3127 Closes #3142. PiperOrigin-RevId: 158392078
* Hollow out docs and redirect to rules_docker.Gravatar Googler2017-05-15
| | | | PiperOrigin-RevId: 156095174
* Automated g4 rollback of commit 965617aebf4665b6a48229f32ab9a5ef7d4336c5.Gravatar Googler2017-05-05
| | | | | | | | | | | | | | | | | | | | *** Reason for rollback *** rules_docker is again the default. *** Original change description *** Automated g4 rollback of commit 70d8c32e8f7b97413a4e88e219114c117deedb8b. *** Reason for rollback *** Rolling back the switch to rules_docker due to substantial performance regression in certain actions. *** Original change description *** Emit warnings when the bundled docker_build and docker_bundle rules are used. PiperOrigin-RevId: 155195712
* Automated g4 rollback of commit df3d09baf2adc2b84825a6e706f9f0c041e72425.Gravatar Googler2017-05-03
| | | | | | | | | | | | *** Reason for rollback *** Rolling back the switch to rules_docker due to substantial performance regression in certain actions. *** Original change description *** Emit warnings when the bundled docker_build and docker_bundle rules are used. PiperOrigin-RevId: 154869510
* Emit warnings when the bundled docker_build and docker_bundle rules are used.Gravatar Googler2017-05-03
| | | | PiperOrigin-RevId: 154835221
* Make tools/build_defs/hash/sha256.py py3 compatibleGravatar David Flemström2017-05-02
| | | | | | Closes #2866. PiperOrigin-RevId: 154817470
* Make tools/build_defs/pkg/archive.py py3 compatibleGravatar David Flemström2017-05-02
| | | | | | | | | | | | | | | Without this change, any build using python3 and involving this tool fails with: Traceback (most recent call last): File ".../bazel-out/host/bin/external/bazel_tools/tools/build_defs/pkg/build_tar.runfiles/__main__/../bazel_tools/tools/build_defs/pkg/build_tar.py", line 22, in <module> from tools.build_defs.pkg import archive File ".../bazel-out/host/bin/external/bazel_tools/tools/build_defs/pkg/build_tar.runfiles/bazel_tools/tools/build_defs/pkg/archive.py", line 17, in <module> from StringIO import StringIO ModuleNotFoundError: No module named 'StringIO' Closes #2865. PiperOrigin-RevId: 154808860
* Adjust the visibility of this rule, which is needed for the migration of ↵Gravatar Googler2017-04-28
| | | | | | docker_build to rules_docker. PiperOrigin-RevId: 154431359
* Add possibility to set ownership of files on pkg_tarGravatar Damien Martin-Guillerez2017-04-24
| | | | | Change-Id: Ic8c57c0ce78b5875135d5d1f19629ee40fd8f5f2 PiperOrigin-RevId: 153718869
* Support top level package for docker image.Gravatar Linuxer Wang2017-04-24
| | | | | | | | Fixes #616. Closes #2807. PiperOrigin-RevId: 153714590
* Remove tools/build_defs/apple/apple.bzl.Gravatar thomasvl2017-04-20
| | | | PiperOrigin-RevId: 153589856
* Move the sha256 tool into its own directory, as it isn't specific to ↵Gravatar Googler2017-04-19
| | | | | | docker_build. PiperOrigin-RevId: 153508081
* Copy swift.bzl into bazel_rules/rules_apple.Gravatar allevato2017-04-11
| | | | PiperOrigin-RevId: 152729637
* Use sha256 prefix when tagging docker images with full IDsGravatar Jason Young2017-04-11
| | | | | | | | | | | | | | | | | | | | Newer versions of docker require 'sha256' prefix with full IDs (see https://github.com/docker/docker/issues/20972#issuecomment-193381422). Without the prefix users get the following error with newer versions of docke, e.g. 17.04.0-ce-rc1: $ docker tag 7cd4bfeb6766d1c5e5d729b7444cba3d9f97dfddfbeab90ed2e3f7147804ee8f \ docker.io/<user>/<image>:<tag> Error parsing reference: "7cd4bfeb6766d1c5e5d729b7444cba3d9f97dfddfbeab90ed2e3f7147804ee8f" is not a valid repository/tag: invalid repository name (7cd4bfeb6766d1c5e5d729b7444cba3d9f97dfddfbeab90ed2e3f7147804ee8f), cannot specify 64-byte hexadecimal strings --- I'm not sure if this is the proper solution, but it seems to fix the problem with docker version `17.04.0-ce-rc1` as well as older docker version (e.g. `1.12.0`). Alternative solutions welcome. Closes #2755. PiperOrigin-RevId: 152685896
* Description redacted.Gravatar Googler2017-03-27
| | | | | | -- PiperOrigin-RevId: 151263526 MOS_MIGRATED_REVID=151263526
* Disable sandboxing for some bundling actions.Gravatar Googler2017-03-27
| | | | | | -- PiperOrigin-RevId: 151193034 MOS_MIGRATED_REVID=151193034
* Add "resources", "structured_resources" attrs to swift_library.Gravatar Googler2017-03-27
| | | | | | -- PiperOrigin-RevId: 151183770 MOS_MIGRATED_REVID=151183770
* Add a test that a v2.2 format tarball used as a base image contains the ↵Gravatar Googler2017-03-20
| | | | | | | | appropriate ancestry. -- PiperOrigin-RevId: 150530623 MOS_MIGRATED_REVID=150530623
* Reword a commentGravatar Googler2017-03-20
| | | | | | -- PiperOrigin-RevId: 150435164 MOS_MIGRATED_REVID=150435164
* Break apart the monolithic docker.bzl into smaller pieces that logically ↵Gravatar Googler2017-03-16
| | | | | | | | group functions, constants and rules. -- PiperOrigin-RevId: 150326696 MOS_MIGRATED_REVID=150326696