[Development] could not find or load the Qt platform plugin "cocoa"

Ziller Eike Eike.Ziller at theqtcompany.com
Thu Oct 29 09:09:20 CET 2015


> On Oct 28, 2015, at 3:09 PM, Gil Moses <gil at waves.com> wrote:
> 
> Hi,
> 
> I've built Mac universal binaries of v5.5.1 (built separately for i386 and x86_64, then used lipo).
> Built and ran my Qt app (Xcode 5, Mavericks), and got this error:
> 
> . could not find or load the Qt platform plugin "cocoa".
> 
> Further diagnosis using DYLD_PRINT_LIBRARIES and QT_DEBUG_PLUGINS prints this when running the app:
> 
> ==============
> <many lines>
> QFactoryLoader::QFactoryLoader() checking directory path "/Library/Application Support/Waves/WavesQtLibs_5.5.1/plugins/platforms" ...
> QFactoryLoader::QFactoryLoader() looking at "/Library/Application Support/Waves/WavesQtLibs_5.5.1/plugins/platforms/libqcocoa.dylib"
> Found metadata in lib /Library/Application Support/Waves/WavesQtLibs_5.5.1/plugins/platforms/libqcocoa.dylib, metadata=
> {
>     "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
>     "MetaData": {
>         "Keys": [
>             "cocoa"
>         ]
>     },
>     "className": "QCocoaIntegrationPlugin",
>     "debug": false,
>     "version": 328961
> }
> 
> 
> Got keys from plugin meta data ("cocoa")
> QFactoryLoader::QFactoryLoader() checking directory path "/Volumes/Data/p4client/ProAudio/dev_main/ProAudio/Products/Release/Apps/CODEX App.app/Contents/MacOS/platforms" ...
> dyld: loaded: /Library/Application Support/Waves/WavesQtLibs_5.5.1/plugins/platforms/libqcocoa.dylib
> dyld: unloaded: /Library/Application Support/Waves/WavesQtLibs_5.5.1/plugins/platforms/libqcocoa.dylib
> loaded library "/Library/Application Support/Waves/WavesQtLibs_5.5.1/plugins/platforms/libqcocoa.dylib"
> QLibraryPrivate::loadPlugin failed on "/Library/Application Support/Waves/WavesQtLibs_5.5.1/plugins/platforms/libqcocoa.dylib" : "Cannot load library /Library/Application Support/Waves/WavesQtLibs_5.5.1/plugins/platforms/libqcocoa.dylib: (dlopen(/Library/Application Support/Waves/WavesQtLibs_5.5.1/plugins/platforms/libqcocoa.dylib, 5): Library not loaded: @rpath/QtGui.framework/Versions/5/QtGui\n  Referenced from: /Library/Application Support/Waves/WavesQtLibs_5.5.1/plugins/platforms/libqcocoa.dylib\n  Reason: image not found)”

libqcocoa.dylib does not find @rpath/QtGui.framework/Versions/5/QtGui
What is the RPATH of the executable that you try to run? (check with “otool -l”, look for LC_RPATH entries)

Br, Eike

> This application failed to start because it could not find or load the Qt platform plugin "cocoa".
> 
> Available platform plugins are: cocoa.
> 
> Reinstalling the application may fix this problem.
> Abort trap: 6
> 
> ============
> 
> I verified that the Qt frameworks (especially the QtGui mentioned in the error) and libqcocoa.dylib are universal i386 & x86_64.
> 
> Any ideas?
> 
> Thanks, 
> Gil Moses
> Waves Ltd.
> _______________________________________________
> Development mailing list
> Development at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/development

-- 
Eike Ziller, Senior Software Engineer - The Qt Company GmbH
 
The Qt Company GmbH, Rudower Chaussee 13, D-12489 Berlin
Geschäftsführer: Mika Pälsi, Juha Varelius, Tuula Haataja
Sitz der Gesellschaft: Berlin, Registergericht: Amtsgericht Charlottenburg, HRB 144331 B



More information about the Development mailing list