我正在尝试按照这些说明安装PythonMagick。https://gist.github.com/tomekwojcik/2778301
当我到达$ make时,我得到这个错误
Making all in pythonmagick_src
CXX libpymagick_la-_DrawableFillRule.lo
_DrawableFillRule.cpp:3:10: fatal error: 'boost/python.hpp' file not found
#include <boost/python.hpp>
^
1 error generated.
make[1]: *** [libpymagick_la-_DrawableFillRule.lo] Error 1
make: *** [all-recursive] Error 1如何在项目中安装PythonMagick?无论哪种方式都行得通。我在互联网上找不到有用的说明。
发布于 2015-11-06 15:35:16
确保你有boost-python brew boost-python。请注意版本号,因为您需要将下面的1.59.0替换为正确的版本。
$ BOOST_ROOT=/usr/local/Cellar/boost/1.59.0
$ ./configure编辑Makefile和pythonmagick_src/Makefile以包含boost库。您正在寻找两行代码:DEFAULT_INCLUDES和LDFLAGS。您将在这些行的末尾添加boost路径,使它们看起来像这样:
DEFAULT_INCLUDES = -I. -I$(top_builddir)/config -I/usr/local/Cellar/boost/1.59.0/include
LDFLAGS = -L/usr/local/Cellar/boost-python/1.59.0/lib这应该可以解决编译/链接错误。
https://stackoverflow.com/questions/28162495
复制相似问题