summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
Diffstat (limited to '')
-rwxr-xr-xconfigure (renamed from src/configure)4429
-rw-r--r--configure.ac283
-rw-r--r--configure.bat (renamed from src/configure.bat)0
3 files changed, 1852 insertions, 2860 deletions
diff --git a/src/configure b/configure
index 5347cc48..6fe74ff0 100755
--- a/src/configure
+++ b/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.68 for ejabberd 13.03-beta2.
+# Generated by GNU Autoconf 2.67 for ejabberd 3.0.0.
#
# Report bugs to <ejabberd@process-one.net>.
#
@@ -91,7 +91,6 @@ fi
IFS=" "" $as_nl"
# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
case $0 in #((
*[\\/]* ) as_myself=$0 ;;
*) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -217,18 +216,11 @@ IFS=$as_save_IFS
# We cannot yet assume a decent shell, so we have to provide a
# neutralization value for shells without unset; and this also
# works around shells that cannot unset nonexistent variables.
- # Preserve -v and -x to the replacement shell.
BASH_ENV=/dev/null
ENV=/dev/null
(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
export CONFIG_SHELL
- case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
- esac
- exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"}
+ exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
fi
if test x$as_have_required = xno; then :
@@ -560,115 +552,64 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='ejabberd'
PACKAGE_TARNAME='ejabberd'
-PACKAGE_VERSION='13.03-beta2'
-PACKAGE_STRING='ejabberd 13.03-beta2'
+PACKAGE_VERSION='3.0.0'
+PACKAGE_STRING='ejabberd 3.0.0'
PACKAGE_BUGREPORT='ejabberd@process-one.net'
PACKAGE_URL=''
-# Factoring default headers for most tests.
-ac_includes_default="\
-#include <stdio.h>
-#ifdef HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-#ifdef HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-#ifdef STDC_HEADERS
-# include <stdlib.h>
-# include <stddef.h>
-#else
-# ifdef HAVE_STDLIB_H
-# include <stdlib.h>
-# endif
-#endif
-#ifdef HAVE_STRING_H
-# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
-# include <memory.h>
-# endif
-# include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-# include <strings.h>
-#endif
-#ifdef HAVE_INTTYPES_H
-# include <inttypes.h>
-#endif
-#ifdef HAVE_STDINT_H
-# include <stdint.h>
-#endif
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif"
-
ac_default_prefix=/
ac_subst_vars='LTLIBOBJS
-ERLCFLAGS
-target_os
-target_vendor
-target_cpu
-target
-host_os
-host_vendor
-host_cpu
-host
-build_os
-build_vendor
-build_cpu
-build
-md2
-INSTALLUSER
-SSL_CFLAGS
-SSL_LIBS
+LIBOBJS
+tools
+lager
+http
+debug
+iconv
+json
+stun
+zlib
+pam
+pgsql
+mysql
+odbc
+db_type
nif
full_xml
transient_supervisors
-db_type
roster_gateway_workaround
hipe
-PAM_LIBS
-PAM_CFLAGS
-make_pam
-pam
-ZLIB_LIBS
-ZLIB_CFLAGS
-make_ejabberd_zlib
-ejabberd_zlib
-make_web
-web
-make_tls
-tls
-make_odbc
-odbc
-make_eldap
-eldap
-make_mod_pubsub
-mod_pubsub
-make_mod_proxy65
-mod_proxy65
-make_mod_muc
-mod_muc
-make_mod_irc
-mod_irc
-LIBOBJS
-EXPAT_LIBS
-EXPAT_CFLAGS
-EGREP
-GREP
-CPP
-LIBICONV
-ERLANG_LIBS
-ERLANG_CFLAGS
-ERL
+ERLANG_LIB_VER_runtime_tools
+ERLANG_LIB_DIR_runtime_tools
+ERLANG_LIB_VER_tools
+ERLANG_LIB_DIR_tools
+ERLANG_LIB_VER_odbc
+ERLANG_LIB_DIR_odbc
+ERLANG_LIB_VER_compiler
+ERLANG_LIB_DIR_compiler
+ERLANG_LIB_VER_inets
+ERLANG_LIB_DIR_inets
+ERLANG_LIB_VER_mnesia
+ERLANG_LIB_DIR_mnesia
+ERLANG_LIB_VER_ssl
+ERLANG_LIB_DIR_ssl
+ERLANG_LIB_VER_public_key
+ERLANG_LIB_DIR_public_key
+ERLANG_LIB_VER_crypto
+ERLANG_LIB_DIR_crypto
+ERLANG_LIB_VER_sasl
+ERLANG_LIB_DIR_sasl
+INSTALLUSER
+MAKE
+ESCRIPT
+ERLANG_ROOT_DIR
+ERLCFLAGS
ERLC
+ERL
+SED
+INSTALL_DATA
+INSTALL_SCRIPT
+INSTALL_PROGRAM
SET_MAKE
-OBJEXT
-EXEEXT
-ac_ct_CC
-CPPFLAGS
-LDFLAGS
-CFLAGS
-CC
target_alias
host_alias
build_alias
@@ -711,38 +652,32 @@ ac_subst_files=''
ac_user_opts='
enable_option_checking
with_erlang
-with_libiconv_prefix
-with_expat
-enable_mod_irc
-enable_mod_muc
-enable_mod_proxy65
-enable_mod_pubsub
-enable_eldap
-enable_odbc
-enable_tls
-enable_web
-enable_ejabberd_zlib
-with_zlib
-enable_pam
-with_pam
+enable_erlang_version_check
enable_hipe
enable_roster_gateway_workaround
-enable_mssql
enable_transient_supervisors
enable_full_xml
+enable_mssql
+enable_tools
+enable_all
enable_nif
-with_openssl
+enable_odbc
+enable_mysql
+enable_pgsql
+enable_pam
+enable_zlib
+enable_stun
+enable_json
+enable_iconv
+enable_debug
+enable_http
+enable_lager
enable_user
'
ac_precious_vars='build_alias
host_alias
target_alias
-CC
-CFLAGS
-LDFLAGS
-LIBS
-CPPFLAGS
-CPP
+ERL
ERLC
ERLCFLAGS'
@@ -1149,7 +1084,7 @@ Try \`$0 --help' for more information"
$as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
$as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
- : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
+ : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
;;
esac
@@ -1287,7 +1222,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures ejabberd 13.03-beta2 to adapt to many kinds of systems.
+\`configure' configures ejabberd 3.0.0 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1343,17 +1278,12 @@ Fine tuning of the installation directories:
_ACEOF
cat <<\_ACEOF
-
-System types:
- --build=BUILD configure for building on BUILD [guessed]
- --host=HOST cross-compile to build programs to run on HOST [BUILD]
- --target=TARGET configure for building compilers for TARGET [HOST]
_ACEOF
fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of ejabberd 13.03-beta2:";;
+ short | recursive ) echo "Configuration of ejabberd 3.0.0:";;
esac
cat <<\_ACEOF
@@ -1361,30 +1291,42 @@ Optional Features:
--disable-option-checking ignore unrecognized --enable/--with options
--disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --enable-mod_irc enable mod_irc (default: yes)
- --enable-mod_muc enable mod_muc (default: yes)
- --enable-mod_proxy65 enable mod_proxy65 (default: yes)
- --enable-mod_pubsub enable mod_pubsub (default: yes)
- --enable-eldap enable eldap (default: yes)
- --enable-odbc enable odbc (default: no)
- --enable-tls enable tls (default: yes)
- --enable-web enable web (default: yes)
- --enable-ejabberd_zlib enable ejabberd_zlib (default: yes)
- --enable-pam enable pam (default: no)
+ --enable-erlang-version-check
+ Check Erlang/OTP version [default=yes]
--enable-hipe compile natively with HiPE, not recommended
(default: no)
--enable-roster-gateway-workaround
turn on workaround for processing gateway
subscriptions (default: no)
- --enable-mssql use Microsoft SQL Server database (default: no,
- requires --enable-odbc)
--enable-transient_supervisors
use Erlang supervision for transient process
- (default: yes)
+ (default: no)
--enable-full-xml use XML features in XMPP stream (ex: CDATA)
(default: no, requires XML compliant clients)
+ --enable-mssql use Microsoft SQL Server database (default: no,
+ requires --enable-odbc)
+ --enable-tools build development tools (currently the ejabberd
+ profiler only, default: no)
+ --enable-all same as --enable-nif --enable-odbc --enable-mysql
+ --enable-pgsql --enable-pam --enable-zlib
+ --enable-stun --enable-json --enable-iconv
+ --enable-debug --enable-http (useful for Dialyzer
+ checks, default: no)
--enable-nif replace some functions with C equivalents. Requires
Erlang R13B04 or higher (default: no)
+ --enable-odbc enable pure ODBC support (default: no)
+ --enable-mysql enable MySQL support (default: no)
+ --enable-pgsql enable PostgreSQL support (default: no)
+ --enable-pam enable PAM support (default: no)
+ --enable-zlib enable Stream Compression (XEP-0138) using zlib
+ (default: yes)
+ --enable-stun enable STUN support (default: no)
+ --enable-json enable JSON support for mod_bosh (default: no)
+ --enable-iconv enable iconv support (default: yes)
+ --enable-debug enable debug information (default: yes)
+ --enable-http build external HTTP libraries ('ibrowse' and
+ 'lhttpc', default: no)
+ --enable-lager enable lager support (default: yes)
--enable-user[[[=USER]]]
allow this system user to start ejabberd (default:
no)
@@ -1392,23 +1334,10 @@ Optional Features:
Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
--without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --with-erlang=PREFIX path to erlc and erl
- --with-libiconv-prefix=PREFIX
- prefix where libiconv is installed
- --with-expat=PREFIX prefix where EXPAT is installed
- --with-zlib=PREFIX prefix where zlib is installed
- --with-pam=PREFIX prefix where PAM is installed
- --with-openssl=PREFIX prefix where OPENSSL is installed
+ --with-erlang=dir search for erlang in dir
Some influential environment variables:
- CC C compiler command
- CFLAGS C compiler flags
- LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
- nonstandard directory <lib dir>
- LIBS libraries to pass to the linker, e.g. -l<library>
- CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
- you have headers in a nonstandard directory <include dir>
- CPP C preprocessor
+ ERL Erlang/OTP interpreter command [autodetected]
ERLC Erlang/OTP compiler command [autodetected]
ERLCFLAGS Erlang/OTP compiler flags [none]
@@ -1478,8 +1407,8 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-ejabberd configure 13.03-beta2
-generated by GNU Autoconf 2.68
+ejabberd configure 3.0.0
+generated by GNU Autoconf 2.67
Copyright (C) 2010 Free Software Foundation, Inc.
This configure script is free software; the Free Software Foundation
@@ -1492,291 +1421,6 @@ fi
## Autoconf initialization. ##
## ------------------------ ##
-# ac_fn_c_try_compile LINENO
-# --------------------------
-# Try to compile conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
- if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_compile
-
-# ac_fn_c_try_link LINENO
-# -----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_link ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest$ac_exeext
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- $as_test_x conftest$ac_exeext
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
- # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
- # interfere with the next link command; also delete a directory that is
- # left behind by Apple's compiler. We do this before executing the actions.
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_link
-
-# ac_fn_c_try_cpp LINENO
-# ----------------------
-# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_cpp ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } > conftest.i && {
- test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
- test ! -s conftest.err
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_cpp
-
-# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists, giving a warning if it cannot be compiled using
-# the include files in INCLUDES and setting the cache variable VAR
-# accordingly.
-ac_fn_c_check_header_mongrel ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if eval \${$3+:} false; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-else
- # Is the header compilable?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
-$as_echo_n "checking $2 usability... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_header_compiler=yes
-else
- ac_header_compiler=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
-$as_echo "$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
-$as_echo_n "checking $2 presence... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <$2>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- ac_header_preproc=yes
-else
- ac_header_preproc=no
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
-$as_echo "$ac_header_preproc" >&6; }
-
-# So? What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
- yes:no: )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
-$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
- no:yes:* )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
-$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
-$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
-$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
-$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
-( $as_echo "## --------------------------------------- ##
-## Report this to ejabberd@process-one.net ##
-## --------------------------------------- ##"
- ) | sed "s/^/$as_me: WARNING: /" >&2
- ;;
-esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- eval "$3=\$ac_header_compiler"
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_mongrel
-
-# ac_fn_c_try_run LINENO
-# ----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
-# that executables *can* be run.
-ac_fn_c_try_run ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then :
- ac_retval=0
-else
- $as_echo "$as_me: program exited with status $ac_status" >&5
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=$ac_status
-fi
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_run
-
-# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists and can be compiled using the include files in
-# INCLUDES, setting the cache variable VAR accordingly.
-ac_fn_c_check_header_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_compile
-
# ac_fn_erl_try_run LINENO
# ------------------------
# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
@@ -1814,7 +1458,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_retval=$ac_status
fi
rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
+ eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
as_fn_set_status $ac_retval
} # ac_fn_erl_try_run
@@ -1822,8 +1466,8 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by ejabberd $as_me 13.03-beta2, which was
-generated by GNU Autoconf 2.68. Invocation command line was
+It was created by ejabberd $as_me 3.0.0, which was
+generated by GNU Autoconf 2.67. Invocation command line was
$ $0 $@
@@ -2081,7 +1725,7 @@ $as_echo "$as_me: loading site script $ac_site_file" >&6;}
|| { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
as_fn_error $? "failed to load site script $ac_site_file
-See \`config.log' for more details" "$LINENO" 5; }
+See \`config.log' for more details" "$LINENO" 5 ; }
fi
done
@@ -2170,224 +1814,271 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $
ac_compiler_gnu=$ac_cv_c_compiler_gnu
+REQUIRE_ERLANG_MIN="5.9.1 (Erlang/OTP R15B01)"
+REQUIRE_ERLANG_MAX="9.0.0 (No Max)"
# Checks for programs.
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
+$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
+set x ${MAKE-make}
+ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
+if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\"" = set; then :
$as_echo_n "(cached) " >&6
else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_prog_CC="${ac_tool_prefix}gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
+ cat >conftest.make <<\_ACEOF
+SHELL = /bin/sh
+all:
+ @echo '@@@%%%=$(MAKE)=@@@%%%'
+_ACEOF
+# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
+case `${MAKE-make} -f conftest.make 2>/dev/null` in
+ *@@@%%%=?*=@@@%%%*)
+ eval ac_cv_prog_make_${ac_make}_set=yes;;
+ *)
+ eval ac_cv_prog_make_${ac_make}_set=no;;
+esac
+rm -f conftest.make
fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
+if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+ SET_MAKE=
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
+ SET_MAKE="MAKE=${MAKE-make}"
fi
-
-fi
-if test -z "$ac_cv_prog_CC"; then
- ac_ct_CC=$CC
- # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_prog_ac_ct_CC="gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
+ac_aux_dir=
+for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
+ if test -f "$ac_dir/install-sh"; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f "$ac_dir/install.sh"; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ elif test -f "$ac_dir/shtool"; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/shtool install -c"
+ break
fi
done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+if test -z "$ac_aux_dir"; then
+ as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
fi
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-else
- CC="$ac_cv_prog_CC"
-fi
+# These three variables are undocumented and unsupported,
+# and are intended to be withdrawn in a future Autoconf release.
+# They can cause serious problems if a builder's source tree is in a directory
+# whose full name contains unusual characters.
+ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
+ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
+ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
+
+# Find a good install program. We prefer a C program (faster),
+# so one script is as good as another. But avoid the broken or
+# incompatible versions:
+# SysV /etc/install, /usr/sbin/install
+# SunOS /usr/etc/install
+# IRIX /sbin/install
+# AIX /bin/install
+# AmigaOS /C/install, which installs bootblocks on floppy discs
+# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
+# AFS /usr/afsws/bin/install, which mishandles nonexistent args
+# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
+# OS/2's system install, which has a completely different semantic
+# ./install, which can be erroneously created by make from ./install.sh.
+# Reject install programs that cannot install multiple files.
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
+$as_echo_n "checking for a BSD-compatible install... " >&6; }
+if test -z "$INSTALL"; then
+if test "${ac_cv_path_install+set}" = set; then :
$as_echo_n "(cached) " >&6
else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_prog_CC="${ac_tool_prefix}cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
+ # Account for people who put trailing slashes in PATH elements.
+case $as_dir/ in #((
+ ./ | .// | /[cC]/* | \
+ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
+ ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
+ /usr/ucb/* ) ;;
+ *)
+ # OSF1 and SCO ODT 3.0 have their own names for install.
+ # Don't use installbsd from OSF since it installs stuff as root
+ # by default.
+ for ac_prog in ginstall scoinst install; do
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
+ if test $ac_prog = install &&
+ grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
+ # AIX install. It has an incompatible calling convention.
+ :
+ elif test $ac_prog = install &&
+ grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
+ # program-specific install script used by HP pwplus--don't use.
+ :
+ else
+ rm -rf conftest.one conftest.two conftest.dir
+ echo one > conftest.one
+ echo two > conftest.two
+ mkdir conftest.dir
+ if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
+ test -s conftest.one && test -s conftest.two &&
+ test -s conftest.dir/conftest.one &&
+ test -s conftest.dir/conftest.two
+ then
+ ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
+ break 3
+ fi
+ fi
+ fi
+ done
+ done
+ ;;
+esac
+
done
IFS=$as_save_IFS
+rm -rf conftest.one conftest.two conftest.dir
+
fi
+ if test "${ac_cv_path_install+set}" = set; then
+ INSTALL=$ac_cv_path_install
+ else
+ # As a last resort, use the slow shell script. Don't cache a
+ # value for INSTALL within a source directory, because that will
+ # break other packages using the cache if that directory is
+ # removed, or if the value is a relative name.
+ INSTALL=$ac_install_sh
+ fi
fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
+$as_echo "$INSTALL" >&6; }
+# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
+# It thinks the first close brace ends the variable substitution.
+test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
- fi
-fi
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
+test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
+
+test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
+
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
+$as_echo_n "checking for a sed that does not truncate output... " >&6; }
+if test "${ac_cv_path_SED+set}" = set; then :
$as_echo_n "(cached) " >&6
else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- ac_prog_rejected=no
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+ ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
+ for ac_i in 1 2 3 4 5 6 7; do
+ ac_script="$ac_script$as_nl$ac_script"
+ done
+ echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
+ { ac_script=; unset ac_script;}
+ if test -z "$SED"; then
+ ac_path_SED_found=false
+ # Loop through the user's path and test for each of PROGNAME-LIST
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
+ for ac_prog in sed gsed; do
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
+ ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
+ { test -f "$ac_path_SED" && $as_test_x "$ac_path_SED"; } || continue
+# Check for GNU ac_path_SED and select it if it is found.
+ # Check for GNU $ac_path_SED
+case `"$ac_path_SED" --version 2>&1` in
+*GNU*)
+ ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
+*)
+ ac_count=0
+ $as_echo_n 0123456789 >"conftest.in"
+ while :
+ do
+ cat "conftest.in" "conftest.in" >"conftest.tmp"
+ mv "conftest.tmp" "conftest.in"
+ cp "conftest.in" "conftest.nl"
+ $as_echo '' >> "conftest.nl"
+ "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
+ diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
+ as_fn_arith $ac_count + 1 && ac_count=$as_val
+ if test $ac_count -gt ${ac_path_SED_max-0}; then
+ # Best one so far, save it but keep looking for a better one
+ ac_cv_path_SED="$ac_path_SED"
+ ac_path_SED_max=$ac_count
+ fi
+ # 10*(2^10) chars as input seems more than enough
+ test $ac_count -gt 10 && break
done
-IFS=$as_save_IFS
+ rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
+esac
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# != 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
+ $ac_path_SED_found && break 3
+ done
+ done
+ done
+IFS=$as_save_IFS
+ if test -z "$ac_cv_path_SED"; then
+ as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
fi
+else
+ ac_cv_path_SED=$SED
fi
+
fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
+$as_echo "$ac_cv_path_SED" >&6; }
+ SED="$ac_cv_path_SED"
+ rm -f conftest.sed
+
+
+if test "x$GCC" = "xyes"; then
+ CFLAGS="$CFLAGS -Wall"
fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
+
+# Checks Erlang runtime and compiler
+
+# Check whether --with-erlang was given.
+if test "${with_erlang+set}" = set; then :
+ withval=$with_erlang; if test "$withval" = "yes" -o "$withval" = "no" -o "X$with_erlang" = "X"; then
+ extra_erl_path=""
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ extra_erl_path="$with_erlang:$with_erlang/bin:"
fi
-
fi
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- for ac_prog in cl.exe
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
+
+
+if test -n "$ac_tool_prefix"; then
+ # Extract the first word of "${ac_tool_prefix}erl", so it can be a program name with args.
+set dummy ${ac_tool_prefix}erl; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
+if test "${ac_cv_path_ERL+set}" = set; then :
$as_echo_n "(cached) " >&6
else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
+ case $ERL in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_ERL="$ERL" # Let the user override the test with a path.
+ ;;
+ *)
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in ${extra_erl_path}$PATH
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
+ ac_cv_path_ERL="$as_dir/$ac_word$ac_exec_ext"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
@@ -2395,43 +2086,42 @@ done
done
IFS=$as_save_IFS
+ ;;
+esac
fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
+ERL=$ac_cv_path_ERL
+if test -n "$ERL"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ERL" >&5
+$as_echo "$ERL" >&6; }
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
fi
- test -n "$CC" && break
- done
fi
-if test -z "$CC"; then
- ac_ct_CC=$CC
- for ac_prog in cl.exe
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
+if test -z "$ac_cv_path_ERL"; then
+ ac_pt_ERL=$ERL
+ # Extract the first word of "erl", so it can be a program name with args.
+set dummy erl; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
+if test "${ac_cv_path_ac_pt_ERL+set}" = set; then :
$as_echo_n "(cached) " >&6
else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
+ case $ac_pt_ERL in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_ac_pt_ERL="$ac_pt_ERL" # Let the user override the test with a path.
+ ;;
+ *)
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in ${extra_erl_path}$PATH
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_prog_ac_ct_CC="$ac_prog"
+ ac_cv_path_ac_pt_ERL="$as_dir/$ac_word$ac_exec_ext"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
@@ -2439,23 +2129,20 @@ done
done
IFS=$as_save_IFS
+ ;;
+esac
fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
+ac_pt_ERL=$ac_cv_path_ac_pt_ERL
+if test -n "$ac_pt_ERL"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_ERL" >&5
+$as_echo "$ac_pt_ERL" >&6; }
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
fi
-
- test -n "$ac_ct_CC" && break
-done
-
- if test "x$ac_ct_CC" = x; then
- CC=""
+ if test "x$ac_pt_ERL" = x; then
+ ERL=""
else
case $cross_compiling:$ac_tool_warned in
yes:)
@@ -2463,555 +2150,18 @@ yes:)
$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
- CC=$ac_ct_CC
- fi
-fi
-
-fi
-
-
-test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "no acceptable C compiler found in \$PATH
-See \`config.log' for more details" "$LINENO" 5; }
-
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
- fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-done
-
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
-# Try to create an executable without -o first, disregard a.out.
-# It will help us diagnose broken compilers, and finding out an intuition
-# of exeext.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
-$as_echo_n "checking whether the C compiler works... " >&6; }
-ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-
-# The possible output files:
-ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
-
-ac_rmfiles=
-for ac_file in $ac_files
-do
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- * ) ac_rmfiles="$ac_rmfiles $ac_file";;
- esac
-done
-rm -f $ac_rmfiles
-
-if { { ac_try="$ac_link_default"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link_default") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
-# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
-# in a Makefile. We should not override ac_cv_exeext if it was cached,
-# so that the user can short-circuit this test for compilers unknown to
-# Autoconf.
-for ac_file in $ac_files ''
-do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
- ;;
- [ab].out )
- # We found the default executable, but exeext='' is most
- # certainly right.
- break;;
- *.* )
- if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
- then :; else
- ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- fi
- # We set ac_cv_exeext here because the later test for it is not
- # safe: cross compilers may not add the suffix if given an `-o'
- # argument, so we may need to know it at that point already.
- # Even if this section looks crufty: it has the advantage of
- # actually working.
- break;;
- * )
- break;;
- esac
-done
-test "$ac_cv_exeext" = no && ac_cv_exeext=
-
-else
- ac_file=''
-fi
-if test -z "$ac_file"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-$as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "C compiler cannot create executables
-See \`config.log' for more details" "$LINENO" 5; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
-$as_echo_n "checking for C compiler default output file name... " >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
-$as_echo "$ac_file" >&6; }
-ac_exeext=$ac_cv_exeext
-
-rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
-$as_echo_n "checking for suffix of executables... " >&6; }
-if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # If both `conftest.exe' and `conftest' are `present' (well, observable)
-# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
-# work properly (i.e., refer to `conftest.exe'), while it won't with
-# `rm'.
-for ac_file in conftest.exe conftest conftest.*; do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- break;;
- * ) break;;
- esac
-done
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest conftest$ac_cv_exeext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
-$as_echo "$ac_cv_exeext" >&6; }
-
-rm -f conftest.$ac_ext
-EXEEXT=$ac_cv_exeext
-ac_exeext=$EXEEXT
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdio.h>
-int
-main ()
-{
-FILE *f = fopen ("conftest.out", "w");
- return ferror (f) || fclose (f) != 0;
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files="$ac_clean_files conftest.out"
-# Check that the compiler produces executables we can run. If not, either
-# the compiler is broken, or we cross compile.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
-$as_echo_n "checking whether we are cross compiling... " >&6; }
-if test "$cross_compiling" != yes; then
- { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- if { ac_try='./conftest$ac_cv_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then
- cross_compiling=no
- else
- if test "$cross_compiling" = maybe; then
- cross_compiling=yes
- else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details" "$LINENO" 5; }
- fi
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
-$as_echo "$cross_compiling" >&6; }
-
-rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
-$as_echo_n "checking for suffix of object files... " >&6; }
-if ${ac_cv_objext+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.o conftest.obj
-if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- for ac_file in conftest.o conftest.obj conftest.*; do
- test -f "$ac_file" || continue;
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
- *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
- break;;
- esac
-done
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of object files: cannot compile
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
-$as_echo "$ac_cv_objext" >&6; }
-OBJEXT=$ac_cv_objext
-ac_objext=$OBJEXT
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
-$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if ${ac_cv_c_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-#ifndef __GNUC__
- choke me
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_compiler_gnu=yes
-else
- ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
-$as_echo "$ac_cv_c_compiler_gnu" >&6; }
-if test $ac_compiler_gnu = yes; then
- GCC=yes
-else
- GCC=
-fi
-ac_test_CFLAGS=${CFLAGS+set}
-ac_save_CFLAGS=$CFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
-$as_echo_n "checking whether $CC accepts -g... " >&6; }
-if ${ac_cv_prog_cc_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_c_werror_flag=$ac_c_werror_flag
- ac_c_werror_flag=yes
- ac_cv_prog_cc_g=no
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-else
- CFLAGS=""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
-else
- ac_c_werror_flag=$ac_save_c_werror_flag
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_c_werror_flag=$ac_save_c_werror_flag
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
-$as_echo "$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS=$ac_save_CFLAGS
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
+ ERL=$ac_pt_ERL
fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
-$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if ${ac_cv_prog_cc_c89+:} false; then :
- $as_echo_n "(cached) " >&6
else
- ac_cv_prog_cc_c89=no
-ac_save_CC=$CC
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdarg.h>
-#include <stdio.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
-{
- return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
- char *s;
- va_list v;
- va_start (v,p);
- s = g (p, va_arg (v,int));
- va_end (v);
- return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
- function prototypes and stuff, but not '\xHH' hex character constants.
- These don't provoke an error unfortunately, instead are silently treated
- as 'x'. The following induces an error, until -std is added to get
- proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
- array size at least. It's necessary to write '\x00'==0 to get something
- that's true only with -std. */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
-
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
- inside strings and character constants. */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
-
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
- ;
- return 0;
-}
-_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
- -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
- CC="$ac_save_CC $ac_arg"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_c89=$ac_arg
-fi
-rm -f core conftest.err conftest.$ac_objext
- test "x$ac_cv_prog_cc_c89" != "xno" && break
-done
-rm -f conftest.$ac_ext
-CC=$ac_save_CC
-
-fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
- x)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
-$as_echo "none needed" >&6; } ;;
- xno)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
-$as_echo "unsupported" >&6; } ;;
- *)
- CC="$CC $ac_cv_prog_cc_c89"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
-$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-if test "x$ac_cv_prog_cc_c89" != xno; then :
-
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
-set x ${MAKE-make}
-ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat >conftest.make <<\_ACEOF
-SHELL = /bin/sh
-all:
- @echo '@@@%%%=$(MAKE)=@@@%%%'
-_ACEOF
-# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
-case `${MAKE-make} -f conftest.make 2>/dev/null` in
- *@@@%%%=?*=@@@%%%*)
- eval ac_cv_prog_make_${ac_make}_set=yes;;
- *)
- eval ac_cv_prog_make_${ac_make}_set=no;;
-esac
-rm -f conftest.make
-fi
-if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- SET_MAKE=
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-
-if test "x$GCC" = "xyes"; then
- CFLAGS="$CFLAGS -Wall"
-fi
-
-#locating erlang
-
-# Check whether --with-erlang was given.
-if test "${with_erlang+set}" = set; then :
- withval=$with_erlang;
+ ERL="$ac_cv_path_ERL"
fi
-
- if test -n "$ac_tool_prefix"; then
+if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}erlc", so it can be a program name with args.
set dummy ${ac_tool_prefix}erlc; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_ERLC+:} false; then :
+if test "${ac_cv_path_ERLC+set}" = set; then :
$as_echo_n "(cached) " >&6
else
case $ERLC in
@@ -3020,8 +2170,7 @@ else
;;
*)
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-as_dummy="$with_erlang:$with_erlang/bin:$PATH"
-for as_dir in $as_dummy
+for as_dir in ${extra_erl_path}$PATH
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
@@ -3055,7 +2204,7 @@ if test -z "$ac_cv_path_ERLC"; then
set dummy erlc; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_ac_pt_ERLC+:} false; then :
+if test "${ac_cv_path_ac_pt_ERLC+set}" = set; then :
$as_echo_n "(cached) " >&6
else
case $ac_pt_ERLC in
@@ -3064,8 +2213,7 @@ else
;;
*)
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-as_dummy="$with_erlang:$with_erlang/bin:$PATH"
-for as_dir in $as_dummy
+for as_dir in ${extra_erl_path}$PATH
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
@@ -3106,12 +2254,19 @@ else
ERLC="$ac_cv_path_ERLC"
fi
- if test -n "$ac_tool_prefix"; then
+
+if test -n "$ERL"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for erl" >&5
+$as_echo_n "checking for erl... " >&6; }
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ERL" >&5
+$as_echo "$ERL" >&6; }
+else
+ if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}erl", so it can be a program name with args.
set dummy ${ac_tool_prefix}erl; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_ERL+:} false; then :
+if test "${ac_cv_path_ERL+set}" = set; then :
$as_echo_n "(cached) " >&6
else
case $ERL in
@@ -3120,8 +2275,7 @@ else
;;
*)
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-as_dummy="$with_erlang:$with_erlang/bin:$PATH"
-for as_dir in $as_dummy
+for as_dir in $PATH
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
@@ -3155,7 +2309,7 @@ if test -z "$ac_cv_path_ERL"; then
set dummy erl; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_ac_pt_ERL+:} false; then :
+if test "${ac_cv_path_ac_pt_ERL+set}" = set; then :
$as_echo_n "(cached) " >&6
else
case $ac_pt_ERL in
@@ -3164,8 +2318,7 @@ else
;;
*)
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-as_dummy="$with_erlang:$with_erlang/bin:$PATH"
-for as_dir in $as_dummy
+for as_dir in $PATH
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
@@ -3192,7 +2345,7 @@ $as_echo "no" >&6; }
fi
if test "x$ac_pt_ERL" = x; then
- ERL=""
+ ERL="not found"
else
case $cross_compiling:$ac_tool_warned in
yes:)
@@ -3205,1925 +2358,1502 @@ esac
else
ERL="$ac_cv_path_ERL"
fi
+fi
+if test "$ERL" = "not found"; then
+ as_fn_error $? "Erlang/OTP interpreter (erl) not found but required" "$LINENO" 5
+fi
- if test "z$ERLC" = "z" || test "z$ERL" = "z"; then
- as_fn_error $? "erlang not found" "$LINENO" 5
- fi
-
-
- cat >>conftest.erl <<_EOF
+if test -n "$ERLC"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for erlc" >&5
+$as_echo_n "checking for erlc... " >&6; }
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ERLC" >&5
+$as_echo "$ERLC" >&6; }
+else
+ if test -n "$ac_tool_prefix"; then
+ # Extract the first word of "${ac_tool_prefix}erlc", so it can be a program name with args.
+set dummy ${ac_tool_prefix}erlc; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_path_ERLC+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ case $ERLC in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_ERLC="$ERLC" # Let the user override the test with a path.
+ ;;
+ *)
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ ac_cv_path_ERLC="$as_dir/$ac_word$ac_exec_ext"
+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+ done
+IFS=$as_save_IFS
--module(conftest).
--author('alexey@sevcom.net').
+ ;;
+esac
+fi
+ERLC=$ac_cv_path_ERLC
+if test -n "$ERLC"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ERLC" >&5
+$as_echo "$ERLC" >&6; }
+else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
--export([start/0]).
-start() ->
- EIDirS = code:lib_dir("erl_interface") ++ "\n",
- EILibS = libpath("erl_interface") ++ "\n",
- RootDirS = code:root_dir() ++ "\n",
- file:write_file("conftest.out", list_to_binary(EIDirS ++ EILibS ++ RootDirS)),
- halt().
+fi
+if test -z "$ac_cv_path_ERLC"; then
+ ac_pt_ERLC=$ERLC
+ # Extract the first word of "erlc", so it can be a program name with args.
+set dummy erlc; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_path_ac_pt_ERLC+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ case $ac_pt_ERLC in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_ac_pt_ERLC="$ac_pt_ERLC" # Let the user override the test with a path.
+ ;;
+ *)
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ ac_cv_path_ac_pt_ERLC="$as_dir/$ac_word$ac_exec_ext"
+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+ done
+IFS=$as_save_IFS
-%% return physical architecture based on OS/Processor
-archname() ->
- ArchStr = erlang:system_info(system_architecture),
- case os:type() of
- {win32, _} -> "windows";
- {unix,UnixName} ->
- Specs = string:tokens(ArchStr,"-"),
- Cpu = case lists:nth(2,Specs) of
- "pc" -> "x86";
- _ -> hd(Specs)
- end,
- atom_to_list(UnixName) ++ "-" ++ Cpu;
- _ -> "generic"
- end.
+ ;;
+esac
+fi
+ac_pt_ERLC=$ac_cv_path_ac_pt_ERLC
+if test -n "$ac_pt_ERLC"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_ERLC" >&5
+$as_echo "$ac_pt_ERLC" >&6; }
+else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
-%% Return arch-based library path or a default value if this directory
-%% does not exist
-libpath(App) ->
- PrivDir = code:priv_dir(App),
- ArchDir = archname(),
- LibArchDir = filename:join([PrivDir,"lib",ArchDir]),
- case file:list_dir(LibArchDir) of
- %% Arch lib dir exists: We use it
- {ok, _List} -> LibArchDir;
- %% Arch lib dir does not exist: Return the default value
- %% ({error, enoent}):
- _Error -> code:lib_dir("erl_interface") ++ "/lib"
- end.
+ if test "x$ac_pt_ERLC" = x; then
+ ERLC="not found"
+ else
+ case $cross_compiling:$ac_tool_warned in
+yes:)
+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+ac_tool_warned=yes ;;
+esac
+ ERLC=$ac_pt_ERLC
+ fi
+else
+ ERLC="$ac_cv_path_ERLC"
+fi
-_EOF
+fi
- if ! $ERLC conftest.erl; then
- as_fn_error $? "could not compile sample program" "$LINENO" 5
- fi
+if test "$ERLC" = "not found"; then
+ as_fn_error $? "Erlang/OTP compiler (erlc) not found but required" "$LINENO" 5
+fi
- if ! $ERL -s conftest -noshell; then
- as_fn_error $? "could not run sample program" "$LINENO" 5
- fi
- if ! test -f conftest.out; then
- as_fn_error $? "erlang program was not properly executed, (conftest.out was not produced)" "$LINENO" 5
- fi
+# Check whether --enable-erlang-version-check was given.
+if test "${enable_erlang_version_check+set}" = set; then :
+ enableval=$enable_erlang_version_check;
+fi
- # First line
- ERLANG_EI_DIR=`cat conftest.out | head -n 1`
- # Second line
- ERLANG_EI_LIB=`cat conftest.out | head -n 2 | tail -n 1`
- # End line
- ERLANG_DIR=`cat conftest.out | tail -n 1`
+ case "$enable_erlang_version_check" in
+ yes|'')
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking Erlang/OTP version" >&5
+$as_echo_n "checking Erlang/OTP version... " >&6; }
+ cat > conftest.erl <<EOF
+-module(conftest).
+-export([start/0]).
- ERLANG_CFLAGS="-I$ERLANG_EI_DIR/include -I$ERLANG_DIR/usr/include"
- ERLANG_LIBS="-L$ERLANG_EI_LIB -lerl_interface -lei"
+start() ->
+ ERTS = erlang:system_info(version),
+ RequiredMin = "$REQUIRE_ERLANG_MIN",
+ RequiredMax = "$REQUIRE_ERLANG_MAX",
+ Status =
+ case {string:tokens(RequiredMin, " "),
+ string:tokens(RequiredMax, " ")} of
+ {[MinStr | _], [MaxStr | _]} ->
+ case check(ERTS, {MinStr, MaxStr}) of
+ less ->
+ list_to_binary([ERTS, " found, ", RequiredMin, " required"]);
+ greater ->
+ list_to_binary([ERTS, " found, ", RequiredMax, " or earlier required"]);
+ ok ->
+ <<"ok">>
+ end;
+ _ ->
+ list_to_binary([ERTS, " found, ", RequiredMin, " required"])
+ end,
+ file:write_file("conftest.out", Status),
+ halt().
+check(CurStr, {MinStr, MaxStr}) ->
+ Cur = parse(CurStr),
+ Min = parse(MinStr),
+ Max = parse(MaxStr),
+ case {less_or_equal(Min, Cur), less_or_equal(Cur, Max)} of
+ {false, true} -> less;
+ {true, true} -> ok;
+ {true, false} -> greater
+ end.
+parse(Version) ->
+ lists:map(fun(A) -> {Int,[]} = string:to_integer(A), Int end,
+ string:tokens(Version, ".")).
+
+less_or_equal([], []) ->
+ true;
+less_or_equal([Left| Rl], [Right| Rr]) ->
+ case {Left < Right, Left == Right} of
+ {true, _} ->
+ true;
+ {false, false} ->
+ false;
+ {false, true} ->
+ less_or_equal(Rl, Rr)
+ end.
+EOF
+ $ERLC conftest.erl || as_fn_error $? "\"Could not compile Erlang/OTP version check program using '$ERLC'\"" "$LINENO" 5
+ if ! $ERL -s conftest -noshell -o ! -f conftest.out ; then
+ as_fn_error $? "\"Could not run Erlang/OTP version check program using '$ERL'\"" "$LINENO" 5
+ fi
-#locating iconv
+ if test "x`cat conftest.out`" != "xok"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
+$as_echo "failed" >&6; }
+ X="`cat conftest.out`"
+ if test "" == "warn"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $X" >&5
+$as_echo "$as_me: WARNING: $X" >&2;}
+ else
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "$X
+See \`config.log' for more details" "$LINENO" 5 ; }
+ fi
+ else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
+$as_echo "ok" >&6; }
+ fi
+ ;;
+ no)
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking Erlang/OTP version" >&5
+$as_echo_n "checking Erlang/OTP version... " >&6; }
+ cat > conftest.erl <<EOF
+-module(conftest).
+-export([start/0]).
+start() ->
+ ERTS = erlang:system_info(version),
+ RequiredMin = "$REQUIRE_ERLANG_MIN",
+ RequiredMax = "$REQUIRE_ERLANG_MAX",
+ Status =
+ case {string:tokens(RequiredMin, " "),
+ string:tokens(RequiredMax, " ")} of
+ {[MinStr | _], [MaxStr | _]} ->
+ case check(ERTS, {MinStr, MaxStr}) of
+ less ->
+ list_to_binary([ERTS, " found, ", RequiredMin, " required"]);
+ greater ->
+ list_to_binary([ERTS, " found, ", RequiredMax, " or earlier required"]);
+ ok ->
+ <<"ok">>
+ end;
+ _ ->
+ list_to_binary([ERTS, " found, ", RequiredMin, " required"])
+ end,
+ file:write_file("conftest.out", Status),
+ halt().
-# Check whether --with-libiconv-prefix was given.
-if test "${with_libiconv_prefix+set}" = set; then :
- withval=$with_libiconv_prefix;
- for dir in `echo "$withval" | tr : ' '`; do
- if test -d $dir/include; then CPPFLAGS="$CPPFLAGS -I$dir/include"; fi
- if test -d $dir/include; then CFLAGS="$CFLAGS -I$dir/include"; fi
- if test -d $dir/lib; then LDFLAGS="$LDFLAGS -L$dir/lib"; fi
- done
+check(CurStr, {MinStr, MaxStr}) ->
+ Cur = parse(CurStr),
+ Min = parse(MinStr),
+ Max = parse(MaxStr),
+ case {less_or_equal(Min, Cur), less_or_equal(Cur, Max)} of
+ {false, true} -> less;
+ {true, true} -> ok;
+ {true, false} -> greater
+ end.
-fi
+parse(Version) ->
+ lists:map(fun(A) -> {Int,[]} = string:to_integer(A), Int end,
+ string:tokens(Version, ".")).
+
+less_or_equal([], []) ->
+ true;
+less_or_equal([Left| Rl], [Right| Rr]) ->
+ case {Left < Right, Left == Right} of
+ {true, _} ->
+ true;
+ {false, false} ->
+ false;
+ {false, true} ->
+ less_or_equal(Rl, Rr)
+ end.
+EOF
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
-$as_echo_n "checking for iconv... " >&6; }
-if ${am_cv_func_iconv+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ $ERLC conftest.erl || as_fn_error $? "\"Could not compile Erlang/OTP version check program using '$ERLC'\"" "$LINENO" 5
- am_cv_func_iconv="no, consider installing GNU libiconv"
- am_cv_lib_iconv=no
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-#include <iconv.h>
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if test "$am_cv_func_iconv" != yes; then
- am_save_LIBS="$LIBS"
- LIBS="$LIBS -liconv"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-#include <iconv.h>
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_lib_iconv=yes
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$am_save_LIBS"
- fi
- if test "$am_cv_func_iconv" != yes; then
- am_save_LIBS="$LIBS"
- am_save_CFLAGS="$CFLAGS"
- am_save_LDFLAGS="$LDFLAGS"
- LIBS="$LIBS -liconv"
- LDFLAGS="$LDFLAGS -L/usr/local/lib"
- CFLAGS="$CFLAGS -I/usr/local/include"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-#include <iconv.h>
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_lib_iconv=yes
- am_cv_func_iconv=yes
- CPPFLAGS="$CPPFLAGS -I/usr/local/include"
-else
- LDFLAGS="$am_save_LDFLAGS"
- CFLAGS="$am_save_CFLAGS"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$am_save_LIBS"
- fi
+ if ! $ERL -s conftest -noshell -o ! -f conftest.out ; then
+ as_fn_error $? "\"Could not run Erlang/OTP version check program using '$ERL'\"" "$LINENO" 5
+ fi
+ if test "x`cat conftest.out`" != "xok"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
+$as_echo "failed" >&6; }
+ X="`cat conftest.out`"
+ if test "warn" == "warn"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $X" >&5
+$as_echo "$as_me: WARNING: $X" >&2;}
+ else
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "$X
+See \`config.log' for more details" "$LINENO" 5 ; }
+ fi
+ else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
+$as_echo "ok" >&6; }
+ fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
-$as_echo "$am_cv_func_iconv" >&6; }
- if test "$am_cv_func_iconv" = yes; then
+ ;;
+esac
-$as_echo "#define HAVE_ICONV 1" >>confdefs.h
+# Checks and sets ERLANG_ROOT_DIR and ERLANG_LIB_DIR variable
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5
-$as_echo_n "checking for iconv declaration... " >&6; }
- if ${am_cv_proto_iconv+:} false; then :
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP root directory" >&5
+$as_echo_n "checking for Erlang/OTP root directory... " >&6; }
+if test "${ac_cv_erlang_root_dir+set}" = set; then :
$as_echo_n "(cached) " >&6
else
+ ac_ext=erl
+ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5'
+ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5 && echo "#!/bin/sh" > conftest$ac_exeext && $as_echo "\"$ERL\" -run conftest start -run init stop -noshell" >> conftest$ac_exeext && chmod +x conftest$ac_exeext'
+ if test "$cross_compiling" = yes; then :
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5 ; }
+else
+ cat > conftest.$ac_ext <<_ACEOF
+-module(conftest).
+-export([start/0]).
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-extern
-#ifdef __cplusplus
-"C"
-#endif
-#if defined(__STDC__) || defined(__cplusplus)
-size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
-#else
-size_t iconv();
-#endif
-
-int
-main ()
-{
+start() ->
+ RootDir = code:root_dir(),
+ file:write_file("conftest.out", RootDir),
+ ReturnValue = 0,
+ halt(ReturnValue)
+.
- ;
- return 0;
-}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- am_cv_proto_iconv_arg1=""
+if ac_fn_erl_try_run "$LINENO"; then :
+ ac_cv_erlang_root_dir=`cat conftest.out`
+ rm -f conftest.out
else
- am_cv_proto_iconv_arg1="const"
+ rm -f conftest.out
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "test Erlang program execution failed
+See \`config.log' for more details" "$LINENO" 5 ; }
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+ conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
- am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ac_t:-
- }$am_cv_proto_iconv" >&5
-$as_echo "${ac_t:-
- }$am_cv_proto_iconv" >&6; }
-
-cat >>confdefs.h <<_ACEOF
-#define ICONV_CONST $am_cv_proto_iconv_arg1
-_ACEOF
-
- fi
- LIBICONV=
- if test "$am_cv_lib_iconv" = yes; then
- LIBICONV="-liconv"
- fi
-
-
-#locating libexpat
-ac_ext=c
+ ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
-$as_echo_n "checking how to run the C preprocessor... " >&6; }
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
- CPP=
-fi
-if test -z "$CPP"; then
- if ${ac_cv_prog_CPP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # Double quotes because CPP needs to be expanded
- for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
- do
- ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
- break
-fi
-
- done
- ac_cv_prog_CPP=$CPP
-
-fi
- CPP=$ac_cv_prog_CPP
-else
- ac_cv_prog_CPP=$CPP
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
-$as_echo "$CPP" >&6; }
-ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
fi
-rm -f conftest.err conftest.i conftest.$ac_ext
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_root_dir" >&5
+$as_echo "$ac_cv_erlang_root_dir" >&6; }
+ERLANG_ROOT_DIR=$ac_cv_erlang_root_dir
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
-
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
+# AC_ERLANG_SUBST_LIB_DIR
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
-$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
-if ${ac_cv_path_GREP+:} false; then :
+#locating escript
+# Extract the first word of "escript", so it can be a program name with args.
+set dummy escript; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_path_ESCRIPT+set}" = set; then :
$as_echo_n "(cached) " >&6
else
- if test -z "$GREP"; then
- ac_path_GREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
+ case $ESCRIPT in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_ESCRIPT="$ESCRIPT" # Let the user override the test with a path.
+ ;;
+ *)
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
+for as_dir in $ERLANG_ROOT_DIR/bin
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
- for ac_prog in grep ggrep; do
for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
- { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
-# Check for GNU ac_path_GREP and select it if it is found.
- # Check for GNU $ac_path_GREP
-case `"$ac_path_GREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'GREP' >> "conftest.nl"
- "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_GREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_GREP="$ac_path_GREP"
- ac_path_GREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_GREP_found && break 3
- done
- done
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ ac_cv_path_ESCRIPT="$as_dir/$ac_word$ac_exec_ext"
+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
done
IFS=$as_save_IFS
- if test -z "$ac_cv_path_GREP"; then
- as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
+
+ ;;
+esac
+fi
+ESCRIPT=$ac_cv_path_ESCRIPT
+if test -n "$ESCRIPT"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ESCRIPT" >&5
+$as_echo "$ESCRIPT" >&6; }
else
- ac_cv_path_GREP=$GREP
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
-$as_echo "$ac_cv_path_GREP" >&6; }
- GREP="$ac_cv_path_GREP"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
-$as_echo_n "checking for egrep... " >&6; }
-if ${ac_cv_path_EGREP+:} false; then :
+#locating make
+# Extract the first word of "make", so it can be a program name with args.
+set dummy make; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_prog_MAKE+set}" = set; then :
$as_echo_n "(cached) " >&6
else
- if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
- then ac_cv_path_EGREP="$GREP -E"
- else
- if test -z "$EGREP"; then
- ac_path_EGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
+ if test -n "$MAKE"; then
+ ac_cv_prog_MAKE="$MAKE" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
- for ac_prog in egrep; do
for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
- { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
-# Check for GNU ac_path_EGREP and select it if it is found.
- # Check for GNU $ac_path_EGREP
-case `"$ac_path_EGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'EGREP' >> "conftest.nl"
- "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_EGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_EGREP="$ac_path_EGREP"
- ac_path_EGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_EGREP_found && break 3
- done
- done
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ ac_cv_prog_MAKE="make"
+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
done
IFS=$as_save_IFS
- if test -z "$ac_cv_path_EGREP"; then
- as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
+
+fi
+fi
+MAKE=$ac_cv_prog_MAKE
+if test -n "$MAKE"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5
+$as_echo "$MAKE" >&6; }
else
- ac_cv_path_EGREP=$EGREP
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
fi
- fi
+
+
+if test "x$ESCRIPT" = "x"; then
+ as_fn_error $? "'escript' was not found" "$LINENO" 5
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
-$as_echo "$ac_cv_path_EGREP" >&6; }
- EGREP="$ac_cv_path_EGREP"
+if test "x$MAKE" = "x"; then
+ as_fn_error $? "'make' was not found" "$LINENO" 5
+fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
-$as_echo_n "checking for ANSI C header files... " >&6; }
-if ${ac_cv_header_stdc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <float.h>
+# Change default prefix
-int
-main ()
-{
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_header_stdc=yes
+# Check whether --enable-hipe was given.
+if test "${enable_hipe+set}" = set; then :
+ enableval=$enable_hipe; case "${enableval}" in
+ yes) hipe=true ;;
+ no) hipe=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-hipe" "$LINENO" 5 ;;
+esac
else
- ac_cv_header_stdc=no
+ hipe=false
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-if test $ac_cv_header_stdc = yes; then
- # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "memchr" >/dev/null 2>&1; then :
+# Check whether --enable-roster_gateway_workaround was given.
+if test "${enable_roster_gateway_workaround+set}" = set; then :
+ enableval=$enable_roster_gateway_workaround; case "${enableval}" in
+ yes) roster_gateway_workaround=true ;;
+ no) roster_gateway_workaround=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-roster-gateway-workaround" "$LINENO" 5 ;;
+esac
else
- ac_cv_header_stdc=no
+ roster_gateway_workaround=false
fi
-rm -f conftest*
-fi
-if test $ac_cv_header_stdc = yes; then
- # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
+# Check whether --enable-transient_supervisors was given.
+if test "${enable_transient_supervisors+set}" = set; then :
+ enableval=$enable_transient_supervisors; case "${enableval}" in
+ yes) transient_supervisors=true ;;
+ no) transient_supervisors=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-transient_supervisors" "$LINENO" 5 ;;
+esac
+else
+ transient_supervisors=false
+fi
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "free" >/dev/null 2>&1; then :
+# Check whether --enable-full_xml was given.
+if test "${enable_full_xml+set}" = set; then :
+ enableval=$enable_full_xml; case "${enableval}" in
+ yes) full_xml=true ;;
+ no) full_xml=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-full-xml" "$LINENO" 5 ;;
+esac
else
- ac_cv_header_stdc=no
+ full_xml=false
fi
-rm -f conftest*
-fi
-if test $ac_cv_header_stdc = yes; then
- # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
- if test "$cross_compiling" = yes; then :
- :
+# Check whether --enable-mssql was given.
+if test "${enable_mssql+set}" = set; then :
+ enableval=$enable_mssql; case "${enableval}" in
+ yes) db_type=mssql ;;
+ no) db_type=generic ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-mssql" "$LINENO" 5 ;;
+esac
else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ctype.h>
-#include <stdlib.h>
-#if ((' ' & 0x0FF) == 0x020)
-# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#else
-# define ISLOWER(c) \
- (('a' <= (c) && (c) <= 'i') \
- || ('j' <= (c) && (c) <= 'r') \
- || ('s' <= (c) && (c) <= 'z'))
-# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-#endif
+ db_type=generic
+fi
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int
-main ()
-{
- int i;
- for (i = 0; i < 256; i++)
- if (XOR (islower (i), ISLOWER (i))
- || toupper (i) != TOUPPER (i))
- return 2;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
+# Check whether --enable-tools was given.
+if test "${enable_tools+set}" = set; then :
+ enableval=$enable_tools; case "${enableval}" in
+ yes) tools=true ;;
+ no) tools=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-tools" "$LINENO" 5 ;;
+esac
else
- ac_cv_header_stdc=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
+ tools=false
fi
+
+# Check whether --enable-all was given.
+if test "${enable_all+set}" = set; then :
+ enableval=$enable_all; case "${enableval}" in
+ yes) nif=true odbc=true mysql=true pgsql=true pam=true zlib=true stun=true json=true iconv=true debug=true http=true ;;
+ no) nif=false odbc=false mysql=false pgsql=false pam=false zlib=false stun=false json=false iconv=false debug=false http=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-all" "$LINENO" 5 ;;
+esac
fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
-$as_echo "$ac_cv_header_stdc" >&6; }
-if test $ac_cv_header_stdc = yes; then
-$as_echo "#define STDC_HEADERS 1" >>confdefs.h
+# Check whether --enable-nif was given.
+if test "${enable_nif+set}" = set; then :
+ enableval=$enable_nif; case "${enableval}" in
+ yes) nif=true ;;
+ no) nif=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-nif" "$LINENO" 5 ;;
+esac
+else
+ if test "x$nif" = "x"; then nif=false; fi
fi
-# On IRIX 5.3, sys/types and inttypes.h are conflicting.
-for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
- inttypes.h stdint.h unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
+# Check whether --enable-odbc was given.
+if test "${enable_odbc+set}" = set; then :
+ enableval=$enable_odbc; case "${enableval}" in
+ yes) odbc=true ;;
+ no) odbc=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-odbc" "$LINENO" 5 ;;
+esac
+else
+ if test "x$odbc" = "x"; then odbc=false; fi
fi
-done
+# Check whether --enable-mysql was given.
+if test "${enable_mysql+set}" = set; then :
+ enableval=$enable_mysql; case "${enableval}" in
+ yes) mysql=true ;;
+ no) mysql=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-mysql" "$LINENO" 5 ;;
+esac
+else
+ if test "x$mysql" = "x"; then mysql=false; fi
+fi
-# Check whether --with-expat was given.
-if test "${with_expat+set}" = set; then :
- withval=$with_expat;
+# Check whether --enable-pgsql was given.
+if test "${enable_pgsql+set}" = set; then :
+ enableval=$enable_pgsql; case "${enableval}" in
+ yes) pgsql=true ;;
+ no) pgsql=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-pgsql" "$LINENO" 5 ;;
+esac
+else
+ if test "x$pgsql" = "x"; then pgsql=false; fi
fi
- EXPAT_CFLAGS=
- EXPAT_LIBS=
- if test x"$with_expat" != x; then
- EXPAT_CFLAGS="-I$with_expat/include"
- EXPAT_LIBS="-L$with_expat/lib"
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XML_ParserCreate in -lexpat" >&5
-$as_echo_n "checking for XML_ParserCreate in -lexpat... " >&6; }
-if ${ac_cv_lib_expat_XML_ParserCreate+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lexpat "$EXPAT_LIBS" $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char XML_ParserCreate ();
-int
-main ()
-{
-return XML_ParserCreate ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_expat_XML_ParserCreate=yes
+# Check whether --enable-pam was given.
+if test "${enable_pam+set}" = set; then :
+ enableval=$enable_pam; case "${enableval}" in
+ yes) pam=true ;;
+ no) pam=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-pam" "$LINENO" 5 ;;
+esac
else
- ac_cv_lib_expat_XML_ParserCreate=no
+ if test "x$pam" = "x"; then pam=false; fi
fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_expat_XML_ParserCreate" >&5
-$as_echo "$ac_cv_lib_expat_XML_ParserCreate" >&6; }
-if test "x$ac_cv_lib_expat_XML_ParserCreate" = xyes; then :
- EXPAT_LIBS="$EXPAT_LIBS -lexpat"
- expat_found=yes
+
+
+# Check whether --enable-zlib was given.
+if test "${enable_zlib+set}" = set; then :
+ enableval=$enable_zlib; case "${enableval}" in
+ yes) zlib=true ;;
+ no) zlib=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-zlib" "$LINENO" 5 ;;
+esac
else
- expat_found=no
+ if test "x$zlib" = "x"; then zlib=true; fi
fi
- if test $expat_found = no; then
- as_fn_error $? "Could not find development files of Expat library" "$LINENO" 5
- fi
- expat_save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $EXPAT_CFLAGS"
- expat_save_CPPFLAGS="$CPPFLAGS"
- CPPFLAGS="$CPPFLAGS $EXPAT_CFLAGS"
- for ac_header in expat.h
-do :
- ac_fn_c_check_header_mongrel "$LINENO" "expat.h" "ac_cv_header_expat_h" "$ac_includes_default"
-if test "x$ac_cv_header_expat_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_EXPAT_H 1
-_ACEOF
+# Check whether --enable-stun was given.
+if test "${enable_stun+set}" = set; then :
+ enableval=$enable_stun; case "${enableval}" in
+ yes) stun=true ;;
+ no) stun=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-stun" "$LINENO" 5 ;;
+esac
else
- expat_found=no
+ if test "x$stun" = "x"; then stun=false; fi
fi
-done
-
- if test $expat_found = no; then
- as_fn_error $? "Could not find expat.h" "$LINENO" 5
- fi
- CFLAGS="$expat_save_CFLAGS"
- CPPFLAGS="$expat_save_CPPFLAGS"
+# Check whether --enable-json was given.
+if test "${enable_json+set}" = set; then :
+ enableval=$enable_json; case "${enableval}" in
+ yes) json=true ;;
+ no) json=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-json" "$LINENO" 5 ;;
+esac
+else
+ if test "x$json" = "x"; then json=false; fi
+fi
+# Check whether --enable-iconv was given.
+if test "${enable_iconv+set}" = set; then :
+ enableval=$enable_iconv; case "${enableval}" in
+ yes) iconv=true ;;
+ no) iconv=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-iconv" "$LINENO" 5 ;;
+esac
+else
+ if test "x$iconv" = "x"; then iconv=true; fi
+fi
-# Checks for typedefs, structures, and compiler characteristics.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
-$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
-if ${ac_cv_c_const+:} false; then :
- $as_echo_n "(cached) " >&6
+# Check whether --enable-debug was given.
+if test "${enable_debug+set}" = set; then :
+ enableval=$enable_debug; case "${enableval}" in
+ yes) debug=true ;;
+ no) debug=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-debug" "$LINENO" 5 ;;
+esac
else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
+ if test "x$debug" = "x"; then debug=true; fi
+fi
-int
-main ()
-{
-/* FIXME: Include the comments suggested by Paul. */
-#ifndef __cplusplus
- /* Ultrix mips cc rejects this. */
- typedef int charset[2];
- const charset cs;
- /* SunOS 4.1.1 cc rejects this. */
- char const *const *pcpcc;
- char **ppc;
- /* NEC SVR4.0.2 mips cc rejects this. */
- struct point {int x, y;};
- static struct point const zero = {0,0};
- /* AIX XL C 1.02.0.0 rejects this.
- It does not let you subtract one const X* pointer from another in
- an arm of an if-expression whose if-part is not a constant
- expression */
- const char *g = "string";
- pcpcc = &g + (g ? g-g : 0);
- /* HPUX 7.0 cc rejects these. */
- ++pcpcc;
- ppc = (char**) pcpcc;
- pcpcc = (char const *const *) ppc;
- { /* SCO 3.2v4 cc rejects this. */
- char *t;
- char const *s = 0 ? (char *) 0 : (char const *) 0;
-
- *t++ = 0;
- if (s) return 0;
- }
- { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
- int x[] = {25, 17};
- const int *foo = &x[0];
- ++foo;
- }
- { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
- typedef const int *iptr;
- iptr p = 0;
- ++p;
- }
- { /* AIX XL C 1.02.0.0 rejects this saying
- "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
- struct s { int j; const int *ap[3]; };
- struct s *b; b->j = 5;
- }
- { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
- const int foo = 10;
- if (!foo) return 0;
- }
- return !cs[0] && !zero.x;
-#endif
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_c_const=yes
+# Check whether --enable-http was given.
+if test "${enable_http+set}" = set; then :
+ enableval=$enable_http; case "${enableval}" in
+ yes) http=true ;;
+ no) http=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-http" "$LINENO" 5 ;;
+esac
else
- ac_cv_c_const=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+ if test "x$http" = "x"; then http=false; fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
-$as_echo "$ac_cv_c_const" >&6; }
-if test $ac_cv_c_const = no; then
-$as_echo "#define const /**/" >>confdefs.h
+# Check whether --enable-lager was given.
+if test "${enable_lager+set}" = set; then :
+ enableval=$enable_lager; case "${enableval}" in
+ yes) lager=true ;;
+ no) lager=false ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-lager" "$LINENO" 5 ;;
+esac
+else
+ if test "x$lager" = "x"; then lager=true; fi
fi
-# Check Erlang headers are installed
-#AC_CHECK_HEADER(erl_driver.h,,[AC_MSG_ERROR([cannot find Erlang header files])])
+ac_config_files="$ac_config_files Makefile vars.config src/ejabberd.app.src"
-# Change default prefix
+ENABLEUSER=""
+# Check whether --enable-user was given.
+if test "${enable_user+set}" = set; then :
+ enableval=$enable_user; case "${enableval}" in
+ yes) ENABLEUSER=`whoami` ;;
+ no) ENABLEUSER="" ;;
+ *) ENABLEUSER=$enableval
+ esac
+fi
-# Checks for library functions.
-for ac_header in stdlib.h
-do :
- ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
-if test "x$ac_cv_header_stdlib_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_STDLIB_H 1
-_ACEOF
+if test "$ENABLEUSER" != ""; then
+ echo "allow this system user to start ejabberd: $ENABLEUSER"
+ INSTALLUSER=$ENABLEUSER
fi
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
-$as_echo_n "checking for GNU libc compatible malloc... " >&6; }
-if ${ac_cv_func_malloc_0_nonnull+:} false; then :
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'sasl' library subdirectory" >&5
+$as_echo_n "checking for Erlang/OTP 'sasl' library subdirectory... " >&6; }
+if test "${ac_cv_erlang_lib_dir_sasl+set}" = set; then :
$as_echo_n "(cached) " >&6
else
- if test "$cross_compiling" = yes; then :
- ac_cv_func_malloc_0_nonnull=no
+ ac_ext=erl
+ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5'
+ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5 && echo "#!/bin/sh" > conftest$ac_exeext && $as_echo "\"$ERL\" -run conftest start -run init stop -noshell" >> conftest$ac_exeext && chmod +x conftest$ac_exeext'
+ if test "$cross_compiling" = yes; then :
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5 ; }
else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#if defined STDC_HEADERS || defined HAVE_STDLIB_H
-# include <stdlib.h>
-#else
-char *malloc ();
-#endif
+ cat > conftest.$ac_ext <<_ACEOF
+-module(conftest).
+-export([start/0]).
+
+start() ->
+ ReturnValue = case code:lib_dir("sasl") of
+ {error, bad_name} ->
+ file:write_file("conftest.out", "not found\n"),
+ 1;
+ LibDir ->
+ file:write_file("conftest.out", LibDir),
+ 0
+ end,
+ halt(ReturnValue)
+.
-int
-main ()
-{
-return ! malloc (0);
- ;
- return 0;
-}
_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- ac_cv_func_malloc_0_nonnull=yes
+if ac_fn_erl_try_run "$LINENO"; then :
+ ac_cv_erlang_lib_dir_sasl=`cat conftest.out`
+ rm -f conftest.out
else
- ac_cv_func_malloc_0_nonnull=no
+ if test ! -f conftest.out; then
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "test Erlang program execution failed
+See \`config.log' for more details" "$LINENO" 5 ; }
+ else
+ ac_cv_erlang_lib_dir_sasl="not found"
+ rm -f conftest.out
+ fi
fi
rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5
-$as_echo "$ac_cv_func_malloc_0_nonnull" >&6; }
-if test $ac_cv_func_malloc_0_nonnull = yes; then :
-
-$as_echo "#define HAVE_MALLOC 1" >>confdefs.h
+ ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_dir_sasl" >&5
+$as_echo "$ac_cv_erlang_lib_dir_sasl" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'sasl' library version" >&5
+$as_echo_n "checking for Erlang/OTP 'sasl' library version... " >&6; }
+if test "${ac_cv_erlang_lib_ver_sasl+set}" = set; then :
+ $as_echo_n "(cached) " >&6
else
- $as_echo "#define HAVE_MALLOC 0" >>confdefs.h
-
- case " $LIBOBJS " in
- *" malloc.$ac_objext "* ) ;;
- *) LIBOBJS="$LIBOBJS malloc.$ac_objext"
- ;;
-esac
-
+ if test "$ac_cv_erlang_lib_dir_sasl" = "not found"; then :
+ ac_cv_erlang_lib_ver_sasl="not found"
+else
+ ac_cv_erlang_lib_ver_sasl=`$as_echo "$ac_cv_erlang_lib_dir_sasl" | sed -n -e 's,^.*-\([^/-]*\)$,\1,p'`
+fi
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_ver_sasl" >&5
+$as_echo "$ac_cv_erlang_lib_ver_sasl" >&6; }
+ERLANG_LIB_DIR_sasl=$ac_cv_erlang_lib_dir_sasl
-$as_echo "#define malloc rpl_malloc" >>confdefs.h
+ERLANG_LIB_VER_sasl=$ac_cv_erlang_lib_ver_sasl
+if test "$ac_cv_erlang_lib_dir_sasl" = "not found"; then :
+ as_fn_error $? "Erlang application 'sasl' was not found" "$LINENO" 5
fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
-$as_echo_n "checking for ANSI C header files... " >&6; }
-if ${ac_cv_header_stdc+:} false; then :
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'crypto' library subdirectory" >&5
+$as_echo_n "checking for Erlang/OTP 'crypto' library subdirectory... " >&6; }
+if test "${ac_cv_erlang_lib_dir_crypto+set}" = set; then :
$as_echo_n "(cached) " >&6
else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <float.h>
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_header_stdc=yes
+ ac_ext=erl
+ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5'
+ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5 && echo "#!/bin/sh" > conftest$ac_exeext && $as_echo "\"$ERL\" -run conftest start -run init stop -noshell" >> conftest$ac_exeext && chmod +x conftest$ac_exeext'
+ if test "$cross_compiling" = yes; then :
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5 ; }
else
- ac_cv_header_stdc=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+ cat > conftest.$ac_ext <<_ACEOF
+-module(conftest).
+-export([start/0]).
-if test $ac_cv_header_stdc = yes; then
- # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <string.h>
+start() ->
+ ReturnValue = case code:lib_dir("crypto") of
+ {error, bad_name} ->
+ file:write_file("conftest.out", "not found\n"),
+ 1;
+ LibDir ->
+ file:write_file("conftest.out", LibDir),
+ 0
+ end,
+ halt(ReturnValue)
+.
_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "memchr" >/dev/null 2>&1; then :
-
+if ac_fn_erl_try_run "$LINENO"; then :
+ ac_cv_erlang_lib_dir_crypto=`cat conftest.out`
+ rm -f conftest.out
else
- ac_cv_header_stdc=no
+ if test ! -f conftest.out; then
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "test Erlang program execution failed
+See \`config.log' for more details" "$LINENO" 5 ; }
+ else
+ ac_cv_erlang_lib_dir_crypto="not found"
+ rm -f conftest.out
+ fi
fi
-rm -f conftest*
-
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+ conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-if test $ac_cv_header_stdc = yes; then
- # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "free" >/dev/null 2>&1; then :
+ ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_dir_crypto" >&5
+$as_echo "$ac_cv_erlang_lib_dir_crypto" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'crypto' library version" >&5
+$as_echo_n "checking for Erlang/OTP 'crypto' library version... " >&6; }
+if test "${ac_cv_erlang_lib_ver_crypto+set}" = set; then :
+ $as_echo_n "(cached) " >&6
else
- ac_cv_header_stdc=no
+ if test "$ac_cv_erlang_lib_dir_crypto" = "not found"; then :
+ ac_cv_erlang_lib_ver_crypto="not found"
+else
+ ac_cv_erlang_lib_ver_crypto=`$as_echo "$ac_cv_erlang_lib_dir_crypto" | sed -n -e 's,^.*-\([^/-]*\)$,\1,p'`
+fi
fi
-rm -f conftest*
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_ver_crypto" >&5
+$as_echo "$ac_cv_erlang_lib_ver_crypto" >&6; }
+ERLANG_LIB_DIR_crypto=$ac_cv_erlang_lib_dir_crypto
+
+ERLANG_LIB_VER_crypto=$ac_cv_erlang_lib_ver_crypto
+if test "$ac_cv_erlang_lib_dir_crypto" = "not found"; then :
+ as_fn_error $? "Erlang application 'crypto' was not found" "$LINENO" 5
fi
-if test $ac_cv_header_stdc = yes; then
- # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
- if test "$cross_compiling" = yes; then :
- :
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'public_key' library subdirectory" >&5
+$as_echo_n "checking for Erlang/OTP 'public_key' library subdirectory... " >&6; }
+if test "${ac_cv_erlang_lib_dir_public_key+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ ac_ext=erl
+ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5'
+ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5 && echo "#!/bin/sh" > conftest$ac_exeext && $as_echo "\"$ERL\" -run conftest start -run init stop -noshell" >> conftest$ac_exeext && chmod +x conftest$ac_exeext'
+ if test "$cross_compiling" = yes; then :
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5 ; }
else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ctype.h>
-#include <stdlib.h>
-#if ((' ' & 0x0FF) == 0x020)
-# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#else
-# define ISLOWER(c) \
- (('a' <= (c) && (c) <= 'i') \
- || ('j' <= (c) && (c) <= 'r') \
- || ('s' <= (c) && (c) <= 'z'))
-# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-#endif
+ cat > conftest.$ac_ext <<_ACEOF
+-module(conftest).
+-export([start/0]).
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int
-main ()
-{
- int i;
- for (i = 0; i < 256; i++)
- if (XOR (islower (i), ISLOWER (i))
- || toupper (i) != TOUPPER (i))
- return 2;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
+start() ->
+ ReturnValue = case code:lib_dir("public_key") of
+ {error, bad_name} ->
+ file:write_file("conftest.out", "not found\n"),
+ 1;
+ LibDir ->
+ file:write_file("conftest.out", LibDir),
+ 0
+ end,
+ halt(ReturnValue)
+.
+_ACEOF
+if ac_fn_erl_try_run "$LINENO"; then :
+ ac_cv_erlang_lib_dir_public_key=`cat conftest.out`
+ rm -f conftest.out
else
- ac_cv_header_stdc=no
+ if test ! -f conftest.out; then
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "test Erlang program execution failed
+See \`config.log' for more details" "$LINENO" 5 ; }
+ else
+ ac_cv_erlang_lib_dir_public_key="not found"
+ rm -f conftest.out
+ fi
fi
rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
-$as_echo "$ac_cv_header_stdc" >&6; }
-if test $ac_cv_header_stdc = yes; then
-
-$as_echo "#define STDC_HEADERS 1" >>confdefs.h
+ ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
fi
-
-
-
-mod_irc=
-make_mod_irc=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build mod_irc" >&5
-$as_echo_n "checking whether build mod_irc... " >&6; }
-# Check whether --enable-mod_irc was given.
-if test "${enable_mod_irc+set}" = set; then :
- enableval=$enable_mod_irc; mr_enable_mod_irc="$enableval"
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_dir_public_key" >&5
+$as_echo "$ac_cv_erlang_lib_dir_public_key" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'public_key' library version" >&5
+$as_echo_n "checking for Erlang/OTP 'public_key' library version... " >&6; }
+if test "${ac_cv_erlang_lib_ver_public_key+set}" = set; then :
+ $as_echo_n "(cached) " >&6
else
- mr_enable_mod_irc=yes
-fi
-
-if test "$mr_enable_mod_irc" = "yes"; then
-mod_irc=mod_irc
-make_mod_irc=mod_irc/Makefile
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $mr_enable_mod_irc" >&5
-$as_echo "$mr_enable_mod_irc" >&6; }
-
-
-
-
-
-mod_muc=
-make_mod_muc=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build mod_muc" >&5
-$as_echo_n "checking whether build mod_muc... " >&6; }
-# Check whether --enable-mod_muc was given.
-if test "${enable_mod_muc+set}" = set; then :
- enableval=$enable_mod_muc; mr_enable_mod_muc="$enableval"
+ if test "$ac_cv_erlang_lib_dir_public_key" = "not found"; then :
+ ac_cv_erlang_lib_ver_public_key="not found"
else
- mr_enable_mod_muc=yes
+ ac_cv_erlang_lib_ver_public_key=`$as_echo "$ac_cv_erlang_lib_dir_public_key" | sed -n -e 's,^.*-\([^/-]*\)$,\1,p'`
fi
-
-if test "$mr_enable_mod_muc" = "yes"; then
-mod_muc=mod_muc
-make_mod_muc=mod_muc/Makefile
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $mr_enable_mod_muc" >&5
-$as_echo "$mr_enable_mod_muc" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_ver_public_key" >&5
+$as_echo "$ac_cv_erlang_lib_ver_public_key" >&6; }
+ERLANG_LIB_DIR_public_key=$ac_cv_erlang_lib_dir_public_key
+ERLANG_LIB_VER_public_key=$ac_cv_erlang_lib_ver_public_key
+if test "$ac_cv_erlang_lib_dir_public_key" = "not found"; then :
+ as_fn_error $? "Erlang application 'public_key' was not found" "$LINENO" 5
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'ssl' library subdirectory" >&5
+$as_echo_n "checking for Erlang/OTP 'ssl' library subdirectory... " >&6; }
+if test "${ac_cv_erlang_lib_dir_ssl+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ ac_ext=erl
+ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5'
+ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5 && echo "#!/bin/sh" > conftest$ac_exeext && $as_echo "\"$ERL\" -run conftest start -run init stop -noshell" >> conftest$ac_exeext && chmod +x conftest$ac_exeext'
+ if test "$cross_compiling" = yes; then :
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5 ; }
+else
+ cat > conftest.$ac_ext <<_ACEOF
+-module(conftest).
+-export([start/0]).
+start() ->
+ ReturnValue = case code:lib_dir("ssl") of
+ {error, bad_name} ->
+ file:write_file("conftest.out", "not found\n"),
+ 1;
+ LibDir ->
+ file:write_file("conftest.out", LibDir),
+ 0
+ end,
+ halt(ReturnValue)
+.
-mod_proxy65=
-make_mod_proxy65=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build mod_proxy65" >&5
-$as_echo_n "checking whether build mod_proxy65... " >&6; }
-# Check whether --enable-mod_proxy65 was given.
-if test "${enable_mod_proxy65+set}" = set; then :
- enableval=$enable_mod_proxy65; mr_enable_mod_proxy65="$enableval"
+_ACEOF
+if ac_fn_erl_try_run "$LINENO"; then :
+ ac_cv_erlang_lib_dir_ssl=`cat conftest.out`
+ rm -f conftest.out
else
- mr_enable_mod_proxy65=yes
+ if test ! -f conftest.out; then
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "test Erlang program execution failed
+See \`config.log' for more details" "$LINENO" 5 ; }
+ else
+ ac_cv_erlang_lib_dir_ssl="not found"
+ rm -f conftest.out
+ fi
fi
-
-if test "$mr_enable_mod_proxy65" = "yes"; then
-mod_proxy65=mod_proxy65
-make_mod_proxy65=mod_proxy65/Makefile
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+ conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $mr_enable_mod_proxy65" >&5
-$as_echo "$mr_enable_mod_proxy65" >&6; }
-
-
-
+ ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
-mod_pubsub=
-make_mod_pubsub=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build mod_pubsub" >&5
-$as_echo_n "checking whether build mod_pubsub... " >&6; }
-# Check whether --enable-mod_pubsub was given.
-if test "${enable_mod_pubsub+set}" = set; then :
- enableval=$enable_mod_pubsub; mr_enable_mod_pubsub="$enableval"
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_dir_ssl" >&5
+$as_echo "$ac_cv_erlang_lib_dir_ssl" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'ssl' library version" >&5
+$as_echo_n "checking for Erlang/OTP 'ssl' library version... " >&6; }
+if test "${ac_cv_erlang_lib_ver_ssl+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ if test "$ac_cv_erlang_lib_dir_ssl" = "not found"; then :
+ ac_cv_erlang_lib_ver_ssl="not found"
else
- mr_enable_mod_pubsub=yes
+ ac_cv_erlang_lib_ver_ssl=`$as_echo "$ac_cv_erlang_lib_dir_ssl" | sed -n -e 's,^.*-\([^/-]*\)$,\1,p'`
fi
-
-if test "$mr_enable_mod_pubsub" = "yes"; then
-mod_pubsub=mod_pubsub
-make_mod_pubsub=mod_pubsub/Makefile
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $mr_enable_mod_pubsub" >&5
-$as_echo "$mr_enable_mod_pubsub" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_ver_ssl" >&5
+$as_echo "$ac_cv_erlang_lib_ver_ssl" >&6; }
+ERLANG_LIB_DIR_ssl=$ac_cv_erlang_lib_dir_ssl
+ERLANG_LIB_VER_ssl=$ac_cv_erlang_lib_ver_ssl
+if test "$ac_cv_erlang_lib_dir_ssl" = "not found"; then :
+ as_fn_error $? "Erlang application 'ssl' was not found" "$LINENO" 5
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'mnesia' library subdirectory" >&5
+$as_echo_n "checking for Erlang/OTP 'mnesia' library subdirectory... " >&6; }
+if test "${ac_cv_erlang_lib_dir_mnesia+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ ac_ext=erl
+ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5'
+ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5 && echo "#!/bin/sh" > conftest$ac_exeext && $as_echo "\"$ERL\" -run conftest start -run init stop -noshell" >> conftest$ac_exeext && chmod +x conftest$ac_exeext'
+ if test "$cross_compiling" = yes; then :
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5 ; }
+else
+ cat > conftest.$ac_ext <<_ACEOF
+-module(conftest).
+-export([start/0]).
+start() ->
+ ReturnValue = case code:lib_dir("mnesia") of
+ {error, bad_name} ->
+ file:write_file("conftest.out", "not found\n"),
+ 1;
+ LibDir ->
+ file:write_file("conftest.out", LibDir),
+ 0
+ end,
+ halt(ReturnValue)
+.
-eldap=
-make_eldap=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build eldap" >&5
-$as_echo_n "checking whether build eldap... " >&6; }
-# Check whether --enable-eldap was given.
-if test "${enable_eldap+set}" = set; then :
- enableval=$enable_eldap; mr_enable_eldap="$enableval"
+_ACEOF
+if ac_fn_erl_try_run "$LINENO"; then :
+ ac_cv_erlang_lib_dir_mnesia=`cat conftest.out`
+ rm -f conftest.out
else
- mr_enable_eldap=yes
+ if test ! -f conftest.out; then
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "test Erlang program execution failed
+See \`config.log' for more details" "$LINENO" 5 ; }
+ else
+ ac_cv_erlang_lib_dir_mnesia="not found"
+ rm -f conftest.out
+ fi
fi
-
-if test "$mr_enable_eldap" = "yes"; then
-eldap=eldap
-make_eldap=eldap/Makefile
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+ conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $mr_enable_eldap" >&5
-$as_echo "$mr_enable_eldap" >&6; }
-
-
-
+ ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
-odbc=
-make_odbc=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build odbc" >&5
-$as_echo_n "checking whether build odbc... " >&6; }
-# Check whether --enable-odbc was given.
-if test "${enable_odbc+set}" = set; then :
- enableval=$enable_odbc; mr_enable_odbc="$enableval"
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_dir_mnesia" >&5
+$as_echo "$ac_cv_erlang_lib_dir_mnesia" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'mnesia' library version" >&5
+$as_echo_n "checking for Erlang/OTP 'mnesia' library version... " >&6; }
+if test "${ac_cv_erlang_lib_ver_mnesia+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ if test "$ac_cv_erlang_lib_dir_mnesia" = "not found"; then :
+ ac_cv_erlang_lib_ver_mnesia="not found"
else
- mr_enable_odbc=no
+ ac_cv_erlang_lib_ver_mnesia=`$as_echo "$ac_cv_erlang_lib_dir_mnesia" | sed -n -e 's,^.*-\([^/-]*\)$,\1,p'`
fi
-
-if test "$mr_enable_odbc" = "yes"; then
-odbc=odbc
-make_odbc=odbc/Makefile
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $mr_enable_odbc" >&5
-$as_echo "$mr_enable_odbc" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_ver_mnesia" >&5
+$as_echo "$ac_cv_erlang_lib_ver_mnesia" >&6; }
+ERLANG_LIB_DIR_mnesia=$ac_cv_erlang_lib_dir_mnesia
+ERLANG_LIB_VER_mnesia=$ac_cv_erlang_lib_ver_mnesia
+if test "$ac_cv_erlang_lib_dir_mnesia" = "not found"; then :
+ as_fn_error $? "Erlang application 'mnesia' was not found" "$LINENO" 5
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'inets' library subdirectory" >&5
+$as_echo_n "checking for Erlang/OTP 'inets' library subdirectory... " >&6; }
+if test "${ac_cv_erlang_lib_dir_inets+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ ac_ext=erl
+ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5'
+ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5 && echo "#!/bin/sh" > conftest$ac_exeext && $as_echo "\"$ERL\" -run conftest start -run init stop -noshell" >> conftest$ac_exeext && chmod +x conftest$ac_exeext'
+ if test "$cross_compiling" = yes; then :
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5 ; }
+else
+ cat > conftest.$ac_ext <<_ACEOF
+-module(conftest).
+-export([start/0]).
+start() ->
+ ReturnValue = case code:lib_dir("inets") of
+ {error, bad_name} ->
+ file:write_file("conftest.out", "not found\n"),
+ 1;
+ LibDir ->
+ file:write_file("conftest.out", LibDir),
+ 0
+ end,
+ halt(ReturnValue)
+.
-tls=
-make_tls=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build tls" >&5
-$as_echo_n "checking whether build tls... " >&6; }
-# Check whether --enable-tls was given.
-if test "${enable_tls+set}" = set; then :
- enableval=$enable_tls; mr_enable_tls="$enableval"
+_ACEOF
+if ac_fn_erl_try_run "$LINENO"; then :
+ ac_cv_erlang_lib_dir_inets=`cat conftest.out`
+ rm -f conftest.out
else
- mr_enable_tls=yes
+ if test ! -f conftest.out; then
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "test Erlang program execution failed
+See \`config.log' for more details" "$LINENO" 5 ; }
+ else
+ ac_cv_erlang_lib_dir_inets="not found"
+ rm -f conftest.out
+ fi
fi
-
-if test "$mr_enable_tls" = "yes"; then
-tls=tls
-make_tls=tls/Makefile
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+ conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $mr_enable_tls" >&5
-$as_echo "$mr_enable_tls" >&6; }
-
-
-
+ ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
-web=
-make_web=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build web" >&5
-$as_echo_n "checking whether build web... " >&6; }
-# Check whether --enable-web was given.
-if test "${enable_web+set}" = set; then :
- enableval=$enable_web; mr_enable_web="$enableval"
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_dir_inets" >&5
+$as_echo "$ac_cv_erlang_lib_dir_inets" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'inets' library version" >&5
+$as_echo_n "checking for Erlang/OTP 'inets' library version... " >&6; }
+if test "${ac_cv_erlang_lib_ver_inets+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ if test "$ac_cv_erlang_lib_dir_inets" = "not found"; then :
+ ac_cv_erlang_lib_ver_inets="not found"
else
- mr_enable_web=yes
+ ac_cv_erlang_lib_ver_inets=`$as_echo "$ac_cv_erlang_lib_dir_inets" | sed -n -e 's,^.*-\([^/-]*\)$,\1,p'`
fi
-
-if test "$mr_enable_web" = "yes"; then
-web=web
-make_web=web/Makefile
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $mr_enable_web" >&5
-$as_echo "$mr_enable_web" >&6; }
-
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_ver_inets" >&5
+$as_echo "$ac_cv_erlang_lib_ver_inets" >&6; }
+ERLANG_LIB_DIR_inets=$ac_cv_erlang_lib_dir_inets
+ERLANG_LIB_VER_inets=$ac_cv_erlang_lib_ver_inets
+if test "$ac_cv_erlang_lib_dir_inets" = "not found"; then :
+ as_fn_error $? "Erlang application 'inets' was not found" "$LINENO" 5
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'compiler' library subdirectory" >&5
+$as_echo_n "checking for Erlang/OTP 'compiler' library subdirectory... " >&6; }
+if test "${ac_cv_erlang_lib_dir_compiler+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ ac_ext=erl
+ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5'
+ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5 && echo "#!/bin/sh" > conftest$ac_exeext && $as_echo "\"$ERL\" -run conftest start -run init stop -noshell" >> conftest$ac_exeext && chmod +x conftest$ac_exeext'
+ if test "$cross_compiling" = yes; then :
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5 ; }
+else
+ cat > conftest.$ac_ext <<_ACEOF
+-module(conftest).
+-export([start/0]).
+start() ->
+ ReturnValue = case code:lib_dir("compiler") of
+ {error, bad_name} ->
+ file:write_file("conftest.out", "not found\n"),
+ 1;
+ LibDir ->
+ file:write_file("conftest.out", LibDir),
+ 0
+ end,
+ halt(ReturnValue)
+.
-ejabberd_zlib=
-make_ejabberd_zlib=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build ejabberd_zlib" >&5
-$as_echo_n "checking whether build ejabberd_zlib... " >&6; }
-# Check whether --enable-ejabberd_zlib was given.
-if test "${enable_ejabberd_zlib+set}" = set; then :
- enableval=$enable_ejabberd_zlib; mr_enable_ejabberd_zlib="$enableval"
+_ACEOF
+if ac_fn_erl_try_run "$LINENO"; then :
+ ac_cv_erlang_lib_dir_compiler=`cat conftest.out`
+ rm -f conftest.out
else
- mr_enable_ejabberd_zlib=yes
+ if test ! -f conftest.out; then
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "test Erlang program execution failed
+See \`config.log' for more details" "$LINENO" 5 ; }
+ else
+ ac_cv_erlang_lib_dir_compiler="not found"
+ rm -f conftest.out
+ fi
fi
-
-if test "$mr_enable_ejabberd_zlib" = "yes"; then
-ejabberd_zlib=ejabberd_zlib
-make_ejabberd_zlib=ejabberd_zlib/Makefile
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+ conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $mr_enable_ejabberd_zlib" >&5
-$as_echo "$mr_enable_ejabberd_zlib" >&6; }
-
+ ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-#locating zlib
-
-# Check whether --with-zlib was given.
-if test "${with_zlib+set}" = set; then :
- withval=$with_zlib;
fi
-
-
-if test x"$ejabberd_zlib" != x; then
- ZLIB_CFLAGS=
- ZLIB_LIBS=
- if test x"$with_zlib" != x; then
- ZLIB_CFLAGS="-I$with_zlib/include"
- ZLIB_LIBS="-L$with_zlib/lib"
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gzgets in -lz" >&5
-$as_echo_n "checking for gzgets in -lz... " >&6; }
-if ${ac_cv_lib_z_gzgets+:} false; then :
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_dir_compiler" >&5
+$as_echo "$ac_cv_erlang_lib_dir_compiler" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'compiler' library version" >&5
+$as_echo_n "checking for Erlang/OTP 'compiler' library version... " >&6; }
+if test "${ac_cv_erlang_lib_ver_compiler+set}" = set; then :
$as_echo_n "(cached) " >&6
else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lz "$ZLIB_LIBS" $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char gzgets ();
-int
-main ()
-{
-return gzgets ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_z_gzgets=yes
-else
- ac_cv_lib_z_gzgets=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_gzgets" >&5
-$as_echo "$ac_cv_lib_z_gzgets" >&6; }
-if test "x$ac_cv_lib_z_gzgets" = xyes; then :
- ZLIB_LIBS="$ZLIB_LIBS -lz"
- zlib_found=yes
+ if test "$ac_cv_erlang_lib_dir_compiler" = "not found"; then :
+ ac_cv_erlang_lib_ver_compiler="not found"
else
- zlib_found=no
+ ac_cv_erlang_lib_ver_compiler=`$as_echo "$ac_cv_erlang_lib_dir_compiler" | sed -n -e 's,^.*-\([^/-]*\)$,\1,p'`
fi
-
- if test $zlib_found = no; then
- as_fn_error $? "Could not find development files of zlib library. Install them or disable \`ejabberd_zlib' with: --disable-ejabberd_zlib" "$LINENO" 5
- fi
- zlib_save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $ZLIB_CFLAGS"
- zlib_save_CPPFLAGS="$CFLAGS"
- CPPFLAGS="$CPPFLAGS $ZLIB_CFLAGS"
- for ac_header in zlib.h
-do :
- ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default"
-if test "x$ac_cv_header_zlib_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_ZLIB_H 1
-_ACEOF
-
-else
- zlib_found=no
fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_ver_compiler" >&5
+$as_echo "$ac_cv_erlang_lib_ver_compiler" >&6; }
+ERLANG_LIB_DIR_compiler=$ac_cv_erlang_lib_dir_compiler
-done
-
- if test $zlib_found = no; then
- as_fn_error $? "Could not find zlib.h. Install it or disable \`ejabberd_zlib' with: --disable-ejabberd_zlib" "$LINENO" 5
- fi
- CFLAGS="$zlib_save_CFLAGS"
- CPPFLAGS="$zlib_save_CPPFLAGS"
-
-
+ERLANG_LIB_VER_compiler=$ac_cv_erlang_lib_ver_compiler
+if test "$ac_cv_erlang_lib_dir_compiler" = "not found"; then :
+ as_fn_error $? "Erlang application 'compiler' was not found" "$LINENO" 5
fi
+if test "x$odbc" = "xtrue"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'odbc' library subdirectory" >&5
+$as_echo_n "checking for Erlang/OTP 'odbc' library subdirectory... " >&6; }
+if test "${ac_cv_erlang_lib_dir_odbc+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ ac_ext=erl
+ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5'
+ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5 && echo "#!/bin/sh" > conftest$ac_exeext && $as_echo "\"$ERL\" -run conftest start -run init stop -noshell" >> conftest$ac_exeext && chmod +x conftest$ac_exeext'
+ if test "$cross_compiling" = yes; then :
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5 ; }
+else
+ cat > conftest.$ac_ext <<_ACEOF
+-module(conftest).
+-export([start/0]).
+start() ->
+ ReturnValue = case code:lib_dir("odbc") of
+ {error, bad_name} ->
+ file:write_file("conftest.out", "not found\n"),
+ 1;
+ LibDir ->
+ file:write_file("conftest.out", LibDir),
+ 0
+ end,
+ halt(ReturnValue)
+.
-pam=
-make_pam=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build pam" >&5
-$as_echo_n "checking whether build pam... " >&6; }
-# Check whether --enable-pam was given.
-if test "${enable_pam+set}" = set; then :
- enableval=$enable_pam; mr_enable_pam="$enableval"
+_ACEOF
+if ac_fn_erl_try_run "$LINENO"; then :
+ ac_cv_erlang_lib_dir_odbc=`cat conftest.out`
+ rm -f conftest.out
else
- mr_enable_pam=no
+ if test ! -f conftest.out; then
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "test Erlang program execution failed
+See \`config.log' for more details" "$LINENO" 5 ; }
+ else
+ ac_cv_erlang_lib_dir_odbc="not found"
+ rm -f conftest.out
+ fi
fi
-
-if test "$mr_enable_pam" = "yes"; then
-pam=pam
-make_pam=pam/Makefile
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+ conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $mr_enable_pam" >&5
-$as_echo "$mr_enable_pam" >&6; }
-
-
+ ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
-#locating PAM
-
-# Check whether --with-pam was given.
-if test "${with_pam+set}" = set; then :
- withval=$with_pam;
fi
-
-if test x"$pam" != x; then
- PAM_CFLAGS=
- PAM_LIBS=
- if test x"$with_pam" != x; then
- PAM_CFLAGS="-I$with_pam/include"
- PAM_LIBS="-L$with_pam/lib"
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pam_start in -lpam" >&5
-$as_echo_n "checking for pam_start in -lpam... " >&6; }
-if ${ac_cv_lib_pam_pam_start+:} false; then :
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_dir_odbc" >&5
+$as_echo "$ac_cv_erlang_lib_dir_odbc" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'odbc' library version" >&5
+$as_echo_n "checking for Erlang/OTP 'odbc' library version... " >&6; }
+if test "${ac_cv_erlang_lib_ver_odbc+set}" = set; then :
$as_echo_n "(cached) " >&6
else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lpam "$PAM_LIBS" $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char pam_start ();
-int
-main ()
-{
-return pam_start ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_pam_pam_start=yes
+ if test "$ac_cv_erlang_lib_dir_odbc" = "not found"; then :
+ ac_cv_erlang_lib_ver_odbc="not found"
else
- ac_cv_lib_pam_pam_start=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+ ac_cv_erlang_lib_ver_odbc=`$as_echo "$ac_cv_erlang_lib_dir_odbc" | sed -n -e 's,^.*-\([^/-]*\)$,\1,p'`
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pam_pam_start" >&5
-$as_echo "$ac_cv_lib_pam_pam_start" >&6; }
-if test "x$ac_cv_lib_pam_pam_start" = xyes; then :
- PAM_LIBS="$PAM_LIBS -lpam"
- pam_found=yes
-else
- pam_found=no
fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_ver_odbc" >&5
+$as_echo "$ac_cv_erlang_lib_ver_odbc" >&6; }
+ERLANG_LIB_DIR_odbc=$ac_cv_erlang_lib_dir_odbc
- if test $pam_found = no; then
- as_fn_error $? "Could not find development files of PAM library. Install them or disable \`pam' with: --disable-pam" "$LINENO" 5
- fi
- pam_save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $PAM_CFLAGS"
- pam_save_CPPFLAGS="$CPPFLAGS"
- CPPFLAGS="$CPPFLAGS $PAM_CFLAGS"
- for ac_header in security/pam_appl.h
-do :
- ac_fn_c_check_header_mongrel "$LINENO" "security/pam_appl.h" "ac_cv_header_security_pam_appl_h" "$ac_includes_default"
-if test "x$ac_cv_header_security_pam_appl_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_SECURITY_PAM_APPL_H 1
-_ACEOF
+ERLANG_LIB_VER_odbc=$ac_cv_erlang_lib_ver_odbc
-else
- pam_found=no
+if test "$ac_cv_erlang_lib_dir_odbc" = "not found"; then :
+ as_fn_error $? "Erlang application 'odbc' was not found" "$LINENO" 5
fi
-done
-
- if test $pam_found = no; then
- as_fn_error $? "Could not find security/pam_appl.h. Install it or disable \`pam' with: --disable-pam" "$LINENO" 5
- fi
- CFLAGS="$pam_save_CFLAGS"
- CPPFLAGS="$pam_save_CPPFLAGS"
-
-
-
fi
-
-
-# Check whether --enable-hipe was given.
-if test "${enable_hipe+set}" = set; then :
- enableval=$enable_hipe; case "${enableval}" in
- yes) hipe=true ;;
- no) hipe=false ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-hipe" "$LINENO" 5 ;;
-esac
+if test "x$tools" = "xtrue"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'tools' library subdirectory" >&5
+$as_echo_n "checking for Erlang/OTP 'tools' library subdirectory... " >&6; }
+if test "${ac_cv_erlang_lib_dir_tools+set}" = set; then :
+ $as_echo_n "(cached) " >&6
else
- hipe=false
-fi
-
-
-
-# Check whether --enable-roster_gateway_workaround was given.
-if test "${enable_roster_gateway_workaround+set}" = set; then :
- enableval=$enable_roster_gateway_workaround; case "${enableval}" in
- yes) roster_gateway_workaround=true ;;
- no) roster_gateway_workaround=false ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-roster-gateway-workaround" "$LINENO" 5 ;;
-esac
+ ac_ext=erl
+ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5'
+ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5 && echo "#!/bin/sh" > conftest$ac_exeext && $as_echo "\"$ERL\" -run conftest start -run init stop -noshell" >> conftest$ac_exeext && chmod +x conftest$ac_exeext'
+ if test "$cross_compiling" = yes; then :
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5 ; }
else
- roster_gateway_workaround=false
-fi
-
+ cat > conftest.$ac_ext <<_ACEOF
+-module(conftest).
+-export([start/0]).
+start() ->
+ ReturnValue = case code:lib_dir("tools") of
+ {error, bad_name} ->
+ file:write_file("conftest.out", "not found\n"),
+ 1;
+ LibDir ->
+ file:write_file("conftest.out", LibDir),
+ 0
+ end,
+ halt(ReturnValue)
+.
-# Check whether --enable-mssql was given.
-if test "${enable_mssql+set}" = set; then :
- enableval=$enable_mssql; case "${enableval}" in
- yes) db_type=mssql ;;
- no) db_type=generic ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-mssql" "$LINENO" 5 ;;
-esac
+_ACEOF
+if ac_fn_erl_try_run "$LINENO"; then :
+ ac_cv_erlang_lib_dir_tools=`cat conftest.out`
+ rm -f conftest.out
else
- db_type=generic
+ if test ! -f conftest.out; then
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "test Erlang program execution failed
+See \`config.log' for more details" "$LINENO" 5 ; }
+ else
+ ac_cv_erlang_lib_dir_tools="not found"
+ rm -f conftest.out
+ fi
fi
-
-
-
-# Check whether --enable-transient_supervisors was given.
-if test "${enable_transient_supervisors+set}" = set; then :
- enableval=$enable_transient_supervisors; case "${enableval}" in
- yes) transient_supervisors=true ;;
- no) transient_supervisors=false ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-transient_supervisors" "$LINENO" 5 ;;
-esac
-else
- transient_supervisors=true
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+ conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
+ ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-# Check whether --enable-full_xml was given.
-if test "${enable_full_xml+set}" = set; then :
- enableval=$enable_full_xml; case "${enableval}" in
- yes) full_xml=true ;;
- no) full_xml=false ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-full-xml" "$LINENO" 5 ;;
-esac
-else
- full_xml=false
fi
-
-
-
-# Check whether --enable-nif was given.
-if test "${enable_nif+set}" = set; then :
- enableval=$enable_nif; case "${enableval}" in
- yes) nif=true ;;
- no) nif=false ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-nif" "$LINENO" 5 ;;
-esac
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_dir_tools" >&5
+$as_echo "$ac_cv_erlang_lib_dir_tools" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'tools' library version" >&5
+$as_echo_n "checking for Erlang/OTP 'tools' library version... " >&6; }
+if test "${ac_cv_erlang_lib_ver_tools+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ if test "$ac_cv_erlang_lib_dir_tools" = "not found"; then :
+ ac_cv_erlang_lib_ver_tools="not found"
else
- nif=false
+ ac_cv_erlang_lib_ver_tools=`$as_echo "$ac_cv_erlang_lib_dir_tools" | sed -n -e 's,^.*-\([^/-]*\)$,\1,p'`
fi
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_ver_tools" >&5
+$as_echo "$ac_cv_erlang_lib_ver_tools" >&6; }
+ERLANG_LIB_DIR_tools=$ac_cv_erlang_lib_dir_tools
+ERLANG_LIB_VER_tools=$ac_cv_erlang_lib_ver_tools
-
-ac_config_files="$ac_config_files Makefile $make_mod_irc $make_mod_muc $make_mod_pubsub $make_mod_proxy65 $make_eldap $make_pam $make_web mysql/Makefile pgsql/Makefile stringprep/Makefile stun/Makefile $make_tls $make_odbc $make_ejabberd_zlib"
-
-#openssl
-
-# Check whether --with-openssl was given.
-if test "${with_openssl+set}" = set; then :
- withval=$with_openssl;
+if test "$ac_cv_erlang_lib_dir_tools" = "not found"; then :
+ as_fn_error $? "Erlang application 'tools' was not found" "$LINENO" 5
fi
-unset SSL_LIBS;
-unset SSL_CFLAGS;
-have_openssl=no
-if test x"$tls" != x; then
- for ssl_prefix in $withval /usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /usr; do
- printf "looking for openssl in $ssl_prefix...\n"
- SSL_CFLAGS="-I$ssl_prefix/include"
- SSL_LIBS="-L$ssl_prefix/lib -lcrypto"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_new in -lssl" >&5
-$as_echo_n "checking for SSL_new in -lssl... " >&6; }
-if ${ac_cv_lib_ssl_SSL_new+:} false; then :
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'runtime_tools' library subdirectory" >&5
+$as_echo_n "checking for Erlang/OTP 'runtime_tools' library subdirectory... " >&6; }
+if test "${ac_cv_erlang_lib_dir_runtime_tools+set}" = set; then :
$as_echo_n "(cached) " >&6
else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lssl $SSL_LIBS $SSL_CFLAGS $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char SSL_new ();
-int
-main ()
-{
-return SSL_new ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_ssl_SSL_new=yes
-else
- ac_cv_lib_ssl_SSL_new=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_SSL_new" >&5
-$as_echo "$ac_cv_lib_ssl_SSL_new" >&6; }
-if test "x$ac_cv_lib_ssl_SSL_new" = xyes; then :
- have_openssl=yes
+ ac_ext=erl
+ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5'
+ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5 && echo "#!/bin/sh" > conftest$ac_exeext && $as_echo "\"$ERL\" -run conftest start -run init stop -noshell" >> conftest$ac_exeext && chmod +x conftest$ac_exeext'
+ if test "$cross_compiling" = yes; then :
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5 ; }
else
- have_openssl=no
-fi
+ cat > conftest.$ac_ext <<_ACEOF
+-module(conftest).
+-export([start/0]).
+
+start() ->
+ ReturnValue = case code:lib_dir("runtime_tools") of
+ {error, bad_name} ->
+ file:write_file("conftest.out", "not found\n"),
+ 1;
+ LibDir ->
+ file:write_file("conftest.out", LibDir),
+ 0
+ end,
+ halt(ReturnValue)
+.
- if test x"$have_openssl" = xyes; then
- save_CPPFLAGS=$CPPFLAGS
- CPPFLAGS="-I$ssl_prefix/include $CPPFLAGS"
- for ac_header in openssl/ssl.h
-do :
- ac_fn_c_check_header_mongrel "$LINENO" "openssl/ssl.h" "ac_cv_header_openssl_ssl_h" "$ac_includes_default"
-if test "x$ac_cv_header_openssl_ssl_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_OPENSSL_SSL_H 1
_ACEOF
- have_openssl_h=yes
+if ac_fn_erl_try_run "$LINENO"; then :
+ ac_cv_erlang_lib_dir_runtime_tools=`cat conftest.out`
+ rm -f conftest.out
+else
+ if test ! -f conftest.out; then
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "test Erlang program execution failed
+See \`config.log' for more details" "$LINENO" 5 ; }
+ else
+ ac_cv_erlang_lib_dir_runtime_tools="not found"
+ rm -f conftest.out
+ fi
fi
-
-done
-
- CPPFLAGS=$save_CPPFLAGS
- if test x"$have_openssl_h" = xyes; then
- have_openssl=yes
- printf "openssl found in $ssl_prefix\n";
- SSL_LIBS="-L$ssl_prefix/lib -lssl -lcrypto"
- CPPFLAGS="-I$ssl_prefix/include $CPPFLAGS"
- SSL_CFLAGS="-DHAVE_SSL"
- break
- fi
- else
- # Clear this from the autoconf cache, so in the next pass of
- # this loop with different -L arguments, it will test again.
- unset ac_cv_lib_ssl_SSL_new
- fi
- done
-if test x${have_openssl} != xyes; then
- as_fn_error $? "Could not find development files of OpenSSL library. Install them or disable \`tls' with: --disable-tls" "$LINENO" 5
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+ conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
+ ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
fi
-
-# If ssl is kerberized it need krb5.h
-# On RedHat and OpenBSD, krb5.h is in an unsual place:
-KRB5_INCLUDE="`krb5-config --cflags 2>/dev/null`"
-if test -n "$KRB5_INCLUDE" ; then
- CPPFLAGS="$CPPFLAGS $KRB5_INCLUDE"
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_dir_runtime_tools" >&5
+$as_echo "$ac_cv_erlang_lib_dir_runtime_tools" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Erlang/OTP 'runtime_tools' library version" >&5
+$as_echo_n "checking for Erlang/OTP 'runtime_tools' library version... " >&6; }
+if test "${ac_cv_erlang_lib_ver_runtime_tools+set}" = set; then :
+ $as_echo_n "(cached) " >&6
else
- # For RedHat For BSD
- for D in /usr/kerberos/include /usr/include/kerberos /usr/include/kerberosV
- do
- if test -d $D ; then
- CPPFLAGS="$CPPFLAGS -I$D"
- fi
- done
+ if test "$ac_cv_erlang_lib_dir_runtime_tools" = "not found"; then :
+ ac_cv_erlang_lib_ver_runtime_tools="not found"
+else
+ ac_cv_erlang_lib_ver_runtime_tools=`$as_echo "$ac_cv_erlang_lib_dir_runtime_tools" | sed -n -e 's,^.*-\([^/-]*\)$,\1,p'`
fi
-ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
-if test "x$ac_cv_header_krb5_h" = xyes; then :
-
fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_erlang_lib_ver_runtime_tools" >&5
+$as_echo "$ac_cv_erlang_lib_ver_runtime_tools" >&6; }
+ERLANG_LIB_DIR_runtime_tools=$ac_cv_erlang_lib_dir_runtime_tools
+ERLANG_LIB_VER_runtime_tools=$ac_cv_erlang_lib_ver_runtime_tools
-
-ENABLEUSER=""
-# Check whether --enable-user was given.
-if test "${enable_user+set}" = set; then :
- enableval=$enable_user; case "${enableval}" in
- yes) ENABLEUSER=`whoami` ;;
- no) ENABLEUSER="" ;;
- *) ENABLEUSER=$enableval
- esac
+if test "$ac_cv_erlang_lib_dir_runtime_tools" = "not found"; then :
+ as_fn_error $? "Erlang application 'runtime_tools' was not found" "$LINENO" 5
fi
-if test "$ENABLEUSER" != ""; then
- echo "allow this system user to start ejabberd: $ENABLEUSER"
- INSTALLUSER=$ENABLEUSER
-
fi
-ac_fn_c_check_header_mongrel "$LINENO" "openssl/md2.h" "ac_cv_header_openssl_md2_h" "$ac_includes_default"
-if test "x$ac_cv_header_openssl_md2_h" = xyes; then :
- md2=true
-else
- md2=false
-fi
-ac_aux_dir=
-for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
- if test -f "$ac_dir/install-sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f "$ac_dir/install.sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- elif test -f "$ac_dir/shtool"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/shtool install -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
-fi
-# These three variables are undocumented and unsupported,
-# and are intended to be withdrawn in a future Autoconf release.
-# They can cause serious problems if a builder's source tree is in a directory
-# whose full name contains unusual characters.
-ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
-ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
-ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
-# Make sure we can run config.sub.
-$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
- as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
-$as_echo_n "checking build system type... " >&6; }
-if ${ac_cv_build+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_build_alias=$build_alias
-test "x$ac_build_alias" = x &&
- ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
-test "x$ac_build_alias" = x &&
- as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
-ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
-$as_echo "$ac_cv_build" >&6; }
-case $ac_cv_build in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
-esac
-build=$ac_cv_build
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_build
-shift
-build_cpu=$1
-build_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-build_os=$*
-IFS=$ac_save_IFS
-case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
-$as_echo_n "checking host system type... " >&6; }
-if ${ac_cv_host+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$host_alias" = x; then
- ac_cv_host=$ac_cv_build
-else
- ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
-$as_echo "$ac_cv_host" >&6; }
-case $ac_cv_host in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
-esac
-host=$ac_cv_host
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_host
-shift
-host_cpu=$1
-host_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-host_os=$*
-IFS=$ac_save_IFS
-case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
-$as_echo_n "checking target system type... " >&6; }
-if ${ac_cv_target+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$target_alias" = x; then
- ac_cv_target=$ac_cv_host
-else
- ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
-$as_echo "$ac_cv_target" >&6; }
-case $ac_cv_target in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
-esac
-target=$ac_cv_target
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_target
-shift
-target_cpu=$1
-target_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-target_os=$*
-IFS=$ac_save_IFS
-case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
-
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-test -n "$target_alias" &&
- test "$program_prefix$program_suffix$program_transform_name" = \
- NONENONEs,x,x, &&
- program_prefix=${target_alias}-
-
-#AC_DEFINE_UNQUOTED(CPU_VENDOR_OS, "$target")
-#AC_SUBST(target_os)
-
-
-case "$target_os" in
- *darwin*)
- echo "Target OS is 'Darwin'"
- ac_ext=erl
-ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5'
-ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&5 && echo "#!/bin/sh" > conftest$ac_exeext && $as_echo "\"$ERL\" -run conftest start -run init stop -noshell" >> conftest$ac_exeext && chmod +x conftest$ac_exeext'
- if test -n "$ERLC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for erlc" >&5
-$as_echo_n "checking for erlc... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ERLC" >&5
-$as_echo "$ERLC" >&6; }
-else
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}erlc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}erlc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_ERLC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $ERLC in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_ERLC="$ERLC" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_path_ERLC="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
- ;;
-esac
-fi
-ERLC=$ac_cv_path_ERLC
-if test -n "$ERLC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ERLC" >&5
-$as_echo "$ERLC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-fi
-if test -z "$ac_cv_path_ERLC"; then
- ac_pt_ERLC=$ERLC
- # Extract the first word of "erlc", so it can be a program name with args.
-set dummy erlc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_ac_pt_ERLC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $ac_pt_ERLC in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_ac_pt_ERLC="$ac_pt_ERLC" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_path_ac_pt_ERLC="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
- ;;
-esac
-fi
-ac_pt_ERLC=$ac_cv_path_ac_pt_ERLC
-if test -n "$ac_pt_ERLC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_ERLC" >&5
-$as_echo "$ac_pt_ERLC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_pt_ERLC" = x; then
- ERLC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- ERLC=$ac_pt_ERLC
- fi
-else
- ERLC="$ac_cv_path_ERLC"
-fi
-fi
-if test "$cross_compiling" = yes; then :
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot run test program while cross compiling
-See \`config.log' for more details" "$LINENO" 5; }
-else
- cat > conftest.$ac_ext <<_ACEOF
--module(conftest).
--export([start/0]).
-
-start() ->
- halt(case erlang:system_info(wordsize) of
- 8 -> 0; 4 -> 1 end)
-.
-
-_ACEOF
-if ac_fn_erl_try_run "$LINENO"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: found 64-bit Erlang" >&5
-$as_echo "$as_me: found 64-bit Erlang" >&6;}
- CBIT=-m64
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: found 32-bit Erlang" >&5
-$as_echo "$as_me: found 32-bit Erlang" >&6;}
- CBIT=-m32
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
- ;;
- *)
- echo "Target OS is '$target_os'"
- CBIT=""
- ;;
-esac
-CFLAGS="$CFLAGS $CBIT"
-LD_SHARED="$LD_SHARED $CBIT"
-echo "CBIT is set to '$CBIT'"
-
cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
# tests run on this system so they can be shared between configure
@@ -5188,21 +3918,10 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
:end' >>confcache
if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
if test -w "$cache_file"; then
- if test "x$cache_file" != "x/dev/null"; then
+ test "x$cache_file" != "x/dev/null" &&
{ $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
$as_echo "$as_me: updating cache $cache_file" >&6;}
- if test ! -f "$cache_file" || test -h "$cache_file"; then
- cat confcache >"$cache_file"
- else
- case $cache_file in #(
- */* | ?:*)
- mv -f confcache "$cache_file"$$ &&
- mv -f "$cache_file"$$ "$cache_file" ;; #(
- *)
- mv -f confcache "$cache_file" ;;
- esac
- fi
- fi
+ cat confcache >$cache_file
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
@@ -5270,7 +3989,7 @@ LTLIBOBJS=$ac_ltlibobjs
-: "${CONFIG_STATUS=./config.status}"
+: ${CONFIG_STATUS=./config.status}
ac_write_fail=0
ac_clean_files_save=$ac_clean_files
ac_clean_files="$ac_clean_files $CONFIG_STATUS"
@@ -5371,7 +4090,6 @@ fi
IFS=" "" $as_nl"
# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
case $0 in #((
*[\\/]* ) as_myself=$0 ;;
*) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -5678,8 +4396,8 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by ejabberd $as_me 13.03-beta2, which was
-generated by GNU Autoconf 2.68. Invocation command line was
+This file was extended by ejabberd $as_me 3.0.0, which was
+generated by GNU Autoconf 2.67. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
CONFIG_HEADERS = $CONFIG_HEADERS
@@ -5731,8 +4449,8 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
-ejabberd config.status 13.03-beta2
-configured by $0, generated by GNU Autoconf 2.68,
+ejabberd config.status 3.0.0
+configured by $0, generated by GNU Autoconf 2.67,
with options \\"\$ac_cs_config\\"
Copyright (C) 2010 Free Software Foundation, Inc.
@@ -5741,6 +4459,7 @@ gives unlimited permission to copy, distribute and modify it."
ac_pwd='$ac_pwd'
srcdir='$srcdir'
+INSTALL='$INSTALL'
test -n "\$AWK" || AWK=awk
_ACEOF
@@ -5842,22 +4561,10 @@ for ac_config_target in $ac_config_targets
do
case $ac_config_target in
"Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
- "$make_mod_irc") CONFIG_FILES="$CONFIG_FILES $make_mod_irc" ;;
- "$make_mod_muc") CONFIG_FILES="$CONFIG_FILES $make_mod_muc" ;;
- "$make_mod_pubsub") CONFIG_FILES="$CONFIG_FILES $make_mod_pubsub" ;;
- "$make_mod_proxy65") CONFIG_FILES="$CONFIG_FILES $make_mod_proxy65" ;;
- "$make_eldap") CONFIG_FILES="$CONFIG_FILES $make_eldap" ;;
- "$make_pam") CONFIG_FILES="$CONFIG_FILES $make_pam" ;;
- "$make_web") CONFIG_FILES="$CONFIG_FILES $make_web" ;;
- "mysql/Makefile") CONFIG_FILES="$CONFIG_FILES mysql/Makefile" ;;
- "pgsql/Makefile") CONFIG_FILES="$CONFIG_FILES pgsql/Makefile" ;;
- "stringprep/Makefile") CONFIG_FILES="$CONFIG_FILES stringprep/Makefile" ;;
- "stun/Makefile") CONFIG_FILES="$CONFIG_FILES stun/Makefile" ;;
- "$make_tls") CONFIG_FILES="$CONFIG_FILES $make_tls" ;;
- "$make_odbc") CONFIG_FILES="$CONFIG_FILES $make_odbc" ;;
- "$make_ejabberd_zlib") CONFIG_FILES="$CONFIG_FILES $make_ejabberd_zlib" ;;
-
- *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
+ "vars.config") CONFIG_FILES="$CONFIG_FILES vars.config" ;;
+ "src/ejabberd.app.src") CONFIG_FILES="$CONFIG_FILES src/ejabberd.app.src" ;;
+
+ *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5 ;;
esac
done
@@ -5878,10 +4585,9 @@ fi
# after its creation but before its name has been assigned to `$tmp'.
$debug ||
{
- tmp= ac_tmp=
+ tmp=
trap 'exit_status=$?
- : "${ac_tmp:=$tmp}"
- { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
+ { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
' 0
trap 'as_fn_exit 1' 1 2 13 15
}
@@ -5889,13 +4595,12 @@ $debug ||
{
tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
- test -d "$tmp"
+ test -n "$tmp" && test -d "$tmp"
} ||
{
tmp=./conf$$-$RANDOM
(umask 077 && mkdir "$tmp")
} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
-ac_tmp=$tmp
# Set up the scripts for CONFIG_FILES section.
# No need to generate them if there are no CONFIG_FILES.
@@ -5917,7 +4622,7 @@ else
ac_cs_awk_cr=$ac_cr
fi
-echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
+echo 'BEGIN {' >"$tmp/subs1.awk" &&
_ACEOF
@@ -5945,7 +4650,7 @@ done
rm -f conf$$subs.sh
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
+cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
_ACEOF
sed -n '
h
@@ -5993,7 +4698,7 @@ t delim
rm -f conf$$subs.awk
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
_ACAWK
-cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
+cat >>"\$tmp/subs1.awk" <<_ACAWK &&
for (key in S) S_is_set[key] = 1
FS = ""
@@ -6025,7 +4730,7 @@ if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
else
cat
-fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
+fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
|| as_fn_error $? "could not setup config files machinery" "$LINENO" 5
_ACEOF
@@ -6065,7 +4770,7 @@ do
esac
case $ac_mode$ac_tag in
:[FHL]*:*);;
- :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
+ :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5 ;;
:[FH]-) ac_tag=-:-;;
:[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
esac
@@ -6084,7 +4789,7 @@ do
for ac_f
do
case $ac_f in
- -) ac_f="$ac_tmp/stdin";;
+ -) ac_f="$tmp/stdin";;
*) # Look for the file first in the build tree, then in the source tree
# (if the path is not absolute). The absolute path cannot be DOS-style,
# because $ac_f cannot contain `:'.
@@ -6093,7 +4798,7 @@ do
[\\/$]*) false;;
*) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
esac ||
- as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
+ as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5 ;;
esac
case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
as_fn_append ac_file_inputs " '$ac_f'"
@@ -6119,8 +4824,8 @@ $as_echo "$as_me: creating $ac_file" >&6;}
esac
case $ac_tag in
- *:-:* | *:-) cat >"$ac_tmp/stdin" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
+ *:-:* | *:-) cat >"$tmp/stdin" \
+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
esac
;;
esac
@@ -6190,6 +4895,10 @@ ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
# CONFIG_FILE
#
+ case $INSTALL in
+ [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
+ *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
+ esac
_ACEOF
cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
@@ -6243,24 +4952,24 @@ s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
s&@builddir@&$ac_builddir&;t t
s&@abs_builddir@&$ac_abs_builddir&;t t
s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
+s&@INSTALL@&$ac_INSTALL&;t t
$ac_datarootdir_hack
"
-eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
- >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
+eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5
test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
- { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
- { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
- "$ac_tmp/out"`; test -z "$ac_out"; } &&
+ { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
+ { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
which seems to be undefined. Please make sure it is defined" >&5
$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
which seems to be undefined. Please make sure it is defined" >&2;}
- rm -f "$ac_tmp/stdin"
+ rm -f "$tmp/stdin"
case $ac_file in
- -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
- *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
+ -) cat "$tmp/out" && rm -f "$tmp/out";;
+ *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
esac \
|| as_fn_error $? "could not create $ac_file" "$LINENO" 5
;;
diff --git a/configure.ac b/configure.ac
new file mode 100644
index 00000000..d3efb806
--- /dev/null
+++ b/configure.ac
@@ -0,0 +1,283 @@
+# -*- Autoconf -*-
+# Process this file with autoconf to produce a configure script.
+
+AC_PREREQ(2.53)
+AC_PACKAGE_VERSION(3.0.0)
+AC_INIT(ejabberd, 3.0.0, [ejabberd@process-one.net], [ejabberd])
+REQUIRE_ERLANG_MIN="5.9.1 (Erlang/OTP R15B01)"
+REQUIRE_ERLANG_MAX="9.0.0 (No Max)"
+
+# Checks for programs.
+AC_PROG_MAKE_SET
+AC_PROG_INSTALL
+AC_PROG_SED
+
+if test "x$GCC" = "xyes"; then
+ CFLAGS="$CFLAGS -Wall"
+fi
+
+# Checks Erlang runtime and compiler
+AC_ARG_WITH(erlang,
+ AC_HELP_STRING([--with-erlang=dir],
+ [search for erlang in dir]),
+[if test "$withval" = "yes" -o "$withval" = "no" -o "X$with_erlang" = "X"; then
+ extra_erl_path=""
+else
+ extra_erl_path="$with_erlang:$with_erlang/bin:"
+fi
+])
+
+AC_PATH_TOOL(ERL, erl, , [${extra_erl_path}$PATH])
+AC_PATH_TOOL(ERLC, erlc, , [${extra_erl_path}$PATH])
+
+AC_ERLANG_NEED_ERL
+AC_ERLANG_NEED_ERLC
+
+AC_ARG_ENABLE(erlang-version-check,
+[AC_HELP_STRING([--enable-erlang-version-check],
+ [Check Erlang/OTP version @<:@default=yes@:>@])])
+ case "$enable_erlang_version_check" in
+ yes|'')
+ ERLANG_VERSION_CHECK([$REQUIRE_ERLANG_MIN],[$REQUIRE_ERLANG_MAX])
+ ;;
+ no)
+ ERLANG_VERSION_CHECK([$REQUIRE_ERLANG_MIN],[$REQUIRE_ERLANG_MAX],[warn])
+ ;;
+esac
+
+# Checks and sets ERLANG_ROOT_DIR and ERLANG_LIB_DIR variable
+AC_ERLANG_SUBST_ROOT_DIR
+# AC_ERLANG_SUBST_LIB_DIR
+
+#locating escript
+AC_PATH_PROG([ESCRIPT], [escript], [], [$ERLANG_ROOT_DIR/bin])
+
+#locating make
+AC_CHECK_PROG([MAKE], [make], [make], [])
+
+if test "x$ESCRIPT" = "x"; then
+ AC_MSG_ERROR(['escript' was not found])
+fi
+
+if test "x$MAKE" = "x"; then
+ AC_MSG_ERROR(['make' was not found])
+fi
+
+# Change default prefix
+AC_PREFIX_DEFAULT(/)
+
+AC_ARG_ENABLE(hipe,
+[AC_HELP_STRING([--enable-hipe], [compile natively with HiPE, not recommended (default: no)])],
+[case "${enableval}" in
+ yes) hipe=true ;;
+ no) hipe=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-hipe) ;;
+esac],[hipe=false])
+
+AC_ARG_ENABLE(roster_gateway_workaround,
+[AC_HELP_STRING([--enable-roster-gateway-workaround], [turn on workaround for processing gateway subscriptions (default: no)])],
+[case "${enableval}" in
+ yes) roster_gateway_workaround=true ;;
+ no) roster_gateway_workaround=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-roster-gateway-workaround) ;;
+esac],[roster_gateway_workaround=false])
+
+AC_ARG_ENABLE(transient_supervisors,
+[AC_HELP_STRING([--enable-transient_supervisors], [use Erlang supervision for transient process (default: no)])],
+[case "${enableval}" in
+ yes) transient_supervisors=true ;;
+ no) transient_supervisors=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-transient_supervisors) ;;
+esac],[transient_supervisors=false])
+
+AC_ARG_ENABLE(full_xml,
+[AC_HELP_STRING([--enable-full-xml], [use XML features in XMPP stream (ex: CDATA) (default: no, requires XML compliant clients)])],
+[case "${enableval}" in
+ yes) full_xml=true ;;
+ no) full_xml=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-full-xml) ;;
+esac],[full_xml=false])
+
+AC_ARG_ENABLE(mssql,
+[AC_HELP_STRING([--enable-mssql], [use Microsoft SQL Server database (default: no, requires --enable-odbc)])],
+[case "${enableval}" in
+ yes) db_type=mssql ;;
+ no) db_type=generic ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-mssql) ;;
+esac],[db_type=generic])
+
+AC_ARG_ENABLE(tools,
+[AC_HELP_STRING([--enable-tools], [build development tools (currently the ejabberd profiler only, default: no)])],
+[case "${enableval}" in
+ yes) tools=true ;;
+ no) tools=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-tools) ;;
+esac],[tools=false])
+
+AC_ARG_ENABLE(all,
+[AC_HELP_STRING([--enable-all], [same as --enable-nif --enable-odbc --enable-mysql --enable-pgsql --enable-pam --enable-zlib --enable-stun --enable-json --enable-iconv --enable-debug --enable-http (useful for Dialyzer checks, default: no)])],
+[case "${enableval}" in
+ yes) nif=true odbc=true mysql=true pgsql=true pam=true zlib=true stun=true json=true iconv=true debug=true http=true ;;
+ no) nif=false odbc=false mysql=false pgsql=false pam=false zlib=false stun=false json=false iconv=false debug=false http=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-all) ;;
+esac],[])
+
+AC_ARG_ENABLE(nif,
+[AC_HELP_STRING([--enable-nif], [replace some functions with C equivalents. Requires Erlang R13B04 or higher (default: no)])],
+[case "${enableval}" in
+ yes) nif=true ;;
+ no) nif=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-nif) ;;
+esac],[if test "x$nif" = "x"; then nif=false; fi])
+
+AC_ARG_ENABLE(odbc,
+[AC_HELP_STRING([--enable-odbc], [enable pure ODBC support (default: no)])],
+[case "${enableval}" in
+ yes) odbc=true ;;
+ no) odbc=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-odbc) ;;
+esac],[if test "x$odbc" = "x"; then odbc=false; fi])
+
+AC_ARG_ENABLE(mysql,
+[AC_HELP_STRING([--enable-mysql], [enable MySQL support (default: no)])],
+[case "${enableval}" in
+ yes) mysql=true ;;
+ no) mysql=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-mysql) ;;
+esac],[if test "x$mysql" = "x"; then mysql=false; fi])
+
+AC_ARG_ENABLE(pgsql,
+[AC_HELP_STRING([--enable-pgsql], [enable PostgreSQL support (default: no)])],
+[case "${enableval}" in
+ yes) pgsql=true ;;
+ no) pgsql=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-pgsql) ;;
+esac],[if test "x$pgsql" = "x"; then pgsql=false; fi])
+
+AC_ARG_ENABLE(pam,
+[AC_HELP_STRING([--enable-pam], [enable PAM support (default: no)])],
+[case "${enableval}" in
+ yes) pam=true ;;
+ no) pam=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-pam) ;;
+esac],[if test "x$pam" = "x"; then pam=false; fi])
+
+AC_ARG_ENABLE(zlib,
+[AC_HELP_STRING([--enable-zlib], [enable Stream Compression (XEP-0138) using zlib (default: yes)])],
+[case "${enableval}" in
+ yes) zlib=true ;;
+ no) zlib=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-zlib) ;;
+esac],[if test "x$zlib" = "x"; then zlib=true; fi])
+
+AC_ARG_ENABLE(stun,
+[AC_HELP_STRING([--enable-stun], [enable STUN support (default: no)])],
+[case "${enableval}" in
+ yes) stun=true ;;
+ no) stun=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-stun) ;;
+esac],[if test "x$stun" = "x"; then stun=false; fi])
+
+AC_ARG_ENABLE(json,
+[AC_HELP_STRING([--enable-json], [enable JSON support for mod_bosh (default: no)])],
+[case "${enableval}" in
+ yes) json=true ;;
+ no) json=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-json) ;;
+esac],[if test "x$json" = "x"; then json=false; fi])
+
+AC_ARG_ENABLE(iconv,
+[AC_HELP_STRING([--enable-iconv], [enable iconv support (default: yes)])],
+[case "${enableval}" in
+ yes) iconv=true ;;
+ no) iconv=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-iconv) ;;
+esac],[if test "x$iconv" = "x"; then iconv=true; fi])
+
+AC_ARG_ENABLE(debug,
+[AC_HELP_STRING([--enable-debug], [enable debug information (default: yes)])],
+[case "${enableval}" in
+ yes) debug=true ;;
+ no) debug=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-debug) ;;
+esac],[if test "x$debug" = "x"; then debug=true; fi])
+
+AC_ARG_ENABLE(http,
+[AC_HELP_STRING([--enable-http], [build external HTTP libraries ('ibrowse' and 'lhttpc', default: no)])],
+[case "${enableval}" in
+ yes) http=true ;;
+ no) http=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-http) ;;
+esac],[if test "x$http" = "x"; then http=false; fi])
+
+AC_ARG_ENABLE(lager,
+[AC_HELP_STRING([--enable-lager], [enable lager support (default: yes)])],
+[case "${enableval}" in
+ yes) lager=true ;;
+ no) lager=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-lager) ;;
+esac],[if test "x$lager" = "x"; then lager=true; fi])
+
+AC_CONFIG_FILES([Makefile
+ vars.config
+ src/ejabberd.app.src])
+
+ENABLEUSER=""
+AC_ARG_ENABLE(user,
+ [AS_HELP_STRING([--enable-user[[[[=USER]]]]], [allow this system user to start ejabberd (default: no)])],
+ [case "${enableval}" in
+ yes) ENABLEUSER=`whoami` ;;
+ no) ENABLEUSER="" ;;
+ *) ENABLEUSER=$enableval
+ esac],
+ [])
+if test "$ENABLEUSER" != ""; then
+ echo "allow this system user to start ejabberd: $ENABLEUSER"
+ AC_SUBST([INSTALLUSER], [$ENABLEUSER])
+fi
+
+AC_ERLANG_CHECK_LIB([sasl], [],
+ [AC_MSG_ERROR([Erlang application 'sasl' was not found])])
+AC_ERLANG_CHECK_LIB([crypto], [],
+ [AC_MSG_ERROR([Erlang application 'crypto' was not found])])
+AC_ERLANG_CHECK_LIB([public_key], [],
+ [AC_MSG_ERROR([Erlang application 'public_key' was not found])])
+AC_ERLANG_CHECK_LIB([ssl], [],
+ [AC_MSG_ERROR([Erlang application 'ssl' was not found])])
+AC_ERLANG_CHECK_LIB([mnesia], [],
+ [AC_MSG_ERROR([Erlang application 'mnesia' was not found])])
+AC_ERLANG_CHECK_LIB([inets], [],
+ [AC_MSG_ERROR([Erlang application 'inets' was not found])])
+AC_ERLANG_CHECK_LIB([compiler], [],
+ [AC_MSG_ERROR([Erlang application 'compiler' was not found])])
+if test "x$odbc" = "xtrue"; then
+ AC_ERLANG_CHECK_LIB([odbc], [],
+ [AC_MSG_ERROR([Erlang application 'odbc' was not found])])
+fi
+if test "x$tools" = "xtrue"; then
+ AC_ERLANG_CHECK_LIB([tools], [],
+ [AC_MSG_ERROR([Erlang application 'tools' was not found])])
+ AC_ERLANG_CHECK_LIB([runtime_tools], [],
+ [AC_MSG_ERROR([Erlang application 'runtime_tools' was not found])])
+fi
+
+AC_SUBST(hipe)
+AC_SUBST(roster_gateway_workaround)
+AC_SUBST(transient_supervisors)
+AC_SUBST(full_xml)
+AC_SUBST(nif)
+AC_SUBST(db_type)
+AC_SUBST(odbc)
+AC_SUBST(mysql)
+AC_SUBST(pgsql)
+AC_SUBST(pam)
+AC_SUBST(zlib)
+AC_SUBST(stun)
+AC_SUBST(json)
+AC_SUBST(iconv)
+AC_SUBST(debug)
+AC_SUBST(http)
+AC_SUBST(lager)
+AC_SUBST(tools)
+
+AC_OUTPUT
diff --git a/src/configure.bat b/configure.bat
index 46a93d8c..46a93d8c 100644
--- a/src/configure.bat
+++ b/configure.bat