Pau Freixes wrote:
The best way for add new path before call PyImport_Import is adding new string item into sys path object ?
The same way you'd add a path in Python: PyObject *sys_path; PyObject *path; sys_path = PySys_GetObject("path"); if (sys_path == NULL) return NULL; path = PyString_FromString("/your/path") if (path == NULL) return NULL; if (PyList_Append(sys_path, path) < 0) return NULL Py_RETURN_NONE; Christian -- http://mail.python.org/mailman/listinfo/python-list