QWebEngineCore - dyld not loaded
-
I'm trying to deploy an app that is using QWebEngine on OSX.
The app run fine inside QtCreator,
but once I use macdeployqt and try to run it from there, I get this error on runtime :dyld: Library not loaded: @executable_path/../Frameworks/QtQuick.framework/Versions/5/QtQuick
Referenced from: /Users/tourlou2/build-PowerVelo2-Desktop_Qt_5_4_1_clang_64bit-Release/MaximumTrainer.app/Contents/Frameworks/QtWebEngineCore.framework/Versions/5/QtWebEngineCore
Reason: image not foundMy QWebEngineView is also black and not working.
I checked and the QtQuick reference is good and the library is there.. not sure why I get this error -
Hi,
Check with otool -L where it's look for its dependencies
-
Hi,
Did you figure out anything on this?
I have one project that uses QtWebKit that builds fine with 5.4.2 and another with QtWebEngine that has this bug.
Thanks,
Jimmy -
Hi and welcome to devnet,
Can you run otool -L on it and post the result ?
-
Haven't had time to experiment more with QWebEngine on OSX.
Will let you know next time I try. I'm still using QWebKit until some feature I need comes with QWebEngine. -
I've just started using QWebEngine (5.5.0) and I'm running into the same problem on mac. When I try to using QWebEngineView, I get the following runtime error:
dyld: Library not loaded: @executable_path/../Frameworks/QtQuick.framework/Versions/5/QtQuick
Referenced from
/svn/dev/trunk/build/svl/mac/Release-5.5/MyApp.app/Contents/Frameworks/QtWebEngineCore.framework/Versions/5/QtWebEngineCore
Reason: image not foundNot sure why, though. QtQuick.framework is there:
$> ls Contents/Frameworks | grep Quick
QtQuick.frameworkand looks good with otool:
$> otool -L Contents/Frameworks/QtQuick.framework/Versions/5/QtQuick
Contents/Frameworks/QtQuick.framework/Versions/5/QtQuick:
@executable_path/../Frameworks/QtQuick.framework/Versions/5/QtQuick (compatibility version 5.5.0, current version 5.5.0)
@executable_path/../Frameworks/QtGui.framework/Versions/5/QtGui (compatibility version 5.5.0, current version 5.5.0)
@executable_path/../Frameworks/QtCore.framework/Versions/5/QtCore (compatibility version 5.5.0, current version 5.5.0)
/System/Library/Frameworks/DiskArbitration.framework/Versions/A/DiskArbitration (compatibility version 1.0.0, current version 1.0.0)
/System/Library/Frameworks/IOKit.framework/Versions/A/IOKit (compatibility version 1.0.0, current version 275.0.0)
@executable_path/../Frameworks/QtQml.framework/Versions/5/QtQml (compatibility version 5.5.0, current version 5.5.0)
@executable_path/../Frameworks/QtNetwork.framework/Versions/5/QtNetwork (compatibility version 5.5.0, current version 5.5.0)
/System/Library/Frameworks/OpenGL.framework/Versions/A/OpenGL (compatibility version 1.0.0, current version 1.0.0)
/System/Library/Frameworks/AGL.framework/Versions/A/AGL (compatibility version 1.0.0, current version 1.0.0)
/usr/lib/libc++.1.dylib (compatibility version 1.0.0, current version 120.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1213.0.0)This is very strange. I would love to know if anyone makes any progress/discoveries with this problem on OS X.
-
I've made some discoveries that may be of help. I noticed that QtWebEngineCore.framework has other binaries into it besides Versions/5/QtWebEngineCore such as
Versions/5/Helpers/QtWebEngineProcess.app/Contents/MacOS/QtWebEngineProcess
SimVirtualLabs.app/Contents/Frameworks/QtWebEngineCore.framework/Versions/5/Libraries/ffmpegsumo.soI also noticed that the prebuilt 5.5.0 binaries from Qt use @rpath instead @excutable_path or an absolute path.
otool -L lib/QtCore.framework/Versions/5/QtCore
lib/QtCore.framework/Versions/5/QtCore:
@rpath/QtCore.framework/Versions/5/QtCore (compatibility version 5.5.0, current version 5.5.0)
/System/Library/Frameworks/DiskArbitration.framework/Versions/A/DiskArbitration (compatibility version 1.0.0, current version 1.0.0)
....I'm not how the macdeployqt works since I have own script to move/prepare the Qt frameworks but I've always used the install_name_tool to create paths using @executable_path like:
@executable_path/../Frameworks/QtQuick.framework/Versions/5/QtQuick
However, if leave the install name paths alone for the prebuilt binaries (that use @rpath) and add the following to my Xcode target settings:
Linker -> Runtime Search Paths : @executable_path/../Frameworks
Then I don't get the runtime load error and everything seems to work. I don't understand the nitty-gritty about why this works (anyone want to chime in) but hopefully this information will help somebody get QWebEngine working on OS X.