Erros when compiling a CPP program which uses CPython API functions

Christian Heimes lists at cheimes.de
Fri Dec 7 04:15:47 EST 2007


grbgooglefan wrote:
> I am compiling CPP program which uses CPython API functions from
> Python 2.5.1 source code
> 
> First I compiled with this commanline, that time I got "pyconfig.h"
> not found.

On Unix you have to run ./configure and make before you can use a source
tree. It creates a valid pyconfig.h for you. You may want to use the
./configure option --enable-shared.

> So, I added "-I../../PC" to my cmd line to get pyconfig.h, like:

PC/pyconfig.h is for Windows only!


Christian




More information about the Python-list mailing list