How to Make Plugins Using Qt Creator
-
Hi,
I am a novice with Qt Creator, and I am trying to make dynamic link libs for my application via the Qt Creator. When I use the Qt Creator's template, the compiled output of my plugin library is a static shared library. How does the Qt Plugin system work? I am having a bit of difficulty trying to get a library working...Thanks!
-Masoug
-
What exactly are you trying to do?
Are you trying to get a dynamic library (something like QtCore) up and running or a plugin into your application/library? Technically both are pretty much the same thing, but the method to actually make use of the code differs slightly:-)
-
Thanks!
I'm trying to do something like the Plug and Paint Demo, where they showed how to make plugins for the application, not Qt. And some of the plugins are dynamic link libs, so the program loads them at runtime. I can't seem to replicate this on Qt Creator because Qt Creator says "Shared Library" (I use the template) but when I compile my project, it spits out a static library.
How do I make plugins for applications?
-Masoug
-
That would be strange... what exactly does it spit out and which OS are you using? What does your .pro-file look like?
-
So I go to File > New File or Project and I choose the "Other Project" template and select "C++ Library". Then I click "Choose..." and select "Shared Library" as type. Then the rest of the process were normal. When I compile the template, on the build folder i only find a ".a" file, no ".dll" file.
I run Windows Vista w/ Qt Creator 2.0.0
Thanks!
-Masoug
.pro file:
@#-------------------------------------------------
Project created by QtCreator 2010-09-19T09:53:58
#-------------------------------------------------
QT -= gui
TARGET = untitled
TEMPLATE = libDEFINES += UNTITLED_LIBRARY
SOURCES += untitled.cpp
HEADERS += untitled.h
untitled_global.h
@