Py_Initialize(); undefined reference...

Markus Heller markus at relix.de
Wed Dec 21 23:31:06 EST 2005


> I want to embed python into C++ and I have followed the documentation as
> given here:
> http://docs.python.org/api/
> I have stated an include to "Python.h" and now I want to initialize the
> Python framework. My compiler though says that the call to the function
> Py_Initialize() is an undefined reference.
> 
> My question to you: How can I change it so that the compiler sees that the
> function call is defined?

Hi guys,

no need to reply, I solved it. This issue is simply due to a linker
statement... I need to link the according python2.3 lib and that's it. 

Best wishes,
Markus



More information about the Python-list mailing list