… | |
… | |
221 | AC_MSG_CHECKING(for $PERL suitability) |
221 | AC_MSG_CHECKING(for $PERL suitability) |
222 | if $PERL -MExtUtils::Embed -e "use v5.8" >/dev/null 2>/dev/null; then |
222 | if $PERL -MExtUtils::Embed -e "use v5.8" >/dev/null 2>/dev/null; then |
223 | |
223 | |
224 | save_CFLAGS="$CFLAGS" |
224 | save_CFLAGS="$CFLAGS" |
225 | save_LIBS="$LIBS" |
225 | save_LIBS="$LIBS" |
226 | CFLAGS="$CFLAGS `$PERL -MExtUtils::Embed -e ccopts`" |
226 | CFLAGS="$CFLAGS `$PERL -MExtUtils::Embed -e ccopts` `$PERL -MEvent::MakeMaker -e 'print +{&Event::MakeMaker::event_args}->{INC}'`" |
227 | LIBS="$LIBS `$PERL -MExtUtils::Embed -e ldopts`" |
227 | LIBS="$LIBS `$PERL -MExtUtils::Embed -e ldopts`" |
228 | AC_TRY_LINK([ |
228 | AC_TRY_LINK([ |
229 | #include <EXTERN.h> |
229 | #include <EXTERN.h> |
230 | #include <perl.h> |
230 | #include <perl.h> |
231 | #include <XSUB.h> |
231 | #include <XSUB.h> |
|
|
232 | #include "EventAPI.h" |
232 | ],[ |
233 | ],[ |
233 | PerlInterpreter *perl = perl_alloc (); |
234 | PerlInterpreter *perl = perl_alloc (); |
234 | ],[perl_link=yes],[perl_link=no]) |
235 | ],[perl_link=yes],[perl_link=no]) |
235 | CXXFLAGS="$save_CFLAGS" |
236 | CXXFLAGS="$save_CFLAGS" |
236 | LIBS="$save_LIBS" |
237 | LIBS="$save_LIBS" |
237 | |
238 | |
238 | if test x$perl_link = xyes; then |
239 | if test x$perl_link = xyes; then |
239 | AC_MSG_RESULT(ok) |
240 | AC_MSG_RESULT(ok) |
240 | AC_DEFINE(ENABLE_PERL, 1, Define if you can embed a perl interpreter) |
241 | AC_DEFINE(ENABLE_PERL, 1, Define if you can embed a perl interpreter) |
241 | PERLFLAGS="`$PERL -MExtUtils::Embed -e ccopts`" |
242 | PERLFLAGS="`$PERL -MExtUtils::Embed -e ccopts` `$PERL -MEvent::MakeMaker -e 'print +{&Event::MakeMaker::event_args}->{INC}'`" |
242 | PERLLIB="`$PERL -MExtUtils::Embed -e ldopts`" |
243 | PERLLIB="`$PERL -MExtUtils::Embed -e ldopts`" |
243 | PERLPRIVLIBEXP="`$PERL -MConfig -e 'print $Config{privlibexp}'`" |
244 | PERLPRIVLIBEXP="`$PERL -MConfig -e 'print $Config{privlibexp}'`" |
244 | PERL_PLUGIN=yes |
245 | PERL_PLUGIN=yes |
245 | else |
246 | else |
246 | AC_MSG_ERROR([no, unable to link]) |
247 | AC_MSG_ERROR([no, unable to link]) |