[Insight-users] Linking errors with ITK+WTL - help please
Frank Gao
gao at mdimaging.com
Mon Mar 27 11:59:14 EST 2006
Hi Luis,
Thanks for the reply. I was able to get it work by searching some old posts.
The reason seems to be that I did not completely configure the project with
options found in vcl/vnl modules. I opened the ITK solution and coped the
options from there, and then get it work. I was using CMAKE, but I am pretty
new to this. Not sure how I can make sure to get options of VCL. I had
similar problem with another GUI tool the other day. It seems people tend to
have trouble with vcl and vnl.
Thanks again,
Frank
-----Original Message-----
From: Luis Ibanez [mailto:luis.ibanez at kitware.com]
Sent: Sunday, March 26, 2006 8:17 AM
To: gao at mdimaging.com
Cc: insight-users at itk.org
Subject: Re: [Insight-users] Linking errors with ITK+WTL - help please
Hi Frank,
You seem to be making the common mistake of mixing compilation modes.
You probably built ITK for "Debug" and your application for "Release" ,
or the other way around.
Please make sure that you use the *EXACT* same compilation mode for
all the components of you application. That will include ITK, VTK,
and any other library that you may be combining.
If you were using CMake in order to configure your project, you
will not be having any of these problems.
Regards,
Luis
----------------------
Frank Gao wrote:
> Hi All,
>
> I am trying to use WTL to develop ITK/VTK a sample application. There
seems
> to be no problem to get VTK work, but some issues with ITK.
>
> The application is to open and show a DICOM file.
>
> Hundreds of linking errors like this one:
> msvcprtd.lib(MSVCP71D.dll) : error LNK2005: "public: class
> std::basic_ostream<char,struct std::char_traits<char> > & __thiscall
> std::basic_ostream<char,struct std::char_traits<char> >::operator<<(class
> std::basic_ostream<char,struct std::char_traits<char> > & (__cdecl*)(class
> std::basic_ostream<char,struct std::char_traits<char> > &))"
>
(??6?$basic_ostream at DU?$char_traits at D@std@@@std@@QAEAAV01 at P6AAAV01@AAV01@@Z@
> Z) already defined in MainFrm.obj
>
> I came across some page in ITK site, which said that including aIl ITK
files
> before any other ones may help. I tried this, but then the code won't
> compile.
>
> If I use 'ignore default library', I get lots of error like this:
> ITKNrrdIO.lib(enum.obj) : warning LNK4049: locally defined symbol _calloc
> imported
>
> Would anybody please point out a solution to this? Does WTL or ITK have a
> version of stream libs?
>
> Thanks,
>
> Frank
>
>
>
>
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk.org
> http://www.itk.org/mailman/listinfo/insight-users
>
>
More information about the Insight-users
mailing list