1

我试图在opensolaris 2009.6 上安装shoutpy。它依赖于 boost.python。我已经boost_devel从 blastwave 安装了库并链接/opt/csw/include/boost/usr/include/boost. 但是当我尝试easy_install shoutpy得到以下输出时

munderwo@opensolaris-test1:/usr/include$ pfexec easy_install shoutpy
Searching for shoutpy
Reading http://pypi.python.org/simple/shoutpy/
Reading http://dingoskidneys.com/shoutpy/
Best match: shoutpy 1.0.0
Downloading http://dingoskidneys.com/shoutpy/shoutpy-1.0.0.tar.gz
Processing shoutpy-1.0.0.tar.gz
Running shoutpy-1.0.0/setup.py -q bdist_egg --dist-dir /tmp/easy_install-w7XQfv/shoutpy-1.0.0/egg-dist-tmp-k11Dky
In file included from /usr/include/boost/python/object/make_instance.hpp:9,
                 from /usr/include/boost/python/object/make_ptr_instance.hpp:8,
                 from /usr/include/boost/python/to_python_indirect.hpp:11,
                 from /usr/include/boost/python/converter/arg_to_python.hpp:10,
                 from /usr/include/boost/python/call.hpp:15,
                 from /usr/include/boost/python/object_core.hpp:12,
                 from /usr/include/boost/python/args.hpp:25,
                 from /usr/include/boost/python.hpp:11,
                 from shoutpy.cc:26:
/usr/include/boost/python/object/instance.hpp:44: error: a casts to a type other than an integral or enumeration type cannot appear in a constant-expression
/usr/include/boost/python/object/instance.hpp:44: error: '->' cannot appear in a constant-expression
/usr/include/boost/python/object/instance.hpp:44: error: `&' cannot appear in a constant-expression
In file included from /usr/include/boost/python/converter/registry.hpp:9,
                 from /usr/include/boost/python/converter/registered.hpp:8,
                 from /usr/include/boost/python/object/make_instance.hpp:10,
                 from /usr/include/boost/python/object/make_ptr_instance.hpp:8,
                 from /usr/include/boost/python/to_python_indirect.hpp:11,
                 from /usr/include/boost/python/converter/arg_to_python.hpp:10,
                 from /usr/include/boost/python/call.hpp:15,
                 from /usr/include/boost/python/object_core.hpp:12,
                 from /usr/include/boost/python/args.hpp:25,
                 from /usr/include/boost/python.hpp:11,
                 from shoutpy.cc:26:
/usr/include/boost/python/converter/rvalue_from_python_data.hpp:99: error: '->' cannot appear in a constant-expression
/usr/include/boost/python/converter/rvalue_from_python_data.hpp:99: error: `&' cannot appear in a constant-expression
/usr/include/boost/python/converter/rvalue_from_python_data.hpp:99: error: template argument 1 is invalid
/usr/include/boost/python/converter/rvalue_from_python_data.hpp:99: error: `value' is not a member of `<declaration error>'
error: Setup script exited with error: command '/usr/lib/python2.6/pycc' failed with exit status 1

这是使用python2.6,opensolaris 2009.06,boost 1.35。

任何帮助都会很棒!

干杯

标记

编辑 - 这已在 serverfault 上交叉发布,因为它有点难以分类问题域在哪里。https://serverfault.com/questions/88724/problem-with-opensolaris-boost-python-and-shoutpy

4

1 回答 1

0

不幸的是,我从未尝试shoutpy在 OpenSolaris 下编译,而且这些天我也不使用它。Boost.python 对其 C++ 编译器有很多要求。使用easy_install -b build_directory shoutpy它会在失败后保留源代码,然后检查 C++ 编译器 Python 尝试使用的那些受 boost.python 支持的代码。

我尝试在我的桌面 Linux 上编译它,并且在我编辑setup.py链接后它仍然可以工作,libboost_python-mt而不是libboost_python在 Ubuntu 中不存在(有几个libboost_python*取决于 Python 版本等等)。

于 2009-12-07T17:47:52.000 回答