2022-06-06 06:08:49 -04:00
|
|
|
AC_INIT(irssi, 1.4.1)
|
2007-05-05 10:29:25 -04:00
|
|
|
AC_CONFIG_SRCDIR([src])
|
2008-01-21 06:30:58 -05:00
|
|
|
AC_CONFIG_AUX_DIR(build-aux)
|
2006-10-27 13:14:57 -04:00
|
|
|
AC_PREREQ(2.50)
|
1999-09-03 10:27:29 -04:00
|
|
|
|
2008-02-16 06:13:45 -05:00
|
|
|
AC_CONFIG_HEADERS([irssi-config.h])
|
2014-06-21 11:20:53 -04:00
|
|
|
AC_CONFIG_MACRO_DIR([m4])
|
2021-02-01 18:24:34 -05:00
|
|
|
AM_INIT_AUTOMAKE([1.9 no-define foreign subdir-objects nostdinc])
|
1999-09-03 10:27:29 -04:00
|
|
|
|
2015-10-02 12:57:06 -04:00
|
|
|
AM_SILENT_RULES([yes])
|
|
|
|
|
1999-09-03 10:27:29 -04:00
|
|
|
AM_MAINTAINER_MODE
|
|
|
|
|
|
|
|
AC_PROG_CC
|
|
|
|
AC_PROG_CPP
|
|
|
|
AM_PROG_LIBTOOL
|
|
|
|
|
2001-07-30 18:10:11 -04:00
|
|
|
AC_PATH_PROG(sedpath, sed)
|
|
|
|
AC_PATH_PROG(perlpath, perl)
|
|
|
|
|
2019-05-02 11:14:23 -04:00
|
|
|
PKG_INSTALLDIR
|
|
|
|
|
2008-03-14 06:34:34 -04:00
|
|
|
AC_CHECK_HEADERS(unistd.h dirent.h sys/ioctl.h sys/resource.h)
|
1999-09-03 10:27:29 -04:00
|
|
|
|
2000-10-26 14:12:20 -04:00
|
|
|
# check posix headers..
|
2016-01-29 10:08:40 -05:00
|
|
|
AC_CHECK_HEADERS(sys/socket.h sys/time.h sys/utsname.h)
|
2000-10-08 08:54:26 -04:00
|
|
|
|
2007-04-29 19:43:17 -04:00
|
|
|
AC_SYS_LARGEFILE
|
|
|
|
|
1999-09-03 10:27:29 -04:00
|
|
|
AC_ARG_WITH(socks,
|
|
|
|
[ --with-socks Build with socks support],
|
2007-12-06 05:16:02 -05:00
|
|
|
if test x$withval = xno; then
|
|
|
|
want_socks=no
|
1999-09-03 10:27:29 -04:00
|
|
|
else
|
2007-12-06 05:16:02 -05:00
|
|
|
want_socks=yes
|
1999-09-03 10:27:29 -04:00
|
|
|
fi,
|
|
|
|
want_socks=no)
|
|
|
|
|
|
|
|
AC_ARG_WITH(textui,
|
2008-03-04 17:57:01 -05:00
|
|
|
[ --without-textui Build without text frontend],
|
2007-12-06 05:16:02 -05:00
|
|
|
if test x$withval = xno; then
|
|
|
|
want_textui=no
|
1999-09-03 10:27:29 -04:00
|
|
|
else
|
2007-12-06 05:16:02 -05:00
|
|
|
want_textui=yes
|
1999-09-03 10:27:29 -04:00
|
|
|
fi,
|
|
|
|
want_textui=yes)
|
|
|
|
|
1999-10-02 06:29:01 -04:00
|
|
|
AC_ARG_WITH(bot,
|
|
|
|
[ --with-bot Build irssi-bot],
|
2007-12-06 05:16:02 -05:00
|
|
|
if test x$withval = xno; then
|
|
|
|
want_irssibot=no
|
1999-10-02 06:29:01 -04:00
|
|
|
else
|
2007-12-06 05:16:02 -05:00
|
|
|
want_irssibot=yes
|
1999-10-02 06:29:01 -04:00
|
|
|
fi,
|
2000-09-06 17:30:56 -04:00
|
|
|
want_irssibot=no)
|
1999-10-02 06:29:01 -04:00
|
|
|
|
2017-01-07 20:01:07 -05:00
|
|
|
AC_ARG_WITH(fuzzer,
|
|
|
|
[ --with-fuzzer Build irssi-fuzzer],
|
|
|
|
if test x$withval = xno; then
|
|
|
|
want_irssifuzzer=no
|
|
|
|
else
|
|
|
|
want_irssifuzzer=yes
|
|
|
|
fi,
|
|
|
|
want_irssifuzzer=no)
|
|
|
|
|
|
|
|
AC_ARG_WITH(fuzzer-lib,
|
|
|
|
[ --with-fuzzer-lib Specify path to fuzzer library],
|
|
|
|
fuzzerlibpath="$withval")
|
|
|
|
|
2000-09-29 19:59:51 -04:00
|
|
|
AC_ARG_WITH(proxy,
|
|
|
|
[ --with-proxy Build irssi-proxy],
|
2007-12-06 05:16:02 -05:00
|
|
|
if test x$withval = xno; then
|
|
|
|
want_irssiproxy=no
|
2000-09-29 19:59:51 -04:00
|
|
|
else
|
2007-12-06 05:16:02 -05:00
|
|
|
want_irssiproxy=yes
|
2000-09-29 19:59:51 -04:00
|
|
|
fi,
|
|
|
|
want_irssiproxy=no)
|
|
|
|
|
2000-05-29 12:37:00 -04:00
|
|
|
AC_ARG_WITH(modules,
|
|
|
|
[ --with-modules Specify what modules to build in binary],
|
2000-10-11 18:09:53 -04:00
|
|
|
if test x$withval != xyes -a x$withval != xno; then
|
|
|
|
build_modules="$withval"
|
|
|
|
fi)
|
1999-09-03 10:27:29 -04:00
|
|
|
|
2001-07-30 18:10:11 -04:00
|
|
|
if test "x$prefix" != "xNONE"; then
|
2007-12-05 18:13:53 -05:00
|
|
|
prefix=`eval echo $prefix`
|
2014-01-08 07:45:22 -05:00
|
|
|
PERL_MM_PARAMS="INSTALLDIRS=perl INSTALL_BASE=$prefix"
|
2001-10-22 16:34:05 -04:00
|
|
|
perl_set_use_lib=yes
|
2001-07-30 18:10:11 -04:00
|
|
|
|
|
|
|
perl_prefix_note=yes
|
2000-07-16 10:30:29 -04:00
|
|
|
fi
|
|
|
|
|
2001-10-24 19:17:27 -04:00
|
|
|
AC_ARG_WITH(perl-staticlib,
|
|
|
|
[ --with-perl-staticlib Specify that we want to link perl libraries
|
2002-08-26 15:32:15 -04:00
|
|
|
statically in irssi, default is no],
|
2007-12-06 05:16:02 -05:00
|
|
|
if test x$withval = xno; then
|
|
|
|
want_staticperllib=no
|
2001-10-24 19:17:27 -04:00
|
|
|
else
|
2007-12-06 05:16:02 -05:00
|
|
|
want_staticperllib=yes
|
2001-10-24 19:17:27 -04:00
|
|
|
fi,
|
|
|
|
want_staticperllib=no)
|
|
|
|
|
|
|
|
|
2001-07-30 18:10:11 -04:00
|
|
|
AC_ARG_WITH(perl-lib,
|
2016-05-09 10:55:35 -04:00
|
|
|
[ --with-perl-lib=[perl|site|vendor|DIR] Specify where to install the
|
2002-08-26 15:32:15 -04:00
|
|
|
Perl libraries for irssi, default is site],
|
2001-07-30 18:10:11 -04:00
|
|
|
if test "x$withval" = xyes; then
|
2000-10-03 18:57:14 -04:00
|
|
|
want_perl=yes
|
2001-07-30 18:10:11 -04:00
|
|
|
elif test "x$withval" = xno; then
|
|
|
|
want_perl=no
|
2016-05-09 10:55:35 -04:00
|
|
|
elif test "x$withval" = xperl; then
|
|
|
|
want_perl=yes
|
|
|
|
perl_prefix_note=no
|
|
|
|
PERL_MM_PARAMS="INSTALLDIRS=perl"
|
|
|
|
perl_set_use_lib=no
|
2001-07-30 18:10:11 -04:00
|
|
|
elif test "x$withval" = xsite; then
|
|
|
|
want_perl=yes
|
2001-10-14 11:19:57 -04:00
|
|
|
perl_prefix_note=no
|
2001-10-14 10:56:49 -04:00
|
|
|
PERL_MM_PARAMS=""
|
2016-05-09 10:55:35 -04:00
|
|
|
perl_set_use_lib=no
|
2001-07-30 18:10:11 -04:00
|
|
|
elif test "x$withval" = xvendor; then
|
|
|
|
want_perl=yes
|
2001-10-14 11:19:57 -04:00
|
|
|
perl_prefix_note=no
|
2001-07-30 18:10:11 -04:00
|
|
|
if test -z "`$perlpath -v|grep '5\.0'`"; then
|
|
|
|
PERL_MM_PARAMS="INSTALLDIRS=vendor"
|
2000-02-20 18:28:50 -05:00
|
|
|
else
|
2016-05-09 10:55:35 -04:00
|
|
|
PERL_MM_PARAMS="INSTALLDIRS=perl PREFIX=`$perlpath -e 'use Config; print $Config{prefix}'`"
|
2000-02-20 18:28:50 -05:00
|
|
|
fi
|
2016-05-09 10:55:35 -04:00
|
|
|
perl_set_use_lib=no
|
2001-07-30 18:10:11 -04:00
|
|
|
else
|
|
|
|
want_perl=yes
|
2001-10-14 11:19:57 -04:00
|
|
|
perl_prefix_note=no
|
2001-07-30 18:10:11 -04:00
|
|
|
PERL_MM_PARAMS="INSTALLDIRS=perl LIB=$withval"
|
2001-10-22 16:34:05 -04:00
|
|
|
perl_set_use_lib=yes
|
2000-02-20 18:28:50 -05:00
|
|
|
fi,
|
|
|
|
want_perl=yes)
|
|
|
|
|
2001-07-29 05:17:53 -04:00
|
|
|
AC_ARG_WITH(perl,
|
2001-10-20 17:32:22 -04:00
|
|
|
[ --with-perl[=yes|no|module] Build with Perl support - also specifies
|
2002-08-26 15:32:15 -04:00
|
|
|
if it should be built into main irssi binary
|
|
|
|
(static, default) or as module],
|
2001-07-29 05:17:53 -04:00
|
|
|
if test x$withval = xyes; then
|
2001-10-20 17:32:22 -04:00
|
|
|
want_perl=static
|
2001-07-29 05:17:53 -04:00
|
|
|
elif test x$withval = xstatic; then
|
2000-10-03 18:57:14 -04:00
|
|
|
want_perl=static
|
2001-10-20 17:32:22 -04:00
|
|
|
elif test x$withval = xmodule; then
|
|
|
|
want_perl=module
|
2000-10-03 18:57:14 -04:00
|
|
|
else
|
|
|
|
want_perl=no
|
|
|
|
fi,
|
2001-10-20 17:32:22 -04:00
|
|
|
want_perl=static)
|
2000-10-03 18:57:14 -04:00
|
|
|
|
2015-01-03 19:57:21 -05:00
|
|
|
AC_ARG_WITH(otr,
|
2018-02-26 18:04:56 -05:00
|
|
|
[ --with-otr[=yes|no|static] Build with OTR support - also specifies
|
2015-01-03 19:57:21 -05:00
|
|
|
if it should be built into the main irssi
|
2018-02-26 18:04:56 -05:00
|
|
|
binary (static) or as a module (default)],
|
2015-01-03 19:57:21 -05:00
|
|
|
if test x$withval = xyes; then
|
|
|
|
want_otr=module
|
|
|
|
elif test x$withval = xstatic; then
|
|
|
|
want_otr=static
|
|
|
|
elif test x$withval = xmodule; then
|
|
|
|
want_otr=module
|
|
|
|
else
|
|
|
|
want_otr=no
|
|
|
|
fi,
|
|
|
|
want_otr=no)
|
|
|
|
|
2014-01-09 09:20:29 -05:00
|
|
|
AC_ARG_ENABLE(true-color,
|
|
|
|
[ --enable-true-color Build with true color support in terminal],
|
|
|
|
if test x$enableval = xno ; then
|
|
|
|
want_truecolor=no
|
|
|
|
else
|
|
|
|
want_truecolor=yes
|
|
|
|
fi,
|
|
|
|
want_truecolor=no)
|
|
|
|
|
2017-01-03 06:04:56 -05:00
|
|
|
AC_ARG_ENABLE(gregex,
|
2017-07-29 07:32:15 -04:00
|
|
|
[ --disable-gregex Build without GRegex (fall back to regex.h)],
|
2017-01-03 06:04:56 -05:00
|
|
|
if test x$enableval = xno ; then
|
|
|
|
want_gregex=no
|
|
|
|
else
|
|
|
|
want_gregex=yes
|
|
|
|
fi,
|
|
|
|
want_gregex=yes)
|
|
|
|
|
2019-02-20 10:34:17 -05:00
|
|
|
AC_ARG_ENABLE(utf8proc,
|
|
|
|
[ --disable-utf8proc Build without Julia's utf8proc],
|
|
|
|
if test x$enableval = xno ; then
|
|
|
|
want_utf8proc=no
|
|
|
|
else
|
|
|
|
want_utf8proc=yes
|
|
|
|
fi,
|
|
|
|
want_utf8proc=yes)
|
|
|
|
|
2017-07-25 14:39:15 -04:00
|
|
|
AC_ARG_WITH(capsicum,
|
2017-07-25 15:15:14 -04:00
|
|
|
[ --with-capsicum Build with Capsicum support],
|
2017-07-25 14:39:15 -04:00
|
|
|
if test x$withval = xno; then
|
|
|
|
want_capsicum=no
|
|
|
|
else
|
|
|
|
want_capsicum=yes
|
|
|
|
fi,
|
|
|
|
want_capsicum=yes)
|
|
|
|
|
1999-09-03 10:27:29 -04:00
|
|
|
dnl **
|
|
|
|
dnl ** just some generic stuff...
|
|
|
|
dnl **
|
|
|
|
|
2001-03-03 16:01:36 -05:00
|
|
|
dnl * OS specific options
|
|
|
|
case "$host_os" in
|
|
|
|
hpux*)
|
|
|
|
CFLAGS="$CFLAGS -D_XOPEN_SOURCE_EXTENDED"
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
|
2002-01-14 08:30:21 -05:00
|
|
|
|
2014-07-21 19:39:16 -04:00
|
|
|
AC_SEARCH_LIBS([socket], [network socket])
|
2002-01-14 08:30:21 -05:00
|
|
|
|
2014-07-22 15:59:31 -04:00
|
|
|
AC_SEARCH_LIBS([inet_addr], [nsl])
|
2002-01-14 08:30:21 -05:00
|
|
|
|
|
|
|
dnl * gcc specific options
|
|
|
|
if test "x$ac_cv_prog_gcc" = "xyes"; then
|
|
|
|
CFLAGS="$CFLAGS -Wall"
|
|
|
|
fi
|
|
|
|
|
2014-07-22 16:36:49 -04:00
|
|
|
AC_CHECK_TYPE(socklen_t, ,
|
|
|
|
[AC_DEFINE([socklen_t], [int], [Define to 'int' if <sys/socket.h> doesn't define.])], [
|
|
|
|
AC_INCLUDES_DEFAULT
|
|
|
|
#ifdef HAVE_SYS_SOCKET_H
|
|
|
|
# include <sys/socket.h>
|
|
|
|
#endif
|
|
|
|
])
|
2000-03-26 11:46:40 -05:00
|
|
|
|
2002-11-21 12:48:40 -05:00
|
|
|
AC_CHECK_SIZEOF(int)
|
|
|
|
AC_CHECK_SIZEOF(long)
|
|
|
|
AC_CHECK_SIZEOF(long long)
|
2006-10-27 13:14:57 -04:00
|
|
|
AC_CHECK_SIZEOF(off_t)
|
2002-11-21 12:48:40 -05:00
|
|
|
|
2006-10-27 13:14:57 -04:00
|
|
|
if test $ac_cv_sizeof_off_t = 8; then
|
2002-11-21 12:48:40 -05:00
|
|
|
offt_64bit=yes
|
|
|
|
else
|
|
|
|
offt_64bit=no
|
|
|
|
fi
|
|
|
|
|
1999-09-03 10:27:29 -04:00
|
|
|
dnl **
|
|
|
|
dnl ** check for socks
|
|
|
|
dnl **
|
|
|
|
|
|
|
|
if test "x$want_socks" = "xyes"; then
|
|
|
|
AC_CHECK_LIB(socks, connect, [
|
2005-10-21 08:48:07 -04:00
|
|
|
AC_DEFINE(HAVE_SOCKS,, Build with socks support)
|
2001-10-28 06:30:26 -05:00
|
|
|
LIBS="$LIBS -lsocks"
|
1999-09-03 10:27:29 -04:00
|
|
|
AC_CHECK_HEADER(socks.h, [
|
|
|
|
AC_DEFINE(HAVE_SOCKS_H)
|
|
|
|
CFLAGS="$CFLAGS -DSOCKS"
|
|
|
|
AC_MSG_RESULT(["socks5 library found, building with it"])
|
|
|
|
], [
|
|
|
|
AC_MSG_RESULT(["socks4 library found, building with it"])
|
|
|
|
CFLAGS="$CFLAGS -Dconnect=Rconnect -Dgetsockname=Rgetsockname -Dgetpeername=Rgetpeername -Dbind=Rbind -Daccept=Raccept -Dlisten=Rlisten -Dselect=Rselect"
|
|
|
|
])
|
|
|
|
])
|
|
|
|
fi
|
|
|
|
|
|
|
|
dnl **
|
2000-04-26 04:10:09 -04:00
|
|
|
dnl ** fe-text checks
|
1999-09-03 10:27:29 -04:00
|
|
|
dnl **
|
|
|
|
|
2007-05-20 19:13:29 -04:00
|
|
|
for try in 1 2; do
|
|
|
|
if test $try = 1; then
|
2007-04-14 11:17:19 -04:00
|
|
|
glib_modules=gmodule
|
2001-01-15 19:14:14 -05:00
|
|
|
else
|
2007-04-14 11:17:19 -04:00
|
|
|
echo "*** trying without -lgmodule"
|
|
|
|
glib_modules=
|
2001-01-15 19:14:14 -05:00
|
|
|
fi
|
2021-01-28 15:25:53 -05:00
|
|
|
AM_PATH_GLIB_2_0(2.32.0,,, $glib_modules)
|
2007-04-14 11:17:19 -04:00
|
|
|
if test "$GLIB_LIBS"; then
|
|
|
|
if test $glib_modules = gmodule; then
|
|
|
|
AC_DEFINE(HAVE_GMODULE)
|
|
|
|
have_gmodule=yes
|
2001-02-23 03:07:10 -05:00
|
|
|
fi
|
2007-04-14 11:17:19 -04:00
|
|
|
break
|
2000-11-23 17:42:37 -05:00
|
|
|
fi
|
2007-04-14 11:17:19 -04:00
|
|
|
done
|
|
|
|
|
|
|
|
if test -z "$GLIB_LIBS"; then
|
|
|
|
echo
|
|
|
|
echo "*** If you don't have GLIB, you can get it from ftp://ftp.gtk.org/pub/glib/"
|
|
|
|
echo "*** We recommend you get the latest stable GLIB 2 version."
|
|
|
|
echo "*** Compile and install it, and make sure pkg-config finds it,"
|
|
|
|
echo "*** by adding the path where the .pc file is located to PKG_CONFIG_PATH"
|
2014-07-07 17:41:38 -04:00
|
|
|
echo -n "*** Or alternatively install your distribution's package"
|
|
|
|
if test -f /etc/debian_version; then
|
|
|
|
echo :
|
|
|
|
echo "*** sudo apt-get install libglib2.0-dev"
|
|
|
|
elif test -f /etc/redhat-release; then
|
|
|
|
echo " (glib2-devel)"
|
|
|
|
else
|
|
|
|
echo .
|
|
|
|
fi
|
2007-04-14 11:17:19 -04:00
|
|
|
echo
|
|
|
|
|
|
|
|
AC_ERROR([GLIB is required to build irssi.])
|
2000-07-31 16:17:33 -04:00
|
|
|
fi
|
1999-09-03 10:27:29 -04:00
|
|
|
|
Get back to using pkg-config to check for OpenSSL
Commit 6300dfec7 removed the option to disable SSL support from the
configure script since it became a requirement, but it also removed the
use of pkg-config for finding the OpenSSL library and its dependencies.
This had the unfortunate consequence of breaking the correct detection
of library flags in many static linking scenarios. In some cases, for
example, OpenSSL might have been built with zlib, which requires `-lz`
to be passed to the linker when doing a static link of the irssi
executable. Thus, pkg-config becomes an invaluable tool in such
situations, since no guessing work is needed as the OpenSSL .pc file
provides all the necessary flags.
So, this commit re-inserts the PKG_CHECK_MODULES macro in the configure
script when looking for OpenSSL. The test using AC_CHECK_LIB remains,
but only as a last resort in case the one using pkg-config fails.
Also, because the macro AM_PATH_GLIB_2_0 contains an unconditional call
to PKG_PROG_PKG_CONFIG, the OpenSSL checks are moved so that they come
after the Glib ones in order to avoid doubly checking for the pkg-config
binary (PKG_CHECK_MODULES skips that check if it has been performed
before, but PKG_PROG_PKG_CONFIG does not).
2017-03-20 12:17:42 -04:00
|
|
|
LIBS="$LIBS $GLIB_LIBS"
|
|
|
|
|
2017-11-26 10:19:31 -05:00
|
|
|
GLIB_TESTS
|
|
|
|
|
Get back to using pkg-config to check for OpenSSL
Commit 6300dfec7 removed the option to disable SSL support from the
configure script since it became a requirement, but it also removed the
use of pkg-config for finding the OpenSSL library and its dependencies.
This had the unfortunate consequence of breaking the correct detection
of library flags in many static linking scenarios. In some cases, for
example, OpenSSL might have been built with zlib, which requires `-lz`
to be passed to the linker when doing a static link of the irssi
executable. Thus, pkg-config becomes an invaluable tool in such
situations, since no guessing work is needed as the OpenSSL .pc file
provides all the necessary flags.
So, this commit re-inserts the PKG_CHECK_MODULES macro in the configure
script when looking for OpenSSL. The test using AC_CHECK_LIB remains,
but only as a last resort in case the one using pkg-config fails.
Also, because the macro AM_PATH_GLIB_2_0 contains an unconditional call
to PKG_PROG_PKG_CONFIG, the OpenSSL checks are moved so that they come
after the Glib ones in order to avoid doubly checking for the pkg-config
binary (PKG_CHECK_MODULES skips that check if it has been performed
before, but PKG_PROG_PKG_CONFIG does not).
2017-03-20 12:17:42 -04:00
|
|
|
dnl **
|
|
|
|
dnl ** OpenSSL checks
|
|
|
|
dnl **
|
|
|
|
PKG_CHECK_MODULES([OPENSSL], [openssl], [
|
|
|
|
CFLAGS="$CFLAGS $OPENSSL_CFLAGS"
|
|
|
|
LIBS="$LIBS $OPENSSL_LIBS"
|
|
|
|
], [
|
|
|
|
AC_CHECK_LIB([ssl], [SSL_library_init], [
|
|
|
|
LIBS="$LIBS -lssl -lcrypto"
|
|
|
|
], [
|
|
|
|
AC_MSG_ERROR([The OpenSSL library was not found])
|
|
|
|
])
|
|
|
|
])
|
2002-08-26 20:27:43 -04:00
|
|
|
|
2018-08-23 07:16:50 -04:00
|
|
|
dnl **
|
|
|
|
dnl ** utf8proc
|
|
|
|
dnl **
|
2019-02-20 10:34:17 -05:00
|
|
|
if test "x$want_utf8proc" != "xno"; then
|
|
|
|
AC_CHECK_HEADER([utf8proc.h], [
|
|
|
|
AC_CHECK_LIB([utf8proc], [utf8proc_version], [
|
|
|
|
want_utf8proc=yes
|
2019-03-08 05:24:16 -05:00
|
|
|
AC_DEFINE(HAVE_LIBUTF8PROC,, [Define to 1 if you have the `utf8proc' library (-lutf8proc).])
|
2019-02-20 10:34:17 -05:00
|
|
|
LIBS="$LIBS -lutf8proc"
|
|
|
|
], [
|
|
|
|
want_utf8proc="no, library not found"
|
|
|
|
])
|
|
|
|
], [
|
|
|
|
want_utf8proc="no, library header not found"
|
|
|
|
])
|
|
|
|
fi
|
2018-08-23 07:16:50 -04:00
|
|
|
|
1999-09-03 10:27:29 -04:00
|
|
|
dnl **
|
|
|
|
dnl ** curses checks
|
|
|
|
dnl **
|
|
|
|
|
2016-03-30 04:14:57 -04:00
|
|
|
if test "x$want_textui" != "xno"; then
|
|
|
|
|
|
|
|
TEXTUI_NO_LIBS="$LIBS"
|
|
|
|
LIBS=
|
2017-05-04 06:27:23 -04:00
|
|
|
AC_SEARCH_LIBS([setupterm], [tinfo ncursesw ncurses terminfo], [want_textui=yes], [
|
2016-03-30 04:14:57 -04:00
|
|
|
AC_ERROR(Terminfo not found - install libncurses-dev or ncurses-devel package)
|
|
|
|
want_textui="no, Terminfo not found"
|
|
|
|
])
|
|
|
|
|
|
|
|
TEXTUI_LIBS="$LIBS"
|
2002-08-26 19:58:59 -04:00
|
|
|
AC_SUBST(TEXTUI_LIBS)
|
2016-03-30 04:14:57 -04:00
|
|
|
LIBS="$TEXTUI_NO_LIBS"
|
2002-08-26 19:58:59 -04:00
|
|
|
|
2021-03-26 22:20:22 -04:00
|
|
|
AC_CHECK_HEADER([term.h], [
|
|
|
|
AC_DEFINE(HAVE_TERM_H, [], [Define to 1 if you have the `term.h' header.])
|
|
|
|
])
|
|
|
|
|
1999-09-03 10:27:29 -04:00
|
|
|
fi
|
|
|
|
|
2017-01-07 20:01:07 -05:00
|
|
|
dnl **
|
|
|
|
dnl ** irssifuzzer checks
|
|
|
|
dnl **
|
|
|
|
|
|
|
|
if test "$want_irssifuzzer" != "no"; then
|
|
|
|
dnl * we need to build with -fsanitize-coverage=trace-pc-guard
|
|
|
|
dnl * otherwise fuzzer won't be very successful at finding bugs :)
|
|
|
|
if test -z "$SANFLAGS"; then
|
|
|
|
SANFLAGS="-g -fsanitize=address -fsanitize-coverage=trace-pc-guard"
|
|
|
|
fi
|
|
|
|
CFLAGS="$CFLAGS $SANFLAGS"
|
|
|
|
CXXFLAGS="$CXXFLAGS $SANFLAGS"
|
|
|
|
|
|
|
|
AC_MSG_CHECKING(for fuzzer library)
|
|
|
|
|
|
|
|
if test -z "$fuzzerlibpath"; then
|
|
|
|
AC_MSG_RESULT([not found, building without fuzzer front end])
|
|
|
|
want_irssifuzzer=no
|
|
|
|
else
|
|
|
|
FUZZER_LIBS="$fuzzerlibpath"
|
|
|
|
AC_SUBST(FUZZER_LIBS)
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
2001-01-01 05:42:15 -05:00
|
|
|
dnl **
|
|
|
|
dnl ** perl checks
|
|
|
|
dnl **
|
|
|
|
|
2000-10-03 18:57:14 -04:00
|
|
|
if test "$want_perl" != "no"; then
|
2001-02-22 15:39:35 -05:00
|
|
|
AC_MSG_CHECKING(for working Perl support)
|
|
|
|
|
2001-07-14 15:34:28 -04:00
|
|
|
if test -z "$perlpath"; then
|
2007-12-05 18:13:53 -05:00
|
|
|
perl_check_error="perl binary not found"
|
2001-02-22 15:39:35 -05:00
|
|
|
else
|
|
|
|
PERL_CFLAGS=`$perlpath -MExtUtils::Embed -e ccopts 2>/dev/null`
|
|
|
|
fi
|
2000-02-24 16:14:44 -05:00
|
|
|
|
2002-11-02 18:20:50 -05:00
|
|
|
if test "x$ac_cv_prog_gcc" = "xyes" -a -z "`echo $host_os|grep 'bsd\|linux'`"; then
|
2002-10-27 19:12:42 -05:00
|
|
|
dnl * several systems have Perl compiled with native compiler
|
|
|
|
dnl * but irssi is being compiled with GCC. Here we try to
|
|
|
|
dnl * fix those command line options a bit so GCC won't
|
|
|
|
dnl * complain about them. Normally there's only few options
|
|
|
|
dnl * that we want to keep:
|
2018-09-02 19:30:48 -04:00
|
|
|
dnl * -Ddefine -Uundef -I/path -fopt -mopt -iwithsysroot
|
|
|
|
PERL_CFLAGS=`echo $PERL_CFLAGS | $perlpath -pe 's/^(.* )?-@<:@^DUIifm@:>@@<:@^ @:>@+/\1/g; s/^(.* )?\+@<:@^ @:>@+/\1/g'`
|
2002-11-17 09:18:11 -05:00
|
|
|
|
|
|
|
PERL_EXTRA_OPTS="CCCDLFLAGS=\"-fPIC\""
|
|
|
|
AC_SUBST(PERL_EXTRA_OPTS)
|
2002-10-27 19:12:42 -05:00
|
|
|
fi
|
|
|
|
|
2001-07-14 14:46:19 -04:00
|
|
|
if test -z "$PERL_CFLAGS"; then
|
|
|
|
if test -n "$perl_check_error"; then
|
|
|
|
perl_check_error="Error getting perl CFLAGS"
|
|
|
|
fi
|
2001-02-22 15:39:35 -05:00
|
|
|
AC_MSG_RESULT([not found, building without Perl])
|
2000-02-24 16:14:44 -05:00
|
|
|
want_perl=no
|
|
|
|
else
|
2001-01-01 05:42:15 -05:00
|
|
|
PERL_LDFLAGS=`$perlpath -MExtUtils::Embed -e ldopts 2>/dev/null`
|
2000-09-07 17:55:58 -04:00
|
|
|
|
|
|
|
dnl * remove all database stuffs
|
|
|
|
dnl * nsl is already in ldflags
|
2001-02-23 03:07:10 -05:00
|
|
|
dnl * libc is of course linked without needing -lc
|
|
|
|
dnl * -rdynamic must not be in LIBADD line
|
2001-04-09 12:36:28 -04:00
|
|
|
for word in -ldb -ldbm -lndbm -lgdbm -lc -rdynamic; do
|
2001-02-23 03:07:10 -05:00
|
|
|
PERL_LDFLAGS=`echo $PERL_LDFLAGS | $sedpath -e "s/$word //" -e "s/$word$//"`
|
|
|
|
done
|
2000-02-24 16:14:44 -05:00
|
|
|
|
2001-02-23 03:07:10 -05:00
|
|
|
case "$host_os" in
|
|
|
|
linux*)
|
|
|
|
PERL_LDFLAGS=`echo $PERL_LDFLAGS | $sedpath -e 's/-lposix //' -e 's/-lposix$//'`
|
|
|
|
;;
|
|
|
|
hpux*)
|
|
|
|
if test "x$ac_cv_prog_gcc" = "xyes"; then
|
|
|
|
PERL_CFLAGS=`echo $PERL_CFLAGS | $sedpath -e 's/-Ae //' -e 's/-Ae$//'`
|
|
|
|
PERL_LDFLAGS=`echo $PERL_LDFLAGS | $sedpath -e 's/-Ae //' -e 's/-Ae$//'`
|
|
|
|
fi
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
;;
|
|
|
|
esac
|
2000-09-07 17:55:58 -04:00
|
|
|
|
2001-02-22 15:39:35 -05:00
|
|
|
dnl * check that perl's ldflags actually work
|
2014-07-06 13:56:17 -04:00
|
|
|
echo "#include <EXTERN.h>" > conftest.c
|
|
|
|
echo "#include <perl.h>" >> conftest.c
|
|
|
|
echo "int main(){perl_alloc(); return 0;}" >> conftest.c
|
|
|
|
$CC $CFLAGS $PERL_CFLAGS conftest.c -o conftest $LDFLAGS $PERL_LDFLAGS 2> perl.error.tmp > /dev/null
|
2002-12-23 01:39:26 -05:00
|
|
|
if test ! -s conftest -a "x$ignore_perl_errors" = "x"; then
|
2001-10-23 16:30:01 -04:00
|
|
|
perl_check_error="Error linking with perl libraries: $PERL_LDFLAGS: `cat perl.error.tmp`"
|
2001-02-22 15:39:35 -05:00
|
|
|
AC_MSG_RESULT([error linking with perl libraries, building without Perl])
|
|
|
|
want_perl=no
|
|
|
|
fi
|
2002-04-29 13:17:17 -04:00
|
|
|
|
2001-10-23 16:30:01 -04:00
|
|
|
rm -f perl.error.tmp
|
2001-02-22 15:39:35 -05:00
|
|
|
fi
|
|
|
|
|
|
|
|
if test "x$want_perl" != "xno"; then
|
2008-11-23 04:48:48 -05:00
|
|
|
AC_MSG_RESULT(ok)
|
2000-03-11 15:19:24 -05:00
|
|
|
|
2000-10-03 18:57:14 -04:00
|
|
|
if test "x$want_perl" = "xstatic"; then
|
2000-10-03 20:22:59 -04:00
|
|
|
dnl * building with static perl support
|
|
|
|
dnl * all PERL_LDFLAGS linking is done in fe-text
|
2001-07-29 05:17:53 -04:00
|
|
|
PERL_LINK_FLAGS="$PERL_LDFLAGS"
|
|
|
|
PERL_LINK_LIBS="../perl/libperl_core_static.la"
|
|
|
|
PERL_FE_LINK_LIBS="../perl/libfe_perl_static.la"
|
2000-10-03 18:57:14 -04:00
|
|
|
PERL_LDFLAGS=
|
|
|
|
AC_DEFINE(HAVE_STATIC_PERL)
|
2000-10-03 20:22:59 -04:00
|
|
|
|
|
|
|
dnl * build only static library of perl module
|
2001-02-17 05:35:35 -05:00
|
|
|
perl_module_lib=
|
2001-07-29 05:17:53 -04:00
|
|
|
perl_module_fe_lib=
|
|
|
|
perl_static_lib=libperl_core_static.la
|
|
|
|
perl_static_fe_lib=libfe_perl_static.la
|
2000-10-03 19:54:56 -04:00
|
|
|
else
|
2001-05-31 17:19:29 -04:00
|
|
|
dnl * build dynamic library of perl module
|
2001-02-17 05:35:35 -05:00
|
|
|
perl_module_lib=libperl_core.la
|
2001-07-29 05:17:53 -04:00
|
|
|
perl_module_fe_lib=libfe_perl.la
|
2001-02-17 05:35:35 -05:00
|
|
|
perl_static_lib=
|
2001-07-29 05:17:53 -04:00
|
|
|
perl_static_fe_lib=
|
2000-09-07 17:55:58 -04:00
|
|
|
fi
|
2001-10-22 16:34:05 -04:00
|
|
|
|
2001-10-24 19:17:27 -04:00
|
|
|
if test "x$want_staticperllib" = "xyes"; then
|
|
|
|
PERL_MM_PARAMS="$PERL_MM_PARAMS LINKTYPE=static"
|
|
|
|
PERL_LINK_LIBS="$PERL_LINK_LIBS ../perl/common/blib/arch/auto/Irssi/Irssi.a ../perl/irc/blib/arch/auto/Irssi/Irc/Irc.a ../perl/ui/blib/arch/auto/Irssi/UI/UI.a ../perl/textui/blib/arch/auto/Irssi/TextUI/TextUI.a"
|
|
|
|
PERL_STATIC_LIBS=1
|
|
|
|
else
|
|
|
|
PERL_STATIC_LIBS=0
|
|
|
|
fi
|
|
|
|
|
2016-05-09 10:55:35 -04:00
|
|
|
# remove any prefix from PERL_MM_OPT
|
|
|
|
PERL_MM_OPT=`perl -MText::ParseWords -e 'sub qu{$_=shift;s{^(.*?)=(.*)$}{($a,$b)=($1,$2);$b=~s/"/\\\\"/g;qq{$a="$b"}}ge if /@<:@\s"@:>@/;$_} local $,=" "; print map qu($_), grep !/^(INSTALL_BASE|PREFIX)=/, shellwords(@ARGV)' "$PERL_MM_OPT"`
|
2001-10-22 16:34:05 -04:00
|
|
|
# figure out the correct @INC path - we'll need to do this
|
|
|
|
# through MakeMaker since it's difficult to get it right
|
|
|
|
# otherwise.
|
2016-05-09 10:55:35 -04:00
|
|
|
$perlpath -MExtUtils::MakeMaker -e 'WriteMakefile(NAME => "test", MAKEFILE => "Makefile.test", FIRST_MAKEFILE => "/dev/null", NO_META => 1, NO_MYMETA => 1);' $PERL_MM_PARAMS >/dev/null
|
|
|
|
echo 'show-INSTALLDIRS:' >> Makefile.test
|
|
|
|
echo ' @echo $(INSTALLDIRS)' >> Makefile.test
|
2016-05-11 05:43:08 -04:00
|
|
|
perl_INSTALLDIRS=`$am_make -s -f Makefile.test show-INSTALLDIRS`
|
2016-05-09 10:55:35 -04:00
|
|
|
if test "x$perl_INSTALLDIRS" = "xsite"; then
|
|
|
|
perl_library_dir="site default"
|
|
|
|
perl_INSTALL_VAR=INSTALLSITEARCH
|
|
|
|
elif test "x$perl_INSTALLDIRS" = "xvendor"; then
|
|
|
|
perl_library_dir="vendor default"
|
|
|
|
perl_INSTALL_VAR=INSTALLVENDORARCH
|
|
|
|
else
|
|
|
|
perl_library_dir="module default"
|
|
|
|
perl_INSTALL_VAR=INSTALLARCHLIB
|
|
|
|
fi
|
|
|
|
echo 'show-ARCHLIB:' >> Makefile.test
|
|
|
|
echo ' @echo $('"$perl_INSTALL_VAR"')' >> Makefile.test
|
2016-05-11 05:43:08 -04:00
|
|
|
perl_use_lib=`$am_make -s -f Makefile.test show-ARCHLIB`
|
2016-05-09 10:55:35 -04:00
|
|
|
rm -f Makefile.test
|
2001-10-22 16:34:05 -04:00
|
|
|
if test "x$perl_set_use_lib" = "xyes"; then
|
2016-05-09 10:55:35 -04:00
|
|
|
if $perlpath -e 'exit ! grep $_ eq $ARGV@<:@0@:>@, grep /^\//, @INC' "$perl_use_lib"; then
|
|
|
|
perl_library_dir="other path in @INC"
|
|
|
|
perl_set_use_lib=no
|
|
|
|
else
|
|
|
|
perl_library_dir="prepends to @INC with /set perl_use_lib"
|
|
|
|
PERL_USE_LIB="$perl_use_lib"
|
|
|
|
fi
|
2001-10-22 16:34:05 -04:00
|
|
|
fi
|
|
|
|
|
2001-02-17 05:35:35 -05:00
|
|
|
AC_SUBST(perl_module_lib)
|
|
|
|
AC_SUBST(perl_static_lib)
|
2001-07-29 05:17:53 -04:00
|
|
|
AC_SUBST(perl_module_fe_lib)
|
|
|
|
AC_SUBST(perl_static_fe_lib)
|
2000-10-03 19:54:56 -04:00
|
|
|
|
2001-07-29 05:17:53 -04:00
|
|
|
AC_SUBST(PERL_LINK_FLAGS)
|
2001-02-17 06:05:29 -05:00
|
|
|
AC_SUBST(PERL_LINK_LIBS)
|
2007-12-05 18:13:53 -05:00
|
|
|
AC_SUBST(PERL_FE_LINK_LIBS)
|
2001-02-17 06:05:29 -05:00
|
|
|
|
2000-10-03 18:57:14 -04:00
|
|
|
AC_SUBST(PERL_LDFLAGS)
|
|
|
|
AC_SUBST(PERL_CFLAGS)
|
2001-07-30 18:10:11 -04:00
|
|
|
|
|
|
|
AC_SUBST(PERL_USE_LIB)
|
2016-05-09 10:55:35 -04:00
|
|
|
AC_SUBST(PERL_MM_OPT)
|
2001-07-30 18:10:11 -04:00
|
|
|
AC_SUBST(PERL_MM_PARAMS)
|
2001-10-24 19:17:27 -04:00
|
|
|
AC_SUBST(PERL_STATIC_LIBS)
|
2000-03-11 15:19:24 -05:00
|
|
|
fi
|
2000-02-20 18:28:50 -05:00
|
|
|
fi
|
|
|
|
|
2017-07-25 14:39:15 -04:00
|
|
|
dnl **
|
|
|
|
dnl ** check for capsicum
|
|
|
|
dnl **
|
|
|
|
|
|
|
|
if test "x$want_capsicum" = "xyes"; then
|
|
|
|
AC_CHECK_LIB(c, cap_enter, [
|
2017-07-27 09:20:47 -04:00
|
|
|
AC_CHECK_LIB(nv, nvlist_create, [
|
|
|
|
AC_DEFINE(HAVE_CAPSICUM,, Build with Capsicum support)
|
|
|
|
LIBS="$LIBS -lnv"
|
|
|
|
], [
|
|
|
|
want_capsicum="no, nvlist_create not found"
|
|
|
|
])
|
2017-07-25 14:39:15 -04:00
|
|
|
], [
|
|
|
|
want_capsicum="no, cap_enter not found"
|
|
|
|
])
|
|
|
|
fi
|
|
|
|
|
2015-01-03 19:57:21 -05:00
|
|
|
dnl **
|
|
|
|
dnl ** OTR checks
|
|
|
|
dnl **
|
|
|
|
|
|
|
|
have_otr=no
|
|
|
|
if test "x$want_otr" != "xno"; then
|
|
|
|
AM_PATH_LIBGCRYPT(1:1.2.0, [], [AC_ERROR(libgcrypt 1.2.0 or newer is required.)])
|
|
|
|
AM_PATH_LIBOTR(4.1.0, [], [AC_ERROR([libotr 4.1.0 or newer is required.])])
|
|
|
|
|
|
|
|
OTR_CFLAGS="$LIBOTR_CFLAGS $LIBGCRYPT_CFLAGS"
|
|
|
|
OTR_LDFLAGS="$LIBOTR_LIBS $LIBGCRYPT_LIBS"
|
|
|
|
|
|
|
|
AC_SUBST(otr_module_lib)
|
|
|
|
AC_SUBST(otr_static_lib)
|
|
|
|
|
|
|
|
if test "x$want_otr" != "xno"; then
|
|
|
|
if test "x$want_otr" = "xstatic"; then
|
|
|
|
otr_module_lib=
|
|
|
|
otr_static_lib=libotr_core_static.la
|
|
|
|
|
|
|
|
OTR_LINK_LIBS="../otr/libotr_core_static.la"
|
|
|
|
OTR_LINK_FLAGS="$OTR_LDFLAGS"
|
|
|
|
|
|
|
|
AC_DEFINE(HAVE_STATIC_OTR)
|
|
|
|
else
|
|
|
|
otr_module_lib=libotr_core.la
|
|
|
|
otr_static_lib=
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
|
|
|
AC_SUBST(otr_module_lib)
|
|
|
|
AC_SUBST(otr_static_lib)
|
|
|
|
|
|
|
|
AC_SUBST(OTR_CFLAGS)
|
|
|
|
AC_SUBST(OTR_LDFLAGS)
|
|
|
|
|
|
|
|
AC_SUBST(OTR_LINK_LIBS)
|
|
|
|
AC_SUBST(OTR_LINK_FLAGS)
|
|
|
|
|
|
|
|
have_otr=yes
|
|
|
|
fi
|
|
|
|
|
1999-10-30 09:21:14 -04:00
|
|
|
dnl ** check what we want to build
|
2000-01-12 17:10:30 -05:00
|
|
|
AM_CONDITIONAL(BUILD_TEXTUI, test "$want_textui" = "yes")
|
|
|
|
AM_CONDITIONAL(BUILD_IRSSIBOT, test "$want_irssibot" = "yes")
|
2017-01-07 20:01:07 -05:00
|
|
|
AM_CONDITIONAL(BUILD_IRSSIFUZZER, test "$want_irssifuzzer" = "yes")
|
2000-09-29 19:59:51 -04:00
|
|
|
AM_CONDITIONAL(BUILD_IRSSIPROXY, test "$want_irssiproxy" = "yes")
|
2000-10-03 18:57:14 -04:00
|
|
|
AM_CONDITIONAL(HAVE_PERL, test "$want_perl" != "no")
|
2017-07-25 15:15:14 -04:00
|
|
|
AM_CONDITIONAL(HAVE_CAPSICUM, test "x$want_capsicum" = "xyes")
|
2017-02-16 16:48:13 -05:00
|
|
|
AM_CONDITIONAL(USE_GREGEX, test "x$want_gregex" = "xyes")
|
2015-01-03 19:57:21 -05:00
|
|
|
AM_CONDITIONAL(HAVE_OTR, test "x$have_otr" != "xno")
|
1999-11-28 12:50:17 -05:00
|
|
|
|
2001-10-29 08:43:46 -05:00
|
|
|
# move LIBS to PROG_LIBS so they're not tried to be used when linking eg. perl libraries
|
|
|
|
PROG_LIBS=$LIBS
|
|
|
|
LIBS=
|
|
|
|
AC_SUBST(PROG_LIBS)
|
|
|
|
|
2000-04-26 04:10:09 -04:00
|
|
|
dnl **
|
|
|
|
dnl ** Keep all the libraries here so each frontend doesn't need to
|
|
|
|
dnl ** keep track of them all
|
|
|
|
dnl **
|
2000-05-09 07:42:42 -04:00
|
|
|
dnl ** (these could be made configurable)
|
|
|
|
|
2000-07-16 16:34:49 -04:00
|
|
|
CHAT_MODULES="irc"
|
2000-05-09 07:42:42 -04:00
|
|
|
irc_MODULES="dcc flood notifylist"
|
2001-07-14 14:46:19 -04:00
|
|
|
if test -n "$build_modules"; then
|
2000-05-29 12:37:00 -04:00
|
|
|
irc_MODULES="$irc_MODULES $build_modules"
|
|
|
|
fi
|
2000-04-26 04:10:09 -04:00
|
|
|
|
2000-05-09 07:42:42 -04:00
|
|
|
dnl ****************************************
|
|
|
|
|
|
|
|
AC_SUBST(CHAT_MODULES)
|
|
|
|
AC_SUBST(irc_MODULES)
|
|
|
|
|
2008-02-03 11:48:02 -05:00
|
|
|
CORE_LIBS="../core/libcore.a ../lib-config/libirssi_config.a"
|
2000-09-06 17:30:56 -04:00
|
|
|
FE_COMMON_LIBS=""
|
2000-05-09 07:42:42 -04:00
|
|
|
|
|
|
|
CHAT_LIBS=""
|
|
|
|
for c in $CHAT_MODULES; do
|
2000-08-27 18:40:08 -04:00
|
|
|
CHAT_LIBS="$CHAT_LIBS ../$c/lib$c.a ../$c/core/lib${c}_core.a"
|
2001-04-16 08:46:57 -04:00
|
|
|
if test -f $srcdir/src/fe-common/$c/module.h; then
|
2000-09-06 17:30:56 -04:00
|
|
|
FE_COMMON_LIBS="$FE_COMMON_LIBS../fe-common/$c/libfe_common_$c.a "
|
2000-07-16 10:30:29 -04:00
|
|
|
fi
|
2000-05-09 07:42:42 -04:00
|
|
|
for s in `eval echo \\$${c}_MODULES`; do
|
2001-06-01 14:39:45 -04:00
|
|
|
CHAT_LIBS="$CHAT_LIBS ../$c/$s/lib${c}_$s.a"
|
2001-04-16 08:46:57 -04:00
|
|
|
if test -f $srcdir/src/fe-common/$c/$s/module.h; then
|
2001-06-01 14:39:45 -04:00
|
|
|
FE_COMMON_LIBS="$FE_COMMON_LIBS../fe-common/$c/$s/libfe_${c}_$s.a "
|
2000-05-25 07:30:47 -04:00
|
|
|
fi
|
2000-05-09 07:42:42 -04:00
|
|
|
done
|
|
|
|
done
|
2000-04-26 04:10:09 -04:00
|
|
|
|
2000-09-06 17:30:56 -04:00
|
|
|
FE_COMMON_LIBS="$FE_COMMON_LIBS../fe-common/core/libfe_common_core.a"
|
|
|
|
|
2000-04-26 04:10:09 -04:00
|
|
|
dnl ** common libraries needed by frontends
|
2002-02-17 12:53:11 -05:00
|
|
|
COMMON_NOUI_LIBS="$CHAT_LIBS $CORE_LIBS"
|
2001-02-17 06:09:14 -05:00
|
|
|
COMMON_LIBS="$FE_COMMON_LIBS $COMMON_NOUI_LIBS"
|
2000-05-09 07:42:42 -04:00
|
|
|
AC_SUBST(COMMON_NOUI_LIBS)
|
2000-04-26 04:10:09 -04:00
|
|
|
AC_SUBST(COMMON_LIBS)
|
|
|
|
|
2016-03-30 04:14:57 -04:00
|
|
|
if test "x$want_truecolor" = "xyes"; then
|
2014-01-09 09:20:29 -05:00
|
|
|
AC_DEFINE([TERM_TRUECOLOR], [], [true color support in terminal])
|
|
|
|
else
|
|
|
|
want_truecolor=no
|
|
|
|
fi
|
|
|
|
|
2017-01-03 06:04:56 -05:00
|
|
|
if test "x$want_gregex" = "xyes"; then
|
|
|
|
AC_DEFINE([USE_GREGEX], [], [use GRegex for regular expressions])
|
|
|
|
else
|
|
|
|
want_gregex=no
|
|
|
|
fi
|
|
|
|
|
2020-05-27 16:28:07 -04:00
|
|
|
AC_DEFINE([FHS_PREFIX], [""], [Alternate filesystem prefix for Termux])
|
2016-05-09 10:55:35 -04:00
|
|
|
AH_TEMPLATE(HAVE_GMODULE)
|
|
|
|
AH_TEMPLATE(HAVE_SOCKS_H, [misc..])
|
|
|
|
AH_TEMPLATE(HAVE_STATIC_PERL)
|
2015-01-03 19:57:21 -05:00
|
|
|
AH_TEMPLATE(HAVE_STATIC_OTR)
|
2016-05-09 10:55:35 -04:00
|
|
|
AH_TEMPLATE(PRIuUOFF_T, [printf()-format for uoff_t, eg. "u" or "lu" or "llu"])
|
|
|
|
AH_TEMPLATE(UOFF_T_INT, [What type should be used for uoff_t])
|
|
|
|
AH_TEMPLATE(UOFF_T_LONG)
|
|
|
|
AH_TEMPLATE(UOFF_T_LONG_LONG)
|
|
|
|
|
2007-05-05 10:29:25 -04:00
|
|
|
AC_CONFIG_FILES([
|
1999-09-03 10:27:29 -04:00
|
|
|
Makefile
|
|
|
|
src/Makefile
|
2000-04-26 04:10:09 -04:00
|
|
|
src/core/Makefile
|
|
|
|
src/irc/Makefile
|
|
|
|
src/irc/core/Makefile
|
|
|
|
src/irc/dcc/Makefile
|
|
|
|
src/irc/notifylist/Makefile
|
2000-09-29 19:59:51 -04:00
|
|
|
src/irc/proxy/Makefile
|
2000-04-26 04:10:09 -04:00
|
|
|
src/irc/flood/Makefile
|
|
|
|
src/fe-common/Makefile
|
|
|
|
src/fe-common/core/Makefile
|
|
|
|
src/fe-common/irc/Makefile
|
|
|
|
src/fe-common/irc/dcc/Makefile
|
|
|
|
src/fe-common/irc/notifylist/Makefile
|
2017-01-07 20:01:07 -05:00
|
|
|
src/fe-fuzz/Makefile
|
2017-10-24 13:27:11 -04:00
|
|
|
src/fe-fuzz/irc/Makefile
|
|
|
|
src/fe-fuzz/irc/core/Makefile
|
2018-01-15 11:59:01 -05:00
|
|
|
src/fe-fuzz/fe-common/Makefile
|
|
|
|
src/fe-fuzz/fe-common/core/Makefile
|
2000-04-26 04:10:09 -04:00
|
|
|
src/fe-none/Makefile
|
|
|
|
src/fe-text/Makefile
|
1999-09-03 10:27:29 -04:00
|
|
|
src/lib-config/Makefile
|
2000-04-26 04:10:09 -04:00
|
|
|
src/perl/Makefile
|
2000-10-03 15:10:24 -04:00
|
|
|
src/perl/common/Makefile.PL
|
2000-09-29 19:59:51 -04:00
|
|
|
src/perl/irc/Makefile.PL
|
2001-06-28 07:01:24 -04:00
|
|
|
src/perl/ui/Makefile.PL
|
2001-07-14 14:46:19 -04:00
|
|
|
src/perl/textui/Makefile.PL
|
2015-01-03 19:57:21 -05:00
|
|
|
src/otr/Makefile
|
2000-03-15 15:59:36 -05:00
|
|
|
scripts/Makefile
|
2002-03-10 16:30:45 -05:00
|
|
|
scripts/examples/Makefile
|
2017-10-21 23:01:04 -04:00
|
|
|
tests/Makefile
|
2017-11-26 15:10:49 -05:00
|
|
|
tests/fe-common/Makefile
|
|
|
|
tests/fe-common/core/Makefile
|
2018-11-09 04:57:37 -05:00
|
|
|
tests/fe-text/Makefile
|
2017-10-21 23:01:04 -04:00
|
|
|
tests/irc/Makefile
|
|
|
|
tests/irc/core/Makefile
|
2018-01-04 08:29:57 -05:00
|
|
|
tests/irc/flood/Makefile
|
1999-10-30 11:56:53 -04:00
|
|
|
docs/Makefile
|
|
|
|
docs/help/Makefile
|
2000-07-26 13:52:19 -04:00
|
|
|
docs/help/in/Makefile
|
2017-10-25 10:22:57 -04:00
|
|
|
utils/Makefile
|
|
|
|
themes/Makefile
|
2019-05-02 11:14:23 -04:00
|
|
|
irssi-1.pc
|
2007-05-05 10:29:25 -04:00
|
|
|
])
|
|
|
|
|
2019-05-01 10:33:47 -04:00
|
|
|
dnl ** make the paths like include headers later
|
2019-05-01 16:35:08 -04:00
|
|
|
AC_CONFIG_LINKS([irssi/irssi-config.h:irssi-config.h])
|
2019-05-01 10:33:47 -04:00
|
|
|
AC_LINK_FILES([$srcdir/src],[irssi/src])
|
|
|
|
|
2007-05-05 10:29:25 -04:00
|
|
|
AC_OUTPUT
|
2019-05-01 16:35:08 -04:00
|
|
|
$LN_S ../irssi-version.h irssi/irssi-version.h
|
2000-01-12 17:10:30 -05:00
|
|
|
|
2000-10-03 19:54:56 -04:00
|
|
|
dnl ** for building from objdir
|
2001-10-22 16:00:15 -04:00
|
|
|
old_dir=`pwd` && cd $srcdir && whole_dir=`pwd` && cd $old_dir
|
|
|
|
if test "x$old_dir" != "x$whole_dir"; then
|
2015-12-09 09:00:25 -05:00
|
|
|
$LN_S $srcdir/irssi-version.h irssi-version.h
|
2001-10-22 16:00:15 -04:00
|
|
|
if test "x$want_perl" != "xno"; then
|
|
|
|
subdirfiles=""
|
|
|
|
for i in $whole_dir/src/perl/common $whole_dir/src/perl/irc $whole_dir/src/perl/ui $whole_dir/src/perl/textui; do
|
2021-01-06 15:52:32 -05:00
|
|
|
subdirfiles=`echo $subdirfiles $i/typemap $i/*.h $i/*.pm $i/*.xs`
|
2001-10-22 16:00:15 -04:00
|
|
|
done
|
2008-11-23 04:48:48 -05:00
|
|
|
for file in $whole_dir/src/perl/module.h $subdirfiles; do
|
2001-02-23 03:07:10 -05:00
|
|
|
link=`echo $file|$sedpath "s?$whole_dir/??"`
|
2000-10-03 20:22:59 -04:00
|
|
|
rm -f $link
|
|
|
|
$LN_S $file $link
|
2000-06-04 12:01:19 -04:00
|
|
|
done
|
2000-03-11 15:19:24 -05:00
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
2000-01-12 17:10:30 -05:00
|
|
|
echo
|
|
|
|
|
2016-03-30 04:14:57 -04:00
|
|
|
echo "Building text frontend ........... : $want_textui"
|
2002-11-21 12:48:40 -05:00
|
|
|
echo "Building irssi bot ............... : $want_irssibot"
|
|
|
|
echo "Building irssi proxy ............. : $want_irssiproxy"
|
2002-02-15 03:31:35 -05:00
|
|
|
if test "x$have_gmodule" = "xyes"; then
|
2002-11-21 12:48:40 -05:00
|
|
|
echo "Building with module support ..... : yes"
|
2002-02-15 03:31:35 -05:00
|
|
|
else
|
|
|
|
echo "Building with module support : NO!! /LOAD will not work!"
|
|
|
|
echo " - You're missing gmodule (comes with glib) for some reason,"
|
|
|
|
echo " or it doesn't work in your system."
|
|
|
|
fi
|
2001-02-23 03:07:10 -05:00
|
|
|
|
2000-10-03 18:57:14 -04:00
|
|
|
if test "x$want_perl" = "xstatic"; then
|
2002-11-21 12:48:40 -05:00
|
|
|
echo "Building with Perl support ....... : static (in irssi binary)"
|
2001-10-20 17:32:22 -04:00
|
|
|
elif test "x$want_perl" = "xmodule"; then
|
2002-11-21 12:48:40 -05:00
|
|
|
echo "Building with Perl support ....... : module"
|
2000-10-03 18:57:14 -04:00
|
|
|
else
|
2001-07-14 14:46:19 -04:00
|
|
|
if test -z "$perl_check_error"; then
|
2002-11-21 12:48:40 -05:00
|
|
|
echo "Building with Perl support ....... : no"
|
2001-02-22 15:39:35 -05:00
|
|
|
else
|
2002-11-21 12:48:40 -05:00
|
|
|
echo "Building with Perl support ....... : NO!"
|
2001-02-22 15:39:35 -05:00
|
|
|
echo " - $perl_check_error"
|
2014-07-07 17:41:38 -04:00
|
|
|
if test -f /etc/debian_version; then
|
|
|
|
echo " - Try: sudo apt-get install libperl-dev"
|
|
|
|
elif test -f /etc/redhat-release; then
|
|
|
|
echo " - Try installing perl-devel"
|
|
|
|
fi
|
2001-02-22 15:39:35 -05:00
|
|
|
fi
|
2000-10-03 18:57:14 -04:00
|
|
|
fi
|
|
|
|
|
2001-02-23 03:07:10 -05:00
|
|
|
if test "x$want_perl" != "xno" -a "x$perl_mod_error" != "x"; then
|
2001-01-01 05:42:15 -05:00
|
|
|
echo " - NOTE: Perl support will be compiled statically to irssi, not as"
|
|
|
|
echo " a module as requested. Reason:"
|
|
|
|
echo " $perl_mod_error"
|
2002-04-29 13:17:17 -04:00
|
|
|
|
|
|
|
if test -f /etc/debian_version; then
|
2014-07-07 17:41:38 -04:00
|
|
|
echo " - Try: sudo apt-get install libperl-dev"
|
2002-04-29 13:17:17 -04:00
|
|
|
fi
|
2001-01-01 05:42:15 -05:00
|
|
|
fi
|
|
|
|
|
2001-10-20 17:32:22 -04:00
|
|
|
if test "x$want_perl" != "xno"; then
|
2016-05-09 10:55:35 -04:00
|
|
|
echo "Perl library directory ........... : ($perl_library_dir - $perl_use_lib)"
|
2001-07-30 18:10:11 -04:00
|
|
|
if test "x$perl_prefix_note" = "xyes"; then
|
|
|
|
echo " - NOTE: This was automatically set to the same directory you gave with"
|
|
|
|
echo " --prefix. If you want the perl libraries to install to their 'correct'"
|
|
|
|
echo " path, you'll need to give --with-perl-lib=site option to configure."
|
|
|
|
echo " Anyway, installing perl to this directory should work just as well."
|
2000-07-09 08:33:33 -04:00
|
|
|
fi
|
|
|
|
fi
|
2002-11-21 12:48:40 -05:00
|
|
|
echo "Install prefix ................... : $prefix"
|
2000-01-12 17:10:30 -05:00
|
|
|
|
2002-08-26 15:32:15 -04:00
|
|
|
echo
|
|
|
|
|
2002-11-21 12:48:40 -05:00
|
|
|
echo "Building with 64bit DCC support .. : $offt_64bit"
|
2014-01-09 09:20:29 -05:00
|
|
|
echo "Building with true color support.. : $want_truecolor"
|
2017-01-03 06:04:56 -05:00
|
|
|
echo "Building with GRegex ............. : $want_gregex"
|
2017-07-25 14:39:15 -04:00
|
|
|
echo "Building with Capsicum ........... : $want_capsicum"
|
2019-02-20 10:34:17 -05:00
|
|
|
echo "Building with utf8proc ........... : $want_utf8proc"
|
2015-01-03 19:57:21 -05:00
|
|
|
if test "x$want_otr" = "xstatic"; then
|
|
|
|
echo "Building with OTR support ........ : static (in irssi binary)"
|
|
|
|
elif test "x$want_otr" = "xmodule"; then
|
|
|
|
echo "Building with OTR support ........ : module"
|
|
|
|
else
|
|
|
|
echo "Building with OTR support ........ : no"
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
2002-03-31 14:51:58 -05:00
|
|
|
echo
|
2006-05-05 09:13:46 -04:00
|
|
|
echo "If there are any problems, read the INSTALL file."
|