3
0
Fork 0
forked from mirrors/nixpkgs

espeak-classic: fix build with gcc6

This commit is contained in:
Samuel Leathers 2017-09-01 10:25:48 -04:00
parent b2e7e231ec
commit 6c1364712a
2 changed files with 18 additions and 1 deletions

View file

@ -10,7 +10,11 @@ stdenv.mkDerivation rec {
buildInputs = [ unzip portaudio ];
patchPhase = ''
patches = [
./gcc6.patch
];
prePatch = ''
sed -e s,/bin/ln,ln,g -i src/Makefile
sed -e 's,^CXXFLAGS=-O2,CXXFLAGS=-O2 -D PATH_ESPEAK_DATA=\\\"$(DATADIR)\\\",' -i src/Makefile
'' + (if portaudio.api_version == 19 then ''

View file

@ -0,0 +1,13 @@
diff --git c/src/tr_languages.cpp i/src/tr_languages.cpp
index ec210a5..9503f47 100755
--- c/src/tr_languages.cpp
+++ i/src/tr_languages.cpp
@@ -198,7 +198,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)