diff --git a/SWIG/Lib/perl5/perlrun.swg b/SWIG/Lib/perl5/perlrun.swg index 883359835..321f588bc 100644 --- a/SWIG/Lib/perl5/perlrun.swg +++ b/SWIG/Lib/perl5/perlrun.swg @@ -1,7 +1,7 @@ /*********************************************************************** * perlrun.swg * - * This file contains the runtime support for Ruby modules + * This file contains the runtime support for Perl modules * and includes code for managing global variables and pointer * type checking. * diff --git a/SWIG/Lib/perl5/perlruntime.swg b/SWIG/Lib/perl5/perlruntime.swg index 691a9a67f..1aed9c4d1 100644 --- a/SWIG/Lib/perl5/perlruntime.swg +++ b/SWIG/Lib/perl5/perlruntime.swg @@ -1,14 +1,23 @@ %insert(runtime) %{ -#include -#include -#include +#ifdef __cplusplus +/* Needed on some windows machines---since MS plays funny games with the header files under C++ */ +#include +#include +extern "C" { +#endif +#include "EXTERN.h" +#include "perl.h" +#include "XSUB.h" #ifndef pTHX_ #define pTHX_ #endif #include +#ifdef __cplusplus +} +#endif /* Macro to call an XS function */