Cygwin安装:graphviz和/或libcgraph缺少文件吗?

时间:2019-03-11 17:23:04

标签: cygwin graphviz pygraphviz

我一直试图在cygwin上'pip install pygraphviz'并继续遇到缺少的依赖项。我确实在cygwin下安装了libcgraph6-2.40.1-3和graphviz-2.40.1-3。软件包列表中没有可用的graphviz-devel(graphviz-debug也不起作用)。

首先找不到cgraph.h或cdt.h:

 gcc -fno-strict-aliasing -ggdb -O2 -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector-strong --param=ssp-buffer-size=4 -fdebug-prefix-map=/usr/src/ports/python2/python2-2.7.15-1.x86_64/build=/usr/src/debug/python2-2.7.15-1 -fdebug-prefix-map=/usr/src/ports/python2/python2-2.7.15-1.x86_64/src/Python-2.7.15=/usr/src/debug/python2-2.7.15-1 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/usr/include/python2.7 -c pygraphviz/graphviz_wrap.c -o build/temp.cygwin-3.0.3-x86_64-2.7/pygraphviz/graphviz_wrap.o
  pygraphviz/graphviz_wrap.c:2987:10: fatal error: graphviz/cgraph.h: No such file or directory
   #include "graphviz/cgraph.h"
            ^~~~~~~~~~~~~~~~~~~
  compilation terminated.
  error: command 'gcc' failed with exit status 1

graphvize / cdt.h的确切错误。我想知道是否还有其他遗漏。因此,我在cygwin包源tgz的头文件中找到了这些头文件,然后将它们复制到/ usr / include / graphviz /中,以作弊。下一个pip安装失败,因为(惊奇的是,它也找不到库):

 gcc -shared -Wl,--enable-auto-image-base -L. build/temp.cygwin-3.0.3-x86_64-2.7/pygraphviz/graphviz_wrap.o -L/usr/lib/python2.7/config -L/usr/lib -lcgraph -lcdt -lpython2.7 -o build/lib.cygwin-3.0.3-x86_64-2.7/pygraphviz/_graphviz.dll
  /usr/lib/gcc/x86_64-pc-cygwin/7.4.0/../../../../x86_64-pc-cygwin/bin/ld: cannot find -lcgraph
  /usr/lib/gcc/x86_64-pc-cygwin/7.4.0/../../../../x86_64-pc-cygwin/bin/ld: cannot find -lcdt
  collect2: error: ld returned 1 exit status
  error: command 'gcc' failed with exit status 1

有人在cygwin下有效地安装了pygraphviz吗?您能告诉我安装时在哪里找到这些标头和库吗?

0 个答案:

没有答案