windows build appears broken
See original GitHub issueHard to say if it’s the same underlying issue but https://github.com/electron/build-tools/issues/261 is still broken for me.
I’m using the following docker config (note I don’t think this has anything to do with docker…it’s just what i’m using):
FROM mcr.microsoft.com/windows:2004
ENV chocolateyUseWindowsCompression false
RUN powershell -Command Set-ExecutionPolicy Unrestricted -Force
RUN powershell -Command \
iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1')); \
choco feature disable --name showDownloadProgress
RUN choco install -y -d --accept-license git
RUN git config --system core.longpaths true
RUN choco install -y -d --accept-license nodejs
RUN choco install -y -d --accept-license vim
# chrome build needs python2...eww
RUN choco install -y -d --accept-license python2
RUN pip install pywin32
RUN pip install crcmod
# https://chromium.googlesource.com/chromium/src/+/master/docs/windows_build_instructions.md#visual-studio
RUN choco install -y -d --accept-license visualstudio2019community \
--package-parameters \
"--add Microsoft.VisualStudio.Workload.NativeDesktop --add Microsoft.VisualStudio.Component.VC.ATLMFC --includeRecommended --passive"
# https://github.com/electron/build-tools
RUN npm install --global yarn
RUN npm i -g @electron/build-tools
# Setup required git settings for electron build tools
# If you don't set these the e init will fail
RUN git config --global core.filemode false
RUN git config --global core.autocrlf false
RUN git config --global branch.autosetuprebase always
RUN e init --root=C:/electron release
RUN e sync -vvvv
CMD [ "cmd" ]
FYI I need to increase the default vm size because 20GB isn’t enough. I did this through editing "C:\ProgramData\Docker\config\daemon.json"
to:
{
"registry-mirrors": [],
"insecure-registries": [],
"debug": false,
"experimental": false,
"storage-opts": [
"size=60GB"
]
}
and restarting docker.
Then you have to build with a larger memory because the default isn’t enough.
docker build --memory 8g electron_builid_win .
After that, run the container:
docker run --memory 8g -it electron_builder_win
And try to build:
e build electron:dist
and get:
Writing new goma.gn file C:\Users\ContainerAdministrator\.electron_build_tools\third_party\goma.gn
Downloading "https://electron-build-tools.s3-us-west-2.amazonaws.com/build-dependencies/064e0beb3c11b82b66ae4b4959e6c0cdaa2116d77c50841e4a213d4f4fb1aeaf/goma-win.zip" into C:\Users\ContainerAdministrator\.electron_build_tools\third_party\goma-win.zip
[=======================================================================================================================================================================================================] 9266800/bps 100% 0.0s
Running "goma_ctl.py ensure_start" in C:\Users\ContainerAdministrator\.electron_build_tools\third_party\goma
ERROR Error: Command failed: C:\Windows\system32\cmd.exe /d /s /c "vpython goma_ctl.py ensure_start"
'vpython' is not recognized as an internal or external command,
operable program or batch file.
at checkExecSyncError (node:child_process:690:11)
at Object.execFileSync (node:child_process:709:15)
at Object.ensureGomaStart [as ensure] (C:\Users\ContainerAdministrator\.electron_build_tools\src\utils\goma.js:175:16)
at runNinja (C:\Users\ContainerAdministrator\.electron_build_tools\src\e-build.js:60:10)
at Object.<anonymous> (C:\Users\ContainerAdministrator\.electron_build_tools\src\e-build.js:133:3)
at Module._compile (node:internal/modules/cjs/loader:1092:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1121:10)
at Module.load (node:internal/modules/cjs/loader:972:32)
at Function.Module._load (node:internal/modules/cjs/loader:813:14)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:76:12)
Issue Analytics
- State:
- Created 3 years ago
- Comments:7 (3 by maintainers)
Top Results From Across the Web
Windows Update broken after trying to update to Build 22494 ...
Windows Update shows up this once I've tried to update to Build 22494(Dev Channel). It says: "A problem has occurred.
Read more >Windows 10 clients not showing correct OS build after ...
The only way I've found to resolve is to unistall the CU and then reinstall. This is extremely disruptive to the users and...
Read more >Task Manager broken after latest upgrade
This morning I updated to W11 build 22621.900 (KB5020044). First off, task manager still has no search feature, but a bigger issue is...
Read more >Windows 10 Automatic Repair failure. Windows broken.
I installed it and windows booted as normal. I checked task manager and saw it only was showing 4 cores and threads when...
Read more >Resolved issues in Windows 10, version 21H2 | Microsoft Learn
After installing updates released November 2022, you might have Kerberos authentication issues. OS Build 19044.2251. KB5019959 2022-11-08, Resolved, 2022-11-18
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
ok - that workaround get’s me past that problem…then in the build I hit:
../../buildtools/third_party/libc++/trunk/include\__config(297,14): fatal error: 'winapifamily.h' file not found
and#include <windows.h>
winapifamily.h is definitely in multiple places.
I’m not using goma I don’t think. I did:
At this point i’m a bit more interested in having
e build electron:dist
properly then just working around the problem. Unless investigating the workaround helps narrow down the required fix.