无法找到或加载Qt平台插件"windows"
Could not find or load the Qt platform plugin "windows"
首先,为了防止重复报告,我尝试了这里,这里,这里,这里和这里给出的多种解决方案。
我使用Qt 5.5.1与Visual Studio 2012和开发我的应用程序在Windows 10 x64(不使用Qt Creator)。应用程序在发布模式下编译。
实际上,我的应用程序在我的PC上工作,没有任何问题,我的目录中唯一需要的库是:
Qt5Core.dll
Qt5Gui.dll
Qt5WinExtras.dll
Qt5Widgets.dll
Qt5Network.dll
msvcp110.dll
msvcr110.dll
现在,当我尝试在新安装的Windows 7 x86上启动我的应用程序时,我得到以下错误消息:
此应用程序无法启动,因为它无法找到或加载Qt平台插件"windows"。
重新安装应用程序可以解决这个问题。
现在我无法摆脱它。根据前面问的问题,这可能是qwindows.dll
文件的问题(或者更准确地说,是应用程序无法找到它),首先,我像这样部署了我的发布目录:
[..]msvc2012bin>windeployqt.exe <PATH>
它已经生成了我的应用程序启动所需的所有文件,包括platforms/qwindows.dll
,所以我只是简单地将它们全部复制到Windows 7目录而没有任何效果-错误仍然发生
我也尝试从msvc2012pluginsplatforms
手动复制qwindows.dll
-没有效果,
我做的最后一步是在Dependency Walker中检查我的应用程序-令人惊讶的是,没有qwindows.dll
相关的依赖:
所以我现在没有主意了,这里的问题是什么?
我在Windows下部署QOwnNotes (Qt5): https://github.com/pbek/QOwnNotes/blob/develop/appveyor.yml
# AppVeyor build configuration
# http://www.appveyor.com/docs/build-configuration
os: unstable
skip_tags: true
install:
- set QTDIR=C:Qt5.5mingw492_32
- set PATH=%PATH%;%QTDIR%bin;C:MinGWbin
- set RELEASE_PATH=appveyorrelease
before_build:
# getting submodules
- git submodule update --init
build_script:
# using a header file without MemoryBarrier, that causes the build to fail
- copy appveyorqopenglversionfunctions.h %QTDIR%includeQtGui
# workaround for MinGW bug
- sed -i s/_hypot/hypot/g c:mingwincludemath.h
- cd src
# we need to modify that to make it running on AppVeyor
- sed -i "s/CONFIG += c++11/QMAKE_CXXFLAGS += -std=gnu++0x/g" QOwnNotes.pro
- "echo #define RELEASE "AppVeyor" > release.h"
# setting the build number in the header file
- "echo #define BUILD %APPVEYOR_BUILD_NUMBER% > build_number.h"
- qmake QOwnNotes.pro -r -spec win32-g++
# - qmake QOwnNotes.pro -r -spec win32-g++ "CONFIG+=debug"
- mingw32-make
# creating the release path
- md ..%RELEASE_PATH%
# copy the binary to our release path
- copy releaseQOwnNotes.exe ..%RELEASE_PATH%
# copy OpenSSL DLLs to the release path
- copy ..appveyorOpenSSLlibeay32.dll ..%RELEASE_PATH%
- copy ..appveyorOpenSSLlibssl32.dll ..%RELEASE_PATH%
- copy ..appveyorOpenSSLssleay32.dll ..%RELEASE_PATH%
# copy portable mode launcher to the release path
- copy ..appveyorQOwnNotesPortable.bat ..%RELEASE_PATH%
# copy translation files
- copy languages*.qm ..%RELEASE_PATH%
- cd ..%RELEASE_PATH%
# fetching dependencies of QT app
# http://doc.qt.io/qt-5/windows-deployment.html
- windeployqt --release QOwnNotes.exe
# this dll was missed by windeployqt
- copy ..libwinpthread-1.dll . /y
# this dll didn't work when released by windeployqt
- copy "..libstdc++-6.dll" . /y
# for some reason AppVeyor or windeployqt uses a copy of the German
# translation file as English one, which screws up the English user interface
- del "translationsqt_en.qm"
artifacts:
# pushing entire folder as a zip archive
- path: appveyorrelease
name: QOwnNotes
deploy:
# Deploy to GitHub Releases
- provider: GitHub
artifact: QOwnNotes
draft: false
prerelease: false
auth_token:
secure: spcyN/Dz3B2GXBPii8IywDLq6vfxC1SrN+xR2wMerFM7g2nTy0Lrh5agQONFoInR
on:
branch: master
notifications:
# Gitter webhook
- provider: Webhook
url: https://webhooks.gitter.im/e/b6ef22402eb4af50f73a
on_build_success: true
on_build_failure: true
on_build_status_changed: false
- 正在查找文档以获得PS4平台的C++中的设备信息
- 从C++本机插件更新Vector3数组
- 使用CMake创建QML插件
- 停止cmake target_link_libraries将插件中静态库的两个对象文件链接到静态库本身
- 如何在fixup_bundle宏之后修复"即使找到Qt平台插件也无法加载" " "xcb" Qt平台插件"?
- 在" "中加载Qt平台插件"windlows"
- Qt找不到平台插件可可
- 此应用程序无法启动,因为它找不到或加载Qt平台插件"windows"
- QT平台插件"windows"
- 部署Qt-dll文件-找不到windows插件,尽管平台/qwindows.dll存在,因此存在libEGL和libGL
- Qt5 找不到 Mac OS X 的平台插件
- 应用程序无法启动,因为缺少平台插件“窗口”
- 节点-gyp 平台特定的插件
- 此应用程序无法启动,因为它找不到或加载Qt平台插件"xcb"
- Qt5.1未能加载平台插件xcb
- Qt5 静态构建产量 无法加载平台插件"windows"
- 无法找到或加载Qt平台插件"windows"
- 与Qt静态链接的应用程序出现错误:无法加载平台插件"windows"
- 无法加载平台插件"windows" 可用平台包括:窗口,最小
- (Qt 5.7.0)无法找到或加载 qt 平台插件"windows"