[SciPy-dev] Re: Scipy-dev digest, Vol 1 #11 - 1 msg

Robert Kern kern at caltech.edu
Thu Sep 27 14:48:52 CDT 2001


On Thu, Sep 27, 2001 at 08:10:57PM +0200, Pearu Peterson wrote:
> 
> 
> On Thu, 27 Sep 2001, Travis Oliphant wrote:
> 
> > > The problem I am running into in linalg is that I get compile errors
> > > in flapackmodule.c:
> > > ,----
> > > | linalg/flapackmodule.c:447: initializer element is not constant
> > > | linalg/flapackmodule.c:502: initializer element is not constant
> > > | linalg/flapackmodule.c:557: initializer element is not constant
> > > | linalg/flapackmodule.c:616: initializer element is not constant
> > > `----
> > >
> > > The respective code is
> > > ,----[flapackmodule.c: 447]
> > > | PyObject *cb_cselect_in_cgees__user__routines_capi = Py_None;
> > > `----
> > 
> > 
> > Well it looks like some more ifdefs are needed.
> > 
> > I think there is some DL_EXPORT macro that needs to be used somewhere for
> > it to work on CYGWIN.  Because this is an f2py generated file, I'm not
> > sure what to do.  Does f2py support Cygwin?
> 
> I have never tried cygwin but it is basically gcc (right?) and therefore
> I did not see any reasons why f2py generated code would fail on
> cygwin. However, it seems that I need to let f2py to put lines like 477
> above to init<module> () block. 

It's a silly Windows DLL-linking limitation. I don't know the technical details
of why one can't initialize pointers like that, but putting the assignment in
the init<module>() block will work. Also, if you compile with g++, it should
work (don't ask me why it works, but it does).

-- 
Robert Kern
kern at caltech.edu

"In the fields of hell where the grass grows high
 Are the graves of dreams allowed to die."
  -- Richard Harter



More information about the Scipy-dev mailing list