安装cairo-1.0.2失败

qq_26958775 2018-10-10 02:31:08
执行./configure --prefix=/usr/local
有如下信息
cairo will be compiled with the following surface backends:
Xlib: yes
Quartz: no
XCB: no
Win32: no
PostScript: no
PDF: no
glitz: no

the following font backends:
FreeType: no
Win32: no
ATSUI: no

and the following features:
PNG functions: no
configure: error: Cairo requires at least one font backend.
Please install freetype and fontconfig, then try again:
http://freetype.org/ http://fontconfig.org/
再执行 make
如下信息
make all-recursive
make[1]: Entering directory `/home/bss/igs/nodecanvas/cairo-1.0.2'
Making all in pixman
make[2]: Entering directory `/home/bss/igs/nodecanvas/cairo-1.0.2/pixman'
Making all in src
make[3]: Entering directory `/home/bss/igs/nodecanvas/cairo-1.0.2/pixman/src'
if /bin/sh ../../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../.. -I. -g -O2 -MT fbpict.lo -MD -MP -MF ".deps/fbpict.Tpo" -c -o fbpict.lo fbpict.c; \
then mv -f ".deps/fbpict.Tpo" ".deps/fbpict.Plo"; else rm -f ".deps/fbpict.Tpo"; exit 1; fi
gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../.. -I. -g -O2 -MT fbpict.lo -MD -MP -MF .deps/fbpict.Tpo -c fbpict.c -fPIC -DPIC -o .libs/fbpict.o
/tmp/ccU7WdtR.s: Assembler messages:
/tmp/ccU7WdtR.s:5383: Error: symbol `_cairo_pixman_composite' is already defined
make[3]: *** [fbpict.lo] 错误 1
make[3]: Leaving directory `/home/bss/igs/nodecanvas/cairo-1.0.2/pixman/src'
make[2]: *** [all-recursive] 错误 1
make[2]: Leaving directory `/home/bss/igs/nodecanvas/cairo-1.0.2/pixman'
make[1]: *** [all-recursive] 错误 1
make[1]: Leaving directory `/home/bss/igs/nodecanvas/cairo-1.0.2'
make: *** [all] 错误 2
...全文
455 5 打赏 收藏 转发到动态 举报
写回复
用AI写文章
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
qq_26958775 2018-10-16
  • 打赏
  • 举报
回复
[root@host03 cairo-1.10.2]# npm install canvas > canvas@1.6.13 install /home/bss/igs/node_modules/canvas > node-gyp rebuild Package /usr/local/lib/libpng was not found in the pkg-config search path. Perhaps you should add the directory containing `/usr/local/lib/libpng.pc' to the PKG_CONFIG_PATH environment variable Package '/usr/local/lib/libpng', required by 'cairo', not found gyp: Call to './util/has_lib.sh freetype' returned exit status 0 while in binding.gyp. while trying to load binding.gyp gyp ERR! configure error gyp ERR! stack Error: `gyp` failed with exit code: 1 gyp ERR! stack at ChildProcess.onCpExit (/home/bss/igs/node_js/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:345:16) gyp ERR! stack at emitTwo (events.js:126:13) gyp ERR! stack at ChildProcess.emit (events.js:214:7) gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:198:12) gyp ERR! System Linux 2.6.32-431.el6.x86_64 gyp ERR! command "/home/bss/igs/node_js/bin/node" "/home/bss/igs/node_js/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild" gyp ERR! cwd /home/bss/igs/node_modules/canvas gyp ERR! node -v v8.12.0 gyp ERR! node-gyp -v v3.8.0 gyp ERR! not ok npm WARN enoent ENOENT: no such file or directory, open '/home/bss/igs/package.json' npm WARN igs No description npm WARN igs No repository field. npm WARN igs No README data npm WARN igs No license field. npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! canvas@1.6.13 install: `node-gyp rebuild` npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the canvas@1.6.13 install script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2018-10-16T06_17_21_541Z-debug.log 现在是这种情况了
老马何以识途 2018-10-15
  • 打赏
  • 举报
回复
就是缺少gtkdoc-rebase吧,看名稱是文檔,可能影響不大。 或者你就上網下載一個咯。
幽饮烛 2018-10-13
  • 打赏
  • 举报
回复
configure 都失败了,Cairo requires at least one font backend.缺少字体库。

make[6]: [install-data-local] 错误 1 (忽略) 忽略的错误不用管。
qq_26958775 2018-10-11
  • 打赏
  • 举报
回复
我换了版本可以了 但是又出现了一个问题 编译通过 make install的时候 有个这样的错误 which: no gtkdoc-rebase in (/usr/java/jdk1.7.0_67-cloudera/bin:/opt/mqm/bin:./usr/java/jdk1.7.0_67-cloudera/bin:/opt/mqm/bin:./usr/lib64/qt-3.3/bin:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin/:/home/bss/bin:/usr/local/bin/) make[6]: [install-data-local] 错误 1 (忽略)
老马何以识途 2018-10-11
  • 打赏
  • 举报
回复
讓你先安裝字體,裝了沒有呢? 網上有説這是一個bug的,應該是pixman-remap.h裏面的重複定義。要不你先試試升級版本?

23,121

社区成员

发帖
与我相关
我的任务
社区描述
Linux/Unix社区 应用程序开发区
社区管理员
  • 应用程序开发区社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧