【问题标题】:Error when installing ITK with Python bindings使用 Python 绑定安装 ITK 时出错
【发布时间】:2013-09-17 12:49:41
【问题描述】:

我正在 OsX 10.8.4 上安装 ITK 4.2.2。我使用 Unix Makefiles 生成器使用 CMake 2.8.11.1 构建它。我需要 python 包装,所以我选择了ITK_WRAP_PYTHON。构建完成后,我进入终端中包含构建文件的目录并输入make。这一切都很顺利,直到我收到以下消息:

[ 41%] Generating vcl_complex.xml
In file included from /usr/include/c++/4.2.1/climits:50,
                 from /usr/include/c++/4.2.1/bits/stl_algobase.h:67,
                 from /usr/include/c++/4.2.1/bits/char_traits.h:46,
                 from /usr/include/c++/4.2.1/string:47,
                 from /Applications/ITK/src/Modules/Core/Common/include/itkMacro.h:46,
                 from /Applications/ITK/src/Modules/Core/Common/include/itkLightObject.h:21,
                 from /Applications/ITK/src/Modules/Core/Common/include/itkObject.h:31,
                 from /Applications/ITK/src/Modules/Core/Common/include/itkCommand.h:21,
                 from /Applications/ITK/build/Wrapping/Modules/ITKCommon/vcl_complex.cxx:1:
/usr/bin/../lib/clang/4.2/include/limits.h:37:54: error: missing binary operator before token "("
In file included from /usr/include/c++/4.2.1/bits/postypes.h:49,
                 from /usr/include/c++/4.2.1/iosfwd:49,
                 from /usr/include/c++/4.2.1/bits/stl_algobase.h:70,
                 from /usr/include/c++/4.2.1/bits/char_traits.h:46,
                 from /usr/include/c++/4.2.1/string:47,
                 from /Applications/ITK/src/Modules/Core/Common/include/itkMacro.h:46,
                 from /Applications/ITK/src/Modules/Core/Common/include/itkLightObject.h:21,
                 from /Applications/ITK/src/Modules/Core/Common/include/itkObject.h:31,
                 from /Applications/ITK/src/Modules/Core/Common/include/itkCommand.h:21,
                 from /Applications/ITK/build/Wrapping/Modules/ITKCommon/vcl_complex.cxx:1:
/usr/bin/../lib/clang/4.2/include/stdint.h:32:54: error: missing binary operator before token "("
make[2]: *** [Wrapping/Modules/ITKCommon/vcl_complex.xml] Error 1
make[1]: *** [Wrapping/Modules/ITKCommon/CMakeFiles/ITKCommonGccXML.dir/all] Error 2
make: *** [all] Error 2

此时我不确定它是否“有效”,因为它在许多不同的过程中多次从 1% 变为 100%,所以我输入了sudo make install。过了一会儿,我得到了同样的错误。

问题

  1. 如何消除此错误?
  2. 我需要重新开始安装吗?
  3. 如果我确实需要重新开始,有没有办法撤消我已经完成的操作以进行全新安装?

【问题讨论】:

    标签: python macos cmake itk


    【解决方案1】:

    GCC-XML(ITK 的 Python 包装中使用的工具)不支持 OSX 10.8 (clang) 的编译器。这将需要支持基于 Clang 的 GCC-XML 替代品 CastXML。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2017-04-22
      • 2017-09-16
      • 1970-01-01
      • 2018-12-09
      • 2017-05-08
      • 2020-10-09
      • 2020-09-03
      相关资源
      最近更新 更多