[qt5] QML `qtquick2plugind.dll` cannot be loaded
Closed this issue Β· 17 comments
It seems QML is not working now. See this repo for reporduce: https://github.com/upupming/vcpkg-qt5-qml-bug
Did we forget to copy some libraries to the tools folder?
@JackBoosY I got this bug, too when I build a QML project (an empty QML project from Qt creator).
It says C:\Users\ming\projects\tooth-studio\build\Debug\qml\QtQuick.2\qtquick2plugind.dll
couldn't be found, but it exists there:
Originally posted by @upupming in #14156 (comment)
It seems not related to vcpkg, the same problem will happen if using manually installed Qt & CMake
Sorry, I think the root cause is still the vcpkg copied DLLs. The DLLs are all copied, but the module cannot be loaded correctly.
Howerver, If I copy the built vcpkg-qt5-qml-bug.exe
and main.qml
to my Qt install library C:\Qt\5.15.2\msvc2019_64\bin
, I can run it successfully:
Without vcpkg, I can also success start the exe.
- Configure & Build with native Qt (don't use vcpkg)
- Got an
Debug
folder which only contains exe file and copy the QML file there (no DLLs copied). - Run windeploy to copy DLLs etc.:
PS C:\Users\ming\projects\vcpkg-qt5-qml-bug\build\Debug> C:\Qt\5.15.2\msvc2019_64\bin\windeployqt.exe --debug --qmldir ../../ .\vcpkg-qt5-qml-bug.exe
- Double click to run exe and succeeded
cc @Neumann-A
@JackBoosY This is a deployment problem. You have to figure out whats wrong with the deployment in example by yourself. I don't have time to debug this. It is probably easier to deploy a working qt.conf instead of all the dlls. (That also seems like the main difference to the example)
@upupming could you list the files (dlls) windeployqt deployed vs the files vcpkg deployed to see the difference?
@upupming could you list the files (dlls) windeployqt deployed vs the files vcpkg deployed to see the difference?
@Neumann-A Thanks for your advice, I have listed the difference of them below.
There are several observations:
- when using windeploy, the DLL is copied to
QtQuick.2\qtquick2plugind.dll
; when using vcpkg, the DLL is copied toqml\QtQuick.2\qtquick2plugind.dll
- The file size of windeploy's
qtquick2plugind.dll
is the same as that ofC:\Qt\5.15.2\msvc2019_64\qml\QtQuick.2
, both are 84.4KB; the file size of vcpkg'sqtquick2plugind.dll
is the same of that ofC:\src\vcpkg\installed\x64-windows\debug\qml\QtQuick.2\qtquick2plugind.dll
, both are 82.0KB.
I have tried to replace vcpkgs's copied qtquick2plugind.dll
with that of windeploy, but it doesn't help.
Maybe the issue is the file structure of the copied DLLs, but simply move all files behind qml
outside doesn;t help too. What do you think, @Neumann-A ?
Here are the results:
- https://github.com/upupming/vcpkg-qt5-qml-bug/releases/download/0.0.1/Debug-vcpkg.zip
- https://github.com/upupming/vcpkg-qt5-qml-bug/releases/download/0.0.1/Debug-windeploy.zip
Using windeploy
:
Folder PATH listing for volume PortableSSD
Volume serial number is 3C57-10F9
C:.
β D3Dcompiler_47.dll
β libEGLd.dll
β libGLESv2d.dll
β main.qml
β opengl32sw.dll
β Qt5Cored.dll
β Qt5Guid.dll
β Qt5Networkd.dll
β Qt5Qmld.dll
β Qt5QmlModelsd.dll
β Qt5QmlWorkerScriptd.dll
β Qt5Quickd.dll
β Qt5RemoteObjectsd.dll
β Qt5Svgd.dll
β Qt5Widgetsd.dll
β tree.txt
β vcpkg-qt5-qml-bug.exe
β vcpkg-qt5-qml-bug.ilk
β vcpkg-qt5-qml-bug.pdb
β
ββbearer
β qgenericbearerd.dll
β
ββiconengines
β qsvgicond.dll
β
ββimageformats
β qgifd.dll
β qicnsd.dll
β qicod.dll
β qjpegd.dll
β qsvgd.dll
β qtgad.dll
β qtiffd.dll
β qwbmpd.dll
β qwebpd.dll
β
ββplatforms
β qwindowsd.dll
β
ββqmltooling
β qmldbg_debuggerd.dll
β qmldbg_inspectord.dll
β qmldbg_locald.dll
β qmldbg_messagesd.dll
β qmldbg_natived.dll
β qmldbg_nativedebuggerd.dll
β qmldbg_previewd.dll
β qmldbg_profilerd.dll
β qmldbg_quickprofilerd.dll
β qmldbg_serverd.dll
β qmldbg_tcpd.dll
β
ββQtQml
β β plugins.qmltypes
β β qmldir
β β qmlplugind.dll
β β
β ββModels.2
β β modelsplugind.dll
β β plugins.qmltypes
β β qmldir
β β
β ββRemoteObjects
β β plugins.qmltypes
β β qmldir
β β qtqmlremoteobjectsd.dll
β β
β ββStateMachine
β β plugins.qmltypes
β β qmldir
β β qtqmlstatemachined.dll
β β
β ββWorkerScript.2
β plugins.qmltypes
β qmldir
β workerscriptplugind.dll
β
ββQtQuick
β ββWindow.2
β plugins.qmltypes
β qmldir
β windowplugind.dll
β
ββQtQuick.2
β plugins.qmltypes
β qmldir
β qtquick2plugind.dll
β
ββscenegraph
β qsgd3d12backendd.dll
β
ββstyles
β qwindowsvistastyled.dll
β
ββtranslations
qt_ar.qm
qt_bg.qm
qt_ca.qm
qt_cs.qm
qt_da.qm
qt_de.qm
qt_en.qm
qt_es.qm
qt_fi.qm
qt_fr.qm
qt_gd.qm
qt_he.qm
qt_hu.qm
qt_it.qm
qt_ja.qm
qt_ko.qm
qt_lv.qm
qt_pl.qm
qt_ru.qm
qt_sk.qm
qt_tr.qm
qt_uk.qm
qt_zh_TW.qm
Using vcpkg:
Folder PATH listing for volume PortableSSD
Volume serial number is 3C57-10F9
C:.
β brotlicommon.dll
β brotlidec.dll
β bz2d.dll
β freetyped.dll
β harfbuzz.dll
β icudtd67.dll
β icuind67.dll
β icuucd67.dll
β jasperd.dll
β jpeg62.dll
β libcrypto-1_1-x64.dll
β libpng16d.dll
β libssl-1_1-x64.dll
β libwebpmuxd.dll
β lzmad.dll
β main.qml
β pcre2-16d.dll
β qt.conf
β Qt5Cored.dll
β Qt5Guid.dll
β Qt5Networkd.dll
β Qt5Qmld.dll
β Qt5Svgd.dll
β Qt5Widgetsd.dll
β tiffd.dll
β tree.txt
β vcpkg-qt5-qml-bug.exe
β vcpkg-qt5-qml-bug.ilk
β vcpkg-qt5-qml-bug.pdb
β webpd.dll
β webpdecoderd.dll
β webpdemuxd.dll
β zlibd1.dll
β zstdd.dll
β
ββplugins
β ββbearer
β β qgenericbearerd.dll
β β
β ββiconengines
β β qsvgicond.dll
β β
β ββimageformats
β β qgifd.dll
β β qicnsd.dll
β β qicod.dll
β β qjp2d.dll
β β qjpegd.dll
β β qsvgd.dll
β β qtgad.dll
β β qtiffd.dll
β β qwbmpd.dll
β β qwebpd.dll
β β
β ββplatforms
β β qwindowsd.dll
β β
β ββstyles
β qwindowsvistastyled.dll
β
ββqml
β builtins.qmltypes
β
ββQt
β ββlabs
β β ββanimation
β β β labsanimationplugind.dll
β β β labsanimationplugind.pdb
β β β plugins.qmltypes
β β β qmldir
β β β
β β ββcalendar
β β β DayOfWeekRow.qml
β β β DayOfWeekRow.qmlc
β β β MonthGrid.qml
β β β MonthGrid.qmlc
β β β plugins.qmltypes
β β β qmldir
β β β qtlabscalendarplugind.dll
β β β qtlabscalendarplugind.pdb
β β β WeekNumberColumn.qml
β β β WeekNumberColumn.qmlc
β β β
β β ββfolderlistmodel
β β β plugins.qmltypes
β β β qmldir
β β β qmlfolderlistmodelplugind.dll
β β β qmlfolderlistmodelplugind.pdb
β β β
β β ββplatform
β β β plugins.qmltypes
β β β qmldir
β β β qtlabsplatformplugind.dll
β β β qtlabsplatformplugind.pdb
β β β
β β ββqmlmodels
β β β labsmodelsplugind.dll
β β β labsmodelsplugind.pdb
β β β plugins.qmltypes
β β β qmldir
β β β
β β ββsettings
β β β plugins.qmltypes
β β β qmldir
β β β qmlsettingsplugind.dll
β β β qmlsettingsplugind.pdb
β β β
β β ββsharedimage
β β β plugins.qmltypes
β β β qmldir
β β β sharedimageplugind.dll
β β β sharedimageplugind.pdb
β β β
β β ββwavefrontmesh
β β plugins.qmltypes
β β qmldir
β β qmlwavefrontmeshplugind.dll
β β qmlwavefrontmeshplugind.pdb
β β
β ββtest
β ββqtestroot
β plugins.qmltypes
β qmldir
β
ββQtMultimedia
β declarative_multimediad.dll
β declarative_multimediad.pdb
β plugins.qmltypes
β qmldir
β Video.qml
β
ββQtQml
β β plugins.qmltypes
β β qmldir
β β qmlplugind.dll
β β qmlplugind.pdb
β β
β ββModels.2
β β modelsplugind.dll
β β modelsplugind.pdb
β β plugins.qmltypes
β β qmldir
β β
β ββStateMachine
β β plugins.qmltypes
β β qmldir
β β qtqmlstatemachined.dll
β β qtqmlstatemachined.pdb
β β
β ββWorkerScript.2
β plugins.qmltypes
β qmldir
β workerscriptplugind.dll
β workerscriptplugind.pdb
β
ββQtQuick
β ββControls.2
β β β AbstractButton.qml
β β β Action.qml
β β β ActionGroup.qml
β β β ApplicationWindow.qml
β β β BusyIndicator.qml
β β β Button.qml
β β β ButtonGroup.qml
β β β CheckBox.qml
β β β CheckDelegate.qml
β β β ComboBox.qml
β β β Container.qml
β β β Control.qml
β β β DelayButton.qml
β β β Dial.qml
β β β Dialog.qml
β β β DialogButtonBox.qml
β β β Drawer.qml
β β β Frame.qml
β β β GroupBox.qml
β β β HorizontalHeaderView.qml
β β β ItemDelegate.qml
β β β Label.qml
β β β Menu.qml
β β β MenuBar.qml
β β β MenuBarItem.qml
β β β MenuItem.qml
β β β MenuSeparator.qml
β β β Page.qml
β β β PageIndicator.qml
β β β Pane.qml
β β β plugins.qmltypes
β β β Popup.qml
β β β ProgressBar.qml
β β β qmldir
β β β qtquickcontrols2plugind.dll
β β β qtquickcontrols2plugind.pdb
β β β RadioButton.qml
β β β RadioDelegate.qml
β β β RangeSlider.qml
β β β RoundButton.qml
β β β ScrollBar.qml
β β β ScrollIndicator.qml
β β β ScrollView.qml
β β β Slider.qml
β β β SpinBox.qml
β β β SplitView.qml
β β β StackView.qml
β β β SwipeDelegate.qml
β β β SwipeView.qml
β β β Switch.qml
β β β SwitchDelegate.qml
β β β TabBar.qml
β β β TabButton.qml
β β β TextArea.qml
β β β TextField.qml
β β β ToolBar.qml
β β β ToolButton.qml
β β β ToolSeparator.qml
β β β ToolTip.qml
β β β Tumbler.qml
β β β VerticalHeaderView.qml
β β β
β β ββdesigner
β β β β AbstractButtonSection.qml
β β β β BusyIndicatorSpecifics.qml
β β β β ButtonSection.qml
β β β β ButtonSpecifics.qml
β β β β CheckBoxSpecifics.qml
β β β β CheckDelegateSpecifics.qml
β β β β CheckSection.qml
β β β β ComboBoxSpecifics.qml
β β β β ContainerSection.qml
β β β β ControlSection.qml
β β β β ControlSpecifics.qml
β β β β DelayButtonSpecifics.qml
β β β β DialSpecifics.qml
β β β β FrameSpecifics.qml
β β β β GroupBoxSpecifics.qml
β β β β InsetSection.qml
β β β β ItemDelegateSection.qml
β β β β ItemDelegateSpecifics.qml
β β β β LabelSpecifics.qml
β β β β PaddingSection.qml
β β β β PageIndicatorSpecifics.qml
β β β β PageSpecifics.qml
β β β β PaneSection.qml
β β β β PaneSpecifics.qml
β β β β ProgressBarSpecifics.qml
β β β β qtquickcontrols2.metainfo
β β β β RadioButtonSpecifics.qml
β β β β RadioDelegateSpecifics.qml
β β β β RangeSliderSpecifics.qml
β β β β RoundButtonSpecifics.qml
β β β β ScrollViewSpecifics.qml
β β β β SliderSpecifics.qml
β β β β SpinBoxSpecifics.qml
β β β β StackViewSpecifics.qml
β β β β SwipeDelegateSpecifics.qml
β β β β SwipeViewSpecifics.qml
β β β β SwitchDelegateSpecifics.qml
β β β β SwitchSpecifics.qml
β β β β TabBarSpecifics.qml
β β β β TabButtonSpecifics.qml
β β β β TextAreaSpecifics.qml
β β β β TextFieldSpecifics.qml
β β β β ToolBarSpecifics.qml
β β β β ToolButtonSpecifics.qml
β β β β ToolSeparatorSpecifics.qml
β β β β TumblerSpecifics.qml
β β β β
β β β ββimages
β β β busyindicator-icon.png
β β β busyindicator-icon16.png
β β β busyindicator-icon@2x.png
β β β button-icon.png
β β β button-icon16.png
β β β button-icon@2x.png
β β β checkbox-icon.png
β β β checkbox-icon16.png
β β β checkbox-icon@2x.png
β β β combobox-icon.png
β β β combobox-icon16.png
β β β combobox-icon@2x.png
β β β delaybutton-icon.png
β β β delaybutton-icon16.png
β β β delaybutton-icon@2x.png
β β β dial-icon.png
β β β dial-icon16.png
β β β dial-icon@2x.png
β β β frame-icon.png
β β β frame-icon16.png
β β β frame-icon@2x.png
β β β groupbox-icon.png
β β β groupbox-icon16.png
β β β groupbox-icon@2x.png
β β β itemdelegate-icon.png
β β β itemdelegate-icon16.png
β β β itemdelegate-icon@2x.png
β β β label-icon.png
β β β label-icon16.png
β β β label-icon@2x.png
β β β page-icon.png
β β β page-icon16.png
β β β page-icon@2x.png
β β β pageindicator-icon.png
β β β pageindicator-icon16.png
β β β pageindicator-icon@2x.png
β β β pane-icon.png
β β β pane-icon16.png
β β β pane-icon@2x.png
β β β progressbar-icon.png
β β β progressbar-icon16.png
β β β progressbar-icon@2x.png
β β β radiobutton-icon.png
β β β radiobutton-icon16.png
β β β radiobutton-icon@2x.png
β β β rangeslider-icon.png
β β β rangeslider-icon16.png
β β β rangeslider-icon@2x.png
β β β roundbutton-icon.png
β β β roundbutton-icon16.png
β β β roundbutton-icon@2x.png
β β β scrollview-icon.png
β β β scrollview-icon16.png
β β β scrollview-icon@2x.png
β β β slider-icon.png
β β β slider-icon16.png
β β β slider-icon@2x.png
β β β spinbox-icon.png
β β β spinbox-icon16.png
β β β spinbox-icon@2x.png
β β β stackview-icon.png
β β β stackview-icon16.png
β β β stackview-icon@2x.png
β β β swipeview-icon.png
β β β swipeview-icon16.png
β β β swipeview-icon@2x.png
β β β switch-icon.png
β β β switch-icon16.png
β β β switch-icon@2x.png
β β β textarea-icon.png
β β β textarea-icon16.png
β β β textarea-icon@2x.png
β β β textfield-icon.png
β β β textfield-icon16.png
β β β textfield-icon@2x.png
β β β toolbar-icon.png
β β β toolbar-icon16.png
β β β toolbar-icon@2x.png
β β β toolbutton-icon.png
β β β toolbutton-icon16.png
β β β toolbutton-icon@2x.png
β β β toolseparator-icon.png
β β β toolseparator-icon16.png
β β β toolseparator-icon@2x.png
β β β tumbler-icon.png
β β β tumbler-icon16.png
β β β tumbler-icon@2x.png
β β β
β β ββFusion
β β β ApplicationWindow.qml
β β β BusyIndicator.qml
β β β Button.qml
β β β ButtonPanel.qml
β β β CheckBox.qml
β β β CheckDelegate.qml
β β β CheckIndicator.qml
β β β ComboBox.qml
β β β DelayButton.qml
β β β Dial.qml
β β β Dialog.qml
β β β DialogButtonBox.qml
β β β Drawer.qml
β β β Frame.qml
β β β GroupBox.qml
β β β HorizontalHeaderView.qml
β β β ItemDelegate.qml
β β β Label.qml
β β β Menu.qml
β β β MenuBar.qml
β β β MenuBarItem.qml
β β β MenuItem.qml
β β β MenuSeparator.qml
β β β Page.qml
β β β PageIndicator.qml
β β β Pane.qml
β β β plugins.qmltypes
β β β Popup.qml
β β β ProgressBar.qml
β β β qmldir
β β β qtquickcontrols2fusionstyleplugind.dll
β β β qtquickcontrols2fusionstyleplugind.pdb
β β β RadioButton.qml
β β β RadioDelegate.qml
β β β RadioIndicator.qml
β β β RangeSlider.qml
β β β RoundButton.qml
β β β ScrollBar.qml
β β β ScrollIndicator.qml
β β β Slider.qml
β β β SliderGroove.qml
β β β SliderHandle.qml
β β β SpinBox.qml
β β β SplitView.qml
β β β SwipeDelegate.qml
β β β Switch.qml
β β β SwitchDelegate.qml
β β β SwitchIndicator.qml
β β β TabBar.qml
β β β TabButton.qml
β β β TextArea.qml
β β β TextField.qml
β β β ToolBar.qml
β β β ToolButton.qml
β β β ToolSeparator.qml
β β β ToolTip.qml
β β β Tumbler.qml
β β β VerticalHeaderView.qml
β β β
β β ββImagine
β β β ApplicationWindow.qml
β β β BusyIndicator.qml
β β β Button.qml
β β β CheckBox.qml
β β β CheckDelegate.qml
β β β ComboBox.qml
β β β DelayButton.qml
β β β Dial.qml
β β β Dialog.qml
β β β DialogButtonBox.qml
β β β Drawer.qml
β β β Frame.qml
β β β GroupBox.qml
β β β HorizontalHeaderView.qml
β β β ItemDelegate.qml
β β β Label.qml
β β β Menu.qml
β β β MenuItem.qml
β β β MenuSeparator.qml
β β β Page.qml
β β β PageIndicator.qml
β β β Pane.qml
β β β plugins.qmltypes
β β β Popup.qml
β β β ProgressBar.qml
β β β qmldir
β β β qtquickcontrols2imaginestyleplugind.dll
β β β qtquickcontrols2imaginestyleplugind.pdb
β β β RadioButton.qml
β β β RadioDelegate.qml
β β β RangeSlider.qml
β β β RoundButton.qml
β β β ScrollBar.qml
β β β ScrollIndicator.qml
β β β Slider.qml
β β β SpinBox.qml
β β β SplitView.qml
β β β StackView.qml
β β β SwipeDelegate.qml
β β β SwipeView.qml
β β β Switch.qml
β β β SwitchDelegate.qml
β β β TabBar.qml
β β β TabButton.qml
β β β TextArea.qml
β β β TextField.qml
β β β ToolBar.qml
β β β ToolButton.qml
β β β ToolSeparator.qml
β β β ToolTip.qml
β β β Tumbler.qml
β β β VerticalHeaderView.qml
β β β
β β ββMaterial
β β β ApplicationWindow.qml
β β β BoxShadow.qml
β β β BusyIndicator.qml
β β β Button.qml
β β β CheckBox.qml
β β β CheckDelegate.qml
β β β CheckIndicator.qml
β β β ComboBox.qml
β β β CursorDelegate.qml
β β β DelayButton.qml
β β β Dial.qml
β β β Dialog.qml
β β β DialogButtonBox.qml
β β β Drawer.qml
β β β ElevationEffect.qml
β β β Frame.qml
β β β GroupBox.qml
β β β HorizontalHeaderView.qml
β β β ItemDelegate.qml
β β β Label.qml
β β β Menu.qml
β β β MenuBar.qml
β β β MenuBarItem.qml
β β β MenuItem.qml
β β β MenuSeparator.qml
β β β Page.qml
β β β PageIndicator.qml
β β β Pane.qml
β β β plugins.qmltypes
β β β Popup.qml
β β β ProgressBar.qml
β β β qmldir
β β β qtquickcontrols2materialstyleplugind.dll
β β β qtquickcontrols2materialstyleplugind.pdb
β β β RadioButton.qml
β β β RadioDelegate.qml
β β β RadioIndicator.qml
β β β RangeSlider.qml
β β β RectangularGlow.qml
β β β RoundButton.qml
β β β ScrollBar.qml
β β β ScrollIndicator.qml
β β β Slider.qml
β β β SliderHandle.qml
β β β SpinBox.qml
β β β SplitView.qml
β β β StackView.qml
β β β SwipeDelegate.qml
β β β SwipeView.qml
β β β Switch.qml
β β β SwitchDelegate.qml
β β β SwitchIndicator.qml
β β β TabBar.qml
β β β TabButton.qml
β β β TextArea.qml
β β β TextField.qml
β β β ToolBar.qml
β β β ToolButton.qml
β β β ToolSeparator.qml
β β β ToolTip.qml
β β β Tumbler.qml
β β β VerticalHeaderView.qml
β β β
β β ββUniversal
β β ApplicationWindow.qml
β β BusyIndicator.qml
β β Button.qml
β β CheckBox.qml
β β CheckDelegate.qml
β β CheckIndicator.qml
β β ComboBox.qml
β β DelayButton.qml
β β Dial.qml
β β Dialog.qml
β β DialogButtonBox.qml
β β Drawer.qml
β β Frame.qml
β β GroupBox.qml
β β HorizontalHeaderView.qml
β β ItemDelegate.qml
β β Label.qml
β β Menu.qml
β β MenuBar.qml
β β MenuBarItem.qml
β β MenuItem.qml
β β MenuSeparator.qml
β β Page.qml
β β PageIndicator.qml
β β Pane.qml
β β plugins.qmltypes
β β Popup.qml
β β ProgressBar.qml
β β qmldir
β β qtquickcontrols2universalstyleplugind.dll
β β qtquickcontrols2universalstyleplugind.pdb
β β RadioButton.qml
β β RadioDelegate.qml
β β RadioIndicator.qml
β β RangeSlider.qml
β β RoundButton.qml
β β ScrollBar.qml
β β ScrollIndicator.qml
β β Slider.qml
β β SpinBox.qml
β β SplitView.qml
β β StackView.qml
β β SwipeDelegate.qml
β β Switch.qml
β β SwitchDelegate.qml
β β SwitchIndicator.qml
β β TabBar.qml
β β TabButton.qml
β β TextArea.qml
β β TextField.qml
β β ToolBar.qml
β β ToolButton.qml
β β ToolSeparator.qml
β β ToolTip.qml
β β Tumbler.qml
β β VerticalHeaderView.qml
β β
β ββLayouts
β β plugins.qmltypes
β β qmldir
β β qquicklayoutsplugind.dll
β β qquicklayoutsplugind.pdb
β β
β ββLocalStorage
β β plugins.qmltypes
β β qmldir
β β qmllocalstorageplugind.dll
β β qmllocalstorageplugind.pdb
β β
β ββParticles.2
β β particlesplugind.dll
β β particlesplugind.pdb
β β plugins.qmltypes
β β qmldir
β β
β ββShapes
β β plugins.qmltypes
β β qmldir
β β qmlshapesplugind.dll
β β qmlshapesplugind.pdb
β β
β ββTemplates.2
β β plugins.qmltypes
β β qmldir
β β qtquicktemplates2plugind.dll
β β qtquicktemplates2plugind.pdb
β β
β ββWindow.2
β plugins.qmltypes
β qmldir
β windowplugind.dll
β windowplugind.pdb
β
ββQtQuick.2
β plugins.qmltypes
β qmldir
β qtquick2plugind.dll
β qtquick2plugind.pdb
β
ββQtTest
plugins.qmltypes
qmldir
qmltestplugind.dll
qmltestplugind.pdb
SignalSpy.qml
TestCase.qml
testlogger.js
there are a few things which could be the problem:
a) the qt.conf is incorrect.
b) the extra folder structure, plugins and qml are probably not necessary or wrong. But depends on what the qt.conf says
c) I don't see the folder plugin/qmltooling
which could also be the problem
Dump of file qtquick2plugind.dll
File Type: DLL
Image has the following dependencies:
Qt5Quickd.dll
Qt5QmlModelsd.dll
Qt5QmlWorkerScriptd.dll
Qt5Qmld.dll
Qt5Cored.dll
KERNEL32.dll
VCRUNTIME140D.dll
ucrtbased.dll
Looking at the files the vcpkg deployment is at least missing
Qt5Quickd.dll
Qt5QmlModelsd.dll
Qt5QmlWorkerScriptd.dll
@Neumann-A Thanks for the advice, I will try it.
Reason:
Dump of file vcpkg-qt5-qml-bug.exe
File Type: EXECUTABLE IMAGE
Image has the following dependencies:
Qt5Qmld.dll
Qt5Guid.dll
Qt5Cored.dll
VCRUNTIME140_1D.dll
VCRUNTIME140D.dll
ucrtbased.dll
KERNEL32.dll
vcpkg only deploys these if it detects linkage against Qt5Quick maybe it needs to be moved to also do so on Qt5Qml
@Neumann-A Just a question, could vcpkg call windeployqt.exe
to copy Qt's DLL files instead of maintaining an extra script? I think this will make life easier π
@Neumann-A Just a question, could vcpkg call windeployqt.exe to copy Qt's DLL files instead of maintaining an extra script? I think this will make life easier π
I don't mind using windeployqt or macdeployqt or whatever. The only issue is it requires at least qt5-tools for the host to be installed. (I also didn't write the deployment scripts.)
If I delete all files except the exe and qml file, and then run windeployqt.exe
, the exe will also succeed to start.
So I think: The easiest workaround is that we can add an option to prevent vcpkg to copy these Qt DLL files. Then the user can use their own prefered deploy method. For example, I may write a VSCode task like this to run windeployqt
on first successfully build:
{
"label": "Run windeploy",
"type": "shell",
"command": "C:/Qt/5.15.2/msvc2019_64/bin/windeployqt.exe --debug --qmldir . ${workspaceFolder}/Debug/vcpkg-qt5-qml-bug.exe",
"args": [],
"problemMatcher": []
},
prevent vcpkg to copy these Qt DLL files
just set VCPKG_APPLOCAL_DEPS
to off.
prevent vcpkg to copy these Qt DLL files
just set
VCPKG_APPLOCAL_DEPS
to off.
Can I just disable Qt, but keep copying others, such as opencv, sqlite's DLLs (Because vcpkg works well on these packages.)? It will be nice if this VCPKG_APPLOCAL_DEPS
can be per-package based.
Same error
before the bug is fixed, is there any convenient way to operate? vcpkg is a nice tool and I still want to continue to use it to manage my projects
windeployqt is not setup for debug configuration in qt5 within vcpkg. If you want to make it work you need to apply the same workaround as in qt6. Meaning creating a qmake.bat file which loads a qt.conf with the debug paths and a windeploy.bat which actually uses that qmake.bat to retrieve the paths. Otherwise it won't work correctly since it cannot find the required debug dlls.
@Logiase My workaround is using self insatlled qt instead the one from vcpkg. You cam see this repo for example: https://github.com/upupming/vscode-qt-qml-vcpkg-template