{"action":"opened","issue":{"url":"https://api.github.com/repos/bazelbuild/bazel/issues/2165","repository_url":"https://api.github.com/repos/bazelbuild/bazel","labels_url":"https://api.github.com/repos/bazelbuild/bazel/issues/2165/labels{/name}","comments_url":"https://api.github.com/repos/bazelbuild/bazel/issues/2165/comments","events_url":"https://api.github.com/repos/bazelbuild/bazel/issues/2165/events","html_url":"https://github.com/bazelbuild/bazel/issues/2165","id":193060891,"number":2165,"title":"Superfluous dependency on Visual Studio?","user":{"login":"zmeggyesi","id":16238446,"avatar_url":"https://avatars.githubusercontent.com/u/16238446?v=3","gravatar_id":"","url":"https://api.github.com/users/zmeggyesi","html_url":"https://github.com/zmeggyesi","followers_url":"https://api.github.com/users/zmeggyesi/followers","following_url":"https://api.github.com/users/zmeggyesi/following{/other_user}","gists_url":"https://api.github.com/users/zmeggyesi/gists{/gist_id}","starred_url":"https://api.github.com/users/zmeggyesi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zmeggyesi/subscriptions","organizations_url":"https://api.github.com/users/zmeggyesi/orgs","repos_url":"https://api.github.com/users/zmeggyesi/repos","events_url":"https://api.github.com/users/zmeggyesi/events{/privacy}","received_events_url":"https://api.github.com/users/zmeggyesi/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-12-02T08:34:19Z","updated_at":"2016-12-02T08:34:19Z","closed_at":null,"body":"Please provide the following information. The more we know about your system and use case, the more easily and likely we can help.\r\n\r\n### Description of the problem / feature request / question:\r\nBazel requires a Visual Studio even when building a pure-Java project.  \r\nThe exact error output:  \r\n```\r\nERROR: in target '//external:cc_toolchain': no such package '@local_config_cc//': Traceback (most recent call last):\r\n        File \"C:/tools/msys64/var/tmp/Bazel/qNrn0$Ug/external/bazel_tools/tools/cpp/cc_configure.bzl\", line 481\r\n                _find_env_vars(repository_ctx, vs_path)\r\n        File \"C:/tools/msys64/var/tmp/Bazel/qNrn0$Ug/external/bazel_tools/tools/cpp/cc_configure.bzl\", line 423, in _find_env_vars\r\n                _execute(repository_ctx, [\"wrapper/get_env....\"])\r\n        File \"C:/tools/msys64/var/tmp/Bazel/qNrn0$Ug/external/bazel_tools/tools/cpp/cc_configure.bzl\", line 93, in _execute\r\n                auto_configure_fail(result.stderr)\r\n        File \"C:/tools/msys64/var/tmp/Bazel/qNrn0$Ug/external/bazel_tools/tools/cpp/cc_configure.bzl\", line 50, in auto_configure_fail\r\n                fail(\"\r\n%sAuto-Configuration Error:%s ...))\r\n\r\nAuto-Configuration Error: The system cannot find the path specified.\r\n```\r\n\r\nAt first, I thought the issue was the lack of a `BAZEL_VS` variable in the shell, so I suppressed it by setting an empty string. Since that didn't help, I first tried getting a GCC using MSYS `pacman`, to no avail. Finally, I installed MSVS Community Edition, and provided the path, which fixed the issue. \r\n\r\nHowever, the feeling still remains that a pure-Java project should not require me to install VS to run the `java_binary` or `java_library` rules.\r\n\r\n### If possible, provide a minimal example to reproduce the problem:\r\nThe Java tutorial, or any Java project, without some version of Visual Studio installed will present the problem. The `BAZEL_VS` variable may need to be unset from the shell environment.\r\n\r\n### Environment info\r\n* Operating System: Windows 10 v1607 build 14393.447; java version \"1.8.0_112\"\r\n\r\n* Bazel version (output of `bazel info release`): release 0.4.1\r\n\r\n* If `bazel info release` returns \"development version\" or \"(@non-git)\", please tell us what source tree you compiled Bazel from; git commit hash is appreciated (`git rev-parse HEAD`): N/A\r\n\r\n###  Have you found anything relevant by searching the web? (e.g. GitHub issues, email threads in the [bazel-discuss@googlegroups.com](https://groups.google.com/forum/#!forum/bazel-discuss) archive)\r\nI did raise the [question](https://groups.google.com/forum/#!topic/bazel-discuss/esKQVJYsKUE) in the Bazel Discussions group, and one user offered that the `java_binary` rule accidentally triggers the discovery of the C toolchain as well due to insufficient granularity.\r\n\r\n### Anything else, information or logs or outputs that would be helpful?\r\n(If they are large, please upload as attachment or provide link).\r\n"}}
{"actor":{"display_login":"zmeggyesi"}}