error installing libgd in mac 10.9

你。 提交于 2019-12-12 12:39:01

问题


I'm trying to install libgd on my mac OSX 10.9 following the instructions here (https://mikewest.org/2007/04/installing-libgd-from-source-on-os-x) and peaking on some more info here (Installing GD library for perl on MacOSX 10.6).

the main goal is to be able to install and use Circos.

i followed all the steps to install the various libraries libpgn, pibjpeg and freetype using mainly ./configure && make && make sudo install...however 1) the ./congigure command from libgd does not find the libraries that I just installed and what I get is the following:

** Configuration summary for libgd 2.1.0:

   Support for Zlib:                 yes
   Support for PNG library:          no
   Support for JPEG library:         no
   Support for VPX library:          no
   Support for TIFF library:         no
   Support for Freetype 2.x library: no
   Support for Fontconfig library:   no
   Support for Xpm library:          no
   Support for pthreads:             yes

i read the README file (yeeee) suggesting to use --with-png=myDirectory --with-freetype=myDir etc..i did that (not sure if it made a difference) but when I get to the make command I get the following error

Undefined symbols for architecture x86_64:
  "___sincos_stret", referenced from:
      _gdImageCopyRotated in gd.o
      _gdAffineRotate in gd_matrix.o
      _gdImageRotateNearestNeighbour in gd_interpolation.o
      _gdImageRotateGeneric in gd_interpolation.o
      _gdImageRotateBilinear in gd_interpolation.o
      _gdImageRotateBicubicFixed in gd_interpolation.o
      _filter_bessel in gd_interpolation.o
      ...
  "_iconv", referenced from:
      _do_convert in gdkanji.o
  "_iconv_close", referenced from:
      _do_convert in gdkanji.o
  "_iconv_open", referenced from:
      _do_convert in gdkanji.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [libgd.la] Error 1
make[1]: *** [all] Error 2
make: *** [all-recursive] Error 1

...more extensive in pastie: http://pastebin.com/BuvskMPe

so I'm stuck, I'm reading online and it looks like it has to do with Xcode and gcc but I can't find out how to troubleshoot this.

any help would be awesome!!


回答1:


I successfully installed it using homebrew. It was as simple as:

brew install gd

This installed lib-gd version 2.1.0_1.



来源:https://stackoverflow.com/questions/22059211/error-installing-libgd-in-mac-10-9

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!