[Insight-users] Compile issues with ITK - itkNumericTraits.h

Stefan group at spellgen.com
Wed Nov 24 18:30:44 EST 2004


I had a working copy of ITK 1.8.1 last week on a machine running SuSE 
9.1. Unfortunately its main hard drive crashed and I installed Fedora 
Core 3 on the new setup instead. As I try to compile ITK from the same 
source (1.8.1), I run into some interesting-looking compile-time issues. 
Trying the CVS source instead, I still have compile-time trouble, but in 
a different place this time. Here is the complaint from the compiler for 
the current CVS source (as of Nov 24, 5 pm CST).

=== final lines from top-level make ===
cmake.depends is up-to-date
/home/stefan/src/Insight-bin/Code/Numerics: building default_target
Building object file itkAmoebaOptimizer.o...
In file included from 
/home/stefan/src/Insight/Code/Numerics/itkSingleValuedCostFunction.h:23,
                 from 
/home/stefan/src/Insight/Code/Numerics/itkSingleValuedNonLinearOptimizer.h:21,
                 from 
/home/stefan/src/Insight/Code/Numerics/itkSingleValuedNonLinearVnlOptimizer.h:20,
                 from 
/home/stefan/src/Insight/Code/Numerics/itkAmoebaOptimizer.h:20,
                 from 
/home/stefan/src/Insight/Code/Numerics/itkAmoebaOptimizer.cxx:20:
/home/stefan/src/Insight/Code/Common/itkNumericTraits.h: In static 
member function `static T itk::NumericTraits<T>::NonpositiveMin()':
/home/stefan/src/Insight/Code/Common/itkNumericTraits.h:61: error: there 
are no arguments to `min' that depend on a template parameter, so a 
declaration of `min' must be available
/home/stefan/src/Insight/Code/Common/itkNumericTraits.h:61: error: (if 
you use `-fpermissive', G++ will accept your code, but allowing the use 
of an undeclared name is deprecated)
/home/stefan/src/Insight/Code/Common/itkEventObject.h: In member 
function `virtual void itk::AmoebaOptimizer::StartOptimization()':
/home/stefan/src/Insight/Code/Common/itkEventObject.h:137: error: 
`itk::StartEvent::StartEvent(const itk::StartEvent&)' is private
/home/stefan/src/Insight/Code/Numerics/itkAmoebaOptimizer.cxx:188: 
error: within this context
/home/stefan/src/Insight/Code/Common/itkEventObject.h:138: error: 
`itk::EndEvent::EndEvent(const itk::EndEvent&)' is private
/home/stefan/src/Insight/Code/Numerics/itkAmoebaOptimizer.cxx:226: 
error: within this context
make[5]: *** [itkAmoebaOptimizer.o] Error 1
make[4]: *** [default_target] Error 2
make[3]: *** [default_target_Numerics] Error 2
make[2]: *** [default_target] Error 2
make[1]: *** [default_target_Code] Error 2
make: *** [default_target] Error 2
=== end shell output ===

I use gcc 3.4.2, cmake 2.0.5
I notice in the compiler detection code that things above 3.2 are not 
considered - is this the problem here?

Thanks in advance for any help,

Stefan Engstrom




More information about the Insight-users mailing list