Include <cstddef> in python modules to workaround Swig bug.

* wrap/python/spot.i, wrap/python/buddy.i: Include <cstddef>
because Swig 2.0.2 uses ptrdiff_t and does not do the include
itself.  In g++ most libstdc++ standard headers have been changed
to no longer include <cstddef> as an implementation detail, so
the difference shows.
This commit is contained in:
Alexandre Duret-Lutz 2011-03-29 22:52:17 +02:00
parent 4ce06114d7
commit 35a0193781
3 changed files with 22 additions and 1 deletions

View file

@ -1,3 +1,13 @@
2011-03-29 Alexandre Duret-Lutz <adl@lrde.epita.fr>
Include <cstddef> in python modules to workaround Swig bug.
* wrap/python/spot.i, wrap/python/buddy.i: Include <cstddef>
because Swig 2.0.2 uses ptrdiff_t and does not do the include
itself. In g++ most libstdc++ standard headers have been changed
to no longer include <cstddef> as an implementation detail, so
the difference shows.
2011-03-20 Alexandre Duret-Lutz <adl@lrde.epita.fr>
* THANKS: Add Michael Weber for his help on the DiVinE interface.

View file

@ -1,4 +1,4 @@
// Copyright (C) 2010 Laboratoire de Recherche et Développement de l'EPITA.
// Copyright (C) 2010, 2011 Laboratoire de Recherche et Développement de l'EPITA.
// Copyright (C) 2003, 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
// et Marie Curie.
@ -52,6 +52,11 @@
MODIFICATIONS.
========================================================================*/
%{
// Workaround for SWIG 2.0.2 using ptrdiff_t but not including cstddef.
// It matters with g++ 4.6.
#include <cstddef>
%}
%module buddy

View file

@ -21,6 +21,12 @@
// Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
// 02111-1307, USA.
%{
// Workaround for SWIG 2.0.2 using ptrdiff_t but not including cstddef.
// It matters with g++ 4.6.
#include <cstddef>
%}
%module(directors="1") spot
%include "std_string.i"