Skip to content

dbghelp.dll not found #169587

Open
Open
@BrainRayChristensen

Description

@BrainRayChristensen

Steps to reproduce

  1. Get an arm x64 windows tablet (I'm assuming something about this configuration is what caused the issue)
  2. Set it up to build the flutter engine following the instructions from Setting up the Engine development environment and Compiling the engine including adding the debugging tools from here
  3. Run the command python .\flutter\tools\gn --unoptimized

Actual results

I'm trying to set up building the flutter engine on an x64 arm windows tablet, but encountered the error after installing the "Debugging Tools for Windows" feature from the Windows 10 SDK and running python3 .\flutter\tools\gn --unoptimized.

Exception: dbghelp.dll not found in "C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\dbghelp.dll"
You must install the "Debugging Tools for Windows" feature from the Windows 10 SDK.

I downloaded the debugging tools for windows 10 from the link in the docs for Compiling the engine but it only ended up installing files into my C:\Program Files (x86)\Windows Kits\10\Debuggers\x86 folder and not my x64 folder, and the error is getting thrown because its looking for the dbghelp.dll in the x64 folder. I found dbghelp.dll in my C:\\Windows\System32 folder and copied it over to my C:\Program Files (x86)\Windows Kits\10\Debuggers\x64 folder, as well as dbgcore.dll, and was able to get it to run, but I'm not 100% confident those are the right steps. If they are, it would be useful to include that in the docs for both pages listed previously. Something like the following:

Windows 10 SDK (required for non-Googlers only). Be sure to install the "Debugging Tools for Windows" feature. If the installer does not install dbghelp.dll and dbgcore.dll toC:\Program Files (x86)\Windows Kits\10\Debuggers\x64\ you'll need to copy those files over from C:\\Windows\System32

Note: You may also have to run msiexec /i "C:\Program Files (x86)\Windows Kits\10\Debuggers\Redist\X64 Debuggers And Tools-x64_en-us.msi" from an elevated terminal after running the installer to get the dbghelp.dll and dbgcore.dll to appear in your C:\\Windows\System32 folder

Logs

Logs
PS C:\Users\myuser\Desktop\flutter_engine\engine\src> python3 .\flutter\tools\gn --unoptimized
Using prebuilt Dart SDK binary. If you are editing Dart sources and wish to compile the Dart SDK, set `--no-prebuilt-dart-sdk`.
Generating GN files in: out\host_debug_unopt
Traceback (most recent call last):
  File "C:/Users/myuser/Desktop/flutter_engine/engine/src/build/vs_toolchain.py", line 561, in <module>
    sys.exit(main())
  File "C:/Users/myuser/Desktop/flutter_engine/engine/src/build/vs_toolchain.py", line 557, in main
    return commands[sys.argv[1]](*sys.argv[2:])
  File "C:/Users/myuser/Desktop/flutter_engine/engine/src/build/vs_toolchain.py", line 383, in CopyDlls
    _CopyDebugger(target_dir, target_cpu)
  File "C:/Users/myuser/Desktop/flutter_engine/engine/src/build/vs_toolchain.py", line 413, in _CopyDebugger
    raise Exception('%s not found in "%s"\r\nYou must install the '
Exception: dbghelp.dll not found in "C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\dbghelp.dll"
You must install the "Debugging Tools for Windows" feature from the Windows 10 SDK.
ERROR at //build/toolchain/win/BUILD.gn:54:3: Script returned non-zero exit code.
  exec_script("//build/vs_toolchain.py",
  ^----------
Current dir: C:/Users/myuser/Desktop/flutter_engine/engine/src/out/host_debug_unopt/
Command: C:/Users/myuser/AppData/Local/vpython-root.0/store/python_venv-h51svab29kl4eaifbpdpb5k8ck/contents/Scripts/python3.exe C:/Users/myuser/Desktop/flutter_engine/engine/src/build/vs_toolchain.py copy_dlls C:/Users/myuser/Desktop/flutter_engine/engine/src/out/host_debug_unopt Debug x64
Returned 1.
See //BUILD.gn:5:1: which caused the file to be included.
group("default") {
^------------------

Flutter Doctor output

Not Applicable. This is related to building the flutter engine

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Issues that are less important to the Flutter projectd: docs/flutter/flutter/docs, for contributorsengineflutter/engine repository. See also e: labels.team-engineOwned by Engine teamtriaged-engineTriaged by Engine team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions