onboarding question

57 views
Skip to first unread message

Ryan Guilbault

unread,
Aug 8, 2025, 9:16:47 AMAug 8
to Chromium-dev
I'm trying to follow the documentation to build chrome on Windows:


I am electing to NOT let depot_tools install/configure visual studio, because I have particular constraints required for my day job and my need to build chrome is limited to prototyping a fix/feature for native messaging, therefore I don't want to destabilize my everyday development just for this. and the docs say I don't have to yield to Google's toolchain.

however, I cannot figure out how to get myself past two flavors of errors:

exhibit A:

>autoninja -C out\Default chrome
offline mode
ninja: Entering directory `out\Default'
 2.22s load siso config
 1.36s load build.ninja
[84/72428] 37.45s F CC obj/third_party/nasm/nasm/regdis.obj
stdout:
Unknown clang plugin argument: raw-ref-template-as-trivial-member

[84/72428] 37.45s F CC obj/third_party/nasm/nasm/insnsn.obj
stdout:
Unknown clang plugin argument: raw-ref-template-as-trivial-member

-- I am ASSUMING that this is maybe ok/acceptable noise. more warning than error.

exhibit B:

[1391/71489] 2m04.00s F CXX obj/third_party/abseil-cpp/absl/synchronization/synchronization/pthread_waiter.obj
FAILED: 3f7abf3d-57bf-4345-8fc2-2d2720cca0d5 "./obj/third_party/abseil-cpp/absl/synchronization/synchronization/pthread_waiter.obj" CXX obj/third_party/abseil-cpp/absl/synchronization/synchronization/pthread_waiter.obj
err: exit=1
..\..\third_party\llvm-build\Release+Asserts\bin\clang-cl.exe /c ../../third_party/abseil-cpp/absl/synchronization/internal/pthread_waiter.cc /Foobj/third_party/abseil-cpp/absl/synchronization/synchronization/pthread_waiter.obj /nologo /showIncludes:user "-imsvc../../../../../../../../Program Files/Microsoft Visual Studio/2022/Professional/VC/Tools/MSVC/14.44.35207/include" "-imsvc../../../../../../../../Program Files/Microsoft Visual Studio/2022/Professional/VC/Tools/MSVC/14.44.35207/ATLMFC/include" "-imsvc../../../../../../../../Program Files/Microsoft Visual Studio/2022/Professional/VC/Auxiliary/VS/include" "-imsvc../../../../../../../../Program Files (x86)/Windows Kits/10/include/10.0.26100.0/ucrt" "-imsvc../../../../../../../../Program Files (x86)/Windows Kits/10/include/10.0.26100.0/um" "-imsvc../../../../../../../../Program Files (x86)/Windows Kits/10/include/10.0.26100.0/shared" "-imsvc../../../../../../../../Program Files (x86)/Windows Kits/10/include/10.0.26100.0/winrt" "-imsvc../../../../../../../../Program Files (x86)/Windows Kits/10/include/10.0.26100.0/cppwinrt" "-imsvc../../../../../../../../Program Files (x86)/Windows Kits/NETFXSDK/4.8/include/um" -DABSL_BUILD_DLL "-DCR_CLANG_REVISION=\"llvmorg-21-init-16348-gbd809ffb-17\"" -D_LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_EXTENSIVE -DCOMPONENT_BUILD -D_LIBCPP_INSTRUMENTED_WITH_ASAN=0 -DCR_LIBCXX_REVISION=6f8fe913d64254ab2231e0e98d2b6b5650ef4917 -D__STD_C -D_CRT_RAND_S -D_CRT_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_DEPRECATE -D_ATL_NO_OPENGL -D_WINDOWS -DCERT_CHAIN_PARA_HAS_EXTRA_FIELDS -DPSAPI_VERSION=2 -DWIN32 -D_SECURE_ATL -DWINAPI_FAMILY=WINAPI_FAMILY_DESKTOP_APP -DDCHECK_ALWAYS_ON=1 -DUSE_AURA=1 -DWIN32_LEAN_AND_MEAN -DNOMINMAX -D_UNICODE -DUNICODE -DNTDDI_VERSION=NTDDI_WIN11_GE -D_WIN32_WINNT=0x0A00 -DWINVER=0x0A00 -D_DEBUG -DDYNAMIC_ANNOTATIONS_ENABLED=1 -D_CRT_NONSTDC_NO_WARNINGS -D_WINSOCK_DEPRECATED_NO_WARNINGS -DABSL_ALLOCATOR_NOTHROW=1 -I../.. -Igen -I../../buildtools/third_party/libc++ -I../../third_party/abseil-cpp -fno-delete-null-pointer-checks /clang:-fno-strict-overflow -fno-ident /clang:-fno-math-errno -fcolor-diagnostics -fmerge-all-constants /Zc:sizedDealloc- -fcrash-diagnostics-dir=../../tools/clang/crashreports -mllvm -instcombine-lower-dbg-declare=0 -mllvm -split-threshold-for-reg-with-hint=0 /clang:-ffp-contract=off -fcomplete-member-pointers /Gy /FS /bigobj /utf-8 /Zc:twoPhase -ffile-reproducible /D__WRL_ENABLE_FUNCTION_STATICS__ -fmsc-version=1934 /Zc:dllexportInlines- -m64 -msse3 /Brepro -Wno-builtin-macro-redefined -D__DATE__= -D__TIME__= -D__TIMESTAMP__= -ffile-compilation-dir=. -no-canonical-prefixes --warning-suppression-mappings=../../build/config/warning_suppression.txt -ftrivial-auto-var-init=pattern /Od /Ob0 /GF /Z7 -gno-codeview-command-line -mllvm -pick-merged-source-locations -gcodeview-ghash -Xclang -fuse-ctor-homing /guard:cf,nochecks /MDd -Wheader-hygiene -Wstring-conversion -Wtautological-overlap-compare -Xclang -add-plugin -Xclang find-bad-constructs -Xclang -plugin-arg-find-bad-constructs -Xclang raw-ref-template-as-trivial-member -Xclang -plugin-arg-find-bad-constructs -Xclang raw-span-template-as-trivial-member -Xclang -plugin-arg-find-bad-constructs -Xclang check-stack-allocated -Xclang -add-plugin -Xclang raw-ptr-plugin -Xclang -plugin-arg-raw-ptr-plugin -Xclang check-raw-ptr-to-stack-allocated -Xclang -plugin-arg-raw-ptr-plugin -Xclang disable-check-raw-ptr-to-stack-allocated-error -Xclang -plugin-arg-raw-ptr-plugin -Xclang raw-ptr-exclude-path=../../third_party/dawn/ -Xclang -plugin-arg-raw-ptr-plugin -Xclang raw-ptr-exclude-path=../../build/config/clang/chrome/test/fuzzing/webidl_fuzzing/ -Xclang -plugin-arg-raw-ptr-plugin -Xclang check-raw-ptr-fields -Xclang -plugin-arg-raw-ptr-plugin -Xclang check-span-fields -Xclang -plugin-arg-raw-ptr-plugin -Xclang check-raw-ref-fields /W3 /wd4800 /wd4267 -Wno-unused-variable -Wno-c++11-narrowing -Wno-unused-but-set-variable -Wno-missing-field-initializers -Wno-unused-parameter -Wno-psabi -Wloop-analysis -Wno-unneeded-internal-declaration -Wno-cast-function-type -Wno-thread-safety-reference-return -Wno-nontrivial-memcall -Wno-nonportable-include-path /WX -Wno-exit-time-destructors -Wimplicit-int-conversion -Wshorten-64-to-32 -Wsign-compare -Wsign-conversion -Wtautological-unsigned-zero-compare /TP /std:c++20 -Wno-trigraphs /GR- -I../../third_party/libc++/src/include -Wno-invalid-offsetof -Wenum-compare-conditional -Wno-nullability-completeness -Wbool-conversion -Wconstant-conversion -Wenum-conversion -Wint-conversion -Wliteral-conversion -Wnon-literal-null-conversion -Wnull-conversion -Wobjc-literal-conversion -Wstring-conversion -Wbitfield-enum-conversion  /Fd"obj/third_party/abseil-cpp/absl/synchronization/synchronization_cc.pdb"
build step: cxx "./obj/third_party/abseil-cpp/absl/synchronization/synchronization/pthread_waiter.obj"
stderr:
clang-cl: error: no such file or directory: '"-imsvc../../../../../../../../Program'
clang-cl: error: no such file or directory: 'Files/Microsoft'
clang-cl: error: no such file or directory: 'Visual'
clang-cl: error: no such file or directory: 'Studio/2022/Professional/VC/Tools/MSVC/14.44.35207/include"'
clang-cl: error: no such file or directory: '"-imsvc../../../../../../../../Program'
clang-cl: error: no such file or directory: 'Files/Microsoft'
clang-cl: error: no such file or directory: 'Visual'
clang-cl: error: no such file or directory: 'Studio/2022/Professional/VC/Tools/MSVC/14.44.35207/ATLMFC/include"'
clang-cl: error: no such file or directory: '"-imsvc../../../../../../../../Program'
clang-cl: error: no such file or directory: 'Files/Microsoft'
clang-cl: error: no such file or directory: 'Visual'
clang-cl: error: no such file or directory: 'Studio/2022/Professional/VC/Auxiliary/VS/include"'
clang-cl: error: no such file or directory: '"-imsvc../../../../../../../../Program'
clang-cl: error: no such file or directory: 'Files'
clang-cl: error: no such file or directory: '(x86)/Windows'
clang-cl: error: no such file or directory: 'Kits/10/include/10.0.26100.0/ucrt"'
clang-cl: error: no such file or directory: '"-imsvc../../../../../../../../Program'
clang-cl: error: no such file or directory: 'Files'
clang-cl: error: no such file or directory: '(x86)/Windows'
clang-cl: error: no such file or directory: 'Kits/10/include/10.0.26100.0/um"'
clang-cl: error: no such file or directory: '"-imsvc../../../../../../../../Program'
clang-cl: error: no such file or directory: 'Files'
clang-cl: error: no such file or directory: '(x86)/Windows'
clang-cl: error: no such file or directory: 'Kits/10/include/10.0.26100.0/shared"'
clang-cl: error: no such file or directory: '"-imsvc../../../../../../../../Program'
clang-cl: error: no such file or directory: 'Files'
clang-cl: error: no such file or directory: '(x86)/Windows'
clang-cl: error: no such file or directory: 'Kits/10/include/10.0.26100.0/winrt"'
clang-cl: error: no such file or directory: '"-imsvc../../../../../../../../Program'
clang-cl: error: no such file or directory: 'Files'
clang-cl: error: no such file or directory: '(x86)/Windows'
clang-cl: error: no such file or directory: 'Kits/10/include/10.0.26100.0/cppwinrt"'
clang-cl: error: no such file or directory: '"-imsvc../../../../../../../../Program'
clang-cl: error: no such file or directory: 'Files'
clang-cl: error: no such file or directory: '(x86)/Windows'
clang-cl: error: no such file or directory: 'Kits/NETFXSDK/4.8/include/um"'
clang-cl: error: no such file or directory: '"-DCR_CLANG_REVISION=\"llvmorg-21-init-16348-gbd809ffb-17\""'

-- this error is more catastrophic, because it fails the build and I'm just stuck. the error FEELS like it is a quoting problem with the -imsvc parameter such that the Program Files path for my VS install is causing problems. I used the default visual studio options when initially installing...I'm hoping that I don't need to reinstall it in a non-space directory to get past this, but everything else that I have tried so far is not helping me advance and I'm not finding any reports of this in this forum thus far...

any assistance would be most welcomed.

some context to help the tier1 troubleshooting:

1. >echo %DEPOT_TOOLS_WIN_TOOLCHAIN%
0

2. >echo %PATH%
C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.44.35207\bin\HostX64\x64;C:\Program Files\Microsoft Visual Studio\2022\Professional\Common7\IDE\VC\VCPackages;C:\Program Files\Microsoft Visual Studio\2022\Professional\Common7\IDE\CommonExtensions\Microsoft\TestWindow;C:\Program Files\Microsoft Visual Studio\2022\Professional\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer;C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Current\bin\Roslyn;C:\Program Files (x86)\Microsoft Visual Studio\Shared\Common\VSPerfCollectionTools\vs2019\\x64;C:\Program Files (x86)\Microsoft Visual Studio\Shared\Common\VSPerfCollectionTools\vs2019\;C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.8 Tools\x64\;C:\Program Files (x86)\HTML Help Workshop;C:\Program Files\Microsoft Visual Studio\2022\Professional\Team Tools\DiagnosticsHub\Collector;C:\Program Files (x86)\Windows Kits\10\bin\10.0.26100.0\\x64;C:\Program Files (x86)\Windows Kits\10\bin\\x64;C:\Program Files\Microsoft Visual Studio\2022\Professional\\MSBuild\Current\Bin\amd64;C:\Windows\Microsoft.NET\Framework64\v4.0.30319;C:\Program Files\Microsoft Visual Studio\2022\Professional\Common7\IDE\;C:\Program Files\Microsoft Visual Studio\2022\Professional\Common7\Tools\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files (x86)\MEDITECH\ubu\;C:\Program Files\dotnet\;C:\tools;C:\Program Files (x86)\Google\Cloud SDK\google-cloud-sdk\bin;C:\Program Files\Git\cmd;C:\Program Files\Tesseract-OCR;C:\Program Files (x86)\Windows Kits\10\Windows Performance Toolkit\;C:\Program Files (x86)\Orca;C:\Program Files\doxygen\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit\;C:\Program Files\TortoiseSVN\bin;C:\Program Files\Beyond Compare 4;C:\Program Files\TortoiseGit\bin;C:\Program Files\nodejs\;C:\Users\rguilbault\Documents\Projects\depot_tools;C:\Users\rguilbault\AppData\Local\Programs\Python\Python311\Scripts\;C:\Users\rguilbault\AppData\Local\Programs\Python\Python311\;C:\Users\rguilbault\AppData\Local\Microsoft\WindowsApps;C:\Users\rguilbault\AppData\Local\Programs\Microsoft VS Code\bin;C:\Users\rguilbault\.dotnet\tools;C:\Users\rguilbault\AppData\Local\Microsoft\WindowsApps;C:\Users\rguilbault\AppData\Roaming\npm;;C:\Program Files\Microsoft Visual Studio\2022\Professional\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin;C:\Program Files\Microsoft Visual Studio\2022\Professional\Common7\IDE\CommonExtensions\Microsoft\CMake\Ninja;C:\Program Files\Microsoft Visual Studio\2022\Professional\Common7\IDE\VC\Linux\bin\ConnectionManagerExe;C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\vcpkg

3. >echo %vs2022_install%
C:\Program Files\Microsoft Visual Studio\2022\Professional

4. I did not install/update python, i.e. I have what I have/need for other purposes. 

5. I did add the ATL/MFC items in visual studio. 

6. I enabled most of the git global settings (though that should be irrelevant at this point of the workflow).

7. I am running the Visual Studio 2022 Command Prompt shortcut that dumps me into cmd.exe with all the visual studio environment variables setup.

I appreciate the time and consideration.

 https://www.facebook.com/MeditechEHR  https://twitter.com/MEDITECH  https://www.youtube.com/@MEDITECHvideo  https://www.threads.net/@meditechehr  https://www.linkedin.com/company/meditech  https://instagram.com/meditechehr
Subscribe to receive emails from MEDITECH or to change email preferences.

Ryan Guilbault

unread,
Aug 8, 2025, 11:35:36 AMAug 8
to Liviu Laslau, Chromium-dev
re: "Follow the steps and run the visual studio installer and click the required workloads as instructed." -- can you please be more specific? if you mean:

"Chromium requires Visual Studio 2022 (>=17.0.0) to build. Visual Studio can also be used to debug Chromium. The clang-cl compiler is used but Visual Studio's header files, libraries, and some tools are required. Visual Studio Community Edition should work if its license is appropriate for you. You must install the “Desktop development with C++” component and the “MFC/ATL support” sub-components."

that is not the problem. I added the addition MFC/ATL recommendations, but otherwise I already had/have Visual Studio setup to build native C++ applications.

the advice I followed that avoids Google's internal version of Visual Studio is from here:

"Also, add a DEPOT_TOOLS_WIN_TOOLCHAIN environment variable in the same way, and set it to 0. This tells depot_tools to use your locally installed version of Visual Studio (by default, depot_tools will try to use a google-internal version)."

i.e. I defined DEPOT_TOOLS_WIN_TOOLCHAIN as 0.

re: "verify gn args out/your_out_config works." -- I don't know how to verify that it works. it doesn't produce any obvious errors. I managed to get through 1391 files that, seemingly, compiled ok (if exhibit A is something I can ignore), so I don't BELIEVE my setup is total trash. it just seems that certain things might not be available and/or something about the orchestration is not creating the arguments well, when they have spaces.


On Fri, Aug 8, 2025 at 10:58 AM Liviu Laslau <liviu....@avast.com> wrote:
Follow the steps and run the visual studio installer and click the required workloads as instructed.
Even if you use it for other work, it will just add few more workloads, it won't corrupt anything, just adds libs.

separately download the windows sdk version as indicated (or it's already installed with visual studio, in control panel it will appear and you can click Change instead of uninstall)
Checkmark the debuggers, all of them.

setup your PATH so depot_tools/autoninja.bat is in your path, python3.bat is in your path.
Can be a .cmd or .bat file, no need to make the changes permanent PATH.

verify gclient works standalong.
gclient sync
verify gn args out/your_out_config works.

Liviu Laslau

unread,
Aug 8, 2025, 4:00:31 PMAug 8
to Chromium-dev, Ryan Guilbault
Follow the steps and run the visual studio installer and click the required workloads as instructed.
Even if you use it for other work, it will just add few more workloads, it won't corrupt anything, just adds libs.

separately download the windows sdk version as indicated (or it's already installed with visual studio, in control panel it will appear and you can click Change instead of uninstall)
Checkmark the debuggers, all of them.

setup your PATH so depot_tools/autoninja.bat is in your path, python3.bat is in your path.
Can be a .cmd or .bat file, no need to make the changes permanent PATH.

verify gclient works standalong.
gclient sync
verify gn args out/your_out_config works.

On Friday, August 8, 2025 at 4:16:47 PM UTC+3 Ryan Guilbault wrote:

Liviu Laslau

unread,
Aug 11, 2025, 6:43:29 AMAug 11
to Chromium-dev, Ryan Guilbault, Chromium-dev, Liviu Laslau
You are missing visual studio ATL and  the windows SDK part of the instructions.
Try to modify visual and make sure all the revelevant checks are made.
Also re-install windows sdk not from visual but from download page.

Reply all
Reply to author
Forward
0 new messages