[Insight-developers] ITK 3.14 cannot build with GCC on non-ix86
Steve M. Robbins
steve at sumost.ca
Wed Jul 22 02:07:50 EDT 2009
Hi,
Has anyone successfully built ITK using GCC on a platform other than
x86 or amd64?
The Debian builds for 3.14 are failing [1] on all platforms (other
than i386 and amd64), mainly with this error:
> /build/buildd-insighttoolkit_3.14.0-1-alpha-pWsSda/insighttoolkit-3.14.0/Utilities/vxl/core/vnl/vnl_math.h: In member function 'virtual void itk::SPSAOptimizer::GenerateDelta(unsigned int)':
> /build/buildd-insighttoolkit_3.14.0-1-alpha-pWsSda/insighttoolkit-3.14.0/Utilities/vxl/core/vnl/vnl_math.h:220: error: unknown register name 'st' in 'asm'
> make[3]: *** [Code/Numerics/CMakeFiles/ITKNumerics.dir/itkSPSAOptimizer.o] Error 1
My first guess is that the assembly code in vnl_math.h (the new
rounding functions) is actually ix86-specific. Can anyone confirm? Here is the
failing code, for reference:
inline int vnl_math_rnd_halfinttoeven(double x)
{
# ifdef VNL_CHECK_FPU_ROUNDING_MODE
assert(fegetround()==FE_TONEAREST);
# endif
int r;
__asm__ __volatile__ ("fistpl %0" : "=m"(r) : "t"(x) : "st");
return r;
}
Thanks,
-Steve
[1] https://buildd.debian.org/~luk/status/package.php?p=insighttoolkit
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://www.itk.org/mailman/private/insight-developers/attachments/20090722/d4153fa2/attachment.pgp>
More information about the Insight-developers
mailing list