1
0
mirror of https://github.com/irssi/irssi.git synced 2024-12-04 14:46:39 -05:00

Initial Perl support.

git-svn-id: http://svn.irssi.org/repos/irssi/trunk@126 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Timo Sirainen 2000-02-20 23:28:50 +00:00 committed by cras
parent 141b4490b2
commit a95cb0aa60
2 changed files with 50 additions and 2 deletions

View File

@ -19,6 +19,7 @@
#undef HAVE_IPV6
#undef HAVE_POPT_H
#undef HAVE_SOCKS_H
#undef HAVE_PERL
/* macros/curses checks */
#undef HAS_CURSES

View File

@ -116,6 +116,19 @@ AC_ARG_WITH(plugins,
fi,
want_plugins=yes)
AC_ARG_ENABLE(perl,
[ --enable-perl Enable Perl scripting],
if test x$withval = xyes; then
want_perl=yes
else
if test "x$withval" = xno; then
want_perl=no
else
want_perl=yes
fi
fi,
want_perl=yes)
AC_ARG_WITH(servertest,
[ --with-servertest Build servertest],
if test x$withval = xyes; then
@ -330,6 +343,30 @@ else
has_curses=false
fi
AC_PATH_PROG(sedpath, sed)
if test "$want_perl" = yes; then
AC_PATH_PROG(perlpath, perl)
AC_MSG_CHECKING(for Perl compile flags)
PERL_CFLAGS=`$perlpath -MExtUtils::Embed -e ccopts 2>/dev/null`
if test "_$PERL_CFLAGS" = _ ; then
AC_MSG_RESULT([not found, building without perl.])
want_perl=no
else
PERL_LDFLAGS=`$perlpath -MExtUtils::Embed -e ldopts |$sedpath 's/-lgdbm //'`
PERL_LDFLAGS=`echo $PERL_LDFLAGS |$sedpath 's/-ldb //'`
PERL_LDFLAGS=`echo $PERL_LDFLAGS |$sedpath 's/-lndbm //'`
if test "$system" = "Linux"; then
PERL_LDFLAGS=`echo $PERL_LDFLAGS |$sedpath 's/-lnsl //'`
PERL_LDFLAGS=`echo $PERL_LDFLAGS |$sedpath 's/-lposix //'`
fi
PERL_LDFLAGS=`echo $PERL_LDFLAGS |$sedpath 's/-lc //'`
AC_MSG_RESULT(ok)
AC_SUBST(PERL_CFLAGS)
AC_SUBST(PERL_LDFLAGS)
AC_DEFINE(HAVE_PERL)
fi
fi
dnl ** check what we want to build
AM_CONDITIONAL(BUILD_GNOMEUI, test "x$GUI_LIBS" != "x")
AM_CONDITIONAL(BUILD_TEXTUI, test "$want_textui" = "yes")
@ -339,6 +376,7 @@ AM_CONDITIONAL(BUILD_SERVERTEST, test "$want_servertest" = "yes")
AM_CONDITIONAL(HAVE_GNOME, test "$want_gnome" = "yes")
AM_CONDITIONAL(HAVE_GNOME_PANEL, test "$want_gnome_panel" = "yes")
AM_CONDITIONAL(HAVE_MYSQL, test "$want_mysql" = "yes")
AM_CONDITIONAL(HAVE_PERL, test "$want_perl" = "yes")
AC_SUBST(MYSQL_LIBS)
@ -396,15 +434,23 @@ plugins/proxy/Makefile
plugins/external/Makefile
plugins/bot/Makefile
plugins/sql/Makefile
plugins/perl/Makefile.PL
stamp.h
irssi.spec)
dnl ** build actual the Makefile for Perl plugin
if test "x$want_perl" = "xyes"; then
cd plugins/perl
$perlpath Makefile.PL
cd ../..
fi
echo
if test "x$GUI_LIBS" != "x"; then
echo Building GTK frontend ...... : yes
echo Building GTK frontend ...... : yes
else
echo Building GTK frontend ...... : no
echo Building GTK frontend ...... : no
fi
echo Building with GNOME ........ : $want_gnome
echo Building with GNOME panel .. : $want_gnome_panel
@ -412,5 +458,6 @@ echo Building with GNOME panel .. : $want_gnome_panel
echo Building text frontend ..... : $want_textui
echo Building irssi-bot ......... : $want_irssibot
echo Building with IPv6 support . : $want_ipv6
echo Building with Perl support . : $want_perl
echo Install prefix ............. : $prefix