12007-11-07 Bruno Haible <bruno@clisp.org> 2 3 * gettext-0.17 released. 4 52007-10-28 Bruno Haible <bruno@clisp.org> 6 7 * color.c (style_file_lookup): New function. 8 (style_file_prepare): Use it. 9 102007-10-21 Bruno Haible <bruno@clisp.org> 11 12 Normalize the leading space of every comment line during input, not 13 during output. 14 * read-catalog-abstract.c (po_callback_comment_dispatcher): Before 15 calling po_callback_comment or po_callback_comment_dot, drop the 16 leading space. 17 * write-po.c (message_print_comment, message_print_comment_dot): Don't 18 remove the leading space of every comment line. 19 * write-stringtable.c (write_message): Likewise. 20 Suggested by Dwayne Bailey <dwayne@translate.org.za>. 21 222007-10-20 Bruno Haible <bruno@clisp.org> 23 24 * msgmerge.c (message_merge): Set the fuzzy flag if the msgid_plural 25 changed. 26 Suggested by Chusslove Illich (������������ ��������) <caslav.ilic@gmx.net>. 27 282007-10-20 Bruno Haible <bruno@clisp.org> 29 30 Make msgmerge's introduction of fuzzy markers more consistent with 31 msgfmt's --check-format. 32 * format.h (check_msgid_msgstr_format_i): New declaration. 33 * format.c (check_msgid_msgstr_format_i): New function, extracted from 34 check_msgid_msgstr_format. 35 (check_msgid_msgstr_format): Use it. 36 * msgl-check.h: Include plural-eval.h. 37 (check_plural_eval): New declaration. 38 * msgl-check.c (check_plural_eval): Add const to first parameter. Make 39 non-static. 40 (check_plural): Update. 41 * msgmerge.c: Include plural-exp.h, msgl-check.h, po-xerror.h. 42 (msgfmt_check_pair_fails): Remove function. 43 (silent_error_logger, silent_xerror): New functions. 44 (message_merge): Add plural_distribution, plural_distribution_length 45 arguments. Call check_msgid_msgstr_format_i instead of 46 msgfmt_check_pair_fails. 47 (match_domain): Extract not only the plural count, but also the 48 plural expression from the header entry. Determine the plural 49 distribution from it. Pass it to message_merge. 50 Reported by Chusslove Illich (������������ ��������) <caslav.ilic@gmx.net>. 51 522007-10-20 Bruno Haible <bruno@clisp.org> 53 54 * msgl-check.c (check_plural): If there is no header entry, or if the 55 header entry does not contain plural= and nplurals=, return a plural 56 distribution corresponding to the Germanic plural. 57 582007-10-20 Bruno Haible <bruno@clisp.org> 59 60 * format.h (check_msgid_msgstr_format): Add plural_distribution_length 61 argument. 62 * format.c (check_msgid_msgstr_format): Likewise. 63 * msgl-check.h (check_message): Likewise. 64 * msgl-check.c (check_plural_eval, check_plural, check_pair, 65 check_message): Likewise. 66 (check_message_list): Update. 67 682007-10-18 Bruno Haible <bruno@clisp.org> 69 70 * plural-count.c (get_plural_count): Adapt to changed prototype of 71 extract_plural_expression. 72 * write-csharp.c (write_csharp_expression): Add const to parameter. 73 (write_csharp_code): Adapt to changed prototype of 74 extract_plural_expression. 75 * write-java.c (write_java_expression): Add const to parameter. 76 (write_java_code): Adapt to changed prototype of 77 extract_plural_expression. 78 792007-10-07 Bruno Haible <bruno@clisp.org> 80 81 * hostname.c (main): In the --version output, say GPLv3+. 82 * msgattrib.c (main): Likewise. 83 * msgcat.c (main): Likewise. 84 * msgcmp.c (main): Likewise. 85 * msgcomm.c (main): Likewise. 86 * msgconv.c (main): Likewise. 87 * msgen.c (main): Likewise. 88 * msgexec.c (main): Likewise. 89 * msgfilter.c (main): Likewise. 90 * msgfmt.c (main): Likewise. 91 * msggrep.c (main): Likewise. 92 * msginit.c (main): Likewise. 93 * msgmerge.c (main): Likewise. 94 * msgunfmt.c (main): Likewise. 95 * msguniq.c (main): Likewise. 96 * recode-sr-latin.c (main): Likewise. 97 * urlget.c (main): Likewise. 98 * xgettext.c (main): Likewise. 99 1002007-09-30 Bruno Haible <bruno@clisp.org> 101 102 * xgettext.c (package_name, package_version): New variables. 103 (long_options): Add --package-name, --package-version. 104 (main): Handle options --package-name, --package-version. 105 (usage): Document them. 106 (construct_header): Use package_name if present. 107 * msginit.c (project_id_version): Take a header argument. Return the 108 old value if already present. 109 (fields): Update. 110 1112007-09-30 Bruno Haible <bruno@clisp.org> 112 113 * message.h (format_type): New enum value 'format_kde'. 114 (NFORMATS): Increment. 115 * message.c (format_language): Add format_kde entry. 116 (format_language_pretty): Likewise. 117 * format.h (formatstring_kde): New declaration. 118 * format-kde.c: New file. 119 * format.c (formatstring_parsers): Add formatstring_kde. 120 * x-c.c (init_flag_table_c): Also register flags for qt-format and 121 kde-format. 122 * xgettext.c (flag_table_cxx_kde): New variable. 123 (recognize_format_kde): New variable. 124 (main): Handle --kde option. 125 (usage): Document --kde option. 126 (xgettext_record_flag): Also fill flag_table_cxx_kde. 127 (remember_a_message, remember_a_message_plural): In the heuristics, 128 don't mark a string as c-format that is already known to be a 129 kde-format. 130 (language_to_extractor): Use a flag_table_cxx_kde that is different 131 from flag_table_c. 132 * Makefile.am (FORMAT_SOURCE): Add format-kde.c. 133 * FILES: Update. 134 1352007-09-09 Bruno Haible <bruno@clisp.org> 136 137 Add support for Qt 4 format strings. 138 * format-qt.c (struct spec): Increase args_used field size to 100. 139 Add 'simple' field. 140 (format_parse): Update for Qt 4 syntax. Remove error message when the 141 same format argument is used more than once. 142 (format_check): Add check: If the msgid is simple, the msgstr must be 143 simple as well. 144 Reported by Chusslove Illich <caslav.ilic@gmx.net>. 145 1462007-09-02 Bruno Haible <bruno@clisp.org> 147 148 Correct handling of different libexpat ABIs. 149 * x-glade.c: Include <stdint.h>. 150 (p_XML_GetCurrentLineNumber, p_XML_GetCurrentColumnNumber): New 151 variables. 152 (is_XML_LARGE_SIZE_ABI, GetCurrentLineNumber, GetCurrentColumnNumber): 153 New functions. 154 (XML_GetCurrentLineNumber, XML_GetCurrentColumnNumber): Redefine. 155 (XML_Expat_Version, XML_FeatureEnum, XML_Feature): New types. 156 (p_XML_ExpatVersionInfo, p_XML_GetFeatureList): New variables. 157 (p_XML_GetCurrentLineNumber, p_XML_GetCurrentColumnNumber): Change 158 type to 'void *'. 159 (XML_ExpatVersionInfo, XML_GetFeatureList): New macros. 160 (XML_Size_ABI): New type. 161 (get_XML_Size_ABI): New function. 162 (XML_GetCurrentLineNumber, XML_GetCurrentColumnNumber): New functions. 163 (load_libexpat): Try both version 2 and version 1. Initialize 164 p_XML_ExpatVersionInfo, p_XML_GetFeatureList. 165 1662007-09-02 Bruno Haible <bruno@clisp.org> 167 168 Implement msgctxt for C# ResourceManagers. 169 * x-csharp.c (init_keywords): Also register GetParticularString and 170 GetParticularPluralString. 171 (init_flag_table_csharp): Update accordingly. 172 * write-csharp.c: Include xmalloca.h. 173 (write_csharp_msgid): New function. 174 (write_csharp_code): Use it instead of write_csharp_string. 175 (msgdomain_write_csharp): Remove error message if mlp has entries with 176 context. 177 * msgunfmt.cs (DumpResource.DumpMessage): Emit an msgctxt line 178 if the message contain the context separator. 179 1802007-09-01 Bruno Haible <bruno@clisp.org> 181 182 Implement msgctxt for Java ResourceBundles. 183 * x-java.c (init_keywords): Also register pgettext and npgettext. 184 (init_flag_table_java): Update accordingly. 185 * write-java.c (msgid_hashcode): New function. 186 (compute_hashsize, compute_table_items): Use it instead of 187 string_hashcode. 188 (write_java_msgid): New function. 189 (write_java_code): Use it instead of write_java_string. 190 (msgdomain_write_java): Remove error message if mlp has entries with 191 context. 192 * gnu/gettext/DumpResource.java (dumpMessage): Emit an msgctxt line 193 if the message contain the context separator. 194 Suggested by Felix Berger. 195 1962007-09-01 Bruno Haible <bruno@clisp.org> 197 198 * po-lex.c: Include uniwidth.h. 199 2002007-06-19 Bruno Haible <bruno@clisp.org> 201 202 * x-c.c (phase8_get): Call free_token, so that the reference to 203 tmp.comment gets dropped. 204 2052007-08-27 Bruno Haible <bruno@clisp.org> 206 207 * x-python.c (phase7_getuc): Interpret octal and hexadecimal escapes 208 as Unicode code points inside Unicode strings. 209 Reported and patch by Jakub Wilk <ubanus@users.sf.net>. 210 2112007-08-23 Bruno Haible <bruno@clisp.org> 212 213 * file-list.c: Don't include getline.h. 214 * format-awk.c: Likewise. 215 * format-boost.c: Likewise. 216 * format-c.c: Likewise. 217 * format-csharp.c: Likewise. 218 * format-elisp.c: Likewise. 219 * format-gcc-internal.c: Likewise. 220 * format-java.c: Likewise. 221 * format-librep.c: Likewise. 222 * format-lisp.c: Likewise. 223 * format-pascal.c: Likewise. 224 * format-perl-brace.c: Likewise. 225 * format-perl.c: Likewise. 226 * format-php.c: Likewise. 227 * format-python.c: Likewise. 228 * format-qt.c: Likewise. 229 * format-scheme.c: Likewise. 230 * format-sh.c: Likewise. 231 * format-tcl.c: Likewise. 232 * format-ycp.c: Likewise. 233 * msginit.c: Likewise. 234 * x-perl.c: Likewise. 235 2362007-08-18 Bruno Haible <bruno@clisp.org> 237 238 * write-csharp.c (msgdomain_write_csharp): Don't recommend to use 239 --verbose if it is already in use. 240 * write-java.c (msgdomain_write_java): Likewise. 241 Reported by Karsten Kousgaard <karsten@f-kousgaard.dk>. 242 2432007-07-07 Bruno Haible <bruno@clisp.org> 244 245 * Makefile.am (AM_CPPFLAGS): Remove reference to libuniname directory. 246 (LIBUNINAME): Remove variable. 247 (xgettext_LDADD): Update. 248 2492007-07-04 Bruno Haible <bruno@clisp.org> 250 251 Recognize the PHP string concatenation operator. 252 * x-php.c (enum token_type_ty): New elements token_type_dot, 253 token_type_operator1, token_type_operator2. 254 (struct token_ty): Add comment field. 255 (free_token): Drop reference to comment field. 256 (phase4_pushback, phase4_pushback_length): New variables. 257 (phase4_get): Renamed from x_php_lex. Return last pushed-back token if 258 available. Recognize tokens '.', '+', '-', '*', '/', '%', '++', '--', 259 '!', '~', '@'. Fill in tp->comment. 260 (phase4_unget): New function. 261 (phase5_last): New variable. 262 (x_php_lex): New function. 263 (extract_balanced): Handle the new token types. Pass token's comment 264 to remember_a_message. 265 (extract_php): Initialize phase5_last. 266 Reported by Jan Engelhardt <jengelh@computergmbh.de>. 267 2682007-06-30 Bruno Haible <bruno@clisp.org> 269 270 * hostname.c (main): Use the standard --version output, see 271 <http://lists.gnu.org/archive/html/bug-gnulib/2007-03/msg00302.html>. 272 * msgattrib.c (main): Likewise. 273 * msgcat.c (main): Likewise. 274 * msgcmp.c (main): Likewise. 275 * msgcomm.c (main): Likewise. 276 * msgconv.c (main): Likewise. 277 * msgen.c (main): Likewise. 278 * msgexec.c (main): Likewise. 279 * msgfilter.c (main): Likewise. 280 * msgfmt.c (main): Likewise. 281 * msggrep.c (main): Likewise. 282 * msginit.c (main): Likewise. 283 * msgmerge.c (main): Likewise. 284 * msgunfmt.c (main): Likewise. 285 * msguniq.c (main): Likewise. 286 * recode-sr-latin.c (main): Likewise. 287 * urlget.c (main): Likewise. 288 * xgettext.c (main): Likewise. 289 2902007-06-30 Bruno Haible <bruno@clisp.org> 291 292 * lang-table.c (language_table): Fix entry for Javanese. 293 2942007-06-28 Bruno Haible <bruno@clisp.org> 295 296 * format-gcc-internal.c (format_parse): Tweak an error message. 297 Reported by Karl Eichwalder. 298 2992007-06-28 Bruno Haible <bruno@clisp.org> 300 301 * lang-table.h (language_variant_table, language_variant_table_size): 302 New declarations. 303 * lang-table.c (language_variant_table, language_variant_table_size): 304 New variables. 305 * msginit.c (language_team_englishname): New function. 306 (language_team): Use it instead of englishname_of_language. 307 Reported by Li Daobing <lidaobing@gmail.com>. 308 3092007-06-25 Bruno Haible <bruno@clisp.org> 310 311 Change boundary of extracted comments. 312 * x-perl.c (struct token_ty): Add comment field. 313 (free_token): Release tp->comment. 314 (extract_quotelike): Fill in tp->comment. 315 (x_perl_prelex): Set or release tp->comment when constructing tokens. 316 (x_perl_lex): Likewise. 317 (extract_balanced): Pass token's comment to remember_a_message. 318 3192007-06-18 Bruno Haible <bruno@clisp.org> 320 321 Change boundary of extracted comments. 322 * x-ycp.c (struct token_ty): Add comment field. 323 (free_token): New function. 324 (phase5_get): Fill in tp->comment. 325 (phase8_get): Use free_token. 326 (extract_parenthesized): Pass token's comment to remember_a_message. 327 Use free_token. 328 Reported by Karl Eichwalder <ke@suse.de>. 329 3302007-06-09 Bruno Haible <bruno@clisp.org> 331 332 * format-java.c: Include xmalloca.h instead of xallocsa.h. 333 (message_format_parse): Use xmalloca/freea instead of xallocsa/freesa. 334 * message.c: Include xmalloca.h instead of xallocsa.h. 335 (message_list_hash_insert_entry, message_list_search): Use 336 xmalloca/freea instead of xallocsa/freesa. 337 * msggrep.c: Include xmalloca.h instead of xallocsa.h. 338 (is_message_selected_no_invert): Use xmalloca/freea instead of 339 xallocsa/freesa. 340 * msginit.c: Include xmalloca.h instead of xallocsa.h. 341 (subst_string): Use xmalloca/freea instead of xallocsa/freesa. 342 * msgl-cat.c: Include xmalloca.h instead of xallocsa.h. 343 (catenate_msgdomain_list): Use xmalloca/freea instead of 344 xallocsa/freesa. 345 * msgl-charset.c: Include xmalloca.h instead of xallocsa.h. 346 (compare_po_locale_charsets): Use xmalloca/freea instead of 347 xallocsa/freesa. 348 * msgl-iconv.c: Include xmalloca.h instead of xallocsa.h. 349 (iconv_message_list_internal, is_message_list_iconvable): Use 350 xmalloca/freea instead of xallocsa/freesa. 351 * msgmerge.c: Include xmalloca.h instead of xallocsa.h. 352 (merge): Use xmalloca/freea instead of xallocsa/freesa. 353 * po-charset.c: Include xmalloca.h instead of xallocsa.h. 354 (po_lex_charset_set): Use xmalloca/freea instead of xallocsa/freesa. 355 * read-tcl.c: Include xmalloca.h instead of xallocsa.h. 356 (msgdomain_read_tcl): Use xmalloca/freea instead of xallocsa/freesa. 357 * write-java.c: Include xmalloca.h instead of xallocsa.h. 358 (compute_hashsize, msgdomain_write_java): Use xmalloca/freea instead of 359 xallocsa/freesa. 360 * write-mo.c: Include xmalloca.h instead of xallocsa.h. 361 (write_table): Use xmalloca/freea instead of xallocsa/freesa. 362 * write-po.c: Include xmalloca.h instead of xallocsa.h. 363 (msgdomain_list_print_po): Use xmalloca/freea instead of 364 xallocsa/freesa. 365 * write-tcl.c: Include xmalloca.h instead of xallocsa.h. 366 (msgdomain_write_tcl): Use xmalloca/freea instead of xallocsa/freesa. 367 * xgettext.c: Include xmalloca.h instead of xallocsa.h. 368 (flag_context_list_table_insert): Use xmalloca/freea instead of 369 xallocsa/freesa. 370 3712007-06-08 Bruno Haible <bruno@clisp.org> 372 373 * msgattrib.c (main): Update year in --version output. 374 * msgcat.c (main): Likewise. 375 * msgcmp.c (main): Likewise. 376 * msgcomm.c (main): Likewise. 377 * msgconv.c (main): Likewise. 378 * msgen.c (main): Likewise. 379 * msgexec.c (main): Likewise. 380 * msgfilter.c (main): Likewise. 381 * msgfmt.c (main): Likewise. 382 * msggrep.c (main): Likewise. 383 * msginit.c (main): Likewise. 384 * msgmerge.c (main): Likewise. 385 * msgunfmt.c (main): Likewise. 386 * msguniq.c (main): Likewise. 387 * xgettext.c (main): Likewise. 388 * recode-sr-latin.c (main): Likewise. 389 * hostname.c (main): Likewise. 390 * urlget.c (main): Likewise. 391 3922007-06-08 Bruno Haible <bruno@clisp.org> 393 394 * msginit.c: Include localename.h. 395 (_nl_locale_name): Remove declaration. 396 (main): Use gl_locale_name instead of _nl_locale_name. 397 * Makefile.am (msginit_LDADD): Remove localename object file. 398 3992007-05-28 Bruno Haible <bruno@clisp.org> 400 401 * Makefile.am (WOE32_LDADD): New variable. 402 (LDADD, msgcmp_LDADD, msgfmt_LDADD, msgmerge_LDADD, msgunfmt_LDADD, 403 xgettext_LDADD, msgattrib_LDADD, msgcat_LDADD, msgcomm_LDADD, 404 msgconv_LDADD, msgen_LDADD, msgexec_LDADD, msgfilter_LDADD, 405 msggrep_LDADD, msginit_LDADD, msguniq_LDADD, recode_sr_latin_LDADD): 406 Include it. 407 (gettext.res): New rule. 408 (MOSTLYCLEANFILES): Add gettext.res. 409 4102007-05-27 Bruno Haible <bruno@clisp.org> 411 412 Avoid link error; u16_mbtouc_aux is no longer a public API. 413 * x-java.c (string_buffer_append): Use u16_mbtouc instead of 414 u16_mbtouc_aux. 415 * x-python.c (mixed_string_buffer_append): Likewise. 416 4172007-05-13 Bruno Haible <bruno@clisp.org> 418 419 * write-java.c (mkdir): Remove definition. Now done by gnulib. 420 * write-csharp.c (mkdir): Remove definition. Now done by gnulib. 421 4222007-05-13 Bruno Haible <bruno@clisp.org> 423 424 * msgl-check.c: Include stdio.h instead of vasprintf.h. 425 * po-lex.c: Don't include vasprintf.h. 426 4272007-03-27 Bruno Haible <bruno@clisp.org> 428 429 * hostname.c (usage): Ask translators to specify a translation bug 430 report address. 431 * msgattrib.c (usage): Likewise. 432 * msgcat.c (usage): Likewise. 433 * msgcmp.c (usage): Likewise. 434 * msgcomm.c (usage): Likewise. 435 * msgconv.c (usage): Likewise. 436 * msgen.c (usage): Likewise. 437 * msgexec.c (usage): Likewise. 438 * msgfilter.c (usage): Likewise. 439 * msgfmt.c (usage): Likewise. 440 * msggrep.c (usage): Likewise. 441 * msginit.c (usage): Likewise. 442 * msgmerge.c (usage): Likewise. 443 * msgunfmt.c (usage): Likewise. 444 * msguniq.c (usage): Likewise. 445 * recode-sr-latin.c (usage): Likewise. 446 * urlget.c (usage): Likewise. 447 * xgettext.c (usage): Likewise. 448 4492007-03-24 Bruno Haible <bruno@clisp.org> 450 451 * po-lex.c: Include unistr.h instead of utf8-ucs4.h. 452 * read-properties.c: Include unistr.h instead of utf16-ucs4.h, 453 ucs4-utf8.h. 454 * x-java.c: Likewise. 455 * read-stringtable.c: Include unistr.h instead of utf8-ucs4.h, 456 ucs4-utf8.h. 457 * x-csharp.c: Likewise. 458 * write-csharp.c: Include unistr.h instead of utf8-ucs4.h. 459 * write-java.c: Likewise. 460 * write-properties.c: Likewise. 461 * write-qt.c: Likewise. 462 * write-tcl.c: Likewise. 463 * x-perl.c: Likewise. 464 * x-python.c: Include unistr.h instead of utf8-ucs4.h, utf16-ucs4.h, 465 ucs4-utf8.h. 466 * x-tcl.c: Include unistr.h instead of ucs4-utf8.h. 467 4682007-03-17 Bruno Haible <bruno@clisp.org> 469 470 * x-php.c (enum token_type_ty): New values token_type_lbracket, 471 token_type_rbracket. 472 (x_php_lex): Recognize also token_type_lbracket, token_type_rbracket. 473 (extract_balanced): Renamed from extract_parenthesized. Add 'delim' 474 argument. Handle token_type_lbracket and token_type_rbracket. 475 (extract_php): Update. 476 Reported by Robert Vock <RobertVock@gmx.de>. 477 4782007-03-10 Bruno Haible <bruno@clisp.org> 479 480 * msginit.c (get_user_fullname): Reduce scope of local variables. 481 4822007-03-04 Bruno Haible <bruno@clisp.org> 483 484 Moved --enable-relocatable infrastructure to gnulib. 485 * Makefile.am: Remove SET_RELOCATABLE invocation. 486 4872007-02-25 Bruno Haible <bruno@clisp.org> 488 489 * color.c: Include filename.h instead of pathname.h. 490 (style_file_prepare): Update. 491 * msginit.c: Include filename.h instead of pathname.h. 492 (project_id, project_id_version): Update. 493 * open-catalog.c: Include filename.h instead of pathname.h. 494 (try_open_catalog_file): Update. 495 * read-csharp.c: Include filename.h instead of pathname.h. 496 (msgdomain_read_csharp): Update. 497 * read-resources.c: Include filename.h instead of pathname.h. 498 (read_resources_file): Update. 499 * read-tcl.c: Include filename.h instead of pathname.h. 500 (msgdomain_read_tcl): Update. 501 * write-csharp.c: Include filename.h instead of pathname.h. 502 (msgdomain_write_csharp): Update. 503 * write-java.c Include filename.h instead of pathname.h. 504 (msgdomain_write_java): Update. 505 * write-resources.c: Include filename.h instead of pathname.h. 506 (msgdomain_write_csharp_resources): Update. 507 * write-tcl.c: Include filename.h instead of pathname.h. 508 (msgdomain_write_tcl): Update. 509 * xgettext.c: Include filename.h instead of pathname.h. 510 (main, xgettext_open): Update. 511 5122007-02-19 Bruno Haible <bruno@clisp.org> 513 514 * file-list.c: Don't include exit.h. 515 * hostname.c: Likewise. 516 * msgattrib.c: Likewise. 517 * msgcat.c: Likewise. 518 * msgcmp.c: Likewise. 519 * msgcomm.c: Likewise. 520 * msgconv.c: Likewise. 521 * msgen.c: Likewise. 522 * msgexec.c: Likewise. 523 * msgfilter.c: Likewise. 524 * msgfmt.c: Likewise. 525 * msggrep.c: Likewise. 526 * msginit.c: Likewise. 527 * msgl-cat.c: Include <stdlib.h> instead of exit.h. 528 * msgl-charset.c: Likewise. 529 * msgl-check.c: Don't include exit.h. 530 * msgmerge.c: Likewise. 531 * msgunfmt.c: Likewise. 532 * msguniq.c: Likewise. 533 * po-lex.c: Likewise. 534 * po-xerror.c: Likewise. 535 * read-csharp.c: Likewise. 536 * read-java.c: Likewise. 537 * read-mo.c: Likewise. 538 * read-resources.c: Likewise. 539 * read-tcl.c: Likewise. 540 * recode-sr-latin.c: Likewise. 541 * urlget.c: Likewise. 542 * write-mo.c: Likewise. 543 * write-qt.c: Likewise. 544 * write-resources.c: Likewise. 545 * write-tcl.c: Include <stdlib.h> instead of exit.h. 546 * x-awk.c: Don't include exit.h. 547 * x-c.c: Likewise. 548 * x-csharp.c: Likewise. 549 * x-elisp.c: Likewise. 550 * x-glade.c: Likewise. 551 * x-java.c: Likewise. 552 * x-librep.c: Likewise. 553 * x-lisp.c: Likewise. 554 * x-perl.c: Likewise. 555 * x-php.c: Likewise. 556 * x-python.c: Likewise. 557 * x-rst.c: Include <stdlib.h> instead of exit.h. 558 * x-scheme.c: Don't include exit.h. 559 * x-sh.c: Likewise. 560 * x-smalltalk.c: Likewise. 561 * x-tcl.c: Likewise. 562 * x-ycp.c: Likewise. 563 * xgettext.c: Likewise. 564 5652007-01-28 Bruno Haible <bruno@clisp.org> 566 567 * x-java.c (string_buffer_append_lone_surrogate): New function. 568 (string_buffer_flush_utf16_surr, string_buffer_append): Use it. 569 5702007-01-28 Bruno Haible <bruno@clisp.org> 571 572 * x-java.c (string_buffer_flush_utf16_surr): Give a warning when 573 converting a surrogate code point to U+FFFD. 574 (string_buffer_append): Convert a lone high surrogate code point to 575 U+FFFD, and give a warning. 576 5772007-01-26 Bruno Haible <bruno@clisp.org> 578 579 * msgfilter.c: Include <sys/time.h> unconditionally. 580 5812007-01-26 Bruno Haible <bruno@clisp.org> 582 583 * msginit.c: Don't include strpbrk.h, use <string.h> instead. 584 5852007-01-26 Bruno Haible <bruno@clisp.org> 586 587 * msgmerge.c: Don't include stpncpy.h, use <string.h> instead. 588 5892007-01-26 Bruno Haible <bruno@clisp.org> 590 591 * msgfmt.c: Don't include stpcpy.h, use <string.h> instead. 592 * msgmerge.c: Likewise. 593 5942007-01-21 Bruno Haible <bruno@clisp.org> 595 596 * msgl-iconv.c (convert_string, convert_msgstr, iconvable_string, 597 iconvable_msgstr): Update for changed calling convention of 598 xmem_cd_iconv. 599 * recode-sr-latin.c (process): Likewise. 600 6012007-01-07 Bruno Haible <bruno@clisp.org> 602 603 * msgmerge.c (message_merge): Copy the obsolete bit from the ref 604 message. 605 Reported by Leonardo Fontenelle <leo.fontenelle@gmail.com>. 606 6072006-12-24 Bruno Haible <bruno@clisp.org> 608 609 * Makefile.am (AM_CXXFLAGS): New variable. 610 6112006-12-23 Bruno Haible <bruno@clisp.org> 612 613 * color.c (print_color_test): Print labels before the hue/saturation 614 rectangle. Show also a few lines that mix colors and attributes. 615 6162006-12-03 Bruno Haible <bruno@clisp.org> 617 618 * msgcat.c: Include color.h. 619 (long_options): Add --color, --style options. 620 (main): Handle them. Invoke print_color_test when --color=test was 621 given. 622 (usage): Document --color, --style options. 623 6242006-12-01 Bruno Haible <bruno@clisp.org> 625 626 Add styling support to the PO output routines. 627 * color.h: New file. 628 * color.c: New file. 629 * write-catalog.h (struct catalog_output_format): Add field 630 'supports_color'. 631 * write-catalog.c: Include fcntl.h, unistd.h, styled-ostream.h, 632 term-styled-ostream.h, html-styled-ostream.h, fd-ostream.h, color.h, 633 po-charset.h, msgl-iconv.h. 634 (STDOUT_FILENO): New macro. 635 (ENABLE_COLOR): New macro. 636 (msgdomain_list_print): Use a styled_ostream_t that uses the 637 style_file_name. 638 * write-po.c: Include format.h, styled-ostream.h. 639 (is_stylable, begin_css_class, end_css_class): New functions or macros. 640 (class_header, class_translated, class_untranslated, class_fuzzy, 641 class_obsolete, class_comment, class_translator_comment, 642 class_extracted_comment, class_reference_comment, class_reference, 643 class_flag_comment, class_flag, class_fuzzy_flag, 644 class_previous_comment, class_previous, class_msgid, class_msgstr, 645 class_keyword, class_string, class_text, class_escape_sequence, 646 class_format_directive, class_invalid_format_directive): New variables. 647 (ATTR_ESCAPE_SEQUENCE, ATTR_FORMAT_DIRECTIVE, 648 ATTR_INVALID_FORMAT_DIRECTIVE): New enum items. 649 (message_print_comment, message_print_comment_dot, 650 message_print_comment_filepos, message_print_comment_flags): Call 651 begin/end_css_class. 652 (memset_small): New function. 653 (wrap): Add css_class argument. Determine the extent of format 654 string directives. Call begin/end_css_class. 655 (print_blank_line): Call begin/end_css_class. 656 (message_print, message_print_obsolete): Likewise. Pass a css_class 657 argument to 'wrap'. 658 (msgdomain_list_print_po): Call begin/end_css_class. 659 (output_format_po): Update. 660 * write-properties.c (output_format_properties): Update. 661 * write-stringtable.c (output_format_stringtable): Update. 662 * Makefile.am (noinst_HEADERS): Add color.h. 663 (libgettextsrc_la_SOURCES): Add color.c. 664 6652006-11-26 Bruno Haible <bruno@clisp.org> 666 667 * write-po.c (make_format_description_string, 668 make_c_width_description_string): Strip off the leading space. 669 (message_print_comment_flags): Print the space here. 670 * write-stringtable.c (write_message): Print the space here. 671 6722006-11-26 Bruno Haible <bruno@clisp.org> 673 674 * write-po.c: Include write-catalog.h instead of write-properties.h, 675 write-stringtable.h. 676 6772006-11-26 Bruno Haible <bruno@clisp.org> 678 679 * format.h (FMTDIR_START, FMTDIR_END, FMTDIR_ERROR): New enum values. 680 (FDI_SET): New macro. 681 (struct formatstring_parser): Add fdi argument to 'parse' method. 682 * format.c (check_msgid_msgstr_format): Update. 683 * format-awk.c (format_parse): Add fdi argument. Invoke FDI_SET. 684 * format-boost.c (format_parse): Likewise. 685 * format-c.c (format_parse): Add fdi argument. Invoke FDI_SET. 686 (format_c_parse, format_objc_parse): Add fdi argument. 687 (get_sysdep_c_format_directives): Update. 688 * format-csharp.c (format_parse): Add fdi argument. Invoke FDI_SET. 689 * format-elisp.c (format_parse): Likewise. 690 * format-gcc-internal.c (format_parse): Likewise. 691 * format-java.c (message_format_parse): Add fdi argument. Invoke 692 FDI_SET. 693 (choice_format_parse): Update. 694 (format_parse): Add fdi argument. 695 * format-librep.c (format_parse): Add fdi argument. Invoke FDI_SET. 696 * format-lisp.c (parse_upto): Add fdi argument. Invoke FDI_SET. 697 (format_parse): Add fdi argument. 698 * format-pascal.c (format_parse): Add fdi argument. Invoke FDI_SET. 699 * format-perl.c (format_parse): Likewise. 700 * format-perl-brace.c (format_parse): Likewise. 701 * format-php.c (format_parse): Likewise. 702 * format-python.c (format_parse): Add fdi argument. Invoke FDI_SET. 703 (get_python_format_unnamed_arg_count): Update. 704 * format-qt.c (format_parse): Add fdi argument. Invoke FDI_SET. 705 * format-scheme.c (parse_upto): Add fdi argument. Invoke FDI_SET. 706 (format_parse): Add fdi argument. 707 * format-sh.c (format_parse): Add fdi argument. Invoke FDI_SET. 708 * format-tcl.c (format_parse): Likewise. 709 * format-ycp.c (format_parse): Likewise. 710 * msgmerge.c (msgfmt_check_pair_fails): Update. 711 * read-mo.c (read_mo_file): Update. 712 * xgettext.c (set_format_flags_from_context, remember_a_message, 713 remember_a_message_plural): Update. 714 7152006-11-25 Bruno Haible <bruno@clisp.org> 716 717 * message.h (message_list_copy, msgdomain_list_copy): New declarations. 718 * message.c (message_list_copy, msgdomain_list_copy): New functions. 719 7202006-11-25 Bruno Haible <bruno@clisp.org> 721 722 * msgl-iconv.h (iconv_msgdomain_list): Add update_header argument. 723 * msgl-iconv.c (iconv_message_list_internal): Renamed from 724 iconv_msgdomain_list. Add update_header argument. 725 (iconv_message_list): New function. 726 (iconv_msgdomain_list): Add update_header argument. 727 * msgcmp.c (compare): Update iconv_msgdomain_list call. 728 * msgconv.c (main): Likewise. 729 * msgfilter.c (main): Likewise. 730 * msgmerge.c (merge): Likewise. 731 * xgettext.c (main): Likewise. 732 7332006-11-23 Bruno Haible <bruno@clisp.org> 734 735 * write-catalog.h: Include ostream.h. Don't include <stdio.h>. 736 (struct catalog_output_format): Use ostream_t instead of 'FILE *'. 737 * write-catalog.c: Include ostream.h, file-ostream.h. 738 (msgdomain_list_print): Open a temporary file_ostream_t. 739 * write-po.h: Include ostream.h. Don't include <stdio.h>. 740 (message_print_comment, message_print_comment_dot, 741 message_print_comment_filepos, message_print_comment_flags): Replace 742 'FILE *' argument with an 'ostream_t' argument. 743 * write-po.c: Include ostream.h. 744 (message_print_comment, message_print_comment_dot, 745 message_print_comment_filepos, message_print_comment_flags, wrap, 746 print_blank_line, message_print, message_print_obsolete, 747 msgdomain_list_print_po): Replace 'FILE *' argument with an 'ostream_t' 748 argument. 749 * write-properties.c: Include ostream.h. 750 (write_escaped_string, write_message, write_properties, 751 msgdomain_list_print_properties): Replace 'FILE *' argument with an 752 'ostream_t' argument. 753 * write-stringtable.c: Include ostream.h, xvasprintf.h. Don't include 754 <stdio.h>. 755 (write_escaped_string, write_message, write_stringtable, 756 msgdomain_list_print_stringtable): Replace 'FILE *' argument with an 757 'ostream_t' argument. 758 7592006-11-12 Bruno Haible <bruno@clisp.org> 760 761 * write-po.c (wrap): Indent by use of spaces, not tabs. 762 7632006-11-03 Bruno Haible <bruno@clisp.org> 764 765 Simplify xmalloc expressions. Add overflow check in xmalloc arguments. 766 * filter-sr-latin.c (serbian_to_latin): Use XNMALLOC instead of xmalloc. 767 * format-awk.c (format_parse): Use XMALLOC instead of xmalloc. 768 * format-boost.c (format_parse): Likewise. 769 * format-c.c (format_parse): Use XMALLOC, XNMALLOC instead of xmalloc. 770 (get_sysdep_c_format_directives): Use XNMALLOC instead of xmalloc. 771 * format-csharp.c (format_parse): Use XMALLOC instead of xmalloc. 772 * format-elisp.c (format_parse): Likewise. 773 * format-gcc-internal.c (format_parse): Likewise. 774 * format-java.c (format_parse): Likewise. 775 * format-librep.c (format_parse): Likewise. 776 * format-lisp.c (copy_list): Use XMALLOC, XNMALLOC instead of xmalloc. 777 (make_unconstrained_list): Likewise. 778 (make_empty_list): Use XMALLOC instead of xmalloc. 779 (rotate_loop): Use XNMALLOC instead of xmalloc. 780 (make_intersected_list): Use XMALLOC instead of xmalloc. 781 (make_union_list): Use XMALLOC, XNMALLOC instead of xmalloc. 782 (make_repeated_list_of_lists): Likewise. 783 (make_repeated_list): Likewise. 784 (format_parse): Use XMALLOC instead of xmalloc. 785 * format-pascal.c (format_parse): Likewise. 786 * format-perl.c (format_parse): Likewise. 787 * format-perl-brace.c (format_parse): Use XMALLOC, XNMALLOC instead of 788 xmalloc. 789 * format-php.c (format_parse): Use XMALLOC instead of xmalloc. 790 * format-python.c (format_parse): Use XMALLOC, XNMALLOC instead of 791 xmalloc. 792 * format-qt.c (format_parse): Use XMALLOC instead of xmalloc. 793 * format-scheme.c (copy_list): Use XMALLOC, XNMALLOC instead of xmalloc. 794 (make_unconstrained_list): Likewise. 795 (make_empty_list): Use XMALLOC instead of xmalloc. 796 (rotate_loop): Use XNMALLOC instead of xmalloc. 797 (make_intersected_list): Use XMALLOC instead of xmalloc. 798 (make_union_list): Use XMALLOC, XNMALLOC instead of xmalloc. 799 (make_repeated_list_of_lists): Likewise. 800 (make_repeated_list): Likewise. 801 (format_parse): Use XMALLOC instead of xmalloc. 802 * format-sh.c (format_parse): Use XMALLOC, XNMALLOC instead of xmalloc. 803 * format-tcl.c (format_parse): Use XMALLOC instead of xmalloc. 804 * format-ycp.c (format_parse): Likewise. 805 * message.c (message_alloc, message_list_list_alloc, msgdomain_alloc): 806 Use XMALLOC instead of xmalloc. 807 (msgdomain_list_alloc): Use XMALLOC, XNMALLOC instead of xmalloc. 808 * msgexec.c (main): Use XNMALLOC instead of xmalloc. 809 * msgfilter.c (main, generic_filter, process_message): Likewise. 810 * msgfmt.c (add_mo_suffix): Likewise. 811 (new_domain): Use XMALLOC instead of xmalloc. 812 * msginit.c (catalogname_for_locale, language_of_locale, 813 get_user_fullname, get_field, put_field, subst_string, 814 update_msgstr_plurals): Use XNMALLOC instead of xmalloc. 815 * msgl-cat.c (catenate_msgdomain_list): Likewise. 816 * msgl-check.c (check_plural_eval): Use XCALLOC instead of xcalloc. 817 * msgl-english.c (msgdomain_list_english): Use XNMALLOC instead of 818 xmalloc. 819 * msgl-fsearch.c (new_index): Likewise. 820 (message_fuzzy_index_alloc): Use XMALLOC instead of xmalloc. 821 (mult_index_list_accumulate): Use XNMALLOC instead of xmalloc. 822 * msgl-iconv.c (iconv_message_list): Likewise. 823 * msgmerge.c (message_merge, match_domain): Likewise. 824 * po-gram-gen.y (plural_form_list): Likewise. 825 * read-catalog-abstract.c (po_parse_comment_filepos, 826 po_parse_comment_solaris_filepos): Likewise. 827 * read-mo.c (get_sysdep_string): Likewise. 828 * read-properties.c (conv_from_iso_8859_1, read_escaped_string): 829 Likewise. 830 * read-stringtable.c (conv_from_ucs4): Likewise. 831 * str-list.c (string_list_alloc): Use XMALLOC instead of xmalloc. 832 (string_list_concat, string_list_join): Use XNMALLOC instead of xmalloc. 833 * write-csharp.c (construct_class_name, msgdomain_write_csharp): 834 Likewise. 835 * write-java.c (compute_hashsize, compute_table_items): Likewise. 836 * write-mo.c: Include xsize.h. 837 (write_table): Use XNMALLOC instead of xmalloc. Use xsum, xtimes in 838 xmalloc argument. 839 * write-po.c (wrap): Use XNMALLOC instead of xmalloc. 840 * write-properties.c (conv_to_java): Likewise. 841 * write-qt.c (conv_to_iso_8859_1, conv_to_utf16): Likewise. 842 * x-elisp.c (init_token, string_of_object): Likewise. 843 (read_object): Use XMALLOC instead of xmalloc. 844 * x-librep.c (init_token, string_of_object): Use XNMALLOC instead of 845 xmalloc. 846 (read_object): Use XMALLOC instead of xmalloc. 847 * x-lisp.c (x_lisp_keyword, init_token, string_of_object): Use XNMALLOC 848 instead of xmalloc. 849 (read_object): Use XMALLOC instead of xmalloc. 850 * x-perl.c (get_here_document, extract_quotelike_pass1, 851 extract_quotelike_pass3): Use XNMALLOC instead of xmalloc. 852 (x_perl_lex): Use XMALLOC instead of xmalloc. 853 * x-po.c (strextract_add_message, extract): Use XNMALLOC instead of 854 xmalloc. 855 * x-python.c (try_to_extract_coding): Use XNMALLOC instead of xmalloc. 856 * x-scheme.c (init_token, string_of_object): Use XNMALLOC 857 instead of xmalloc. 858 (read_object): Use XMALLOC instead of xmalloc. 859 * x-sh.c (init_token, string_of_token, string_of_word): Use XNMALLOC 860 instead of xmalloc. 861 (read_word): Use XMALLOC instead of xmalloc. 862 * x-smalltalk.c (phase2_get): Use XNMALLOC instead of xmalloc. 863 * x-tcl.c (init_token, string_of_word): Use XNMALLOC instead of xmalloc. 864 (read_word): Use XMALLOC instead of xmalloc. 865 * xgettext.c: Include xsize.h. 866 (split_keywordspec): Use XNMALLOC instead of xmalloc. 867 (insert_keyword_callshape): Use XMALLOC instead of xmalloc. Use xsum, 868 xtimes to avoid overflow. 869 (flag_context_list_table_insert): Use XMALLOC instead of xmalloc. 870 (savable_comment_add): Likewise. 871 (remember_a_message_plural): Use XNMALLOC instead of xmalloc. 872 (arglist_parser_alloc, arglist_parser_clone): Use xsum, xtimes. 873 (arglist_parser_done): Use XNMALLOC instead of xmalloc. 874 (finalize_header): Likewise. 875 8762006-10-30 Bruno Haible <bruno@clisp.org> 877 878 * plural-eval.h [C++]: Define functions without name mangling. 879 8802006-10-29 Bruno Haible <bruno@clisp.org> 881 882 Clean up libgettextpo exports in C++ mode. 883 * po-gram.h: Wrap declarations in extern "C". 884 8852006-10-29 Bruno Haible <bruno@clisp.org> 886 887 Make it compile in C++ mode. 888 * dir-list.c (dir_list_restore): Add cast. 889 * format-c.c (format_arg_type_t): New type. Use it instead of 890 'enum format_arg_type'. 891 * format-gcc-internal.c (format_arg_type_t): New type. Use it instead of 892 'enum format_arg_type'. 893 * format-perl.c (format_arg_type_t): New type. Use it instead of 894 'enum format_arg_type'. 895 * format-lisp.c (struct segment): Move out of the scope of struct 896 format_arg_list. 897 * format-scheme.c (struct segment): Likewise. 898 * message.h (struct altstr): Move out of the scope of struct message_ty. 899 * msgl-equal.c (msgstr_equal_ignoring_potcdate): Cast memchr results. 900 * po-lex.c (mb_copy): Rename arguments to new_mbc, old_mbc. 901 * read-mo.c (enum mo_endianness): Move out of the scope of struct 902 binary_mo_file. 903 * read-po.c (this): New macro. 904 * read-properties.c (this): New macro. 905 * write-mo.c (write_table): Cast alloca result. 906 * x-glade.c (load_libexpat): Cast dlsym results. 907 * x-perl.c (get_here_document): Use xmalloc instead of 908 xrealloc (NULL...). Cast its result. 909 * x-po.c (extract_add_message): Limit the scope of variable 910 'charsetstr'. 911 * x-smalltalk.c (phase2_get): Cast xmalloc results. 912 9132006-10-29 Bruno Haible <bruno@clisp.org> 914 915 * x-awk.h: Make includable without prerequisites. 916 * x-c.h: Likewise. 917 * x-csharp.h: Likewise. 918 * x-elisp.h: Likewise. 919 * x-glade.h: Likewise. 920 * x-java.h: Likewise. 921 * x-librep.h: Likewise. 922 * x-lisp.h: Likewise. 923 * x-perl.h: Likewise. 924 * x-php.h: Likewise. 925 * x-po.h: Likewise. 926 * x-properties.h: Likewise. 927 * x-python.h: Likewise. 928 * x-rst.h: Likewise. 929 * x-scheme.h: Likewise. 930 * x-sh.h: Likewise. 931 * x-smalltalk.h: Likewise. 932 * x-stringtable.h: Likewise. 933 * x-tcl.h: Likewise. 934 * x-ycp.h: Likewise. 935 * x-awk.c: Include x-awk.h. 936 * x-c.c: Include x-c.h. 937 * x-csharp.c: Include x-csharp.h. 938 * x-elisp.c: Include x-elisp.h. 939 * x-glade.c: Include x-glade.h. 940 * x-java.c: Include x-java.h. 941 * x-librep.c: Include x-librep.h. 942 * x-lisp.c: Include x-lisp.h. 943 * x-perl.c: Include x-perl.h. 944 * x-php.c: Include x-php.h. 945 * x-po.c: Include x-po.h, x-properties.h, x-stringtable.h. 946 * x-python.c: Include x-python.h. 947 * x-rst.c: Include x-rst.h. 948 * x-scheme.c: Include x-scheme.h. 949 * x-sh.c: Include x-sh.h. 950 * x-smalltalk.c: Include x-smalltalk.h. 951 * x-tcl.c: Include x-tcl.h. 952 * x-ycp.c: Include x-ycp.h. 953 * xgettext.c: Remove extern "C" around x-*.h includes. 954 9552006-10-29 Bruno Haible <bruno@clisp.org> 956 957 * format-awk.c (format_parse): Fix bug with unnumbered argument in 958 precision field. 959 9602006-11-27 Bruno Haible <bruno@clisp.org> 961 962 * gettext-0.16.1 released. 963 9642006-10-26 Bruno Haible <bruno@clisp.org> 965 966 * gettext-0.16 released. 967 9682006-10-24 Bruno Haible <bruno@clisp.org> 969 970 * Makefile.am (AM_CPPFLAGS): Add also $(top_srcdir). Needed so that 971 woe32dll/export.h is found while compiling gettextsrc-exports.c in a 972 VPATH build. 973 Reported by Charles Wilson <cygwin@cwilson.fastmail.fm>. 974 9752006-10-24 Bruno Haible <bruno@clisp.org> 976 977 * msgmerge.c (struct definitions_ty): Remove semicolon after 978 gl_lock_define invocation. 979 9802006-10-21 Bruno Haible <bruno@clisp.org> 981 982 * po-error.h (po_error, po_error_at_line): Use format attribute only 983 with gcc >= 3.1. 984 9852006-10-21 Bruno Haible <bruno@clisp.org> 986 987 * msgmerge.c (struct definitions_ty): Use gl_lock_define to declare 988 the findex_init_lock field. 989 (definitions_init): Use gl_lock_init to initialize it, instead of 990 memcpy hack. 991 9922006-10-16 Bruno Haible <bruno@clisp.org> 993 994 Work around automake-1.10 problem described in 995 http://lists.gnu.org/archive/html/bug-automake/2006-08/msg00025.html. 996 * Makefile.am (CXXLINK): Remove variable. 997 (msgmerge_CXXFLAGS): New variable. 998 (libgettextsrc_la_LINK, msgattrib_LINK, msgcat_LINK, msgcomm_LINK, 999 msgconv_LINK, msgen_LINK, msgfilter_LINK, msggrep_LINK, msgmerge_LINK, 1000 msguniq_LINK, xgettext_LINK): New variables. 1001 10022006-10-18 Bruno Haible <bruno@clisp.org> 1003 1004 * read-po.h (input_format_po): Mark as DLL_VARIABLE. 1005 * read-properties.h (input_format_properties): Likewise. 1006 * read-stringtable.h (input_format_stringtable): Likewise. 1007 * write-po.h (output_format_po): Likewise. 1008 * write-properties.h (output_format_properties): Likewise. 1009 * write-stringtable.h (output_format_stringtable): Likewise. 1010 10112006-10-16 Bruno Haible <bruno@clisp.org> 1012 1013 * gettext-po.h.in: Move to ../libgettextpo/. 1014 * gettext-po.c: Move to ../libgettextpo/. 1015 * Makefile.am (lib_LTLIBRARIES): Remove libgettextpo.la. 1016 (nodist_include_HEADERS): Remove variable. 1017 (libgettextpo_la_SOURCES, LTV_CURRENT, LTV_REVISION, LTV_AGE, 1018 libgettextpo_la_LDFLAGS, libgettextpo_la_DEPENDENCIES, 1019 libgettextpo_la_LDFLAGS): Remove variables. 1020 (EXTRA_DIST, BUILT_SOURCES, CLEANFILES): Remove gettext-po.h support. 1021 (gettext-po.h): Remove rule. 1022 10232006-10-18 Bruno Haible <bruno@clisp.org> 1024 1025 * po-error.h (__attribute__, __format__, __printf__): New macros. 1026 (po_error, po_error_at_line): Declare format string argument. 1027 * po-lex.h (__attribute__, __format__, __printf__): New macros. 1028 (po_gram_error, po_gram_error_at_line): Declare format string argument. 1029 1030 * msgl-cat.c (catenate_msgdomain_list): Avoid "gcc -Wshadow" warning. 1031 * msgl-check.c (formatstring_error_logger): Avoid "gcc 1032 -Wmissing-format-attribute" warning. 1033 (check_pair): Avoid "gcc -Wshadow" warning. 1034 1035 * read-stringtable.c (stringtable_parse): Pass a mutable string as 1036 msgstr to po_callback_message. 1037 * write-po.c (msgdomain_list_print_po): Avoid "gcc -Wwrite-strings" 1038 warning. 1039 * xgettext.c (remember_a_message_plural): Free a temporary string 1040 after use. 1041 10422006-10-17 Bruno Haible <bruno@clisp.org> 1043 1044 * lang-table.c (language_table): Add the most important languages that 1045 have an ISO 639-2 code. 1046 * msginit.c (catalogname_for_locale): Likewise. 1047 10482006-10-15 Bruno Haible <bruno@clisp.org> 1049 1050 * read-catalog-abstract.h (input_syntax_ty): Remove type. 1051 (catalog_input_format): New structure type. 1052 (catalog_input_format_ty): New type. 1053 (catalog_reader_parse): Change type of input_syntax argument. 1054 * read-catalog.h (input_syntax): Remove variable. 1055 (read_catalog_stream, read_catalog_file): Add input_syntax argument. 1056 * msgl-cat.h: Include read-catalog-abstract.h. 1057 (catenate_msgdomain_list): Add input_syntax argument. 1058 * read-po.h: New file. 1059 * read-po.c: New file, extracted from read-catalog-abstract.c. 1060 * msgattrib.c: Include read-po.h, read-properties.h, read-stringtable.h. 1061 (main): Change handling of --properties-input, --stringtable-input 1062 options. Update read_catalog_file calls. 1063 * msgcat.c: Include read-po.h, read-properties.h, read-stringtable.h. 1064 (main): Change handling of --properties-input, --stringtable-input 1065 options. Update catenate_msgdomain_list call. 1066 * msgcmp.c: Include read-po.h, read-properties.h, read-stringtable.h. 1067 (main): Change handling of --properties-input, --stringtable-input 1068 options. Update compare call. 1069 (compare): Add input_syntax argument. 1070 * msgcomm.c: Include read-po.h, read-properties.h, read-stringtable.h. 1071 (main): Change handling of --properties-input, --stringtable-input 1072 options. Update catenate_msgdomain_list call. 1073 * msgconv.c: Include read-po.h, read-properties.h, read-stringtable.h. 1074 (main): Change handling of --properties-input, --stringtable-input 1075 options. Update read_catalog_file call. 1076 * msgen.c: Include read-po.h, read-properties.h, read-stringtable.h. 1077 (main): Change handling of --properties-input, --stringtable-input 1078 options. Update read_catalog_file call. 1079 * msgexec.c: Include read-po.h, read-properties.h, read-stringtable.h. 1080 (main): Change handling of --properties-input, --stringtable-input 1081 options. Update read_catalog_file call. 1082 * msgfilter.c: Include read-po.h, read-properties.h, read-stringtable.h. 1083 (main): Change handling of --properties-input, --stringtable-input 1084 options. Update read_catalog_file call. 1085 * msgfmt.c: Include read-po.h, read-properties.h, read-stringtable.h. 1086 (main): Change handling of --properties-input, --stringtable-input 1087 options. Update read_catalog_file_msgfmt call. 1088 (read_catalog_file_msgfmt): Add input_syntax argument. 1089 * msggrep.c: Include read-po.h, read-properties.h, read-stringtable.h. 1090 (main): Change handling of --properties-input, --stringtable-input 1091 options. Update read_catalog_file call. 1092 * msginit.c: Include read-po.h, read-properties.h, read-stringtable.h. 1093 (main): Change handling of --properties-input, --stringtable-input 1094 options. Update read_catalog_file call. 1095 * msgl-cat.c (catenate_msgdomain_list): Add input_syntax argument. 1096 * msgmerge.c: Include read-po.h, read-properties.h, read-stringtable.h. 1097 (main): Change handling of --properties-input, --stringtable-input 1098 options. Update merge call. 1099 (compendium): Read it in PO syntax. 1100 (merge): Add input_syntax argument. 1101 * msguniq.c: Include read-po.h, read-properties.h, read-stringtable.h. 1102 (main): Change handling of --properties-input, --stringtable-input 1103 options. Update catenate_msgdomain_list call. 1104 * read-catalog-abstract.c: Don't include po-gram.h, read-properties.h, 1105 read-stringtable.h. 1106 (catalog_reader_parse): Change type of input_syntax argument. Invoke 1107 the parser indirectly. 1108 * read-catalog.c (input_syntax): Remove variable. 1109 (read_catalog_stream, read_catalog_file): Add input_syntax argument. 1110 * read-csharp.c: Include read-po.h. 1111 (execute_and_read_po_output): Update read_catalog_stream call. 1112 * read-java.c: Include read-po.h. 1113 (execute_and_read_po_output): Update read_catalog_stream call. 1114 * read-properties.c (properties_parse): Make static. 1115 (input_format_properties): New variable. 1116 * read-properties.h (properties_parse): Remove declaration. 1117 (input_format_properties): New declaration. 1118 * read-resources.c: Include read-po.h. 1119 (execute_and_read_po_output): Update read_catalog_stream call. 1120 * read-stringtable.c (stringtable_parse): Make static. 1121 (input_format_stringtable): New variable. 1122 * read-stringtable.h (stringtable_parse): Remove declaration. 1123 (input_format_stringtable): New declaration. 1124 * read-tcl.c: Include read-po.h. 1125 (msgdomain_read_tcl): Update read_catalog_stream call. 1126 * x-po.c: Include read-po.h, read-properties.h, read-stringtable.h. 1127 (extract): Change type of input_syntax argument. 1128 (extract_po, extract_properties, extract_stringtable): Update. 1129 * xgettext.c: Include read-po.h. 1130 (read_exclusion_file): Read it in PO syntax. 1131 * gettext-po.c: Include read-po.h. 1132 (po_file_read_v3, po_file_read_v2, po_file_read): Update 1133 read_catalog_stream call. 1134 * Makefile.am (noinst_HEADERS): Add read-po.h. 1135 (COMMON_SOURCE): Add read-po.c. 1136 11372006-10-15 Bruno Haible <bruno@clisp.org> 1138 1139 * read-catalog-abstract.h (abstract_catalog_reader_ty): Renamed from 1140 abstract_po_reader_ty. 1141 (abstract_catalog_reader_class_ty): Renamed from 1142 abstract_po_reader_class_ty. Update. 1143 (ABSTRACT_CATALOG_READER_TY): Renamed from ABSTRACT_PO_READER_TY. 1144 Update. 1145 (abstract_catalog_reader_ty): Renamed from abstract_po_reader_ty. 1146 Update. 1147 (catalog_reader_alloc): Renamed from po_reader_alloc. 1148 (catalog_reader_parse): Renamed from po_scan. 1149 (catalog_reader_free): Renamed from po_reader_free. 1150 * read-catalog.h: Update. 1151 (default_catalog_reader_class_ty): Renamed from 1152 default_po_reader_class_ty. 1153 (DEFAULT_CATALOG_READER_TY): Renamed from DEFAULT_PO_READER_TY. Update. 1154 (default_catalog_reader_ty): Renamed from default_po_reader_ty. Update. 1155 (default_constructor, default_destructor, default_parse_brief, 1156 default_parse_debrief, default_directive_domain, 1157 default_directive_message, default_comment, default_comment_dot, 1158 default_comment_filepos, default_comment_special, default_set_domain, 1159 default_add_message): Update. 1160 (default_catalog_reader_alloc): Renamed from default_po_reader_alloc. 1161 Update. 1162 (read_catalog_stream): Renamed from read_po. 1163 (read_catalog_file): Renamed from read_po_file. 1164 * open-catalog.h (open_catalog_file): Renamed from open_po_file. 1165 * msgattrib.c: Update. 1166 (main): Update. 1167 * msgcat.c: Update. 1168 * msgcmp.c: Update. 1169 (compare): Update. 1170 * msgcomm.c: Update. 1171 * msgconv.c: Update. 1172 (main): Update. 1173 * msgen.c: Update. 1174 (main): Update. 1175 * msgexec.c: Update. 1176 (main): Update. 1177 * msgfilter.c: Update. 1178 (main): Update. 1179 * msgfmt.c: Update. 1180 (read_catalog_file_msgfmt): Renamed from read_po_file_msgfmt. Update. 1181 (main): Update. 1182 (msgfmt_catalog_reader_ty): Renamed from msgfmt_po_reader_ty. Update. 1183 (msgfmt_constructor, msgfmt_parse_debrief, msgfmt_set_domain, 1184 msgfmt_add_message, msgfmt_frob_new_message, msgfmt_comment_special, 1185 msgfmt_methods): Update. 1186 (read_catalog_file_msgfmt): Renamed from read_po_file_msgfmt. Update. 1187 * msggrep.c: Update. 1188 (main): Update. 1189 * msginit.c: Update. 1190 (main): Update. 1191 * msgl-cat.c: Update. 1192 (catenate_msgdomain_list): Update. 1193 * msgmerge.c: Update. 1194 (compendium, merge): Update. 1195 * msguniq.c: Update. 1196 * open-catalog.c: Update. 1197 (try_open_catalog_file): Renamed from try_open_po_file. 1198 (open_catalog_file): Renamed from open_po_file. Update. 1199 * po-gram-gen.y: Update. 1200 * read-catalog-abstract.c: Update. 1201 (callback_arg): Update. 1202 (catalog_reader_alloc): Renamed from po_reader_alloc. 1203 (catalog_reader_free): Renamed from po_reader_free. 1204 (call_parse_brief, call_parse_debrief, call_directive_domain, 1205 call_directive_message, call_comment, call_comment_dot, 1206 call_comment_filepos, call_comment_special): Update. 1207 (parse_start): Renamed from po_scan_start. 1208 (parse_end): Renamed from po_scan_end. 1209 (catalog_reader_parse): Renamed from po_scan. 1210 * read-catalog.c: Update. 1211 (call_set_domain, call_add_message, call_frob_new_message): Update. 1212 (default_constructor, default_destructor, default_parse_brief, 1213 default_parse_debrief, default_copy_comment_state, 1214 default_reset_comment_state, default_directive_domain, 1215 default_directive_message, default_comment, default_comment_dot, 1216 default_comment_filepos, default_comment_special, default_set_domain, 1217 default_add_message, default_methods): Update. 1218 (default_catalog_reader_alloc): Renamed from default_po_reader_alloc. 1219 (read_catalog_stream): Renamed from read_po. Update. 1220 (read_catalog_file): Renamed from read_po_file. Update. 1221 * read-csharp.c: Update. 1222 (execute_and_read_po_output): Update. 1223 * read-java.c: Update. 1224 (execute_and_read_po_output): Update. 1225 * read-properties.c: Update. 1226 (properties_parse): Update. 1227 * read-properties.h: Update. 1228 (properties_parse): Update. 1229 * read-resources.c: Update. 1230 (execute_and_read_po_output): Update. 1231 * read-stringtable.c: Update. 1232 (stringtable_parse): Update. 1233 * read-stringtable.h: Update. 1234 (stringtable_parse): Update. 1235 * read-tcl.c: Update. 1236 (msgdomain_read_tcl): Update. 1237 * x-po.c: Update. 1238 (extract_add_message, extract_methods, extract): Update. 1239 * xgettext.c: Update. 1240 (exclude_directive_domain, exclude_directive_message, exclude_methods, 1241 read_exclusion_file): Update. 1242 * xgettext.h: Update. 1243 * gettext-po.c: Update. 1244 (po_file_read_v3, po_file_read_v2, po_file_read): Update. 1245 1246 * read-catalog-abstract.h: Renamed from read-po-abstract.h. 1247 * read-catalog-abstract.c: Renamed from read-po-abstract.c. 1248 * read-catalog.h: Renamed from read-po.h. 1249 * read-catalog.c: Renamed from read-po.c. 1250 * open-catalog.h: Renamed from open-po.h. 1251 * open-catalog.c: Renamed from open-po.c. 1252 * Makefile.am (noinst_HEADERS, COMMON_SOURCE, libgettextsrc_la_SOURCES): 1253 Update. 1254 12552006-10-15 Bruno Haible <bruno@clisp.org> 1256 1257 * write-catalog.h: New file. 1258 * write-catalog.c: New file, mostly extracted from write-po.c. 1259 * write-po.h (message_page_width_set): Move declaration to 1260 write-catalog.h. 1261 (message_print_syntax_properties, message_print_syntax_stringtable): 1262 Remove declarations. 1263 (msgdomain_list_print): Move out to write-catalog.h, adding a 1264 catalog_output_format_ty argument. 1265 (msgdomain_list_sort_by_msgid, msgdomain_list_sort_by_filepos): Move 1266 out to write-catalog.h. 1267 (output_format_po): New declaration. 1268 * write-po.c: Don't include fwriteerror.h, error-progname.h. 1269 (page_width, message_page_width_set): Move out to write-catalog.c. 1270 (use_syntax_properties): Remove variable. 1271 (message_print_syntax_properties): Remove function. 1272 (use_syntax_stringtable): Remove variable. 1273 (message_print_syntax_stringtable): Remove function. 1274 (wrap, message_print, message_print_obsolete, msgdomain_list_print_po): 1275 Add page_width argument. 1276 (msgdomain_list_print): Move out to write-catalog.c, adding a 1277 catalog_output_format_ty argument. 1278 (cmp_by_msgid, msgdomain_list_sort_by_msgid, 1279 cmp_filepos, msgdomain_list_sort_filepos, 1280 cmp_by_filepos, msgdomain_list_sort_by_filepos): Move out to 1281 write-catalog.c. 1282 (output_format_po): New variable. 1283 * write-properties.h (msgdomain_list_print_properties): Remove 1284 declaration. 1285 (output_format_properties): New declaration. 1286 * write-properties.c (msgdomain_list_print_properties): Make static. 1287 (output_format_properties): New variable. 1288 * write-stringtable.h (msgdomain_list_print_stringtable): Remove 1289 declaration. 1290 (output_format_stringtable): New declaration. 1291 * write-stringtable.c (msgdomain_list_print_stringtable): Make static. 1292 (output_format_stringtable): New variable. 1293 * msgattrib.c: Include write-catalog.h, write-properties.h, 1294 write-stringtable.h. 1295 (main): Change handling of --properties-output, --stringtable-output 1296 options. Pass the output_syntax to msgdomain_list_print. 1297 * msgcat.c: Include write-catalog.h, write-properties.h, 1298 write-stringtable.h. 1299 (main): Change handling of --properties-output, --stringtable-output 1300 options. Pass the output_syntax to msgdomain_list_print. 1301 * msgcomm.c: Include write-catalog.h, write-properties.h, 1302 write-stringtable.h. 1303 (main): Change handling of --properties-output, --stringtable-output 1304 options. Pass the output_syntax to msgdomain_list_print. 1305 * msgconv.c: Include write-catalog.h, write-properties.h, 1306 write-stringtable.h. 1307 (main): Change handling of --properties-output, --stringtable-output 1308 options. Pass the output_syntax to msgdomain_list_print. 1309 * msgen.c: Include write-catalog.h, write-properties.h, 1310 write-stringtable.h. 1311 (main): Change handling of --properties-output, --stringtable-output 1312 options. Pass the output_syntax to msgdomain_list_print. 1313 * msgfilter.c: Include write-catalog.h, write-properties.h, 1314 write-stringtable.h. 1315 (main): Change handling of --properties-output, --stringtable-output 1316 options. Pass the output_syntax to msgdomain_list_print. 1317 * msggrep.c: Include write-catalog.h, write-properties.h, 1318 write-stringtable.h. 1319 (main): Change handling of --properties-output, --stringtable-output 1320 options. Pass the output_syntax to msgdomain_list_print. 1321 * msginit.c: Include write-catalog.h, write-properties.h, 1322 write-stringtable.h. 1323 (main): Change handling of --properties-output, --stringtable-output 1324 options. Pass the output_syntax to msgdomain_list_print. 1325 * msgmerge.c: Include write-catalog.h, write-properties.h, 1326 write-stringtable.h. 1327 (main): Change handling of --properties-output, --stringtable-output 1328 options. Pass the output_syntax to msgdomain_list_print. 1329 * msgunfmt.c: Include write-catalog.h, write-properties.h, 1330 write-stringtable.h. 1331 (main): Change handling of --properties-output, --stringtable-output 1332 options. Pass the output_syntax to msgdomain_list_print. 1333 * msguniq.c: Include write-catalog.h, write-properties.h, 1334 write-stringtable.h. 1335 (main): Change handling of --properties-output, --stringtable-output 1336 options. Pass the output_syntax to msgdomain_list_print. 1337 * xgettext.c: Include write-catalog.h, write-properties.h, 1338 write-stringtable.h. 1339 (output_syntax): Change type to catalog_output_format_ty. 1340 (main): Update. Pass the output_syntax to msgdomain_list_print. 1341 (finalize_header): Update. 1342 * gettext-po.c: Include write-catalog.h. 1343 (po_file_write): Specify PO syntax. 1344 * Makefile.am (noinst_HEADERS): Add write-catalog.h. 1345 (libgettextsrc_la_SOURCES): Add write.catalog.c. 1346 13472006-10-05 Bruno Haible <bruno@clisp.org> 1348 1349 * lang-table.c (language_table): Add Adangme, Kashubian. Fix the 1350 names of Western Frisian, Marshallese, Sinhala. 1351 * msginit.c (catalogname_for_locale): Add entries for Kashubian, 1352 Western Frisian, South Ndebele. Change entry for Serbian from sr_CS to 1353 sr_RS. 1354 13552006-10-06 Bruno Haible <bruno@clisp.org> 1356 1357 * write-java.c (msgdomain_write_java): Use fopen_temp, fwriteerror_temp 1358 instead of fopen, fwriteerror. 1359 * write-csharp.c (msgdomain_write_csharp): Likewise. 1360 13612006-10-06 Bruno Haible <bruno@clisp.org> 1362 1363 * Makefile.am (LTV_CURRENT, LTV_REVISION, LTV_AGE): Bump to 3:0:3. 1364 13652006-10-03 Bruno Haible <bruno@clisp.org> 1366 1367 * message.h (struct message_ty): New fields prev_msgctxt, prev_msgid, 1368 prev_msgid_plural. 1369 * message.c (message_alloc): Initialize the prev_msg* fields. 1370 (message_free): Free the prev_msg* fields. 1371 (message_copy): Copy the prev_msg* fields. 1372 * msgl-ascii.c (is_ascii_message): Consider also the prev_msg* fields. 1373 * msgl-cat.c (catenate_msgdomain_list): Copy the prev_msg* fields if 1374 a message is copied, not merged. 1375 * msgl-equal.c (message_equal): Consider also the prev_msg* fields. 1376 * msgl-iconv.c (convert_prev_msgid): New function. 1377 (iconv_message_list): Call it. 1378 iconvable_prev_msgid): New function. 1379 (is_message_list_iconvable): Call it. 1380 1381 * po-lex.c (po_lex_previous): New variable. 1382 (lex_start, lex_end): Reset it. 1383 (keyword_p): Test it. New return values PREV_MSGID, PREV_MSGID_PLURAL, 1384 PREV_MSGCTXT. 1385 (po_gram_lex): Recognize #| and #~| syntax. New return value 1386 PREV_STRING. 1387 * po-gram-gen.y (do_callback_message): Add prev_msgctxt, prev_msgid, 1388 prev_msgid_plural arguments. 1389 (free_message_intro): New macro. 1390 (PREV_MSGCTXT, PREV_MSGID, PREV_MSGID_PLURAL, PREV_STRING): New tokens. 1391 (prev, message_intro): New structures. 1392 (po_file): Renamed from msgfmt. 1393 (message): Pass prev_* fields around. Call free_message_intro. 1394 (message_intro, prev): New rules. 1395 (msg_intro): Renamed from message_intro. 1396 (prev_msg_intro, prev_msgid_pluralform, prev_string_list): New rules. 1397 * read-po-abstract.h (struct abstract_po_reader_class_ty): Add 1398 prev_msgctxt, prev_msgid, prev_msgid_plural arguments to the 1399 'directive_message' method. 1400 (po_callback_message): Add prev_msgctxt, prev_msgid, 1401 prev_msgid_plural arguments. 1402 * read-po-abstract.c (call_directive_message, po_callback_message): Add 1403 prev_msgctxt, prev_msgid, prev_msgid_plural arguments. 1404 * read-po.h (struct default_po_reader_class_ty): Add prev_msgctxt, 1405 prev_msgid, prev_msgid_plural arguments to the 'add_message' method. 1406 (default_directive_message, default_add_message): Add prev_msgctxt, 1407 prev_msgid, prev_msgid_plural arguments. 1408 * read-po.c (call_add_message, default_directive_message, 1409 default_add_message): Add prev_msgctxt, prev_msgid, prev_msgid_plural 1410 arguments. 1411 * read-properties.c (properties_parse): Update. 1412 * read-stringtable.c (stringtable_parse): Update. 1413 * xgettext.c (exclude_directive_message): Add prev_msgctxt, prev_msgid, 1414 prev_msgid_plural arguments. 1415 * x-po.c (extract_add_message): Add prev_msgctxt, prev_msgid, 1416 prev_msgid_plural arguments. 1417 1418 * write-po.c (wrap): Add extra_indent argument. 1419 (message_print, message_print_obsolete): Print the prev_msgctxt, 1420 prev_msgid, prev_msgid_plural fields. Compute an extra_indent. 1421 1422 * msgmerge.c (keep_previous): New variable. 1423 (long_options): Add --previous option. 1424 (main): Handle it. 1425 (usage): Document --previous option. 1426 (message_merge): Add force_fuzzy argument. Set the new message's 1427 prev_msg* fields. 1428 (match_domain): Update. 1429 * msgattrib.c (REMOVE_PREV): New enum item. 1430 (long_options): Add --clear-previous option. 1431 (main): Handle it. 1432 (usage): Document --clear-previous option. 1433 (process_message_list): Handle REMOVE_PREV. 1434 * msgfmt.c (msgfmt_add_message): Add prev_msgctxt, prev_msgid, 1435 prev_msgid_plural arguments. 1436 * gettext-po.c (po_message_prev_msgctxt, po_message_set_prev_msgctxt, 1437 po_message_prev_msgid, po_message_set_prev_msgid, 1438 po_message_prev_msgid_plural, po_message_set_prev_msgid_plural): New 1439 functions. 1440 14412006-10-03 Bruno Haible <bruno@clisp.org> 1442 1443 * msgmerge.c (definitions_init): Fix initialization of fresh_lock. 1444 14452006-10-03 Bruno Haible <bruno@clisp.org> 1446 1447 * msgcmp.c (include_fuzzies, include_untranslated): New variables. 1448 (long_options): Add options --use-fuzzy, --use-untranslated. 1449 (main): Handle them. 1450 (usage): Document them. 1451 (match_domain): Consider include_fuzzies and include_untranslated. 1452 14532006-10-02 Bruno Haible <bruno@clisp.org> 1454 1455 * gettext-po.h.in (LIBGETTEXTPO_VERSION): Bump version number. 1456 * Makefile.am (LTV_CURRENT, LTV_REVISION, LTV_AGE): Bump to 2:1:2. 1457 14582006-10-01 Bruno Haible <bruno@clisp.org> 1459 1460 * x-perl.c (extract_balanced): Remove state argument. 1461 1462 * x-perl.c (extract_balanced): Remove unused variable prev_last_token. 1463 1464 Fix Perl parsing bug introduced between 0.14.6 and 0.15. 1465 * x-perl.c (extract_balanced): Add eat_delim and comma_delim arguments. 1466 Use recursion to handle the case of a keyword not followed by an 1467 opening parenthesis. When a keyword is seen, set next_argparser 1468 instead of modifying the argparser variable of the current recursion. 1469 When seeing an opening parenthesis, distinguish the case of function 1470 arguments and the case of a subexpression. Don't call collect_message 1471 for unused argument positions. 1472 Reported by Nicolas Fran��ois <nicolas.francois@centraliens.net>. 1473 1474 * x-perl.c (extract_balanced): Remove unused variable. 1475 14762006-09-06 Bruno Haible <bruno@clisp.org> 1477 1478 * msgl-iconv.c: Include xstriconv.h instead of iconvstring.h. 1479 (convert_string, convert_msgstr, iconvable_string, iconvable_msgstr): 1480 Use xmem_cd_iconv instead of iconv_string. 1481 * recode-sr-latin.c: Include xstriconv.h instead of iconvstring.h. 1482 (process): Use xmem_cd_iconv instead of iconv_string. 1483 14842006-09-04 Bruno Haible <bruno@clisp.org> 1485 1486 * Makefile.am (msginit_SOURCES): Add ../../gettext-runtime/intl/lock.c. 1487 Reported by Aaron Williams <aaron_williams@net.com>. 1488 14892006-08-28 Bruno Haible <bruno@clisp.org> 1490 1491 * x-scheme.c (read_object): Don't call arglist_parser_remember if 1492 argparser is NULL. 1493 * x-elisp.c (read_object): Likewise. 1494 * x-librep.c (read_object): Likewise. 1495 * x-lisp.c (read_object): Likewise. 1496 Reported by Kevin Ryde <user42@zip.com.au>. 1497 14982006-08-16 Bruno Haible <bruno@clisp.org> 1499 1500 * plural-table.c (plural_table): Put Hungarian under nplurals=2. 1501 Reported by Arpad Biro <biro_arpad@yahoo.com> and 1502 Gabor Kelemen <kelemeng@gnome.hu>. 1503 15042006-08-16 Bruno Haible <bruno@clisp.org> 1505 1506 * read-mo.c: Include stdbool.h, stdlib.h, format.h. 1507 (read_mo_file): Mark messages with system-dependent segments as 1508 "#, c-format" or "#, objc-format", as appropriate. 1509 Reported by Egmont Koblinger <egmont@uhulinux.hu>. 1510 15112006-08-07 Bruno Haible <bruno@clisp.org> 1512 1513 * xgettext.c (remember_a_message): Use the position passed as argument 1514 instead of a dummypos. 1515 Reported by Paul Eggert <eggert@cs.ucla.edu>. 1516 15172006-08-01 Bruno Haible <bruno@clisp.org> 1518 1519 Fix behaviour of msgmerge when the PO file and the compendium are 1520 in different encodings. 1521 * msgl-iconv.h (is_message_list_iconvable): New declaration. 1522 * msgl-iconv.c (iconvable_string, iconvable_string_list, 1523 iconvable_msgid, iconvable_msgstr, is_message_list_iconvable): New 1524 functions. 1525 * msgmerge.c: Include xallocsa.h. 1526 (merge): In the case that the .pot file is ASCII, not UTF-8, convert 1527 the definitions and the compendia contents to a common encoding. 1528 Reported by Stanislav Brabec <sbrabec@suse.cz>. 1529 15302006-07-30 Bruno Haible <bruno@clisp.org> 1531 1532 * Makefile.am (AM_CPPFLAGS, LDADD, libgettextsrc_la_LDFLAGS, 1533 libgettextpo_la_LDFLAGS, recode_sr_latin_LDADD, RELOCATABLE_SRC_DIR, 1534 RELOCATABLE_BUILD_DIR): Replace ../lib with ../gnulib-lib. 1535 (JAVACOMP, CSHARPCOMP): Remove lib/ from pathname. 1536 15372006-07-30 Bruno Haible <bruno@clisp.org> 1538 1539 * msgl-cat.c: Include c-strstr.h instead of strstr.h. 1540 (catenate_msgdomain_list): Use c_strstr instead of strstr. 1541 * msgl-charset.c: Include c-strstr.h instead of strstr.h. 1542 (compare_po_locale_charsets): Use c_strstr instead of strstr. 1543 * msgl-check.c: Include c-strstr.h instead of strstr.h. 1544 (plural_help, check_plural, check_header_entry): Use c_strstr instead 1545 of strstr. 1546 * msgl-iconv.c: Include c-strstr.h instead of strstr.h. 1547 (iconv_message_list): Use c_strstr instead of strstr. 1548 * po-charset.c: Include c-strstr.h instead of strstr.h. 1549 (po_lex_charset_set): Use c_strstr instead of strstr. 1550 * write-po.c: Include c-strstr.h instead of strstr.h. 1551 (msgdomain_list_print_po): Use c_strstr instead of strstr. 1552 * write-stringtable.c: Include c-strstr.h instead of strstr.h. 1553 (write_message): Use c_strstr instead of strstr. 1554 * msgcmp.c: Include c-strstr.h instead of strstr.h. 1555 (compare): Use c_strstr instead of strstr. 1556 * msginit.c: Include c-strstr.h instead of strstr.h. 1557 (content_type): Use c_strstr instead of strstr. 1558 * msgmerge.c: Include c-strstr.h instead of strstr.h. 1559 (message_merge, merge): Use c_strstr instead of strstr. 1560 * x-python.c: Include c-strstr.h instead of strstr.h. 1561 (try_to_extract_coding): Use c_strstr instead of strstr. 1562 * xgettext.c: Include c-strstr.h instead of strstr.h. 1563 (remember_a_message, finalize_header): Use c_strstr instead of strstr. 1564 15652006-07-23 Bruno Haible <bruno@clisp.org> 1566 1567 Exploit CPUs with multiple execution units. 1568 * msgmerge.c: Include lock.h. 1569 (struct definitions_ty): Add 'findex_init_lock' field. 1570 (definitions_init): Initialize it. 1571 (definitions_init_findex): Ensure findex is initialized by the 1572 first thread who attempts so. 1573 (match_domain): Split the main loop into two. Parallelize the first 1574 loop using OpenMP pragmas. 1575 * Makefile.am (msgmerge_CFLAGS): New variable. 1576 (msgmerge_LDADD): Add OPENMP_CFLAGS. 1577 15782006-07-25 Bruno Haible <bruno@clisp.org> 1579 1580 * Makefile.msvc: Remove file. 1581 * Makefile.am (EXTRA_DIST): Remove Makefile.msvc. 1582 15832006-07-25 Bruno Haible <bruno@clisp.org> 1584 1585 * Makefile.vms: Remove file. 1586 * Makefile.am (EXTRA_DIST): Remove Makefile.vms. 1587 15882006-07-24 Bruno Haible <bruno@clisp.org> 1589 1590 * Makefile.am (include_HEADERS): Remove variable. 1591 (nodist_include_HEADERS): New variable. 1592 Suggested by Ralf Corsepius <rc040203@freenet.de>. 1593 15942006-07-21 Bruno Haible <bruno@clisp.org> 1595 1596 * gettext-0.15 released. 1597 15982006-07-20 Bruno Haible <bruno@clisp.org> 1599 1600 * gettext-po.h.in (LIBGETTEXTPO_VERSION): Bump version number. 1601 16022006-07-20 Bruno Haible <bruno@clisp.org> 1603 1604 * Makefile.am (LTV_CURRENT, LTV_REVISION, LTV_AGE): Bump to 2:0:2. 1605 16062006-07-14 Bruno Haible <bruno@clisp.org> 1607 1608 * Makefile.am (MOSTLYCLEANFILES): New variable. 1609 16102006-07-02 Bruno Haible <bruno@clisp.org> 1611 1612 * write-csharp.c (msgdomain_write_csharp): Update. 1613 * write-java.c (msgdomain_write_java): Update. 1614 16152006-06-29 Bruno Haible <bruno@clisp.org> 1616 1617 * write-csharp.c (msgdomain_write_csharp): Update. 1618 * write-java.c (msgdomain_write_java): Likewise. 1619 16202006-06-28 Bruno Haible <bruno@clisp.org> 1621 1622 Assume <dirent.h> on all Unix platforms. Assume closedir works. 1623 * msginit.c: Don't include <sys/ndir.h>, <sys/dir.h>, <ndir.h>. 1624 (find_pot): Use closedir directly. 1625 16262006-06-27 Bruno Haible <bruno@clisp.org> 1627 1628 Assume correct S_ISDIR macro. 1629 * write-csharp.c: Remove test of STAT_MACROS_BROKEN. 1630 * write-java.c: Likewise. 1631 16322006-04-14 Bruno Haible <bruno@clisp.org> 1633 1634 Assume autoconf >= 2.60. 1635 * Makefile.am (localedir): Remove variable. 1636 16372006-06-21 Bruno Haible <bruno@clisp.org> 1638 1639 * x-sh.c (read_word): Recognize the Bash process substitution syntax. 1640 16412006-06-21 Bruno Haible <bruno@clisp.org> 1642 1643 * x-sh.c (read_word): Recognize $(...) and $((...)) also inside 1644 double-quoted strings. 1645 Reported by Michelle Konzack <linux4michelle@freenet.de>. 1646 16472006-06-04 Bruno Haible <bruno@clisp.org> 1648 1649 * msgl-check.c (check_plural_eval): Declare 'distribution' as volatile, 1650 so that it is unaffected by longjmp. 1651 16522006-06-04 Bruno Haible <bruno@clisp.org> 1653 1654 * xgettext.c (arglist_parser_done): Cast length argument for format 1655 string. 1656 16572006-05-31 Bruno Haible <bruno@clisp.org> 1658 1659 * x-ycp.c (phase5_pushback, phase5_pushback_length): New variables. 1660 (phase5_get): Renamed from x_ycp_lex. 1661 (phase5_unget): New function. 1662 (phase8_get): New function. 1663 (extract_parenthesized): Inside i18n construct, use phase8_get 1664 instead of phase5_get. 1665 Reported by Karl Eichwalder <ke@suse.de>. 1666 16672006-05-22 Bruno Haible <bruno@clisp.org> 1668 1669 * msgfilter.c: Include <sys/select.h> also on Minix. 1670 Reported by Leonard den Ottolander <leonard@den.ottolander.nl>. 1671 16722006-05-17 Bruno Haible <bruno@clisp.org> 1673 1674 Cygwin portability. 1675 * hostname.c (WIN32_NATIVE): Renamed from WIN32. 1676 16772006-05-16 Bruno Haible <bruno@clisp.org> 1678 1679 * Makefile.am (CLEANFILES): Add gettext-po.h. 1680 16812006-05-16 Bruno Haible <bruno@clisp.org> 1682 1683 * xgettext.c (main): Use a size_t index variable for looping over the 1684 files. 1685 (arglist_parser_done): Fix a format string. 1686 16872006-05-16 Bruno Haible <bruno@clisp.org> 1688 1689 * msgfilter.c (main): Change type of i. 1690 16912006-05-15 Bruno Haible <bruno@clisp.org> 1692 1693 * Makefile.am: Test flag WOE32DLL instead of CYGWINDLL. 1694 16952006-05-14 Bruno Haible <bruno@clisp.org> 1696 1697 * x-php.c (x_php_lex): Fix handling of here documents. 1698 Reported by Ga��tan Frenoy <gaetan@frenoy.net>. 1699 17002006-05-12 Bruno Haible <bruno@clisp.org> 1701 1702 * write-csharp.c [MINGW]: Include <io.h>. 1703 (mkdir): Define using _mkdir. 1704 * write-java.c [MINGW]: Include <io.h>. 1705 (mkdir): Define using _mkdir. 1706 17072006-05-11 Bruno Haible <bruno@clisp.org> 1708 1709 * gettext-po.h.in: Renamed from gettext-po.h. 1710 * Makefile.am: Treat condition WOE32DLL like MINGW. Update file names. 1711 (libgettextsrc_la_SOURCES, libgettextsrc_la_LDFLAGS): Modify for 1712 Cygwin. 1713 libgettextpo_la_SOURCES, libgettextpo_la_LDFLAGS): Likewise. 1714 (BUILT_SOURCES): Add gettext-po.h. 1715 (EXTRA_DIST): Add gettext-po.h.in. 1716 (gettext-po.h): New rule. 1717 17182006-05-11 Bruno Haible <bruno@clisp.org> 1719 1720 * Makefile.am (format_CFLAGS): Remove variable. 1721 (format.lo): Remove variable. 1722 (FORMAT_SOURCE) [MINGW]: Use ../mingw/c++format.cc instead of format.c. 1723 17242006-05-09 Bruno Haible <bruno@clisp.org> 1725 1726 * plural-eval.h (USE_SIGINFO): Don't define on Cygwin. 1727 17282006-05-02 Charles Wilson <cygwin@cwilson.fastmail.fm> 1729 1730 * write-mo.h: Remove DLL_VARIABLE declarations, not needed since 1731 write-mo.c is not compiled into a shared library. 1732 * lang-table.h: Likewise. 1733 17342006-05-02 Charles Wilson <cygwin@cwilson.fastmail.fm> 1735 1736 * filters.h: Add C++ guards. 1737 17382006-05-07 Bruno Haible <bruno@clisp.org> 1739 1740 * x-perl.c (extract_variable): Fix syntax error introduced on 1741 2005-10-03. 1742 17432006-05-07 Bruno Haible <bruno@clisp.org> 1744 1745 * format-awk.c: Include xvasprintf.h instead of xerror.h. 1746 * format-elisp.c: Likewise. 1747 * format-librep.c: Likewise. 1748 * format-pascal.c: Likewise. 1749 * format-php.c: Likewise. 1750 * format-tcl.c: Likewise. 1751 17522006-04-30 Bruno Haible <bruno@clisp.org> 1753 1754 * write-java.c (msgdomain_write_java): Specify source-version 1.3 and 1755 require target-version 1.1. 1756 17572006-04-30 Bruno Haible <bruno@clisp.org> 1758 1759 * msginit.c (main): Simplify by use of xasprintf(). 1760 * write-java.c: Include xvasprintf.h. 1761 (msgdomain_write_java): Simplify by use of xasprintf(). 1762 * x-c.c: Include xvasprintf.h. 1763 (phase8a_get): Simplify by use of xasprintf(). 1764 * xgettext.c: Don't include stpcpy.h. 1765 (remember_a_message, remember_a_message_plural): Simplify by use of 1766 xasprintf(). 1767 17682006-04-30 Bruno Haible <bruno@clisp.org> 1769 1770 * msgfmt.c: Include xvasprintf.h. 1771 * msginit.c: Likewise. 1772 * msgl-cat.c: Likewise. 1773 * msgl-charset.c: Likewise. 1774 * po-xerror.c: Likewise. 1775 * x-csharp.c: Likewise. 1776 * x-glade.c: Likewise. 1777 * x-python.c: Likewise. 1778 * xgettext.c: Likewise. 1779 * format-boost.c: Include xvasprintf.h instead of xerror.h. 1780 * format-c.c: Likewise. 1781 * format-csharp.c: Likewise. 1782 * format-gcc-internal.c: Likewise. 1783 * format-java.c: Likewise. 1784 * format-lisp.c: Likewise. 1785 * format-perl.c: Likewise. 1786 * format-python.c: Likewise. 1787 * format-qt.c: Likewise. 1788 * format-scheme.c: Likewise. 1789 * format-ycp.c: Likewise. 1790 * msgexec.c: Likewise. 1791 * msgl-check.c: Likewise. 1792 * msgl-iconv.c: Likewise. 1793 * open-po.c: Likewise. 1794 * po-charset.c: Likewise. 1795 * po-lex.c: Likewise. 1796 * po-time.c: Likewise. 1797 * read-po-abstract.c: Likewise. 1798 * read-properties.c: Likewise. 1799 * read-stringtable.c: Likewise. 1800 * write-po.c: Likewise. 1801 18022006-04-30 Bruno Haible <bruno@clisp.org> 1803 1804 * msginit.c (project_id, project_id_version, get_user_email): Close 1805 the FILE in case of I/O error. 1806 18072006-04-30 Bruno Haible <bruno@clisp.org> 1808 1809 * write-java.c (msgdomain_write_java): Don't fclose the FILE after 1810 fwriteerror signalled a failure. 1811 * write-csharp.c (msgdomain_write_csharp): Likewise. 1812 18132006-04-23 Bruno Haible <bruno@clisp.org> 1814 1815 * msgexec.c: Include <unistd.h> unconditionally. 1816 * msgfilter.c: Likewise. 1817 * msggrep.c: Likewise. 1818 * msginit.c: Likewise. 1819 * hostname.c: Likewise. 1820 * urlget.c: Likewise. 1821 18222006-04-17 Bruno Haible <bruno@clisp.org> 1823 1824 * Makefile.am: Use $(mkdir_p) instead of $(mkinstalldirs). 1825 18262006-04-09 Bruno Haible <bruno@clisp.org> 1827 1828 * write-csharp.c: Include clean-temp.h. Don't include unistd.h, 1829 mkdtemp.h, tmpdir.h, pathmax.h, fatal-signal.h, xallocsa.h. 1830 (cleanup_list): Remove variable. 1831 (cleanup): Remove function. 1832 (msgdomain_write_csharp): Simplify handling of temporary directory. 1833 * write-java.c: Include clean-temp.h. Don't include unistd.h, 1834 mkdtemp.h, tmpdir.h, pathmax.h, fatal-signal.h. 1835 (cleanup_list): Remove variable. 1836 (cleanup): Remove function. 1837 (msgdomain_write_java): Simplify handling of temporary directory. 1838 18392006-04-03 Bruno Haible <bruno@clisp.org> 1840 1841 * x-glade.c (p_XML_GetCurrentLineNumber, p_XML_GetCurrentColumnNumber): 1842 Declare differently for expat >= 2.0.0. 1843 (load_libexpat): Search for a differently library name for expat >= 1844 2.0.0. 1845 (do_extract_glade): Update. 1846 Reported by Mike Frysinger <vapier@gentoo.org>. 1847 18482006-04-02 Bruno Haible <bruno@clisp.org> 1849 1850 * hostname.c: Include propername.h. 1851 (main): Call proper_name. 1852 * msgattrib.c: Include propername.h. 1853 (main): Call proper_name. 1854 * msgcat.c: Include propername.h. 1855 (main): Call proper_name. 1856 * msgcmp.c: Include propername.h. 1857 (main): Call proper_name. 1858 * msgcomm.c: Include propername.h. 1859 (main): Call proper_name. 1860 * msgconv.c: Include propername.h. 1861 (main): Call proper_name. 1862 * msgen.c: Include propername.h. 1863 (main): Call proper_name. 1864 * msgexec.c: Include propername.h. 1865 (main): Call proper_name. 1866 * msgfilter.c: Include propername.h. 1867 (main): Call proper_name. 1868 * msgfmt.c: Include propername.h. 1869 (main): Call proper_name. 1870 * msggrep.c: Include propername.h. 1871 (main): Call proper_name. 1872 * msginit.c: Include propername.h. 1873 (main): Call proper_name. 1874 * msgmerge.c: Include propername.h. 1875 (main): Call proper_name. 1876 * msgunfmt.c: Include propername.h. 1877 (main): Call proper_name. 1878 * msguniq.c: Include propername.h. 1879 (main): Call proper_name. 1880 * recode-sr-latin.c: Include propername.h. 1881 (main): Call proper_name and proper_name_utf8. 1882 * urlget.c: Include propername.h. 1883 (main): Call proper_name. 1884 * xgettext.c: Include propername.h. 1885 (main): Call proper_name. 1886 18872006-04-01 Bruno Haible <bruno@clisp.org> 1888 1889 * xgettext.c (main): Treat --keyword= like --keyword. 1890 18912006-03-28 Bruno Haible <bruno@clisp.org> 1892 1893 * filters.h: New file. 1894 * filter-sr-latin.c: New file, based on code from Danilo ��egan. 1895 * recode-sr-latin.c: New file. 1896 * msgfilter.c: Include filters.h, msgl-iconv.h, po-charset.h. 1897 (filter): New variable. 1898 (main): Recognize recode-sr-latin as built-in. 1899 (generic_filter): New function, extracted from process_string. 1900 (process_string): Call the filter. 1901 * Makefile.am (bin_PROGRAMS): Add recode-sr-latin. 1902 (noinst_HEADERS): Add filters.h. 1903 (msgfilter_SOURCES): Add filter-sr-latin.c. 1904 (recode_sr_latin_SOURCES, recode_sr_latin_LDADD, 1905 recode_sr_latin_CPPFLAGS, recode_sr_latin_LDFLAGS): New variables. 1906 * Makefile.msvc (PROGRAMS): Add recode-sr-latin.exe. 1907 (msgfilter_OBJECTS): Add filter-sr-latin.obj. 1908 (recode_sr_latin_OBJECTS): New variable. 1909 (filter-sr-latin.obj, recode-sr-latin.obj): New rules. 1910 (recode-sr-latin.exe): New rule. 1911 (install): Also install recode-sr-latin.exe. 1912 (uninstall): Also uninstall recode-sr-latin.exe. 1913 * Makefile.vms (PROGRAMS): Add recode-sr-latin.exe. 1914 (msgfilter_OBJECTS): Add filter-sr-latin.obj. 1915 (recode_sr_latin_OBJECTS): New variable. 1916 (filter-sr-latin.obj, recode-sr-latin.obj): New rules. 1917 (recode-sr-latin.exe): New rule. 1918 (install): Also install recode-sr-latin.exe. 1919 (uninstall): Also uninstall recode-sr-latin.exe. 1920 19212006-03-28 Bruno Haible <bruno@clisp.org> 1922 1923 * msgl-iconv.c: Include iconvstring.h. Don't include <errno.h>. 1924 (iconv_string): Remove function, moved to ../lib/. 1925 19262006-03-19 Bruno Haible <bruno@clisp.org> 1927 1928 * xgettext.h (struct callshape): New field 'xcomments'. 1929 (struct partial_call): New field 'xcomments'. 1930 * xgettext.c (split_keywordspec): Accept the ID:ARGNUM...,"XCOMMENT" 1931 syntax. 1932 (insert_keyword_callshape): Store the xcomments from the new shape. 1933 (arglist_parser_alloc, arglist_parser_clone): Update. 1934 (arglist_parser_done): After calling remember_a_message, attach the 1935 specified extracted comments. 1936 * x-perl.c (extract_variable): Update. 1937 Suggested by Behdad Esfahbod <behdad@cs.toronto.edu>. 1938 19392006-03-19 Bruno Haible <bruno@clisp.org> 1940 1941 * xgettext.c (arglist_parser_done): Use error_at_line instead of error. 1942 19432006-03-16 Bruno Haible <bruno@clisp.org> 1944 1945 * msggrep.c (grep_task): Increment size. 1946 (long_options): Add --extracted-comment option. 1947 (main): Handle --extracted-comment option. 1948 (no_pass, usage): Update. 1949 (is_message_selected_no_invert): Implement matching on extracted 1950 comments. 1951 Suggested by Behdad Esfahbod <behdad@cs.toronto.edu>. 1952 19532006-03-16 Bruno Haible <bruno@clisp.org> 1954 1955 Handle GNOME glib context syntax. 1956 * xgettext.h (struct callshape): Add fields argnum1_glib_context, 1957 argnum2_glib_context. 1958 (struct partial_call): Add fields argnum1_glib_context, 1959 argnum2_glib_context. 1960 * xgettext.c (split_keywordspec): Recognize suffix 'g' and set the 1961 argnum1_glib_context, argnum2_glib_context fields. 1962 (insert_keyword_callshape, arglist_parser_alloc, arglist_parser_clone): 1963 Update. 1964 (arglist_parser_done): When suffix 'g' was specified, split off the 1965 context from the msgid and/or msgid_plural. 1966 * x-perl.c (extract_variable): Update. 1967 Suggested by Danilo ��egan <danilo@gnome.org>. 1968 19692006-03-16 Bruno Haible <bruno@clisp.org> 1970 1971 * xgettext.c (set_format_flags_from_context): Break long line. 1972 19732006-03-11 Bruno Haible <bruno@clisp.org> 1974 1975 * message.c (fuzzy_search_goal_function): Use 'volatile double'. 1976 19772006-03-11 Bruno Haible <bruno@clisp.org> 1978 1979 Speed up msgmerge with large compendia. 1980 * message.h (message_list_free): Add keep_messages argument. 1981 (message_list_list_free): Add keep_level argument. 1982 (fuzzy_search_goal_function): New declaration. 1983 (FUZZY_THRESHOLD): New macro. 1984 * message.c (message_list_free): Add keep_messages argument. 1985 (fuzzy_search_goal_function): New function, extracted from 1986 message_list_search_fuzzy_inner. 1987 (message_list_search_fuzzy_inner): Use it. 1988 (message_list_search_fuzzy): Use symbolic value FUZZY_THRESHOLD. 1989 (message_list_list_free): Comment in. Add keep_level argument. 1990 (message_list_list_search_fuzzy): Comment out. Use symbolic value 1991 FUZZY_THRESHOLD. 1992 (msgdomain_free): Update. 1993 (msgdomain_list_search_fuzzy): Use symbolic value FUZZY_THRESHOLD. 1994 * po-charset.h: Include stddef.h. 1995 (character_iterator_t): New type. 1996 (po_charset_character_iterator): New declaration. 1997 * po-charset.c (char_iterator, euc_character_iterator, 1998 euc_jp_character_iterator, euc_tw_character_iterator, 1999 big5_character_iterator, big5hkscs_character_iterator, 2000 gbk_character_iterator, gb18030_character_iterator, 2001 shift_jis_character_iterator, johab_character_iterator, 2002 utf8_character_iterator, po_charset_character_iterator): New functions. 2003 * msgl-fsearch.h: New file. 2004 * msgl-fsearch.c: New file. 2005 * msgmerge.c: Include po-charset.h, msgl-fsearch.h. 2006 (compendium_filenames): New variable. 2007 (compendium): Also put the filename into compendium_filenames. 2008 (definitions_ty): New structure type. 2009 (definitions_init, definitions_init_findex, definitions_current_list, 2010 definitions_set_current_list, definitions_search, 2011 definitions_search_fuzzy, definitions_destroy): New functions. 2012 (match_domain): Change type of 'definitions' argument. 2013 (merge): Also convert the compendium to UTF-8. Use definitions_init, 2014 definitions_set_current_list, definitions_destroy. 2015 * msgfmt.c (main): Update. 2016 * Makefile.am (noinst_HEADERS): Add msgl-fsearch.h. 2017 (msgmerge_SOURCES): Add msgl-fsearch.c. 2018 (msgmerge_LDADD): Link with MSGMERGE_LIBM. 2019 * Makefile.msvc (msgmerge_OBJECTS): Add msgl-fsearch.obj. 2020 (msgl-fsearch.obj): New rule. 2021 * Makefile.vms (msgmerge_OBJECTS): Add msgl-fsearch.obj. 2022 (msgl-fsearch.obj): New rule. 2023 Reported by Clytie Siddall <clytie@riverland.net.au>. 2024 20252006-03-09 Bruno Haible <bruno@clisp.org> 2026 2027 * Makefile.am (CXXLINK) [!mingw]: Overwrite automake's value. Fixes 2028 unintended dependency on libstdc++ introduced on 2005-07-05. 2029 20302005-10-09 Bruno Haible <bruno@clisp.org> 2031 2032 * lang-table.h: New file. 2033 * lang-table.c: New file, extracted from msginit.c. 2034 * msginit.c: Include lang-table.h. 2035 (englishname_of_language): Use language_table. 2036 * Makefile.am (noinst_HEADERS): Add lang-table.h. 2037 (msginit_SOURCES): Add lang-table.c. 2038 * Makefile.msvc (MSGINIT_OBJECTS): Add lang-table.obj. 2039 (lang-table.obj): New rule. 2040 * Makefile.vms (MSGINIT_OBJECTS): Add lang-table.obj. 2041 (lang-table.obj): New rule. 2042 20432006-02-12 Bruno Haible <bruno@clisp.org> 2044 2045 * message.h (format_type): New enum value 'format_boost'. 2046 (NFORMATS): Increment. 2047 * message.c (format_language): Add format_boost entry. 2048 (format_language_pretty): Likewise. 2049 * format.h (formatstring_boost): New declaration. 2050 * format-boost.c: New file, based on format-c.c. 2051 * format.c (formatstring_parsers): Add formatstring_boost. 2052 * x-c.c (init_flag_table_c): Also register flags for boost-format. 2053 * xgettext.c (flag_table_cxx_qt, flag_table_cxx_boost): New variables. 2054 (recognize_format_boost): New variable. 2055 (main): Handle --boost option. 2056 (usage): Document --boost option. 2057 (xgettext_record_flag): Also fill flag_table_cxx_qt, 2058 flag_table_cxx_boost. 2059 (remember_a_message, remember_a_message_plural): In the heuristics, 2060 don't mark a string as c-format that is already known to be a qt-format 2061 or boost-format. 2062 (language_to_extractor): Use a flag_table_cxx_qt or 2063 flag_table_cxx_boost that is different from flag_table_c. 2064 * Makefile.am (FORMAT_SOURCE): Add format-boost.c. 2065 * Makefile.msvc (OBJECTS): Add format-boost.obj. 2066 (format-boost.obj): New rule. 2067 * Makefile.vms (OBJECTS): Add format-boost.obj. 2068 (format-boost.obj): New rule. 2069 * FILES: Update. 2070 20712006-02-12 Bruno Haible <bruno@clisp.org> 2072 2073 * xgettext.c (xgettext_record_flag): When asked to set "qt-format", 2074 really set "qt-format", not "c-format". Fixes bug introduced on 2075 2003-10-19. 2076 20772006-02-12 Bruno Haible <bruno@clisp.org> 2078 2079 Reduce the number of false positives produced by the c-format guessing 2080 heuristics. 2081 * format.h (struct formatstring_parser): Add 'is_unlikely_intentional' 2082 field. 2083 * format-awk.c (formatstring_awk): Update. 2084 * format-c.c (struct spec): Add 'unlikely_unintentional' field. 2085 (format_parse): Set unlikely_unintentional to true when encountering 2086 a "%...%" directive other than "%%". 2087 (format_is_unlikely_intentional): New function. 2088 (formatstring_c, formatstring_objc): Use it. 2089 * format-csharp.c (formatstring_csharp): Update. 2090 * format-elisp.c (formatstring_elisp): Update. 2091 * format-gcc-internal.c (formatstring_gcc_internal): Update. 2092 * format-java.c (formatstring_java): Update. 2093 * format-librep.c (formatstring_librep): Update. 2094 * format-lisp.c (formatstring_lisp): Update. 2095 * format-pascal.c (formatstring_pascal): Update. 2096 * format-perl.c (formatstring_perl): Update. 2097 * format-perl-brace.c (formatstring_perl_brace): Update. 2098 * format-php.c (format_php): Update. 2099 * format-python.c (formatstring_python): Update. 2100 * format-qt.c (formatstring_qt): Update. 2101 * format-scheme.c (formatstring_scheme): Update 2102 * format-sh.c (formatstring_sh): Update. 2103 * format-tcl.c (formatstring_tcl): Update. 2104 * format-ycp.c (formatstring_ycp, formatstring_smalltalk): Update. 2105 * xgettext.c (remember_a_message, remember_a_message_plural): Don't 2106 mark the message as c-format if the validity as c-format looks 2107 unintentional. 2108 21092006-02-12 Bruno Haible <bruno@clisp.org> 2110 2111 * msgattrib.c (main): Update year in --version output. 2112 * msgcat.c (main): Likewise. 2113 * msgcmp.c (main): Likewise. 2114 * msgcomm.c (main): Likewise. 2115 * msgconv.c (main): Likewise. 2116 * msgen.c (main): Likewise. 2117 * msgexec.c (main): Likewise. 2118 * msgfilter.c (main): Likewise. 2119 * msgfmt.c (main): Likewise. 2120 * msggrep.c (main): Likewise. 2121 * msginit.c (main): Likewise. 2122 * msgmerge.c (main): Likewise. 2123 * msgunfmt.c (main): Likewise. 2124 * msguniq.c (main): Likewise. 2125 * xgettext.c (main): Likewise. 2126 21272006-01-25 Bruno Haible <bruno@clisp.org> 2128 2129 * x-php.c (x_php_lex): Treat byte values >= 127 like alphabetic. 2130 Reported by Hagen Fritsch <itooktheredpill@gmx.de>. 2131 21322005-12-25 Bruno Haible <bruno@clisp.org> 2133 2134 Tell Python developers to use named arguments in format strings. 2135 * format.h (get_python_format_unnamed_arg_count): New declaration. 2136 * format-python.c (get_python_format_unnamed_arg_count): New function. 2137 * xgettext.c (warn_format_string): New function. 2138 (remember_a_message, remember_a_message_plural): Call it. 2139 Suggested by Martin von L��wis. 2140 21412005-12-07 Bruno Haible <bruno@clisp.org> 2142 2143 * msgl-iconv.c (iconv_message_list): Fix syntax error. 2144 Reported by Dave Patton <dpatton@confluence.org>. 2145 21462005-12-04 Bruno Haible <bruno@clisp.org> 2147 2148 * Makefile.am (CSHARPCOMPFLAGS): Use value set by csharpcomp.m4. 2149 21502005-11-29 Colin Watson <cjwatson@ubuntu.com> 2151 2152 * msggrep.c (invert_match): New variable. 2153 (long_options): Add --invert-match option. 2154 (main): Handle --invert-match option. 2155 (usage): Document --invert-match option. 2156 (is_message_selected_no_invert): New function, extracted from 2157 is_message_selected. 2158 (is_message_selected): Call it. Handle match inversion. 2159 21602005-11-01 Bruno Haible <bruno@clisp.org> 2161 2162 * write-csharp.c (write_csharp_code): Add culture_name argument. 2163 Emit an AssemblyCulture note for it. 2164 (msgdomain_write_csharp): Update. 2165 Suggested by Pepa <cerna.zelva@seznam.cz>. 2166 21672005-10-09 Bruno Haible <bruno@clisp.org> 2168 2169 * plural-eval.h: New file. 2170 * plural-eval.c: Include plural-eval.h. 2171 (sigfpe_exit, sigfpe_code, sigfpe_handler, install_sigfpe_handler, 2172 uninstall_sigfpe_handler): New definitions, moved here from 2173 msgl-check.c. 2174 * msgl-check.c: Include plural.eval.h. 2175 (sigjmp_buf, sigsetjmp, siglongjmp, USE_SIGINFO): Move to plural-eval.h. 2176 (sigfpe_exit, sigfpe_code, sigfpe_handler, install_sigfpe_handler, 2177 uninstall_sigfpe_handler): Move to plural-eval.c. 2178 * Makefile.am (noinst_HEADERS): Add plural-eval.h. 2179 21802005-10-09 Bruno Haible <bruno@clisp.org> 2181 2182 * msgl-check.c: Include c-ctype.h instead of ctype.h. 2183 (check_plural): Use c_isspace instead of isspace. 2184 * x-librep.c: Include c-ctype.h instead of ctype.h. 2185 (read_token): Use c_isxdigit instead of isxdigit. 2186 * x-rst.c: Include c-ctype.h instead of ctype.h. 2187 (extract_rst): Use c_isdigit instead of isdigit. 2188 * x-ycp.c: Don't include ctype.h. 2189 21902005-10-09 Bruno Haible <bruno@clisp.org> 2191 2192 * plural-exp.c: Renamed from plural.c. 2193 * Makefile.am (libgettextsrc_la_SOURCES): Update. 2194 21952005-10-18 Bruno Haible <bruno@clisp.org> 2196 2197 Disambiguate overloaded function calls according to argument count. 2198 * xgettext.h (struct callshape): Add field 'argtotal'. 2199 (struct partial_call): Likewise. 2200 (arglist_parser_done): Add argnum argument. 2201 * xgettext.c (split_keywordspec): Recognize NNt syntax and fill 2202 argtotal. 2203 (insert_keyword_callshape, arglist_parser_alloc, arglist_parser_clone): 2204 Update. 2205 (arglist_parser_decidedp): Compare also the argtotal if given. 2206 (arglist_parser_done): Add argnum argument. 2207 * x-awk.c (extract_parenthesized): Pass arg count to 2208 arglist_parser_done. 2209 * x-c.c (extract_parenthesized): Likewise. 2210 * x-csharp.c (extract_parenthesized): Likewise. 2211 * x-elisp.c (read_object): Likewise. 2212 * x-java.c (extract_parenthesized): Likewise. 2213 * x-librep.c (read_object): Likewise. 2214 * x-lisp.c (read_object): Likewise. 2215 * x-perl.c (extract_variable): Update. 2216 (extract_balanced): Pass arg count to arglist_parser_done. 2217 * x-php.c (extract_parenthesized): Likewise. 2218 * x-python.c (extract_parenthesized): Likewise. 2219 * x-scheme.c (read_object): Likewise. 2220 * x-sh.c (read_command): Likewise. 2221 * x-tcl.c (read_command): Likewise. 2222 Stimulated by a patch from 2223 Chusslove Illich (������������ ��������) <caslav.ilic@gmx.net>. 2224 22252005-10-09 Bruno Haible <bruno@clisp.org> 2226 2227 * msginit.c (catalogname_for_locale, language_of_locale): Drop support 2228 of CEN locale name syntax. 2229 22302005-10-05 Bruno Haible <bruno@clisp.org> 2231 2232 * format.h (check_msgid_msgstr_format): Add plural_distribution 2233 argument. 2234 * format.c (check_msgid_msgstr_format): Add plural_distribution 2235 argument. Use it for index dependent strictness. 2236 * msgl-check.h (check_message): Add plural_distribution argument. 2237 * msgl-check.c: Include xalloc.h. 2238 (check_plural_eval): Create a plural_distribution array as additional 2239 output parameter. 2240 (check_plural): Return plural_distribution array as additional output 2241 parameter. 2242 (check_pair, check_message): Add plural_distribution argument. 2243 (check_message_list): Pass the plural_distribution from check_plural 2244 to check_message. 2245 * gettext-po.c (po_message_check_format): Update. 2246 22472005-10-04 Bruno Haible <bruno@clisp.org> 2248 2249 Combine all msgfmt checks in a single place. 2250 * format.h (check_msgid_msgstr_format): Change return type to int. 2251 * format.c (check_msgid_msgstr_format): Return the number of errors. 2252 * msgl-check.h (check_plural): Remove declaration. 2253 * msgl-check.c (check_plural): Make static. Return the number of 2254 errors. 2255 (check_pair): Return the number of errors. 2256 (check_message_list): Likewise. 2257 * msgfmt.c (main): Perform the message checks here, after all files 2258 were read. Call check_message_list instead of check_plural and 2259 check_message. Emit statistics of fatal errors. 2260 (msgfmt_frob_new_message): Don't call check_message here. 2261 22622005-10-04 Bruno Haible <bruno@clisp.org> 2263 2264 * msgl-check.h (check_message_list): New declaration. 2265 * msgl-check.c (check_message_list): New function. 2266 * gettext-po.c (po_file_check_all, po_message_check_all): Call 2267 check_message_list instead of check_message and check_plural. 2268 22692005-10-04 Bruno Haible <bruno@clisp.org> 2270 2271 Fix handling of obsolete messages. 2272 * msgl-check.c (check_plural): Ignore obsolete messages. 2273 * gettext-po.c (po_file_check_all, po_message_check_all, 2274 po_message_check_format): Likewise. 2275 22762005-10-04 Bruno Haible <bruno@clisp.org> 2277 2278 * msgl-check.h (check_message): Remove msgstr_pos argument. 2279 * msgl-check.c (check_pair, check_message): Remove msgstr_pos argument. 2280 * msgfmt.c (msgfmt_frob_new_message): Update. 2281 * gettext-po.c (po_file_check_all, po_message_check_all, 2282 po_message_check_format): Update. 2283 22842005-10-03 Bruno Haible <bruno@clisp.org> 2285 2286 Add support for contexts in xgettext. 2287 * xgettext.h: Include stdbool.h. 2288 (struct callshape): New structure type. 2289 (split_keywordspec): Return a struct callshape, not two integers, 2290 by reference. 2291 (struct callshapes): New structure type. 2292 (insert_keyword_callshape): New declaration. 2293 (remember_a_message): Add msgctxt argument. 2294 (struct partial_call): New structure type. 2295 (struct arglist_parser): New structure type. 2296 (arglist_parser_alloc, arglist_parser_clone, arglist_parser_remember, 2297 arglist_parser_decidedp, arglist_parser_done): New declarations. 2298 * xgettext.c (split_keywordspec): Return a struct callshape, not two 2299 integers, by reference. Handle the notation Nc for a context argument. 2300 (insert_keyword_callshape): New function. 2301 (remember_a_message): Add msgctxt argument. Free both strings when 2302 the message is excluded. 2303 (arglist_parser_alloc, arglist_parser_clone, arglist_parser_remember, 2304 arglist_parser_decidedp, arglist_parser_done): New functions. 2305 * x-awk.c (x_awk_keyword): Use callshape API: split_keywordspec, 2306 insert_keyword_callshape. 2307 (extract_parenthesized): Replace commas_to_skip, plural_commas 2308 arguments with a single argparser argument. Use arglist_parser_* API. 2309 (extract_awk): Update. 2310 * x-c.c (add_keyword): Use callshape API: split_keywordspec, 2311 insert_keyword_callshape. 2312 (init_keywords): Register the new functions [d[c]][n]pgettext. 2313 (init_flag_table_c, init_flag_table_objc): Likewise. 2314 (struct xgettext_token_ty): Replace argnum1, argnum2 with a callshapes 2315 pointer. 2316 (x_c_lex): Update. 2317 (extract_parenthesized): Replace commas_to_skip, plural_commas 2318 arguments with a single argparser argument. Use arglist_parser_* API. 2319 (extract_whole_file): Update. 2320 * x-csharp.c (x_csharp_keyword): Use callshape API: split_keywordspec, 2321 insert_keyword_callshape. 2322 (extract_parenthesized): Replace commas_to_skip, plural_commas 2323 arguments with a single argparser argument. Use arglist_parser_* API. 2324 (extract_csharp): Update. 2325 * x-elisp.c (x_elisp_keyword): Use callshape API: split_keywordspec, 2326 insert_keyword_callshape. 2327 (read_object): Use arglist_parser_* API. 2328 * x-glade.c (start_element_handler, end_element_handler): Update. 2329 * x-java.c (x_java_keyword): Use callshape API: split_keywordspec, 2330 insert_keyword_callshape. 2331 (extract_parenthesized): Replace commas_to_skip, plural_commas 2332 arguments with a single argparser argument. Use arglist_parser_* API. 2333 (extract_java): Update. 2334 * x-librep.c (x_librep_keyword): Use callshape API: split_keywordspec, 2335 insert_keyword_callshape. 2336 (read_object): Use arglist_parser_* API. 2337 * x-lisp.c (x_lisp_keyword): Use callshape API: split_keywordspec, 2338 insert_keyword_callshape. 2339 (read_object): Use arglist_parser_* API. 2340 * x-perl.c (x_perl_keyword): Use callshape API: split_keywordspec, 2341 insert_keyword_callshape. 2342 (extract_balanced): Replace arg_sg, arg_pl arguments with arg, 2343 argparser arguments. Use arglist_parser_* API. 2344 (extract_variable, interpolate_keywords, extract_perl): Update. 2345 * x-php.c (x_php_keyword): Use callshape API: split_keywordspec, 2346 insert_keyword_callshape. 2347 (extract_parenthesized): Replace commas_to_skip, plural_commas 2348 arguments with a single argparser argument. Use arglist_parser_* API. 2349 (extract_php): Update. 2350 * x-python.c (x_python_keyword): Use callshape API: split_keywordspec, 2351 insert_keyword_callshape. 2352 (extract_parenthesized): Replace commas_to_skip, plural_commas 2353 arguments with a single argparser argument. Use arglist_parser_* API. 2354 (extract_python): Update. 2355 * x-rst.c (extract_rst): Update. 2356 * x-scheme.c (x_scheme_keyword): Use callshape API: split_keywordspec, 2357 insert_keyword_callshape. 2358 (read_object): Use arglist_parser_* API. 2359 * x-sh.c (x_sh_keyword): Use callshape API: split_keywordspec, 2360 insert_keyword_callshape. 2361 (read_word): Update. 2362 (read_command): Use arglist_parser_* API. 2363 * x-smalltalk.c (extract_smalltalk): Update. 2364 * x-tcl.c (x_tcl_keyword): Use callshape API: split_keywordspec, 2365 insert_keyword_callshape. 2366 (read_command): Use arglist_parser_* API. 2367 * x-ycp.c (extract_parenthesized): Update. 2368 23692005-10-03 Bruno Haible <bruno@clisp.org> 2370 2371 * xgettext.h (savable_comment_to_xgettext_comment): Remove 2372 declaration. 2373 (remember_a_message, remember_a_message_plural): Add a comment 2374 argument. 2375 * xgettext.c (savable_comment_to_xgettext_comment): Make static. 2376 (remember_a_message): Add comment argument. Call 2377 savable_comment_to_xgettext_comment and savable_comment_reset at the 2378 end. 2379 (remember_a_message_plural): Add comment argument. Call 2380 savable_comment_to_xgettext_comment and xgettext_comment_reset, 2381 savable_comment_reset at the end. 2382 * x-awk.c (extract_parenthesized): Pass comment to remember_a_message. 2383 * x-c.c (extract_parenthesized): Likewise. 2384 * x-csharp.c (extract_parenthesized): Likewise. 2385 * x-elisp.c (read_object): Likewise. 2386 * x-glade.c (start_element_handler, end_element_handler): Likewise. 2387 * x-java.c (extract_parenthesized): Likewise. 2388 * x-librep.c (read_object): Likewise. 2389 * x-lisp.c (read_object): Likewise. 2390 * x-perl.c (extract_variable, interpolate_keywords, extract_balanced): 2391 Likewise. 2392 * x-php.c (extract_parenthesized): Likewise. 2393 * x-python.c (extract_parenthesized): Likewise. 2394 * x-scheme.c (read_object): Likewise. 2395 * x-sh.c (read_word, read_command): Likewise. 2396 * x-smalltalk.c (extract_smalltalk): Likewise. 2397 * x-tcl.c (read_command): Likewise. 2398 * x-ycp.c (extract_parenthesized): Likewise. 2399 * x-rst.c (extract_rst): Update. 2400 24012005-10-03 Bruno Haible <bruno@clisp.org> 2402 2403 * xgettext.h (xgettext_comment_add, xgettext_comment, 2404 xgettext_comment_reset): Remove declarations. 2405 * xgettext.c (xgettext_comment_add, xgettext_comment, 2406 xgettext_comment_reset): Make static. 2407 24082005-10-03 Bruno Haible <bruno@clisp.org> 2409 2410 Use savable_comment_* API instead of xgettext_comment_* API. 2411 * x-awk.c (phase2_getc): Call savable_comment_add instead of 2412 xgettext_comment_add. 2413 (x_awk_lex): Call savable_comment_reset instead of 2414 xgettext_comment_reset. 2415 (extract_parenthesized): Call savable_comment_to_xgettext_comment and 2416 savable_comment_reset around remember_a_message. 2417 * x-elisp.c (comment_line_end): Call savable_comment_add instead of 2418 xgettext_comment_add. 2419 (read_object): Call savable_comment_reset instead of 2420 xgettext_comment_reset. Call savable_comment_to_xgettext_comment and 2421 savable_comment_reset around remember_a_message. 2422 * x-glade.c (start_element_handler, end_element_handler): Call 2423 savable_comment_to_xgettext_comment and savable_comment_reset around 2424 remember_a_message. Call savable_comment_reset instead of 2425 xgettext_comment_reset. 2426 (comment_handler): Call savable_comment_add instead of 2427 xgettext_comment_add. 2428 * x-librep.c (comment_line_end): Call savable_comment_add instead of 2429 xgettext_comment_add. 2430 (read_object): Call savable_comment_reset instead of 2431 xgettext_comment_reset. Call savable_comment_to_xgettext_comment and 2432 savable_comment_reset around remember_a_message. 2433 * x-lisp.c (comment_line_end): Call savable_comment_add instead of 2434 xgettext_comment_add. 2435 (read_object): Call savable_comment_reset instead of 2436 xgettext_comment_reset. Call savable_comment_to_xgettext_comment and 2437 savable_comment_reset around remember_a_message. 2438 * x-perl.c (phase2_getc): Call savable_comment_add instead of 2439 xgettext_comment_add. 2440 (extract_variable, interpolate_keywords): Call 2441 savable_comment_to_xgettext_comment and savable_comment_reset around 2442 remember_a_message. 2443 (x_perl_prelex): Call savable_comment_reset instead of 2444 xgettext_comment_reset. 2445 (extract_balanced): Call savable_comment_to_xgettext_comment and 2446 savable_comment_reset around remember_a_message. 2447 * x-php.c (comment_line_end): Call savable_comment_add instead of 2448 xgettext_comment_add. 2449 (x_php_lex): Call savable_comment_reset instead of 2450 xgettext_comment_reset. 2451 (extract_parenthesized): Call savable_comment_to_xgettext_comment and 2452 savable_comment_reset around remember_a_message. 2453 * x-scheme.c (comment_line_end): Call savable_comment_add instead of 2454 xgettext_comment_add. 2455 (read_object): Call savable_comment_reset instead of 2456 xgettext_comment_reset. Call savable_comment_to_xgettext_comment and 2457 savable_comment_reset around remember_a_message. 2458 * x-sh.c (comment_line_end): Call savable_comment_add instead of 2459 xgettext_comment_add. 2460 (read_word): Call savable_comment_reset instead of 2461 xgettext_comment_reset. Call savable_comment_to_xgettext_comment and 2462 savable_comment_reset around remember_a_message. 2463 (read_command): Call savable_comment_to_xgettext_comment and 2464 savable_comment_reset around remember_a_message. 2465 * x-smalltalk.c (comment_line_end): Call savable_comment_add instead of 2466 xgettext_comment_add. 2467 (phase2_get): Call savable_comment_reset instead of 2468 xgettext_comment_reset. 2469 (extract_smalltalk): Call savable_comment_to_xgettext_comment and 2470 savable_comment_reset around remember_a_message. 2471 * x-tcl.c (comment_line_end): Call savable_comment_add instead of 2472 xgettext_comment_add. 2473 (read_word): Call savable_comment_reset instead of 2474 xgettext_comment_reset. 2475 (read_command): Call savable_comment_to_xgettext_comment and 2476 savable_comment_reset around remember_a_message. 2477 * x-ycp.c (phase2_getc): Call savable_comment_add instead of 2478 xgettext_comment_add. 2479 (x_ycp_lex): Call savable_comment_reset instead of 2480 xgettext_comment_reset. 2481 (extract_parenthesized): Call savable_comment_to_xgettext_comment and 2482 savable_comment_reset around remember_a_message. 2483 24842005-10-03 Bruno Haible <bruno@clisp.org> 2485 2486 * message.c (message_list_hash_insert_entry): Update. 2487 24882005-10-03 Bruno Haible <bruno@clisp.org> 2489 2490 * message.c (message_list_alloc, message_list_free, 2491 message_list_hash_insert_entry, message_list_remove_if_not, 2492 message_list_msgids_changed, message_list_search): Update. 2493 * write-qt.c (write_qm): Update. 2494 * xgettext.c (flag_context_list_table_lookup, 2495 flag_context_list_table_insert): Update. 2496 * x-awk.c (x_awk_keyword, extract_parenthesized): Update. 2497 * x-c.c (add_keyword, x_c_lex): Update. 2498 * x-csharp.c (x_csharp_keyword, extract_parenthesized: Update. 2499 * x-elisp.c (x_elisp_keyword, read_object): Update. 2500 * x-glade.c (x_glade_keyword, start_element_handler): Update. 2501 * x-java.c (x_java_keyword, extract_parenthesized): Update. 2502 * x-librep.c (x_librep_keyword, read_object): Update. 2503 * x-lisp.c (x_lisp_keyword, read_object): Update. 2504 * x-perl.c (x_perl_keyword, extract_variable, interpolate_keywords, 2505 extract_balanced): Update. 2506 * x-php.c (x_php_keyword, extract_parenthesized): Update. 2507 * x-python.c (x_python_keyword, extract_parenthesized): Update. 2508 * x-scheme.c (x_scheme_keyword, read_object): Update. 2509 * x-sh.c (x_sh_keyword, read_command): Update. 2510 * x-tcl.c (x_tcl_keyword, read_command): Update. 2511 25122005-10-01 Bruno Haible <bruno@clisp.org> 2513 2514 Support for context dependent translations in PO files. 2515 * message.h (MSGCTXT_SEPARATOR): New macro. 2516 (struct message_ty): Add 'msgctxt' field. 2517 (message_alloc): Add msgctxt argument. 2518 (is_header): New macro. 2519 (message_list_search, message_list_search_fuzzy, 2520 message_list_list_search, message_list_list_search_fuzzy, 2521 msgdomain_list_search, msgdomain_list_search_fuzzy): Add msgctxt 2522 argument. 2523 * message.c: Include xallocsa.h. 2524 (message_alloc): Add msgctxt argument. 2525 (message_copy): Update. 2526 (message_list_hash_insert_entry): New function. 2527 (message_list_append, message_list_prepend, message_list_insert_at, 2528 message_list_msgids_changed): Use it. 2529 (message_list_search): Add msgctxt argument. 2530 (message_list_search_fuzzy_inner): Likewise. 2531 (message_list_search_fuzzy): Likewise. 2532 (message_list_list_search): Likewise. 2533 (message_list_list_search_fuzzy): Likewise. 2534 * msgl-ascii.c (is_ascii_message): Also test the msgctxt. 2535 * write-po.c (message_print): Warn if some msgctxt has non-ASCII 2536 characters. Write out the msgctxt. 2537 (message_print_obsolete): Likewise. 2538 (msgdomain_list_print_po): Use is_header macro. 2539 (msgdomain_list_print): Likewise. Bail out if contexts are present and 2540 cannot be stored in the given output format. 2541 * write-properties.c (write_message): Use is_header macro. 2542 * po-lex.c: Include message.h. 2543 (keyword_p): Also recognize 'msgctxt'. 2544 (po_gram_lex): Bail out if a string contains the EOT character. 2545 * read-po-abstract.h (struct abstract_po_reader_class_ty): Add msgctxt 2546 argument to directive_message function pointer. 2547 (po_callback_message): Add msgctxt argument. 2548 * read-po-abstract.c (call_directive_message, po_callback_message): Add 2549 msgctxt argument. 2550 * po-gram-gen.y (do_callback_message): Add msgctxt argument. Use 2551 is_header macro. 2552 (MSGCTXT): New token type. 2553 (message_intro, MSGCTXT): Declare return types. 2554 (message): Use message_intro instead of just MSGID. 2555 (message_intro): New nonterminal reduction rules. 2556 * read-properties.c (properties_parse): Update. 2557 * read-stringtable.c (stringtable_parse): Update. 2558 * read-po.h (struct default_po_reader_class_ty): Add msgctxt argument 2559 to add_message field. 2560 (default_directive_message, default_add_message): Likewise. 2561 * read-po.c (call_add_message, default_directive_message, 2562 default_add_message): Add msgctxt argument. 2563 * msgl-iconv.c (convert_msgid): Also convert the msgctxt. 2564 (iconv_message_list): Use is_header macro. Test also the msgctxt for 2565 non-ASCII-ness. 2566 * msgl-cat.c (is_message_selected, is_message_needed): Use is_header 2567 macro. 2568 (catenate_msgdomain_list): Likewise. Update. 2569 * msgl-equal.c (message_equal): Likewise. Also compare the msgctxt. 2570 * msgcmp.c (is_message_selected): Use is_header macro. 2571 (match_domain): Update. 2572 (compare): Use is_header macro. 2573 * msgmerge.c (message_merge, match_domain): Use is_header macro. 2574 Update. 2575 (merge): Update. 2576 * msgattrib.c (is_message_selected): Use is_header macro. 2577 (process_message_list): Likewise. Update. 2578 * msgl-charset.c (compare_po_locale_charsets): Use is_header macro. 2579 * msgexec.c (process_string): Also set or unset MSGEXEC_MSGCTXT 2580 variable. 2581 * msgfilter.c (process_message): Use is_header macro. 2582 * msggrep.c (grep_task): Increase size from 3 to 4. 2583 (long_options): Add --msgctxt option. 2584 (main): Accept -J/--msgctxt option. Update grep_pass numbers. 2585 (no_pass): Update. 2586 (usage): Mention -J option. 2587 (is_message_selected): Use is_header macro. Perform a new grep pass on 2588 the msgctxt. 2589 * msginit.c (fill_header): Use is_header macro. Update. 2590 (update_msgstr_plurals): Update. 2591 * read-mo.c (read_mo_file): Split msgid into msgctxt and msgid. Update. 2592 * read-tcl.c (msgdomain_read_tcl): Use is_header macro. 2593 * msgl-check.c (check_plural): Update. 2594 (check_message): Use is_header macro. 2595 * write-mo.c (write_table): Write msgid with msgctxt, instead of just 2596 the msgid. 2597 * write-java.c: Include xerror.h. 2598 (write_java_code): Update. 2599 (msgdomain_write_java): Give error if some entries have a context. 2600 * write-csharp.c: Include xerror.h. 2601 (write_csharp_code): Update. 2602 (msgdomain_write_csharp): Give error if some entries have a context. 2603 * write-resources.c (msgdomain_write_csharp_resources): Bail out if 2604 contexts are present and cannot be stored in the given output format. 2605 * write-tcl.c (write_msg): Use is_header macro. 2606 (msgdomain_write_tcl): Bail out if contexts are present and cannot be 2607 stored in the given output format. 2608 * write-qt.c: Include hash.h. 2609 (write_qm): Use is_header macro. Write out msgctxt if present. Write 2610 a contexts section if appropriate. 2611 * msgfmt.c (msgfmt_add_message): Add msgctxt argument. 2612 (msgfmt_frob_new_message): Use is_header macro. 2613 * xgettext.c (exclude_directive_message): Add msgctxt argument. 2614 (remember_a_message, construct_header, finalize_header): Update. 2615 * x-po.c (extract_add_message): Add msgctxt argument. Update. 2616 (extract): Update. 2617 * gettext-po.h (po_message_msgctxt, po_message_set_msgctxt): New 2618 declarations. 2619 * gettext-po.c (po_file_domain_header): Use is_header macro. 2620 (po_message_create): Update. 2621 (po_message_msgctxt, po_message_set_msgctxt): New functions. 2622 (po_message_check_all): Use is_header macro. 2623 26242005-10-01 Bruno Haible <bruno@clisp.org> 2625 2626 Avoid a crash when msgcat or msgconv is asked to convert a non-ASCII 2627 msgid. 2628 * msgl-iconv.h (iconv_message_list): Change return type to boolean. 2629 * msgl-iconv.c (iconv_message_list): Likewise. Return true if some 2630 msgids change. 2631 * msgl-cat.c (catenate_msgdomain_list): Exit with an error message if 2632 the msgids change through charset conversion. 2633 26342005-10-04 Bruno Haible <bruno@clisp.org> 2635 2636 * format.c: Include stdbool.h. 2637 (check_msgid_msgstr_format): Enable strict checking also when 2638 msgid_plural is present but nplurals = 1. 2639 Reported by Farzaneh Sarafraz <farzaneh@farsiweb.info>. 2640 26412005-10-01 Bruno Haible <bruno@clisp.org> 2642 2643 Change msgattrib to no longer remove extracted comments and file 2644 positions when marking messages obsolete. 2645 * msgmerge.c (merge): When marking a message obsolete, remove the 2646 extracted comments and file positions. 2647 * write-po.c (message_print_obsolete): Also print the extracted 2648 comments and file positions. 2649 26502005-09-25 Bruno Haible <bruno@clisp.org> 2651 2652 Support for Python source encodings (PEP 0263). 2653 * x-python.c: Include progname.h, basename.h, xerror.h, strstr.h, 2654 c-ctype.h, utf8-ucs4.h. 2655 (phase1_pushback): Reduce size. 2656 (UEOF): New macro. 2657 (phase2_pushback, phase2_pushback_length): New variables. 2658 (phase2_getc, phase2_ungetc): New functions. 2659 (struct unicode_string_buffer): New structure type. 2660 (init_unicode_string_buffer, unicode_string_buffer_append_unicode_grow, 2661 unicode_string_buffer_append_unicode, unicode_string_buffer_result, 2662 free_unicode_string_buffer): New functions. 2663 (comment_buffer): New variable. 2664 (buffer, bufmax, buflen): Remove variables. 2665 (comment_start, comment_add, comment_line_end): Rewritten. 2666 (comment_at_start): New function. 2667 (xgettext_current_file_source_encoding): New variable. 2668 (xgettext_current_file_source_iconv): New variable. 2669 (set_current_file_source_encoding, try_to_extract_coding): New 2670 functions. 2671 (continuation_or_nonblank_line): New variable. 2672 (phase3_getc): Renamed from phase2_getc. Use phase2_getc instead of 2673 phase1_getc. Return a Unicode character. Call try_to_extract_coding 2674 when seeing a comment among the first two lines. 2675 (phase3_ungetc): Renamed from phase2_ungetc. Use phase2_ungetc instead 2676 of phase1_ungetc. 2677 (UNICODE, IS_UNICODE, UNICODE_VALUE): New macros. 2678 (struct mixed_string_buffer): New structure type. 2679 (init_mixed_string_buffer, mixed_string_buffer_append_byte, 2680 mixed_string_buffer_append_unicode_grow, 2681 mixed_string_buffer_append_unicode, 2682 mixed_string_buffer_flush_utf16_surr, 2683 mixed_string_buffer_flush_curr_buffer, mixed_string_buffer_append, 2684 mixed_string_buffer_result, free_mixed_string_buffer): New functions. 2685 (phase7_getuc): Use phase2_getc instead of phase1_getc. Return a 2686 Unicode character except for \ooo and \xnn. 2687 (phase5_get): Operate on the level of Unicode characters instead of 2688 at the level of bytes. Use a mixed_string_buffer to accumulate a 2689 string literal. 2690 (extract_parenthesized): Set xgettext_current_source_encoding to UTF-8 2691 while passing UTF-8 strings to the xgettext main code. 2692 (extract_python): Initialize xgettext_current_file_source_encoding and 2693 xgettext_current_source_encoding. 2694 26952005-09-25 Bruno Haible <bruno@clisp.org> 2696 2697 * x-csharp.c (phase2_getc): Fix mis-use of iconv() when the source 2698 encoding is neither ASCII nor UTF-8. 2699 27002005-09-20 Bruno Haible <bruno@clisp.org> 2701 2702 * msgattrib.c (main): Invoke bindtextdomain for bison-runtime. 2703 * msgcat.c (main): Likewise. 2704 * msgcmp.c (main): Likewise. 2705 * msgcomm.c (main): Likewise. 2706 * msgconv.c (main): Likewise. 2707 * msgen.c (main): Likewise. 2708 * msgexec.c (main): Likewise. 2709 * msgfilter.c (main): Likewise. 2710 * msggrep.c (main): Likewise. 2711 * msginit.c (main): Likewise. 2712 * msgmerge.c (main): Likewise. 2713 * msgunfmt.c (main): Likewise. 2714 * msguniq.c (main): Likewise. 2715 * xgettext.c (main): Likewise. 2716 * Makefile.am (DEFS): Also define BISON_LOCALEDIR. 2717 27182005-09-17 Bruno Haible <bruno@clisp.org> 2719 2720 * msgl-check.h: New file. 2721 * msgl-check.c: New file, mostly extracted from msgfmt.c. 2722 * Makefile.am (noinst_HEADERS): Add msgl-check.h. 2723 (libgettextsrc_la_SOURCES): Add msgl-check.c, plural-eval.c. 2724 (msgfmt_SOURCES): Remove plural-eval.c. 2725 * format.c (check_msgid_msgstr_format): Add const to argument type. 2726 * format.h (check_msgid_msgstr_format): Add const to argument type. 2727 * gettext-po.c: Include msgl-check.h. 2728 (po_file_check_all, po_message_check_all): New functions. 2729 (po_xerror_logger): Remove function. 2730 (po_message_check_format): Use new check_message function. 2731 * gettext-po.h (po_file_check_all, po_message_check_all): New 2732 declarations. 2733 * msgfmt.c: Include msgl-check.h instead of setjmp.h, signal.h, 2734 stdarg.h, po-xerror.h, format.h, plural-exp.h, plural-table.h, 2735 strstr.h. 2736 (SIZEOF, sigjmp_buf, sigsetjmp, siglongjmp, USE_SIGINFO, 2737 sigfpe_exit, sigfpe_code, sigfpe_handler, install_sigfpe_handler, 2738 uninstall_sigfpe_handler, check_plural_eval, plural_help, check_plural, 2739 curr_mp, curr_msgid_pos, formatstring_error_logger, check_pair, 2740 check_header_entry): Move definitions to msgl-check.c. 2741 (main): Update. 2742 (msgfmt_frob_new_message): Call check_message instead of 2743 check_header_entry and check_pair. 2744 27452005-09-17 Bruno Haible <bruno@clisp.org> 2746 2747 Use new error handlers in libgettextpo. 2748 * gettext-po.h (PO_SEVERITY_WARNING, PO_SEVERITY_ERROR, 2749 PO_SEVERITY_FATAL_ERROR): New macros. 2750 (po_xerror_handler): New structure type. 2751 (po_xerror_handler_t): New type. 2752 (po_file_read): Change signature; version 3. 2753 (po_file_write): Change signature; version 2. 2754 (po_message_check_format): Change signature; version 2. 2755 * gettext-po.c: Include po-xerror.h. 2756 (po_file_read): New implementation. Renamed old implementation to 2757 po_file_read_v2. 2758 (po_file_write): New implementation. Keep old implementation. 2759 (po_xerror_logger): New function. 2760 (po_message_check_format): New implementation. Keep old implementation. 2761 27622005-09-17 Bruno Haible <bruno@clisp.org> 2763 2764 * msgfmt.c (check_plural): Fix broken determination of max_nplurals. 2765 27662005-09-17 Bruno Haible <bruno@clisp.org> 2767 2768 New, higher-level error message output primitives. 2769 * po-xerror.h: New file. 2770 * po-xerror.c: New file. 2771 * open-po.c: Include xerror.h, po-xerror.h, not error.h. 2772 (open_po_file): Use po_xerror instead of error. 2773 * po-charset.c: Include po-xerror.h, not po-error.h. 2774 (po_lex_charset_set): Use po_xerror instead of po_multiline_warning. 2775 * po-lex.c: Include xerror.h, po-error.h, po-xerror.h. 2776 (po_gram_error, po_gram_error_at_line): Use po_xerror instead of 2777 po_error or po_error_at_line. Don't decrement error_message_count; 2778 let the caller do this instead. 2779 (mbfile_getc, lex_getc): Use po_xerror instead of po_error. 2780 * po-lex.h: Don't include po-error.h. 2781 (po_gram_error, po_gram_error_at_line): Remove optimized macros. 2782 * read-po-abstract.c: Include xerror.h, po-xerror.h. 2783 (po_scan): Use po_xerror instead of po_error. 2784 * read-po.c: Include po-xerror.h. 2785 (default_add_message): Use po_xerror2 instead of po_gram_error_at_line 2786 pair. 2787 * read-properties.c: Include xerror.h, po-xerror.h, not exit.h. 2788 (phase1_getc, phase4_getuc): Use po_xerror instead of error. 2789 * read-stringtable.c: Include xerror.h, po-xerror.h, not exit.h. 2790 (phase1_getc, read_string, stringtable_parse): Use po_xerror instead of 2791 error. 2792 * write-po.c: Include po-xerror.h, not exit.h, po-error.h. 2793 (wrap): Pass the entire message as argument. Use po_xerror instead of 2794 po_error. 2795 (message_print, message_print_obsolete): Update. Use po_xerror instead 2796 of po_multiline_warning. 2797 (msgdomain_list_print): Use po_xerror instead of po_error or 2798 po_error_at_line. 2799 * msgl-iconv.h (struct conversion_context): Add 'message' field. 2800 * msgl-iconv.c: Include xerror.h, po-xerror.h, not error.h, exit.h. 2801 (conversion_error): Use po_xerror instead of error. 2802 (iconv_message_list): Likewise. Set the entire message in the 2803 conversion context before calling convert_*. 2804 (iconv_msgdomain_list): Use po_xerror instead of error. 2805 * xgettext.c (from_current_source_encoding): Set context.message. 2806 * msgfmt.c: Include po-xerror.h. 2807 (check_plural_eval): Pass the entire header as argument. Use po_xerror 2808 instead of error_at_line. 2809 (plural_help): New function, extracted from check_plural. 2810 (check_plural): Change type of local variables has_plural, min_pos, 2811 max_pos. Use po_xerror2 instead of error_at_line pairs. Use po_xerror 2812 instead of error_at_line. 2813 (curr_mp): New variable. 2814 (formatstring_error_logger): Use po_xerror instead of vfprintf. 2815 (check_pair): Take the entire message as argument. Use po_xerror 2816 instead of error_at_line. Set curr_mp before calling 2817 check_msgid_msgstr_format. 2818 (check_header_entry): Take the entire header message as argument. Use 2819 po_xerror instead of multiline_error. 2820 (msgfmt_frob_new_message): Update. 2821 * msgcmp.c (match_domain): Decrement error_message_count between two 2822 error messages that belong together. 2823 * msgmerge.c (match_domain): Decrement error_message_count between two 2824 error messages that belong together. 2825 * Makefile.am (noinst_HEADERS): Add po-xerror.h. 2826 (COMMON_SOURCE): Add po-xerror.c. 2827 28282005-09-16 Bruno Haible <bruno@clisp.org> 2829 2830 * gettext-po.c (po_file_read): Set gram_max_allowed_errors to a large 2831 integer, so that po_gram_error doesn't cause the program to exit(). 2832 28332005-09-14 Bruno Haible <bruno@clisp.org> 2834 2835 * x-csharp.c: Include xerror.h. 2836 28372005-09-11 Bruno Haible <bruno@clisp.org> 2838 2839 * user-email.sh.in: Add support for Mozilla Thunderbird and GNOME 2840 Evolution 2. Improve mutt support. 2841 28422005-08-26 Bruno Haible <bruno@clisp.org> 2843 2844 * plural-table.c (plural_table): Add an entry about Romanian. 2845 Explanations by Eddy Petri��or <eddy.petrisor@gmail.com>. 2846 28472005-08-23 Bruno Haible <bruno@clisp.org> 2848 2849 * write-mo.h (byteswap): New variable. 2850 * write-mo.c: Include byteswap.h. 2851 (byteswap): New variable. 2852 (BSWAP32): New macro. 2853 (write_table): If requested, byteswap all 32-bit values before writing 2854 them out. 2855 * msgfmt.c (long_options): Add --endianness. 2856 (main): Accept --endianness argument and set byteswap. 2857 28582005-08-08 Bruno Haible <bruno@clisp.org> 2859 2860 * msginit.c (catalogname_for_locale): Add support for Old English, 2861 Hyam, Jju, Tyap, Maithili, Nahuatl, Low Saxon, Northern Sotho, P��ez, 2862 Tetum, Zapotec. 2863 (englishname_of_language): Add support for Old English, Hyam, Jju, 2864 Tyap, Kagoma, Maithili, Mayan, Nahuatl, Low Saxon, Northern Sotho, 2865 P��ez, Tetum, Zapotec. 2866 28672005-05-21 Bruno Haible <bruno@clisp.org> 2868 2869 New undocumented option, used by glocale PO files. 2870 * msgfmt.c (include_fuzzies): Renamed from include_all. 2871 (include_untranslated): New variable. 2872 (long_options): Add --use-untranslated. 2873 (main): Handle --use-untranslated. 2874 (msgfmt_frob_new_message): Test include_untranslated. 2875 (msgfmt_comment_special): Update. 2876 28772005-07-26 Bruno Haible <bruno@clisp.org> 2878 2879 * user-email.sh.in (datarootdir): New variable. 2880 28812005-07-26 Bruno Haible <bruno@clisp.org> 2882 2883 Fix compilation error on systems without iconv(). 2884 * xgettext.c (convert_string): Remove fallback macro definition. 2885 (from_current_source_encoding) [!HAVE_ICONV]: Just abort here. 2886 28872005-07-17 Bruno Haible <bruno@clisp.org> 2888 2889 * po-lex.c (mb_width): Remove gcc warnings on platform with unsigned 2890 'char' type (e.g. Linux/PowerPC). 2891 Reported by Jeff Rizzo <riz@netbsd.org>. 2892 28932005-07-05 Bruno Haible <bruno@clisp.org> 2894 2895 * Makefile.am (msgmerge_SOURCES, xgettext_SOURCES, msgattrib_SOURCES, 2896 msgcat_SOURCES, msgcomm_SOURCES, msgconv_SOURCES, msgen_SOURCES, 2897 msgfilter_SOURCES, msggrep_SOURCES, msguniq_SOURCES): On mingw, use 2898 C++ source code. 2899 (libgettextsrc_la_LDFLAGS, libgettextpo_la_LDFLAGS): Use LTNOUNDEF. 2900 (format_CFLAGS): New variable. 2901 (format.lo): New rule. 2902 (msg*_CFLAGS, xgettext_CFLAGS): Remove variables. 2903 (msg*_CPPFLAGS, xgettext_CPPFLAGS): New variables. 2904 29052005-05-27 Bruno Haible <bruno@clisp.org> 2906 2907 * write-po.c (wrap): Output \a and \v as an escape sequence, like 2908 \b, \f, \r. 2909 Suggested by Asgeir Frimannsson <asgeirf@redhat.com>. 2910 29112005-05-05 Bruno Haible <bruno@clisp.org> 2912 2913 * Makefile.am (msgfmt_SOURCES): Add hash-string.c. 2914 * Makefile.msvc (msgfmt_OBJECTS): Add hash-string.obj. 2915 (hash-string.obj): New rule. 2916 * Makefile.vms (msgfmt_OBJECTS): Add hash-string.obj. 2917 (hash-string.obj): New rule. 2918 29192005-05-01 Bruno Haible <bruno@clisp.org> 2920 2921 * x-sh.c (open_singlequote_terminator): New variable. 2922 (saw_opening_singlequote): Set it. 2923 (phase2_getc): Handle the case of open_singlequote_terminator == '"'. 2924 (read_word): Likewise. Treat i18n quotes like single quotes with 2925 terminator '"'. 2926 Reported by Jakub Bogusz <qboosh@pld-linux.org>. 2927 29282005-05-01 Bruno Haible <bruno@clisp.org> 2929 2930 Improved error message. 2931 * msgl-iconv.h (struct conversion_context): New type. 2932 (convert_string): Add context argument. 2933 * msgl-iconv.c (conversion_error): New function. 2934 (convert_string, convert_string_list, convert_msgid, convert_msgstr): 2935 Add context argument. 2936 (iconv_message_list): Construct context for them. 2937 * xgettext.c (convert_string): Add context argument. 2938 (from_current_source_encoding): Construct context for convert_string. 2939 Reported by Hans Ulrich Niedermann <debian@n-dimensional.de>. 2940 29412005-04-18 Bruno Haible <bruno@clisp.org> 2942 2943 * po-lex.h (po_gram_error, po_gram_error_at_line): Test for 2944 __APPLE_CC__ > 1. Needed because gcc-4.0 defines __APPLE_CC__ and 2945 implements __VA_ARGS__ correctly. 2946 * po-lex.c (po_gram_error, po_gram_error_at_line): Likewise. 2947 * read-stringtable.c (phase2_getc): Optimize UTF-8 code. Avoids 2948 gcc-4.0 warnings. 2949 29502006-06-21 Bruno Haible <bruno@clisp.org> 2951 2952 * gettext-0.14.6 released. 2953 29542006-06-21 Bruno Haible <bruno@clisp.org> 2955 2956 * Makefile.am (CLEANFILES): Add msgfmt.net.exe.mdb, 2957 msgunfmt.net.exe.mdb. 2958 29592006-06-21 Bruno Haible <bruno@clisp.org> 2960 2961 * gettext-po.h (LIBGETTEXTPO_VERSION): Bump version number. 2962 29632006-06-20 Bruno Haible <bruno@clisp.org> 2964 2965 * format-gcc-internal.c (struct unnumbered_arg): Remove type. 2966 (struct numbered_arg): New type. 2967 (struct spec): Use it. 2968 (isdigit): New macro. 2969 (numbered_arg_compare): New function. 2970 (format_parse, format_free, format_check, format_print): Update to 2971 GCC 4.1 internal format strings. 2972 Reported by G��ran Uddeborg <goeran@uddeborg.se>. 2973 29742005-05-23 Bruno Haible <bruno@clisp.org> 2975 2976 * gettext-0.14.5 released. 2977 29782005-05-23 Bruno Haible <bruno@clisp.org> 2979 2980 * gettext-po.h (LIBGETTEXTPO_VERSION): Bump version number. 2981 29822005-05-21 Bruno Haible <bruno@clisp.org> 2983 2984 * format-gcc-internal.c: Update for GCC 4.0. 2985 (FAT_POINTER, FAT_SIZE_LONGLONG, FAT_SIZE_WIDE, FAT_SIZE_MASK): New 2986 enum items. 2987 (FAT_*): Update. 2988 (struct spec): Add uses_err_no field. 2989 (format_parse): Initialize uses_err_no field. Handle %q flag. Handle 2990 'll', 'w' size specifiers. Handle %<, %>, %', %m, %p, %J directives. 2991 (format_check): Also check that the use of err_no is the same. 2992 Based on a patch by Jakub Jelinek <jakub@redhat.com>. 2993 29942005-04-11 Bruno Haible <bruno@clisp.org> 2995 2996 * gettext-0.14.4 released. 2997 29982005-04-11 Bruno Haible <bruno@clisp.org> 2999 3000 * gettext-po.h (LIBGETTEXTPO_VERSION): Bump version number. 3001 30022005-03-14 Bruno Haible <bruno@clisp.org> 3003 3004 * gettext-0.14.3 released. 3005 30062005-03-08 Bruno Haible <bruno@clisp.org> 3007 3008 * gettext-po.h (LIBGETTEXTPO_VERSION): Bump version number. 3009 30102005-02-26 Bruno Haible <bruno@clisp.org> 3011 3012 * format-scheme.c (format_arg_type): Add FAT_COMPLEX. Remove 3013 FAT_FUNCTION. 3014 (make_intersected_element): Simplify also the intersection with 3015 FAT_COMPLEX. 3016 (make_union_element): Simplify also the union with FAT_COMPLEX. 3017 (IIC): New array. 3018 (nocheck_params): Remove function. 3019 (parse_upto): Remove handling of ~W, ~<, ~>. 3020 Implement non-CL handling of ~C, ~I, ~_, ~/, ~T. 3021 Implement handling of ~Y, ~!, ~Q, ~K. 3022 30232005-02-26 Bruno Haible <bruno@clisp.org> 3024 3025 * format-scheme.c (parse_upto): Remove support for ~!. 3026 Reported by Kevin Ryde <user42@zip.com.au>. 3027 30282005-02-24 Bruno Haible <bruno@clisp.org> 3029 3030 * gettext-0.14.2 released. 3031 30322005-02-12 Bruno Haible <bruno@clisp.org> 3033 3034 * Makefile.msvc (gettextpo.lib): Link with intl.lib as well. 3035 30362005-02-12 Bruno Haible <bruno@clisp.org> 3037 3038 * Makefile.msvc (msginit_OBJECTS): Add plural-count.obj. 3039 * Makefile.vms (msginit_OBJECTS): Add plural-count.obj. 3040 30412005-02-10 Bruno Haible <bruno@clisp.org> 3042 3043 * gettext-po.h (po_header_set_field): New declaration. 3044 * gettext-po.c (po_header_set_field): New function. 3045 Suggested by Ross Golder <ross@golder.org>. 3046 30472005-02-10 Bruno Haible <bruno@clisp.org> 3048 3049 * gettext-po.h (LIBGETTEXTPO_VERSION): New macro. 3050 (libgettextpo_version): New declaration. 3051 * gettext-po.c (libgettextpo_version): New variable. 3052 30532005-02-10 Bruno Haible <bruno@clisp.org> 3054 3055 * gettext-po.h (po_message_remove_filepos, po_message_add_filepos): New 3056 declarations. 3057 * gettext-po.c (po_message_remove_filepos, po_message_add_filepos): New 3058 functions. 3059 Suggested by Asgeir Frimannsson <asgeirf@redhat.com>. 3060 30612005-02-10 Bruno Haible <bruno@clisp.org> 3062 3063 * gettext-po.h (po_message_set_extracted_comments): New declaration. 3064 * gettext-po.c (po_message_set_extracted_comments): New function. 3065 Suggested by Asgeir Frimannsson <asgeirf@redhat.com>. 3066 30672005-02-08 Bruno Haible <bruno@clisp.org> 3068 3069 * msginit.c (get_user_email): Cast _() to 'char *', to avoid compiler 3070 warning. 3071 30722005-02-07 Bruno Haible <bruno@clisp.org> 3073 3074 Make the tools work in the tr_TR locale. 3075 * po-charset.c: Include c-strcase.h instead of strcase.h. 3076 (po_charset_canonicalize): Use c_strcasecmp. 3077 * msgcmp.c: Include c-strcase.h instead of strcase.h. 3078 (compare): Use c_strncasecmp. 3079 * msginit.c: Include c-strcase.h instead of strcase.h. 3080 (content_type): Use c_strcasecmp. 3081 * msgmerge.c: Include c-strcase.h instead of strcase.h. 3082 (message_merge, merge): Use c_strncasecmp. 3083 * xgettext.c: Include c-strcase.h instead of strcase.h. 3084 (language_to_extractor): Use c_strcasecmp. 3085 Reported by Recai Okta�� <roktas@omu.edu.tr>. 3086 30872005-02-07 Bruno Haible <bruno@clisp.org> 3088 3089 * project-id: Use LC_ALL=C to protect range expression against 3090 Estonian locale. 3091 30922005-02-06 Bruno Haible <bruno@clisp.org> 3093 3094 Leave #: lines with unknown syntax alone instead of turning them into 3095 plain comments. 3096 * po-hash.h: Remove file. 3097 * po-hash-gen.y: Remove file. 3098 * read-po-abstract.c: Don't include po-hash.h. 3099 (po_parse_comment_filepos, po_parse_comment_solaris_filepos): New 3100 functions. 3101 (po_callback_comment_dispatcher): Call them instead of the old 3102 po_parse_comment_filepos. 3103 * read-stringtable.c: Don't include po-hash.h. 3104 * Makefile.am (noinst_HEADERS): Remove po-hash.h, po-hash-gen.h. 3105 (COMMON_SOURCE): Remove po-hash-gen.y. 3106 (BUILT_SOURCES): Remove po-hash-gen.c, po-hash-gen.h. 3107 * Makefile.msvc (OBJECTS): Remove po-hash-gen.obj. 3108 (po-hash-gen.obj): Remove rule. 3109 * Makefile.vms (OBJECTS): Remove po-hash-gen.obj. 3110 (po-hash-gen.obj): Remove rule. 3111 * FILES: Update. 3112 Reported by David Fraser <davidf@sjsoft.com>. 3113 31142005-02-04 Bruno Haible <bruno@clisp.org> 3115 3116 * plural-table.c (plural_table): Add an entry about Vietnamese. 3117 Explanations by Clytie Siddall <clytie@riverland.net.au>. 3118 31192005-01-29 Bruno Haible <bruno@clisp.org> 3120 3121 * Makefile.am (msgcmp_LDADD, msgfmt_LDADD, msgmerge_LDADD, 3122 msgunfmt_LDADD, xgettext_LDADD, msgattrib_LDADD, msgcat_LDADD, 3123 msgcomm_LDADD, msgconv_LDADD, msgen_LDADD, msgexec_LDADD, 3124 msgfilter_LDADD, msggrep_LDADD, msguniq_LDADD): Add INTL_MACOSX_LIBS. 3125 31262005-01-27 Bruno Haible <bruno@clisp.org> 3127 3128 * msgfmt.c (formatstring_error_logger): Cast the fprrintf argument, 3129 to make it work on big-endian 64-bit machines. 3130 31312005-01-16 Bruno Haible <bruno@clisp.org> 3132 3133 Support for Scheme. 3134 * message.h (format_type): New enum value 'format_scheme'. 3135 (NFORMATS): Increment. 3136 * message.c (format_language): Add format_scheme entry. 3137 (format_language_pretty): Likewise. 3138 * format.h (formatstring_scheme): New declaration. 3139 * format-scheme.c: New file, based on format-lisp.c. 3140 * format.c (formatstring_parsers): Add formatstring_scheme. 3141 * x-scheme.h: New file. 3142 * x-scheme.c: New file. 3143 * xgettext.c: Include x-scheme.h. 3144 (flag_table_scheme): New variable. 3145 (main): Invoke init_flag_table_scheme, x_scheme_extract_all, 3146 x_scheme_keyword. 3147 (usage): Mention Scheme source language. 3148 (xgettext_record_flag): Handle format_scheme. 3149 (language_to_extractor): Add Scheme rule. 3150 (extension_to_language): Add Scheme rule. 3151 * Makefile.am (noinst_HEADERS): Add x-scheme.h. 3152 (FORMAT_SOURCE): Add format-scheme.c. 3153 (xgettext_SOURCES): Add x-scheme.c. 3154 * Makefile.msvc (OBJECTS): Add format-scheme.obj. 3155 (xgettext_OBJECTS): Add x-scheme.obj. 3156 (format-scheme.obj, x-scheme.obj): New rules. 3157 * Makefile.vms (OBJECTS): Add format-scheme.obj. 3158 (xgettext_OBJECTS): Add x-scheme.obj. 3159 (format-scheme.obj, x-scheme.obj): New rules. 3160 * FILES: Update. 3161 31622005-01-08 Bruno Haible <bruno@clisp.org> 3163 3164 * msggrep.c (grep_args, grep_path, grep_argv): Remove variables. 3165 (struct grep_task): New type. 3166 (grep_task): New variable. 3167 (main): Initialize grep_task instead of grep_args. Change processing 3168 of options 'E', 'F' to set a matcher, of 'e', 'f' to append to the 3169 pattern string, and of 'i' to set a boolean. Compile the patterns. 3170 (is_string_selected): Execute a compiled pattern instead of calling 3171 the grep program. 3172 (is_message_selected): Update. 3173 * Makefile.am (AM_CPPFLAGS): Add -I option for libgrep. 3174 (LIBGREP): New variable. 3175 (msggrep_LDADD): Add $(LIBGREP). 3176 * Makefile.msvc (INCLUDES): Add libgrep directory. 3177 (msggrep.exe): Link with libgrep. 3178 * Makefile.vms (INCLUDES): Add libgrep directory. 3179 (msggrep.exe): Link with libgrep. 3180 31812005-01-09 Bruno Haible <bruno@clisp.org> 3182 3183 * msgl-ascii.h (is_ascii_msgdomain_list): New declaration. 3184 * msgl-ascii.c (is_ascii_msgdomain_list): New function. 3185 * x-po.c (header_charset): New variable. 3186 (extract_add_message): When seeing the header entry, store the charset 3187 in header_charset. 3188 (extract): Store the value of header_charset in the new constructed 3189 header entry. 3190 * xgettext.c (main): Convert the existing PO file to UTF-8 if it was 3191 not entirely ASCII. 3192 Reported by J��rg Schilling <schilling@fokus.fraunhofer.de>. 3193 31942005-01-08 Bruno Haible <bruno@clisp.org> 3195 3196 * msggrep.c (usage): Explain COMMENT-PATTERN syntax as well. 3197 31982005-01-06 Bruno Haible <bruno@clisp.org> 3199 3200 * x-tcl.c (read_word): Ignore non-space whitespace at the beginning. 3201 Reported by William J Poser <wjposer@ldc.upenn.edu>. 3202 32032005-01-06 Bruno Haible <bruno@clisp.org> 3204 3205 * write-csharp.c (msgdomain_write_csharp): Don't call fclose after 3206 fwriteerror. 3207 * write-java.c (msgdomain_write_java): Likewise. 3208 * write-mo.c (msgdomain_write_mo): Likewise. 3209 * write-po.c (msgdomain_list_print): Likewise. 3210 * write-qt.c (msgdomain_write_qt): Likewise. 3211 * write-resources.c (execute_writing_input): Likewise. 3212 * write-tcl.c (msgdomain_write_tcl): Likewise. 3213 32142005-01-05 Bruno Haible <bruno@clisp.org> 3215 3216 * msgattrib.c (main): Update year in --version output. 3217 * msgcat.c (main): Likewise. 3218 * msgcmp.c (main): Likewise. 3219 * msgcomm.c (main): Likewise. 3220 * msgconv.c (main): Likewise. 3221 * msgen.c (main): Likewise. 3222 * msgexec.c (main): Likewise. 3223 * msgfilter.c (main): Likewise. 3224 * msgfmt.c (main): Likewise. 3225 * msggrep.c (main): Likewise. 3226 * msginit.c (main): Likewise. 3227 * msgmerge.c (main): Likewise. 3228 * msgunfmt.c (main): Likewise. 3229 * msguniq.c (main): Likewise. 3230 * xgettext.c (main): Likewise. 3231 32322005-01-07 Bruno Haible <bruno@clisp.org> 3233 3234 * gettext-po.c (po_file_read): Interpret "-" and "/dev/stdin" as 3235 denoting stdin. 3236 Suggested by Asgeir Frimannsson <asgeirf@redhat.com>. 3237 32382004-11-29 Bruno Haible <bruno@clisp.org> 3239 3240 * Makefile.am (libgettextpo_la_LDFLAGS): Add @LTLIBINTL@ @LTLIBICONV@. 3241 Reported by Sam Steingold <sds@gnu.org>. 3242 32432004-10-01 Guido Flohr <guido@imperia.net> 3244 3245 * x-perl.c (x_perl_prelex): Recognize function names starting with '-'. 3246 Reported by Ryan Anderson <ryan@autoweb.net>. 3247 32482004-09-16 Bruno Haible <bruno@clisp.org> 3249 3250 * format.h (formatstring_error_logger_t): Modify decl for GCC <= 3.0. 3251 Reported by Jens A. Tkotz <jens@peino.de>. 3252 32532004-09-11 Bruno Haible <bruno@clisp.org> 3254 3255 * Makefile.am (msginit_SOURCES): Add plural-count.c. 3256 * msginit.c (update_msgstr_plurals): New function. 3257 (main): Call it. 3258 * msgmerge.c (match_domain): Provide the appropriate number of plural 3259 forms for messages that don't occur in the Def.po file. 3260 Reported by Jens A. Tkotz <jens@peino.de>. 3261 32622004-09-06 Bruno Haible <bruno@clisp.org> 3263 3264 * format.h (formatstring_error_logger_t): New type. 3265 (struct formatstring_parser): Change calling convention of 'check' 3266 method. 3267 (check_msgid_msgstr_format): New declaration. 3268 * format-awk.c (format_check): Use error_logger argument instead of 3269 noisy and error_at_line. 3270 * format-c.c (format_check): Likewise. 3271 * format-csharp.c (format_check): Likewise. 3272 * format-elisp.c (format_check): Likewise. 3273 * format-gcc-internal.c (format_check): Likewise. 3274 * format-java.c (format_check): Likewise. 3275 * format-librep.c (format_check): Likewise. 3276 * format-lisp.c (format_check): Likewise. 3277 * format-pascal.c (format_check): Likewise. 3278 * format-perl.c (format_check): Likewise. 3279 * format-perl-brace.c (format_check): Likewise. 3280 * format-php.c (format_check): Likewise. 3281 * format-python.c (format_check): Likewise. 3282 * format-qt.c (format_check): Likewise. 3283 * format-sh.c (format_check): Likewise. 3284 * format-tcl.c (format_check): Likewise. 3285 * format-ycp.c (format_check): Likewise. 3286 * format.c (check_msgid_msgstr_format): New function, extracted from 3287 msgfmt.c. 3288 * msgfmt.c (curr_msgid_pos): New variable. 3289 (formatstring_error_logger): New function. 3290 (check_pair): Use check_msgid_msgstr_format, formatstring_error_logger. 3291 * msgmerge.c (msgfmt_check_pair_fails): Update. 3292 * gettext-po.h (po_message_check_format): New declaration. 3293 * gettext-po.c (po_error_logger, po_message_check_format): New 3294 functions. 3295 32962004-09-05 Bruno Haible <bruno@clisp.org> 3297 3298 * po-error.h: New file. 3299 * po-error.c: New file. 3300 * po-charset.c: Include po-error.h. 3301 (po_lex_charset_set): Use po_multiline_warning instead of 3302 multiline_warning. 3303 * po-lex.h: Include po-error.h. 3304 (po_gram_error): Use po_error instead of error. 3305 (po_gram_error_at_line): Use po_error_at_line instead of error_at_line. 3306 * po-lex.c (po_gram_error): Use po_error instead of error. 3307 (po_gram_error_at_line): Use po_error_at_line instead of error_at_line. 3308 (mbfile_getc, lex_getc): Use po_error instead of error. 3309 * read-po-abstract.c (po_scan): Likewise. 3310 * write-po.c: Include po-error.h instead of error.h. 3311 (wrap): Use po_error instead of error. 3312 (message_print, message_print_obsolete): Use po_multiline_warning 3313 instead of multiline_warning. 3314 (msgdomain_list_print): Use po_error instead of error, po_error_at_line 3315 instead of error_at_line. 3316 * str-list.h (string_list_join): New declaration. 3317 * str-list.c (string_list_join): New function. 3318 * message.h (message_list_insert_at): New declaration. 3319 * message.c (message_list_insert_at): New function. 3320 * gettext-po.h (po_filepos_t): New type. 3321 (struct po_error_handler, po_error_handler_t): New types. 3322 (po_file_create): New declaration. 3323 (po_file_read): Add handler argument. 3324 (po_file_write, po_message_insert, po_message_create, 3325 po_message_set_msgid, po_message_set_msgid_plural, 3326 po_message_set_msgstr, po_message_set_msgstr_plural, 3327 po_message_comments, po_message_set_comments, 3328 po_message_extracted_comments, po_message_filepos, 3329 po_message_set_obsolete, po_message_set_fuzzy, po_message_set_format, 3330 po_filepos_file, po_filepos_start_line): New declarations. 3331 * gettext-po.c (po_file_create): New function. 3332 (po_file_read): Add handler argument. Keep an old version for backward 3333 compatibility. 3334 (po_file_write): New function. 3335 (po_message_iterator): Store more information, to make 3336 po_message_insert possible. 3337 (po_message_iterator_free): Update. 3338 (po_next_message): Don't crash if iterator->mlp is NULL. 3339 (po_message_insert): New function. 3340 (po_message_create): New function. 3341 (po_message_set_msgid, po_message_set_msgid_plural, 3342 po_message_set_msgstr, po_message_set_msgstr_plural, 3343 po_message_comments, po_message_set_comments, 3344 po_message_extracted_comments, po_message_filepos, 3345 po_message_set_obsolete, po_message_set_fuzzy, po_message_set_format, 3346 po_filepos_file, po_filepos_start_line): New functions. 3347 * Makefile.am (noinst_HEADERS): Add po-error.h. 3348 (COMMON_SOURCE): Add po-error.c. 3349 * Makefile.msvc (OBJECTS): Add po-error.obj. 3350 (po-error.obj): New rule. 3351 * Makefile.vms (OBJECTS): Add po-error.obj. 3352 (po-error.obj): New rule. 3353 * FILES: Update. 3354 33552004-09-03 Bruno Haible <bruno@clisp.org> 3356 3357 * Makefile.am (msginit_LDADD): Use the INTL_MACOSX_LDFLAGS. 3358 33592004-08-30 Bruno Haible <bruno@clisp.org> 3360 3361 * plural-table.c (plural_table): Czech is now like Slovak. 3362 Reported by Stepan Kasal <kasal@ucw.cz>. 3363 33642004-06-23 Bruno Haible <bruno@clisp.org> 3365 3366 * x-c.c (phase1_getc): Fix phase0_getc invocation. 3367 Reported by Matt Dreezer <matthew.dreezer@edl.uk.eds.com>. 3368 33692004-05-14 Bruno Haible <bruno@clisp.org> 3370 3371 * format-java.c (message_format_parse): Fix argument of freesa() calls. 3372 33732004-03-19 Bruno Haible <bruno@clisp.org> 3374 3375 * Makefile.am (install-exec-clean): Don't remove libgettextsrc.a on 3376 AIX. 3377 Reported by Kouichi Hashikawa <z01a7ksy@cs.ecip.tohoku.ac.jp>. 3378 33792004-03-14 Bruno Haible <bruno@clisp.org> 3380 3381 * format-lisp.c (parse_upto): Add integer restriction for the dispatch 3382 argument in ~[...~]. 3383 33842004-03-02 Bruno Haible <bruno@clisp.org> 3385 3386 * read-csharp.c (msgdomain_read_csharp): Extend the lang -> frobbedlang 3387 mapping so as to support Serbian and Uzbek locales. 3388 * write-csharp.c (msgdomain_write_csharp): Likewise. 3389 Reported by Jorn Baayen <jbaayen@dds.nl>. 3390 33912004-02-27 Bruno Haible <bruno@clisp.org> 3392 3393 * plural-table.c (plural_table): Add an entry about Serbian. 3394 Reported by Danilo Segan <danilo@gnome.org>. 3395 33962004-01-29 Bruno Haible <bruno@clisp.org> 3397 3398 * gettext-0.14.1 released. 3399 34002004-01-28 Bruno Haible <bruno@clisp.org> 3401 3402 * gettext-0.14 released. 3403 34042004-01-18 Bruno Haible <bruno@clisp.org> 3405 3406 * msginit.c (catalogname_for_locale): Add entries for Akan, Avaric, 3407 Bambara, Cree, Divehi (Maldivian), ��w��, Igbo, Kongo, Kanuri, Ganda, 3408 Luba-Katanga, Ojibwa, Venda. 3409 (englishname_of_language): Likewise, and also for Fulah (Fulfulde). 3410 34112004-01-09 Bruno Haible <bruno@clisp.org> 3412 3413 * format.h (struct formatstring_parser): Add 'translated' argument to 3414 parse function. 3415 (get_sysdep_c_format_directives): Renamed from 3416 get_c99_format_directives. Add 'translated' argument. Change meaning 3417 of endpos in returned array. 3418 * format-c.c (struct spec): Rename field c99_directives to 3419 sysdep_directives, and c99_directives_count to sysdep_directives_count. 3420 (format_parse): Add 'translated' argument. Handle 'I' flag. Store the 3421 pointer past the '>' character instead of the pointer to the '>'. 3422 (format_c_parse, format_objc_parse): Add 'translated' argument. 3423 (get_sysdep_c_format_directives): Renamed from 3424 get_c99_format_directives. Add 'translated' argument. 3425 * format-awk.c (format_parse): Add 'translated' argument. 3426 * format-csharp.c (format_parse): Likewise. 3427 * format-elisp.c (format_parse): Likewise. 3428 * format-gcc-internal.c (format_parse): Likewise. 3429 * format-java.c (format_parse): Likewise. 3430 * format-librep.c (format_parse): Likewise. 3431 * format-lisp.c (format_parse): Likewise. 3432 * format-pascal.c (format_parse): Likewise. 3433 * format-perl-brace.c (format_parse): Likewise. 3434 * format-perl.c (format_parse): Likewise. 3435 * format-php.c (format_parse): Likewise. 3436 * format-python.c (format_parse): Likewise. 3437 * format-qt.c (format_parse): Likewise. 3438 * format-sh.c (format_parse): Likewise. 3439 * format-tcl.c (format_parse): Likewise. 3440 * format-ycp.c (format_parse): Likewise. 3441 * msgfmt.c (check_pair): Update. 3442 * msgmerge.c (msgfmt_check_pair_fails): Likewise. 3443 * read-mo.c (get_sysdep_string): Don't add '<'...'>' around segments 3444 of length 1. 3445 (read_mo_file): Treat major revision 1 like major revision 0. 3446 * write-mo.c (write_table): Update. Use major revision 1 if "I" occurs 3447 among the sysdep segments. 3448 * xgettext.c (set_format_flags_from_context, remember_a_message, 3449 remember_a_message_plural): Update. 3450 34512004-01-14 Bruno Haible <bruno@clisp.org> 3452 3453 * msginit.c (fill_header): Avoid a NULL pointer access when the header 3454 has no comment attached to it. 3455 Reported by Josep Puigdemont <baldrick@terra.es>. 3456 34572004-01-09 Bruno Haible <bruno@clisp.org> 3458 3459 * msgattrib.c (main): Update year in --version output. 3460 * msgcat.c (main): Likewise. 3461 * msgcmp.c (main): Likewise. 3462 * msgcomm.c (main): Likewise. 3463 * msgconv.c (main): Likewise. 3464 * msgen.c (main): Likewise. 3465 * msgexec.c (main): Likewise. 3466 * msgfilter.c (main): Likewise. 3467 * msgfmt.c (main): Likewise. 3468 * msggrep.c (main): Likewise. 3469 * msginit.c (main): Likewise. 3470 * msgmerge.c (main): Likewise. 3471 * msgunfmt.c (main): Likewise. 3472 * msguniq.c (main): Likewise. 3473 * xgettext.c (main): Likewise. 3474 34752003-12-29 Bruno Haible <bruno@clisp.org> 3476 3477 * xgettext.h: Include stdlib.h, str-list.h. 3478 (struct refcounted_string_list_ty): New type. 3479 (add_reference, drop_reference): New functions. 3480 (savable_comment, savable_comment_add, savable_comment_reset, 3481 savable_comment_to_xgettext_comment): New declarations. 3482 * xgettext.c (savable_comment): New variable. 3483 (savable_comment_add, savable_comment_reset, 3484 savable_comment_to_xgettext_comment): New functions. 3485 * x-java.c (struct refcounted_string_list_ty, comment, add_reference, 3486 drop_reference, x_java_comment_add, x_java_comment_reset, 3487 x_java_comment_to_xgettext_comment): Remove. Use replacement from 3488 xgettext.{h,c} instead. 3489 * x-csharp.c (struct refcounted_string_list_ty, comment, add_reference, 3490 drop_reference, x_csharp_comment_add, x_csharp_comment_reset, 3491 x_csharp_comment_to_xgettext_comment): Remove. Use replacement from 3492 xgettext.{h,c} instead. 3493 * x-c.c (comment_line_end): Call savable_comment_add instead of 3494 xgettext_comment_add. 3495 (struct token_ty): Add 'comment' field. 3496 (free_token): Free it. 3497 (phase5_get): Initialize token's 'comment' field. 3498 (phase6_get): Call savable_comment_reset instead of 3499 xgettext_comment_reset. 3500 (phase8a_get): Initialize token's 'comment' field. 3501 (phase8b_get): Call savable_comment_reset instead of 3502 xgettext_comment_reset. 3503 (phase8c_get): In @"...", use the comment of the first token, not of 3504 the second. 3505 (struct xgettext_token_ty): Add 'comment' field. 3506 (x_c_lex): Deal with the token's comment. 3507 (extract_parenthesized): Call savable_comment_to_xgettext_comment and 3508 savable_comment_reset. Free the token's comment field. 3509 * x-python.c (comment_line_end): Call savable_comment_add instead of 3510 xgettext_comment_add. 3511 (struct token_ty): Add 'comment' field. 3512 (phase5_get): Call savable_comment_reset instead of 3513 xgettext_comment_reset. Initialize token's 'comment' field. 3514 (extract_parenthesized): Call savable_comment_to_xgettext_comment and 3515 savable_comment_reset. Free the token's comment field. 3516 35172003-12-28 Bruno Haible <bruno@clisp.org> 3518 3519 * read-mo.h (read_mo_file): Change 'fn' into 'filename'. 3520 * read-mo.c (read_mo_file): Likewise. 3521 35222003-12-28 Bruno Haible <bruno@clisp.org> 3523 3524 * write-resources.h: New file. 3525 * write-resources.c: New file. 3526 * msgfmt.cs: New file. 3527 * msgfmt.c: Include write-resources.h. 3528 (csharp_resources_mode): New variable. 3529 (long_options): Add --csharp-resources. 3530 (main): Handle --csharp-resources. More generic code for detection of 3531 contradicting modes. Invoke msgdomain_write_csharp_resources. 3532 (usage): Document --csharp-resources option. 3533 (msgfmt_set_domain): Update. 3534 * read-resources.h: New file. 3535 * read-resources.c: New file. 3536 * msgunfmt.cs (DumpResource): Add a constructor that dumps a .resources 3537 file. 3538 (Main): Invoke it when only one argument is given. 3539 * msgunfmt.c: Include read-resources.h. 3540 (csharp_resources_mode): New variable. 3541 (long_options): Add --csharp-resources. 3542 (main): Handle --csharp-resources. More generic code for detection of 3543 contradicting modes. Invoke read_one_file instead of read_mo_file. 3544 (usage): Document --csharp-resources option. 3545 (read_one_file): New function. 3546 * Makefile.am (noinst_HEADERS): Add read-resources.h and 3547 write-resources.h. 3548 (msgfmt_SOURCES): Add write-resources.c. 3549 (msgunfmt_SOURCES): Add read-resources.c. 3550 (EXTRA_DIST): Add msgfmt.cs. 3551 (CLEANFILES): Add msgfmt.net.exe. 3552 (msgfmt.net.exe): New rule. 3553 (all-csharp-yes): Depend on it. 3554 (install-exec-csharp-yes): Also install msgfmt.net.exe. 3555 (uninstall-csharp-yes): Also uninstall msgfmt.net.exe. 3556 * Makefile.msvc (msgfmt_OBJECTS): Add write-resources.obj. 3557 (msgunfmt_OBJECTS): Add read-resources.obj. 3558 (write-resources.obj, read-resources.obj): New rules. 3559 * Makefile.vms (msgfmt_OBJECTS): Add write-resources.obj. 3560 (msgunfmt_OBJECTS): Add read-resources.obj. 3561 (write-resources.obj, read-resources.obj): New rules. 3562 * FILES: Update. 3563 35642003-12-26 Bruno Haible <bruno@clisp.org> 3565 3566 Support for C#. 3567 * write-csharp.h: New file. 3568 * write-csharp.c: New file. 3569 * msgfmt.c: Include write-csharp.h. 3570 (csharp_mode, csharp_resource_name, csharp_locale_name, 3571 csharp_base_directory): New variables. 3572 (long_options): Add option --csharp. 3573 (main): Handle option --csharp. Initialize csharp_resource_name, 3574 csharp_locale_name, csharp_base_directory. Perform checks for C# mode. 3575 Invoke msgdomain_write_csharp. 3576 (usage): Document --csharp option and C# mode. 3577 (msgfmt_set_domain): Ignore in C# mode. 3578 * read-csharp.h: New file. 3579 * read-csharp.c: New file. 3580 * msgunfmt.cs: New file. 3581 * msgunfmt.c: Include read-csharp.h. 3582 (csharp_mode, csharp_resource_name, csharp_locale_name, 3583 csharp_base_directory): New variables. 3584 (long_options): Add option --csharp. 3585 (main): Handle option --csharp. Initialize csharp_resource_name, 3586 csharp_locale_name, csharp_base_directory. Perform checks for C# mode. 3587 Invoke msgdomain_read_csharp. 3588 (usage): Document --csharp option and C# mode. 3589 * Makefile.am (noinst_HEADERS): Add read-csharp.h, write-csharp.h. 3590 (CSHARPCOMP, CSHARPCOMPFLAGS): New variables. 3591 (msgfmt_SOURCES): Add write-csharp.c. 3592 (msgunfmt_SOURCES): Add read-csharp.c. 3593 (EXTRA_DIST): Add msgunfmt.cs. 3594 (CLEANFILES): Add msgunfmt.net.exe. 3595 (all-csharp-yes, all-csharp-no): New rules. 3596 (all-local): Depend on them. 3597 (msgunfmt.net.exe): New rule. 3598 (install-exec-csharp-yes, install-exec-csharp-no): New rules. 3599 (install-exec-local): Depend on them. 3600 (installdirs-csharp): New rule. 3601 (installdirs-local): Depend on it. 3602 (uninstall-csharp-yes, uninstall-csharp-no): New rules. 3603 (uninstall-local): Depend on it. 3604 * Makefile.msvc (msgfmt_OBJECTS): Add write-csharp.obj. 3605 (msgunfmt_OBJECTS): Add read-csharp.obj. 3606 (write-csharp.obj, read-csharp.obj): New rules. 3607 * Makefile.vms (msgfmt_OBJECTS): Add write-csharp.obj. 3608 (msgunfmt_OBJECTS): Add read-csharp.obj. 3609 (write-csharp.obj, read-csharp.obj): New rules. 3610 * FILES: Update. 3611 36122003-12-26 Bruno Haible <bruno@clisp.org> 3613 3614 * read-java.c (msgdomain_read_java): Relocate also the GETTEXTJAR 3615 value. 3616 * urlget.c (fetch): Likewise. 3617 36182003-12-26 Bruno Haible <bruno@clisp.org> 3619 3620 * write-java.c (write_java_code): Emit a static method 3621 'get_msgid_plural_table' instead of a static field 'plural'. 3622 * gnu/gettext/DumpResource.java (DumpResource.dump): Exploit a 3623 'get_msgid_plural_table' method if it exists. 3624 36252003-12-14 Bruno Haible <bruno@clisp.org> 3626 3627 * message.h (format_type): New enum value 'format_csharp'. 3628 (NFORMATS): Increment. 3629 * message.c (format_language): Add format_csharp entry. 3630 (format_language_pretty): Likewise. 3631 * format.h (formatstring_csharp): New declaration. 3632 * format-csharp.c: New file. 3633 * format.c (formatstring_parsers): Add formatstring_csharp. 3634 * x-csharp.h: New file. 3635 * x-csharp.c: New file. 3636 * xgettext.c: Include x-csharp.h. 3637 (flag_table_csharp): New variable. 3638 (main): Invoke init_flag_table_csharp, x_csharp_extract_all, 3639 x_csharp_keyword. 3640 (usage): Mention C# source language. 3641 (xgettext_record_flag): Handle format_csharp. 3642 (language_to_extractor): Add C# rule. 3643 (extension_to_language): Add C# rule. 3644 * Makefile.am (noinst_HEADERS): Add x-csharp.h. 3645 (FORMAT_SOURCE): Add format-csharp.c. 3646 (xgettext_SOURCES): Add x-csharp.c. 3647 * Makefile.msvc (OBJECTS): Add format-csharp.obj. 3648 (xgettext_OBJECTS): Add x-csharp.obj. 3649 (format-csharp.obj, x-csharp.obj): New rules. 3650 * Makefile.vms (OBJECTS): Add format-csharp.obj. 3651 (xgettext_OBJECTS): Add x-csharp.obj. 3652 (format-csharp.obj, x-csharp.obj): New rules. 3653 * FILES: Update. 3654 36552003-12-28 Bruno Haible <bruno@clisp.org> 3656 3657 * msgexec.c (process_string): Pass ignore_sigpipe = false. 3658 * msgfilter.c (process_string): Likewise. 3659 * msggrep.c (is_string_selected): Likewise. 3660 * msginit.c (project_id, project_id_version, get_user_email, 3661 language_team_address): Likewise. 3662 * read-java.c (execute_and_read_po_output): Likewise. 3663 * read-tcl.c (msgdomain_read_tcl): Likewise. 3664 * urlget.c (execute_it): Pass ignore_sigpipe = true. 3665 (fetch): Pass ignore_sigpipe = true when fetching the file, = false 3666 otherwise. 3667 36682003-12-14 Bruno Haible <bruno@clisp.org> 3669 3670 * x-c.c (SIZEOF): New macro. 3671 (phase1_ungetc): Verify that the pushback buffer's size is sufficient. 3672 (phase2_ungetc): Likewise. 3673 (phase3_ungetc): Likewise. 3674 (phase5_unget): Likewise. 3675 (phase6_unget): Likewise. 3676 * x-java.c (SIZEOF): New macro. 3677 (phase1_ungetc): Verify that the pushback buffer's size is sufficient. 3678 (phase2_ungetc): Likewise. 3679 (phase3_ungetc): Likewise. 3680 (phase5_unget): Likewise. 3681 (phase6_unget): Likewise. 3682 * x-php.c (SIZEOF): New macro. 3683 (phase1_ungetc): Verify that the pushback buffer's size is sufficient. 3684 (phase2_ungetc): Likewise. 3685 (phase3_ungetc): Likewise. 3686 * x-python.c (SIZEOF): New macro. 3687 (phase1_ungetc): Verify that the pushback buffer's size is sufficient. 3688 (phase5_unget): Likewise. 3689 * x-sh.c (SIZEOF): New macro. 3690 (phase1_ungetc): Verify that the pushback buffer's size is sufficient. 3691 (phase2_ungetc): Likewise. 3692 * x-smalltalk.c (SIZEOF): New macro. 3693 (phase2_unget): Verify that the pushback buffer's size is sufficient. 3694 * x-tcl.c (SIZEOF): New macro. 3695 (phase1_ungetc): Verify that the pushback buffer's size is sufficient. 3696 (phase2_ungetc): Likewise. 3697 * x-ycp.c (SIZEOF): New macro. 3698 (phase2_unget): Verify that the pushback buffer's size is sufficient. 3699 37002003-12-14 Bruno Haible <bruno@clisp.org> 3701 3702 * x-c.c (phase1_pushback): Reduce size to 2. 3703 (phase2_pushback): Reduce size to 1. 3704 (phase3_pushback): Reduce size to 2. 3705 (phase5_pushback): Reduce size to 1. 3706 (phase6_pushback): Reduce size to 2. 3707 * x-java.c (phase2_pushback): Reduce size to 1. 3708 (phase3_pushback): Reduce size to 2. 3709 (phase5_pushback): Reduce size to 3. 3710 (phase6_pushback): Reduce size to 2. 3711 * x-php.c (phase1_pushback): Reduce size to 2. 3712 * x-python.c (max): New macro. 3713 (phase1_pushback): Reduce size to UNINAME_MAX + 3. 3714 (phase5_pushback): Reduce size to 1. 3715 * x-sh.c (phase1_pushback): Reduce size to 1. 3716 (phase2_pushback): Reduce size to 2. 3717 * x-smalltalk.c (phase2_pushback): Reduce size to 1. 3718 * x-tcl.c (phase1_pushback): Reduce size to 1. 3719 (phase2_pushback): Reduce size to 2. 3720 37212003-12-12 Bruno Haible <bruno@clisp.org> 3722 3723 Assume automake-1.8. 3724 * Makefile.am (install-exec-local): Renamed from install-exec-am. 3725 37262003-11-30 Bruno Haible <bruno@clisp.org> 3727 3728 * format-java.c: Include xallocsa.h. 3729 (message_format_parse): Use xallocsa instead of alloca. 3730 (choice_format_parse): Likewise. 3731 * msgl-cat.c: Include xallocsa.h. 3732 (catenate_msgdomain_list): Use xallocsa instead of alloca. 3733 * msgl-charset.c: Include xallocsa.h. 3734 (compare_po_locale_charsets): Use xallocsa instead of alloca. 3735 * msgl-iconv.c: Include xallocsa.h. 3736 (iconv_message_list): Use xallocsa instead of alloca. 3737 * po-charset.c: Include xallocsa.h. 3738 (po_lex_charset_set): Use xallocsa instead of alloca. 3739 * read-tcl.c: Include xallocsa.h. 3740 (msgdomain_read_tcl): Use xallocsa instead of alloca. 3741 * write-java.c: Include xallocsa.h. 3742 (compute_hashsize, msgdomain_write_java): Use xallocsa instead of 3743 alloca. 3744 * write-mo.c: Include xallocsa.h. 3745 (write_table): Use xallocsa instead of alloca. 3746 * write-po.c: Include xallocsa.h. 3747 (msgdomain_list_print_po): Use xallocsa instead of alloca. 3748 * write-tcl.c: Include xallocsa.h. 3749 (msgdomain_write_tcl): Use xallocsa instead of alloca. 3750 * msggrep.c: Include xallocsa.h. 3751 (is_message_selected): Use xallocsa instead of alloca. 3752 * msginit.c: Include xallocsa.h. 3753 (subst_string): Use xallocsa instead of alloca. 3754 * msgmerge.c: Include obstack.h. 3755 (obstack_chunk_alloc, obstack_chunk_free): New macros. 3756 (message_merge): Use obstack_alloc instead of alloca. 3757 * xgettext.c: Include xallocsa.h. 3758 (flag_context_list_table_insert): Use xallocsa instead of alloca. 3759 37602003-12-17 Bruno Haible <bruno@clisp.org> 3761 3762 * gettext-0.13.1 released. 3763 37642003-12-14 Bruno Haible <bruno@clisp.org> 3765 3766 * x-sh.c (phase2_getc): Call phase1_ungetc instead of phase2_ungetc: 3767 The next phase2_getc invocation must return QUOTED('"'), not '"'. 3768 37692003-12-14 Bruno Haible <bruno@clisp.org> 3770 3771 * x-c.c (phase7_getc): Remove dead code. 3772 * x-java.c (accumulate_escaped): More precise error message. 3773 37742003-12-02 Bruno Haible <bruno@clisp.org> 3775 3776 * msginit.c (catalogname_for_locale): Treat sr_CS like sr_YU. 3777 37782003-11-30 Bruno Haible <bruno@clisp.org> 3779 3780 * gettext-0.13 released. 3781 37822003-11-28 Bruno Haible <bruno@clisp.org> 3783 3784 * xgettext.c (set_format_flags_from_context): Add casts, to make it 3785 compile in C++ mode. 3786 37872003-11-22 Bruno Haible <bruno@clisp.org> 3788 3789 * x-c.c (phase4_getc): Skip leading whitespace in C++ style comments 3790 as well. 3791 * x-sh.c (read_word): Skip leading whitespace in comments. 3792 * x-lisp.c (read_object): Skip leading whitespace in single-line 3793 comments as well. 3794 * x-elisp.c (read_object): Skip leading whitespace in comments. 3795 * x-librep.c (read_object): Skip leading whitespace in single-line 3796 comments as well. 3797 * x-java.c (phase4_getc): Skip leading whitespace in C++ style comments 3798 as well. 3799 * x-awk.c (phase2_getc): Skip leading whitespace in comments. 3800 * x-ycp.c (phase2_getc): Skip leading whitespace in single-line 3801 comments as well. 3802 * x-tcl.c (read_command): Skip leading whitespace in comments. 3803 38042003-11-24 Bruno Haible <bruno@clisp.org> 3805 3806 * format-lisp.c (check_params): Use ngettext for one of the messages. 3807 Reported by Rafa�� Maszkowski <rzm@icm.edu.pl>. 3808 38092003-11-15 Bruno Haible <bruno@clisp.org> 3810 3811 * Makefile.am (AM_CPPFLAGS): Renamed from INCLUDES. 3812 38132003-11-09 Bruno Haible <bruno@clisp.org> 3814 3815 * msginit.c (main): Drop the blank line in --no-translator mode. 3816 38172003-11-07 Bruno Haible <bruno@clisp.org> 3818 3819 * xgettext.c (remember_a_message): Omit the programmer comments of a 3820 duplicated msgid only if they are redundant. 3821 Reported by Christian Neumair <chris@gnome-de.org>. 3822 38232003-11-05 Bruno Haible <bruno@clisp.org> 3824 3825 * user-email.sh.in: Renamed from user-email.in. Internationalize, use 3826 localedir and gettext. 3827 * FILES: Update. 3828 38292003-10-23 Bruno Haible <bruno@clisp.org> 3830 3831 * read-stringtable.c (read_string, stringtable_parse): Cast 3832 gram_pos.line_number to 'unsigned long'. 3833 * x-sh.c (read_word): Case line_number to 'unsigned long'. 3834 38352003-10-21 Bruno Haible <bruno@clisp.org> 3836 3837 * message.h (message_list_msgids_changed): New declaration. 3838 * message.c (message_list_msgids_changed): New function. 3839 * msgl-iconv.c (iconv_message_list): Update the message list's hash 3840 table if it happens to contain non-ASCII msgids. 3841 38422003-10-19 Bruno Haible <bruno@clisp.org> 3843 3844 * message.h (format_type): New enum value 'format_qt'. 3845 (NFORMATS): Increment. 3846 * message.c (format_language): Add format_qt entry. 3847 (format_language_pretty): Likewise. 3848 * format.h (formatstring_qt): New declaration. 3849 * format-qt.c: New file. 3850 * format.c (formatstring_parsers): Add formatstring_qt. 3851 * xgettext.c (recognize_format_qt): New variable. 3852 (long_options): Add option "--qt". 3853 (main): Handle --qt option. Determine the extractor only after option 3854 processing is complete. 3855 (usage): Document --qt option. 3856 (xgettext_record_flag): Handle format_qt. 3857 (language_to_extractor): For C++, return a different extractor when 3858 --qt was specified. 3859 * write-qt.h: New file. 3860 * write-qt.c: New file. 3861 * msgfmt.c: Include write-qt.h. 3862 (qt_mode): New variable. 3863 (long_options): Add option "--qt". 3864 (main): Handle --qt option. More checks for contradicting options. 3865 Call msgdomain_write_qt. 3866 (usage): Mention Qt mode. 3867 (format_directive_domain): Ignore domain directive if in Qt mode. 3868 * Makefile.am (noinst_HEADERS): Add write-qt.h. 3869 (FORMAT_SOURCE): Add format-qt.c. 3870 (msgfmt_SOURCES): Add write-qt.c. 3871 * Makefile.msvc (OBJECTS): Add format-qt.obj. 3872 (msgfmt_OBJECTS): Add write-qt.obj. 3873 (format-qt.obj, write-qt.obj): New rules. 3874 * Makefile.vms (OBJECTS): Add format-qt.obj. 3875 (msgfmt_OBJECTS): Add write-qt.obj. 3876 (format-qt.obj, write-qt.obj): New rules. 3877 * FILES: Update. 3878 38792003-10-14 Bruno Haible <bruno@clisp.org> 3880 3881 Fix compilation errors in C++ mode. 3882 * msgfilter.c (process_string): Cast the xrealloc expression. 3883 * xgettext.c (language_to_extractor, extension_to_language): Move the 3884 typedef after the struct definition. 3885 38862003-10-13 Bruno Haible <bruno@clisp.org> 3887 3888 Support CR/LF line terminators in C sources even on Unix. 3889 * x-c.c (phase0_getc, phase0_ungetc): New functions. 3890 (phase1_getc): Use them instead of calling getc/ungetc directly. 3891 Reported by Christoph Thielecke <u15119@hs-harz.de>. 3892 38932003-10-13 Bruno Haible <bruno@clisp.org> 3894 3895 Support and recognize Objective C specific format strings. 3896 * message.h (enum format_type): New item format_objc. 3897 (NFORMATS): Increment. 3898 * message.c (format_language): Add an entry for format_objc. 3899 (format_language_pretty): Likewise. 3900 * format.h (formatstring_objc): New declaration. 3901 * format-c.c (enum format_arg_type): New item FAT_OBJC_OBJECT. 3902 (format_parse): Add objc_extensions argument. Handle %@ in ObjC mode. 3903 (format_c_parse, format_objc_parse): New functions. 3904 (formatstring_c): Use format_c_parse instead of format_parse. 3905 (formatstring_objc): New variable. 3906 (get_c99_format_directives): Update. 3907 * format.c (formatstring_parsers): Add an entry for format_objc. 3908 * write-mo.c (write_table): Look for system dependent strings also in 3909 ObjectiveC format strings. 3910 * x-c.h (SCANNERS_C): Use separate flag_table for ObjectiveC. 3911 (x_objc_keyword, init_flag_table_objc): New declarations. 3912 (x_c_any_keywords): Remove declaration. 3913 * x-c.c (c_keywords): Renamed from keywords. 3914 (objc_keywords): New variable. 3915 (add_keyword): Renamed from x_c_keyword. Add keywords table argument. 3916 (x_c_keyword, x_objc_keyword): New functions. 3917 (x_c_any_keywords): Remove function. 3918 (init_keywords): Also initialize ObjectiveC keyword table. 3919 (init_flag_table_objc): New function. 3920 (enum token_type_ty): New item token_type_colon. 3921 (phase5_get): Recognize colon. 3922 (enum xgettext_token_type_ty): New item xgettext_token_type_colon. 3923 (x_c_lex): Use keywords table depending on objc_extensions. Handle 3924 colon. 3925 (extract_parenthesized): Change the context_iter and inner_context 3926 after a keyword/symbol followed by a colon was seen. 3927 * xgettext.c (flag_table_objc): New variable. 3928 (main): Invoke init_flag_table_objc, x_objc_keyword. Watch out for 3929 keywords arguments, instead of calling x_c_any_keywords(). 3930 (flag_context_list_table_insert): New function, extracted from 3931 xgettext_record_flag. 3932 (xgettext_record_flag): Call it. For format_c, insert the flags also 3933 in the flag_table_objc. Handle format_objc. 3934 (remember_a_message): Don't add a heuristic c-format flag to an entry 3935 that already carries objc-format. 3936 (remember_a_message_plural): Likewise. 3937 39382003-10-18 Bruno Haible <bruno@clisp.org> 3939 3940 Support for GNUstep .strings format. 3941 * read-stringtable.h: New file. 3942 * read-stringtable.c: New file. 3943 * read-po-abstract.h (enum input_syntax_ty): New item 3944 syntax_stringtable. 3945 (po_callback_comment_dispatcher): Renamed from po_callback_comment. 3946 (po_callback_comment, po_callback_comment_special): New declarations. 3947 * read-po-abstract.c: Include read-stringtable.h. 3948 (po_scan): Add support for syntax_stringtable. 3949 (po_callback_comment_dispatcher): Renamed from po_callback_comment. 3950 (po_callback_comment, po_callback_comment_dot): New functions. 3951 (po_callback_comment_special): New function. 3952 * read-po.c (read_po): Set mdlp->encoding for syntax_stringtable too. 3953 * po-gram-gen.y: Update po_callback_comment_dispatcher call. 3954 * read-properties.c (properties_parse): Likewise. 3955 * write-stringtable.h: New file. 3956 * write-stringtable.c: New file. 3957 * write-po.h (make_format_description_string, significant_format_p): 3958 New declarations. 3959 (message_print_syntax_stringtable): New declaration. 3960 * write-po.c: Include write-stringtable.h. 3961 (make_format_description_string, significant_format_p): Make 3962 non-static. 3963 (use_syntax_stringtable): New variable. 3964 (message_print_syntax_stringtable): New function. 3965 (msgdomain_list_print): Add check for plural forms for 3966 syntax_stringtable too. Add support for writing the .strings format. 3967 * msgattrib.c (long_options): Add --stringtable-input/output. 3968 (main): Handle them. 3969 (usage): Document options --stringtable-input/output. 3970 * msgcat.c (long_options): Add --stringtable-input/output. 3971 (main): Handle them. If option --stringtable-output is used, convert to 3972 UTF-8 and ignore the to_code. 3973 (usage): Document options --stringtable-input/output. 3974 * msgcmp.c (long_options): Add --stringtable-input. 3975 (main): Handle it. 3976 (usage): Document option --stringtable-input. 3977 * msgcomm.c (long_options): Add --stringtable-input/output. 3978 (main): Handle them. 3979 (usage): Document options --stringtable-input/output. 3980 * msgconv.c (long_options): Add --stringtable-input/output. 3981 (main): Handle them. If option --stringtable-output is used, ignore the 3982 to_code. 3983 (usage): Document options --stringtable-input/output. 3984 * msgen.c (long_options): Add --stringtable-input/output. 3985 (main): Handle them. 3986 (usage): Document options --stringtable-input/output. 3987 * msgexec.c: Include limits.h. 3988 (long_options): Add --stringtable-input. 3989 (main): Handle it. 3990 (usage): Document option --stringtable-input. 3991 * msgfilter.c (long_options): Add --stringtable-input/output. 3992 (main): Handle them. 3993 (usage): Document options --stringtable-input/output. 3994 * msgfmt.c (long_options): Add --stringtable-input. 3995 (main): Handle it. 3996 (usage): Document option --stringtable-input. 3997 * msggrep.c (long_options): Add --stringtable-input/output. 3998 (main): Handle them. 3999 (usage): Document options --stringtable-input/output. 4000 * msginit.c (long_options): Add --stringtable-input/output. 4001 (main): Handle them. 4002 (usage): Document options --stringtable-input/output. 4003 * msgmerge.c (long_options): Add --stringtable-input/output. 4004 (main): Handle them. In update mode, --stringtable-input implies 4005 --stringtable-output. 4006 (usage): Document options --stringtable-input/output. 4007 * msgunfmt.c (long_options): Add --stringtable-output. 4008 (main): Handle it. 4009 (usage): Document option --stringtable-output. 4010 * msguniq.c (long_options): Add --stringtable-input/output. 4011 (main): Handle them. 4012 (usage): Document options --stringtable-input/output. 4013 * x-stringtable.h: New file. 4014 * x-po.c: Include x-stringtable.h. 4015 (extract_stringtable): New function. 4016 * xgettext.c: Include x-stringtable.h. 4017 (long_options): Add --stringtable-output. 4018 (main): Handle it. 4019 (usage): Document options -L NXStringTable and --stringtable-output. 4020 (finalize_header): If --stringtable-output was given, set the charset. 4021 (language_to_extractor): Add support for .strings format. 4022 (extension_to_language): Likewise. 4023 * Makefile.am (noinst_HEADERS): Add read-stringtable.h, 4024 write-stringtable.h, x-stringtable.h. 4025 (COMMON_SOURCE): Add read-stringtable.c. 4026 (libgettextsrc_la_SOURCES): Add write-stringtable.c. 4027 * Makefile.msvc (OBJECTS): Add read-stringtable.obj, 4028 write-stringtable.obj. 4029 (read-stringtable.obj, write-stringtable.obj): New rules. 4030 * Makefile.vms (OBJECTS): Add read-stringtable.obj, 4031 write-stringtable.obj. 4032 (read-stringtable.obj, write-stringtable.obj): New rules. 4033 * FILES: Update. 4034 40352003-10-21 Bruno Haible <bruno@clisp.org> 4036 4037 * hostname.c (xgethostname): Add support for native Woe32 API. 4038 40392003-10-21 Bruno Haible <bruno@clisp.org> 4040 4041 * message.c (message_list_search): Avoid casting a pointer to a local 4042 variable; it violated strict aliasing. 4043 40442003-10-21 Bruno Haible <bruno@clisp.org> 4045 4046 * write-java.c (mkdir): Redefine on mingw. 4047 40482003-10-12 Bruno Haible <bruno@clisp.org> 4049 4050 Improved ObjectiveC support. 4051 * x-c.h (extract_objc): New declaration. 4052 (SCANNERS_C): For ObjectiveC, use extract_objc. 4053 * x-c.c (objc_extensions): New variable. 4054 (enum token_type_ty): New item token_type_objc_special. 4055 (phase5_get): Recognize '@' for ObjectiveC. 4056 (phase8b_get, phase8b_unget): New functions. Handle 4057 token_type_white_space and token_type_eoln here instead of in x_c_lex. 4058 (phase8c_get, phase8c_unget): New functions. 4059 (phase8_get): Rely on phase8c, not phase8a. No more need to care about 4060 token_type_white_space and token_type_eoln. 4061 (x_c_lex): Drop handling of token_type_white_space and token_type_eoln. 4062 (extract_whole_file): Renamed from extract_c. 4063 (extract_c, extract_objc): New functions. 4064 40652003-10-20 Bruno Haible <bruno@clisp.org> 4066 4067 * x-java.c (phase3_getc): Fix typo: Use phase2_ungetc, not phase2_getc. 4068 40692003-10-20 Bruno Haible <bruno@clisp.org> 4070 4071 Portability to AIX with cc. 4072 * xgettext.h (struct flag_context_ty): Define the bitfields of type 4073 'unsigned int'. 4074 40752003-10-20 Bruno Haible <bruno@clisp.org> 4076 4077 Portability to Solaris with cc. 4078 * x-java.c (string_buffer_append): Avoid aggregate initializer 4079 containing non-constant expressions. 4080 * xgettext.c (flag_context_list_iterator): Likewise. 4081 (language_to_extractor): Likewise. 4082 40832003-10-11 Bruno Haible <bruno@clisp.org> 4084 4085 * xgettext.c (main): Drop suffix ".in" from input file name, if 4086 present, before looking at the file extension. 4087 40882003-10-09 Bruno Haible <bruno@clisp.org> 4089 4090 * format-awk.c: Include xalloc.h instead of xmalloc.h. 4091 * format-c.c: Likewise. 4092 * format-elisp.c: Likewise. 4093 * format-gcc-internal.c: Likewise. 4094 * format-java.c: Likewise. 4095 * format-librep.c: Likewise. 4096 * format-lisp.c: Likewise. 4097 * format-pascal.c: Likewise. 4098 * format-perl.c: Likewise. 4099 * format-perl-brace.c: Likewise. 4100 * format-php.c: Likewise. 4101 * format-python.c: Likewise. 4102 * format-sh.c: Likewise. 4103 * format-tcl.c: Likewise. 4104 * format-ycp.c: Likewise. 4105 * gettext-po.c: Likewise. 4106 * hostname.c: Likewise. 4107 * message.c: Likewise. 4108 * msgexec.c: Likewise. 4109 * msgfilter.c: Likewise. 4110 * msgfmt.c: Likewise. 4111 * msggrep.c: Likewise. 4112 * msginit.c: Likewise. 4113 * msgl-cat.c: Likewise. 4114 * msgl-english.c: Likewise. 4115 * msgl-iconv.c: Likewise. 4116 * msgmerge.c: Likewise. 4117 * open-po.c: Likewise. 4118 * po-gram-gen.y: Likewise. 4119 * po-hash-gen.y: Likewise. 4120 * po-lex.c: Likewise. 4121 * read-mo.c: Likewise. 4122 * read-po-abstract.c: Likewise. 4123 * read-po.c: Likewise. 4124 * read-properties.c: Likewise. 4125 * str-list.c: Likewise. 4126 * write-java.c: Likewise. 4127 * write-mo.c: Likewise. 4128 * write-po.c: Likewise. 4129 * write-properties.c: Likewise. 4130 * write-tcl.c: Likewise. 4131 * x-awk.c: Likewise. 4132 * x-c.c: Likewise. 4133 * x-elisp.c: Likewise. 4134 * x-glade.c: Likewise. 4135 * x-java.c: Likewise. 4136 * x-librep.c: Likewise. 4137 * x-lisp.c: Likewise. 4138 * x-perl.c: Likewise. 4139 * x-php.c: Likewise. 4140 * x-po.c: Likewise. 4141 * x-python.c: Likewise. 4142 * x-rst.c: Likewise. 4143 * x-sh.c: Likewise. 4144 * x-smalltalk.c: Likewise. 4145 * x-tcl.c: Likewise. 4146 * x-ycp.c: Likewise. 4147 * xgettext.c: Likewise. 4148 41492003-10-07 Bruno Haible <bruno@clisp.org> 4150 4151 More reliable subprocess cleanup. 4152 * msgexec.c (process_string): Pass slave_process = true to 4153 create_pipe_out() and wait_subprocess(). 4154 * msgfilter.c (process_string): Pass slave_process = true to 4155 create_pipe_bidi() and wait_subprocess(). 4156 * msggrep.c (is_string_selected): Pass slave_process = true to 4157 create_pipe_out() and wait_subprocess(). 4158 * msginit.c (project_id, project_id_version, get_user_email, 4159 language_team_address): Pass slave_process = true to create_pipe_in() 4160 and wait_subprocess(). 4161 * read-java.c (execute_and_read_po_output): Likewise. 4162 * read-tcl.c (msgdomain_read_tcl): Likewise. 4163 * urlget.c (execute_it, fetch): Pass slave_process = true to execute(). 4164 41652003-10-05 Bruno Haible <bruno@clisp.org> 4166 4167 * write-java.c: Include fatal-signal.h, not signal.h. 4168 (uninstall_handlers): Remove function. 4169 (cleanup): Remove signal argument. Don't execute the signal's default 4170 action; leave that to the caller. 4171 (install_handlers, init_signal_set, block, unblock): Remove functions. 4172 (msgdomain_write_java): Invoke at_fatal_signal instead of 4173 install_handlers/uninstall_handlers. Invoke [un]block_fatal_signals 4174 instead of [un]block. 4175 41762003-10-05 Bruno Haible <bruno@clisp.org> 4177 4178 * xgettext.c (substring_match): Remove variable. 4179 (long_options): Remove --keyword-substring option. 4180 (main): Remove handling of --keyword-substring option. 4181 41822003-10-05 Bruno Haible <bruno@clisp.org> 4183 4184 * message.h (enum is_format): New item yes_according_to_context. 4185 * message.c (possible_format_p): Handle also yes_according_to_context. 4186 * write-po.c (make_format_description_string): Likewise. 4187 4188 * xgettext.h (struct flag_context_ty): New type. 4189 (null_context, passthrough_context): New declarations. 4190 (inherited_context): New declaration. 4191 (struct flag_context_list_ty): New type. 4192 (struct flag_context_list_iterator_ty): New type. 4193 (null_context_list_iterator, passthrough_context_list_iterator): New 4194 declarations. 4195 (flag_context_list_iterator): New declaration. 4196 (flag_context_list_iterator_advance): New declaration. 4197 (flag_context_list_table_ty): New type. 4198 (flag_context_list_table_lookup): New declaration. 4199 (xgettext_record_flag): New declaration. 4200 (remember_a_message, remember_a_message_plural): Add context argument. 4201 * xgettext.c: Include alloca.h. 4202 (flag_table_c, flag_table_gcc_internal, flag_table_sh, 4203 flag_table_python, flag_table_lisp, flag_table_elisp, 4204 flag_table_librep, flag_table_java, flag_table_awk, flag_table_ycp, 4205 flag_table_tcl, flag_table_perl, flag_table_php): New variables. 4206 (long_options): Add option --flag. 4207 (extractor_func): Add argument flag_table. 4208 (struct extractor_ty): New type. 4209 (main): Use type 'extractor_ty' instead of 'extractor_func'. 4210 Invoke init_flag_table_c(), init_flag_table_gcc_internal(), 4211 init_flag_table_sh(), init_flag_table_python(), init_flag_table_lisp(), 4212 init_flag_table_elisp(), init_flag_table_librep(), 4213 init_flag_table_java(), init_flag_table_awk(), init_flag_table_ycp(), 4214 init_flag_table_tcl(), init_flag_table_perl(), init_flag_table_php(). 4215 Implement option --flag. 4216 (usage): Rename a section to "Language specific options". Document 4217 the languages to which --extract-all, --keyword, --trigraphs are 4218 applicable. Document option --flag. 4219 (null_context): New variable. 4220 (passthrough_context): New variable. 4221 (inherited_context): New function. 4222 (null_context_list_iterator): New variable. 4223 (passthrough_context_circular_list, passthrough_context_list_iterator): 4224 New variables. 4225 (flag_context_list_iterator): New function. 4226 (flag_context_list_iterator_advance): New function. 4227 (flag_context_list_table_lookup): New function. 4228 (xgettext_record_flag): New function. 4229 (extract_from_file): Change argument type to 'extractor_ty' instead of 4230 'extractor_func'. Set current_formatstring_parser{1,2} before invoking 4231 the extractor. 4232 (set_format_flags_from_context): New function. 4233 (remember_a_message): Add context argument. Set some *-format flag if 4234 the context specifies it. 4235 (remember_a_message_plural): Likewise. 4236 (language_to_extractor): Change return type to 'extractor_ty' instead 4237 of 'extractor_func'. 4238 4239 * x-awk.h (SCANNERS_AWK): Refer to flag_table_awk. 4240 (extract_awk): Add argument flag_table. 4241 (init_flag_table_awk): New declaration. 4242 * x-awk.c (init_flag_table_awk): New function. 4243 (enum token_type_ty): New enum item token_type_semicolon. 4244 (x_awk_lex): Recognize semicolon. 4245 (flag_context_list_table): New variable. 4246 (extract_parenthesized): Add arguments outer_context, context_iter. 4247 Implement context handling depending on symbol before '('. Also 4248 recognize argument lists that start without '(', but only up to the 4249 next semicolon. 4250 (extract_awk): Add argument flag_table. Initialize 4251 flag_context_list_table. 4252 4253 * x-c.h (SCANNERS_C): Refer to flag_table_c, flag_table_gcc_internal. 4254 (extract_c): Add argument flag_table. 4255 (init_flag_table_c): New declaration. 4256 (init_flag_table_gcc_internal): New declaration. 4257 * x-c.c (init_flag_table_c): New function. 4258 (init_flag_table_gcc_internal): New function. 4259 (enum xgettext_token_type_ty): New item xgettext_token_type_other. 4260 (x_c_lex): For token_type_name, put the string into the resulting 4261 token instead of freeing it. Return token type 4262 xgettext_token_type_other instead of xgettext_token_type_symbol in 4263 some cases. 4264 (flag_context_list_table): New variable. 4265 (extract_parenthesized): Add arguments outer_context, context_iter. 4266 Implement context handling depending on symbol before '('. 4267 (extract_c): Add argument flag_table. Initialize 4268 flag_context_list_table. 4269 4270 * x-elisp.h (SCANNERS_ELISP): Refer to flag_table_elisp. 4271 (extract_elisp): Add argument flag_table. 4272 (init_flag_table_elisp): New declaration. 4273 * x-elisp.c (init_flag_table_elisp): New function. 4274 (flag_context_list_table): New variable. 4275 (read_object): Add argument outer_context. Implement context handling 4276 depending on first symbol after '('. 4277 (extract_elisp): Add argument flag_table. Initialize 4278 flag_context_list_table. 4279 4280 * x-glade.h (SCANNERS_GLADE): Update. 4281 (extract_glade): Add argument flag_table. 4282 * x-glade.c (start_element_handler, end_element_handler): Pass null 4283 context to remember_a_message. 4284 (extract_glade): Add argument flag_table. 4285 4286 * x-java.h (SCANNERS_JAVA): Refer to flag_table_java. 4287 (extract_java): Add argument flag_table. 4288 (init_flag_table_java): New declaration. 4289 * x-java.c (init_flag_table_java): New function. 4290 (flag_context_list_table): New variable. 4291 (extract_parenthesized): Add arguments outer_context, context_iter. 4292 Implement context handling depending on symbol before '('. 4293 (extract_java): Add argument flag_table. Initialize 4294 flag_context_list_table. 4295 4296 * x-librep.h (SCANNERS_ELISP): Refer to flag_table_librep. 4297 (extract_librep): Add argument flag_table. 4298 (init_flag_table_librep): New declaration. 4299 * x-librep.c (init_flag_table_librep): New function. 4300 (flag_context_list_table): New variable. 4301 (read_object): Add argument outer_context. Implement context handling 4302 depending on first symbol after '('. 4303 (extract_librep): Add argument flag_table. Initialize 4304 flag_context_list_table. 4305 4306 * x-lisp.h (SCANNERS_LISP): Refer to flag_table_lisp. 4307 (extract_lisp): Add argument flag_table. 4308 (init_flag_table_lisp): New declaration. 4309 * x-lisp.c (init_flag_table_lisp): New function. 4310 (flag_context_list_table): New variable. 4311 (read_object): Add argument outer_context. Implement context handling 4312 depending on first symbol after '('. 4313 (extract_lisp): Add argument flag_table. Initialize 4314 flag_context_list_table. 4315 4316 * x-perl.h (SCANNERS_PERL): Refer to flag_table_perl. 4317 (extract_perl): Add argument flag_table. 4318 (init_flag_table_perl): New declaration. 4319 * x-perl.c (init_flag_table_java): New function. 4320 (flag_context_list_table): New variable. 4321 (extract_variable): Update. Implement context handling depending on 4322 symbol before '{'...'}'. 4323 (interpolate_keywords): Implement context handling depending on symbol 4324 before '->' or '{'...'}'. 4325 (extract_balanced): Add arguments outer_context, context_iter. 4326 Implement context handling depending on symbol before '('. Also 4327 recognize argument lists that start without '('. 4328 (extract_perl): Add argument flag_table. Initialize 4329 flag_context_list_table. 4330 4331 * x-php.h (SCANNERS_PHP): Refer to flag_table_php. 4332 (extract_php): Add argument flag_table. 4333 (init_flag_table_php): New declaration. 4334 * x-php.c (init_flag_table_php): New function. 4335 (flag_context_list_table): New variable. 4336 (extract_parenthesized): Add arguments outer_context, context_iter. 4337 Implement context handling depending on symbol before '('. 4338 (extract_php): Add argument flag_table. Initialize 4339 flag_context_list_table. 4340 4341 * x-po.h (SCANNERS_PO): Update. 4342 (extract_po): Add argument flag_table. 4343 * x-properties.h (SCANNERS_PROPERTIES): Update. 4344 (extract_properties): Add argument flag_table. 4345 * x-po.c (extract_po): Add argument flag_table. 4346 (extract_properties): Add argument flag_table. 4347 4348 * x-python.h (SCANNERS_PYTHON): Refer to flag_table_python. 4349 (extract_python): Add argument flag_table. 4350 (init_flag_table_python): New declaration. 4351 * x-python.c (init_flag_table_python): New function. 4352 (flag_context_list_table): New variable. 4353 (extract_parenthesized): Add arguments outer_context, context_iter. 4354 Implement context handling depending on symbol before '('. 4355 (extract_python): Add argument flag_table. Initialize 4356 flag_context_list_table. 4357 4358 * x-rst.h (SCANNERS_RST): Update. 4359 (extract_rst): Add argument flag_table. 4360 * x-rst.c (extract_rst): Add argument flag_table. 4361 4362 * x-sh.h (SCANNERS_SH): Refer to flag_table_sh. 4363 (extract_sh): Add argument flag_table. 4364 (init_flag_table_sh): New declaration. 4365 * x-sh.c (init_flag_table_sh): New function. 4366 (flag_context_list_table): New variable. 4367 (read_word): Add context argument. 4368 (read_command): Add outer_context argument. Implement context handling 4369 depending on first symbol of command. 4370 (read_command_list): Add outer_context argument. 4371 (extract_sh): Add argument flag_table. Initialize 4372 flag_context_list_table. 4373 4374 * x-smalltalk.h (SCANNERS_SMALLTALK): Update. 4375 (extract_smalltalk): Add argument flag_table. 4376 * x-smalltalk.c (extract_smalltalk): Add argument flag_table. 4377 4378 * x-tcl.h (SCANNERS_TCL): Refer to flag_table_tcl. 4379 (extract_tcl): Add argument flag_table. 4380 (init_flag_table_tcl): New declaration. 4381 * x-tcl.c (init_flag_table_tcl): New function. 4382 (flag_context_list_table): New variable. 4383 (accumulate_word): Add context argument. 4384 (read_word): Add context argument. 4385 (read_command): Add outer_context argument. Implement context handling 4386 depending on first symbol of command. 4387 (read_command_list): Add outer_context argument. 4388 (extract_tcl): Add argument flag_table. Initialize 4389 flag_context_list_table. 4390 4391 * x-ycp.h (SCANNERS_YCP): Refer to flag_table_ycp. 4392 (extract_ycp): Add argument flag_table. 4393 (init_flag_table_ycp): New declaration. 4394 * x-ycp.c (init_flag_table_ycp): New function. 4395 (flag_context_list_table): New variable. 4396 (extract_parenthesized): New function, split off from extract_ycp. 4397 Implement context handling depending on symbol before '('. 4398 (extract_ycp): Add argument flag_table. Initialize 4399 flag_context_list_table. Call extract_parenthesized to do the work. 4400 4401 * po-lex.c (mbfile_getc, control_sequence): Remove explicit marking of 4402 strings as c-format, now done by xgettext. 4403 44042003-09-23 Bruno Haible <bruno@clisp.org> 4405 4406 * x-awk.c (extract_parenthesized): Remove optimization of the 4407 extract_all case. 4408 * x-c.c (extract_parenthesized): Likewise. 4409 * x-elisp.c (read_object): Likewise. 4410 * x-librep.c (read_object): Likewise. 4411 * x-lisp.c (read_object): Likewise. 4412 * x-perl.c (x_perl_prelex, extract_balanced): Likewise. 4413 * x-php.c (extract_parenthesized): Likewise. 4414 * x-python.c (extract_parenthesized): Likewise. 4415 * x-sh.c (read_command): Likewise. 4416 44172003-10-08 Bruno Haible <bruno@clisp.org> 4418 4419 * msgmerge.c (main): Make option -N work. 4420 Reported by Liu Garfield <jackliu9999@hotmail.com>. 4421 44222003-10-04 Bruno Haible <bruno@clisp.org> 4423 4424 New Java backend. 4425 * x-java.c: New file. 4426 * x-java.l: Remove file. 4427 * Makefile.am (xgettext_SOURCES): Add x-java.c, remove x-java.l. 4428 (x-java.c): Remove rule. 4429 * FILES: Update. 4430 44312003-09-22 Bruno Haible <bruno@clisp.org> 4432 4433 * x-glade.c (start_element_handler): Implement extract_all behaviour. 4434 44352003-10-04 Bruno Haible <bruno@clisp.org> 4436 4437 * x-glade.c (do_extract_glade): Initialize stack_depth. 4438 * x-perl.c (extract_perl): Initialize linesize and linepos. 4439 4440 * x-python.c (phase2_getc): Set last_comment_line. 4441 (phase5_get): Set last_non_comment_line. 4442 44432003-10-04 Bruno Haible <bruno@clisp.org> 4444 4445 * x-glade.c: Don't include msgl-ascii.h and msgl-iconv.h. 4446 * x-python.c: Likewise. 4447 * x-tcl.c: Likewise. 4448 44492003-10-06 Guido Flohr <guido@imperia.net> 4450 Bruno Haible <bruno@clisp.org> 4451 4452 * x-perl.c (enum symbol_type_ty): New enum. 4453 (struct token_ty): Rename field string_type to sub_type and change its 4454 type to 'int'. 4455 (extract_quotelike_pass3, interpolate_keywords): Update. 4456 (x_perl_prelex): Set sub_type also for symbol tokens. 4457 (x_perl_lex): Special handling of prototype argument lists. 4458 Reported by Crispin Flowerday <cflowerday@zeus.com>. 4459 44602003-09-22 Bruno Haible <bruno@clisp.org> 4461 4462 * x-sh.c (read_word): Warn about $"...". 4463 44642003-09-18 Bruno Haible <bruno@clisp.org> 4465 4466 * gettext-po.h (po_file_domain_header, po_header_field, 4467 po_message_is_obsolete, po_message_is_fuzzy, po_message_is_format): New 4468 declarations. 4469 * gettext-po.c (po_file_domain_header, po_header_field, 4470 po_message_is_obsolete, po_message_is_fuzzy, po_message_is_format): New 4471 functions. 4472 * Makefile.am (LTV_CURRENT, LTV_REVISION, LTV_AGE): Bump to 1:0:1. 4473 44742003-09-14 Bruno Haible <bruno@clisp.org> 4475 4476 * plural-count.c: Include plural-count.h. 4477 * x-po.c: Include x-properties.h. 4478 * x-java.l (append_strings): Change argument type to 'const char *'. 4479 44802003-09-14 Bruno Haible <bruno@clisp.org> 4481 4482 * msgfmt.c (check_plural_eval): Mark some strings as c-format. 4483 (msgfmt_add_message): Make static. 4484 * po-lex.c (mbfile_getc, control_sequence): Mark some strings as 4485 c-format. 4486 44872003-09-18 Bruno Haible <bruno@clisp.org> 4488 4489 * FILES: Update. 4490 44912003-09-14 Bruno Haible <bruno@clisp.org> 4492 4493 More reliable checking for read errors. 4494 * po-lex.c (mbfile_getc): Diagnose read errors also in the middle of 4495 multibyte characters. 4496 (lex_getc): Diagnose read errors also right after backslash. 4497 * x-rst.c (extract_rst): Diagnose read errors also inside ConstName 4498 and immediately after #. 4499 45002003-09-14 Bruno Haible <bruno@clisp.org> 4501 4502 * write-mo.c: Include fwriterror.h. 4503 (msgdomain_write_mo): Use fwriteerror, to get right errno value in 4504 error message about write error. 4505 * write-po.c: Include fwriterror.h. 4506 (msgdomain_list_print): Use fwriteerror, to get right errno value in 4507 error message about write error. 4508 * write-java.c: Include fwriterror.h. 4509 (msgdomain_write_java): Use fwriteerror, to get right errno value in 4510 error message about write error. 4511 * write-tcl.c: Include fwriterror.h. 4512 (msgdomain_write_tcl): Use fwriteerror, to get right errno value in 4513 error message about write error. 4514 45152003-09-18 Bruno Haible <bruno@clisp.org> 4516 4517 * xgettext.c (from_current_source_encoding): Use multiline_error, 4518 for a prettier error message. 4519 4520 * x-perl.c (extract_quotelike_pass1): Store counter_delim instead of 4521 EOF as delimiter, to avoid error during from_current_source_encoding. 4522 Reported by Crispin Flowerday <cflowerday@zeus.com>. 4523 45242003-09-13 Bruno Haible <bruno@clisp.org> 4525 4526 * format-sh.c (INVALID_SHELL_SYNTAX, 4527 INVALID_CONTEXT_DEPENDENT_VARIABLE): New macros. 4528 (format_parse): Reject constructs like ${variable-default} and $?. 4529 45302003-09-13 Bruno Haible <bruno@clisp.org> 4531 4532 Fix behaviour of "<program> --help > /dev/full". 4533 * hostname.c: Include closeout.h. 4534 (main): Register close_stdout for execution at program exit. 4535 * msgattrib.c: Include closeout.h. 4536 (main): Register close_stdout for execution at program exit. 4537 * msgcat.c: Include closeout.h. 4538 (main): Register close_stdout for execution at program exit. 4539 * msgcmp.c: Include closeout.h. 4540 (main): Register close_stdout for execution at program exit. 4541 * msgcomm.c: Include closeout.h. 4542 (main): Register close_stdout for execution at program exit. 4543 * msgconv.c: Include closeout.h. 4544 (main): Register close_stdout for execution at program exit. 4545 * msgen.c: Include closeout.h. 4546 (main): Register close_stdout for execution at program exit. 4547 * msgexec.c: Include closeout.h. 4548 (main): Register close_stdout for execution at program exit. 4549 * msgfilter.c: Include closeout.h. 4550 (main): Register close_stdout for execution at program exit. 4551 * msgfmt.c: Include closeout.h. 4552 (main): Register close_stdout for execution at program exit. 4553 * msggrep.c: Include closeout.h. 4554 (main): Register close_stdout for execution at program exit. 4555 * msginit.c: Include closeout.h. 4556 (main): Register close_stdout for execution at program exit. 4557 * msgmerge.c: Include closeout.h. 4558 (main): Register close_stdout for execution at program exit. 4559 * msgunfmt.c: Include closeout.h. 4560 (main): Register close_stdout for execution at program exit. 4561 * msguniq.c: Include closeout.h. 4562 (main): Register close_stdout for execution at program exit. 4563 * urlget.c: Include closeout.h. 4564 (main): Register close_stdout for execution at program exit. 4565 * xgettext.c: Include closeout.h. 4566 (main): Register close_stdout for execution at program exit. 4567 * write-po.c (msgdomain_list_print): Don't fclose (stdout) here. 4568 45692003-09-11 Bruno Haible <bruno@clisp.org> 4570 4571 * po-lex.c (mbfile_getc): Handle unexpected return value of 4572 u8_mbtouc(). Reported by Jochen Hein <jochen@jochen.org>. 4573 45742003-09-09 Bruno Haible <bruno@clisp.org> 4575 4576 * read-properties.c (phase4_getuc): Cast line_number to 'unsigned long' 4577 before outputting it. 4578 45792003-09-09 Bruno Haible <bruno@clisp.org> 4580 4581 * po-lex.c: Test HAVE_DECL_GETC_UNLOCKED instead of HAVE_GETC_UNLOCKED. 4582 * write-po.c: Test HAVE_DECL_PUTC_UNLOCKED instead of 4583 HAVE_PUTC_UNLOCKED. 4584 45852003-09-09 Guido Flohr <guido@imperia.net> 4586 4587 * x-perl.c (extract_quotelike_pass3): Change \l handling to no longer 4588 eat up non-uppercase characters; likewise for \u. Also make \l and \u 4589 work on characters written using hex or octal escape sequence. Fix \Q 4590 handling. With option --extract-all, avoid "invalid variable 4591 interpolation" warnings. 4592 (x_perl_prelex): With option --extract-all, keep variables inside 4593 double-quoted strings untouched. 4594 45952003-09-03 Bruno Haible <bruno@clisp.org> 4596 4597 * x-sh.h: New file. 4598 * x-sh.c: New file. 4599 * xgettext.c: Include x-sh.h. 4600 (main): Call x_sh_extract_all, x_sh_keyword. 4601 (usage): Mention Shell language. 4602 (language_to_extractor): Add Shell rule. 4603 (extension_to_language): Add Shell rule. 4604 * Makefile.am (noinst_HEADERS): Add x-sh.h. 4605 (xgettext_SOURCES): Add x-sh.c. 4606 * Makefile.msvc (xgettext_OBJECTS): Add x-sh.obj. 4607 (x-sh.obj): New rule. 4608 * Makefile.vms (xgettext_OBJECTS): Add x-sh.obj. 4609 (x-sh.obj): New rule. 4610 46112003-08-31 Bruno Haible <bruno@clisp.org> 4612 4613 * format-sh.c: New file. 4614 * message.h (format_sh): New enum value. 4615 (NFORMATS): Increment. 4616 * format.h (formatstring_sh): New declaration. 4617 * format.c (formatstring_parsers): Add entry for sh. 4618 * message.c (format_language, format_language_pretty): Likewise. 4619 * Makefile.am (FORMAT_SOURCE): Add format-sh.c. 4620 * Makefile.msvc (OBJECTS): Add format-sh.obj. 4621 (format-sh.obj): New rule. 4622 * Makefile.vms (OBJECTS): Add format-sh.obj. 4623 (format-sh.obj): New rule. 4624 46252003-08-31 Bruno Haible <bruno@clisp.org> 4626 4627 * format-gcc-internal.c (isdigit): Remove unused macro. 4628 * format-perl-brace.c (isdigit): Likewise. 4629 46302003-09-01 Guido Flohr <guido@imperia.net> 4631 4632 * x-perl.c (extract_balanced): Access the global last_token. 4633 Initialize last_token and prefer_division_over_regexp here. 4634 (extract_perl): Not here. 4635 46362003-08-29 Bruno Haible <bruno@clisp.org> 4637 4638 * x-perl.c: Include getline.h. 4639 46402003-08-24 Bruno Haible <bruno@clisp.org> 4641 4642 * Makefile.msvc (format.obj, msgmerge.obj, xgettext.obj, msgattrib.obj, 4643 msgcat.obj, msgcomm.obj, msgconv.obj, msgen.obj, msgfilter.obj, 4644 msggrep.obj, msguniq.obj): Compile these in C++ mode. This works around 4645 the "non-constant initializer" error that we get for addresses of 4646 variables in DLLs in C mode. 4647 46482003-08-24 Bruno Haible <bruno@clisp.org> 4649 4650 * msgfilter.c (process_message): Cast xrealloc() result. 4651 46522003-08-24 Bruno Haible <bruno@clisp.org> 4653 4654 * msgfilter.c: On Windows, include <io.h> instead of <unistd.h>. 4655 * msggrep.c: Likewise. 4656 46572003-08-24 Bruno Haible <bruno@clisp.org> 4658 4659 * plural-count.h: New file. 4660 * plural-count.c: New file, extracted from msgmerge.c. 4661 * msgmerge.c: Include plural-count.h instead of plural-exp.h. 4662 (match_domain): Use function get_plural_count(). 4663 * Makefile.am (noinst_HEADERS): Add plural-count.h. 4664 (msgmerge_SOURCES): Add plural-count.c. 4665 * Makefile.msvc (msgmerge_OBJECTS): Add plural-count.obj. 4666 (plural-count.obj): New rule. 4667 * Makefile.vms (msgmerge_OBJECTS): Add plural-count.obj. 4668 (plural-count.obj): New rule. 4669 46702003-08-24 Bruno Haible <bruno@clisp.org> 4671 4672 Support for building DLLs on Windows. 4673 * format.h (formatstring_c, formatstring_python, formatstring_lisp, 4674 formatstring_elisp, formatstring_librep, formatstring_smalltalk, 4675 formatstring_java, formatstring_awk, formatstring_pascal, 4676 formatstring_ycp, formatstring_tcl, formatstring_perl, 4677 formatstring_perl_brace, formatstring_php, formatstring_gcc_internal, 4678 formatstring_parsers): Add DLL_VARIABLE attribute. 4679 * message.h (format_language, format_language_pretty): Likewise. 4680 * msgl-cat.h (more_than, less_than, use_first, msgcomm_mode, 4681 omit_header): Likewise. 4682 * plural-table.h (plural_table, plural_table_size): Likewise. 4683 * po-charset.h (po_charset_ascii, po_charset_utf8, po_lex_charset, 4684 po_lex_iconv, po_lex_weird_cjk): Likewise. 4685 * po-lex.h (gram_pos, gram_pos_column, gram_max_allowed_errors, 4686 pass_obsolete_entries): Likewise. 4687 * read-po.h (line_comment, allow_duplicates, input_syntax): Likewise. 4688 * write-mo.h (alignment, no_hash_table): Likewise. 4689 * Makefile.am (po-gram-gen2.h): Likewise. 4690 46912003-08-24 Bruno Haible <bruno@clisp.org> 4692 4693 * Makefile.msvc (gettext-po.obj, gettextpo.lib, gettextpo.res): New 4694 rules. 4695 (all): Depend on gettextpo.lib. 4696 (install, installdirs, uninstall): Install/uninstall gettext-po.h, 4697 gettextpo.dll and gettextpo.lib. 4698 * Makefile.vms (gettext-po.obj, gettextpo.olb): New rules. 4699 (all): Depend on gettextpo.olb. 4700 (install, installdirs, uninstall): Install/uninstall gettext-po.h, 4701 gettextpo.olb. 4702 47032003-08-24 Bruno Haible <bruno@clisp.org> 4704 4705 * dir-list.h: Make this file includable in C++ mode: add extern "C". 4706 * file-list.h: Likewise. 4707 * format.h: Likewise. 4708 * message.h: Likewise. 4709 * msgl-ascii.h: Likewise. 4710 * msgl-cat.h: Likewise. 4711 * msgl-charset.h: Likewise. 4712 * msgl-english.h: Likewise. 4713 * msgl-equal.h: Likewise. 4714 * msgl-iconv.h: Likewise. 4715 * open-po.h: Likewise. 4716 * po-charset.h: Likewise. 4717 * po-lex.h: Likewise. 4718 * po-time.h: Likewise. 4719 * read-po-abstract.h: Likewise. 4720 * str-list.h: Likewise. 4721 * write-po.h: Likewise. 4722 * xgettext.h: Likewise. 4723 * read-po.h: Likewise. 4724 (this): Redefine to a different symbol. 4725 * xgettext.c: Add extern "C" around all "x-*.h" includes. 4726 47272003-08-22 Bruno Haible <bruno@clisp.org> 4728 4729 * format-awk.c: Include error-progname.h instead of progname.h. 4730 * format-c.c: Likewise. 4731 * format-elisp.c: Likewise. 4732 * format-gcc-internal.c: Likewise. 4733 * format-java.c: Likewise. 4734 * format-librep.c: Likewise. 4735 * format-lisp.c: Likewise. 4736 * format-pascal.c: Likewise. 4737 * format-perl.c: Likewise. 4738 * format-perl-brace.c: Likewise. 4739 * format-php.c: Likewise. 4740 * format-python.c: Likewise. 4741 * format-tcl.c: Likewise. 4742 * format-ycp.c: Likewise. 4743 * po-lex.h: Likewise. 4744 * read-properties.c: Likewise. 4745 * write-po.c: Likewise. 4746 * x-awk.c: Likewise. 4747 * x-c.c: Likewise. 4748 * x-perl.c: Likewise. 4749 * x-python.c: Likewise. 4750 * x-rst.c: Likewise. 4751 * hostname.c: Include error-progname.h. 4752 * msgattrib.c: Likewise. 4753 * msgcat.c: Likewise. 4754 * msgcmp.c: Likewise. 4755 * msgcomm.c: Likewise. 4756 * msgconv.c: Likewise. 4757 * msgen.c: Likewise. 4758 * msgexec.c: Likewise. 4759 * msgfilter.c: Likewise. 4760 * msgfmt.c: Likewise. 4761 * msggrep.c: Likewise. 4762 * msginit.c: Likewise. 4763 * msgmerge.c: Likewise. 4764 * msgunfmt.c: Likewise. 4765 * msguniq.c: Likewise. 4766 * urlget.c: Likewise. 4767 * xgettext.c: Likewise. 4768 * po-lex.c: Include error-progname.h and pos.h. 4769 47702003-08-15 Bruno Haible <bruno@clisp.org> 4771 4772 * msginit.c (catalogname_for_locale): Add entries for Aragonese, 4773 Haitian, Sichuan Yi, Limburgish. 4774 (englishname_of_language): Likewise. 4775 47762003-08-08 Bruno Haible <bruno@clisp.org> 4777 4778 * format-gcc-internal.c: New file. 4779 * message.h (format_gcc_internal): New enum value. 4780 (NFORMATS): Increment. 4781 * format.h (formatstring_gcc_internal): New declaration. 4782 * format.c (formatstring_parsers): Add entry for gcc_internal. 4783 * message.c (format_language, format_language_pretty): Likewise. 4784 * x-c.h (SCANNERS_C): Add an entry for GCC-source. 4785 * xgettext.c (usage): Mention GCC-source language. 4786 * Makefile.am (FORMAT_SOURCE): Add format-gcc-internal.c. 4787 * Makefile.msvc (OBJECTS): Add format-gcc-internal.obj. 4788 (format-gcc-internal.obj): New rule. 4789 * Makefile.vms (OBJECTS): Add format-gcc-internal.obj. 4790 (format-gcc-internal.obj): New rule. 4791 47922003-08-04 Bruno Haible <bruno@clisp.org> 4793 4794 * x-perl.c (extract_quotelike_pass3): Fix \x handling. 4795 Reported by Guido Flohr. 4796 47972003-07-05 Bruno Haible <bruno@clisp.org> 4798 4799 * format-perl-brace.c: Renamed from format-perl-bracket.c. Recognize 4800 braces instead of brackets. 4801 * format.h (formatstring_perl_brace): Renamed from 4802 formatstring_perl_bracket. 4803 * format.c (formatstring_parsers): Add formatstring_perl_brace, remove 4804 formatstring_perl_bracket. 4805 * message.h (enum format_type): Add format_perl_brace, remove 4806 format_perl_bracket. 4807 * message.c (format_language, format_language_pretty): Update. 4808 * x-perl.h (SCANNERS_PERL): Update. 4809 * Makefile.am (FORMAT_SOURCE): Add format-perl-brace.c, remove 4810 format-perl-bracket.c. 4811 * Makefile.msvc (OBJECTS): Add format-perl-brace.obj, remove 4812 format-perl-bracket.obj. 4813 (format-perl-brace.obj): Renamed from format-perl-bracket.obj. 4814 * Makefile.vms (OBJECTS): Add format-perl-brace.obj, remove 4815 format-perl-bracket.obj. 4816 (format-perl-brace.obj): Renamed from format-perl-bracket.obj. 4817 48182003-07-03 Bruno Haible <bruno@clisp.org> 4819 4820 Support for PHP >= 4.2.0. 4821 * x-php.c (init_keywords): Add ngettext, dngettext, dcngettext to the 4822 built-in keywords. 4823 Reported by A. Sopicki <a.sopicki@gmx.de>. 4824 48252003-06-27 Bruno Haible <bruno@clisp.org> 4826 4827 * xgettext.h (from_current_source_encoding): New declaraction. 4828 * xgettext.c (from_current_source_encoding): New function. 4829 (CONVERT_STRING): Use it. 4830 * x-perl.c: Include po-charset.h. 4831 (get_here_document): Convert each line to UTF-8. 4832 (phase2_getc): Convert each comment to UTF-8. Tell xgettext_comment_add 4833 to not convert it. 4834 (extract_quotelike_pass1_utf8): New function. 4835 (extract_quotelike): Use extract_quotelike_pass1_utf8. 4836 (extract_triple_quotelike): Likewise. 4837 (extract_variable): Tell remember_a_message to not convert the string. 4838 (interpolate_keywords): Likewise. 4839 (extract_balanced): Tell remember_a_message, remember_a_message_plural 4840 to not convert the string. 4841 48422003-06-23 Guido Flohr <guido@imperia.net> 4843 4844 * x-perl.c (extract_quotelike_pass3): Fix handling of doubled 4845 backslashes in single-quoted strings. 4846 48472003-06-23 Bruno Haible <bruno@clisp.org> 4848 4849 * format-perl-bracket.c (format_check): Allow additional bracketed 4850 items in the msgstr. 4851 48522003-06-22 Bruno Haible <bruno@clisp.org> 4853 4854 * write-properties.c: Don't include exit.h and gettext.h. 4855 48562003-06-22 Bruno Haible <bruno@clisp.org> 4857 4858 * x-php.c (phase3_ungetc): Comment out unused function. 4859 48602003-06-21 Bruno Haible <bruno@clisp.org> 4861 4862 * format-perl.c: Complete rewrite. 4863 * format-perl-bracket.c: New file. 4864 * message.h (format_perl_bracket): New enum value. 4865 (NFORMATS): Increment. 4866 * format.h (formatstring_perl_bracket): New declaration. 4867 * format.c (formatstring_parsers): Add entry for perl_bracket. 4868 * message.c (format_language, format_language_pretty): Likewise. 4869 * x-perl.h (SCANNERS_PERL): Use formatstring_perl and 4870 formatstring_perl_bracket. 4871 * Makefile.am (FORMAT_SOURCE): Add format-perl-bracket.c. 4872 * Makefile.msvc (OBJECTS): Add format-perl.obj,format-perl-bracket.obj. 4873 (xgettext_OBJECTS): Add x-perl.obj. 4874 (format-perl.obj, format-perl-bracket.obj, x-perl.obj): New rules. 4875 * Makefile.vms (OBJECTS): Add format-perl.obj, format-perl-bracket.obj. 4876 (xgettext_OBJECTS): Add x-perl.obj. 4877 (format-perl.obj, format-perl-bracket.obj, x-perl.obj): New rules. 4878 4879 * x-perl.c (extract_quotelike_pass3): Don't give an invalid 4880 interpolation error for a backslashed dollar sign. 4881 48822003-06-21 Bruno Haible <bruno@clisp.org> 4883 4884 * x-perl.c (extract_quotelike_pass3): Fix handling of double backslash. 4885 48862003-06-19 Bruno Haible <bruno@clisp.org> 4887 4888 * x-perl.c (enum string_type_ty): Remove trailing comma. 4889 (interpolate_keywords::enum parser_state): Likewise. 4890 (extract_quotelike_pass3): Cast first argument of u8_uctomb(). 4891 48922003-06-15 Bruno Haible <bruno@clisp.org> 4893 4894 * x-awk.c: Reorder definitions. 4895 * x-c.c: Reorder definitions. 4896 * x-perl.c: Reorder definitions. 4897 * x-php.c: Reorder definitions. 4898 * x-python.c: Reorder definitions. 4899 * x-smalltalk.c: Reorder definitions. 4900 * x-ycp.c: Reorder definitions. 4901 49022003-06-15 Bruno Haible <bruno@clisp.org> 4903 4904 * x-perl.c (struct stack_entry): Remove type. 4905 (struct stack): Remove type. 4906 (struct token_stack_ty): New type. 4907 (token_stack): Change type to 'struct token_stack_ty'. 4908 (token_stack_dump): Renamed from stack_dump. Update. 4909 (token_stack_push): Renamed from stack_unshift. Rewritten. 4910 (token_stack_pop): Renamed from stack_shift. Rewritten. 4911 (token_stack_peek): Renamed from stack_head. Rewritten. 4912 (token_stack_free): Renamed from stack_free. Rewritten. 4913 (x_perl_lex, x_perl_unlex, extract_perl): Update. 4914 49152003-06-15 Bruno Haible <bruno@clisp.org> 4916 4917 * x-perl.c (DEBUG_MEMORY): Remove macro. 4918 (remember_a_message_debug, remember_a_message_plural_debug, 4919 xmalloc_debug, xrealloc_debug, xrealloc_static_debug, xstrdup_debug, 4920 free_debug): Remove functions. 4921 (xrealloc_static): Remove macro. Use xrealloc instead. 4922 49232003-06-15 Bruno Haible <bruno@clisp.org> 4924 4925 * x-awk.c (phase2_getc, x_awk_lex): Increase bufmax proportionally. 4926 * x-c.c (comment_add, comment_line_end, phase5_get, phase6_get): 4927 Likewise. 4928 * x-elisp.c (comment_add, comment_line_end): Likewise. 4929 * x-librep.c (comment_add, comment_line_end): Likewise. 4930 * x-lisp.c (comment_add, comment_line_end): Likewise. 4931 * x-php.c (comment_add, comment_line_end, x_php_lex): Likewise. 4932 * x-python.c (comment_add, comment_line_end, phase5_get): Likewise. 4933 * x-rst.c (extract_rst): Likewise. 4934 * x-smalltalk.c (comment_add, comment_line_end, phase2_get): Likewise. 4935 * x-tcl.c (comment_add, comment_line_end): Likewise. 4936 * x-ycp.c (phase2_getc, x_ycp_lex): Likewise. 4937 49382003-06-15 Bruno Haible <bruno@clisp.org> 4939 4940 * xgettext.c (current_formatstring_parser1, 4941 current_formatstring_parser2): New variables, replacing 4942 current_formatstring_parser. 4943 (remember_a_message, remember_a_message_plural): Try both 4944 formatstring parsers. 4945 (language_to_extractor): Allow two formatstring parsers per language, 4946 not just one. 4947 * x-perl.h (SCANNERS_PERL): Add formatstring_c as secondary format 4948 string parser. 4949 * x-awk.h (SCANNERS_AWK): Update. 4950 * x-c.h (SCANNERS_C): Update. 4951 * x-elisp.h (SCANNERS_ELISP): Update. 4952 * x-glade.h (SCANNERS_GLADE): Update. 4953 * x-java.h (SCANNERS_JAVA): Update. 4954 * x-librep.h (SCANNERS_LIBREP): Update. 4955 * x-lisp.h (SCANNERS_LISP): Update. 4956 * x-php.h (SCANNERS_PHP): Update. 4957 * x-po.h (SCANNERS_PO): Update. 4958 * x-properties.h (SCANNERS_PROPERTIES): Update. 4959 * x-python.h (SCANNERS_PYTHON): Update. 4960 * x-rst.h (SCANNERS_RST): Update. 4961 * x-smalltalk.h (SCANNERS_SMALLTALK): Update. 4962 * x-tcl.h (SCANNERS_TCL): Update. 4963 * x-ycp.h (SCANNERS_YCP): Update. 4964 49652003-06-15 Bruno Haible <bruno@clisp.org> 4966 4967 * x-perl.c (case_whitespace): New macro. 4968 (is_whitespace): New function. 4969 (interpolate_keywords): Add lineno argument. Track newlines to update 4970 lineno while processing the string. Use is_whitespace. 4971 (extract_triple_quotelike): Update. Use is_whitespace. 4972 (extract_variable): Simplify: add final NUL byte only when done. Use 4973 is_whitespace. 4974 (x_perl_prelex): Use is_whitespace. After reading a here document, use 4975 line_number+1, not line_number. Fix buffer overrun in <<XYZ handling. 4976 (collect_message): Use is_whitespace. 4977 (extract_balanced): Call free_token at the end of the loop, not at the 4978 beginning. 4979 49802003-06-14 Bruno Haible <bruno@clisp.org> 4981 4982 * x-perl.c (enum token_type_ty): Reorder, so as to simplify the 4983 function free_token(). 4984 (struct token_ty): Fix comments. 4985 (token2string): Add const. 4986 (token_stack): Make static. 4987 (*_debug, stack_dump): Remove all fflushs. 4988 (linebuf, linesize, linepos, linebuf_size, last_token, here_eaten, 4989 end_of_file): Make static. 4990 (last_string, last_string_finished): Remove unused variables. 4991 (phase1_getc, get_here_document, skip_pod): Test getline() result 4992 for being < 0, not == EOF. 4993 (phase1_ungetc): Signal internal error through abort(), not exit(). 4994 (get_here_document): Tweak. Increase bufmax proportionally. 4995 (phase2_getc): Increase bufmax proportionally. 4996 (prefer_division_over_regexp): Fix comment. 4997 (extract_hex, extract_oct): Add const. Simplify. 4998 (extract_quotelike): Add a safety check. 4999 (extract_quotelike_pass1): Increase bufmax proportionally. Fix 5000 insufficient memory allocation at "bufpos + len >= bufmax". 5001 (extract_quotelike_pass3): Increase bufmax proportionally. Make crs 5002 const. After \x{ABC} position crs after the closing brace. Simplify \c 5003 code. Reduce memory allocation when \N{ABC} is seen. Fix bug in \l and 5004 \u. Fix error message when $ or @ is seen. 5005 (extract_variable): Increase bufmax proportionally. 5006 (interpolate_keywords): Likewise. Convert c's value to unsigned char. 5007 (x_perl_prelex): Increase bufmax proportionally. Compute 4th argument 5008 to extract_triple_quotelike completely. 5009 (extract_perl): Initialize token_stack correctly. 5010 50112003-06-13 Bruno Haible <bruno@clisp.org> 5012 5013 * msgexec.c (process_string): Pass null_stderr=false. 5014 * msgfilter.c (process_string): Likewise. 5015 * msggrep.c (is_string_selected): Likewise. 5016 * read-java.c (execute_and_read_po_output): Likewise. 5017 * read-tcl.c (msgdomain_read_tcl): Likewise. 5018 * msginit.c (project_id, project_id_version, get_user_email, 5019 language_team_address): Return a default value if the subprocess 5020 fails, instead of exiting. 5021 50222003-06-12 Bruno Haible <bruno@clisp.org> 5023 5024 * Makefile.am (noinst_HEADERS): Add x-perl.h. 5025 (FORMAT_SOURCE): Add format-perl.c. 5026 (xgettext_SOURCES): Add x-perl.c. 5027 * message.h (enum format_type): Mention perl between tcl and php. 5028 * message.c (format_language, format_language_pretty): Likewise. 5029 * format.h (formatstring_perl): Likewise. 5030 * format.c (formatstring_parsers): Likewise. 5031 * format-perl.c: Use GNU coding style. Prefer xmalloc over xcalloc. 5032 * x-perl.h: Assume ANSI C. 5033 * x-perl.c: Assume ANSI C. Use GNU coding style. Prefer xmalloc over 5034 xcalloc. 5035 (token_buf): Remove unused variable. 5036 (xcalloc_debug, stack_push, stack_pop): Remove unused functions. 5037 * xgettext.c: Mention perl between tcl and php. 5038 50392003-06-11 Guido Flohr <guido@imperia.net> 5040 5041 * message.h (enum format_type): New enum value 'format_perl'. 5042 (NFORMATS): Increment. 5043 * message.c (format_language, format_language_pretty): Add entry 5044 for perl. 5045 * format.h (formatstring_perl): New declaration. 5046 * format-perl.c: New file. 5047 * format.c (formatstring_parsers): Add entry for perl. 5048 * x-perl.h: New file. 5049 * x-perl.c: New file. 5050 * xgettext.c: Include x-perl.h. 5051 (main): Call x_perl_extract_all, x_perl_keyword. 5052 (usage): Mention Perl language. 5053 (language_to_extractor): Add Perl rule. 5054 (extension_to_language): Add Perl rule. 5055 50562003-06-08 Bruno Haible <bruno@clisp.org> 5057 5058 * Makefile.vms (LDADD): Take options from .opt files. 5059 (libiconv.opt): New rule. 5060 (msgcmp.exe, msgfmt.exe, msgmerge.exe, msgunfmt.exe, xgettext.exe, 5061 msgattrib.exe, msgcat.exe, msgcomm.exe, msgconv.exe, msgen.exe, 5062 msgexec.exe, msgfilter.exe, msggrep.exe, msginit.exe, msguniq.exe): 5063 Depend on it. 5064 * plural-eval.c: Include "eval-plural.h" without a path, rely on the 5065 Makefile's -I options instead. 5066 * read-properties.c (conv_from_java): Change type of q to 5067 'unsigned char *'. 5068 Reported by Jouk Jansen <joukj@hrem.stm.tudelft.nl>. 5069 50702003-05-27 Bruno Haible <bruno@clisp.org> 5071 5072 * plural-table.c (plural_table): Correct entry for Slovak. 5073 Reported by Marcel Telka <marcel@telka.sk>. 5074 50752003-05-24 Bruno Haible <bruno@clisp.org> 5076 5077 * x-glade.h (EXTENSIONS_GLADE): Also recognize the .glade2 extension. 5078 * x-glade.c (start_element_handler): Also extract strings according to 5079 Glade 2 conventions. 5080 50812003-05-22 Bruno Haible <bruno@clisp.org> 5082 5083 * gettext-0.12.1 released. 5084 50852003-05-21 Bruno Haible <bruno@clisp.org> 5086 5087 * msggrep.c (main) [Solaris]: Fix syntax error. 5088 Reported by Valery Beaud <valery.beaud@art.alcatel.fr>. 5089 50902003-05-21 Bruno Haible <bruno@clisp.org> 5091 5092 * xgettext.c (output_syntax): New variable. 5093 (main): Set it. 5094 (finalize_header): If --properties-output was given, set the charset. 5095 50962003-05-18 Bruno Haible <bruno@clisp.org> 5097 5098 * Makefile.msvc (DEBUGFLAGS): New variable. 5099 (gettextsrc.lib): Use it. 5100 (msgcmp.exe, msgfmt.exe, msgmerge.exe, msgunfmt.exe, xgettext.exe, 5101 msgattrib.exe, msgcat.exe, msgcomm.exe, msgconv.exe, msgen.exe, 5102 msgexec.exe, msgfilter.exe, msggrep.exe, msginit.exe, msguniq.exe): 5103 Use it, and MFLAGS too. 5104 51052003-05-17 Bruno Haible <bruno@clisp.org> 5106 5107 * gettext-0.12 released. 5108 51092003-05-17 Bruno Haible <bruno@clisp.org> 5110 5111 * Makefile.msvc (msgcmp.exe, msgfmt.exe, msgmerge.exe, msgunfmt.exe, 5112 msgattrib.exe, msgcat.exe, msgcomm.exe, msgconv.exe, msgen.exe, 5113 msgexec.exe, msgfilter.exe, msggrep.exe, msginit.exe, msguniq.exe): 5114 Link with iconv.lib, needed by intl.lib. 5115 51162003-05-12 Bruno Haible <bruno@clisp.org> 5117 5118 * msginit.c (F_OK): Provide a fallback value. 5119 Reported by Perry Rapp. 5120 51212003-05-10 Bruno Haible <bruno@clisp.org> 5122 5123 * msgl-iconv.c (iconv_string): Don't return -1 just because the string 5124 is longer than 4 KB. 5125 Reported by Denis Barbier <barbier@linuxfr.org>. 5126 51272003-05-04 Bruno Haible <bruno@clisp.org> 5128 5129 * po-lex.h (po_gram_error): Don't use ISO C 99 feature on DEC C. 5130 * po-lex.c (po_gram_error): LIkewise. 5131 51322003-05-03 Bruno Haible <bruno@clisp.org> 5133 5134 * msgfilter.c: Include <sys/select.h> also on EMX. 5135 Reported by Andreas Buening <andreas.buening@nexgo.de>. 5136 51372003-04-26 Bruno Haible <bruno@clisp.org> 5138 5139 * message.h (msgdomain_list_ty): Add field 'encoding'. 5140 * message.c (msgdomain_list_alloc): Initialize it. 5141 * read-properties.h: New file. 5142 * read-properties.c: New file. 5143 * read-po-abstract.h (abstract_po_reader_class_ty): In 5144 directive_message field, add force_fuzzy argument. 5145 (po_scan_start, po_scan_end): Remove declarations. 5146 (input_syntax_ty): New type. 5147 (po_callback_message): Add force_fuzzy argument. 5148 * read-po-abstract.c (call_directive_message, po_callback_message): 5149 Add force_fuzzy argument. 5150 (po_scan_start, po_scan_end): Make static. 5151 (po_scan): Add support for syntax_properties. Move 5152 error_message_count handling to here. 5153 (po_callback_message): Move po_lex_charset_set invocation away. 5154 * read-po.h (default_po_reader_class_ty): In add_message field, add 5155 force_fuzzy argument. 5156 (default_directive_message, default_add_message): Add force_fuzzy 5157 argument. 5158 (inout_syntax): New declaration. 5159 * read-po.c (call_add_message): Add force_fuzzy argument. 5160 (default_directive_message, default_add_message): Likewise. 5161 (input_syntax): New variable. 5162 (read_po): Pass input_syntax to po_scan(). Set mdlp->encoding if 5163 possible. 5164 * po-gram-gen.y: Pass force_fuzzy = false. 5165 (do_callback_message): New function. Move po_lex_charset_set 5166 invocation to here. 5167 * po-lex.c (lex_end): Move error_message_count handling away. 5168 * write-properties.h: New file. 5169 * write-properties.c: New file. 5170 * write-po.h (message_print_syntax_properties): New declaration. 5171 * write-po.c (use_syntax_properties): New variable. 5172 (message_print_syntax_properties): New function. 5173 (msgdomain_list_print_po): New function, extracted from 5174 msgdomain_list_print. 5175 (msgdomain_list_print): Add check for plural forms. Add support for 5176 writing the .properties format. 5177 (extract_po): Renamed from extract. 5178 * write-java.h (msgdomain_write_java): Add canon_encoding argument. 5179 * write-java.c (msgdomain_write_java): Likewise. 5180 * write-tcl.h (msgdomain_write_tcl): Likewise. 5181 * write-tcl.c (msgdomain_write_tcl): Likewise. 5182 * msgl-cat.c (catenate_msgdomain_list): Use mdlp->encoding if there 5183 is no header entry. Set total_mdlp->encoding if possible. 5184 * msgl-iconv.c (iconv_msgdomain_list): Use mdlp->encoding if there 5185 is no header entry. Set mdlp->encoding. 5186 * msgattrib.c (long_options): Add --properties-input/output. 5187 (main): Handle them. 5188 (usage): Document options -P and -p. 5189 * msgcat.c (long_options): Add --properties-input/output. 5190 (main): Handle them. If option -p is used, convert to UTF-8 and 5191 ignore the to_code. 5192 (usage): Document options -P and -p. 5193 * msgcomm.c (long_options): Add --properties-input/output. 5194 (main): Handle them. 5195 (usage): Document options -P and -p. 5196 * msgconv.c (long_options): Add --properties-input/output. 5197 (main): Handle them. If option -p is used, ignore the to_code. 5198 (usage): Document options -P and -p. 5199 * msgen.c (long_options): Add --properties-input/output. 5200 (main): Handle them. 5201 (usage): Document options -P and -p. 5202 * msgfilter.c (long_options): Add --properties-input/output. 5203 (main): Handle them. 5204 (usage): Document options -P and -p. 5205 * msggrep.c (long_options): Add --properties-input/output. 5206 (main): Handle them. 5207 (usage): Document options -P and -p. 5208 * msginit.c (long_options): Add --properties-input/output. 5209 (main): Handle them. 5210 (usage): Document options -P and -p. 5211 * msgmerge.c (long_options): Add --properties-input/output. 5212 (main): Handle them. In update mode, --properties-input implies 5213 --properties-output. 5214 (usage): Document options -P and -p. 5215 (merge): Set result->encoding if possible. 5216 * msguniq.c (long_options): Add --properties-input/output. 5217 (main): Handle them. 5218 (usage): Document options -P and -p. 5219 * msgcmp.c (long_options): Add --properties-input. 5220 (main): Handle it. 5221 (usage): Document option -P. 5222 * msgexec.c (long_options): Add --properties-input. 5223 (main): Handle it. 5224 (usage): Document option -P. 5225 * msgfmt.c (long_options): Add --properties-input. 5226 (main): Handle it. Pass the known canon_encoding to 5227 msgdomain_write_java and msgdomain_write_tcl. 5228 (usage): Document option -P. 5229 (msgfmt_add_message): Add force_fuzzy argument. 5230 (read_po_file_msgfmt): Pass input_syntax to po_scan(). 5231 * msgunfmt.c (long_options): Add --properties-output. 5232 (main): Handle it. 5233 (usage): Document option -p. 5234 * x-properties.h: New file. 5235 * x-po.c (extract_add_message): Add force_fuzzy argument. 5236 (extract): Renamed from extract_po. Pass input_syntax to po_scan(). 5237 (extract_po): New function. 5238 (extract_properties): New function. 5239 * xgettext.h: Include read-po.h. 5240 * xgettext.c (long_options): Add --properties-output. 5241 (main): Handle it. 5242 (usage): Document options -L JavaProperties and --properties-output. 5243 (exclude_directive_message): Add force_fuzzy argument. 5244 (read_exclusion_file): Pass input_syntax to po_scan(). 5245 (table): Add support for .properties format. 5246 * Makefile.am (noinst_HEADERS): Add read-properties.h, 5247 write-properties.h, x-properties.h. 5248 (COMMON_SOURCE): Add read-properties.c. 5249 (libgettextsrc_la_SOURCES): Add write-properties.c. 5250 * Makefile.msvc (OBJECTS): Add read-properties.obj, 5251 write-properties.obj. 5252 (read-properties.obj, write-properties.obj): New rules. 5253 * Makefile.vms (OBJECTS): Add read-properties.obj, 5254 write-properties.obj. 5255 (read-properties.obj, write-properties.obj): New rules. 5256 * FILES: Update. 5257 52582003-04-21 Bruno Haible <bruno@clisp.org> 5259 5260 * read-po-abstract.h (po_scan_file): Remove declaration. 5261 * read-po-abstract.c (po_scan_file): Remove function. 5262 * read-po.c (read_po_file): Call read_po. 5263 * msgfmt.c (read_po_file_msgfmt): Call open_po_file. Invoke po_scan 5264 instead of po_scan_file. 5265 * xgettext.c (read_exclusion_file): Call open_po_file. Invoke po_scan 5266 instead of po_scan_file. 5267 52682003-04-20 Bruno Haible <bruno@clisp.org> 5269 5270 * open-po.h (open_po_file): Add argument 'exit_on_error'. 5271 * open-po.c (try_open_po_file): Renamed from open_po_file. 5272 (open_po_file): New function. 5273 * po-lex.h (lex_end): Change return type to void. 5274 (lex_open, lex_close): Remove declarations. 5275 * po-lex.c (lex_end): Change return type to void. 5276 (lex_open, lex_close): Remove functions. 5277 * read-po-abstract.c (po_scan_file): Inline lex_open and lex_close. 5278 Reuse po_scan code. 5279 52802003-04-14 Bruno Haible <bruno@clisp.org> 5281 5282 * hostname.c (usage): Split strings: use one string per option 5283 description. 5284 * msgattrib.c (usage): Likewise. 5285 * msgcat.c (usage): Likewise. 5286 * msgcmp.c (usage): Likewise. 5287 * msgcomm.c (usage): Likewise. 5288 * msgconv.c (usage): Likewise. 5289 * msgen.c (usage): Likewise. 5290 * msgexec.c (usage): Likewise. 5291 * msgfilter.c (usage): Likewise. 5292 * msgfmt.c (usage): Likewise. 5293 * msggrep.c (usage): Likewise. 5294 * msginit.c (usage): Likewise. 5295 * msgmerge.c (usage): Likewise. 5296 * msgunfmt.c (usage): Likewise. 5297 * msguniq.c (usage): Likewise. 5298 * urlget.c (usage): Likewise. 5299 * xgettext.c (usage): Likewise. 5300 53012003-04-13 Bruno Haible <bruno@clisp.org> 5302 5303 Unify three PO file parsers. 5304 * read-po-abstract.h: Renamed from po.h. 5305 (abstract_po_reader_class_ty): Renamed from po_method_ty. 5306 (abstract_po_reader_ty): Renamed from po_ty. 5307 (ABSTRACT_PO_READER_TY): Renamed from PO_BASE_TY. 5308 (po_reader_alloc): Renamed from po_alloc. 5309 (po_reader_free): Renamed from po_free. 5310 * read-po-abstract.c: Renamed from po.c. 5311 (po_reader_alloc): Renamed from po_alloc. 5312 (po_reader_free): Renamed from po_free. 5313 (call_parse_brief): Renamed from po_parse_brief. 5314 (call_parse_debrief): Renamed from po_parse_debrief. 5315 (call_directive_domain): Renamed from po_directive_domain. 5316 (call_directive_message): Renamed from po_directive_message. 5317 (call_comment): Renamed from po_comment. 5318 (call_comment_dot): Renamed from po_comment_dot. 5319 (call_comment_filepos): Renamed from po_comment_filepos. 5320 (call_comment_special): Renamed from po_comment_special. 5321 * read-po.h: Include read-po-abstract.h. 5322 (default_po_reader_class_ty, default_po_reader_ty): New types. 5323 (ABSTRACT_PO_READER_TY): New macro. 5324 (default_constructor, default_destructor, default_parse_brief, 5325 default_parse_debrief, default_directive_domain, 5326 default_directive_message, default_comment, default_comment_dot, 5327 default_comment_filepos, default_comment_special, default_set_domain, 5328 default_add_message): New declarations. 5329 (default_po_reader_alloc): New declaration. 5330 * read-po.c (default_po_reader_ty): Renamed from readall_class_ty. 5331 Add fields handle_comments, handle_filepos_comments, 5332 allow_domain_directives, allow_duplicates, 5333 allow_duplicates_if_same_msgstr. 5334 (call_set_domain, call_add_message, call_frob_new_message): New 5335 functions. 5336 (default_constructor): Renamed from readall_constructor. Don't set 5337 this->mdlp and this->mlp. 5338 (default_destructor): Renamed from readall_destructor. 5339 (default_parse_brief): Renamed from readall_parse_brief. 5340 (default_parse_debrief): New function. 5341 (default_copy_comment_state, default_reset_comment_state): New 5342 functions. 5343 (default_directive_domain): Renamed from readall_directive_domain. 5344 Call set_domain method. 5345 (default_directive_message): Renamed from readall_directive_message. 5346 Call add_message method. 5347 (default_comment): Renamed from readall_comment. 5348 (default_comment_dot): Renamed from readall_comment_dot. 5349 (default_comment_filepos): Renamed from readall_comment_filepos. 5350 (default_comment_special): Renamed from readall_comment_special. 5351 (default_set_domain, default_add_message): New functions. 5352 (default_methods): Renamed from readall_methods. 5353 (default_po_reader_alloc): New function. 5354 (read_po, read_po_file): Update. 5355 * msgfmt.c: Include read-po.h instead of po.h. 5356 (msgfmt_po_reader_ty): Renamed from msgfmt_class_ty. Inherit 5357 from default_po_reader_ty. 5358 (main): Drop po_lex_pass_comments call, done by default_parse_brief. 5359 (msgfmt_constructor): Renamed from format_constructor. Call superclass 5360 function. 5361 (msgfmt_parse_debrief): Renamed from format_debrief. Call superclass 5362 function. 5363 (format_directive_domain): Remove function. 5364 (msgfmt_set_domain): New function. 5365 (format_directive_message): Remove function. 5366 (msgfmt_add_message, msgfmt_frob_new_message): New functions. 5367 (msgfmt_comment_special): Renamed from format_comment_special. 5368 (msgfmt_methods): Renamed from format_methods. 5369 (read_po_file_msgfmt): Renamed from read_po_file. 5370 * x-po.c: Include read-po.h instead of po.h. 5371 (extract_class_ty, extract_constructor, extract_directive_domain, 5372 extract_directive_message, extract_parse_brief, extract_comment, 5373 extract_comment_dot, extract_comment_filepos, extract_comment_special): 5374 Remove functions. 5375 (extract_add_message): New function. 5376 (extract_methods): Update. 5377 (extract_po): Update. 5378 * xgettext.c: Include read-po-abstract.h instead of po.h. 5379 (exclude_directive_domain, exclude_directive_message, exclude_methods, 5380 read_exclusion_file): Update. 5381 * msgcmp.c: Don't include po.h. 5382 * msgmerge.c: Likewise. 5383 * po-gram-gen.y: Include read-po-abstract.h instead of po.h. 5384 * po-hash-gen.y: Likewise. 5385 (po_parse_comment_filepos): Renamed from po_hash. 5386 * po-hash.h (po_parse_comment_filepos): Renamed from po_hash. 5387 * Makefile.am (noinst_HEADERS): Remove po.h, add read-po-abstract.h. 5388 (COMMON_SOURCE): Remove po.c, add read-po-abstract.c. 5389 * Makefile.msvc (OBJECTS): Remove po.obj, add read-po-abstract.obj. 5390 (read-po-abstract.obj): Renamed from po.obj. 5391 * Makefile.vms (OBJECTS): Remove po.obj, add read-po-abstract.obj. 5392 (read-po-abstract.obj): Renamed from po.obj. 5393 53942003-04-13 Bruno Haible <bruno@clisp.org> 5395 5396 * read-po.c (readall_directive_message): Separate accumulation and 5397 reset. 5398 * x-po.c (extract_directive_message): Likewise. 5399 54002003-04-13 Bruno Haible <bruno@clisp.org> 5401 5402 * write-po.h (message_print_comment, message_print_comment_dot, 5403 message_print_comment_filepos, message_print_comment_flags): New 5404 declarations. 5405 * write-po.c: Reorder functions. 5406 (message_print_comment, message_print_comment_dot, 5407 message_print_comment_filepos, message_print_comment_flags): New 5408 functions, extracted from message_print. 5409 (message_print): Use them. 5410 (message_print_obsolete): Use message_print_comment. 5411 54122003-04-22 Bruno Haible <bruno@clisp.org> 5413 5414 * plural-table.c (plural_table): Add an entry about Faroese. 5415 Reported by Jacob Sparre Andersen <sparre@crs4.it>. 5416 54172003-04-13 Bruno Haible <bruno@clisp.org> 5418 5419 * po.h (po_scan_start, po_scan_end): New declarations. 5420 * po.c: Reorder functions. 5421 (po_scan_start, po_scan_end): New functions. 5422 (po_scan, po_scan_file): Use them. 5423 54242003-04-12 Bruno Haible <bruno@clisp.org> 5425 5426 * Makefile.vms: New variables ABIFLAGS, DEFS. Avoid rules with no 5427 lines. Don't use the force target. Correct wildcard syntax. 5428 Suggested by Jouk Jansen <joukj@hrem.stm.tudelft.nl>. 5429 54302003-04-13 Bruno Haible <bruno@clisp.org> 5431 5432 * xgettext.c (construct_header): Remove spurious comma. 5433 54342003-03-30 Bruno Haible <bruno@clisp.org> 5435 5436 * Makefile.vms: New file. 5437 * Makefile.am (EXTRA_DIST): Add Makefile.vms. 5438 (x-java.c): Prepend a few VMS specific lines. 5439 * po-lex.c (mbfile_getc): Change element type of scatchbuf to 5440 'unsigned char'. 5441 * write-java.c (string_hashcode, write_java_string): Cast argument of 5442 u8_mbtouc. 5443 * write-tcl.c (write_tcl_string): Likewise. 5444 * x-python.c (phase7_getuc): Cast argument of unicode_name_character. 5445 * msgfilter.c (write): #undef before redefining it. Needed for VMS. 5446 (select): Likewise. 5447 54482003-03-30 Bruno Haible <bruno@clisp.org> 5449 5450 * Makefile.am (noinst_HEADERS): Add po-gram-gen2.h. 5451 (BUILT_SOURCES): Add po-gram-gen2.h. 5452 (DISTCLEANFILES): Remove po-gram-gen2.h. 5453 (po-gram-gen2.h): Simplify rule. 5454 54552003-03-17 Bruno Haible <bruno@clisp.org> 5456 5457 Native Woe32/MSVC support. 5458 * Makefile.msvc: New file. 5459 * Makefile.am (EXTRA_DIST): Add it. 5460 * msgfilter.c: Include <sys/time.h> only if it exists. 5461 (process_string): Mark as NYI on Woe32. 5462 * msgfmt.c (sigjmp_buf, sigsetjmp, siglongjmp): Provide fallback 5463 definitions for Woe32. 5464 * msginit.c: Include <fcntl.h>, for F_OK. Include <pwd.h> only if it 5465 exists. 5466 (get_user_pwd, get_user_fullname): Adapt for when <pwd.h> is missing. 5467 (project_id, project_id_version, get_user_email, 5468 language_team_address): Use DEV_NULL instead of "/dev/null". 5469 * msggrep.c (is_string_selected): Likewise. 5470 * read-java.c (execute_and_read_po_output): Likewise. 5471 * read-tcl.c (msgdomain_read_tcl): Likewise. 5472 * write-mo.c: Include <sys/param.h> only if it exists. 5473 54742003-03-28 Bruno Haible <bruno@clisp.org> 5475 5476 * msgmerge.c (main): Use copy_file_preserving instead of copy_file. 5477 54782003-03-16 Bruno Haible <bruno@clisp.org> 5479 5480 * str-list.h (string_list_join): Comment out. 5481 * str-list.c (string_list_join): Comment out. 5482 54832003-03-10 Bruno Haible <bruno@clisp.org> 5484 5485 * msggrep.c (no_pass): Mention option -C. 5486 (usage): Document option -C completely. 5487 Reported by Martin Quinson <Martin.Quinson@tuxfamily.org>. 5488 54892003-02-28 Bruno Haible <bruno@clisp.org> 5490 5491 Support for relocatable installation. 5492 * msgattrib.c: Include relocatable.h. 5493 (main): Relocate LOCALEDIR value. 5494 * msgcat.c: Include relocatable.h. 5495 (main): Relocate LOCALEDIR value. 5496 * msgcmp.c: Include relocatable.h. 5497 (main): Relocate LOCALEDIR value. 5498 * msgcomm.c: Include relocatable.h. 5499 (main): Relocate LOCALEDIR value. 5500 * msgconv.c: Include relocatable.h. 5501 (main): Relocate LOCALEDIR value. 5502 * msgen.c: Include relocatable.h. 5503 (main): Relocate LOCALEDIR value. 5504 * msgexec.c: Include relocatable.h. 5505 (main): Relocate LOCALEDIR value. 5506 * msgfilter.c: Include relocatable.h. 5507 (main): Relocate LOCALEDIR value. 5508 * msgfmt.c: Include relocatable.h. 5509 (main): Relocate LOCALEDIR value. 5510 * msggrep.c: Include relocatable.h. 5511 (main): Relocate LOCALEDIR value. 5512 * msginit.c: Include relocatable.h. 5513 (main): Relocate LOCALEDIR value. 5514 (project_id, project_id_version, get_user_email): Relocate LIBDIR 5515 value. 5516 (language_team_address): Relocate LIBDIR and PROJECTSDIR values. 5517 * msgmerge.c: Include relocatable.h. 5518 (main): Relocate LOCALEDIR value. 5519 * msgunfmt.c: Include relocatable.h. 5520 (main): Relocate LOCALEDIR value. 5521 * msguniq.c: Include relocatable.h. 5522 (main): Relocate LOCALEDIR value. 5523 * xgettext.c: Include relocatable.h. 5524 (main): Relocate LOCALEDIR value. 5525 * read-java.c: Include relocatable.h. 5526 (msgdomain_read_java): Relocate GETTEXTJEXEDIR value. 5527 * read-tcl.c: Include relocatable.h. 5528 (msgdomain_read_tcl): Relocate GETTEXTDATADIR value. 5529 * hostname.c: Include relocatable.h. 5530 (main): Relocate LOCALEDIR value. Update copyright year. 5531 * urlget.c: Include relocatable.h. 5532 (main): Relocate LOCALEDIR value. Update copyright year. 5533 (fetch): Relocate GETTEXTJEXEDIR value. 5534 * user-email.in: Relocate $libdir. 5535 * Makefile.am (aliaspath): New variable. 5536 (DEFS): Define LOCALE_ALIAS_PATH. 5537 (msginit_SOURCES): Add .../localealias.c. 5538 (msginit_LDADD): Remove .../localealias.lo. 5539 (msgcmp_CFLAGS, msgfmt_CFLAGS, msgmerge_CFLAGS, msgunfmt_CFLAGS, 5540 xgettext_CFLAGS, msgattrib_CFLAGS, msgcat_CFLAGS, msgcomm_CFLAGS, 5541 msgconv_CFLAGS, msgen_CFLAGS, msgexec_CFLAGS, msgfilter_CFLAGS, 5542 msggrep_CFLAGS, msginit_CFLAGS, msguniq_CFLAGS, hostname_CFLAGS, 5543 urlget_CFLAGS): New variables. 5544 (msgcmp_LDFLAGS, msgfmt_LDFLAGS, msgmerge_LDFLAGS, msgunfmt_LDFLAGS, 5545 xgettext_LDFLAGS, msgattrib_LDFLAGS, msgcat_LDFLAGS, msgcomm_LDFLAGS, 5546 msgconv_LDFLAGS, msgen_LDFLAGS, msgexec_LDFLAGS, msgfilter_LDFLAGS, 5547 msggrep_LDFLAGS, msginit_LDFLAGS, msguniq_LDFLAGS, hostname_LDFLAGS, 5548 urlget_LDFLAGS): New variables. 5549 (install-exec-java-yes): Don't ignore INSTALL_PROGRAM_ENV. 5550 (RELOCATABLE_LIBRARY_PATH, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR, 5551 RELOCATABLE_CONFIG_H_DIR): New variables. 5552 55532003-03-13 Bruno Haible <bruno@clisp.org> 5554 5555 * msggrep.c (main): On Solaris, prefer /usr/xpg4/bin/grep to 5556 /usr/bin/grep. Needed for Solaris 2.8 and 2.9. 5557 Reported by Sven Utcke <utcke@informatik.uni-hamburg.de>. 5558 55592003-03-03 Bruno Haible <bruno@clisp.org> 5560 5561 * msgen.c (usage): Don't say that the entries are marked fuzzy. 5562 Reported by Karl Eichwalder <ke@suse.de>. 5563 55642003-02-23 Bruno Haible <bruno@clisp.org> 5565 5566 Improve error messages for invalid format strings. 5567 * format-invalid.h: New file. 5568 * format.h (struct formatstring_parser): Add invalid_reason argument 5569 to 'parse' field. 5570 * format-awk.c: Include c-ctype.h, xerror.h, format-invalid.h. 5571 (format_parse): Add invalid_reason argument. 5572 * format-c.c: Include c-ctype.h, xerror.h, format-invalid.h. 5573 (INVALID_C99_MACRO): New macro. 5574 (format_parse): Add invalid_reason argument. 5575 (get_c99_format_directives): Update. 5576 * format-elisp.c: Include c-ctype.h, xerror.h, format-invalid.h. 5577 (format_parse): Add invalid_reason argument. 5578 * format-java.c: Include xerror.h, format-invalid.h. 5579 (message_format_parse, choice_format_parse, format_parse): Add 5580 invalid_reason argument. 5581 (choice_format_parse): Return false if a choice contains an empty 5582 number part. 5583 * format-librep.c: Include c-ctype.h, xerror.h, format-invalid.h. 5584 (format_parse): Add invalid_reason argument. 5585 * format-lisp.c: Include xerror.h, format-invalid.h. 5586 (check_params, nocheck_params): Add directives, invalid_reason 5587 arguments. 5588 (parse_upto, format_parse): Add invalid_reason argument. 5589 * format-pascal.c: Include xerror.h, format-invalid.h. 5590 (format_parse): Add invalid_reason argument. 5591 * format-php.c: Include c-ctype.h, xerror.h, format-invalid.h. 5592 (format_parse): Add invalid_reason argument. 5593 * format-python.c: Include c-ctype.h, xerror.h, format-invalid.h. 5594 (INVALID_MIXES_NAMED_UNNAMED): New macro. 5595 (format_parse): Add invalid_reason argument. 5596 * format-tcl.c: Include c-ctype.h, xerror.h, format-invalid.h. 5597 (format_parse): Add invalid_reason argument. 5598 * format-ycp.c: Include c-ctype.h, xerror.h, format-invalid.h. 5599 (format_parse): Add invalid_reason argument. 5600 * msgfmt.c (check_pair): Output invalid_reason returned for msgstr. 5601 * msgmerge.c (msgfmt_check_pair_fails): Update. 5602 * xgettext.c (remember_a_message, remember_a_message_plural): Update. 5603 * Makefile.am (FORMAT_SOURCE): Add format-invalid.h. 5604 56052003-02-22 Bruno Haible <bruno@clisp.org> 5606 5607 * x-python.c (init_keywords): Add u*gettext variants and plural 5608 handling functions added in Python 2.3. 5609 56102003-02-22 Bruno Haible <bruno@clisp.org> 5611 5612 * Makefile.am (installdirs): Remove dependency, redundant with 5613 automake >= 1.6. 5614 56152003-02-20 Bruno Haible <bruno@clisp.org> 5616 5617 * Makefile.am (libgettextpo_la_DEPENDENCIES): New variable. 5618 Reported by Jim Meyering <jim@meyering.net>. 5619 56202003-02-19 Bruno Haible <bruno@clisp.org> 5621 5622 * Makefile.am (xgettext_LDADD): Mention $(LIBUNINAME) before 5623 libgettextsrc.la, not after it. Needed avoid link error on OSF/1 4.0: 5624 libtool produces a link command line that contains "-lc" where a 5625 shared library was used, and on OSF/1 4.0 "-lc" must not be used 5626 before objects that use integer division. 5627 56282003-02-18 Bruno Haible <bruno@clisp.org> 5629 5630 * message.c (msgdomain_list_free): Uncomment this function. 5631 * Makefile.am (libgettextpo_la_LDFLAGS): Add ../lib/libgettextlib.la. 5632 Needed for Solaris 2.7. 5633 56342003-02-16 Bruno Haible <bruno@clisp.org> 5635 5636 * msgmerge.c (message_merge): Add support for Report-Msgid-Bugs-To 5637 field. 5638 * xgettext.c (msgid_bugs_address): New variable. 5639 (long_options): Add option --msgid-bugs-address. 5640 (main): Handle option --msgid-bugs-address. 5641 (usage): Document option --msgid-bugs-address. 5642 (construct_header): Add 'Report-Msgid-Bugs-To:' field. Warn if 5643 msgid_bugs_address is empty. 5644 56452003-02-15 Bruno Haible <bruno@clisp.org> 5646 5647 * user-email.in: Add support for GNOME evolution, OpenOffice and 5648 StarOffice with nonstandard installation directory. 5649 56502003-02-15 Bruno Haible <bruno@clisp.org> 5651 5652 * msgattrib.c (main): Update year in --version output. 5653 * msgcat.c (main): Likewise. 5654 * msgcmp.c (main): Likewise. 5655 * msgcomm.c (main): Likewise. 5656 * msgconv.c (main): Likewise. 5657 * msgen.c (main): Likewise. 5658 * msgexec.c (main): Likewise. 5659 * msgfilter.c (main): Likewise. 5660 * msgfmt.c (main): Likewise. 5661 * msgunfmt.c (main): Likewise. 5662 * msguniq.c (main): Likewise. 5663 * xgettext.c (main): Likewise. 5664 56652003-02-12 Bruno Haible <bruno@clisp.org> 5666 5667 Big restructuring. 5668 * gettext.c: Remove file. 5669 * ngettext.c: Remove file. 5670 * Makefile.am (bin_PROGRAMS): Remove gettext, ngettext. 5671 (EXTRA_DIST): Add ChangeLog.0. 5672 (pkgdatadir): Define using 'gettext' instead of @PACKAGE@. 5673 (pkglibdir): Likewise. 5674 (INCLUDES): Refer to intl in gettext-runtime directory. 5675 (gettext_SOURCES, ngettext_SOURCES, gettext_LDADD, ngettext_LDADD): 5676 Remove variables. 5677 (install-exec-local, installdirs-local, uninstall-local, 5678 install-exec-java-yes, installdirs-java-yes, uninstall-java-yes): Use 5679 $(pkglibdir) instead of $(libdir)/$(PACKAGE). 5680 * plural.c: Update for changed directory structure. 5681 * user-email.in: Use 'gettext' instead of @PACKAGE@. 5682 5683 5684See ChangeLog.0 for earlier changes. 5685