Hi guys, just bumped into the same thing. The reason is that GetClassName is #define'd in winuser.h which substitutes it with GetClassNameA or GetClassNameW. To get rid of this, just replace this with GetNameOfClass()...
Cheers, Rostislav. On 01/06/2015 07:40, Kislinskiy, Stefan wrote: > Hi Ralf, > > I had the exact same problem some weeks ago and was very confused. I didn't > manage to figure out the reason for that and I concluded that it might be an > internal linker error. Let's have a look at your code during this week if you > have time (cannot remember in which plugin I had this problem or even if it > was persistent code)? > > Best, > Stefan > > ________________________________________ > Von: Floca, Ralf Omar [r.fl...@dkfz-heidelberg.de] > Gesendet: Freitag, 29. Mai 2015 16:06 > An: mitk-users@lists.sourceforge.net > Betreff: [mitk-users] Linker problems with QmitkNodeDescriptor::GetClassName > > Hi, > > we are porting our modules and plugins from 2014.10 to the current code base > for the upcoming release. Now we have a strange linker error with VS2013. > > In the activator of a plugin I register an icon for a new data type (analog > to the PlanarFigure plugin). > > With the new MITK code base I get following linker error > > error LNK2001: Nicht aufgelöstes externes Symbol ""public: virtual class > QString __cdecl QmitkNodeDescriptor::GetClassName(void)const " > (?GetClassName@QmitkNodeDescriptor@@UEBA?AVQString@@XZ)". > > The cmake of my plugin does enlist a module dependency to MitkQtWidgets: > > mitk_create_plugin( > EXPORT_DIRECTIVE M4C_MITK_CORE_HELPER_EXPORT > EXPORTED_INCLUDE_SUFFIXES src > MODULE_DEPENDS MitkQtWidgets MitkQtWidgetsExt Map4MITK > PACKAGE_DEPENDS Qt4|QtUiTools Qt5|UiTools > ) > > In the VS project properties “MitkQtWidgets.lib” is correctly listed as > dependency. > > What makes it particularly strange is that > > 1) Usage of other QmitkNodeDescriptor methods (e.g. GetIcon, > GetSeperator) do not provoke a linker error > > 2) Implementation of QmitkNodeDescriptor::GetClassName seems correct and > matches the header declaration. This does not explain the missing symbol > > 3) MITK itself (including Planar figures) build with no errors. > > Any hints or clues regarding this problem are appreciated. > > Thanks, > Ralf > > ------------------------------------------------------------------------------------------------------ > Dr. Ralf Floca > Software development for Integrated Diagnostic and Therapy (SIDT) > Group leader > > German Cancer Research Center (DKFZ) > Foundation under Public Law > Im Neuenheimer Feld 280 > 69120 Heidelberg > Germany > phone: +49 6221 42-2560 > > r.fl...@dkfz.de > www.dkfz.de<http://www.dkfz.de/> > > [cid:image002.png@01D09A29.6C9E3A70] > > Management Board: Prof. Dr. Dr. h.c. Otmar D. Wiestler, Prof. Dr. Josef Puchta > VAT-ID No.: DE143293537 > > > Confidentiality Note: > This message is intended only for the use of the named recipient(s) and may > obtain confidential and/or privileged information. If you are not the > intended recipient, please contact the sender and delete the message. Any > unauthorized use of the information contained in this message is prohibited. > > > ------------------------------------------------------------------------------ > _______________________________________________ > mitk-users mailing list > mitk-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/mitk-users ------------------------------------------------------------------------------ _______________________________________________ mitk-users mailing list mitk-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mitk-users