Re: Undefined __GNUC_GNU_INLINE__

2013-10-18 Thread Vladimir 'φ-coder/phcoder' Serbinenko
On 18.10.2013 17:40, Eric Blake wrote: > On 10/18/2013 09:30 AM, Vladimir 'φ-coder/phcoder' Serbinenko wrote: >> When testing with old gcc, I found out that gnulib uses >> __GNUC_GNU_INLINE__ without checking whether it's defined first. I >> propose follow

Undefined __GNUC_GNU_INLINE__

2013-10-18 Thread Vladimir 'φ-coder/phcoder' Serbinenko
When testing with old gcc, I found out that gnulib uses __GNUC_GNU_INLINE__ without checking whether it's defined first. I propose following fix: === modified file 'm4/extern-inline.m4' --- m4/extern-inline.m4 2013-04-11 19:12:46 + +++ m4/extern-inline.m4 2013-10-18 14:55:19 + @@ -32,7 +32

Windows and Unicode

2013-10-11 Thread Vladimir 'φ-coder/phcoder' Serbinenko
Hello, all. I've been experimenting in porting a GNU project to Windows while preserving Unicode capability. Prepending _t everywhere like Microsoft suggest is hardly an option due to change of code it requires and subtle problems with it. E.g. consider code: s = malloc (strlen (a) + strlen (b) +

Re: gnulib and i18n

2012-09-18 Thread Vladimir 'φ-coder/phcoder' Serbinenko
ationproject.org/domain/gnulib.html). Because of this I'm somewhat reluctant to use it myself. > Translators have to deal with the problem of > shared strings independently of gnulib so the problem is not > as big a deal as one might at first think. > > > -- Regards Vla

Re: Gnulib translation

2012-04-21 Thread Vladimir 'φ-coder/phcoder' Serbinenko
? Why not add a new option to gnulib gnulib --make-pot which would list all files belonging to modules and feed it to xgettext? Looks like it's not difficult to do. -- Regards Vladimir 'φ-coder/phcoder' Serbinenko signature.asc Description: OpenPGP digital signature

Re: Gnulib translation

2012-04-21 Thread Vladimir 'φ-coder/phcoder' Serbinenko
en > $ cd po; make gnulib.pot > or > $ cd po; make update-po Sounds like not trivial. Should I make a script for this? > Bruno > > [1] http://lists.gnu.org/archive/html/bug-gnulib/2007-07/msg00194.html > [2] http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00026.ht

Re: [PATCH, resend] Handle multibyte codepoint width properly

2012-04-20 Thread Vladimir 'φ-coder/phcoder' Serbinenko
at you want to avoid code duplication, > then the trick is to move the common parts to a .h file that gets #included > by the two test-*.c files. Ok, will do. I have sent my paperwork to FSF. > Take a look at, for example, test-log.h, test-log.c, test-logl.c. > > Bruno > >

Re: Gnulib translation

2012-04-20 Thread Vladimir 'φ-coder/phcoder' Serbinenko
On 07.04.2012 05:18, Paul Eggert wrote: > On 04/05/2012 04:01 PM, Vladimir 'φ-coder/phcoder' Serbinenko wrote: >> On 06.04.2012 00:14, Paul Eggert wrote: >>>> On 04/05/2012 03:06 PM, Vladimir 'φ-coder/phcoder' Serbinenko wrote: >>>> &g

Re: Piping sed stalls on OpenSolaris 2010.03

2012-04-13 Thread Vladimir 'φ-coder/phcoder' Serbinenko
sible to detect it on configure time and issue appropriate error? -- Regards Vladimir 'φ-coder/phcoder' Serbinenko signature.asc Description: OpenPGP digital signature

Re: Gnulib translation

2012-04-05 Thread Vladimir 'φ-coder/phcoder' Serbinenko
On 06.04.2012 00:14, Paul Eggert wrote: > On 04/05/2012 03:06 PM, Vladimir 'φ-coder/phcoder' Serbinenko wrote: > >> I mean updating the pot file used at >> http://translationproject.org/domain/gnulib.html > Ah, in that case you can just contact the Translation Proj

Re: Gnulib translation

2012-04-05 Thread Vladimir 'φ-coder/phcoder' Serbinenko
On 05.04.2012 23:58, Paul Eggert wrote: > On 04/05/2012 10:26 AM, Vladimir 'φ-coder/phcoder' Serbinenko wrote: >> Currently GRUB uses the "old" way of gnulib translation (importing into >> our domain) but we'll change for the next release. With that there

Re: [PATCH, resend] Handle multibyte codepoint width properly

2012-04-05 Thread Vladimir 'φ-coder/phcoder' Serbinenko
I hope I hooked it in correctly. Couldn't check yet -- Regards Vladimir 'φ-coder/phcoder' Serbinenko diff --git a/lib/argp-fmtstream.c b/lib/argp-fmtstream.c index 70e3eb8..2db995c 100644 --- a/lib/argp-fmtstream.c +++ b/lib/argp-fmtstream.c @@ -29,9 +29,11 @@ #include #inc

Re: [PATCH, resend] Handle multibyte codepoint width properly

2012-04-05 Thread Vladimir 'φ-coder/phcoder' Serbinenko
is locale and ru_RU for tests like this. Could we perhaps try the locale `locale -a |grep utf8|head -n` as fallback? -- Regards Vladimir 'φ-coder/phcoder' Serbinenko signature.asc Description: OpenPGP digital signature

Re: [PATCH, resend] Handle multibyte codepoint width properly

2012-04-05 Thread Vladimir 'φ-coder/phcoder' Serbinenko
R.UTF-8 >installed, it would be unlikely that it has ru_RU.UTF-8 installed.) > - test-mbsstr2.sh is a wrapper script that uses the LOCALE_FR_UTF8 >value, determined by m4/locale-fr.m4, and invokes test-mbsstr2. I have created separate files but haven't hooked it up in the syst

Re: [PATCH, resend] Handle multibyte codepoint width properly

2012-04-05 Thread Vladimir 'φ-coder/phcoder' Serbinenko
FD, end = 0xFFFE on a 32-bit machine.) > Sure, on many systems this won't matter, because this memory range is > either unmapped or occupied by the stack. But in general you have no guarantee > that the memory page from 0xC000..0x will not be used for > malloc(). I have already been bitten by this once on sparc64 with GRUB :( > Bruno > > -- Regards Vladimir 'φ-coder/phcoder' Serbinenko signature.asc Description: OpenPGP digital signature

Re: [PATCH, resend] Handle multibyte codepoint width properly

2012-04-05 Thread Vladimir 'φ-coder/phcoder' Serbinenko
On 05.04.2012 17:58, Vladimir 'φ-coder/phcoder' Serbinenko wrote: > On 05.04.2012 14:32, Bruno Haible wrote: > > Remaining is the issue due to escape sequences. Fixed patch. Now with highlight sequence support. >> - You have shown a test case as a Cyrillic string. But w

Gnulib translation

2012-04-05 Thread Vladimir 'φ-coder/phcoder' Serbinenko
y UTF-8 support. Could gnulib scripts be modified to run msgconv or should I do it in my own scripts? Or simply ignore these translations given that they are often pretty outdated anyway? -- Regards Vladimir 'φ-coder/phcoder' Serbinenko signature.asc Description: OpenPGP digital signature

Re: [PATCH, resend] Handle multibyte codepoint width properly

2012-04-05 Thread Vladimir 'φ-coder/phcoder' Serbinenko
ode to > tests/test-argp.c, > or create a new test file tests/test-argp-3.c? Done but the test is valid only for UTF-8 locales. Should I force some specific locale? It's impossible to make a test working in all locales since in case of e.g. ASCII we don't have such characters a

Re: [PATCH, resend] Handle multibyte codepoint width properly

2012-04-05 Thread Vladimir 'φ-coder/phcoder' Serbinenko
but they would result in incorrect output no matter what). -- Regards Vladimir 'φ-coder/phcoder' Serbinenko signature.asc Description: OpenPGP digital signature

Re: [PATCH, resend] Handle multibyte codepoint width properly

2012-04-05 Thread Vladimir 'φ-coder/phcoder' Serbinenko
To this effect, can you > fill out the form at gnulib/doc/Copyright/request-assign.future and submit > it, please? I have the assignment covering any contribution to GRUB. So this should go pretty quickly. Alternatively I can commit it in GRUB and you'll lift it from there. > Bruno > > [1] http://lists.gnu.org/archive/html/bug-gnulib/2012-02/msg00072.html > [2] http://lists.gnu.org/archive/html/bug-gnulib/2012-03/msg00170.html > > > -- Regards Vladimir 'φ-coder/phcoder' Serbinenko signature.asc Description: OpenPGP digital signature

GCC 4.4 at least for mips has no -Wsuggest-attribute=pure

2012-04-04 Thread Vladimir 'φ-coder/phcoder' Serbinenko
Which makes compilation fail in regex.c on # if (__GNUC__ == 4 && 3 <= __GNUC_MINOR__) || 4 < __GNUC__ # pragma GCC diagnostic ignored "-Wsuggest-attribute=pure" # pragma GCC diagnostic ignored "-Wtype-limits" # endif -- Regards Vladimir 'φ-code

[PATCH, resend] Handle multibyte codepoint width properly

2012-04-03 Thread Vladimir &#x27;φ-coder/phcoder' Serbinenko
I'm not sure if previous time I sent with or without \0 bugfix. Resending -- Regards Vladimir 'φ-coder/phcoder' Serbinenko diff --git a/lib/argp-fmtstream.c b/lib/argp-fmtstream.c index 70e3eb8..148bfda 100644 --- a/lib/argp-fmtstream.c +++ b/lib/argp-fmtstream.c @@ -29,6 +29

[PATCH] Use opaque struct rather than char * in regex.h

2012-04-03 Thread Vladimir &#x27;φ-coder/phcoder' Serbinenko
sting char * to a re_dfa_t *. Attached patch fixes it -- Regards Vladimir 'φ-coder/phcoder' Serbinenko diff --git a/lib/regcomp.c b/lib/regcomp.c index 311f2d5..0ddff4c 100644 --- a/lib/regcomp.c +++ b/lib/regcomp.c @@ -778,7 +778,7 @@ re_compile_internal (regex_t *preg, const char *

Re: [PATCH] Add const qualifier for charset_name in init_dfa

2012-03-30 Thread Vladimir &#x27;φ-coder/phcoder' Serbinenko
On 26.03.2012 03:24, Vladimir 'φ-coder/phcoder' Serbinenko wrote: > In GRUB charset is hardwired to UTF-8 and we return just a pointer to > "UTF-8" in nl_langinfo (CODESET); > I propose adding const qualifier since this function already handles > codeset_name a

Re: Fix wrong character count in argp

2012-03-26 Thread Vladimir &#x27;φ-coder/phcoder' Serbinenko
или необязательные аргументы для длинных ключей также являются обязательными или необязательными для соответствующих коротких ключей." (break after "являются") Do you need anything else to incorporate my patch? -- Regards Vladimir 'φ-coder/phcoder' Serbinenko signature.asc Description: OpenPGP digital signature

Re: abort() in regex.c

2012-03-26 Thread Vladimir &#x27;φ-coder/phcoder' Serbinenko
created (we have no FS writing) so debug value of abort() is the same as normal printf. On the other hand abort()ing will most likely result in an unbootable system instead of a glitch in glob expansion (primary use of regex in GRUB). Having the whole system unbootable would make the debugging harder. &g

abort() in regex.c

2012-03-25 Thread Vladimir &#x27;φ-coder/phcoder' Serbinenko
null. */ @@ -1151,7 +1157,10 @@ optimize_utf8 (re_dfa_t *dfa) } break; default: +#ifdef HAVE_ABORT abort (); +#endif +break; } if (mb_chars || has_period) -- Regards Vladimir 'φ-coder/phcoder' Serbinenko signature.asc Description: OpenPGP digital signature

[PATCH] Add const qualifier for charset_name in init_dfa

2012-03-25 Thread Vladimir &#x27;φ-coder/phcoder' Serbinenko
NABLE_I18N size_t max_i18n_object_size = MAX (sizeof (wchar_t), sizeof (wctype_t)); -- Regards Vladimir 'φ-coder/phcoder' Serbinenko signature.asc Description: OpenPGP digital signature

Re: Fix wrong character count in argp

2012-02-12 Thread Vladimir &#x27;φ-coder/phcoder' Serbinenko
vide a test program, some input data, and the expected > output for this data? We can then turn it into a gnulib test. I can strip down one of our programs to keep just --help when time permits. > Bruno > > -- Regards Vladimir 'φ-coder/phcoder' Serbinenko === modified fil

Fix wrong character count in argp

2012-02-12 Thread Vladimir &#x27;φ-coder/phcoder' Serbinenko
As already reported several years ago argp counts bytes even when actually what matters is the display length. This patch improves the situation by counting only leading and standalone UTF-8 bytes. It doesn't handle the double-width characters like Chinese sinograms -- Regards Vladimir &#x

Re: canonicalize_file_name should support win32 shortcuts

2011-08-23 Thread Vladimir &#x27;φ-coder/phcoder' Serbinenko
and memory usage benefits occur in normal conditions. But your argumentation makes sense as well. In such cases it's mostly maintainer's personal preference which matters. > Bruno > > -- Regards Vladimir 'φ-coder/phcoder' Serbinenko signature.asc Description: OpenPGP digital signature

Re: canonicalize_file_name should support win32 shortcuts

2011-08-23 Thread Vladimir &#x27;φ-coder/phcoder' Serbinenko
lement it in gnulib, just not until the end of my exams -- Regards Vladimir 'φ-coder/phcoder' Serbinenko signature.asc Description: OpenPGP digital signature

Re: lib/regex_internal.h uses #if _LIBC instead of #if defined (_LIBC)

2009-12-29 Thread Vladimir &#x27;φ-coder/phcoder' Serbinenko
Simon Josefsson wrote: > "Vladimir 'φ-coder/phcoder' Serbinenko" writes: > > >> === modified file 'gnulib/regex_internal.h' >> --- gnulib/regex_internal.h2009-12-27 15:37:18 + >> +++ gnulib/regex_internal.h2009-12-29

lib/regex_internal.h uses #if _LIBC instead of #if defined (_LIBC)

2009-12-29 Thread Vladimir &#x27;φ-coder/phcoder' Serbinenko
_WCTYPE_H && HAVE_ISWCTYPE && HAVE_WCSCOLL) || _LIBC +#if (defined MB_CUR_MAX && HAVE_LOCALE_H && HAVE_WCTYPE_H && HAVE_ISWCTYPE && HAVE_WCSCOLL) || defined (_LIBC) # define RE_ENABLE_I18N #endif -- Regards Vladimir 'φ-coder/phcoder' Serbinenko signature.asc Description: OpenPGP digital signature