[ITK] Problem with installing ITKApplications

Sara Gh sg.ele.eng at gmail.com
Fri Mar 11 13:44:39 EST 2016


Hello ITK experts,

I have been trying to make ITK Apps work but I have not been successful so
far. When I am building (making) ITKApps the process ends with 8 errors in
DICOMApp. I would be thankful if you could help me in this regard. I am on
Mac (El Capitan) and here is the summary of what I have done so far:

1- Installing CMake-3.4.1.
2- Installing VTK-6.3.0
3- Installing ITK-4.8.2
4- Installing FLTK-1.3.3 (Initially, I had some issues with building FLTK
and came across to this <brew reinstall --devel
https://raw.githubusercontent.com/dpo/homebrew/ec46018128dde5bf466b013a6c7086d0880930a3/Library/Formula/fltk.rb>;
and using this solution: brew reinstall --devel
https://raw.githubusercontent.com/dpo/homebrew/ec46018128dde5bf466b013a6c7086d0880930a3/Library/Formula/fltk.rb
,
I could fix the problem and fltk folder has been created at
\usr\local\Cellar\fltk\1.3.3-r10866_1\)
5- Installing ITKApps:

- Create a folder named "Applications"

- In "Applications" directory run: git clone http://itk.org/ITKApps.git

-This will make a floder named "ITKApps"

- Then, create a folder named "build" in "Applications" directory

- Use Cmake gui:

* Source: PathTo/Applications/ITKApps
* Build: PathTo/Applications/build

- Configure! There is a bug: Fltk resources not found, GUI application will
not respond to mouse events

- Manually set the ITK_FLTK_RESOURCE to
\usr\local\Cellar\fltk\1.3.3-r10866_1\

- Configure again! Successful!

- Generate! Successful!

- Go to /Applications/build directory, and make.

This process ends with 8 errors related to DICOMApp.
"8 errors generated.
make[2]: *** [DICOMApp/CMakeFiles/DICOMApp.dir/main.cxx.o] Error 1make[1]:
*** [DICOMApp/CMakeFiles/DICOMApp.dir/all] Error 2
make: *** [all] Error 2"

Please find attached the text file including the errors I got.

Thanks,
Sara Gh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/community/attachments/20160311/3b1263d3/attachment.html>
-------------- next part --------------
Scanning dependencies of target itk2DAnisotropicDiffusionImageFilter
[  0%] Building CXX object AnisotropicDiffusionImageFilter/CMakeFiles/itk2DAnisotropicDiffusionImageFilter.dir/itk2DAnisotropicDiffusionImageFilter.cxx.o
[  1%] Linking CXX executable itk2DAnisotropicDiffusionImageFilter
[  1%] Built target itk2DAnisotropicDiffusionImageFilter
Scanning dependencies of target itk2DCannySegmentationLevelSetImageFilter
[  1%] Building CXX object LevelSetSegmentation/CMakeFiles/itk2DCannySegmentationLevelSetImageFilter.dir/itk2DCannySegmentationLevelSetImageFilter.cxx.o
[  2%] Linking CXX executable itk2DCannySegmentationLevelSetImageFilter
[  2%] Built target itk2DCannySegmentationLevelSetImageFilter
Scanning dependencies of target itk2DThresholdSegmentationLevelSetImageFilter
[  2%] Building CXX object LevelSetSegmentation/CMakeFiles/itk2DThresholdSegmentationLevelSetImageFilter.dir/itk2DThresholdSegmentationLevelSetImageFilter.cxx.o
[  3%] Linking CXX executable itk2DThresholdSegmentationLevelSetImageFilter
[  3%] Built target itk2DThresholdSegmentationLevelSetImageFilter
Scanning dependencies of target Example_ITKFilterLib
[  3%] Building CXX object ITKFilterLib/CMakeFiles/Example_ITKFilterLib.dir/ITKFilterLib.cxx.o
[  3%] Linking CXX static library ../VolviewPlugIns/bin/libExample_ITKFilterLib.a
[  3%] Built target Example_ITKFilterLib
Scanning dependencies of target Example_ITKFilterLibTest
[  4%] Building CXX object ITKFilterLib/CMakeFiles/Example_ITKFilterLibTest.dir/ITKFilterLibTest.cxx.o
[  4%] Linking CXX executable Example_ITKFilterLibTest
[  4%] Built target Example_ITKFilterLibTest
Scanning dependencies of target Example_ITKRegistrationLib
[  5%] Building CXX object ITKRegistrationLib/CMakeFiles/Example_ITKRegistrationLib.dir/ITKRegistrationLib.cxx.o
[  5%] Linking CXX static library ../VolviewPlugIns/bin/libExample_ITKRegistrationLib.a
[  5%] Built target Example_ITKRegistrationLib
Scanning dependencies of target Example_ITKRegistrationLibTest
[  6%] Building CXX object ITKRegistrationLib/CMakeFiles/Example_ITKRegistrationLibTest.dir/ITKRegistrationLibTest.cxx.o
[  6%] Linking CXX executable Example_ITKRegistrationLibTest
[  6%] Built target Example_ITKRegistrationLibTest
Scanning dependencies of target param
[  6%] Building CXX object StreamedWatershedSegmentation/ParameterFileParser/CMakeFiles/param.dir/lex.yy.cxx.o
[  7%] Building CXX object StreamedWatershedSegmentation/ParameterFileParser/CMakeFiles/param.dir/y.tab.cxx.o
[  7%] Building CXX object StreamedWatershedSegmentation/ParameterFileParser/CMakeFiles/param.dir/param.cxx.o
[  7%] Linking CXX static library ../../VolviewPlugIns/bin/libparam.a
[  7%] Built target param
Scanning dependencies of target BiasCorrector
[  7%] Building CXX object MRIBiasCorrection/CMakeFiles/BiasCorrector.dir/BiasCorrector.cxx.o
[  7%] Building CXX object MRIBiasCorrection/CMakeFiles/BiasCorrector.dir/OptionList.cxx.o
[  8%] Linking CXX executable BiasCorrector
[  8%] Built target BiasCorrector
Scanning dependencies of target BiasFieldEstimator
[  8%] Building CXX object MRIBiasCorrection/CMakeFiles/BiasFieldEstimator.dir/BiasFieldEstimator.cxx.o
[  9%] Building CXX object MRIBiasCorrection/CMakeFiles/BiasFieldEstimator.dir/OptionList.cxx.o
[  9%] Linking CXX executable BiasFieldEstimator
[  9%] Built target BiasFieldEstimator
Scanning dependencies of target BiasImageGenerator
[ 10%] Building CXX object MRIBiasCorrection/CMakeFiles/BiasImageGenerator.dir/BiasImageGenerator.cxx.o
[ 10%] Building CXX object MRIBiasCorrection/CMakeFiles/BiasImageGenerator.dir/OptionList.cxx.o
[ 11%] Linking CXX executable BiasImageGenerator
[ 11%] Built target BiasImageGenerator
Scanning dependencies of target EnergyTablePlotter
[ 12%] Building CXX object MRIBiasCorrection/CMakeFiles/EnergyTablePlotter.dir/EnergyTablePlotter.cxx.o
[ 12%] Building CXX object MRIBiasCorrection/CMakeFiles/EnergyTablePlotter.dir/OptionList.cxx.o
[ 13%] Linking CXX executable EnergyTablePlotter
[ 13%] Built target EnergyTablePlotter
Scanning dependencies of target ImageCorrector
[ 14%] Building CXX object MRIBiasCorrection/CMakeFiles/ImageCorrector.dir/ImageCorrector.cxx.o
[ 14%] Building CXX object MRIBiasCorrection/CMakeFiles/ImageCorrector.dir/OptionList.cxx.o
[ 15%] Linking CXX executable ImageCorrector
[ 15%] Built target ImageCorrector
Scanning dependencies of target IntensityHistogram3D
[ 16%] Building CXX object MRIBiasCorrection/CMakeFiles/IntensityHistogram3D.dir/IntensityHistogram3D.cxx.o
[ 16%] Building CXX object MRIBiasCorrection/CMakeFiles/IntensityHistogram3D.dir/OptionList.cxx.o
[ 17%] Linking CXX executable IntensityHistogram3D
[ 17%] Built target IntensityHistogram3D
Scanning dependencies of target InterSliceIntensityCorrector
[ 17%] Building CXX object MRIBiasCorrection/CMakeFiles/InterSliceIntensityCorrector.dir/InterSliceIntensityCorrector.cxx.o
[ 18%] Building CXX object MRIBiasCorrection/CMakeFiles/InterSliceIntensityCorrector.dir/OptionList.cxx.o
[ 18%] Linking CXX executable InterSliceIntensityCorrector
[ 18%] Built target InterSliceIntensityCorrector
Scanning dependencies of target SlabIdentifier
[ 18%] Building CXX object MRIBiasCorrection/CMakeFiles/SlabIdentifier.dir/SlabIdentifier.cxx.o
[ 19%] Building CXX object MRIBiasCorrection/CMakeFiles/SlabIdentifier.dir/OptionList.cxx.o
[ 19%] Linking CXX executable SlabIdentifier
[ 19%] Built target SlabIdentifier
Scanning dependencies of target itkAntiAliasBinaryImageFilterExample
[ 20%] Building CXX object AntiAliasBinaryImageFilter/CMakeFiles/itkAntiAliasBinaryImageFilterExample.dir/itkAntiAliasBinaryImageFilterExample.cxx.o
[ 20%] Linking CXX executable itkAntiAliasBinaryImageFilterExample
[ 20%] Built target itkAntiAliasBinaryImageFilterExample
Scanning dependencies of target itkSampleDataGenerator
[ 20%] Building CXX object AntiAliasBinaryImageFilter/CMakeFiles/itkSampleDataGenerator.dir/itkSampleDataGenerator.cxx.o
[ 21%] Linking CXX executable itkSampleDataGenerator
[ 21%] Built target itkSampleDataGenerator
Scanning dependencies of target itk2DSimpleLevelSetsExample
[ 21%] Building CXX object SimpleLevelSetsExample/CMakeFiles/itk2DSimpleLevelSetsExample.dir/itk2DSimpleLevelSetsExample.cxx.o
[ 22%] Linking CXX executable itk2DSimpleLevelSetsExample
[ 22%] Built target itk2DSimpleLevelSetsExample
Scanning dependencies of target itk3DSimpleLevelSetsExample
[ 23%] Building CXX object SimpleLevelSetsExample/CMakeFiles/itk3DSimpleLevelSetsExample.dir/itk3DSimpleLevelSetsExample.cxx.o
[ 23%] Linking CXX executable itk3DSimpleLevelSetsExample
[ 23%] Built target itk3DSimpleLevelSetsExample
Scanning dependencies of target GaussianMSClassificationApp
[ 24%] Building CXX object MultichannelTissueClassificationValidation/CMakeFiles/GaussianMSClassificationApp.dir/Code/GaussianMSClassifierValidationApp.cxx.o
[ 24%] Linking CXX executable GaussianMSClassificationApp
[ 24%] Built target GaussianMSClassificationApp
Scanning dependencies of target KmeansMSClassificationApp
[ 24%] Building CXX object MultichannelTissueClassificationValidation/CMakeFiles/KmeansMSClassificationApp.dir/Code/KmeansMSClassifierValidationApp.cxx.o
[ 25%] Linking CXX executable KmeansMSClassificationApp
[ 25%] Built target KmeansMSClassificationApp
Scanning dependencies of target DICOMApp
[ 26%] Building CXX object DICOMApp/CMakeFiles/DICOMApp.dir/main.cxx.o
In file included from /Volumes/Academic/ITKVTK/Applications/ITKApps/DICOMApp/main.cxx:15:
/usr/local/include/ITK-4.8/itkDICOMImageIO2.h:119:3: error: use of undeclared identifier 'itkdicomparser'
  itkdicomparser::DICOMParser    *m_Parser;
  ^
/usr/local/include/ITK-4.8/itkDICOMImageIO2.h:120:3: error: use of undeclared identifier 'itkdicomparser'
  itkdicomparser::DICOMAppHelper *m_AppHelper;
  ^
/usr/local/include/ITK-4.8/itkDICOMImageIO2.h:124:25: error: use of undeclared identifier 'itkdicomparser'
                        itkdicomparser::DICOMParser::VRTypes type,
                        ^
/usr/local/include/ITK-4.8/itkDICOMImageIO2.h:45:3: error: cannot initialize object parameter of type 'const itk::Object' with an expression of type 'ObjectType' (aka 'itk::DICOMImageIO2')
  itkNewMacro(Self);
  ^~~~~~~~~~~~~~~~~
/usr/local/include/ITK-4.8/itkMacro.h:184:3: note: expanded from macro 'itkNewMacro'
  itkSimpleNewMacro(x)                                         \
  ^~~~~~~~~~~~~~~~~~~~
/usr/local/include/ITK-4.8/itkMacro.h:196:5: note: expanded from macro 'itkSimpleNewMacro'
    smartPtr->UnRegister();                                    \
    ^~~~~~~~
In file included from /Volumes/Academic/ITKVTK/Applications/ITKApps/DICOMApp/main.cxx:15:
/usr/local/include/ITK-4.8/itkDICOMImageIO2.h:45:3: error: no viable overloaded '='
  itkNewMacro(Self);
  ^~~~~~~~~~~~~~~~~
/usr/local/include/ITK-4.8/itkMacro.h:185:3: note: expanded from macro 'itkNewMacro'
  itkCreateAnotherMacro(x)                                     \
  ^~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/include/ITK-4.8/itkMacro.h:204:14: note: expanded from macro 'itkCreateAnotherMacro'
    smartPtr = x::New().GetPointer();                          \
    ~~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~
/usr/local/include/ITK-4.8/itkSmartPointer.h:128:18: note: candidate function not viable: no known conversion from 'ObjectType *' (aka 'itk::DICOMImageIO2 *') to
      'const itk::SmartPointer<itk::LightObject>' for 1st argument
  SmartPointer & operator=(const SmartPointer & r)
                 ^
/usr/local/include/ITK-4.8/itkSmartPointer.h:132:18: note: candidate function not viable: no known conversion from 'ObjectType *' (aka 'itk::DICOMImageIO2 *') to 'ObjectType *' (aka 'itk::LightObject *')
      for 1st argument
  SmartPointer & operator=(ObjectType *r)
                 ^
In file included from /Volumes/Academic/ITKVTK/Applications/ITKApps/DICOMApp/main.cxx:15:
/usr/local/include/ITK-4.8/itkDICOMImageIO2.h:45:3: error: cannot initialize object parameter of type 'const itk::LightObject' with an expression of type 'const itk::DICOMImageIO2'
  itkNewMacro(Self);
  ^~~~~~~~~~~~~~~~~
/usr/local/include/ITK-4.8/itkMacro.h:186:3: note: expanded from macro 'itkNewMacro'
  itkCloneMacro(x)
  ^~~~~~~~~~~~~~~~
/usr/local/include/ITK-4.8/itkMacro.h:212:25: note: expanded from macro 'itkCloneMacro'
      dynamic_cast<x *>(this->InternalClone().GetPointer());    \
                        ^~~~
In file included from /Volumes/Academic/ITKVTK/Applications/ITKApps/DICOMApp/main.cxx:14:
In file included from /usr/local/include/ITK-4.8/itkImage.h:21:
In file included from /usr/local/include/ITK-4.8/itkImageRegion.h:31:
In file included from /usr/local/include/ITK-4.8/itkRegion.h:31:
In file included from /usr/local/include/ITK-4.8/itkObject.h:31:
In file included from /usr/local/include/ITK-4.8/itkLightObject.h:21:
In file included from /usr/local/include/ITK-4.8/itkMacro.h:337:
In file included from /usr/local/include/ITK-4.8/itkExceptionObject.h:28:
/usr/local/include/ITK-4.8/itkSmartPointer.h:168:24: error: cannot initialize object parameter of type 'const itk::Object' with an expression of type 'ObjectType' (aka 'itk::DICOMImageIO2')
    if ( m_Pointer ) { m_Pointer->Register(); }
                       ^~~~~~~~~
/usr/local/include/ITK-4.8/itkSmartPointer.h:72:11: note: in instantiation of member function 'itk::SmartPointer<itk::DICOMImageIO2>::Register' requested here
  { this->Register(); }
          ^
/usr/local/include/ITK-4.8/itkObjectFactory.h:62:12: note: in instantiation of member function 'itk::SmartPointer<itk::DICOMImageIO2>::SmartPointer' requested here
    return dynamic_cast< T * >( ret.GetPointer() );
           ^
/usr/local/include/ITK-4.8/itkDICOMImageIO2.h:45:3: note: in instantiation of member function 'itk::ObjectFactory<itk::DICOMImageIO2>::Create' requested here
  itkNewMacro(Self);
  ^
/usr/local/include/ITK-4.8/itkMacro.h:184:3: note: expanded from macro 'itkNewMacro'
  itkSimpleNewMacro(x)                                         \
  ^
/usr/local/include/ITK-4.8/itkMacro.h:191:51: note: expanded from macro 'itkSimpleNewMacro'
    Pointer smartPtr = ::itk::ObjectFactory< x >::Create();    \
                                                  ^
In file included from /Volumes/Academic/ITKVTK/Applications/ITKApps/DICOMApp/main.cxx:14:
In file included from /usr/local/include/ITK-4.8/itkImage.h:21:
In file included from /usr/local/include/ITK-4.8/itkImageRegion.h:31:
In file included from /usr/local/include/ITK-4.8/itkRegion.h:31:
In file included from /usr/local/include/ITK-4.8/itkObject.h:31:
In file included from /usr/local/include/ITK-4.8/itkLightObject.h:21:
In file included from /usr/local/include/ITK-4.8/itkMacro.h:337:
In file included from /usr/local/include/ITK-4.8/itkExceptionObject.h:28:
/usr/local/include/ITK-4.8/itkSmartPointer.h:173:24: error: cannot initialize object parameter of type 'const itk::Object' with an expression of type 'ObjectType' (aka 'itk::DICOMImageIO2')
    if ( m_Pointer ) { m_Pointer->UnRegister(); }
                       ^~~~~~~~~
/usr/local/include/ITK-4.8/itkSmartPointer.h:77:11: note: in instantiation of member function 'itk::SmartPointer<itk::DICOMImageIO2>::UnRegister' requested here
    this->UnRegister();
          ^
/usr/local/include/ITK-4.8/itkDICOMImageIO2.h:45:3: note: in instantiation of member function 'itk::SmartPointer<itk::DICOMImageIO2>::~SmartPointer' requested here
  itkNewMacro(Self);
  ^
/usr/local/include/ITK-4.8/itkMacro.h:184:3: note: expanded from macro 'itkNewMacro'
  itkSimpleNewMacro(x)                                         \
  ^
/usr/local/include/ITK-4.8/itkMacro.h:191:24: note: expanded from macro 'itkSimpleNewMacro'
    Pointer smartPtr = ::itk::ObjectFactory< x >::Create();    \
                       ^
8 errors generated.
make[2]: *** [DICOMApp/CMakeFiles/DICOMApp.dir/main.cxx.o] Error 1
make[1]: *** [DICOMApp/CMakeFiles/DICOMApp.dir/all] Error 2
make: *** [all] Error 2


More information about the Community mailing list