embedding python

William Park opengeometry at yahoo.ca
Tue Feb 3 07:48:29 CET 2004


Anand K Rayudu <anand at easi.soft.net> wrote:
> Hi All,
> 
> I have one problem with embedding python into my application.
> on HP-UX11 i created my application with linking libPython2.3.a
> And with my product i supply all extension dlls [ .so] and with  
> appropriate PYTHONHOME and PYTHONPATH set.
> 
> Every thing is fine till  i import math,
> When i import math [ For all extension modules ]
>  I get following error.
>     import math
> ImportError: dynamic module does not define init function (initmath)
> 
> But if i run python in shell it works fine,
> I am sure it is some thing to do with my application linking or some 
> thing like that.
> Could some one please suggest, how to solve  this problem.
> 
> It works fine on all other platforms.
> I call python using 'PyRunSimpleFile' Function.
> 
> Thanks in advance.
> 
> Anand

Did you compile with '-lm' ?
Eg:
    http://home.eol.ca/~parkw/index.html

-- 
William Park, Open Geometry Consulting, <opengeometry at yahoo.ca>
Linux solution for data management and processing. 



More information about the Python-list mailing list