Page 1 of 2

errors in building the CEF

Posted: Sat May 17, 2025 11:43 am
by coater
Creating D:\code\chromium_git\chromium\src\out\Release_GN_x64 directory.
ERROR Need exactly one build directory to generate.
I expected something more like "gn gen out/foo"
You can also see "gn help gen".
Traceback (most recent call last):
File "D:\code\chromium_git\chromium\src\cef\tools\gclient_hook.py", line 154, in <module>
RunAction(src_dir, cmd)
File "D:\code\chromium_git\chromium\src\cef\tools\gclient_util.py", line 35, in RunAction
gclient_utils.CheckCallAndFilter(
File "D:\code\depot_tools\gclient_utils.py", line 733, in CheckCallAndFilter
raise subprocess2.CalledProcessError(rv, args, kwargs.get('cwd', None),
subprocess2.CalledProcessError: Command 'gn gen out\\Release_GN_x64 --ide=vs2022 --sln=cef --filters=//cef/* ' returned non-zero exit status 1 in D:\code\chromium_git\chromium\src
ERROR Need exactly one build directory to generate.
I expected something more like "gn gen out/foo"
You can also see "gn help gen".


------------------
set GN_DEFINES=ffmpeg_branding=Chrome proprietary_codecs=true is_official_build=true is_debug=false is_asan=true dcheck_always_on=true
set GN_ARGUMENTS=--ide=vs2022 --sln=cef --filters=//cef/*
call cef_create_projects.bat
--------------------
There is no problem to generate Debug_GN_x64, but when generating Release_GN_x64, this error happen!

Keen for your help, thank you!

Re: errors in building the CEF

Posted: Sat May 17, 2025 12:59 pm
by salvadordf
Hi,

This post mentions a similar error. https://magpcss.org/ceforum/viewtopic.php?f=6&t=17117

I haven't tried to build the binaries recently but if the previous post wasn't helpful then I would try the following :
  • Check that the PC has the right software versions installed. The CEF Wiki says that the Windows 10+ build system requires VS2022 17.13.4, Win 10.0.26100.3323 SDK, Ninja. https://bitbucket.org/chromiumembedded/cef/wiki/BranchesAndBuilding.md
  • Some developers reported problems when the build system had several versions of the SDK or incorrect paths pointing to the wrong SDK, Python compiler, etc.
  • Install all the options from the Windows SDK.
  • Always download the latest depot_tools package before building. https://storage.googleapis.com/chrome-infra/depot_tools.zip
  • Try to build CEF with the official script. https://bitbucket.org/chromiumembedded/cef/wiki/AutomatedBuildSetup.md#markdown-header-windows-configuration

Re: errors in building the CEF

Posted: Sun May 18, 2025 12:34 am
by coater
Win 10.0.26100.3916 SDK
Microsoft Visual Studio Community 2022 (64) 17.14.0
only one version.
latest depot_tools
-------------
I can build the binaries in Debug_GN_x64!
When generating Release_GN_x64 error happened, and cannot build the binaries in Release_GN_x64!

Re: errors in building the CEF

Posted: Sun May 18, 2025 7:47 am
by salvadordf
Report this issue in the official CEF forum.

It seems you're not the only one:
https://magpcss.org/ceforum/viewtopic.php?f=6&t=20284

Re: errors in building the CEF

Posted: Tue May 20, 2025 9:09 am
by coater
set GN_DEFINES=ffmpeg_branding=Chrome proprietary_codecs=true is_official_build=true
set GYP_MSVS_VERSION=2022
set GYP_MSVS_OVERRIDE_PATH=C:\Program Files\Microsoft Visual Studio\2022\Professional
set WINDOWSSDKDIR=C:\Program Files (x86)\Windows Kits\10
set GN_ARGUMENTS=--ide=vs2022 --sln=cef --filters=//cef/*
call cef_create_projects.bat

I have done the building use that!

system language: change to English(unite state)
set :
set GYP_MSVS_OVERRIDE_PATH=C:\Program Files\Microsoft Visual Studio\2022\Professional
set WINDOWSSDKDIR=C:\Program Files (x86)\Windows Kits\10

Thank you very much!

Re: errors in building the CEF

Posted: Tue May 20, 2025 2:48 pm
by coater
Is this correct?

I couldn't find libcef.lib but libcef.dll.lib was found!

Re: errors in building the CEF

Posted: Tue May 20, 2025 3:23 pm
by salvadordf
Please, report this issue in the official CEF forum.
https://magpcss.org/ceforum/

Re: errors in building the CEF

Posted: Wed May 21, 2025 11:25 am
by coater
https://magpcss.org/ceforum/viewtopic.php?t=16444
Maybe it is correct.

Re: errors in building the CEF

Posted: Wed May 21, 2025 1:50 pm
by salvadordf
How much RAM and free hard drive space is in your computer?

The hardware requirements have increased lately and perhaps this is the cause of this problem.

Re: errors in building the CEF

Posted: Thu May 22, 2025 8:31 am
by coater
32.0 GB RAM and 400G free disk space.