[Insight-developers] ITK CVS HEAD, build error with Python, signal.h
Brad King
brad.king at kitware.com
Mon, 22 Mar 2004 09:26:26 -0500
Charl P. Botha wrote:
> Dear developers (and especially Brad),
>
> The watershed wrappings seem to work. I've been stress-testing them on
> the 1-6 branch and I'm now busy porting them to HEAD. However, I'm
> getting the following build error on Debian Stable, gcc 2.95.4, ITK CVS
> HEAD:
>
> Building wrap_ITKPyUtils.xml from
> /home/cpbotha/DoNotBackup/build/Insight-HEAD-
> VC6/Wrapping/CSwig/Common/wrap_ITKPyUtils.xml...
> In file included from /usr/include/signal.h:358,
> from /usr/include/python2.2/pyfpe.h:129,
> from /usr/include/python2.2/Python.h:122,
> from
> /home/cpbotha/DoNotBackup/build/Insight-HEAD/Wrapping/CSwi
> g/Common/itkPyCommand.h:22,
> from
> /home/cpbotha/DoNotBackup/build/Insight-HEAD/Wrapping/CSwi
> g/Common/wrap_ITKPyUtils.cxx:17:
> /usr/include/bits/sigthread.h:36: error: storage class specifiers
> invalid in
> parameter declarations
> /usr/include/bits/sigthread.h:36: error: storage class specified for
> parameter
> `parameter'
>
> Now, it seems that the compatibility header in CableSwig (pthread.h)
> would fix this problem in sigthread.h[1], but the Python header is
> bypassing that: Python.h -> pyfpe.h -> signal.h -> sigthread.h
>
> It would seem that a signal.h compatibility header is also required, as
> including signal.h (WITHOUT pthread.h) is a valid way of getting to
> sigthread.h.
>
> If this is so, should I add a signal.h header similar to the pthread.h
> header to all the GCC_XML compatibility header directories, or is there
> a better way(tm)?
Yes, please add the signal.h wrapper to to all the places that have a
pthread.h wrapper. Please test it by including all combinations of
relevant headers in all orders. We do not want two places to define
__thread at the same time.
Thanks,
-Brad