| Author | Topic |
Posts: 11
Registered: June 2006
|
|
Cannot load python binding module
|
08 Apr '06 15:12
|
 |
|
Hello,
I have the same problem as described in
(*) http://www.sbml.org/forums/index.php?t=tree&goto=1099&rid=0
and I run eclipse 3.1.
As I understand from (*), it is important that python first looks
for libsbml.py and then for the two private and public *.so.
1) my first example, is the copy libsbmlpy.py of libsbml.py which is included in the PYTHONPATH before
the *.so s
2) my second example is libsbml.py which is included in the PYTHONPATH after the *.so s
2) terminates with
Traceback (most recent call last):
File "/home/olli/workspace/MSc_hello_world_py/test.py", line 4, in ?
import libsbml
ImportError: dynamic module does not define init function (initlibsbml)
as expected but
1) terminates with
Traceback (most recent call last):
File "/home/olli/workspace/MSc_hello_world_py/test.py", line 4, in ?
import libsbmlpy
File "/usr/local/lib/libsbmlpy.py", line 6, in ?
import _libsbml
ImportError: libsbml.so: cannot open shared object file: No such file or directory
which is supposed to work?
--------------------------
without Eclipse, essentially libsbmlpy.py is not found even though it is there (!?), and
the error from (2) above reproduces. I illustrate with some commmandline output:
#libsbmlpy.py is there
olliver:/usr/local/lib# ls
firmware libsbmlpy.py libsbmlpy.pyc python2.3 python2.4 site_ruby
#the *.so s are in the site-packages
olliver:/usr/local/lib/python2.3/site-packages# ls
_libsbml.so libsbml libsbml.2.3.4.so libsbml.a libsbml.pth libsbml.so
#pythonpath points to libsbml.py
olliver:/usr/local/lib/python2.3/site-packages# echo $PYTHONPATH
#the LD_LIBRARY_PATH points to the *.os s
/home/olli/scripting/src/tools:/usr/local/lib/python2.3/site-packages/libsbml:/usr/local/lib/
olliver:/usr/local/lib/python2.3/site-packages# echo $LD_LIBRARY_PATH
/usr/local/lib/python2.3/site-packages
Could you please help?
oliver
|
|
|