Posts: 23
Joined: Mar 2011
Reputation:
1
2011-05-07, 13:17
I need access to a shared library from within a plugin and need the ctypes module for that, but it doesn't seem to be available? Is there a way to install it?
(The python 2.6 that's installed by default on the system does work, just not the 2.4 included in XBMC itself)
Posts: 2,752
Joined: Dec 2008
Reputation:
23
bobo1on1
cheapass Team-XBMC Developer
Posts: 2,752
Python 2.4 doesn't have ctypes, you need to use the dl module.
Posts: 23
Joined: Mar 2011
Reputation:
1
Well, if it was only some calls with simple arguments it would be okay, but we're talking about an API that uses structs everywhere which makes it a bit difficult without ctypes.
Anyway, I found that if I copy the 2.4 ctype module to the plugin directory it works perfectly. Not an ideal situation but it will do for now.