diff options
author | René Engelhard <rene@openoffice.org> | 2008-04-23 20:01:06 +0000 |
---|---|---|
committer | René Engelhard <rene@openoffice.org> | 2008-04-23 20:01:06 +0000 |
commit | 1124dc7e3f4dcfdc3683f95506786dc52bf81ba7 (patch) | |
tree | 3ed41af897b429852cfc02a87332bca803438312 /hunspell | |
parent | cf1b287098c2fd0104068be23280f16253f04cdf (diff) |
i10000# EXTERNAL_WARNINGS_NOT_ERRORS := TRUE
Diffstat (limited to 'hunspell')
-rw-r--r-- | hunspell/hunspell-1.1.12.patch | 606 |
1 files changed, 236 insertions, 370 deletions
diff --git a/hunspell/hunspell-1.1.12.patch b/hunspell/hunspell-1.1.12.patch index 3f7cf61872cb..3610f3a81e13 100644 --- a/hunspell/hunspell-1.1.12.patch +++ b/hunspell/hunspell-1.1.12.patch @@ -1,374 +1,125 @@ -*** misc/hunspell-1.1.12/src/hunspell/affixmgr.cxx Tue Sep 4 09:49:30 2007 ---- misc/build/hunspell-1.1.12/src/hunspell/affixmgr.cxx Thu Apr 10 20:27:15 2008 -*************** -*** 25,30 **** ---- 25,34 ---- - #endif - #endif - -+ #ifdef OS2 -+ #undef DEBUG -+ #endif -+ - AffixMgr::AffixMgr(const char * affpath, HashMgr* ptr) - { - // register hash manager and load affix data from aff file -*************** -*** 2789,2795 **** - - int AffixMgr::expand_rootword(struct guessword * wlst, int maxn, const char * ts, - int wl, const unsigned short * ap, unsigned short al, char * bad, int badl, -! char * phone) - { - - int nh=0; ---- 2793,2799 ---- - - int AffixMgr::expand_rootword(struct guessword * wlst, int maxn, const char * ts, - int wl, const unsigned short * ap, unsigned short al, char * bad, int badl, -! char * phone_) - { - - int nh=0; -*************** -*** 2801,2808 **** - wlst[nh].orig = NULL; - nh++; - // add special phonetic version -! if (phone && (nh < maxn)) { -! wlst[nh].word = mystrdup(phone); - wlst[nh].allow = (1 == 0); - wlst[nh].orig = mystrdup(ts); - nh++; ---- 2805,2812 ---- - wlst[nh].orig = NULL; - nh++; - // add special phonetic version -! if (phone_ && (nh < maxn)) { -! wlst[nh].word = mystrdup(phone_); - wlst[nh].allow = (1 == 0); - wlst[nh].orig = mystrdup(ts); - nh++; -*************** -*** 2832,2842 **** - wlst[nh].orig = NULL; - nh++; - // add special phonetic version -! if (phone && (nh < maxn)) { - char st[MAXWORDUTF8LEN]; -! strcpy(st, phone); - strcat(st, sptr->getKey()); -! reverseword(st + strlen(phone)); - wlst[nh].word = mystrdup(st); - wlst[nh].allow = (1 == 0); - wlst[nh].orig = mystrdup(newword); ---- 2836,2846 ---- - wlst[nh].orig = NULL; - nh++; - // add special phonetic version -! if (phone_ && (nh < maxn)) { - char st[MAXWORDUTF8LEN]; -! strcpy(st, phone_); - strcat(st, sptr->getKey()); -! reverseword(st + strlen(phone_)); - wlst[nh].word = mystrdup(st); - wlst[nh].allow = (1 == 0); - wlst[nh].orig = mystrdup(newword); -*** misc/hunspell-1.1.12/src/hunspell/atypes.hxx Sat Sep 1 08:57:35 2007 ---- misc/build/hunspell-1.1.12/src/hunspell/atypes.hxx Thu Apr 10 20:27:15 2008 -*************** -*** 9,15 **** - static inline void HUNSPELL_WARNING(FILE *, const char *, ...) {} - #endif - #endif -! - // HUNSTEM def. - #define HUNSTEM - ---- 9,15 ---- - static inline void HUNSPELL_WARNING(FILE *, const char *, ...) {} - #endif - #endif -! - // HUNSTEM def. - #define HUNSTEM - -*************** -*** 91,98 **** - }; - - #endif -- -- -- -- -- ---- 91,93 ---- -*** misc/hunspell-1.1.12/src/hunspell/csutil.cxx Thu Aug 23 09:27:39 2007 ---- misc/build/hunspell-1.1.12/src/hunspell/csutil.cxx Thu Apr 10 20:27:15 2008 -*************** -*** 18,29 **** - #include "langnum.hxx" - - #ifdef OPENOFFICEORG -! # include <unicode/uchar.h> - #else -! # ifndef MOZILLA_CLIENT -! # include "utf_info.cxx" -! # define UTF_LST_LEN (sizeof(utf_lst) / (sizeof(unicode_info))) -! # endif - #endif - - #ifdef MOZILLA_CLIENT ---- 18,29 ---- - #include "langnum.hxx" - - #ifdef OPENOFFICEORG -! #include <unicode/uchar.h> - #else -! #ifndef MOZILLA_CLIENT -! #include "utf_info.cxx" -! #define UTF_LST_LEN (sizeof(utf_lst) / (sizeof(unicode_info))) -! #endif - #endif - - #ifdef MOZILLA_CLIENT -*************** -*** 125,131 **** - case 0x90: - case 0xa0: - case 0xb0: { -! HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Unexpected continuation bytes in %d. character position\n%s\n", u8 - src, src); - u2->h = 0xff; - u2->l = 0xfd; - break; ---- 125,131 ---- - case 0x90: - case 0xa0: - case 0xb0: { -! HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Unexpected continuation bytes in %ld. character position\n%s\n", static_cast<long>(u8 - src), src); - u2->h = 0xff; - u2->l = 0xfd; - break; -*************** -*** 137,143 **** - u2->l = (*u8 << 6) + (*(u8+1) & 0x3f); - u8++; - } else { -! HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Missing continuation byte in %d. character position:\n%s\n", u8 - src, src); - u2->h = 0xff; - u2->l = 0xfd; - } ---- 137,143 ---- - u2->l = (*u8 << 6) + (*(u8+1) & 0x3f); - u8++; - } else { -! HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Missing continuation byte in %ld. character position:\n%s\n", static_cast<long>(u8 - src), src); - u2->h = 0xff; - u2->l = 0xfd; - } -*************** -*** 151,162 **** - u2->l = (*u8 << 6) + (*(u8+1) & 0x3f); - u8++; - } else { -! HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Missing continuation byte in %d. character position:\n%s\n", u8 - src, src); - u2->h = 0xff; - u2->l = 0xfd; - } - } else { -! HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Missing continuation byte in %d. character position:\n%s\n", u8 - src, src); - u2->h = 0xff; - u2->l = 0xfd; - } ---- 151,162 ---- - u2->l = (*u8 << 6) + (*(u8+1) & 0x3f); - u8++; - } else { -! HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Missing continuation byte in %ld. character position:\n%s\n", static_cast<long>(u8 - src), src); - u2->h = 0xff; - u2->l = 0xfd; - } - } else { -! HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Missing continuation byte in %ld. character position:\n%s\n", static_cast<long>(u8 - src), src); - u2->h = 0xff; - u2->l = 0xfd; - } -*** misc/hunspell-1.1.12/src/hunspell/hunspell.cxx Tue Aug 28 15:17:30 2007 ---- misc/build/hunspell-1.1.12/src/hunspell/hunspell.cxx Thu Apr 10 20:27:15 2008 -*************** -*** 1,3 **** ---- 1,7 ---- -+ #ifdef _MSC_VER -+ #pragma setlocale("C") -+ #endif +--- misc/hunspell-1.1.12/src/hunspell/affixmgr.cxx 2007-09-04 09:49:30.000000000 +0200 ++++ misc/build/hunspell-1.1.12/src/hunspell/affixmgr.cxx 2008-04-23 22:59:31.000000000 +0200 +@@ -25,6 +25,10 @@ + #endif + #endif + ++#ifdef OS2 ++#undef DEBUG ++#endif ++ + AffixMgr::AffixMgr(const char * affpath, HashMgr* ptr) + { + // register hash manager and load affix data from aff file +@@ -2789,7 +2793,7 @@ + + int AffixMgr::expand_rootword(struct guessword * wlst, int maxn, const char * ts, + int wl, const unsigned short * ap, unsigned short al, char * bad, int badl, +- char * phone) ++ char * phone_) + { + + int nh=0; +@@ -2801,8 +2805,8 @@ + wlst[nh].orig = NULL; + nh++; + // add special phonetic version +- if (phone && (nh < maxn)) { +- wlst[nh].word = mystrdup(phone); ++ if (phone_ && (nh < maxn)) { ++ wlst[nh].word = mystrdup(phone_); + wlst[nh].allow = (1 == 0); + wlst[nh].orig = mystrdup(ts); + nh++; +@@ -2832,11 +2836,11 @@ + wlst[nh].orig = NULL; + nh++; + // add special phonetic version +- if (phone && (nh < maxn)) { ++ if (phone_ && (nh < maxn)) { + char st[MAXWORDUTF8LEN]; +- strcpy(st, phone); ++ strcpy(st, phone_); + strcat(st, sptr->getKey()); +- reverseword(st + strlen(phone)); ++ reverseword(st + strlen(phone_)); + wlst[nh].word = mystrdup(st); + wlst[nh].allow = (1 == 0); + wlst[nh].orig = mystrdup(newword); +--- misc/hunspell-1.1.12/src/hunspell/atypes.hxx 2007-09-01 08:57:35.000000000 +0200 ++++ misc/build/hunspell-1.1.12/src/hunspell/atypes.hxx 2008-04-23 22:59:31.000000000 +0200 +@@ -9,7 +9,7 @@ + static inline void HUNSPELL_WARNING(FILE *, const char *, ...) {} + #endif + #endif +- + - #include "license.hunspell" - #include "license.myspell" - -*************** -*** 12,18 **** - #endif - - #include "hunspell.hxx" -! #include "hunspell.h" - - #ifndef MOZILLA_CLIENT - #ifndef W32 ---- 16,26 ---- - #endif - - #include "hunspell.hxx" -! #ifndef OPENOFFICEORG -! #ifndef MOZILLA_CLIENT -! //#include "hunspell.h" -! #endif -! #endif - - #ifndef MOZILLA_CLIENT - #ifndef W32 -*************** -*** 1727,1755 **** - } - - #endif // END OF HUNSPELL_EXPERIMENTAL CODE -- -- Hunhandle *Hunspell_create(const char * affpath, const char * dpath) -- { -- return (Hunhandle*)(new Hunspell(affpath, dpath)); -- } -- -- void Hunspell_destroy(Hunhandle *pHunspell) -- { -- delete (Hunspell*)(pHunspell); -- } -- -- int Hunspell_spell(Hunhandle *pHunspell, const char *word) -- { -- return ((Hunspell*)pHunspell)->spell(word); -- } -- -- char *Hunspell_get_dic_encoding(Hunhandle *pHunspell) -- { -- return ((Hunspell*)pHunspell)->get_dic_encoding(); -- } -- -- int Hunspell_suggest(Hunhandle *pHunspell, char*** slst, const char * word) -- { -- return ((Hunspell*)pHunspell)->suggest(slst, word); -- } -- ---- 1735,1737 ---- -*** misc/hunspell-1.1.12/src/hunspell/license.hunspell Thu Jun 14 14:07:47 2007 ---- misc/build/hunspell-1.1.12/src/hunspell/license.hunspell Thu Apr 10 20:27:15 2008 -*************** -*** 56,59 **** - * - * ***** END LICENSE BLOCK ***** */ - -- #include "config.h" ---- 56,58 ---- -*** misc/hunspell-1.1.12/src/hunspell/makefile.mk Fri Apr 6 10:05:32 2007 ---- misc/build/hunspell-1.1.12/src/hunspell/makefile.mk Thu Apr 10 20:28:34 2008 -*************** -*** 60,70 **** - # - #************************************************************************* - -! PRJ = .. - - PRJNAME = hunspell - TARGET = hunspell -! LIBTARGET=NO - - #----- Settings --------------------------------------------------------- - ---- 60,70 ---- - # - #************************************************************************* - -! PRJ = ../../../../../.. - - PRJNAME = hunspell - TARGET = hunspell -! LIBTARGET=YES - - #----- Settings --------------------------------------------------------- - -*************** -*** 73,79 **** - # --- Files -------------------------------------------------------- - - # all_target: ALLTAR DICTIONARY -! all_target: ALLTAR - - ##CXXFLAGS += -I..$/..$/lingutil - ##CFLAGSCXX += -I..$/..$/lingutil ---- 73,79 ---- - # --- Files -------------------------------------------------------- - - # all_target: ALLTAR DICTIONARY -! #all_target: ALLTAR - - ##CXXFLAGS += -I..$/..$/lingutil - ##CFLAGSCXX += -I..$/..$/lingutil -*************** -*** 81,87 **** - - CDEFS+=-DOPENOFFICEORG - -! SLOFILES= \ - $(SLO)$/affentry.obj \ - $(SLO)$/affixmgr.obj \ - $(SLO)$/dictmgr.obj \ ---- 81,87 ---- - - CDEFS+=-DOPENOFFICEORG - -! OBJFILES= \ - $(SLO)$/affentry.obj \ - $(SLO)$/affixmgr.obj \ - $(SLO)$/dictmgr.obj \ -*************** -*** 93,99 **** - - LIB1TARGET= $(SLB)$/lib$(TARGET).lib - LIB1ARCHIV= $(LB)/lib$(TARGET).a -! LIB1OBJFILES= $(SLOFILES) - - # DIC2BIN= \ - # en_US.aff \ ---- 93,99 ---- - - LIB1TARGET= $(SLB)$/lib$(TARGET).lib - LIB1ARCHIV= $(LB)/lib$(TARGET).a -! LIB1OBJFILES= $(OBJFILES) - - # DIC2BIN= \ - # en_US.aff \ -*** misc/hunspell-1.1.12/src/hunspell/suggestmgr.cxx Tue Sep 4 13:21:26 2007 ---- misc/build/hunspell-1.1.12/src/hunspell/suggestmgr.cxx Thu Apr 10 20:27:15 2008 -*************** -*** 118,124 **** - return ns; - } - -! // generate suggestions for a mispelled word - // pass in address of array of char * pointers - // onlycompoundsug: probably bad suggestions (need for ngram sugs, too) - ---- 118,124 ---- - return ns; - } - -! // generate suggestions for a misspelled word - // pass in address of array of char * pointers - // onlycompoundsug: probably bad suggestions (need for ngram sugs, too) - -diff -urNad hunspell-1.1.9~/src/hunspell/csutil.cxx hunspell-1.1.9/src/hunspell/csutil.cxx ---- hunspell-1.1.9~/src/hunspell/csutil.cxx 2007-07-16 08:48:38.000000000 +0200 -+++ misc/build/hunspell-1.1.12/src/hunspell/csutil.cxx 2008-04-07 00:13:28.000000000 +0200 -@@ -4937,7 +4937,7 @@ + // HUNSTEM def. + #define HUNSTEM + +@@ -91,8 +91,3 @@ + }; + + #endif +- +- +- +- +- +--- misc/hunspell-1.1.12/src/hunspell/csutil.cxx 2007-08-23 09:27:39.000000000 +0200 ++++ misc/build/hunspell-1.1.12/src/hunspell/csutil.cxx 2008-04-23 22:59:31.000000000 +0200 +@@ -18,12 +18,12 @@ + #include "langnum.hxx" + + #ifdef OPENOFFICEORG +-# include <unicode/uchar.h> ++#include <unicode/uchar.h> + #else +-# ifndef MOZILLA_CLIENT +-# include "utf_info.cxx" +-# define UTF_LST_LEN (sizeof(utf_lst) / (sizeof(unicode_info))) +-# endif ++#ifndef MOZILLA_CLIENT ++#include "utf_info.cxx" ++#define UTF_LST_LEN (sizeof(utf_lst) / (sizeof(unicode_info))) ++#endif + #endif + + #ifdef MOZILLA_CLIENT +@@ -125,7 +125,7 @@ + case 0x90: + case 0xa0: + case 0xb0: { +- HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Unexpected continuation bytes in %d. character position\n%s\n", u8 - src, src); ++ HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Unexpected continuation bytes in %ld. character position\n%s\n", static_cast<long>(u8 - src), src); + u2->h = 0xff; + u2->l = 0xfd; + break; +@@ -137,7 +137,7 @@ + u2->l = (*u8 << 6) + (*(u8+1) & 0x3f); + u8++; + } else { +- HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Missing continuation byte in %d. character position:\n%s\n", u8 - src, src); ++ HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Missing continuation byte in %ld. character position:\n%s\n", static_cast<long>(u8 - src), src); + u2->h = 0xff; + u2->l = 0xfd; + } +@@ -151,12 +151,12 @@ + u2->l = (*u8 << 6) + (*(u8+1) & 0x3f); + u8++; + } else { +- HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Missing continuation byte in %d. character position:\n%s\n", u8 - src, src); ++ HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Missing continuation byte in %ld. character position:\n%s\n", static_cast<long>(u8 - src), src); + u2->h = 0xff; + u2->l = 0xfd; + } + } else { +- HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Missing continuation byte in %d. character position:\n%s\n", u8 - src, src); ++ HUNSPELL_WARNING(stderr, "UTF-8 encoding error. Missing continuation byte in %ld. character position:\n%s\n", static_cast<long>(u8 - src), src); + u2->h = 0xff; + u2->l = 0xfd; + } +@@ -4939,7 +4939,7 @@ { 0x00, 0xff, 0xff }, }; @@ -377,3 +128,118 @@ diff -urNad hunspell-1.1.9~/src/hunspell/csutil.cxx hunspell-1.1.9/src/hunspell/ {"ISO8859-1",iso1_tbl}, {"ISO8859-2",iso2_tbl}, {"ISO8859-3",iso3_tbl}, +--- misc/hunspell-1.1.12/src/hunspell/hunspell.cxx 2007-08-28 15:17:30.000000000 +0200 ++++ misc/build/hunspell-1.1.12/src/hunspell/hunspell.cxx 2008-04-23 22:59:31.000000000 +0200 +@@ -1,3 +1,7 @@ ++#ifdef _MSC_VER ++#pragma setlocale("C") ++#endif ++ + #include "license.hunspell" + #include "license.myspell" + +@@ -12,7 +16,11 @@ + #endif + + #include "hunspell.hxx" +-#include "hunspell.h" ++#ifndef OPENOFFICEORG ++#ifndef MOZILLA_CLIENT ++//#include "hunspell.h" ++#endif ++#endif + + #ifndef MOZILLA_CLIENT + #ifndef W32 +@@ -1727,29 +1735,3 @@ + } + + #endif // END OF HUNSPELL_EXPERIMENTAL CODE +- +-Hunhandle *Hunspell_create(const char * affpath, const char * dpath) +-{ +- return (Hunhandle*)(new Hunspell(affpath, dpath)); +-} +- +-void Hunspell_destroy(Hunhandle *pHunspell) +-{ +- delete (Hunspell*)(pHunspell); +-} +- +-int Hunspell_spell(Hunhandle *pHunspell, const char *word) +-{ +- return ((Hunspell*)pHunspell)->spell(word); +-} +- +-char *Hunspell_get_dic_encoding(Hunhandle *pHunspell) +-{ +- return ((Hunspell*)pHunspell)->get_dic_encoding(); +-} +- +-int Hunspell_suggest(Hunhandle *pHunspell, char*** slst, const char * word) +-{ +- return ((Hunspell*)pHunspell)->suggest(slst, word); +-} +- +--- misc/hunspell-1.1.12/src/hunspell/license.hunspell 2007-06-14 14:07:47.000000000 +0200 ++++ misc/build/hunspell-1.1.12/src/hunspell/license.hunspell 2008-04-23 22:59:31.000000000 +0200 +@@ -56,4 +56,3 @@ + * + * ***** END LICENSE BLOCK ***** */ + +-#include "config.h" +--- misc/hunspell-1.1.12/src/hunspell/makefile.mk 2007-04-06 10:05:32.000000000 +0200 ++++ misc/build/hunspell-1.1.12/src/hunspell/makefile.mk 2008-04-23 23:00:30.000000000 +0200 +@@ -60,11 +60,12 @@ + # + #************************************************************************* + +-PRJ = .. ++PRJ = ../../../../../.. + + PRJNAME = hunspell + TARGET = hunspell +-LIBTARGET=NO ++LIBTARGET=YES ++EXTERNAL_WARNINGS_NOT_ERRORS := TRUE + + #----- Settings --------------------------------------------------------- + +@@ -73,7 +74,7 @@ + # --- Files -------------------------------------------------------- + + # all_target: ALLTAR DICTIONARY +-all_target: ALLTAR ++#all_target: ALLTAR + + ##CXXFLAGS += -I..$/..$/lingutil + ##CFLAGSCXX += -I..$/..$/lingutil +@@ -81,7 +82,7 @@ + + CDEFS+=-DOPENOFFICEORG + +-SLOFILES= \ ++OBJFILES= \ + $(SLO)$/affentry.obj \ + $(SLO)$/affixmgr.obj \ + $(SLO)$/dictmgr.obj \ +@@ -93,7 +94,7 @@ + + LIB1TARGET= $(SLB)$/lib$(TARGET).lib + LIB1ARCHIV= $(LB)/lib$(TARGET).a +-LIB1OBJFILES= $(SLOFILES) ++LIB1OBJFILES= $(OBJFILES) + + # DIC2BIN= \ + # en_US.aff \ +--- misc/hunspell-1.1.12/src/hunspell/suggestmgr.cxx 2007-09-04 13:21:26.000000000 +0200 ++++ misc/build/hunspell-1.1.12/src/hunspell/suggestmgr.cxx 2008-04-23 22:59:31.000000000 +0200 +@@ -118,7 +118,7 @@ + return ns; + } + +-// generate suggestions for a mispelled word ++// generate suggestions for a misspelled word + // pass in address of array of char * pointers + // onlycompoundsug: probably bad suggestions (need for ngram sugs, too) + |