CentOS 5下freeswitch中集成使用ekho实现TTS功能二
三:以上Festival安装完成以后回到ekho安装目录:
执行./configure --enable-festival 前
更改configure
1:替换
#AC_DEFINE(ENABLE_FESTIVAL,,[Enable Festival])
#LIB_FESTIVAL="${srcdir}/lib/libFestival.a ${srcdir}/lib/libestools.a ${srcdir}/lib/libestbase.a ${srcdir}/lib/libeststring.a -lncurses"
# CFLAG_FESTIVAL="-I${srcdir}/include/festival -I${srcdir}/include/speech_tools"
else
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
as_fn_error $? "ncurses test failed
See \`config.log' for more details" "$LINENO" 5; }
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lestools" >&5
$as_echo_n "checking for main in -lestools... " >&6; }
if ${ac_cv_lib_estools_main+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lestools
$LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
main ()
{
return main ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_estools_main=yes
else
ac_cv_lib_estools_main=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_estools_main" >&5
$as_echo "$ac_cv_lib_estools_main" >&6; }
if test "x$ac_cv_lib_estools_main" = xyes; then :
cat >>confdefs.h <<_ACEOF
#define HAVE_LIBESTOOLS 1
_ACEOF
LIBS="-lestools $LIBS"
改为:
$as_echo "#define ENABLE_FESTIVAL /**/" >>confdefs.h
LIB_FESTIVAL="${srcdir}/lib/libFestival.a ${srcdir}/lib/libestools.a ${srcdir}/lib/libestbase.a ${srcdir}/lib/libeststring.a -lncurses"
CFLAG_FESTIVAL="-I${srcdir}/include/festival -I${srcdir}/include/speech_tools"
2:替换
as_fn_error $? "estool test failed
See \`config.log' for more details" "$LINENO" 5; }
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lFestival" >&5
$as_echo_n "checking for main in -lFestival... " >&6; }
if ${ac_cv_lib_Festival_main+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lFestival
$LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
main ()
{
return main ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_Festival_main=yes
else
ac_cv_lib_Festival_main=no
改为:
as_fn_error "ncurses test failed (--disable-festival to disable)
See \`config.log' for more details." "$LINENO" 5; }
3去掉:
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_Festival_main" >&5
$as_echo "$ac_cv_lib_Festival_main" >&6; }
if test "x$ac_cv_lib_Festival_main" = xyes; then :
$as_echo "#define ENABLE_FESTIVAL /**/" >>confdefs.h
LIB_FESTIVAL="-lFestival -lestbase -lestools -leststring -lncurses"
CFLAG_FESTIVAL="-I/usr/include/festival -I/usr/include/speech_tools"
else
$as_echo "#define ENABLE_FESTIVAL /**/" >>confdefs.h
LIB_FESTIVAL="${srcdir}/lib/libFestival.a ${srcdir}/lib/libestools.a ${srcdir}/lib/libestbase.a ${srcdir}/lib/libeststring.a -lncurses"
CFLAG_FESTIVAL="-I${srcdir}/include -I${srcdir}/include/festival -I${srcdir}/include/speech_tools"
else
LIB_FESTIVAL=""
CFLAG_FESTIVAL=""
Fi
4:添加:
else
with_mp3lame=no
fi
后添加
LIBS="-lasound $LIBS"
5以上更改以后:
在ekho安装目录下:
执行make
出现以下错误:
src/libekho.cpp:58:31: 错误:festival/festival.h:没有那个文件或目录
src/libekho.cpp: In member function ‘int ekho::Ekho::initFestival()’:
src/libekho.cpp:252: 错误:‘festival_initialize’ 在此作用域中尚未声明
src/libekho.cpp:257: 错误:‘strintern’ 在此作用域中尚未声明
src/libekho.cpp:257: 错误:‘siod_set_lval’ 在此作用域中尚未声明
src/libekho.cpp:261: 错误:‘festival_load_file’ 在此作用域中尚未声明
src/libekho.cpp:269: 错误:‘festival_tidy_up’ 在此作用域中尚未声明
src/libekho.cpp: In member function ‘int ekho::Ekho::writeToSonicStream(short int*, int, bool, bool)’:
src/libekho.cpp:752: 警告:当转换到 ‘short int’ (从 ‘double’)时
src/libekho.cpp:762: 警告:当转换到 ‘int’ (从 ‘float’)时
src/libekho.cpp: In member function ‘const char* ekho::Ekho::getPcmFromFestival(std::string, int&)’:
src/libekho.cpp:1203: 错误:‘festival_eval_command’ 在此作用域中尚未声明
src/libekho.cpp:1218: 错误:‘EST_Wave’ 在此作用域中尚未声明
src/libekho.cpp:1218: 错误:expected `;' before ‘wave’
src/libekho.cpp:1219: 错误:‘wave’ 在此作用域中尚未声明
src/libekho.cpp:1219: 错误:‘festival_text_to_wave’ 在此作用域中尚未声明
src/libekho.cpp:1225: 错误:‘EST_TVector’ 在此作用域中尚未声明
src/libekho.cpp:1225: 错误:expected primary-expression before ‘short’
src/libekho.cpp:1225: 错误:expected `;' before ‘short’
src/libekho.cpp:1226: 错误:‘tvector’ 在此作用域中尚未声明
make[1]: *** [src/libekho_a-libekho.o] 错误 1
make[1]: Leaving directory `/home/new_uucc_soft/ekho-6.0'
make: *** [all] 错误 2
解决方法:
用命令:mkdir /usr/include/festival
cd /usr/include/festival
拷贝festival.h fngram.h intonation.h lexicon.h Makefile ModuleDescription.h modules.h module_support.h Phone.h text.h
到festival文件夹下
6.回到ekho安装目录下:
执行make:
出现:
g++: ./lib/libFestival.a: No such file or directory
g++: ./lib/libestools.a: No such file or directory
g++: ./lib/libestbase.a: No such file or directory
g++: ./lib/libeststring.a: No such file or directory
make[1]: *** [test_ekho] 错误 1
解决办法:
在ekho安装目录下执行:
cp lib32 lib
在festival和speech_tools的安装目录下面将.a文件
/festival/src/lib/中的libFestival.a拷贝到ekho安装目录下的lib中并覆盖
/speech_tools/lib/中的libestools.a libestbase.a libeststring.a拷贝到ekho安装目录下的lib中并覆盖
最后,执行make && make install ,安装完成
CentOS 5下freeswitch中集成使用ekho实现TTS功能二的更多相关文章
- CentOS 5下freeswitch中集成使用ekho实现TTS功能三
四:在freeswitch中调用ekho 注:在测试过程中该语音包好像没用 FreeSWITCH 中文语音包测试版fssounds.zip 在/usr/local/freeswitch/sounds/ ...
- freeswitch中集成使用ekho实现TTS功能一
Linux下安装freeswitch并集成ekho实现TTS 1. linux下安装freeswitch就不多介绍了,具体链接网址: http://www.8000hz.com/archives/14 ...
- AngularJS进阶(十九)在AngularJS应用中集成百度地图实现定位功能
在AngularJS应用中集成百度地图实现定位功能 注:请点击此处进行充电! 前言 根据项目需求,需要实现手机定位功能,考虑到百度业务的强大能力,遂决定使用百度地图第三方服务. 添加第三方模块的步骤与 ...
- 记录下项目中常用到的JavaScript/JQuery代码二(大量实例)
记录下项目中常用到的JavaScript/JQuery代码一(大量实例) 1.input输入框监听变化 <input type="text" style="widt ...
- 实战MySQL集群,试用CentOS 6下的MariaDB-Galera集成版
说起mysql的集群估计很多人会首先想起mysql自带的replication或者mysql-mmm.mysql-mmm其实也是基于mysql自带的replication的,不过封装的更好用一些,但是 ...
- windows下openresty中使用lua做接口转发、二次封装等
需求:根据客户需求,可以在ngx下 通过lua做接口二次封装再次转发给用户或第三方 场景:对返回值有要求的.接口屏蔽字段.或做一些业务上的验证等 1.windows直接下载openresty 解压即可 ...
- 现有项目中集成Flutter
本文列举了项目开发使用Flutter会遇到的问题,以及如何使用Flutter module在现有项目中集成Flutter,并对其原理进行了分析. 最近在做的一个商业项目,完全的使用Flutter编写的 ...
- 怎么在我们的App中集成条码扫描功能?
现在很多App都有条码扫描功能,有的手机比如某米在照相机中集成了条码扫描功能,但是还有一部分手机没有这样的集成,比如韩国某星,需要自己下载一个条码扫描App.今天我们就来看看怎么在自己的App中集成一 ...
- windows下VMware-workstation中安装CentOS
windows下VMware-workstation中安装CentOS,可以分两部分,安装虚拟机和安装CentOS虚拟机.具体步骤如下: 一.安装虚拟机 1.安装VMware-workstation, ...
随机推荐
- js模板引擎artTemplate快速上手
腾讯的artTemplate 1,编写模板 (采用script标签并带有属性id和type="text/html") <script id="test" ...
- java中.currentTimeMillis的用法和含义
用法:可以用法获取当前时间的毫秒数,可以通过毫秒数进行时间比较,时间转化以及时间格式化等.public class SystemTime {public static void main(String ...
- 如需在 HTML 页面中插入 JavaScript,请使用 <script> 标签。
如需在 HTML 页面中插入 JavaScript,请使用 <script> 标签. <script> 和 </script> 会告诉 JavaScript 在何处 ...
- hdu 3062+1824(2-sat入门)
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=3062 思路:根据矛盾关系连边(如果a与b矛盾,则连边a'->b,b'->a),然后强连通缩 ...
- MySQL左连接查询
1.语法: select 字段列表 from table1 别名1 left join table2 别名2 on 连接条件 [where 子句]
- poj1742
Coins Time Limit: 3000MS Memory Limit: 30000K Total Submissions: 33998 Accepted: 11554 Descripti ...
- Android输入法的显示与隐藏
显示输入法: public void ShowSoftInput(View v) { // v 接受输入的控件 mInputMethodManager = (InputMethodManager) ( ...
- redis集群报错,(error) MOVED 15495 127.0.0.1:7003
节点会对命令请求进行分析和key的slot计算,并且会查找这个命令所要处理的键所在的槽.如果要查找的哈希槽正好就由接收到命令的节点负责处理, 那么节点就直接执行这个命令. 另一方面, 如果所查 ...
- 查看虚拟机里的Centos7的IP(四)
这里之所以是查看下IP ,是我们后面要建一个Centos远程工具Xshell 连接Centos的时候,需要IP地址,所以我们这里先 学会查看虚拟机里的Centos7的IP地址 首先我们登录操作系统 用 ...
- Linux学习拾遗
一.安装iso文件 首先建立一个目录作为挂载点:# mkdir /mnt/iso 获得root权限然后使用下面的参数挂载ISO映像文件:# mount -t iso9660 /path/image.i ...