added my Recipes

This commit is contained in:
2024-07-11 14:16:35 +02:00
parent 38bc4f53ac
commit 09b621d929
7118 changed files with 525762 additions and 3 deletions

View File

@@ -0,0 +1,68 @@
DESCRIPTION = "eSpeak is a compact open source software speech synthesizer"
SECTION = "base"
LICENSE = "GPL-3.0-only"
LIC_FILES_CHKSUM = "file://License.txt;md5=cb7a20edb4c9f5f478de6523dcd7362c"
SRC_URI = "http://downloads.sourceforge.net/espeak/espeak-1.48.04-source.zip \
file://0001-Fix-build-of-shared-library-on-architectures-needing.patch \
file://0002-tr_languages-cast-string_ordinal-init-values.patch \
file://0001-Drop-using-register-keyword-for-storage-classifier.patch \
"
SRC_URI[md5sum] = "cadd7482eaafe9239546bdc09fa244c3"
SRC_URI[sha256sum] = "bf9a17673adffcc28ff7ea18764f06136547e97bbd9edf2ec612f09b207f0659"
S = "${WORKDIR}/espeak-${PV}-source"
DEPENDS = "portaudio-v19 qemu-helper-native"
inherit siteinfo qemu
CXXFLAGS += "-DUSE_PORTAUDIO"
TARGET_CC_ARCH += "${LDFLAGS}"
FILES:${PN} += "${datadir}/espeak-data"
do_configure() {
# "speak" binary, a TTS engine, uses portaudio in either APIs V18 or V19, use V19
install -m 0644 "${S}/src/portaudio19.h" "${S}/src/portaudio.h"
}
do_compile() {
cd src
oe_runmake
cd "${S}/platforms/big_endian"
qemu_binary="${@qemu_wrapper_cmdline(d, '${STAGING_DIR_TARGET}', ['${S}/platforms/big_endian', '${STAGING_DIR_TARGET}${base_libdir}'])}"
cat >qemuwrapper <<EOF
#!/bin/sh
$qemu_binary "\$@"
EOF
chmod +x qemuwrapper
sed -i '/^ *CC *=/d' Makefile
# Fixing byte order of phoneme data files
if [ "${SITEINFO_ENDIANNESS}" = "be" ]; then
sed -i 's/\(.*BYTE_ORDER\)/#undef BYTE_ORDER\n#define BYTE_ORDER BIG_ENDIAN\n\1/' espeak-phoneme-data.c
else
sed -i 's/\(.*BYTE_ORDER\)/#undef BYTE_ORDER\n#define BYTE_ORDER LITTLE_ENDIAN\n\1/' espeak-phoneme-data.c
fi
oe_runmake
./qemuwrapper ./espeak-phoneme-data "${S}/espeak-data" "." "${S}/espeak-data/phondata-manifest"
cp -f phondata phonindex phontab "${S}/espeak-data"
}
do_install() {
install -d ${D}${bindir}
install -d ${D}${libdir}
install -d ${D}${includedir}/espeak
install -d ${D}${datadir}/espeak-data
# we do not ship "speak" binary though.
install -m 0755 ${S}/src/espeak ${D}${bindir}
install -m 0644 ${S}/src/speak_lib.h ${D}${includedir}/espeak/
ln -sf espeak/espeak.h ${D}${includedir}/
oe_libinstall -so -C src libespeak ${D}${libdir}
cp -R --no-dereference --preserve=mode,links ${S}/espeak-data/* ${D}${datadir}/espeak-data
}
RDEPENDS:${PN} = "portaudio-v19"

View File

@@ -0,0 +1,38 @@
From bad6131463275bd8013a82c28fb0b27e882bc801 Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Wed, 18 Jan 2023 16:07:35 -0800
Subject: [PATCH] Drop using 'register' keyword for storage classifier
Its gone from C++17 and newer
Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
src/klatt.cpp | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/klatt.cpp b/src/klatt.cpp
index b15f77c..9c51bc5 100755
--- a/src/klatt.cpp
+++ b/src/klatt.cpp
@@ -167,7 +167,7 @@ Output = (rnz.a * input) + (rnz.b * oldin1) + (rnz.c * oldin2)
#ifdef deleted
static double antiresonator(resonator_ptr r, double input)
{
- register double x = (double)r->a * (double)input + (double)r->b * (double)r->p1 + (double)r->c * (double)r->p2;
+ double x = (double)r->a * (double)input + (double)r->b * (double)r->p1 + (double)r->c * (double)r->p2;
r->p2 = (double)r->p1;
r->p1 = (double)input;
return (double)x;
@@ -176,7 +176,7 @@ static double antiresonator(resonator_ptr r, double input)
static double antiresonator2(resonator_ptr r, double input)
{
- register double x = (double)r->a * (double)input + (double)r->b * (double)r->p1 + (double)r->c * (double)r->p2;
+ double x = (double)r->a * (double)input + (double)r->b * (double)r->p1 + (double)r->c * (double)r->p2;
r->p2 = (double)r->p1;
r->p1 = (double)input;
--
2.39.1

View File

@@ -0,0 +1,31 @@
From 08a464e2b6bd31bb2bf4e258ebfa9b9d65805abf Mon Sep 17 00:00:00 2001
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Date: Fri, 27 Nov 2015 15:17:02 +0100
Subject: [PATCH] Fix build of shared library on architectures needing -fPIC
Certain architectures, like Sparc and Sparc64 require objects to be
built with -fPIC (and not just -fpic) to be usable in shared
libraries. On other architectures, -fPIC is the same as -fpic so this
patch doesn't affect such architectures.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
---
src/Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/Makefile b/src/Makefile
index 95fe549..c293611 100755
--- a/src/Makefile
+++ b/src/Makefile
@@ -110,7 +110,7 @@ $(BIN2_NAME): $(OBJS3) $(LIB_NAME)
x_%.o: %.cpp
- $(CXX) $(CXXFLAGS) $(USE_AUDIO) -D PATH_ESPEAK_DATA=\"$(DATADIR)\" -Wall -fpic -fvisibility=hidden -pedantic \
+ $(CXX) $(CXXFLAGS) $(USE_AUDIO) -D PATH_ESPEAK_DATA=\"$(DATADIR)\" -Wall -fPIC -fvisibility=hidden -pedantic \
-I. -D LIBRARY -c -fno-exceptions $< -o x_$*.o
$(LIB_NAME): $(OBJS2)
--
2.6.3

View File

@@ -0,0 +1,34 @@
From 451330d09a6a3500b40bc4f5896ba790ab46cd6c Mon Sep 17 00:00:00 2001
From: Romain Naour <romain.naour@gmail.com>
Date: Sun, 15 Jan 2017 19:37:31 +0100
Subject: [PATCH 2/2] tr_languages: cast string_ordinal init values
On some architecture, "char" is signed (x86_64, nios2...) so the
compiler try to convert int 0xc2 and 0xba to a signed char.
This is an error since gcc6 (Wnarrowing).
Fixes:
http://autobuild.buildroot.net/results/bae/baef9888b1979d18171668a675985e3f3b45fda6
Upstream-Status: Pending [imported from BR]
Signed-off-by: Romain Naour <romain.naour@gmail.com>
---
src/tr_languages.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/tr_languages.cpp b/src/tr_languages.cpp
index 5c80286..dbc6e36 100644
--- a/src/tr_languages.cpp
+++ b/src/tr_languages.cpp
@@ -200,7 +200,7 @@ static const unsigned short chars_ignore_zwnj_hyphen[] = {
0x200d, 1, // zero width joiner
0, 0 };
-const char string_ordinal[] = {0xc2,0xba,0}; // masculine ordinal character, UTF-8
+const char string_ordinal[] = {(char)0xc2,(char)0xba,0}; // masculine ordinal character, UTF-8
static Translator* NewTranslator(void)
--
2.9.3