1

I'm trying to compile a Windows version of Chromium. I followed the guidelines mentioned here and I'm getting an error at the last part, when running the following command:

gn gen out/Default

After taking a look at the code (in python) causing the error, I noticed this:

for path in env['LIB'].split(';'):
    if os.path.exists(os.path.join(path, 'User32.Lib')):
      vc_lib_um_path = os.path.realpath(path)
      break

then

assert vc_lib_um_path

This line last is causing the error, which makes me think that he problem might be due to the fact that the program can't find "User32.lib". I'm on a Windows 10 (64 bits) system, and I'd like to know if there is an environment variable to be updated so that this library can be found. I'm open to any suggestions.

My path variable:

enter image description here

And the full error message:

   Traceback (most recent call last):
   File "D:/Work/chromium/src/build/toolchain/win/setup_toolchain.py", line 274, in <module>
 main()
    File "D:/Work/chromium/src/build/toolchain/win/setup_toolchain.py", line 269, in main
    assert vc_lib_um_path
    AssertionError
    ERROR at //build/toolchain/win/BUILD.gn:400:22: Script returned non-zero exit code.
    x64_toolchain_data = exec_script("setup_toolchain.py",
                                      ^----------
    Current dir: D:/Work/chromium/src/out/Default/
    Command: D:/Work/depot_tools/win_tools-2_7_6_bin/python/bin/python.exe -- D:/Work/chromium/src/build/toolchain/win/setup_toolchain.py "C:\Program Files (x86)/Microsoft Visual Studio/2017/Community" "C:\Program Files (x86)\Windows Kits\10" "C:\WINDOWS\Sysnative;C:\WINDOWS/SysWOW64" win x64 environment.x64 false
     Returned 1 and printed out:
     vc_bin_dir = "C:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\VC\\Tools\\MSVC\\14.13.26128\\bin\\HostX64\\x64"                                                                                                            include_flags_I = "\"/IC:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\VC\\Tools\\MSVC\\14.13.26128\\ATLMFC\\include\" \"/IC:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\VC\\Tools\\MSVC\\14.13.26128\\include\" \"/IC:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.16299.0\\ucrt\" \"/IC:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.15063.0\\shared\" \"/IC:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.15063.0\\um\" \"/IC:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.15063.0\\winrt\" \"/IC:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.15063.0\\cppwinrt\""                                                                        include_flags_imsvc = "\"-imsvcC:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\VC\\Tools\\MSVC\\14.13.26128\\ATLMFC\\include\" \"-imsvcC:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\VC\\Tools\\MSVC\\14.13.26128\\include\" \"-imsvcC:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.16299.0\\ucrt\" \"-imsvcC:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.15063.0\\shared\" \"-imsvcC:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.15063.0\\um\" \"-imsvcC:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.15063.0\\winrt\" \"-imsvcC:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.15063.0\\cppwinrt\""                                        vc_lib_path = "C:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\VC\\Tools\\MSVC\\14.13.26128\\lib\\x64"                                                                                                                    vc_lib_atlmfc_path = "C:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\VC\\Tools\\MSVC\\14.13.26128\\ATLMFC\\lib\\x64"

    See //BUILD.gn:60:1: which caused the file to be included.
     group("gn_all") {
     ^----------------
     Traceback (most recent call last):
     File "D:/Work/chromium/src/build/toolchain/win/setup_toolchain.py", line 274, in <module>
     main()
     File "D:/Work/chromium/src/build/toolchain/win/setup_toolchain.py", line 269, in main
     assert vc_lib_um_path
     AssertionError
     Traceback (most recent call last):
     File "D:/Work/chromium/src/build/toolchain/win/setup_toolchain.py", line 274, in <module>
     main()
     File "D:/Work/chromium/src/build/toolchain/win/setup_toolchain.py", line 269, in main
     assert vc_lib_um_path
     AssertionError                                                                                             

Thanks

0

1 Answer 1

5

I'm on a Windows 10 (64 bits) system, and I'd like to know if there is an environment variable to be updated so that this library can be found. I'm open to any suggestions.

As per the build instructions you must install the 10.0.15063 Windows 10 SDK.

You must have the version 10.0.15063 Windows 10 SDK installed. This can be installed separately or by checking the appropriate box in the Visual Studio Installer. The SDK Debugging Tools must also be installed. If the Windows 10 SDK was installed via the Visual Studio installer, then they can be installed by going to: Control Panel → Programs → Programs and Features → Select the “Windows Software Development Kit” → Change → Change → Check “Debugging Tools For Windows” → Change. Or, you can download the standalone SDK installer and use it to install the Debugging Tools.

Source

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .