summaryrefslogtreecommitdiff
path: root/audio/festival/patches
diff options
context:
space:
mode:
authorjoerg <joerg>2012-05-04 16:01:04 +0000
committerjoerg <joerg>2012-05-04 16:01:04 +0000
commitb01ec32950b64ed75e23e7d8cbad6a3b6cf5f2e9 (patch)
tree67379cff30a08ae20d26f877b11546d1f682f795 /audio/festival/patches
parent1867a2d8d2c08d4f103521ef36e6c5f4cf0a57b1 (diff)
downloadpkgsrc-b01ec32950b64ed75e23e7d8cbad6a3b6cf5f2e9.tar.gz
Fix C++ issues for the stricter checks in clang
Diffstat (limited to 'audio/festival/patches')
-rw-r--r--audio/festival/patches/patch-speech__tools_base__class_EST__TSimpleMatrix.cc33
-rw-r--r--audio/festival/patches/patch-speech__tools_base__class_EST__TSimpleVector.cc21
-rw-r--r--audio/festival/patches/patch-speech__tools_base__class_EST__TVector.cc13
-rw-r--r--audio/festival/patches/patch-speech__tools_base__class_inst__tmpl_vector__dmatrix__t.cc27
-rw-r--r--audio/festival/patches/patch-speech__tools_base__class_inst__tmpl_vector__dvector__t.cc27
-rw-r--r--audio/festival/patches/patch-speech__tools_base__class_inst__tmpl_vector__fmatrix__t.cc26
-rw-r--r--audio/festival/patches/patch-speech__tools_include_EST__SCFG.h13
-rw-r--r--audio/festival/patches/patch-speech__tools_include_EST__TIterator.h22
-rw-r--r--audio/festival/patches/patch-speech__tools_include_EST__TNamedEnum.h13
-rw-r--r--audio/festival/patches/patch-speech__tools_include_ling__class_EST__FeatureFunctionPackage.h12
-rw-r--r--audio/festival/patches/patch-speech__tools_stats_dynamic__program.cc30
-rw-r--r--audio/festival/patches/patch-speech__tools_utils_EST__ServiceTable.cc20
12 files changed, 257 insertions, 0 deletions
diff --git a/audio/festival/patches/patch-speech__tools_base__class_EST__TSimpleMatrix.cc b/audio/festival/patches/patch-speech__tools_base__class_EST__TSimpleMatrix.cc
new file mode 100644
index 00000000000..c4ea2afc683
--- /dev/null
+++ b/audio/festival/patches/patch-speech__tools_base__class_EST__TSimpleMatrix.cc
@@ -0,0 +1,33 @@
+$NetBSD: patch-speech__tools_base__class_EST__TSimpleMatrix.cc,v 1.1 2012/05/04 16:01:04 joerg Exp $
+
+--- speech_tools/base_class/EST_TSimpleMatrix.cc.orig 2012-04-27 12:32:06.000000000 +0000
++++ speech_tools/base_class/EST_TSimpleMatrix.cc
+@@ -42,6 +42,7 @@
+
+ #include "EST_TSimpleMatrix.h"
+ #include "EST_TVector.h"
++#include <cstring>
+ #include <fstream>
+ #include <iostream>
+ #include "EST_cutils.h"
+@@ -98,7 +99,7 @@ void EST_TSimpleMatrix<T>::resize(int ne
+ {
+ int copy_r = Lof(this->num_rows(), new_rows);
+
+- just_resize(new_rows, new_cols, &old_vals);
++ this->just_resize(new_rows, new_cols, &old_vals);
+
+ for (q=0; q<(copy_r*new_cols*sizeof(T)); q++) /* memcpy */
+ ((char *)this->p_memory)[q] = ((char *)old_vals)[q];
+@@ -127,9 +128,9 @@ void EST_TSimpleMatrix<T>::resize(int ne
+ int copy_r = Lof(this->num_rows(), new_rows);
+ int copy_c = Lof(this->num_columns(), new_cols);
+
+- just_resize(new_rows, new_cols, &old_vals);
++ this->just_resize(new_rows, new_cols, &old_vals);
+
+- set_values(old_vals,
++ this->set_values(old_vals,
+ old_row_step, old_column_step,
+ 0, copy_r,
+ 0, copy_c);
diff --git a/audio/festival/patches/patch-speech__tools_base__class_EST__TSimpleVector.cc b/audio/festival/patches/patch-speech__tools_base__class_EST__TSimpleVector.cc
new file mode 100644
index 00000000000..bababac7a71
--- /dev/null
+++ b/audio/festival/patches/patch-speech__tools_base__class_EST__TSimpleVector.cc
@@ -0,0 +1,21 @@
+$NetBSD: patch-speech__tools_base__class_EST__TSimpleVector.cc,v 1.1 2012/05/04 16:01:04 joerg Exp $
+
+--- speech_tools/base_class/EST_TSimpleVector.cc.orig 2012-04-27 12:32:56.000000000 +0000
++++ speech_tools/base_class/EST_TSimpleVector.cc
+@@ -42,6 +42,7 @@
+
+ #include "EST_TSimpleVector.h"
+ #include "EST_matrix_support.h"
++#include <cstring>
+ #include <fstream>
+ #include "EST_cutils.h"
+
+@@ -70,7 +71,7 @@ template<class T> void EST_TSimpleVector
+ int old_offset = this->p_offset;
+ unsigned int q;
+
+- just_resize(newn, &old_vals);
++ this->just_resize(newn, &old_vals);
+
+ if (set && old_vals)
+ {
diff --git a/audio/festival/patches/patch-speech__tools_base__class_EST__TVector.cc b/audio/festival/patches/patch-speech__tools_base__class_EST__TVector.cc
new file mode 100644
index 00000000000..6a4e386cf46
--- /dev/null
+++ b/audio/festival/patches/patch-speech__tools_base__class_EST__TVector.cc
@@ -0,0 +1,13 @@
+$NetBSD: patch-speech__tools_base__class_EST__TVector.cc,v 1.1 2012/05/04 16:01:04 joerg Exp $
+
+--- speech_tools/base_class/EST_TVector.cc.orig 2012-04-27 13:01:33.000000000 +0000
++++ speech_tools/base_class/EST_TVector.cc
+@@ -258,7 +258,7 @@ int EST_TVector<T>::operator == (const E
+ return 0;
+
+ for(int i=0; i<num_columns() ; i++)
+- if (fast_a_v(i) != v.fast_a_v(i))
++ if (!(fast_a_v(i) == v.fast_a_v(i)))
+ return 0;
+ return 1;
+ }
diff --git a/audio/festival/patches/patch-speech__tools_base__class_inst__tmpl_vector__dmatrix__t.cc b/audio/festival/patches/patch-speech__tools_base__class_inst__tmpl_vector__dmatrix__t.cc
new file mode 100644
index 00000000000..241d3a4487d
--- /dev/null
+++ b/audio/festival/patches/patch-speech__tools_base__class_inst__tmpl_vector__dmatrix__t.cc
@@ -0,0 +1,27 @@
+$NetBSD: patch-speech__tools_base__class_inst__tmpl_vector__dmatrix__t.cc,v 1.1 2012/05/04 16:01:04 joerg Exp $
+
+--- speech_tools/base_class/inst_tmpl/vector_dmatrix_t.cc.orig 2012-04-27 12:36:31.000000000 +0000
++++ speech_tools/base_class/inst_tmpl/vector_dmatrix_t.cc
+@@ -40,6 +40,11 @@
+ #include "EST_types.h"
+ #include "EST_TVector.h"
+
++static const EST_DMatrix def_val_DMatrix;
++static EST_DMatrix error_return_DMatrix;
++template <> const EST_DMatrix *EST_TVector<EST_DMatrix>::def_val = &def_val_DMatrix;
++template <> EST_DMatrix *EST_TVector<EST_DMatrix>::error_return = &error_return_DMatrix;
++
+ #if defined(INSTANTIATE_TEMPLATES)
+
+ #include "../base_class/EST_TVector.cc"
+@@ -47,10 +52,6 @@
+ template class EST_TVector<EST_DMatrix>;
+
+ #endif
+-static const EST_DMatrix def_val_DMatrix;
+-static EST_DMatrix error_return_DMatrix;
+-template <> const EST_DMatrix *EST_TVector<EST_DMatrix>::def_val = &def_val_DMatrix;
+-template <> EST_DMatrix *EST_TVector<EST_DMatrix>::error_return = &error_return_DMatrix;
+
+ int operator !=(const EST_DMatrix &fm1,
+ const EST_DMatrix &fm2)
diff --git a/audio/festival/patches/patch-speech__tools_base__class_inst__tmpl_vector__dvector__t.cc b/audio/festival/patches/patch-speech__tools_base__class_inst__tmpl_vector__dvector__t.cc
new file mode 100644
index 00000000000..4feac2f74bb
--- /dev/null
+++ b/audio/festival/patches/patch-speech__tools_base__class_inst__tmpl_vector__dvector__t.cc
@@ -0,0 +1,27 @@
+$NetBSD: patch-speech__tools_base__class_inst__tmpl_vector__dvector__t.cc,v 1.1 2012/05/04 16:01:04 joerg Exp $
+
+--- speech_tools/base_class/inst_tmpl/vector_dvector_t.cc.orig 2012-04-27 12:36:12.000000000 +0000
++++ speech_tools/base_class/inst_tmpl/vector_dvector_t.cc
+@@ -40,6 +40,11 @@
+ #include "EST_types.h"
+ #include "EST_TVector.h"
+
++static const EST_DVector def_val_DVector;
++static EST_DVector error_return_DVector;
++template <> const EST_DVector *EST_TVector<EST_DVector>::def_val = &def_val_DVector;
++template <> EST_DVector *EST_TVector<EST_DVector>::error_return = &error_return_DVector;
++
+ #if defined(INSTANTIATE_TEMPLATES)
+
+ #include "../base_class/EST_TVector.cc"
+@@ -47,10 +52,6 @@
+ template class EST_TVector<EST_DVector>;
+
+ #endif
+-static const EST_DVector def_val_DVector;
+-static EST_DVector error_return_DVector;
+-template <> const EST_DVector *EST_TVector<EST_DVector>::def_val = &def_val_DVector;
+-template <> EST_DVector *EST_TVector<EST_DVector>::error_return = &error_return_DVector;
+
+ int operator !=(const EST_DVector &fv1,
+ const EST_DVector &fv2)
diff --git a/audio/festival/patches/patch-speech__tools_base__class_inst__tmpl_vector__fmatrix__t.cc b/audio/festival/patches/patch-speech__tools_base__class_inst__tmpl_vector__fmatrix__t.cc
new file mode 100644
index 00000000000..af8a8354358
--- /dev/null
+++ b/audio/festival/patches/patch-speech__tools_base__class_inst__tmpl_vector__fmatrix__t.cc
@@ -0,0 +1,26 @@
+$NetBSD: patch-speech__tools_base__class_inst__tmpl_vector__fmatrix__t.cc,v 1.1 2012/05/04 16:01:04 joerg Exp $
+
+--- speech_tools/base_class/inst_tmpl/vector_fmatrix_t.cc.orig 2012-04-27 12:34:44.000000000 +0000
++++ speech_tools/base_class/inst_tmpl/vector_fmatrix_t.cc
+@@ -40,6 +40,10 @@
+ #include "EST_types.h"
+ #include "EST_TVector.h"
+
++static EST_FMatrix error_return_FMatrix;
++static const EST_FMatrix def_val_FMatrix;
++template <> const EST_FMatrix *EST_TVector<EST_FMatrix>::def_val = &def_val_FMatrix;
++template <> EST_FMatrix *EST_TVector<EST_FMatrix>::error_return = &error_return_FMatrix;
+ #if defined(INSTANTIATE_TEMPLATES)
+
+ #include "../base_class/EST_TVector.cc"
+@@ -48,10 +52,6 @@ template class EST_TVector<EST_FMatrix>;
+
+
+ #endif
+-static const EST_FMatrix def_val_FMatrix;
+-static EST_FMatrix error_return_FMatrix;
+-template <> const EST_FMatrix *EST_TVector<EST_FMatrix>::def_val = &def_val_FMatrix;
+-template <> EST_FMatrix *EST_TVector<EST_FMatrix>::error_return = &error_return_FMatrix;
+
+ int operator !=(const EST_FMatrix &fm1,
+ const EST_FMatrix &fm2)
diff --git a/audio/festival/patches/patch-speech__tools_include_EST__SCFG.h b/audio/festival/patches/patch-speech__tools_include_EST__SCFG.h
new file mode 100644
index 00000000000..74f4da9b860
--- /dev/null
+++ b/audio/festival/patches/patch-speech__tools_include_EST__SCFG.h
@@ -0,0 +1,13 @@
+$NetBSD: patch-speech__tools_include_EST__SCFG.h,v 1.1 2012/05/04 16:01:04 joerg Exp $
+
+--- speech_tools/include/EST_SCFG.h.orig 2012-04-27 12:52:20.000000000 +0000
++++ speech_tools/include/EST_SCFG.h
+@@ -85,6 +85,8 @@ class EST_bracketed_string {
+ int valid(int i,int k) const { return valid_spans[i][k]; }
+
+ ///
++ int operator ==(const EST_bracketed_string &a) const
++ { return (this == &a); }
+ int operator !=(const EST_bracketed_string &a) const
+ { return (!(this == &a)); }
+ ///
diff --git a/audio/festival/patches/patch-speech__tools_include_EST__TIterator.h b/audio/festival/patches/patch-speech__tools_include_EST__TIterator.h
new file mode 100644
index 00000000000..7ae40cf8b52
--- /dev/null
+++ b/audio/festival/patches/patch-speech__tools_include_EST__TIterator.h
@@ -0,0 +1,22 @@
+$NetBSD: patch-speech__tools_include_EST__TIterator.h,v 1.1 2012/05/04 16:01:04 joerg Exp $
+
+--- speech_tools/include/EST_TIterator.h.orig 2012-04-27 12:26:17.000000000 +0000
++++ speech_tools/include/EST_TIterator.h
+@@ -209,7 +209,7 @@ public:
+
+ /// Create an iterator ready to run over the given container.
+ EST_TStructIterator(const Container &over)
+- { begin(over); }
++ { this->begin(over); }
+
+ const Entry *operator ->() const
+ {return &this->current();}
+@@ -289,7 +289,7 @@ public:
+
+ /// Create an iterator ready to run over the given container.
+ EST_TRwStructIterator(Container &over)
+- { begin(over); }
++ { this->begin(over); }
+
+ Entry *operator ->() const
+ {return &this->current();}
diff --git a/audio/festival/patches/patch-speech__tools_include_EST__TNamedEnum.h b/audio/festival/patches/patch-speech__tools_include_EST__TNamedEnum.h
new file mode 100644
index 00000000000..aaa120c3fbd
--- /dev/null
+++ b/audio/festival/patches/patch-speech__tools_include_EST__TNamedEnum.h
@@ -0,0 +1,13 @@
+$NetBSD: patch-speech__tools_include_EST__TNamedEnum.h,v 1.1 2012/05/04 16:01:04 joerg Exp $
+
+--- speech_tools/include/EST_TNamedEnum.h.orig 2012-04-27 12:28:44.000000000 +0000
++++ speech_tools/include/EST_TNamedEnum.h
+@@ -130,7 +130,7 @@ public:
+ {this->initialise((const void *)defs); };
+ EST_TNamedEnumI(EST_TValuedEnumDefinition<const char *,const char *,INFO> defs[], ENUM (*conv)(const char *))
+ {this->initialise((const void *)defs, conv); };
+- const char *name(ENUM tok, int n=0) const {return value(tok,n); };
++ const char *name(ENUM tok, int n=0) const {return this->value(tok,n); };
+
+ };
+
diff --git a/audio/festival/patches/patch-speech__tools_include_ling__class_EST__FeatureFunctionPackage.h b/audio/festival/patches/patch-speech__tools_include_ling__class_EST__FeatureFunctionPackage.h
new file mode 100644
index 00000000000..9da1b3e4a91
--- /dev/null
+++ b/audio/festival/patches/patch-speech__tools_include_ling__class_EST__FeatureFunctionPackage.h
@@ -0,0 +1,12 @@
+$NetBSD: patch-speech__tools_include_ling__class_EST__FeatureFunctionPackage.h,v 1.1 2012/05/04 16:01:04 joerg Exp $
+
+--- speech_tools/include/ling_class/EST_FeatureFunctionPackage.h.orig 2012-04-27 12:41:31.000000000 +0000
++++ speech_tools/include/ling_class/EST_FeatureFunctionPackage.h
+@@ -70,5 +70,7 @@ public:
+ };
+
+ int operator == (const EST_FeatureFunctionPackage::Entry &a, const EST_FeatureFunctionPackage::Entry &b);
++ostream &operator << (ostream &s, EST_FeatureFunctionPackage::Entry &e);
++
+ #endif
+
diff --git a/audio/festival/patches/patch-speech__tools_stats_dynamic__program.cc b/audio/festival/patches/patch-speech__tools_stats_dynamic__program.cc
new file mode 100644
index 00000000000..ef31d4d77a4
--- /dev/null
+++ b/audio/festival/patches/patch-speech__tools_stats_dynamic__program.cc
@@ -0,0 +1,30 @@
+$NetBSD: patch-speech__tools_stats_dynamic__program.cc,v 1.1 2012/05/04 16:01:04 joerg Exp $
+
+--- speech_tools/stats/dynamic_program.cc.orig 2012-04-27 12:49:30.000000000 +0000
++++ speech_tools/stats/dynamic_program.cc
+@@ -42,6 +42,12 @@
+ #include "ling_class/EST_Utterance.h"
+
+ typedef EST_TVector<EST_Item*> EST_Item_ptr_Vector;
++
++static EST_Item *const def_val_item_ptr = NULL;
++template <> EST_Item* const *EST_Item_ptr_Vector::def_val = &def_val_item_ptr;
++static EST_Item* error_return_item_ptr = NULL;
++template <> EST_Item* *EST_Item_ptr_Vector::error_return = &error_return_item_ptr;
++
+ #if defined(INSTANTIATE_TEMPLATES)
+ #include "../base_class/EST_TVector.cc"
+
+@@ -49,12 +55,6 @@ template class EST_TVector<EST_Item*>;
+
+ #endif
+
+-static EST_Item *const def_val_item_ptr = NULL;
+-template <> EST_Item* const *EST_Item_ptr_Vector::def_val = &def_val_item_ptr;
+-
+-static EST_Item* error_return_item_ptr = NULL;
+-template <> EST_Item* *EST_Item_ptr_Vector::error_return = &error_return_item_ptr;
+-
+ typedef
+ float (*local_cost_function)(const EST_Item *item1,
+ const EST_Item *item2);
diff --git a/audio/festival/patches/patch-speech__tools_utils_EST__ServiceTable.cc b/audio/festival/patches/patch-speech__tools_utils_EST__ServiceTable.cc
new file mode 100644
index 00000000000..e6461cf7178
--- /dev/null
+++ b/audio/festival/patches/patch-speech__tools_utils_EST__ServiceTable.cc
@@ -0,0 +1,20 @@
+$NetBSD: patch-speech__tools_utils_EST__ServiceTable.cc,v 1.1 2012/05/04 16:01:04 joerg Exp $
+
+--- speech_tools/utils/EST_ServiceTable.cc.orig 2012-04-27 12:30:06.000000000 +0000
++++ speech_tools/utils/EST_ServiceTable.cc
+@@ -68,6 +68,7 @@ int gethostname(char *name, int namelen)
+ }
+ #endif
+
++Declare_KVL_T(EST_String, EST_ServiceTable::Entry, EST_String_ST_entry)
+
+ EST_ServiceTable::EntryTable EST_ServiceTable::entries;
+ bool EST_ServiceTable::random_init=FALSE;
+@@ -339,7 +340,6 @@ const EST_ServiceTable::Entry &EST_Servi
+
+
+
+-Declare_KVL_T(EST_String, EST_ServiceTable::Entry, EST_String_ST_entry)
+
+ #if defined(INSTANTIATE_TEMPLATES)
+