aboutsummaryrefslogtreecommitdiffstats
path: root/audio
diff options
context:
space:
mode:
authormi <mi@FreeBSD.org>2014-12-01 03:28:20 +0800
committermi <mi@FreeBSD.org>2014-12-01 03:28:20 +0800
commitf929628f2fad4dc1837d62c1b3187a8018a151de (patch)
treed37323f71ed356fdfd14a5ac9a62e9289924e04d /audio
parent0e87abbcb01e8f382ff8f7da91e55a7df18e9b68 (diff)
downloadfreebsd-ports-gnome-f929628f2fad4dc1837d62c1b3187a8018a151de.tar.gz
freebsd-ports-gnome-f929628f2fad4dc1837d62c1b3187a8018a151de.tar.zst
freebsd-ports-gnome-f929628f2fad4dc1837d62c1b3187a8018a151de.zip
Stop disabling optimization -- which was not necessary since the current
version (1.4) was released years ago. Clean-up some compiler warnings. PR: ports/174624 Submitted by: mi@ Approved by: maintainer timeout (two years)
Diffstat (limited to 'audio')
-rw-r--r--audio/flite/Makefile2
-rw-r--r--audio/flite/files/patch-include__cst_sts.h18
-rw-r--r--audio/flite/files/patch-warnings127
3 files changed, 127 insertions, 20 deletions
diff --git a/audio/flite/Makefile b/audio/flite/Makefile
index cc794840a989..60f3d1ee584c 100644
--- a/audio/flite/Makefile
+++ b/audio/flite/Makefile
@@ -19,8 +19,6 @@ USE_LDCONFIG= yes
MAKE_JOBS_UNSAFE= yes
-CFLAGS:= ${CFLAGS:N-O:N-O[0123456789]} -O0
-
post-patch:
@${REINPLACE_CMD} -e 's|-pd|-p|g' ${WRKSRC}/main/Makefile
diff --git a/audio/flite/files/patch-include__cst_sts.h b/audio/flite/files/patch-include__cst_sts.h
deleted file mode 100644
index c27fd15d0595..000000000000
--- a/audio/flite/files/patch-include__cst_sts.h
+++ /dev/null
@@ -1,18 +0,0 @@
-
-$FreeBSD$
-
---- include/cst_sts.h
-+++ include/cst_sts.h
-@@ -47,9 +47,9 @@
- /* else where, this information plus the indexes in the Unit relation */
- /* allow reconstruction of the signal itself */
- struct cst_sts_struct {
-- const unsigned short *frame;
-- const int size; /* in samples */
-- const unsigned char *residual;
-+ unsigned short *frame;
-+ int size; /* in samples */
-+ unsigned char *residual;
- };
- typedef struct cst_sts_struct cst_sts;
-
diff --git a/audio/flite/files/patch-warnings b/audio/flite/files/patch-warnings
new file mode 100644
index 000000000000..04e66b5c36e4
--- /dev/null
+++ b/audio/flite/files/patch-warnings
@@ -0,0 +1,127 @@
+--- src/audio/au_oss.c 2009-04-08 09:18:42.000000000 -0400
++++ src/audio/au_oss.c 2014-11-30 13:21:50.000000000 -0500
+@@ -84,5 +84,5 @@
+ ad->channels = channels;
+ ad->fmt = fmt;
+- ad->platform_data = (void *)afd;
++ ad->platform_data = (void *)(intptr_t)afd;
+
+ if (ad->channels == 0)
+--- src/synth/cst_ssml.c 2009-05-01 10:52:13.000000000 -0400
++++ src/synth/cst_ssml.c 2014-11-30 13:23:47.000000000 -0500
+@@ -57,41 +57,7 @@
+ #include "cst_tokenstream.h"
+
+-static const char *ssml_whitespacesymbols;
+ static const char *ssml_singlecharsymbols_general = "<>&/\";";
+ static const char *ssml_singlecharsymbols_inattr = "=>;/\"";
+
+-static void add_raw_data(cst_utterance *u, const char *raw_data,
+- cst_features *attributes)
+-{
+- /* Add all tokens in raw _data to u */
+- cst_tokenstream *ts;
+- cst_relation *r;
+- cst_item *t;
+- const char *token;
+-
+- r = utt_relation_create(u,"Token");
+- ts =
+- ts_open_string(raw_data,
+- get_param_string(u->features,"text_whitespace",NULL),
+- get_param_string(u->features,"text_singlecharsymbols",NULL),
+- get_param_string(u->features,"text_prepunctuation",NULL),
+- get_param_string(u->features,"text_pospunctuation",NULL));
+- while (!(ts_eof(ts)))
+- {
+- t = relation_append(r,NULL);
+- feat_copy_into(item_feats(t),attributes);
+- token = ts_get(ts);
+- if (cst_strlen(token) > 0)
+- {
+- t = relation_append(r,NULL);
+- item_set_string(t,"name",token);
+- item_set_string(t,"whitespace",ts->whitespace);
+- item_set_string(t,"prepunctuation",ts->prepunctuation);
+- item_set_string(t,"punc",ts->postpunctuation);
+- }
+- }
+-
+-}
+-
+ static const char *ts_get_quoted_remainder(cst_tokenstream *ts)
+ {
+@@ -169,14 +135,4 @@
+ }
+
+-static void extend_buffer(char **buffer,int *buffer_max,int at_least)
+-{
+- int new_max;
+-
+- new_max = (*buffer_max)+at_least;
+- cst_free(*buffer);
+- *buffer = cst_alloc(char,new_max);
+- *buffer_max = new_max;
+-}
+-
+ static float flite_ssml_to_speech_ts(cst_tokenstream *ts,
+ cst_voice *voice,
+--- include/cst_lexicon.h 2009-06-09 14:07:34.000000000 -0400
++++ include/cst_lexicon.h 2014-11-30 13:26:51.000000000 -0500
+@@ -45,5 +45,5 @@
+
+ typedef struct lexicon_struct {
+- char *name;
++ const char *name;
+ int num_entries;
+ /* Entries are centered around bytes with value 255 */
+@@ -51,5 +51,5 @@
+ /* each are terminated (preceeded in pron case) by 0 */
+ /* This saves 4 bytes per entry for an index */
+- unsigned char *data; /* the entries and phone strings */
++ const unsigned char *data; /* the entries and phone strings */
+ int num_bytes; /* the number of bytes in the data */
+- char **phone_table;
++ const char * const *phone_table;
+--- src/lexicon/cst_lexicon.c 2009-08-24 12:35:51.000000000 -0400
++++ src/lexicon/cst_lexicon.c 2014-11-30 13:31:33.000000000 -0500
+@@ -63,14 +63,4 @@
+ }
+
+-void delete_lexicon(cst_lexicon *lex)
+-{ /* But I doubt if this will ever be called, lexicons are mapped */
+- /* This probably isn't complete */
+- if (lex)
+- {
+- cst_free(lex->data);
+- cst_free(lex);
+- }
+-}
+-
+ cst_val *cst_lex_load_addenda(const cst_lexicon *lex, const char *lexfile)
+ { /* Load an addend from given file, check its phones wrt lex */
+@@ -331,5 +321,5 @@
+ {
+ int i,j=0,length;
+- unsigned char *cword;
++ const unsigned char *cword;
+
+ if (l->entry_hufftable == 0)
+--- lang/cmulex/cmu_lex.c 2009-08-14 12:30:10.000000000 -0400
++++ lang/cmulex/cmu_lex.c 2014-11-30 13:37:22.000000000 -0500
+@@ -360,5 +360,5 @@
+ #endif
+ cmu_lex.num_bytes = cmu_lex_num_bytes;
+- cmu_lex.phone_table = (char **) cmu_lex_phone_table;
++ cmu_lex.phone_table = cmu_lex_phone_table;
+ cmu_lex.syl_boundary = cmu_syl_boundary_mo;
+ cmu_lex.addenda = (char ***) addenda;
+--- main/compile_regexes.c 2009-04-08 09:18:42.000000000 -0400
++++ main/compile_regexes.c 2014-11-30 13:43:25.000000000 -0500
+@@ -75,5 +75,5 @@
+ printf("NULL, ");
+ else
+- printf("%s_rxprog + %d, ", name, rgx->regmust - rgx->program);
++ printf("%s_rxprog + %td, ", name, rgx->regmust - rgx->program);
+ printf("%d, ",rgx->regmlen);
+ printf("%d,\n ",rgx->regsize);