Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
766 views
in Technique[技术] by (71.8m points)

plugins - How can I solve this 'no service found for - “org.qt-project.qt.mediaplayer”' error with a statically built Qt?

Hello in order to build static Qt for Windows, I followed the next article.

http://qt-project.org/wiki/How-to-build-a-static-Qt-for-Windows-MinGW

Using Qt vesion – 5.2.0. Operating System- Windows7. The problem is that it says – no service found for – “org.qt-project.qt.mediaplayer” on building the project.

I searched the net, but no solution was useful. Maybe I’m not using them correctly because of some lack of knowledge of Qt infrastructure, but anyway if someone could give me some instructions of solving of this problem, I would really appreciate that.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

I'm using statically Qt 5.2.1 OpenGL MinGW and had same problem (video wasn't playing with same "no service found"). In my case I solved the problem linking the static mediaplayer plugin (dsengine) in project. To do this I had to:

1) add in .pro file:

CONFIG += static
static:{
QTPLUGIN += dsengine
CONFIG += release
LIBS += -ldsengine
}

dsengine plugin is located in %QTDIR%/plugins/mediaservice/libdsengine.a

2) add somewhere in the code (around main.cpp):

#ifdef QT_STATIC
#include <QtCore/QtPlugin>
Q_IMPORT_PLUGIN(DSServicePlugin)
#endif

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...