[Insight-users] starting with ITK registration
Luis Ibanez
luis.ibanez at kitware.com
Wed Mar 24 16:58:24 EDT 2010
Hi Stephen,
You are missing the ITKNumerics library in the
TARGET_LINK_LIBRARIES() command of your
CMakeLists.txt file.
Regards,
Luis
---------------------------------------------------------------------
On Wed, Mar 24, 2010 at 1:06 PM, Stephen Yip <stephen.fyip1 at gmail.com> wrote:
> Hi Luis,
>
> I redid the helloworld registration. I got the following errors while visual
> c++ was building an executable. could you skim through and instruct how I
> can possibly fix it? Thank you very much. Stephen
>
> 1>------ Build started: Project: ImageRegistration1, Configuration: Debug
> Win32 ------
> 1>Compiling...
> 1>ImageRegistration1.cxx
> 1>c:\itk\src\code\io\itkImageFileReader.txx(433) : warning C4996:
> 'std::copy': Function call with parameters that may be unsafe - this call
> relies on the caller to check that the passed values are correct. To disable
> this warning, use -D_SCL_SECURE_NO_WARNINGS. See documentation on how to use
> Visual C++ 'Checked Iterators'
> 1> C:\Program Files\Microsoft Visual Studio
> 9.0\VC\include\xutility(2576) : see declaration of 'std::copy'
> 1> c:\itk\src\code\io\itkImageFileReader.txx(357) : while compiling
> class template member function 'void
> itk::ImageFileReader<TOutputImage>::GenerateData(void)'
> 1> with
> 1> [
> 1> TOutputImage=FixedImageType
> 1> ]
> 1> ..\ImageRegistration1.cxx(258) : see reference to class template
> instantiation 'itk::ImageFileReader<TOutputImage>' being compiled
> 1> with
> 1> [
> 1> TOutputImage=FixedImageType
> 1> ]
> 1>Compiling manifest to resources...
> 1>Microsoft (R) Windows (R) Resource Compiler Version 6.1.6723.1
> 1>Copyright (C) Microsoft Corporation. All rights reserved.
> 1>Linking...
> 1> Creating library
> G:\ITK_test\registration\registration\Debug\ImageRegistration1.lib and
> object G:\ITK_test\registration\registration\Debug\ImageRegistration1.exp
> 1>ImageRegistration1.obj : error LNK2019: unresolved external symbol
> "protected: __thiscall
> itk::RegularStepGradientDescentBaseOptimizer::RegularStepGradientDescentBaseOptimizer(void)"
> (??0RegularStepGradientDescentBaseOptimizer at itk@@IAE at XZ) referenced in
> function "protected: __thiscall
> itk::RegularStepGradientDescentOptimizer::RegularStepGradientDescentOptimizer(void)"
> (??0RegularStepGradientDescentOptimizer at itk@@IAE at XZ)
> 1>ImageRegistration1.obj : error LNK2001: unresolved external symbol
> "protected: virtual void __thiscall
> itk::RegularStepGradientDescentBaseOptimizer::PrintSelf(class
> std::basic_ostream<char,struct std::char_traits<char> > &,class
> itk::Indent)const "
> (?PrintSelf at RegularStepGradientDescentBaseOptimizer@itk@@MBEXAAV?$basic_ostream at DU?$char_traits at D@std@@@std@@VIndent at 2@@Z)
> 1>ImageRegistration1.obj : error LNK2001: unresolved external symbol
> "public: virtual void __thiscall itk::Optimizer::SetInitialPosition(class
> itk::Array<double> const &)"
> (?SetInitialPosition at Optimizer@itk@@UAEXABV?$Array at N@2@@Z)
> 1>ImageRegistration1.obj : error LNK2001: unresolved external symbol
> "public: virtual void __thiscall
> itk::RegularStepGradientDescentBaseOptimizer::StartOptimization(void)"
> (?StartOptimization at RegularStepGradientDescentBaseOptimizer@itk@@UAEXXZ)
> 1>ImageRegistration1.obj : error LNK2001: unresolved external symbol
> "public: virtual class std::basic_string<char,struct
> std::char_traits<char>,class std::allocator<char> > const __thiscall
> itk::RegularStepGradientDescentBaseOptimizer::GetStopConditionDescription(void)const
> "
> (?GetStopConditionDescription at RegularStepGradientDescentBaseOptimizer@itk@@UBE?BV?$basic_string at DU?$char_traits at D@std@@V?$allocator at D@2@@std@@XZ)
> 1>ImageRegistration1.obj : error LNK2001: unresolved external symbol
> "protected: virtual void __thiscall itk::Optimizer::SetCurrentPosition(class
> itk::Array<double> const &)"
> (?SetCurrentPosition at Optimizer@itk@@MAEXABV?$Array at N@2@@Z)
> 1>ImageRegistration1.obj : error LNK2001: unresolved external symbol
> "public: virtual void __thiscall
> itk::SingleValuedNonLinearOptimizer::SetCostFunction(class
> itk::SingleValuedCostFunction *)"
> (?SetCostFunction at SingleValuedNonLinearOptimizer@itk@@UAEXPAVSingleValuedCostFunction at 2@@Z)
> 1>ImageRegistration1.obj : error LNK2001: unresolved external symbol
> "protected: virtual void __thiscall
> itk::RegularStepGradientDescentBaseOptimizer::AdvanceOneStep(void)"
> (?AdvanceOneStep at RegularStepGradientDescentBaseOptimizer@itk@@MAEXXZ)
> 1>ImageRegistration1.obj : error LNK2001: unresolved external symbol
> "protected: virtual void __thiscall
> itk::RegularStepGradientDescentOptimizer::StepAlongGradient(double,class
> itk::Array<double> const &)"
> (?StepAlongGradient at RegularStepGradientDescentOptimizer@itk@@MAEXNABV?$Array at N@2@@Z)
> 1>ImageRegistration1.obj : error LNK2001: unresolved external symbol
> "protected: virtual void __thiscall
> itk::SingleValuedNonLinearOptimizer::PrintSelf(class
> std::basic_ostream<char,struct std::char_traits<char> > &,class
> itk::Indent)const "
> (?PrintSelf at SingleValuedNonLinearOptimizer@itk@@MBEXAAV?$basic_ostream at DU?$char_traits at D@std@@@std@@VIndent at 2@@Z)
> 1>ImageRegistration1.obj : error LNK2001: unresolved external symbol
> "public: virtual class std::basic_string<char,struct
> std::char_traits<char>,class std::allocator<char> > const __thiscall
> itk::Optimizer::GetStopConditionDescription(void)const "
> (?GetStopConditionDescription at Optimizer@itk@@UBE?BV?$basic_string at DU?$char_traits at D@std@@V?$allocator at D@2@@std@@XZ)
> 1>ImageRegistration1.obj : error LNK2001: unresolved external symbol
> "protected: virtual void __thiscall itk::Optimizer::PrintSelf(class
> std::basic_ostream<char,struct std::char_traits<char> > &,class
> itk::Indent)const "
> (?PrintSelf at Optimizer@itk@@MBEXAAV?$basic_ostream at DU?$char_traits at D@std@@@std@@VIndent at 2@@Z)
> 1>ImageRegistration1.obj : error LNK2019: unresolved external symbol
> "protected: __thiscall itk::Optimizer::Optimizer(void)"
> (??0Optimizer at itk@@IAE at XZ) referenced in function "public: static class
> itk::SmartPointer<class itk::Optimizer> __cdecl itk::Optimizer::New(void)"
> (?New at Optimizer@itk@@SA?AV?$SmartPointer at VOptimizer@itk@@@2 at XZ)
> 1>ImageRegistration1.obj : error LNK2019: unresolved external symbol
> "protected: __thiscall
> itk::SingleValuedNonLinearOptimizer::SingleValuedNonLinearOptimizer(void)"
> (??0SingleValuedNonLinearOptimizer at itk@@IAE at XZ) referenced in function
> "public: static class itk::SmartPointer<class
> itk::SingleValuedNonLinearOptimizer> __cdecl
> itk::SingleValuedNonLinearOptimizer::New(void)"
> (?New at SingleValuedNonLinearOptimizer@itk@@SA?AV?$SmartPointer at VSingleValuedNonLinearOptimizer@itk@@@2 at XZ)
> 1>ImageRegistration1.obj : error LNK2001: unresolved external symbol
> "protected: virtual void __thiscall itk::CostFunction::PrintSelf(class
> std::basic_ostream<char,struct std::char_traits<char> > &,class
> itk::Indent)const "
> (?PrintSelf at CostFunction@itk@@MBEXAAV?$basic_ostream at DU?$char_traits at D@std@@@std@@VIndent at 2@@Z)
> 1>G:\ITK_test\registration\registration\Debug\ImageRegistration1.exe : fatal
> error LNK1120: 15 unresolved externals
> 1>Build log was saved at
> "file://g:\ITK_test\registration\registration\ImageRegistration1.dir\Debug\BuildLog.htm"
> 1>ImageRegistration1 - 16 error(s), 1 warning(s)
> ========== Build: 0 succeeded, 1 failed, 2 up-to-date, 0 skipped ==========
>
>
More information about the Insight-users
mailing list