Results 1 to 2 of 2

Thread: Q_export_plugin2

  1. #1
    Join Date
    Jul 2006
    Posts
    25
    Thanks
    3
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Q_export_plugin2

    Hello,

    In my library I'm creating differents plugins for Qt Designer. I have readed about plugins and the examples that comes with qtdemo: "analogclock" plugin. The diference with my lib with the analog clock is that this is one project one plugin and my project is more than one plugin. So I defined Q_EXPORT_PLUGIN2 in diferents classes I have problems compiling the project :

    .obj/akfielddateplugin.o: In function `qt_plugin_query_verification_data':
    akfielddateplugin.cpp.text+0x40): multiple definition of `qt_plugin_query_verification_data'
    .obj/akfieldplugin.o:akfieldplugin.cpp.text+0x40): first defined here
    .obj/akfielddateplugin.o: In function `qt_plugin_instance':
    akfielddateplugin.cpp.text+0x220): multiple definition of `qt_plugin_instance'
    .obj/akfieldplugin.o:akfieldplugin.cpp.text+0x220): first defined here
    collect2: ld returned 1 exit status

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Q_export_plugin2

    There can be only one Q_EXPORT_PLUGIN macro. Use QDesignerCustomWidgetCollectionInterface.

  3. The following 2 users say thank you to jacek for this useful post:

    fpujol (20th April 2007), kaje44 (7th December 2008)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.