[Insight-users] Problems with itk and streams under VC++

Nils Hanßen hanssen at caesar.de
Tue Dec 11 10:44:26 EST 2001


Thanks for the hint (and Stephen), it seems to work now...
However, the linker is missing some symbols. Could this be a cosequence of
the former problem?

The missing symbols are (sorry, the explantory text of the compiler is in
german):

ButtonDialog.obj : error LNK2001: Nichtaufgeloestes externes Symbol
"protected: virtual void __thiscall itk::Region::PrintTrailer(class
std::basic_ostream<char,struct std::char_traits<char> > &,class
itk::Indent)const " (?PrintTrailer at Region@itk@@MB
EXAAV?$basic_ostream at DU?$char_traits at D@std@@@std@@VIndent at 2@@Z)
ButtonDialog.obj : error LNK2001: Nichtaufgeloestes externes Symbol
"protected: virtual void __thiscall itk::Region::PrintHeader(class
std::basic_ostream<char,struct std::char_traits<char> > &,class
itk::Indent)const " (?PrintHeader at Region@itk@@MBEX
AAV?$basic_ostream at DU?$char_traits at D@std@@@std@@VIndent at 2@@Z)
ButtonDialog.obj : error LNK2001: Nichtaufgeloestes externes Symbol "public:
virtual void __thiscall itk::Region::Print(class
std::basic_ostream<char,struct std::char_traits<char> > &)const "
(?Print at Region@itk@@UBEXAAV?$basic_ostream at DU?$char_trait
s at D@std@@@std@@@Z)
ButtonDialog.obj : error LNK2001: Nichtaufgeloestes externes Symbol
"protected: virtual void __thiscall itk::Region::PrintSelf(class
std::basic_ostream<char,struct std::char_traits<char> > &,class
itk::Indent)const " (?PrintSelf at Region@itk@@MBEXAAV?
$basic_ostream at DU?$char_traits at D@std@@@std@@VIndent at 2@@Z)
ButtonDialog.obj : error LNK2001: Nichtaufgeloestes externes Symbol
"protected: virtual void __thiscall
itk::DataObject::PropagateResetPipeline(void)"
(?PropagateResetPipeline at DataObject@itk@@MAEXXZ)
ButtonDialog.obj : error LNK2001: Nichtaufgeloestes externes Symbol "public:
virtual void __thiscall itk::DataObject::ResetPipeline(void)"
(?ResetPipeline at DataObject@itk@@UAEXXZ)
ButtonDialog.obj : error LNK2001: Nichtaufgeloestes externes Symbol "public:
virtual void __thiscall itk::Object::DebugOff(void)const "
(?DebugOff at Object@itk@@UBEXXZ)
ButtonDialog.obj : error LNK2001: Nichtaufgeloestes externes Symbol "public:
virtual void __thiscall itk::Object::DebugOn(void)const "
(?DebugOn at Object@itk@@UBEXXZ)
ButtonDialog.obj : error LNK2001: Nichtaufgeloestes externes Symbol "void
__cdecl itk::OutputWindowDisplayDebugText(char const *)"
(?OutputWindowDisplayDebugText at itk@@YAXPBD at Z)
ButtonDialog.obj : error LNK2001: Nichtaufgeloestes externes Symbol "void
__cdecl itk::OutputWindowDisplayErrorText(char const *)"
(?OutputWindowDisplayErrorText at itk@@YAXPBD at Z)
ButtonDialog.obj : error LNK2001: Nichtaufgeloestes externes Symbol "public:
void __thiscall itk::SimpleFastMutexLock::Unlock(void)const "
(?Unlock at SimpleFastMutexLock@itk@@QBEXXZ)
ButtonDialog.obj : error LNK2001: Nichtaufgeloestes externes Symbol "public:
void __thiscall itk::SimpleFastMutexLock::Lock(void)const "
(?Lock at SimpleFastMutexLock@itk@@QBEXXZ)
ButtonDialog.obj : error LNK2001: Nichtaufgeloestes externes Symbol "public:
__thiscall itk::SimpleFastMutexLock::~SimpleFastMutexLock(void)"
(??1SimpleFastMutexLock at itk@@QAE at XZ)
  -----Original Message-----
  From: Miller, James V (CRD) [mailto:millerjv at crd.ge.com]
  Sent: Tuesday, December 11, 2001 4:22 PM
  To: 'Nils Hanßen'; insight-users at public.kitware.com
  Subject: RE: [Insight-users] Problems with itk and streams under VC++


  What file was compiling at the time the error occurred?

  ITK requires the new C++ streams library be used from the C++ Standard
Library.  These headers are of the type <strstream> as opposed to
<strstream.h>.  From the snippet you provided, it looks like the correct
streams header is being used.

  Depending on what you were compiling (for instance an application that you
are writing), a header from the old streams library might have been included
prior to ITK including a file from the streams library.  The two streams
libraries cannot be mixed.

  So QT might be trying to use the old streams library.

  Try putting itkImage.h as the first include file in your application.
    -----Original Message-----
    From: Nils Hanßen [mailto:hanssen at caesar.de]
    Sent: Tuesday, December 11, 2001 9:54 AM
    To: insight-users at public.kitware.com
    Subject: [Insight-users] Problems with itk and streams under VC++


    Hello all,

    i encounter problems when i try to create a QT application that uses
itk.
    When i include <itkImage.h> for example, it produces an error C2039.
More precise, it says:

    c:\programme\microsoft visual studio\vc98\include\strstream(51) : error
C2039: 'seekdir' : is no element of 'ios'
            c:\programme\microsoft visual studio\vc98\include\ios.h(106) :
see declaration of 'ios'

    Does itk use a different definition of streams?
    I looked into the document "Building an ITK Application in Visual C++
6.0" and this issue is not mentioned there.

    Thanks in advance for any comments or hints!

    Regards
    Nils
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://itk.org/pipermail/insight-users/attachments/20011211/50137198/attachment-0001.html>


More information about the Insight-users mailing list