Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

qt vs tools, executable directories not work



  • e.g. the project depends on a.dll

    set it:

    1. In project property / VC++ Directories / Executable Directories, add directory path of a.dll
    2. In project property / Debugging / Environment, add $(ExecutablePath). In the environment Evaluated value, I can see the directories are there and right.

    I'm sure the method works for my non Qt project.



  • @jronald
    Maybe the DLL(s) have further dependent DLLs which are still not on path? Use a dependency walker on them? Compare your added directories to exactly whatever VS would have, if you can do that?



  • @JonB said in qt vs tools, executable directories not work:

    @jronald
    Maybe the DLL(s) have further dependent DLLs which are still not on path?

    No, if the same directory paths are added in system environment, it runs. And it's a project I'm migrating from wxWidgets, I'm sure the paths are enough.



  • @JonB

    By default, i.e. add PATH=$(ExecutablePath), it doesn't work, the result is as below:

    PATH=$(ExecutablePath)$(LocalDebuggerEnvironment)
    

    whichs is equivalant to:

    PATH=$(ExecutablePath)
    PATH=%PATH%;$(QtDllPath)
    

    The one below works, the key point is not check Inherit from parent or project defaults.

    PATH=$(ExecutablePath)$(QtDllPath)
    


  • @JonB

    By default, i.e. add PATH=$(ExecutablePath), it doesn't work, the result is as below:

    PATH=$(ExecutablePath)$(LocalDebuggerEnvironment)
    

    whichs is equivalant to:

    PATH=$(ExecutablePath)
    PATH=%PATH%;$(QtDllPath)
    

    The one below works, the key point is not to check Inherit from parent or project defaults.

    PATH=$(ExecutablePath)$(QtDllPath)
    

    BTW, where to report the bug?


Log in to reply