ububtu 平台 AVS搭建

原文:
Ubuntu Linux Quick Start Guide

        • 1、在Ubuntu 使用AVS SDK 搭建 Alexa
        • 2、创建安全配置文件
        • 3、在ubuntu 上配置相关环境

1、在Ubuntu 使用AVS SDK 搭建 Alexa

调用Alexa SDK ,在ubuntu 上模拟Alexa

2、创建安全配置文件

1)登录亚马逊
2)然后按照下图填写
ububtu 平台 AVS搭建_第1张图片

ububtu 平台 AVS搭建_第2张图片

3)然后进入这个界面创建一个client id

ububtu 平台 AVS搭建_第3张图片

4)然后登录这个网址
https://developer.amazon.com/lwa/sp/overview.html
选择你刚刚创建的那个 profile
点击 Confirm
ububtu 平台 AVS搭建_第4张图片

3、在ubuntu 上配置相关环境

1)sudo apt-get update && sudo apt-get upgrade -y
2)mkdir sdk-folder && cd sdk-folder && mkdir sdk-build sdk-source third-party application-necessities
3)sudo apt-get install -y git gcc cmake openssl clang-format
4)sudo apt-get install -y openssl libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev gstreamer1.0-plugins-good libgstreamer-plugins-good1.0-dev libgstreamer-plugins-bad1.0-dev gstreamer1.0-libav pulseaudio doxygen libsqlite3-dev repo libasound2-dev
5)下载安装 Cmake
(1)wget https://cmake.org/files/v3.8/cmake-3.8.0-rc1.tar.gz
(2)tar -xvf cmake-3.8.0-rc1.tar.gz
(3)cd cmake-3.8.0-rc1/
(4)./bootstrap && make && sudo make install

(5)wget https://github.com/nghttp2/nghttp2/releases/download/v1.19.0/nghttp2-1.19.0.tar.gz
(6)tar -xvf nghttp2-1.19.0.tar.gz
(7)cd nghttp2-1.19.0
(9)autoreconf -i
(10)sudo apt-get update && sudo apt-get install g++ make binutils autoconf automake autotools-dev libtool pkg-config zlib1g-dev libcunit1-dev libssl-dev libxml2-dev libev-dev libevent-dev -y
(11)automake
(12)autoconf
(13)./configure –prefix=$WD/nghttp2/
(14)make
(15)sudo make install

(16) wget https://tls.mbed.org/download/mbedtls-2.4.0-apache.tgz
(17) tar -xvf mbedtls-2.4.0-apache.tgz
(18) cd mbedtls-2.4.0/
(19) Build with CMake:
cmake -DCMAKE_INSTALL_PREFIX=$WD/mbedtls/ -DUSE_SHARED_MBEDTLS_LIBRARY=On
(20) make
(21) sudo make install

(22) wget https://curl.haxx.se/download/curl-7.53.0.tar.gz
tar -xvf curl-7.53.0.tar.gz
(23) cd curl-7.53.0/
(24) LIBS=”-lpthread” LDFLAGS=”-Wl,-R WD/mbedtls/lib"./configurewithnghttp2= W D / m b e d t l s / l i b " . / c o n f i g u r e − − w i t h − n g h t t p 2 = WD/nghttp2/ –without-ssl –with-mbedtls= WD/mbedtlsprefix= W D / m b e d t l s − − p r e f i x = WD/curl/
(25) The configuration summary should be printed to your terminal. Make sure that SSL support (mbed TLS) and HTTP/2 support (nghttp2) are enabled.
(26) make
(27) sudo make install
(28)Test curl:

curl -I https://nghttp2.org/

If the request succeeds, you will see a message like this:

HTTP/2 200
date: Fri, 15 Dec 2017 18:13:26 GMT
content-type: text/html
last-modified: Sat, 25 Nov 2017 14:02:51 GMT
etag: “5a19780b-19e1”
accept-ranges: bytes
content-length: 6625
x-backend-header-rtt: 0.001021
strict-transport-security: max-age=31536000
server: nghttpx
via: 2 nghttpx
x-frame-options: SAMEORIGIN
x-xss-protection: 1; mode=block
x-content-type-options: nosniff

(29) cd ~/sdk-folder/third-party
(30)wget -c http://www.portaudio.com/archives/pa_stable_v190600_20161030.tgz && tar zxf pa_stable_v190600_20161030.tgz && cd portaudio && ./configure –without-jack && make

(31)cd /{HOME}/sdk-folder/sdk-build && cmake /{HOME}/sdk-folder/sdk-source/avs-device-sdk -DSENSORY_KEY_WORD_DETECTOR=OFF -DGSTREAMER_MEDIA_PLAYER=ON -DPORTAUDIO=ON -DPORTAUDIO_LIB_PATH=/{HOME}/sdk-folder/third-party/portaudio/lib/.libs/libportaudio.a -DPORTAUDIO_INCLUDE_DIR=/{HOME}/sdk-folder/third-party/portaudio/include && make

使用绝对路径:
cd /home/lum/sdk-folder/sdk-build && cmake /home/lum/sdk-folder/sdk-source/avs-device-sdk-master -DSENSORY_KEY_WORD_DETECTOR=OFF -DGSTREAMER_MEDIA_PLAYER=ON -DPORTAUDIO=ON -DPORTAUDIO_LIB_PATH=/home/lum/sdk-folder/third-party/portaudio/lib/.libs/libportaudio.a -DPORTAUDIO_INCLUDE_DIR=/home/lum/sdk-folder/third-party/portaudio/include && make

(32)~/sdk-folder/sdk-build/Integration/AlexaClientSDKConfig.json 记事本打开,添加Client ID and Product ID 和一些数据库信息

(33)

待续“““

你可能感兴趣的:(Android,智能语音,alexa)