当前位置: 首页 > 工具软件 > Ekho > 使用案例 >

linux平台ekho,How to Install Ekho

聂翼
2023-12-01

How to Install Ekho (for Linux and Raspberry Pi)

(updated on Nov 21, 2017)

To build from source, following commands will work if you are lucky enough.

$ sudo apt-get install libsndfile1-dev libpulse-dev libncurses5-dev libmp3lame-dev libespeak-dev

$ tar xJvf ekho-xxx.tar.xz

$ cd ekho-xxx

$ ./configure

$ make

$ sudo make install

$ ekho "hello 123"

For Raspberry Pi, please use Ubuntu MATE version since Jessie version has something wrong with PulseAudio.

Please refer to file INSTALL for more information.

If you want to make Ekho work with Speech-dispatcher, which is the API for screen reader like Orca, you should `configure --enable-speechd`.

For usage of ekho, please try:

$ ekho -h

CENTOS6安装Ekho的方法

CentOS 6.9 x86_64 下安装的历史命令如下:

# 添加 SCL 和 EPEL 软件仓库

yum install centos-release-scl epel-release

# 安装 GCC 5 和编译 ekho 的开发库

yum install devtoolset-4-gcc* libsndfile-devel.x86_64 pulseaudio-libs-devel.x86_64 ncurses-devel.x86_64 espeak-devel.x86_64 lame-devel.x86_64

# 使用 SCL 启动 shell

scl enable devtoolset-4 bash

# 验证 GCC 版本

# which gcc

# gcc --version

# [可选] 设置 GCC 编译器选项

export CFLAGS='-O2 -g -pipe -Wall -fexceptions -fno-strict-aliasing -fstack-protector -m64 -mtune=generic -fPIC'

# 生成 MakeFile,编译,安装

./configure --prefix=/opt/app/ekho && make -j 8 && make install

# 设置 ekho 相关环境变量

cat > /etc/profile.d/ekho_env.sh << EOF

#!/bin/bash

export PATH=\${PATH}:/opt/app/ekho/bin

export EKHO_DATA_PATH=/opt/app/ekho/share/ekho-data/

EOF

# 退出 SCL shell

exit

由于 GCC 5 需要配置 SCL,但是 CentOS 6.5 及更高版本才支持 SCL,所以低于 CentOS 6.5 的版本就要使用其他办法了。

 类似资料: