aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools
Commit message (Collapse)AuthorAge
...
* Re-add host_platform and target_platform, and set them as defaults.Gravatar jcater2017-06-21
| | | | | | Part of #2219. PiperOrigin-RevId: 159596011
* Use wrapped_ar on darwin in cc_configure.bzlGravatar hlopko2017-06-20
| | | | | | | | Tool.AR is used by go rules, and the inconsistency fixed in this cl was causing a bug. Fixes #3184. RELNOTES: None. PiperOrigin-RevId: 159562216
* Pass all J2ObjC args using a file instead of just the source files.Gravatar Googler2017-06-19
| | | | | RELNOTES: None. PiperOrigin-RevId: 159228238
* Make cc_configure on Windows simpler and more robustGravatar Yun Peng2017-06-13
| | | | | | | | | | | | | The previous registry value we are querying only exists when Visual Studio is installed. If user only has VC build tools installed and doesn't set env vars like BAZEL_VS, VS140COMNTOOLS, VC won't be detected. HKEY_LOCAL_MACHINE\\SOFTWARE\\Wow6432Node\\Microsoft\\VisualStudio\\SxS\\VC7 exists in both situations and works for all VS versions. Change-Id: I07b5593e882e23fa9e0079e082e6d357b905736d PiperOrigin-RevId: 158841618
* Also add TEMP into msvc_env featureGravatar Yun Peng2017-06-12
| | | | | Change-Id: Ia2510a2b8df728c02f77e2df4effff3232cfe3a2 PiperOrigin-RevId: 158685074
* Use the correct JVM for LcovMerger instead of whatever "java" gets us.Gravatar lberki2017-06-09
| | | | | | | Fixes #2904. RELNOTES: None. PiperOrigin-RevId: 158516169
* Ensure that TEST_TMPDIR exists on the remote host when testing a remote build.Gravatar Googler2017-06-09
| | | | PiperOrigin-RevId: 158430272
* 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
* Add new configuration fragment for platforms, with host and targetGravatar John Cater2017-06-08
| | | | | | | options. Change-Id: If623f2416f8bff7c74ddf99d5c957a075de6494f PiperOrigin-RevId: 158275892
* protobuf: Use bazel's native java_proto_library rules.Gravatar Jakob Buchgraber2017-06-06
| | | | | | | | | Additional changes: - Introduce a Skylark macro java_library_srcs that provides the source jars of a java_*_library rule. - Remove bazel's own java_proto_library implementation. Change-Id: I18f2259bc75ca0fb32dcd8a6a857c609bd2c7773 PiperOrigin-RevId: 158146210
* Use a wrapper-free MSVC toolchain when NO_MSVC_WRAPPER=1Gravatar Yun Peng2017-06-06
| | | | | | | | | | | | | | | | | | | To enable a wrapper free MSVC CROSSTOOL, set NO_MSVC_WRAPPER=1 or add --action_env=NO_MSVC_WRAPPER=1 flag. Note that we still use windows_cc_wrapper.bat to invoke cl.exe and link.exe for different actions. Result for bazel build src/main/cpp:client : NO_WRAPPER: INFO: Elapsed time: 76.833s, Critical Path: 16.70s WRAPPER: INFO: Elapsed time: 138.517s, Critical Path: 27.78s Change-Id: Iaf6b67fc791ae1f8b62d332e47f96f719510bda1 PiperOrigin-RevId: 158118110
* Suggest signing xcode license if that likely inhibits xcode-locator-bin ↵Gravatar cparsons2017-06-06
| | | | | | | generation RELNOTES: None. PiperOrigin-RevId: 158066648
* Remote host_platform pending upcoming changes inGravatar jcater2017-06-06
| | | | | | https://bazel-review.googlesource.com/c/11690/. PiperOrigin-RevId: 158046253
* Automated g4 rollback of commit dba22f337a20d3e8f3ac8dfd23bc6fa69e4528da.Gravatar xingao2017-06-02
| | | | | | | | | | | | | | | | | | | | | *** Reason for rollback *** Use Java implementation of singlejar on FreeBSD, and roll forward change 157473007. *** Original change description *** Automated g4 rollback of commit d894345ed88f8adce600b66a310b5210d0bcb59c. *** Reason for rollback *** Breaks Bazel on FreeBSD: http://ci.bazel.io/view/Dashboard/job/Bazel/JAVA_VERSION=1.8,PLATFORM_NAME=freebsd-11/1542/console *** Original change description *** Use cc implementation of singlejar except on Windows. Change-Id: Ie4a2db2a6fa1ea86f4bdd42cd806f6804a0c56d4 PiperOrigin-RevId: 157729503
* Make C++ archiving use action_configs instead of hardcoded flagsGravatar hlopko2017-06-01
| | | | | RELNOTES: Use action_config in crosstool for static library archiving, remove ar_flag. PiperOrigin-RevId: 157685703
* Add //external:has_androidsdk config_setting.Gravatar ajmichael2017-06-01
| | | | | | | | | | | | | | | | | | This will be used to add some tests and targets to the Bazel codebase that build and run successfully when android_sdk_repository is in the WORKSPACE and silently skip if it is not. Example deps of a library that links against dx.jar: ``` deps = select({ "//external:has_androidsdk": ["//external:android/dx_jar_import"], "//conditions:default": [], }), ``` Also adds tests that config_setting works as expected when propagated through an alias or bind rule. RELNOTES: None PiperOrigin-RevId: 157627472
* Migrate all tests to Truth (except the ones in the examples).Gravatar lberki2017-05-31
| | | | | RELNOTES: None. PiperOrigin-RevId: 157576492
* Fix typo: s/exists/exist/ where needed.Gravatar philwo2017-05-31
| | | | | RELNOTES: None. PiperOrigin-RevId: 157572063
* Automated g4 rollback of commit d894345ed88f8adce600b66a310b5210d0bcb59c.Gravatar laszlocsomor2017-05-31
| | | | | | | | | | | | | *** Reason for rollback *** Breaks Bazel on FreeBSD: http://ci.bazel.io/view/Dashboard/job/Bazel/JAVA_VERSION=1.8,PLATFORM_NAME=freebsd-11/1542/console *** Original change description *** Use cc implementation of singlejar except on Windows. Change-Id: Ie4a2db2a6fa1ea86f4bdd42cd806f6804a0c56d4 PiperOrigin-RevId: 157567871
* Reverts non-xcode-available darwin crosstool generation.Gravatar cparsons2017-05-31
| | | | | RELNOTES: None. PiperOrigin-RevId: 157529642
* Use cc implementation of singlejar except on Windows.Gravatar Xin Gao2017-05-31
| | | | | Change-Id: Ie4a2db2a6fa1ea86f4bdd42cd806f6804a0c56d4 PiperOrigin-RevId: 157473007
* Add host platform definition that internal code can depend on.Gravatar jcater2017-05-31
| | | | | | Part of #2219. PiperOrigin-RevId: 157469326
* Keep "srcs", "hdrs" and "textual_hdrs" separate.Gravatar Googler2017-05-29
| | | | | | | | | | Each can has slightly different semantics for the IDE, and it is better to use the information on which files belong to which group from BUILD file rather than use heuristics like file extension to determine it. The contents of "textual_hdrs" are added by the prefetcher. RELNOTES: None. PiperOrigin-RevId: 157256048
* Let MSVC wrapper recongnize -DEFAULTLIB:library optionGravatar Yun Peng2017-05-26
| | | | | | | | | | | | | If MSVC wrapper is removed, users cannot put flags like `-Wl,ws2_32.lib` in linkopts of C++ rules on Windows. Instead, they should do `-DEFAULTLIB:ws2_32.lib`. This change is to make the wrapper script also accpet -DEFAULTLIB:library option. https://msdn.microsoft.com/en-us/library/229a6ysd.aspx Change-Id: I0cf9f5529f833470166488100b70fb497384e083 PiperOrigin-RevId: 156978364
* Fix msvc_cl.py for cuda compilationGravatar Yun Peng2017-05-24
| | | | | | | Passing /MT or /MD option using --compiler_options to nvcc Change-Id: Idf02ca0a4abf25bced397f5fffc1bc10ff0c160f PiperOrigin-RevId: 156976225
* Remove /W3 from compiler_flag from MSVC CROSSTOOLGravatar pcloudy2017-05-24
| | | | | | | | | The default warning level will become /W1 which only display severe warnings. https://msdn.microsoft.com/en-us/library/thxezb7y.aspx RELNOTES: None PiperOrigin-RevId: 156972872
* Add functionality from the old shell-based coverage runner script to the new ↵Gravatar lberki2017-05-23
| | | | | | | | | | | | | one. This isn't a principled solution, but since it depends on /usr/bin/lcov, it should never be relied on at all. It's mostly a courtesy to people who came to use C++ coverage in Bazel before we removed it. Fixes #2685. Progress on #1118. RELNOTES: None. PiperOrigin-RevId: 156866370
* Store the features enabled for each targetGravatar Googler2017-05-23
| | | | | | | ctx.features has already merged the package-level and rule-level feature sets. RELNOTES: None. PiperOrigin-RevId: 156811464
* Wrap ar invocations for osx bazel crosstool.Gravatar cparsons2017-05-23
| | | | | | | | | This: 1. Forces ar invocations to go through xcrunwrapper (thus having the environment variables set correctly so that the appropriate xcode is used) 2. Institutes a fix for non-hermeticism around object file timestamps. RELNOTES: None. PiperOrigin-RevId: 156759530
* Include input header files in CIdeInfoGravatar Googler2017-05-22
| | | | | | A precursor to prefetching source files outside the project. PiperOrigin-RevId: 156598992
* Expose javac jar in java_toolchain's skylark providerGravatar Googler2017-05-22
| | | | PiperOrigin-RevId: 156589908
* Fix compile project/file actions for scala.Gravatar Googler2017-05-19
| | | | | | | | Rather than including all of intellij-resolve in intellij-compile, calculate compilation artifacts for each custom language we support (as we already need to do for the other output groups). PiperOrigin-RevId: 156466315
* intellij-compile output group should request compilation artifacts fromGravatar Googler2017-05-19
| | | | | | transitive closure of targets. PiperOrigin-RevId: 156428233
* Remove toolchain_rule.Gravatar John Cater2017-05-17
| | | | | | | | It's unneeded syntactic sugar, we can re-introduce it later if it seems warranted. Change-Id: If41e10f96ae0b6ac522a1da36237ff1b3c91757d PiperOrigin-RevId: 156184854
* Hollow out docs and redirect to rules_docker.Gravatar Googler2017-05-15
| | | | PiperOrigin-RevId: 156095174
* Fixes compilation on Power8Gravatar davideleoni902017-05-15
| | | | | | | | This fixes #3000 Closes #3002. PiperOrigin-RevId: 156046356
* Adding feature for linking C Run-Time library on WindowsGravatar Yun Peng2017-05-12
| | | | | | | | | | | | | | | By default, we use /MT(/MTd for debug mode) and link to libcmt.lib(libcmtd.lib). Users can set USE_DYNAMIC_CRT=1 or add --action_env=USE_DYNAMIC_CRT=1 to switch to /MD and msvcrt.lib (/MDd and msvcrtd.lib for debug mode) Reference: https://msdn.microsoft.com/en-us/library/abx4dbyh.aspx Fixed https://github.com/bazelbuild/bazel/issues/2120 Change-Id: I61e65ace82163acd456bf82f2b108c5fe8d8a8ce PiperOrigin-RevId: 155850886
* Set the correct main class on the desugar java_binary target in Bazel.Gravatar ajmichael2017-05-10
| | | | | | | | | | | | | | | | | | This will make it easier to build the desugarer tool from the Bazel source tree as an executable (deploy) jar and then use it for something else. For example, with this CL, you can do the following steps to get a standalone desugarer binary: 1. git clone https://github.com/bazelbuild/bazel 2. bazel build //src/tools/android/java/com/google/devtools/build/android/desugar:desugar_bin_deploy.jar 3. cp bazel-bin/src/tools/android/java/com/google/devtools/build/android/desugar/desugar_bin_deploy.jar ~/bin/desugar.jar And then you can invoke desugar without bazel with `java -jar ~/bin/desugar.jar`. https://github.com/bazelbuild/bazel/issues/2975 RELNOTES: None PiperOrigin-RevId: 155629711
* Escape % in strings that will appear in CrosstoolGravatar hlopko2017-05-10
| | | | | | | | | | %foo% syntax is not allowed in Crosstool, but some Windows environment variables that we read in cc_configure.bzl can reference other variables, therefore in order not to crash, we need to escape them before putting the values into the Crosstool. RELNOTES: None. PiperOrigin-RevId: 155602425
* Migrate off versioned javac and Error Prone targetsGravatar Liam Miller-Cushon2017-05-09
| | | | | Change-Id: Iad1e07ad55d5304d7c3dbb8bdab856728a91432d PiperOrigin-RevId: 155375893
* Allow android compilations to use type annotationsGravatar cushon2017-05-08
| | | | PiperOrigin-RevId: 155287620
* 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
* Add compile_jars for Skylark to JavaProviderGravatar Stephen Twigg2017-05-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | Add compile_jars Skylark accessor to JavaProvider. This outputs the non-recursive set of jars needed to build with this target. Allows Skylark tools to get the same set of compile_jars that JavaLibrary is getting. Added test that verifies Skylark was getting lists from both compile_jars and transitive_runtime_jars of the expected length. Then, verified (via test code) those nested sets were identical to the ones provided by the java_library. To reviewers: First, would like to add documentation flags to these fields in JavaProvider. Is it possible, instead of adding them to this map to follow use the @SkylarkCallable annotation to expose methods on JavaProvider instead? It would then also be nice to mark these as experimental since won't really know the final API until java_skylark_library sandwich is done. I also tested this locally via bazel build //src:bazel and then doing ~/bazelsandbox/bazel/bazel-bin/src/bazel test SomeTarget in a different repo that had a .bzl file trying to use compile_jars. Change-Id: I1779c1b6303f36e50076c3479bfcb15a25aa95d8 PiperOrigin-RevId: 155191816
* Improve error message when building Android rules without an SDK.Gravatar ajmichael2017-05-05
| | | | | | | | | | | | | | | | | | | | Fixes https://github.com/bazelbuild/bazel/issues/509. Example output: ``` $ bazel build //:all INFO: Found 1 target... ERROR: /usr/local/google/home/ajmichael/.cache/bazel/_bazel_ajmichael/7fcc7480abc634522e5c0cfe6b85b583/external/bazel_tools/tools/android/BUILD:236:1: Executing genrule @bazel_tools//tools/android:no_android_sdk_repository_error failed: Process exited with status 1 [sandboxed]. This build requires an Android SDK. Please add the android_sdk_repository rule to your WORKSPACE. Use --strategy=Genrule=standalone to disable sandboxing for the failing actions. Target //:lib failed to build Use --verbose_failures to see the command lines of failed build steps. INFO: Elapsed time: 0.327s, Critical Path: 0.10s ``` RELNOTES: Attempting to build an Android target without setting up android_sdk_repository will now produce a helpful error message. PiperOrigin-RevId: 155158667
* Stop using zip and unzip in android shell tests.Gravatar ajmichael2017-05-04
| | | | | | | Also, open source two more tests. RELNOTES: None PiperOrigin-RevId: 155129416
* Remove debug print statement from proguard_whitelister.pyGravatar ahumesky2017-05-04
| | | | | RELNOTES: None. PiperOrigin-RevId: 155003333
* Rollforward #2 of: Basic open-source crosstool to support targeting apple ↵Gravatar cparsons2017-05-04
| | | | | | | platform types. RELNOTES: None. PiperOrigin-RevId: 154993630
* 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