2

我正在尝试在 Xcode4 中安装 GraphicsMagick,当我执行命令“make”时出现此错误。

/usr/bin/ranlib: file: magick/.libs/libGraphicsMagick.a(magick_libGraphicsMagick_la-module.o) has no symbols
/usr/bin/ranlib: file: magick/.libs/libGraphicsMagick.a(magick_libGraphicsMagick_la-PreRvIcccm.o) has no symbols
libtool: link: ranlib magick/.libs/libGraphicsMagick.a
ranlib: file: magick/.libs/libGraphicsMagick.a(magick_libGraphicsMagick_la-module.o) has no symbols
ranlib: file: magick/.libs/libGraphicsMagick.a(magick_libGraphicsMagick_la-PreRvIcccm.o) has no symbols


Undefined symbols for architecture x86_64:
  "___builtin_object_size", referenced from:
      _BlurImageScanlines.omp_fn.6 in libGraphicsMagick.a(magick_libGraphicsMagick_la-effect.o)
      _XShearImage.omp_fn.0 in libGraphicsMagick.a(magick_libGraphicsMagick_la-shear.o)
      _YShearImage.omp_fn.1 in libGraphicsMagick.a(magick_libGraphicsMagick_la-shear.o)
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
make[1]: *** [utilities/gm] Error 1
make: *** [install] Error 2
4

2 回答 2

2

GraphicsMagick 无法在 OS X 10.7 (Lion) 或 10.8 (Mountain Lion) 上使用默认的 LLVM GCC/G++ 编译器进行编译。解决方法是改用 Clang 编译器:

./configure CC=clang [...other config options...]

make check为了安全起见,在编译后运行单元测试也是一个好主意。

这个技巧对我有用,希望它有帮助。

于 2013-03-20T15:04:11.257 回答
0

您可以在这里找到解决方案。

http://sourceforge.net/projects/graphicsmagick/forums/forum/250738/topic/5221775

于 2013-03-21T04:48:01.107 回答