I am embedding Python in a C program (on Linux 2.2.x, Debian 2.1), and
trying to run a script via PyRun_SimpleFile(). "print 'hello, world'"
works, but "import socket" dies. Can anyone help me find out why?
$ ./testfile
Traceback (innermost last):
File "jukebox_xml.py", line 1, in ?
import socket
ImportError: /usr/lib/python1.5/lib-dynload/socketmodule.so:
undefined symbol: _Py_NoneStruct
$ nm testfile | grep NoneStruct
0808ecfc D _Py_NoneStruct
And of course "import socket" works fine in /usr/bin/python.
--
Steven Work
Renaissance Labs
steve@renlabs.com
360 647-1833
trying to run a script via PyRun_SimpleFile(). "print 'hello, world'"
works, but "import socket" dies. Can anyone help me find out why?
$ ./testfile
Traceback (innermost last):
File "jukebox_xml.py", line 1, in ?
import socket
ImportError: /usr/lib/python1.5/lib-dynload/socketmodule.so:
undefined symbol: _Py_NoneStruct
$ nm testfile | grep NoneStruct
0808ecfc D _Py_NoneStruct
And of course "import socket" works fine in /usr/bin/python.
--
Steven Work
Renaissance Labs
steve@renlabs.com
360 647-1833