2017-09-12 9 views
0

tensorflowに表示されたガイドに従ってbazel buildコマンドを実行しようとしていますが、これまでに失敗しました。私はPythonバージョン3.5.0を使用していますWindows 10 Bazel_SHの設定

Bazelは、websiteのガイドを使用して正しくインストールされ、設定されていますが、役に立たなくなっています。私はいつも同じエラーが表示されています:

ERROR: in target '//external:cc_toolchain': no such package '@local_config_cc//': Traceback (most recent call last): 
    File "C:/users/username/appdata/local/temp/_bazel_username/ykvutwrt/external/bazel_tools/tools/cpp/cc_configure.bzl", line 32 
      configure_windows_toolchain(repository_ctx) 
    File "C:/users/username/appdata/local/temp/_bazel_username/ykvutwrt/external/bazel_tools/tools/cpp/windows_cc_configure.bzl", line 365, in configure_windows_toolchain 
      tpl(repository_ctx, "CROSSTOOL", {"%{cpu...}": ""}) 
    File "C:/users/username/appdata/local/temp/_bazel_username/ykvutwrt/external/bazel_tools/tools/cpp/windows_cc_configure.bzl", line 377, in tpl 
      _get_escaped_windows_msys_crosstool_content(repository_ctx) 
    File "C:/users/username/appdata/local/temp/_bazel_username/ykvutwrt/external/bazel_tools/tools/cpp/windows_cc_configure.bzl", line 34, in _get_escaped_windows_msys_crosstool_content 
      get_env_var(repository_ctx, "BAZEL_SH") 
    File "C:/users/username/appdata/local/temp/_bazel_username/ykvutwrt/external/bazel_tools/tools/cpp/lib_cc_configure.bzl", line 48, in get_env_var 
      auto_configure_fail(("'%s' environment variable is n...)) 
    File "C:/users/username/appdata/local/temp/_bazel_username/ykvutwrt/external/bazel_tools/tools/cpp/lib_cc_configure.bzl", line 30, in auto_configure_fail 
      fail(("\n%sAuto-Configuration Error:%...))) 

Auto-Configuration Error: 'BAZEL_SH' environment variable is not set 

もう何をすべきかわかりません。

答えて

2

BAZEL_SH env varが設定されていません。要件セクションの次のコマンドを実行しましたか?

You also need to set the BAZEL_SH environment variable to point to bash.exe. For example in the Windows Command Prompt (cmd.exe):

set BAZEL_SH=C:\msys64\usr\bin\bash.exe

あなたはシェル全体で生活するset the environment variable permanentlysetxを使用することもできます。

+0

はい私は何度かでした – Dexstrum

+0

うん、 'Bazel_SH'を設定すると、Bazelのどのバージョンが動いているのですか? –

+0

私はBazelバージョン0.5.4を使用しています。私もsetxコマンドを実行しようとしましたが、コマンドを正しく構成していません。 – Dexstrum

関連する問題