Newer
Older
45001
45002
45003
45004
45005
45006
45007
45008
45009
45010
45011
45012
45013
45014
45015
45016
45017
45018
{ echo "$as_me:$LINENO: checking for ZT_SET_HWGAIN in zaptel/zaptel.h" >&5
echo $ECHO_N "checking for ZT_SET_HWGAIN in zaptel/zaptel.h... $ECHO_C" >&6; }
saved_cppflags="${CPPFLAGS}"
if test "x${ZAPTEL_HWGAIN_DIR}" != "x"; then
ZAPTEL_HWGAIN_INCLUDE="-I${ZAPTEL_HWGAIN_DIR}/include"
fi
CPPFLAGS="${CPPFLAGS} ${ZAPTEL_HWGAIN_INCLUDE}"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
#include <zaptel/zaptel.h>
int
main ()
{
Kevin P. Fleming
committed
#if defined(ZT_SET_HWGAIN)
int foo = 0;
#else
int foo = bar;
#endif
0
45026
45027
45028
45029
45030
45031
45032
45033
45034
45035
45036
45037
45038
45039
45040
45041
45042
;
return 0;
}
_ACEOF
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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
{ echo "$as_me:$LINENO: result: yes" >&5
echo "${ECHO_T}yes" >&6; }
PBX_ZAPTEL_HWGAIN=1
cat >>confdefs.h <<\_ACEOF
#define HAVE_ZAPTEL_HWGAIN 1
_ACEOF
cat >>confdefs.h <<\_ACEOF
#define HAVE_ZAPTEL_HWGAIN_VERSION
_ACEOF
45061
45062
45063
45064
45065
45066
45067
45068
45069
45070
45071
45072
45073
45074
45075
45076
45077
45078
45079
45080
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
{ echo "$as_me:$LINENO: result: no" >&5
echo "${ECHO_T}no" >&6; }
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
CPPFLAGS="${saved_cppflags}"
fi
# On FreeBSD, try old zaptel (0.80 or so) and pretend we have vldtmf
case "${host_os}" in
freebsd*)
if test "x${PBX_ZAPTEL}" != "x1" -a "${USE_ZAPTEL}" != "no"; then
pbxlibdir=""
# if --with-ZAPTEL=DIR has been specified, use it.
45082
45083
45084
45085
45086
45087
45088
45089
45090
45091
45092
45093
45094
45095
45096
45097
45098
45099
45100
45101
45102
45103
45104
45105
45106
45107
45108
45109
45110
45111
45112
45113
45114
45115
45116
45117
45118
45119
45120
45121
45122
45123
45124
45125
45126
45127
45128
45129
45130
45131
45132
45133
45134
45135
if test "x${ZAPTEL_DIR}" != "x"; then
if test -d ${ZAPTEL_DIR}/lib; then
pbxlibdir="-L${ZAPTEL_DIR}/lib"
else
pbxlibdir="-L${ZAPTEL_DIR}"
fi
fi
pbxfuncname=""
if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
AST_ZAPTEL_FOUND=yes
else
as_ac_Lib=`echo "ac_cv_lib_zaptel_${pbxfuncname}" | $as_tr_sh`
{ echo "$as_me:$LINENO: checking for ${pbxfuncname} in -lzaptel" >&5
echo $ECHO_N "checking for ${pbxfuncname} in -lzaptel... $ECHO_C" >&6; }
if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lzaptel ${pbxlibdir} $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* 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 ${pbxfuncname} ();
int
main ()
{
return ${pbxfuncname} ();
;
return 0;
}
_ACEOF
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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
(eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest$ac_exeext &&
$as_test_x conftest$ac_exeext; then
eval "$as_ac_Lib=yes"
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
eval "$as_ac_Lib=no"
fi
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
ac_res=`eval echo '${'$as_ac_Lib'}'`
{ echo "$as_me:$LINENO: result: $ac_res" >&5
echo "${ECHO_T}$ac_res" >&6; }
if test `eval echo '${'$as_ac_Lib'}'` = yes; then
AST_ZAPTEL_FOUND=yes
else
AST_ZAPTEL_FOUND=no
fi
fi
# now check for the header.
if test "${AST_ZAPTEL_FOUND}" = "yes"; then
ZAPTEL_LIB="${pbxlibdir} -lzaptel "
# if --with-ZAPTEL=DIR has been specified, use it.
if test "x${ZAPTEL_DIR}" != "x"; then
ZAPTEL_INCLUDE="-I${ZAPTEL_DIR}/include"
fi
ZAPTEL_INCLUDE="${ZAPTEL_INCLUDE} "
if test "xzaptel.h" = "x" ; then # no header, assume found
ZAPTEL_HEADER_FOUND="1"
else # check for the header
saved_cppflags="${CPPFLAGS}"
CPPFLAGS="${CPPFLAGS} ${ZAPTEL_INCLUDE} "
if test "${ac_cv_header_zaptel_h+set}" = set; then
45178
45179
45180
45181
45182
45183
45184
45185
45186
45187
45188
45189
45190
45191
45192
45193
45194
45195
45196
45197
45198
45199
45200
45201
45202
45203
45204
45205
45206
45207
45208
45209
45210
{ echo "$as_me:$LINENO: checking for zaptel.h" >&5
echo $ECHO_N "checking for zaptel.h... $ECHO_C" >&6; }
if test "${ac_cv_header_zaptel_h+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
fi
{ echo "$as_me:$LINENO: result: $ac_cv_header_zaptel_h" >&5
echo "${ECHO_T}$ac_cv_header_zaptel_h" >&6; }
else
# Is the header compilable?
{ echo "$as_me:$LINENO: checking zaptel.h usability" >&5
echo $ECHO_N "checking zaptel.h usability... $ECHO_C" >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
#include <zaptel.h>
_ACEOF
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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
45215
45216
45217
45218
45219
45220
45221
45222
45223
45224
45225
45226
45227
45228
45229
45230
45231
45232
45233
45234
45235
45236
45237
45238
45239
45240
45241
45242
45243
45244
45245
45246
45247
45248
45249
ac_header_compiler=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_header_compiler=no
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
echo "${ECHO_T}$ac_header_compiler" >&6; }
# Is the header present?
{ echo "$as_me:$LINENO: checking zaptel.h presence" >&5
echo $ECHO_N "checking zaptel.h presence... $ECHO_C" >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
#include <zaptel.h>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
(eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } >/dev/null && {
test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
test ! -s conftest.err
}; then
45254
45255
45256
45257
45258
45259
45260
45261
45262
45263
45264
45265
45266
45267
45268
45269
45270
45271
45272
45273
45274
45275
45276
45277
45278
45279
45280
45281
45282
45283
45284
45285
45286
45287
ac_header_preproc=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_header_preproc=no
fi
rm -f conftest.err conftest.$ac_ext
{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
echo "${ECHO_T}$ac_header_preproc" >&6; }
# So? What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
yes:no: )
{ echo "$as_me:$LINENO: WARNING: zaptel.h: accepted by the compiler, rejected by the preprocessor!" >&5
echo "$as_me: WARNING: zaptel.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel.h: proceeding with the compiler's result" >&5
echo "$as_me: WARNING: zaptel.h: proceeding with the compiler's result" >&2;}
ac_header_preproc=yes
;;
no:yes:* )
{ echo "$as_me:$LINENO: WARNING: zaptel.h: present but cannot be compiled" >&5
echo "$as_me: WARNING: zaptel.h: present but cannot be compiled" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel.h: check for missing prerequisite headers?" >&5
echo "$as_me: WARNING: zaptel.h: check for missing prerequisite headers?" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel.h: see the Autoconf documentation" >&5
echo "$as_me: WARNING: zaptel.h: see the Autoconf documentation" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel.h: section \"Present But Cannot Be Compiled\"" >&5
echo "$as_me: WARNING: zaptel.h: section \"Present But Cannot Be Compiled\"" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel.h: proceeding with the preprocessor's result" >&5
echo "$as_me: WARNING: zaptel.h: proceeding with the preprocessor's result" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel.h: in the future, the compiler will take precedence" >&5
echo "$as_me: WARNING: zaptel.h: in the future, the compiler will take precedence" >&2;}
( cat <<\_ASBOX
## ------------------------------- ##
## Report this to www.asterisk.org ##
## ------------------------------- ##
_ASBOX
) | sed "s/^/$as_me: WARNING: /" >&2
45294
45295
45296
45297
45298
45299
45300
45301
45302
45303
45304
45305
45306
45307
45308
45309
45310
45311
45312
45313
;;
esac
{ echo "$as_me:$LINENO: checking for zaptel.h" >&5
echo $ECHO_N "checking for zaptel.h... $ECHO_C" >&6; }
if test "${ac_cv_header_zaptel_h+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_cv_header_zaptel_h=$ac_header_preproc
fi
{ echo "$as_me:$LINENO: result: $ac_cv_header_zaptel_h" >&5
echo "${ECHO_T}$ac_cv_header_zaptel_h" >&6; }
fi
if test $ac_cv_header_zaptel_h = yes; then
ZAPTEL_HEADER_FOUND=1
else
ZAPTEL_HEADER_FOUND=0
fi
CPPFLAGS="${saved_cppflags}"
45315
45316
45317
45318
45319
45320
45321
45322
45323
45324
45325
45326
45327
45328
45329
45330
45331
fi
if test "x${ZAPTEL_HEADER_FOUND}" = "x0" ; then
ZAPTEL_LIB=""
ZAPTEL_INCLUDE=""
else
if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
ZAPTEL_LIB=""
fi
PBX_ZAPTEL=1
# XXX don't know how to evaluate the description (third argument) in AC_DEFINE_UNQUOTED
cat >>confdefs.h <<_ACEOF
#define HAVE_ZAPTEL 1
_ACEOF
cat >>confdefs.h <<_ACEOF
_ACEOF
fi
fi
fi
if test "x${PBX_ZAPTEL_VLDTMF}" != "x1" -a "${USE_ZAPTEL_VLDTMF}" != "no"; then
pbxlibdir=""
# if --with-ZAPTEL_VLDTMF=DIR has been specified, use it.
45343
45344
45345
45346
45347
45348
45349
45350
45351
45352
45353
45354
45355
45356
45357
45358
45359
45360
45361
45362
45363
45364
45365
45366
45367
45368
45369
45370
45371
45372
45373
45374
45375
45376
45377
45378
45379
45380
45381
45382
45383
45384
45385
45386
45387
45388
45389
45390
45391
45392
45393
45394
45395
45396
if test "x${ZAPTEL_VLDTMF_DIR}" != "x"; then
if test -d ${ZAPTEL_VLDTMF_DIR}/lib; then
pbxlibdir="-L${ZAPTEL_VLDTMF_DIR}/lib"
else
pbxlibdir="-L${ZAPTEL_VLDTMF_DIR}"
fi
fi
pbxfuncname=""
if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
AST_ZAPTEL_VLDTMF_FOUND=yes
else
as_ac_Lib=`echo "ac_cv_lib_zaptel_${pbxfuncname}" | $as_tr_sh`
{ echo "$as_me:$LINENO: checking for ${pbxfuncname} in -lzaptel" >&5
echo $ECHO_N "checking for ${pbxfuncname} in -lzaptel... $ECHO_C" >&6; }
if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lzaptel ${pbxlibdir} $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* 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 ${pbxfuncname} ();
int
main ()
{
return ${pbxfuncname} ();
;
return 0;
}
_ACEOF
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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
(eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest$ac_exeext &&
$as_test_x conftest$ac_exeext; then
eval "$as_ac_Lib=yes"
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
eval "$as_ac_Lib=no"
fi
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
ac_res=`eval echo '${'$as_ac_Lib'}'`
{ echo "$as_me:$LINENO: result: $ac_res" >&5
echo "${ECHO_T}$ac_res" >&6; }
if test `eval echo '${'$as_ac_Lib'}'` = yes; then
AST_ZAPTEL_VLDTMF_FOUND=yes
AST_ZAPTEL_VLDTMF_FOUND=no
fi
# now check for the header.
if test "${AST_ZAPTEL_VLDTMF_FOUND}" = "yes"; then
ZAPTEL_VLDTMF_LIB="${pbxlibdir} -lzaptel "
# if --with-ZAPTEL_VLDTMF=DIR has been specified, use it.
if test "x${ZAPTEL_VLDTMF_DIR}" != "x"; then
ZAPTEL_VLDTMF_INCLUDE="-I${ZAPTEL_VLDTMF_DIR}/include"
fi
ZAPTEL_VLDTMF_INCLUDE="${ZAPTEL_VLDTMF_INCLUDE} "
if test "xzaptel/zaptel.h" = "x" ; then # no header, assume found
ZAPTEL_VLDTMF_HEADER_FOUND="1"
else # check for the header
saved_cppflags="${CPPFLAGS}"
CPPFLAGS="${CPPFLAGS} ${ZAPTEL_VLDTMF_INCLUDE} "
if test "${ac_cv_header_zaptel_zaptel_h+set}" = set; then
45439
45440
45441
45442
45443
45444
45445
45446
45447
45448
45449
45450
45451
45452
45453
45454
45455
45456
45457
45458
45459
45460
45461
45462
45463
45464
45465
45466
45467
45468
45469
45470
45471
{ echo "$as_me:$LINENO: checking for zaptel/zaptel.h" >&5
echo $ECHO_N "checking for zaptel/zaptel.h... $ECHO_C" >&6; }
if test "${ac_cv_header_zaptel_zaptel_h+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
fi
{ echo "$as_me:$LINENO: result: $ac_cv_header_zaptel_zaptel_h" >&5
echo "${ECHO_T}$ac_cv_header_zaptel_zaptel_h" >&6; }
else
# Is the header compilable?
{ echo "$as_me:$LINENO: checking zaptel/zaptel.h usability" >&5
echo $ECHO_N "checking zaptel/zaptel.h usability... $ECHO_C" >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
#include <zaptel/zaptel.h>
_ACEOF
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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
45476
45477
45478
45479
45480
45481
45482
45483
45484
45485
45486
45487
45488
45489
45490
45491
45492
45493
45494
45495
45496
45497
45498
45499
45500
45501
45502
45503
45504
45505
45506
45507
45508
45509
45510
ac_header_compiler=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_header_compiler=no
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
echo "${ECHO_T}$ac_header_compiler" >&6; }
# Is the header present?
{ echo "$as_me:$LINENO: checking zaptel/zaptel.h presence" >&5
echo $ECHO_N "checking zaptel/zaptel.h presence... $ECHO_C" >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
#include <zaptel/zaptel.h>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
(eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } >/dev/null && {
test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
test ! -s conftest.err
}; then
45515
45516
45517
45518
45519
45520
45521
45522
45523
45524
45525
45526
45527
45528
45529
45530
45531
45532
45533
45534
45535
45536
45537
45538
45539
45540
45541
45542
45543
45544
45545
45546
45547
45548
ac_header_preproc=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_header_preproc=no
fi
rm -f conftest.err conftest.$ac_ext
{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
echo "${ECHO_T}$ac_header_preproc" >&6; }
# So? What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
yes:no: )
{ echo "$as_me:$LINENO: WARNING: zaptel/zaptel.h: accepted by the compiler, rejected by the preprocessor!" >&5
echo "$as_me: WARNING: zaptel/zaptel.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel/zaptel.h: proceeding with the compiler's result" >&5
echo "$as_me: WARNING: zaptel/zaptel.h: proceeding with the compiler's result" >&2;}
ac_header_preproc=yes
;;
no:yes:* )
{ echo "$as_me:$LINENO: WARNING: zaptel/zaptel.h: present but cannot be compiled" >&5
echo "$as_me: WARNING: zaptel/zaptel.h: present but cannot be compiled" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel/zaptel.h: check for missing prerequisite headers?" >&5
echo "$as_me: WARNING: zaptel/zaptel.h: check for missing prerequisite headers?" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel/zaptel.h: see the Autoconf documentation" >&5
echo "$as_me: WARNING: zaptel/zaptel.h: see the Autoconf documentation" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel/zaptel.h: section \"Present But Cannot Be Compiled\"" >&5
echo "$as_me: WARNING: zaptel/zaptel.h: section \"Present But Cannot Be Compiled\"" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel/zaptel.h: proceeding with the preprocessor's result" >&5
echo "$as_me: WARNING: zaptel/zaptel.h: proceeding with the preprocessor's result" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel/zaptel.h: in the future, the compiler will take precedence" >&5
echo "$as_me: WARNING: zaptel/zaptel.h: in the future, the compiler will take precedence" >&2;}
( cat <<\_ASBOX
## ------------------------------- ##
## Report this to www.asterisk.org ##
## ------------------------------- ##
_ASBOX
) | sed "s/^/$as_me: WARNING: /" >&2
45555
45556
45557
45558
45559
45560
45561
45562
45563
45564
45565
45566
45567
45568
45569
45570
45571
45572
45573
45574
;;
esac
{ echo "$as_me:$LINENO: checking for zaptel/zaptel.h" >&5
echo $ECHO_N "checking for zaptel/zaptel.h... $ECHO_C" >&6; }
if test "${ac_cv_header_zaptel_zaptel_h+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_cv_header_zaptel_zaptel_h=$ac_header_preproc
fi
{ echo "$as_me:$LINENO: result: $ac_cv_header_zaptel_zaptel_h" >&5
echo "${ECHO_T}$ac_cv_header_zaptel_zaptel_h" >&6; }
fi
if test $ac_cv_header_zaptel_zaptel_h = yes; then
ZAPTEL_VLDTMF_HEADER_FOUND=1
else
ZAPTEL_VLDTMF_HEADER_FOUND=0
fi
CPPFLAGS="${saved_cppflags}"
45576
45577
45578
45579
45580
45581
45582
45583
45584
45585
45586
45587
45588
45589
45590
45591
45592
fi
if test "x${ZAPTEL_VLDTMF_HEADER_FOUND}" = "x0" ; then
ZAPTEL_VLDTMF_LIB=""
ZAPTEL_VLDTMF_INCLUDE=""
else
if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
ZAPTEL_VLDTMF_LIB=""
fi
PBX_ZAPTEL_VLDTMF=1
# XXX don't know how to evaluate the description (third argument) in AC_DEFINE_UNQUOTED
cat >>confdefs.h <<_ACEOF
#define HAVE_ZAPTEL_VLDTMF 1
_ACEOF
cat >>confdefs.h <<_ACEOF
#define HAVE_ZAPTEL_VLDTMF_VERSION 90
_ACEOF
fi
fi
fi
if test "x${PBX_ZAPTEL_VLDTMF}" != "x1" -a "${USE_ZAPTEL_VLDTMF}" != "no"; then
pbxlibdir=""
# if --with-ZAPTEL_VLDTMF=DIR has been specified, use it.
45604
45605
45606
45607
45608
45609
45610
45611
45612
45613
45614
45615
45616
45617
45618
45619
45620
45621
45622
45623
45624
45625
45626
45627
45628
45629
45630
45631
45632
45633
45634
45635
45636
45637
45638
45639
45640
45641
45642
45643
45644
45645
45646
45647
45648
45649
45650
45651
45652
45653
45654
45655
45656
45657
if test "x${ZAPTEL_VLDTMF_DIR}" != "x"; then
if test -d ${ZAPTEL_VLDTMF_DIR}/lib; then
pbxlibdir="-L${ZAPTEL_VLDTMF_DIR}/lib"
else
pbxlibdir="-L${ZAPTEL_VLDTMF_DIR}"
fi
fi
pbxfuncname=""
if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
AST_ZAPTEL_VLDTMF_FOUND=yes
else
as_ac_Lib=`echo "ac_cv_lib_zaptel_${pbxfuncname}" | $as_tr_sh`
{ echo "$as_me:$LINENO: checking for ${pbxfuncname} in -lzaptel" >&5
echo $ECHO_N "checking for ${pbxfuncname} in -lzaptel... $ECHO_C" >&6; }
if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lzaptel ${pbxlibdir} $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* 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 ${pbxfuncname} ();
int
main ()
{
return ${pbxfuncname} ();
;
return 0;
}
_ACEOF
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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
(eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest$ac_exeext &&
$as_test_x conftest$ac_exeext; then
eval "$as_ac_Lib=yes"
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
eval "$as_ac_Lib=no"
fi
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
ac_res=`eval echo '${'$as_ac_Lib'}'`
{ echo "$as_me:$LINENO: result: $ac_res" >&5
echo "${ECHO_T}$ac_res" >&6; }
if test `eval echo '${'$as_ac_Lib'}'` = yes; then
AST_ZAPTEL_VLDTMF_FOUND=yes
Kevin P. Fleming
committed
else
AST_ZAPTEL_VLDTMF_FOUND=no
fi
# now check for the header.
if test "${AST_ZAPTEL_VLDTMF_FOUND}" = "yes"; then
ZAPTEL_VLDTMF_LIB="${pbxlibdir} -lzaptel "
# if --with-ZAPTEL_VLDTMF=DIR has been specified, use it.
if test "x${ZAPTEL_VLDTMF_DIR}" != "x"; then
ZAPTEL_VLDTMF_INCLUDE="-I${ZAPTEL_VLDTMF_DIR}/include"
fi
ZAPTEL_VLDTMF_INCLUDE="${ZAPTEL_VLDTMF_INCLUDE} "
if test "xzaptel.h" = "x" ; then # no header, assume found
ZAPTEL_VLDTMF_HEADER_FOUND="1"
else # check for the header
saved_cppflags="${CPPFLAGS}"
CPPFLAGS="${CPPFLAGS} ${ZAPTEL_VLDTMF_INCLUDE} "
if test "${ac_cv_header_zaptel_h+set}" = set; then
{ echo "$as_me:$LINENO: checking for zaptel.h" >&5
echo $ECHO_N "checking for zaptel.h... $ECHO_C" >&6; }
if test "${ac_cv_header_zaptel_h+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
Kevin P. Fleming
committed
fi
{ echo "$as_me:$LINENO: result: $ac_cv_header_zaptel_h" >&5
echo "${ECHO_T}$ac_cv_header_zaptel_h" >&6; }
Kevin P. Fleming
committed
# Is the header compilable?
{ echo "$as_me:$LINENO: checking zaptel.h usability" >&5
echo $ECHO_N "checking zaptel.h usability... $ECHO_C" >&6; }
Kevin P. Fleming
committed
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
Kevin P. Fleming
committed
$ac_includes_default
#include <zaptel.h>
Kevin P. Fleming
committed
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
Kevin P. Fleming
committed
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Kevin P. Fleming
committed
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
Kevin P. Fleming
committed
ac_header_compiler=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
Kevin P. Fleming
committed
ac_header_compiler=no
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Kevin P. Fleming
committed
{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
echo "${ECHO_T}$ac_header_compiler" >&6; }
Kevin P. Fleming
committed
# Is the header present?
{ echo "$as_me:$LINENO: checking zaptel.h presence" >&5
echo $ECHO_N "checking zaptel.h presence... $ECHO_C" >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
#include <zaptel.h>
Kevin P. Fleming
committed
if { (ac_try="$ac_cpp conftest.$ac_ext"
Kevin P. Fleming
committed
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Kevin P. Fleming
committed
(eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } >/dev/null && {
test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
test ! -s conftest.err
}; then
Kevin P. Fleming
committed
ac_header_preproc=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
Kevin P. Fleming
committed
ac_header_preproc=no
Kevin P. Fleming
committed
rm -f conftest.err conftest.$ac_ext
{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
echo "${ECHO_T}$ac_header_preproc" >&6; }
# So? What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
yes:no: )
{ echo "$as_me:$LINENO: WARNING: zaptel.h: accepted by the compiler, rejected by the preprocessor!" >&5
echo "$as_me: WARNING: zaptel.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel.h: proceeding with the compiler's result" >&5
echo "$as_me: WARNING: zaptel.h: proceeding with the compiler's result" >&2;}
Kevin P. Fleming
committed
ac_header_preproc=yes
;;
no:yes:* )
{ echo "$as_me:$LINENO: WARNING: zaptel.h: present but cannot be compiled" >&5
echo "$as_me: WARNING: zaptel.h: present but cannot be compiled" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel.h: check for missing prerequisite headers?" >&5
echo "$as_me: WARNING: zaptel.h: check for missing prerequisite headers?" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel.h: see the Autoconf documentation" >&5
echo "$as_me: WARNING: zaptel.h: see the Autoconf documentation" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel.h: section \"Present But Cannot Be Compiled\"" >&5
echo "$as_me: WARNING: zaptel.h: section \"Present But Cannot Be Compiled\"" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel.h: proceeding with the preprocessor's result" >&5
echo "$as_me: WARNING: zaptel.h: proceeding with the preprocessor's result" >&2;}
{ echo "$as_me:$LINENO: WARNING: zaptel.h: in the future, the compiler will take precedence" >&5
echo "$as_me: WARNING: zaptel.h: in the future, the compiler will take precedence" >&2;}
( cat <<\_ASBOX
## ------------------------------- ##
## Report this to www.asterisk.org ##
## ------------------------------- ##
_ASBOX
) | sed "s/^/$as_me: WARNING: /" >&2
Kevin P. Fleming
committed
;;
esac
{ echo "$as_me:$LINENO: checking for zaptel.h" >&5
echo $ECHO_N "checking for zaptel.h... $ECHO_C" >&6; }
if test "${ac_cv_header_zaptel_h+set}" = set; then
Kevin P. Fleming
committed
echo $ECHO_N "(cached) $ECHO_C" >&6
ac_cv_header_zaptel_h=$ac_header_preproc
{ echo "$as_me:$LINENO: result: $ac_cv_header_zaptel_h" >&5
echo "${ECHO_T}$ac_cv_header_zaptel_h" >&6; }
fi
if test $ac_cv_header_zaptel_h = yes; then
ZAPTEL_VLDTMF_HEADER_FOUND=1
else
ZAPTEL_VLDTMF_HEADER_FOUND=0
fi
CPPFLAGS="${saved_cppflags}"
fi
if test "x${ZAPTEL_VLDTMF_HEADER_FOUND}" = "x0" ; then
ZAPTEL_VLDTMF_LIB=""
ZAPTEL_VLDTMF_INCLUDE=""
else
if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
ZAPTEL_VLDTMF_LIB=""
fi
PBX_ZAPTEL_VLDTMF=1
# XXX don't know how to evaluate the description (third argument) in AC_DEFINE_UNQUOTED
cat >>confdefs.h <<_ACEOF
#define HAVE_ZAPTEL_VLDTMF 1
_ACEOF
cat >>confdefs.h <<_ACEOF
#define HAVE_ZAPTEL_VLDTMF_VERSION 80
_ACEOF
fi
fi
fi
# other case, old tonezone (0.80)
if test "x${PBX_TONEZONE}" != "x1" -a "${USE_TONEZONE}" != "no"; then
Kevin P. Fleming
committed
pbxlibdir=""
# if --with-TONEZONE=DIR has been specified, use it.
if test "x${TONEZONE_DIR}" != "x"; then
if test -d ${TONEZONE_DIR}/lib; then
pbxlibdir="-L${TONEZONE_DIR}/lib"
Kevin P. Fleming
committed
else
pbxlibdir="-L${TONEZONE_DIR}"
Kevin P. Fleming
committed
fi
fi
pbxfuncname="tone_zone_find"
if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
AST_TONEZONE_FOUND=yes
else
as_ac_Lib=`echo "ac_cv_lib_tonezone_${pbxfuncname}" | $as_tr_sh`
{ echo "$as_me:$LINENO: checking for ${pbxfuncname} in -ltonezone" >&5
echo $ECHO_N "checking for ${pbxfuncname} in -ltonezone... $ECHO_C" >&6; }
if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
Kevin P. Fleming
committed
ac_check_lib_save_LIBS=$LIBS
LIBS="-ltonezone ${pbxlibdir} ${tonezone_extra} $LIBS"
Kevin P. Fleming
committed
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
Kevin P. Fleming
committed
/* 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 ${pbxfuncname} ();
int
main ()
Kevin P. Fleming
committed
{
return ${pbxfuncname} ();
;
return 0;
}
_ACEOF
Kevin P. Fleming
committed
rm -f conftest.$ac_objext conftest$ac_exeext
Kevin P. Fleming
committed
if { (ac_try="$ac_link"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Kevin P. Fleming
committed
(eval "$ac_link") 2>conftest.er1
ac_status=$?
Kevin P. Fleming
committed
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest$ac_exeext &&
$as_test_x conftest$ac_exeext; then
eval "$as_ac_Lib=yes"
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
eval "$as_ac_Lib=no"
Kevin P. Fleming
committed
fi
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
ac_res=`eval echo '${'$as_ac_Lib'}'`
{ echo "$as_me:$LINENO: result: $ac_res" >&5
echo "${ECHO_T}$ac_res" >&6; }
if test `eval echo '${'$as_ac_Lib'}'` = yes; then
AST_TONEZONE_FOUND=yes
Kevin P. Fleming
committed
else
AST_TONEZONE_FOUND=no
Kevin P. Fleming
committed
fi
Kevin P. Fleming
committed
# now check for the header.
if test "${AST_TONEZONE_FOUND}" = "yes"; then
TONEZONE_LIB="${pbxlibdir} -ltonezone ${tonezone_extra}"
# if --with-TONEZONE=DIR has been specified, use it.
if test "x${TONEZONE_DIR}" != "x"; then
TONEZONE_INCLUDE="-I${TONEZONE_DIR}/include"
fi
TONEZONE_INCLUDE="${TONEZONE_INCLUDE} "
if test "xzaptel.h" = "x" ; then # no header, assume found
TONEZONE_HEADER_FOUND="1"
else # check for the header
saved_cppflags="${CPPFLAGS}"
CPPFLAGS="${CPPFLAGS} ${TONEZONE_INCLUDE} "
if test "${ac_cv_header_zaptel_h+set}" = set; then
{ echo "$as_me:$LINENO: checking for zaptel.h" >&5
echo $ECHO_N "checking for zaptel.h... $ECHO_C" >&6; }
if test "${ac_cv_header_zaptel_h+set}" = set; then
Kevin P. Fleming
committed
echo $ECHO_N "(cached) $ECHO_C" >&6
fi
{ echo "$as_me:$LINENO: result: $ac_cv_header_zaptel_h" >&5
echo "${ECHO_T}$ac_cv_header_zaptel_h" >&6; }
Kevin P. Fleming
committed
else
# Is the header compilable?
{ echo "$as_me:$LINENO: checking zaptel.h usability" >&5
echo $ECHO_N "checking zaptel.h usability... $ECHO_C" >&6; }
Kevin P. Fleming
committed
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
Kevin P. Fleming
committed
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
#include <zaptel.h>
Kevin P. Fleming
committed
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
Kevin P. Fleming
committed
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Kevin P. Fleming
committed
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
Kevin P. Fleming
committed
ac_header_compiler=yes