Qt5-Windows:找不到VCRUNTIME140D_APP.dll

问题描述 投票:0回答:1

我将在Windows 10上部署一个小型应用程序。由于this post,我成功构建并运行了该应用程序,并创建了可执行文件。我的问题是突然之间缺少.dll。具体来说,单击.exe以确保应用程序令我惊讶的是以下错误消息:

未找到VCRUNTIME140D_APP.dll

“错误”

在我的调试文件夹中,我创建了.exe,但不知道为什么要该库。

这是我的.pro文件:

QT += quick quickcontrols2 concurrent network core gui

CONFIG += c++11

# The following define makes your compiler emit warnings if you use
# any Qt feature that has been marked deprecated (the exact warnings
# depend on your compiler). Refer to the documentation for the
# deprecated API to know how to port your code away from it.
DEFINES += QT_DEPRECATED_WARNINGS

TARGET = SMTPEmail
TEMPLATE = app
DEFINES += SMTP_BUILD
#win32:CONFIG += dll

#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000    # disables all the APIs deprecated before Qt 6.0.0

SOURCES += \
        main.cpp \
        progressbardialog.cpp \
        robot.cpp \
        robotmanager.cpp \
        settings/emailaddress.cpp \
        settings/mimeattachment.cpp \
        settings/mimecontentformatter.cpp \
        settings/mimefile.cpp \
        settings/mimehtml.cpp \
        settings/mimeinlinefile.cpp \
        settings/mimemessage.cpp \
        settings/mimemultipart.cpp \
        settings/mimepart.cpp \
        settings/mimetext.cpp \
        settings/quotedprintable.cpp \
        settings/smtpclient.cpp \
        user.cpp \
        usermanager.cpp

RESOURCES += qml.qrc

# Additional import path used to resolve QML modules in Qt Creator's code model
QML_IMPORT_PATH =

# Additional import path used to resolve QML modules just for Qt Quick Designer
QML_DESIGNER_IMPORT_PATH =

# Default rules for deployment.
qnx: target.path = /tmp/$${TARGET}/bin
else: unix:!android: target.path = /opt/$${TARGET}/bin
!isEmpty(target.path): INSTALLS += target

HEADERS += \
    progressbardialog.h \
    robot.h \
    robotmanager.h \
    settings/SmtpMime \
    settings/emailaddress.h \
    settings/mimeattachment.h \
    settings/mimecontentformatter.h \
    settings/mimefile.h \
    settings/mimehtml.h \
    settings/mimeinlinefile.h \
    settings/mimemessage.h \
    settings/mimemultipart.h \
    settings/mimepart.h \
    settings/mimetext.h \
    settings/quotedprintable.h \
    settings/smtpclient.h \
    settings/smtpexports.h \
    user.h \
    usermanager.h

到目前为止我做了什么

1]为了解决最后一个问题,我进行了研究,发现this useful post也解释了主要区别。尽管要注意的是,此应用程序只能在桌面上运行。

[2)我发现此版本要下载vcruntime140_app.dll,我从中下载缺少的库。解压缩并添加到我的调试文件夹中,也可以从下面的打印屏幕中看到:

“

此后,我构建并运行了该应用程序,但令人惊讶的是,尽管缺少.dll,但仍手动将其添加到调试文件夹,但仍出现了相同的错误。

3)我做了更多研究,发现了thisthis post以及this one。但是所有这些都没有帮助我弄清楚如何理解问题所在。

4)我也尝试从以上第2点的同一站点安装此版本vcruntime140d.dll,但结果仍然相同。缺少资料库VCRUNTIME140D_APP.dll was not found

<< img src =“ https://image.soinside.com/eyJ1cmwiOiAiaHR0cHM6Ly9pLmltZ3VyLmNvbS9IcG56WXdKLnBuZyJ9” alt =“错误”>

我最后要注意的是:我下载并尝试了vcruntime140d_app.dll,然后尝试了[[vcruntime140d.dll,但如果存在vcruntime140d_app.dll,我找不到它。] >我不明白为什么,尽管有库,在这里也可以看到C:\Users\me\OneDrive\Desktop\build-signalsQML-Desktop_Qt_5_12_0_MSVC2017_64bit-Debug\vcruntime140_app.dll双击可执行文件仍然会出现相同的错误。

感谢您指出正确的方向来解决此问题。

我将在Windows 10上部署一个小型应用程序。由于这篇文章,我成功地构建并运行了该应用程序并创建了可执行文件。我的问题是突然之间...

c++ windows qt dll qt5
1个回答
0
投票
他,我最近在Windows下发现了二进制打包,但不笑这种处理依赖关系的方式在关联中很痛苦。在我看来,我遇到了此错误,这与缺少Visual C ++版本有关,试图安装Microsoft Visual C ++ 2015 Redistributable,但我不确定该版本是否可以帮助您。哦,qt带有一个您不知道的名为windeployqt的软件,它应该通过提供必要的dll来简化部署,无需花费任何尝试。
© www.soinside.com 2019 - 2024. All rights reserved.