From: Alan W. I. <ir...@be...> - 2002-08-23 16:51:17
|
On Thu, 22 Aug 2002, Maurice LeBrun wrote: > Good news and bad news. The bad news is, it still doesn't work. The good > news is that it's the exact same error message I got with python2.2, so maybe > if a solution is found it will apply to both. Here it is: > > trinity$ ./pythondemos.py > Traceback (innermost last): > File "./pythondemos.py", line 15, in ? > from plplot import * > File "/home/mjl/dev/plplot/plpy/tmp/plplot.py", line 20, in ? > from plplotc import * > ImportError: dynamic module does not define init function (initplplotc) That reminds me of an error that Olof was getting on windows. The solution was to drop "module" from the name of the created shared object (i.e plplotc.so rather than plplotcmodule.so). I wondered at the time whether the windows version of python was no longer supporting those legacy-style 'module.so names, but perhaps it is Debian that is the odd man out by still allowing them. Note Gary has always used *.so names with "module" dropped, and that may be one key to his success on RedHat (and windows and mac os x). To try the shortened names, in plplot/tmp remove plplotcmodule.so and plplot_widgetmodule.so and change the lines in the (configure-generated) setup.py from module1 = Extension( "plplotcmodule", ==> module1 = Extension( "plplotc", and module2 = Extension( "plplot_widgetmodule", ==> module2 = Extension( "plplot_widget", Then execute make to generate plplotc.so and plplot_widget.so, etc. Let us know if that works. If it does, then go ahead and make the permanent setup.py.in changes and the modest configuration changes to do with the changed plplot*.so names. If that doesn't work for you, then my plan is to copy my test environment to a RH 7.3 box I have access to and then figure out what is best to do for that environment. However, I have no time to pursue that now. It would be at the top of my PLplot agenda once I have a chance to work on PLplot again in September or October, but I am hoping somebody else will figure it out before then. Alan |