summaryrefslogtreecommitdiffstats
path: root/spelling
diff options
context:
space:
mode:
authorEric Sandall2008-03-22 00:44:33 -0700
committerEric Sandall2008-03-22 00:59:05 -0700
commit73fef20077befbd80a24c0657e244035bd09b21c (patch)
tree228aee65cca1049fbc644e8d9ee323f5f8413d0e /spelling
parent023c8f3008c50ea294485a292be8b7eb2bab281c (diff)
wpa_supplicant: Add patches to compile with gcc 4.3.0
Diffstat (limited to 'spelling')
-rw-r--r--spelling/aspell/HISTORY7
-rwxr-xr-xspelling/aspell/PRE_BUILD4
-rw-r--r--spelling/aspell/gcc43.patch157
-rw-r--r--spelling/aspell/templateinstantiations.patch8
4 files changed, 176 insertions, 0 deletions
diff --git a/spelling/aspell/HISTORY b/spelling/aspell/HISTORY
index da85e1b0a5..a6d0540953 100644
--- a/spelling/aspell/HISTORY
+++ b/spelling/aspell/HISTORY
@@ -1,3 +1,10 @@
+2008-03-22 Eric Sandall <sandalle@sourcemage.org>
+ * PRE_BUILD: Apply gcc43.patch
+ * gcc43.patch: Patch to compile with gcc 4.3.0
+ From http://kambing.ui.edu/gentoo-portage/app-text/aspell/files/aspell-0.60.5-gcc-4.3.patch
+ * templateinstantiations.patch: Patch to compile after gcc43.patch
+ is applied. From http://kambing.ui.edu/gentoo-portage/app-text/aspell/files/aspell-0.60.3-templateinstantiations.patch
+
2007-03-31 David Brown <dmlb2000@gmail.com>
* POST_INSTALL: removed not needed anymore
diff --git a/spelling/aspell/PRE_BUILD b/spelling/aspell/PRE_BUILD
new file mode 100755
index 0000000000..8335061562
--- /dev/null
+++ b/spelling/aspell/PRE_BUILD
@@ -0,0 +1,4 @@
+default_pre_build &&
+cd $SOURCE_DIRECTORY &&
+patch -p1 < $SCRIPT_DIRECTORY/gcc43.patch &&
+patch -p0 < $SCRIPT_DIRECTORY/templateinstantiations.patch
diff --git a/spelling/aspell/gcc43.patch b/spelling/aspell/gcc43.patch
new file mode 100644
index 0000000000..c898dea54e
--- /dev/null
+++ b/spelling/aspell/gcc43.patch
@@ -0,0 +1,157 @@
+#
+# From http://kambing.ui.edu/gentoo-portage/app-text/aspell/files/aspell-0.60.5-gcc-4.3.patch
+#
+diff -Naur aspell-0.60.5-orig/common/convert.cpp aspell-0.60.5/common/convert.cpp
+--- aspell-0.60.5-orig/common/convert.cpp 2006-11-18 02:36:01.000000000 -0600
++++ aspell-0.60.5/common/convert.cpp 2007-12-29 11:17:11.000000000 -0600
+@@ -238,7 +238,7 @@
+ }
+
+ template <class T>
+- static void free_norm_table(NormTable<T> * d)
++ void free_norm_table(NormTable<T> * d)
+ {
+ for (T * cur = d->data; cur != d->end; ++cur) {
+ if (cur->sub_table)
+diff -Naur aspell-0.60.5-orig/common/string.hpp aspell-0.60.5/common/string.hpp
+--- aspell-0.60.5-orig/common/string.hpp 2004-11-29 11:50:05.000000000 -0600
++++ aspell-0.60.5/common/string.hpp 2007-12-29 11:17:11.000000000 -0600
+@@ -129,10 +129,10 @@
+ }
+
+ char & operator[] (size_t pos) {return begin_[pos];}
+- const char operator[] (size_t pos) const {return begin_[pos];}
++ char operator[] (size_t pos) const {return begin_[pos];}
+
+ char & back() {return end_[-1];}
+- const char back() const {return end_[-1];}
++ char back() const {return end_[-1];}
+
+ void clear() {end_ = begin_;}
+
+@@ -492,7 +492,7 @@
+
+ namespace std
+ {
+- template<> static inline void swap(acommon::String & x, acommon::String & y) {return x.swap(y);}
++ template<> inline void swap(acommon::String & x, acommon::String & y) {return x.swap(y);}
+ }
+
+ #endif
+diff -Naur aspell-0.60.5-orig/modules/speller/default/affix.cpp aspell-0.60.5/modules/speller/default/affix.cpp
+--- aspell-0.60.5-orig/modules/speller/default/affix.cpp 2006-01-21 08:27:54.000000000 -0600
++++ aspell-0.60.5/modules/speller/default/affix.cpp 2007-12-29 11:17:11.000000000 -0600
+@@ -193,7 +193,7 @@
+ typedef const Conds * Value;
+ typedef const char * Key;
+ static const bool is_multi = false;
+- hash<const char *> hfun;
++ acommon::hash<const char *> hfun;
+ size_t hash(const char * s) {return hfun(s);}
+ bool equal(const char * x, const char * y) {return strcmp(x,y) == 0;}
+ const char * key(const Conds * c) {return c->str;}
+diff -Naur aspell-0.60.5-orig/modules/speller/default/affix.hpp aspell-0.60.5/modules/speller/default/affix.hpp
+--- aspell-0.60.5-orig/modules/speller/default/affix.hpp 2004-11-29 11:50:06.000000000 -0600
++++ aspell-0.60.5/modules/speller/default/affix.hpp 2007-12-29 11:17:11.000000000 -0600
+@@ -107,7 +107,7 @@
+ {
+ return expand(word,aff,buf,0);
+ }
+- WordAff * expand_suffix(ParmString word, const unsigned char * new_aff,
++ WordAff * expand_suffix(ParmString word, const unsigned char * aff,
+ ObjStack &, int limit = INT_MAX,
+ unsigned char * new_aff = 0, WordAff * * * l = 0,
+ ParmString orig_word = 0) const;
+diff -Naur aspell-0.60.5-orig/modules/speller/default/readonly_ws.cpp aspell-0.60.5/modules/speller/default/readonly_ws.cpp
+--- aspell-0.60.5-orig/modules/speller/default/readonly_ws.cpp 2006-11-18 03:17:19.000000000 -0600
++++ aspell-0.60.5/modules/speller/default/readonly_ws.cpp 2007-12-29 11:17:11.000000000 -0600
+@@ -726,7 +726,7 @@
+ struct WordLookupParms {
+ const char * block_begin;
+ WordLookupParms() {}
+- typedef Vector<u32int> Vector;
++ typedef acommon::Vector<u32int> Vector;
+ typedef u32int Value;
+ typedef const char * Key;
+ static const bool is_multi = false;
+diff -Naur aspell-0.60.5-orig/prog/aspell.cpp aspell-0.60.5/prog/aspell.cpp
+--- aspell-0.60.5-orig/prog/aspell.cpp 2006-12-19 04:51:08.000000000 -0600
++++ aspell-0.60.5/prog/aspell.cpp 2007-12-29 11:18:10.000000000 -0600
+@@ -239,6 +239,14 @@
+ return i;
+ }
+
++static void line_buffer() {
++#ifndef WIN32
++ // set up stdin and stdout to be line buffered
++ assert(setvbuf(stdin, 0, _IOLBF, 0) == 0);
++ assert(setvbuf(stdout, 0, _IOLBF, 0) == 0);
++#endif
++}
++
+ Conv dconv;
+ Conv uiconv;
+
+@@ -686,11 +694,7 @@
+
+ void pipe()
+ {
+-#ifndef WIN32
+- // set up stdin and stdout to be line buffered
+- assert(setvbuf(stdin, 0, _IOLBF, 0) == 0);
+- assert(setvbuf(stdout, 0, _IOLBF, 0) == 0);
+-#endif
++ line_buffer();
+
+ bool terse_mode = true;
+ bool do_time = options->retrieve_bool("time");
+@@ -1651,6 +1655,7 @@
+ Conv oconv(setup_conv(lang, options));
+ String word;
+ String sl;
++ line_buffer();
+ while (CIN.getline(word)) {
+ const char * w = iconv(word);
+ lang->LangImpl::to_soundslike(sl, w);
+@@ -1675,6 +1680,7 @@
+ Conv oconv(setup_conv(lang, options));
+ String word;
+ GuessInfo gi;
++ line_buffer();
+ while (CIN.getline(word)) {
+ lang->munch(iconv(word), &gi);
+ COUT << word;
+@@ -1713,6 +1719,7 @@
+ String word, buf;
+ ObjStack exp_buf;
+ WordAff * exp_list;
++ line_buffer();
+ while (CIN.getline(word)) {
+ buf = word;
+ char * w = iconv(buf.mstr(), buf.size());
+@@ -1799,6 +1806,7 @@
+ String word;
+ String base;
+ String affs;
++ line_buffer();
+ while (CIN.getline(word)) {
+ word = iconv(word);
+
+@@ -1882,7 +1890,7 @@
+ typedef SML_WordEntry Value;
+ typedef const char * Key;
+ static const bool is_multi = false;
+- hash<const char *> hash;
++ acommon::hash<const char *> hash;
+ bool equal(Key x, Key y) {return strcmp(x,y) == 0;}
+ Key key(const Value & v) {return v.word;}
+ };
+@@ -2033,7 +2041,7 @@
+ typedef CML_Entry Value;
+ typedef const char * Key;
+ static const bool is_multi = true;
+- hash<const char *> hash;
++ acommon::hash<const char *> hash;
+ bool equal(Key x, Key y) {return strcmp(x,y) == 0;}
+ Key key(const Value & v) {return v.word;}
+ };
diff --git a/spelling/aspell/templateinstantiations.patch b/spelling/aspell/templateinstantiations.patch
new file mode 100644
index 0000000000..a533f9e811
--- /dev/null
+++ b/spelling/aspell/templateinstantiations.patch
@@ -0,0 +1,8 @@
+--- common/string_map.cpp~ 2004-07-15 12:58:58.000000000 +0200
++++ common/string_map.cpp 2005-07-19 14:31:42.000000000 +0200
+@@ -82,3 +82,5 @@
+ }
+ }
+
++template class acommon::HashTable<acommon::StringMap::Parms>;
++template class acommon::BlockSList<acommon::StringPair>;