> #include <python.h> > > char secret_code[] = "print 'moshe'"; > > int main() > { > return PyRun_SimpleString(secret_code); > } > > and you need to link with python24.lib or whatever the object file is > for your platform.
Are you sure? On a linux platform I tried linking with libpython2.4.so (I assume this is the correct object file) but it segfaults in PyImport_GetModuleDict( ). -- http://mail.python.org/mailman/listinfo/python-list