[Insight-users] Re: WrapITK: more windows build errors
zpincus at stanford.edu
Tue Feb 14 17:27:26 EST 2006
It looks like (perhaps) GCC_XML is parsing itkMultiThreader.h
differently than VC++ is. Specifically, for POSIX systems,
ThreadFunctionType is 'void *(*ThreadFunctionType)(void *)', whereas
on windows systems it is 'void (*ThreadFunctionType)(void *)'. It
looks like you're getting a mix of the two.
The error you sent below may be because somehow GCC_XML is seeing
that typedef as for the POSIX case and then SWIG wrappers are
generated for that, but then VC++ sees the proper typedef and then
the SWIG wrapper code is wrong for the actual MultiThreader code.
(This would require that somehow ITK_USE_PTHREADS is defined when
GCC_XML parses the source. How could that happen?)
I've CC'd Brad on this because he might have some additional insight
on what's happening here, or how to deal with it.
Also, could you send me the entire function 'static PyObject
*_wrap_itkMultiThreader_SetMultipleMethod(PyObject *, PyObject
*args)' from wrap_ITKCommonBasePython.cxx (should be lines 4500-4600
or so) so I can check this theory out more carefully?
In the mean time, I think that WrapITK will work right without
wrappers for the multithreader. I'm not ready to say that it should
be removed from WrapITK though... but if we can't fix these build
problems, then maybe it will have to be.
On Feb 14, 2006, at 3:35 PM, Charl P. Botha wrote:
> On 2/14/06, Charl P. Botha <cpbotha at cpbotha.net> wrote:
>>> However, I would be first tempted to try using the CVS version of
>>> CableSwig -- this might be a Swig bug, which perhaps was fixed in
>> Eventually I'll probably try that, but for a toolset used by me and
>> others on Linux and Windows I wanted to standardise on "stable"
>> versions (or at least tags) of everything.
> Just another data point - Using a CVS checkout and build of CableSwig
> yields the same error:
> error C2664: 'itk::MultiThreader::SetMultipleMethod' : cannot convert
> parameter 2 from 'unsigned long (__cdecl *)(void *)' to
> 'itk::ThreadFunctionType'" and so forth.
> Insight-users mailing list
> Insight-users at itk.org
More information about the Insight-users