Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build envoy with bazel,but has error, someone would help me? #13194

Closed
WestEnlarged opened this issue Sep 19, 2020 · 16 comments
Closed

build envoy with bazel,but has error, someone would help me? #13194

WestEnlarged opened this issue Sep 19, 2020 · 16 comments

Comments

@WestEnlarged
Copy link

i'm using win10 ,and installed bazel (3.5.0) , then i checkout the code to build master with the envoy doc. It is very confused like this, and i was installed python.

`PS E:\code\envoy> bazel build

Starting local Bazel server and connecting to it...
INFO: Repository protodoc_pip3 instantiated at:
no stack (--record_rule_instantiation_callstack not enabled)
Repository rule pip_import defined at:
C:/users/admin/_bazel_admin/mr5hobvt/external/rules_python/python/pip.bzl:51:29: in
INFO: Repository kafka_pip3 instantiated at:
no stack (--record_rule_instantiation_callstack not enabled)
Repository rule pip_import defined at:
C:/users/admin/_bazel_admin/mr5hobvt/external/rules_python/python/pip.bzl:51:29: in
INFO: Repository headersplit_pip3 instantiated at:
no stack (--record_rule_instantiation_callstack not enabled)
Repository rule pip_import defined at:
C:/users/admin/_bazel_admin/mr5hobvt/external/rules_python/python/pip.bzl:51:29: in
INFO: Repository configs_pip3 instantiated at:
no stack (--record_rule_instantiation_callstack not enabled)
Repository rule pip_import defined at:
C:/users/admin/_bazel_admin/mr5hobvt/external/rules_python/python/pip.bzl:51:29: in
ERROR: An error occurred during the fetch of repository 'protodoc_pip3':
Traceback (most recent call last):
File "C:/users/admin/_bazel_admin/mr5hobvt/external/rules_python/python/pip.bzl", line 49, column 13, in _pip_import_impl
fail("pip_import failed: %s (%s)" % (result.stdout, result.stderr))
Error in fail: pip_import failed: (Python was not found but can be installed from the Microsoft Store: https://go.microsoft.com/fwlink?linkID=2082640)
INFO: Repository envoy_build_tools instantiated at:
no stack (--record_rule_instantiation_callstack not enabled)
Repository rule http_archive defined at:
C:/users/admin/_bazel_admin/mr5hobvt/external/bazel_tools/tools/build_defs/repo/http.bzl:336:31: in
INFO: Repository rules_foreign_cc instantiated at:
no stack (--record_rule_instantiation_callstack not enabled)
Repository rule http_archive defined at:
C:/users/admin/_bazel_admin/mr5hobvt/external/bazel_tools/tools/build_defs/repo/http.bzl:336:31: in
INFO: Repository upb instantiated at:
no stack (--record_rule_instantiation_callstack not enabled)
Repository rule http_archive defined at:
C:/users/admin/_bazel_admin/mr5hobvt/external/bazel_tools/tools/build_defs/repo/http.bzl:336:31: in
INFO: Repository io_bazel_rules_go instantiated at:
no stack (--record_rule_instantiation_callstack not enabled)
Repository rule http_archive defined at:
C:/users/admin/_bazel_admin/mr5hobvt/external/bazel_tools/tools/build_defs/repo/http.bzl:336:31: in
INFO: Repository bazel_gazelle instantiated at:
no stack (--record_rule_instantiation_callstack not enabled)
Repository rule http_archive defined at:
C:/users/admin/_bazel_admin/mr5hobvt/external/bazel_tools/tools/build_defs/repo/http.bzl:336:31: in
INFO: Repository build_bazel_rules_apple instantiated at:
no stack (--record_rule_instantiation_callstack not enabled)
Repository rule http_archive defined at:
C:/users/admin/_bazel_admin/mr5hobvt/external/bazel_tools/tools/build_defs/repo/http.bzl:336:31: in
INFO: Repository bazel_toolchains instantiated at:
no stack (--record_rule_instantiation_callstack not enabled)
Repository rule http_archive defined at:
C:/users/admin/_bazel_admin/mr5hobvt/external/bazel_tools/tools/build_defs/repo/http.bzl:336:31: in
INFO: Reading rc options for 'build' from e:\code\envoy.bazelrc:
'build' options: --workspace_status_command=bash bazel/get_workspace_status --experimental_strict_action_env=true --host_force_python=PY3 --action_env=BAZEL_LINKLIBS=-l%:libstdc++.a --action_env=BAZEL_LINKOPTS=-lm --host_javabase=@bazel_tools//tools/jdk:remote_jdk11 --javabase=@bazel_tools//tools/jdk:remote_jdk11 --enable_platform_specific_config --define absl=1 --action_env=CC --action_env=CXX --action_env=LLVM_CONFIG --action_env=PATH --@com_googlesource_googleurl//build_config:system_icu=0 --test_env=HEAPCHECK=normal --test_env=PPROF_PATH
ERROR: @com_googlesource_googleurl//build_config:system_icu :: Error loading option @com_googlesource_googleurl//build_config:system_icu: no such package '@protodoc_pip3//': pip_import failed: (Python was not found but can be installed from the Microsoft Store: https://go.microsoft.com/fwlink?linkID=2082640)`

image

@WestEnlarged WestEnlarged added the triage Issue requires triage label Sep 19, 2020
@rtttech
Copy link

rtttech commented Sep 20, 2020

I have the same error, windows10

@yanavlasov
Copy link
Contributor

Did you follow this process to set-up your build environment? https://github.com/envoyproxy/envoy/blob/master/bazel/README.md#windows

@envoyproxy/windows-dev

@yanavlasov yanavlasov added area/build area/windows and removed triage Issue requires triage labels Sep 22, 2020
@sunjayBhatia
Copy link
Member

@WestEnlarged @rtttech you will have to Python is installed and on the PATH as described in the linked docs

I would also suggest supplying a target to bazel build e.g. bazel build //source/exe:envoy-static to build the server binary

@WestEnlarged
Copy link
Author

@yanavlasov thank you, i forget the
mklink %USERPROFILE%\Python38\python3.exe %USERPROFILE%\Python38\python.exe

the problem has been solved. but the build still failed. It seems MSVS not support the option '-Zc:__cplusplus' , not sure.

image

i was very confused! then i remove this option, got this:
ERROR: E:/code/envoy/source/extensions/resource_monitors/injected_resource/BUILD:12:17: C++ compilation of rule '//source/extensions/resource_monitors/injected_resource:injected_resource_monitor' failed (Exit 2) bazel-out/x64_windows-opt/bin/include/envoy/common/_virtual_includes/base_includes\envoy/common/platform.h(24): fatal error C1083: Cannot open include file: 'afunix.h': No such file or directory

@sunjayBhatia
Copy link
Member

@WestEnlarged what version of the Windows SDK are you on? You will need a version of Windows that is recent enough to include support for Unix Domain Sockets and an SDK that contains that header, we have tested only with VS 2019 and the associated VS Build Tools standalone installs

@WestEnlarged
Copy link
Author

i installed vs2019 and using windows 10 sdk(10.0.19041.0). Then i follow the instructions (https://github.com/envoyproxy/envoy/blob/master/bazel/README.md#windows) every step, but failed very sadless.
like this:
image

maybe i shoud working without windows. what environment are you using for development? @sunjayBhatia

@davinci26
Copy link
Member

From the error message it looks like the 'ninja' is not in the path.

In my dev environment I have it separately installed and added on the path.

@sunjayBhatia does ninja come with VS build tools 2019 or does it have to be installed separately?

@sunjayBhatia
Copy link
Member

Looks like theres also a path issue in the CMake output there as well: D:\eb\execroot\envoy//D:/tools/...

Ninja comes with VS Build Tools (it is a 32 bit exe so just be aware if you've disabled support for that), just needs to be on your PATH (you can also install it separately if you like but it needs to be on your PATH as described in the setup docs)

@sunjayBhatia
Copy link
Member

what environment are you using for development

I have recently been using a Windows Server 2019 host in GCP, doing builds in the envoyproxy/envoy-build-windows2019 container image

@WestEnlarged
Copy link
Author

yes, it is. but i not know how to generated "crosstool_bazel.cmake", and i'm sure that i put ninja to the path.
it's msys2's convert path issue probably but i not know how to solve it.
On the bazel's doc, they recommend to use cmd or powershell, but envoy's build must need bash. It's confused.

image

@sunjayBhatia
Copy link
Member

can you give us the output of your environment? Seems like some environment variable may be mangled

@WestEnlarged
Copy link
Author

WestEnlarged commented Sep 26, 2020

@sunjayBhatia i'm using win10 professional(10.0.18362)

the environment variables:
C:\Users\admin>env
!::=::
!C:=C:\Users\admin
ALLUSERSPROFILE=C:\ProgramData
APPDATA=C:\Users\admin\AppData\Roaming
BAZEL_SH=D:\msys64\usr\bin\bash.exe
BAZEL_VC=D:\tools\VS2019\Community\VC
CLASSPATH=.;D:\tools\jdk\jdk1.8.0_161\lib\dt.jar;D:\tools\jdk\jdk1.8.0_161\lib\tools.jar;
COMMONPROGRAMFILES=C:\Program Files\Common Files
CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files
CommonProgramW6432=C:\Program Files\Common Files
COMPUTERNAME=DESKTOP-6KJIBN1
COMSPEC=C:\Windows\system32\cmd.exe
DriverData=C:\Windows\System32\Drivers\DriverData
GOPATH=D:\tools\Go
HOMEDRIVE=C:
HOMEPATH=\Users\admin
JAVA_HOME=D:\tools\jdk\jdk1.8.0_161
LESSCHARSET=utf-8
LOCALAPPDATA=C:\Users\admin\AppData\Local
LOGONSERVER=\DESKTOP-6KJIBN1
MSYS2_ARG_CONV_EXCL=*
NUMBER_OF_PROCESSORS=4
OneDrive=C:\Users\admin\OneDrive
OS=Windows_NT
PATH=/c/Program Files (x86)/Common Files/Oracle/Java/javapath:/c/ProgramData/Oracle/Java/javapath:/c/Windows/system32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0:/c/Windows/System32/OpenSSH:/c/Program Files/Git/cmd:/d/tools/jdk/jdk1.8.0_161/bin:/d/tools/jdk/jdk1.8.0_161/jre/bin:/c/Program Files/nodejs:/c/Program Files/JetBrains/IntelliJ IDEA 2019.2/plugins/maven/lib/maven3/bin:/c/Program Files/Docker/Docker/resources/bin:/c/ProgramData/DockerDesktop/version-bin:/d/tools/bazel:/d/tools/VS2019/Community/VC/Tools/MSVC/14.27.29110/bin/Hostx64/x64:/d/tools/Go/bin:/d/tools/Python/Python38:/d/tools/Python/Python38/Scripts:/usr/bin:/d/tools/VS2019/Community/Common7/IDE/CommonExtensions/Microsoft/CMake/CMake/bin:/d/tools/VS2019/Community/Common7/IDE/CommonExtensions/Microsoft/CMake/Ninja:/d/tools/vscode/bin
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC
PROCESSOR_ARCHITECTURE=AMD64
PROCESSOR_IDENTIFIER=Intel64 Family 6 Model 142 Stepping 9, GenuineIntel
PROCESSOR_LEVEL=6
PROCESSOR_REVISION=8e09
ProgramData=C:\ProgramData
PROGRAMFILES=C:\Program Files
ProgramFiles(x86)=C:\Program Files (x86)
ProgramW6432=C:\Program Files
PROMPT=$P$G
PSModulePath=C:\Program Files\WindowsPowerShell\Modules;C:\Windows\system32\WindowsPowerShell\v1.0\Modules
PUBLIC=C:\Users\Public
SESSIONNAME=Console
SYSTEMDRIVE=C:
SYSTEMROOT=C:\Windows
TEMP=/c/Users/admin/AppData/Local/Temp
TMP=/c/Users/admin/AppData/Local/Temp
TMPDIR=/d/tmp
USERDOMAIN=DESKTOP-6KJIBN1
USERDOMAIN_ROAMINGPROFILE=DESKTOP-6KJIBN1
USERNAME=admin
USERPROFILE=C:\Users\admin
WINDIR=C:\Windows
TERM=xterm-256color
HOME=/home/admin

  1. i install msys2, the follows is lanch msys2 and output the variables:

admin@DESKTOP-6KJIBN1 MINGW64 ~ $ env

USERDOMAIN=DESKTOP-6KJIBN1
OS=Windows_NT
COMMONPROGRAMFILES=C:\Program Files\Common Files
PROCESSOR_LEVEL=6
PSModulePath=C:\Program Files\WindowsPowerShell\Modules;C:\Windows\system32\WindowsPowerShell\v1.0\Modules
CommonProgramW6432=C:\Program Files\Common Files
CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files
MSYSCON=mintty.exe
LANG=zh_CN.UTF-8
TZ=Asia/Shanghai
MSYSTEM_CARCH=x86_64
HOSTNAME=DESKTOP-6KJIBN1
PUBLIC=C:\Users\Public
OLDPWD=/
CONFIG_SITE=/mingw64/etc/config.site
WD=D:\msys64\usr\bin
CONTITLE=MinGW x64
MSYSTEM_CHOST=x86_64-w64-mingw32
LOGINSHELL=bash
USERNAME=admin
JAVA_HOME=D:\tools\jdk\jdk1.8.0_161
LOGONSERVER=\DESKTOP-6KJIBN1
PROCESSOR_ARCHITECTURE=AMD64
tmp=C:\Users\admin\AppData\Local\Temp
LOCALAPPDATA=C:\Users\admin\AppData\Local
!D:=D:\msys64
CLASSPATH=.;D:\tools\jdk\jdk1.8.0_161\lib\dt.jar;D:\tools\jdk\jdk1.8.0_161\lib\tools.jar;
COMPUTERNAME=DESKTOP-6KJIBN1
USER=admin
!::=::
SYSTEMDRIVE=C:
USERPROFILE=C:\Users\admin
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC
SYSTEMROOT=C:\Windows
GOPATH=D:\tools\Go
USERDOMAIN_ROAMINGPROFILE=DESKTOP-6KJIBN1
PROCESSOR_IDENTIFIER=Intel64 Family 6 Model 142 Stepping 9, GenuineIntel
MINGW_PACKAGE_PREFIX=mingw-w64-x86_64
PWD=/home/admin
HOME=/home/admin
TMP=/tmp
TERM_PROGRAM=mintty
TERM_PROGRAM_VERSION=3.4.0
MSYSTEM_PREFIX=/mingw64
OneDrive=C:\Users\admin\OneDrive
PROCESSOR_REVISION=8e09
TMPDIR=/d/tmp
PROMPT=$P$G
NUMBER_OF_PROCESSORS=4
ProgramW6432=C:\Program Files
COMSPEC=C:\Windows\system32\cmd.exe
APPDATA=C:\Users\admin\AppData\Roaming
SHELL=/usr/bin/bash
TERM=xterm
WINDIR=C:\Windows
MINGW_CHOST=x86_64-w64-mingw32
ProgramData=C:\ProgramData
SHLVL=1
PRINTER=Hewlett-Packard HP LaserJet Professional M1213nf MFP
ACLOCAL_PATH=/mingw64/share/aclocal:/usr/share/aclocal
PROGRAMFILES=C:\Program Files
BAZEL_VC=D:\tools\VS2019\Community\VC
MANPATH=/mingw64/local/man:/mingw64/share/man:/usr/local/man:/usr/share/man:/usr/man:/share/man
ORIGINAL_TEMP=/c/Users/admin/AppData/Local/Temp
ORIGINAL_TMP=/c/Users/admin/AppData/Local/Temp
ALLUSERSPROFILE=C:\ProgramData
TEMP=/tmp
temp=C:\Users\admin\AppData\Local\Temp
MSYS2_ARG_CONV_EXCL=*
DriverData=C:\Windows\System32\Drivers\DriverData
LESSCHARSET=utf-8
MSYSTEM=MINGW64
MINGW_PREFIX=/mingw64
SESSIONNAME=Console
ProgramFiles(x86)=C:\Program Files (x86)
PATH=/mingw64/bin:/usr/local/bin:/usr/bin:/bin:/d/tools/VS2019/Community/Common7/IDE/CommonExtensions/Microsoft/CMake/CMake/bin:/d/tools/VS2019/Community/Common7/IDE/CommonExtensions/Microsoft/CMake/Ninja:/c/Windows/System32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0/:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl
PS1=[\e]0;\w\a]\n[\e[32m]\u@\h [\e[35m]$MSYSTEM[\e[0m] [\e[33m]\w[\e[0m]\n$
HOMEDRIVE=C:
PKG_CONFIG_PATH=/mingw64/lib/pkgconfig:/mingw64/share/pkgconfig
INFOPATH=/usr/local/info:/usr/share/info:/usr/info:/share/info
HOMEPATH=\Users\admin
ORIGINAL_PATH=/c/Windows/System32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0/
BAZEL_SH=D:\msys64\usr\bin\bash.exe
_=/usr/bin/env

  1. i tested the cmake and ninja working after install vs2019.

  2. and i download the bazel example code to build. it works.

  3. i modify the envoy code .bazelrc , add follows:

startup --output_base=D:/eb startup --output_user_root=D:/tmp startup --windows_enable_symlinks build --enable_runfiles

  1. then run the build command in powershell.

bazel build -c opt //source/exe:envoy-static

can catch the follow issue and preivious issues:

ERROR: D:/code/envoy/source/extensions/filters/listener/tls_inspector/BUILD:15:17: C++ compilation of rule '//source/extensions/filters/listener/tls_inspector:tls_inspector_lib' failed (Exit 2) external/boringssl/src/include\openssl/engine.h(1): error C2220: the following warning is treated as an error external/boringssl/src/include\openssl/engine.h(1): warning C4819: The file contains a character that cannot be represented in the current code page (936). Save the file in Unicode format to prevent data loss external/boringssl/src/include\openssl/crypto.h(1): warning C4819: The file contains a character that cannot be represented in the current code page (936). Save the file in Unicode format to prevent data loss external/boringssl/src/include\openssl/ssl.h(636): warning C4819: The file contains a character that cannot be represented in the current code page (936). Save the file in Unicode format to prevent data loss external/boringssl/src/include\openssl/ssl.h(2928): warning C4819: The file contains a character that cannot be represented in the current code page (936). Save the file in Unicode format to prevent data loss external/boringssl/src/include\openssl/ssl.h(4707): warning C4819: The file contains a character that cannot be represented in the current code page (936). Save the file in Unicode format to prevent data loss Target //source/exe:envoy-static failed to build

if i modify those files encoding. it report preivious path issue. all of this.

@nigriMSFT
Copy link
Contributor

After following the build instructions on a clean install VM, here are my relevant env variables for each shell. Note that when following the build instructions for Windows, you only need to set environment variables in the shell that you want to build in. For me, I invoke bazel in cmd, so I only set up the environment variables in a cmd prompt.

cmd:

BAZEL_SH=C:\Users\Administrator\msys64\usr\bin\bash.exe
BAZEL_VC=C:\Users\Administrator\VSBT2019\VC
BUILDIFIER_BIN=C:\Users\Administrator\go\bin\buildifier
BUILDOZER_BIN=C:\Users\Administrator\go\bin\buildozer
GOPATH=C:\Users\Administrator\go
MSYS2_ARG_CONV_EXCL=*
PATH=/c/Windows/system32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0:/c/Windows/System32/OpenSSH:/c/users/administrator/Git/cmd:/c/users/administrator/Go/bin:/c/Windows/system32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0:/c/Windows/System32/OpenSSH:/c/Users/Administrator/AppData/Local/Microsoft/WindowsApps:/c/Users/Administrator/bazel:/c/Users/Administrator/Python38:/c/Users/Administrator/Python38/Scripts:/c/Users/Administrator/VSBT2019/VC/Tools/MSVC/14.27.29110/bin/Hostx64/x64:/c/Users/Administrator/VSBT2019/Common7/IDE/CommonExtensions/Microsoft/CMake/CMake/bin:/c/Users/Administrator/VSBT2019/Common7/IDE/CommonExtensions/Microsoft/CMake/Ninja:/usr/bin:/c/Users/Administrator/Git/bin:/c/Users/Administrator/go/bin
TMPDIR=/c/Windows/TEMP

msys:

BUILDOZER_BIN=C:\Users\Administrator\go\bin\buildozer
GOPATH=C:\Users\Administrator\go
TMPDIR=/c/Windows/TEMP
BAZEL_VC=C:\Users\Administrator\VSBT2019\VC
MSYS2_ARG_CONV_EXCL=*
PATH=/usr/local/bin:/usr/bin:/bin:/opt/bin:/c/Windows/System32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0/:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl
BAZEL_SH=C:\Users\Administrator\msys64\usr\bin\bash.exe
BUILDIFIER_BIN=C:\Users\Administrator\go\bin\buildifier

I can successfully build the envoy binary using:
bazel build --config=msvc-cl //source/exe:envoy-static

FYI this was done on rsmaster a few weeks ago

@WestEnlarged
Copy link
Author

I retried but faild, and give up windows. Instead of windows, I trail run building in Alpine (WSL).

I run ./ci/run_envoy_docker.sh './ci/do_ci.sh bazel.dev' , and the output like this. Is code of master has problem? or any other tip with me to fix this?

DESKTOP-6KJIBN1:/mnt/d/code/envoy# ./ci/run_envoy_docker.sh './ci/do_ci.sh bazel.dev'
Unable to find image 'envoyproxy/envoy-build-ubuntu:b480535e8423b5fd7c102fd30c92f4785519e33a' locally
b480535e8423b5fd7c102fd30c92f4785519e33a: Pulling from envoyproxy/envoy-build-ubuntu
171857c49d0f: Already exists
419640447d26: Already exists
61e52f862619: Already exists
c1436c379eed: Already exists
478f32722cdd: Already exists
d1ecde92478d: Already exists
e74a8145b4d9: Pull complete
123e397ef204: Pull complete
Digest: sha256:46b862116589db1ea4a2cb00554071c640ee46b00eb7191e0b5f4d3f5a8abb80
Status: Downloaded newer image for envoyproxy/envoy-build-ubuntu:b480535e8423b5fd7c102fd30c92f4785519e33a
No remote cache is set, skipping setup remote cache.
ENVOY_SRCDIR=/source
ENVOY_BUILD_TARGET=//source/exe:envoy-static
ENVOY_BUILD_ARCH=x86_64
2020/10/22 08:00:01 Downloading https://releases.bazel.build/3.6.0/release/bazel-3.6.0-linux-x86_64...
$TEST_TMPDIR defined: output root default is '/build/tmp' and max_idle_secs default is '15'.
Extracting Bazel installation...
Starting local Bazel server and connecting to it...
$TEST_TMPDIR defined: output root default is '/build/tmp' and max_idle_secs default is '15'.
Cloning into '/build/envoy-filter-example'...
remote: Enumerating objects: 74, done.
remote: Counting objects: 100% (74/74), done.
remote: Compressing objects: 100% (56/56), done.
remote: Total 11533 (delta 72), reused 20 (delta 18), pack-reused 11459
Receiving objects: 100% (11533/11533), 1.09 MiB | 295.00 KiB/s, done.
Resolving deltas: 100% (11330/11330), done.
Note: checking out 'bebd0b2422ea7739905f1793565681d7266491e6'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

git checkout -b

HEAD is now at bebd0b2 http: update header get call (#135)
$TEST_TMPDIR defined: output root default is '/build/tmp' and max_idle_secs default is '15'.
building using 4 CPUs
building for x86_64
clang toolchain with libc++ configured
bazel fastbuild build with tests...
Building...
Building...
$TEST_TMPDIR defined: output root default is '/build/tmp' and max_idle_secs default is '15'.
INFO: Repository com_github_grpc_grpc instantiated at:
no stack (--record_rule_instantiation_callstack not enabled)
Repository rule http_archive defined at:
/build/tmp/_bazel_envoybuild/b570b5ccd0454dc9af9f65ab1833764d/external/bazel_tools/tools/build_defs/repo/http.bzl:336:31: in
WARNING: Download from https://github.com/grpc/grpc/archive/d8f4928fa779f6005a7fe55a176bdb373b0f910f.tar.gz failed: class java.io.IOException Tried to reconnect at offset 14,087,636 but server didn't support it
ERROR: An error occurred during the fetch of repository 'com_github_grpc_grpc':
Traceback (most recent call last):
File "/build/tmp/_bazel_envoybuild/b570b5ccd0454dc9af9f65ab1833764d/external/bazel_tools/tools/build_defs/repo/http.bzl", line 111, column 45, in _http_archive_impl
download_info = ctx.download_and_extract(
Error in download_and_extract: java.io.IOException: Error downloading [https://github.com/grpc/grpc/archive/d8f4928fa779f6005a7fe55a176bdb373b0f910f.tar.gz] to /build/tmp/_bazel_envoybuild/b570b5ccd0454dc9af9f65ab1833764d/external/com_github_grpc_grpc/d8f4928fa779f6005a7fe55a176bdb373b0f910f.tar.gz: Tried to reconnect at offset 14,087,636 but server didn't support it
ERROR: Skipping '//source/exe:envoy-static': no such package '@com_github_grpc_grpc//bazel': java.io.IOException: Error downloading [https://github.com/grpc/grpc/archive/d8f4928fa779f6005a7fe55a176bdb373b0f910f.tar.gz] to /build/tmp/_bazel_envoybuild/b570b5ccd0454dc9af9f65ab1833764d/external/com_github_grpc_grpc/d8f4928fa779f6005a7fe55a176bdb373b0f910f.tar.gz: Tried to reconnect at offset 14,087,636 but server didn't support it
WARNING: Target pattern parsing failed.
ERROR: no such package '@com_github_grpc_grpc//bazel': java.io.IOException: Error downloading [https://github.com/grpc/grpc/archive/d8f4928fa779f6005a7fe55a176bdb373b0f910f.tar.gz] to /build/tmp/_bazel_envoybuild/b570b5ccd0454dc9af9f65ab1833764d/external/com_github_grpc_grpc/d8f4928fa779f6005a7fe55a176bdb373b0f910f.tar.gz: Tried to reconnect at offset 14,087,636 but server didn't support it
INFO: Elapsed time: 1335.869s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (0 packages loaded)
currently loading: source/exe

image

@sunjayBhatia
Copy link
Member

that looks like a download error which should be good to retry

just a word of warning, we don't explicitly test building Envoy in WSL, it may work but there is not validation in CI or otherwise

If youre comfortable with developing in containers, see https://github.com/envoyproxy/envoy/tree/master/ci#on-windows for notes on using the Windows container build image

@WestEnlarged
Copy link
Author

@sunjayBhatia yes, i retry sometimes then build success. Thans a lot!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants