qtqt-creatorqmlembedded-linuxqtembedded

Qt QML Unsupported Image Format for SVG Files


I am continually getting the errors below when launching a Qt Embedded application that uses QML. From Googling around it seems like I needed to add the image loading plugins to my embedded system's exported nfs. So I attempted to add them several places but I keep getting the errors. I added the embedded ARM's version of libqsvg.so to the following locations but still get the errors...

/home/user/exported-nfs/lib/plugins/imageformats/libqsvg.so
/home/user/exported-nfs/plugins/imageformats/libqsvg.so
/home/user/exported-nfs/usr/bin/plugins/imageformats/libqsvg.so
/home/user/exported-nfs/usr/lib/plugins/imageformats/libqsvg.so
/home/user/exported-nfs/usr/plugins/imageformats/libqsvg.so

This doesn't work either:

export QT_PLUGIN_PATH=/usr/plugins:/usr/plugins/imageformats
echo $QT_PLUGIN_PATH

How can I fix this?? Where is the proper place that I need to put the plugins so they are found?

The errors:

WARNING: file:///usr/share/maliit/plugins/org/nemomobile/FunctionKey.qml:98:5: QML Image: Error decoding: file:///usr/share/maliit/plugins/org/nemomobile/icon-m-input-methods-backspace.svg: Unsupported image format
WARNING: file:///usr/share/maliit/plugins/org/nemomobile/FunctionKey.qml:98:5: QML Image: Error decoding: file:///usr/share/maliit/plugins/org/nemomobile/icon-m-input-methods-shift-lowercase.svg: Unsupported image format
WARNING: file:///usr/share/maliit/plugins/org/nemomobile/FunctionKey.qml:98:5: QML Image: Error decoding: file:///usr/share/maliit/plugins/org/nemomobile/icon-m-input-methods-backspace.svg: Unsupported image format


Solution

  • The answer was to copy the plugins directory to my embedded board at the location specified by the -plugins flag in the configure step.. In my case /usr/lib/qt/plugins. You can also set the environment variable QT_DEBUG_PLUGINS to 1 to get some debug output from any plugins that fail to load.