aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2016-11-02 17:16:25 +0200
committerTimo Teräs <timo.teras@iki.fi>2016-11-02 17:16:40 +0200
commit4839e670592bcf73f73af3ef6d6140dada2f1f34 (patch)
treec77c121172e075c869323007c468a6005c5fe595
parent8acdc1def3ab26094585b1a84271c0dfb09c7c34 (diff)
main/espeak: fix build
-rw-r--r--main/espeak/APKBUILD21
-rw-r--r--main/espeak/fix-narrowing.patch23
2 files changed, 36 insertions, 8 deletions
diff --git a/main/espeak/APKBUILD b/main/espeak/APKBUILD
index c94e503ac6a..ffa6a1ec2f4 100644
--- a/main/espeak/APKBUILD
+++ b/main/espeak/APKBUILD
@@ -1,7 +1,7 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=espeak
pkgver=1.48.04
-pkgrel=0
+pkgrel=1
pkgdesc="Speech synthesizer for English and other languages"
url="http://espeak.sourceforge.net/"
arch="all"
@@ -9,20 +9,25 @@ license="GPL3"
subpackages="$pkgname-dev"
depends=
makedepends=
-source="http://downloads.sourceforge.net/project/espeak/espeak/espeak-${pkgver%.*}/espeak-$pkgver-source.zip"
+source="http://downloads.sourceforge.net/project/espeak/espeak/espeak-${pkgver%.*}/espeak-$pkgver-source.zip
+ fix-narrowing.patch
+ "
-_builddir="$srcdir"/$pkgname-$pkgver-source
+builddir="$srcdir"/$pkgname-$pkgver-source
build() {
- cd "$_builddir"/src
+ cd "$builddir"/src
make AUDIO=none || return 1
}
package() {
- cd "$_builddir"/src
+ cd "$builddir"/src
make AUDIO=none DESTDIR="$pkgdir" install || return 1
}
-md5sums="cadd7482eaafe9239546bdc09fa244c3 espeak-1.48.04-source.zip"
-sha256sums="bf9a17673adffcc28ff7ea18764f06136547e97bbd9edf2ec612f09b207f0659 espeak-1.48.04-source.zip"
-sha512sums="f0759e6ace2604c8cbb19e8c3fd4b106edf4dcece247a6677f6b734af7746c35a367126edfbe585396c98f6c54f07e25d64bfab35e258e64f09bd2c0833247fa espeak-1.48.04-source.zip"
+md5sums="cadd7482eaafe9239546bdc09fa244c3 espeak-1.48.04-source.zip
+088613fcee8a403295b37c4db7c5bd65 fix-narrowing.patch"
+sha256sums="bf9a17673adffcc28ff7ea18764f06136547e97bbd9edf2ec612f09b207f0659 espeak-1.48.04-source.zip
+52c048d5875235989158ea4cd09bb0f8234a5a130cdf04f664f4a5f20f5d11f3 fix-narrowing.patch"
+sha512sums="f0759e6ace2604c8cbb19e8c3fd4b106edf4dcece247a6677f6b734af7746c35a367126edfbe585396c98f6c54f07e25d64bfab35e258e64f09bd2c0833247fa espeak-1.48.04-source.zip
+e22808285b40a3cb65343e3c1bc10971cf00200e68358628813c71ee427d368e068baaf253b9b7b4a70fbec116f9914439fa499d162b132e259e712abaf8399d fix-narrowing.patch"
diff --git a/main/espeak/fix-narrowing.patch b/main/espeak/fix-narrowing.patch
new file mode 100644
index 00000000000..1cda004d11a
--- /dev/null
+++ b/main/espeak/fix-narrowing.patch
@@ -0,0 +1,23 @@
+https://raw.githubusercontent.com/termux/termux-packages/master/packages/espeak/char_unsigned_narrowing.patch
+
+diff -u -r ../espeak-1.48.01-source/src/tr_languages.cpp ./src/tr_languages.cpp
+--- ../espeak-1.48.01-source/src/tr_languages.cpp 2014-02-02 11:52:30.000000000 +0100
++++ ./src/tr_languages.cpp 2014-02-11 22:02:07.000000000 +0100
+@@ -198,7 +198,7 @@
+ 0x200d, 1, // zero width joiner
+ 0, 0 };
+
+-const char string_ordinal[] = {0xc2,0xba,0}; // masculine ordinal character, UTF-8
++const unsigned char string_ordinal[] = {0xc2,0xba,0}; // masculine ordinal character, UTF-8
+
+
+ static Translator* NewTranslator(void)
+@@ -758,7 +758,7 @@
+ tr->langopts.stress_flags = S_FINAL_SPANISH | S_FINAL_DIM_ONLY | S_FINAL_NO_2;
+ tr->langopts.numbers = NUM_SINGLE_STRESS | NUM_DECIMAL_COMMA | NUM_AND_UNITS | NUM_OMIT_1_HUNDRED | NUM_OMIT_1_THOUSAND | NUM_ROMAN | NUM_ROMAN_ORDINAL;
+ tr->langopts.numbers2 = NUM2_ORDINAL_NO_AND;
+- tr->langopts.roman_suffix = string_ordinal;
++ tr->langopts.roman_suffix = (char*) string_ordinal;
+ }
+ else
+ if(name2 == L_pap)