One of the two will be used. Which one is undefined.... error
i am on Mac OS X.6 using qt 4.8.2 within XCode.
I built Qt as a static library. I linked this static library within 2 different plug-ins. I have an host application (non qt), that can load one or the other of those plug-ins...
if i work with only one of the 2 plug-ins... load and quit plug-in 1 or plug-in 2 only all works fine.
If i load plug-in 1 (or 2), then close the plug-in, then load the second one... i get in console many similar messages with various classes
Class QCocoaColorPanelDelegate is implemented in both /Applications/xxxapp/Plug-ins/plugin1 and /Applications/xxxapp/Plug-ins/plugin2. One of the two will be used. Which one is undefined.
then a crash...
i have no clue why this is happening... i obviously load the qt binaries twice but any hint on how to to avoid this double loading would be awesome
i did post a couple of weeks ago the same issue on another qt forum.. but have not got any answer, i am totally stuck now... and i do apologize for those who are covering different forums and have seen this question
Your problem is that each plugin contains Qt. The symbols for Qt are in both libraries which leads to the problem you describe. The only viable solution for you is to build a SHARED Qt, and link your plugins to this version that will be loaded dynamically along with your plugins, only ONCE, even if you load the two plugins.