mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-28 13:16:41 +00:00
new package: add package 'espeak' (initial)
Signed-off-by: Stephan Raue <stephan@openelec.tv>
This commit is contained in:
parent
b5a9271e03
commit
70391fbdf0
53
packages/audio/espeak/package.mk
Normal file
53
packages/audio/espeak/package.mk
Normal file
@ -0,0 +1,53 @@
|
|||||||
|
################################################################################
|
||||||
|
# This file is part of OpenELEC - http://www.openelec.tv
|
||||||
|
# Copyright (C) 2009-2014 Stephan Raue (stephan@openelec.tv)
|
||||||
|
#
|
||||||
|
# OpenELEC is free software: you can redistribute it and/or modify
|
||||||
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
# the Free Software Foundation, either version 2 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
|
#
|
||||||
|
# OpenELEC is distributed in the hope that it will be useful,
|
||||||
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
# GNU General Public License for more details.
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License
|
||||||
|
# along with OpenELEC. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
################################################################################
|
||||||
|
|
||||||
|
PKG_NAME="espeak"
|
||||||
|
PKG_VERSION="1.48.04-source"
|
||||||
|
PKG_REV="1"
|
||||||
|
PKG_ARCH="any"
|
||||||
|
PKG_LICENSE="GPL"
|
||||||
|
PKG_SITE="http://espeak.sourceforge.net/"
|
||||||
|
PKG_URL="http://downloads.sourceforge.net/$PKG_NAME/$PKG_NAME-$PKG_VERSION.zip"
|
||||||
|
PKG_SOURCE_DIR="$PKG_NAME/$PKG_NAME-$PKG_VERSION"
|
||||||
|
PKG_DEPENDS_TARGET="toolchain"
|
||||||
|
PKG_PRIORITY="optional"
|
||||||
|
PKG_SECTION="audio"
|
||||||
|
PKG_SHORTDESC="Text to Speech engine for English, with support for other languages"
|
||||||
|
PKG_LONGDESC="Text to Speech engine for English, with support for other languages"
|
||||||
|
|
||||||
|
PKG_IS_ADDON="no"
|
||||||
|
PKG_AUTORECONF="no"
|
||||||
|
|
||||||
|
pre_make_target() {
|
||||||
|
cp src/portaudio19.h src/portaudio.h
|
||||||
|
}
|
||||||
|
|
||||||
|
make_target() {
|
||||||
|
make -C src \
|
||||||
|
CXXFLAGS="$CXXFLAGS" \
|
||||||
|
LDFLAGS="$LDFLAGS" \
|
||||||
|
AUDIO=""
|
||||||
|
}
|
||||||
|
|
||||||
|
makeinstall_target() {
|
||||||
|
make -C src \
|
||||||
|
CXXFLAGS="$CXXFLAGS" \
|
||||||
|
LDFLAGS="$LDFLAGS" \
|
||||||
|
AUDIO="" \
|
||||||
|
DESTDIR=$INSTALL install
|
||||||
|
}
|
23
packages/audio/espeak/patches/espeak-1.47-ftbs-ld-libm.patch
Normal file
23
packages/audio/espeak/patches/espeak-1.47-ftbs-ld-libm.patch
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
diff --git a/src/Makefile b/src/Makefile
|
||||||
|
index f04b4c4..b8d4b19 100644
|
||||||
|
--- a/src/Makefile
|
||||||
|
+++ b/src/Makefile
|
||||||
|
@@ -83,15 +83,15 @@ libespeak_SOURCES = speak_lib.cpp compiledict.cpp dictionary.cpp intonation.cpp
|
||||||
|
|
||||||
|
SRCS1=$(speak_SOURCES)
|
||||||
|
OBJS1=$(patsubst %.cpp,%.o,$(SRCS1))
|
||||||
|
-LIBS1=-lstdc++ $(LIB_AUDIO) -lpthread $(EXTRA_LIBS)
|
||||||
|
+LIBS1=-lstdc++ -lm $(LIB_AUDIO) -lpthread $(EXTRA_LIBS)
|
||||||
|
|
||||||
|
SRCS2=$(libespeak_SOURCES)
|
||||||
|
OBJS2=$(patsubst %.cpp,x_%.o,$(SRCS2))
|
||||||
|
-LIBS2=-lstdc++ $(LIB_AUDIO) -lpthread
|
||||||
|
+LIBS2=-lstdc++ -lm $(LIB_AUDIO) -lpthread
|
||||||
|
|
||||||
|
SRCS3 = espeak.cpp
|
||||||
|
OBJS3=$(patsubst %.cpp,%.o,$(SRCS3))
|
||||||
|
-LIBS3=-lstdc++ -L . -lespeak
|
||||||
|
+LIBS3=-lstdc++ -lm -L . -lespeak
|
||||||
|
|
||||||
|
CXXFLAGS=-O2
|
||||||
|
|
23
packages/audio/espeak/patches/espeak-1.47-wav-close.patch
Normal file
23
packages/audio/espeak/patches/espeak-1.47-wav-close.patch
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
diff --git a/src/espeak.cpp b/src/espeak.cpp
|
||||||
|
index 00f93c1..4ad42e8 100644
|
||||||
|
--- a/src/espeak.cpp
|
||||||
|
+++ b/src/espeak.cpp
|
||||||
|
@@ -281,10 +281,7 @@ static int SynthCallback(short *wav, int numsamples, espeak_EVENT *events)
|
||||||
|
if(quiet) return(0); // -q quiet mode
|
||||||
|
|
||||||
|
if(wav == NULL)
|
||||||
|
- {
|
||||||
|
- CloseWavFile();
|
||||||
|
return(0);
|
||||||
|
- }
|
||||||
|
|
||||||
|
while(events->type != 0)
|
||||||
|
{
|
||||||
|
@@ -805,5 +802,7 @@ int main (int argc, char **argv)
|
||||||
|
|
||||||
|
if(f_phonemes_out != stdout)
|
||||||
|
fclose(f_phonemes_out); // needed for WinCE
|
||||||
|
+ CloseWavFile();
|
||||||
|
+ espeak_Terminate();
|
||||||
|
return(0);
|
||||||
|
}
|
@ -88,6 +88,11 @@ else
|
|||||||
XBMC_PULSEAUDIO="--disable-pulse"
|
XBMC_PULSEAUDIO="--disable-pulse"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ "$ESPEAK_SUPPORT" = yes ]; then
|
||||||
|
# for espeak support
|
||||||
|
PKG_DEPENDS_TARGET="$PKG_DEPENDS_TARGET espeak"
|
||||||
|
fi
|
||||||
|
|
||||||
if [ "$CEC_SUPPORT" = yes ]; then
|
if [ "$CEC_SUPPORT" = yes ]; then
|
||||||
# for CEC support
|
# for CEC support
|
||||||
PKG_DEPENDS_TARGET="$PKG_DEPENDS_TARGET libcec"
|
PKG_DEPENDS_TARGET="$PKG_DEPENDS_TARGET libcec"
|
||||||
|
@ -152,6 +152,9 @@
|
|||||||
# build and install PulseAudio support (yes / no)
|
# build and install PulseAudio support (yes / no)
|
||||||
PULSEAUDIO_SUPPORT="no"
|
PULSEAUDIO_SUPPORT="no"
|
||||||
|
|
||||||
|
# build and install espeak support (yes / no)
|
||||||
|
ESPEAK_SUPPORT="yes"
|
||||||
|
|
||||||
# build and install with non-free support
|
# build and install with non-free support
|
||||||
# (RAR compression support in XBMC) (yes / no)
|
# (RAR compression support in XBMC) (yes / no)
|
||||||
NONFREE_SUPPORT="yes"
|
NONFREE_SUPPORT="yes"
|
||||||
|
@ -153,6 +153,9 @@
|
|||||||
# build and install PulseAudio support (yes / no)
|
# build and install PulseAudio support (yes / no)
|
||||||
PULSEAUDIO_SUPPORT="no"
|
PULSEAUDIO_SUPPORT="no"
|
||||||
|
|
||||||
|
# build and install espeak support (yes / no)
|
||||||
|
ESPEAK_SUPPORT="yes"
|
||||||
|
|
||||||
# build and install with non-free support
|
# build and install with non-free support
|
||||||
# (RAR compression support in XBMC) (yes / no)
|
# (RAR compression support in XBMC) (yes / no)
|
||||||
NONFREE_SUPPORT="yes"
|
NONFREE_SUPPORT="yes"
|
||||||
|
@ -152,6 +152,9 @@
|
|||||||
# build and install PulseAudio support (yes / no)
|
# build and install PulseAudio support (yes / no)
|
||||||
PULSEAUDIO_SUPPORT="no"
|
PULSEAUDIO_SUPPORT="no"
|
||||||
|
|
||||||
|
# build and install espeak support (yes / no)
|
||||||
|
ESPEAK_SUPPORT="yes"
|
||||||
|
|
||||||
# build and install with non-free support
|
# build and install with non-free support
|
||||||
# (RAR compression support in XBMC) (yes / no)
|
# (RAR compression support in XBMC) (yes / no)
|
||||||
NONFREE_SUPPORT="yes"
|
NONFREE_SUPPORT="yes"
|
||||||
|
@ -153,6 +153,9 @@
|
|||||||
# build and install PulseAudio support (yes / no)
|
# build and install PulseAudio support (yes / no)
|
||||||
PULSEAUDIO_SUPPORT="no"
|
PULSEAUDIO_SUPPORT="no"
|
||||||
|
|
||||||
|
# build and install espeak support (yes / no)
|
||||||
|
ESPEAK_SUPPORT="yes"
|
||||||
|
|
||||||
# build and install with non-free support
|
# build and install with non-free support
|
||||||
# (RAR compression support in XBMC) (yes / no)
|
# (RAR compression support in XBMC) (yes / no)
|
||||||
NONFREE_SUPPORT="yes"
|
NONFREE_SUPPORT="yes"
|
||||||
|
@ -147,6 +147,9 @@
|
|||||||
# build and install PulseAudio support (yes / no)
|
# build and install PulseAudio support (yes / no)
|
||||||
PULSEAUDIO_SUPPORT="no"
|
PULSEAUDIO_SUPPORT="no"
|
||||||
|
|
||||||
|
# build and install espeak support (yes / no)
|
||||||
|
ESPEAK_SUPPORT="yes"
|
||||||
|
|
||||||
# build and install with non-free support
|
# build and install with non-free support
|
||||||
# (RAR compression support in XBMC) (yes / no)
|
# (RAR compression support in XBMC) (yes / no)
|
||||||
NONFREE_SUPPORT="yes"
|
NONFREE_SUPPORT="yes"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user