Fix a few things I missed to ensure zt_chan_conf structure is not modified in mkintf
[asterisk-bristuff.git] / configure.ac
blobaeda896e1b971833db3b1885c0e1e084269b83b7
1 # Process this file with autoconf to produce a configure script.
3 AC_PREREQ(2.60)
5 AC_INIT(asterisk, 1.4, www.asterisk.org)
7 # cross-compile macros
8 AC_CANONICAL_BUILD
9 AC_CANONICAL_HOST
11 # check existence of the package
12 AC_CONFIG_SRCDIR([main/asterisk.c])
14 # specify output header file
15 AC_CONFIG_HEADER(include/asterisk/autoconfig.h)
17 AC_COPYRIGHT("Asterisk")
18 AC_REVISION($Revision$)
20 AC_GNU_SOURCE
21 AC_USE_SYSTEM_EXTENSIONS        # note- does not work on FreeBSD
23 case "${host_os}" in
24      freebsd*)
25      ac_default_prefix=/usr/local
26      CPPFLAGS=-I/usr/local/include
27      LDFLAGS=-L/usr/local/lib
28      ;;
29      *)
30      ac_default_prefix=/usr
31      if test ${sysconfdir} = '${prefix}/etc'; then
32         sysconfdir=/etc
33      fi
34      if test ${mandir} = '${prefix}/man'; then
35         mandir=/usr/share/man
36      fi
37      ;;
38 esac
40 if test ${localstatedir} = '${prefix}/var'; then
41      localstatedir=/var
44 BUILD_PLATFORM=${build}
45 BUILD_CPU=${build_cpu}
46 BUILD_VENDOR=${build_vendor}
47 BUILD_OS=${build_os}
49 AC_SUBST(BUILD_PLATFORM)
50 AC_SUBST(BUILD_CPU)
51 AC_SUBST(BUILD_VENDOR)
52 AC_SUBST(BUILD_OS)
54 HOST_PLATFORM=${host}
55 HOST_CPU=${host_cpu}
56 HOST_VENDOR=${host_vendor}
57 HOST_OS=${host_os}
59 AC_SUBST(HOST_PLATFORM)
60 AC_SUBST(HOST_CPU)
61 AC_SUBST(HOST_VENDOR)
62 AC_SUBST(HOST_OS)
64 case "${host_os}" in
65      freebsd*)
66      OSARCH=FreeBSD
67      ;;
68      netbsd*)
69      OSARCH=NetBSD
70      ;;
71      openbsd*)
72      OSARCH=OpenBSD
73      ;;
74      solaris*)
75      OSARCH=SunOS
76      ;;
77      *)
78      OSARCH=${HOST_OS}
79      ;;
80 esac
82 AC_SUBST(OSARCH)
84 #  check for uname
85 AC_PATH_TOOL([UNAME], [uname], No)
86 if test ! x"${UNAME}" = xNo; then
87    PBX_OSREV=$(${UNAME} -r)
89 AC_SUBST(PBX_OSREV)
91 AH_TOP(
92 #ifndef ASTERISK_AUTOCONFIG_H
93 #define ASTERISK_AUTOCONFIG_H
95 #include "asterisk/buildopts.h"
99 AH_BOTTOM(
100 #endif
103 # cross-compile checks
104 if test "${cross_compiling}" = "yes"; 
105 then
106    AC_CHECK_TOOL(CC, gcc, :)
107    AC_CHECK_TOOL(CXX, g++, :)
108    AC_CHECK_TOOL(LD, ld, :)
109    AC_CHECK_TOOL(RANLIB, ranlib, :)
112 # Checks for programs.
113 AC_PROG_CC
114 AC_PROG_CXX
115 AC_PROG_CPP
116 AC_PROG_CXXCPP
117 # This macro is just copied into our local acinclude.m4 from libtool.m4 so that
118 # the developers regenerating the configure script don't have to install libtool.
119 AST_PROG_LD     # note - does not work on freebsd
120 AC_PROG_AWK
121 AC_PROG_INSTALL
122 AC_PROG_LN_S
123 AC_PROG_RANLIB
124 AST_CHECK_GNU_MAKE
126 AC_PATH_TOOL([STRIP], [strip], :)
127 AC_PATH_TOOL([AR], [ar], :)
129 GNU_LD=0
130 if test "x$with_gnu_ld" = "xyes" ; then
131    GNU_LD=1
133 AC_SUBST(GNU_LD)
135 AC_PATH_PROG([AWK], [awk], :)
136 AC_PATH_PROG([GREP], [grep], :)
137 AC_PATH_PROG([FIND], [find], :)
138 AC_PATH_PROG([COMPRESS], [compress], :)
139 AC_PATH_PROG([BASENAME], [basename], :)
140 AC_PATH_PROG([ID], [id], :)
141 AC_PATH_PROG([DIRNAME], [dirname], :)
142 AC_PATH_PROG([SHELL], [sh], :)
143 AC_PATH_PROG([LN], [ln], :)
144 AC_PATH_PROG([DOT], [dot], :)
145 AC_PATH_PROG([WGET], [wget], :)
146 if test "${WGET}" != ":" ; then
147   DOWNLOAD=${WGET}
148 else
149   AC_PATH_PROG([FETCH], [fetch], [:])
150   DOWNLOAD=${FETCH}
152 AC_SUBST(DOWNLOAD)
154 AC_CHECK_TOOL([SOXMIX], [soxmix], [:])
155 if test "${SOXMIX}" != ":" ; then
156         AC_DEFINE([HAVE_SOXMIX], 1, [Define to 1 if your system has soxmix application.])
159 ACX_PTHREAD
161 AC_LANG(C)
163 AC_ARG_ENABLE(dev-mode,
164         [  --enable-dev-mode    Turn on developer mode],
165         [case "${enableval}" in
166               y|ye|yes) AST_DEVMODE=yes ;;
167               n|no)  AST_DEVMODE=no ;;
168               *) AC_MSG_ERROR(bad value ${enableval} for --enable-dev-mode)  ;;
169         esac])
170 AC_SUBST(AST_DEVMODE)
172 # package option names should be in alphabetical order
173 # by the --with option name, to make things easier for the users :-)
175 AST_EXT_LIB_SETUP([ALSA], [Advanced Linux Sound Architecture], [asound])
176 AST_EXT_LIB_SETUP([CURL], [cURL], [curl])
177 AST_EXT_LIB_SETUP([CAP], [POSIX 1.e capabilities], [cap])
178 AST_EXT_LIB_SETUP([CURSES], [curses], [curses])
179 AST_EXT_LIB_SETUP([GNUTLS], [GNU TLS support (used for iksemel only)], [gnutls])
180 AST_EXT_LIB_SETUP([GSM], [GSM], [gsm], [, or 'internal'])
181 AST_EXT_LIB_SETUP([IKSEMEL], [Iksemel Jabber Library], [iksemel])
182 AST_EXT_LIB_SETUP([IMAP_TK], [UW IMAP Toolkit], [imap])
183 AST_EXT_LIB_SETUP([ISDNNET], [ISDN4Linux Library], [isdnnet])
184 AST_EXT_LIB_SETUP([KDE], [KDE], [kde])
185 AST_EXT_LIB_SETUP([LTDL], [libtool], [ltdl])
186 AST_EXT_LIB_SETUP([MISDN], [mISDN User Library], [misdn])
187 AST_EXT_LIB_SETUP([NBS], [Network Broadcast Sound], [nbs])
188 AST_EXT_LIB_SETUP([NCURSES], [ncurses], [ncurses])
189 AST_EXT_LIB_SETUP([NETSNMP], [Net-SNMP], [netsnmp])
190 AST_EXT_LIB_SETUP([NEWT], [newt], [newt])
191 AST_EXT_LIB_SETUP([UNIXODBC], [unixODBC], [odbc])
192 AST_EXT_LIB_SETUP([OGG], [OGG], [ogg])
193 AST_EXT_LIB_SETUP([OSPTK], [OSP Toolkit], [osptk])
194 AST_EXT_LIB_SETUP([OSS], [Open Sound System], [oss])
195 AST_EXT_LIB_SETUP([POPT], [popt], [popt])
196 AST_EXT_LIB_SETUP([PGSQL], [PostgreSQL], [postgres])
197 AST_EXT_LIB_SETUP([PRI], [ISDN PRI], [pri])
198 AST_EXT_LIB_SETUP([PWLIB], [PWlib], [pwlib])
199 AST_EXT_LIB_SETUP([OPENH323], [OpenH323], [h323])
200 AST_EXT_LIB_SETUP([RADIUS], [Radius Client], [radius])
201 AST_EXT_LIB_SETUP([SPEEX], [Speex], [speex])
202 AST_EXT_LIB_SETUP([SPEEXDSP], [Speexdsp], [speexdsp])
203 AST_EXT_LIB_SETUP([SQLITE], [SQLite], [sqlite])
204 AST_EXT_LIB_SETUP([SUPPSERV], [mISDN Supplemental Services], [suppserv])
205 AST_EXT_LIB_SETUP([OPENSSL], [OpenSSL], [ssl])
206 AST_EXT_LIB_SETUP([FREETDS], [FreeTDS], [tds])
207 AST_EXT_LIB_SETUP([TERMCAP], [Termcap], [termcap])
208 AST_EXT_LIB_SETUP([TINFO], [Term Info], [tinfo])
209 AST_EXT_LIB_SETUP([TONEZONE], [tonezone], [tonezone])
210 AST_EXT_LIB_SETUP([USB], [usb], [usb])
211 AST_EXT_LIB_SETUP([VORBIS], [Vorbis], [vorbis])
212 AST_EXT_LIB_SETUP([VPB], [Voicetronix API], [vpb])
213 AST_EXT_LIB_SETUP([ZLIB], [zlib], [z])
214 AST_EXT_LIB_SETUP([ZAPTEL], [Zaptel], [zaptel])
216 # check for basic system features and functionality before
217 # checking for package libraries
219 AC_FUNC_ALLOCA
220 AC_HEADER_DIRENT
221 AC_HEADER_STDC
222 AC_HEADER_SYS_WAIT
223 AC_CHECK_HEADERS([arpa/inet.h fcntl.h inttypes.h libintl.h limits.h locale.h malloc.h netdb.h netinet/in.h stddef.h stdint.h stdlib.h string.h strings.h sys/file.h sys/ioctl.h sys/param.h sys/socket.h sys/time.h syslog.h termios.h unistd.h utime.h arpa/nameser.h])
225 AC_SYS_LARGEFILE
227 # Checks for typedefs, structures, and compiler characteristics.
228 AC_HEADER_STDBOOL
229 AC_C_CONST
230 AC_TYPE_UID_T
231 AC_C_INLINE
232 AC_TYPE_MODE_T
233 AC_TYPE_OFF_T
234 AC_TYPE_PID_T
235 AC_TYPE_SIZE_T
236 AC_CHECK_MEMBERS([struct stat.st_blksize])
237 AC_HEADER_TIME
238 AC_STRUCT_TM
239 AC_C_VOLATILE
240 AC_CHECK_TYPES([ptrdiff_t])
242 # Checks for library functions.
243 AC_FUNC_CHOWN
244 AC_FUNC_CLOSEDIR_VOID
245 AC_FUNC_ERROR_AT_LINE
246 AST_FUNC_FORK
247 AC_FUNC_FSEEKO
248 AC_PROG_GCC_TRADITIONAL
249 # XXX: these are commented out until we determine whether it matters if our malloc()
250 # acts exactly like glibc's or not
251 # AC_FUNC_MALLOC
252 # AC_FUNC_REALLOC
253 AC_FUNC_MEMCMP
254 AC_FUNC_MMAP
255 AC_FUNC_SELECT_ARGTYPES
256 AC_FUNC_SETVBUF_REVERSED
257 AC_TYPE_SIGNAL
258 AC_FUNC_STAT
259 AC_FUNC_STRCOLL
260 AC_FUNC_STRFTIME
261 AC_FUNC_STRNLEN
262 AC_FUNC_STRTOD
263 AC_FUNC_UTIME_NULL
264 AC_FUNC_VPRINTF
265 AC_CHECK_FUNCS([asprintf atexit bzero dup2 endpwent floor ftruncate getcwd gethostbyname gethostname getloadavg gettimeofday inet_ntoa isascii localtime_r memchr memmove memset mkdir munmap pow putenv re_comp regcomp rint select setenv socket sqrt strcasecmp strcasestr strchr strcspn strdup strerror strlcat strlcpy strncasecmp strndup strnlen strrchr strsep strspn strstr strtol strtoq unsetenv utime vasprintf])
267 # some systems already have gethostbyname_r so we don't need to build ours in main/utils.c
268 AC_SEARCH_LIBS(gethostbyname_r, [socket nsl])
270 AC_MSG_CHECKING(for gethostbyname_r with 6 arguments)
271 AC_LINK_IFELSE(
272         AC_LANG_PROGRAM([#include <stdlib.h>
273                          #include <netdb.h>],
274                         [struct hostent *he = gethostbyname_r((const char *)NULL, (struct hostent *)NULL, (char *)NULL, (int)0, (struct hostent **)NULL, (int *)NULL);]),
275         AC_MSG_RESULT(yes)
276         AC_DEFINE([HAVE_GETHOSTBYNAME_R_6], 1, [Define to 1 if your system has gethostbyname_r with 6 arguments.]),
277         AC_MSG_RESULT(no)
280 AC_MSG_CHECKING(for gethostbyname_r with 5 arguments)
281 AC_LINK_IFELSE(
282         AC_LANG_PROGRAM([#include <stdlib.h>
283                          #include <netdb.h>],
284                         [struct hostent *he = gethostbyname_r((const char *)NULL, (struct hostent *)NULL, (char *)NULL, (int)0, (int *)NULL);]),
285         AC_MSG_RESULT(yes)
286         AC_DEFINE([HAVE_GETHOSTBYNAME_R_5], 1, [Define to 1 if your system has gethostbyname_r with 5 arguments.]),
287         AC_MSG_RESULT(no)
290 AC_MSG_CHECKING(for PTHREAD_RWLOCK_INITIALIZER)
291 AC_LINK_IFELSE(
292         AC_LANG_PROGRAM([#include <pthread.h>],
293                         [int foo = PTHREAD_RWLOCK_INITIALIZER;]),
294         AC_MSG_RESULT(yes)
295         AC_DEFINE([HAVE_PTHREAD_RWLOCK_INITIALIZER], 1, [Define to 1 if your system has PTHREAD_RWLOCK_INITIALIZER.]),
296         AC_MSG_RESULT(no)
299 AC_MSG_CHECKING(for PTHREAD_RWLOCK_PREFER_WRITER_NP)
300 AC_LINK_IFELSE(
301         AC_LANG_PROGRAM([#include <pthread.h>],
302                         [int foo = PTHREAD_RWLOCK_PREFER_WRITER_NP;]),
303         AC_MSG_RESULT(yes)
304         AC_DEFINE([HAVE_PTHREAD_RWLOCK_PREFER_WRITER_NP], 1, [Define to 1 if your system has PTHREAD_RWLOCK_PREFER_WRITER_NP.]),
305         AC_MSG_RESULT(no)
308 AC_MSG_CHECKING(for compiler atomic operations)
309 AC_LINK_IFELSE(
310 AC_LANG_PROGRAM([], [int foo1; int foo2 = __sync_fetch_and_add(&foo1, 1);]),
311 AC_MSG_RESULT(yes)
312 AC_DEFINE([HAVE_GCC_ATOMICS], 1, [Define to 1 if your GCC C compiler provides atomic operations.]),
313 AC_MSG_RESULT(no)
316 AST_GCC_ATTRIBUTE(pure)
317 AST_GCC_ATTRIBUTE(malloc)
318 AST_GCC_ATTRIBUTE(const)
319 AST_GCC_ATTRIBUTE(unused)
320 AST_GCC_ATTRIBUTE(always_inline)
321 AST_GCC_ATTRIBUTE(deprecated)
323 AC_MSG_CHECKING(for -ffunction-sections support)
324 saved_CFLAGS="${CFLAGS}"
325 CFLAGS="${CFLAGS} -ffunction-sections"
326 AC_COMPILE_IFELSE(
327         AC_LANG_PROGRAM([], [int x = 1;]),
328         AC_MSG_RESULT(yes)
329         [saved_LDFLAGS="${LDFLAGS}"]
330         [LDFLAGS="${LDFLAGS} -Wl,--gc-sections"]
331         AC_MSG_CHECKING(for --gc-sections support)
332         AC_LINK_IFELSE(
333                 AC_LANG_PROGRAM([], [int x = 1;]),
334                 AC_MSG_RESULT(yes)
335                 [GC_CFLAGS="-ffunction-sections"]
336                 [[GC_LDFLAGS="-Wl,--gc-sections"]],
337                 AC_MSG_RESULT(no)
338         )
339         [LDFLAGS="${saved_LDFLAGS}"],
340         AC_MSG_RESULT(no)
342 CFLAGS="${saved_CFLAGS}"
343 AC_SUBST(GC_CFLAGS)
344 AC_SUBST(GC_LDFLAGS)
346 AC_MSG_CHECKING(for -Wdeclaration-after-statement support)
347 if $(${CC} -Wdeclaration-after-statement -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
348    AC_MSG_RESULT(yes)
349    AST_DECLARATION_AFTER_STATEMENT=-Wdeclaration-after-statement
350 else
351         AC_MSG_RESULT(no)
352         AST_DECLARATION_AFTER_STATEMENT=
354 AC_SUBST(AST_DECLARATION_AFTER_STATEMENT)
356 AC_MSG_CHECKING(for -fno-strict-overflow)
357 if $(${CC} -O2 -fno-strict-overflow -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
358    AC_MSG_RESULT(yes)
359    AST_NO_STRICT_OVERFLOW=-fno-strict-overflow
360 else
361         AC_MSG_RESULT(no)
362         AST_NO_STRICT_OVERFLOW=
364 AC_SUBST(AST_NO_STRICT_OVERFLOW)
366 AC_SEARCH_LIBS(res_9_ninit, resolv)
367 AC_MSG_CHECKING(for res_ninit)
368 AC_LINK_IFELSE(
369         AC_LANG_PROGRAM([
370                         #ifdef HAVE_SYS_SOCKET_H
371                         #include <sys/socket.h>
372                         #endif
373                         #ifdef HAVE_NETINET_IN_H
374                         #include <netinet/in.h>
375                         #endif
376                         #ifdef HAVE_ARPA_NAMESER_H
377                         #include <arpa/nameser.h>
378                         #endif
379                         #include <resolv.h>],
380                         [int foo = res_ninit(NULL);]),
381         AC_MSG_RESULT(yes)
382         AC_DEFINE([HAVE_RES_NINIT], 1, [Define to 1 if your system has the re-entrant resolver functions.])
383         AC_SEARCH_LIBS(res_9_ndestroy, resolv)
384         AC_MSG_CHECKING(for res_ndestroy)
385         AC_LINK_IFELSE(
386                 AC_LANG_PROGRAM([
387                                 #ifdef HAVE_SYS_SOCKET_H
388                                 #include <sys/socket.h>
389                                 #endif
390                                 #ifdef HAVE_NETINET_IN_H
391                                 #include <netinet/in.h>
392                                 #endif
393                                 #ifdef HAVE_ARPA_NAMESER_H
394                                 #include <arpa/nameser.h>
395                                 #endif
396                                 #include <resolv.h>],
397                                 [res_ndestroy(NULL);]),
398                 AC_MSG_RESULT(yes)
399                 AC_DEFINE([HAVE_RES_NDESTROY], 1, [Define to 1 if your system has the ndestroy resolver function.]),
400                 AC_MSG_RESULT(no)
401         ),
402         AC_MSG_RESULT(no)
405 AC_MSG_CHECKING(for RTLD_NOLOAD)
406 AC_LINK_IFELSE(
407         AC_LANG_PROGRAM([#include <dlfcn.h>],
408                         [int foo = RTLD_NOLOAD;]),
409         AC_MSG_RESULT(yes)
410         AC_DEFINE([HAVE_RTLD_NOLOAD], 1, [Define to 1 if your system has a dynamic linker that supports RTLD_NOLOAD.]),
411         AC_MSG_RESULT(no)
414 AC_MSG_CHECKING(for IP_MTU_DISCOVER)
415 AC_LINK_IFELSE(
416         AC_LANG_PROGRAM([#include <netinet/in.h>],
417                         [int foo = IP_MTU_DISCOVER;]),
418         AC_MSG_RESULT(yes)
419         AC_DEFINE([HAVE_IP_MTU_DISCOVER], 1, [Define to 1 if your system has PMTU discovery on UDP sockets.]),
420         AC_MSG_RESULT(no)
423 AC_CHECK_HEADER([libkern/OSAtomic.h],
424                 [AC_DEFINE_UNQUOTED([HAVE_OSX_ATOMICS], 1, [Define to 1 if OSX atomic operations are supported.])])
426 AC_CHECK_SIZEOF(int)
428 # do the package library checks now
430 AST_EXT_LIB_CHECK([ALSA], [asound], [snd_spcm_init], [alsa/asoundlib.h], [-lm -ldl])
432 AST_EXT_LIB_CHECK([CURSES], [curses], [initscr], [curses.h])
434 if test "x${host_os}" = "xlinux-gnu" ; then
435   AST_EXT_LIB_CHECK([CAP], [cap], [cap_from_text], [sys/capability.h])
438 AST_C_COMPILE_CHECK([GETIFADDRS], [struct ifaddrs *p; getifaddrs(&p)], [ifaddrs.h])
440 GSM_INTERNAL="yes"
441 AC_SUBST(GSM_INTERNAL)
442 GSM_SYSTEM="yes"
443 if test "${USE_GSM}" != "no"; then
444    if test "${GSM_DIR}" = "internal"; then
445       GSM_SYSTEM="no"
446    elif test "${GSM_DIR}" != ""; then
447       GSM_INTERNAL="no"
448    fi
449    if test "${GSM_SYSTEM}" = "yes"; then
450       gsmlibdir=""
451       if test "x${GSM_DIR}" != "x"; then
452          if test -d ${GSM_DIR}/lib; then
453             gsmlibdir="-L${GSM_DIR}/lib"
454          else
455             gsmlibdir="-L${GSM_DIR}"
456          fi
457       fi
458       AC_CHECK_LIB([gsm], [gsm_create], AC_DEFINE_UNQUOTED([HAVE_GSM], 1,
459       [Define to indicate the GSM library]), [], ${gsmlibdir})
460       if test "${ac_cv_lib_gsm_gsm_create}" = "yes"; then
461          if test "x${GSM_DIR}" != "x" ; then
462             AC_CHECK_HEADER([${GSM_DIR}/include/gsm.h], [GSM_HEADER_FOUND=1], [GSM_HEADER_FOUND=0])
463             AC_CHECK_HEADER([${GSM_DIR}/include/gsm/gsm.h], [GSM_GSM_HEADER_FOUND=1], [GSM_GSM_HEADER_FOUND=0])
464          else
465             AC_CHECK_HEADER([gsm.h], [GSM_HEADER_FOUND=1], [GSM_HEADER_FOUND=0])
466             AC_CHECK_HEADER([gsm/gsm.h], [GSM_GSM_HEADER_FOUND=1], [GSM_GSM_HEADER_FOUND=0])
467          fi
468          if test "${GSM_HEADER_FOUND}" = "0" ; then
469             if test "{GSM_GSM_HEADER_FOUND}" = "0" ; then
470                if test "x${GSM_MANDATORY}" = "xyes" ; then
471                   AC_MSG_NOTICE([***])
472                   AC_MSG_NOTICE([*** It appears that you do not have the gsm development package installed.])
473                   AC_MSG_NOTICE([*** Please install it to include ${GSM_DESCRIP} support, or re-run configure])
474                   AC_MSG_NOTICE([*** without explicitly specifying --with-${GSM_OPTION}])
475                   exit 1
476                fi
477             fi
478          fi
479          GSM_OK=0
480          if test "${GSM_HEADER_FOUND}" = "1" ; then
481             AC_DEFINE_UNQUOTED([HAVE_GSM_HEADER], 1, [Define to indicate that gsm.h has no prefix for its location])
482             GSM_OK=1
483          else
484             if test "${GSM_GSM_HEADER_FOUND}" = "1" ; then
485                AC_DEFINE_UNQUOTED([HAVE_GSM_GSM_HEADER], 1, [Define to indicate that gsm.h is in gsm/gsm.h])
486                GSM_OK=1
487             fi
488          fi
489          if test "${GSM_OK}" = "1" ; then
490             GSM_LIB="-lgsm"
491             if test "x${GSM_DIR}" != "x"; then
492                GSM_LIB="${gsmlibdir} ${GSM_LIB}"
493                GSM_INCLUDE="-I${GSM_DIR}/include"
494             fi
495             PBX_GSM=1
496             GSM_INTERNAL="no"
497          fi
498       fi
499    fi
500    if test "${GSM_INTERNAL}" = "yes"; then
501       PBX_GSM=1
502       AC_DEFINE_UNQUOTED([HAVE_GSM_HEADER], 1, [Define to indicate that gsm.h has no prefix for its location])
503    fi
506 AST_EXT_LIB_CHECK([IKSEMEL], [iksemel], [iks_start_sasl], [iksemel.h])
508 if test "${PBX_IKSEMEL}" = 1; then
509    AST_EXT_LIB_CHECK([GNUTLS], [gnutls], [gnutls_bye], [gnutls/gnutls.h], [-lz -lgcrypt -lgpg-error])
512 if test "${USE_IMAP_TK}" != "no"; then
513         saved_cppflags="${CPPFLAGS}"
514         saved_libs="${LIBS}"
515         switch_to_system_on_failure="no"
516         if test "${IMAP_TK_DIR}" = ""; then
517                 IMAP_TK_DIR=`pwd`"/../imap-2004g"
518                 switch_to_system_on_failure="yes"
519         fi
520         if test "${IMAP_TK_DIR}" != "system"; then
521                 AC_MSG_CHECKING(for UW IMAP Toolkit c-client library)
522                 if test -f "${IMAP_TK_DIR}/c-client/LDFLAGS"; then
523                 imap_ldflags=`cat ${IMAP_TK_DIR}/c-client/LDFLAGS`
524                 fi
525                 imap_libs="${IMAP_TK_DIR}/c-client/c-client.a"
526                 imap_include="-I${IMAP_TK_DIR}/c-client"
527         CPPFLAGS="${CPPFLAGS} ${imap_include}"
528                 LIBS="${LIBS} ${imap_libs} "`echo ${imap_ldflags}`
529                 AC_LINK_IFELSE(
530                 AC_LANG_PROGRAM(
531                                 [#include "c-client.h"
532                                 void mm_searched (MAILSTREAM *stream,unsigned long number)
533                                 {
534                                 }
535                                 void mm_exists (MAILSTREAM *stream,unsigned long number)
536                                 {
537                                 }
538                                 void mm_expunged (MAILSTREAM *stream,unsigned long number)
539                                 {
540                                 }
541                                 void mm_flags (MAILSTREAM *stream,unsigned long number)
542                                 {
543                                 }
544                                 void mm_notify (MAILSTREAM *stream,char *string,long errflg)
545                                 {
546                                 }
547                                 void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
548                                 {
549                                 }
550                                 void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
551                                 {
552                                 }
553                                 void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
554                                 {
555                                 }
556                                 void mm_log (char *string,long errflg)
557                                 {
558                                 }
559                                 void mm_dlog (char *string)
560                                 {
561                                 }
562                                 void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
563                                 {
564                                 }
565                                 void mm_critical (MAILSTREAM *stream)
566                                 {
567                                 }
568                                 void mm_nocritical (MAILSTREAM *stream)
569                                 {
570                                 }
571                                 long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
572                                 {
573                                 }
574                                 void mm_fatal (char *string)
575                                 {
576                                 }],
577                                 [
578                                 MAILSTREAM *foo = mail_open(NULL, "", 0);
579                                 ]
580                         ),
581                         [ac_cv_imap_tk="yes"],
582                         [ac_cv_imap_tk="no"]
583                 )
584                 if test "${ac_cv_imap_tk}" = "yes"; then
585                         AC_LINK_IFELSE(
586                                 AC_LANG_PROGRAM(
587                                         [#include "c-client.h"
588                                         void mm_searched (MAILSTREAM *stream,unsigned long number)
589                                         {
590                                         }
591                                         void mm_exists (MAILSTREAM *stream,unsigned long number)
592                                         {
593                                         }
594                                         void mm_expunged (MAILSTREAM *stream,unsigned long number)
595                                         {
596                                         }
597                                         void mm_flags (MAILSTREAM *stream,unsigned long number)
598                                         {
599                                         }
600                                         void mm_notify (MAILSTREAM *stream,char *string,long errflg)
601                                         {
602                                         }
603                                         void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
604                                         {
605                                         }
606                                         void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
607                                         {
608                                         }
609                                         void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
610                                         {
611                                         }
612                                         void mm_log (char *string,long errflg)
613                                         {
614                                         }
615                                         void mm_dlog (char *string)
616                                         {
617                                         }
618                                         void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
619                                         {
620                                         }
621                                         void mm_critical (MAILSTREAM *stream)
622                                         {
623                                         }
624                                         void mm_nocritical (MAILSTREAM *stream)
625                                         {
626                                         }
627                                         long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
628                                         {
629                                         }
630                                         void mm_fatal (char *string)
631                                         {
632                                         }],
633                                         [
634                                         long check = mail_expunge_full(NULL, "", 0);
635                                         ]
636                                 ),
637                                 [ac_cv_imap_tk2006="yes"],
638                                 [ac_cv_imap_tk2006="no"]
639                         )
640                 fi
641                 CPPFLAGS="${saved_cppflags}"
642                 LIBS="${saved_libs}"
643                 if test "${ac_cv_imap_tk}" = "no"; then
644                         AC_MSG_RESULT(no)
645                         if test "${switch_to_system_on_failure}" = "yes"; then 
646                                 IMAP_TK_DIR="system"
647                         else #This means they specified a directory. Search for a package installation there too
648                                 AC_MSG_CHECKING([for system c-client library...])
649                                 CPPFLAGS="${saved_cppflags}"
650                                 LIBS="${saved_libs}"
651                                 imap_include="-I${IMAP_TK_DIR}/include"
652                                 imap_ldflags="-L${IMAP_TK_DIR}/lib"
653                                 imap_libs="-lc-client"
654                                 CPPFLAGS="${CPPFLAGS} ${imap_include}"
655                                 LIBS="${LIBS} ${imap_libs} ${imap_ldflags}"
656                                 AC_LINK_IFELSE(
657                                 AC_LANG_PROGRAM(
658                                                 [#include "c-client.h"
659                                                 void mm_searched (MAILSTREAM *stream,unsigned long number)
660                                                 {
661                                                 }
662                                                 void mm_exists (MAILSTREAM *stream,unsigned long number)
663                                                 {
664                                                 }
665                                                 void mm_expunged (MAILSTREAM *stream,unsigned long number)
666                                                 {
667                                                 }
668                                                 void mm_flags (MAILSTREAM *stream,unsigned long number)
669                                                 {
670                                                 }
671                                                 void mm_notify (MAILSTREAM *stream,char *string,long errflg)
672                                                 {
673                                                 }
674                                                 void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
675                                                 {
676                                                 }
677                                                 void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
678                                                 {
679                                                 }
680                                                 void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
681                                                 {
682                                                 }
683                                                 void mm_log (char *string,long errflg)
684                                                 {
685                                                 }
686                                                 void mm_dlog (char *string)
687                                                 {
688                                                 }
689                                                 void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
690                                                 {
691                                                 }
692                                                 void mm_critical (MAILSTREAM *stream)
693                                                 {
694                                                 }
695                                                 void mm_nocritical (MAILSTREAM *stream)
696                                                 {
697                                                 }
698                                                 long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
699                                                 {
700                                                 }
701                                                 void mm_fatal (char *string)
702                                                 {
703                                                 }],
704                                                 [
705                                                 MAILSTREAM *foo = mail_open(NULL, "", 0);
706                                                 ]
707                                         ),
708                                         [ac_cv_imap_tk="yes"],
709                                         [ac_cv_imap_tk="no"]
710                                 )
711                                 if test "${ac_cv_imap_tk}" = "yes"; then
712                                         AC_LINK_IFELSE(
713                                                 AC_LANG_PROGRAM(
714                                                         [#include "c-client.h"
715                                                         void mm_searched (MAILSTREAM *stream,unsigned long number)
716                                                         {
717                                                         }
718                                                         void mm_exists (MAILSTREAM *stream,unsigned long number)
719                                                         {
720                                                         }
721                                                         void mm_expunged (MAILSTREAM *stream,unsigned long number)
722                                                         {
723                                                         }
724                                                         void mm_flags (MAILSTREAM *stream,unsigned long number)
725                                                         {
726                                                         }
727                                                         void mm_notify (MAILSTREAM *stream,char *string,long errflg)
728                                                         {
729                                                         }
730                                                         void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
731                                                         {
732                                                         }
733                                                         void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
734                                                         {
735                                                         }
736                                                         void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
737                                                         {
738                                                         }
739                                                         void mm_log (char *string,long errflg)
740                                                         {
741                                                         }
742                                                         void mm_dlog (char *string)
743                                                         {
744                                                         }
745                                                         void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
746                                                         {
747                                                         }
748                                                         void mm_critical (MAILSTREAM *stream)
749                                                         {
750                                                         }
751                                                         void mm_nocritical (MAILSTREAM *stream)
752                                                         {
753                                                         }
754                                                         long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
755                                                         {
756                                                         }
757                                                         void mm_fatal (char *string)
758                                                         {
759                                                         }],
760                                                         [
761                                                         long check = mail_expunge_full(NULL, "", 0);
762                                                         ]
763                                                 ),
764                                                 [ac_cv_imap_tk2006="yes"],
765                                                 [ac_cv_imap_tk2006="no"]
766                                         )
767                                 fi
768                         fi
769                 fi
770         fi 
771         if test "${IMAP_TK_DIR}" = "system"; then
772                 #We will enter here if user specified "system" or if any of above checks failed
773                 AC_MSG_CHECKING([for system c-client library...])
774                 CPPFLAGS="${saved_cppflags}"
775                 LIBS="${saved_libs}"
776                 imap_ldflags=""
777                 imap_libs="-lc-client"
778                 imap_include="-DUSE_SYSTEM_IMAP" #Try the imap directory first
779                 CPPFLAGS="${CPPFLAGS} ${imap_include}"
780                 LIBS="${LIBS} ${imap_libs} "`echo ${imap_ldflags}`
781                 AC_LINK_IFELSE(
782                 AC_LANG_PROGRAM(
783                                 [#include <stdio.h>
784                                 #include <imap/c-client.h>
785                                 void mm_searched (MAILSTREAM *stream,unsigned long number)
786                                 {
787                                 }
788                                 void mm_exists (MAILSTREAM *stream,unsigned long number)
789                                 {
790                                 }
791                                 void mm_expunged (MAILSTREAM *stream,unsigned long number)
792                                 {
793                                 }
794                                 void mm_flags (MAILSTREAM *stream,unsigned long number)
795                                 {
796                                 }
797                                 void mm_notify (MAILSTREAM *stream,char *string,long errflg)
798                                 {
799                                 }
800                                 void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
801                                 {
802                                 }
803                                 void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
804                                 {
805                                 }
806                                 void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
807                                 {
808                                 }
809                                 void mm_log (char *string,long errflg)
810                                 {
811                                 }
812                                 void mm_dlog (char *string)
813                                 {
814                                 }
815                                 void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
816                                 {
817                                 }
818                                 void mm_critical (MAILSTREAM *stream)
819                                 {
820                                 }
821                                 void mm_nocritical (MAILSTREAM *stream)
822                                 {
823                                 }
824                                 long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
825                                 {
826                                 }
827                                 void mm_fatal (char *string)
828                                 {
829                                 }],
830                                 [
831                                 MAILSTREAM *foo = mail_open(NULL, "", 0);
832                                 ]
833                         ),
834                         [ac_cv_imap_tk="yes"],
835                         [ac_cv_imap_tk="no"]
836                 )
837                 if test "${ac_cv_imap_tk}" = "yes"; then
838                         AC_LINK_IFELSE(
839                                 AC_LANG_PROGRAM(
840                                         [#include <stdio.h>
841                                         #include <imap/c-client.h>
842                                         void mm_searched (MAILSTREAM *stream,unsigned long number)
843                                         {
844                                         }
845                                         void mm_exists (MAILSTREAM *stream,unsigned long number)
846                                         {
847                                         }
848                                         void mm_expunged (MAILSTREAM *stream,unsigned long number)
849                                         {
850                                         }
851                                         void mm_flags (MAILSTREAM *stream,unsigned long number)
852                                         {
853                                         }
854                                         void mm_notify (MAILSTREAM *stream,char *string,long errflg)
855                                         {
856                                         }
857                                         void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
858                                         {
859                                         }
860                                         void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
861                                         {
862                                         }
863                                         void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
864                                         {
865                                         }
866                                         void mm_log (char *string,long errflg)
867                                         {
868                                         }
869                                         void mm_dlog (char *string)
870                                         {
871                                         }
872                                         void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
873                                         {
874                                         }
875                                         void mm_critical (MAILSTREAM *stream)
876                                         {
877                                         }
878                                         void mm_nocritical (MAILSTREAM *stream)
879                                         {
880                                         }
881                                         long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
882                                         {
883                                         }
884                                         void mm_fatal (char *string)
885                                         {
886                                         }],
887                                         [
888                                         long check = mail_expunge_full(NULL, "", 0);
889                                         ]
890                                 ),
891                                 [ac_cv_imap_tk2006="yes"],
892                                 [ac_cv_imap_tk2006="no"]
893                         )
894                 else #looking in imap directory didn't work, try c-client
895                         imap_ldflags=""
896                         imap_libs="-lc-client"
897                         imap_include="-DUSE_SYSTEM_CCLIENT"
898                         CPPFLAGS="${saved_cppflags}"
899                         LIBS="${saved_libs}"
900                         CPPFLAGS="${CPPFLAGS} ${imap_include}"
901                         LIBS="${LIBS} ${imap_libs} "`echo ${imap_ldflags}`
902                         AC_LINK_IFELSE(
903                         AC_LANG_PROGRAM(
904                                         [#include <stdio.h>
905                                         #include <c-client/c-client.h>
906                                         void mm_searched (MAILSTREAM *stream,unsigned long number)
907                                         {
908                                         }
909                                         void mm_exists (MAILSTREAM *stream,unsigned long number)
910                                         {
911                                         }
912                                         void mm_expunged (MAILSTREAM *stream,unsigned long number)
913                                         {
914                                         }
915                                         void mm_flags (MAILSTREAM *stream,unsigned long number)
916                                         {
917                                         }
918                                         void mm_notify (MAILSTREAM *stream,char *string,long errflg)
919                                         {
920                                         }
921                                         void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
922                                         {
923                                         }
924                                         void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
925                                         {
926                                         }
927                                         void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
928                                         {
929                                         }
930                                         void mm_log (char *string,long errflg)
931                                         {
932                                         }
933                                         void mm_dlog (char *string)
934                                         {
935                                         }
936                                         void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
937                                         {
938                                         }
939                                         void mm_critical (MAILSTREAM *stream)
940                                         {
941                                         }
942                                         void mm_nocritical (MAILSTREAM *stream)
943                                         {
944                                         }
945                                         long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
946                                         {
947                                         }
948                                         void mm_fatal (char *string)
949                                         {
950                                         }],
951                                         [
952                                         MAILSTREAM *foo = mail_open(NULL, "", 0);
953                                         ]
954                                 ),
955                                 [ac_cv_imap_tk="yes"],
956                                 [ac_cv_imap_tk="no"]
957                         )
958                         if test "${ac_cv_imap_tk}" = "yes"; then
959                                 AC_LINK_IFELSE(
960                                         AC_LANG_PROGRAM(
961                                                 [#include <stdio.h>
962                                                 #include <c-client/c-client.h>
963                                                 void mm_searched (MAILSTREAM *stream,unsigned long number)
964                                                 {
965                                                 }
966                                                 void mm_exists (MAILSTREAM *stream,unsigned long number)
967                                                 {
968                                                 }
969                                                 void mm_expunged (MAILSTREAM *stream,unsigned long number)
970                                                 {
971                                                 }
972                                                 void mm_flags (MAILSTREAM *stream,unsigned long number)
973                                                 {
974                                                 }
975                                                 void mm_notify (MAILSTREAM *stream,char *string,long errflg)
976                                                 {
977                                                 }
978                                                 void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
979                                                 {
980                                                 }
981                                                 void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
982                                                 {
983                                                 }
984                                                 void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
985                                                 {
986                                                 }
987                                                 void mm_log (char *string,long errflg)
988                                                 {
989                                                 }
990                                                 void mm_dlog (char *string)
991                                                 {
992                                                 }
993                                                 void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
994                                                 {
995                                                 }
996                                                 void mm_critical (MAILSTREAM *stream)
997                                                 {
998                                                 }
999                                                 void mm_nocritical (MAILSTREAM *stream)
1000                                                 {
1001                                                 }
1002                                                 long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
1003                                                 {
1004                                                 }
1005                                                 void mm_fatal (char *string)
1006                                                 {
1007                                                 }],
1008                                                 [
1009                                                 long check = mail_expunge_full(NULL, "", 0);
1010                                                 ]
1011                                         ),
1012                                         [ac_cv_imap_tk2006="yes"],
1013                                         [ac_cv_imap_tk2006="no"]
1014                                 )
1015                         fi
1016                 fi
1017         fi
1018         if test "${ac_cv_imap_tk}" = "yes"; then
1019                 AC_MSG_RESULT(yes)
1020                 IMAP_TK_LIB="${imap_libs} "`echo ${imap_ldflags}`
1021                 IMAP_TK_INCLUDE="${imap_include}"
1022                 PBX_IMAP_TK=1
1023                 AC_DEFINE([HAVE_IMAP_TK], 1, [Define if your system has the UW IMAP Toolkit c-client library.])
1024                 if test "${ac_cv_imap_tk2006}" = "yes"; then
1025                         AC_DEFINE([HAVE_IMAP_TK2006], 1, [Define if your system has the UW IMAP Toolkit c-client library version 2006 or greater.])
1026                 fi
1027         elif test -n "${IMAP_TK_MANDATORY}"; then
1028                 AC_MSG_RESULT(no) 
1029                 AC_MSG_NOTICE([***])
1030                 AC_MSG_NOTICE([*** The UW IMAP Toolkit installation on this system appears to be broken.])
1031                 AC_MSG_NOTICE([*** Either correct the installation, or run configure])
1032                 AC_MSG_NOTICE([*** including --without-imap.])
1033                 exit 1
1034         else
1035                 AC_MSG_RESULT(no)
1036         fi
1037         CPPFLAGS="${saved_cppflags}"
1038         LIBS="${saved_libs}"
1041 # Needed by unixodbc
1042 AST_EXT_LIB_CHECK([LTDL], [ltdl], [lt_dlinit], [ltdl.h], [])
1044 AC_LANG_PUSH(C++)
1046 if test "${USE_KDE}" != "no"; then
1047    AC_MSG_CHECKING(for crashHandler in -lkdecore)
1048    saved_libs="${LIBS}"
1049    saved_cppflags="${CPPFLAGS}"
1050    CPPFLAGS="${CPPFLAGS} -I${KDE_DIR}/include"
1051    if test -d ${KDE_DIR}/lib; then
1052       kdelibdir="${KDE_DIR}/lib"
1053    else
1054       kdelibdir="${KDE_DIR}"
1055    fi
1056    LIBS="${LIBS} -L${kdelibdir} -lkdecore"
1058    AC_LINK_IFELSE(
1059         [AC_LANG_PROGRAM(
1060                         [#include "kcrash.h"],
1061                         [KCrash::defaultCrashHandler(1);])
1062         ],
1063         [ac_cv_lib_kde_crash="yes"],
1064         [ac_cv_lib_kde_crash="no"])
1065                 
1066    LIBS="${saved_libs}"
1067    CPPFLAGS="${saved_cppflags}"
1068         
1069    if test "${ac_cv_lib_kde_crash}" = "yes"; then
1070       AC_MSG_RESULT(yes) 
1071       KDE_LIB="-lkdecore -lkdeui"
1072       if test "${KDE_DIR}" != ""; then
1073          KDE_LIB="-L${kdelibdir} ${KDE_LIB}"
1074          KDE_INCLUDE="-I${KDE_DIR}/include"
1075       fi
1076       PBX_KDE=1
1077       AC_DEFINE([HAVE_LIBKDE], 1, [Define if your system has the KDE libraries.])
1078    elif test -n "${KDE_MANDATORY}"; then
1079       AC_MSG_RESULT(no) 
1080       AC_MSG_NOTICE([***])
1081       AC_MSG_NOTICE([*** The KDE installation on this system appears to be broken.])
1082       AC_MSG_NOTICE([*** Either correct the installation, or run configure])
1083       AC_MSG_NOTICE([*** including --without-kde.])
1084       exit 1
1085    else
1086       AC_MSG_RESULT(no) 
1087    fi
1089 if test "${PBX_KDE}" = 1; then
1090    AC_PATH_TOOL(KDEINIT, kdeinit, No)
1091    if test ! x"${KDEINIT}" = xNo; then
1092       KDEDIR=$(${DIRNAME} ${KDEINIT})
1093       KDEDIR=$(${DIRNAME} ${KDEDIR})
1094    fi
1095    AC_SUBST([KDEDIR])
1098 AC_LANG_POP
1100 AST_EXT_LIB_CHECK([MISDN], [mISDN], [mISDN_open], [mISDNuser/mISDNlib.h])
1102 if test "${PBX_MISDN}" = 1; then
1103    AST_EXT_LIB_CHECK([ISDNNET], [isdnnet], [init_manager], [mISDNuser/isdn_net.h], [-lmISDN -lpthread])
1104    AST_EXT_LIB_CHECK([SUPPSERV], [suppserv], [encodeFac], [mISDNuser/suppserv.h])
1105    AC_CHECK_HEADER([linux/mISDNdsp.h], [AC_DEFINE_UNQUOTED([MISDN_1_2], 1, [Build chan_misdn for mISDN 1.2 or later.])])
1108 AST_EXT_LIB_CHECK([NBS], [nbs], [nbs_connect], [nbs.h])
1110 AST_EXT_LIB_CHECK([NCURSES], [ncurses], [initscr], [curses.h])
1112 NETSNMP_CONFIG=No
1113 if test "${USE_NETSNMP}" != "no"; then  
1114    if test "x${NETSNMP_DIR}" != "x"; then
1115       AC_PATH_TOOL([NETSNMP_CONFIG], [net-snmp-config], No, [${NETSNMP_DIR}/bin])
1116       if test x"${NETSNMP_CONFIG}" = xNo; then
1117          AC_MSG_NOTICE([***])
1118          AC_MSG_NOTICE([*** net-snmp-config was not found in the path you specified:])
1119          AC_MSG_NOTICE([*** ${NETSNMP_DIR}/bin])
1120          AC_MSG_NOTICE([*** Either correct the installation, or run configure])
1121          AC_MSG_NOTICE([*** including --without-netsnmp])
1122          exit 1
1123       fi
1124    else
1125       AC_PATH_TOOL([NETSNMP_CONFIG], [net-snmp-config], No)
1126    fi
1128 if test x"${NETSNMP_CONFIG}" != xNo; then
1129    NETSNMP_libs=`${NETSNMP_CONFIG} --agent-libs`
1130    
1131    AC_CHECK_LIB([netsnmp], [snmp_register_callback], AC_DEFINE_UNQUOTED([HAVE_NETSNMP], 1,
1132    [Define to indicate the Net-SNMP library]), [], ${NETSNMP_libs})
1134    if test "${ac_cv_lib_netsnmp_snmp_register_callback}" = "yes"; then
1135       NETSNMP_LIB="${NETSNMP_libs}"
1136       PBX_NETSNMP=1
1137    elif test -n "${NETSNMP_MANDATORY}";
1138    then
1139       AC_MSG_NOTICE([***])
1140       AC_MSG_NOTICE([*** The Net-SNMP installation on this system appears to be broken.])
1141       AC_MSG_NOTICE([*** Either correct the installation, or run configure])
1142       AC_MSG_NOTICE([*** including --without-netsnmp])
1143       exit 1
1144    fi
1145 elif test -n "${NETSNMP_MANDATORY}";
1146 then
1147    AC_MSG_NOTICE([***])
1148    AC_MSG_NOTICE([*** The Net-SNMP installation on this system appears to be broken.])
1149    AC_MSG_NOTICE([*** Either correct the installation, or run configure])
1150    AC_MSG_NOTICE([*** including --without-netsnmp])
1151    exit 1
1154 AST_EXT_LIB_CHECK([NEWT], [newt], [newtBell], [newt.h])
1156 AST_EXT_LIB_CHECK([UNIXODBC], [odbc], [SQLConnect], [sql.h], [])
1158 AST_EXT_LIB_CHECK([OGG], [ogg], [ogg_sync_init], [])
1160 if test "${USE_OSS}" != "no"; then
1161 PBX_OSS=0
1162 AC_CHECK_HEADER([linux/soundcard.h],
1163                 [
1164                 PBX_OSS=1
1165                 AC_DEFINE_UNQUOTED([HAVE_OSS], 1, [Define to indicate the Open Sound System library])
1166                 ])
1167 if test "$PBX_OSS" = "0"; then
1168    AC_CHECK_HEADER([sys/soundcard.h],
1169                    [
1170                    PBX_OSS=1
1171                    AC_DEFINE_UNQUOTED([HAVE_OSS], 1, [Define to indicate the Open Sound System library])
1172                    ])
1174 if test "$PBX_OSS" = "0"; then
1175    AST_EXT_LIB_CHECK([OSS], [ossaudio], [oss_ioctl_mixer], [soundcard.h])
1179 PG_CONFIG=No
1180 if test "${USE_PGSQL}" != "no"; then    
1181    if test "x${PGSQL_DIR}" != "x"; then
1182       AC_PATH_TOOL([PG_CONFIG], [pg_config], No, [${PGSQL_DIR}/bin])
1183       if test x"${PG_CONFIG}" = xNo; then
1184          AC_MSG_NOTICE([***])
1185          AC_MSG_NOTICE([*** pg_config was not found in the path you specified:])
1186          AC_MSG_NOTICE([*** ${PGSQL_DIR}/bin])
1187          AC_MSG_NOTICE([*** Either correct the installation, or run configure])
1188          AC_MSG_NOTICE([*** including --without-postgres])
1189          exit 1
1190       fi
1191    else
1192       AC_PATH_TOOL([PG_CONFIG], [pg_config], No)
1193    fi
1195 if test "${PG_CONFIG}" != No; then
1196    PGSQL_libdir=`${PG_CONFIG} --libdir`
1197    PGSQL_includedir=`${PG_CONFIG} --includedir`
1199    if test "x$?" != "x0" ; then
1200       if test -n "${PGSQL_MANDATORY}" ; then
1201          AC_MSG_NOTICE([***])
1202          AC_MSG_NOTICE([*** The PostgreSQL installation on this system appears to be broken.])
1203          AC_MSG_NOTICE([*** Either correct the installation, or run configure])
1204          AC_MSG_NOTICE([*** including --without-postgres])
1205          exit 1
1206           fi
1207    else 
1208       AC_CHECK_LIB([pq], [PQescapeStringConn], AC_DEFINE_UNQUOTED([HAVE_PGSQL], 1,
1209       [Define to indicate the PostgreSQL library]), [], -L${PGSQL_libdir} -lz)
1211       if test "${ac_cv_lib_pq_PQescapeStringConn}" = "yes"; then
1212          PGSQL_LIB="-L${PGSQL_libdir} -lpq -lz"
1213          PGSQL_INCLUDE="-I${PGSQL_includedir}"
1214          PBX_PGSQL=1
1215       elif test -n "${PGSQL_MANDATORY}";
1216       then
1217          AC_MSG_NOTICE([***])
1218          AC_MSG_NOTICE([*** The PostgreSQL installation on this system appears to be broken.])
1219          AC_MSG_NOTICE([*** Either correct the installation, or run configure])
1220          AC_MSG_NOTICE([*** including --without-postgres])
1221          exit 1
1222       fi
1223    fi
1224 elif test -n "${PGSQL_MANDATORY}";
1225 then
1226    AC_MSG_NOTICE([***])
1227    AC_MSG_NOTICE([*** The PostgreSQL installation on this system appears to be broken.])
1228    AC_MSG_NOTICE([*** Either correct the installation, or run configure])
1229    AC_MSG_NOTICE([*** including --without-postgres])
1230    exit 1
1233 AST_EXT_LIB_CHECK([POPT], [popt], [poptStrerror], [popt.h])
1235 AST_EXT_LIB_CHECK([PRI], [pri], [pri_keypad_facility], [libpri.h])
1237 AST_EXT_LIB_CHECK([PRI_VERSION], [pri], [pri_get_version], [libpri.h])
1239 if test "${USE_PWLIB}" != "no"; then
1240         if test -n "${PWLIB_DIR}"; then
1241                 PWLIBDIR="${PWLIB_DIR}"
1242         fi
1243         AST_CHECK_PWLIB()
1244         AST_CHECK_PWLIB_VERSION([PWLib], [PWLIB], [ptbuildopts.h], [1], [9], [2])
1245                 
1246         if test "${HAS_PWLIB:-unset}" != "unset"; then
1247                 AST_CHECK_OPENH323_PLATFORM()
1249                 PLATFORM_PWLIB="pt_${PWLIB_PLATFORM}_r"
1251                 AST_CHECK_PWLIB_BUILD([PWLib], [PWLIB],
1252                         [Define if your system has the PWLib libraries.],
1253                         [#include "ptlib.h"],
1254                         [BOOL q = PTime::IsDaylightSavings();])
1255         fi
1258 if test "${USE_PWLIB}" != "no" -a "x${ac_cv_lib_PWLIB}" != "xyes" -a -n "${PWLIB_MANDATORY}"; then
1259    AC_MSG_NOTICE([***])
1260    AC_MSG_NOTICE([*** The PWLIB installation on this system appears to be broken.])
1261    AC_MSG_NOTICE([*** Either correct the installation, or run configure])
1262    AC_MSG_NOTICE([*** including --without-pwlib])
1263    exit 1
1266 if test "${PBX_PWLIB}" = "1" -a "${USE_OPENH323}" != "no" ; then
1267         if test -n "${OPENH323_DIR}"; then
1268                 OPENH323DIR="${OPENH323_DIR}"
1269         fi
1270         AST_CHECK_OPENH323()
1271         AST_CHECK_PWLIB_VERSION([OpenH323], [OPENH323], [openh323buildopts.h], [1], [17], [3])
1272         AST_CHECK_OPENH323_BUILD()
1273         PLATFORM_OPENH323="h323_${PWLIB_PLATFORM}_${OPENH323_SUFFIX}"
1274         AST_CHECK_PWLIB_BUILD([OpenH323], [OPENH323],
1275                 [Define if your system has the OpenH323 libraries.],
1276                 [#include "ptlib.h"
1277                 #include "h323.h"
1278                 #include "h323ep.h"],
1279                 [H323EndPoint ep = H323EndPoint();],
1280                 [${PWLIB_INCLUDE}], [${PWLIB_LIB}])
1282 if test "${USE_OPENH323}" != "no" -a "x${ac_cv_lib_OPENH323}" != "xyes" -a -n "${OPENH323_MANDATORY}"; then
1283    AC_MSG_NOTICE([***])
1284    AC_MSG_NOTICE([*** The OPENH323 installation on this system appears to be broken.])
1285    AC_MSG_NOTICE([*** Either correct the installation, or run configure])
1286    AC_MSG_NOTICE([*** including --without-h323])
1287    exit 1
1290 AST_EXT_LIB_CHECK([RADIUS], [radiusclient-ng], [rc_read_config], [radiusclient-ng.h])
1292 AST_EXT_LIB_CHECK([SPEEX], [speex], [speex_encode], [speex/speex.h], [-lm])
1294 # See if the main speex library contains the preprocess functions
1295 AST_EXT_LIB_CHECK([SPEEX_PREPROCESS], [speex], [speex_preprocess_ctl], [speex/speex.h], [-lm])
1296 if test "${PBX_SPEEX_PREPROCESS}" = 1; then
1297    PBX_SPEEX_PREPROCESS=1
1300 AST_EXT_LIB_CHECK([SPEEXDSP], [speexdsp], [speex_preprocess_ctl], [speex/speex.h], [-lm])
1301 if test "${PBX_SPEEXDSP}" = 1; then
1302    PBX_SPEEX_PREPROCESS=1
1305 AC_SUBST(PBX_SPEEX_PREPROCESS)
1307 AST_EXT_LIB_CHECK([SQLITE], [sqlite], [sqlite_exec], [sqlite.h])
1309 AST_EXT_LIB_CHECK([OPENSSL], [ssl], [ssl2_connect], [openssl/ssl.h], [-lcrypto])
1310 if test "$PBX_OPENSSL" = "1";
1311 then
1312     AST_EXT_LIB_CHECK([OSPTK], [osptk], [OSPPCryptoDecrypt], [osp/osp.h], [-lcrypto -lssl])
1315 AST_EXT_LIB_CHECK([FREETDS], [tds], [tds_version], [tds.h])
1316 if test "${PBX_FREETDS}" != "0";
1317 then
1318     if test "${FREETDS_DIR}x" = "x";
1319     then
1320         for tds_dir in /usr /usr/local;
1321         do
1322             if test -f "${tds_dir}/include/tdsver.h";
1323             then
1324                 FREETDS_DIR="${tds_dir}"
1325             fi
1326         done
1327     fi
1328     case `${GREP} TDS_VERSION_NO ${FREETDS_DIR:-/usr}/include/tdsver.h` in
1329     *0.64*)
1330         FREETDS_INCLUDE="${FREETDS_INCLUDE} -DFREETDS_0_64"
1331         ;;
1332     *0.63*)
1333         FREETDS_INCLUDE="${FREETDS_INCLUDE} -DFREETDS_0_63"
1334         ;;
1335     *0.62*)
1336         FREETDS_INCLUDE="${FREETDS_INCLUDE} -DFREETDS_0_62"
1337         ;;
1338     *)
1339         FREETDS_INCLUDE="${FREETDS_INCLUDE} -DFREETDS_PRE_0_62"
1340         ;;
1341     esac
1344 AST_EXT_LIB_CHECK([TERMCAP], [termcap], [tgetent], [])
1346 AST_EXT_LIB_CHECK([TINFO], [tinfo], [tgetent], [])
1348 if test "${host_os}" != "linux-gnu" ; then
1349   tonezone_extra="-lm"
1352 AST_EXT_LIB_CHECK([TONEZONE], [tonezone], [tone_zone_find], [zaptel/tonezone.h], [${tonezone_extra}])
1354 AST_EXT_LIB_CHECK([USB], [usb], [usb_init], [usb.h], [])
1356 AST_EXT_LIB_CHECK([VORBIS], [vorbis], [vorbis_info_init], [vorbis/codec.h], [-lm -lvorbisenc])
1358 AC_LANG_PUSH(C++)
1360 if test "${USE_VPB}" != "no"; then
1361    AC_MSG_CHECKING(for vpb_open in -lvpb)
1362    saved_libs="${LIBS}"
1363    saved_cppflags="${CPPFLAGS}"
1364    if test "x${VPB_DIR}" != "x"; then
1365       if test -d ${VPB_DIR}/lib; then
1366          vpblibdir=${VPB_DIR}/lib
1367       else
1368          vpblibdir=${VPB_DIR}
1369       fi
1370       LIBS="${LIBS} -L${vpblibdir}"
1371       CPPFLAGS="${CPPFLAGS} -I${VPB_DIR}/include"
1372    fi
1373    LIBS="${LIBS} -lvpb -lpthread"
1374    AC_LINK_IFELSE(
1375         [
1376         AC_LANG_PROGRAM(
1377         [#include <vpbapi.h>],
1378         [int q = vpb_open(0,0);])
1379         ],
1380         [       AC_MSG_RESULT(yes) 
1381                 ac_cv_lib_vpb_vpb_open="yes" 
1382         ],
1383         [       AC_MSG_RESULT(no) 
1384                 ac_cv_lib_vpb_vpb_open="no" 
1385         ]
1386         )
1387    LIBS="${saved_libs}"
1388    CPPFLAGS="${saved_cppflags}"
1389    if test "${ac_cv_lib_vpb_vpb_open}" = "yes"; then
1390         VPB_LIB="-lvpb"
1391         if test "${VPB_DIR}" != ""; then
1392            VPB_LIB="-L${vpblibdir}  ${VPB_LIB}"
1393            VPB_INCLUDE="-I${VPB_DIR}/include"
1394         fi
1395         PBX_VPB=1
1396         AC_DEFINE([HAVE_VPB], 1, [Define if your system has the VoiceTronix API libraries.])
1397    elif test -n "${VPB_MANDATORY}"; then
1398       AC_MSG_NOTICE([***])
1399       AC_MSG_NOTICE([*** The VoiceTronix (vpb) installation on this system appears to be broken.])
1400       AC_MSG_NOTICE([*** Either correct the installation, or run configure])
1401       AC_MSG_NOTICE([*** including --without-vpb.])
1402       exit 1
1403    fi
1406 AC_LANG_POP
1408 AST_EXT_LIB_CHECK([ZLIB], [z], [compress], [zlib.h])
1410 if test "${USE_ZAPTEL}" != "no"; then
1411    AC_MSG_CHECKING(for ZT_DIAL_OP_CANCEL in zaptel/zaptel.h)
1412    saved_cppflags="${CPPFLAGS}"
1413    if test "x${ZAPTEL_DIR}" != "x"; then
1414       CPPFLAGS="${CPPFLAGS} -I${ZAPTEL_DIR}/include"
1415    fi
1416    AC_COMPILE_IFELSE(
1417         [
1418         AC_LANG_PROGRAM(
1419         [#include <zaptel/zaptel.h>],
1420         [int foo = ZT_DIAL_OP_CANCEL;])
1421         ],
1422         [       AC_MSG_RESULT(yes) 
1423                 ac_cv_zaptel_h="yes" 
1424         ],
1425         [       AC_MSG_RESULT(no) 
1426                 ac_cv_zaptel_h="no" 
1427         ]
1428         )
1429    CPPFLAGS="${saved_cppflags}"
1430    if test "${ac_cv_zaptel_h}" = "yes"; then
1431         if test "${ZAPTEL_DIR}" != ""; then
1432            ZAPTEL_INCLUDE="-I${ZAPTEL_DIR}/include"
1433         fi
1434         PBX_ZAPTEL=1
1435         AC_DEFINE([HAVE_ZAPTEL], 1, [Define if your system has the Zaptel headers.])
1436    elif test -n "${ZAPTEL_MANDATORY}"; 
1437    then
1438       AC_MSG_NOTICE([***])
1439       AC_MSG_NOTICE([*** The Zaptel installation on this system appears to be broken.])
1440       AC_MSG_NOTICE([*** Either correct the installation, or run configure])
1441       AC_MSG_NOTICE([*** including --without-zaptel.])
1442       exit 1
1443    fi
1446 if test "${PBX_ZAPTEL}" = 1; then
1447    AC_MSG_CHECKING(for ZT_EVENT_REMOVED in zaptel/zaptel.h)
1448    saved_cppflags="${CPPFLAGS}"
1449    if test "x${ZAPTEL_DIR}" != "x"; then
1450       CPPFLAGS="${CPPFLAGS} -I${ZAPTEL_DIR}/include"
1451    fi
1452    AC_COMPILE_IFELSE(
1453         [
1454         AC_LANG_PROGRAM(
1455         [#include <zaptel/zaptel.h>],
1456         [int foo = ZT_EVENT_REMOVED;])
1457         ],
1458         [       AC_MSG_RESULT(yes) 
1459                 ac_cv_zaptel_vldtmf="yes" 
1460         ],
1461         [       AC_MSG_RESULT(no) 
1462                 ac_cv_zaptel_vldtmf="no" 
1463         ]
1464         )
1465    CPPFLAGS="${saved_cppflags}"
1466    if test "${ac_cv_zaptel_vldtmf}" = "yes"; then
1467         PBX_ZAPTEL_VLDTMF=1
1468    fi
1469    AC_MSG_CHECKING(for ZT_TCOP_ALLOCATE in zaptel/zaptel.h)
1470    saved_cppflags="${CPPFLAGS}"
1471    if test "x${ZAPTEL_DIR}" != "x"; then
1472       CPPFLAGS="${CPPFLAGS} -I${ZAPTEL_DIR}/include"
1473    fi
1474    AC_COMPILE_IFELSE(
1475         [
1476         AC_LANG_PROGRAM(
1477         [#include <zaptel/zaptel.h>],
1478         [int foo = ZT_TCOP_ALLOCATE;])
1479         ],
1480         [       AC_MSG_RESULT(yes) 
1481                 ac_cv_zaptel_transcode="yes" 
1482         ],
1483         [       AC_MSG_RESULT(no) 
1484                 ac_cv_zaptel_transcode="no" 
1485         ]
1486         )
1487    CPPFLAGS="${saved_cppflags}"
1488    if test "${ac_cv_zaptel_transcode}" = "yes"; then
1489         PBX_ZAPTEL_TRANSCODE=1
1490    fi
1492 AC_SUBST(PBX_ZAPTEL_VLDTMF)
1493 AC_SUBST(PBX_ZAPTEL_TRANSCODE)
1495 EDITLINE_LIB=""
1496 if test "x$TERMCAP_LIB" != "x" ; then
1497   EDITLINE_LIB="$TERMCAP_LIB"
1498 elif test "x$TINFO_LIB" != "x" ; then
1499   EDITLINE_LIB="$TINFO_LIB"
1500 elif test "x$CURSES_LIB" != "x" ; then
1501   EDITLINE_LIB="$CURSES_LIB"
1502 elif test "x$NCURSES_LIB" != "x" ; then
1503   EDITLINE_LIB="$NCURSES_LIB"
1504 else
1505   AC_MSG_ERROR(*** termcap support not found)
1507 AC_SUBST(EDITLINE_LIB)
1509 AC_CHECK_HEADER([h323.h], [PBX_H323=1], [PBX_H323=0])
1510 AC_SUBST(PBX_H323)
1512 AC_CHECK_HEADER([linux/compiler.h],
1513                 [AC_DEFINE_UNQUOTED([HAVE_LINUX_COMPILER_H], 1, [Define to 1 if your system has linux/compiler.h.])])
1515 AC_CHECK_HEADER([linux/ixjuser.h], [PBX_IXJUSER=1], [PBX_IXJUSER=0], [
1516                                    #include <linux/version.h>
1517                                    #ifdef HAVE_LINUX_COMPILER_H
1518                                    #include <linux/compiler.h>
1519                                    #endif
1520                                    ])
1521 AC_SUBST(PBX_IXJUSER)
1523 if test "${cross_compiling}" = "no";
1524 then
1525   AC_CHECK_FILE(/sbin/launchd, AC_DEFINE([HAVE_SBIN_LAUNCHD], 1, [Define to 1 if your system has /sbin/launchd.]))
1528 PBX_GTK=0
1529 AC_CHECK_TOOL(GTKCONFIG, gtk-config, No)
1530 if test ! "x${GTKCONFIG}" = xNo; then
1531    GTK_INCLUDE=$(${GTKCONFIG} --cflags gthread)
1532    GTK_LIB=$(${GTKCONFIG} --libs gthread)
1533    PBX_GTK=1
1534    AC_DEFINE([HAVE_GTK], 1, [Define if your system has the GTK libraries.])
1536 AC_SUBST(PBX_GTK)
1537 AC_SUBST(GTK_INCLUDE)
1538 AC_SUBST(GTK_LIB)
1540 PBX_GTK2=0
1541 AC_CHECK_TOOL(PKGCONFIG, pkg-config, No)
1542 if test ! "x${PKGCONFIG}" = xNo; then
1543    GTK2_INCLUDE=$(${PKGCONFIG} gtk+-2.0 --cflags 2>/dev/null)
1544    GTK2_LIB=$(${PKGCONFIG} gtk+-2.0 --libs)
1545    PBX_GTK2=1
1546    AC_DEFINE([HAVE_GTK2], 1, [Define if your system has the GTK2 libraries.])
1548 AC_SUBST(PBX_GTK2)
1549 AC_SUBST(GTK2_INCLUDE)
1550 AC_SUBST(GTK2_LIB)
1552 if test "${USE_CURL}" != "no"; then
1553    AC_PATH_TOOL([CURL_CONFIG], [curl-config], No)
1554    if test ! x"${CURL_CONFIG}" = xNo; then
1555    # check for version
1556       if test $(printf "%d" 0x$(${CURL_CONFIG} --vernum)) -ge $(printf "%d" 0x070907); then
1557          CURL_INCLUDE=$(${CURL_CONFIG} --cflags)
1558          CURL_LIB=$(${CURL_CONFIG} --libs)
1560          AC_MSG_CHECKING(for curl_version() in curl/curl.h)
1561          saved_cppflags="${CPPFLAGS}"
1562          CPPFLAGS="${CPPFLAGS} ${CURL_INCLUDE}"
1563          AC_COMPILE_IFELSE(
1564             [AC_LANG_PROGRAM(
1565                 [#include <curl/curl.h>],
1566                     [curl_version();])
1567             ],[
1568                 AC_MSG_RESULT(yes)
1569                 ac_cv_curl_h="yes"
1570             ],[
1571                 AC_MSG_RESULT(no)
1572                 ac_cv_curl_h="no"
1573             ]
1574          )
1575          CPPFLAGS="${saved_cppflags}"
1576          if test "${ac_cv_curl_h}" = "yes"; then
1577              PBX_CURL=1
1578              AC_DEFINE([HAVE_CURL], 1, [Define if your system has the curl libraries.])
1579          fi
1580       fi
1581    fi
1584 AC_CONFIG_FILES([build_tools/menuselect-deps makeopts channels/h323/Makefile])
1585 AC_OUTPUT
1587 if test "x${silent}" != "xyes" ; then
1588 echo
1589 echo "               .\$\$\$\$\$\$\$\$\$\$\$\$\$\$\$=..      "
1590 echo "            .\$7\$7..          .7\$\$7:.    "
1591 echo "          .\$\$:.                 ,\$7.7   "
1592 echo "        .\$7.     7\$\$\$\$           .\$\$77  "
1593 echo "     ..\$\$.       \$\$\$\$\$            .\$\$\$7 "
1594 echo "    ..7\$   .?.   \$\$\$\$\$   .?.       7\$\$\$."
1595 echo "   \$.\$.   .\$\$\$7. \$\$\$\$7 .7\$\$\$.      .\$\$\$."
1596 echo " .777.   .\$\$\$\$\$\$77\$\$\$77\$\$\$\$\$7.      \$\$\$,"
1597 echo " \$\$\$~      .7\$\$\$\$\$\$\$\$\$\$\$\$\$7.       .\$\$\$."
1598 echo ".\$\$7          .7\$\$\$\$\$\$\$7:          ?\$\$\$."
1599 echo "\$\$\$          ?7\$\$\$\$\$\$\$\$\$\$I        .\$\$\$7 "
1600 echo "\$\$\$       .7\$\$\$\$\$\$\$\$\$\$\$\$\$\$\$\$      :\$\$\$. "
1601 echo "\$\$\$       \$\$\$\$\$\$7\$\$\$\$\$\$\$\$\$\$\$\$    .\$\$\$.  "
1602 echo "\$\$\$        \$\$\$   7\$\$\$7  .\$\$\$    .\$\$\$.   "
1603 echo "\$\$\$\$             \$\$\$\$7         .\$\$\$.    "
1604 echo "7\$\$\$7            7\$\$\$\$        7\$\$\$      "
1605 echo " \$\$\$\$\$                        \$\$\$       "
1606 echo "  \$\$\$\$7.                       \$\$  (TM)     "
1607 echo "   \$\$\$\$\$\$\$.           .7\$\$\$\$\$\$  \$\$      "
1608 echo "     \$\$\$\$\$\$\$\$\$\$\$\$7\$\$\$\$\$\$\$\$\$.\$\$\$\$\$\$      "
1609 echo "       \$\$\$\$\$\$\$\$\$\$\$\$\$\$\$\$.                "
1610 echo
1613 AC_MSG_NOTICE(Package configured for: )
1614 AC_MSG_NOTICE( OS type  : $host_os)
1615 AC_MSG_NOTICE( Host CPU : $host_cpu)
1616 if test "${cross_compiling}" = "yes"; then
1617    AC_MSG_NOTICE( Cross Compilation = YES)