Build Failure using "autoninja"

403 views
Skip to first unread message

Avi Mathur

unread,
Feb 13, 2023, 1:00:15 PM2/13/23
to Chromium-dev
Hi everyone, 
I have been trying to build Chromium on Windows 10, using the documentation given here, https://chromium.googlesource.com/chromium/src/+/master/docs/windows_build_instructions.md#System-requirements.
Specifically after passing the command 'autoninja -C out\Default chrome', I am getting a build failure, and particularly a 'fatal error' that 'atldef.h' file not found. I am not sure why that error persists, as I am running the command on cmd as an administrator at the same path that is specified in the documentation, ran the 'gclient sync' command in case there's anything I missed, and made sure I follow the command steps for improving build speeds. 
I am attaching the screenshots of the particular build error that I had explained above. May somebody please help me with this error, thanks in advance. 

Regards 
Avi Mathur
build-error1.png
build-error2.png

Bruce Dawson

unread,
Feb 13, 2023, 9:22:54 PM2/13/23
to Chromium-dev, Avi Mathur
When sharing build output it is much better to share it as text rather than screenshots. Text is much more compact, and is searchable.

As to your error, on my machine atldef.h is found in c:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.34.31933\atlmfc\include. The exact location will depend on the Visual Studio version you have installed, but my guess is that you missed the Microsoft.VisualStudio.Component.VC.ATLMFC component listed in the instructions. This is the recommended command line for installing Visual Studio:

PATH_TO_INSTALLER.EXE ^
--add Microsoft.VisualStudio.Workload.NativeDesktop ^
--add Microsoft.VisualStudio.Component.VC.ATLMFC ^
--includeRecommended

BTW, you don't need to run the build process as administrator. You need admin privileges for some install steps (installing Visual Studio and the SDK) but after that you generally don't, and it is safer to not run as admin. However this is unrelated to your build problems.

Avi Mathur

unread,
Feb 16, 2023, 1:52:39 PM2/16/23
to Chromium-dev, Bruce Dawson, Avi Mathur
Hi, 

Yeah I will make sure to share the text as text, form next time rather than sending a screenshot, that's my bad.

I didn't run those initial commands for getting the atlmfc file, I ran them now, and I have gotten all the necessary header files in the same location as you had specified earlier.  

Oh okay, yeah I'll take care of not using administrator all the time, thanks a lot for the suggestion. 

Reply all
Reply to author
Forward
0 new messages