Date: Wednesday, January 19, 2011 @ 04:42:18 Author: bisson Revision: 106797
address FS#20482 Added: m17n-lib/trunk/locale.patch Modified: m17n-lib/trunk/PKGBUILD --------------+ PKGBUILD | 9 ++++++--- locale.patch | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 57 insertions(+), 3 deletions(-) Modified: PKGBUILD =================================================================== --- PKGBUILD 2011-01-19 09:36:23 UTC (rev 106796) +++ PKGBUILD 2011-01-19 09:42:18 UTC (rev 106797) @@ -3,7 +3,7 @@ pkgname=m17n-lib pkgver=1.6.2 -pkgrel=1 +pkgrel=2 pkgdesc='A multilingual text processing library (runtimes)' arch=('i686' 'x86_64') url='http://www.m17n.org/m17n-lib/' @@ -11,11 +11,14 @@ depends=('libxft' 'm17n-db' 'fribidi' 'libxml2' 'gd' 'libotf>=0.9.11') optdepends=('anthy: to use the anthy input method') options=('!libtool' '!makeflags') -source=("http://www.m17n.org/m17n-lib-download/$pkgname-$pkgver.tar.gz") -sha1sums=('9b9ada79357dd56c90c64cd36845c5537c363d79') +source=("http://www.m17n.org/m17n-lib-download/$pkgname-$pkgver.tar.gz" + 'locale.patch') +sha1sums=('9b9ada79357dd56c90c64cd36845c5537c363d79' + '55a09b9d8e6ea590d5c8f06d1397bfa0b00c1697') build() { cd "$srcdir/$pkgname-$pkgver" + patch -p1 -i ../locale.patch # cf. FS#20482 ./configure --prefix=/usr make } Added: locale.patch =================================================================== --- locale.patch (rev 0) +++ locale.patch 2011-01-19 09:42:18 UTC (rev 106797) @@ -0,0 +1,51 @@ +--- old/src/locale.c 2010/03/19 11:59:43 1.12 ++++ new/src/locale.c 2010/11/05 11:20:41 1.13 +@@ -86,34 +86,24 @@ + MLocale *mlocale_monetary, *mlocale_numeric, ; + #endif + +-/** Parse locale name NAME and return a newly created MLocale object. +- If the locale is not supported by the system, return NULL. */ ++/** Parse locale name NAME and return a newly created MLocale object. */ + + static MLocale * + make_locale (const char *name) + { +- char *current, *new, *str; ++ char *str; + int len; + MLocale *locale; + char c; + +- str = setlocale (LC_CTYPE, NULL); +- len = strlen (str) + 1; +- current = alloca (len); +- memcpy (current, str, len); +- +- if (! (new = setlocale (LC_CTYPE, name))) +- return NULL; +- +- + M17N_OBJECT (locale, NULL, MERROR_LOCALE); +- locale->name = msymbol (new); ++ locale->name = msymbol (name); + msymbol_put (locale->name, M_locale, (void *) locale); + M17N_OBJECT_UNREF (locale); + +- len = strlen (new) + 1; ++ len = strlen (name) + 1; + str = alloca (len); +- memcpy (str, new, len); ++ memcpy (str, name, len); + + c = '\0'; + while (1) +@@ -162,8 +152,6 @@ + } + else + locale->coding = Mcoding_us_ascii; +- +- setlocale (LC_CTYPE, current); + return locale; + } +