[Insight-developers] VS2010 and itkStdAlgorithm

Niels Dekker niels-xtk at xs4all.nl
Thu Apr 25 07:51:54 EDT 2013


On 2013-04-25 13:24, Marius Staring wrote:
> My VS2010 cannot build the latest ITK git due to the changes wrt
> itkStdAlgorithm.
...
> http://open.cdash.org/viewBuildError.php?buildid=2886200

I guess it goes wrong here in itkStdAlgorithm.h 
(www.itk.org/Doxygen/html/itkStdAlgorithm_8h_source.html):

   #if defined(ITK_HAS_STD_COPY_N)
   #if defined(__cplusplus) && (__cplusplus <= 199711L)
   #error ITK built with C++11, current source file is not.
   #endif
   #endif


Microsoft Visual Studio 2010 does have std::copy_n, so I guess 
ITK_HAS_STD_COPY_N is defined. However, Visual Studio 2010 was shipped 
before the C++11 standard, so for this compiler, __cplusplus is still 
199711L.

I'd suggested removing the #error from itkStdAlgorithm.h.

My 2 cents, Niels
-- 
Niels Dekker
http://www.xs4all.nl/~nd/dekkerware
Scientific programmer at LKEB, Leiden University Medical Center



More information about the Insight-developers mailing list