Hi, everyone,
I just started study boost.python. and have following problem
/boostpy.cc
#include <boost/python.hpp>
char const* greet()
{
return "hello, world";
}
BOOST_PYTHON_MODULE(boostpy)
{
using namespace boost::python;
def("greet", greet);
}
g++ boostpy.cc -lpython2.5 -I /usr/include/python2.5 -o boostpy.so -shared
It complies ,but when import it in python, I have following error,
<<<import boostpy
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: ./boostpy.so: undefined symbol: _ZN5boost6python6detail11init_
moduleEPKcPFvvE
any suggestion?
Thanks
--
Junwei Zhang
Office Phone:402-472-1968
[email protected]
www.junweizhang.com
Department of Electrical Engineering
University of Nebraska-Lincoln
209N Walter Scott Engineering Center
P.O. Box 880511
Lincoln, NE 68588-0511
--
Junwei Zhang
Office Phone:402-472-1968
[email protected]
www.junweizhang.com
Department of Electrical Engineering
University of Nebraska-Lincoln
209N Walter Scott Engineering Center
P.O. Box 880511
Lincoln, NE 68588-0511
_______________________________________________
Cplusplus-sig mailing list
[email protected]
http://mail.python.org/mailman/listinfo/cplusplus-sig