-
Notifications
You must be signed in to change notification settings - Fork 18
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 fails in patching on Windows #24
Comments
Maybe got a bit further, but still failling
|
I tried to reproduce this on my machine, but I've so far not been able to hit an error in applying the patch. Also, I just wanted to comment on:
The |
I have reproduced the patch crash building with mysys2/mingw64. Pasting Dockerfile for reference: FROM mcr.microsoft.com/windows/servercore:ltsc2022
RUN reg add HKLM\SYSTEM\CurrentControlSet\Control\FileSystem /v LongPathsEnabled /t REG_DWORD /d 1 /f
RUN powershell `
Set-ExecutionPolicy Bypass -Scope Process -Force; `
[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; `
iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1'))
# Required for building the Goma client.
RUN choco install -y visualstudio2019buildtools `
&& choco install -y visualstudio2019-workload-vctools --params "--no-includeRecommended --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.Component.Windows10SDK.20348" `
&& "C:\ProgramData\Package Cache\{63ca8fb0-603f-4442-aa8b-48659a9338f5}\winsdksetup.exe" /features OptionId.WindowsDesktopDebuggers /q /norestart
RUN choco install -y git `
&& "C:\Program Files\Git\cmd\git.exe" config --system core.autocrlf false `
&& "C:\Program Files\Git\cmd\git.exe" config --system core.longpaths true
RUN choco install -y bazelisk
RUN choco install -y python3
RUN choco install -y msys2 && del /f /s /q "C:\$Recycle.Bin" `
&& C:\tools\msys64\usr\bin\bash.exe -lc "pacman -S --noconfirm base-devel mingw-w64-x86_64-gcc" `
&& setx /M PATH "C:\tools\msys64\usr\bin;%PATH%;C:\tools\msys64\mingw64\bin"
# HACK: Copy the MINGW64 DLLs to the Windows system directory. This is required
# for the Protobuf compiler to work, since it uses the MINGW64 toolchain.
RUN cd /d C:\tools\msys64\mingw64\bin `
&& copy libwinpthread-1.dll C:\Windows\System32\ `
&& copy "libstdc++-6.dll" C:\Windows\System32\ `
&& copy libgcc_s_seh-1.dll C:\Windows\System32\ looking into it. @gkousik is there a reference windows build that you would be willing to share? |
full traceback: ERROR: An error occurred during the fetch of repository 'io_opencensus_go_contrib_exporter_stackdriver':
Traceback (most recent call last):
File "C:/users/t-danielsu/_bazel_t-danielsu/sd2lufjt/external/bazel_gazelle/internal/go_repository.bzl", line 311, column 10, in _go_repository_impl
patch(ctx)
File "C:/users/t-danielsu/_bazel_t-danielsu/sd2lufjt/external/bazel_gazelle/internal/go_repository.bzl", line 563, column 17, in patch
fail("Error applying patch %s:\n%s%s" %
Error in fail: Error applying patch @//third_party/patches/opencensus-go-exporter-stackdriver:opencensus-stackdriver-interval.patch:
<3>WSL (549) ERROR: CreateProcessEntryCommon:505: execvpe /bin/bash failed 2
<3>WSL (549) ERROR: CreateProcessEntryCommon:508: Create process not expected to return
ERROR: C:/src/reclient/WORKSPACE:372:14: fetching go_repository rule //external:io_opencensus_go_contrib_exporter_stackdriver: Traceback (most recent call last):
File "C:/users/t-danielsu/_bazel_t-danielsu/sd2lufjt/external/bazel_gazelle/internal/go_repository.bzl", line 311, column 10, in _go_repository_impl
patch(ctx)
File "C:/users/t-danielsu/_bazel_t-danielsu/sd2lufjt/external/bazel_gazelle/internal/go_repository.bzl", line 563, column 17, in patch
fail("Error applying patch %s:\n%s%s" %
Error in fail: Error applying patch @//third_party/patches/opencensus-go-exporter-stackdriver:opencensus-stackdriver-interval.patch:
<3>WSL (549) ERROR: CreateProcessEntryCommon:505: execvpe /bin/bash failed 2
<3>WSL (549) ERROR: CreateProcessEntryCommon:508: Create process not expected to return
ERROR: C:/src/reclient/internal/pkg/monitoring/BUILD.bazel:3:11: //internal/pkg/monitoring:monitoring depends on @io_opencensus_go_contrib_exporter_stackdriver//:stackdriver in repository @io_opencensus_go_contrib_exporter_stackdriver which failed to fetch. no such package '@io_opencensus_go_contrib_exporter_stackdriver//': Error applying patch @//third_party/patches/opencensus-go-exporter-stackdriver:opencensus-stackdriver-interval.patch:
<3>WSL (549) ERROR: CreateProcessEntryCommon:505: execvpe /bin/bash failed 2
<3>WSL (549) ERROR: CreateProcessEntryCommon:508: Create process not expected to return |
@kschzt did you ever find a resolution? |
Building with bazelisk on Windows 11 in git bash. This is after installing GNU
patch
and hardcoding the Python3 path:The text was updated successfully, but these errors were encountered: