diff options
author | Nils Wallménius <nils@rockbox.org> | 2007-08-05 19:19:39 +0000 |
---|---|---|
committer | Nils Wallménius <nils@rockbox.org> | 2007-08-05 19:19:39 +0000 |
commit | b3113674819cd8daf44750d129c5d8298e830df0 (patch) | |
tree | ebc7ec9e096e309ef79834802eed28ff9c22fd41 /tools/genvoice.sh | |
parent | e70f7f4ca857e9e88a6e076360b6c9c235d7739b (diff) | |
download | rockbox-b3113674819cd8daf44750d129c5d8298e830df0.tar.gz rockbox-b3113674819cd8daf44750d129c5d8298e830df0.zip |
*** Lang v2 cleanup (FS#6574) ***
1) Introduces apps/features.txt that controls which strings are included
for each target based on defines.
2) .lng and .voice files are now target specific and the format versions
of both these file types have been bumped, which means that new voice
files are needed.
3) Use the 'features' mechanism to exclude strings for targets that
didn't use them.
4) Delete unused and deprecated and duplicated strings, sort strings in
english.lang
Some string IDs were changed so translations will be slightly worse than
before.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14198 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'tools/genvoice.sh')
-rwxr-xr-x | tools/genvoice.sh | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/tools/genvoice.sh b/tools/genvoice.sh index f32ab9476a..15028e3bd1 100755 --- a/tools/genvoice.sh +++ b/tools/genvoice.sh | |||
@@ -34,13 +34,17 @@ TTS_ENGINE=festival | |||
34 | ENCODER=lame | 34 | ENCODER=lame |
35 | # Where to save temporary files | 35 | # Where to save temporary files |
36 | TEMPDIR=/tmp | 36 | TEMPDIR=/tmp |
37 | # List of IDs to send to voicefont | ||
38 | VOICEFONTIDS=voicefontids | ||
37 | 39 | ||
38 | ################### | 40 | ################### |
39 | # End of settings # | 41 | # End of settings # |
40 | ################### | 42 | ################### |
41 | 43 | ||
44 | TARGET_ID="$4" | ||
42 | createvoicefile() { | 45 | createvoicefile() { |
43 | $VOICEFONT "$LANG_FILE" "$TEMPDIR/" "./$RLANG.voice" | 46 | $GENLANG -e=$ENGLISH -o -t=$TARGET $LANG_FILE > $VOICEFONTIDS |
47 | $VOICEFONT "$VOICEFONTIDS" "$TARGET_ID" "$TEMPDIR/" "./$RLANG.voice" | ||
44 | } | 48 | } |
45 | 49 | ||
46 | deletefiles() { | 50 | deletefiles() { |
@@ -106,7 +110,7 @@ generateclips() { | |||
106 | } | 110 | } |
107 | 111 | ||
108 | if [ -z "$3" ]; then | 112 | if [ -z "$3" ]; then |
109 | echo "Usage: $0 rockboxdirectory language target [settingsfile]"; | 113 | echo "Usage: $0 rockboxdirectory language target targetid [settingsfile]"; |
110 | exit 32 | 114 | exit 32 |
111 | else | 115 | else |
112 | if [ ! -d "$1" ] || [ ! -f "$1/tools/genlang" ]; then | 116 | if [ ! -d "$1" ] || [ ! -f "$1/tools/genlang" ]; then |
@@ -117,12 +121,12 @@ else | |||
117 | echo "Error: $2 is not a valid language" | 121 | echo "Error: $2 is not a valid language" |
118 | exit 34 | 122 | exit 34 |
119 | fi | 123 | fi |
120 | if [ ! -z "$4" ]; then | 124 | if [ ! -z "$5" ]; then |
121 | if [ -f "$4" ]; then | 125 | if [ -f "$5" ]; then |
122 | # Read settings from file | 126 | # Read settings from file |
123 | source "$4" | 127 | source "$5" |
124 | else | 128 | else |
125 | echo "Error: $4 does not exist" | 129 | echo "Error: $5 does not exist" |
126 | exit 36 | 130 | exit 36 |
127 | fi | 131 | fi |
128 | fi | 132 | fi |