bridge_softmix_binaural: Enable FFTW3 in Solaris 11.

ASTERISK-27939

Change-Id: Ice5640e08385a64a0a6555deaccd91e86bca154f
This commit is contained in:
Alexander Traud 2018-06-23 11:50:00 +02:00
parent efe2ba43ca
commit 804d931f27
3 changed files with 14 additions and 14 deletions

View File

@ -193,12 +193,12 @@ int init_convolve_channel(struct convolve_channel *channel, unsigned int hrtf_le
float *hrir;
/* Prepare FFTW. */
channel->fftw_in = fftw_alloc_real(hrtf_len + 1);
channel->fftw_in = (double *) fftw_malloc(sizeof(double) * (hrtf_len + 1));
if (channel->fftw_in == NULL) {
return -1;
}
channel->fftw_out = fftw_alloc_real(hrtf_len + 1);
channel->fftw_out = (double *) fftw_malloc(sizeof(double) * (hrtf_len + 1));
if (channel->fftw_out == NULL) {
fftw_free(channel->fftw_in);
return -1;
@ -239,7 +239,7 @@ int init_convolve_channel(struct convolve_channel *channel, unsigned int hrtf_le
}
fftw_execute(channel->fftw_plan);
channel->hrtf = fftw_alloc_real(hrtf_len);
channel->hrtf = (double *) fftw_malloc(sizeof(double) * hrtf_len);
if (channel->hrtf == NULL) {
fftw_free(channel->fftw_in);
fftw_free(channel->fftw_out);

20
configure vendored
View File

@ -28201,9 +28201,9 @@ if test "x${PBX_FFTW3}" != "x1" -a "${USE_FFTW3}" != "no"; then
ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
CFLAGS="${CFLAGS} "
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftw_alloc_real in -lfftw3" >&5
$as_echo_n "checking for fftw_alloc_real in -lfftw3... " >&6; }
if ${ac_cv_lib_fftw3_fftw_alloc_real+:} false; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftw_malloc in -lfftw3" >&5
$as_echo_n "checking for fftw_malloc in -lfftw3... " >&6; }
if ${ac_cv_lib_fftw3_fftw_malloc+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
@ -28217,27 +28217,27 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
#ifdef __cplusplus
extern "C"
#endif
char fftw_alloc_real ();
char fftw_malloc ();
int
main ()
{
return fftw_alloc_real ();
return fftw_malloc ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_fftw3_fftw_alloc_real=yes
ac_cv_lib_fftw3_fftw_malloc=yes
else
ac_cv_lib_fftw3_fftw_alloc_real=no
ac_cv_lib_fftw3_fftw_malloc=no
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw3_fftw_alloc_real" >&5
$as_echo "$ac_cv_lib_fftw3_fftw_alloc_real" >&6; }
if test "x$ac_cv_lib_fftw3_fftw_alloc_real" = xyes; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw3_fftw_malloc" >&5
$as_echo "$ac_cv_lib_fftw3_fftw_malloc" >&6; }
if test "x$ac_cv_lib_fftw3_fftw_malloc" = xyes; then :
AST_FFTW3_FOUND=yes
else
AST_FFTW3_FOUND=no

View File

@ -2389,7 +2389,7 @@ AST_EXT_LIB_CHECK([PRI_REVERSE_CHARGE], [pri], [pri_sr_set_reversecharge], [libp
# ------------------------------------^
AST_EXT_LIB_CHECK([RESAMPLE], [resample], [resample_open], [libresample.h], [-lm])
AST_EXT_LIB_CHECK([FFTW3], [fftw3], [fftw_alloc_real], [fftw3.h])
AST_EXT_LIB_CHECK([FFTW3], [fftw3], [fftw_malloc], [fftw3.h])
AST_EXT_LIB_CHECK([SNDFILE], [sndfile], [sf_open], [sndfile.h])
AST_C_COMPILE_CHECK([SPANDSP], [