1 Upstream-Status: Inappropriate [configuration]
3 --- lrzsz-0.12.20.safe/ABOUT-NLS 1998-04-26 09:22:30.000000000 -0400
4 +++ lrzsz-0.12.20/ABOUT-NLS 2004-09-12 14:40:34.323752952 -0400
6 Notes on the Free Translation Project
7 *************************************
9 - Free software is going international! The Free Translation Project
10 -is a way to get maintainers of free software, translators, and users all
11 +Free software is going international! The Free Translation Project is
12 +a way to get maintainers of free software, translators, and users all
13 together, so that will gradually become able to speak many languages.
14 A few packages already provide translations for their messages.
16 If you found this `ABOUT-NLS' file inside a distribution, you may
17 assume that the distributed package does use GNU `gettext' internally,
18 -itself available at your nearest GNU archive site. But you do *not*
19 +itself available at your nearest GNU archive site. But you do _not_
20 need to install GNU `gettext' prior to configuring, installing or using
21 this package with messages translated.
24 `gettext' which is used. The information can be found in the
25 `intl/VERSION' file, in internationalized packages.
27 -One advise in advance
28 -=====================
29 +Quick configuration advice
30 +==========================
32 - If you want to exploit the full power of internationalization, you
33 +If you want to exploit the full power of internationalization, you
34 should configure it using
36 ./configure --with-included-gettext
38 package, despite the existence of internationalizing capabilities in the
39 operating system where this package is being installed. So far, only
40 the `gettext' implementation in the GNU C library version 2 provides as
41 -many features (such as locale alias or message inheritance) as the
42 -implementation here. It is also not possible to offer this additional
43 -functionality on top of a `catgets' implementation. Future versions of
44 -GNU `gettext' will very likely convey even more functionality. So it
45 -might be a good idea to change to GNU `gettext' as soon as possible.
46 +many features (such as locale alias, message inheritance, automatic
47 +charset conversion or plural form handling) as the implementation here.
48 +It is also not possible to offer this additional functionality on top
49 +of a `catgets' implementation. Future versions of GNU `gettext' will
50 +very likely convey even more functionality. So it might be a good idea
51 +to change to GNU `gettext' as soon as possible.
53 - So you need not provide this option if you are using GNU libc 2 or
54 + So you need _not_ provide this option if you are using GNU libc 2 or
55 you have installed a recent copy of the GNU gettext package with the
61 - Some packages are "localizable" when properly installed; the
62 -programs they contain can be made to speak your own native language.
63 -Most such packages use GNU `gettext'. Other packages have their own
64 -ways to internationalization, predating GNU `gettext'.
65 +Some packages are "localizable" when properly installed; the programs
66 +they contain can be made to speak your own native language. Most such
67 +packages use GNU `gettext'. Other packages have their own ways to
68 +internationalization, predating GNU `gettext'.
70 By default, this package will be installed to allow translation of
71 -messages. It will automatically detect whether the system provides
72 -usable `catgets' (if using this is selected by the installer) or
73 -`gettext' functions. If neither is available, the GNU `gettext' own
74 +messages. It will automatically detect whether the system already
75 +provides the GNU `gettext' functions. If not, the GNU `gettext' own
76 library will be used. This library is wholly contained within this
77 package, usually in the `intl/' subdirectory, so prior installation of
78 -the GNU `gettext' package is *not* required. Installers may use
79 +the GNU `gettext' package is _not_ required. Installers may use
80 special options at configuration time for changing the default
81 behaviour. The commands:
83 ./configure --with-included-gettext
84 - ./configure --with-catgets
85 ./configure --disable-nls
87 -will respectively bypass any pre-existing `catgets' or `gettext' to use
88 -the internationalizing routines provided within this package, enable
89 -the use of the `catgets' functions (if found on the locale system), or
90 -else, *totally* disable translation of messages.
91 +will respectively bypass any pre-existing `gettext' to use the
92 +internationalizing routines provided within this package, or else,
93 +_totally_ disable translation of messages.
95 When you already have GNU `gettext' installed on your system and run
96 configure without an option for your new package, `configure' will
99 to prevent auto-detection.
101 - By default the configuration process will not test for the `catgets'
102 -function and therefore they will not be used. The reasons are already
103 -given above: the emulation on top of `catgets' cannot provide all the
104 -extensions provided by the GNU `gettext' library. If you nevertheless
105 -want to use the `catgets' functions use
107 - ./configure --with-catgets
109 -to enable the test for `catgets' (this causes no harm if `catgets' is
110 -not available on your system). If you really select this option we
111 -would like to hear about the reasons because we cannot think of any
113 + The configuration process will not test for the `catgets' function
114 +and therefore it will not be used. The reason is that even an
115 +emulation of `gettext' on top of `catgets' could not provide all the
116 +extensions of the GNU `gettext' library.
118 Internationalized packages have usually many `po/LL.po' files, where
119 LL gives an ISO 639 two-letter code identifying the language. Unless
124 - As a user, if your language has been installed for this package, you
125 +As a user, if your language has been installed for this package, you
126 only have to set the `LANG' environment variable to the appropriate
127 -ISO 639 `LL' two-letter code prior to using the programs in the
128 -package. For example, let's suppose that you speak German. At the
129 -shell prompt, merely execute `setenv LANG de' (in `csh'),
130 -`export LANG; LANG=de' (in `sh') or `export LANG=de' (in `bash'). This
131 -can be done from your `.login' or `.profile' file, once and for all.
132 +`LL_CC' combination. Here `LL' is an ISO 639 two-letter language code,
133 +and `CC' is an ISO 3166 two-letter country code. For example, let's
134 +suppose that you speak German and live in Germany. At the shell
135 +prompt, merely execute `setenv LANG de_DE' (in `csh'),
136 +`export LANG; LANG=de_DE' (in `sh') or `export LANG=de_DE' (in `bash').
137 +This can be done from your `.login' or `.profile' file, once and for
140 - An operating system might already offer message localization for
141 -many of its programs, while other programs have been installed locally
142 -with the full capabilities of GNU `gettext'. Just using `gettext'
143 -extended syntax for `LANG' would break proper localization of already
144 -available operating system programs. In this case, users should set
145 -both `LANGUAGE' and `LANG' variables in their environment, as programs
146 -using GNU `gettext' give preference to `LANGUAGE'. For example, some
147 -Swedish users would rather read translations in German than English for
148 -when Swedish is not available. This is easily accomplished by setting
149 -`LANGUAGE' to `sv:de' while leaving `LANG' to `sv'.
150 + You might think that the country code specification is redundant.
151 +But in fact, some languages have dialects in different countries. For
152 +example, `de_AT' is used for Austria, and `pt_BR' for Brazil. The
153 +country code serves to distinguish the dialects.
155 + The locale naming convention of `LL_CC', with `LL' denoting the
156 +language and `CC' denoting the country, is the one use on systems based
157 +on GNU libc. On other systems, some variations of this scheme are
158 +used, such as `LL' or `LL_CC.ENCODING'. You can get the list of
159 +locales supported by your system for your country by running the command
160 +`locale -a | grep '^LL''.
162 + Not all programs have translations for all languages. By default, an
163 +English message is shown in place of a nonexistent translation. If you
164 +understand other languages, you can set up a priority list of languages.
165 +This is done through a different environment variable, called
166 +`LANGUAGE'. GNU `gettext' gives preference to `LANGUAGE' over `LANG'
167 +for the purpose of message handling, but you still need to have `LANG'
168 +set to the primary language; this is required by other parts of the
169 +system libraries. For example, some Swedish users who would rather
170 +read translations in German than English for when Swedish is not
171 +available, set `LANGUAGE' to `sv:de' while leaving `LANG' to `sv_SE'.
173 + Special advice for Norwegian users: The language code for Norwegian
174 +bokma*l changed from `no' to `nb' recently (in 2003). During the
175 +transition period, while some message catalogs for this language are
176 +installed under `nb' and some older ones under `no', it's recommended
177 +for Norwegian users to set `LANGUAGE' to `nb:no' so that both newer and
178 +older translations are used.
180 + In the `LANGUAGE' environment variable, but not in the `LANG'
181 +environment variable, `LL_CC' combinations can be abbreviated as `LL'
182 +to denote the language's main dialect. For example, `de' is equivalent
183 +to `de_DE' (German as spoken in Germany), and `pt' to `pt_PT'
184 +(Portuguese as spoken in Portugal) in this context.
189 - For the Free Translation Project to be a success, we need interested
190 +For the Free Translation Project to be a success, we need interested
191 people who like their own language and write it well, and who are also
192 able to synergize with other translators speaking the same language.
193 -Each translation team has its own mailing list, courtesy of Linux
194 -International. You may reach your translation team at the address
195 -`LL@li.org', replacing LL by the two-letter ISO 639 code for your
196 -language. Language codes are *not* the same as the country codes given
197 -in ISO 3166. The following translation teams exist, as of August 1997:
199 - Chinese `zh', Czech `cs', Danish `da', Dutch `nl', English `en',
200 - Esperanto `eo', Finnish `fi', French `fr', German `de', Hungarian
201 - `hu', Irish `ga', Italian `it', Indonesian `id', Japanese `ja',
202 - Korean `ko', Latin `la', Norwegian `no', Persian `fa', Polish
203 - `pl', Portuguese `pt', Russian `ru', Slovenian `sl', Spanish `es',
204 - Swedish `sv', and Turkish `tr'.
206 -For example, you may reach the Chinese translation team by writing to
208 +Each translation team has its own mailing list. The up-to-date list of
209 +teams can be found at the Free Translation Project's homepage,
210 +`http://www.iro.umontreal.ca/contrib/po/HTML/', in the "National teams"
213 - If you'd like to volunteer to *work* at translating messages, you
214 + If you'd like to volunteer to _work_ at translating messages, you
215 should become a member of the translating team for your own language.
216 -The subscribing address is *not* the same as the list itself, it has
217 +The subscribing address is _not_ the same as the list itself, it has
218 `-request' appended. For example, speakers of Swedish can send a
219 message to `sv-request@li.org', having this message body:
223 Keep in mind that team members are expected to participate
224 -*actively* in translations, or at solving translational difficulties,
225 +_actively_ in translations, or at solving translational difficulties,
226 rather than merely lurking around. If your team does not exist yet and
227 you want to start one, or if you are unsure about what to do or how to
228 get started, please write to `translation@iro.umontreal.ca' to reach the
229 @@ -171,43 +177,559 @@
233 - Languages are not equally supported in all packages. The following
234 -matrix shows the current state of internationalization, as of August
235 -1997. The matrix shows, in regard of each package, for which languages
236 -PO files have been submitted to translation coordination.
237 +Languages are not equally supported in all packages. The following
238 +matrix shows the current state of internationalization, as of January
239 +2004. The matrix shows, in regard of each package, for which languages
240 +PO files have been submitted to translation coordination, with a
241 +translation percentage of at least 50%.
243 - Ready PO files cs da de en es fi fr it ja ko nl no pl pt sl sv
244 - .-------------------------------------------------.
245 - bash | [] [] [] | 3
246 - bison | [] [] [] | 3
247 - clisp | [] [] [] [] | 4
248 - cpio | [] [] [] [] [] | 5
249 - diffutils | [] [] [] [] [] | 5
250 - enscript | [] [] [] [] [] [] | 6
251 - fileutils | [] [] [] [] [] [] [] [] [] [] | 10
252 - findutils | [] [] [] [] [] [] [] [] | 8
253 - flex | [] [] [] [] | 4
254 - gcal | [] [] [] [] [] | 5
255 - gettext | [] [] [] [] [] [] [] [] [] [] | 11
256 - grep | [] [] [] [] [] [] [] [] [] | 9
257 - hello | [] [] [] [] [] [] [] [] [] [] | 10
258 - id-utils | [] [] [] | 3
259 - indent | [] [] [] [] | 4
260 - libc | [] [] [] [] [] [] [] | 7
261 - m4 | [] [] [] [] [] | 5
262 - make | [] [] [] [] [] [] | 6
264 - ptx | [] [] [] [] [] [] [] [] | 8
265 - recode | [] [] [] [] [] [] [] [] [] | 9
266 - sh-utils | [] [] [] [] [] [] [] | 7
267 - sharutils | [] [] [] [] [] | 5
268 - tar | [] [] [] [] [] [] [] [] [] [] | 10
270 - textutils | [] [] [] [] [] [] [] [] [] | 9
271 - wdiff | [] [] [] [] [] [] [] [] | 8
272 - `-------------------------------------------------'
273 - 16 languages cs da de en es fi fr it ja ko nl no pl pt sl sv
274 - 27 packages 3 2 24 1 17 1 26 2 1 11 20 9 19 7 7 17 167
275 + Ready PO files af am ar az be bg bs ca cs da de el en en_GB eo es
276 + +----------------------------------------------------+
277 + a2ps | [] [] [] [] |
283 + bash | [] [] [] [] |
288 + bluez-pin | [] [] [] |
291 + console-tools | [] [] |
292 + coreutils | [] [] [] [] |
294 + darkstat | [] () [] |
295 + diffutils | [] [] [] [] [] [] [] |
296 + e2fsprogs | [] [] [] |
297 + enscript | [] [] [] [] |
298 + error | [] [] [] [] [] |
299 + fetchmail | [] () [] [] [] [] |
300 + fileutils | [] [] [] |
301 + findutils | [] [] [] [] [] [] [] |
302 + flex | [] [] [] [] |
305 + gawk | [] [] [] [] |
309 + gettext | [] [] [] [] [] |
310 + gettext-examples | [] [] [] [] |
311 + gettext-runtime | [] [] [] [] [] |
312 + gettext-tools | [] [] [] |
313 + gimp-print | [] [] [] [] [] |
315 + glunarclock | [] [] |
317 + gnucash | [] () [] [] |
318 + gnucash-glossary | [] () [] |
319 + gnupg | [] () [] [] [] [] |
322 + gpe-calendar | [] [] |
323 + gpe-clock | [] [] |
325 + gpe-contacts | [] [] |
328 + gpe-login | [] [] |
329 + gpe-ownerinfo | [] [] |
330 + gpe-sketchbook | [] [] |
332 + gpe-taskmanager | [] [] |
333 + gpe-timesheet | [] |
334 + gpe-today | [] [] |
336 + gphoto2 | [] [] [] [] |
338 + gpsdrive | () () () |
340 + grep | [] [] [] [] [] [] |
343 + hello | [] [] [] [] [] [] |
345 + indent | [] [] [] [] |
346 + iso_3166 | [] [] [] [] [] [] [] [] [] [] |
347 + iso_3166_1 | [] [] [] [] [] [] |
350 + iso_4217 | [] [] [] [] |
352 + jpilot | [] [] [] |
355 + kbd | [] [] [] [] [] |
358 + libc | [] [] [] [] [] [] |
359 + libgpewidget | [] [] |
360 + libiconv | [] [] [] [] [] |
361 + lifelines | [] () |
364 + lingoteach_lessons | () () |
365 + lynx | [] [] [] [] |
367 + mailutils | [] [] |
369 + man-db | [] () [] [] () |
370 + minicom | [] [] [] |
371 + mysecretdiary | [] [] [] |
372 + nano | [] () [] [] [] |
373 + nano_1_0 | [] () [] [] [] |
375 + parted | [] [] [] [] [] |
376 + ptx | [] [] [] [] [] |
379 + recode | [] [] [] [] [] [] [] |
382 + scrollkeeper | [] [] [] [] [] [] |
383 + sed | [] [] [] [] [] [] |
384 + sh-utils | [] [] [] |
385 + shared-mime-info | |
386 + sharutils | [] [] [] [] [] [] |
388 + skencil | [] () [] |
389 + sketch | [] () [] |
390 + soundtracker | [] [] [] |
392 + tar | [] [] [] [] |
393 + texinfo | [] [] [] |
394 + textutils | [] [] [] [] |
397 + tuxpaint | [] [] [] [] [] [] [] |
398 + unicode-han-tra... | |
399 + unicode-transla... | |
400 + util-linux | [] [] [] [] [] |
401 + vorbis-tools | [] [] [] [] |
403 + wdiff | [] [] [] [] |
404 + wget | [] [] [] [] [] [] |
405 + xchat | [] [] [] [] |
406 + xfree86_xkb_xml | [] [] |
408 + +----------------------------------------------------+
409 + af am ar az be bg bs ca cs da de el en en_GB eo es
410 + 4 0 0 1 9 4 1 40 41 60 78 17 1 5 13 68
412 + et eu fa fi fr ga gl he hr hu id is it ja ko lg
413 + +-------------------------------------------------+
414 + a2ps | [] [] [] () () |
421 + batchelor | [] [] |
424 + bison | [] [] [] [] |
425 + bluez-pin | [] [] [] [] [] |
429 + coreutils | [] [] [] [] [] [] |
430 + cpio | [] [] [] [] |
431 + darkstat | () [] [] [] |
432 + diffutils | [] [] [] [] [] [] [] |
435 + error | [] [] [] [] |
437 + fileutils | [] [] [] [] [] [] |
438 + findutils | [] [] [] [] [] [] [] [] [] [] [] |
446 + gettext | [] [] [] |
447 + gettext-examples | [] [] |
448 + gettext-runtime | [] [] [] [] [] |
449 + gettext-tools | [] [] [] |
450 + gimp-print | [] [] |
452 + glunarclock | [] [] [] [] |
455 + gnucash-glossary | [] |
456 + gnupg | [] [] [] [] [] [] [] |
459 + gpe-calendar | [] [] [] |
462 + gpe-contacts | [] [] |
465 + gpe-login | [] [] |
466 + gpe-ownerinfo | [] [] [] |
467 + gpe-sketchbook | [] |
469 + gpe-taskmanager | [] |
470 + gpe-timesheet | [] [] [] |
471 + gpe-today | [] [] |
473 + gphoto2 | [] [] [] |
475 + gpsdrive | () () () |
476 + gramadoir | [] [] |
477 + grep | [] [] [] [] [] [] [] [] [] [] [] |
480 + hello | [] [] [] [] [] [] [] [] [] [] [] [] [] |
481 + id-utils | [] [] [] [] |
482 + indent | [] [] [] [] [] [] [] [] [] |
483 + iso_3166 | [] [] [] [] [] [] [] |
484 + iso_3166_1 | [] [] [] [] [] |
487 + iso_4217 | [] [] [] [] [] [] |
491 + jwhois | [] [] [] [] |
495 + libc | [] [] [] [] [] [] |
496 + libgpewidget | [] [] [] [] |
497 + libiconv | [] [] [] [] [] [] [] [] [] |
500 + lingoteach | [] [] |
501 + lingoteach_lessons | |
502 + lynx | [] [] [] [] |
505 + make | [] [] [] [] [] [] |
507 + minicom | [] [] [] [] |
508 + mysecretdiary | [] [] |
509 + nano | [] [] [] [] |
510 + nano_1_0 | [] [] [] [] |
512 + parted | [] [] [] |
513 + ptx | [] [] [] [] [] [] [] |
516 + recode | [] [] [] [] [] [] |
519 + scrollkeeper | [] |
520 + sed | [] [] [] [] [] [] [] [] [] |
521 + sh-utils | [] [] [] [] [] [] [] |
522 + shared-mime-info | [] [] [] |
523 + sharutils | [] [] [] [] [] |
524 + silky | () [] () () |
527 + soundtracker | [] [] |
529 + tar | [] [] [] [] [] [] [] [] [] |
530 + texinfo | [] [] [] [] |
531 + textutils | [] [] [] [] [] [] |
534 + tuxpaint | [] [] [] [] [] [] [] [] [] |
535 + unicode-han-tra... | |
536 + unicode-transla... | [] [] |
537 + util-linux | [] [] [] [] () [] |
538 + vorbis-tools | [] |
540 + wdiff | [] [] [] [] [] [] |
541 + wget | [] [] [] [] [] [] [] |
543 + xfree86_xkb_xml | [] [] |
545 + +-------------------------------------------------+
546 + et eu fa fi fr ga gl he hr hu id is it ja ko lg
547 + 22 2 1 26 106 28 24 8 10 41 33 1 26 33 12 0
549 + lt lv mk mn ms mt nb nl nn no nso pl pt pt_BR ro ru
550 + +-----------------------------------------------------+
551 + a2ps | [] [] () () [] [] [] |
553 + ant-phone | [] [] |
554 + anubis | [] [] [] [] [] [] |
555 + ap-utils | [] () [] |
561 + bison | [] [] [] [] [] |
562 + bluez-pin | [] [] [] |
565 + console-tools | [] |
566 + coreutils | [] [] |
567 + cpio | [] [] [] [] [] |
568 + darkstat | [] [] [] [] |
569 + diffutils | [] [] [] [] [] [] |
571 + enscript | [] [] [] [] |
573 + fetchmail | [] [] () [] |
574 + fileutils | [] [] [] |
575 + findutils | [] [] [] [] [] |
576 + flex | [] [] [] [] |
583 + gettext | [] [] [] |
584 + gettext-examples | [] [] [] |
585 + gettext-runtime | [] [] [] [] |
586 + gettext-tools | [] [] |
589 + glunarclock | [] [] [] [] |
591 + gnucash | [] [] () [] |
592 + gnucash-glossary | [] [] |
594 + gpe-aerial | [] [] [] [] |
595 + gpe-beam | [] [] [] [] |
596 + gpe-calendar | [] [] [] [] |
597 + gpe-clock | [] [] [] [] |
598 + gpe-conf | [] [] [] [] |
599 + gpe-contacts | [] [] [] [] |
600 + gpe-edit | [] [] [] [] |
601 + gpe-go | [] [] [] |
602 + gpe-login | [] [] [] [] |
603 + gpe-ownerinfo | [] [] [] [] |
604 + gpe-sketchbook | [] [] [] [] |
605 + gpe-su | [] [] [] [] |
606 + gpe-taskmanager | [] [] [] [] |
607 + gpe-timesheet | [] [] [] [] |
608 + gpe-today | [] [] [] [] |
609 + gpe-todo | [] [] [] [] |
612 + gpsdrive | () () [] |
613 + gramadoir | () [] |
614 + grep | [] [] [] [] [] |
617 + hello | [] [] [] [] [] [] [] [] [] [] |
618 + id-utils | [] [] [] [] |
619 + indent | [] [] [] [] |
620 + iso_3166 | [] [] [] |
621 + iso_3166_1 | [] [] |
624 + iso_4217 | [] [] [] [] [] [] [] [] |
628 + jwhois | [] [] [] [] () |
632 + libc | [] [] [] [] |
633 + libgpewidget | [] [] [] |
634 + libiconv | [] [] [] [] [] |
638 + lingoteach_lessons | |
640 + m4 | [] [] [] [] [] |
641 + mailutils | [] [] [] |
642 + make | [] [] [] [] |
644 + minicom | [] [] [] [] |
645 + mysecretdiary | [] [] [] |
646 + nano | [] [] [] [] [] |
647 + nano_1_0 | [] [] [] [] [] [] |
649 + parted | [] [] [] [] |
650 + ptx | [] [] [] [] [] [] [] [] |
653 + recode | [] [] [] [] |
656 + scrollkeeper | [] [] [] [] [] |
659 + shared-mime-info | [] [] |
660 + sharutils | [] [] |
666 + tar | [] [] [] [] [] [] |
667 + texinfo | [] [] [] [] |
668 + textutils | [] [] |
671 + tuxpaint | [] [] [] [] [] [] [] [] |
672 + unicode-han-tra... | |
673 + unicode-transla... | |
674 + util-linux | [] [] [] |
675 + vorbis-tools | [] [] [] |
677 + wdiff | [] [] [] [] [] |
680 + xfree86_xkb_xml | [] [] |
682 + +-----------------------------------------------------+
683 + lt lv mk mn ms mt nb nl nn no nso pl pt pt_BR ro ru
684 + 1 2 0 3 12 0 10 69 6 7 1 40 26 36 76 63
686 + sk sl sr sv ta th tr uk ven vi wa xh zh_CN zh_TW zu
687 + +-----------------------------------------------------+
688 + a2ps | [] [] [] [] | 16
697 + binutils | [] [] [] | 8
699 + bluez-pin | [] [] [] | 14
702 + console-tools | | 3
703 + coreutils | [] [] [] [] | 16
705 + darkstat | [] [] [] () () | 12
706 + diffutils | [] [] [] | 23
707 + e2fsprogs | [] [] | 6
708 + enscript | [] [] | 12
709 + error | [] [] [] | 15
710 + fetchmail | [] [] | 11
711 + fileutils | [] [] [] [] [] | 17
712 + findutils | [] [] [] [] [] [] | 29
720 + gettext | [] [] [] [] [] | 16
721 + gettext-examples | [] [] [] [] [] | 14
722 + gettext-runtime | [] [] [] [] [] [] [] [] | 22
723 + gettext-tools | [] [] [] [] [] [] | 14
724 + gimp-print | [] [] | 10
726 + glunarclock | [] [] [] | 13
728 + gnucash | [] [] | 9
729 + gnucash-glossary | [] [] [] | 8
730 + gnupg | [] [] [] [] | 17
731 + gpe-aerial | [] | 7
733 + gpe-calendar | [] [] [] [] | 13
734 + gpe-clock | [] [] [] | 10
735 + gpe-conf | [] [] | 9
736 + gpe-contacts | [] [] [] | 11
737 + gpe-edit | [] [] [] [] [] | 12
739 + gpe-login | [] [] [] [] [] | 13
740 + gpe-ownerinfo | [] [] [] [] | 13
741 + gpe-sketchbook | [] [] | 9
742 + gpe-su | [] [] [] | 10
743 + gpe-taskmanager | [] [] [] | 10
744 + gpe-timesheet | [] [] [] [] | 12
745 + gpe-today | [] [] [] [] [] | 13
746 + gpe-todo | [] [] [] [] | 12
747 + gphoto2 | [] [] [] | 11
749 + gpsdrive | [] [] | 3
751 + grep | [] [] [] [] | 26
754 + hello | [] [] [] [] [] | 34
755 + id-utils | [] [] | 12
756 + indent | [] [] [] [] | 21
757 + iso_3166 | [] [] [] [] [] [] [] | 27
758 + iso_3166_1 | [] [] [] | 16
761 + iso_4217 | [] [] [] [] [] [] | 24
763 + jpilot | [] [] [] [] [] | 9
765 + jwhois | () [] [] | 11
769 + libc | [] [] [] [] | 20
770 + libgpewidget | [] [] [] [] | 13
771 + libiconv | [] [] [] [] [] [] [] [] | 27
775 + lingoteach_lessons | () | 0
776 + lynx | [] [] [] | 14
779 + make | [] [] [] | 16
782 + mysecretdiary | [] [] | 10
783 + nano | [] [] [] [] | 17
784 + nano_1_0 | [] [] [] | 17
785 + opcodes | [] [] | 6
786 + parted | [] [] [] | 15
790 + recode | [] [] [] | 20
793 + scrollkeeper | [] [] [] | 15
794 + sed | [] [] [] [] [] [] | 24
795 + sh-utils | [] [] | 14
796 + shared-mime-info | [] [] | 7
797 + sharutils | [] [] [] [] | 17
801 + soundtracker | [] [] | 7
803 + tar | [] [] [] [] [] | 24
804 + texinfo | [] [] [] | 14
805 + textutils | [] [] [] [] | 16
808 + tuxpaint | [] [] [] [] [] | 29
809 + unicode-han-tra... | | 0
810 + unicode-transla... | | 2
811 + util-linux | [] [] | 15
814 + wdiff | [] [] [] | 18
815 + wget | [] [] [] [] [] [] [] [] | 24
816 + xchat | [] [] [] [] [] | 15
817 + xfree86_xkb_xml | [] [] [] [] [] | 11
819 + +-----------------------------------------------------+
820 + 63 teams sk sl sr sv ta th tr uk ven vi wa xh zh_CN zh_TW zu
821 + 131 domains 47 19 28 83 0 0 59 13 1 1 11 0 22 22 0 1373
823 Some counters in the preceding matrix are higher than the number of
824 visible blocks let us expect. This is because a few extra PO files are
826 lag between the mere existence a PO file and its wide availability in a
829 - If August 1997 seems to be old, you may fetch a more recent copy of
830 -this `ABOUT-NLS' file on most GNU archive sites.
831 + If January 2004 seems to be old, you may fetch a more recent copy of
832 +this `ABOUT-NLS' file on most GNU archive sites. The most up-to-date
833 +matrix with full percentage details can be found at
834 +`http://www.iro.umontreal.ca/contrib/po/HTML/matrix.html'.
836 +Using `gettext' in new packages
837 +===============================
839 +If you are writing a freely available program and want to
840 +internationalize it you are welcome to use GNU `gettext' in your
841 +package. Of course you have to respect the GNU Library General Public
842 +License which covers the use of the GNU `gettext' library. This means
843 +in particular that even non-free programs can use `libintl' as a shared
844 +library, whereas only free software can use `libintl' as a static
845 +library or use modified versions of `libintl'.
847 + Once the sources are changed appropriately and the setup can handle
848 +the use of `gettext' the only thing missing are the translations. The
849 +Free Translation Project is also available for packages which are not
850 +developed inside the GNU project. Therefore the information given above
851 +applies also for every other Free Software Project. Contact
852 +`translation@iro.umontreal.ca' to make the `.pot' files available to
853 +the translation teams.
855 --- lrzsz-0.12.20.safe/ChangeLog 1998-12-29 17:49:56.000000000 -0500
856 +++ lrzsz-0.12.20/ChangeLog 2004-09-12 14:40:35.846521456 -0400
858 +2004-09-12 gettextize <bug-gnu-gettext@gnu.org>
860 + * Makefile.am (ACLOCAL_AMFLAGS): New variable.
861 + (EXTRA_DIST): Add config.rpath.
862 + * configure.in (AC_OUTPUT): Add m4/Makefile.
863 + (AC_OUTPUT): Remove command that created po/Makefile.
864 + (AC_LINK_FILES): Remove invocation.
866 1998-12-29 Uwe Ohse <uwe@ohse.de>
868 * src/lrz.c: removed stpcpy call.
869 --- lrzsz-0.12.20.safe/config.rpath 1969-12-31 19:00:00.000000000 -0500
870 +++ lrzsz-0.12.20/config.rpath 2004-09-12 14:40:34.329752040 -0400
873 +# Output a system dependent set of variables, describing how to set the
874 +# run time search path of shared libraries in an executable.
876 +# Copyright 1996-2003 Free Software Foundation, Inc.
877 +# Taken from GNU libtool, 2001
878 +# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
880 +# This program is free software; you can redistribute it and/or modify
881 +# it under the terms of the GNU General Public License as published by
882 +# the Free Software Foundation; either version 2 of the License, or
883 +# (at your option) any later version.
885 +# This program is distributed in the hope that it will be useful, but
886 +# WITHOUT ANY WARRANTY; without even the implied warranty of
887 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
888 +# General Public License for more details.
890 +# You should have received a copy of the GNU General Public License
891 +# along with this program; if not, write to the Free Software
892 +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
894 +# As a special exception to the GNU General Public License, if you
895 +# distribute this file as part of a program that contains a
896 +# configuration script generated by Autoconf, you may include it under
897 +# the same distribution terms that you use for the rest of that program.
899 +# The first argument passed to this file is the canonical host specification,
900 +# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
902 +# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM
903 +# The environment variables CC, GCC, LDFLAGS, LD, with_gnu_ld
904 +# should be set by the caller.
906 +# The set of defined variables is at the end of this script.
908 +# Known limitations:
909 +# - On IRIX 6.5 with CC="cc", the run time search patch must not be longer
910 +# than 256 bytes, otherwise the compiler driver will dump core. The only
911 +# known workaround is to choose shorter directory names for the build
912 +# directory and/or the installation directory.
914 +# All known linkers require a `.a' archive for static linking (except M$VC,
915 +# which needs '.lib').
920 +host_cpu=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
921 +host_vendor=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
922 +host_os=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
924 +# Code taken from libtool.m4's AC_LIBTOOL_PROG_COMPILER_PIC.
927 +if test "$GCC" = yes; then
934 + mingw* | pw32* | os2*)
936 + hpux9* | hpux10* | hpux11*)
939 + irix5* | irix6* | nonstopux*)
954 + osf3* | osf4* | osf5*)
965 + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
975 +# Code taken from libtool.m4's AC_LIBTOOL_PROG_LD_SHLIBS.
977 +hardcode_libdir_flag_spec=
978 +hardcode_libdir_separator=
983 + cygwin* | mingw* | pw32*)
984 + # FIXME: the MSVC++ port hasn't been tested in a loooong time
985 + # When not using gcc, we currently assume that we are using
986 + # Microsoft Visual C++.
987 + if test "$GCC" != yes; then
997 +if test "$with_gnu_ld" = yes; then
999 + aix3* | aix4* | aix5*)
1000 + # On AIX/PPC, the GNU linker is very broken
1001 + if test "$host_cpu" != ia64; then
1006 + hardcode_libdir_flag_spec='-L$libdir'
1007 + hardcode_minus_L=yes
1008 + # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
1009 + # that the semantics of dynamic libraries on AmigaOS, at least up
1010 + # to version 4, is to share data among multiple programs linked
1011 + # with the same dynamic library. Since this doesn't match the
1012 + # behavior of shared libraries on other platforms, we can use
1017 + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
1023 + cygwin* | mingw* | pw32*)
1024 + # hardcode_libdir_flag_spec is actually meaningless, as there is
1025 + # no search path for DLLs.
1026 + hardcode_libdir_flag_spec='-L$libdir'
1027 + if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
1035 + solaris* | sysv5*)
1036 + if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
1038 + elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
1045 + hardcode_direct=yes
1048 + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
1055 + if test "$ld_shlibs" = yes; then
1056 + # Unlike libtool, we use -rpath here, not --rpath, since the documented
1057 + # option of GNU ld is called -rpath, not --rpath.
1058 + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
1061 + case "$host_os" in
1063 + # Note: this linker hardcodes the directories in LIBPATH if there
1064 + # are no directories specified by -L.
1065 + hardcode_minus_L=yes
1066 + if test "$GCC" = yes; then
1067 + # Neither direct hardcoding nor static linking is supported with a
1068 + # broken collect2.
1069 + hardcode_direct=unsupported
1073 + if test "$host_cpu" = ia64; then
1074 + # On IA64, the linker does run time linking by default, so we don't
1075 + # have to do anything special.
1076 + aix_use_runtimelinking=no
1078 + aix_use_runtimelinking=no
1079 + # Test if we are trying to use run time linking or normal
1080 + # AIX style linking. If -brtl is somewhere in LDFLAGS, we
1081 + # need to do runtime linking.
1082 + case $host_os in aix4.[23]|aix4.[23].*|aix5*)
1083 + for ld_flag in $LDFLAGS; do
1084 + if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
1085 + aix_use_runtimelinking=yes
1091 + hardcode_direct=yes
1092 + hardcode_libdir_separator=':'
1093 + if test "$GCC" = yes; then
1094 + case $host_os in aix4.[012]|aix4.[012].*)
1095 + collect2name=`${CC} -print-prog-name=collect2`
1096 + if test -f "$collect2name" && \
1097 + strings "$collect2name" | grep resolve_lib_name >/dev/null
1099 + # We have reworked collect2
1100 + hardcode_direct=yes
1102 + # We have old collect2
1103 + hardcode_direct=unsupported
1104 + hardcode_minus_L=yes
1105 + hardcode_libdir_flag_spec='-L$libdir'
1106 + hardcode_libdir_separator=
1110 + # Begin _LT_AC_SYS_LIBPATH_AIX.
1111 + echo 'int main () { return 0; }' > conftest.c
1112 + ${CC} ${LDFLAGS} conftest.c -o conftest
1113 + aix_libpath=`dump -H conftest 2>/dev/null | sed -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
1115 + if test -z "$aix_libpath"; then
1116 + aix_libpath=`dump -HX64 conftest 2>/dev/null | sed -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
1119 + if test -z "$aix_libpath"; then
1120 + aix_libpath="/usr/lib:/lib"
1122 + rm -f conftest.c conftest
1123 + # End _LT_AC_SYS_LIBPATH_AIX.
1124 + if test "$aix_use_runtimelinking" = yes; then
1125 + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
1127 + if test "$host_cpu" = ia64; then
1128 + hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
1130 + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
1135 + hardcode_libdir_flag_spec='-L$libdir'
1136 + hardcode_minus_L=yes
1137 + # see comment about different semantics on the GNU ld section
1142 + cygwin* | mingw* | pw32*)
1143 + # When not using gcc, we currently assume that we are using
1144 + # Microsoft Visual C++.
1145 + # hardcode_libdir_flag_spec is actually meaningless, as there is
1146 + # no search path for DLLs.
1147 + hardcode_libdir_flag_spec=' '
1150 + darwin* | rhapsody*)
1151 + if $CC -v 2>&1 | grep 'Apple' >/dev/null ; then
1152 + hardcode_direct=no
1156 + hardcode_libdir_flag_spec='-L$libdir'
1162 + hardcode_libdir_flag_spec='-R$libdir'
1163 + hardcode_direct=yes
1166 + hardcode_direct=yes
1167 + hardcode_minus_L=yes
1170 + hardcode_libdir_flag_spec='-R$libdir'
1171 + hardcode_direct=yes
1174 + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
1175 + hardcode_libdir_separator=:
1176 + hardcode_direct=yes
1177 + # hardcode_minus_L: Not really in the search PATH,
1178 + # but as the default location of the library.
1179 + hardcode_minus_L=yes
1181 + hpux10* | hpux11*)
1182 + if test "$with_gnu_ld" = no; then
1183 + case "$host_cpu" in
1185 + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
1186 + hardcode_libdir_separator=:
1187 + hardcode_direct=no
1190 + hardcode_libdir_flag_spec='-L$libdir'
1191 + hardcode_direct=no
1192 + # hardcode_minus_L: Not really in the search PATH,
1193 + # but as the default location of the library.
1194 + hardcode_minus_L=yes
1197 + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
1198 + hardcode_libdir_separator=:
1199 + hardcode_direct=yes
1200 + # hardcode_minus_L: Not really in the search PATH,
1201 + # but as the default location of the library.
1202 + hardcode_minus_L=yes
1207 + irix5* | irix6* | nonstopux*)
1208 + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
1209 + hardcode_libdir_separator=:
1212 + hardcode_libdir_flag_spec='-R$libdir'
1213 + hardcode_direct=yes
1216 + hardcode_direct=yes
1217 + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
1218 + hardcode_libdir_separator=:
1221 + hardcode_direct=yes
1222 + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
1223 + hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
1225 + case "$host_os" in
1226 + openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
1227 + hardcode_libdir_flag_spec='-R$libdir'
1230 + hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
1236 + hardcode_libdir_flag_spec='-L$libdir'
1237 + hardcode_minus_L=yes
1240 + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
1241 + hardcode_libdir_separator=:
1244 + if test "$GCC" = yes; then
1245 + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
1247 + # Both cc and cxx compiler support -rpath directly
1248 + hardcode_libdir_flag_spec='-rpath $libdir'
1250 + hardcode_libdir_separator=:
1255 + hardcode_libdir_flag_spec='-R$libdir'
1258 + hardcode_libdir_flag_spec='-L$libdir'
1259 + hardcode_direct=yes
1260 + hardcode_minus_L=yes
1263 + case $host_vendor in
1265 + hardcode_direct=yes # is this really true???
1268 + hardcode_direct=no
1271 + hardcode_direct=no #Motorola manual says yes, but my tests say they lie
1278 + if test -d /usr/nec; then
1283 + hardcode_direct=yes
1284 + hardcode_minus_L=no
1286 + sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*)
1289 + hardcode_libdir_flag_spec=
1292 + hardcode_libdir_flag_spec='-L$libdir'
1300 +# Check dynamic linker characteristics
1301 +# Code taken from libtool.m4's AC_LIBTOOL_SYS_DYNAMIC_LINKER.
1302 +libname_spec='lib$name'
1314 + cygwin* | mingw* | pw32*)
1317 + darwin* | rhapsody*)
1328 + hpux9* | hpux10* | hpux11*)
1329 + case "$host_cpu" in
1341 + irix5* | irix6* | nonstopux*)
1342 + case "$host_os" in
1343 + irix5* | nonstopux*)
1344 + libsuff= shlibsuff=
1348 + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= ;;
1349 + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 ;;
1350 + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 ;;
1351 + *) libsuff= shlibsuff= ;;
1356 + linux*oldld* | linux*aout* | linux*coff*)
1369 + libname_spec='$name'
1372 + osf3* | osf4* | osf5*)
1380 + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
1388 +sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
1389 +escaped_wl=`echo "X$wl" | sed -e 's/^X//' -e "$sed_quote_subst"`
1390 +shlibext=`echo "$shrext" | sed -e 's,^\.,,'`
1391 +escaped_hardcode_libdir_flag_spec=`echo "X$hardcode_libdir_flag_spec" | sed -e 's/^X//' -e "$sed_quote_subst"`
1393 +sed -e 's/^\([a-zA-Z0-9_]*\)=/acl_cv_\1=/' <<EOF
1395 +# How to pass a linker flag through the compiler.
1398 +# Static library suffix (normally "a").
1401 +# Shared library suffix (normally "so").
1402 +shlibext="$shlibext"
1404 +# Flag to hardcode \$libdir into a binary during linking.
1405 +# This must work even if \$libdir does not exist.
1406 +hardcode_libdir_flag_spec="$escaped_hardcode_libdir_flag_spec"
1408 +# Whether we need a single -rpath flag with a separated argument.
1409 +hardcode_libdir_separator="$hardcode_libdir_separator"
1411 +# Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the
1412 +# resulting binary.
1413 +hardcode_direct="$hardcode_direct"
1415 +# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
1416 +# resulting binary.
1417 +hardcode_minus_L="$hardcode_minus_L"
1420 --- lrzsz-0.12.20.safe/configure.in 2004-09-12 14:39:55.161706488 -0400
1421 +++ lrzsz-0.12.20/configure.in 2004-09-12 14:40:35.816526016 -0400
1422 @@ -260,11 +260,10 @@
1425 AC_DEFINE_UNQUOTED(LOCALEDIR,"$prefix/$DATADIRNAME")
1426 -AC_LINK_FILES($nls_cv_header_libgt, $nls_cv_header_intl)
1428 -AC_OUTPUT([Makefile intl/Makefile lib/Makefile testsuite/Makefile \
1429 +AC_OUTPUT([Makefile intl/Makefile lib/Makefile testsuite/Makefile m4/Makefile \
1430 man/Makefile po/Makefile.in src/Makefile debian/rules Specfile systype \
1432 -[sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile;
1434 chmod +x debian/rules;
1435 test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h])
1436 --- lrzsz-0.12.20.safe/intl/bindtextdom.c 1998-04-26 09:22:36.000000000 -0400
1437 +++ lrzsz-0.12.20/intl/bindtextdom.c 2004-09-12 14:40:34.343749912 -0400
1439 /* Implementation of the bindtextdomain(3) function
1440 - Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
1441 + Copyright (C) 1995-1998, 2000-2003 Free Software Foundation, Inc.
1443 - This program is free software; you can redistribute it and/or modify
1444 - it under the terms of the GNU General Public License as published by
1445 - the Free Software Foundation; either version 2, or (at your option)
1446 + This program is free software; you can redistribute it and/or modify it
1447 + under the terms of the GNU Library General Public License as published
1448 + by the Free Software Foundation; either version 2, or (at your option)
1451 This program is distributed in the hope that it will be useful,
1452 but WITHOUT ANY WARRANTY; without even the implied warranty of
1453 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1454 - GNU General Public License for more details.
1455 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
1456 + Library General Public License for more details.
1458 - You should have received a copy of the GNU General Public License
1459 - along with this program; if not, write to the Free Software Foundation,
1460 - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
1461 + You should have received a copy of the GNU Library General Public
1462 + License along with this program; if not, write to the Free Software
1463 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
1466 #ifdef HAVE_CONFIG_H
1467 # include <config.h>
1470 -#if defined STDC_HEADERS || defined _LIBC
1471 -# include <stdlib.h>
1473 -# ifdef HAVE_MALLOC_H
1474 -# include <malloc.h>
1479 +#include <stddef.h>
1480 +#include <stdlib.h>
1481 +#include <string.h>
1483 -#if defined HAVE_STRING_H || defined _LIBC
1484 -# include <string.h>
1486 +# include <libintl.h>
1488 -# include <strings.h>
1490 -# define memcpy(Dst, Src, Num) bcopy (Src, Dst, Num)
1492 +# include "libgnuintl.h"
1494 +#include "gettextP.h"
1497 -# include <libintl.h>
1498 +/* We have to handle multi-threaded applications. */
1499 +# include <bits/libc-lock.h>
1501 -# include "libgettext.h"
1502 +/* Provide dummy implementation if this is outside glibc. */
1503 +# define __libc_rwlock_define(CLASS, NAME)
1504 +# define __libc_rwlock_wrlock(NAME)
1505 +# define __libc_rwlock_unlock(NAME)
1508 +/* The internal variables in the standalone libintl.a must have different
1509 + names than the internal variables in GNU libc, otherwise programs
1510 + using libintl.a cannot be linked statically. */
1512 +# define _nl_default_dirname libintl_nl_default_dirname
1513 +# define _nl_domain_bindings libintl_nl_domain_bindings
1516 +/* Some compilers, like SunOS4 cc, don't have offsetof in <stddef.h>. */
1518 +# define offsetof(type,ident) ((size_t)&(((type*)0)->ident))
1520 -#include "gettext.h"
1521 -#include "gettextP.h"
1523 /* @@ end of prolog @@ */
1525 /* Contains the default location of the message catalogs. */
1526 extern const char _nl_default_dirname[];
1528 +extern const char _nl_default_dirname_internal[] attribute_hidden;
1530 +# define INTUSE(name) name
1533 /* List with bindings of specific domains. */
1534 extern struct binding *_nl_domain_bindings;
1536 +/* Lock variable to protect the global data in the gettext implementation. */
1537 +__libc_rwlock_define (extern, _nl_state_lock attribute_hidden)
1540 /* Names for the libintl functions are a problem. They must not clash
1541 with existing names and they should follow ANSI C. But this source
1543 prefix. So we have to make a difference here. */
1545 # define BINDTEXTDOMAIN __bindtextdomain
1546 -# define strdup(str) __strdup (str)
1547 +# define BIND_TEXTDOMAIN_CODESET __bind_textdomain_codeset
1549 +# define strdup(str) __strdup (str)
1552 -# define BINDTEXTDOMAIN bindtextdomain__
1553 +# define BINDTEXTDOMAIN libintl_bindtextdomain
1554 +# define BIND_TEXTDOMAIN_CODESET libintl_bind_textdomain_codeset
1557 -/* Specify that the DOMAINNAME message catalog will be found
1558 - in DIRNAME rather than in the system locale data base. */
1560 -BINDTEXTDOMAIN (domainname, dirname)
1561 - const char *domainname;
1562 - const char *dirname;
1563 +/* Specifies the directory name *DIRNAMEP and the output codeset *CODESETP
1564 + to be used for the DOMAINNAME message catalog.
1565 + If *DIRNAMEP or *CODESETP is NULL, the corresponding attribute is not
1566 + modified, only the current value is returned.
1567 + If DIRNAMEP or CODESETP is NULL, the corresponding attribute is neither
1568 + modified nor returned. */
1570 +set_binding_values (const char *domainname,
1571 + const char **dirnamep, const char **codesetp)
1573 struct binding *binding;
1576 /* Some sanity checks. */
1577 if (domainname == NULL || domainname[0] == '\0')
1587 + __libc_rwlock_wrlock (_nl_state_lock);
1591 for (binding = _nl_domain_bindings; binding != NULL; binding = binding->next)
1593 @@ -93,81 +127,173 @@
1597 - if (dirname == NULL)
1598 - /* The current binding has be to returned. */
1599 - return binding == NULL ? (char *) _nl_default_dirname : binding->dirname;
1601 if (binding != NULL)
1603 - /* The domain is already bound. If the new value and the old
1604 - one are equal we simply do nothing. Otherwise replace the
1606 - if (strcmp (dirname, binding->dirname) != 0)
1609 - char *new_dirname;
1610 + const char *dirname = *dirnamep;
1612 - if (strcmp (dirname, _nl_default_dirname) == 0)
1613 - new_dirname = (char *) _nl_default_dirname;
1614 + if (dirname == NULL)
1615 + /* The current binding has be to returned. */
1616 + *dirnamep = binding->dirname;
1619 + /* The domain is already bound. If the new value and the old
1620 + one are equal we simply do nothing. Otherwise replace the
1622 + char *result = binding->dirname;
1623 + if (strcmp (dirname, result) != 0)
1625 + if (strcmp (dirname, INTUSE(_nl_default_dirname)) == 0)
1626 + result = (char *) INTUSE(_nl_default_dirname);
1629 #if defined _LIBC || defined HAVE_STRDUP
1630 - new_dirname = strdup (dirname);
1631 - if (new_dirname == NULL)
1633 + result = strdup (dirname);
1635 - size_t len = strlen (dirname) + 1;
1636 - new_dirname = (char *) malloc (len);
1637 - if (new_dirname == NULL)
1640 - memcpy (new_dirname, dirname, len);
1641 + size_t len = strlen (dirname) + 1;
1642 + result = (char *) malloc (len);
1643 + if (__builtin_expect (result != NULL, 1))
1644 + memcpy (result, dirname, len);
1648 + if (__builtin_expect (result != NULL, 1))
1650 + if (binding->dirname != INTUSE(_nl_default_dirname))
1651 + free (binding->dirname);
1653 + binding->dirname = result;
1657 + *dirnamep = result;
1661 - if (binding->dirname != _nl_default_dirname)
1662 - free (binding->dirname);
1665 + const char *codeset = *codesetp;
1667 - binding->dirname = new_dirname;
1668 + if (codeset == NULL)
1669 + /* The current binding has be to returned. */
1670 + *codesetp = binding->codeset;
1673 + /* The domain is already bound. If the new value and the old
1674 + one are equal we simply do nothing. Otherwise replace the
1676 + char *result = binding->codeset;
1677 + if (result == NULL || strcmp (codeset, result) != 0)
1679 +#if defined _LIBC || defined HAVE_STRDUP
1680 + result = strdup (codeset);
1682 + size_t len = strlen (codeset) + 1;
1683 + result = (char *) malloc (len);
1684 + if (__builtin_expect (result != NULL, 1))
1685 + memcpy (result, codeset, len);
1688 + if (__builtin_expect (result != NULL, 1))
1690 + if (binding->codeset != NULL)
1691 + free (binding->codeset);
1693 + binding->codeset = result;
1694 + binding->codeset_cntr++;
1698 + *codesetp = result;
1702 + else if ((dirnamep == NULL || *dirnamep == NULL)
1703 + && (codesetp == NULL || *codesetp == NULL))
1705 + /* Simply return the default values. */
1707 + *dirnamep = INTUSE(_nl_default_dirname);
1713 /* We have to create a new binding. */
1715 + size_t len = strlen (domainname) + 1;
1716 struct binding *new_binding =
1717 - (struct binding *) malloc (sizeof (*new_binding));
1718 + (struct binding *) malloc (offsetof (struct binding, domainname) + len);
1720 - if (new_binding == NULL)
1722 + if (__builtin_expect (new_binding == NULL, 0))
1725 + memcpy (new_binding->domainname, domainname, len);
1729 + const char *dirname = *dirnamep;
1731 + if (dirname == NULL)
1732 + /* The default value. */
1733 + dirname = INTUSE(_nl_default_dirname);
1736 + if (strcmp (dirname, INTUSE(_nl_default_dirname)) == 0)
1737 + dirname = INTUSE(_nl_default_dirname);
1741 #if defined _LIBC || defined HAVE_STRDUP
1742 - new_binding->domainname = strdup (domainname);
1743 - if (new_binding->domainname == NULL)
1745 + result = strdup (dirname);
1746 + if (__builtin_expect (result == NULL, 0))
1747 + goto failed_dirname;
1749 - len = strlen (domainname) + 1;
1750 - new_binding->domainname = (char *) malloc (len);
1751 - if (new_binding->domainname == NULL)
1753 - memcpy (new_binding->domainname, domainname, len);
1754 + size_t len = strlen (dirname) + 1;
1755 + result = (char *) malloc (len);
1756 + if (__builtin_expect (result == NULL, 0))
1757 + goto failed_dirname;
1758 + memcpy (result, dirname, len);
1761 - if (strcmp (dirname, _nl_default_dirname) == 0)
1762 - new_binding->dirname = (char *) _nl_default_dirname;
1766 + *dirnamep = dirname;
1767 + new_binding->dirname = (char *) dirname;
1770 + /* The default value. */
1771 + new_binding->dirname = (char *) INTUSE(_nl_default_dirname);
1773 + new_binding->codeset_cntr = 0;
1777 + const char *codeset = *codesetp;
1779 + if (codeset != NULL)
1783 #if defined _LIBC || defined HAVE_STRDUP
1784 - new_binding->dirname = strdup (dirname);
1785 - if (new_binding->dirname == NULL)
1787 + result = strdup (codeset);
1788 + if (__builtin_expect (result == NULL, 0))
1789 + goto failed_codeset;
1791 - len = strlen (dirname) + 1;
1792 - new_binding->dirname = (char *) malloc (len);
1793 - if (new_binding->dirname == NULL)
1795 - memcpy (new_binding->dirname, dirname, len);
1796 + size_t len = strlen (codeset) + 1;
1797 + result = (char *) malloc (len);
1798 + if (__builtin_expect (result == NULL, 0))
1799 + goto failed_codeset;
1800 + memcpy (result, codeset, len);
1803 + new_binding->codeset_cntr++;
1805 + *codesetp = codeset;
1806 + new_binding->codeset = (char *) codeset;
1809 + new_binding->codeset = NULL;
1811 /* Now enqueue it. */
1812 if (_nl_domain_bindings == NULL
1813 @@ -187,13 +313,51 @@
1814 binding->next = new_binding;
1817 - binding = new_binding;
1820 + /* Here we deal with memory allocation failures. */
1824 + if (new_binding->dirname != INTUSE(_nl_default_dirname))
1825 + free (new_binding->dirname);
1827 + free (new_binding);
1836 - return binding->dirname;
1837 + /* If we modified any binding, we flush the caches. */
1839 + ++_nl_msg_cat_cntr;
1841 + __libc_rwlock_unlock (_nl_state_lock);
1844 +/* Specify that the DOMAINNAME message catalog will be found
1845 + in DIRNAME rather than in the system locale data base. */
1847 +BINDTEXTDOMAIN (const char *domainname, const char *dirname)
1849 + set_binding_values (domainname, &dirname, NULL);
1850 + return (char *) dirname;
1853 +/* Specify the character encoding in which the messages from the
1854 + DOMAINNAME message catalog will be returned. */
1856 +BIND_TEXTDOMAIN_CODESET (const char *domainname, const char *codeset)
1858 + set_binding_values (domainname, NULL, &codeset);
1859 + return (char *) codeset;
1863 -/* Alias for function name in GNU C Library. */
1864 +/* Aliases for function names in GNU C Library. */
1865 weak_alias (__bindtextdomain, bindtextdomain);
1866 +weak_alias (__bind_textdomain_codeset, bind_textdomain_codeset);
1868 --- lrzsz-0.12.20.safe/intl/cat-compat.c 1998-04-26 09:22:37.000000000 -0400
1869 +++ lrzsz-0.12.20/intl/cat-compat.c 1969-12-31 19:00:00.000000000 -0500
1871 -/* Compatibility code for gettext-using-catgets interface.
1872 - Copyright (C) 1995, 1997 Free Software Foundation, Inc.
1874 - This program is free software; you can redistribute it and/or modify
1875 - it under the terms of the GNU General Public License as published by
1876 - the Free Software Foundation; either version 2, or (at your option)
1877 - any later version.
1879 - This program is distributed in the hope that it will be useful,
1880 - but WITHOUT ANY WARRANTY; without even the implied warranty of
1881 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1882 - GNU General Public License for more details.
1884 - You should have received a copy of the GNU General Public License
1885 - along with this program; if not, write to the Free Software Foundation,
1886 - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
1888 -#ifdef HAVE_CONFIG_H
1889 -# include <config.h>
1894 -#ifdef STDC_HEADERS
1895 -# include <stdlib.h>
1896 -# include <string.h>
1899 -# ifdef HAVE_MALLOC_H
1900 -# include <malloc.h>
1904 -#ifdef HAVE_NL_TYPES_H
1905 -# include <nl_types.h>
1908 -#include "libgettext.h"
1910 -/* @@ end of prolog @@ */
1912 -/* XPG3 defines the result of `setlocale (category, NULL)' as:
1913 - ``Directs `setlocale()' to query `category' and return the current
1914 - setting of `local'.''
1915 - However it does not specify the exact format. And even worse: POSIX
1916 - defines this not at all. So we can use this feature only on selected
1917 - system (e.g. those using GNU C Library). */
1919 -# define HAVE_LOCALE_NULL
1922 -/* The catalog descriptor. */
1923 -static nl_catd catalog = (nl_catd) -1;
1925 -/* Name of the default catalog. */
1926 -static const char default_catalog_name[] = "messages";
1928 -/* Name of currently used catalog. */
1929 -static const char *catalog_name = default_catalog_name;
1931 -/* Get ID for given string. If not found return -1. */
1932 -static int msg_to_cat_id PARAMS ((const char *msg));
1934 -/* Substitution for systems lacking this function in their C library. */
1935 -#if !_LIBC && !HAVE_STPCPY
1936 -static char *stpcpy PARAMS ((char *dest, const char *src));
1940 -/* Set currently used domain/catalog. */
1942 -textdomain (domainname)
1943 - const char *domainname;
1945 - nl_catd new_catalog;
1947 - size_t new_name_len;
1950 -#if defined HAVE_SETLOCALE && defined HAVE_LC_MESSAGES \
1951 - && defined HAVE_LOCALE_NULL
1952 - lang = setlocale (LC_MESSAGES, NULL);
1954 - lang = getenv ("LC_ALL");
1955 - if (lang == NULL || lang[0] == '\0')
1957 - lang = getenv ("LC_MESSAGES");
1958 - if (lang == NULL || lang[0] == '\0')
1959 - lang = getenv ("LANG");
1962 - if (lang == NULL || lang[0] == '\0')
1965 - /* See whether name of currently used domain is asked. */
1966 - if (domainname == NULL)
1967 - return (char *) catalog_name;
1969 - if (domainname[0] == '\0')
1970 - domainname = default_catalog_name;
1972 - /* Compute length of added path element. */
1973 - new_name_len = sizeof (LOCALEDIR) - 1 + 1 + strlen (lang)
1974 - + sizeof ("/LC_MESSAGES/") - 1 + sizeof (PACKAGE) - 1
1975 - + sizeof (".cat");
1977 - new_name = (char *) malloc (new_name_len);
1978 - if (new_name == NULL)
1981 - strcpy (new_name, PACKAGE);
1982 - new_catalog = catopen (new_name, 0);
1984 - if (new_catalog == (nl_catd) -1)
1986 - /* NLSPATH search didn't work, try absolute path */
1987 - sprintf (new_name, "%s/%s/LC_MESSAGES/%s.cat", LOCALEDIR, lang,
1989 - new_catalog = catopen (new_name, 0);
1991 - if (new_catalog == (nl_catd) -1)
1994 - return (char *) catalog_name;
1998 - /* Close old catalog. */
1999 - if (catalog != (nl_catd) -1)
2000 - catclose (catalog);
2001 - if (catalog_name != default_catalog_name)
2002 - free ((char *) catalog_name);
2004 - catalog = new_catalog;
2005 - catalog_name = new_name;
2007 - return (char *) catalog_name;
2011 -bindtextdomain (domainname, dirname)
2012 - const char *domainname;
2013 - const char *dirname;
2015 -#if HAVE_SETENV || HAVE_PUTENV
2016 - char *old_val, *new_val, *cp;
2017 - size_t new_val_len;
2019 - /* This does not make much sense here but to be compatible do it. */
2020 - if (domainname == NULL)
2023 - /* Compute length of added path element. If we use setenv we don't need
2024 - the first byts for NLSPATH=, but why complicate the code for this
2026 - new_val_len = sizeof ("NLSPATH=") - 1 + strlen (dirname)
2027 - + sizeof ("/%L/LC_MESSAGES/%N.cat");
2029 - old_val = getenv ("NLSPATH");
2030 - if (old_val == NULL || old_val[0] == '\0')
2033 - new_val_len += 1 + sizeof (LOCALEDIR) - 1
2034 - + sizeof ("/%L/LC_MESSAGES/%N.cat");
2037 - new_val_len += strlen (old_val);
2039 - new_val = (char *) malloc (new_val_len);
2040 - if (new_val == NULL)
2046 - cp = stpcpy (new_val, "NLSPATH=");
2049 - cp = stpcpy (cp, dirname);
2050 - cp = stpcpy (cp, "/%L/LC_MESSAGES/%N.cat:");
2052 - if (old_val == NULL)
2055 - stpcpy (cp, LOCALEDIR "/%L/LC_MESSAGES/%N.cat");
2058 - cp = stpcpy (cp, LOCALEDIR);
2059 - stpcpy (cp, "/%L/LC_MESSAGES/%N.cat");
2063 - stpcpy (cp, old_val);
2066 - setenv ("NLSPATH", new_val, 1);
2070 - /* Do *not* free the environment entry we just entered. It is used
2076 - return (char *) domainname;
2086 - if (msg == NULL || catalog == (nl_catd) -1)
2087 - return (char *) msg;
2089 - /* Get the message from the catalog. We always use set number 1.
2090 - The message ID is computed by the function `msg_to_cat_id'
2091 - which works on the table generated by `po-to-tbl'. */
2092 - msgid = msg_to_cat_id (msg);
2094 - return (char *) msg;
2096 - return catgets (catalog, 1, msgid, (char *) msg);
2099 -/* Look through the table `_msg_tbl' which has `_msg_tbl_length' entries
2100 - for the one equal to msg. If it is found return the ID. In case when
2101 - the string is not found return -1. */
2103 -msg_to_cat_id (msg)
2108 - for (cnt = 0; cnt < _msg_tbl_length; ++cnt)
2109 - if (strcmp (msg, _msg_tbl[cnt]._msg) == 0)
2110 - return _msg_tbl[cnt]._msg_number;
2116 -/* @@ begin of epilog @@ */
2118 -/* We don't want libintl.a to depend on any other library. So we
2119 - avoid the non-standard function stpcpy. In GNU C Library this
2120 - function is available, though. Also allow the symbol HAVE_STPCPY
2122 -#if !_LIBC && !HAVE_STPCPY
2128 - while ((*dest++ = *src++) != '\0')
2129 - /* Do nothing. */ ;
2133 --- lrzsz-0.12.20.safe/intl/ChangeLog 1998-04-26 09:22:35.000000000 -0400
2134 +++ lrzsz-0.12.20/intl/ChangeLog 2004-09-12 14:40:34.349749000 -0400
2136 -1997-09-06 02:10 Ulrich Drepper <drepper@cygnus.com>
2138 - * intlh.inst.in: Reformat copyright.
2140 -1997-08-19 15:22 Ulrich Drepper <drepper@cygnus.com>
2142 - * dcgettext.c (DCGETTEXT): Remove wrong comment.
2144 -1997-08-16 00:13 Ulrich Drepper <drepper@cygnus.com>
2146 - * Makefile.in (install-data): Don't change directory to install.
2148 -1997-08-01 14:30 Ulrich Drepper <drepper@cygnus.com>
2150 - * cat-compat.c: Fix copyright.
2152 - * localealias.c: Don't define strchr unless !HAVE_STRCHR.
2154 - * loadmsgcat.c: Update copyright. Fix typos.
2156 - * l10nflist.c: Don't define strchr unless !HAVE_STRCHR.
2157 - (_nl_make_l10nflist): Handle sponsor and revision correctly.
2159 - * gettext.c: Update copyright.
2160 - * gettext.h: Likewise.
2161 - * hash-string.h: Likewise.
2163 - * finddomain.c: Remoave dead code. Define strchr only if
2166 - * explodename.c: Include <sys/types.h>.
2168 - * explodename.c: Reformat copyright text.
2169 - (_nl_explode_name): Fix typo.
2171 - * dcgettext.c: Define and use __set_errno.
2172 - (guess_category_value): Don't use setlocale if HAVE_LC_MESSAGES is
2175 - * bindtextdom.c: Pretty printing.
2177 -1997-05-01 02:25 Ulrich Drepper <drepper@cygnus.com>
2179 - * dcgettext.c (guess_category_value): Don't depend on
2180 - HAVE_LC_MESSAGES. We don't need the macro here.
2181 - Patch by Bruno Haible <haible@ilog.fr>.
2183 - * cat-compat.c (textdomain): DoN't refer to HAVE_SETLOCALE_NULL
2184 - macro. Instead use HAVE_LOCALE_NULL and define it when using
2185 - glibc, as in dcgettext.c.
2186 - Patch by Bruno Haible <haible@ilog.fr>.
2188 - * Makefile.in (CPPFLAGS): New variable. Reported by Franc,ois
2191 -Mon Mar 10 06:51:17 1997 Ulrich Drepper <drepper@cygnus.com>
2193 - * Makefile.in: Implement handling of libtool.
2195 - * gettextP.h: Change data structures for use of generic lowlevel
2196 - i18n file handling.
2198 -Wed Dec 4 20:21:18 1996 Ulrich Drepper <drepper@cygnus.com>
2200 - * textdomain.c: Put parentheses around arguments of memcpy macro
2202 - * localealias.c: Likewise.
2203 - * l10nflist.c: Likewise.
2204 - * finddomain.c: Likewise.
2205 - * bindtextdom.c: Likewise.
2206 - Reported by Thomas Esken.
2208 -Mon Nov 25 22:57:51 1996 Ulrich Drepper <drepper@cygnus.com>
2210 - * textdomain.c: Move definition of `memcpy` macro to right
2213 -Fri Nov 22 04:01:58 1996 Ulrich Drepper <drepper@cygnus.com>
2215 - * finddomain.c [!HAVE_STRING_H && !_LIBC]: Define memcpy using
2216 - bcopy if not already defined. Reported by Thomas Esken.
2217 - * bindtextdom.c: Likewise.
2218 - * l10nflist.c: Likewise.
2219 - * localealias.c: Likewise.
2220 - * textdomain.c: Likewise.
2222 -Tue Oct 29 11:10:27 1996 Ulrich Drepper <drepper@cygnus.com>
2224 - * Makefile.in (libdir): Change to use exec_prefix instead of
2225 - prefix. Reported by Knut-HåvardAksnes <etokna@eto.ericsson.se>.
2227 -Sat Aug 31 03:07:09 1996 Ulrich Drepper <drepper@cygnus.com>
2229 - * l10nflist.c (_nl_normalize_codeset): We convert to lower case,
2230 - so don't prepend uppercase `ISO' for only numeric arg.
2232 -Fri Jul 19 00:15:46 1996 Ulrich Drepper <drepper@cygnus.com>
2234 - * l10nflist.c: Move inclusion of argz.h, ctype.h, stdlib.h after
2235 - definition of _GNU_SOURCE. Patch by Roland McGrath.
2237 - * Makefile.in (uninstall): Fix another bug with `for' loop and
2238 - empty arguments. Patch by Jim Meyering. Correct name os
2239 - uninstalled files: no intl- prefix anymore.
2241 - * Makefile.in (install-data): Again work around shells which
2242 - cannot handle mpty for list. Reported by Jim Meyering.
2244 -Sat Jul 13 18:11:35 1996 Ulrich Drepper <drepper@cygnus.com>
2246 - * Makefile.in (install): Split goal. Now depend on install-exec
2248 - (install-exec, install-data): New goals. Created from former
2250 - Reported by Karl Berry.
2252 -Sat Jun 22 04:58:14 1996 Ulrich Drepper <drepper@cygnus.com>
2254 - * Makefile.in (MKINSTALLDIRS): New variable. Path to
2255 - mkinstalldirs script.
2256 - (install): use MKINSTALLDIRS variable or if the script is not present
2257 - try to find it in the $top_scrdir).
2259 -Wed Jun 19 02:56:56 1996 Ulrich Drepper <drepper@cygnus.com>
2261 - * l10nflist.c: Linux libc *partly* includes the argz_* functions.
2262 - Grr. Work around by renaming the static version and use macros
2265 -Tue Jun 18 20:11:17 1996 Ulrich Drepper <drepper@cygnus.com>
2267 - * l10nflist.c: Correct presence test macros of __argz_* functions.
2269 - * l10nflist.c: Include <argz.h> based on test of it instead when
2270 - __argz_* functions are available.
2271 - Reported by Andreas Schwab.
2273 -Thu Jun 13 15:17:44 1996 Ulrich Drepper <drepper@cygnus.com>
2275 - * explodename.c, l10nflist.c: Define NULL for dumb systems.
2277 -Tue Jun 11 17:05:13 1996 Ulrich Drepper <drepper@cygnus.com>
2279 - * intlh.inst.in, libgettext.h (dcgettext): Rename local variable
2280 - result to __result to prevent name clash.
2282 - * l10nflist.c, localealias.c, dcgettext.c: Define _GNU_SOURCE to
2283 - get prototype for stpcpy and strcasecmp.
2285 - * intlh.inst.in, libgettext.h: Move declaration of
2286 - `_nl_msg_cat_cntr' outside __extension__ block to prevent warning
2287 - from gcc's -Wnested-extern option.
2289 -Fri Jun 7 01:58:00 1996 Ulrich Drepper <drepper@cygnus.com>
2291 - * Makefile.in (install): Remove comment.
2293 -Thu Jun 6 17:28:17 1996 Ulrich Drepper <drepper@cygnus.com>
2295 - * Makefile.in (install): Work around for another Buglix stupidity.
2296 - Always use an `else' close for `if's. Reported by Nelson Beebe.
2298 - * Makefile.in (intlh.inst): Correct typo in phony rule.
2299 - Reported by Nelson Beebe.
2301 -Thu Jun 6 01:49:52 1996 Ulrich Drepper <drepper@cygnus.com>
2303 - * dcgettext.c (read_alias_file): Rename variable alloca_list to
2304 - block_list as the macro calls assume.
2305 - Patch by Eric Backus.
2307 - * localealias.c [!HAVE_ALLOCA]: Define alloca as macro using
2309 - (read_alias_file): Rename varriabe alloca_list to block_list as the
2310 - macro calls assume.
2311 - Patch by Eric Backus.
2313 - * l10nflist.c: Correct conditional for <argz.h> inclusion.
2314 - Reported by Roland McGrath.
2316 - * Makefile.in (all): Depend on all-@USE_INCLUDED_LIBINTL@, not
2319 - * Makefile.in (install): intlh.inst comes from local dir, not
2322 - * Makefile.in (intlh.inst): Special handling of this goal. If
2323 - used in gettext, this is really a rul to construct this file. If
2324 - used in any other package it is defined as a .PHONY rule with
2327 - * finddomain.c: Extract locale file information handling into
2328 - l10nfile.c. Rename local stpcpy__ function to stpcpy.
2330 - * dcgettext.c (stpcpy): Add local definition.
2332 - * l10nflist.c: Solve some portability problems. Patches partly by
2333 - Thomas Esken. Add local definition of stpcpy.
2335 -Tue Jun 4 02:47:49 1996 Ulrich Drepper <drepper@cygnus.com>
2337 - * intlh.inst.in: Don't depend including <locale.h> on
2338 - HAVE_LOCALE_H. Instead configure must rewrite this fiile
2339 - depending on the result of the configure run.
2341 - * Makefile.in (install): libintl.inst is now called intlh.inst.
2342 - Add rules for updating intlh.inst from intlh.inst.in.
2344 - * libintl.inst: Renamed to intlh.inst.in.
2346 - * localealias.c, dcgettext.c [__GNUC__]: Define HAVE_ALLOCA to 1
2347 - because gcc has __buitlin_alloca.
2348 - Reported by Roland McGrath.
2350 -Mon Jun 3 00:32:16 1996 Ulrich Drepper <drepper@cygnus.com>
2352 - * Makefile.in (installcheck): New goal to fulfill needs of
2353 - automake's distcheck.
2355 - * Makefile.in (install): Reorder commands so that VERSION is
2358 - * Makefile.in (gettextsrcdir): Now use subdirectory intl/ in
2359 - @datadir@/gettext.
2360 - (COMSRCS): Add l10nfile.c.
2361 - (OBJECTS): Add l10nfile.o.
2362 - (DISTFILES): Rename to DISTFILE.normal. Remove $(DISTFILES.common).
2363 - (DISTFILE.gettext): Remove $(DISTFILES.common).
2364 - (all-gettext): Remove goal.
2365 - (install): If $(PACKAGE) = gettext install, otherwose do nothing. No
2366 - package but gettext itself should install libintl.h + headers.
2367 - (dist): Extend goal to work for gettext, too.
2368 - (dist-gettext): Remove goal.
2370 - * dcgettext.c [!HAVE_ALLOCA]: Define macro alloca by using malloc.
2372 -Sun Jun 2 17:33:06 1996 Ulrich Drepper <drepper@cygnus.com>
2374 - * loadmsgcat.c (_nl_load_domain): Parameter is now comes from
2377 -Sat Jun 1 02:23:03 1996 Ulrich Drepper <drepper@cygnus.com>
2379 - * l10nflist.c (__argz_next): Add definition.
2381 - * dcgettext.c [!HAVE_ALLOCA]: Add code for handling missing alloca
2382 - code. Use new l10nfile handling.
2384 - * localealias.c [!HAVE_ALLOCA]: Add code for handling missing
2387 - * l10nflist.c: Initial revision.
2389 -Tue Apr 2 18:51:18 1996 Ulrich Drepper <drepper@myware>
2391 - * Makefile.in (all-gettext): New goal. Same as all-yes.
2393 -Thu Mar 28 23:01:22 1996 Karl Eichwalder <ke@ke.central.de>
2395 - * Makefile.in (gettextsrcdir): Define using @datadir@.
2397 -Tue Mar 26 12:39:14 1996 Ulrich Drepper <drepper@myware>
2399 - * finddomain.c: Include <ctype.h>. Reported by Roland McGrath.
2401 -Sat Mar 23 02:00:35 1996 Ulrich Drepper <drepper@myware>
2403 - * finddomain.c (stpcpy): Rename to stpcpy__ to prevent clashing
2404 - with external declaration.
2406 -Sat Mar 2 00:47:09 1996 Ulrich Drepper <drepper@myware>
2408 - * Makefile.in (all-no): Rename from all_no.
2410 -Sat Feb 17 00:25:59 1996 Ulrich Drepper <drepper@myware>
2412 - * gettextP.h [loaded_domain]: Array `successor' must now contain up
2413 - to 63 elements (because of codeset name normalization).
2415 - * finddomain.c: Implement codeset name normalization.
2417 -Thu Feb 15 04:39:09 1996 Ulrich Drepper <drepper@myware>
2419 - * Makefile.in (all): Define to `all-@USE_NLS@'.
2420 - (all-yes, all_no): New goals. `all-no' is noop, `all-yes'
2423 -Mon Jan 15 21:46:01 1996 Howard Gayle <howard@hal.com>
2425 - * localealias.c (alias_compare): Increment string pointers in loop
2426 - of strcasecmp replacement.
2428 -Fri Dec 29 21:16:34 1995 Ulrich Drepper <drepper@myware>
2430 - * Makefile.in (install-src): Who commented this goal out ? :-)
2432 -Fri Dec 29 15:08:16 1995 Ulrich Drepper <drepper@myware>
2434 - * dcgettext.c (DCGETTEXT): Save `errno'. Failing system calls
2435 - should not effect it because a missing catalog is no error.
2436 - Reported by Harald K<o:>nig <koenig@tat.physik.uni-tuebingen.de>.
2438 -Tue Dec 19 22:09:13 1995 Ulrich Drepper <drepper@myware>
2440 - * Makefile.in (Makefile): Explicitly use $(SHELL) for running
2443 -Fri Dec 15 17:34:59 1995 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
2445 - * Makefile.in (install-src): Only install library and header when
2446 - we use the own implementation. Don't do it when using the
2447 - system's gettext or catgets functions.
2449 - * dcgettext.c (find_msg): Must not swap domain->hash_size here.
2451 -Sat Dec 9 16:24:37 1995 Ulrich Drepper <drepper@myware>
2453 - * localealias.c, libintl.inst, libgettext.h, hash-string.h,
2454 - gettextP.h, finddomain.c, dcgettext.c, cat-compat.c:
2455 - Use PARAMS instead of __P. Suggested by Roland McGrath.
2457 -Tue Dec 5 11:39:14 1995 Larry Schwimmer <rosebud@cyclone.stanford.edu>
2459 - * libgettext.h: Use `#if !defined (_LIBINTL_H)' instead of `#if
2460 - !_LIBINTL_H' because Solaris defines _LIBINTL_H as empty.
2462 -Mon Dec 4 15:42:07 1995 Ulrich Drepper <drepper@myware>
2464 - * Makefile.in (install-src):
2465 - Install libintl.inst instead of libintl.h.install.
2467 -Sat Dec 2 22:51:38 1995 Marcus Daniels <marcus@sysc.pdx.edu>
2469 - * cat-compat.c (textdomain):
2470 - Reverse order in which files are tried you load. First
2471 - try local file, when this failed absolute path.
2473 -Wed Nov 29 02:03:53 1995 Nelson H. F. Beebe <beebe@math.utah.edu>
2475 - * cat-compat.c (bindtextdomain): Add missing { }.
2477 -Sun Nov 26 18:21:41 1995 Ulrich Drepper <drepper@myware>
2479 - * libintl.inst: Add missing __P definition. Reported by Nelson Beebe.
2482 - Add dummy `all' and `dvi' goals. Reported by Tom Tromey.
2484 -Sat Nov 25 16:12:01 1995 Franc,ois Pinard <pinard@iro.umontreal.ca>
2486 - * hash-string.h: Capitalize arguments of macros.
2488 -Sat Nov 25 12:01:36 1995 Ulrich Drepper <drepper@myware>
2490 - * Makefile.in (DISTFILES): Prevent files names longer than 13
2491 - characters. libintl.h.glibc->libintl.glibc,
2492 - libintl.h.install->libintl.inst. Reported by Joshua R. Poulson.
2494 -Sat Nov 25 11:31:12 1995 Eric Backus <ericb@lsid.hp.com>
2496 - * dcgettext.c: Fix bug in preprocessor conditionals.
2498 -Sat Nov 25 02:35:27 1995 Nelson H. F. Beebe <beebe@math.utah.edu>
2500 - * libgettext.h: Solaris cc does not understand
2501 - #if !SYMBOL1 && !SYMBOL2. Sad but true.
2503 -Thu Nov 23 16:22:14 1995 Ulrich Drepper <drepper@myware>
2505 - * hash-string.h (hash_string):
2506 - Fix for machine with >32 bit `unsigned long's.
2508 - * dcgettext.c (DCGETTEXT):
2509 - Fix horrible bug in loop for alternative translation.
2511 -Thu Nov 23 01:45:29 1995 Ulrich Drepper <drepper@myware>
2513 - * po2tbl.sed.in, linux-msg.sed, xopen-msg.sed:
2514 - Some further simplifications in message number generation.
2516 -Mon Nov 20 21:08:43 1995 Ulrich Drepper <drepper@myware>
2518 - * libintl.h.glibc: Use __const instead of const in prototypes.
2520 - * Makefile.in (install-src):
2521 - Install libintl.h.install instead of libintl.h. This
2522 - is a stripped-down version. Suggested by Peter Miller.
2524 - * libintl.h.install, libintl.h.glibc: Initial revision.
2526 - * localealias.c (_nl_expand_alias, read_alias_file):
2527 - Protect prototypes in type casts by __P.
2529 -Tue Nov 14 16:43:58 1995 Ulrich Drepper <drepper@myware>
2531 - * hash-string.h: Correct prototype for hash_string.
2533 -Sun Nov 12 12:42:30 1995 Ulrich Drepper <drepper@myware>
2535 - * hash-string.h (hash_string): Add prototype.
2537 - * gettextP.h: Fix copyright.
2538 - (SWAP): Add prototype.
2540 -Wed Nov 8 22:56:33 1995 Ulrich Drepper <drepper@myware>
2542 - * localealias.c (read_alias_file): Forgot sizeof.
2543 - Avoid calling *printf function. This introduces a big overhead.
2544 - Patch by Roland McGrath.
2546 -Tue Nov 7 14:21:08 1995 Ulrich Drepper <drepper@myware>
2548 - * finddomain.c, cat-compat.c: Wrong indentation in #if for stpcpy.
2550 - * finddomain.c (stpcpy):
2551 - Define substitution function local. The macro was to flaky.
2553 - * cat-compat.c: Fix typo.
2555 - * xopen-msg.sed, linux-msg.sed:
2556 - While bringing message number to right place only accept digits.
2558 - * linux-msg.sed, xopen-msg.sed: Now that the counter does not have
2559 - leading 0s we don't need to remove them. Reported by Marcus
2562 - * Makefile.in (../po/cat-id-tbl.o): Use $(top_srdir) in
2563 - dependency. Reported by Marcus Daniels.
2565 - * cat-compat.c: (stpcpy) [!_LIBC && !HAVE_STPCPY]: Define replacement.
2566 - Generally cleanup using #if instead of #ifndef.
2568 - * Makefile.in: Correct typos in comment. By Franc,ois Pinard.
2570 -Mon Nov 6 00:27:02 1995 Ulrich Drepper <drepper@myware>
2572 - * Makefile.in (install-src): Don't install libintl.h and libintl.a
2573 - if we use an available gettext implementation.
2575 -Sun Nov 5 22:02:08 1995 Ulrich Drepper <drepper@myware>
2577 - * libgettext.h: Fix typo: HAVE_CATGETTS -> HAVE_CATGETS. Reported
2578 - by Franc,ois Pinard.
2580 - * libgettext.h: Use #if instead of #ifdef/#ifndef.
2583 - Comments describing what has to be done should start with FIXME.
2585 -Sun Nov 5 19:38:01 1995 Ulrich Drepper <drepper@myware>
2587 - * Makefile.in (DISTFILES): Split. Use DISTFILES with normal meaning.
2588 - DISTFILES.common names the files common to both dist goals.
2589 - DISTFILES.gettext are the files only distributed in GNU gettext.
2591 -Sun Nov 5 17:32:54 1995 Ulrich Drepper <drepper@myware>
2593 - * dcgettext.c (DCGETTEXT): Correct searching in derived locales.
2594 - This was necessary since a change in _nl_find_msg several weeks
2595 - ago. I really don't know this is still not fixed.
2597 -Sun Nov 5 12:43:12 1995 Ulrich Drepper <drepper@myware>
2599 - * loadmsgcat.c (_nl_load_domain): Test for FILENAME == NULL. This
2600 - might mark a special condition.
2602 - * finddomain.c (make_entry_rec): Don't make illegal entry as decided.
2604 - * Makefile.in (dist): Suppress error message when ln failed.
2605 - Get files from $(srcdir) explicitly.
2607 - * libgettext.h (gettext_const): Rename to gettext_noop.
2609 -Fri Nov 3 07:36:50 1995 Ulrich Drepper <drepper@myware>
2611 - * finddomain.c (make_entry_rec):
2612 - Protect against wrong locale names by testing mask.
2614 - * libgettext.h (gettext_const): Add macro definition.
2615 - Capitalize macro arguments.
2617 -Thu Nov 2 23:15:51 1995 Ulrich Drepper <drepper@myware>
2619 - * finddomain.c (_nl_find_domain):
2620 - Test for pointer != NULL before accessing value.
2621 - Reported by Tom Tromey.
2623 - * gettext.c (NULL):
2624 - Define as (void*)0 instad of 0. Reported by Franc,ois Pinard.
2626 -Mon Oct 30 21:28:52 1995 Ulrich Drepper <drepper@myware>
2628 - * po2tbl.sed.in: Serious typo bug fixed by Jim Meyering.
2630 -Sat Oct 28 23:20:47 1995 Ulrich Drepper <drepper@myware>
2632 - * libgettext.h: Disable dcgettext optimization for Solaris 2.3.
2634 - * localealias.c (alias_compare):
2635 - Peter Miller reported that tolower in some systems is
2636 - even dumber than I thought. Protect call by `isupper'.
2638 -Fri Oct 27 22:22:51 1995 Ulrich Drepper <drepper@myware>
2640 - * Makefile.in (libdir, includedir): New variables.
2641 - (install-src): Install libintl.a and libintl.h in correct dirs.
2643 -Fri Oct 27 22:07:29 1995 Ulrich Drepper <drepper@myware>
2645 - * Makefile.in (SOURCES): Fix typo: intrl.compat.c -> intl-compat.c.
2647 - * po2tbl.sed.in: Patch for buggy SEDs by Christian von Roques.
2650 - Fix typo and superflous test. Reported by Christian von Roques.
2652 -Fri Oct 6 11:52:05 1995 Ulrich Drepper <drepper@myware>
2654 - * finddomain.c (_nl_find_domain):
2655 - Correct some remainder from the pre-CEN syntax. Now
2656 - we don't have a constant number of successors anymore.
2658 -Wed Sep 27 21:41:13 1995 Ulrich Drepper <drepper@myware>
2660 - * Makefile.in (DISTFILES): Add libintl.h.glibc.
2662 - * Makefile.in (dist-libc): Add goal for packing sources for glibc.
2663 - (COMSRCS, COMHDRS): Splitted to separate sources shared with glibc.
2665 - * loadmsgcat.c: Forget to continue #if line.
2668 - [_LIBC]: Rename strcasecmp to __strcasecmp to keep ANSI C name
2671 - * dcgettext.c, finddomain.c: Better comment to last change.
2674 - [_LIBC]: Rename fstat, open, close, read, mmap, and munmap to
2675 - __fstat, __open, __close, __read, __mmap, and __munmap resp
2676 - to keep ANSI C name space clean.
2679 - [_LIBC]: Rename stpcpy to __stpcpy to keep ANSI C name space clean.
2682 - [_LIBC]: Rename getced and stpcpy to __getcwd and __stpcpy resp to
2683 - keep ANSI C name space clean.
2686 - Include sys/types.h for those old SysV systems out there.
2687 - Reported by Francesco Potorti`.
2689 - * loadmsgcat.c (use_mmap): Define if compiled for glibc.
2691 - * bindtextdom.c: Include all those standard headers
2692 - unconditionally if _LIBC is defined.
2694 - * finddomain.c: Fix 2 times defiend -> defined.
2696 - * textdomain.c: Include libintl.h instead of libgettext.h when
2697 - compiling for glibc. Include all those standard headers
2698 - unconditionally if _LIBC is defined.
2700 - * localealias.c, loadmsgcat.c: Prepare to be compiled in glibc.
2703 - Include libintl.h instead of libgettext.h when compiling for glibc.
2704 - Get NULL from stddef.h if we compile for glibc.
2706 - * finddomain.c: Include libintl.h instead of libgettext.h when
2707 - compiling for glibc. Include all those standard headers
2708 - unconditionally if _LIBC is defined.
2710 - * dcgettext.c: Include all those standard headers unconditionally
2711 - if _LIBC is defined.
2713 - * dgettext.c: If compiled in glibc include libintl.h instead of
2715 - (locale.h): Don't rely on HAVE_LOCALE_H when compiling for glibc.
2717 - * dcgettext.c: If compiled in glibc include libintl.h instead of
2719 - (getcwd): Don't rely on HAVE_GETCWD when compiling for glibc.
2722 - If compiled in glibc include libintl.h instead of libgettext.h.
2724 -Mon Sep 25 22:23:06 1995 Ulrich Drepper <drepper@myware>
2726 - * localealias.c (_nl_expand_alias): Don't call bsearch if NMAP <= 0.
2727 - Reported by Marcus Daniels.
2729 - * cat-compat.c (bindtextdomain):
2730 - String used in putenv must not be recycled.
2731 - Reported by Marcus Daniels.
2733 - * libgettext.h (__USE_GNU_GETTEXT):
2734 - Additional symbol to signal that we use GNU gettext
2737 - * cat-compat.c (bindtextdomain):
2738 - Fix bug with the strange stpcpy replacement.
2739 - Reported by Nelson Beebe.
2741 -Sat Sep 23 08:23:51 1995 Ulrich Drepper <drepper@myware>
2743 - * cat-compat.c: Include <string.h> for stpcpy prototype.
2745 - * localealias.c (read_alias_file):
2746 - While expand strdup code temporary variable `cp' hided
2747 - higher level variable with same name. Rename to `tp'.
2749 - * textdomain.c (textdomain):
2750 - Avoid warning by using temporary variable in strdup code.
2752 - * finddomain.c (_nl_find_domain): Remove unused variable `application'.
2754 -Thu Sep 21 15:51:44 1995 Ulrich Drepper <drepper@myware>
2756 - * localealias.c (alias_compare):
2757 - Use strcasecmp() only if available. Else use
2758 - implementation in place.
2761 - Wrapper functions now call *__ functions instead of __*.
2763 - * libgettext.h: Declare prototypes for *__ functions instead for __*.
2765 - * cat-compat.c, loadmsgcat.c:
2766 - Don't use xmalloc, xstrdup, and stpcpy. These functions are not part
2767 - of the standard libc and so prevent libintl.a from being used
2771 - Don't use xmalloc, xstrdup, and stpcpy. These functions are not part
2772 - of the standard libc and so prevent libintl.a from being used
2774 - Rename to bindtextdomain__ if not used in GNU C Library.
2777 - Rename function to dgettext__ if not used in GNU C Library.
2780 - Don't use xmalloc, xstrdup, and stpcpy. These functions are not part
2781 - of the standard libc and so prevent libintl.a from being used
2783 - Functions now called gettext__ if not used in GNU C Library.
2785 - * dcgettext.c, localealias.c, textdomain.c, finddomain.c:
2786 - Don't use xmalloc, xstrdup, and stpcpy. These functions are not part
2787 - of the standard libc and so prevent libintl.a from being used
2790 -Sun Sep 17 23:14:49 1995 Ulrich Drepper <drepper@myware>
2792 - * finddomain.c: Correct some bugs in handling of CEN standard
2793 - locale definitions.
2795 -Thu Sep 7 01:49:28 1995 Ulrich Drepper <drepper@myware>
2797 - * finddomain.c: Implement CEN syntax.
2799 - * gettextP.h (loaded_domain): Extend number of successors to 31.
2801 -Sat Aug 19 19:25:29 1995 Ulrich Drepper <drepper@myware>
2803 - * Makefile.in (aliaspath): Remove path to X11 locale dir.
2805 - * Makefile.in: Make install-src depend on install. This helps
2806 - gettext to install the sources and other packages can use the
2809 -Sat Aug 19 15:19:33 1995 Ulrich Drepper <drepper@myware>
2811 - * Makefile.in (uninstall): Remove stuff installed by install-src.
2813 -Tue Aug 15 13:13:53 1995 Ulrich Drepper <drepper@myware>
2815 - * VERSION.in: Initial revision.
2817 - * Makefile.in (DISTFILES):
2818 - Add VERSION file. This is not necessary for gettext, but
2819 - for other packages using this library.
2821 -Tue Aug 15 06:16:44 1995 Ulrich Drepper <drepper@myware>
2823 - * gettextP.h (_nl_find_domain):
2824 - New prototype after changing search strategy.
2826 - * finddomain.c (_nl_find_domain):
2827 - We now try only to find a specified catalog. Fall back to other
2828 - catalogs listed in the locale list is now done in __dcgettext.
2830 - * dcgettext.c (__dcgettext):
2831 - Now we provide message fall back even to different languages.
2832 - I.e. if a message is not available in one language all the other
2833 - in the locale list a tried. Formerly fall back was only possible
2834 - within one language. Implemented by moving one loop from
2835 - _nl_find_domain to here.
2837 -Mon Aug 14 23:45:50 1995 Ulrich Drepper <drepper@myware>
2839 - * Makefile.in (gettextsrcdir):
2840 - Directory where source of GNU gettext library are made
2842 - (INSTALL, INSTALL_DATA): Programs used for installing sources.
2843 - (gettext-src): New. Rule to install GNU gettext sources for use in
2844 - gettextize shell script.
2846 -Sun Aug 13 14:40:48 1995 Ulrich Drepper <drepper@myware>
2848 - * loadmsgcat.c (_nl_load_domain):
2849 - Use mmap for loading only when munmap function is
2852 - * Makefile.in (install): Depend on `all' goal.
2854 -Wed Aug 9 11:04:33 1995 Ulrich Drepper <drepper@myware>
2856 - * localealias.c (read_alias_file):
2857 - Do not overwrite '\n' when terminating alias value string.
2859 - * localealias.c (read_alias_file):
2860 - Handle long lines. Ignore the rest not fitting in
2861 - the buffer after the initial `fgets' call.
2863 -Wed Aug 9 00:54:29 1995 Ulrich Drepper <drepper@myware>
2865 - * gettextP.h (_nl_load_domain):
2866 - Add prototype, replacing prototype for _nl_load_msg_cat.
2868 - * finddomain.c (_nl_find_domain):
2869 - Remove unneeded variable filename and filename_len.
2870 - (expand_alias): Remove prototype because functions does not
2873 - * localealias.c (read_alias_file):
2874 - Change type of fname_len parameter to int.
2875 - (xmalloc): Add prototype.
2877 - * loadmsgcat.c: Better prototypes for xmalloc.
2879 -Tue Aug 8 22:30:39 1995 Ulrich Drepper <drepper@myware>
2881 - * finddomain.c (_nl_find_domain):
2882 - Allow alias name to be constructed from the four components.
2884 - * Makefile.in (aliaspath): New variable. Set to preliminary value.
2885 - (SOURCES): Add localealias.c.
2886 - (OBJECTS): Add localealias.o.
2888 - * gettextP.h: Add prototype for _nl_expand_alias.
2890 - * finddomain.c: Aliasing handled in intl/localealias.c.
2892 - * localealias.c: Aliasing for locale names.
2894 - * bindtextdom.c: Better prototypes for xmalloc and xstrdup.
2896 -Mon Aug 7 23:47:42 1995 Ulrich Drepper <drepper@myware>
2898 - * Makefile.in (DISTFILES): gettext.perl is now found in misc/.
2900 - * cat-compat.c (bindtextdomain):
2901 - Correct implementation. dirname parameter was not used.
2902 - Reported by Marcus Daniels.
2904 - * gettextP.h (loaded_domain):
2905 - New fields `successor' and `decided' for oo, lazy
2906 - message handling implementation.
2909 - Adopt for oo, lazy message handliing.
2910 - Now we can inherit translations from less specific locales.
2911 - (find_msg): New function.
2913 - * loadmsgcat.c, finddomain.c:
2914 - Complete rewrite. Implement oo, lazy message handling :-).
2915 - We now have an additional environment variable `LANGUAGE' with
2916 - a higher priority than LC_ALL for the LC_MESSAGE locale.
2917 - Here we can set a colon separated list of specifications each
2918 - of the form `language[_territory[.codeset]][@modifier]'.
2920 -Sat Aug 5 09:55:42 1995 Ulrich Drepper <drepper@myware>
2922 - * finddomain.c (unistd.h):
2923 - Include to get _PC_PATH_MAX defined on system having it.
2925 -Fri Aug 4 22:42:00 1995 Ulrich Drepper <drepper@myware>
2927 - * finddomain.c (stpcpy): Include prototype.
2929 - * Makefile.in (dist): Remove `copying instead' message.
2931 -Wed Aug 2 18:52:03 1995 Ulrich Drepper <drepper@myware>
2933 - * Makefile.in (ID, TAGS): Do not use $^.
2935 -Tue Aug 1 20:07:11 1995 Ulrich Drepper <drepper@myware>
2937 - * Makefile.in (TAGS, ID): Use $^ as command argument.
2938 - (TAGS): Give etags -o option t write to current directory,
2940 - (ID): Use $(srcdir) instead os $(top_srcdir)/src.
2941 - (distclean): Remove ID.
2943 -Sun Jul 30 11:51:46 1995 Ulrich Drepper <drepper@myware>
2945 - * Makefile.in (gnulocaledir):
2946 - New variable, always using share/ for data directory.
2947 - (DEFS): Add GNULOCALEDIR, used in finddomain.c.
2949 - * finddomain.c (_nl_default_dirname):
2950 - Set to GNULOCALEDIR, because it always has to point
2951 - to the directory where GNU gettext Library writes it to.
2953 - * intl-compat.c (textdomain, bindtextdomain):
2954 - Undefine macros before function definition.
2956 -Sat Jul 22 01:10:02 1995 Ulrich Drepper <drepper@myware>
2958 - * libgettext.h (_LIBINTL_H):
2959 - Protect definition in case where this file is included as
2960 - libgettext.h on Solaris machines. Add comment about this.
2962 -Wed Jul 19 02:36:42 1995 Ulrich Drepper <drepper@myware>
2964 - * intl-compat.c (textdomain): Correct typo.
2966 -Wed Jul 19 01:51:35 1995 Ulrich Drepper <drepper@myware>
2968 - * dcgettext.c (dcgettext): Function now called __dcgettext.
2970 - * dgettext.c (dgettext): Now called __dgettext and calls
2973 - * gettext.c (gettext):
2974 - Function now called __gettext and calls __dgettext.
2976 - * textdomain.c (textdomain): Function now called __textdomain.
2978 - * bindtextdom.c (bindtextdomain): Function now called
2981 - * intl-compat.c: Initial revision.
2983 - * Makefile.in (SOURCES): Add intl-compat.c.
2984 - (OBJECTS): We always compile the GNU gettext library functions.
2985 - OBJECTS contains all objects but cat-compat.o, ../po/cat-if-tbl.o,
2986 - and intl-compat.o.
2987 - (GETTOBJS): Contains now only intl-compat.o.
2990 - Re-include protection matches dualistic character of libgettext.h.
2991 - For all functions in GNU gettext library define __ counter part.
2993 - * finddomain.c (strchr): Define as index if not found in C library.
2994 - (_nl_find_domain): For relative paths paste / in between.
2996 -Tue Jul 18 16:37:45 1995 Ulrich Drepper <drepper@myware>
2998 - * loadmsgcat.c, finddomain.c: Add inclusion of sys/types.h.
3000 - * xopen-msg.sed: Fix bug with `msgstr ""' lines.
3001 - A little bit better comments.
3003 -Tue Jul 18 01:18:27 1995 Ulrich Drepper <drepper@myware>
3006 - po-mode.el, makelinks, combine-sh are now found in ../misc.
3008 - * po-mode.el, makelinks, combine-sh, elisp-comp:
3009 - Moved to ../misc/.
3011 - * libgettext.h, gettextP.h, gettext.h: Uniform test for __STDC__.
3013 -Sun Jul 16 22:33:02 1995 Ulrich Drepper <drepper@myware>
3015 - * Makefile.in (INSTALL, INSTALL_DATA): New variables.
3016 - (install-data, uninstall): Install/uninstall .elc file.
3018 - * po-mode.el (Installation comment):
3019 - Add .pox as possible extension of .po files.
3021 -Sun Jul 16 13:23:27 1995 Ulrich Drepper <drepper@myware>
3023 - * elisp-comp: Complete new version by Franc,ois: This does not
3024 - fail when not compiling in the source directory.
3026 -Sun Jul 16 00:12:17 1995 Ulrich Drepper <drepper@myware>
3028 - * Makefile.in (../po/cat-id-tbl.o):
3029 - Use $(MAKE) instead of make for recursive make.
3031 - * Makefile.in (.el.elc): Use $(SHELL) instead of /bin/sh.
3032 - (install-exec): Add missing dummy goal.
3033 - (install-data, uninstall): @ in multi-line shell command at
3034 - beginning, not in front of echo. Reported by Eric Backus.
3036 -Sat Jul 15 00:21:28 1995 Ulrich Drepper <drepper@myware>
3038 - * Makefile.in (DISTFILES):
3039 - Rename libgettext.perl to gettext.perl to fit in 14 chars
3043 - Rename to gettext.perl to fit in 14 chars file systems.
3045 -Thu Jul 13 23:17:20 1995 Ulrich Drepper <drepper@myware>
3047 - * cat-compat.c: If !STDC_HEADERS try to include malloc.h.
3049 -Thu Jul 13 20:55:02 1995 Ulrich Drepper <drepper@myware>
3051 - * po2tbl.sed.in: Pretty printing.
3053 - * linux-msg.sed, xopen-msg.sed:
3054 - Correct bugs with handling substitute flags in branches.
3056 - * hash-string.h (hash_string):
3057 - Old K&R compilers don't under stand `unsigned char'.
3059 - * gettext.h (nls_uint32):
3060 - Some old K&R compilers (eg HP) don't understand `unsigned int'.
3062 - * cat-compat.c (msg_to_cat_id): De-ANSI-fy prototypes.
3064 -Thu Jul 13 01:34:33 1995 Ulrich Drepper <drepper@myware>
3066 - * Makefile.in (ELCFILES): New variable.
3067 - (DISTFILES): Add elisp-comp.
3068 - Add implicit rule for .el -> .elc compilation.
3069 - (install-data): install $ELCFILES
3070 - (clean): renamed po-to-tbl and po-to-msg to po2tbl and po2msg resp.
3072 - * elisp-comp: Initial revision
3074 -Wed Jul 12 16:14:52 1995 Ulrich Drepper <drepper@myware>
3077 - cat-id-tbl.c is now found in po/. This enables us to use an identical
3078 - intl/ directory in all packages.
3080 - * dcgettext.c (dcgettext): hashing does not work for table size <= 2.
3082 - * textdomain.c: fix typo (#if def -> #if defined)
3084 -Tue Jul 11 18:44:43 1995 Ulrich Drepper <drepper@myware>
3086 - * Makefile.in (stamp-cat-id): use top_srcdir to address source files
3087 - (DISTFILES,distclean): move tupdate.perl to src/
3089 - * po-to-tbl.sed.in:
3090 - add additional jump to clear change flag to recognize multiline strings
3092 -Tue Jul 11 01:32:50 1995 Ulrich Drepper <drepper@myware>
3094 - * textdomain.c: Protect inclusion of stdlib.h and string.h.
3096 - * loadmsgcat.c: Protect inclusion of stdlib.h.
3098 - * libgettext.h: Protect inclusion of locale.h.
3099 - Allow use in C++ programs.
3100 - Define NULL is not happened already.
3102 - * Makefile.in (DISTFILES): ship po-to-tbl.sed.in instead of
3104 - (distclean): remove po-to-tbl.sed and tupdate.perl.
3106 - * tupdate.perl.in: Substitute Perl path even in exec line.
3107 - Don't include entries without translation from old .po file.
3109 -Tue Jul 4 00:41:51 1995 Ulrich Drepper <drepper@myware>
3111 - * tupdate.perl.in: use "Updated: " in msgid "".
3113 - * cat-compat.c: Fix typo (LOCALDIR -> LOCALEDIR).
3114 - Define getenv if !__STDC__.
3116 - * bindtextdom.c: Protect stdlib.h and string.h inclusion.
3117 - Define free if !__STDC__.
3119 - * finddomain.c: Change DEF_MSG_DOM_DIR to LOCALEDIR.
3120 - Define free if !__STDC__.
3122 - * cat-compat.c: Change DEF_MSG_DOM_DIR to LOCALEDIR.
3124 -Mon Jul 3 23:56:30 1995 Ulrich Drepper <drepper@myware>
3126 - * Makefile.in: Use LOCALEDIR instead of DEF_MSG_DOM_DIR.
3127 - Remove unneeded $(srcdir) from Makefile.in dependency.
3129 - * makelinks: Add copyright and short description.
3131 - * po-mode.el: Last version for 0.7.
3133 - * tupdate.perl.in: Fix die message.
3135 - * dcgettext.c: Protect include of string.h.
3137 - * gettext.c: Protect include of stdlib.h and further tries to get NULL.
3139 - * finddomain.c: Some corrections in includes.
3141 - * Makefile.in (INCLUDES): Prune list correct path to Makefile.in.
3143 - * po-to-tbl.sed: Adopt for new .po file format.
3145 - * linux-msg.sed, xopen-msg.sed: Adopt for new .po file format.
3147 -Sun Jul 2 23:55:03 1995 Ulrich Drepper <drepper@myware>
3149 - * tupdate.perl.in: Complete rewrite for new .po file format.
3150 +2004-01-29 GNU <bug-gnu-gettext@gnu.org>
3152 -Sun Jul 2 02:06:50 1995 Ulrich Drepper <drepper@myware>
3153 + * Version 0.14.1 released.
3155 - * First official release. This directory contains all the code
3156 - needed to internationalize own packages. It provides functions
3157 - which allow to use the X/Open catgets function with an interface
3158 - like the Uniforum gettext function. For system which does not
3159 - have neither of those a complete implementation is provided.
3160 --- lrzsz-0.12.20.safe/intl/config.charset 1969-12-31 19:00:00.000000000 -0500
3161 +++ lrzsz-0.12.20/intl/config.charset 2004-09-12 14:40:34.354748240 -0400
3164 +# Output a system dependent table of character encoding aliases.
3166 +# Copyright (C) 2000-2004 Free Software Foundation, Inc.
3168 +# This program is free software; you can redistribute it and/or modify it
3169 +# under the terms of the GNU Library General Public License as published
3170 +# by the Free Software Foundation; either version 2, or (at your option)
3171 +# any later version.
3173 +# This program is distributed in the hope that it will be useful,
3174 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
3175 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
3176 +# Library General Public License for more details.
3178 +# You should have received a copy of the GNU Library General Public
3179 +# License along with this program; if not, write to the Free Software
3180 +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
3183 +# The table consists of lines of the form
3186 +# ALIAS is the (system dependent) result of "nl_langinfo (CODESET)".
3187 +# ALIAS is compared in a case sensitive way.
3189 +# CANONICAL is the GNU canonical name for this character encoding.
3190 +# It must be an encoding supported by libiconv. Support by GNU libc is
3191 +# also desirable. CANONICAL is case insensitive. Usually an upper case
3192 +# MIME charset name is preferred.
3193 +# The current list of GNU canonical charset names is as follows.
3195 +# name MIME? used by which systems
3196 +# ASCII, ANSI_X3.4-1968 glibc solaris freebsd darwin
3197 +# ISO-8859-1 Y glibc aix hpux irix osf solaris freebsd darwin
3198 +# ISO-8859-2 Y glibc aix hpux irix osf solaris freebsd darwin
3199 +# ISO-8859-3 Y glibc solaris
3200 +# ISO-8859-4 Y osf solaris freebsd darwin
3201 +# ISO-8859-5 Y glibc aix hpux irix osf solaris freebsd darwin
3202 +# ISO-8859-6 Y glibc aix hpux solaris
3203 +# ISO-8859-7 Y glibc aix hpux irix osf solaris
3204 +# ISO-8859-8 Y glibc aix hpux osf solaris
3205 +# ISO-8859-9 Y glibc aix hpux irix osf solaris
3206 +# ISO-8859-13 glibc
3207 +# ISO-8859-14 glibc
3208 +# ISO-8859-15 glibc aix osf solaris freebsd
3209 +# KOI8-R Y glibc solaris freebsd darwin
3210 +# KOI8-U Y glibc freebsd darwin
3214 +# CP850 aix osf dos
3223 +# CP866 freebsd darwin dos
3227 +# CP932 aix woe32 dos
3229 +# CP949 osf woe32 dos
3236 +# CP1251 glibc solaris darwin woe32
3240 +# CP1255 glibc woe32
3243 +# GB2312 Y glibc aix hpux irix solaris freebsd darwin
3244 +# EUC-JP Y glibc aix hpux irix osf solaris freebsd darwin
3245 +# EUC-KR Y glibc aix hpux irix osf solaris freebsd darwin
3246 +# EUC-TW glibc aix hpux irix osf solaris
3247 +# BIG5 Y glibc aix hpux osf solaris freebsd darwin
3248 +# BIG5-HKSCS glibc solaris
3249 +# GBK glibc aix osf solaris woe32 dos
3250 +# GB18030 glibc solaris
3251 +# SHIFT_JIS Y hpux osf solaris freebsd darwin
3252 +# JOHAB glibc solaris woe32
3253 +# TIS-620 glibc aix hpux osf solaris
3256 +# GEORGIAN-PS glibc
3265 +# UTF-8 Y glibc aix hpux osf solaris
3267 +# Note: Names which are not marked as being a MIME name should not be used in
3268 +# Internet protocols for information interchange (mail, news, etc.).
3270 +# Note: ASCII and ANSI_X3.4-1968 are synonymous canonical names. Applications
3271 +# must understand both names and treat them as equivalent.
3273 +# The first argument passed to this file is the canonical host specification,
3274 +# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
3276 +# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM
3279 +os=`echo "$host" | sed -e 's/^[^-]*-[^-]*-\(.*\)$/\1/'`
3280 +echo "# This file contains a table of character encoding aliases,"
3281 +echo "# suitable for operating system '${os}'."
3282 +echo "# It was automatically generated from config.charset."
3283 +# List of references, updated during installation:
3284 +echo "# Packages using this file: "
3287 + # Linux libc5 doesn't have nl_langinfo(CODESET); therefore
3288 + # localcharset.c falls back to using the full locale name
3289 + # from the environment variables.
3291 + echo "POSIX ASCII"
3292 + for l in af af_ZA ca ca_ES da da_DK de de_AT de_BE de_CH de_DE de_LU \
3293 + en en_AU en_BW en_CA en_DK en_GB en_IE en_NZ en_US en_ZA \
3294 + en_ZW es es_AR es_BO es_CL es_CO es_DO es_EC es_ES es_GT \
3295 + es_HN es_MX es_PA es_PE es_PY es_SV es_US es_UY es_VE et \
3296 + et_EE eu eu_ES fi fi_FI fo fo_FO fr fr_BE fr_CA fr_CH fr_FR \
3297 + fr_LU ga ga_IE gl gl_ES id id_ID in in_ID is is_IS it it_CH \
3298 + it_IT kl kl_GL nl nl_BE nl_NL no no_NO pt pt_BR pt_PT sv \
3300 + echo "$l ISO-8859-1"
3301 + echo "$l.iso-8859-1 ISO-8859-1"
3302 + echo "$l.iso-8859-15 ISO-8859-15"
3303 + echo "$l.iso-8859-15@euro ISO-8859-15"
3304 + echo "$l@euro ISO-8859-15"
3305 + echo "$l.cp-437 CP437"
3306 + echo "$l.cp-850 CP850"
3307 + echo "$l.cp-1252 CP1252"
3308 + echo "$l.cp-1252@euro CP1252"
3309 + #echo "$l.atari-st ATARI-ST" # not a commonly used encoding
3310 + echo "$l.utf-8 UTF-8"
3311 + echo "$l.utf-8@euro UTF-8"
3313 + for l in cs cs_CZ hr hr_HR hu hu_HU pl pl_PL ro ro_RO sk sk_SK sl \
3314 + sl_SI sr sr_CS sr_YU; do
3315 + echo "$l ISO-8859-2"
3316 + echo "$l.iso-8859-2 ISO-8859-2"
3317 + echo "$l.cp-852 CP852"
3318 + echo "$l.cp-1250 CP1250"
3319 + echo "$l.utf-8 UTF-8"
3321 + for l in mk mk_MK ru ru_RU; do
3322 + echo "$l ISO-8859-5"
3323 + echo "$l.iso-8859-5 ISO-8859-5"
3324 + echo "$l.koi8-r KOI8-R"
3325 + echo "$l.cp-866 CP866"
3326 + echo "$l.cp-1251 CP1251"
3327 + echo "$l.utf-8 UTF-8"
3329 + for l in ar ar_SA; do
3330 + echo "$l ISO-8859-6"
3331 + echo "$l.iso-8859-6 ISO-8859-6"
3332 + echo "$l.cp-864 CP864"
3333 + #echo "$l.cp-868 CP868" # not a commonly used encoding
3334 + echo "$l.cp-1256 CP1256"
3335 + echo "$l.utf-8 UTF-8"
3337 + for l in el el_GR gr gr_GR; do
3338 + echo "$l ISO-8859-7"
3339 + echo "$l.iso-8859-7 ISO-8859-7"
3340 + echo "$l.cp-869 CP869"
3341 + echo "$l.cp-1253 CP1253"
3342 + echo "$l.cp-1253@euro CP1253"
3343 + echo "$l.utf-8 UTF-8"
3344 + echo "$l.utf-8@euro UTF-8"
3346 + for l in he he_IL iw iw_IL; do
3347 + echo "$l ISO-8859-8"
3348 + echo "$l.iso-8859-8 ISO-8859-8"
3349 + echo "$l.cp-862 CP862"
3350 + echo "$l.cp-1255 CP1255"
3351 + echo "$l.utf-8 UTF-8"
3353 + for l in tr tr_TR; do
3354 + echo "$l ISO-8859-9"
3355 + echo "$l.iso-8859-9 ISO-8859-9"
3356 + echo "$l.cp-857 CP857"
3357 + echo "$l.cp-1254 CP1254"
3358 + echo "$l.utf-8 UTF-8"
3360 + for l in lt lt_LT lv lv_LV; do
3361 + #echo "$l BALTIC" # not a commonly used encoding, wrong encoding name
3362 + echo "$l ISO-8859-13"
3364 + for l in ru_UA uk uk_UA; do
3367 + for l in zh zh_CN; do
3368 + #echo "$l GB_2312-80" # not a commonly used encoding, wrong encoding name
3371 + for l in ja ja_JP ja_JP.EUC; do
3374 + for l in ko ko_KR; do
3377 + for l in th th_TH; do
3380 + for l in fa fa_IR; do
3381 + #echo "$l ISIRI-3342" # a broken encoding
3382 + echo "$l.utf-8 UTF-8"
3386 + # With glibc-2.1 or newer, we don't need any canonicalization,
3387 + # because glibc has iconv and both glibc and libiconv support all
3388 + # GNU canonical names directly. Therefore, the Makefile does not
3389 + # need to install the alias file at all.
3390 + # The following applies only to glibc-2.0.x and older libcs.
3391 + echo "ISO_646.IRV:1983 ASCII"
3394 + echo "ISO8859-1 ISO-8859-1"
3395 + echo "ISO8859-2 ISO-8859-2"
3396 + echo "ISO8859-5 ISO-8859-5"
3397 + echo "ISO8859-6 ISO-8859-6"
3398 + echo "ISO8859-7 ISO-8859-7"
3399 + echo "ISO8859-8 ISO-8859-8"
3400 + echo "ISO8859-9 ISO-8859-9"
3401 + echo "ISO8859-15 ISO-8859-15"
3402 + echo "IBM-850 CP850"
3403 + echo "IBM-856 CP856"
3404 + echo "IBM-921 ISO-8859-13"
3405 + echo "IBM-922 CP922"
3406 + echo "IBM-932 CP932"
3407 + echo "IBM-943 CP943"
3408 + echo "IBM-1046 CP1046"
3409 + echo "IBM-1124 CP1124"
3410 + echo "IBM-1129 CP1129"
3411 + echo "IBM-1252 CP1252"
3412 + echo "IBM-eucCN GB2312"
3413 + echo "IBM-eucJP EUC-JP"
3414 + echo "IBM-eucKR EUC-KR"
3415 + echo "IBM-eucTW EUC-TW"
3418 + echo "TIS-620 TIS-620"
3419 + echo "UTF-8 UTF-8"
3422 + echo "iso88591 ISO-8859-1"
3423 + echo "iso88592 ISO-8859-2"
3424 + echo "iso88595 ISO-8859-5"
3425 + echo "iso88596 ISO-8859-6"
3426 + echo "iso88597 ISO-8859-7"
3427 + echo "iso88598 ISO-8859-8"
3428 + echo "iso88599 ISO-8859-9"
3429 + echo "iso885915 ISO-8859-15"
3430 + echo "roman8 HP-ROMAN8"
3431 + echo "arabic8 HP-ARABIC8"
3432 + echo "greek8 HP-GREEK8"
3433 + echo "hebrew8 HP-HEBREW8"
3434 + echo "turkish8 HP-TURKISH8"
3435 + echo "kana8 HP-KANA8"
3436 + echo "tis620 TIS-620"
3438 + echo "eucJP EUC-JP"
3439 + echo "eucKR EUC-KR"
3440 + echo "eucTW EUC-TW"
3441 + echo "hp15CN GB2312"
3442 + #echo "ccdc ?" # what is this?
3443 + echo "SJIS SHIFT_JIS"
3447 + echo "ISO8859-1 ISO-8859-1"
3448 + echo "ISO8859-2 ISO-8859-2"
3449 + echo "ISO8859-5 ISO-8859-5"
3450 + echo "ISO8859-7 ISO-8859-7"
3451 + echo "ISO8859-9 ISO-8859-9"
3452 + echo "eucCN GB2312"
3453 + echo "eucJP EUC-JP"
3454 + echo "eucKR EUC-KR"
3455 + echo "eucTW EUC-TW"
3458 + echo "ISO8859-1 ISO-8859-1"
3459 + echo "ISO8859-2 ISO-8859-2"
3460 + echo "ISO8859-4 ISO-8859-4"
3461 + echo "ISO8859-5 ISO-8859-5"
3462 + echo "ISO8859-7 ISO-8859-7"
3463 + echo "ISO8859-8 ISO-8859-8"
3464 + echo "ISO8859-9 ISO-8859-9"
3465 + echo "ISO8859-15 ISO-8859-15"
3466 + echo "cp850 CP850"
3468 + echo "dechanyu DEC-HANYU"
3469 + echo "dechanzi GB2312"
3470 + echo "deckanji DEC-KANJI"
3471 + echo "deckorean EUC-KR"
3472 + echo "eucJP EUC-JP"
3473 + echo "eucKR EUC-KR"
3474 + echo "eucTW EUC-TW"
3476 + echo "KSC5601 CP949"
3477 + echo "sdeckanji EUC-JP"
3478 + echo "SJIS SHIFT_JIS"
3479 + echo "TACTIS TIS-620"
3480 + echo "UTF-8 UTF-8"
3484 + echo "ISO8859-1 ISO-8859-1"
3485 + echo "ISO8859-2 ISO-8859-2"
3486 + echo "ISO8859-3 ISO-8859-3"
3487 + echo "ISO8859-4 ISO-8859-4"
3488 + echo "ISO8859-5 ISO-8859-5"
3489 + echo "ISO8859-6 ISO-8859-6"
3490 + echo "ISO8859-7 ISO-8859-7"
3491 + echo "ISO8859-8 ISO-8859-8"
3492 + echo "ISO8859-9 ISO-8859-9"
3493 + echo "ISO8859-15 ISO-8859-15"
3494 + echo "koi8-r KOI8-R"
3495 + echo "ansi-1251 CP1251"
3497 + echo "Big5-HKSCS BIG5-HKSCS"
3498 + echo "gb2312 GB2312"
3500 + echo "GB18030 GB18030"
3501 + echo "cns11643 EUC-TW"
3502 + echo "5601 EUC-KR"
3503 + echo "ko_KR.johap92 JOHAB"
3504 + echo "eucJP EUC-JP"
3505 + echo "PCK SHIFT_JIS"
3506 + echo "TIS620.2533 TIS-620"
3507 + #echo "sun_eu_greek ?" # what is this?
3508 + echo "UTF-8 UTF-8"
3511 + # FreeBSD 4.2 doesn't have nl_langinfo(CODESET); therefore
3512 + # localcharset.c falls back to using the full locale name
3513 + # from the environment variables.
3514 + # Likewise for OS/2. OS/2 has XFree86 just like FreeBSD. Just
3515 + # reuse FreeBSD's locale data for OS/2.
3517 + echo "US-ASCII ASCII"
3518 + for l in la_LN lt_LN; do
3519 + echo "$l.ASCII ASCII"
3521 + for l in da_DK de_AT de_CH de_DE en_AU en_CA en_GB en_US es_ES \
3522 + fi_FI fr_BE fr_CA fr_CH fr_FR is_IS it_CH it_IT la_LN \
3523 + lt_LN nl_BE nl_NL no_NO pt_PT sv_SE; do
3524 + echo "$l.ISO_8859-1 ISO-8859-1"
3525 + echo "$l.DIS_8859-15 ISO-8859-15"
3527 + for l in cs_CZ hr_HR hu_HU la_LN lt_LN pl_PL sl_SI; do
3528 + echo "$l.ISO_8859-2 ISO-8859-2"
3530 + for l in la_LN lt_LT; do
3531 + echo "$l.ISO_8859-4 ISO-8859-4"
3533 + for l in ru_RU ru_SU; do
3534 + echo "$l.KOI8-R KOI8-R"
3535 + echo "$l.ISO_8859-5 ISO-8859-5"
3536 + echo "$l.CP866 CP866"
3538 + echo "uk_UA.KOI8-U KOI8-U"
3539 + echo "zh_TW.BIG5 BIG5"
3540 + echo "zh_TW.Big5 BIG5"
3541 + echo "zh_CN.EUC GB2312"
3542 + echo "ja_JP.EUC EUC-JP"
3543 + echo "ja_JP.SJIS SHIFT_JIS"
3544 + echo "ja_JP.Shift_JIS SHIFT_JIS"
3545 + echo "ko_KR.EUC EUC-KR"
3549 + echo "ISO8859-1 ISO-8859-1"
3550 + echo "ISO8859-2 ISO-8859-2"
3551 + echo "ISO8859-4 ISO-8859-4"
3552 + echo "ISO8859-5 ISO-8859-5"
3553 + echo "ISO8859-15 ISO-8859-15"
3554 + echo "eucCN GB2312"
3555 + echo "eucJP EUC-JP"
3556 + echo "eucKR EUC-KR"
3557 + echo "eucTW EUC-TW"
3559 + echo "SJIS SHIFT_JIS"
3562 + # Darwin 6.8 doesn't have nl_langinfo(CODESET); therefore
3563 + # localcharset.c falls back to using the full locale name
3564 + # from the environment variables.
3566 + for l in en_AU en_CA en_GB en_US la_LN; do
3567 + echo "$l.US-ASCII ASCII"
3569 + for l in da_DK de_AT de_CH de_DE en_AU en_CA en_GB en_US es_ES \
3570 + fi_FI fr_BE fr_CA fr_CH fr_FR is_IS it_CH it_IT nl_BE \
3571 + nl_NL no_NO pt_PT sv_SE; do
3572 + echo "$l ISO-8859-1"
3573 + echo "$l.ISO8859-1 ISO-8859-1"
3574 + echo "$l.ISO8859-15 ISO-8859-15"
3576 + for l in la_LN; do
3577 + echo "$l.ISO8859-1 ISO-8859-1"
3578 + echo "$l.ISO8859-15 ISO-8859-15"
3580 + for l in cs_CZ hr_HR hu_HU la_LN pl_PL sl_SI; do
3581 + echo "$l.ISO8859-2 ISO-8859-2"
3583 + for l in la_LN lt_LT; do
3584 + echo "$l.ISO8859-4 ISO-8859-4"
3586 + for l in ru_RU; do
3587 + echo "$l.KOI8-R KOI8-R"
3588 + echo "$l.ISO8859-5 ISO-8859-5"
3589 + echo "$l.CP866 CP866"
3591 + for l in bg_BG; do
3592 + echo "$l.CP1251 CP1251"
3594 + echo "uk_UA.KOI8-U KOI8-U"
3595 + echo "zh_TW.BIG5 BIG5"
3596 + echo "zh_TW.Big5 BIG5"
3597 + echo "zh_CN.EUC GB2312"
3598 + echo "ja_JP.EUC EUC-JP"
3599 + echo "ja_JP.SJIS SHIFT_JIS"
3600 + echo "ko_KR.EUC EUC-KR"
3603 + # BeOS has a single locale, and it has UTF-8 encoding.
3607 + # DJGPP 2.03 doesn't have nl_langinfo(CODESET); therefore
3608 + # localcharset.c falls back to using the full locale name
3609 + # from the environment variables.
3611 + echo "# The encodings given here may not all be correct."
3612 + echo "# If you find that the encoding given for your language and"
3613 + echo "# country is not the one your DOS machine actually uses, just"
3614 + echo "# correct it in this file, and send a mail to"
3615 + echo "# Juan Manuel Guerrero <st001906@hrz1.hrz.tu-darmstadt.de>"
3616 + echo "# and Bruno Haible <bruno@clisp.org>."
3619 + # ISO-8859-1 languages
3621 + echo "ca_ES CP850"
3622 + echo "da CP865" # not CP850 ??
3623 + echo "da_DK CP865" # not CP850 ??
3625 + echo "de_AT CP850"
3626 + echo "de_CH CP850"
3627 + echo "de_DE CP850"
3629 + echo "en_AU CP850" # not CP437 ??
3630 + echo "en_CA CP850"
3631 + echo "en_GB CP850"
3632 + echo "en_NZ CP437"
3633 + echo "en_US CP437"
3634 + echo "en_ZA CP850" # not CP437 ??
3636 + echo "es_AR CP850"
3637 + echo "es_BO CP850"
3638 + echo "es_CL CP850"
3639 + echo "es_CO CP850"
3640 + echo "es_CR CP850"
3641 + echo "es_CU CP850"
3642 + echo "es_DO CP850"
3643 + echo "es_EC CP850"
3644 + echo "es_ES CP850"
3645 + echo "es_GT CP850"
3646 + echo "es_HN CP850"
3647 + echo "es_MX CP850"
3648 + echo "es_NI CP850"
3649 + echo "es_PA CP850"
3650 + echo "es_PY CP850"
3651 + echo "es_PE CP850"
3652 + echo "es_SV CP850"
3653 + echo "es_UY CP850"
3654 + echo "es_VE CP850"
3656 + echo "et_EE CP850"
3658 + echo "eu_ES CP850"
3660 + echo "fi_FI CP850"
3662 + echo "fr_BE CP850"
3663 + echo "fr_CA CP850"
3664 + echo "fr_CH CP850"
3665 + echo "fr_FR CP850"
3667 + echo "ga_IE CP850"
3669 + echo "gd_GB CP850"
3671 + echo "gl_ES CP850"
3672 + echo "id CP850" # not CP437 ??
3673 + echo "id_ID CP850" # not CP437 ??
3674 + echo "is CP861" # not CP850 ??
3675 + echo "is_IS CP861" # not CP850 ??
3677 + echo "it_CH CP850"
3678 + echo "it_IT CP850"
3680 + echo "lt_LT CP775"
3682 + echo "lv_LV CP775"
3683 + echo "nb CP865" # not CP850 ??
3684 + echo "nb_NO CP865" # not CP850 ??
3686 + echo "nl_BE CP850"
3687 + echo "nl_NL CP850"
3688 + echo "nn CP865" # not CP850 ??
3689 + echo "nn_NO CP865" # not CP850 ??
3690 + echo "no CP865" # not CP850 ??
3691 + echo "no_NO CP865" # not CP850 ??
3693 + echo "pt_BR CP850"
3694 + echo "pt_PT CP850"
3696 + echo "sv_SE CP850"
3697 + # ISO-8859-2 languages
3699 + echo "cs_CZ CP852"
3701 + echo "hr_HR CP852"
3703 + echo "hu_HU CP852"
3705 + echo "pl_PL CP852"
3707 + echo "ro_RO CP852"
3709 + echo "sk_SK CP852"
3711 + echo "sl_SI CP852"
3713 + echo "sq_AL CP852"
3714 + echo "sr CP852" # CP852 or CP866 or CP855 ??
3715 + echo "sr_CS CP852" # CP852 or CP866 or CP855 ??
3716 + echo "sr_YU CP852" # CP852 or CP866 or CP855 ??
3717 + # ISO-8859-3 languages
3719 + echo "mt_MT CP850"
3720 + # ISO-8859-5 languages
3722 + echo "be_BE CP866"
3723 + echo "bg CP866" # not CP855 ??
3724 + echo "bg_BG CP866" # not CP855 ??
3725 + echo "mk CP866" # not CP855 ??
3726 + echo "mk_MK CP866" # not CP855 ??
3728 + echo "ru_RU CP866"
3730 + echo "uk_UA CP1125"
3731 + # ISO-8859-6 languages
3733 + echo "ar_AE CP864"
3734 + echo "ar_DZ CP864"
3735 + echo "ar_EG CP864"
3736 + echo "ar_IQ CP864"
3737 + echo "ar_IR CP864"
3738 + echo "ar_JO CP864"
3739 + echo "ar_KW CP864"
3740 + echo "ar_MA CP864"
3741 + echo "ar_OM CP864"
3742 + echo "ar_QA CP864"
3743 + echo "ar_SA CP864"
3744 + echo "ar_SY CP864"
3745 + # ISO-8859-7 languages
3747 + echo "el_GR CP869"
3748 + # ISO-8859-8 languages
3750 + echo "he_IL CP862"
3751 + # ISO-8859-9 languages
3753 + echo "tr_TR CP857"
3756 + echo "ja_JP CP932"
3759 + echo "zh_TW CP950" # not CP938 ??
3761 + echo "kr CP949" # not CP934 ??
3762 + echo "kr_KR CP949" # not CP934 ??
3765 + echo "th_TH CP874"
3768 + echo "eo_EO CP850"
3771 --- lrzsz-0.12.20.safe/intl/dcgettext.c 1998-04-26 09:22:36.000000000 -0400
3772 +++ lrzsz-0.12.20/intl/dcgettext.c 2004-09-12 14:40:34.359747480 -0400
3774 -/* Implementation of the dcgettext(3) function
3775 - Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
3776 +/* Implementation of the dcgettext(3) function.
3777 + Copyright (C) 1995-1999, 2000-2003 Free Software Foundation, Inc.
3779 - This program is free software; you can redistribute it and/or modify
3780 - it under the terms of the GNU General Public License as published by
3781 - the Free Software Foundation; either version 2, or (at your option)
3782 + This program is free software; you can redistribute it and/or modify it
3783 + under the terms of the GNU Library General Public License as published
3784 + by the Free Software Foundation; either version 2, or (at your option)
3787 This program is distributed in the hope that it will be useful,
3788 but WITHOUT ANY WARRANTY; without even the implied warranty of
3789 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3790 - GNU General Public License for more details.
3791 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
3792 + Library General Public License for more details.
3794 - You should have received a copy of the GNU General Public License
3795 - along with this program; if not, write to the Free Software Foundation,
3796 - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
3797 + You should have received a copy of the GNU Library General Public
3798 + License along with this program; if not, write to the Free Software
3799 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
3802 #ifdef HAVE_CONFIG_H
3803 # include <config.h>
3806 -#include <sys/types.h>
3809 -# define alloca __builtin_alloca
3810 -# define HAVE_ALLOCA 1
3812 -# if defined HAVE_ALLOCA_H || defined _LIBC
3813 -# include <alloca.h>
3829 -#ifndef __set_errno
3830 -# define __set_errno(val) errno = (val)
3833 -#if defined STDC_HEADERS || defined _LIBC
3834 -# include <stdlib.h>
3837 -# ifdef HAVE_MALLOC_H
3838 -# include <malloc.h>
3844 -#if defined HAVE_STRING_H || defined _LIBC
3845 -# ifndef _GNU_SOURCE
3846 -# define _GNU_SOURCE 1
3848 -# include <string.h>
3850 -# include <strings.h>
3852 -#if !HAVE_STRCHR && !defined _LIBC
3854 -# define strchr index
3858 -#if defined HAVE_UNISTD_H || defined _LIBC
3859 -# include <unistd.h>
3862 -#include "gettext.h"
3863 #include "gettextP.h"
3865 # include <libintl.h>
3867 -# include "libgettext.h"
3868 +# include "libgnuintl.h"
3870 -#include "hash-string.h"
3872 /* @@ end of prolog @@ */
3875 -/* Rename the non ANSI C functions. This is required by the standard
3876 - because some ANSI C functions will require linking with this object
3877 - file and the name space must not be polluted. */
3878 -# define getcwd __getcwd
3879 -# define stpcpy __stpcpy
3881 -# if !defined HAVE_GETCWD
3883 -# define getcwd(buf, max) getwd (buf)
3887 -# ifndef HAVE_STPCPY
3888 -static char *stpcpy PARAMS ((char *dest, const char *src));
3892 -/* Amount to increase buffer size by in each try. */
3893 -#define PATH_INCR 32
3895 -/* The following is from pathmax.h. */
3896 -/* Non-POSIX BSD systems might have gcc's limits.h, which doesn't define
3897 - PATH_MAX but might cause redefinition warnings when sys/param.h is
3898 - later included (as on MORE/BSD 4.3). */
3899 -#if defined(_POSIX_VERSION) || (defined(HAVE_LIMITS_H) && !defined(__GNUC__))
3900 -# include <limits.h>
3903 -#ifndef _POSIX_PATH_MAX
3904 -# define _POSIX_PATH_MAX 255
3907 -#if !defined(PATH_MAX) && defined(_PC_PATH_MAX)
3908 -# define PATH_MAX (pathconf ("/", _PC_PATH_MAX) < 1 ? 1024 : pathconf ("/", _PC_PATH_MAX))
3911 -/* Don't include sys/param.h if it already has been. */
3912 -#if defined(HAVE_SYS_PARAM_H) && !defined(PATH_MAX) && !defined(MAXPATHLEN)
3913 -# include <sys/param.h>
3916 -#if !defined(PATH_MAX) && defined(MAXPATHLEN)
3917 -# define PATH_MAX MAXPATHLEN
3921 -# define PATH_MAX _POSIX_PATH_MAX
3924 -/* XPG3 defines the result of `setlocale (category, NULL)' as:
3925 - ``Directs `setlocale()' to query `category' and return the current
3926 - setting of `local'.''
3927 - However it does not specify the exact format. And even worse: POSIX
3928 - defines this not at all. So we can use this feature only on selected
3929 - system (e.g. those using GNU C Library). */
3931 -# define HAVE_LOCALE_NULL
3934 -/* Name of the default domain used for gettext(3) prior any call to
3935 - textdomain(3). The default value for this is "messages". */
3936 -const char _nl_default_default_domain[] = "messages";
3938 -/* Value used as the default domain for gettext(3). */
3939 -const char *_nl_current_default_domain = _nl_default_default_domain;
3941 -/* Contains the default location of the message catalogs. */
3942 -const char _nl_default_dirname[] = GNULOCALEDIR;
3944 -/* List with bindings of specific domains created by bindtextdomain()
3946 -struct binding *_nl_domain_bindings;
3948 -/* Prototypes for local functions. */
3949 -static char *find_msg PARAMS ((struct loaded_l10nfile *domain_file,
3950 - const char *msgid));
3951 -static const char *category_to_name PARAMS ((int category));
3952 -static const char *guess_category_value PARAMS ((int category,
3953 - const char *categoryname));
3956 -/* For those loosing systems which don't have `alloca' we have to add
3957 - some additional code emulating it. */
3959 -/* Nothing has to be done. */
3960 -# define ADD_BLOCK(list, address) /* nothing */
3961 -# define FREE_BLOCKS(list) /* nothing */
3966 - struct block_list *next;
3968 -# define ADD_BLOCK(list, addr) \
3970 - struct block_list *newp = (struct block_list *) malloc (sizeof (*newp)); \
3971 - /* If we cannot get a free block we cannot add the new element to \
3973 - if (newp != NULL) { \
3974 - newp->address = (addr); \
3975 - newp->next = (list); \
3979 -# define FREE_BLOCKS(list) \
3981 - while (list != NULL) { \
3982 - struct block_list *old = list; \
3983 - list = list->next; \
3988 -# define alloca(size) (malloc (size))
3989 -#endif /* have alloca */
3992 /* Names for the libintl functions are a problem. They must not clash
3993 with existing names and they should follow ANSI C. But this source
3994 code is also used in GNU C Library where the names have a __
3995 prefix. So we have to make a difference here. */
3997 # define DCGETTEXT __dcgettext
3998 +# define DCIGETTEXT __dcigettext
4000 -# define DCGETTEXT dcgettext__
4001 +# define DCGETTEXT libintl_dcgettext
4002 +# define DCIGETTEXT libintl_dcigettext
4005 /* Look up MSGID in the DOMAINNAME message catalog for the current CATEGORY
4008 -DCGETTEXT (domainname, msgid, category)
4009 - const char *domainname;
4010 - const char *msgid;
4012 +DCGETTEXT (const char *domainname, const char *msgid, int category)
4014 -#ifndef HAVE_ALLOCA
4015 - struct block_list *block_list = NULL;
4017 - struct loaded_l10nfile *domain;
4018 - struct binding *binding;
4019 - const char *categoryname;
4020 - const char *categoryvalue;
4021 - char *dirname, *xdomainname;
4022 - char *single_locale;
4024 - int saved_errno = errno;
4026 - /* If no real MSGID is given return NULL. */
4027 - if (msgid == NULL)
4030 - /* If DOMAINNAME is NULL, we are interested in the default domain. If
4031 - CATEGORY is not LC_MESSAGES this might not make much sense but the
4032 - defintion left this undefined. */
4033 - if (domainname == NULL)
4034 - domainname = _nl_current_default_domain;
4036 - /* First find matching binding. */
4037 - for (binding = _nl_domain_bindings; binding != NULL; binding = binding->next)
4039 - int compare = strcmp (domainname, binding->domainname);
4041 - /* We found it! */
4045 - /* It is not in the list. */
4051 - if (binding == NULL)
4052 - dirname = (char *) _nl_default_dirname;
4053 - else if (binding->dirname[0] == '/')
4054 - dirname = binding->dirname;
4057 - /* We have a relative path. Make it absolute now. */
4058 - size_t dirname_len = strlen (binding->dirname) + 1;
4062 - path_max = (unsigned) PATH_MAX;
4063 - path_max += 2; /* The getcwd docs say to do this. */
4065 - dirname = (char *) alloca (path_max + dirname_len);
4066 - ADD_BLOCK (block_list, dirname);
4069 - while ((ret = getcwd (dirname, path_max)) == NULL && errno == ERANGE)
4071 - path_max += PATH_INCR;
4072 - dirname = (char *) alloca (path_max + dirname_len);
4073 - ADD_BLOCK (block_list, dirname);
4079 - /* We cannot get the current working directory. Don't signal an
4080 - error but simply return the default string. */
4081 - FREE_BLOCKS (block_list);
4082 - __set_errno (saved_errno);
4083 - return (char *) msgid;
4086 - stpcpy (stpcpy (strchr (dirname, '\0'), "/"), binding->dirname);
4089 - /* Now determine the symbolic name of CATEGORY and its value. */
4090 - categoryname = category_to_name (category);
4091 - categoryvalue = guess_category_value (category, categoryname);
4093 - xdomainname = (char *) alloca (strlen (categoryname)
4094 - + strlen (domainname) + 5);
4095 - ADD_BLOCK (block_list, xdomainname);
4097 - stpcpy (stpcpy (stpcpy (stpcpy (xdomainname, categoryname), "/"),
4101 - /* Creating working area. */
4102 - single_locale = (char *) alloca (strlen (categoryvalue) + 1);
4103 - ADD_BLOCK (block_list, single_locale);
4106 - /* Search for the given string. This is a loop because we perhaps
4107 - got an ordered list of languages to consider for th translation. */
4110 - /* Make CATEGORYVALUE point to the next element of the list. */
4111 - while (categoryvalue[0] != '\0' && categoryvalue[0] == ':')
4113 - if (categoryvalue[0] == '\0')
4115 - /* The whole contents of CATEGORYVALUE has been searched but
4116 - no valid entry has been found. We solve this situation
4117 - by implicitly appending a "C" entry, i.e. no translation
4118 - will take place. */
4119 - single_locale[0] = 'C';
4120 - single_locale[1] = '\0';
4124 - char *cp = single_locale;
4125 - while (categoryvalue[0] != '\0' && categoryvalue[0] != ':')
4126 - *cp++ = *categoryvalue++;
4130 - /* If the current locale value is C (or POSIX) we don't load a
4131 - domain. Return the MSGID. */
4132 - if (strcmp (single_locale, "C") == 0
4133 - || strcmp (single_locale, "POSIX") == 0)
4135 - FREE_BLOCKS (block_list);
4136 - __set_errno (saved_errno);
4137 - return (char *) msgid;
4141 - /* Find structure describing the message catalog matching the
4142 - DOMAINNAME and CATEGORY. */
4143 - domain = _nl_find_domain (dirname, single_locale, xdomainname);
4145 - if (domain != NULL)
4147 - retval = find_msg (domain, msgid);
4149 - if (retval == NULL)
4153 - for (cnt = 0; domain->successor[cnt] != NULL; ++cnt)
4155 - retval = find_msg (domain->successor[cnt], msgid);
4157 - if (retval != NULL)
4162 - if (retval != NULL)
4164 - FREE_BLOCKS (block_list);
4165 - __set_errno (saved_errno);
4171 + return DCIGETTEXT (domainname, msgid, NULL, 0, 0, category);
4175 /* Alias for function name in GNU C Library. */
4176 +INTDEF(__dcgettext)
4177 weak_alias (__dcgettext, dcgettext);
4182 -find_msg (domain_file, msgid)
4183 - struct loaded_l10nfile *domain_file;
4184 - const char *msgid;
4186 - size_t top, act, bottom;
4187 - struct loaded_domain *domain;
4189 - if (domain_file->decided == 0)
4190 - _nl_load_domain (domain_file);
4192 - if (domain_file->data == NULL)
4195 - domain = (struct loaded_domain *) domain_file->data;
4197 - /* Locate the MSGID and its translation. */
4198 - if (domain->hash_size > 2 && domain->hash_tab != NULL)
4200 - /* Use the hashing table. */
4201 - nls_uint32 len = strlen (msgid);
4202 - nls_uint32 hash_val = hash_string (msgid);
4203 - nls_uint32 idx = hash_val % domain->hash_size;
4204 - nls_uint32 incr = 1 + (hash_val % (domain->hash_size - 2));
4205 - nls_uint32 nstr = W (domain->must_swap, domain->hash_tab[idx]);
4208 - /* Hash table entry is empty. */
4211 - if (W (domain->must_swap, domain->orig_tab[nstr - 1].length) == len
4213 - domain->data + W (domain->must_swap,
4214 - domain->orig_tab[nstr - 1].offset)) == 0)
4215 - return (char *) domain->data + W (domain->must_swap,
4216 - domain->trans_tab[nstr - 1].offset);
4220 - if (idx >= domain->hash_size - incr)
4221 - idx -= domain->hash_size - incr;
4225 - nstr = W (domain->must_swap, domain->hash_tab[idx]);
4227 - /* Hash table entry is empty. */
4230 - if (W (domain->must_swap, domain->orig_tab[nstr - 1].length) == len
4232 - domain->data + W (domain->must_swap,
4233 - domain->orig_tab[nstr - 1].offset))
4235 - return (char *) domain->data
4236 - + W (domain->must_swap, domain->trans_tab[nstr - 1].offset);
4241 - /* Now we try the default method: binary search in the sorted
4242 - array of messages. */
4244 - top = domain->nstrings;
4245 - while (bottom < top)
4249 - act = (bottom + top) / 2;
4250 - cmp_val = strcmp (msgid, domain->data
4251 - + W (domain->must_swap,
4252 - domain->orig_tab[act].offset));
4255 - else if (cmp_val > 0)
4261 - /* If an translation is found return this. */
4262 - return bottom >= top ? NULL : (char *) domain->data
4263 - + W (domain->must_swap,
4264 - domain->trans_tab[act].offset);
4268 -/* Return string representation of locale CATEGORY. */
4269 -static const char *
4270 -category_to_name (category)
4273 - const char *retval;
4279 - retval = "LC_COLLATE";
4284 - retval = "LC_CTYPE";
4289 - retval = "LC_MONETARY";
4294 - retval = "LC_NUMERIC";
4299 - retval = "LC_TIME";
4304 - retval = "LC_MESSAGES";
4309 - retval = "LC_RESPONSE";
4314 - /* This might not make sense but is perhaps better than any other
4316 - retval = "LC_ALL";
4320 - /* If you have a better idea for a default value let me know. */
4321 - retval = "LC_XXX";
4327 -/* Guess value of current locale from value of the environment variables. */
4328 -static const char *
4329 -guess_category_value (category, categoryname)
4331 - const char *categoryname;
4333 - const char *retval;
4335 - /* The highest priority value is the `LANGUAGE' environment
4336 - variable. This is a GNU extension. */
4337 - retval = getenv ("LANGUAGE");
4338 - if (retval != NULL && retval[0] != '\0')
4341 - /* `LANGUAGE' is not set. So we have to proceed with the POSIX
4342 - methods of looking to `LC_ALL', `LC_xxx', and `LANG'. On some
4343 - systems this can be done by the `setlocale' function itself. */
4344 -#if defined HAVE_SETLOCALE && defined HAVE_LC_MESSAGES && defined HAVE_LOCALE_NULL
4345 - return setlocale (category, NULL);
4347 - /* Setting of LC_ALL overwrites all other. */
4348 - retval = getenv ("LC_ALL");
4349 - if (retval != NULL && retval[0] != '\0')
4352 - /* Next comes the name of the desired category. */
4353 - retval = getenv (categoryname);
4354 - if (retval != NULL && retval[0] != '\0')
4357 - /* Last possibility is the LANG environment variable. */
4358 - retval = getenv ("LANG");
4359 - if (retval != NULL && retval[0] != '\0')
4362 - /* We use C as the default domain. POSIX says this is implementation
4368 -/* @@ begin of epilog @@ */
4370 -/* We don't want libintl.a to depend on any other library. So we
4371 - avoid the non-standard function stpcpy. In GNU C Library this
4372 - function is available, though. Also allow the symbol HAVE_STPCPY
4374 -#if !_LIBC && !HAVE_STPCPY
4380 - while ((*dest++ = *src++) != '\0')
4381 - /* Do nothing. */ ;
4385 --- lrzsz-0.12.20.safe/intl/dcigettext.c 1969-12-31 19:00:00.000000000 -0500
4386 +++ lrzsz-0.12.20/intl/dcigettext.c 2004-09-12 14:40:34.369745960 -0400
4388 +/* Implementation of the internal dcigettext function.
4389 + Copyright (C) 1995-1999, 2000-2003 Free Software Foundation, Inc.
4391 + This program is free software; you can redistribute it and/or modify it
4392 + under the terms of the GNU Library General Public License as published
4393 + by the Free Software Foundation; either version 2, or (at your option)
4394 + any later version.
4396 + This program is distributed in the hope that it will be useful,
4397 + but WITHOUT ANY WARRANTY; without even the implied warranty of
4398 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
4399 + Library General Public License for more details.
4401 + You should have received a copy of the GNU Library General Public
4402 + License along with this program; if not, write to the Free Software
4403 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
4406 +/* Tell glibc's <string.h> to provide a prototype for mempcpy().
4407 + This must come before <config.h> because <config.h> may include
4408 + <features.h>, and once <features.h> has been included, it's too late. */
4409 +#ifndef _GNU_SOURCE
4410 +# define _GNU_SOURCE 1
4413 +#ifdef HAVE_CONFIG_H
4414 +# include <config.h>
4417 +#include <sys/types.h>
4420 +# define alloca __builtin_alloca
4421 +# define HAVE_ALLOCA 1
4424 +# include <malloc.h>
4425 +# define alloca _alloca
4427 +# if defined HAVE_ALLOCA_H || defined _LIBC
4428 +# include <alloca.h>
4445 +#ifndef __set_errno
4446 +# define __set_errno(val) errno = (val)
4449 +#include <stddef.h>
4450 +#include <stdlib.h>
4451 +#include <string.h>
4453 +#if defined HAVE_UNISTD_H || defined _LIBC
4454 +# include <unistd.h>
4457 +#include <locale.h>
4460 + /* Guess whether integer division by zero raises signal SIGFPE.
4461 + Set to 1 only if you know for sure. In case of doubt, set to 0. */
4462 +# if defined __alpha__ || defined __arm__ || defined __i386__ \
4463 + || defined __m68k__ || defined __s390__
4464 +# define INTDIV0_RAISES_SIGFPE 1
4466 +# define INTDIV0_RAISES_SIGFPE 0
4469 +#if !INTDIV0_RAISES_SIGFPE
4470 +# include <signal.h>
4473 +#if defined HAVE_SYS_PARAM_H || defined _LIBC
4474 +# include <sys/param.h>
4477 +#include "gettextP.h"
4478 +#include "plural-exp.h"
4480 +# include <libintl.h>
4482 +# include "libgnuintl.h"
4484 +#include "hash-string.h"
4486 +/* Thread safetyness. */
4488 +# include <bits/libc-lock.h>
4490 +/* Provide dummy implementation if this is outside glibc. */
4491 +# define __libc_lock_define_initialized(CLASS, NAME)
4492 +# define __libc_lock_lock(NAME)
4493 +# define __libc_lock_unlock(NAME)
4494 +# define __libc_rwlock_define_initialized(CLASS, NAME)
4495 +# define __libc_rwlock_rdlock(NAME)
4496 +# define __libc_rwlock_unlock(NAME)
4499 +/* Alignment of types. */
4500 +#if defined __GNUC__ && __GNUC__ >= 2
4501 +# define alignof(TYPE) __alignof__ (TYPE)
4503 +# define alignof(TYPE) \
4504 + ((int) &((struct { char dummy1; TYPE dummy2; } *) 0)->dummy2)
4507 +/* The internal variables in the standalone libintl.a must have different
4508 + names than the internal variables in GNU libc, otherwise programs
4509 + using libintl.a cannot be linked statically. */
4511 +# define _nl_default_default_domain libintl_nl_default_default_domain
4512 +# define _nl_current_default_domain libintl_nl_current_default_domain
4513 +# define _nl_default_dirname libintl_nl_default_dirname
4514 +# define _nl_domain_bindings libintl_nl_domain_bindings
4517 +/* Some compilers, like SunOS4 cc, don't have offsetof in <stddef.h>. */
4519 +# define offsetof(type,ident) ((size_t)&(((type*)0)->ident))
4522 +/* @@ end of prolog @@ */
4525 +/* Rename the non ANSI C functions. This is required by the standard
4526 + because some ANSI C functions will require linking with this object
4527 + file and the name space must not be polluted. */
4528 +# define getcwd __getcwd
4530 +# define stpcpy __stpcpy
4532 +# define tfind __tfind
4534 +# if !defined HAVE_GETCWD
4536 +# define getcwd(buf, max) getwd (buf)
4539 +# define getcwd(buf, max) (getcwd) (buf, max, 0)
4544 +# ifndef HAVE_STPCPY
4545 +static char *stpcpy (char *dest, const char *src);
4547 +# ifndef HAVE_MEMPCPY
4548 +static void *mempcpy (void *dest, const void *src, size_t n);
4552 +/* Amount to increase buffer size by in each try. */
4553 +#define PATH_INCR 32
4555 +/* The following is from pathmax.h. */
4556 +/* Non-POSIX BSD systems might have gcc's limits.h, which doesn't define
4557 + PATH_MAX but might cause redefinition warnings when sys/param.h is
4558 + later included (as on MORE/BSD 4.3). */
4559 +#if defined _POSIX_VERSION || (defined HAVE_LIMITS_H && !defined __GNUC__)
4560 +# include <limits.h>
4563 +#ifndef _POSIX_PATH_MAX
4564 +# define _POSIX_PATH_MAX 255
4567 +#if !defined PATH_MAX && defined _PC_PATH_MAX
4568 +# define PATH_MAX (pathconf ("/", _PC_PATH_MAX) < 1 ? 1024 : pathconf ("/", _PC_PATH_MAX))
4571 +/* Don't include sys/param.h if it already has been. */
4572 +#if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
4573 +# include <sys/param.h>
4576 +#if !defined PATH_MAX && defined MAXPATHLEN
4577 +# define PATH_MAX MAXPATHLEN
4581 +# define PATH_MAX _POSIX_PATH_MAX
4584 +/* Pathname support.
4585 + ISSLASH(C) tests whether C is a directory separator character.
4586 + IS_ABSOLUTE_PATH(P) tests whether P is an absolute path. If it is not,
4587 + it may be concatenated to a directory pathname.
4588 + IS_PATH_WITH_DIR(P) tests whether P contains a directory specification.
4590 +#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
4591 + /* Win32, OS/2, DOS */
4592 +# define ISSLASH(C) ((C) == '/' || (C) == '\\')
4593 +# define HAS_DEVICE(P) \
4594 + ((((P)[0] >= 'A' && (P)[0] <= 'Z') || ((P)[0] >= 'a' && (P)[0] <= 'z')) \
4596 +# define IS_ABSOLUTE_PATH(P) (ISSLASH ((P)[0]) || HAS_DEVICE (P))
4597 +# define IS_PATH_WITH_DIR(P) \
4598 + (strchr (P, '/') != NULL || strchr (P, '\\') != NULL || HAS_DEVICE (P))
4601 +# define ISSLASH(C) ((C) == '/')
4602 +# define IS_ABSOLUTE_PATH(P) ISSLASH ((P)[0])
4603 +# define IS_PATH_WITH_DIR(P) (strchr (P, '/') != NULL)
4606 +/* This is the type used for the search tree where known translations
4608 +struct known_translation_t
4610 + /* Domain in which to search. */
4613 + /* The category. */
4616 + /* State of the catalog counter at the point the string was found. */
4619 + /* Catalog where the string was found. */
4620 + struct loaded_l10nfile *domain;
4622 + /* And finally the translation. */
4623 + const char *translation;
4624 + size_t translation_length;
4626 + /* Pointer to the string in question. */
4630 +/* Root of the search tree with known translations. We can use this
4631 + only if the system provides the `tsearch' function family. */
4632 +#if defined HAVE_TSEARCH || defined _LIBC
4633 +# include <search.h>
4638 +# define tsearch __tsearch
4641 +/* Function to compare two entries in the table of known translations. */
4643 +transcmp (const void *p1, const void *p2)
4645 + const struct known_translation_t *s1;
4646 + const struct known_translation_t *s2;
4649 + s1 = (const struct known_translation_t *) p1;
4650 + s2 = (const struct known_translation_t *) p2;
4652 + result = strcmp (s1->msgid, s2->msgid);
4655 + result = strcmp (s1->domainname, s2->domainname);
4657 + /* We compare the category last (though this is the cheapest
4658 + operation) since it is hopefully always the same (namely
4660 + result = s1->category - s2->category;
4668 +# define INTVARDEF(name)
4671 +# define INTUSE(name) name
4674 +/* Name of the default domain used for gettext(3) prior any call to
4675 + textdomain(3). The default value for this is "messages". */
4676 +const char _nl_default_default_domain[] attribute_hidden = "messages";
4678 +/* Value used as the default domain for gettext(3). */
4679 +const char *_nl_current_default_domain attribute_hidden
4680 + = _nl_default_default_domain;
4682 +/* Contains the default location of the message catalogs. */
4683 +#if defined __EMX__
4684 +extern const char _nl_default_dirname[];
4686 +const char _nl_default_dirname[] = LOCALEDIR;
4687 +INTVARDEF (_nl_default_dirname)
4690 +/* List with bindings of specific domains created by bindtextdomain()
4692 +struct binding *_nl_domain_bindings;
4694 +/* Prototypes for local functions. */
4695 +static char *plural_lookup (struct loaded_l10nfile *domain,
4696 + unsigned long int n,
4697 + const char *translation, size_t translation_len)
4698 + internal_function;
4699 +static const char *guess_category_value (int category,
4700 + const char *categoryname)
4701 + internal_function;
4703 +# include "../locale/localeinfo.h"
4704 +# define category_to_name(category) _nl_category_names[category]
4706 +static const char *category_to_name (int category) internal_function;
4710 +/* For those loosing systems which don't have `alloca' we have to add
4711 + some additional code emulating it. */
4713 +/* Nothing has to be done. */
4714 +# define freea(p) /* nothing */
4715 +# define ADD_BLOCK(list, address) /* nothing */
4716 +# define FREE_BLOCKS(list) /* nothing */
4721 + struct block_list *next;
4723 +# define ADD_BLOCK(list, addr) \
4725 + struct block_list *newp = (struct block_list *) malloc (sizeof (*newp)); \
4726 + /* If we cannot get a free block we cannot add the new element to \
4728 + if (newp != NULL) { \
4729 + newp->address = (addr); \
4730 + newp->next = (list); \
4734 +# define FREE_BLOCKS(list) \
4736 + while (list != NULL) { \
4737 + struct block_list *old = list; \
4738 + list = list->next; \
4739 + free (old->address); \
4744 +# define alloca(size) (malloc (size))
4745 +# define freea(p) free (p)
4746 +#endif /* have alloca */
4750 +/* List of blocks allocated for translations. */
4751 +typedef struct transmem_list
4753 + struct transmem_list *next;
4755 +} transmem_block_t;
4756 +static struct transmem_list *transmem_list;
4758 +typedef unsigned char transmem_block_t;
4762 +/* Names for the libintl functions are a problem. They must not clash
4763 + with existing names and they should follow ANSI C. But this source
4764 + code is also used in GNU C Library where the names have a __
4765 + prefix. So we have to make a difference here. */
4767 +# define DCIGETTEXT __dcigettext
4769 +# define DCIGETTEXT libintl_dcigettext
4772 +/* Lock variable to protect the global data in the gettext implementation. */
4774 +__libc_rwlock_define_initialized (, _nl_state_lock attribute_hidden)
4777 +/* Checking whether the binaries runs SUID must be done and glibc provides
4778 + easier methods therefore we make a difference here. */
4780 +# define ENABLE_SECURE __libc_enable_secure
4781 +# define DETERMINE_SECURE
4783 +# ifndef HAVE_GETUID
4784 +# define getuid() 0
4786 +# ifndef HAVE_GETGID
4787 +# define getgid() 0
4789 +# ifndef HAVE_GETEUID
4790 +# define geteuid() getuid()
4792 +# ifndef HAVE_GETEGID
4793 +# define getegid() getgid()
4795 +static int enable_secure;
4796 +# define ENABLE_SECURE (enable_secure == 1)
4797 +# define DETERMINE_SECURE \
4798 + if (enable_secure == 0) \
4800 + if (getuid () != geteuid () || getgid () != getegid ()) \
4801 + enable_secure = 1; \
4803 + enable_secure = -1; \
4807 +/* Get the function to evaluate the plural expression. */
4808 +#include "eval-plural.h"
4810 +/* Look up MSGID in the DOMAINNAME message catalog for the current
4811 + CATEGORY locale and, if PLURAL is nonzero, search over string
4812 + depending on the plural form determined by N. */
4814 +DCIGETTEXT (const char *domainname, const char *msgid1, const char *msgid2,
4815 + int plural, unsigned long int n, int category)
4817 +#ifndef HAVE_ALLOCA
4818 + struct block_list *block_list = NULL;
4820 + struct loaded_l10nfile *domain;
4821 + struct binding *binding;
4822 + const char *categoryname;
4823 + const char *categoryvalue;
4824 + char *dirname, *xdomainname;
4825 + char *single_locale;
4829 +#if defined HAVE_TSEARCH || defined _LIBC
4830 + struct known_translation_t *search;
4831 + struct known_translation_t **foundp = NULL;
4834 + size_t domainname_len;
4836 + /* If no real MSGID is given return NULL. */
4837 + if (msgid1 == NULL)
4841 + if (category < 0 || category >= __LC_LAST || category == LC_ALL)
4843 + return (plural == 0
4845 + /* Use the Germanic plural rule. */
4846 + : n == 1 ? (char *) msgid1 : (char *) msgid2);
4849 + __libc_rwlock_rdlock (_nl_state_lock);
4851 + /* If DOMAINNAME is NULL, we are interested in the default domain. If
4852 + CATEGORY is not LC_MESSAGES this might not make much sense but the
4853 + definition left this undefined. */
4854 + if (domainname == NULL)
4855 + domainname = _nl_current_default_domain;
4857 + /* OS/2 specific: backward compatibility with older libintl versions */
4858 +#ifdef LC_MESSAGES_COMPAT
4859 + if (category == LC_MESSAGES_COMPAT)
4860 + category = LC_MESSAGES;
4863 +#if defined HAVE_TSEARCH || defined _LIBC
4864 + msgid_len = strlen (msgid1) + 1;
4866 + /* Try to find the translation among those which we found at
4868 + search = (struct known_translation_t *)
4869 + alloca (offsetof (struct known_translation_t, msgid) + msgid_len);
4870 + memcpy (search->msgid, msgid1, msgid_len);
4871 + search->domainname = (char *) domainname;
4872 + search->category = category;
4874 + foundp = (struct known_translation_t **) tfind (search, &root, transcmp);
4876 + if (foundp != NULL && (*foundp)->counter == _nl_msg_cat_cntr)
4878 + /* Now deal with plural. */
4880 + retval = plural_lookup ((*foundp)->domain, n, (*foundp)->translation,
4881 + (*foundp)->translation_length);
4883 + retval = (char *) (*foundp)->translation;
4885 + __libc_rwlock_unlock (_nl_state_lock);
4890 + /* Preserve the `errno' value. */
4891 + saved_errno = errno;
4893 + /* See whether this is a SUID binary or not. */
4896 + /* First find matching binding. */
4897 + for (binding = _nl_domain_bindings; binding != NULL; binding = binding->next)
4899 + int compare = strcmp (domainname, binding->domainname);
4901 + /* We found it! */
4905 + /* It is not in the list. */
4911 + if (binding == NULL)
4912 + dirname = (char *) INTUSE(_nl_default_dirname);
4913 + else if (IS_ABSOLUTE_PATH (binding->dirname))
4914 + dirname = binding->dirname;
4917 + /* We have a relative path. Make it absolute now. */
4918 + size_t dirname_len = strlen (binding->dirname) + 1;
4922 + path_max = (unsigned int) PATH_MAX;
4923 + path_max += 2; /* The getcwd docs say to do this. */
4927 + dirname = (char *) alloca (path_max + dirname_len);
4928 + ADD_BLOCK (block_list, dirname);
4931 + ret = getcwd (dirname, path_max);
4932 + if (ret != NULL || errno != ERANGE)
4935 + path_max += path_max / 2;
4936 + path_max += PATH_INCR;
4940 + /* We cannot get the current working directory. Don't signal an
4941 + error but simply return the default string. */
4942 + goto return_untranslated;
4944 + stpcpy (stpcpy (strchr (dirname, '\0'), "/"), binding->dirname);
4947 + /* Now determine the symbolic name of CATEGORY and its value. */
4948 + categoryname = category_to_name (category);
4949 + categoryvalue = guess_category_value (category, categoryname);
4951 + domainname_len = strlen (domainname);
4952 + xdomainname = (char *) alloca (strlen (categoryname)
4953 + + domainname_len + 5);
4954 + ADD_BLOCK (block_list, xdomainname);
4956 + stpcpy (mempcpy (stpcpy (stpcpy (xdomainname, categoryname), "/"),
4957 + domainname, domainname_len),
4960 + /* Creating working area. */
4961 + single_locale = (char *) alloca (strlen (categoryvalue) + 1);
4962 + ADD_BLOCK (block_list, single_locale);
4965 + /* Search for the given string. This is a loop because we perhaps
4966 + got an ordered list of languages to consider for the translation. */
4969 + /* Make CATEGORYVALUE point to the next element of the list. */
4970 + while (categoryvalue[0] != '\0' && categoryvalue[0] == ':')
4972 + if (categoryvalue[0] == '\0')
4974 + /* The whole contents of CATEGORYVALUE has been searched but
4975 + no valid entry has been found. We solve this situation
4976 + by implicitly appending a "C" entry, i.e. no translation
4977 + will take place. */
4978 + single_locale[0] = 'C';
4979 + single_locale[1] = '\0';
4983 + char *cp = single_locale;
4984 + while (categoryvalue[0] != '\0' && categoryvalue[0] != ':')
4985 + *cp++ = *categoryvalue++;
4988 + /* When this is a SUID binary we must not allow accessing files
4989 + outside the dedicated directories. */
4990 + if (ENABLE_SECURE && IS_PATH_WITH_DIR (single_locale))
4991 + /* Ingore this entry. */
4995 + /* If the current locale value is C (or POSIX) we don't load a
4996 + domain. Return the MSGID. */
4997 + if (strcmp (single_locale, "C") == 0
4998 + || strcmp (single_locale, "POSIX") == 0)
5001 + /* Find structure describing the message catalog matching the
5002 + DOMAINNAME and CATEGORY. */
5003 + domain = _nl_find_domain (dirname, single_locale, xdomainname, binding);
5005 + if (domain != NULL)
5007 + retval = _nl_find_msg (domain, binding, msgid1, &retlen);
5009 + if (retval == NULL)
5013 + for (cnt = 0; domain->successor[cnt] != NULL; ++cnt)
5015 + retval = _nl_find_msg (domain->successor[cnt], binding,
5018 + if (retval != NULL)
5020 + domain = domain->successor[cnt];
5026 + if (retval != NULL)
5028 + /* Found the translation of MSGID1 in domain DOMAIN:
5029 + starting at RETVAL, RETLEN bytes. */
5030 + FREE_BLOCKS (block_list);
5031 +#if defined HAVE_TSEARCH || defined _LIBC
5032 + if (foundp == NULL)
5034 + /* Create a new entry and add it to the search tree. */
5035 + struct known_translation_t *newp;
5037 + newp = (struct known_translation_t *)
5038 + malloc (offsetof (struct known_translation_t, msgid)
5039 + + msgid_len + domainname_len + 1);
5042 + newp->domainname =
5043 + mempcpy (newp->msgid, msgid1, msgid_len);
5044 + memcpy (newp->domainname, domainname, domainname_len + 1);
5045 + newp->category = category;
5046 + newp->counter = _nl_msg_cat_cntr;
5047 + newp->domain = domain;
5048 + newp->translation = retval;
5049 + newp->translation_length = retlen;
5051 + /* Insert the entry in the search tree. */
5052 + foundp = (struct known_translation_t **)
5053 + tsearch (newp, &root, transcmp);
5054 + if (foundp == NULL
5055 + || __builtin_expect (*foundp != newp, 0))
5056 + /* The insert failed. */
5062 + /* We can update the existing entry. */
5063 + (*foundp)->counter = _nl_msg_cat_cntr;
5064 + (*foundp)->domain = domain;
5065 + (*foundp)->translation = retval;
5066 + (*foundp)->translation_length = retlen;
5069 + __set_errno (saved_errno);
5071 + /* Now deal with plural. */
5073 + retval = plural_lookup (domain, n, retval, retlen);
5075 + __libc_rwlock_unlock (_nl_state_lock);
5081 + return_untranslated:
5082 + /* Return the untranslated MSGID. */
5083 + FREE_BLOCKS (block_list);
5084 + __libc_rwlock_unlock (_nl_state_lock);
5086 + if (!ENABLE_SECURE)
5088 + extern void _nl_log_untranslated (const char *logfilename,
5089 + const char *domainname,
5090 + const char *msgid1, const char *msgid2,
5092 + const char *logfilename = getenv ("GETTEXT_LOG_UNTRANSLATED");
5094 + if (logfilename != NULL && logfilename[0] != '\0')
5095 + _nl_log_untranslated (logfilename, domainname, msgid1, msgid2, plural);
5098 + __set_errno (saved_errno);
5099 + return (plural == 0
5101 + /* Use the Germanic plural rule. */
5102 + : n == 1 ? (char *) msgid1 : (char *) msgid2);
5108 +_nl_find_msg (struct loaded_l10nfile *domain_file,
5109 + struct binding *domainbinding, const char *msgid,
5112 + struct loaded_domain *domain;
5113 + nls_uint32 nstrings;
5118 + if (domain_file->decided == 0)
5119 + _nl_load_domain (domain_file, domainbinding);
5121 + if (domain_file->data == NULL)
5124 + domain = (struct loaded_domain *) domain_file->data;
5126 + nstrings = domain->nstrings;
5128 + /* Locate the MSGID and its translation. */
5129 + if (domain->hash_tab != NULL)
5131 + /* Use the hashing table. */
5132 + nls_uint32 len = strlen (msgid);
5133 + nls_uint32 hash_val = hash_string (msgid);
5134 + nls_uint32 idx = hash_val % domain->hash_size;
5135 + nls_uint32 incr = 1 + (hash_val % (domain->hash_size - 2));
5140 + W (domain->must_swap_hash_tab, domain->hash_tab[idx]);
5143 + /* Hash table entry is empty. */
5148 + /* Compare msgid with the original string at index nstr.
5149 + We compare the lengths with >=, not ==, because plural entries
5150 + are represented by strings with an embedded NUL. */
5151 + if (nstr < nstrings
5152 + ? W (domain->must_swap, domain->orig_tab[nstr].length) >= len
5153 + && (strcmp (msgid,
5154 + domain->data + W (domain->must_swap,
5155 + domain->orig_tab[nstr].offset))
5157 + : domain->orig_sysdep_tab[nstr - nstrings].length > len
5158 + && (strcmp (msgid,
5159 + domain->orig_sysdep_tab[nstr - nstrings].pointer)
5166 + if (idx >= domain->hash_size - incr)
5167 + idx -= domain->hash_size - incr;
5175 + /* Try the default method: binary search in the sorted array of
5177 + size_t top, bottom;
5181 + while (bottom < top)
5185 + act = (bottom + top) / 2;
5186 + cmp_val = strcmp (msgid, (domain->data
5187 + + W (domain->must_swap,
5188 + domain->orig_tab[act].offset)));
5191 + else if (cmp_val > 0)
5196 + /* No translation was found. */
5201 + /* The translation was found at index ACT. If we have to convert the
5202 + string to use a different character set, this is the time. */
5203 + if (act < nstrings)
5206 + (domain->data + W (domain->must_swap, domain->trans_tab[act].offset));
5207 + resultlen = W (domain->must_swap, domain->trans_tab[act].length) + 1;
5211 + result = (char *) domain->trans_sysdep_tab[act - nstrings].pointer;
5212 + resultlen = domain->trans_sysdep_tab[act - nstrings].length;
5215 +#if defined _LIBC || HAVE_ICONV
5216 + if (domain->codeset_cntr
5217 + != (domainbinding != NULL ? domainbinding->codeset_cntr : 0))
5219 + /* The domain's codeset has changed through bind_textdomain_codeset()
5220 + since the message catalog was initialized or last accessed. We
5221 + have to reinitialize the converter. */
5222 + _nl_free_domain_conv (domain);
5223 + _nl_init_domain_conv (domain_file, domain, domainbinding);
5228 + domain->conv != (__gconv_t) -1
5231 + domain->conv != (iconv_t) -1
5236 + /* We are supposed to do a conversion. First allocate an
5237 + appropriate table with the same structure as the table
5238 + of translations in the file, where we can put the pointers
5239 + to the converted strings in.
5240 + There is a slight complication with plural entries. They
5241 + are represented by consecutive NUL terminated strings. We
5242 + handle this case by converting RESULTLEN bytes, including
5245 + if (domain->conv_tab == NULL
5246 + && ((domain->conv_tab =
5247 + (char **) calloc (nstrings + domain->n_sysdep_strings,
5250 + /* Mark that we didn't succeed allocating a table. */
5251 + domain->conv_tab = (char **) -1;
5253 + if (__builtin_expect (domain->conv_tab == (char **) -1, 0))
5254 + /* Nothing we can do, no more memory. */
5257 + if (domain->conv_tab[act] == NULL)
5259 + /* We haven't used this string so far, so it is not
5260 + translated yet. Do this now. */
5261 + /* We use a bit more efficient memory handling.
5262 + We allocate always larger blocks which get used over
5263 + time. This is faster than many small allocations. */
5264 + __libc_lock_define_initialized (static, lock)
5265 +# define INITIAL_BLOCK_SIZE 4080
5266 + static unsigned char *freemem;
5267 + static size_t freemem_size;
5269 + const unsigned char *inbuf;
5270 + unsigned char *outbuf;
5273 + transmem_block_t *transmem_list = NULL;
5276 + __libc_lock_lock (lock);
5278 + inbuf = (const unsigned char *) result;
5279 + outbuf = freemem + sizeof (size_t);
5284 + transmem_block_t *newmem;
5286 + size_t non_reversible;
5289 + if (freemem_size < sizeof (size_t))
5290 + goto resize_freemem;
5292 + res = __gconv (domain->conv,
5293 + &inbuf, inbuf + resultlen,
5295 + outbuf + freemem_size - sizeof (size_t),
5298 + if (res == __GCONV_OK || res == __GCONV_EMPTY_INPUT)
5301 + if (res != __GCONV_FULL_OUTPUT)
5303 + __libc_lock_unlock (lock);
5310 + const char *inptr = (const char *) inbuf;
5311 + size_t inleft = resultlen;
5312 + char *outptr = (char *) outbuf;
5315 + if (freemem_size < sizeof (size_t))
5316 + goto resize_freemem;
5318 + outleft = freemem_size - sizeof (size_t);
5319 + if (iconv (domain->conv,
5320 + (ICONV_CONST char **) &inptr, &inleft,
5321 + &outptr, &outleft)
5324 + outbuf = (unsigned char *) outptr;
5327 + if (errno != E2BIG)
5329 + __libc_lock_unlock (lock);
5336 + /* We must allocate a new buffer or resize the old one. */
5337 + if (malloc_count > 0)
5340 + freemem_size = malloc_count * INITIAL_BLOCK_SIZE;
5341 + newmem = (transmem_block_t *) realloc (transmem_list,
5344 + if (newmem != NULL)
5345 + transmem_list = transmem_list->next;
5348 + struct transmem_list *old = transmem_list;
5350 + transmem_list = transmem_list->next;
5358 + freemem_size = INITIAL_BLOCK_SIZE;
5359 + newmem = (transmem_block_t *) malloc (freemem_size);
5361 + if (__builtin_expect (newmem == NULL, 0))
5365 + __libc_lock_unlock (lock);
5370 + /* Add the block to the list of blocks we have to free
5372 + newmem->next = transmem_list;
5373 + transmem_list = newmem;
5375 + freemem = newmem->data;
5376 + freemem_size -= offsetof (struct transmem_list, data);
5378 + transmem_list = newmem;
5382 + outbuf = freemem + sizeof (size_t);
5385 + /* We have now in our buffer a converted string. Put this
5386 + into the table of conversions. */
5387 + *(size_t *) freemem = outbuf - freemem - sizeof (size_t);
5388 + domain->conv_tab[act] = (char *) freemem;
5389 + /* Shrink freemem, but keep it aligned. */
5390 + freemem_size -= outbuf - freemem;
5392 + freemem += freemem_size & (alignof (size_t) - 1);
5393 + freemem_size = freemem_size & ~ (alignof (size_t) - 1);
5395 + __libc_lock_unlock (lock);
5398 + /* Now domain->conv_tab[act] contains the translation of all
5399 + the plural variants. */
5400 + result = domain->conv_tab[act] + sizeof (size_t);
5401 + resultlen = *(size_t *) domain->conv_tab[act];
5405 + /* The result string is converted. */
5407 +#endif /* _LIBC || HAVE_ICONV */
5409 + *lengthp = resultlen;
5414 +/* Look up a plural variant. */
5417 +plural_lookup (struct loaded_l10nfile *domain, unsigned long int n,
5418 + const char *translation, size_t translation_len)
5420 + struct loaded_domain *domaindata = (struct loaded_domain *) domain->data;
5421 + unsigned long int index;
5424 + index = plural_eval (domaindata->plural, n);
5425 + if (index >= domaindata->nplurals)
5426 + /* This should never happen. It means the plural expression and the
5427 + given maximum value do not match. */
5430 + /* Skip INDEX strings at TRANSLATION. */
5432 + while (index-- > 0)
5435 + p = __rawmemchr (p, '\0');
5437 + p = strchr (p, '\0');
5439 + /* And skip over the NUL byte. */
5442 + if (p >= translation + translation_len)
5443 + /* This should never happen. It means the plural expression
5444 + evaluated to a value larger than the number of variants
5445 + available for MSGID1. */
5446 + return (char *) translation;
5448 + return (char *) p;
5452 +/* Return string representation of locale CATEGORY. */
5453 +static const char *
5455 +category_to_name (int category)
5457 + const char *retval;
5463 + retval = "LC_COLLATE";
5468 + retval = "LC_CTYPE";
5473 + retval = "LC_MONETARY";
5478 + retval = "LC_NUMERIC";
5483 + retval = "LC_TIME";
5488 + retval = "LC_MESSAGES";
5493 + retval = "LC_RESPONSE";
5498 + /* This might not make sense but is perhaps better than any other
5500 + retval = "LC_ALL";
5504 + /* If you have a better idea for a default value let me know. */
5505 + retval = "LC_XXX";
5512 +/* Guess value of current locale from value of the environment variables. */
5513 +static const char *
5515 +guess_category_value (int category, const char *categoryname)
5517 + const char *language;
5518 + const char *retval;
5520 + /* The highest priority value is the `LANGUAGE' environment
5521 + variable. But we don't use the value if the currently selected
5522 + locale is the C locale. This is a GNU extension. */
5523 + language = getenv ("LANGUAGE");
5524 + if (language != NULL && language[0] == '\0')
5527 + /* We have to proceed with the POSIX methods of looking to `LC_ALL',
5528 + `LC_xxx', and `LANG'. On some systems this can be done by the
5529 + `setlocale' function itself. */
5531 + retval = __current_locale_name (category);
5533 + retval = _nl_locale_name (category, categoryname);
5536 + /* Ignore LANGUAGE if the locale is set to "C" because
5537 + 1. "C" locale usually uses the ASCII encoding, and most international
5538 + messages use non-ASCII characters. These characters get displayed
5539 + as question marks (if using glibc's iconv()) or as invalid 8-bit
5540 + characters (because other iconv()s refuse to convert most non-ASCII
5541 + characters to ASCII). In any case, the output is ugly.
5542 + 2. The precise output of some programs in the "C" locale is specified
5543 + by POSIX and should not depend on environment variables like
5544 + "LANGUAGE". We allow such programs to use gettext(). */
5545 + return language != NULL && strcmp (retval, "C") != 0 ? language : retval;
5548 +/* @@ begin of epilog @@ */
5550 +/* We don't want libintl.a to depend on any other library. So we
5551 + avoid the non-standard function stpcpy. In GNU C Library this
5552 + function is available, though. Also allow the symbol HAVE_STPCPY
5554 +#if !_LIBC && !HAVE_STPCPY
5556 +stpcpy (char *dest, const char *src)
5558 + while ((*dest++ = *src++) != '\0')
5559 + /* Do nothing. */ ;
5564 +#if !_LIBC && !HAVE_MEMPCPY
5566 +mempcpy (void *dest, const void *src, size_t n)
5568 + return (void *) ((char *) memcpy (dest, src, n) + n);
5574 +/* If we want to free all resources we have to do some work at
5576 +libc_freeres_fn (free_mem)
5580 + while (_nl_domain_bindings != NULL)
5582 + struct binding *oldp = _nl_domain_bindings;
5583 + _nl_domain_bindings = _nl_domain_bindings->next;
5584 + if (oldp->dirname != INTUSE(_nl_default_dirname))
5585 + /* Yes, this is a pointer comparison. */
5586 + free (oldp->dirname);
5587 + free (oldp->codeset);
5591 + if (_nl_current_default_domain != _nl_default_default_domain)
5592 + /* Yes, again a pointer comparison. */
5593 + free ((char *) _nl_current_default_domain);
5595 + /* Remove the search tree with the known translations. */
5596 + __tdestroy (root, free);
5599 + while (transmem_list != NULL)
5601 + old = transmem_list;
5602 + transmem_list = transmem_list->next;
5607 --- lrzsz-0.12.20.safe/intl/dcngettext.c 1969-12-31 19:00:00.000000000 -0500
5608 +++ lrzsz-0.12.20/intl/dcngettext.c 2004-09-12 14:40:34.375745048 -0400
5610 +/* Implementation of the dcngettext(3) function.
5611 + Copyright (C) 1995-1999, 2000-2003 Free Software Foundation, Inc.
5613 + This program is free software; you can redistribute it and/or modify it
5614 + under the terms of the GNU Library General Public License as published
5615 + by the Free Software Foundation; either version 2, or (at your option)
5616 + any later version.
5618 + This program is distributed in the hope that it will be useful,
5619 + but WITHOUT ANY WARRANTY; without even the implied warranty of
5620 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5621 + Library General Public License for more details.
5623 + You should have received a copy of the GNU Library General Public
5624 + License along with this program; if not, write to the Free Software
5625 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
5628 +#ifdef HAVE_CONFIG_H
5629 +# include <config.h>
5632 +#include "gettextP.h"
5634 +# include <libintl.h>
5636 +# include "libgnuintl.h"
5639 +/* @@ end of prolog @@ */
5641 +/* Names for the libintl functions are a problem. They must not clash
5642 + with existing names and they should follow ANSI C. But this source
5643 + code is also used in GNU C Library where the names have a __
5644 + prefix. So we have to make a difference here. */
5646 +# define DCNGETTEXT __dcngettext
5647 +# define DCIGETTEXT __dcigettext
5649 +# define DCNGETTEXT libintl_dcngettext
5650 +# define DCIGETTEXT libintl_dcigettext
5653 +/* Look up MSGID in the DOMAINNAME message catalog for the current CATEGORY
5656 +DCNGETTEXT (const char *domainname,
5657 + const char *msgid1, const char *msgid2, unsigned long int n,
5660 + return DCIGETTEXT (domainname, msgid1, msgid2, 1, n, category);
5664 +/* Alias for function name in GNU C Library. */
5665 +weak_alias (__dcngettext, dcngettext);
5667 --- lrzsz-0.12.20.safe/intl/dgettext.c 1998-04-26 09:20:52.000000000 -0400
5668 +++ lrzsz-0.12.20/intl/dgettext.c 2004-09-12 14:40:34.380744288 -0400
5670 -/* dgettext.c -- implementation of the dgettext(3) function
5671 - Copyright (C) 1995 Software Foundation, Inc.
5672 +/* Implementation of the dgettext(3) function.
5673 + Copyright (C) 1995-1997, 2000-2003 Free Software Foundation, Inc.
5675 -This program is free software; you can redistribute it and/or modify
5676 -it under the terms of the GNU General Public License as published by
5677 -the Free Software Foundation; either version 2, or (at your option)
5679 + This program is free software; you can redistribute it and/or modify it
5680 + under the terms of the GNU Library General Public License as published
5681 + by the Free Software Foundation; either version 2, or (at your option)
5682 + any later version.
5684 -This program is distributed in the hope that it will be useful,
5685 -but WITHOUT ANY WARRANTY; without even the implied warranty of
5686 -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
5687 -GNU General Public License for more details.
5688 + This program is distributed in the hope that it will be useful,
5689 + but WITHOUT ANY WARRANTY; without even the implied warranty of
5690 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5691 + Library General Public License for more details.
5693 -You should have received a copy of the GNU General Public License
5694 -along with this program; if not, write to the Free Software
5695 -Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
5696 + You should have received a copy of the GNU Library General Public
5697 + License along with this program; if not, write to the Free Software
5698 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
5701 #ifdef HAVE_CONFIG_H
5702 # include <config.h>
5705 -#if defined HAVE_LOCALE_H || defined _LIBC
5706 -# include <locale.h>
5708 +#include "gettextP.h"
5710 +#include <locale.h>
5713 # include <libintl.h>
5715 -# include "libgettext.h"
5716 +# include "libgnuintl.h"
5719 /* @@ end of prolog @@ */
5721 prefix. So we have to make a difference here. */
5723 # define DGETTEXT __dgettext
5724 -# define DCGETTEXT __dcgettext
5725 +# define DCGETTEXT INTUSE(__dcgettext)
5727 -# define DGETTEXT dgettext__
5728 -# define DCGETTEXT dcgettext__
5729 +# define DGETTEXT libintl_dgettext
5730 +# define DCGETTEXT libintl_dcgettext
5733 /* Look up MSGID in the DOMAINNAME message catalog of the current
5734 LC_MESSAGES locale. */
5736 -DGETTEXT (domainname, msgid)
5737 - const char *domainname;
5738 - const char *msgid;
5739 +DGETTEXT (const char *domainname, const char *msgid)
5741 return DCGETTEXT (domainname, msgid, LC_MESSAGES);
5743 --- lrzsz-0.12.20.safe/intl/dngettext.c 1969-12-31 19:00:00.000000000 -0500
5744 +++ lrzsz-0.12.20/intl/dngettext.c 2004-09-12 14:40:34.385743528 -0400
5746 +/* Implementation of the dngettext(3) function.
5747 + Copyright (C) 1995-1997, 2000-2003 Free Software Foundation, Inc.
5749 + This program is free software; you can redistribute it and/or modify it
5750 + under the terms of the GNU Library General Public License as published
5751 + by the Free Software Foundation; either version 2, or (at your option)
5752 + any later version.
5754 + This program is distributed in the hope that it will be useful,
5755 + but WITHOUT ANY WARRANTY; without even the implied warranty of
5756 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5757 + Library General Public License for more details.
5759 + You should have received a copy of the GNU Library General Public
5760 + License along with this program; if not, write to the Free Software
5761 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
5764 +#ifdef HAVE_CONFIG_H
5765 +# include <config.h>
5768 +#include "gettextP.h"
5770 +#include <locale.h>
5773 +# include <libintl.h>
5775 +# include "libgnuintl.h"
5778 +/* @@ end of prolog @@ */
5780 +/* Names for the libintl functions are a problem. They must not clash
5781 + with existing names and they should follow ANSI C. But this source
5782 + code is also used in GNU C Library where the names have a __
5783 + prefix. So we have to make a difference here. */
5785 +# define DNGETTEXT __dngettext
5786 +# define DCNGETTEXT __dcngettext
5788 +# define DNGETTEXT libintl_dngettext
5789 +# define DCNGETTEXT libintl_dcngettext
5792 +/* Look up MSGID in the DOMAINNAME message catalog of the current
5793 + LC_MESSAGES locale and skip message according to the plural form. */
5795 +DNGETTEXT (const char *domainname,
5796 + const char *msgid1, const char *msgid2, unsigned long int n)
5798 + return DCNGETTEXT (domainname, msgid1, msgid2, n, LC_MESSAGES);
5802 +/* Alias for function name in GNU C Library. */
5803 +weak_alias (__dngettext, dngettext);
5805 --- lrzsz-0.12.20.safe/intl/eval-plural.h 1969-12-31 19:00:00.000000000 -0500
5806 +++ lrzsz-0.12.20/intl/eval-plural.h 2004-09-12 14:40:34.390742768 -0400
5808 +/* Plural expression evaluation.
5809 + Copyright (C) 2000-2003 Free Software Foundation, Inc.
5811 + This program is free software; you can redistribute it and/or modify it
5812 + under the terms of the GNU Library General Public License as published
5813 + by the Free Software Foundation; either version 2, or (at your option)
5814 + any later version.
5816 + This program is distributed in the hope that it will be useful,
5817 + but WITHOUT ANY WARRANTY; without even the implied warranty of
5818 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5819 + Library General Public License for more details.
5821 + You should have received a copy of the GNU Library General Public
5822 + License along with this program; if not, write to the Free Software
5823 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
5827 +#define STATIC static
5830 +/* Evaluate the plural expression and return an index value. */
5834 +plural_eval (struct expression *pexp, unsigned long int n)
5836 + switch (pexp->nargs)
5839 + switch (pexp->operation)
5844 + return pexp->val.num;
5852 + /* pexp->operation must be lnot. */
5853 + unsigned long int arg = plural_eval (pexp->val.args[0], n);
5858 + unsigned long int leftarg = plural_eval (pexp->val.args[0], n);
5859 + if (pexp->operation == lor)
5860 + return leftarg || plural_eval (pexp->val.args[1], n);
5861 + else if (pexp->operation == land)
5862 + return leftarg && plural_eval (pexp->val.args[1], n);
5865 + unsigned long int rightarg = plural_eval (pexp->val.args[1], n);
5867 + switch (pexp->operation)
5870 + return leftarg * rightarg;
5872 +#if !INTDIV0_RAISES_SIGFPE
5873 + if (rightarg == 0)
5876 + return leftarg / rightarg;
5878 +#if !INTDIV0_RAISES_SIGFPE
5879 + if (rightarg == 0)
5882 + return leftarg % rightarg;
5884 + return leftarg + rightarg;
5886 + return leftarg - rightarg;
5888 + return leftarg < rightarg;
5889 + case greater_than:
5890 + return leftarg > rightarg;
5891 + case less_or_equal:
5892 + return leftarg <= rightarg;
5893 + case greater_or_equal:
5894 + return leftarg >= rightarg;
5896 + return leftarg == rightarg;
5898 + return leftarg != rightarg;
5908 + /* pexp->operation must be qmop. */
5909 + unsigned long int boolarg = plural_eval (pexp->val.args[0], n);
5910 + return plural_eval (pexp->val.args[boolarg ? 1 : 2], n);
5916 --- lrzsz-0.12.20.safe/intl/explodename.c 1998-04-26 09:22:37.000000000 -0400
5917 +++ lrzsz-0.12.20/intl/explodename.c 2004-09-12 14:40:34.395742008 -0400
5919 -/* Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
5920 +/* Copyright (C) 1995-1998, 2000-2001, 2003 Free Software Foundation, Inc.
5921 Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
5923 - This program is free software; you can redistribute it and/or modify
5924 - it under the terms of the GNU General Public License as published by
5925 - the Free Software Foundation; either version 2, or (at your option)
5926 + This program is free software; you can redistribute it and/or modify it
5927 + under the terms of the GNU Library General Public License as published
5928 + by the Free Software Foundation; either version 2, or (at your option)
5931 This program is distributed in the hope that it will be useful,
5932 but WITHOUT ANY WARRANTY; without even the implied warranty of
5933 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
5934 - GNU General Public License for more details.
5935 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5936 + Library General Public License for more details.
5938 - You should have received a copy of the GNU General Public License
5939 - along with this program; if not, write to the Free Software Foundation,
5940 - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
5941 + You should have received a copy of the GNU Library General Public
5942 + License along with this program; if not, write to the Free Software
5943 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
5946 #ifdef HAVE_CONFIG_H
5947 # include <config.h>
5950 /* @@ end of prolog @@ */
5953 +_nl_find_language (const char *name)
5955 + while (name[0] != '\0' && name[0] != '_' && name[0] != '@'
5956 + && name[0] != '+' && name[0] != ',')
5959 + return (char *) name;
5964 -_nl_explode_name (name, language, modifier, territory, codeset,
5965 - normalized_codeset, special, sponsor, revision)
5967 - const char **language;
5968 - const char **modifier;
5969 - const char **territory;
5970 - const char **codeset;
5971 - const char **normalized_codeset;
5972 - const char **special;
5973 - const char **sponsor;
5974 - const char **revision;
5975 +_nl_explode_name (char *name,
5976 + const char **language, const char **modifier,
5977 + const char **territory, const char **codeset,
5978 + const char **normalized_codeset, const char **special,
5979 + const char **sponsor, const char **revision)
5981 enum { undecided, xpg, cen } syntax;
5986 *language = cp = name;
5987 - while (cp[0] != '\0' && cp[0] != '_' && cp[0] != '@'
5988 - && cp[0] != '+' && cp[0] != ',')
5990 + cp = _nl_find_language (*language);
5992 if (*language == cp)
5993 /* This does not make sense: language has to be specified. Use
5994 --- lrzsz-0.12.20.safe/intl/finddomain.c 1998-04-26 09:22:36.000000000 -0400
5995 +++ lrzsz-0.12.20/intl/finddomain.c 2004-09-12 14:40:34.415738968 -0400
5997 /* Handle list of needed message catalogs
5998 - Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
5999 - Written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
6000 + Copyright (C) 1995-1999, 2000-2001, 2003 Free Software Foundation, Inc.
6001 + Written by Ulrich Drepper <drepper@gnu.org>, 1995.
6003 - This program is free software; you can redistribute it and/or modify
6004 - it under the terms of the GNU General Public License as published by
6005 - the Free Software Foundation; either version 2, or (at your option)
6006 + This program is free software; you can redistribute it and/or modify it
6007 + under the terms of the GNU Library General Public License as published
6008 + by the Free Software Foundation; either version 2, or (at your option)
6011 This program is distributed in the hope that it will be useful,
6012 but WITHOUT ANY WARRANTY; without even the implied warranty of
6013 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
6014 - GNU General Public License for more details.
6015 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
6016 + Library General Public License for more details.
6018 - You should have received a copy of the GNU General Public License
6019 - along with this program; if not, write to the Free Software Foundation,
6020 - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
6021 + You should have received a copy of the GNU Library General Public
6022 + License along with this program; if not, write to the Free Software
6023 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
6026 #ifdef HAVE_CONFIG_H
6027 # include <config.h>
6033 #include <sys/types.h>
6035 -#if defined STDC_HEADERS || defined _LIBC
6036 -# include <stdlib.h>
6038 -# ifdef HAVE_MALLOC_H
6039 -# include <malloc.h>
6045 -#if defined HAVE_STRING_H || defined _LIBC
6046 -# include <string.h>
6048 -# include <strings.h>
6050 -# define memcpy(Dst, Src, Num) bcopy (Src, Dst, Num)
6053 -#if !HAVE_STRCHR && !defined _LIBC
6055 -# define strchr index
6058 +#include <stdlib.h>
6059 +#include <string.h>
6061 #if defined HAVE_UNISTD_H || defined _LIBC
6062 # include <unistd.h>
6065 -#include "gettext.h"
6066 #include "gettextP.h"
6068 # include <libintl.h>
6070 -# include "libgettext.h"
6071 +# include "libgnuintl.h"
6074 /* @@ end of prolog @@ */
6076 the DOMAINNAME and CATEGORY parameters with respect to the currently
6077 established bindings. */
6078 struct loaded_l10nfile *
6079 -_nl_find_domain (dirname, locale, domainname)
6080 - const char *dirname;
6082 - const char *domainname;
6084 +_nl_find_domain (const char *dirname, char *locale,
6085 + const char *domainname, struct binding *domainbinding)
6087 struct loaded_l10nfile *retval;
6088 const char *language;
6091 language[_territory][+audience][+special][,[sponsor][_revision]]
6093 - Beside the first all of them are allowed to be missing. If the
6094 - full specified locale is not found, the less specific one are
6095 - looked for. The various part will be stripped of according to
6096 + Beside the first part all of them are allowed to be missing. If
6097 + the full specified locale is not found, the less specific one are
6098 + looked for. The various parts will be stripped off according to
6099 the following order:
6105 if (retval->decided == 0)
6106 - _nl_load_domain (retval);
6107 + _nl_load_domain (retval, domainbinding);
6109 if (retval->data != NULL)
6112 for (cnt = 0; retval->successor[cnt] != NULL; ++cnt)
6114 if (retval->successor[cnt]->decided == 0)
6115 - _nl_load_domain (retval->successor[cnt]);
6116 + _nl_load_domain (retval->successor[cnt], domainbinding);
6118 if (retval->successor[cnt]->data != NULL)
6120 @@ -142,12 +117,18 @@
6121 alias_value = _nl_expand_alias (locale);
6122 if (alias_value != NULL)
6124 +#if defined _LIBC || defined HAVE_STRDUP
6125 + locale = strdup (alias_value);
6126 + if (locale == NULL)
6129 size_t len = strlen (alias_value) + 1;
6130 locale = (char *) malloc (len);
6134 memcpy (locale, alias_value, len);
6138 /* Now we determine the single parts of the locale name. First
6139 @@ -168,14 +149,14 @@
6142 if (retval->decided == 0)
6143 - _nl_load_domain (retval);
6144 + _nl_load_domain (retval, domainbinding);
6145 if (retval->data == NULL)
6148 for (cnt = 0; retval->successor[cnt] != NULL; ++cnt)
6150 if (retval->successor[cnt]->decided == 0)
6151 - _nl_load_domain (retval->successor[cnt]);
6152 + _nl_load_domain (retval->successor[cnt], domainbinding);
6153 if (retval->successor[cnt]->data != NULL)
6156 @@ -185,5 +166,27 @@
6157 if (alias_value != NULL)
6160 + /* The space for normalized_codeset is dynamically allocated. Free it. */
6161 + if (mask & XPG_NORM_CODESET)
6162 + free ((void *) normalized_codeset);
6169 +libc_freeres_fn (free_mem)
6171 + struct loaded_l10nfile *runp = _nl_loaded_domains;
6173 + while (runp != NULL)
6175 + struct loaded_l10nfile *here = runp;
6176 + if (runp->data != NULL)
6177 + _nl_unload_domain ((struct loaded_domain *) runp->data);
6178 + runp = runp->next;
6179 + free ((char *) here->filename);
6184 --- lrzsz-0.12.20.safe/intl/gettext.c 1998-04-26 09:22:36.000000000 -0400
6185 +++ lrzsz-0.12.20/intl/gettext.c 2004-09-12 14:40:34.420738208 -0400
6187 -/* Implementation of gettext(3) function
6188 - Copyright (C) 1995, 1997 Free Software Foundation, Inc.
6189 +/* Implementation of gettext(3) function.
6190 + Copyright (C) 1995, 1997, 2000-2003 Free Software Foundation, Inc.
6192 - This program is free software; you can redistribute it and/or modify
6193 - it under the terms of the GNU General Public License as published by
6194 - the Free Software Foundation; either version 2, or (at your option)
6195 + This program is free software; you can redistribute it and/or modify it
6196 + under the terms of the GNU Library General Public License as published
6197 + by the Free Software Foundation; either version 2, or (at your option)
6200 This program is distributed in the hope that it will be useful,
6201 but WITHOUT ANY WARRANTY; without even the implied warranty of
6202 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
6203 - GNU General Public License for more details.
6204 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
6205 + Library General Public License for more details.
6207 - You should have received a copy of the GNU General Public License
6208 - along with this program; if not, write to the Free Software Foundation,
6209 - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
6210 + You should have received a copy of the GNU Library General Public
6211 + License along with this program; if not, write to the Free Software
6212 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
6215 #ifdef HAVE_CONFIG_H
6216 # include <config.h>
6218 # define __need_NULL
6219 # include <stddef.h>
6221 -# ifdef STDC_HEADERS
6222 -# include <stdlib.h> /* Just for NULL. */
6224 -# ifdef HAVE_STRING_H
6225 -# include <string.h>
6227 -# define NULL ((void *) 0)
6230 +# include <stdlib.h> /* Just for NULL. */
6233 +#include "gettextP.h"
6235 # include <libintl.h>
6237 -# include "libgettext.h"
6238 +# include "libgnuintl.h"
6241 /* @@ end of prolog @@ */
6243 prefix. So we have to make a difference here. */
6245 # define GETTEXT __gettext
6246 -# define DGETTEXT __dgettext
6247 +# define DCGETTEXT INTUSE(__dcgettext)
6249 -# define GETTEXT gettext__
6250 -# define DGETTEXT dgettext__
6251 +# define GETTEXT libintl_gettext
6252 +# define DCGETTEXT libintl_dcgettext
6255 /* Look up MSGID in the current default message catalog for the current
6256 LC_MESSAGES locale. If not found, returns MSGID itself (the default
6260 - const char *msgid;
6261 +GETTEXT (const char *msgid)
6263 - return DGETTEXT (NULL, msgid);
6264 + return DCGETTEXT (NULL, msgid, LC_MESSAGES);
6268 --- lrzsz-0.12.20.safe/intl/gettext.h 1998-04-26 09:22:35.000000000 -0400
6269 +++ lrzsz-0.12.20/intl/gettext.h 1969-12-31 19:00:00.000000000 -0500
6271 -/* Internal header for GNU gettext internationalization functions
6272 - Copyright (C) 1995, 1997 Free Software Foundation, Inc.
6274 - This program is free software; you can redistribute it and/or modify
6275 - it under the terms of the GNU General Public License as published by
6276 - the Free Software Foundation; either version 2, or (at your option)
6277 - any later version.
6279 - This program is distributed in the hope that it will be useful,
6280 - but WITHOUT ANY WARRANTY; without even the implied warranty of
6281 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
6282 - GNU General Public License for more details.
6284 - You should have received a copy of the GNU Library General Public
6285 - License along with the GNU C Library; see the file COPYING.LIB. If not,
6286 - write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
6287 - Boston, MA 02111-1307, USA. */
6290 -#define _GETTEXT_H 1
6294 -#if HAVE_LIMITS_H || _LIBC
6295 -# include <limits.h>
6298 -/* @@ end of prolog @@ */
6300 -/* The magic number of the GNU message catalog format. */
6301 -#define _MAGIC 0x950412de
6302 -#define _MAGIC_SWAPPED 0xde120495
6304 -/* Revision number of the currently used .mo (binary) file format. */
6305 -#define MO_REVISION_NUMBER 0
6307 -/* The following contortions are an attempt to use the C preprocessor
6308 - to determine an unsigned integral type that is 32 bits wide. An
6309 - alternative approach is to use autoconf's AC_CHECK_SIZEOF macro, but
6310 - doing that would require that the configure script compile and *run*
6311 - the resulting executable. Locally running cross-compiled executables
6312 - is usually not possible. */
6315 -# define UINT_MAX_32_BITS 4294967295U
6317 -# define UINT_MAX_32_BITS 0xFFFFFFFF
6320 -/* If UINT_MAX isn't defined, assume it's a 32-bit type.
6321 - This should be valid for all systems GNU cares about because
6322 - that doesn't include 16-bit systems, and only modern systems
6323 - (that certainly have <limits.h>) have 64+-bit integral types. */
6326 -# define UINT_MAX UINT_MAX_32_BITS
6329 -#if UINT_MAX == UINT_MAX_32_BITS
6330 -typedef unsigned nls_uint32;
6332 -# if USHRT_MAX == UINT_MAX_32_BITS
6333 -typedef unsigned short nls_uint32;
6335 -# if ULONG_MAX == UINT_MAX_32_BITS
6336 -typedef unsigned long nls_uint32;
6338 - /* The following line is intended to throw an error. Using #error is
6339 - not portable enough. */
6340 - "Cannot determine unsigned 32-bit data type."
6346 -/* Header for binary .mo file format. */
6347 -struct mo_file_header
6349 - /* The magic number. */
6351 - /* The revision number of the file format. */
6352 - nls_uint32 revision;
6353 - /* The number of strings pairs. */
6354 - nls_uint32 nstrings;
6355 - /* Offset of table with start offsets of original strings. */
6356 - nls_uint32 orig_tab_offset;
6357 - /* Offset of table with start offsets of translation strings. */
6358 - nls_uint32 trans_tab_offset;
6359 - /* Size of hashing table. */
6360 - nls_uint32 hash_tab_size;
6361 - /* Offset of first hashing entry. */
6362 - nls_uint32 hash_tab_offset;
6367 - /* Length of addressed string. */
6368 - nls_uint32 length;
6369 - /* Offset of string in file. */
6370 - nls_uint32 offset;
6373 -/* @@ begin of epilog @@ */
6375 -#endif /* gettext.h */
6376 --- lrzsz-0.12.20.safe/intl/gettextP.h 1998-04-26 09:22:35.000000000 -0400
6377 +++ lrzsz-0.12.20/intl/gettextP.h 2004-09-12 14:40:34.426737296 -0400
6379 -/* Header describing internals of gettext library
6380 - Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
6381 +/* Header describing internals of libintl library.
6382 + Copyright (C) 1995-1999, 2000-2003 Free Software Foundation, Inc.
6383 + Written by Ulrich Drepper <drepper@cygnus.com>, 1995.
6385 - This program is free software; you can redistribute it and/or modify
6386 - it under the terms of the GNU General Public License as published by
6387 - the Free Software Foundation; either version 2, or (at your option)
6388 + This program is free software; you can redistribute it and/or modify it
6389 + under the terms of the GNU Library General Public License as published
6390 + by the Free Software Foundation; either version 2, or (at your option)
6393 This program is distributed in the hope that it will be useful,
6394 but WITHOUT ANY WARRANTY; without even the implied warranty of
6395 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
6396 - GNU General Public License for more details.
6397 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
6398 + Library General Public License for more details.
6400 - You should have received a copy of the GNU General Public License
6401 - along with this program; if not, write to the Free Software Foundation,
6402 - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
6403 + You should have received a copy of the GNU Library General Public
6404 + License along with this program; if not, write to the Free Software
6405 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
6411 +#include <stddef.h> /* Get size_t. */
6414 +# include "../iconv/gconv_int.h"
6417 +# include <iconv.h>
6421 #include "loadinfo.h"
6423 +#include "gmo.h" /* Get nls_uint32. */
6425 /* @@ end of prolog @@ */
6429 -# define PARAMS(args) args
6431 -# define PARAMS(args) ()
6433 +#ifndef internal_function
6434 +# define internal_function
6437 +#ifndef attribute_hidden
6438 +# define attribute_hidden
6441 +/* Tell the compiler when a conditional or integer expression is
6442 + almost always true or almost always false. */
6443 +#ifndef HAVE_BUILTIN_EXPECT
6444 +# define __builtin_expect(expr, val) (expr)
6448 @@ -35,38 +55,160 @@
6452 -static nls_uint32 SWAP PARAMS ((nls_uint32 i));
6455 +# include <byteswap.h>
6456 +# define SWAP(i) bswap_32 (i)
6458 static inline nls_uint32
6462 return (i << 24) | ((i & 0xff00) << 8) | ((i >> 8) & 0xff00) | (i >> 24);
6467 +/* In-memory representation of system dependent string. */
6468 +struct sysdep_string_desc
6470 + /* Length of addressed string, including the trailing NUL. */
6472 + /* Pointer to addressed string. */
6473 + const char *pointer;
6476 +/* The representation of an opened message catalog. */
6477 struct loaded_domain
6479 + /* Pointer to memory containing the .mo file. */
6481 + /* 1 if the memory is mmap()ed, 0 if the memory is malloc()ed. */
6483 + /* Size of mmap()ed memory. */
6485 + /* 1 if the .mo file uses a different endianness than this machine. */
6487 + /* Pointer to additional malloc()ed memory. */
6490 + /* Number of static strings pairs. */
6491 nls_uint32 nstrings;
6492 - struct string_desc *orig_tab;
6493 - struct string_desc *trans_tab;
6494 + /* Pointer to descriptors of original strings in the file. */
6495 + const struct string_desc *orig_tab;
6496 + /* Pointer to descriptors of translated strings in the file. */
6497 + const struct string_desc *trans_tab;
6499 + /* Number of system dependent strings pairs. */
6500 + nls_uint32 n_sysdep_strings;
6501 + /* Pointer to descriptors of original sysdep strings. */
6502 + const struct sysdep_string_desc *orig_sysdep_tab;
6503 + /* Pointer to descriptors of translated sysdep strings. */
6504 + const struct sysdep_string_desc *trans_sysdep_tab;
6506 + /* Size of hash table. */
6507 nls_uint32 hash_size;
6508 - nls_uint32 *hash_tab;
6509 + /* Pointer to hash table. */
6510 + const nls_uint32 *hash_tab;
6511 + /* 1 if the hash table uses a different endianness than this machine. */
6512 + int must_swap_hash_tab;
6524 + struct expression *plural;
6525 + unsigned long int nplurals;
6528 +/* We want to allocate a string at the end of the struct. But ISO C
6529 + doesn't allow zero sized arrays. */
6536 +/* A set of settings bound to a message domain. Used to store settings
6537 + from bindtextdomain() and bind_textdomain_codeset(). */
6540 struct binding *next;
6543 + int codeset_cntr; /* Incremented each time codeset changes. */
6545 + char domainname[ZERO];
6548 -struct loaded_l10nfile *_nl_find_domain PARAMS ((const char *__dirname,
6550 - const char *__domainname));
6551 -void _nl_load_domain PARAMS ((struct loaded_l10nfile *__domain));
6552 +/* A counter which is incremented each time some previous translations
6554 + This variable is part of the external ABI of the GNU libintl. */
6555 +extern int _nl_msg_cat_cntr;
6558 +const char *_nl_locale_name (int category, const char *categoryname);
6561 +struct loaded_l10nfile *_nl_find_domain (const char *__dirname, char *__locale,
6562 + const char *__domainname,
6563 + struct binding *__domainbinding)
6564 + internal_function;
6565 +void _nl_load_domain (struct loaded_l10nfile *__domain,
6566 + struct binding *__domainbinding)
6567 + internal_function;
6568 +void _nl_unload_domain (struct loaded_domain *__domain)
6569 + internal_function;
6570 +const char *_nl_init_domain_conv (struct loaded_l10nfile *__domain_file,
6571 + struct loaded_domain *__domain,
6572 + struct binding *__domainbinding)
6573 + internal_function;
6574 +void _nl_free_domain_conv (struct loaded_domain *__domain)
6575 + internal_function;
6577 +char *_nl_find_msg (struct loaded_l10nfile *domain_file,
6578 + struct binding *domainbinding, const char *msgid,
6580 + internal_function;
6583 +extern char *__gettext (const char *__msgid);
6584 +extern char *__dgettext (const char *__domainname, const char *__msgid);
6585 +extern char *__dcgettext (const char *__domainname, const char *__msgid,
6587 +extern char *__ngettext (const char *__msgid1, const char *__msgid2,
6588 + unsigned long int __n);
6589 +extern char *__dngettext (const char *__domainname,
6590 + const char *__msgid1, const char *__msgid2,
6591 + unsigned long int n);
6592 +extern char *__dcngettext (const char *__domainname,
6593 + const char *__msgid1, const char *__msgid2,
6594 + unsigned long int __n, int __category);
6595 +extern char *__dcigettext (const char *__domainname,
6596 + const char *__msgid1, const char *__msgid2,
6597 + int __plural, unsigned long int __n,
6599 +extern char *__textdomain (const char *__domainname);
6600 +extern char *__bindtextdomain (const char *__domainname,
6601 + const char *__dirname);
6602 +extern char *__bind_textdomain_codeset (const char *__domainname,
6603 + const char *__codeset);
6605 +/* Declare the exported libintl_* functions, in a way that allows us to
6606 + call them under their real name. */
6607 +# undef _INTL_REDIRECT_INLINE
6608 +# undef _INTL_REDIRECT_MACROS
6609 +# define _INTL_REDIRECT_MACROS
6610 +# include "libgnuintl.h"
6611 +extern char *libintl_dcigettext (const char *__domainname,
6612 + const char *__msgid1, const char *__msgid2,
6613 + int __plural, unsigned long int __n,
6617 /* @@ begin of epilog @@ */
6619 --- lrzsz-0.12.20.safe/intl/gmo.h 1969-12-31 19:00:00.000000000 -0500
6620 +++ lrzsz-0.12.20/intl/gmo.h 2004-09-12 14:40:34.431736536 -0400
6622 +/* Description of GNU message catalog format: general file layout.
6623 + Copyright (C) 1995, 1997, 2000-2002, 2004 Free Software Foundation, Inc.
6625 + This program is free software; you can redistribute it and/or modify it
6626 + under the terms of the GNU Library General Public License as published
6627 + by the Free Software Foundation; either version 2, or (at your option)
6628 + any later version.
6630 + This program is distributed in the hope that it will be useful,
6631 + but WITHOUT ANY WARRANTY; without even the implied warranty of
6632 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
6633 + Library General Public License for more details.
6635 + You should have received a copy of the GNU Library General Public
6636 + License along with this program; if not, write to the Free Software
6637 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
6641 +#define _GETTEXT_H 1
6643 +#include <limits.h>
6645 +/* @@ end of prolog @@ */
6647 +/* The magic number of the GNU message catalog format. */
6648 +#define _MAGIC 0x950412de
6649 +#define _MAGIC_SWAPPED 0xde120495
6651 +/* Revision number of the currently used .mo (binary) file format. */
6652 +#define MO_REVISION_NUMBER 0
6653 +#define MO_REVISION_NUMBER_WITH_SYSDEP_I 1
6655 +/* The following contortions are an attempt to use the C preprocessor
6656 + to determine an unsigned integral type that is 32 bits wide. An
6657 + alternative approach is to use autoconf's AC_CHECK_SIZEOF macro, but
6658 + as of version autoconf-2.13, the AC_CHECK_SIZEOF macro doesn't work
6659 + when cross-compiling. */
6662 +# define UINT_MAX_32_BITS 4294967295U
6664 +# define UINT_MAX_32_BITS 0xFFFFFFFF
6667 +/* If UINT_MAX isn't defined, assume it's a 32-bit type.
6668 + This should be valid for all systems GNU cares about because
6669 + that doesn't include 16-bit systems, and only modern systems
6670 + (that certainly have <limits.h>) have 64+-bit integral types. */
6673 +# define UINT_MAX UINT_MAX_32_BITS
6676 +#if UINT_MAX == UINT_MAX_32_BITS
6677 +typedef unsigned nls_uint32;
6679 +# if USHRT_MAX == UINT_MAX_32_BITS
6680 +typedef unsigned short nls_uint32;
6682 +# if ULONG_MAX == UINT_MAX_32_BITS
6683 +typedef unsigned long nls_uint32;
6685 + /* The following line is intended to throw an error. Using #error is
6686 + not portable enough. */
6687 + "Cannot determine unsigned 32-bit data type."
6693 +/* Header for binary .mo file format. */
6694 +struct mo_file_header
6696 + /* The magic number. */
6698 + /* The revision number of the file format. */
6699 + nls_uint32 revision;
6701 + /* The following are only used in .mo files with major revision 0 or 1. */
6703 + /* The number of strings pairs. */
6704 + nls_uint32 nstrings;
6705 + /* Offset of table with start offsets of original strings. */
6706 + nls_uint32 orig_tab_offset;
6707 + /* Offset of table with start offsets of translated strings. */
6708 + nls_uint32 trans_tab_offset;
6709 + /* Size of hash table. */
6710 + nls_uint32 hash_tab_size;
6711 + /* Offset of first hash table entry. */
6712 + nls_uint32 hash_tab_offset;
6714 + /* The following are only used in .mo files with minor revision >= 1. */
6716 + /* The number of system dependent segments. */
6717 + nls_uint32 n_sysdep_segments;
6718 + /* Offset of table describing system dependent segments. */
6719 + nls_uint32 sysdep_segments_offset;
6720 + /* The number of system dependent strings pairs. */
6721 + nls_uint32 n_sysdep_strings;
6722 + /* Offset of table with start offsets of original sysdep strings. */
6723 + nls_uint32 orig_sysdep_tab_offset;
6724 + /* Offset of table with start offsets of translated sysdep strings. */
6725 + nls_uint32 trans_sysdep_tab_offset;
6728 +/* Descriptor for static string contained in the binary .mo file. */
6731 + /* Length of addressed string, not including the trailing NUL. */
6732 + nls_uint32 length;
6733 + /* Offset of string in file. */
6734 + nls_uint32 offset;
6737 +/* The following are only used in .mo files with minor revision >= 1. */
6739 +/* Descriptor for system dependent string segment. */
6740 +struct sysdep_segment
6742 + /* Length of addressed string, including the trailing NUL. */
6743 + nls_uint32 length;
6744 + /* Offset of string in file. */
6745 + nls_uint32 offset;
6748 +/* Descriptor for system dependent string. */
6749 +struct sysdep_string
6751 + /* Offset of static string segments in file. */
6752 + nls_uint32 offset;
6753 + /* Alternating sequence of static and system dependent segments.
6754 + The last segment is a static segment, including the trailing NUL. */
6755 + struct segment_pair
6757 + /* Size of static segment. */
6758 + nls_uint32 segsize;
6759 + /* Reference to system dependent string segment, or ~0 at the end. */
6760 + nls_uint32 sysdepref;
6764 +/* Marker for the end of the segments[] array. This has the value 0xFFFFFFFF,
6765 + regardless whether 'int' is 16 bit, 32 bit, or 64 bit. */
6766 +#define SEGMENTS_END ((nls_uint32) ~0)
6768 +/* @@ begin of epilog @@ */
6770 +#endif /* gettext.h */
6771 --- lrzsz-0.12.20.safe/intl/hash-string.h 1998-04-26 09:22:36.000000000 -0400
6772 +++ lrzsz-0.12.20/intl/hash-string.h 2004-09-12 14:40:34.436735776 -0400
6774 -/* Implements a string hashing function.
6775 - Copyright (C) 1995, 1997 Free Software Foundation, Inc.
6776 +/* Description of GNU message catalog format: string hashing function.
6777 + Copyright (C) 1995, 1997-1998, 2000-2003 Free Software Foundation, Inc.
6779 - This program is free software; you can redistribute it and/or modify
6780 - it under the terms of the GNU General Public License as published by
6781 - the Free Software Foundation; either version 2, or (at your option)
6782 + This program is free software; you can redistribute it and/or modify it
6783 + under the terms of the GNU Library General Public License as published
6784 + by the Free Software Foundation; either version 2, or (at your option)
6787 This program is distributed in the hope that it will be useful,
6788 but WITHOUT ANY WARRANTY; without even the implied warranty of
6789 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
6790 - GNU General Public License for more details.
6791 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
6792 + Library General Public License for more details.
6794 You should have received a copy of the GNU Library General Public
6795 - License along with the GNU C Library; see the file COPYING.LIB. If not,
6796 - write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
6797 - Boston, MA 02111-1307, USA. */
6799 -#ifdef HAVE_VALUES_H
6800 -# include <values.h>
6802 + License along with this program; if not, write to the Free Software
6803 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
6806 /* @@ end of prolog @@ */
6810 -# define PARAMS(Args) Args
6812 -# define PARAMS(Args) ()
6816 /* We assume to have `unsigned long int' value with at least 32 bits. */
6817 #define HASHWORDBITS 32
6820 /* Defines the so called `hashpjw' function by P.J. Weinberger
6821 [see Aho/Sethi/Ullman, COMPILERS: Principles, Techniques and Tools,
6822 1986, 1987 Bell Telephone Laboratories, Inc.] */
6823 -static unsigned long hash_string PARAMS ((const char *__str_param));
6825 -static inline unsigned long
6826 -hash_string (str_param)
6827 - const char *str_param;
6828 +static inline unsigned long int
6829 +hash_string (const char *str_param)
6831 unsigned long int hval, g;
6832 const char *str = str_param;
6834 while (*str != '\0')
6837 - hval += (unsigned long) *str++;
6838 - g = hval & ((unsigned long) 0xf << (HASHWORDBITS - 4));
6839 + hval += (unsigned char) *str++;
6840 + g = hval & ((unsigned long int) 0xf << (HASHWORDBITS - 4));
6843 hval ^= g >> (HASHWORDBITS - 8);
6844 --- lrzsz-0.12.20.safe/intl/intl-compat.c 1998-04-26 09:20:52.000000000 -0400
6845 +++ lrzsz-0.12.20/intl/intl-compat.c 2004-09-12 14:40:34.441735016 -0400
6847 /* intl-compat.c - Stub functions to call gettext functions from GNU gettext
6849 - Copyright (C) 1995 Software Foundation, Inc.
6850 + Copyright (C) 1995, 2000-2003 Software Foundation, Inc.
6852 -This program is free software; you can redistribute it and/or modify
6853 -it under the terms of the GNU General Public License as published by
6854 -the Free Software Foundation; either version 2, or (at your option)
6856 + This program is free software; you can redistribute it and/or modify it
6857 + under the terms of the GNU Library General Public License as published
6858 + by the Free Software Foundation; either version 2, or (at your option)
6859 + any later version.
6861 -This program is distributed in the hope that it will be useful,
6862 -but WITHOUT ANY WARRANTY; without even the implied warranty of
6863 -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
6864 -GNU General Public License for more details.
6865 + This program is distributed in the hope that it will be useful,
6866 + but WITHOUT ANY WARRANTY; without even the implied warranty of
6867 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
6868 + Library General Public License for more details.
6870 -You should have received a copy of the GNU General Public License
6871 -along with this program; if not, write to the Free Software
6872 -Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
6873 + You should have received a copy of the GNU Library General Public
6874 + License along with this program; if not, write to the Free Software
6875 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
6878 #ifdef HAVE_CONFIG_H
6879 # include <config.h>
6882 -#include "libgettext.h"
6883 +#include "gettextP.h"
6885 /* @@ end of prolog @@ */
6887 +/* This file redirects the gettext functions (without prefix) to those
6888 + defined in the included GNU libintl library (with "libintl_" prefix).
6889 + It is compiled into libintl in order to make the AM_GNU_GETTEXT test
6890 + of gettext <= 0.11.2 work with the libintl library >= 0.11.3 which
6891 + has the redirections primarily in the <libintl.h> include file.
6892 + It is also compiled into libgnuintl so that libgnuintl.so can be used
6893 + as LD_PRELOADable library on glibc systems, to provide the extra
6894 + features that the functions in the libc don't have (namely, logging). */
6904 #undef bindtextdomain
6905 +#undef bind_textdomain_codeset
6908 +/* When building a DLL, we must export some functions. Note that because
6909 + the functions are only defined for binary backward compatibility, we
6910 + don't need to use __declspec(dllimport) in any case. */
6911 +#if defined _MSC_VER && BUILDING_DLL
6912 +# define DLL_EXPORTED __declspec(dllexport)
6914 +# define DLL_EXPORTED
6920 -bindtextdomain (domainname, dirname)
6921 - const char *domainname;
6922 - const char *dirname;
6923 +gettext (const char *msgid)
6925 - return bindtextdomain__ (domainname, dirname);
6926 + return libintl_gettext (msgid);
6932 -dcgettext (domainname, msgid, category)
6933 - const char *domainname;
6934 - const char *msgid;
6936 +dgettext (const char *domainname, const char *msgid)
6938 - return dcgettext__ (domainname, msgid, category);
6939 + return libintl_dgettext (domainname, msgid);
6945 -dgettext (domainname, msgid)
6946 - const char *domainname;
6947 - const char *msgid;
6948 +dcgettext (const char *domainname, const char *msgid, int category)
6950 - return dgettext__ (domainname, msgid);
6951 + return libintl_dcgettext (domainname, msgid, category);
6958 - const char *msgid;
6959 +ngettext (const char *msgid1, const char *msgid2, unsigned long int n)
6961 - return gettext__ (msgid);
6962 + return libintl_ngettext (msgid1, msgid2, n);
6968 -textdomain (domainname)
6969 - const char *domainname;
6970 +dngettext (const char *domainname,
6971 + const char *msgid1, const char *msgid2, unsigned long int n)
6973 - return textdomain__ (domainname);
6974 + return libintl_dngettext (domainname, msgid1, msgid2, n);
6980 +dcngettext (const char *domainname,
6981 + const char *msgid1, const char *msgid2, unsigned long int n,
6984 + return libintl_dcngettext (domainname, msgid1, msgid2, n, category);
6990 +textdomain (const char *domainname)
6992 + return libintl_textdomain (domainname);
6998 +bindtextdomain (const char *domainname, const char *dirname)
7000 + return libintl_bindtextdomain (domainname, dirname);
7006 +bind_textdomain_codeset (const char *domainname, const char *codeset)
7008 + return libintl_bind_textdomain_codeset (domainname, codeset);
7010 --- lrzsz-0.12.20.safe/intl/l10nflist.c 1998-04-26 09:22:37.000000000 -0400
7011 +++ lrzsz-0.12.20/intl/l10nflist.c 2004-09-12 14:40:34.457732584 -0400
7013 -/* Handle list of needed message catalogs
7014 - Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
7015 - Written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
7016 +/* Copyright (C) 1995-1999, 2000-2003 Free Software Foundation, Inc.
7017 + Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
7019 - This program is free software; you can redistribute it and/or modify
7020 - it under the terms of the GNU General Public License as published by
7021 - the Free Software Foundation; either version 2, or (at your option)
7022 + This program is free software; you can redistribute it and/or modify it
7023 + under the terms of the GNU Library General Public License as published
7024 + by the Free Software Foundation; either version 2, or (at your option)
7027 This program is distributed in the hope that it will be useful,
7028 but WITHOUT ANY WARRANTY; without even the implied warranty of
7029 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
7030 - GNU General Public License for more details.
7031 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
7032 + Library General Public License for more details.
7034 - You should have received a copy of the GNU General Public License
7035 - along with this program; if not, write to the Free Software Foundation,
7036 - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
7037 + You should have received a copy of the GNU Library General Public
7038 + License along with this program; if not, write to the Free Software
7039 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
7042 +/* Tell glibc's <string.h> to provide a prototype for stpcpy().
7043 + This must come before <config.h> because <config.h> may include
7044 + <features.h>, and once <features.h> has been included, it's too late. */
7045 +#ifndef _GNU_SOURCE
7046 +# define _GNU_SOURCE 1
7049 #ifdef HAVE_CONFIG_H
7050 # include <config.h>
7054 -#if defined HAVE_STRING_H || defined _LIBC
7055 -# ifndef _GNU_SOURCE
7056 -# define _GNU_SOURCE 1
7058 -# include <string.h>
7060 -# include <strings.h>
7062 -# define memcpy(Dst, Src, Num) bcopy (Src, Dst, Num)
7065 -#if !HAVE_STRCHR && !defined _LIBC
7067 -# define strchr index
7070 +#include <string.h>
7072 #if defined _LIBC || defined HAVE_ARGZ_H
7076 #include <sys/types.h>
7078 -#if defined STDC_HEADERS || defined _LIBC
7079 -# include <stdlib.h>
7081 +#include <stdlib.h>
7083 #include "loadinfo.h"
7086 /* Rename the non ANSI C functions. This is required by the standard
7087 because some ANSI C functions will require linking with this object
7088 file and the name space must not be polluted. */
7089 -# define stpcpy(dest, src) __stpcpy(dest, src)
7091 +# define stpcpy(dest, src) __stpcpy(dest, src)
7094 # ifndef HAVE_STPCPY
7095 -static char *stpcpy PARAMS ((char *dest, const char *src));
7096 +static char *stpcpy (char *dest, const char *src);
7100 +/* Pathname support.
7101 + ISSLASH(C) tests whether C is a directory separator character.
7102 + IS_ABSOLUTE_PATH(P) tests whether P is an absolute path. If it is not,
7103 + it may be concatenated to a directory pathname.
7105 +#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
7106 + /* Win32, OS/2, DOS */
7107 +# define ISSLASH(C) ((C) == '/' || (C) == '\\')
7108 +# define HAS_DEVICE(P) \
7109 + ((((P)[0] >= 'A' && (P)[0] <= 'Z') || ((P)[0] >= 'a' && (P)[0] <= 'z')) \
7111 +# define IS_ABSOLUTE_PATH(P) (ISSLASH ((P)[0]) || HAS_DEVICE (P))
7114 +# define ISSLASH(C) ((C) == '/')
7115 +# define IS_ABSOLUTE_PATH(P) ISSLASH ((P)[0])
7118 /* Define function which are usually not available. */
7120 #if !defined _LIBC && !defined HAVE___ARGZ_COUNT
7121 /* Returns the number of strings in ARGZ. */
7122 -static size_t argz_count__ PARAMS ((const char *argz, size_t len));
7125 -argz_count__ (argz, len)
7128 +argz_count__ (const char *argz, size_t len)
7134 # undef __argz_count
7135 # define __argz_count(argz, len) argz_count__ (argz, len)
7138 +# define __argz_count(argz, len) INTUSE(__argz_count) (argz, len)
7140 #endif /* !_LIBC && !HAVE___ARGZ_COUNT */
7142 #if !defined _LIBC && !defined HAVE___ARGZ_STRINGIFY
7143 /* Make '\0' separated arg vector ARGZ printable by converting all the '\0's
7144 except the last into the character SEP. */
7145 -static void argz_stringify__ PARAMS ((char *argz, size_t len, int sep));
7148 -argz_stringify__ (argz, len, sep)
7152 +argz_stringify__ (char *argz, size_t len, int sep)
7156 @@ -119,17 +122,16 @@
7158 # undef __argz_stringify
7159 # define __argz_stringify(argz, len, sep) argz_stringify__ (argz, len, sep)
7162 +# define __argz_stringify(argz, len, sep) \
7163 + INTUSE(__argz_stringify) (argz, len, sep)
7165 #endif /* !_LIBC && !HAVE___ARGZ_STRINGIFY */
7167 #if !defined _LIBC && !defined HAVE___ARGZ_NEXT
7168 -static char *argz_next__ PARAMS ((char *argz, size_t argz_len,
7169 - const char *entry));
7172 -argz_next__ (argz, argz_len, entry)
7175 - const char *entry;
7176 +argz_next__ (char *argz, size_t argz_len, const char *entry)
7180 @@ -150,11 +152,8 @@
7183 /* Return number of bits set in X. */
7184 -static int pop PARAMS ((int x));
7191 /* We assume that no more than 16 bits are used. */
7192 x = ((x & ~0x5555) >> 1) + (x & 0x5555);
7193 @@ -167,31 +166,27 @@
7196 struct loaded_l10nfile *
7197 -_nl_make_l10nflist (l10nfile_list, dirlist, dirlist_len, mask, language,
7198 - territory, codeset, normalized_codeset, modifier, special,
7199 - sponsor, revision, filename, do_allocate)
7200 - struct loaded_l10nfile **l10nfile_list;
7201 - const char *dirlist;
7202 - size_t dirlist_len;
7204 - const char *language;
7205 - const char *territory;
7206 - const char *codeset;
7207 - const char *normalized_codeset;
7208 - const char *modifier;
7209 - const char *special;
7210 - const char *sponsor;
7211 - const char *revision;
7212 - const char *filename;
7214 +_nl_make_l10nflist (struct loaded_l10nfile **l10nfile_list,
7215 + const char *dirlist, size_t dirlist_len,
7216 + int mask, const char *language, const char *territory,
7217 + const char *codeset, const char *normalized_codeset,
7218 + const char *modifier, const char *special,
7219 + const char *sponsor, const char *revision,
7220 + const char *filename, int do_allocate)
7223 - struct loaded_l10nfile *last = NULL;
7224 + struct loaded_l10nfile **lastp;
7225 struct loaded_l10nfile *retval;
7227 + size_t dirlist_count;
7231 + /* If LANGUAGE contains an absolute directory specification, we ignore
7233 + if (IS_ABSOLUTE_PATH (language))
7236 /* Allocate room for the full file name. */
7237 abs_filename = (char *) malloc (dirlist_len
7240 + (((mask & CEN_SPONSOR) != 0
7241 || (mask & CEN_REVISION) != 0)
7242 ? (1 + ((mask & CEN_SPONSOR) != 0
7243 - ? strlen (sponsor) + 1 : 0)
7244 + ? strlen (sponsor) : 0)
7245 + ((mask & CEN_REVISION) != 0
7246 ? strlen (revision) + 1 : 0)) : 0)
7247 + 1 + strlen (filename) + 1);
7248 @@ -217,14 +212,16 @@
7249 if (abs_filename == NULL)
7255 /* Construct file name. */
7256 - memcpy (abs_filename, dirlist, dirlist_len);
7257 - __argz_stringify (abs_filename, dirlist_len, ':');
7258 - cp = abs_filename + (dirlist_len - 1);
7260 + cp = abs_filename;
7261 + if (dirlist_len > 0)
7263 + memcpy (cp, dirlist, dirlist_len);
7264 + __argz_stringify (cp, dirlist_len, PATH_SEPARATOR);
7265 + cp += dirlist_len;
7269 cp = stpcpy (cp, language);
7271 if ((mask & TERRITORY) != 0)
7274 /* Look in list of already loaded domains whether it is already
7277 + lastp = l10nfile_list;
7278 for (retval = *l10nfile_list; retval != NULL; retval = retval->next)
7279 if (retval->filename != NULL)
7286 + lastp = &retval->next;
7289 if (retval != NULL || do_allocate == 0)
7290 @@ -295,48 +292,66 @@
7294 - retval = (struct loaded_l10nfile *)
7295 - malloc (sizeof (*retval) + (__argz_count (dirlist, dirlist_len)
7296 - * (1 << pop (mask))
7297 - * sizeof (struct loaded_l10nfile *)));
7298 + dirlist_count = (dirlist_len > 0 ? __argz_count (dirlist, dirlist_len) : 1);
7300 + /* Allocate a new loaded_l10nfile. */
7302 + (struct loaded_l10nfile *)
7303 + malloc (sizeof (*retval)
7304 + + (((dirlist_count << pop (mask)) + (dirlist_count > 1 ? 1 : 0))
7305 + * sizeof (struct loaded_l10nfile *)));
7309 retval->filename = abs_filename;
7310 - retval->decided = (__argz_count (dirlist, dirlist_len) != 1
7312 + /* We set retval->data to NULL here; it is filled in later.
7313 + Setting retval->decided to 1 here means that retval does not
7314 + correspond to a real file (dirlist_count > 1) or is not worth
7315 + looking up (if an unnormalized codeset was specified). */
7316 + retval->decided = (dirlist_count > 1
7317 || ((mask & XPG_CODESET) != 0
7318 && (mask & XPG_NORM_CODESET) != 0));
7319 retval->data = NULL;
7323 - retval->next = *l10nfile_list;
7324 - *l10nfile_list = retval;
7328 - retval->next = last->next;
7329 - last->next = retval;
7331 + retval->next = *lastp;
7335 - /* If the DIRLIST is a real list the RETVAL entry corresponds not to
7336 - a real file. So we have to use the DIRLIST separation mechanism
7337 - of the inner loop. */
7338 - cnt = __argz_count (dirlist, dirlist_len) == 1 ? mask - 1 : mask;
7339 - for (; cnt >= 0; --cnt)
7340 + /* Recurse to fill the inheritance list of RETVAL.
7341 + If the DIRLIST is a real list (i.e. DIRLIST_COUNT > 1), the RETVAL
7342 + entry does not correspond to a real file; retval->filename contains
7343 + colons. In this case we loop across all elements of DIRLIST and
7344 + across all bit patterns dominated by MASK.
7345 + If the DIRLIST is a single directory or entirely redundant (i.e.
7346 + DIRLIST_COUNT == 1), we loop across all bit patterns dominated by
7347 + MASK, excluding MASK itself.
7348 + In either case, we loop down from MASK to 0. This has the effect
7349 + that the extra bits in the locale name are dropped in this order:
7350 + first the modifier, then the territory, then the codeset, then the
7351 + normalized_codeset. */
7352 + for (cnt = dirlist_count > 1 ? mask : mask - 1; cnt >= 0; --cnt)
7353 if ((cnt & ~mask) == 0
7354 && ((cnt & CEN_SPECIFIC) == 0 || (cnt & XPG_SPECIFIC) == 0)
7355 && ((cnt & XPG_CODESET) == 0 || (cnt & XPG_NORM_CODESET) == 0))
7357 - /* Iterate over all elements of the DIRLIST. */
7359 + if (dirlist_count > 1)
7361 + /* Iterate over all elements of the DIRLIST. */
7364 - while ((dir = __argz_next ((char *) dirlist, dirlist_len, dir))
7366 + while ((dir = __argz_next ((char *) dirlist, dirlist_len, dir))
7368 + retval->successor[entries++]
7369 + = _nl_make_l10nflist (l10nfile_list, dir, strlen (dir) + 1,
7370 + cnt, language, territory, codeset,
7371 + normalized_codeset, modifier, special,
7372 + sponsor, revision, filename, 1);
7375 retval->successor[entries++]
7376 - = _nl_make_l10nflist (l10nfile_list, dir, strlen (dir) + 1, cnt,
7377 - language, territory, codeset,
7378 + = _nl_make_l10nflist (l10nfile_list, dirlist, dirlist_len,
7379 + cnt, language, territory, codeset,
7380 normalized_codeset, modifier, special,
7381 sponsor, revision, filename, 1);
7383 @@ -347,11 +362,10 @@
7385 /* Normalize codeset name. There is no standard for the codeset
7386 names. Normalization allows the user to use any of the common
7388 + names. The return value is dynamically allocated and has to be
7389 + freed by the caller. */
7391 -_nl_normalize_codeset (codeset, name_len)
7392 - const char *codeset;
7394 +_nl_normalize_codeset (const char *codeset, size_t name_len)
7398 @@ -360,11 +374,11 @@
7401 for (cnt = 0; cnt < name_len; ++cnt)
7402 - if (isalnum (codeset[cnt]))
7403 + if (isalnum ((unsigned char) codeset[cnt]))
7407 - if (isalpha (codeset[cnt]))
7408 + if (isalpha ((unsigned char) codeset[cnt]))
7415 for (cnt = 0; cnt < name_len; ++cnt)
7416 - if (isalpha (codeset[cnt]))
7417 - *wp++ = tolower (codeset[cnt]);
7418 - else if (isdigit (codeset[cnt]))
7419 + if (isalpha ((unsigned char) codeset[cnt]))
7420 + *wp++ = tolower ((unsigned char) codeset[cnt]);
7421 + else if (isdigit ((unsigned char) codeset[cnt]))
7422 *wp++ = codeset[cnt];
7427 #if !_LIBC && !HAVE_STPCPY
7432 +stpcpy (char *dest, const char *src)
7434 while ((*dest++ = *src++) != '\0')
7436 --- lrzsz-0.12.20.safe/intl/libgettext.h 1998-04-26 09:22:36.000000000 -0400
7437 +++ lrzsz-0.12.20/intl/libgettext.h 1969-12-31 19:00:00.000000000 -0500
7439 -/* Message catalogs for internationalization.
7440 - Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
7442 - This program is free software; you can redistribute it and/or modify
7443 - it under the terms of the GNU General Public License as published by
7444 - the Free Software Foundation; either version 2, or (at your option)
7445 - any later version.
7447 - This program is distributed in the hope that it will be useful,
7448 - but WITHOUT ANY WARRANTY; without even the implied warranty of
7449 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
7450 - GNU General Public License for more details.
7452 - You should have received a copy of the GNU General Public License
7453 - along with this program; if not, write to the Free Software Foundation,
7454 - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
7456 -/* Because on some systems (e.g. Solaris) we sometimes have to include
7457 - the systems libintl.h as well as this file we have more complex
7458 - include protection above. But the systems header might perhaps also
7459 - define _LIBINTL_H and therefore we have to protect the definition here. */
7461 -#if !defined (_LIBINTL_H) || !defined (_LIBGETTEXT_H)
7462 -#if !defined (_LIBINTL_H)
7463 -# define _LIBINTL_H 1
7465 -#define _LIBGETTEXT_H 1
7467 -/* We define an additional symbol to signal that we use the GNU
7468 - implementation of gettext. */
7469 -#define __USE_GNU_GETTEXT 1
7471 -#include <sys/types.h>
7474 -# include <locale.h>
7482 -/* @@ end of prolog @@ */
7486 -# define PARAMS(args) args
7488 -# define PARAMS(args) ()
7493 -# if !defined __cplusplus || defined __GNUC__
7494 -# define NULL ((void *) 0)
7500 -#if !HAVE_LC_MESSAGES
7501 -/* This value determines the behaviour of the gettext() and dgettext()
7502 - function. But some system does not have this defined. Define it
7503 - to a default value. */
7504 -# define LC_MESSAGES (-1)
7508 -/* Declarations for gettext-using-catgets interface. Derived from
7509 - Jim Meyering's libintl.h. */
7518 -/* These two variables are defined in the automatically by po-to-tbl.sed
7519 - generated file `cat-id-tbl.c'. */
7520 -extern const struct _msg_ent _msg_tbl[];
7521 -extern int _msg_tbl_length;
7525 -/* For automatical extraction of messages sometimes no real
7526 - translation is needed. Instead the string itself is the result. */
7527 -#define gettext_noop(Str) (Str)
7529 -/* Look up MSGID in the current default message catalog for the current
7530 - LC_MESSAGES locale. If not found, returns MSGID itself (the default
7532 -extern char *gettext PARAMS ((const char *__msgid));
7533 -extern char *gettext__ PARAMS ((const char *__msgid));
7535 -/* Look up MSGID in the DOMAINNAME message catalog for the current
7536 - LC_MESSAGES locale. */
7537 -extern char *dgettext PARAMS ((const char *__domainname, const char *__msgid));
7538 -extern char *dgettext__ PARAMS ((const char *__domainname,
7539 - const char *__msgid));
7541 -/* Look up MSGID in the DOMAINNAME message catalog for the current CATEGORY
7543 -extern char *dcgettext PARAMS ((const char *__domainname, const char *__msgid,
7545 -extern char *dcgettext__ PARAMS ((const char *__domainname,
7546 - const char *__msgid, int __category));
7549 -/* Set the current default message catalog to DOMAINNAME.
7550 - If DOMAINNAME is null, return the current default.
7551 - If DOMAINNAME is "", reset to the default of "messages". */
7552 -extern char *textdomain PARAMS ((const char *__domainname));
7553 -extern char *textdomain__ PARAMS ((const char *__domainname));
7555 -/* Specify that the DOMAINNAME message catalog will be found
7556 - in DIRNAME rather than in the system locale data base. */
7557 -extern char *bindtextdomain PARAMS ((const char *__domainname,
7558 - const char *__dirname));
7559 -extern char *bindtextdomain__ PARAMS ((const char *__domainname,
7560 - const char *__dirname));
7564 -/* Solaris 2.3 has the gettext function but dcgettext is missing.
7565 - So we omit this optimization for Solaris 2.3. BTW, Solaris 2.4
7567 -# if !HAVE_CATGETS && (!HAVE_GETTEXT || HAVE_DCGETTEXT)
7569 -# define gettext(Msgid) \
7570 - dgettext (NULL, Msgid)
7572 -# define dgettext(Domainname, Msgid) \
7573 - dcgettext (Domainname, Msgid, LC_MESSAGES)
7575 -# if defined __GNUC__ && __GNUC__ == 2 && __GNUC_MINOR__ >= 7
7576 -/* This global variable is defined in loadmsgcat.c. We need a sign,
7577 - whether a new catalog was loaded, which can be associated with all
7579 -extern int _nl_msg_cat_cntr;
7581 -# define dcgettext(Domainname, Msgid, Category) \
7585 - if (__builtin_constant_p (Msgid)) \
7587 - static char *__translation__; \
7588 - static int __catalog_counter__; \
7589 - if (! __translation__ || __catalog_counter__ != _nl_msg_cat_cntr) \
7591 - __translation__ = \
7592 - dcgettext__ (Domainname, Msgid, Category); \
7593 - __catalog_counter__ = _nl_msg_cat_cntr; \
7595 - __result = __translation__; \
7598 - __result = dcgettext__ (Domainname, Msgid, Category); \
7606 -# define gettext(Msgid) (Msgid)
7607 -# define dgettext(Domainname, Msgid) (Msgid)
7608 -# define dcgettext(Domainname, Msgid, Category) (Msgid)
7609 -# define textdomain(Domainname) while (0) /* nothing */
7610 -# define bindtextdomain(Domainname, Dirname) while (0) /* nothing */
7614 -/* @@ begin of epilog @@ */
7621 --- lrzsz-0.12.20.safe/intl/libgnuintl.h.in 1969-12-31 19:00:00.000000000 -0500
7622 +++ lrzsz-0.12.20/intl/libgnuintl.h.in 2004-09-12 14:40:34.462731824 -0400
7624 +/* Message catalogs for internationalization.
7625 + Copyright (C) 1995-1997, 2000-2003 Free Software Foundation, Inc.
7627 + This program is free software; you can redistribute it and/or modify it
7628 + under the terms of the GNU Library General Public License as published
7629 + by the Free Software Foundation; either version 2, or (at your option)
7630 + any later version.
7632 + This program is distributed in the hope that it will be useful,
7633 + but WITHOUT ANY WARRANTY; without even the implied warranty of
7634 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
7635 + Library General Public License for more details.
7637 + You should have received a copy of the GNU Library General Public
7638 + License along with this program; if not, write to the Free Software
7639 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
7643 +#define _LIBINTL_H 1
7645 +#include <locale.h>
7647 +/* The LC_MESSAGES locale category is the category used by the functions
7648 + gettext() and dgettext(). It is specified in POSIX, but not in ANSI C.
7649 + On systems that don't define it, use an arbitrary value instead.
7650 + On Solaris, <locale.h> defines __LOCALE_H (or _LOCALE_H in Solaris 2.5)
7651 + then includes <libintl.h> (i.e. this file!) and then only defines
7652 + LC_MESSAGES. To avoid a redefinition warning, don't define LC_MESSAGES
7654 +#if !defined LC_MESSAGES && !(defined __LOCALE_H || (defined _LOCALE_H && defined __sun))
7655 +# define LC_MESSAGES 1729
7658 +/* We define an additional symbol to signal that we use the GNU
7659 + implementation of gettext. */
7660 +#define __USE_GNU_GETTEXT 1
7662 +/* Provide information about the supported file formats. Returns the
7663 + maximum minor revision number supported for a given major revision. */
7664 +#define __GNU_GETTEXT_SUPPORTED_REVISION(major) \
7665 + ((major) == 0 ? 1 : -1)
7667 +/* Resolve a platform specific conflict on DJGPP. GNU gettext takes
7668 + precedence over _conio_gettext. */
7678 +/* We redirect the functions to those prefixed with "libintl_". This is
7679 + necessary, because some systems define gettext/textdomain/... in the C
7680 + library (namely, Solaris 2.4 and newer, and GNU libc 2.0 and newer).
7681 + If we used the unprefixed names, there would be cases where the
7682 + definition in the C library would override the one in the libintl.so
7683 + shared library. Recall that on ELF systems, the symbols are looked
7684 + up in the following order:
7685 + 1. in the executable,
7686 + 2. in the shared libraries specified on the link command line, in order,
7687 + 3. in the dependencies of the shared libraries specified on the link
7689 + 4. in the dlopen()ed shared libraries, in the order in which they were
7691 + The definition in the C library would override the one in libintl.so if
7693 + * -lc is given on the link command line and -lintl isn't, or
7694 + * -lc is given on the link command line before -lintl, or
7695 + * libintl.so is a dependency of a dlopen()ed shared library but not
7696 + linked to the executable at link time.
7697 + Since Solaris gettext() behaves differently than GNU gettext(), this
7698 + would be unacceptable.
7700 + The redirection happens by default through macros in C, so that &gettext
7701 + is independent of the compilation unit, but through inline functions in
7702 + C++, in order not to interfere with the name mangling of class fields or
7703 + class methods called 'gettext'. */
7705 +/* The user can define _INTL_REDIRECT_INLINE or _INTL_REDIRECT_MACROS.
7706 + If he doesn't, we choose the method. A third possible method is
7707 + _INTL_REDIRECT_ASM, supported only by GCC. */
7708 +#if !(defined _INTL_REDIRECT_INLINE || defined _INTL_REDIRECT_MACROS)
7709 +# if __GNUC__ >= 2 && !defined __APPLE_CC__ && !defined __MINGW32__ && !(__GNUC__ == 2 && defined _AIX) && (defined __STDC__ || defined __cplusplus)
7710 +# define _INTL_REDIRECT_ASM
7712 +# ifdef __cplusplus
7713 +# define _INTL_REDIRECT_INLINE
7715 +# define _INTL_REDIRECT_MACROS
7719 +/* Auxiliary macros. */
7720 +#ifdef _INTL_REDIRECT_ASM
7721 +# define _INTL_ASM(cname) __asm__ (_INTL_ASMNAME (__USER_LABEL_PREFIX__, #cname))
7722 +# define _INTL_ASMNAME(prefix,cnamestring) _INTL_STRINGIFY (prefix) cnamestring
7723 +# define _INTL_STRINGIFY(prefix) #prefix
7725 +# define _INTL_ASM(cname)
7728 +/* Look up MSGID in the current default message catalog for the current
7729 + LC_MESSAGES locale. If not found, returns MSGID itself (the default
7731 +#ifdef _INTL_REDIRECT_INLINE
7732 +extern char *libintl_gettext (const char *__msgid);
7733 +static inline char *gettext (const char *__msgid)
7735 + return libintl_gettext (__msgid);
7738 +#ifdef _INTL_REDIRECT_MACROS
7739 +# define gettext libintl_gettext
7741 +extern char *gettext (const char *__msgid)
7742 + _INTL_ASM (libintl_gettext);
7745 +/* Look up MSGID in the DOMAINNAME message catalog for the current
7746 + LC_MESSAGES locale. */
7747 +#ifdef _INTL_REDIRECT_INLINE
7748 +extern char *libintl_dgettext (const char *__domainname, const char *__msgid);
7749 +static inline char *dgettext (const char *__domainname, const char *__msgid)
7751 + return libintl_dgettext (__domainname, __msgid);
7754 +#ifdef _INTL_REDIRECT_MACROS
7755 +# define dgettext libintl_dgettext
7757 +extern char *dgettext (const char *__domainname, const char *__msgid)
7758 + _INTL_ASM (libintl_dgettext);
7761 +/* Look up MSGID in the DOMAINNAME message catalog for the current CATEGORY
7763 +#ifdef _INTL_REDIRECT_INLINE
7764 +extern char *libintl_dcgettext (const char *__domainname, const char *__msgid,
7766 +static inline char *dcgettext (const char *__domainname, const char *__msgid,
7769 + return libintl_dcgettext (__domainname, __msgid, __category);
7772 +#ifdef _INTL_REDIRECT_MACROS
7773 +# define dcgettext libintl_dcgettext
7775 +extern char *dcgettext (const char *__domainname, const char *__msgid,
7777 + _INTL_ASM (libintl_dcgettext);
7781 +/* Similar to `gettext' but select the plural form corresponding to the
7783 +#ifdef _INTL_REDIRECT_INLINE
7784 +extern char *libintl_ngettext (const char *__msgid1, const char *__msgid2,
7785 + unsigned long int __n);
7786 +static inline char *ngettext (const char *__msgid1, const char *__msgid2,
7787 + unsigned long int __n)
7789 + return libintl_ngettext (__msgid1, __msgid2, __n);
7792 +#ifdef _INTL_REDIRECT_MACROS
7793 +# define ngettext libintl_ngettext
7795 +extern char *ngettext (const char *__msgid1, const char *__msgid2,
7796 + unsigned long int __n)
7797 + _INTL_ASM (libintl_ngettext);
7800 +/* Similar to `dgettext' but select the plural form corresponding to the
7802 +#ifdef _INTL_REDIRECT_INLINE
7803 +extern char *libintl_dngettext (const char *__domainname, const char *__msgid1,
7804 + const char *__msgid2, unsigned long int __n);
7805 +static inline char *dngettext (const char *__domainname, const char *__msgid1,
7806 + const char *__msgid2, unsigned long int __n)
7808 + return libintl_dngettext (__domainname, __msgid1, __msgid2, __n);
7811 +#ifdef _INTL_REDIRECT_MACROS
7812 +# define dngettext libintl_dngettext
7814 +extern char *dngettext (const char *__domainname,
7815 + const char *__msgid1, const char *__msgid2,
7816 + unsigned long int __n)
7817 + _INTL_ASM (libintl_dngettext);
7820 +/* Similar to `dcgettext' but select the plural form corresponding to the
7822 +#ifdef _INTL_REDIRECT_INLINE
7823 +extern char *libintl_dcngettext (const char *__domainname,
7824 + const char *__msgid1, const char *__msgid2,
7825 + unsigned long int __n, int __category);
7826 +static inline char *dcngettext (const char *__domainname,
7827 + const char *__msgid1, const char *__msgid2,
7828 + unsigned long int __n, int __category)
7830 + return libintl_dcngettext (__domainname, __msgid1, __msgid2, __n, __category);
7833 +#ifdef _INTL_REDIRECT_MACROS
7834 +# define dcngettext libintl_dcngettext
7836 +extern char *dcngettext (const char *__domainname,
7837 + const char *__msgid1, const char *__msgid2,
7838 + unsigned long int __n, int __category)
7839 + _INTL_ASM (libintl_dcngettext);
7843 +/* Set the current default message catalog to DOMAINNAME.
7844 + If DOMAINNAME is null, return the current default.
7845 + If DOMAINNAME is "", reset to the default of "messages". */
7846 +#ifdef _INTL_REDIRECT_INLINE
7847 +extern char *libintl_textdomain (const char *__domainname);
7848 +static inline char *textdomain (const char *__domainname)
7850 + return libintl_textdomain (__domainname);
7853 +#ifdef _INTL_REDIRECT_MACROS
7854 +# define textdomain libintl_textdomain
7856 +extern char *textdomain (const char *__domainname)
7857 + _INTL_ASM (libintl_textdomain);
7860 +/* Specify that the DOMAINNAME message catalog will be found
7861 + in DIRNAME rather than in the system locale data base. */
7862 +#ifdef _INTL_REDIRECT_INLINE
7863 +extern char *libintl_bindtextdomain (const char *__domainname,
7864 + const char *__dirname);
7865 +static inline char *bindtextdomain (const char *__domainname,
7866 + const char *__dirname)
7868 + return libintl_bindtextdomain (__domainname, __dirname);
7871 +#ifdef _INTL_REDIRECT_MACROS
7872 +# define bindtextdomain libintl_bindtextdomain
7874 +extern char *bindtextdomain (const char *__domainname, const char *__dirname)
7875 + _INTL_ASM (libintl_bindtextdomain);
7878 +/* Specify the character encoding in which the messages from the
7879 + DOMAINNAME message catalog will be returned. */
7880 +#ifdef _INTL_REDIRECT_INLINE
7881 +extern char *libintl_bind_textdomain_codeset (const char *__domainname,
7882 + const char *__codeset);
7883 +static inline char *bind_textdomain_codeset (const char *__domainname,
7884 + const char *__codeset)
7886 + return libintl_bind_textdomain_codeset (__domainname, __codeset);
7889 +#ifdef _INTL_REDIRECT_MACROS
7890 +# define bind_textdomain_codeset libintl_bind_textdomain_codeset
7892 +extern char *bind_textdomain_codeset (const char *__domainname,
7893 + const char *__codeset)
7894 + _INTL_ASM (libintl_bind_textdomain_codeset);
7898 +/* Support for format strings with positions in *printf(), following the
7899 + POSIX/XSI specification.
7900 + Note: These replacements for the *printf() functions are visible only
7901 + in source files that #include <libintl.h> or #include "gettext.h".
7902 + Packages that use *printf() in source files that don't refer to _()
7903 + or gettext() but for which the format string could be the return value
7904 + of _() or gettext() need to add this #include. Oh well. */
7906 +#if !@HAVE_POSIX_PRINTF@
7909 +#include <stddef.h>
7912 +#if __STDC__ || defined __cplusplus || defined _MSC_VER
7913 +# include <stdarg.h>
7915 +# include <varargs.h>
7919 +#define fprintf libintl_fprintf
7920 +extern int fprintf (FILE *, const char *, ...);
7922 +#define vfprintf libintl_vfprintf
7923 +extern int vfprintf (FILE *, const char *, va_list);
7926 +#define printf libintl_printf
7927 +extern int printf (const char *, ...);
7929 +#define vprintf libintl_vprintf
7930 +extern int vprintf (const char *, va_list);
7933 +#define sprintf libintl_sprintf
7934 +extern int sprintf (char *, const char *, ...);
7936 +#define vsprintf libintl_vsprintf
7937 +extern int vsprintf (char *, const char *, va_list);
7939 +#if @HAVE_SNPRINTF@
7942 +#define snprintf libintl_snprintf
7943 +extern int snprintf (char *, size_t, const char *, ...);
7945 +#define vsnprintf libintl_vsnprintf
7946 +extern int vsnprintf (char *, size_t, const char *, va_list);
7950 +#if @HAVE_ASPRINTF@
7953 +#define asprintf libintl_asprintf
7954 +extern int asprintf (char **, const char *, ...);
7956 +#define vasprintf libintl_vasprintf
7957 +extern int vasprintf (char **, const char *, va_list);
7964 +#define fwprintf libintl_fwprintf
7965 +extern int fwprintf (FILE *, const wchar_t *, ...);
7967 +#define vfwprintf libintl_vfwprintf
7968 +extern int vfwprintf (FILE *, const wchar_t *, va_list);
7971 +#define wprintf libintl_wprintf
7972 +extern int wprintf (const wchar_t *, ...);
7974 +#define vwprintf libintl_vwprintf
7975 +extern int vwprintf (const wchar_t *, va_list);
7978 +#define swprintf libintl_swprintf
7979 +extern int swprintf (wchar_t *, size_t, const wchar_t *, ...);
7981 +#define vswprintf libintl_vswprintf
7982 +extern int vswprintf (wchar_t *, size_t, const wchar_t *, va_list);
7989 +/* Support for relocatable packages. */
7991 +/* Sets the original and the current installation prefix of the package.
7992 + Relocation simply replaces a pathname starting with the original prefix
7993 + by the corresponding pathname with the current prefix instead. Both
7994 + prefixes should be directory names without trailing slash (i.e. use ""
7995 + instead of "/"). */
7996 +#define libintl_set_relocation_prefix libintl_set_relocation_prefix
7998 + libintl_set_relocation_prefix (const char *orig_prefix,
7999 + const char *curr_prefix);
8006 +#endif /* libintl.h */
8007 --- lrzsz-0.12.20.safe/intl/linux-msg.sed 1998-04-26 09:20:52.000000000 -0400
8008 +++ lrzsz-0.12.20/intl/linux-msg.sed 1969-12-31 19:00:00.000000000 -0500
8010 -# po2msg.sed - Convert Uniforum style .po file to Linux style .msg file
8011 -# Copyright (C) 1995 Free Software Foundation, Inc.
8012 -# Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
8014 -# This program is free software; you can redistribute it and/or modify
8015 -# it under the terms of the GNU General Public License as published by
8016 -# the Free Software Foundation; either version 2, or (at your option)
8017 -# any later version.
8019 -# This program is distributed in the hope that it will be useful,
8020 -# but WITHOUT ANY WARRANTY; without even the implied warranty of
8021 -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
8022 -# GNU General Public License for more details.
8024 -# You should have received a copy of the GNU General Public License
8025 -# along with this program; if not, write to the Free Software
8026 -# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
8029 -# The first directive in the .msg should be the definition of the
8030 -# message set number. We use always set number 1.
8034 -$set 1 # Automatically created by po2msg.sed
8040 -# Mitch's old catalog format does not allow comments.
8042 -# We copy the original message as a comment into the .msg file.
8047 -# This does not work now with the new format.
8050 -# s/$/ ... (more lines following)"/
8053 -# The following nice solution is by
8054 -# Bruno <Haible@ma2s2.mathematik.uni-karlsruhe.de>
8056 -# Increment a decimal number in pattern space.
8057 -# First hide trailing `9' digits.
8061 -# Assure at least one digit is available.
8063 -# Increment the last digit.
8073 -# Convert the hidden `9' digits to `0's.
8077 - s/\(.*\)"\n\([0-9]*\)/$ #\2 Original Message:(\1)/p
8080 -# The .msg file contains, other then the .po file, only the translations
8081 -# but each given a unique ID. Starting from 1 and incrementing by 1 for
8082 -# each message we assign them to the messages.
8083 -# It is important that the .po file used to generate the cat-id-tbl.c file
8084 -# (with po-to-tbl) is the same as the one used here. (At least the order
8085 -# of declarations must not be changed.)
8088 - s/msgstr[ ]*"\(.*\)"/# \1/
8089 -# Clear substitution flag.
8091 -# Append the next line.
8094 -# Look whether second part is continuation line.
8095 - s/\(.*\n\)"\(.*\)"/\1\2/
8096 -# Yes, then branch.
8100 -# Note that D includes a jump to the start!!
8101 -# We found a continuation line. But before printing insert '\'.
8103 - s/\(.*\)\(\n.*\)/\1\\\2/
8105 -# We cannot use D here.
8110 --- lrzsz-0.12.20.safe/intl/loadinfo.h 1998-04-26 09:20:52.000000000 -0400
8111 +++ lrzsz-0.12.20/intl/loadinfo.h 2004-09-12 14:40:34.468730912 -0400
8115 -# define PARAMS(args) args
8117 -# define PARAMS(args) ()
8119 +/* Copyright (C) 1996-1999, 2000-2003 Free Software Foundation, Inc.
8120 + This file is part of the GNU C Library.
8121 + Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
8123 + This program is free software; you can redistribute it and/or modify it
8124 + under the terms of the GNU Library General Public License as published
8125 + by the Free Software Foundation; either version 2, or (at your option)
8126 + any later version.
8128 + This program is distributed in the hope that it will be useful,
8129 + but WITHOUT ANY WARRANTY; without even the implied warranty of
8130 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
8131 + Library General Public License for more details.
8133 + You should have received a copy of the GNU Library General Public
8134 + License along with this program; if not, write to the Free Software
8135 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
8138 +#ifndef _LOADINFO_H
8139 +#define _LOADINFO_H 1
8141 +/* Declarations of locale dependent catalog lookup functions.
8144 + localealias.c Possibly replace a locale name by another.
8145 + explodename.c Split a locale name into its various fields.
8146 + l10nflist.c Generate a list of filenames of possible message catalogs.
8147 + finddomain.c Find and open the relevant message catalogs.
8149 + The main function _nl_find_domain() in finddomain.c is declared
8153 +#ifndef internal_function
8154 +# define internal_function
8157 +/* Tell the compiler when a conditional or integer expression is
8158 + almost always true or almost always false. */
8159 +#ifndef HAVE_BUILTIN_EXPECT
8160 +# define __builtin_expect(expr, val) (expr)
8163 +/* Separator in PATH like lists of pathnames. */
8164 +#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
8165 + /* Win32, OS/2, DOS */
8166 +# define PATH_SEPARATOR ';'
8169 +# define PATH_SEPARATOR ':'
8172 /* Encoding of locale name parts. */
8177 -extern const char *_nl_normalize_codeset PARAMS ((const char *codeset,
8178 - size_t name_len));
8179 +/* Normalize codeset name. There is no standard for the codeset
8180 + names. Normalization allows the user to use any of the common
8181 + names. The return value is dynamically allocated and has to be
8182 + freed by the caller. */
8183 +extern const char *_nl_normalize_codeset (const char *codeset,
8186 +/* Lookup a locale dependent file.
8187 + *L10NFILE_LIST denotes a pool of lookup results of locale dependent
8188 + files of the same kind, sorted in decreasing order of ->filename.
8189 + DIRLIST and DIRLIST_LEN are an argz list of directories in which to
8190 + look, containing at least one directory (i.e. DIRLIST_LEN > 0).
8191 + MASK, LANGUAGE, TERRITORY, CODESET, NORMALIZED_CODESET, MODIFIER,
8192 + SPECIAL, SPONSOR, REVISION are the pieces of the locale name, as
8193 + produced by _nl_explode_name(). FILENAME is the filename suffix.
8194 + The return value is the lookup result, either found in *L10NFILE_LIST,
8195 + or - if DO_ALLOCATE is nonzero - freshly allocated, or possibly NULL.
8196 + If the return value is non-NULL, it is added to *L10NFILE_LIST, and
8197 + its ->next field denotes the chaining inside *L10NFILE_LIST, and
8198 + furthermore its ->successor[] field contains a list of other lookup
8199 + results from which this lookup result inherits. */
8200 extern struct loaded_l10nfile *
8201 -_nl_make_l10nflist PARAMS ((struct loaded_l10nfile **l10nfile_list,
8202 - const char *dirlist, size_t dirlist_len, int mask,
8203 - const char *language, const char *territory,
8204 - const char *codeset,
8205 - const char *normalized_codeset,
8206 - const char *modifier, const char *special,
8207 - const char *sponsor, const char *revision,
8208 - const char *filename, int do_allocate));
8209 +_nl_make_l10nflist (struct loaded_l10nfile **l10nfile_list,
8210 + const char *dirlist, size_t dirlist_len, int mask,
8211 + const char *language, const char *territory,
8212 + const char *codeset, const char *normalized_codeset,
8213 + const char *modifier, const char *special,
8214 + const char *sponsor, const char *revision,
8215 + const char *filename, int do_allocate);
8217 +/* Lookup the real locale name for a locale alias NAME, or NULL if
8218 + NAME is not a locale alias (but possibly a real locale name).
8219 + The return value is statically allocated and must not be freed. */
8220 +extern const char *_nl_expand_alias (const char *name);
8222 -extern const char *_nl_expand_alias PARAMS ((const char *name));
8223 +/* Split a locale name NAME into its pieces: language, modifier,
8224 + territory, codeset, special, sponsor, revision.
8225 + NAME gets destructively modified: NUL bytes are inserted here and
8226 + there. *LANGUAGE gets assigned NAME. Each of *MODIFIER, *TERRITORY,
8227 + *CODESET, *SPECIAL, *SPONSOR, *REVISION gets assigned either a
8228 + pointer into the old NAME string, or NULL. *NORMALIZED_CODESET
8229 + gets assigned the expanded *CODESET, if it is different from *CODESET;
8230 + this one is dynamically allocated and has to be freed by the caller.
8231 + The return value is a bitmask, where each bit corresponds to one
8233 + XPG_MODIFIER, CEN_AUDIENCE for *MODIFIER,
8234 + TERRITORY for *TERRITORY,
8235 + XPG_CODESET for *CODESET,
8236 + XPG_NORM_CODESET for *NORMALIZED_CODESET,
8237 + CEN_SPECIAL for *SPECIAL,
8238 + CEN_SPONSOR for *SPONSOR,
8239 + CEN_REVISION for *REVISION.
8241 +extern int _nl_explode_name (char *name, const char **language,
8242 + const char **modifier, const char **territory,
8243 + const char **codeset,
8244 + const char **normalized_codeset,
8245 + const char **special, const char **sponsor,
8246 + const char **revision);
8248 -extern int _nl_explode_name PARAMS ((char *name, const char **language,
8249 - const char **modifier,
8250 - const char **territory,
8251 - const char **codeset,
8252 - const char **normalized_codeset,
8253 - const char **special,
8254 - const char **sponsor,
8255 - const char **revision));
8256 +/* Split a locale name NAME into a leading language part and all the
8257 + rest. Return a pointer to the first character after the language,
8258 + i.e. to the first byte of the rest. */
8259 +extern char *_nl_find_language (const char *name);
8261 +#endif /* loadinfo.h */
8262 --- lrzsz-0.12.20.safe/intl/loadmsgcat.c 1998-04-26 09:22:37.000000000 -0400
8263 +++ lrzsz-0.12.20/intl/loadmsgcat.c 2004-09-12 14:40:34.473730152 -0400
8265 -/* Load needed message catalogs
8266 - Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
8267 +/* Load needed message catalogs.
8268 + Copyright (C) 1995-1999, 2000-2004 Free Software Foundation, Inc.
8270 - This program is free software; you can redistribute it and/or modify
8271 - it under the terms of the GNU General Public License as published by
8272 - the Free Software Foundation; either version 2, or (at your option)
8273 + This program is free software; you can redistribute it and/or modify it
8274 + under the terms of the GNU Library General Public License as published
8275 + by the Free Software Foundation; either version 2, or (at your option)
8278 This program is distributed in the hope that it will be useful,
8279 but WITHOUT ANY WARRANTY; without even the implied warranty of
8280 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
8281 - GNU General Public License for more details.
8282 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
8283 + Library General Public License for more details.
8285 - You should have received a copy of the GNU General Public License
8286 - along with this program; if not, write to the Free Software Foundation,
8287 - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
8288 + You should have received a copy of the GNU Library General Public
8289 + License along with this program; if not, write to the Free Software
8290 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
8293 +/* Tell glibc's <string.h> to provide a prototype for mempcpy().
8294 + This must come before <config.h> because <config.h> may include
8295 + <features.h>, and once <features.h> has been included, it's too late. */
8296 +#ifndef _GNU_SOURCE
8297 +# define _GNU_SOURCE 1
8300 #ifdef HAVE_CONFIG_H
8301 # include <config.h>
8307 #include <sys/types.h>
8308 #include <sys/stat.h>
8310 -#if defined STDC_HEADERS || defined _LIBC
8311 -# include <stdlib.h>
8314 +# define alloca __builtin_alloca
8315 +# define HAVE_ALLOCA 1
8318 +# include <malloc.h>
8319 +# define alloca _alloca
8321 +# if defined HAVE_ALLOCA_H || defined _LIBC
8322 +# include <alloca.h>
8335 +#include <stdlib.h>
8336 +#include <string.h>
8338 #if defined HAVE_UNISTD_H || defined _LIBC
8339 # include <unistd.h>
8342 -#if (defined HAVE_MMAP && defined HAVE_MUNMAP) || defined _LIBC
8344 +# include <langinfo.h>
8345 +# include <locale.h>
8348 +#if (defined HAVE_MMAP && defined HAVE_MUNMAP && !defined DISALLOW_MMAP) \
8349 + || (defined _LIBC && defined _POSIX_MAPPED_FILES)
8350 # include <sys/mman.h>
8352 +# define HAVE_MMAP 1
8357 -#include "gettext.h"
8358 +#if defined HAVE_STDINT_H_WITH_UINTMAX || defined _LIBC
8359 +# include <stdint.h>
8361 +#if defined HAVE_INTTYPES_H || defined _LIBC
8362 +# include <inttypes.h>
8366 #include "gettextP.h"
8367 +#include "hash-string.h"
8368 +#include "plural-exp.h"
8371 +# include "../locale/localeinfo.h"
8374 +/* Provide fallback values for macros that ought to be defined in <inttypes.h>.
8375 + Note that our fallback values need not be literal strings, because we don't
8376 + use them with preprocessor string concatenation. */
8377 +#if !defined PRId8 || PRI_MACROS_BROKEN
8381 +#if !defined PRIi8 || PRI_MACROS_BROKEN
8385 +#if !defined PRIo8 || PRI_MACROS_BROKEN
8389 +#if !defined PRIu8 || PRI_MACROS_BROKEN
8393 +#if !defined PRIx8 || PRI_MACROS_BROKEN
8397 +#if !defined PRIX8 || PRI_MACROS_BROKEN
8401 +#if !defined PRId16 || PRI_MACROS_BROKEN
8403 +# define PRId16 "d"
8405 +#if !defined PRIi16 || PRI_MACROS_BROKEN
8407 +# define PRIi16 "i"
8409 +#if !defined PRIo16 || PRI_MACROS_BROKEN
8411 +# define PRIo16 "o"
8413 +#if !defined PRIu16 || PRI_MACROS_BROKEN
8415 +# define PRIu16 "u"
8417 +#if !defined PRIx16 || PRI_MACROS_BROKEN
8419 +# define PRIx16 "x"
8421 +#if !defined PRIX16 || PRI_MACROS_BROKEN
8423 +# define PRIX16 "X"
8425 +#if !defined PRId32 || PRI_MACROS_BROKEN
8427 +# define PRId32 "d"
8429 +#if !defined PRIi32 || PRI_MACROS_BROKEN
8431 +# define PRIi32 "i"
8433 +#if !defined PRIo32 || PRI_MACROS_BROKEN
8435 +# define PRIo32 "o"
8437 +#if !defined PRIu32 || PRI_MACROS_BROKEN
8439 +# define PRIu32 "u"
8441 +#if !defined PRIx32 || PRI_MACROS_BROKEN
8443 +# define PRIx32 "x"
8445 +#if !defined PRIX32 || PRI_MACROS_BROKEN
8447 +# define PRIX32 "X"
8449 +#if !defined PRId64 || PRI_MACROS_BROKEN
8451 +# define PRId64 (sizeof (long) == 8 ? "ld" : "lld")
8453 +#if !defined PRIi64 || PRI_MACROS_BROKEN
8455 +# define PRIi64 (sizeof (long) == 8 ? "li" : "lli")
8457 +#if !defined PRIo64 || PRI_MACROS_BROKEN
8459 +# define PRIo64 (sizeof (long) == 8 ? "lo" : "llo")
8461 +#if !defined PRIu64 || PRI_MACROS_BROKEN
8463 +# define PRIu64 (sizeof (long) == 8 ? "lu" : "llu")
8465 +#if !defined PRIx64 || PRI_MACROS_BROKEN
8467 +# define PRIx64 (sizeof (long) == 8 ? "lx" : "llx")
8469 +#if !defined PRIX64 || PRI_MACROS_BROKEN
8471 +# define PRIX64 (sizeof (long) == 8 ? "lX" : "llX")
8473 +#if !defined PRIdLEAST8 || PRI_MACROS_BROKEN
8475 +# define PRIdLEAST8 "d"
8477 +#if !defined PRIiLEAST8 || PRI_MACROS_BROKEN
8479 +# define PRIiLEAST8 "i"
8481 +#if !defined PRIoLEAST8 || PRI_MACROS_BROKEN
8483 +# define PRIoLEAST8 "o"
8485 +#if !defined PRIuLEAST8 || PRI_MACROS_BROKEN
8487 +# define PRIuLEAST8 "u"
8489 +#if !defined PRIxLEAST8 || PRI_MACROS_BROKEN
8491 +# define PRIxLEAST8 "x"
8493 +#if !defined PRIXLEAST8 || PRI_MACROS_BROKEN
8495 +# define PRIXLEAST8 "X"
8497 +#if !defined PRIdLEAST16 || PRI_MACROS_BROKEN
8498 +# undef PRIdLEAST16
8499 +# define PRIdLEAST16 "d"
8501 +#if !defined PRIiLEAST16 || PRI_MACROS_BROKEN
8502 +# undef PRIiLEAST16
8503 +# define PRIiLEAST16 "i"
8505 +#if !defined PRIoLEAST16 || PRI_MACROS_BROKEN
8506 +# undef PRIoLEAST16
8507 +# define PRIoLEAST16 "o"
8509 +#if !defined PRIuLEAST16 || PRI_MACROS_BROKEN
8510 +# undef PRIuLEAST16
8511 +# define PRIuLEAST16 "u"
8513 +#if !defined PRIxLEAST16 || PRI_MACROS_BROKEN
8514 +# undef PRIxLEAST16
8515 +# define PRIxLEAST16 "x"
8517 +#if !defined PRIXLEAST16 || PRI_MACROS_BROKEN
8518 +# undef PRIXLEAST16
8519 +# define PRIXLEAST16 "X"
8521 +#if !defined PRIdLEAST32 || PRI_MACROS_BROKEN
8522 +# undef PRIdLEAST32
8523 +# define PRIdLEAST32 "d"
8525 +#if !defined PRIiLEAST32 || PRI_MACROS_BROKEN
8526 +# undef PRIiLEAST32
8527 +# define PRIiLEAST32 "i"
8529 +#if !defined PRIoLEAST32 || PRI_MACROS_BROKEN
8530 +# undef PRIoLEAST32
8531 +# define PRIoLEAST32 "o"
8533 +#if !defined PRIuLEAST32 || PRI_MACROS_BROKEN
8534 +# undef PRIuLEAST32
8535 +# define PRIuLEAST32 "u"
8537 +#if !defined PRIxLEAST32 || PRI_MACROS_BROKEN
8538 +# undef PRIxLEAST32
8539 +# define PRIxLEAST32 "x"
8541 +#if !defined PRIXLEAST32 || PRI_MACROS_BROKEN
8542 +# undef PRIXLEAST32
8543 +# define PRIXLEAST32 "X"
8545 +#if !defined PRIdLEAST64 || PRI_MACROS_BROKEN
8546 +# undef PRIdLEAST64
8547 +# define PRIdLEAST64 PRId64
8549 +#if !defined PRIiLEAST64 || PRI_MACROS_BROKEN
8550 +# undef PRIiLEAST64
8551 +# define PRIiLEAST64 PRIi64
8553 +#if !defined PRIoLEAST64 || PRI_MACROS_BROKEN
8554 +# undef PRIoLEAST64
8555 +# define PRIoLEAST64 PRIo64
8557 +#if !defined PRIuLEAST64 || PRI_MACROS_BROKEN
8558 +# undef PRIuLEAST64
8559 +# define PRIuLEAST64 PRIu64
8561 +#if !defined PRIxLEAST64 || PRI_MACROS_BROKEN
8562 +# undef PRIxLEAST64
8563 +# define PRIxLEAST64 PRIx64
8565 +#if !defined PRIXLEAST64 || PRI_MACROS_BROKEN
8566 +# undef PRIXLEAST64
8567 +# define PRIXLEAST64 PRIX64
8569 +#if !defined PRIdFAST8 || PRI_MACROS_BROKEN
8571 +# define PRIdFAST8 "d"
8573 +#if !defined PRIiFAST8 || PRI_MACROS_BROKEN
8575 +# define PRIiFAST8 "i"
8577 +#if !defined PRIoFAST8 || PRI_MACROS_BROKEN
8579 +# define PRIoFAST8 "o"
8581 +#if !defined PRIuFAST8 || PRI_MACROS_BROKEN
8583 +# define PRIuFAST8 "u"
8585 +#if !defined PRIxFAST8 || PRI_MACROS_BROKEN
8587 +# define PRIxFAST8 "x"
8589 +#if !defined PRIXFAST8 || PRI_MACROS_BROKEN
8591 +# define PRIXFAST8 "X"
8593 +#if !defined PRIdFAST16 || PRI_MACROS_BROKEN
8595 +# define PRIdFAST16 "d"
8597 +#if !defined PRIiFAST16 || PRI_MACROS_BROKEN
8599 +# define PRIiFAST16 "i"
8601 +#if !defined PRIoFAST16 || PRI_MACROS_BROKEN
8603 +# define PRIoFAST16 "o"
8605 +#if !defined PRIuFAST16 || PRI_MACROS_BROKEN
8607 +# define PRIuFAST16 "u"
8609 +#if !defined PRIxFAST16 || PRI_MACROS_BROKEN
8611 +# define PRIxFAST16 "x"
8613 +#if !defined PRIXFAST16 || PRI_MACROS_BROKEN
8615 +# define PRIXFAST16 "X"
8617 +#if !defined PRIdFAST32 || PRI_MACROS_BROKEN
8619 +# define PRIdFAST32 "d"
8621 +#if !defined PRIiFAST32 || PRI_MACROS_BROKEN
8623 +# define PRIiFAST32 "i"
8625 +#if !defined PRIoFAST32 || PRI_MACROS_BROKEN
8627 +# define PRIoFAST32 "o"
8629 +#if !defined PRIuFAST32 || PRI_MACROS_BROKEN
8631 +# define PRIuFAST32 "u"
8633 +#if !defined PRIxFAST32 || PRI_MACROS_BROKEN
8635 +# define PRIxFAST32 "x"
8637 +#if !defined PRIXFAST32 || PRI_MACROS_BROKEN
8639 +# define PRIXFAST32 "X"
8641 +#if !defined PRIdFAST64 || PRI_MACROS_BROKEN
8643 +# define PRIdFAST64 PRId64
8645 +#if !defined PRIiFAST64 || PRI_MACROS_BROKEN
8647 +# define PRIiFAST64 PRIi64
8649 +#if !defined PRIoFAST64 || PRI_MACROS_BROKEN
8651 +# define PRIoFAST64 PRIo64
8653 +#if !defined PRIuFAST64 || PRI_MACROS_BROKEN
8655 +# define PRIuFAST64 PRIu64
8657 +#if !defined PRIxFAST64 || PRI_MACROS_BROKEN
8659 +# define PRIxFAST64 PRIx64
8661 +#if !defined PRIXFAST64 || PRI_MACROS_BROKEN
8663 +# define PRIXFAST64 PRIX64
8665 +#if !defined PRIdMAX || PRI_MACROS_BROKEN
8667 +# define PRIdMAX (sizeof (uintmax_t) == sizeof (long) ? "ld" : "lld")
8669 +#if !defined PRIiMAX || PRI_MACROS_BROKEN
8671 +# define PRIiMAX (sizeof (uintmax_t) == sizeof (long) ? "li" : "lli")
8673 +#if !defined PRIoMAX || PRI_MACROS_BROKEN
8675 +# define PRIoMAX (sizeof (uintmax_t) == sizeof (long) ? "lo" : "llo")
8677 +#if !defined PRIuMAX || PRI_MACROS_BROKEN
8679 +# define PRIuMAX (sizeof (uintmax_t) == sizeof (long) ? "lu" : "llu")
8681 +#if !defined PRIxMAX || PRI_MACROS_BROKEN
8683 +# define PRIxMAX (sizeof (uintmax_t) == sizeof (long) ? "lx" : "llx")
8685 +#if !defined PRIXMAX || PRI_MACROS_BROKEN
8687 +# define PRIXMAX (sizeof (uintmax_t) == sizeof (long) ? "lX" : "llX")
8689 +#if !defined PRIdPTR || PRI_MACROS_BROKEN
8692 + (sizeof (void *) == sizeof (long) ? "ld" : \
8693 + sizeof (void *) == sizeof (int) ? "d" : \
8696 +#if !defined PRIiPTR || PRI_MACROS_BROKEN
8699 + (sizeof (void *) == sizeof (long) ? "li" : \
8700 + sizeof (void *) == sizeof (int) ? "i" : \
8703 +#if !defined PRIoPTR || PRI_MACROS_BROKEN
8706 + (sizeof (void *) == sizeof (long) ? "lo" : \
8707 + sizeof (void *) == sizeof (int) ? "o" : \
8710 +#if !defined PRIuPTR || PRI_MACROS_BROKEN
8713 + (sizeof (void *) == sizeof (long) ? "lu" : \
8714 + sizeof (void *) == sizeof (int) ? "u" : \
8717 +#if !defined PRIxPTR || PRI_MACROS_BROKEN
8720 + (sizeof (void *) == sizeof (long) ? "lx" : \
8721 + sizeof (void *) == sizeof (int) ? "x" : \
8724 +#if !defined PRIXPTR || PRI_MACROS_BROKEN
8727 + (sizeof (void *) == sizeof (long) ? "lX" : \
8728 + sizeof (void *) == sizeof (int) ? "X" : \
8732 /* @@ end of prolog @@ */
8735 /* Rename the non ISO C functions. This is required by the standard
8736 because some ISO C functions will require linking with this object
8737 file and the name space must not be polluted. */
8738 -# define fstat __fstat
8739 # define open __open
8740 # define close __close
8741 # define read __read
8742 @@ -52,30 +464,471 @@
8743 # define munmap __munmap
8746 +/* For those losing systems which don't have `alloca' we have to add
8747 + some additional code emulating it. */
8749 +# define freea(p) /* nothing */
8751 +# define alloca(n) malloc (n)
8752 +# define freea(p) free (p)
8755 +/* For systems that distinguish between text and binary I/O.
8756 + O_BINARY is usually declared in <fcntl.h>. */
8757 +#if !defined O_BINARY && defined _O_BINARY
8758 + /* For MSC-compatible compilers. */
8759 +# define O_BINARY _O_BINARY
8760 +# define O_TEXT _O_TEXT
8763 + /* BeOS 5 has O_BINARY and O_TEXT, but they have no effect. */
8767 +/* On reasonable systems, binary I/O is the default. */
8769 +# define O_BINARY 0
8773 /* We need a sign, whether a new catalog was loaded, which can be associated
8774 with all translations. This is important if the translations are
8775 cached by one of GCC's features. */
8776 -int _nl_msg_cat_cntr = 0;
8777 +int _nl_msg_cat_cntr;
8780 +/* Expand a system dependent string segment. Return NULL if unsupported. */
8781 +static const char *
8782 +get_sysdep_segment_value (const char *name)
8784 + /* Test for an ISO C 99 section 7.8.1 format string directive.
8786 + P R I { d | i | o | u | x | X }
8787 + { { | LEAST | FAST } { 8 | 16 | 32 | 64 } | MAX | PTR } */
8788 + /* We don't use a table of 14 times 6 'const char *' strings here, because
8789 + data relocations cost startup time. */
8790 + if (name[0] == 'P' && name[1] == 'R' && name[2] == 'I')
8792 + if (name[3] == 'd' || name[3] == 'i' || name[3] == 'o' || name[3] == 'u'
8793 + || name[3] == 'x' || name[3] == 'X')
8795 + if (name[4] == '8' && name[5] == '\0')
8797 + if (name[3] == 'd')
8799 + if (name[3] == 'i')
8801 + if (name[3] == 'o')
8803 + if (name[3] == 'u')
8805 + if (name[3] == 'x')
8807 + if (name[3] == 'X')
8811 + if (name[4] == '1' && name[5] == '6' && name[6] == '\0')
8813 + if (name[3] == 'd')
8815 + if (name[3] == 'i')
8817 + if (name[3] == 'o')
8819 + if (name[3] == 'u')
8821 + if (name[3] == 'x')
8823 + if (name[3] == 'X')
8827 + if (name[4] == '3' && name[5] == '2' && name[6] == '\0')
8829 + if (name[3] == 'd')
8831 + if (name[3] == 'i')
8833 + if (name[3] == 'o')
8835 + if (name[3] == 'u')
8837 + if (name[3] == 'x')
8839 + if (name[3] == 'X')
8843 + if (name[4] == '6' && name[5] == '4' && name[6] == '\0')
8845 + if (name[3] == 'd')
8847 + if (name[3] == 'i')
8849 + if (name[3] == 'o')
8851 + if (name[3] == 'u')
8853 + if (name[3] == 'x')
8855 + if (name[3] == 'X')
8859 + if (name[4] == 'L' && name[5] == 'E' && name[6] == 'A'
8860 + && name[7] == 'S' && name[8] == 'T')
8862 + if (name[9] == '8' && name[10] == '\0')
8864 + if (name[3] == 'd')
8865 + return PRIdLEAST8;
8866 + if (name[3] == 'i')
8867 + return PRIiLEAST8;
8868 + if (name[3] == 'o')
8869 + return PRIoLEAST8;
8870 + if (name[3] == 'u')
8871 + return PRIuLEAST8;
8872 + if (name[3] == 'x')
8873 + return PRIxLEAST8;
8874 + if (name[3] == 'X')
8875 + return PRIXLEAST8;
8878 + if (name[9] == '1' && name[10] == '6' && name[11] == '\0')
8880 + if (name[3] == 'd')
8881 + return PRIdLEAST16;
8882 + if (name[3] == 'i')
8883 + return PRIiLEAST16;
8884 + if (name[3] == 'o')
8885 + return PRIoLEAST16;
8886 + if (name[3] == 'u')
8887 + return PRIuLEAST16;
8888 + if (name[3] == 'x')
8889 + return PRIxLEAST16;
8890 + if (name[3] == 'X')
8891 + return PRIXLEAST16;
8894 + if (name[9] == '3' && name[10] == '2' && name[11] == '\0')
8896 + if (name[3] == 'd')
8897 + return PRIdLEAST32;
8898 + if (name[3] == 'i')
8899 + return PRIiLEAST32;
8900 + if (name[3] == 'o')
8901 + return PRIoLEAST32;
8902 + if (name[3] == 'u')
8903 + return PRIuLEAST32;
8904 + if (name[3] == 'x')
8905 + return PRIxLEAST32;
8906 + if (name[3] == 'X')
8907 + return PRIXLEAST32;
8910 + if (name[9] == '6' && name[10] == '4' && name[11] == '\0')
8912 + if (name[3] == 'd')
8913 + return PRIdLEAST64;
8914 + if (name[3] == 'i')
8915 + return PRIiLEAST64;
8916 + if (name[3] == 'o')
8917 + return PRIoLEAST64;
8918 + if (name[3] == 'u')
8919 + return PRIuLEAST64;
8920 + if (name[3] == 'x')
8921 + return PRIxLEAST64;
8922 + if (name[3] == 'X')
8923 + return PRIXLEAST64;
8927 + if (name[4] == 'F' && name[5] == 'A' && name[6] == 'S'
8928 + && name[7] == 'T')
8930 + if (name[8] == '8' && name[9] == '\0')
8932 + if (name[3] == 'd')
8934 + if (name[3] == 'i')
8936 + if (name[3] == 'o')
8938 + if (name[3] == 'u')
8940 + if (name[3] == 'x')
8942 + if (name[3] == 'X')
8946 + if (name[8] == '1' && name[9] == '6' && name[10] == '\0')
8948 + if (name[3] == 'd')
8949 + return PRIdFAST16;
8950 + if (name[3] == 'i')
8951 + return PRIiFAST16;
8952 + if (name[3] == 'o')
8953 + return PRIoFAST16;
8954 + if (name[3] == 'u')
8955 + return PRIuFAST16;
8956 + if (name[3] == 'x')
8957 + return PRIxFAST16;
8958 + if (name[3] == 'X')
8959 + return PRIXFAST16;
8962 + if (name[8] == '3' && name[9] == '2' && name[10] == '\0')
8964 + if (name[3] == 'd')
8965 + return PRIdFAST32;
8966 + if (name[3] == 'i')
8967 + return PRIiFAST32;
8968 + if (name[3] == 'o')
8969 + return PRIoFAST32;
8970 + if (name[3] == 'u')
8971 + return PRIuFAST32;
8972 + if (name[3] == 'x')
8973 + return PRIxFAST32;
8974 + if (name[3] == 'X')
8975 + return PRIXFAST32;
8978 + if (name[8] == '6' && name[9] == '4' && name[10] == '\0')
8980 + if (name[3] == 'd')
8981 + return PRIdFAST64;
8982 + if (name[3] == 'i')
8983 + return PRIiFAST64;
8984 + if (name[3] == 'o')
8985 + return PRIoFAST64;
8986 + if (name[3] == 'u')
8987 + return PRIuFAST64;
8988 + if (name[3] == 'x')
8989 + return PRIxFAST64;
8990 + if (name[3] == 'X')
8991 + return PRIXFAST64;
8995 + if (name[4] == 'M' && name[5] == 'A' && name[6] == 'X'
8996 + && name[7] == '\0')
8998 + if (name[3] == 'd')
9000 + if (name[3] == 'i')
9002 + if (name[3] == 'o')
9004 + if (name[3] == 'u')
9006 + if (name[3] == 'x')
9008 + if (name[3] == 'X')
9012 + if (name[4] == 'P' && name[5] == 'T' && name[6] == 'R'
9013 + && name[7] == '\0')
9015 + if (name[3] == 'd')
9017 + if (name[3] == 'i')
9019 + if (name[3] == 'o')
9021 + if (name[3] == 'u')
9023 + if (name[3] == 'x')
9025 + if (name[3] == 'X')
9031 + /* Test for a glibc specific printf() format directive flag. */
9032 + if (name[0] == 'I' && name[1] == '\0')
9034 +#if defined _LIBC || __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2)
9035 + /* The 'I' flag, in numeric format directives, replaces ASCII digits
9036 + with the 'outdigits' defined in the LC_CTYPE locale facet. This is
9037 + used for Farsi (Persian) and maybe Arabic. */
9043 + /* Other system dependent strings are not valid. */
9047 +/* Initialize the codeset dependent parts of an opened message catalog.
9048 + Return the header entry. */
9051 +_nl_init_domain_conv (struct loaded_l10nfile *domain_file,
9052 + struct loaded_domain *domain,
9053 + struct binding *domainbinding)
9055 + /* Find out about the character set the file is encoded with.
9056 + This can be found (in textual form) in the entry "". If this
9057 + entry does not exist or if this does not contain the `charset='
9058 + information, we will assume the charset matches the one the
9059 + current locale and we don't have to perform any conversion. */
9061 + size_t nullentrylen;
9063 + /* Preinitialize fields, to avoid recursion during _nl_find_msg. */
9064 + domain->codeset_cntr =
9065 + (domainbinding != NULL ? domainbinding->codeset_cntr : 0);
9067 + domain->conv = (__gconv_t) -1;
9070 + domain->conv = (iconv_t) -1;
9073 + domain->conv_tab = NULL;
9075 + /* Get the header entry. */
9076 + nullentry = _nl_find_msg (domain_file, domainbinding, "", &nullentrylen);
9078 + if (nullentry != NULL)
9080 +#if defined _LIBC || HAVE_ICONV
9081 + const char *charsetstr;
9083 + charsetstr = strstr (nullentry, "charset=");
9084 + if (charsetstr != NULL)
9088 + const char *outcharset;
9090 + charsetstr += strlen ("charset=");
9091 + len = strcspn (charsetstr, " \t\n");
9093 + charset = (char *) alloca (len + 1);
9094 +# if defined _LIBC || HAVE_MEMPCPY
9095 + *((char *) mempcpy (charset, charsetstr, len)) = '\0';
9097 + memcpy (charset, charsetstr, len);
9098 + charset[len] = '\0';
9101 + /* The output charset should normally be determined by the
9102 + locale. But sometimes the locale is not used or not correctly
9103 + set up, so we provide a possibility for the user to override
9104 + this. Moreover, the value specified through
9105 + bind_textdomain_codeset overrides both. */
9106 + if (domainbinding != NULL && domainbinding->codeset != NULL)
9107 + outcharset = domainbinding->codeset;
9110 + outcharset = getenv ("OUTPUT_CHARSET");
9111 + if (outcharset == NULL || outcharset[0] == '\0')
9114 + outcharset = _NL_CURRENT (LC_CTYPE, CODESET);
9117 + extern const char *locale_charset (void);
9118 + outcharset = locale_charset ();
9125 + /* We always want to use transliteration. */
9126 + outcharset = norm_add_slashes (outcharset, "TRANSLIT");
9127 + charset = norm_add_slashes (charset, NULL);
9128 + if (__gconv_open (outcharset, charset, &domain->conv,
9129 + GCONV_AVOID_NOCONV)
9131 + domain->conv = (__gconv_t) -1;
9134 + /* When using GNU libc >= 2.2 or GNU libiconv >= 1.5,
9135 + we want to use transliteration. */
9136 +# if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || __GLIBC__ > 2 \
9137 + || _LIBICONV_VERSION >= 0x0105
9138 + if (strchr (outcharset, '/') == NULL)
9142 + len = strlen (outcharset);
9143 + tmp = (char *) alloca (len + 10 + 1);
9144 + memcpy (tmp, outcharset, len);
9145 + memcpy (tmp + len, "//TRANSLIT", 10 + 1);
9148 + domain->conv = iconv_open (outcharset, charset);
9150 + freea (outcharset);
9154 + domain->conv = iconv_open (outcharset, charset);
9160 +#endif /* _LIBC || HAVE_ICONV */
9166 +/* Frees the codeset dependent parts of an opened message catalog. */
9169 +_nl_free_domain_conv (struct loaded_domain *domain)
9171 + if (domain->conv_tab != NULL && domain->conv_tab != (char **) -1)
9172 + free (domain->conv_tab);
9175 + if (domain->conv != (__gconv_t) -1)
9176 + __gconv_close (domain->conv);
9179 + if (domain->conv != (iconv_t) -1)
9180 + iconv_close (domain->conv);
9185 /* Load the message catalogs specified by FILENAME. If it is no valid
9186 message catalog do nothing. */
9188 -_nl_load_domain (domain_file)
9189 - struct loaded_l10nfile *domain_file;
9191 +_nl_load_domain (struct loaded_l10nfile *domain_file,
9192 + struct binding *domainbinding)
9201 struct mo_file_header *data = (struct mo_file_header *) -1;
9202 -#if (defined HAVE_MMAP && defined HAVE_MUNMAP && !defined DISALLOW_MMAP) \
9206 struct loaded_domain *domain;
9208 + const char *nullentry;
9210 domain_file->decided = 1;
9211 domain_file->data = NULL;
9213 + /* Note that it would be useless to store domainbinding in domain_file
9214 + because domainbinding might be == NULL now but != NULL later (after
9215 + a call to bind_textdomain_codeset). */
9217 /* If the record does not represent a valid locale the FILENAME
9218 might be NULL. This can happen when according to the given
9219 specification the locale file name is different for XPG and CEN
9220 @@ -84,27 +937,32 @@
9223 /* Try to open the addressed file. */
9224 - fd = open (domain_file->filename, O_RDONLY);
9225 + fd = open (domain_file->filename, O_RDONLY | O_BINARY);
9229 /* We must know about the size of the file. */
9230 - if (fstat (fd, &st) != 0
9231 - && st.st_size < (off_t) sizeof (struct mo_file_header))
9234 + __builtin_expect (fstat64 (fd, &st) != 0, 0)
9236 + __builtin_expect (fstat (fd, &st) != 0, 0)
9238 + || __builtin_expect ((size = (size_t) st.st_size) != st.st_size, 0)
9239 + || __builtin_expect (size < sizeof (struct mo_file_header), 0))
9241 /* Something went wrong. */
9246 -#if (defined HAVE_MMAP && defined HAVE_MUNMAP && !defined DISALLOW_MMAP) \
9249 /* Now we are ready to load the file. If mmap() is available we try
9250 this first. If not available or it failed we try to load it. */
9251 - data = (struct mo_file_header *) mmap (NULL, st.st_size, PROT_READ,
9252 + data = (struct mo_file_header *) mmap (NULL, size, PROT_READ,
9253 MAP_PRIVATE, fd, 0);
9255 - if (data != (struct mo_file_header *) -1)
9256 + if (__builtin_expect (data != (struct mo_file_header *) -1, 1))
9258 /* mmap() call was successful. */
9260 @@ -116,24 +974,27 @@
9262 if (data == (struct mo_file_header *) -1)
9268 - data = (struct mo_file_header *) malloc (st.st_size);
9269 + data = (struct mo_file_header *) malloc (size);
9273 - to_read = st.st_size;
9275 read_ptr = (char *) data;
9278 long int nb = (long int) read (fd, read_ptr, to_read);
9283 + if (nb == -1 && errno == EINTR)
9293 @@ -144,47 +1005,378 @@
9295 /* Using the magic number we can test whether it really is a message
9297 - if (data->magic != _MAGIC && data->magic != _MAGIC_SWAPPED)
9298 + if (__builtin_expect (data->magic != _MAGIC && data->magic != _MAGIC_SWAPPED,
9301 /* The magic number is wrong: not a message catalog file. */
9302 -#if (defined HAVE_MMAP && defined HAVE_MUNMAP && !defined DISALLOW_MMAP) \
9306 - munmap ((caddr_t) data, st.st_size);
9307 + munmap ((caddr_t) data, size);
9315 - = (struct loaded_domain *) malloc (sizeof (struct loaded_domain));
9316 - if (domain_file->data == NULL)
9317 + domain = (struct loaded_domain *) malloc (sizeof (struct loaded_domain));
9318 + if (domain == NULL)
9320 + domain_file->data = domain;
9322 - domain = (struct loaded_domain *) domain_file->data;
9323 domain->data = (char *) data;
9324 + domain->use_mmap = use_mmap;
9325 + domain->mmap_size = size;
9326 domain->must_swap = data->magic != _MAGIC;
9327 + domain->malloced = NULL;
9329 /* Fill in the information about the available tables. */
9330 - switch (W (domain->must_swap, data->revision))
9331 + revision = W (domain->must_swap, data->revision);
9332 + /* We support only the major revisions 0 and 1. */
9333 + switch (revision >> 16)
9337 domain->nstrings = W (domain->must_swap, data->nstrings);
9338 - domain->orig_tab = (struct string_desc *)
9339 + domain->orig_tab = (const struct string_desc *)
9340 ((char *) data + W (domain->must_swap, data->orig_tab_offset));
9341 - domain->trans_tab = (struct string_desc *)
9342 + domain->trans_tab = (const struct string_desc *)
9343 ((char *) data + W (domain->must_swap, data->trans_tab_offset));
9344 domain->hash_size = W (domain->must_swap, data->hash_tab_size);
9345 - domain->hash_tab = (nls_uint32 *)
9346 - ((char *) data + W (domain->must_swap, data->hash_tab_offset));
9347 + domain->hash_tab =
9348 + (domain->hash_size > 2
9349 + ? (const nls_uint32 *)
9350 + ((char *) data + W (domain->must_swap, data->hash_tab_offset))
9352 + domain->must_swap_hash_tab = domain->must_swap;
9354 + /* Now dispatch on the minor revision. */
9355 + switch (revision & 0xffff)
9358 + domain->n_sysdep_strings = 0;
9359 + domain->orig_sysdep_tab = NULL;
9360 + domain->trans_sysdep_tab = NULL;
9365 + nls_uint32 n_sysdep_strings;
9367 + if (domain->hash_tab == NULL)
9368 + /* This is invalid. These minor revisions need a hash table. */
9371 + n_sysdep_strings =
9372 + W (domain->must_swap, data->n_sysdep_strings);
9373 + if (n_sysdep_strings > 0)
9375 + nls_uint32 n_sysdep_segments;
9376 + const struct sysdep_segment *sysdep_segments;
9377 + const char **sysdep_segment_values;
9378 + const nls_uint32 *orig_sysdep_tab;
9379 + const nls_uint32 *trans_sysdep_tab;
9380 + nls_uint32 n_inmem_sysdep_strings;
9383 + struct sysdep_string_desc *inmem_orig_sysdep_tab;
9384 + struct sysdep_string_desc *inmem_trans_sysdep_tab;
9385 + nls_uint32 *inmem_hash_tab;
9386 + unsigned int i, j;
9388 + /* Get the values of the system dependent segments. */
9389 + n_sysdep_segments =
9390 + W (domain->must_swap, data->n_sysdep_segments);
9391 + sysdep_segments = (const struct sysdep_segment *)
9393 + + W (domain->must_swap, data->sysdep_segments_offset));
9394 + sysdep_segment_values =
9395 + alloca (n_sysdep_segments * sizeof (const char *));
9396 + for (i = 0; i < n_sysdep_segments; i++)
9398 + const char *name =
9400 + + W (domain->must_swap, sysdep_segments[i].offset);
9401 + nls_uint32 namelen =
9402 + W (domain->must_swap, sysdep_segments[i].length);
9404 + if (!(namelen > 0 && name[namelen - 1] == '\0'))
9406 + freea (sysdep_segment_values);
9410 + sysdep_segment_values[i] = get_sysdep_segment_value (name);
9413 + orig_sysdep_tab = (const nls_uint32 *)
9415 + + W (domain->must_swap, data->orig_sysdep_tab_offset));
9416 + trans_sysdep_tab = (const nls_uint32 *)
9418 + + W (domain->must_swap, data->trans_sysdep_tab_offset));
9420 + /* Compute the amount of additional memory needed for the
9421 + system dependent strings and the augmented hash table.
9422 + At the same time, also drop string pairs which refer to
9423 + an undefined system dependent segment. */
9424 + n_inmem_sysdep_strings = 0;
9425 + memneed = domain->hash_size * sizeof (nls_uint32);
9426 + for (i = 0; i < n_sysdep_strings; i++)
9431 + for (j = 0; j < 2; j++)
9433 + const struct sysdep_string *sysdep_string =
9434 + (const struct sysdep_string *)
9436 + + W (domain->must_swap,
9438 + ? orig_sysdep_tab[i]
9439 + : trans_sysdep_tab[i]));
9441 + const struct segment_pair *p = sysdep_string->segments;
9443 + if (W (domain->must_swap, p->sysdepref) != SEGMENTS_END)
9444 + for (p = sysdep_string->segments;; p++)
9446 + nls_uint32 sysdepref;
9448 + need += W (domain->must_swap, p->segsize);
9450 + sysdepref = W (domain->must_swap, p->sysdepref);
9451 + if (sysdepref == SEGMENTS_END)
9454 + if (sysdepref >= n_sysdep_segments)
9457 + freea (sysdep_segment_values);
9461 + if (sysdep_segment_values[sysdepref] == NULL)
9463 + /* This particular string pair is invalid. */
9468 + need += strlen (sysdep_segment_values[sysdepref]);
9478 + n_inmem_sysdep_strings++;
9479 + memneed += needs[0] + needs[1];
9482 + memneed += 2 * n_inmem_sysdep_strings
9483 + * sizeof (struct sysdep_string_desc);
9485 + if (n_inmem_sysdep_strings > 0)
9489 + /* Allocate additional memory. */
9490 + mem = (char *) malloc (memneed);
9494 + domain->malloced = mem;
9495 + inmem_orig_sysdep_tab = (struct sysdep_string_desc *) mem;
9496 + mem += n_inmem_sysdep_strings
9497 + * sizeof (struct sysdep_string_desc);
9498 + inmem_trans_sysdep_tab = (struct sysdep_string_desc *) mem;
9499 + mem += n_inmem_sysdep_strings
9500 + * sizeof (struct sysdep_string_desc);
9501 + inmem_hash_tab = (nls_uint32 *) mem;
9502 + mem += domain->hash_size * sizeof (nls_uint32);
9504 + /* Compute the system dependent strings. */
9506 + for (i = 0; i < n_sysdep_strings; i++)
9510 + for (j = 0; j < 2; j++)
9512 + const struct sysdep_string *sysdep_string =
9513 + (const struct sysdep_string *)
9515 + + W (domain->must_swap,
9517 + ? orig_sysdep_tab[i]
9518 + : trans_sysdep_tab[i]));
9519 + const struct segment_pair *p =
9520 + sysdep_string->segments;
9522 + if (W (domain->must_swap, p->sysdepref)
9524 + for (p = sysdep_string->segments;; p++)
9526 + nls_uint32 sysdepref;
9529 + W (domain->must_swap, p->sysdepref);
9530 + if (sysdepref == SEGMENTS_END)
9533 + if (sysdep_segment_values[sysdepref] == NULL)
9535 + /* This particular string pair is
9548 + for (j = 0; j < 2; j++)
9550 + const struct sysdep_string *sysdep_string =
9551 + (const struct sysdep_string *)
9553 + + W (domain->must_swap,
9555 + ? orig_sysdep_tab[i]
9556 + : trans_sysdep_tab[i]));
9557 + const char *static_segments =
9559 + + W (domain->must_swap, sysdep_string->offset);
9560 + const struct segment_pair *p =
9561 + sysdep_string->segments;
9563 + /* Concatenate the segments, and fill
9564 + inmem_orig_sysdep_tab[k] (for j == 0) and
9565 + inmem_trans_sysdep_tab[k] (for j == 1). */
9567 + struct sysdep_string_desc *inmem_tab_entry =
9569 + ? inmem_orig_sysdep_tab
9570 + : inmem_trans_sysdep_tab)
9573 + if (W (domain->must_swap, p->sysdepref)
9576 + /* Only one static segment. */
9577 + inmem_tab_entry->length =
9578 + W (domain->must_swap, p->segsize);
9579 + inmem_tab_entry->pointer = static_segments;
9583 + inmem_tab_entry->pointer = mem;
9585 + for (p = sysdep_string->segments;; p++)
9587 + nls_uint32 segsize =
9588 + W (domain->must_swap, p->segsize);
9589 + nls_uint32 sysdepref =
9590 + W (domain->must_swap, p->sysdepref);
9595 + memcpy (mem, static_segments, segsize);
9597 + static_segments += segsize;
9600 + if (sysdepref == SEGMENTS_END)
9603 + n = strlen (sysdep_segment_values[sysdepref]);
9604 + memcpy (mem, sysdep_segment_values[sysdepref], n);
9608 + inmem_tab_entry->length =
9609 + mem - inmem_tab_entry->pointer;
9616 + if (k != n_inmem_sysdep_strings)
9619 + /* Compute the augmented hash table. */
9620 + for (i = 0; i < domain->hash_size; i++)
9621 + inmem_hash_tab[i] =
9622 + W (domain->must_swap_hash_tab, domain->hash_tab[i]);
9623 + for (i = 0; i < n_inmem_sysdep_strings; i++)
9625 + const char *msgid = inmem_orig_sysdep_tab[i].pointer;
9626 + nls_uint32 hash_val = hash_string (msgid);
9627 + nls_uint32 idx = hash_val % domain->hash_size;
9629 + 1 + (hash_val % (domain->hash_size - 2));
9633 + if (inmem_hash_tab[idx] == 0)
9635 + /* Hash table entry is empty. Use it. */
9636 + inmem_hash_tab[idx] = 1 + domain->nstrings + i;
9640 + if (idx >= domain->hash_size - incr)
9641 + idx -= domain->hash_size - incr;
9647 + domain->n_sysdep_strings = n_inmem_sysdep_strings;
9648 + domain->orig_sysdep_tab = inmem_orig_sysdep_tab;
9649 + domain->trans_sysdep_tab = inmem_trans_sysdep_tab;
9651 + domain->hash_tab = inmem_hash_tab;
9652 + domain->must_swap_hash_tab = 0;
9656 + domain->n_sysdep_strings = 0;
9657 + domain->orig_sysdep_tab = NULL;
9658 + domain->trans_sysdep_tab = NULL;
9661 + freea (sysdep_segment_values);
9665 + domain->n_sysdep_strings = 0;
9666 + domain->orig_sysdep_tab = NULL;
9667 + domain->trans_sysdep_tab = NULL;
9674 - /* This is an illegal revision. */
9675 -#if (defined HAVE_MMAP && defined HAVE_MUNMAP && !defined DISALLOW_MMAP) \
9677 + /* This is an invalid revision. */
9679 + /* This is an invalid .mo file. */
9680 + if (domain->malloced)
9681 + free (domain->malloced);
9684 - munmap ((caddr_t) data, st.st_size);
9685 + munmap ((caddr_t) data, size);
9689 @@ -193,7 +1385,36 @@
9693 - /* Show that one domain is changed. This might make some cached
9694 - translations invalid. */
9695 - ++_nl_msg_cat_cntr;
9696 + /* Now initialize the character set converter from the character set
9697 + the file is encoded with (found in the header entry) to the domain's
9698 + specified character set or the locale's character set. */
9699 + nullentry = _nl_init_domain_conv (domain_file, domain, domainbinding);
9701 + /* Also look for a plural specification. */
9702 + EXTRACT_PLURAL_EXPRESSION (nullentry, &domain->plural, &domain->nplurals);
9709 +_nl_unload_domain (struct loaded_domain *domain)
9711 + if (domain->plural != &__gettext_germanic_plural)
9712 + __gettext_free_exp (domain->plural);
9714 + _nl_free_domain_conv (domain);
9716 + if (domain->malloced)
9717 + free (domain->malloced);
9719 +# ifdef _POSIX_MAPPED_FILES
9720 + if (domain->use_mmap)
9721 + munmap ((caddr_t) domain->data, domain->mmap_size);
9723 +# endif /* _POSIX_MAPPED_FILES */
9724 + free ((void *) domain->data);
9729 --- lrzsz-0.12.20.safe/intl/localcharset.c 1969-12-31 19:00:00.000000000 -0500
9730 +++ lrzsz-0.12.20/intl/localcharset.c 2004-09-12 14:40:34.478729392 -0400
9732 +/* Determine a canonical name for the current locale's character encoding.
9734 + Copyright (C) 2000-2003 Free Software Foundation, Inc.
9736 + This program is free software; you can redistribute it and/or modify it
9737 + under the terms of the GNU Library General Public License as published
9738 + by the Free Software Foundation; either version 2, or (at your option)
9739 + any later version.
9741 + This program is distributed in the hope that it will be useful,
9742 + but WITHOUT ANY WARRANTY; without even the implied warranty of
9743 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
9744 + Library General Public License for more details.
9746 + You should have received a copy of the GNU Library General Public
9747 + License along with this program; if not, write to the Free Software
9748 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
9751 +/* Written by Bruno Haible <bruno@clisp.org>. */
9753 +#ifdef HAVE_CONFIG_H
9754 +# include <config.h>
9757 +/* Specification. */
9758 +#include "localcharset.h"
9761 +# include <stddef.h>
9766 +# include <string.h>
9768 +# include <strings.h>
9771 +# include <stdlib.h>
9774 +#if defined _WIN32 || defined __WIN32__
9775 +# undef WIN32 /* avoid warning on mingw32 */
9779 +#if defined __EMX__
9780 +/* Assume EMX program runs on OS/2, even if compiled under DOS. */
9785 +# if HAVE_LANGINFO_CODESET
9786 +# include <langinfo.h>
9788 +# if HAVE_SETLOCALE
9789 +# include <locale.h>
9792 +#elif defined WIN32
9793 +# define WIN32_LEAN_AND_MEAN
9794 +# include <windows.h>
9801 +#if ENABLE_RELOCATABLE
9802 +# include "relocatable.h"
9804 +# define relocate(pathname) (pathname)
9807 +#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
9808 + /* Win32, OS/2, DOS */
9809 +# define ISSLASH(C) ((C) == '/' || (C) == '\\')
9812 +#ifndef DIRECTORY_SEPARATOR
9813 +# define DIRECTORY_SEPARATOR '/'
9817 +# define ISSLASH(C) ((C) == DIRECTORY_SEPARATOR)
9820 +#if HAVE_DECL_GETC_UNLOCKED
9822 +# define getc getc_unlocked
9825 +/* The following static variable is declared 'volatile' to avoid a
9826 + possible multithread problem in the function get_charset_aliases. If we
9827 + are running in a threaded environment, and if two threads initialize
9828 + 'charset_aliases' simultaneously, both will produce the same value,
9829 + and everything will be ok if the two assignments to 'charset_aliases'
9830 + are atomic. But I don't know what will happen if the two assignments mix. */
9832 +# define volatile /* empty */
9834 +/* Pointer to the contents of the charset.alias file, if it has already been
9835 + read, else NULL. Its format is:
9836 + ALIAS_1 '\0' CANONICAL_1 '\0' ... ALIAS_n '\0' CANONICAL_n '\0' '\0' */
9837 +static const char * volatile charset_aliases;
9839 +/* Return a pointer to the contents of the charset.alias file. */
9840 +static const char *
9841 +get_charset_aliases ()
9845 + cp = charset_aliases;
9848 +#if !(defined VMS || defined WIN32)
9850 + const char *dir = relocate (LIBDIR);
9851 + const char *base = "charset.alias";
9854 + /* Concatenate dir and base into freshly allocated file_name. */
9856 + size_t dir_len = strlen (dir);
9857 + size_t base_len = strlen (base);
9858 + int add_slash = (dir_len > 0 && !ISSLASH (dir[dir_len - 1]));
9859 + file_name = (char *) malloc (dir_len + add_slash + base_len + 1);
9860 + if (file_name != NULL)
9862 + memcpy (file_name, dir, dir_len);
9864 + file_name[dir_len] = DIRECTORY_SEPARATOR;
9865 + memcpy (file_name + dir_len + add_slash, base, base_len + 1);
9869 + if (file_name == NULL || (fp = fopen (file_name, "r")) == NULL)
9870 + /* Out of memory or file not found, treat it as empty. */
9874 + /* Parse the file's contents. */
9878 + char *res_ptr = NULL;
9879 + size_t res_size = 0;
9887 + if (c == '\n' || c == ' ' || c == '\t')
9891 + /* Skip comment, to end of line. */
9894 + while (!(c == EOF || c == '\n'));
9900 + if (fscanf (fp, "%50s %50s", buf1, buf2) < 2)
9902 + l1 = strlen (buf1);
9903 + l2 = strlen (buf2);
9904 + if (res_size == 0)
9906 + res_size = l1 + 1 + l2 + 1;
9907 + res_ptr = (char *) malloc (res_size + 1);
9911 + res_size += l1 + 1 + l2 + 1;
9912 + res_ptr = (char *) realloc (res_ptr, res_size + 1);
9914 + if (res_ptr == NULL)
9916 + /* Out of memory. */
9920 + strcpy (res_ptr + res_size - (l2 + 1) - (l1 + 1), buf1);
9921 + strcpy (res_ptr + res_size - (l2 + 1), buf2);
9924 + if (res_size == 0)
9928 + *(res_ptr + res_size) = '\0';
9933 + if (file_name != NULL)
9939 + /* To avoid the troubles of an extra file charset.alias_vms in the
9940 + sources of many GNU packages, simply inline the aliases here. */
9941 + /* The list of encodings is taken from the OpenVMS 7.3-1 documentation
9942 + "Compaq C Run-Time Library Reference Manual for OpenVMS systems"
9943 + section 10.7 "Handling Different Character Sets". */
9944 + cp = "ISO8859-1" "\0" "ISO-8859-1" "\0"
9945 + "ISO8859-2" "\0" "ISO-8859-2" "\0"
9946 + "ISO8859-5" "\0" "ISO-8859-5" "\0"
9947 + "ISO8859-7" "\0" "ISO-8859-7" "\0"
9948 + "ISO8859-8" "\0" "ISO-8859-8" "\0"
9949 + "ISO8859-9" "\0" "ISO-8859-9" "\0"
9951 + "eucJP" "\0" "EUC-JP" "\0"
9952 + "SJIS" "\0" "SHIFT_JIS" "\0"
9953 + "DECKANJI" "\0" "DEC-KANJI" "\0"
9954 + "SDECKANJI" "\0" "EUC-JP" "\0"
9956 + "eucTW" "\0" "EUC-TW" "\0"
9957 + "DECHANYU" "\0" "DEC-HANYU" "\0"
9958 + "DECHANZI" "\0" "GB2312" "\0"
9960 + "DECKOREAN" "\0" "EUC-KR" "\0";
9964 + /* To avoid the troubles of installing a separate file in the same
9965 + directory as the DLL and of retrieving the DLL's directory at
9966 + runtime, simply inline the aliases here. */
9968 + cp = "CP936" "\0" "GBK" "\0"
9969 + "CP1361" "\0" "JOHAB" "\0"
9970 + "CP20127" "\0" "ASCII" "\0"
9971 + "CP20866" "\0" "KOI8-R" "\0"
9972 + "CP21866" "\0" "KOI8-RU" "\0"
9973 + "CP28591" "\0" "ISO-8859-1" "\0"
9974 + "CP28592" "\0" "ISO-8859-2" "\0"
9975 + "CP28593" "\0" "ISO-8859-3" "\0"
9976 + "CP28594" "\0" "ISO-8859-4" "\0"
9977 + "CP28595" "\0" "ISO-8859-5" "\0"
9978 + "CP28596" "\0" "ISO-8859-6" "\0"
9979 + "CP28597" "\0" "ISO-8859-7" "\0"
9980 + "CP28598" "\0" "ISO-8859-8" "\0"
9981 + "CP28599" "\0" "ISO-8859-9" "\0"
9982 + "CP28605" "\0" "ISO-8859-15" "\0";
9986 + charset_aliases = cp;
9992 +/* Determine the current locale's character encoding, and canonicalize it
9993 + into one of the canonical names listed in config.charset.
9994 + The result must not be freed; it is statically allocated.
9995 + If the canonical name cannot be determined, the result is a non-canonical
10004 + const char *codeset;
10005 + const char *aliases;
10007 +#if !(defined WIN32 || defined OS2)
10009 +# if HAVE_LANGINFO_CODESET
10011 + /* Most systems support nl_langinfo (CODESET) nowadays. */
10012 + codeset = nl_langinfo (CODESET);
10016 + /* On old systems which lack it, use setlocale or getenv. */
10017 + const char *locale = NULL;
10019 + /* But most old systems don't have a complete set of locales. Some
10020 + (like SunOS 4 or DJGPP) have only the C locale. Therefore we don't
10021 + use setlocale here; it would return "C" when it doesn't support the
10022 + locale name the user has set. */
10023 +# if HAVE_SETLOCALE && 0
10024 + locale = setlocale (LC_CTYPE, NULL);
10026 + if (locale == NULL || locale[0] == '\0')
10028 + locale = getenv ("LC_ALL");
10029 + if (locale == NULL || locale[0] == '\0')
10031 + locale = getenv ("LC_CTYPE");
10032 + if (locale == NULL || locale[0] == '\0')
10033 + locale = getenv ("LANG");
10037 + /* On some old systems, one used to set locale = "iso8859_1". On others,
10038 + you set it to "language_COUNTRY.charset". In any case, we resolve it
10039 + through the charset.alias file. */
10040 + codeset = locale;
10044 +#elif defined WIN32
10046 + static char buf[2 + 10 + 1];
10048 + /* Woe32 has a function returning the locale's codepage as a number. */
10049 + sprintf (buf, "CP%u", GetACP ());
10054 + const char *locale;
10055 + static char buf[2 + 10 + 1];
10059 + /* Allow user to override the codeset, as set in the operating system,
10060 + with standard language environment variables. */
10061 + locale = getenv ("LC_ALL");
10062 + if (locale == NULL || locale[0] == '\0')
10064 + locale = getenv ("LC_CTYPE");
10065 + if (locale == NULL || locale[0] == '\0')
10066 + locale = getenv ("LANG");
10068 + if (locale != NULL && locale[0] != '\0')
10070 + /* If the locale name contains an encoding after the dot, return it. */
10071 + const char *dot = strchr (locale, '.');
10075 + const char *modifier;
10078 + /* Look for the possible @... trailer and remove it, if any. */
10079 + modifier = strchr (dot, '@');
10080 + if (modifier == NULL)
10082 + if (modifier - dot < sizeof (buf))
10084 + memcpy (buf, dot, modifier - dot);
10085 + buf [modifier - dot] = '\0';
10090 + /* Resolve through the charset.alias file. */
10091 + codeset = locale;
10095 + /* OS/2 has a function returning the locale's codepage as a number. */
10096 + if (DosQueryCp (sizeof (cp), cp, &cplen))
10100 + sprintf (buf, "CP%u", cp[0]);
10107 + if (codeset == NULL)
10108 + /* The canonical name cannot be determined. */
10111 + /* Resolve alias. */
10112 + for (aliases = get_charset_aliases ();
10113 + *aliases != '\0';
10114 + aliases += strlen (aliases) + 1, aliases += strlen (aliases) + 1)
10115 + if (strcmp (codeset, aliases) == 0
10116 + || (aliases[0] == '*' && aliases[1] == '\0'))
10118 + codeset = aliases + strlen (aliases) + 1;
10122 + /* Don't return an empty string. GNU libc and GNU libiconv interpret
10123 + the empty string as denoting "the locale's character encoding",
10124 + thus GNU libiconv would call this function a second time. */
10125 + if (codeset[0] == '\0')
10126 + codeset = "ASCII";
10130 --- lrzsz-0.12.20.safe/intl/localcharset.h 1969-12-31 19:00:00.000000000 -0500
10131 +++ lrzsz-0.12.20/intl/localcharset.h 2004-09-12 14:40:34.483728632 -0400
10133 +/* Determine a canonical name for the current locale's character encoding.
10134 + Copyright (C) 2000-2003 Free Software Foundation, Inc.
10135 + This file is part of the GNU CHARSET Library.
10137 + This program is free software; you can redistribute it and/or modify it
10138 + under the terms of the GNU Library General Public License as published
10139 + by the Free Software Foundation; either version 2, or (at your option)
10140 + any later version.
10142 + This program is distributed in the hope that it will be useful,
10143 + but WITHOUT ANY WARRANTY; without even the implied warranty of
10144 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
10145 + Library General Public License for more details.
10147 + You should have received a copy of the GNU Library General Public
10148 + License along with this program; if not, write to the Free Software
10149 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
10152 +#ifndef _LOCALCHARSET_H
10153 +#define _LOCALCHARSET_H
10156 +#ifdef __cplusplus
10161 +/* Determine the current locale's character encoding, and canonicalize it
10162 + into one of the canonical names listed in config.charset.
10163 + The result must not be freed; it is statically allocated.
10164 + If the canonical name cannot be determined, the result is a non-canonical
10166 +extern const char * locale_charset (void);
10169 +#ifdef __cplusplus
10174 +#endif /* _LOCALCHARSET_H */
10175 --- lrzsz-0.12.20.safe/intl/locale.alias 1969-12-31 19:00:00.000000000 -0500
10176 +++ lrzsz-0.12.20/intl/locale.alias 2004-09-12 14:40:34.499726200 -0400
10178 +# Locale name alias data base.
10179 +# Copyright (C) 1996-2001,2003 Free Software Foundation, Inc.
10181 +# This program is free software; you can redistribute it and/or modify it
10182 +# under the terms of the GNU Library General Public License as published
10183 +# by the Free Software Foundation; either version 2, or (at your option)
10184 +# any later version.
10186 +# This program is distributed in the hope that it will be useful,
10187 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
10188 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
10189 +# Library General Public License for more details.
10191 +# You should have received a copy of the GNU Library General Public
10192 +# License along with this program; if not, write to the Free Software
10193 +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
10196 +# The format of this file is the same as for the corresponding file of
10197 +# the X Window System, which normally can be found in
10198 +# /usr/lib/X11/locale/locale.alias
10199 +# A single line contains two fields: an alias and a substitution value.
10200 +# All entries are case independent.
10202 +# Note: This file is far from being complete. If you have a value for
10203 +# your own site which you think might be useful for others too, share
10204 +# it with the rest of us. Send it using the `glibcbug' script to
10207 +# Packages using this file:
10209 +bokmal nb_NO.ISO-8859-1
10210 +bokmål nb_NO.ISO-8859-1
10211 +catalan ca_ES.ISO-8859-1
10212 +croatian hr_HR.ISO-8859-2
10213 +czech cs_CZ.ISO-8859-2
10214 +danish da_DK.ISO-8859-1
10215 +dansk da_DK.ISO-8859-1
10216 +deutsch de_DE.ISO-8859-1
10217 +dutch nl_NL.ISO-8859-1
10218 +eesti et_EE.ISO-8859-1
10219 +estonian et_EE.ISO-8859-1
10220 +finnish fi_FI.ISO-8859-1
10221 +français fr_FR.ISO-8859-1
10222 +french fr_FR.ISO-8859-1
10223 +galego gl_ES.ISO-8859-1
10224 +galician gl_ES.ISO-8859-1
10225 +german de_DE.ISO-8859-1
10226 +greek el_GR.ISO-8859-7
10227 +hebrew he_IL.ISO-8859-8
10228 +hrvatski hr_HR.ISO-8859-2
10229 +hungarian hu_HU.ISO-8859-2
10230 +icelandic is_IS.ISO-8859-1
10231 +italian it_IT.ISO-8859-1
10232 +japanese ja_JP.eucJP
10233 +japanese.euc ja_JP.eucJP
10235 +ja_JP.ujis ja_JP.eucJP
10236 +japanese.sjis ja_JP.SJIS
10237 +korean ko_KR.eucKR
10238 +korean.euc ko_KR.eucKR
10240 +lithuanian lt_LT.ISO-8859-13
10241 +no_NO nb_NO.ISO-8859-1
10242 +no_NO.ISO-8859-1 nb_NO.ISO-8859-1
10243 +norwegian nb_NO.ISO-8859-1
10244 +nynorsk nn_NO.ISO-8859-1
10245 +polish pl_PL.ISO-8859-2
10246 +portuguese pt_PT.ISO-8859-1
10247 +romanian ro_RO.ISO-8859-2
10248 +russian ru_RU.ISO-8859-5
10249 +slovak sk_SK.ISO-8859-2
10250 +slovene sl_SI.ISO-8859-2
10251 +slovenian sl_SI.ISO-8859-2
10252 +spanish es_ES.ISO-8859-1
10253 +swedish sv_SE.ISO-8859-1
10254 +thai th_TH.TIS-620
10255 +turkish tr_TR.ISO-8859-9
10256 --- lrzsz-0.12.20.safe/intl/localealias.c 1998-04-26 09:22:37.000000000 -0400
10257 +++ lrzsz-0.12.20/intl/localealias.c 2004-09-12 14:40:34.505725288 -0400
10259 -/* Handle aliases for locale names
10260 - Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
10261 - Written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
10262 +/* Handle aliases for locale names.
10263 + Copyright (C) 1995-1999, 2000-2001, 2003 Free Software Foundation, Inc.
10265 - This program is free software; you can redistribute it and/or modify
10266 - it under the terms of the GNU General Public License as published by
10267 - the Free Software Foundation; either version 2, or (at your option)
10268 + This program is free software; you can redistribute it and/or modify it
10269 + under the terms of the GNU Library General Public License as published
10270 + by the Free Software Foundation; either version 2, or (at your option)
10273 This program is distributed in the hope that it will be useful,
10274 but WITHOUT ANY WARRANTY; without even the implied warranty of
10275 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10276 - GNU General Public License for more details.
10277 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
10278 + Library General Public License for more details.
10280 - You should have received a copy of the GNU General Public License
10281 - along with this program; if not, write to the Free Software Foundation,
10282 - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
10283 + You should have received a copy of the GNU Library General Public
10284 + License along with this program; if not, write to the Free Software
10285 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
10288 +/* Tell glibc's <string.h> to provide a prototype for mempcpy().
10289 + This must come before <config.h> because <config.h> may include
10290 + <features.h>, and once <features.h> has been included, it's too late. */
10291 +#ifndef _GNU_SOURCE
10292 +# define _GNU_SOURCE 1
10295 #ifdef HAVE_CONFIG_H
10296 # include <config.h>
10297 @@ -22,56 +29,45 @@
10301 +#if defined _LIBC || defined HAVE___FSETLOCKING
10302 +# include <stdio_ext.h>
10304 #include <sys/types.h>
10308 # define alloca __builtin_alloca
10309 # define HAVE_ALLOCA 1
10311 -# if defined HAVE_ALLOCA_H || defined _LIBC
10312 -# include <alloca.h>
10314 +# include <malloc.h>
10315 +# define alloca _alloca
10319 +# if defined HAVE_ALLOCA_H || defined _LIBC
10320 +# include <alloca.h>
10334 -#if defined STDC_HEADERS || defined _LIBC
10335 -# include <stdlib.h>
10338 -# ifdef HAVE_MALLOC_H
10339 -# include <malloc.h>
10344 +#include <stdlib.h>
10345 +#include <string.h>
10347 -#if defined HAVE_STRING_H || defined _LIBC
10348 -# ifndef _GNU_SOURCE
10349 -# define _GNU_SOURCE 1
10351 -# include <string.h>
10352 +#include "gettextP.h"
10354 +#if ENABLE_RELOCATABLE
10355 +# include "relocatable.h"
10357 -# include <strings.h>
10359 -# define memcpy(Dst, Src, Num) bcopy (Src, Dst, Num)
10362 -#if !HAVE_STRCHR && !defined _LIBC
10364 -# define strchr index
10366 +# define relocate(pathname) (pathname)
10369 -#include "gettext.h"
10370 -#include "gettextP.h"
10372 /* @@ end of prolog @@ */
10375 @@ -79,43 +75,49 @@
10376 because some ANSI C functions will require linking with this object
10377 file and the name space must not be polluted. */
10378 # define strcasecmp __strcasecmp
10381 +# define mempcpy __mempcpy
10383 +# define HAVE_MEMPCPY 1
10384 +# define HAVE___FSETLOCKING 1
10386 +/* We need locking here since we can be called from different places. */
10387 +# include <bits/libc-lock.h>
10389 +__libc_lock_define_initialized (static, lock);
10392 +#ifndef internal_function
10393 +# define internal_function
10396 +/* Some optimizations for glibc. */
10398 +# define FEOF(fp) feof_unlocked (fp)
10399 +# define FGETS(buf, n, fp) fgets_unlocked (buf, n, fp)
10401 +# define FEOF(fp) feof (fp)
10402 +# define FGETS(buf, n, fp) fgets (buf, n, fp)
10405 -/* For those loosing systems which don't have `alloca' we have to add
10406 +/* For those losing systems which don't have `alloca' we have to add
10407 some additional code emulating it. */
10409 -/* Nothing has to be done. */
10410 -# define ADD_BLOCK(list, address) /* nothing */
10411 -# define FREE_BLOCKS(list) /* nothing */
10412 +# define freea(p) /* nothing */
10417 - struct block_list *next;
10419 -# define ADD_BLOCK(list, addr) \
10421 - struct block_list *newp = (struct block_list *) malloc (sizeof (*newp)); \
10422 - /* If we cannot get a free block we cannot add the new element to \
10424 - if (newp != NULL) { \
10425 - newp->address = (addr); \
10426 - newp->next = (list); \
10430 -# define FREE_BLOCKS(list) \
10432 - while (list != NULL) { \
10433 - struct block_list *old = list; \
10434 - list = list->next; \
10439 -# define alloca(size) (malloc (size))
10440 -#endif /* have alloca */
10441 +# define alloca(n) malloc (n)
10442 +# define freea(p) free (p)
10445 +#if defined _LIBC_REENTRANT || HAVE_DECL_FGETS_UNLOCKED
10447 +# define fgets(buf, len, s) fgets_unlocked (buf, len, s)
10449 +#if defined _LIBC_REENTRANT || HAVE_DECL_FEOF_UNLOCKED
10451 +# define feof(s) feof_unlocked (s)
10456 @@ -125,26 +127,41 @@
10460 -static struct alias_map *map;
10461 -static size_t nmap = 0;
10462 -static size_t maxmap = 0;
10464 +# define libc_freeres_ptr(decl) decl
10467 +libc_freeres_ptr (static char *string_space);
10468 +static size_t string_space_act;
10469 +static size_t string_space_max;
10470 +libc_freeres_ptr (static struct alias_map *map);
10471 +static size_t nmap;
10472 +static size_t maxmap;
10475 /* Prototypes for local functions. */
10476 -static size_t read_alias_file PARAMS ((const char *fname, int fname_len));
10477 -static void extend_alias_table PARAMS ((void));
10478 -static int alias_compare PARAMS ((const struct alias_map *map1,
10479 - const struct alias_map *map2));
10480 +static size_t read_alias_file (const char *fname, int fname_len)
10481 + internal_function;
10482 +static int extend_alias_table (void);
10483 +static int alias_compare (const struct alias_map *map1,
10484 + const struct alias_map *map2);
10488 -_nl_expand_alias (name)
10489 - const char *name;
10490 +_nl_expand_alias (const char *name)
10492 - static const char *locale_alias_path = LOCALE_ALIAS_PATH;
10493 + static const char *locale_alias_path;
10494 struct alias_map *retval;
10495 + const char *result = NULL;
10499 + __libc_lock_lock (lock);
10502 + if (locale_alias_path == NULL)
10503 + locale_alias_path = LOCALE_ALIAS_PATH;
10507 struct alias_map item;
10508 @@ -154,15 +171,18 @@
10510 retval = (struct alias_map *) bsearch (&item, map, nmap,
10511 sizeof (struct alias_map),
10512 - (int (*) PARAMS ((const void *,
10514 + (int (*) (const void *,
10520 /* We really found an alias. Return the value. */
10521 if (retval != NULL)
10522 - return retval->value;
10524 + result = retval->value;
10528 /* Perhaps we can find another alias file. */
10530 @@ -170,11 +190,12 @@
10534 - while (locale_alias_path[0] == ':')
10535 + while (locale_alias_path[0] == PATH_SEPARATOR)
10536 ++locale_alias_path;
10537 start = locale_alias_path;
10539 - while (locale_alias_path[0] != '\0' && locale_alias_path[0] != ':')
10540 + while (locale_alias_path[0] != '\0'
10541 + && locale_alias_path[0] != PATH_SEPARATOR)
10542 ++locale_alias_path;
10544 if (start < locale_alias_path)
10545 @@ -183,78 +204,87 @@
10547 while (added != 0);
10551 + __libc_lock_unlock (lock);
10559 -read_alias_file (fname, fname_len)
10560 - const char *fname;
10563 +read_alias_file (const char *fname, int fname_len)
10565 -#ifndef HAVE_ALLOCA
10566 - struct block_list *block_list = NULL;
10571 static const char aliasfile[] = "/locale.alias";
10573 full_fname = (char *) alloca (fname_len + sizeof aliasfile);
10574 - ADD_BLOCK (block_list, full_fname);
10575 +#ifdef HAVE_MEMPCPY
10576 + mempcpy (mempcpy (full_fname, fname, fname_len),
10577 + aliasfile, sizeof aliasfile);
10579 memcpy (full_fname, fname, fname_len);
10580 memcpy (&full_fname[fname_len], aliasfile, sizeof aliasfile);
10583 - fp = fopen (full_fname, "r");
10584 + fp = fopen (relocate (full_fname), "r");
10585 + freea (full_fname);
10588 - FREE_BLOCKS (block_list);
10593 +#ifdef HAVE___FSETLOCKING
10594 + /* No threads present. */
10595 + __fsetlocking (fp, FSETLOCKING_BYCALLER);
10599 - while (!feof (fp))
10600 + while (!FEOF (fp))
10602 /* It is a reasonable approach to use a fix buffer here because
10603 a) we are only interested in the first two fields
10604 b) these fields must be usable as file names and so must not
10607 - char buf[BUFSIZ];
10608 + We avoid a multi-kilobyte buffer here since this would use up
10609 + stack space which we might not have if the program ran out of
10616 - if (fgets (buf, BUFSIZ, fp) == NULL)
10617 + if (FGETS (buf, sizeof buf, fp) == NULL)
10622 /* Ignore leading white space. */
10623 - while (isspace (cp[0]))
10624 + while (isspace ((unsigned char) cp[0]))
10627 /* A leading '#' signals a comment line. */
10628 if (cp[0] != '\0' && cp[0] != '#')
10631 - while (cp[0] != '\0' && !isspace (cp[0]))
10632 + while (cp[0] != '\0' && !isspace ((unsigned char) cp[0]))
10634 /* Terminate alias name. */
10638 /* Now look for the beginning of the value. */
10639 - while (isspace (cp[0]))
10640 + while (isspace ((unsigned char) cp[0]))
10647 + size_t alias_len;
10648 + size_t value_len;
10651 - while (cp[0] != '\0' && !isspace (cp[0]))
10652 + while (cp[0] != '\0' && !isspace ((unsigned char) cp[0]))
10654 /* Terminate value. */
10656 @@ -269,28 +299,44 @@
10659 if (nmap >= maxmap)
10660 - extend_alias_table ();
10662 - /* We cannot depend on strdup available in the libc. Sigh! */
10663 - len = strlen (alias) + 1;
10664 - tp = (char *) malloc (len);
10667 - FREE_BLOCKS (block_list);
10668 + if (__builtin_expect (extend_alias_table (), 0))
10671 - memcpy (tp, alias, len);
10672 - map[nmap].alias = tp;
10674 - len = strlen (value) + 1;
10675 - tp = (char *) malloc (len);
10677 + alias_len = strlen (alias) + 1;
10678 + value_len = strlen (value) + 1;
10680 + if (string_space_act + alias_len + value_len > string_space_max)
10682 - FREE_BLOCKS (block_list);
10684 + /* Increase size of memory pool. */
10685 + size_t new_size = (string_space_max
10686 + + (alias_len + value_len > 1024
10687 + ? alias_len + value_len : 1024));
10688 + char *new_pool = (char *) realloc (string_space, new_size);
10689 + if (new_pool == NULL)
10692 + if (__builtin_expect (string_space != new_pool, 0))
10696 + for (i = 0; i < nmap; i++)
10698 + map[i].alias += new_pool - string_space;
10699 + map[i].value += new_pool - string_space;
10703 + string_space = new_pool;
10704 + string_space_max = new_size;
10706 - memcpy (tp, value, len);
10707 - map[nmap].value = tp;
10709 + map[nmap].alias = memcpy (&string_space[string_space_act],
10710 + alias, alias_len);
10711 + string_space_act += alias_len;
10713 + map[nmap].value = memcpy (&string_space[string_space_act],
10714 + value, value_len);
10715 + string_space_act += value_len;
10719 @@ -299,14 +345,11 @@
10721 /* Possibly not the whole line fits into the buffer. Ignore
10722 the rest of the line. */
10723 - while (strchr (cp, '\n') == NULL)
10726 - if (fgets (buf, BUFSIZ, fp) == NULL)
10727 - /* Make sure the inner loop will be left. The outer loop
10728 - will exit at the `feof' test. */
10731 + while (strchr (buf, '\n') == NULL)
10732 + if (FGETS (buf, sizeof buf, fp) == NULL)
10733 + /* Make sure the inner loop will be left. The outer loop
10734 + will exit at the `feof' test. */
10738 /* Should we test for ferror()? I think we have to silently ignore
10739 @@ -315,40 +358,33 @@
10742 qsort (map, nmap, sizeof (struct alias_map),
10743 - (int (*) PARAMS ((const void *, const void *))) alias_compare);
10744 + (int (*) (const void *, const void *)) alias_compare);
10746 - FREE_BLOCKS (block_list);
10753 extend_alias_table ()
10756 struct alias_map *new_map;
10758 new_size = maxmap == 0 ? 100 : 2 * maxmap;
10759 - new_map = (struct alias_map *) malloc (new_size
10760 - * sizeof (struct alias_map));
10761 + new_map = (struct alias_map *) realloc (map, (new_size
10762 + * sizeof (struct alias_map)));
10763 if (new_map == NULL)
10764 /* Simply don't extend: we don't have any more core. */
10767 - memcpy (new_map, map, nmap * sizeof (struct alias_map));
10780 -alias_compare (map1, map2)
10781 - const struct alias_map *map1;
10782 - const struct alias_map *map2;
10783 +alias_compare (const struct alias_map *map1, const struct alias_map *map2)
10785 #if defined _LIBC || defined HAVE_STRCASECMP
10786 return strcasecmp (map1->alias, map2->alias);
10787 --- lrzsz-0.12.20.safe/intl/localename.c 1969-12-31 19:00:00.000000000 -0500
10788 +++ lrzsz-0.12.20/intl/localename.c 2004-09-12 14:40:34.510724528 -0400
10790 +/* Determine the current selected locale.
10791 + Copyright (C) 1995-1999, 2000-2004 Free Software Foundation, Inc.
10793 + This program is free software; you can redistribute it and/or modify it
10794 + under the terms of the GNU Library General Public License as published
10795 + by the Free Software Foundation; either version 2, or (at your option)
10796 + any later version.
10798 + This program is distributed in the hope that it will be useful,
10799 + but WITHOUT ANY WARRANTY; without even the implied warranty of
10800 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
10801 + Library General Public License for more details.
10803 + You should have received a copy of the GNU Library General Public
10804 + License along with this program; if not, write to the Free Software
10805 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
10808 +/* Written by Ulrich Drepper <drepper@gnu.org>, 1995. */
10809 +/* Win32 code written by Tor Lillqvist <tml@iki.fi>. */
10811 +#ifdef HAVE_CONFIG_H
10812 +# include <config.h>
10815 +#include <stdlib.h>
10816 +#include <locale.h>
10818 +#if defined _WIN32 || defined __WIN32__
10819 +# undef WIN32 /* avoid warning on mingw32 */
10824 +# define WIN32_LEAN_AND_MEAN
10825 +# include <windows.h>
10826 +/* List of language codes, sorted by value:
10828 + 0x02 LANG_BULGARIAN
10829 + 0x03 LANG_CATALAN
10830 + 0x04 LANG_CHINESE
10835 + 0x09 LANG_ENGLISH
10836 + 0x0a LANG_SPANISH
10837 + 0x0b LANG_FINNISH
10840 + 0x0e LANG_HUNGARIAN
10841 + 0x0f LANG_ICELANDIC
10842 + 0x10 LANG_ITALIAN
10843 + 0x11 LANG_JAPANESE
10846 + 0x14 LANG_NORWEGIAN
10848 + 0x16 LANG_PORTUGUESE
10849 + 0x17 LANG_RHAETO_ROMANCE
10850 + 0x18 LANG_ROMANIAN
10851 + 0x19 LANG_RUSSIAN
10852 + 0x1a LANG_CROATIAN == LANG_SERBIAN
10854 + 0x1c LANG_ALBANIAN
10855 + 0x1d LANG_SWEDISH
10857 + 0x1f LANG_TURKISH
10859 + 0x21 LANG_INDONESIAN
10860 + 0x22 LANG_UKRAINIAN
10861 + 0x23 LANG_BELARUSIAN
10862 + 0x24 LANG_SLOVENIAN
10863 + 0x25 LANG_ESTONIAN
10864 + 0x26 LANG_LATVIAN
10865 + 0x27 LANG_LITHUANIAN
10868 + 0x2a LANG_VIETNAMESE
10869 + 0x2b LANG_ARMENIAN
10872 + 0x2e LANG_SORBIAN
10873 + 0x2f LANG_MACEDONIAN
10880 + 0x36 LANG_AFRIKAANS
10881 + 0x37 LANG_GEORGIAN
10882 + 0x38 LANG_FAEROESE
10884 + 0x3a LANG_MALTESE
10887 + 0x3d LANG_YIDDISH
10891 + 0x41 LANG_SWAHILI
10892 + 0x42 LANG_TURKMEN
10895 + 0x45 LANG_BENGALI
10896 + 0x46 LANG_PUNJABI
10897 + 0x47 LANG_GUJARATI
10901 + 0x4b LANG_KANNADA
10902 + 0x4c LANG_MALAYALAM
10903 + 0x4d LANG_ASSAMESE
10904 + 0x4e LANG_MARATHI
10905 + 0x4f LANG_SANSKRIT
10906 + 0x50 LANG_MONGOLIAN
10907 + 0x51 LANG_TIBETAN
10909 + 0x53 LANG_CAMBODIAN
10911 + 0x55 LANG_BURMESE
10912 + 0x56 LANG_GALICIAN
10913 + 0x57 LANG_KONKANI
10914 + 0x58 LANG_MANIPURI
10917 + 0x5b LANG_SINHALESE
10918 + 0x5c LANG_CHEROKEE
10919 + 0x5d LANG_INUKTITUT
10920 + 0x5e LANG_AMHARIC
10921 + 0x5f LANG_TAMAZIGHT
10922 + 0x60 LANG_KASHMIRI
10924 + 0x62 LANG_FRISIAN
10926 + 0x64 LANG_TAGALOG
10929 + 0x67 LANG_FULFULDE
10936 + 0x73 LANG_TIGRINYA
10937 + 0x74 LANG_GUARANI
10938 + 0x75 LANG_HAWAIIAN
10942 + 0x79 LANG_PAPIAMENTU
10944 +/* Mingw headers don't have latest language and sublanguage codes. */
10945 +# ifndef LANG_AFRIKAANS
10946 +# define LANG_AFRIKAANS 0x36
10948 +# ifndef LANG_ALBANIAN
10949 +# define LANG_ALBANIAN 0x1c
10951 +# ifndef LANG_AMHARIC
10952 +# define LANG_AMHARIC 0x5e
10954 +# ifndef LANG_ARABIC
10955 +# define LANG_ARABIC 0x01
10957 +# ifndef LANG_ARMENIAN
10958 +# define LANG_ARMENIAN 0x2b
10960 +# ifndef LANG_ASSAMESE
10961 +# define LANG_ASSAMESE 0x4d
10963 +# ifndef LANG_AZERI
10964 +# define LANG_AZERI 0x2c
10966 +# ifndef LANG_BASQUE
10967 +# define LANG_BASQUE 0x2d
10969 +# ifndef LANG_BELARUSIAN
10970 +# define LANG_BELARUSIAN 0x23
10972 +# ifndef LANG_BENGALI
10973 +# define LANG_BENGALI 0x45
10975 +# ifndef LANG_BURMESE
10976 +# define LANG_BURMESE 0x55
10978 +# ifndef LANG_CAMBODIAN
10979 +# define LANG_CAMBODIAN 0x53
10981 +# ifndef LANG_CATALAN
10982 +# define LANG_CATALAN 0x03
10984 +# ifndef LANG_CHEROKEE
10985 +# define LANG_CHEROKEE 0x5c
10987 +# ifndef LANG_DIVEHI
10988 +# define LANG_DIVEHI 0x65
10991 +# define LANG_EDO 0x66
10993 +# ifndef LANG_ESTONIAN
10994 +# define LANG_ESTONIAN 0x25
10996 +# ifndef LANG_FAEROESE
10997 +# define LANG_FAEROESE 0x38
10999 +# ifndef LANG_FARSI
11000 +# define LANG_FARSI 0x29
11002 +# ifndef LANG_FRISIAN
11003 +# define LANG_FRISIAN 0x62
11005 +# ifndef LANG_FULFULDE
11006 +# define LANG_FULFULDE 0x67
11008 +# ifndef LANG_GAELIC
11009 +# define LANG_GAELIC 0x3c
11011 +# ifndef LANG_GALICIAN
11012 +# define LANG_GALICIAN 0x56
11014 +# ifndef LANG_GEORGIAN
11015 +# define LANG_GEORGIAN 0x37
11017 +# ifndef LANG_GUARANI
11018 +# define LANG_GUARANI 0x74
11020 +# ifndef LANG_GUJARATI
11021 +# define LANG_GUJARATI 0x47
11023 +# ifndef LANG_HAUSA
11024 +# define LANG_HAUSA 0x68
11026 +# ifndef LANG_HAWAIIAN
11027 +# define LANG_HAWAIIAN 0x75
11029 +# ifndef LANG_HEBREW
11030 +# define LANG_HEBREW 0x0d
11032 +# ifndef LANG_HINDI
11033 +# define LANG_HINDI 0x39
11035 +# ifndef LANG_IBIBIO
11036 +# define LANG_IBIBIO 0x69
11038 +# ifndef LANG_IGBO
11039 +# define LANG_IGBO 0x70
11041 +# ifndef LANG_INDONESIAN
11042 +# define LANG_INDONESIAN 0x21
11044 +# ifndef LANG_INUKTITUT
11045 +# define LANG_INUKTITUT 0x5d
11047 +# ifndef LANG_KANNADA
11048 +# define LANG_KANNADA 0x4b
11050 +# ifndef LANG_KANURI
11051 +# define LANG_KANURI 0x71
11053 +# ifndef LANG_KASHMIRI
11054 +# define LANG_KASHMIRI 0x60
11056 +# ifndef LANG_KAZAK
11057 +# define LANG_KAZAK 0x3f
11059 +# ifndef LANG_KONKANI
11060 +# define LANG_KONKANI 0x57
11062 +# ifndef LANG_KYRGYZ
11063 +# define LANG_KYRGYZ 0x40
11066 +# define LANG_LAO 0x54
11068 +# ifndef LANG_LATIN
11069 +# define LANG_LATIN 0x76
11071 +# ifndef LANG_LATVIAN
11072 +# define LANG_LATVIAN 0x26
11074 +# ifndef LANG_LITHUANIAN
11075 +# define LANG_LITHUANIAN 0x27
11077 +# ifndef LANG_MACEDONIAN
11078 +# define LANG_MACEDONIAN 0x2f
11080 +# ifndef LANG_MALAY
11081 +# define LANG_MALAY 0x3e
11083 +# ifndef LANG_MALAYALAM
11084 +# define LANG_MALAYALAM 0x4c
11086 +# ifndef LANG_MALTESE
11087 +# define LANG_MALTESE 0x3a
11089 +# ifndef LANG_MANIPURI
11090 +# define LANG_MANIPURI 0x58
11092 +# ifndef LANG_MARATHI
11093 +# define LANG_MARATHI 0x4e
11095 +# ifndef LANG_MONGOLIAN
11096 +# define LANG_MONGOLIAN 0x50
11098 +# ifndef LANG_NEPALI
11099 +# define LANG_NEPALI 0x61
11101 +# ifndef LANG_ORIYA
11102 +# define LANG_ORIYA 0x48
11104 +# ifndef LANG_OROMO
11105 +# define LANG_OROMO 0x72
11107 +# ifndef LANG_PAPIAMENTU
11108 +# define LANG_PAPIAMENTU 0x79
11110 +# ifndef LANG_PASHTO
11111 +# define LANG_PASHTO 0x63
11113 +# ifndef LANG_PUNJABI
11114 +# define LANG_PUNJABI 0x46
11116 +# ifndef LANG_RHAETO_ROMANCE
11117 +# define LANG_RHAETO_ROMANCE 0x17
11119 +# ifndef LANG_SAAMI
11120 +# define LANG_SAAMI 0x3b
11122 +# ifndef LANG_SANSKRIT
11123 +# define LANG_SANSKRIT 0x4f
11125 +# ifndef LANG_SERBIAN
11126 +# define LANG_SERBIAN 0x1a
11128 +# ifndef LANG_SINDHI
11129 +# define LANG_SINDHI 0x59
11131 +# ifndef LANG_SINHALESE
11132 +# define LANG_SINHALESE 0x5b
11134 +# ifndef LANG_SLOVAK
11135 +# define LANG_SLOVAK 0x1b
11137 +# ifndef LANG_SOMALI
11138 +# define LANG_SOMALI 0x77
11140 +# ifndef LANG_SORBIAN
11141 +# define LANG_SORBIAN 0x2e
11143 +# ifndef LANG_SUTU
11144 +# define LANG_SUTU 0x30
11146 +# ifndef LANG_SWAHILI
11147 +# define LANG_SWAHILI 0x41
11149 +# ifndef LANG_SYRIAC
11150 +# define LANG_SYRIAC 0x5a
11152 +# ifndef LANG_TAGALOG
11153 +# define LANG_TAGALOG 0x64
11155 +# ifndef LANG_TAJIK
11156 +# define LANG_TAJIK 0x28
11158 +# ifndef LANG_TAMAZIGHT
11159 +# define LANG_TAMAZIGHT 0x5f
11161 +# ifndef LANG_TAMIL
11162 +# define LANG_TAMIL 0x49
11164 +# ifndef LANG_TATAR
11165 +# define LANG_TATAR 0x44
11167 +# ifndef LANG_TELUGU
11168 +# define LANG_TELUGU 0x4a
11170 +# ifndef LANG_THAI
11171 +# define LANG_THAI 0x1e
11173 +# ifndef LANG_TIBETAN
11174 +# define LANG_TIBETAN 0x51
11176 +# ifndef LANG_TIGRINYA
11177 +# define LANG_TIGRINYA 0x73
11179 +# ifndef LANG_TSONGA
11180 +# define LANG_TSONGA 0x31
11182 +# ifndef LANG_TSWANA
11183 +# define LANG_TSWANA 0x32
11185 +# ifndef LANG_TURKMEN
11186 +# define LANG_TURKMEN 0x42
11188 +# ifndef LANG_UKRAINIAN
11189 +# define LANG_UKRAINIAN 0x22
11191 +# ifndef LANG_URDU
11192 +# define LANG_URDU 0x20
11194 +# ifndef LANG_UZBEK
11195 +# define LANG_UZBEK 0x43
11197 +# ifndef LANG_VENDA
11198 +# define LANG_VENDA 0x33
11200 +# ifndef LANG_VIETNAMESE
11201 +# define LANG_VIETNAMESE 0x2a
11203 +# ifndef LANG_WELSH
11204 +# define LANG_WELSH 0x52
11206 +# ifndef LANG_XHOSA
11207 +# define LANG_XHOSA 0x34
11210 +# define LANG_YI 0x78
11212 +# ifndef LANG_YIDDISH
11213 +# define LANG_YIDDISH 0x3d
11215 +# ifndef LANG_YORUBA
11216 +# define LANG_YORUBA 0x6a
11218 +# ifndef LANG_ZULU
11219 +# define LANG_ZULU 0x35
11221 +# ifndef SUBLANG_ARABIC_SAUDI_ARABIA
11222 +# define SUBLANG_ARABIC_SAUDI_ARABIA 0x01
11224 +# ifndef SUBLANG_ARABIC_IRAQ
11225 +# define SUBLANG_ARABIC_IRAQ 0x02
11227 +# ifndef SUBLANG_ARABIC_EGYPT
11228 +# define SUBLANG_ARABIC_EGYPT 0x03
11230 +# ifndef SUBLANG_ARABIC_LIBYA
11231 +# define SUBLANG_ARABIC_LIBYA 0x04
11233 +# ifndef SUBLANG_ARABIC_ALGERIA
11234 +# define SUBLANG_ARABIC_ALGERIA 0x05
11236 +# ifndef SUBLANG_ARABIC_MOROCCO
11237 +# define SUBLANG_ARABIC_MOROCCO 0x06
11239 +# ifndef SUBLANG_ARABIC_TUNISIA
11240 +# define SUBLANG_ARABIC_TUNISIA 0x07
11242 +# ifndef SUBLANG_ARABIC_OMAN
11243 +# define SUBLANG_ARABIC_OMAN 0x08
11245 +# ifndef SUBLANG_ARABIC_YEMEN
11246 +# define SUBLANG_ARABIC_YEMEN 0x09
11248 +# ifndef SUBLANG_ARABIC_SYRIA
11249 +# define SUBLANG_ARABIC_SYRIA 0x0a
11251 +# ifndef SUBLANG_ARABIC_JORDAN
11252 +# define SUBLANG_ARABIC_JORDAN 0x0b
11254 +# ifndef SUBLANG_ARABIC_LEBANON
11255 +# define SUBLANG_ARABIC_LEBANON 0x0c
11257 +# ifndef SUBLANG_ARABIC_KUWAIT
11258 +# define SUBLANG_ARABIC_KUWAIT 0x0d
11260 +# ifndef SUBLANG_ARABIC_UAE
11261 +# define SUBLANG_ARABIC_UAE 0x0e
11263 +# ifndef SUBLANG_ARABIC_BAHRAIN
11264 +# define SUBLANG_ARABIC_BAHRAIN 0x0f
11266 +# ifndef SUBLANG_ARABIC_QATAR
11267 +# define SUBLANG_ARABIC_QATAR 0x10
11269 +# ifndef SUBLANG_AZERI_LATIN
11270 +# define SUBLANG_AZERI_LATIN 0x01
11272 +# ifndef SUBLANG_AZERI_CYRILLIC
11273 +# define SUBLANG_AZERI_CYRILLIC 0x02
11275 +# ifndef SUBLANG_BENGALI_INDIA
11276 +# define SUBLANG_BENGALI_INDIA 0x00
11278 +# ifndef SUBLANG_BENGALI_BANGLADESH
11279 +# define SUBLANG_BENGALI_BANGLADESH 0x01
11281 +# ifndef SUBLANG_CHINESE_MACAU
11282 +# define SUBLANG_CHINESE_MACAU 0x05
11284 +# ifndef SUBLANG_ENGLISH_SOUTH_AFRICA
11285 +# define SUBLANG_ENGLISH_SOUTH_AFRICA 0x07
11287 +# ifndef SUBLANG_ENGLISH_JAMAICA
11288 +# define SUBLANG_ENGLISH_JAMAICA 0x08
11290 +# ifndef SUBLANG_ENGLISH_CARIBBEAN
11291 +# define SUBLANG_ENGLISH_CARIBBEAN 0x09
11293 +# ifndef SUBLANG_ENGLISH_BELIZE
11294 +# define SUBLANG_ENGLISH_BELIZE 0x0a
11296 +# ifndef SUBLANG_ENGLISH_TRINIDAD
11297 +# define SUBLANG_ENGLISH_TRINIDAD 0x0b
11299 +# ifndef SUBLANG_ENGLISH_ZIMBABWE
11300 +# define SUBLANG_ENGLISH_ZIMBABWE 0x0c
11302 +# ifndef SUBLANG_ENGLISH_PHILIPPINES
11303 +# define SUBLANG_ENGLISH_PHILIPPINES 0x0d
11305 +# ifndef SUBLANG_ENGLISH_INDONESIA
11306 +# define SUBLANG_ENGLISH_INDONESIA 0x0e
11308 +# ifndef SUBLANG_ENGLISH_HONGKONG
11309 +# define SUBLANG_ENGLISH_HONGKONG 0x0f
11311 +# ifndef SUBLANG_ENGLISH_INDIA
11312 +# define SUBLANG_ENGLISH_INDIA 0x10
11314 +# ifndef SUBLANG_ENGLISH_MALAYSIA
11315 +# define SUBLANG_ENGLISH_MALAYSIA 0x11
11317 +# ifndef SUBLANG_ENGLISH_SINGAPORE
11318 +# define SUBLANG_ENGLISH_SINGAPORE 0x12
11320 +# ifndef SUBLANG_FRENCH_LUXEMBOURG
11321 +# define SUBLANG_FRENCH_LUXEMBOURG 0x05
11323 +# ifndef SUBLANG_FRENCH_MONACO
11324 +# define SUBLANG_FRENCH_MONACO 0x06
11326 +# ifndef SUBLANG_FRENCH_WESTINDIES
11327 +# define SUBLANG_FRENCH_WESTINDIES 0x07
11329 +# ifndef SUBLANG_FRENCH_REUNION
11330 +# define SUBLANG_FRENCH_REUNION 0x08
11332 +# ifndef SUBLANG_FRENCH_CONGO
11333 +# define SUBLANG_FRENCH_CONGO 0x09
11335 +# ifndef SUBLANG_FRENCH_SENEGAL
11336 +# define SUBLANG_FRENCH_SENEGAL 0x0a
11338 +# ifndef SUBLANG_FRENCH_CAMEROON
11339 +# define SUBLANG_FRENCH_CAMEROON 0x0b
11341 +# ifndef SUBLANG_FRENCH_COTEDIVOIRE
11342 +# define SUBLANG_FRENCH_COTEDIVOIRE 0x0c
11344 +# ifndef SUBLANG_FRENCH_MALI
11345 +# define SUBLANG_FRENCH_MALI 0x0d
11347 +# ifndef SUBLANG_FRENCH_MOROCCO
11348 +# define SUBLANG_FRENCH_MOROCCO 0x0e
11350 +# ifndef SUBLANG_FRENCH_HAITI
11351 +# define SUBLANG_FRENCH_HAITI 0x0f
11353 +# ifndef SUBLANG_GERMAN_LUXEMBOURG
11354 +# define SUBLANG_GERMAN_LUXEMBOURG 0x04
11356 +# ifndef SUBLANG_GERMAN_LIECHTENSTEIN
11357 +# define SUBLANG_GERMAN_LIECHTENSTEIN 0x05
11359 +# ifndef SUBLANG_KASHMIRI_INDIA
11360 +# define SUBLANG_KASHMIRI_INDIA 0x02
11362 +# ifndef SUBLANG_MALAY_MALAYSIA
11363 +# define SUBLANG_MALAY_MALAYSIA 0x01
11365 +# ifndef SUBLANG_MALAY_BRUNEI_DARUSSALAM
11366 +# define SUBLANG_MALAY_BRUNEI_DARUSSALAM 0x02
11368 +# ifndef SUBLANG_NEPALI_INDIA
11369 +# define SUBLANG_NEPALI_INDIA 0x02
11371 +# ifndef SUBLANG_PUNJABI_INDIA
11372 +# define SUBLANG_PUNJABI_INDIA 0x00
11374 +# ifndef SUBLANG_PUNJABI_PAKISTAN
11375 +# define SUBLANG_PUNJABI_PAKISTAN 0x01
11377 +# ifndef SUBLANG_ROMANIAN_ROMANIA
11378 +# define SUBLANG_ROMANIAN_ROMANIA 0x00
11380 +# ifndef SUBLANG_ROMANIAN_MOLDOVA
11381 +# define SUBLANG_ROMANIAN_MOLDOVA 0x01
11383 +# ifndef SUBLANG_SERBIAN_LATIN
11384 +# define SUBLANG_SERBIAN_LATIN 0x02
11386 +# ifndef SUBLANG_SERBIAN_CYRILLIC
11387 +# define SUBLANG_SERBIAN_CYRILLIC 0x03
11389 +# ifndef SUBLANG_SINDHI_INDIA
11390 +# define SUBLANG_SINDHI_INDIA 0x00
11392 +# ifndef SUBLANG_SINDHI_PAKISTAN
11393 +# define SUBLANG_SINDHI_PAKISTAN 0x01
11395 +# ifndef SUBLANG_SPANISH_GUATEMALA
11396 +# define SUBLANG_SPANISH_GUATEMALA 0x04
11398 +# ifndef SUBLANG_SPANISH_COSTA_RICA
11399 +# define SUBLANG_SPANISH_COSTA_RICA 0x05
11401 +# ifndef SUBLANG_SPANISH_PANAMA
11402 +# define SUBLANG_SPANISH_PANAMA 0x06
11404 +# ifndef SUBLANG_SPANISH_DOMINICAN_REPUBLIC
11405 +# define SUBLANG_SPANISH_DOMINICAN_REPUBLIC 0x07
11407 +# ifndef SUBLANG_SPANISH_VENEZUELA
11408 +# define SUBLANG_SPANISH_VENEZUELA 0x08
11410 +# ifndef SUBLANG_SPANISH_COLOMBIA
11411 +# define SUBLANG_SPANISH_COLOMBIA 0x09
11413 +# ifndef SUBLANG_SPANISH_PERU
11414 +# define SUBLANG_SPANISH_PERU 0x0a
11416 +# ifndef SUBLANG_SPANISH_ARGENTINA
11417 +# define SUBLANG_SPANISH_ARGENTINA 0x0b
11419 +# ifndef SUBLANG_SPANISH_ECUADOR
11420 +# define SUBLANG_SPANISH_ECUADOR 0x0c
11422 +# ifndef SUBLANG_SPANISH_CHILE
11423 +# define SUBLANG_SPANISH_CHILE 0x0d
11425 +# ifndef SUBLANG_SPANISH_URUGUAY
11426 +# define SUBLANG_SPANISH_URUGUAY 0x0e
11428 +# ifndef SUBLANG_SPANISH_PARAGUAY
11429 +# define SUBLANG_SPANISH_PARAGUAY 0x0f
11431 +# ifndef SUBLANG_SPANISH_BOLIVIA
11432 +# define SUBLANG_SPANISH_BOLIVIA 0x10
11434 +# ifndef SUBLANG_SPANISH_EL_SALVADOR
11435 +# define SUBLANG_SPANISH_EL_SALVADOR 0x11
11437 +# ifndef SUBLANG_SPANISH_HONDURAS
11438 +# define SUBLANG_SPANISH_HONDURAS 0x12
11440 +# ifndef SUBLANG_SPANISH_NICARAGUA
11441 +# define SUBLANG_SPANISH_NICARAGUA 0x13
11443 +# ifndef SUBLANG_SPANISH_PUERTO_RICO
11444 +# define SUBLANG_SPANISH_PUERTO_RICO 0x14
11446 +# ifndef SUBLANG_SWEDISH_FINLAND
11447 +# define SUBLANG_SWEDISH_FINLAND 0x02
11449 +# ifndef SUBLANG_TAMAZIGHT_ARABIC
11450 +# define SUBLANG_TAMAZIGHT_ARABIC 0x01
11452 +# ifndef SUBLANG_TAMAZIGHT_LATIN
11453 +# define SUBLANG_TAMAZIGHT_LATIN 0x02
11455 +# ifndef SUBLANG_TIGRINYA_ETHIOPIA
11456 +# define SUBLANG_TIGRINYA_ETHIOPIA 0x00
11458 +# ifndef SUBLANG_TIGRINYA_ERITREA
11459 +# define SUBLANG_TIGRINYA_ERITREA 0x01
11461 +# ifndef SUBLANG_URDU_PAKISTAN
11462 +# define SUBLANG_URDU_PAKISTAN 0x01
11464 +# ifndef SUBLANG_URDU_INDIA
11465 +# define SUBLANG_URDU_INDIA 0x02
11467 +# ifndef SUBLANG_UZBEK_LATIN
11468 +# define SUBLANG_UZBEK_LATIN 0x01
11470 +# ifndef SUBLANG_UZBEK_CYRILLIC
11471 +# define SUBLANG_UZBEK_CYRILLIC 0x02
11475 +/* XPG3 defines the result of 'setlocale (category, NULL)' as:
11476 + "Directs 'setlocale()' to query 'category' and return the current
11477 + setting of 'local'."
11478 + However it does not specify the exact format. Neither do SUSV2 and
11479 + ISO C 99. So we can use this feature only on selected systems (e.g.
11480 + those using GNU C Library). */
11481 +#if defined _LIBC || (defined __GNU_LIBRARY__ && __GNU_LIBRARY__ >= 2)
11482 +# define HAVE_LOCALE_NULL
11485 +/* Determine the current locale's name, and canonicalize it into XPG syntax
11486 + language[_territory[.codeset]][@modifier]
11487 + The codeset part in the result is not reliable; the locale_charset()
11488 + should be used for codeset information instead.
11489 + The result must not be freed; it is statically allocated. */
11492 +_nl_locale_name (int category, const char *categoryname)
11494 + const char *retval;
11498 + /* Use the POSIX methods of looking to 'LC_ALL', 'LC_xxx', and 'LANG'.
11499 + On some systems this can be done by the 'setlocale' function itself. */
11500 +# if defined HAVE_SETLOCALE && defined HAVE_LC_MESSAGES && defined HAVE_LOCALE_NULL
11501 + retval = setlocale (category, NULL);
11503 + /* Setting of LC_ALL overwrites all other. */
11504 + retval = getenv ("LC_ALL");
11505 + if (retval == NULL || retval[0] == '\0')
11507 + /* Next comes the name of the desired category. */
11508 + retval = getenv (categoryname);
11509 + if (retval == NULL || retval[0] == '\0')
11511 + /* Last possibility is the LANG environment variable. */
11512 + retval = getenv ("LANG");
11513 + if (retval == NULL || retval[0] == '\0')
11514 + /* We use C as the default domain. POSIX says this is
11515 + implementation defined. */
11525 + /* Return an XPG style locale name language[_territory][@modifier].
11526 + Don't even bother determining the codeset; it's not useful in this
11527 + context, because message catalogs are not specific to a single
11532 + int primary, sub;
11534 + /* Let the user override the system settings through environment
11535 + variables, as on POSIX systems. */
11536 + retval = getenv ("LC_ALL");
11537 + if (retval != NULL && retval[0] != '\0')
11539 + retval = getenv (categoryname);
11540 + if (retval != NULL && retval[0] != '\0')
11542 + retval = getenv ("LANG");
11543 + if (retval != NULL && retval[0] != '\0')
11546 + /* Use native Win32 API locale ID. */
11547 + lcid = GetThreadLocale ();
11549 + /* Strip off the sorting rules, keep only the language part. */
11550 + langid = LANGIDFROMLCID (lcid);
11552 + /* Split into language and territory part. */
11553 + primary = PRIMARYLANGID (langid);
11554 + sub = SUBLANGID (langid);
11556 + /* Dispatch on language.
11557 + See also http://www.unicode.org/unicode/onlinedat/languages.html .
11558 + For details about languages, see http://www.ethnologue.com/ . */
11561 + case LANG_AFRIKAANS: return "af_ZA";
11562 + case LANG_ALBANIAN: return "sq_AL";
11563 + case LANG_AMHARIC: return "am_ET";
11564 + case LANG_ARABIC:
11567 + case SUBLANG_ARABIC_SAUDI_ARABIA: return "ar_SA";
11568 + case SUBLANG_ARABIC_IRAQ: return "ar_IQ";
11569 + case SUBLANG_ARABIC_EGYPT: return "ar_EG";
11570 + case SUBLANG_ARABIC_LIBYA: return "ar_LY";
11571 + case SUBLANG_ARABIC_ALGERIA: return "ar_DZ";
11572 + case SUBLANG_ARABIC_MOROCCO: return "ar_MA";
11573 + case SUBLANG_ARABIC_TUNISIA: return "ar_TN";
11574 + case SUBLANG_ARABIC_OMAN: return "ar_OM";
11575 + case SUBLANG_ARABIC_YEMEN: return "ar_YE";
11576 + case SUBLANG_ARABIC_SYRIA: return "ar_SY";
11577 + case SUBLANG_ARABIC_JORDAN: return "ar_JO";
11578 + case SUBLANG_ARABIC_LEBANON: return "ar_LB";
11579 + case SUBLANG_ARABIC_KUWAIT: return "ar_KW";
11580 + case SUBLANG_ARABIC_UAE: return "ar_AE";
11581 + case SUBLANG_ARABIC_BAHRAIN: return "ar_BH";
11582 + case SUBLANG_ARABIC_QATAR: return "ar_QA";
11585 + case LANG_ARMENIAN: return "hy_AM";
11586 + case LANG_ASSAMESE: return "as_IN";
11590 + /* FIXME: Adjust this when Azerbaijani locales appear on Unix. */
11591 + case SUBLANG_AZERI_LATIN: return "az_AZ@latin";
11592 + case SUBLANG_AZERI_CYRILLIC: return "az_AZ@cyrillic";
11595 + case LANG_BASQUE:
11596 + return "eu"; /* Ambiguous: could be "eu_ES" or "eu_FR". */
11597 + case LANG_BELARUSIAN: return "be_BY";
11598 + case LANG_BENGALI:
11601 + case SUBLANG_BENGALI_INDIA: return "bn_IN";
11602 + case SUBLANG_BENGALI_BANGLADESH: return "bn_BD";
11605 + case LANG_BULGARIAN: return "bg_BG";
11606 + case LANG_BURMESE: return "my_MM";
11607 + case LANG_CAMBODIAN: return "km_KH";
11608 + case LANG_CATALAN: return "ca_ES";
11609 + case LANG_CHEROKEE: return "chr_US";
11610 + case LANG_CHINESE:
11613 + case SUBLANG_CHINESE_TRADITIONAL: return "zh_TW";
11614 + case SUBLANG_CHINESE_SIMPLIFIED: return "zh_CN";
11615 + case SUBLANG_CHINESE_HONGKONG: return "zh_HK";
11616 + case SUBLANG_CHINESE_SINGAPORE: return "zh_SG";
11617 + case SUBLANG_CHINESE_MACAU: return "zh_MO";
11620 + case LANG_CROATIAN: /* LANG_CROATIAN == LANG_SERBIAN
11621 + * What used to be called Serbo-Croatian
11622 + * should really now be two separate
11623 + * languages because of political reasons.
11624 + * (Says tml, who knows nothing about Serbian
11626 + * (I can feel those flames coming already.)
11630 + case SUBLANG_DEFAULT: return "hr_HR";
11631 + case SUBLANG_SERBIAN_LATIN: return "sr_CS";
11632 + case SUBLANG_SERBIAN_CYRILLIC: return "sr_CS@cyrillic";
11635 + case LANG_CZECH: return "cs_CZ";
11636 + case LANG_DANISH: return "da_DK";
11637 + case LANG_DIVEHI: return "dv_MV";
11641 + case SUBLANG_DUTCH: return "nl_NL";
11642 + case SUBLANG_DUTCH_BELGIAN: /* FLEMISH, VLAAMS */ return "nl_BE";
11645 + case LANG_EDO: return "bin_NG";
11646 + case LANG_ENGLISH:
11649 + /* SUBLANG_ENGLISH_US == SUBLANG_DEFAULT. Heh. I thought
11650 + * English was the language spoken in England.
11653 + case SUBLANG_ENGLISH_US: return "en_US";
11654 + case SUBLANG_ENGLISH_UK: return "en_GB";
11655 + case SUBLANG_ENGLISH_AUS: return "en_AU";
11656 + case SUBLANG_ENGLISH_CAN: return "en_CA";
11657 + case SUBLANG_ENGLISH_NZ: return "en_NZ";
11658 + case SUBLANG_ENGLISH_EIRE: return "en_IE";
11659 + case SUBLANG_ENGLISH_SOUTH_AFRICA: return "en_ZA";
11660 + case SUBLANG_ENGLISH_JAMAICA: return "en_JM";
11661 + case SUBLANG_ENGLISH_CARIBBEAN: return "en_GD"; /* Grenada? */
11662 + case SUBLANG_ENGLISH_BELIZE: return "en_BZ";
11663 + case SUBLANG_ENGLISH_TRINIDAD: return "en_TT";
11664 + case SUBLANG_ENGLISH_ZIMBABWE: return "en_ZW";
11665 + case SUBLANG_ENGLISH_PHILIPPINES: return "en_PH";
11666 + case SUBLANG_ENGLISH_INDONESIA: return "en_ID";
11667 + case SUBLANG_ENGLISH_HONGKONG: return "en_HK";
11668 + case SUBLANG_ENGLISH_INDIA: return "en_IN";
11669 + case SUBLANG_ENGLISH_MALAYSIA: return "en_MY";
11670 + case SUBLANG_ENGLISH_SINGAPORE: return "en_SG";
11673 + case LANG_ESTONIAN: return "et_EE";
11674 + case LANG_FAEROESE: return "fo_FO";
11675 + case LANG_FARSI: return "fa_IR";
11676 + case LANG_FINNISH: return "fi_FI";
11677 + case LANG_FRENCH:
11680 + case SUBLANG_FRENCH: return "fr_FR";
11681 + case SUBLANG_FRENCH_BELGIAN: /* WALLOON */ return "fr_BE";
11682 + case SUBLANG_FRENCH_CANADIAN: return "fr_CA";
11683 + case SUBLANG_FRENCH_SWISS: return "fr_CH";
11684 + case SUBLANG_FRENCH_LUXEMBOURG: return "fr_LU";
11685 + case SUBLANG_FRENCH_MONACO: return "fr_MC";
11686 + case SUBLANG_FRENCH_WESTINDIES: return "fr"; /* Caribbean? */
11687 + case SUBLANG_FRENCH_REUNION: return "fr_RE";
11688 + case SUBLANG_FRENCH_CONGO: return "fr_CG";
11689 + case SUBLANG_FRENCH_SENEGAL: return "fr_SN";
11690 + case SUBLANG_FRENCH_CAMEROON: return "fr_CM";
11691 + case SUBLANG_FRENCH_COTEDIVOIRE: return "fr_CI";
11692 + case SUBLANG_FRENCH_MALI: return "fr_ML";
11693 + case SUBLANG_FRENCH_MOROCCO: return "fr_MA";
11694 + case SUBLANG_FRENCH_HAITI: return "fr_HT";
11697 + case LANG_FRISIAN: return "fy_NL";
11698 + case LANG_FULFULDE:
11699 + /* Spoken in Nigeria, Guinea, Senegal, Mali, Niger, Cameroon, Benin. */
11701 + case LANG_GAELIC:
11704 + case 0x01: /* SCOTTISH */ return "gd_GB";
11705 + case 0x02: /* IRISH */ return "ga_IE";
11708 + case LANG_GALICIAN: return "gl_ES";
11709 + case LANG_GEORGIAN: return "ka_GE";
11710 + case LANG_GERMAN:
11713 + case SUBLANG_GERMAN: return "de_DE";
11714 + case SUBLANG_GERMAN_SWISS: return "de_CH";
11715 + case SUBLANG_GERMAN_AUSTRIAN: return "de_AT";
11716 + case SUBLANG_GERMAN_LUXEMBOURG: return "de_LU";
11717 + case SUBLANG_GERMAN_LIECHTENSTEIN: return "de_LI";
11720 + case LANG_GREEK: return "el_GR";
11721 + case LANG_GUARANI: return "gn_PY";
11722 + case LANG_GUJARATI: return "gu_IN";
11723 + case LANG_HAUSA: return "ha_NG";
11724 + case LANG_HAWAIIAN:
11725 + /* FIXME: Do they mean Hawaiian ("haw_US", 1000 speakers)
11726 + or Hawaii Creole English ("cpe_US", 600000 speakers)? */
11728 + case LANG_HEBREW: return "he_IL";
11729 + case LANG_HINDI: return "hi_IN";
11730 + case LANG_HUNGARIAN: return "hu_HU";
11731 + case LANG_IBIBIO: return "nic_NG";
11732 + case LANG_ICELANDIC: return "is_IS";
11733 + case LANG_IGBO: return "ig_NG";
11734 + case LANG_INDONESIAN: return "id_ID";
11735 + case LANG_INUKTITUT: return "iu_CA";
11736 + case LANG_ITALIAN:
11739 + case SUBLANG_ITALIAN: return "it_IT";
11740 + case SUBLANG_ITALIAN_SWISS: return "it_CH";
11743 + case LANG_JAPANESE: return "ja_JP";
11744 + case LANG_KANNADA: return "kn_IN";
11745 + case LANG_KANURI: return "kr_NG";
11746 + case LANG_KASHMIRI:
11749 + case SUBLANG_DEFAULT: return "ks_PK";
11750 + case SUBLANG_KASHMIRI_INDIA: return "ks_IN";
11753 + case LANG_KAZAK: return "kk_KZ";
11754 + case LANG_KONKANI:
11755 + /* FIXME: Adjust this when such locales appear on Unix. */
11757 + case LANG_KOREAN: return "ko_KR";
11758 + case LANG_KYRGYZ: return "ky_KG";
11759 + case LANG_LAO: return "lo_LA";
11760 + case LANG_LATIN: return "la_VA";
11761 + case LANG_LATVIAN: return "lv_LV";
11762 + case LANG_LITHUANIAN: return "lt_LT";
11763 + case LANG_MACEDONIAN: return "mk_MK";
11767 + case SUBLANG_MALAY_MALAYSIA: return "ms_MY";
11768 + case SUBLANG_MALAY_BRUNEI_DARUSSALAM: return "ms_BN";
11771 + case LANG_MALAYALAM: return "ml_IN";
11772 + case LANG_MALTESE: return "mt_MT";
11773 + case LANG_MANIPURI:
11774 + /* FIXME: Adjust this when such locales appear on Unix. */
11776 + case LANG_MARATHI: return "mr_IN";
11777 + case LANG_MONGOLIAN:
11778 + return "mn"; /* Ambiguous: could be "mn_CN" or "mn_MN". */
11779 + case LANG_NEPALI:
11782 + case SUBLANG_DEFAULT: return "ne_NP";
11783 + case SUBLANG_NEPALI_INDIA: return "ne_IN";
11786 + case LANG_NORWEGIAN:
11789 + case SUBLANG_NORWEGIAN_BOKMAL: return "no_NO";
11790 + case SUBLANG_NORWEGIAN_NYNORSK: return "nn_NO";
11793 + case LANG_ORIYA: return "or_IN";
11794 + case LANG_OROMO: return "om_ET";
11795 + case LANG_PAPIAMENTU: return "pap_AN";
11796 + case LANG_PASHTO:
11797 + return "ps"; /* Ambiguous: could be "ps_PK" or "ps_AF". */
11798 + case LANG_POLISH: return "pl_PL";
11799 + case LANG_PORTUGUESE:
11802 + case SUBLANG_PORTUGUESE: return "pt_PT";
11803 + /* Hmm. SUBLANG_PORTUGUESE_BRAZILIAN == SUBLANG_DEFAULT.
11804 + Same phenomenon as SUBLANG_ENGLISH_US == SUBLANG_DEFAULT. */
11805 + case SUBLANG_PORTUGUESE_BRAZILIAN: return "pt_BR";
11808 + case LANG_PUNJABI:
11811 + case SUBLANG_PUNJABI_INDIA: return "pa_IN"; /* Gurmukhi script */
11812 + case SUBLANG_PUNJABI_PAKISTAN: return "pa_PK"; /* Arabic script */
11815 + case LANG_RHAETO_ROMANCE: return "rm_CH";
11816 + case LANG_ROMANIAN:
11819 + case SUBLANG_ROMANIAN_ROMANIA: return "ro_RO";
11820 + case SUBLANG_ROMANIAN_MOLDOVA: return "ro_MD";
11823 + case LANG_RUSSIAN:
11824 + return "ru"; /* Ambiguous: could be "ru_RU" or "ru_UA" or "ru_MD". */
11825 + case LANG_SAAMI: /* actually Northern Sami */ return "se_NO";
11826 + case LANG_SANSKRIT: return "sa_IN";
11827 + case LANG_SINDHI:
11830 + case SUBLANG_SINDHI_INDIA: return "sd_IN";
11831 + case SUBLANG_SINDHI_PAKISTAN: return "sd_PK";
11834 + case LANG_SINHALESE: return "si_LK";
11835 + case LANG_SLOVAK: return "sk_SK";
11836 + case LANG_SLOVENIAN: return "sl_SI";
11837 + case LANG_SOMALI: return "so_SO";
11838 + case LANG_SORBIAN:
11839 + /* FIXME: Adjust this when such locales appear on Unix. */
11841 + case LANG_SPANISH:
11844 + case SUBLANG_SPANISH: return "es_ES";
11845 + case SUBLANG_SPANISH_MEXICAN: return "es_MX";
11846 + case SUBLANG_SPANISH_MODERN:
11847 + return "es_ES@modern"; /* not seen on Unix */
11848 + case SUBLANG_SPANISH_GUATEMALA: return "es_GT";
11849 + case SUBLANG_SPANISH_COSTA_RICA: return "es_CR";
11850 + case SUBLANG_SPANISH_PANAMA: return "es_PA";
11851 + case SUBLANG_SPANISH_DOMINICAN_REPUBLIC: return "es_DO";
11852 + case SUBLANG_SPANISH_VENEZUELA: return "es_VE";
11853 + case SUBLANG_SPANISH_COLOMBIA: return "es_CO";
11854 + case SUBLANG_SPANISH_PERU: return "es_PE";
11855 + case SUBLANG_SPANISH_ARGENTINA: return "es_AR";
11856 + case SUBLANG_SPANISH_ECUADOR: return "es_EC";
11857 + case SUBLANG_SPANISH_CHILE: return "es_CL";
11858 + case SUBLANG_SPANISH_URUGUAY: return "es_UY";
11859 + case SUBLANG_SPANISH_PARAGUAY: return "es_PY";
11860 + case SUBLANG_SPANISH_BOLIVIA: return "es_BO";
11861 + case SUBLANG_SPANISH_EL_SALVADOR: return "es_SV";
11862 + case SUBLANG_SPANISH_HONDURAS: return "es_HN";
11863 + case SUBLANG_SPANISH_NICARAGUA: return "es_NI";
11864 + case SUBLANG_SPANISH_PUERTO_RICO: return "es_PR";
11867 + case LANG_SUTU: return "bnt_TZ"; /* or "st_LS" or "nso_ZA"? */
11868 + case LANG_SWAHILI: return "sw_KE";
11869 + case LANG_SWEDISH:
11872 + case SUBLANG_DEFAULT: return "sv_SE";
11873 + case SUBLANG_SWEDISH_FINLAND: return "sv_FI";
11876 + case LANG_SYRIAC: return "syr_TR"; /* An extinct language. */
11877 + case LANG_TAGALOG: return "tl_PH";
11878 + case LANG_TAJIK: return "tg_TJ";
11879 + case LANG_TAMAZIGHT:
11882 + /* FIXME: Adjust this when Tamazight locales appear on Unix. */
11883 + case SUBLANG_TAMAZIGHT_ARABIC: return "ber_MA@arabic";
11884 + case SUBLANG_TAMAZIGHT_LATIN: return "ber_MA@latin";
11888 + return "ta"; /* Ambiguous: could be "ta_IN" or "ta_LK" or "ta_SG". */
11889 + case LANG_TATAR: return "tt_RU";
11890 + case LANG_TELUGU: return "te_IN";
11891 + case LANG_THAI: return "th_TH";
11892 + case LANG_TIBETAN: return "bo_CN";
11893 + case LANG_TIGRINYA:
11896 + case SUBLANG_TIGRINYA_ETHIOPIA: return "ti_ET";
11897 + case SUBLANG_TIGRINYA_ERITREA: return "ti_ER";
11900 + case LANG_TSONGA: return "ts_ZA";
11901 + case LANG_TSWANA: return "tn_BW";
11902 + case LANG_TURKISH: return "tr_TR";
11903 + case LANG_TURKMEN: return "tk_TM";
11904 + case LANG_UKRAINIAN: return "uk_UA";
11908 + case SUBLANG_URDU_PAKISTAN: return "ur_PK";
11909 + case SUBLANG_URDU_INDIA: return "ur_IN";
11915 + case SUBLANG_UZBEK_LATIN: return "uz_UZ";
11916 + case SUBLANG_UZBEK_CYRILLIC: return "uz_UZ@cyrillic";
11919 + case LANG_VENDA: return "ve_ZA";
11920 + case LANG_VIETNAMESE: return "vi_VN";
11921 + case LANG_WELSH: return "cy_GB";
11922 + case LANG_XHOSA: return "xh_ZA";
11923 + case LANG_YI: return "sit_CN";
11924 + case LANG_YIDDISH: return "yi_IL";
11925 + case LANG_YORUBA: return "yo_NG";
11926 + case LANG_ZULU: return "zu_ZA";
11927 + default: return "C";
11932 --- lrzsz-0.12.20.safe/intl/log.c 1969-12-31 19:00:00.000000000 -0500
11933 +++ lrzsz-0.12.20/intl/log.c 2004-09-12 14:40:34.515723768 -0400
11935 +/* Log file output.
11936 + Copyright (C) 2003 Free Software Foundation, Inc.
11938 + This program is free software; you can redistribute it and/or modify it
11939 + under the terms of the GNU Library General Public License as published
11940 + by the Free Software Foundation; either version 2, or (at your option)
11941 + any later version.
11943 + This program is distributed in the hope that it will be useful,
11944 + but WITHOUT ANY WARRANTY; without even the implied warranty of
11945 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11946 + Library General Public License for more details.
11948 + You should have received a copy of the GNU Library General Public
11949 + License along with this program; if not, write to the Free Software
11950 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
11953 +/* Written by Bruno Haible <bruno@clisp.org>. */
11955 +#ifdef HAVE_CONFIG_H
11956 +# include <config.h>
11959 +#include <stdio.h>
11960 +#include <stdlib.h>
11961 +#include <string.h>
11963 +/* Print an ASCII string with quotes and escape sequences where needed. */
11965 +print_escaped (FILE *stream, const char *str)
11967 + putc ('"', stream);
11968 + for (; *str != '\0'; str++)
11969 + if (*str == '\n')
11971 + fputs ("\\n\"", stream);
11972 + if (str[1] == '\0')
11974 + fputs ("\n\"", stream);
11978 + if (*str == '"' || *str == '\\')
11979 + putc ('\\', stream);
11980 + putc (*str, stream);
11982 + putc ('"', stream);
11985 +/* Add to the log file an entry denoting a failed translation. */
11987 +_nl_log_untranslated (const char *logfilename, const char *domainname,
11988 + const char *msgid1, const char *msgid2, int plural)
11990 + static char *last_logfilename = NULL;
11991 + static FILE *last_logfile = NULL;
11994 + /* Can we reuse the last opened logfile? */
11995 + if (last_logfilename == NULL || strcmp (logfilename, last_logfilename) != 0)
11997 + /* Close the last used logfile. */
11998 + if (last_logfilename != NULL)
12000 + if (last_logfile != NULL)
12002 + fclose (last_logfile);
12003 + last_logfile = NULL;
12005 + free (last_logfilename);
12006 + last_logfilename = NULL;
12008 + /* Open the logfile. */
12009 + last_logfilename = (char *) malloc (strlen (logfilename) + 1);
12010 + if (last_logfilename == NULL)
12012 + strcpy (last_logfilename, logfilename);
12013 + last_logfile = fopen (logfilename, "a");
12014 + if (last_logfile == NULL)
12017 + logfile = last_logfile;
12019 + fprintf (logfile, "domain ");
12020 + print_escaped (logfile, domainname);
12021 + fprintf (logfile, "\nmsgid ");
12022 + print_escaped (logfile, msgid1);
12025 + fprintf (logfile, "\nmsgid_plural ");
12026 + print_escaped (logfile, msgid2);
12027 + fprintf (logfile, "\nmsgstr[0] \"\"\n");
12030 + fprintf (logfile, "\nmsgstr \"\"\n");
12031 + putc ('\n', logfile);
12033 --- lrzsz-0.12.20.safe/intl/Makefile.in 1998-04-26 09:22:35.000000000 -0400
12034 +++ lrzsz-0.12.20/intl/Makefile.in 2004-09-12 14:40:34.521722856 -0400
12036 -# Makefile for directory with message catalog handling in GNU NLS Utilities.
12037 -# Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
12038 +# Makefile for directory with message catalog handling library of GNU gettext
12039 +# Copyright (C) 1995-1998, 2000-2003 Free Software Foundation, Inc.
12041 -# This program is free software; you can redistribute it and/or modify
12042 -# it under the terms of the GNU General Public License as published by
12043 -# the Free Software Foundation; either version 2, or (at your option)
12044 +# This program is free software; you can redistribute it and/or modify it
12045 +# under the terms of the GNU Library General Public License as published
12046 +# by the Free Software Foundation; either version 2, or (at your option)
12047 # any later version.
12049 # This program is distributed in the hope that it will be useful,
12050 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12051 -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12052 -# GNU General Public License for more details.
12053 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12054 +# Library General Public License for more details.
12056 -# You should have received a copy of the GNU General Public License
12057 -# along with this program; if not, write to the Free Software
12058 -# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
12059 +# You should have received a copy of the GNU Library General Public
12060 +# License along with this program; if not, write to the Free Software
12061 +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
12064 PACKAGE = @PACKAGE@
12065 VERSION = @VERSION@
12066 @@ -23,118 +24,341 @@
12068 top_srcdir = @top_srcdir@
12071 +#VPATH = $(srcdir)
12074 exec_prefix = @exec_prefix@
12075 transform = @program_transform_name@
12076 -libdir = $(exec_prefix)/lib
12077 -includedir = $(prefix)/include
12078 -datadir = $(prefix)/@DATADIRNAME@
12080 +includedir = @includedir@
12081 +datadir = @datadir@
12082 localedir = $(datadir)/locale
12083 -gnulocaledir = $(prefix)/share/locale
12084 -gettextsrcdir = @datadir@/gettext/intl
12085 -aliaspath = $(localedir):.
12086 +gettextsrcdir = $(datadir)/gettext/intl
12087 +aliaspath = $(localedir)
12090 INSTALL = @INSTALL@
12091 INSTALL_DATA = @INSTALL_DATA@
12092 MKINSTALLDIRS = @MKINSTALLDIRS@
12093 +mkinstalldirs = $(SHELL) $(MKINSTALLDIRS)
12096 +l = @INTL_LIBTOOL_SUFFIX_PREFIX@
12100 LIBTOOL = @LIBTOOL@
12102 +YACC = @INTLBISON@ -y -d
12103 +YFLAGS = --name-prefix=__gettext
12105 -DEFS = -DLOCALEDIR=\"$(localedir)\" -DGNULOCALEDIR=\"$(gnulocaledir)\" \
12106 --DLOCALE_ALIAS_PATH=\"$(aliaspath)\" @DEFS@
12107 +DEFS = -DLOCALEDIR=\"$(localedir)\" -DLOCALE_ALIAS_PATH=\"$(aliaspath)\" \
12108 +-DLIBDIR=\"$(libdir)\" -DIN_LIBINTL \
12109 +-DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"$(libdir)\" -DNO_XMALLOC \
12110 +-Dset_relocation_prefix=libintl_set_relocation_prefix \
12111 +-Drelocate=libintl_relocate \
12112 +-DDEPENDS_ON_LIBICONV=1 @DEFS@
12113 CPPFLAGS = @CPPFLAGS@
12115 LDFLAGS = @LDFLAGS@
12118 COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) $(XCFLAGS)
12120 -HEADERS = $(COMHDRS) libgettext.h loadinfo.h
12121 -COMHDRS = gettext.h gettextP.h hash-string.h
12122 -SOURCES = $(COMSRCS) intl-compat.c cat-compat.c
12123 -COMSRCS = bindtextdom.c dcgettext.c dgettext.c gettext.c \
12124 -finddomain.c loadmsgcat.c localealias.c textdomain.c l10nflist.c \
12126 -OBJECTS = @INTLOBJS@ bindtextdom.$lo dcgettext.$lo dgettext.$lo gettext.$lo \
12127 -finddomain.$lo loadmsgcat.$lo localealias.$lo textdomain.$lo l10nflist.$lo \
12129 -CATOBJS = cat-compat.$lo ../po/cat-id-tbl.$lo
12130 -GETTOBJS = intl-compat.$lo
12131 -DISTFILES.common = ChangeLog Makefile.in linux-msg.sed po2tbl.sed.in \
12132 -xopen-msg.sed $(HEADERS) $(SOURCES)
12143 + printf-args.h printf-args.c \
12144 + printf-parse.h wprintf-parse.h printf-parse.c \
12145 + vasnprintf.h vasnwprintf.h vasnprintf.c \
12174 + bindtextdom.$lo \
12180 + localealias.$lo \
12183 + explodename.$lo \
12190 + localcharset.$lo \
12191 + relocatable.$lo \
12197 +DISTFILES.common = Makefile.in \
12198 +config.charset locale.alias ref-add.sin ref-del.sin $(HEADERS) $(SOURCES)
12199 +DISTFILES.generated = plural.c
12200 DISTFILES.normal = VERSION
12201 -DISTFILES.gettext = libintl.glibc intlh.inst.in
12202 +DISTFILES.gettext = COPYING.LIB-2.0 COPYING.LIB-2.1 libintl.glibc \
12203 +libgnuintl.h_vms Makefile.vms \
12204 +libgnuintl.h.msvc-static libgnuintl.h.msvc-shared README.woe32 Makefile.msvc
12205 +DISTFILES.obsolete = xopen-msg.sed linux-msg.sed po2tbl.sed.in cat-compat.c \
12206 +COPYING.LIB-2 gettext.h libgettext.h plural-eval.c libgnuintl.h
12208 +all: all-@USE_INCLUDED_LIBINTL@
12209 +all-yes: libintl.$la libintl.h charset.alias ref-add.sed ref-del.sed
12210 +all-no: all-no-@BUILD_INCLUDED_LIBINTL@
12211 +all-no-yes: libgnuintl.$la
12214 +libintl.a libgnuintl.a: $(OBJECTS)
12216 + $(AR) cru $@ $(OBJECTS)
12219 +libintl.la libgnuintl.la: $(OBJECTS)
12220 + $(LIBTOOL) --mode=link \
12221 + $(CC) $(CPPFLAGS) $(CFLAGS) $(XCFLAGS) $(LDFLAGS) -o $@ \
12222 + $(OBJECTS) @LTLIBICONV@ $(LIBS) -lc \
12223 + -version-info $(LTV_CURRENT):$(LTV_REVISION):$(LTV_AGE) \
12224 + -rpath $(libdir) \
12227 +# Libtool's library version information for libintl.
12228 +# Before making a gettext release, the gettext maintainer must change this
12229 +# according to the libtool documentation, section "Library interface versions".
12230 +# Maintainers of other packages that include the intl directory must *not*
12231 +# change these values.
12237 -.SUFFIXES: .c .o .lo
12238 +.SUFFIXES: .c .y .o .lo .sin .sed
12243 - $(LIBTOOL) --mode=compile $(COMPILE) $<
12245 -INCLUDES = -I.. -I. -I$(top_srcdir)/intl -I$(top_srcdir)/lib
12247 + $(YACC) $(YFLAGS) --output $@ $<
12250 -all: all-@USE_INCLUDED_LIBINTL@
12251 +bindtextdom.lo: $(srcdir)/bindtextdom.c
12252 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/bindtextdom.c
12253 +dcgettext.lo: $(srcdir)/dcgettext.c
12254 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/dcgettext.c
12255 +dgettext.lo: $(srcdir)/dgettext.c
12256 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/dgettext.c
12257 +gettext.lo: $(srcdir)/gettext.c
12258 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/gettext.c
12259 +finddomain.lo: $(srcdir)/finddomain.c
12260 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/finddomain.c
12261 +loadmsgcat.lo: $(srcdir)/loadmsgcat.c
12262 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/loadmsgcat.c
12263 +localealias.lo: $(srcdir)/localealias.c
12264 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/localealias.c
12265 +textdomain.lo: $(srcdir)/textdomain.c
12266 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/textdomain.c
12267 +l10nflist.lo: $(srcdir)/l10nflist.c
12268 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/l10nflist.c
12269 +explodename.lo: $(srcdir)/explodename.c
12270 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/explodename.c
12271 +dcigettext.lo: $(srcdir)/dcigettext.c
12272 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/dcigettext.c
12273 +dcngettext.lo: $(srcdir)/dcngettext.c
12274 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/dcngettext.c
12275 +dngettext.lo: $(srcdir)/dngettext.c
12276 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/dngettext.c
12277 +ngettext.lo: $(srcdir)/ngettext.c
12278 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/ngettext.c
12279 +plural.lo: $(srcdir)/plural.c
12280 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/plural.c
12281 +plural-exp.lo: $(srcdir)/plural-exp.c
12282 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/plural-exp.c
12283 +localcharset.lo: $(srcdir)/localcharset.c
12284 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/localcharset.c
12285 +relocatable.lo: $(srcdir)/relocatable.c
12286 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/relocatable.c
12287 +localename.lo: $(srcdir)/localename.c
12288 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/localename.c
12289 +log.lo: $(srcdir)/log.c
12290 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/log.c
12291 +printf.lo: $(srcdir)/printf.c
12292 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/printf.c
12293 +osdep.lo: $(srcdir)/osdep.c
12294 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/osdep.c
12295 +intl-compat.lo: $(srcdir)/intl-compat.c
12296 + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/intl-compat.c
12298 -all-yes: libintl.$la intlh.inst
12300 +ref-add.sed: $(srcdir)/ref-add.sin
12301 + sed -e '/^#/d' -e 's/@''PACKAGE''@/@PACKAGE@/g' $(srcdir)/ref-add.sin > t-ref-add.sed
12302 + mv t-ref-add.sed ref-add.sed
12303 +ref-del.sed: $(srcdir)/ref-del.sin
12304 + sed -e '/^#/d' -e 's/@''PACKAGE''@/@PACKAGE@/g' $(srcdir)/ref-del.sin > t-ref-del.sed
12305 + mv t-ref-del.sed ref-del.sed
12307 -libintl.a: $(OBJECTS)
12309 - $(AR) cru $@ $(OBJECTS)
12311 +INCLUDES = -I. -I$(srcdir) -I..
12313 -libintl.la: $(OBJECTS)
12314 - $(LIBTOOL) --mode=link $(CC) $(LDFLAGS) -o $@ $(OBJECTS) \
12315 - -version-info 1:0 -rpath $(libdir)
12316 +libgnuintl.h: $(srcdir)/libgnuintl.h.in
12317 + sed -e 's,@''HAVE_POSIX_PRINTF''@,@HAVE_POSIX_PRINTF@,g' \
12318 + -e 's,@''HAVE_ASPRINTF''@,@HAVE_ASPRINTF@,g' \
12319 + -e 's,@''HAVE_SNPRINTF''@,@HAVE_SNPRINTF@,g' \
12320 + -e 's,@''HAVE_WPRINTF''@,@HAVE_WPRINTF@,g' \
12321 + < $(srcdir)/libgnuintl.h.in > libgnuintl.h
12323 -../po/cat-id-tbl.$lo: ../po/cat-id-tbl.c $(top_srcdir)/po/$(PACKAGE).pot
12324 - cd ../po && $(MAKE) cat-id-tbl.$lo
12325 +libintl.h: libgnuintl.h
12326 + cp libgnuintl.h libintl.h
12329 +charset.alias: $(srcdir)/config.charset
12330 + $(SHELL) $(srcdir)/config.charset '@host@' > t-$@
12333 -# This installation goal is only used in GNU gettext. Packages which
12334 -# only use the library should use install instead.
12337 # We must not install the libintl.h/libintl.a files if we are on a
12338 -# system which has the gettext() function in its C library or in a
12339 -# separate library or use the catgets interface. A special case is
12340 -# where configure found a previously installed GNU gettext library.
12341 +# system which has the GNU gettext() function in its C library or in a
12342 +# separate library.
12343 # If you want to use the one which comes with this version of the
12344 # package, you have to use `configure --with-included-gettext'.
12345 install: install-exec install-data
12347 - if test "$(PACKAGE)" = "gettext" \
12348 - && test '@INTLOBJS@' = '$(GETTOBJS)'; then \
12349 - if test -r $(MKINSTALLDIRS); then \
12350 - $(MKINSTALLDIRS) $(libdir) $(includedir); \
12352 - $(top_srcdir)/mkinstalldirs $(libdir) $(includedir); \
12353 + if { test "$(PACKAGE)" = "gettext-runtime" || test "$(PACKAGE)" = "gettext-tools"; } \
12354 + && test '@USE_INCLUDED_LIBINTL@' = yes; then \
12355 + $(mkinstalldirs) $(DESTDIR)$(libdir) $(DESTDIR)$(includedir); \
12356 + $(INSTALL_DATA) libintl.h $(DESTDIR)$(includedir)/libintl.h; \
12357 + $(LIBTOOL) --mode=install \
12358 + $(INSTALL_DATA) libintl.$la $(DESTDIR)$(libdir)/libintl.$la; \
12359 + if test "@RELOCATABLE@" = yes; then \
12360 + dependencies=`sed -n -e 's,^dependency_libs=\(.*\),\1,p' < $(DESTDIR)$(libdir)/libintl.la | sed -e "s,^',," -e "s,'\$$,,"`; \
12361 + if test -n "$$dependencies"; then \
12362 + rm -f $(DESTDIR)$(libdir)/libintl.la; \
12365 - $(INSTALL_DATA) intlh.inst $(includedir)/libintl.h; \
12366 - $(INSTALL_DATA) libintl.a $(libdir)/libintl.a; \
12371 - if test "$(PACKAGE)" = "gettext"; then \
12372 - if test -r $(MKINSTALLDIRS); then \
12373 - $(MKINSTALLDIRS) $(gettextsrcdir); \
12374 + if test "$(PACKAGE)" = "gettext-tools" \
12375 + && test '@USE_INCLUDED_LIBINTL@' = no; then \
12376 + $(mkinstalldirs) $(DESTDIR)$(libdir); \
12377 + $(LIBTOOL) --mode=install \
12378 + $(INSTALL_DATA) libgnuintl.$la $(DESTDIR)$(libdir)/libgnuintl.$la; \
12379 + rm -f $(DESTDIR)$(libdir)/preloadable_libintl.so; \
12380 + $(INSTALL_DATA) $(DESTDIR)$(libdir)/libgnuintl.so $(DESTDIR)$(libdir)/preloadable_libintl.so; \
12381 + $(LIBTOOL) --mode=uninstall \
12382 + rm -f $(DESTDIR)$(libdir)/libgnuintl.$la; \
12386 + if test '@USE_INCLUDED_LIBINTL@' = yes; then \
12387 + test @GLIBC21@ != no || $(mkinstalldirs) $(DESTDIR)$(libdir); \
12388 + temp=$(DESTDIR)$(libdir)/t-charset.alias; \
12389 + dest=$(DESTDIR)$(libdir)/charset.alias; \
12390 + if test -f $(DESTDIR)$(libdir)/charset.alias; then \
12391 + orig=$(DESTDIR)$(libdir)/charset.alias; \
12392 + sed -f ref-add.sed $$orig > $$temp; \
12393 + $(INSTALL_DATA) $$temp $$dest; \
12396 - $(top_srcdir)/mkinstalldirs $(gettextsrcdir); \
12397 + if test @GLIBC21@ = no; then \
12398 + orig=charset.alias; \
12399 + sed -f ref-add.sed $$orig > $$temp; \
12400 + $(INSTALL_DATA) $$temp $$dest; \
12404 - $(INSTALL_DATA) VERSION $(gettextsrcdir)/VERSION; \
12405 - dists="$(DISTFILES.common)"; \
12406 + $(mkinstalldirs) $(DESTDIR)$(localedir); \
12407 + test -f $(DESTDIR)$(localedir)/locale.alias \
12408 + && orig=$(DESTDIR)$(localedir)/locale.alias \
12409 + || orig=$(srcdir)/locale.alias; \
12410 + temp=$(DESTDIR)$(localedir)/t-locale.alias; \
12411 + dest=$(DESTDIR)$(localedir)/locale.alias; \
12412 + sed -f ref-add.sed $$orig > $$temp; \
12413 + $(INSTALL_DATA) $$temp $$dest; \
12419 + if test "$(PACKAGE)" = "gettext-tools"; then \
12420 + $(mkinstalldirs) $(DESTDIR)$(gettextsrcdir); \
12421 + $(INSTALL_DATA) VERSION $(DESTDIR)$(gettextsrcdir)/VERSION; \
12422 + $(INSTALL_DATA) ChangeLog.inst $(DESTDIR)$(gettextsrcdir)/ChangeLog; \
12423 + dists="COPYING.LIB-2.0 COPYING.LIB-2.1 $(DISTFILES.common)"; \
12424 for file in $$dists; do \
12425 - $(INSTALL_DATA) $(srcdir)/$$file $(gettextsrcdir)/$$file; \
12426 + $(INSTALL_DATA) $(srcdir)/$$file \
12427 + $(DESTDIR)$(gettextsrcdir)/$$file; \
12429 + chmod a+x $(DESTDIR)$(gettextsrcdir)/config.charset; \
12430 + dists="$(DISTFILES.generated)"; \
12431 + for file in $$dists; do \
12432 + if test -f $$file; then dir=.; else dir=$(srcdir); fi; \
12433 + $(INSTALL_DATA) $$dir/$$file \
12434 + $(DESTDIR)$(gettextsrcdir)/$$file; \
12436 + dists="$(DISTFILES.obsolete)"; \
12437 + for file in $$dists; do \
12438 + rm -f $(DESTDIR)$(gettextsrcdir)/$$file; \
12444 +install-strip: install
12447 + if { test "$(PACKAGE)" = "gettext-runtime" || test "$(PACKAGE)" = "gettext-tools"; } \
12448 + && test '@USE_INCLUDED_LIBINTL@' = yes; then \
12449 + $(mkinstalldirs) $(DESTDIR)$(libdir) $(DESTDIR)$(includedir); \
12453 + if test "$(PACKAGE)" = "gettext-tools" \
12454 + && test '@USE_INCLUDED_LIBINTL@' = no; then \
12455 + $(mkinstalldirs) $(DESTDIR)$(libdir); \
12459 + if test '@USE_INCLUDED_LIBINTL@' = yes; then \
12460 + test @GLIBC21@ != no || $(mkinstalldirs) $(DESTDIR)$(libdir); \
12461 + $(mkinstalldirs) $(DESTDIR)$(localedir); \
12465 + if test "$(PACKAGE)" = "gettext-tools"; then \
12466 + $(mkinstalldirs) $(DESTDIR)$(gettextsrcdir); \
12470 @@ -143,22 +367,76 @@
12474 - dists="$(DISTFILES.common)"; \
12475 - for file in $$dists; do \
12476 - rm -f $(gettextsrcdir)/$$file; \
12478 + if { test "$(PACKAGE)" = "gettext-runtime" || test "$(PACKAGE)" = "gettext-tools"; } \
12479 + && test '@USE_INCLUDED_LIBINTL@' = yes; then \
12480 + rm -f $(DESTDIR)$(includedir)/libintl.h; \
12481 + $(LIBTOOL) --mode=uninstall \
12482 + rm -f $(DESTDIR)$(libdir)/libintl.$la; \
12486 + if test "$(PACKAGE)" = "gettext-tools" \
12487 + && test '@USE_INCLUDED_LIBINTL@' = no; then \
12488 + rm -f $(DESTDIR)$(libdir)/preloadable_libintl.so; \
12492 + if test '@USE_INCLUDED_LIBINTL@' = yes; then \
12493 + if test -f $(DESTDIR)$(libdir)/charset.alias; then \
12494 + temp=$(DESTDIR)$(libdir)/t-charset.alias; \
12495 + dest=$(DESTDIR)$(libdir)/charset.alias; \
12496 + sed -f ref-del.sed $$dest > $$temp; \
12497 + if grep '^# Packages using this file: $$' $$temp > /dev/null; then \
12500 + $(INSTALL_DATA) $$temp $$dest; \
12504 + if test -f $(DESTDIR)$(localedir)/locale.alias; then \
12505 + temp=$(DESTDIR)$(localedir)/t-locale.alias; \
12506 + dest=$(DESTDIR)$(localedir)/locale.alias; \
12507 + sed -f ref-del.sed $$dest > $$temp; \
12508 + if grep '^# Packages using this file: $$' $$temp > /dev/null; then \
12511 + $(INSTALL_DATA) $$temp $$dest; \
12518 + if test "$(PACKAGE)" = "gettext-tools"; then \
12519 + for file in VERSION ChangeLog COPYING.LIB-2.0 COPYING.LIB-2.1 $(DISTFILES.common) $(DISTFILES.generated); do \
12520 + rm -f $(DESTDIR)$(gettextsrcdir)/$$file; \
12527 +info dvi ps pdf html:
12529 -$(OBJECTS): ../config.h libgettext.h
12530 -bindtextdom.$lo finddomain.$lo loadmsgcat.$lo: gettextP.h gettext.h loadinfo.h
12531 -dcgettext.$lo: gettextP.h gettext.h hash-string.h loadinfo.h
12532 +$(OBJECTS): ../config.h libgnuintl.h
12533 +bindtextdom.$lo dcgettext.$lo dcigettext.$lo dcngettext.$lo dgettext.$lo dngettext.$lo finddomain.$lo gettext.$lo intl-compat.$lo loadmsgcat.$lo localealias.$lo ngettext.$lo textdomain.$lo: $(srcdir)/gettextP.h $(srcdir)/gmo.h $(srcdir)/loadinfo.h
12534 +dcigettext.$lo loadmsgcat.$lo: $(srcdir)/hash-string.h
12535 +explodename.$lo l10nflist.$lo: $(srcdir)/loadinfo.h
12536 +dcigettext.$lo loadmsgcat.$lo plural.$lo plural-exp.$lo: $(srcdir)/plural-exp.h
12537 +dcigettext.$lo: $(srcdir)/eval-plural.h
12538 +localcharset.$lo: $(srcdir)/localcharset.h
12539 +localealias.$lo localcharset.$lo relocatable.$lo: $(srcdir)/relocatable.h
12540 +printf.$lo: $(srcdir)/printf-args.h $(srcdir)/printf-args.c $(srcdir)/printf-parse.h $(srcdir)/wprintf-parse.h $(srcdir)/xsize.h $(srcdir)/printf-parse.c $(srcdir)/vasnprintf.h $(srcdir)/vasnwprintf.h $(srcdir)/vasnprintf.c
12544 TAGS: $(HEADERS) $(SOURCES)
12545 here=`pwd`; cd $(srcdir) && etags -o $$here/TAGS $(HEADERS) $(SOURCES)
12549 +CTAGS: $(HEADERS) $(SOURCES)
12550 + here=`pwd`; cd $(srcdir) && ctags -o $$here/CTAGS $(HEADERS) $(SOURCES)
12554 ID: $(HEADERS) $(SOURCES)
12555 @@ -166,12 +444,19 @@
12559 - rm -f *.a *.o *.lo core core.*
12560 + rm -f *.a *.la *.o *.obj *.lo core core.*
12561 + rm -f libgnuintl.h libintl.h charset.alias ref-add.sed ref-del.sed
12562 + rm -f -r .libs _libs
12567 - rm -f Makefile ID TAGS po2msg.sed po2tbl.sed libintl.h
12568 + rm -f Makefile ID TAGS
12569 + if test "$(PACKAGE)" = "gettext-runtime" || test "$(PACKAGE)" = "gettext-tools"; then \
12570 + rm -f ChangeLog.inst $(DISTFILES.normal); \
12575 maintainer-clean: distclean
12576 @echo "This command is intended for maintainers to use;"
12577 @@ -181,33 +466,27 @@
12578 # GNU gettext needs not contain the file `VERSION' but contains some
12579 # other files which should not be distributed in other packages.
12580 distdir = ../$(PACKAGE)-$(VERSION)/$(subdir)
12581 -dist distdir: Makefile $(DISTFILES)
12582 - if test "$(PACKAGE)" = gettext; then \
12583 - additional="$(DISTFILES.gettext)"; \
12584 +dist distdir: Makefile
12585 + if test "$(PACKAGE)" = "gettext-tools"; then \
12588 - additional="$(DISTFILES.normal)"; \
12590 - for file in $(DISTFILES.common) $$additional; do \
12591 - ln $(srcdir)/$$file $(distdir) 2> /dev/null \
12592 - || cp -p $(srcdir)/$$file $(distdir); \
12596 - tar zcvf intl-glibc.tar.gz $(COMSRCS) $(COMHDRS) libintl.h.glibc
12598 -Makefile: Makefile.in ../config.status
12600 - && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
12601 + if test "$(PACKAGE)" = "gettext-runtime"; then \
12602 + additional="$(DISTFILES.gettext)"; \
12604 + additional="$(DISTFILES.normal)"; \
12606 + $(MAKE) $(DISTFILES.common) $(DISTFILES.generated) $$additional; \
12607 + for file in ChangeLog $(DISTFILES.common) $(DISTFILES.generated) $$additional; do \
12608 + if test -f $$file; then dir=.; else dir=$(srcdir); fi; \
12609 + cp -p $$dir/$$file $(distdir); \
12613 -# The dependency for intlh.inst is different in gettext and all other
12614 -# packages. Because we cannot you GNU make features we have to solve
12615 -# the problem while rewriting Makefile.in.
12616 -@GT_YES@intlh.inst: intlh.inst.in ../config.status
12618 -@GT_YES@ && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= \
12619 -@GT_YES@ $(SHELL) ./config.status
12620 -@GT_NO@.PHONY: intlh.inst
12621 -@GT_NO@intlh.inst:
12622 +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
12623 + cd $(top_builddir) && $(SHELL) ./config.status
12624 +# This would be more efficient, but doesn't work any more with autoconf-2.57,
12625 +# when AC_CONFIG_FILES([intl/Makefile:somedir/Makefile.in]) is used.
12626 +# cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
12628 # Tell versions [3.59,3.63) of GNU make not to export all variables.
12629 # Otherwise a system limit (for SysV at least) may be exceeded.
12630 --- lrzsz-0.12.20.safe/intl/ngettext.c 1969-12-31 19:00:00.000000000 -0500
12631 +++ lrzsz-0.12.20/intl/ngettext.c 2004-09-12 14:40:34.533721032 -0400
12633 +/* Implementation of ngettext(3) function.
12634 + Copyright (C) 1995, 1997, 2000-2003 Free Software Foundation, Inc.
12636 + This program is free software; you can redistribute it and/or modify it
12637 + under the terms of the GNU Library General Public License as published
12638 + by the Free Software Foundation; either version 2, or (at your option)
12639 + any later version.
12641 + This program is distributed in the hope that it will be useful,
12642 + but WITHOUT ANY WARRANTY; without even the implied warranty of
12643 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12644 + Library General Public License for more details.
12646 + You should have received a copy of the GNU Library General Public
12647 + License along with this program; if not, write to the Free Software
12648 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
12651 +#ifdef HAVE_CONFIG_H
12652 +# include <config.h>
12656 +# define __need_NULL
12657 +# include <stddef.h>
12659 +# include <stdlib.h> /* Just for NULL. */
12662 +#include "gettextP.h"
12664 +# include <libintl.h>
12666 +# include "libgnuintl.h"
12669 +#include <locale.h>
12671 +/* @@ end of prolog @@ */
12673 +/* Names for the libintl functions are a problem. They must not clash
12674 + with existing names and they should follow ANSI C. But this source
12675 + code is also used in GNU C Library where the names have a __
12676 + prefix. So we have to make a difference here. */
12678 +# define NGETTEXT __ngettext
12679 +# define DCNGETTEXT __dcngettext
12681 +# define NGETTEXT libintl_ngettext
12682 +# define DCNGETTEXT libintl_dcngettext
12685 +/* Look up MSGID in the current default message catalog for the current
12686 + LC_MESSAGES locale. If not found, returns MSGID itself (the default
12689 +NGETTEXT (const char *msgid1, const char *msgid2, unsigned long int n)
12691 + return DCNGETTEXT (NULL, msgid1, msgid2, n, LC_MESSAGES);
12695 +/* Alias for function name in GNU C Library. */
12696 +weak_alias (__ngettext, ngettext);
12698 --- lrzsz-0.12.20.safe/intl/os2compat.c 1969-12-31 19:00:00.000000000 -0500
12699 +++ lrzsz-0.12.20/intl/os2compat.c 2004-09-12 14:40:34.539720120 -0400
12701 +/* OS/2 compatibility functions.
12702 + Copyright (C) 2001-2002 Free Software Foundation, Inc.
12704 + This program is free software; you can redistribute it and/or modify it
12705 + under the terms of the GNU Library General Public License as published
12706 + by the Free Software Foundation; either version 2, or (at your option)
12707 + any later version.
12709 + This program is distributed in the hope that it will be useful,
12710 + but WITHOUT ANY WARRANTY; without even the implied warranty of
12711 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12712 + Library General Public License for more details.
12714 + You should have received a copy of the GNU Library General Public
12715 + License along with this program; if not, write to the Free Software
12716 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
12720 +#ifdef HAVE_CONFIG_H
12721 +#include <config.h>
12724 +#include <stdlib.h>
12725 +#include <string.h>
12726 +#include <sys/param.h>
12728 +/* A version of getenv() that works from DLLs */
12729 +extern unsigned long DosScanEnv (const unsigned char *pszName, unsigned char **ppszValue);
12732 +_nl_getenv (const char *name)
12734 + unsigned char *value;
12735 + if (DosScanEnv (name, &value))
12741 +/* A fixed size buffer. */
12742 +char libintl_nl_default_dirname[MAXPATHLEN+1];
12744 +char *_nlos2_libdir = NULL;
12745 +char *_nlos2_localealiaspath = NULL;
12746 +char *_nlos2_localedir = NULL;
12748 +static __attribute__((constructor)) void
12749 +nlos2_initialize ()
12751 + char *root = getenv ("UNIXROOT");
12752 + char *gnulocaledir = getenv ("GNULOCALEDIR");
12754 + _nlos2_libdir = gnulocaledir;
12755 + if (!_nlos2_libdir)
12759 + size_t sl = strlen (root);
12760 + _nlos2_libdir = (char *) malloc (sl + strlen (LIBDIR) + 1);
12761 + memcpy (_nlos2_libdir, root, sl);
12762 + memcpy (_nlos2_libdir + sl, LIBDIR, strlen (LIBDIR) + 1);
12765 + _nlos2_libdir = LIBDIR;
12768 + _nlos2_localealiaspath = gnulocaledir;
12769 + if (!_nlos2_localealiaspath)
12773 + size_t sl = strlen (root);
12774 + _nlos2_localealiaspath = (char *) malloc (sl + strlen (LOCALE_ALIAS_PATH) + 1);
12775 + memcpy (_nlos2_localealiaspath, root, sl);
12776 + memcpy (_nlos2_localealiaspath + sl, LOCALE_ALIAS_PATH, strlen (LOCALE_ALIAS_PATH) + 1);
12779 + _nlos2_localealiaspath = LOCALE_ALIAS_PATH;
12782 + _nlos2_localedir = gnulocaledir;
12783 + if (!_nlos2_localedir)
12787 + size_t sl = strlen (root);
12788 + _nlos2_localedir = (char *) malloc (sl + strlen (LOCALEDIR) + 1);
12789 + memcpy (_nlos2_localedir, root, sl);
12790 + memcpy (_nlos2_localedir + sl, LOCALEDIR, strlen (LOCALEDIR) + 1);
12793 + _nlos2_localedir = LOCALEDIR;
12796 + if (strlen (_nlos2_localedir) <= MAXPATHLEN)
12797 + strcpy (libintl_nl_default_dirname, _nlos2_localedir);
12799 --- lrzsz-0.12.20.safe/intl/os2compat.h 1969-12-31 19:00:00.000000000 -0500
12800 +++ lrzsz-0.12.20/intl/os2compat.h 2004-09-12 14:40:34.544719360 -0400
12802 +/* OS/2 compatibility defines.
12803 + This file is intended to be included from config.h
12804 + Copyright (C) 2001-2002 Free Software Foundation, Inc.
12806 + This program is free software; you can redistribute it and/or modify it
12807 + under the terms of the GNU Library General Public License as published
12808 + by the Free Software Foundation; either version 2, or (at your option)
12809 + any later version.
12811 + This program is distributed in the hope that it will be useful,
12812 + but WITHOUT ANY WARRANTY; without even the implied warranty of
12813 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12814 + Library General Public License for more details.
12816 + You should have received a copy of the GNU Library General Public
12817 + License along with this program; if not, write to the Free Software
12818 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
12821 +/* When included from os2compat.h we need all the original definitions */
12825 +#define LIBDIR _nlos2_libdir
12826 +extern char *_nlos2_libdir;
12829 +#define LOCALEDIR _nlos2_localedir
12830 +extern char *_nlos2_localedir;
12832 +#undef LOCALE_ALIAS_PATH
12833 +#define LOCALE_ALIAS_PATH _nlos2_localealiaspath
12834 +extern char *_nlos2_localealiaspath;
12838 +#undef HAVE_STRCASECMP
12839 +#define HAVE_STRCASECMP 1
12840 +#define strcasecmp stricmp
12841 +#define strncasecmp strnicmp
12843 +/* We have our own getenv() which works even if library is compiled as DLL */
12844 +#define getenv _nl_getenv
12846 +/* Older versions of gettext used -1 as the value of LC_MESSAGES */
12847 +#define LC_MESSAGES_COMPAT (-1)
12848 --- lrzsz-0.12.20.safe/intl/osdep.c 1969-12-31 19:00:00.000000000 -0500
12849 +++ lrzsz-0.12.20/intl/osdep.c 2004-09-12 14:40:34.550718448 -0400
12851 +/* OS dependent parts of libintl.
12852 + Copyright (C) 2001-2002 Free Software Foundation, Inc.
12854 + This program is free software; you can redistribute it and/or modify it
12855 + under the terms of the GNU Library General Public License as published
12856 + by the Free Software Foundation; either version 2, or (at your option)
12857 + any later version.
12859 + This program is distributed in the hope that it will be useful,
12860 + but WITHOUT ANY WARRANTY; without even the implied warranty of
12861 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12862 + Library General Public License for more details.
12864 + You should have received a copy of the GNU Library General Public
12865 + License along with this program; if not, write to the Free Software
12866 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
12869 +#if defined __EMX__
12870 +# include "os2compat.c"
12872 +/* Avoid AIX compiler warning. */
12873 +typedef int dummy;
12875 --- lrzsz-0.12.20.safe/intl/plural.c 1969-12-31 19:00:00.000000000 -0500
12876 +++ lrzsz-0.12.20/intl/plural.c 2004-09-12 14:40:36.571411256 -0400
12878 +/* A Bison parser, made from plural.y
12879 + by GNU bison 1.35. */
12881 +#define YYBISON 1 /* Identify Bison output. */
12883 +#define yyparse __gettextparse
12884 +#define yylex __gettextlex
12885 +#define yyerror __gettexterror
12886 +#define yylval __gettextlval
12887 +#define yychar __gettextchar
12888 +#define yydebug __gettextdebug
12889 +#define yynerrs __gettextnerrs
12890 +# define EQUOP2 257
12891 +# define CMPOP2 258
12892 +# define ADDOP2 259
12893 +# define MULOP2 260
12894 +# define NUMBER 261
12896 +#line 1 "plural.y"
12898 +/* Expression parsing for plural form selection.
12899 + Copyright (C) 2000-2001, 2003 Free Software Foundation, Inc.
12900 + Written by Ulrich Drepper <drepper@cygnus.com>, 2000.
12902 + This program is free software; you can redistribute it and/or modify it
12903 + under the terms of the GNU Library General Public License as published
12904 + by the Free Software Foundation; either version 2, or (at your option)
12905 + any later version.
12907 + This program is distributed in the hope that it will be useful,
12908 + but WITHOUT ANY WARRANTY; without even the implied warranty of
12909 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12910 + Library General Public License for more details.
12912 + You should have received a copy of the GNU Library General Public
12913 + License along with this program; if not, write to the Free Software
12914 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
12917 +/* The bison generated parser uses alloca. AIX 3 forces us to put this
12918 + declaration at the beginning of the file. The declaration in bison's
12919 + skeleton file comes too late. This must come before <config.h>
12920 + because <config.h> may include arbitrary system headers. */
12921 +#if defined _AIX && !defined __GNUC__
12925 +#ifdef HAVE_CONFIG_H
12926 +# include <config.h>
12929 +#include <stddef.h>
12930 +#include <stdlib.h>
12931 +#include "plural-exp.h"
12933 +/* The main function generated by the parser is called __gettextparse,
12934 + but we want it to be called PLURAL_PARSE. */
12936 +# define __gettextparse PLURAL_PARSE
12939 +#define YYLEX_PARAM &((struct parse_args *) arg)->cp
12940 +#define YYPARSE_PARAM arg
12942 +#line 49 "plural.y"
12945 + unsigned long int num;
12946 + enum operator op;
12947 + struct expression *exp;
12949 +# define YYSTYPE yystype
12950 +# define YYSTYPE_IS_TRIVIAL 1
12952 +#line 55 "plural.y"
12954 +/* Prototypes for local functions. */
12955 +static int yylex (YYSTYPE *lval, const char **pexp);
12956 +static void yyerror (const char *str);
12958 +/* Allocation of expressions. */
12960 +static struct expression *
12961 +new_exp (int nargs, enum operator op, struct expression * const *args)
12964 + struct expression *newp;
12966 + /* If any of the argument could not be malloc'ed, just return NULL. */
12967 + for (i = nargs - 1; i >= 0; i--)
12968 + if (args[i] == NULL)
12971 + /* Allocate a new expression. */
12972 + newp = (struct expression *) malloc (sizeof (*newp));
12973 + if (newp != NULL)
12975 + newp->nargs = nargs;
12976 + newp->operation = op;
12977 + for (i = nargs - 1; i >= 0; i--)
12978 + newp->val.args[i] = args[i];
12983 + for (i = nargs - 1; i >= 0; i--)
12984 + FREE_EXPRESSION (args[i]);
12989 +static inline struct expression *
12990 +new_exp_0 (enum operator op)
12992 + return new_exp (0, op, NULL);
12995 +static inline struct expression *
12996 +new_exp_1 (enum operator op, struct expression *right)
12998 + struct expression *args[1];
13001 + return new_exp (1, op, args);
13004 +static struct expression *
13005 +new_exp_2 (enum operator op, struct expression *left, struct expression *right)
13007 + struct expression *args[2];
13011 + return new_exp (2, op, args);
13014 +static inline struct expression *
13015 +new_exp_3 (enum operator op, struct expression *bexp,
13016 + struct expression *tbranch, struct expression *fbranch)
13018 + struct expression *args[3];
13021 + args[1] = tbranch;
13022 + args[2] = fbranch;
13023 + return new_exp (3, op, args);
13027 +# define YYDEBUG 0
13032 +#define YYFINAL 27
13033 +#define YYFLAG -32768
13034 +#define YYNTBASE 16
13036 +/* YYTRANSLATE(YYLEX) -- Bison token number corresponding to YYLEX. */
13037 +#define YYTRANSLATE(x) ((unsigned)(x) <= 261 ? yytranslate[x] : 18)
13039 +/* YYTRANSLATE[YYLEX] -- Bison token number corresponding to YYLEX. */
13040 +static const char yytranslate[] =
13042 + 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13043 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13044 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13045 + 2, 2, 2, 10, 2, 2, 2, 2, 5, 2,
13046 + 14, 15, 2, 2, 2, 2, 2, 2, 2, 2,
13047 + 2, 2, 2, 2, 2, 2, 2, 2, 12, 2,
13048 + 2, 2, 2, 3, 2, 2, 2, 2, 2, 2,
13049 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13050 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13051 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13052 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13053 + 13, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13054 + 2, 2, 2, 2, 4, 2, 2, 2, 2, 2,
13055 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13056 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13057 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13058 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13059 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13060 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13061 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13062 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13063 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13064 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13065 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13066 + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
13067 + 2, 2, 2, 2, 2, 2, 1, 6, 7, 8,
13072 +static const short yyprhs[] =
13074 + 0, 0, 2, 8, 12, 16, 20, 24, 28, 32,
13077 +static const short yyrhs[] =
13079 + 17, 0, 17, 3, 17, 12, 17, 0, 17, 4,
13080 + 17, 0, 17, 5, 17, 0, 17, 6, 17, 0,
13081 + 17, 7, 17, 0, 17, 8, 17, 0, 17, 9,
13082 + 17, 0, 10, 17, 0, 13, 0, 11, 0, 14,
13089 +/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
13090 +static const short yyrline[] =
13092 + 0, 150, 158, 162, 166, 170, 174, 178, 182, 186,
13098 +#if (YYDEBUG) || defined YYERROR_VERBOSE
13100 +/* YYTNAME[TOKEN_NUM] -- String name of the token TOKEN_NUM. */
13101 +static const char *const yytname[] =
13103 + "$", "error", "$undefined.", "'?'", "'|'", "'&'", "EQUOP2", "CMPOP2",
13104 + "ADDOP2", "MULOP2", "'!'", "NUMBER", "':'", "'n'", "'('", "')'",
13105 + "start", "exp", 0
13109 +/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
13110 +static const short yyr1[] =
13112 + 0, 16, 17, 17, 17, 17, 17, 17, 17, 17,
13116 +/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
13117 +static const short yyr2[] =
13119 + 0, 1, 5, 3, 3, 3, 3, 3, 3, 2,
13123 +/* YYDEFACT[S] -- default rule to reduce with in state S when YYTABLE
13124 + doesn't specify something else to do. Zero means the default is an
13126 +static const short yydefact[] =
13128 + 0, 0, 11, 10, 0, 1, 9, 0, 0, 0,
13129 + 0, 0, 0, 0, 0, 12, 0, 3, 4, 5,
13130 + 6, 7, 8, 0, 2, 0, 0, 0
13133 +static const short yydefgoto[] =
13138 +static const short yypact[] =
13140 + -9, -9,-32768,-32768, -9, 34,-32768, 11, -9, -9,
13141 + -9, -9, -9, -9, -9,-32768, 24, 39, 43, 16,
13142 + 26, -3,-32768, -9, 34, 21, 53,-32768
13145 +static const short yypgoto[] =
13154 +static const short yytable[] =
13156 + 6, 1, 2, 7, 3, 4, 14, 16, 17, 18,
13157 + 19, 20, 21, 22, 8, 9, 10, 11, 12, 13,
13158 + 14, 26, 24, 12, 13, 14, 15, 8, 9, 10,
13159 + 11, 12, 13, 14, 13, 14, 23, 8, 9, 10,
13160 + 11, 12, 13, 14, 10, 11, 12, 13, 14, 11,
13164 +static const short yycheck[] =
13166 + 1, 10, 11, 4, 13, 14, 9, 8, 9, 10,
13167 + 11, 12, 13, 14, 3, 4, 5, 6, 7, 8,
13168 + 9, 0, 23, 7, 8, 9, 15, 3, 4, 5,
13169 + 6, 7, 8, 9, 8, 9, 12, 3, 4, 5,
13170 + 6, 7, 8, 9, 5, 6, 7, 8, 9, 6,
13175 +/* -*-C-*- Note some compilers choke on comments on `#line' lines. */
13176 +#line 3 "/usr/local/share/bison/bison.simple"
13178 +/* Skeleton output parser for bison,
13180 + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002 Free Software
13183 + This program is free software; you can redistribute it and/or modify
13184 + it under the terms of the GNU General Public License as published by
13185 + the Free Software Foundation; either version 2, or (at your option)
13186 + any later version.
13188 + This program is distributed in the hope that it will be useful,
13189 + but WITHOUT ANY WARRANTY; without even the implied warranty of
13190 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13191 + GNU General Public License for more details.
13193 + You should have received a copy of the GNU General Public License
13194 + along with this program; if not, write to the Free Software
13195 + Foundation, Inc., 59 Temple Place - Suite 330,
13196 + Boston, MA 02111-1307, USA. */
13198 +/* As a special exception, when this file is copied by Bison into a
13199 + Bison output file, you may use that output file without restriction.
13200 + This special exception was added by the Free Software Foundation
13201 + in version 1.24 of Bison. */
13203 +/* This is the parser code that is written into each bison parser when
13204 + the %semantic_parser declaration is not specified in the grammar.
13205 + It was written by Richard Stallman by simplifying the hairy parser
13206 + used when %semantic_parser is specified. */
13208 +/* All symbols defined below should begin with yy or YY, to avoid
13209 + infringing on user name space. This should be done even for local
13210 + variables, as they might otherwise be expanded by user macros.
13211 + There are some unavoidable exceptions within include files to
13212 + define necessary library symbols; they are noted "INFRINGES ON
13213 + USER NAME SPACE" below. */
13215 +#if ! defined (yyoverflow) || defined (YYERROR_VERBOSE)
13217 +/* The parser invokes alloca or malloc; define the necessary symbols. */
13219 +# if YYSTACK_USE_ALLOCA
13220 +# define YYSTACK_ALLOC alloca
13222 +# ifndef YYSTACK_USE_ALLOCA
13223 +# if defined (alloca) || defined (_ALLOCA_H)
13224 +# define YYSTACK_ALLOC alloca
13227 +# define YYSTACK_ALLOC __builtin_alloca
13233 +# ifdef YYSTACK_ALLOC
13234 + /* Pacify GCC's `empty if-body' warning. */
13235 +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
13237 +# if defined (__STDC__) || defined (__cplusplus)
13238 +# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
13239 +# define YYSIZE_T size_t
13241 +# define YYSTACK_ALLOC malloc
13242 +# define YYSTACK_FREE free
13244 +#endif /* ! defined (yyoverflow) || defined (YYERROR_VERBOSE) */
13247 +#if (! defined (yyoverflow) \
13248 + && (! defined (__cplusplus) \
13249 + || (YYLTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
13251 +/* A type that is properly aligned for any stack member. */
13261 +/* The size of the maximum gap between one aligned stack and the next. */
13262 +# define YYSTACK_GAP_MAX (sizeof (union yyalloc) - 1)
13264 +/* The size of an array large to enough to hold all stacks, each with
13267 +# define YYSTACK_BYTES(N) \
13268 + ((N) * (sizeof (short) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \
13269 + + 2 * YYSTACK_GAP_MAX)
13271 +# define YYSTACK_BYTES(N) \
13272 + ((N) * (sizeof (short) + sizeof (YYSTYPE)) \
13273 + + YYSTACK_GAP_MAX)
13276 +/* Copy COUNT objects from FROM to TO. The source and destination do
13280 +# define YYCOPY(To, From, Count) \
13281 + __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
13283 +# define YYCOPY(To, From, Count) \
13286 + register YYSIZE_T yyi; \
13287 + for (yyi = 0; yyi < (Count); yyi++) \
13288 + (To)[yyi] = (From)[yyi]; \
13294 +/* Relocate STACK from its old location to the new one. The
13295 + local variables YYSIZE and YYSTACKSIZE give the old and new number of
13296 + elements in the stack, and YYPTR gives the new location of the
13297 + stack. Advance YYPTR to a properly aligned location for the next
13299 +# define YYSTACK_RELOCATE(Stack) \
13302 + YYSIZE_T yynewbytes; \
13303 + YYCOPY (&yyptr->Stack, Stack, yysize); \
13304 + Stack = &yyptr->Stack; \
13305 + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAX; \
13306 + yyptr += yynewbytes / sizeof (*yyptr); \
13313 +#if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__)
13314 +# define YYSIZE_T __SIZE_TYPE__
13316 +#if ! defined (YYSIZE_T) && defined (size_t)
13317 +# define YYSIZE_T size_t
13319 +#if ! defined (YYSIZE_T)
13320 +# if defined (__STDC__) || defined (__cplusplus)
13321 +# include <stddef.h> /* INFRINGES ON USER NAME SPACE */
13322 +# define YYSIZE_T size_t
13325 +#if ! defined (YYSIZE_T)
13326 +# define YYSIZE_T unsigned int
13329 +#define yyerrok (yyerrstatus = 0)
13330 +#define yyclearin (yychar = YYEMPTY)
13331 +#define YYEMPTY -2
13333 +#define YYACCEPT goto yyacceptlab
13334 +#define YYABORT goto yyabortlab
13335 +#define YYERROR goto yyerrlab1
13336 +/* Like YYERROR except do call yyerror. This remains here temporarily
13337 + to ease the transition to the new meaning of YYERROR, for GCC.
13338 + Once GCC version 2 has supplanted version 1, this can go. */
13339 +#define YYFAIL goto yyerrlab
13340 +#define YYRECOVERING() (!!yyerrstatus)
13341 +#define YYBACKUP(Token, Value) \
13343 + if (yychar == YYEMPTY && yylen == 1) \
13345 + yychar = (Token); \
13346 + yylval = (Value); \
13347 + yychar1 = YYTRANSLATE (yychar); \
13353 + yyerror ("syntax error: cannot back up"); \
13358 +#define YYTERROR 1
13359 +#define YYERRCODE 256
13362 +/* YYLLOC_DEFAULT -- Compute the default location (before the actions
13365 + When YYLLOC_DEFAULT is run, CURRENT is set the location of the
13366 + first token. By default, to implement support for ranges, extend
13367 + its range to the last symbol. */
13369 +#ifndef YYLLOC_DEFAULT
13370 +# define YYLLOC_DEFAULT(Current, Rhs, N) \
13371 + Current.last_line = Rhs[N].last_line; \
13372 + Current.last_column = Rhs[N].last_column;
13376 +/* YYLEX -- calling `yylex' with the right arguments. */
13380 +# ifdef YYLEX_PARAM
13381 +# define YYLEX yylex (&yylval, &yylloc, YYLEX_PARAM)
13383 +# define YYLEX yylex (&yylval, &yylloc)
13385 +# else /* !YYLSP_NEEDED */
13386 +# ifdef YYLEX_PARAM
13387 +# define YYLEX yylex (&yylval, YYLEX_PARAM)
13389 +# define YYLEX yylex (&yylval)
13391 +# endif /* !YYLSP_NEEDED */
13392 +#else /* !YYPURE */
13393 +# define YYLEX yylex ()
13394 +#endif /* !YYPURE */
13397 +/* Enable debugging if requested. */
13400 +# ifndef YYFPRINTF
13401 +# include <stdio.h> /* INFRINGES ON USER NAME SPACE */
13402 +# define YYFPRINTF fprintf
13405 +# define YYDPRINTF(Args) \
13408 + YYFPRINTF Args; \
13410 +/* Nonzero means print parse trace. It is left uninitialized so that
13411 + multiple parsers can coexist. */
13413 +#else /* !YYDEBUG */
13414 +# define YYDPRINTF(Args)
13415 +#endif /* !YYDEBUG */
13417 +/* YYINITDEPTH -- initial size of the parser's stacks. */
13418 +#ifndef YYINITDEPTH
13419 +# define YYINITDEPTH 200
13422 +/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
13423 + if the built-in stack extension method is used).
13425 + Do not make this value too large; the results are undefined if
13426 + SIZE_MAX < YYSTACK_BYTES (YYMAXDEPTH)
13427 + evaluated with infinite-precision integer arithmetic. */
13429 +#if YYMAXDEPTH == 0
13430 +# undef YYMAXDEPTH
13433 +#ifndef YYMAXDEPTH
13434 +# define YYMAXDEPTH 10000
13437 +#ifdef YYERROR_VERBOSE
13440 +# if defined (__GLIBC__) && defined (_STRING_H)
13441 +# define yystrlen strlen
13443 +/* Return the length of YYSTR. */
13445 +# if defined (__STDC__) || defined (__cplusplus)
13446 +yystrlen (const char *yystr)
13449 + const char *yystr;
13452 + register const char *yys = yystr;
13454 + while (*yys++ != '\0')
13457 + return yys - yystr - 1;
13463 +# if defined (__GLIBC__) && defined (_STRING_H) && defined (_GNU_SOURCE)
13464 +# define yystpcpy stpcpy
13466 +/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
13469 +# if defined (__STDC__) || defined (__cplusplus)
13470 +yystpcpy (char *yydest, const char *yysrc)
13472 +yystpcpy (yydest, yysrc)
13474 + const char *yysrc;
13477 + register char *yyd = yydest;
13478 + register const char *yys = yysrc;
13480 + while ((*yyd++ = *yys++) != '\0')
13489 +#line 315 "/usr/local/share/bison/bison.simple"
13492 +/* The user can define YYPARSE_PARAM as the name of an argument to be passed
13493 + into yyparse. The argument should have type void *.
13494 + It should actually point to an object.
13495 + Grammar actions can access the variable by casting it
13496 + to the proper pointer type. */
13498 +#ifdef YYPARSE_PARAM
13499 +# if defined (__STDC__) || defined (__cplusplus)
13500 +# define YYPARSE_PARAM_ARG void *YYPARSE_PARAM
13501 +# define YYPARSE_PARAM_DECL
13503 +# define YYPARSE_PARAM_ARG YYPARSE_PARAM
13504 +# define YYPARSE_PARAM_DECL void *YYPARSE_PARAM;
13506 +#else /* !YYPARSE_PARAM */
13507 +# define YYPARSE_PARAM_ARG
13508 +# define YYPARSE_PARAM_DECL
13509 +#endif /* !YYPARSE_PARAM */
13511 +/* Prevent warning if -Wstrict-prototypes. */
13513 +# ifdef YYPARSE_PARAM
13514 +int yyparse (void *);
13516 +int yyparse (void);
13520 +/* YY_DECL_VARIABLES -- depending whether we use a pure parser,
13521 + variables are global, or local to YYPARSE. */
13523 +#define YY_DECL_NON_LSP_VARIABLES \
13524 +/* The lookahead symbol. */ \
13527 +/* The semantic value of the lookahead symbol. */ \
13530 +/* Number of parse errors so far. */ \
13534 +# define YY_DECL_VARIABLES \
13535 +YY_DECL_NON_LSP_VARIABLES \
13537 +/* Location data for the lookahead symbol. */ \
13540 +# define YY_DECL_VARIABLES \
13541 +YY_DECL_NON_LSP_VARIABLES
13545 +/* If nonreentrant, generate the variables here. */
13549 +#endif /* !YYPURE */
13552 +yyparse (YYPARSE_PARAM_ARG)
13553 + YYPARSE_PARAM_DECL
13555 + /* If reentrant, generate the variables here. */
13557 + YY_DECL_VARIABLES
13558 +#endif /* !YYPURE */
13560 + register int yystate;
13561 + register int yyn;
13563 + /* Number of tokens to shift before error messages enabled. */
13565 + /* Lookahead token as an internal (translated) token number. */
13568 + /* Three stacks and their tools:
13569 + `yyss': related to states,
13570 + `yyvs': related to semantic values,
13571 + `yyls': related to locations.
13573 + Refer to the stacks thru separate pointers, to allow yyoverflow
13574 + to reallocate them elsewhere. */
13576 + /* The state stack. */
13577 + short yyssa[YYINITDEPTH];
13578 + short *yyss = yyssa;
13579 + register short *yyssp;
13581 + /* The semantic value stack. */
13582 + YYSTYPE yyvsa[YYINITDEPTH];
13583 + YYSTYPE *yyvs = yyvsa;
13584 + register YYSTYPE *yyvsp;
13587 + /* The location stack. */
13588 + YYLTYPE yylsa[YYINITDEPTH];
13589 + YYLTYPE *yyls = yylsa;
13594 +# define YYPOPSTACK (yyvsp--, yyssp--, yylsp--)
13596 +# define YYPOPSTACK (yyvsp--, yyssp--)
13599 + YYSIZE_T yystacksize = YYINITDEPTH;
13602 + /* The variables used to return semantic value and location from the
13603 + action routines. */
13609 + /* When reducing, the number of symbols on the RHS of the reduced
13613 + YYDPRINTF ((stderr, "Starting parse\n"));
13618 + yychar = YYEMPTY; /* Cause a token to be read. */
13620 + /* Initialize stack pointers.
13621 + Waste one element of value and location stack
13622 + so that they stay on the same level as the state stack.
13623 + The wasted elements are never initialized. */
13632 +/*------------------------------------------------------------.
13633 +| yynewstate -- Push a new state, which is found in yystate. |
13634 +`------------------------------------------------------------*/
13636 + /* In all cases, when you get here, the value and location stacks
13637 + have just been pushed. so pushing a state here evens the stacks.
13642 + *yyssp = yystate;
13644 + if (yyssp >= yyss + yystacksize - 1)
13646 + /* Get the current used size of the three stacks, in elements. */
13647 + YYSIZE_T yysize = yyssp - yyss + 1;
13651 + /* Give user a chance to reallocate the stack. Use copies of
13652 + these so that the &'s don't force the real ones into
13654 + YYSTYPE *yyvs1 = yyvs;
13655 + short *yyss1 = yyss;
13657 + /* Each stack pointer address is followed by the size of the
13658 + data in use in that stack, in bytes. */
13660 + YYLTYPE *yyls1 = yyls;
13661 + /* This used to be a conditional around just the two extra args,
13662 + but that might be undefined if yyoverflow is a macro. */
13663 + yyoverflow ("parser stack overflow",
13664 + &yyss1, yysize * sizeof (*yyssp),
13665 + &yyvs1, yysize * sizeof (*yyvsp),
13666 + &yyls1, yysize * sizeof (*yylsp),
13670 + yyoverflow ("parser stack overflow",
13671 + &yyss1, yysize * sizeof (*yyssp),
13672 + &yyvs1, yysize * sizeof (*yyvsp),
13678 +#else /* no yyoverflow */
13679 +# ifndef YYSTACK_RELOCATE
13680 + goto yyoverflowlab;
13682 + /* Extend the stack our own way. */
13683 + if (yystacksize >= YYMAXDEPTH)
13684 + goto yyoverflowlab;
13685 + yystacksize *= 2;
13686 + if (yystacksize > YYMAXDEPTH)
13687 + yystacksize = YYMAXDEPTH;
13690 + short *yyss1 = yyss;
13691 + union yyalloc *yyptr =
13692 + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
13694 + goto yyoverflowlab;
13695 + YYSTACK_RELOCATE (yyss);
13696 + YYSTACK_RELOCATE (yyvs);
13698 + YYSTACK_RELOCATE (yyls);
13700 +# undef YYSTACK_RELOCATE
13701 + if (yyss1 != yyssa)
13702 + YYSTACK_FREE (yyss1);
13705 +#endif /* no yyoverflow */
13707 + yyssp = yyss + yysize - 1;
13708 + yyvsp = yyvs + yysize - 1;
13710 + yylsp = yyls + yysize - 1;
13713 + YYDPRINTF ((stderr, "Stack size increased to %lu\n",
13714 + (unsigned long int) yystacksize));
13716 + if (yyssp >= yyss + yystacksize - 1)
13720 + YYDPRINTF ((stderr, "Entering state %d\n", yystate));
13730 +/* Do appropriate processing given the current state. */
13731 +/* Read a lookahead token if we need one and don't already have one. */
13734 + /* First try to decide what to do without reference to lookahead token. */
13736 + yyn = yypact[yystate];
13737 + if (yyn == YYFLAG)
13740 + /* Not known => get a lookahead token if don't already have one. */
13742 + /* yychar is either YYEMPTY or YYEOF
13743 + or a valid token in external form. */
13745 + if (yychar == YYEMPTY)
13747 + YYDPRINTF ((stderr, "Reading a token: "));
13751 + /* Convert token to internal form (in yychar1) for indexing tables with */
13753 + if (yychar <= 0) /* This means end of input. */
13756 + yychar = YYEOF; /* Don't call YYLEX any more */
13758 + YYDPRINTF ((stderr, "Now at end of input.\n"));
13762 + yychar1 = YYTRANSLATE (yychar);
13765 + /* We have to keep this `#if YYDEBUG', since we use variables
13766 + which are defined only if `YYDEBUG' is set. */
13769 + YYFPRINTF (stderr, "Next token is %d (%s",
13770 + yychar, yytname[yychar1]);
13771 + /* Give the individual parser a way to print the precise
13772 + meaning of a token, for further debugging info. */
13774 + YYPRINT (stderr, yychar, yylval);
13776 + YYFPRINTF (stderr, ")\n");
13782 + if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != yychar1)
13785 + yyn = yytable[yyn];
13787 + /* yyn is what to do for this token type in this state.
13788 + Negative => reduce, -yyn is rule number.
13789 + Positive => shift, yyn is new state.
13790 + New state is final state => don't bother to shift,
13791 + just return success.
13792 + 0, or most negative number => error. */
13796 + if (yyn == YYFLAG)
13801 + else if (yyn == 0)
13804 + if (yyn == YYFINAL)
13807 + /* Shift the lookahead token. */
13808 + YYDPRINTF ((stderr, "Shifting token %d (%s), ",
13809 + yychar, yytname[yychar1]));
13811 + /* Discard the token being shifted unless it is eof. */
13812 + if (yychar != YYEOF)
13813 + yychar = YYEMPTY;
13815 + *++yyvsp = yylval;
13817 + *++yylsp = yylloc;
13820 + /* Count tokens shifted since error; after three, turn off error
13829 +/*-----------------------------------------------------------.
13830 +| yydefault -- do the default action for the current state. |
13831 +`-----------------------------------------------------------*/
13833 + yyn = yydefact[yystate];
13839 +/*-----------------------------.
13840 +| yyreduce -- Do a reduction. |
13841 +`-----------------------------*/
13843 + /* yyn is the number of a rule to reduce with. */
13844 + yylen = yyr2[yyn];
13846 + /* If YYLEN is nonzero, implement the default value of the action:
13849 + Otherwise, the following line sets YYVAL to the semantic value of
13850 + the lookahead token. This behavior is undocumented and Bison
13851 + users should not rely upon it. Assigning to YYVAL
13852 + unconditionally makes the parser a bit smaller, and it avoids a
13853 + GCC warning that YYVAL may be used uninitialized. */
13854 + yyval = yyvsp[1-yylen];
13857 + /* Similarly for the default location. Let the user run additional
13858 + commands if for instance locations are ranges. */
13859 + yyloc = yylsp[1-yylen];
13860 + YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen);
13864 + /* We have to keep this `#if YYDEBUG', since we use variables which
13865 + are defined only if `YYDEBUG' is set. */
13870 + YYFPRINTF (stderr, "Reducing via rule %d (line %d), ",
13871 + yyn, yyrline[yyn]);
13873 + /* Print the symbols being reduced, and their result. */
13874 + for (yyi = yyprhs[yyn]; yyrhs[yyi] > 0; yyi++)
13875 + YYFPRINTF (stderr, "%s ", yytname[yyrhs[yyi]]);
13876 + YYFPRINTF (stderr, " -> %s\n", yytname[yyr1[yyn]]);
13883 +#line 151 "plural.y"
13885 + if (yyvsp[0].exp == NULL)
13887 + ((struct parse_args *) arg)->res = yyvsp[0].exp;
13891 +#line 159 "plural.y"
13893 + yyval.exp = new_exp_3 (qmop, yyvsp[-4].exp, yyvsp[-2].exp, yyvsp[0].exp);
13897 +#line 163 "plural.y"
13899 + yyval.exp = new_exp_2 (lor, yyvsp[-2].exp, yyvsp[0].exp);
13903 +#line 167 "plural.y"
13905 + yyval.exp = new_exp_2 (land, yyvsp[-2].exp, yyvsp[0].exp);
13909 +#line 171 "plural.y"
13911 + yyval.exp = new_exp_2 (yyvsp[-1].op, yyvsp[-2].exp, yyvsp[0].exp);
13915 +#line 175 "plural.y"
13917 + yyval.exp = new_exp_2 (yyvsp[-1].op, yyvsp[-2].exp, yyvsp[0].exp);
13921 +#line 179 "plural.y"
13923 + yyval.exp = new_exp_2 (yyvsp[-1].op, yyvsp[-2].exp, yyvsp[0].exp);
13927 +#line 183 "plural.y"
13929 + yyval.exp = new_exp_2 (yyvsp[-1].op, yyvsp[-2].exp, yyvsp[0].exp);
13933 +#line 187 "plural.y"
13935 + yyval.exp = new_exp_1 (lnot, yyvsp[0].exp);
13939 +#line 191 "plural.y"
13941 + yyval.exp = new_exp_0 (var);
13945 +#line 195 "plural.y"
13947 + if ((yyval.exp = new_exp_0 (num)) != NULL)
13948 + yyval.exp->val.num = yyvsp[0].num;
13952 +#line 200 "plural.y"
13954 + yyval.exp = yyvsp[-1].exp;
13959 +#line 705 "/usr/local/share/bison/bison.simple"
13971 + short *yyssp1 = yyss - 1;
13972 + YYFPRINTF (stderr, "state stack now");
13973 + while (yyssp1 != yyssp)
13974 + YYFPRINTF (stderr, " %d", *++yyssp1);
13975 + YYFPRINTF (stderr, "\n");
13979 + *++yyvsp = yyval;
13981 + *++yylsp = yyloc;
13984 + /* Now `shift' the result of the reduction. Determine what state
13985 + that goes to, based on the state we popped back to and the rule
13986 + number reduced by. */
13990 + yystate = yypgoto[yyn - YYNTBASE] + *yyssp;
13991 + if (yystate >= 0 && yystate <= YYLAST && yycheck[yystate] == *yyssp)
13992 + yystate = yytable[yystate];
13994 + yystate = yydefgoto[yyn - YYNTBASE];
13999 +/*------------------------------------.
14000 +| yyerrlab -- here on detecting error |
14001 +`------------------------------------*/
14003 + /* If not already recovering from an error, report this error. */
14004 + if (!yyerrstatus)
14008 +#ifdef YYERROR_VERBOSE
14009 + yyn = yypact[yystate];
14011 + if (yyn > YYFLAG && yyn < YYLAST)
14013 + YYSIZE_T yysize = 0;
14015 + int yyx, yycount;
14018 + /* Start YYX at -YYN if negative to avoid negative indexes in
14020 + for (yyx = yyn < 0 ? -yyn : 0;
14021 + yyx < (int) (sizeof (yytname) / sizeof (char *)); yyx++)
14022 + if (yycheck[yyx + yyn] == yyx)
14023 + yysize += yystrlen (yytname[yyx]) + 15, yycount++;
14024 + yysize += yystrlen ("parse error, unexpected ") + 1;
14025 + yysize += yystrlen (yytname[YYTRANSLATE (yychar)]);
14026 + yymsg = (char *) YYSTACK_ALLOC (yysize);
14029 + char *yyp = yystpcpy (yymsg, "parse error, unexpected ");
14030 + yyp = yystpcpy (yyp, yytname[YYTRANSLATE (yychar)]);
14035 + for (yyx = yyn < 0 ? -yyn : 0;
14036 + yyx < (int) (sizeof (yytname) / sizeof (char *));
14038 + if (yycheck[yyx + yyn] == yyx)
14040 + const char *yyq = ! yycount ? ", expecting " : " or ";
14041 + yyp = yystpcpy (yyp, yyq);
14042 + yyp = yystpcpy (yyp, yytname[yyx]);
14047 + YYSTACK_FREE (yymsg);
14050 + yyerror ("parse error; also virtual memory exhausted");
14053 +#endif /* defined (YYERROR_VERBOSE) */
14054 + yyerror ("parse error");
14059 +/*--------------------------------------------------.
14060 +| yyerrlab1 -- error raised explicitly by an action |
14061 +`--------------------------------------------------*/
14063 + if (yyerrstatus == 3)
14065 + /* If just tried and failed to reuse lookahead token after an
14066 + error, discard it. */
14068 + /* return failure if at end of input */
14069 + if (yychar == YYEOF)
14071 + YYDPRINTF ((stderr, "Discarding token %d (%s).\n",
14072 + yychar, yytname[yychar1]));
14073 + yychar = YYEMPTY;
14076 + /* Else will try to reuse lookahead token after shifting the error
14079 + yyerrstatus = 3; /* Each real token shifted decrements this */
14081 + goto yyerrhandle;
14084 +/*-------------------------------------------------------------------.
14085 +| yyerrdefault -- current state does not do anything special for the |
14087 +`-------------------------------------------------------------------*/
14090 + /* This is wrong; only states that explicitly want error tokens
14091 + should shift them. */
14093 + /* If its default is to accept any token, ok. Otherwise pop it. */
14094 + yyn = yydefact[yystate];
14100 +/*---------------------------------------------------------------.
14101 +| yyerrpop -- pop the current state because it cannot handle the |
14103 +`---------------------------------------------------------------*/
14105 + if (yyssp == yyss)
14108 + yystate = *--yyssp;
14116 + short *yyssp1 = yyss - 1;
14117 + YYFPRINTF (stderr, "Error: state stack now");
14118 + while (yyssp1 != yyssp)
14119 + YYFPRINTF (stderr, " %d", *++yyssp1);
14120 + YYFPRINTF (stderr, "\n");
14128 + yyn = yypact[yystate];
14129 + if (yyn == YYFLAG)
14130 + goto yyerrdefault;
14133 + if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != YYTERROR)
14134 + goto yyerrdefault;
14136 + yyn = yytable[yyn];
14139 + if (yyn == YYFLAG)
14144 + else if (yyn == 0)
14147 + if (yyn == YYFINAL)
14150 + YYDPRINTF ((stderr, "Shifting error token, "));
14152 + *++yyvsp = yylval;
14154 + *++yylsp = yylloc;
14161 +/*-------------------------------------.
14162 +| yyacceptlab -- YYACCEPT comes here. |
14163 +`-------------------------------------*/
14168 +/*-----------------------------------.
14169 +| yyabortlab -- YYABORT comes here. |
14170 +`-----------------------------------*/
14175 +/*---------------------------------------------.
14176 +| yyoverflowab -- parser overflow comes here. |
14177 +`---------------------------------------------*/
14179 + yyerror ("parser stack overflow");
14181 + /* Fall through. */
14184 +#ifndef yyoverflow
14185 + if (yyss != yyssa)
14186 + YYSTACK_FREE (yyss);
14190 +#line 205 "plural.y"
14195 +FREE_EXPRESSION (struct expression *exp)
14200 + /* Handle the recursive case. */
14201 + switch (exp->nargs)
14204 + FREE_EXPRESSION (exp->val.args[2]);
14205 + /* FALLTHROUGH */
14207 + FREE_EXPRESSION (exp->val.args[1]);
14208 + /* FALLTHROUGH */
14210 + FREE_EXPRESSION (exp->val.args[0]);
14211 + /* FALLTHROUGH */
14221 +yylex (YYSTYPE *lval, const char **pexp)
14223 + const char *exp = *pexp;
14228 + if (exp[0] == '\0')
14234 + if (exp[0] != ' ' && exp[0] != '\t')
14243 + case '0': case '1': case '2': case '3': case '4':
14244 + case '5': case '6': case '7': case '8': case '9':
14246 + unsigned long int n = result - '0';
14247 + while (exp[0] >= '0' && exp[0] <= '9')
14250 + n += exp[0] - '0';
14259 + if (exp[0] == '=')
14262 + lval->op = equal;
14266 + result = YYERRCODE;
14270 + if (exp[0] == '=')
14273 + lval->op = not_equal;
14280 + if (exp[0] == result)
14283 + result = YYERRCODE;
14287 + if (exp[0] == '=')
14290 + lval->op = less_or_equal;
14293 + lval->op = less_than;
14298 + if (exp[0] == '=')
14301 + lval->op = greater_or_equal;
14304 + lval->op = greater_than;
14314 + lval->op = divide;
14319 + lval->op = module;
14329 + lval->op = minus;
14338 + /* Nothing, just return the character. */
14344 + /* Be safe and let the user call this function again. */
14350 + result = YYERRCODE;
14364 +yyerror (const char *str)
14366 + /* Do nothing. We don't print error messages here. */
14368 --- lrzsz-0.12.20.safe/intl/plural-exp.c 1969-12-31 19:00:00.000000000 -0500
14369 +++ lrzsz-0.12.20/intl/plural-exp.c 2004-09-12 14:40:34.578714192 -0400
14371 +/* Expression parsing for plural form selection.
14372 + Copyright (C) 2000-2001, 2003 Free Software Foundation, Inc.
14373 + Written by Ulrich Drepper <drepper@cygnus.com>, 2000.
14375 + This program is free software; you can redistribute it and/or modify it
14376 + under the terms of the GNU Library General Public License as published
14377 + by the Free Software Foundation; either version 2, or (at your option)
14378 + any later version.
14380 + This program is distributed in the hope that it will be useful,
14381 + but WITHOUT ANY WARRANTY; without even the implied warranty of
14382 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14383 + Library General Public License for more details.
14385 + You should have received a copy of the GNU Library General Public
14386 + License along with this program; if not, write to the Free Software
14387 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
14390 +#ifdef HAVE_CONFIG_H
14391 +# include <config.h>
14394 +#include <ctype.h>
14395 +#include <stdlib.h>
14396 +#include <string.h>
14398 +#include "plural-exp.h"
14400 +#if (defined __GNUC__ && !defined __APPLE_CC__) \
14401 + || (defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L)
14403 +/* These structs are the constant expression for the germanic plural
14404 + form determination. It represents the expression "n != 1". */
14405 +static const struct expression plvar =
14408 + .operation = var,
14410 +static const struct expression plone =
14413 + .operation = num,
14419 +struct expression GERMANIC_PLURAL =
14422 + .operation = not_equal,
14427 + [0] = (struct expression *) &plvar,
14428 + [1] = (struct expression *) &plone
14433 +# define INIT_GERMANIC_PLURAL()
14437 +/* For compilers without support for ISO C 99 struct/union initializers:
14438 + Initialization at run-time. */
14440 +static struct expression plvar;
14441 +static struct expression plone;
14442 +struct expression GERMANIC_PLURAL;
14445 +init_germanic_plural ()
14447 + if (plone.val.num == 0)
14450 + plvar.operation = var;
14453 + plone.operation = num;
14454 + plone.val.num = 1;
14456 + GERMANIC_PLURAL.nargs = 2;
14457 + GERMANIC_PLURAL.operation = not_equal;
14458 + GERMANIC_PLURAL.val.args[0] = &plvar;
14459 + GERMANIC_PLURAL.val.args[1] = &plone;
14463 +# define INIT_GERMANIC_PLURAL() init_germanic_plural ()
14469 +EXTRACT_PLURAL_EXPRESSION (const char *nullentry, struct expression **pluralp,
14470 + unsigned long int *npluralsp)
14472 + if (nullentry != NULL)
14474 + const char *plural;
14475 + const char *nplurals;
14477 + plural = strstr (nullentry, "plural=");
14478 + nplurals = strstr (nullentry, "nplurals=");
14479 + if (plural == NULL || nplurals == NULL)
14484 + unsigned long int n;
14485 + struct parse_args args;
14487 + /* First get the number. */
14489 + while (*nplurals != '\0' && isspace ((unsigned char) *nplurals))
14491 + if (!(*nplurals >= '0' && *nplurals <= '9'))
14493 +#if defined HAVE_STRTOUL || defined _LIBC
14494 + n = strtoul (nplurals, &endp, 10);
14496 + for (endp = nplurals, n = 0; *endp >= '0' && *endp <= '9'; endp++)
14497 + n = n * 10 + (*endp - '0');
14499 + if (nplurals == endp)
14503 + /* Due to the restrictions bison imposes onto the interface of the
14504 + scanner function we have to put the input string and the result
14505 + passed up from the parser into the same structure which address
14506 + is passed down to the parser. */
14508 + args.cp = plural;
14509 + if (PLURAL_PARSE (&args) != 0)
14511 + *pluralp = args.res;
14516 + /* By default we are using the Germanic form: singular form only
14517 + for `one', the plural form otherwise. Yes, this is also what
14518 + English is using since English is a Germanic language. */
14520 + INIT_GERMANIC_PLURAL ();
14521 + *pluralp = &GERMANIC_PLURAL;
14525 --- lrzsz-0.12.20.safe/intl/plural-exp.h 1969-12-31 19:00:00.000000000 -0500
14526 +++ lrzsz-0.12.20/intl/plural-exp.h 2004-09-12 14:40:34.584713280 -0400
14528 +/* Expression parsing and evaluation for plural form selection.
14529 + Copyright (C) 2000-2003 Free Software Foundation, Inc.
14530 + Written by Ulrich Drepper <drepper@cygnus.com>, 2000.
14532 + This program is free software; you can redistribute it and/or modify it
14533 + under the terms of the GNU Library General Public License as published
14534 + by the Free Software Foundation; either version 2, or (at your option)
14535 + any later version.
14537 + This program is distributed in the hope that it will be useful,
14538 + but WITHOUT ANY WARRANTY; without even the implied warranty of
14539 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14540 + Library General Public License for more details.
14542 + You should have received a copy of the GNU Library General Public
14543 + License along with this program; if not, write to the Free Software
14544 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
14547 +#ifndef _PLURAL_EXP_H
14548 +#define _PLURAL_EXP_H
14550 +#ifndef internal_function
14551 +# define internal_function
14554 +#ifndef attribute_hidden
14555 +# define attribute_hidden
14559 +/* This is the representation of the expressions to determine the
14563 + int nargs; /* Number of arguments. */
14566 + /* Without arguments: */
14567 + var, /* The variable "n". */
14568 + num, /* Decimal number. */
14569 + /* Unary operators: */
14570 + lnot, /* Logical NOT. */
14571 + /* Binary operators: */
14572 + mult, /* Multiplication. */
14573 + divide, /* Division. */
14574 + module, /* Modulo operation. */
14575 + plus, /* Addition. */
14576 + minus, /* Subtraction. */
14577 + less_than, /* Comparison. */
14578 + greater_than, /* Comparison. */
14579 + less_or_equal, /* Comparison. */
14580 + greater_or_equal, /* Comparison. */
14581 + equal, /* Comparison for equality. */
14582 + not_equal, /* Comparison for inequality. */
14583 + land, /* Logical AND. */
14584 + lor, /* Logical OR. */
14585 + /* Ternary operators: */
14586 + qmop /* Question mark operator. */
14590 + unsigned long int num; /* Number value for `num'. */
14591 + struct expression *args[3]; /* Up to three arguments. */
14595 +/* This is the data structure to pass information to the parser and get
14596 + the result in a thread-safe way. */
14600 + struct expression *res;
14604 +/* Names for the libintl functions are a problem. This source code is used
14605 + 1. in the GNU C Library library,
14606 + 2. in the GNU libintl library,
14607 + 3. in the GNU gettext tools.
14608 + The function names in each situation must be different, to allow for
14609 + binary incompatible changes in 'struct expression'. Furthermore,
14610 + 1. in the GNU C Library library, the names have a __ prefix,
14611 + 2.+3. in the GNU libintl library and in the GNU gettext tools, the names
14612 + must follow ANSI C and not start with __.
14613 + So we have to distinguish the three cases. */
14615 +# define FREE_EXPRESSION __gettext_free_exp
14616 +# define PLURAL_PARSE __gettextparse
14617 +# define GERMANIC_PLURAL __gettext_germanic_plural
14618 +# define EXTRACT_PLURAL_EXPRESSION __gettext_extract_plural
14619 +#elif defined (IN_LIBINTL)
14620 +# define FREE_EXPRESSION libintl_gettext_free_exp
14621 +# define PLURAL_PARSE libintl_gettextparse
14622 +# define GERMANIC_PLURAL libintl_gettext_germanic_plural
14623 +# define EXTRACT_PLURAL_EXPRESSION libintl_gettext_extract_plural
14625 +# define FREE_EXPRESSION free_plural_expression
14626 +# define PLURAL_PARSE parse_plural_expression
14627 +# define GERMANIC_PLURAL germanic_plural
14628 +# define EXTRACT_PLURAL_EXPRESSION extract_plural_expression
14631 +extern void FREE_EXPRESSION (struct expression *exp)
14632 + internal_function;
14633 +extern int PLURAL_PARSE (void *arg);
14634 +extern struct expression GERMANIC_PLURAL attribute_hidden;
14635 +extern void EXTRACT_PLURAL_EXPRESSION (const char *nullentry,
14636 + struct expression **pluralp,
14637 + unsigned long int *npluralsp)
14638 + internal_function;
14640 +#if !defined (_LIBC) && !defined (IN_LIBINTL)
14641 +extern unsigned long int plural_eval (struct expression *pexp,
14642 + unsigned long int n);
14645 +#endif /* _PLURAL_EXP_H */
14646 --- lrzsz-0.12.20.safe/intl/plural.y 1969-12-31 19:00:00.000000000 -0500
14647 +++ lrzsz-0.12.20/intl/plural.y 2004-09-12 14:40:34.589712520 -0400
14650 +/* Expression parsing for plural form selection.
14651 + Copyright (C) 2000-2001, 2003 Free Software Foundation, Inc.
14652 + Written by Ulrich Drepper <drepper@cygnus.com>, 2000.
14654 + This program is free software; you can redistribute it and/or modify it
14655 + under the terms of the GNU Library General Public License as published
14656 + by the Free Software Foundation; either version 2, or (at your option)
14657 + any later version.
14659 + This program is distributed in the hope that it will be useful,
14660 + but WITHOUT ANY WARRANTY; without even the implied warranty of
14661 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14662 + Library General Public License for more details.
14664 + You should have received a copy of the GNU Library General Public
14665 + License along with this program; if not, write to the Free Software
14666 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
14669 +/* The bison generated parser uses alloca. AIX 3 forces us to put this
14670 + declaration at the beginning of the file. The declaration in bison's
14671 + skeleton file comes too late. This must come before <config.h>
14672 + because <config.h> may include arbitrary system headers. */
14673 +#if defined _AIX && !defined __GNUC__
14677 +#ifdef HAVE_CONFIG_H
14678 +# include <config.h>
14681 +#include <stddef.h>
14682 +#include <stdlib.h>
14683 +#include "plural-exp.h"
14685 +/* The main function generated by the parser is called __gettextparse,
14686 + but we want it to be called PLURAL_PARSE. */
14688 +# define __gettextparse PLURAL_PARSE
14691 +#define YYLEX_PARAM &((struct parse_args *) arg)->cp
14692 +#define YYPARSE_PARAM arg
14698 + unsigned long int num;
14699 + enum operator op;
14700 + struct expression *exp;
14704 +/* Prototypes for local functions. */
14705 +static int yylex (YYSTYPE *lval, const char **pexp);
14706 +static void yyerror (const char *str);
14708 +/* Allocation of expressions. */
14710 +static struct expression *
14711 +new_exp (int nargs, enum operator op, struct expression * const *args)
14714 + struct expression *newp;
14716 + /* If any of the argument could not be malloc'ed, just return NULL. */
14717 + for (i = nargs - 1; i >= 0; i--)
14718 + if (args[i] == NULL)
14721 + /* Allocate a new expression. */
14722 + newp = (struct expression *) malloc (sizeof (*newp));
14723 + if (newp != NULL)
14725 + newp->nargs = nargs;
14726 + newp->operation = op;
14727 + for (i = nargs - 1; i >= 0; i--)
14728 + newp->val.args[i] = args[i];
14733 + for (i = nargs - 1; i >= 0; i--)
14734 + FREE_EXPRESSION (args[i]);
14739 +static inline struct expression *
14740 +new_exp_0 (enum operator op)
14742 + return new_exp (0, op, NULL);
14745 +static inline struct expression *
14746 +new_exp_1 (enum operator op, struct expression *right)
14748 + struct expression *args[1];
14751 + return new_exp (1, op, args);
14754 +static struct expression *
14755 +new_exp_2 (enum operator op, struct expression *left, struct expression *right)
14757 + struct expression *args[2];
14761 + return new_exp (2, op, args);
14764 +static inline struct expression *
14765 +new_exp_3 (enum operator op, struct expression *bexp,
14766 + struct expression *tbranch, struct expression *fbranch)
14768 + struct expression *args[3];
14771 + args[1] = tbranch;
14772 + args[2] = fbranch;
14773 + return new_exp (3, op, args);
14778 +/* This declares that all operators have the same associativity and the
14779 + precedence order as in C. See [Harbison, Steele: C, A Reference Manual].
14780 + There is no unary minus and no bitwise operators.
14781 + Operators with the same syntactic behaviour have been merged into a single
14782 + token, to save space in the array generated by bison. */
14783 +%right '?' /* ? */
14784 +%left '|' /* || */
14785 +%left '&' /* && */
14786 +%left EQUOP2 /* == != */
14787 +%left CMPOP2 /* < > <= >= */
14788 +%left ADDOP2 /* + - */
14789 +%left MULOP2 /* * / % */
14790 +%right '!' /* ! */
14792 +%token <op> EQUOP2 CMPOP2 ADDOP2 MULOP2
14793 +%token <num> NUMBER
14802 + ((struct parse_args *) arg)->res = $1;
14806 +exp: exp '?' exp ':' exp
14808 + $$ = new_exp_3 (qmop, $1, $3, $5);
14812 + $$ = new_exp_2 (lor, $1, $3);
14816 + $$ = new_exp_2 (land, $1, $3);
14820 + $$ = new_exp_2 ($2, $1, $3);
14824 + $$ = new_exp_2 ($2, $1, $3);
14828 + $$ = new_exp_2 ($2, $1, $3);
14832 + $$ = new_exp_2 ($2, $1, $3);
14836 + $$ = new_exp_1 (lnot, $2);
14840 + $$ = new_exp_0 (var);
14844 + if (($$ = new_exp_0 (num)) != NULL)
14845 + $$->val.num = $1;
14857 +FREE_EXPRESSION (struct expression *exp)
14862 + /* Handle the recursive case. */
14863 + switch (exp->nargs)
14866 + FREE_EXPRESSION (exp->val.args[2]);
14867 + /* FALLTHROUGH */
14869 + FREE_EXPRESSION (exp->val.args[1]);
14870 + /* FALLTHROUGH */
14872 + FREE_EXPRESSION (exp->val.args[0]);
14873 + /* FALLTHROUGH */
14883 +yylex (YYSTYPE *lval, const char **pexp)
14885 + const char *exp = *pexp;
14890 + if (exp[0] == '\0')
14896 + if (exp[0] != ' ' && exp[0] != '\t')
14905 + case '0': case '1': case '2': case '3': case '4':
14906 + case '5': case '6': case '7': case '8': case '9':
14908 + unsigned long int n = result - '0';
14909 + while (exp[0] >= '0' && exp[0] <= '9')
14912 + n += exp[0] - '0';
14921 + if (exp[0] == '=')
14924 + lval->op = equal;
14928 + result = YYERRCODE;
14932 + if (exp[0] == '=')
14935 + lval->op = not_equal;
14942 + if (exp[0] == result)
14945 + result = YYERRCODE;
14949 + if (exp[0] == '=')
14952 + lval->op = less_or_equal;
14955 + lval->op = less_than;
14960 + if (exp[0] == '=')
14963 + lval->op = greater_or_equal;
14966 + lval->op = greater_than;
14976 + lval->op = divide;
14981 + lval->op = module;
14991 + lval->op = minus;
15000 + /* Nothing, just return the character. */
15006 + /* Be safe and let the user call this function again. */
15012 + result = YYERRCODE;
15026 +yyerror (const char *str)
15028 + /* Do nothing. We don't print error messages here. */
15030 --- lrzsz-0.12.20.safe/intl/po2tbl.sed.in 1998-04-26 09:20:52.000000000 -0400
15031 +++ lrzsz-0.12.20/intl/po2tbl.sed.in 1969-12-31 19:00:00.000000000 -0500
15033 -# po2tbl.sed - Convert Uniforum style .po file to lookup table for catgets
15034 -# Copyright (C) 1995 Free Software Foundation, Inc.
15035 -# Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
15037 -# This program is free software; you can redistribute it and/or modify
15038 -# it under the terms of the GNU General Public License as published by
15039 -# the Free Software Foundation; either version 2, or (at your option)
15040 -# any later version.
15042 -# This program is distributed in the hope that it will be useful,
15043 -# but WITHOUT ANY WARRANTY; without even the implied warranty of
15044 -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15045 -# GNU General Public License for more details.
15047 -# You should have received a copy of the GNU General Public License
15048 -# along with this program; if not, write to the Free Software
15049 -# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
15053 -/* Automatically generated by po2tbl.sed from @PACKAGE NAME@.pot. */\
15055 -#if HAVE_CONFIG_H\
15056 -# include <config.h>\
15059 -#include "libgettext.h"\
15061 -const struct _msg_ent _msg_tbl[] = {
15067 -# Write msgid entries in C array form.
15070 - s/msgid[ ]*\(".*"\)/ {\1/
15072 -# Append the next line
15075 -# Look whether second part is continuation line.
15076 - s/\(.*\)"\(\n\)"\(.*"\)/\1\2\3/
15077 -# Yes, then branch.
15079 -# Because we assume that the input file correctly formed the line
15080 -# just read cannot be again be a msgid line. So it's safe to ignore
15084 -# We found a continuation line. But before printing insert '\'.
15086 - s/\(.*\)\(\n.*\)/\1\\\2/
15088 -# We cannot use D here.
15090 -# Some buggy seds do not clear the `successful substitution since last ``t'''
15091 -# flag on `N', so we do a `t' here to clear it.
15096 -# The following nice solution is by
15097 -# Bruno <Haible@ma2s2.mathematik.uni-karlsruhe.de>
15099 -# Increment a decimal number in pattern space.
15100 -# First hide trailing `9' digits.
15104 -# Assure at least one digit is available.
15106 -# Increment the last digit.
15116 -# Convert the hidden `9' digits to `0's.
15120 - s/\(.*\)\n\([0-9]*\)/\1, \2},/
15132 - s/0*\(.*\)/int _msg_tbl_length = \1;/p
15135 --- lrzsz-0.12.20.safe/intl/printf-args.c 1969-12-31 19:00:00.000000000 -0500
15136 +++ lrzsz-0.12.20/intl/printf-args.c 2004-09-12 14:40:34.595711608 -0400
15138 +/* Decomposed printf argument list.
15139 + Copyright (C) 1999, 2002-2003 Free Software Foundation, Inc.
15141 + This program is free software; you can redistribute it and/or modify it
15142 + under the terms of the GNU Library General Public License as published
15143 + by the Free Software Foundation; either version 2, or (at your option)
15144 + any later version.
15146 + This program is distributed in the hope that it will be useful,
15147 + but WITHOUT ANY WARRANTY; without even the implied warranty of
15148 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15149 + Library General Public License for more details.
15151 + You should have received a copy of the GNU Library General Public
15152 + License along with this program; if not, write to the Free Software
15153 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
15156 +#ifdef HAVE_CONFIG_H
15157 +# include <config.h>
15160 +/* Specification. */
15161 +#include "printf-args.h"
15167 +printf_fetchargs (va_list args, arguments *a)
15172 + for (i = 0, ap = &a->arg[0]; i < a->count; i++, ap++)
15173 + switch (ap->type)
15176 + ap->a.a_schar = va_arg (args, /*signed char*/ int);
15179 + ap->a.a_uchar = va_arg (args, /*unsigned char*/ int);
15182 + ap->a.a_short = va_arg (args, /*short*/ int);
15184 + case TYPE_USHORT:
15185 + ap->a.a_ushort = va_arg (args, /*unsigned short*/ int);
15188 + ap->a.a_int = va_arg (args, int);
15191 + ap->a.a_uint = va_arg (args, unsigned int);
15193 + case TYPE_LONGINT:
15194 + ap->a.a_longint = va_arg (args, long int);
15196 + case TYPE_ULONGINT:
15197 + ap->a.a_ulongint = va_arg (args, unsigned long int);
15199 +#ifdef HAVE_LONG_LONG
15200 + case TYPE_LONGLONGINT:
15201 + ap->a.a_longlongint = va_arg (args, long long int);
15203 + case TYPE_ULONGLONGINT:
15204 + ap->a.a_ulonglongint = va_arg (args, unsigned long long int);
15207 + case TYPE_DOUBLE:
15208 + ap->a.a_double = va_arg (args, double);
15210 +#ifdef HAVE_LONG_DOUBLE
15211 + case TYPE_LONGDOUBLE:
15212 + ap->a.a_longdouble = va_arg (args, long double);
15216 + ap->a.a_char = va_arg (args, int);
15218 +#ifdef HAVE_WINT_T
15219 + case TYPE_WIDE_CHAR:
15220 + ap->a.a_wide_char = va_arg (args, wint_t);
15223 + case TYPE_STRING:
15224 + ap->a.a_string = va_arg (args, const char *);
15226 +#ifdef HAVE_WCHAR_T
15227 + case TYPE_WIDE_STRING:
15228 + ap->a.a_wide_string = va_arg (args, const wchar_t *);
15231 + case TYPE_POINTER:
15232 + ap->a.a_pointer = va_arg (args, void *);
15234 + case TYPE_COUNT_SCHAR_POINTER:
15235 + ap->a.a_count_schar_pointer = va_arg (args, signed char *);
15237 + case TYPE_COUNT_SHORT_POINTER:
15238 + ap->a.a_count_short_pointer = va_arg (args, short *);
15240 + case TYPE_COUNT_INT_POINTER:
15241 + ap->a.a_count_int_pointer = va_arg (args, int *);
15243 + case TYPE_COUNT_LONGINT_POINTER:
15244 + ap->a.a_count_longint_pointer = va_arg (args, long int *);
15246 +#ifdef HAVE_LONG_LONG
15247 + case TYPE_COUNT_LONGLONGINT_POINTER:
15248 + ap->a.a_count_longlongint_pointer = va_arg (args, long long int *);
15252 + /* Unknown type. */
15257 --- lrzsz-0.12.20.safe/intl/printf-args.h 1969-12-31 19:00:00.000000000 -0500
15258 +++ lrzsz-0.12.20/intl/printf-args.h 2004-09-12 14:40:34.601710696 -0400
15260 +/* Decomposed printf argument list.
15261 + Copyright (C) 1999, 2002-2003 Free Software Foundation, Inc.
15263 + This program is free software; you can redistribute it and/or modify it
15264 + under the terms of the GNU Library General Public License as published
15265 + by the Free Software Foundation; either version 2, or (at your option)
15266 + any later version.
15268 + This program is distributed in the hope that it will be useful,
15269 + but WITHOUT ANY WARRANTY; without even the implied warranty of
15270 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15271 + Library General Public License for more details.
15273 + You should have received a copy of the GNU Library General Public
15274 + License along with this program; if not, write to the Free Software
15275 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
15278 +#ifndef _PRINTF_ARGS_H
15279 +#define _PRINTF_ARGS_H
15282 +#include <stddef.h>
15284 +/* Get wchar_t. */
15285 +#ifdef HAVE_WCHAR_T
15286 +# include <stddef.h>
15290 +#ifdef HAVE_WINT_T
15291 +# include <wchar.h>
15294 +/* Get va_list. */
15295 +#include <stdarg.h>
15298 +/* Argument types */
15310 +#ifdef HAVE_LONG_LONG
15311 + TYPE_LONGLONGINT,
15312 + TYPE_ULONGLONGINT,
15315 +#ifdef HAVE_LONG_DOUBLE
15319 +#ifdef HAVE_WINT_T
15323 +#ifdef HAVE_WCHAR_T
15324 + TYPE_WIDE_STRING,
15327 + TYPE_COUNT_SCHAR_POINTER,
15328 + TYPE_COUNT_SHORT_POINTER,
15329 + TYPE_COUNT_INT_POINTER,
15330 + TYPE_COUNT_LONGINT_POINTER
15331 +#ifdef HAVE_LONG_LONG
15332 +, TYPE_COUNT_LONGLONGINT_POINTER
15336 +/* Polymorphic argument */
15342 + signed char a_schar;
15343 + unsigned char a_uchar;
15345 + unsigned short a_ushort;
15347 + unsigned int a_uint;
15348 + long int a_longint;
15349 + unsigned long int a_ulongint;
15350 +#ifdef HAVE_LONG_LONG
15351 + long long int a_longlongint;
15352 + unsigned long long int a_ulonglongint;
15356 +#ifdef HAVE_LONG_DOUBLE
15357 + long double a_longdouble;
15360 +#ifdef HAVE_WINT_T
15361 + wint_t a_wide_char;
15363 + const char* a_string;
15364 +#ifdef HAVE_WCHAR_T
15365 + const wchar_t* a_wide_string;
15368 + signed char * a_count_schar_pointer;
15369 + short * a_count_short_pointer;
15370 + int * a_count_int_pointer;
15371 + long int * a_count_longint_pointer;
15372 +#ifdef HAVE_LONG_LONG
15373 + long long int * a_count_longlongint_pointer;
15388 +/* Fetch the arguments, putting them into a. */
15394 +int printf_fetchargs (va_list args, arguments *a);
15396 +#endif /* _PRINTF_ARGS_H */
15397 --- lrzsz-0.12.20.safe/intl/printf.c 1969-12-31 19:00:00.000000000 -0500
15398 +++ lrzsz-0.12.20/intl/printf.c 2004-09-12 14:40:34.607709784 -0400
15400 +/* Formatted output to strings, using POSIX/XSI format strings with positions.
15401 + Copyright (C) 2003 Free Software Foundation, Inc.
15402 + Written by Bruno Haible <bruno@clisp.org>, 2003.
15404 + This program is free software; you can redistribute it and/or modify it
15405 + under the terms of the GNU Library General Public License as published
15406 + by the Free Software Foundation; either version 2, or (at your option)
15407 + any later version.
15409 + This program is distributed in the hope that it will be useful,
15410 + but WITHOUT ANY WARRANTY; without even the implied warranty of
15411 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15412 + Library General Public License for more details.
15414 + You should have received a copy of the GNU Library General Public
15415 + License along with this program; if not, write to the Free Software
15416 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
15419 +#ifdef HAVE_CONFIG_H
15420 +# include <config.h>
15424 +# define alloca __builtin_alloca
15425 +# define HAVE_ALLOCA 1
15428 +# include <malloc.h>
15429 +# define alloca _alloca
15431 +# if defined HAVE_ALLOCA_H || defined _LIBC
15432 +# include <alloca.h>
15445 +#include <stdio.h>
15447 +#if !HAVE_POSIX_PRINTF
15449 +#include <stdlib.h>
15450 +#include <string.h>
15452 +/* When building a DLL, we must export some functions. Note that because
15453 + the functions are only defined for binary backward compatibility, we
15454 + don't need to use __declspec(dllimport) in any case. */
15455 +#if defined _MSC_VER && BUILDING_DLL
15456 +# define DLL_EXPORTED __declspec(dllexport)
15458 +# define DLL_EXPORTED
15461 +#define STATIC static
15463 +/* Define auxiliary functions declared in "printf-args.h". */
15464 +#include "printf-args.c"
15466 +/* Define auxiliary functions declared in "printf-parse.h". */
15467 +#include "printf-parse.c"
15469 +/* Define functions declared in "vasnprintf.h". */
15470 +#define vasnprintf libintl_vasnprintf
15471 +#include "vasnprintf.c"
15472 +#if 0 /* not needed */
15473 +#define asnprintf libintl_asnprintf
15474 +#include "asnprintf.c"
15479 +libintl_vfprintf (FILE *stream, const char *format, va_list args)
15481 + if (strchr (format, '$') == NULL)
15482 + return vfprintf (stream, format, args);
15486 + char *result = libintl_vasnprintf (NULL, &length, format, args);
15488 + if (result != NULL)
15490 + if (fwrite (result, 1, length, stream) == length)
15500 +libintl_fprintf (FILE *stream, const char *format, ...)
15505 + va_start (args, format);
15506 + retval = libintl_vfprintf (stream, format, args);
15513 +libintl_vprintf (const char *format, va_list args)
15515 + return libintl_vfprintf (stdout, format, args);
15520 +libintl_printf (const char *format, ...)
15525 + va_start (args, format);
15526 + retval = libintl_vprintf (format, args);
15533 +libintl_vsprintf (char *resultbuf, const char *format, va_list args)
15535 + if (strchr (format, '$') == NULL)
15536 + return vsprintf (resultbuf, format, args);
15539 + size_t length = (size_t) ~0 / (4 * sizeof (char));
15540 + char *result = libintl_vasnprintf (resultbuf, &length, format, args);
15541 + if (result != resultbuf)
15553 +libintl_sprintf (char *resultbuf, const char *format, ...)
15558 + va_start (args, format);
15559 + retval = libintl_vsprintf (resultbuf, format, args);
15566 +# if HAVE_DECL__SNPRINTF
15568 +# define system_vsnprintf _vsnprintf
15571 +# define system_vsnprintf vsnprintf
15576 +libintl_vsnprintf (char *resultbuf, size_t length, const char *format, va_list args)
15578 + if (strchr (format, '$') == NULL)
15579 + return system_vsnprintf (resultbuf, length, format, args);
15582 + size_t maxlength = length;
15583 + char *result = libintl_vasnprintf (resultbuf, &length, format, args);
15584 + if (result != resultbuf)
15586 + if (maxlength > 0)
15588 + if (length < maxlength)
15590 + memcpy (resultbuf, result, maxlength - 1);
15591 + resultbuf[maxlength - 1] = '\0';
15603 +libintl_snprintf (char *resultbuf, size_t length, const char *format, ...)
15608 + va_start (args, format);
15609 + retval = libintl_vsnprintf (resultbuf, length, format, args);
15620 +libintl_vasprintf (char **resultp, const char *format, va_list args)
15623 + char *result = libintl_vasnprintf (NULL, &length, format, args);
15624 + if (result == NULL)
15626 + *resultp = result;
15632 +libintl_asprintf (char **resultp, const char *format, ...)
15637 + va_start (args, format);
15638 + retval = libintl_vasprintf (resultp, format, args);
15647 +#include <wchar.h>
15649 +#define WIDE_CHAR_VERSION 1
15651 +/* Define auxiliary functions declared in "wprintf-parse.h". */
15652 +#include "printf-parse.c"
15654 +/* Define functions declared in "vasnprintf.h". */
15655 +#define vasnwprintf libintl_vasnwprintf
15656 +#include "vasnprintf.c"
15657 +#if 0 /* not needed */
15658 +#define asnwprintf libintl_asnwprintf
15659 +#include "asnprintf.c"
15662 +# if HAVE_DECL__SNWPRINTF
15664 +# define system_vswprintf _vsnwprintf
15667 +# define system_vswprintf vswprintf
15672 +libintl_vfwprintf (FILE *stream, const wchar_t *format, va_list args)
15674 + if (wcschr (format, '$') == NULL)
15675 + return vfwprintf (stream, format, args);
15679 + wchar_t *result = libintl_vasnwprintf (NULL, &length, format, args);
15681 + if (result != NULL)
15684 + for (i = 0; i < length; i++)
15685 + if (fputwc (result[i], stream) == WEOF)
15697 +libintl_fwprintf (FILE *stream, const wchar_t *format, ...)
15702 + va_start (args, format);
15703 + retval = libintl_vfwprintf (stream, format, args);
15710 +libintl_vwprintf (const wchar_t *format, va_list args)
15712 + return libintl_vfwprintf (stdout, format, args);
15717 +libintl_wprintf (const wchar_t *format, ...)
15722 + va_start (args, format);
15723 + retval = libintl_vwprintf (format, args);
15730 +libintl_vswprintf (wchar_t *resultbuf, size_t length, const wchar_t *format, va_list args)
15732 + if (wcschr (format, '$') == NULL)
15733 + return system_vswprintf (resultbuf, length, format, args);
15736 + size_t maxlength = length;
15737 + wchar_t *result = libintl_vasnwprintf (resultbuf, &length, format, args);
15738 + if (result != resultbuf)
15740 + if (maxlength > 0)
15742 + if (length < maxlength)
15744 + memcpy (resultbuf, result, (maxlength - 1) * sizeof (wchar_t));
15745 + resultbuf[maxlength - 1] = 0;
15757 +libintl_swprintf (wchar_t *resultbuf, size_t length, const wchar_t *format, ...)
15762 + va_start (args, format);
15763 + retval = libintl_vswprintf (resultbuf, length, format, args);
15771 --- lrzsz-0.12.20.safe/intl/printf-parse.c 1969-12-31 19:00:00.000000000 -0500
15772 +++ lrzsz-0.12.20/intl/printf-parse.c 2004-09-12 14:40:34.622707504 -0400
15774 +/* Formatted output to strings.
15775 + Copyright (C) 1999-2000, 2002-2003 Free Software Foundation, Inc.
15777 + This program is free software; you can redistribute it and/or modify it
15778 + under the terms of the GNU Library General Public License as published
15779 + by the Free Software Foundation; either version 2, or (at your option)
15780 + any later version.
15782 + This program is distributed in the hope that it will be useful,
15783 + but WITHOUT ANY WARRANTY; without even the implied warranty of
15784 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15785 + Library General Public License for more details.
15787 + You should have received a copy of the GNU Library General Public
15788 + License along with this program; if not, write to the Free Software
15789 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
15792 +#ifdef HAVE_CONFIG_H
15793 +# include <config.h>
15796 +/* Specification. */
15797 +#if WIDE_CHAR_VERSION
15798 +# include "wprintf-parse.h"
15800 +# include "printf-parse.h"
15803 +/* Get size_t, NULL. */
15804 +#include <stddef.h>
15806 +/* Get intmax_t. */
15807 +#if HAVE_STDINT_H_WITH_UINTMAX
15808 +# include <stdint.h>
15810 +#if HAVE_INTTYPES_H_WITH_UINTMAX
15811 +# include <inttypes.h>
15814 +/* malloc(), realloc(), free(). */
15815 +#include <stdlib.h>
15817 +/* Checked size_t computations. */
15818 +#include "xsize.h"
15820 +#if WIDE_CHAR_VERSION
15821 +# define PRINTF_PARSE wprintf_parse
15822 +# define CHAR_T wchar_t
15823 +# define DIRECTIVE wchar_t_directive
15824 +# define DIRECTIVES wchar_t_directives
15826 +# define PRINTF_PARSE printf_parse
15827 +# define CHAR_T char
15828 +# define DIRECTIVE char_directive
15829 +# define DIRECTIVES char_directives
15836 +PRINTF_PARSE (const CHAR_T *format, DIRECTIVES *d, arguments *a)
15838 + const CHAR_T *cp = format; /* pointer into format */
15839 + size_t arg_posn = 0; /* number of regular arguments consumed */
15840 + size_t d_allocated; /* allocated elements of d->dir */
15841 + size_t a_allocated; /* allocated elements of a->arg */
15842 + size_t max_width_length = 0;
15843 + size_t max_precision_length = 0;
15847 + d->dir = malloc (d_allocated * sizeof (DIRECTIVE));
15848 + if (d->dir == NULL)
15849 + /* Out of memory. */
15856 +#define REGISTER_ARG(_index_,_type_) \
15858 + size_t n = (_index_); \
15859 + if (n >= a_allocated) \
15861 + size_t memory_size; \
15862 + argument *memory; \
15864 + a_allocated = xtimes (a_allocated, 2); \
15865 + if (a_allocated <= n) \
15866 + a_allocated = xsum (n, 1); \
15867 + memory_size = xtimes (a_allocated, sizeof (argument)); \
15868 + if (size_overflow_p (memory_size)) \
15869 + /* Overflow, would lead to out of memory. */ \
15871 + memory = (a->arg \
15872 + ? realloc (a->arg, memory_size) \
15873 + : malloc (memory_size)); \
15874 + if (memory == NULL) \
15875 + /* Out of memory. */ \
15877 + a->arg = memory; \
15879 + while (a->count <= n) \
15880 + a->arg[a->count++].type = TYPE_NONE; \
15881 + if (a->arg[n].type == TYPE_NONE) \
15882 + a->arg[n].type = (_type_); \
15883 + else if (a->arg[n].type != (_type_)) \
15884 + /* Ambiguous type for positional argument. */ \
15888 + while (*cp != '\0')
15890 + CHAR_T c = *cp++;
15893 + size_t arg_index = ARG_NONE;
15894 + DIRECTIVE *dp = &d->dir[d->count];/* pointer to next directive */
15896 + /* Initialize the next directive. */
15897 + dp->dir_start = cp - 1;
15899 + dp->width_start = NULL;
15900 + dp->width_end = NULL;
15901 + dp->width_arg_index = ARG_NONE;
15902 + dp->precision_start = NULL;
15903 + dp->precision_end = NULL;
15904 + dp->precision_arg_index = ARG_NONE;
15905 + dp->arg_index = ARG_NONE;
15907 + /* Test for positional argument. */
15908 + if (*cp >= '0' && *cp <= '9')
15910 + const CHAR_T *np;
15912 + for (np = cp; *np >= '0' && *np <= '9'; np++)
15918 + for (np = cp; *np >= '0' && *np <= '9'; np++)
15919 + n = xsum (xtimes (n, 10), *np - '0');
15921 + /* Positional argument 0. */
15923 + if (size_overflow_p (n))
15924 + /* n too large, would lead to out of memory later. */
15926 + arg_index = n - 1;
15931 + /* Read the flags. */
15936 + dp->flags |= FLAG_GROUP;
15939 + else if (*cp == '-')
15941 + dp->flags |= FLAG_LEFT;
15944 + else if (*cp == '+')
15946 + dp->flags |= FLAG_SHOWSIGN;
15949 + else if (*cp == ' ')
15951 + dp->flags |= FLAG_SPACE;
15954 + else if (*cp == '#')
15956 + dp->flags |= FLAG_ALT;
15959 + else if (*cp == '0')
15961 + dp->flags |= FLAG_ZERO;
15968 + /* Parse the field width. */
15971 + dp->width_start = cp;
15973 + dp->width_end = cp;
15974 + if (max_width_length < 1)
15975 + max_width_length = 1;
15977 + /* Test for positional argument. */
15978 + if (*cp >= '0' && *cp <= '9')
15980 + const CHAR_T *np;
15982 + for (np = cp; *np >= '0' && *np <= '9'; np++)
15988 + for (np = cp; *np >= '0' && *np <= '9'; np++)
15989 + n = xsum (xtimes (n, 10), *np - '0');
15991 + /* Positional argument 0. */
15993 + if (size_overflow_p (n))
15994 + /* n too large, would lead to out of memory later. */
15996 + dp->width_arg_index = n - 1;
16000 + if (dp->width_arg_index == ARG_NONE)
16002 + dp->width_arg_index = arg_posn++;
16003 + if (dp->width_arg_index == ARG_NONE)
16004 + /* arg_posn wrapped around. */
16007 + REGISTER_ARG (dp->width_arg_index, TYPE_INT);
16009 + else if (*cp >= '0' && *cp <= '9')
16011 + size_t width_length;
16013 + dp->width_start = cp;
16014 + for (; *cp >= '0' && *cp <= '9'; cp++)
16016 + dp->width_end = cp;
16017 + width_length = dp->width_end - dp->width_start;
16018 + if (max_width_length < width_length)
16019 + max_width_length = width_length;
16022 + /* Parse the precision. */
16028 + dp->precision_start = cp - 1;
16030 + dp->precision_end = cp;
16031 + if (max_precision_length < 2)
16032 + max_precision_length = 2;
16034 + /* Test for positional argument. */
16035 + if (*cp >= '0' && *cp <= '9')
16037 + const CHAR_T *np;
16039 + for (np = cp; *np >= '0' && *np <= '9'; np++)
16045 + for (np = cp; *np >= '0' && *np <= '9'; np++)
16046 + n = xsum (xtimes (n, 10), *np - '0');
16048 + /* Positional argument 0. */
16050 + if (size_overflow_p (n))
16051 + /* n too large, would lead to out of memory
16054 + dp->precision_arg_index = n - 1;
16058 + if (dp->precision_arg_index == ARG_NONE)
16060 + dp->precision_arg_index = arg_posn++;
16061 + if (dp->precision_arg_index == ARG_NONE)
16062 + /* arg_posn wrapped around. */
16065 + REGISTER_ARG (dp->precision_arg_index, TYPE_INT);
16069 + size_t precision_length;
16071 + dp->precision_start = cp - 1;
16072 + for (; *cp >= '0' && *cp <= '9'; cp++)
16074 + dp->precision_end = cp;
16075 + precision_length = dp->precision_end - dp->precision_start;
16076 + if (max_precision_length < precision_length)
16077 + max_precision_length = precision_length;
16084 + /* Parse argument type/size specifiers. */
16092 + flags |= (1 << (flags & 1));
16095 + else if (*cp == 'L')
16100 + else if (*cp == 'l')
16105 +#ifdef HAVE_INTMAX_T
16106 + else if (*cp == 'j')
16108 + if (sizeof (intmax_t) > sizeof (long))
16110 + /* intmax_t = long long */
16113 + else if (sizeof (intmax_t) > sizeof (int))
16115 + /* intmax_t = long */
16121 + else if (*cp == 'z' || *cp == 'Z')
16123 + /* 'z' is standardized in ISO C 99, but glibc uses 'Z'
16124 + because the warning facility in gcc-2.95.2 understands
16125 + only 'Z' (see gcc-2.95.2/gcc/c-common.c:1784). */
16126 + if (sizeof (size_t) > sizeof (long))
16128 + /* size_t = long long */
16131 + else if (sizeof (size_t) > sizeof (int))
16133 + /* size_t = long */
16138 + else if (*cp == 't')
16140 + if (sizeof (ptrdiff_t) > sizeof (long))
16142 + /* ptrdiff_t = long long */
16145 + else if (sizeof (ptrdiff_t) > sizeof (int))
16147 + /* ptrdiff_t = long */
16156 + /* Read the conversion character. */
16160 + case 'd': case 'i':
16161 +#ifdef HAVE_LONG_LONG
16162 + if (flags >= 16 || (flags & 4))
16163 + type = TYPE_LONGLONGINT;
16167 + type = TYPE_LONGINT;
16168 + else if (flags & 2)
16169 + type = TYPE_SCHAR;
16170 + else if (flags & 1)
16171 + type = TYPE_SHORT;
16175 + case 'o': case 'u': case 'x': case 'X':
16176 +#ifdef HAVE_LONG_LONG
16177 + if (flags >= 16 || (flags & 4))
16178 + type = TYPE_ULONGLONGINT;
16182 + type = TYPE_ULONGINT;
16183 + else if (flags & 2)
16184 + type = TYPE_UCHAR;
16185 + else if (flags & 1)
16186 + type = TYPE_USHORT;
16188 + type = TYPE_UINT;
16190 + case 'f': case 'F': case 'e': case 'E': case 'g': case 'G':
16191 + case 'a': case 'A':
16192 +#ifdef HAVE_LONG_DOUBLE
16193 + if (flags >= 16 || (flags & 4))
16194 + type = TYPE_LONGDOUBLE;
16197 + type = TYPE_DOUBLE;
16201 +#ifdef HAVE_WINT_T
16202 + type = TYPE_WIDE_CHAR;
16207 + type = TYPE_CHAR;
16209 +#ifdef HAVE_WINT_T
16211 + type = TYPE_WIDE_CHAR;
16217 +#ifdef HAVE_WCHAR_T
16218 + type = TYPE_WIDE_STRING;
16223 + type = TYPE_STRING;
16225 +#ifdef HAVE_WCHAR_T
16227 + type = TYPE_WIDE_STRING;
16232 + type = TYPE_POINTER;
16235 +#ifdef HAVE_LONG_LONG
16236 + if (flags >= 16 || (flags & 4))
16237 + type = TYPE_COUNT_LONGLONGINT_POINTER;
16241 + type = TYPE_COUNT_LONGINT_POINTER;
16242 + else if (flags & 2)
16243 + type = TYPE_COUNT_SCHAR_POINTER;
16244 + else if (flags & 1)
16245 + type = TYPE_COUNT_SHORT_POINTER;
16247 + type = TYPE_COUNT_INT_POINTER;
16250 + type = TYPE_NONE;
16253 + /* Unknown conversion character. */
16258 + if (type != TYPE_NONE)
16260 + dp->arg_index = arg_index;
16261 + if (dp->arg_index == ARG_NONE)
16263 + dp->arg_index = arg_posn++;
16264 + if (dp->arg_index == ARG_NONE)
16265 + /* arg_posn wrapped around. */
16268 + REGISTER_ARG (dp->arg_index, type);
16270 + dp->conversion = c;
16271 + dp->dir_end = cp;
16275 + if (d->count >= d_allocated)
16277 + size_t memory_size;
16278 + DIRECTIVE *memory;
16280 + d_allocated = xtimes (d_allocated, 2);
16281 + memory_size = xtimes (d_allocated, sizeof (DIRECTIVE));
16282 + if (size_overflow_p (memory_size))
16283 + /* Overflow, would lead to out of memory. */
16285 + memory = realloc (d->dir, memory_size);
16286 + if (memory == NULL)
16287 + /* Out of memory. */
16293 + d->dir[d->count].dir_start = cp;
16295 + d->max_width_length = max_width_length;
16296 + d->max_precision_length = max_precision_length;
16310 +#undef PRINTF_PARSE
16311 --- lrzsz-0.12.20.safe/intl/printf-parse.h 1969-12-31 19:00:00.000000000 -0500
16312 +++ lrzsz-0.12.20/intl/printf-parse.h 2004-09-12 14:40:34.628706592 -0400
16314 +/* Parse printf format string.
16315 + Copyright (C) 1999, 2002-2003 Free Software Foundation, Inc.
16317 + This program is free software; you can redistribute it and/or modify it
16318 + under the terms of the GNU Library General Public License as published
16319 + by the Free Software Foundation; either version 2, or (at your option)
16320 + any later version.
16322 + This program is distributed in the hope that it will be useful,
16323 + but WITHOUT ANY WARRANTY; without even the implied warranty of
16324 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16325 + Library General Public License for more details.
16327 + You should have received a copy of the GNU Library General Public
16328 + License along with this program; if not, write to the Free Software
16329 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
16332 +#ifndef _PRINTF_PARSE_H
16333 +#define _PRINTF_PARSE_H
16335 +#include "printf-args.h"
16339 +#define FLAG_GROUP 1 /* ' flag */
16340 +#define FLAG_LEFT 2 /* - flag */
16341 +#define FLAG_SHOWSIGN 4 /* + flag */
16342 +#define FLAG_SPACE 8 /* space flag */
16343 +#define FLAG_ALT 16 /* # flag */
16344 +#define FLAG_ZERO 32
16346 +/* arg_index value indicating that no argument is consumed. */
16347 +#define ARG_NONE (~(size_t)0)
16349 +/* A parsed directive. */
16352 + const char* dir_start;
16353 + const char* dir_end;
16355 + const char* width_start;
16356 + const char* width_end;
16357 + size_t width_arg_index;
16358 + const char* precision_start;
16359 + const char* precision_end;
16360 + size_t precision_arg_index;
16361 + char conversion; /* d i o u x X f e E g G c s p n U % but not C S */
16362 + size_t arg_index;
16366 +/* A parsed format string. */
16370 + char_directive *dir;
16371 + size_t max_width_length;
16372 + size_t max_precision_length;
16377 +/* Parses the format string. Fills in the number N of directives, and fills
16378 + in directives[0], ..., directives[N-1], and sets directives[N].dir_start
16379 + to the end of the format string. Also fills in the arg_type fields of the
16380 + arguments and the needed count of arguments. */
16386 +int printf_parse (const char *format, char_directives *d, arguments *a);
16388 +#endif /* _PRINTF_PARSE_H */
16389 --- lrzsz-0.12.20.safe/intl/ref-add.sin 1969-12-31 19:00:00.000000000 -0500
16390 +++ lrzsz-0.12.20/intl/ref-add.sin 2004-09-12 14:40:34.633705832 -0400
16392 +# Add this package to a list of references stored in a text file.
16394 +# Copyright (C) 2000 Free Software Foundation, Inc.
16396 +# This program is free software; you can redistribute it and/or modify it
16397 +# under the terms of the GNU Library General Public License as published
16398 +# by the Free Software Foundation; either version 2, or (at your option)
16399 +# any later version.
16401 +# This program is distributed in the hope that it will be useful,
16402 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
16403 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16404 +# Library General Public License for more details.
16406 +# You should have received a copy of the GNU Library General Public
16407 +# License along with this program; if not, write to the Free Software
16408 +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
16411 +# Written by Bruno Haible <haible@clisp.cons.org>.
16413 +/^# Packages using this file: / {
16414 + s/# Packages using this file://
16417 + s/ @PACKAGE@ / @PACKAGE@ /
16419 + s/ $/ @PACKAGE@ /
16421 + s/^/# Packages using this file:/
16423 --- lrzsz-0.12.20.safe/intl/ref-del.sin 1969-12-31 19:00:00.000000000 -0500
16424 +++ lrzsz-0.12.20/intl/ref-del.sin 2004-09-12 14:40:34.638705072 -0400
16426 +# Remove this package from a list of references stored in a text file.
16428 +# Copyright (C) 2000 Free Software Foundation, Inc.
16430 +# This program is free software; you can redistribute it and/or modify it
16431 +# under the terms of the GNU Library General Public License as published
16432 +# by the Free Software Foundation; either version 2, or (at your option)
16433 +# any later version.
16435 +# This program is distributed in the hope that it will be useful,
16436 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
16437 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16438 +# Library General Public License for more details.
16440 +# You should have received a copy of the GNU Library General Public
16441 +# License along with this program; if not, write to the Free Software
16442 +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
16445 +# Written by Bruno Haible <haible@clisp.cons.org>.
16447 +/^# Packages using this file: / {
16448 + s/# Packages using this file://
16450 + s/^/# Packages using this file:/
16452 --- lrzsz-0.12.20.safe/intl/relocatable.c 1969-12-31 19:00:00.000000000 -0500
16453 +++ lrzsz-0.12.20/intl/relocatable.c 2004-09-12 14:40:34.644704160 -0400
16455 +/* Provide relocatable packages.
16456 + Copyright (C) 2003 Free Software Foundation, Inc.
16457 + Written by Bruno Haible <bruno@clisp.org>, 2003.
16459 + This program is free software; you can redistribute it and/or modify it
16460 + under the terms of the GNU Library General Public License as published
16461 + by the Free Software Foundation; either version 2, or (at your option)
16462 + any later version.
16464 + This program is distributed in the hope that it will be useful,
16465 + but WITHOUT ANY WARRANTY; without even the implied warranty of
16466 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16467 + Library General Public License for more details.
16469 + You should have received a copy of the GNU Library General Public
16470 + License along with this program; if not, write to the Free Software
16471 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
16475 +/* Tell glibc's <stdio.h> to provide a prototype for getline().
16476 + This must come before <config.h> because <config.h> may include
16477 + <features.h>, and once <features.h> has been included, it's too late. */
16478 +#ifndef _GNU_SOURCE
16479 +# define _GNU_SOURCE 1
16482 +#ifdef HAVE_CONFIG_H
16483 +# include "config.h"
16486 +/* Specification. */
16487 +#include "relocatable.h"
16489 +#if ENABLE_RELOCATABLE
16491 +#include <stddef.h>
16492 +#include <stdio.h>
16493 +#include <stdlib.h>
16494 +#include <string.h>
16497 +# define xmalloc malloc
16499 +# include "xalloc.h"
16502 +#if defined _WIN32 || defined __WIN32__
16503 +# define WIN32_LEAN_AND_MEAN
16504 +# include <windows.h>
16507 +#if DEPENDS_ON_LIBCHARSET
16508 +# include <libcharset.h>
16510 +#if DEPENDS_ON_LIBICONV && HAVE_ICONV
16511 +# include <iconv.h>
16513 +#if DEPENDS_ON_LIBINTL && ENABLE_NLS
16514 +# include <libintl.h>
16517 +/* Faked cheap 'bool'. */
16525 +/* Pathname support.
16526 + ISSLASH(C) tests whether C is a directory separator character.
16527 + IS_PATH_WITH_DIR(P) tests whether P contains a directory specification.
16529 +#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
16530 + /* Win32, OS/2, DOS */
16531 +# define ISSLASH(C) ((C) == '/' || (C) == '\\')
16532 +# define HAS_DEVICE(P) \
16533 + ((((P)[0] >= 'A' && (P)[0] <= 'Z') || ((P)[0] >= 'a' && (P)[0] <= 'z')) \
16534 + && (P)[1] == ':')
16535 +# define IS_PATH_WITH_DIR(P) \
16536 + (strchr (P, '/') != NULL || strchr (P, '\\') != NULL || HAS_DEVICE (P))
16537 +# define FILESYSTEM_PREFIX_LEN(P) (HAS_DEVICE (P) ? 2 : 0)
16540 +# define ISSLASH(C) ((C) == '/')
16541 +# define IS_PATH_WITH_DIR(P) (strchr (P, '/') != NULL)
16542 +# define FILESYSTEM_PREFIX_LEN(P) 0
16545 +/* Original installation prefix. */
16546 +static char *orig_prefix;
16547 +static size_t orig_prefix_len;
16548 +/* Current installation prefix. */
16549 +static char *curr_prefix;
16550 +static size_t curr_prefix_len;
16551 +/* These prefixes do not end in a slash. Anything that will be concatenated
16552 + to them must start with a slash. */
16554 +/* Sets the original and the current installation prefix of this module.
16555 + Relocation simply replaces a pathname starting with the original prefix
16556 + by the corresponding pathname with the current prefix instead. Both
16557 + prefixes should be directory names without trailing slash (i.e. use ""
16558 + instead of "/"). */
16560 +set_this_relocation_prefix (const char *orig_prefix_arg,
16561 + const char *curr_prefix_arg)
16563 + if (orig_prefix_arg != NULL && curr_prefix_arg != NULL
16564 + /* Optimization: if orig_prefix and curr_prefix are equal, the
16565 + relocation is a nop. */
16566 + && strcmp (orig_prefix_arg, curr_prefix_arg) != 0)
16568 + /* Duplicate the argument strings. */
16571 + orig_prefix_len = strlen (orig_prefix_arg);
16572 + curr_prefix_len = strlen (curr_prefix_arg);
16573 + memory = (char *) xmalloc (orig_prefix_len + 1 + curr_prefix_len + 1);
16575 + if (memory != NULL)
16578 + memcpy (memory, orig_prefix_arg, orig_prefix_len + 1);
16579 + orig_prefix = memory;
16580 + memory += orig_prefix_len + 1;
16581 + memcpy (memory, curr_prefix_arg, curr_prefix_len + 1);
16582 + curr_prefix = memory;
16586 + orig_prefix = NULL;
16587 + curr_prefix = NULL;
16588 + /* Don't worry about wasted memory here - this function is usually only
16592 +/* Sets the original and the current installation prefix of the package.
16593 + Relocation simply replaces a pathname starting with the original prefix
16594 + by the corresponding pathname with the current prefix instead. Both
16595 + prefixes should be directory names without trailing slash (i.e. use ""
16596 + instead of "/"). */
16598 +set_relocation_prefix (const char *orig_prefix_arg, const char *curr_prefix_arg)
16600 + set_this_relocation_prefix (orig_prefix_arg, curr_prefix_arg);
16602 + /* Now notify all dependent libraries. */
16603 +#if DEPENDS_ON_LIBCHARSET
16604 + libcharset_set_relocation_prefix (orig_prefix_arg, curr_prefix_arg);
16606 +#if DEPENDS_ON_LIBICONV && HAVE_ICONV && _LIBICONV_VERSION >= 0x0109
16607 + libiconv_set_relocation_prefix (orig_prefix_arg, curr_prefix_arg);
16609 +#if DEPENDS_ON_LIBINTL && ENABLE_NLS && defined libintl_set_relocation_prefix
16610 + libintl_set_relocation_prefix (orig_prefix_arg, curr_prefix_arg);
16614 +#if !defined IN_LIBRARY || (defined PIC && defined INSTALLDIR)
16616 +/* Convenience function:
16617 + Computes the current installation prefix, based on the original
16618 + installation prefix, the original installation directory of a particular
16619 + file, and the current pathname of this file. Returns NULL upon failure. */
16621 +#define compute_curr_prefix local_compute_curr_prefix
16625 +compute_curr_prefix (const char *orig_installprefix,
16626 + const char *orig_installdir,
16627 + const char *curr_pathname)
16629 + const char *curr_installdir;
16630 + const char *rel_installdir;
16632 + if (curr_pathname == NULL)
16635 + /* Determine the relative installation directory, relative to the prefix.
16636 + This is simply the difference between orig_installprefix and
16637 + orig_installdir. */
16638 + if (strncmp (orig_installprefix, orig_installdir, strlen (orig_installprefix))
16640 + /* Shouldn't happen - nothing should be installed outside $(prefix). */
16642 + rel_installdir = orig_installdir + strlen (orig_installprefix);
16644 + /* Determine the current installation directory. */
16646 + const char *p_base = curr_pathname + FILESYSTEM_PREFIX_LEN (curr_pathname);
16647 + const char *p = curr_pathname + strlen (curr_pathname);
16650 + while (p > p_base)
16653 + if (ISSLASH (*p))
16657 + q = (char *) xmalloc (p - curr_pathname + 1);
16662 + memcpy (q, curr_pathname, p - curr_pathname);
16663 + q[p - curr_pathname] = '\0';
16664 + curr_installdir = q;
16667 + /* Compute the current installation prefix by removing the trailing
16668 + rel_installdir from it. */
16670 + const char *rp = rel_installdir + strlen (rel_installdir);
16671 + const char *cp = curr_installdir + strlen (curr_installdir);
16672 + const char *cp_base =
16673 + curr_installdir + FILESYSTEM_PREFIX_LEN (curr_installdir);
16675 + while (rp > rel_installdir && cp > cp_base)
16677 + bool same = false;
16678 + const char *rpi = rp;
16679 + const char *cpi = cp;
16681 + while (rpi > rel_installdir && cpi > cp_base)
16685 + if (ISSLASH (*rpi) || ISSLASH (*cpi))
16687 + if (ISSLASH (*rpi) && ISSLASH (*cpi))
16691 +#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
16692 + /* Win32, OS/2, DOS - case insignificant filesystem */
16693 + if ((*rpi >= 'a' && *rpi <= 'z' ? *rpi - 'a' + 'A' : *rpi)
16694 + != (*cpi >= 'a' && *cpi <= 'z' ? *cpi - 'a' + 'A' : *cpi))
16697 + if (*rpi != *cpi)
16703 + /* The last pathname component was the same. opi and cpi now point
16704 + to the slash before it. */
16709 + if (rp > rel_installdir)
16710 + /* Unexpected: The curr_installdir does not end with rel_installdir. */
16714 + size_t curr_prefix_len = cp - curr_installdir;
16715 + char *curr_prefix;
16717 + curr_prefix = (char *) xmalloc (curr_prefix_len + 1);
16719 + if (curr_prefix == NULL)
16722 + memcpy (curr_prefix, curr_installdir, curr_prefix_len);
16723 + curr_prefix[curr_prefix_len] = '\0';
16725 + return curr_prefix;
16730 +#endif /* !IN_LIBRARY || PIC */
16732 +#if defined PIC && defined INSTALLDIR
16734 +/* Full pathname of shared library, or NULL. */
16735 +static char *shared_library_fullname;
16737 +#if defined _WIN32 || defined __WIN32__
16739 +/* Determine the full pathname of the shared library when it is loaded. */
16742 +DllMain (HINSTANCE module_handle, DWORD event, LPVOID reserved)
16746 + if (event == DLL_PROCESS_ATTACH)
16748 + /* The DLL is being loaded into an application's address range. */
16749 + static char location[MAX_PATH];
16751 + if (!GetModuleFileName (module_handle, location, sizeof (location)))
16752 + /* Shouldn't happen. */
16755 + if (!IS_PATH_WITH_DIR (location))
16756 + /* Shouldn't happen. */
16759 + shared_library_fullname = strdup (location);
16768 +find_shared_library_fullname ()
16770 +#if defined __linux__ && __GLIBC__ >= 2
16771 + /* Linux has /proc/self/maps. glibc 2 has the getline() function. */
16774 + /* Open the current process' maps file. It describes one VMA per line. */
16775 + fp = fopen ("/proc/self/maps", "r");
16778 + unsigned long address = (unsigned long) &find_shared_library_fullname;
16781 + unsigned long start, end;
16784 + if (fscanf (fp, "%lx-%lx", &start, &end) != 2)
16786 + if (address >= start && address <= end - 1)
16788 + /* Found it. Now see if this line contains a filename. */
16789 + while (c = getc (fp), c != EOF && c != '\n' && c != '/')
16797 + shared_library_fullname = NULL; size = 0;
16798 + len = getline (&shared_library_fullname, &size, fp);
16801 + /* Success: filled shared_library_fullname. */
16802 + if (len > 0 && shared_library_fullname[len - 1] == '\n')
16803 + shared_library_fullname[len - 1] = '\0';
16808 + while (c = getc (fp), c != EOF && c != '\n')
16816 +#endif /* WIN32 / Unix */
16818 +/* Return the full pathname of the current shared library.
16819 + Return NULL if unknown.
16820 + Guaranteed to work only on Linux and Woe32. */
16822 +get_shared_library_fullname ()
16824 +#if !(defined _WIN32 || defined __WIN32__)
16825 + static bool tried_find_shared_library_fullname;
16826 + if (!tried_find_shared_library_fullname)
16828 + find_shared_library_fullname ();
16829 + tried_find_shared_library_fullname = true;
16832 + return shared_library_fullname;
16837 +/* Returns the pathname, relocated according to the current installation
16840 +relocate (const char *pathname)
16842 +#if defined PIC && defined INSTALLDIR
16843 + static int initialized;
16845 + /* Initialization code for a shared library. */
16846 + if (!initialized)
16848 + /* At this point, orig_prefix and curr_prefix likely have already been
16849 + set through the main program's set_program_name_and_installdir
16850 + function. This is sufficient in the case that the library has
16851 + initially been installed in the same orig_prefix. But we can do
16852 + better, to also cover the cases that 1. it has been installed
16853 + in a different prefix before being moved to orig_prefix and (later)
16854 + to curr_prefix, 2. unlike the program, it has not moved away from
16856 + const char *orig_installprefix = INSTALLPREFIX;
16857 + const char *orig_installdir = INSTALLDIR;
16858 + const char *curr_prefix_better;
16860 + curr_prefix_better =
16861 + compute_curr_prefix (orig_installprefix, orig_installdir,
16862 + get_shared_library_fullname ());
16863 + if (curr_prefix_better == NULL)
16864 + curr_prefix_better = curr_prefix;
16866 + set_relocation_prefix (orig_installprefix, curr_prefix_better);
16872 + /* Note: It is not necessary to perform case insensitive comparison here,
16873 + even for DOS-like filesystems, because the pathname argument was
16874 + typically created from the same Makefile variable as orig_prefix came
16876 + if (orig_prefix != NULL && curr_prefix != NULL
16877 + && strncmp (pathname, orig_prefix, orig_prefix_len) == 0)
16879 + if (pathname[orig_prefix_len] == '\0')
16880 + /* pathname equals orig_prefix. */
16881 + return curr_prefix;
16882 + if (ISSLASH (pathname[orig_prefix_len]))
16884 + /* pathname starts with orig_prefix. */
16885 + const char *pathname_tail = &pathname[orig_prefix_len];
16887 + (char *) xmalloc (curr_prefix_len + strlen (pathname_tail) + 1);
16890 + if (result != NULL)
16893 + memcpy (result, curr_prefix, curr_prefix_len);
16894 + strcpy (result + curr_prefix_len, pathname_tail);
16899 + /* Nothing to relocate. */
16904 --- lrzsz-0.12.20.safe/intl/relocatable.h 1969-12-31 19:00:00.000000000 -0500
16905 +++ lrzsz-0.12.20/intl/relocatable.h 2004-09-12 14:40:34.651703096 -0400
16907 +/* Provide relocatable packages.
16908 + Copyright (C) 2003 Free Software Foundation, Inc.
16909 + Written by Bruno Haible <bruno@clisp.org>, 2003.
16911 + This program is free software; you can redistribute it and/or modify it
16912 + under the terms of the GNU Library General Public License as published
16913 + by the Free Software Foundation; either version 2, or (at your option)
16914 + any later version.
16916 + This program is distributed in the hope that it will be useful,
16917 + but WITHOUT ANY WARRANTY; without even the implied warranty of
16918 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16919 + Library General Public License for more details.
16921 + You should have received a copy of the GNU Library General Public
16922 + License along with this program; if not, write to the Free Software
16923 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
16926 +#ifndef _RELOCATABLE_H
16927 +#define _RELOCATABLE_H
16929 +#ifdef __cplusplus
16934 +/* This can be enabled through the configure --enable-relocatable option. */
16935 +#if ENABLE_RELOCATABLE
16937 +/* When building a DLL, we must export some functions. Note that because
16938 + this is a private .h file, we don't need to use __declspec(dllimport)
16940 +#if defined _MSC_VER && BUILDING_DLL
16941 +# define RELOCATABLE_DLL_EXPORTED __declspec(dllexport)
16943 +# define RELOCATABLE_DLL_EXPORTED
16946 +/* Sets the original and the current installation prefix of the package.
16947 + Relocation simply replaces a pathname starting with the original prefix
16948 + by the corresponding pathname with the current prefix instead. Both
16949 + prefixes should be directory names without trailing slash (i.e. use ""
16950 + instead of "/"). */
16951 +extern RELOCATABLE_DLL_EXPORTED void
16952 + set_relocation_prefix (const char *orig_prefix,
16953 + const char *curr_prefix);
16955 +/* Returns the pathname, relocated according to the current installation
16957 +extern const char * relocate (const char *pathname);
16959 +/* Memory management: relocate() leaks memory, because it has to construct
16960 + a fresh pathname. If this is a problem because your program calls
16961 + relocate() frequently, think about caching the result. */
16963 +/* Convenience function:
16964 + Computes the current installation prefix, based on the original
16965 + installation prefix, the original installation directory of a particular
16966 + file, and the current pathname of this file. Returns NULL upon failure. */
16967 +extern const char * compute_curr_prefix (const char *orig_installprefix,
16968 + const char *orig_installdir,
16969 + const char *curr_pathname);
16973 +/* By default, we use the hardwired pathnames. */
16974 +#define relocate(pathname) (pathname)
16979 +#ifdef __cplusplus
16983 +#endif /* _RELOCATABLE_H */
16984 --- lrzsz-0.12.20.safe/intl/textdomain.c 1998-04-26 09:22:37.000000000 -0400
16985 +++ lrzsz-0.12.20/intl/textdomain.c 2004-09-12 14:40:34.656702336 -0400
16987 -/* Implementation of the textdomain(3) function
16988 - Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
16989 - Written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
16990 +/* Implementation of the textdomain(3) function.
16991 + Copyright (C) 1995-1998, 2000-2003 Free Software Foundation, Inc.
16993 - This program is free software; you can redistribute it and/or modify
16994 - it under the terms of the GNU General Public License as published by
16995 - the Free Software Foundation; either version 2, or (at your option)
16996 + This program is free software; you can redistribute it and/or modify it
16997 + under the terms of the GNU Library General Public License as published
16998 + by the Free Software Foundation; either version 2, or (at your option)
17001 This program is distributed in the hope that it will be useful,
17002 but WITHOUT ANY WARRANTY; without even the implied warranty of
17003 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17004 - GNU General Public License for more details.
17005 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17006 + Library General Public License for more details.
17008 - You should have received a copy of the GNU General Public License
17009 - along with this program; if not, write to the Free Software Foundation,
17010 - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
17011 + You should have received a copy of the GNU Library General Public
17012 + License along with this program; if not, write to the Free Software
17013 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
17016 #ifdef HAVE_CONFIG_H
17017 # include <config.h>
17020 -#if defined STDC_HEADERS || defined _LIBC
17021 -# include <stdlib.h>
17023 +#include <stdlib.h>
17024 +#include <string.h>
17026 -#if defined STDC_HEADERS || defined HAVE_STRING_H || defined _LIBC
17027 -# include <string.h>
17029 +# include <libintl.h>
17031 -# include <strings.h>
17033 -# define memcpy(Dst, Src, Num) bcopy (Src, Dst, Num)
17035 +# include "libgnuintl.h"
17037 +#include "gettextP.h"
17040 -# include <libintl.h>
17041 +/* We have to handle multi-threaded applications. */
17042 +# include <bits/libc-lock.h>
17044 -# include "libgettext.h"
17045 +/* Provide dummy implementation if this is outside glibc. */
17046 +# define __libc_rwlock_define(CLASS, NAME)
17047 +# define __libc_rwlock_wrlock(NAME)
17048 +# define __libc_rwlock_unlock(NAME)
17051 +/* The internal variables in the standalone libintl.a must have different
17052 + names than the internal variables in GNU libc, otherwise programs
17053 + using libintl.a cannot be linked statically. */
17054 +#if !defined _LIBC
17055 +# define _nl_default_default_domain libintl_nl_default_default_domain
17056 +# define _nl_current_default_domain libintl_nl_current_default_domain
17059 /* @@ end of prolog @@ */
17061 /* Name of the default text domain. */
17062 -extern const char _nl_default_default_domain[];
17063 +extern const char _nl_default_default_domain[] attribute_hidden;
17065 /* Default text domain in which entries for gettext(3) are to be found. */
17066 -extern const char *_nl_current_default_domain;
17067 +extern const char *_nl_current_default_domain attribute_hidden;
17070 /* Names for the libintl functions are a problem. They must not clash
17071 @@ -54,50 +63,76 @@
17072 prefix. So we have to make a difference here. */
17074 # define TEXTDOMAIN __textdomain
17075 -# define strdup(str) __strdup (str)
17077 +# define strdup(str) __strdup (str)
17080 -# define TEXTDOMAIN textdomain__
17081 +# define TEXTDOMAIN libintl_textdomain
17084 +/* Lock variable to protect the global data in the gettext implementation. */
17085 +__libc_rwlock_define (extern, _nl_state_lock attribute_hidden)
17087 /* Set the current default message catalog to DOMAINNAME.
17088 If DOMAINNAME is null, return the current default.
17089 If DOMAINNAME is "", reset to the default of "messages". */
17091 -TEXTDOMAIN (domainname)
17092 - const char *domainname;
17093 +TEXTDOMAIN (const char *domainname)
17096 + char *new_domain;
17097 + char *old_domain;
17099 /* A NULL pointer requests the current setting. */
17100 if (domainname == NULL)
17101 return (char *) _nl_current_default_domain;
17103 - old = (char *) _nl_current_default_domain;
17104 + __libc_rwlock_wrlock (_nl_state_lock);
17106 + old_domain = (char *) _nl_current_default_domain;
17108 /* If domain name is the null string set to default domain "messages". */
17109 if (domainname[0] == '\0'
17110 || strcmp (domainname, _nl_default_default_domain) == 0)
17111 - _nl_current_default_domain = _nl_default_default_domain;
17113 + _nl_current_default_domain = _nl_default_default_domain;
17114 + new_domain = (char *) _nl_current_default_domain;
17116 + else if (strcmp (domainname, old_domain) == 0)
17117 + /* This can happen and people will use it to signal that some
17118 + environment variable changed. */
17119 + new_domain = old_domain;
17122 /* If the following malloc fails `_nl_current_default_domain'
17123 will be NULL. This value will be returned and so signals we
17124 are out of core. */
17125 #if defined _LIBC || defined HAVE_STRDUP
17126 - _nl_current_default_domain = strdup (domainname);
17127 + new_domain = strdup (domainname);
17129 size_t len = strlen (domainname) + 1;
17130 - char *cp = (char *) malloc (len);
17132 - memcpy (cp, domainname, len);
17133 - _nl_current_default_domain = cp;
17134 + new_domain = (char *) malloc (len);
17135 + if (new_domain != NULL)
17136 + memcpy (new_domain, domainname, len);
17139 + if (new_domain != NULL)
17140 + _nl_current_default_domain = new_domain;
17143 - if (old != _nl_default_default_domain)
17145 + /* We use this possibility to signal a change of the loaded catalogs
17146 + since this is most likely the case and there is no other easy we
17147 + to do it. Do it only when the call was successful. */
17148 + if (new_domain != NULL)
17150 + ++_nl_msg_cat_cntr;
17152 - return (char *) _nl_current_default_domain;
17153 + if (old_domain != new_domain && old_domain != _nl_default_default_domain)
17154 + free (old_domain);
17157 + __libc_rwlock_unlock (_nl_state_lock);
17159 + return new_domain;
17163 --- lrzsz-0.12.20.safe/intl/vasnprintf.c 1969-12-31 19:00:00.000000000 -0500
17164 +++ lrzsz-0.12.20/intl/vasnprintf.c 2004-09-12 14:40:34.662701424 -0400
17166 +/* vsprintf with automatic memory allocation.
17167 + Copyright (C) 1999, 2002-2003 Free Software Foundation, Inc.
17169 + This program is free software; you can redistribute it and/or modify it
17170 + under the terms of the GNU Library General Public License as published
17171 + by the Free Software Foundation; either version 2, or (at your option)
17172 + any later version.
17174 + This program is distributed in the hope that it will be useful,
17175 + but WITHOUT ANY WARRANTY; without even the implied warranty of
17176 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17177 + Library General Public License for more details.
17179 + You should have received a copy of the GNU Library General Public
17180 + License along with this program; if not, write to the Free Software
17181 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
17184 +/* Tell glibc's <stdio.h> to provide a prototype for snprintf().
17185 + This must come before <config.h> because <config.h> may include
17186 + <features.h>, and once <features.h> has been included, it's too late. */
17187 +#ifndef _GNU_SOURCE
17188 +# define _GNU_SOURCE 1
17191 +#ifdef HAVE_CONFIG_H
17192 +# include <config.h>
17194 +#ifndef IN_LIBINTL
17195 +# include <alloca.h>
17198 +/* Specification. */
17199 +#if WIDE_CHAR_VERSION
17200 +# include "vasnwprintf.h"
17202 +# include "vasnprintf.h"
17205 +#include <stdio.h> /* snprintf(), sprintf() */
17206 +#include <stdlib.h> /* abort(), malloc(), realloc(), free() */
17207 +#include <string.h> /* memcpy(), strlen() */
17208 +#include <errno.h> /* errno */
17209 +#include <limits.h> /* CHAR_BIT */
17210 +#include <float.h> /* DBL_MAX_EXP, LDBL_MAX_EXP */
17211 +#if WIDE_CHAR_VERSION
17212 +# include "wprintf-parse.h"
17214 +# include "printf-parse.h"
17217 +/* Checked size_t computations. */
17218 +#include "xsize.h"
17220 +#ifdef HAVE_WCHAR_T
17221 +# ifdef HAVE_WCSLEN
17222 +# define local_wcslen wcslen
17224 + /* Solaris 2.5.1 has wcslen() in a separate library libw.so. To avoid
17225 + a dependency towards this library, here is a local substitute.
17226 + Define this substitute only once, even if this file is included
17227 + twice in the same compilation unit. */
17228 +# ifndef local_wcslen_defined
17229 +# define local_wcslen_defined 1
17231 +local_wcslen (const wchar_t *s)
17233 + const wchar_t *ptr;
17235 + for (ptr = s; *ptr != (wchar_t) 0; ptr++)
17243 +#if WIDE_CHAR_VERSION
17244 +# define VASNPRINTF vasnwprintf
17245 +# define CHAR_T wchar_t
17246 +# define DIRECTIVE wchar_t_directive
17247 +# define DIRECTIVES wchar_t_directives
17248 +# define PRINTF_PARSE wprintf_parse
17249 +# define USE_SNPRINTF 1
17250 +# if HAVE_DECL__SNWPRINTF
17251 + /* On Windows, the function swprintf() has a different signature than
17252 + on Unix; we use the _snwprintf() function instead. */
17253 +# define SNPRINTF _snwprintf
17256 +# define SNPRINTF swprintf
17259 +# define VASNPRINTF vasnprintf
17260 +# define CHAR_T char
17261 +# define DIRECTIVE char_directive
17262 +# define DIRECTIVES char_directives
17263 +# define PRINTF_PARSE printf_parse
17264 +# define USE_SNPRINTF (HAVE_DECL__SNPRINTF || HAVE_SNPRINTF)
17265 +# if HAVE_DECL__SNPRINTF
17267 +# define SNPRINTF _snprintf
17270 +# define SNPRINTF snprintf
17275 +VASNPRINTF (CHAR_T *resultbuf, size_t *lengthp, const CHAR_T *format, va_list args)
17280 + if (PRINTF_PARSE (format, &d, &a) < 0)
17286 +#define CLEANUP() \
17291 + if (printf_fetchargs (args, &a) < 0)
17299 + size_t buf_neededlength;
17301 + CHAR_T *buf_malloced;
17302 + const CHAR_T *cp;
17305 + /* Output string accumulator. */
17307 + size_t allocated;
17310 + /* Allocate a small buffer that will hold a directive passed to
17311 + sprintf or snprintf. */
17312 + buf_neededlength =
17313 + xsum4 (7, d.max_width_length, d.max_precision_length, 6);
17315 + if (buf_neededlength < 4000 / sizeof (CHAR_T))
17317 + buf = (CHAR_T *) alloca (buf_neededlength * sizeof (CHAR_T));
17318 + buf_malloced = NULL;
17323 + size_t buf_memsize = xtimes (buf_neededlength, sizeof (CHAR_T));
17324 + if (size_overflow_p (buf_memsize))
17325 + goto out_of_memory_1;
17326 + buf = (CHAR_T *) malloc (buf_memsize);
17328 + goto out_of_memory_1;
17329 + buf_malloced = buf;
17332 + if (resultbuf != NULL)
17334 + result = resultbuf;
17335 + allocated = *lengthp;
17344 + result is either == resultbuf or == NULL or malloc-allocated.
17345 + If length > 0, then result != NULL. */
17347 + /* Ensures that allocated >= needed. Aborts through a jump to
17348 + out_of_memory if needed is SIZE_MAX or otherwise too big. */
17349 +#define ENSURE_ALLOCATION(needed) \
17350 + if ((needed) > allocated) \
17352 + size_t memory_size; \
17353 + CHAR_T *memory; \
17355 + allocated = (allocated > 0 ? xtimes (allocated, 2) : 12); \
17356 + if ((needed) > allocated) \
17357 + allocated = (needed); \
17358 + memory_size = xtimes (allocated, sizeof (CHAR_T)); \
17359 + if (size_overflow_p (memory_size)) \
17360 + goto out_of_memory; \
17361 + if (result == resultbuf || result == NULL) \
17362 + memory = (CHAR_T *) malloc (memory_size); \
17364 + memory = (CHAR_T *) realloc (result, memory_size); \
17365 + if (memory == NULL) \
17366 + goto out_of_memory; \
17367 + if (result == resultbuf && length > 0) \
17368 + memcpy (memory, result, length * sizeof (CHAR_T)); \
17369 + result = memory; \
17372 + for (cp = format, i = 0, dp = &d.dir[0]; ; cp = dp->dir_end, i++, dp++)
17374 + if (cp != dp->dir_start)
17376 + size_t n = dp->dir_start - cp;
17377 + size_t augmented_length = xsum (length, n);
17379 + ENSURE_ALLOCATION (augmented_length);
17380 + memcpy (result + length, cp, n * sizeof (CHAR_T));
17381 + length = augmented_length;
17383 + if (i == d.count)
17386 + /* Execute a single directive. */
17387 + if (dp->conversion == '%')
17389 + size_t augmented_length;
17391 + if (!(dp->arg_index == ARG_NONE))
17393 + augmented_length = xsum (length, 1);
17394 + ENSURE_ALLOCATION (augmented_length);
17395 + result[length] = '%';
17396 + length = augmented_length;
17400 + if (!(dp->arg_index != ARG_NONE))
17403 + if (dp->conversion == 'n')
17405 + switch (a.arg[dp->arg_index].type)
17407 + case TYPE_COUNT_SCHAR_POINTER:
17408 + *a.arg[dp->arg_index].a.a_count_schar_pointer = length;
17410 + case TYPE_COUNT_SHORT_POINTER:
17411 + *a.arg[dp->arg_index].a.a_count_short_pointer = length;
17413 + case TYPE_COUNT_INT_POINTER:
17414 + *a.arg[dp->arg_index].a.a_count_int_pointer = length;
17416 + case TYPE_COUNT_LONGINT_POINTER:
17417 + *a.arg[dp->arg_index].a.a_count_longint_pointer = length;
17419 +#ifdef HAVE_LONG_LONG
17420 + case TYPE_COUNT_LONGLONGINT_POINTER:
17421 + *a.arg[dp->arg_index].a.a_count_longlongint_pointer = length;
17430 + arg_type type = a.arg[dp->arg_index].type;
17432 + unsigned int prefix_count;
17435 + size_t tmp_length;
17436 + CHAR_T tmpbuf[700];
17439 + /* Allocate a temporary buffer of sufficient size for calling
17443 + size_t precision;
17446 + if (dp->width_start != dp->width_end)
17448 + if (dp->width_arg_index != ARG_NONE)
17452 + if (!(a.arg[dp->width_arg_index].type == TYPE_INT))
17454 + arg = a.arg[dp->width_arg_index].a.a_int;
17455 + width = (arg < 0 ? (unsigned int) (-arg) : arg);
17459 + const CHAR_T *digitp = dp->width_start;
17462 + width = xsum (xtimes (width, 10), *digitp++ - '0');
17463 + while (digitp != dp->width_end);
17468 + if (dp->precision_start != dp->precision_end)
17470 + if (dp->precision_arg_index != ARG_NONE)
17474 + if (!(a.arg[dp->precision_arg_index].type == TYPE_INT))
17476 + arg = a.arg[dp->precision_arg_index].a.a_int;
17477 + precision = (arg < 0 ? 0 : arg);
17481 + const CHAR_T *digitp = dp->precision_start + 1;
17485 + precision = xsum (xtimes (precision, 10), *digitp++ - '0');
17486 + while (digitp != dp->precision_end);
17490 + switch (dp->conversion)
17493 + case 'd': case 'i': case 'u':
17494 +# ifdef HAVE_LONG_LONG
17495 + if (type == TYPE_LONGLONGINT || type == TYPE_ULONGLONGINT)
17497 + (unsigned int) (sizeof (unsigned long long) * CHAR_BIT
17498 + * 0.30103 /* binary -> decimal */
17499 + * 2 /* estimate for FLAG_GROUP */
17501 + + 1 /* turn floor into ceil */
17502 + + 1; /* account for leading sign */
17505 + if (type == TYPE_LONGINT || type == TYPE_ULONGINT)
17507 + (unsigned int) (sizeof (unsigned long) * CHAR_BIT
17508 + * 0.30103 /* binary -> decimal */
17509 + * 2 /* estimate for FLAG_GROUP */
17511 + + 1 /* turn floor into ceil */
17512 + + 1; /* account for leading sign */
17515 + (unsigned int) (sizeof (unsigned int) * CHAR_BIT
17516 + * 0.30103 /* binary -> decimal */
17517 + * 2 /* estimate for FLAG_GROUP */
17519 + + 1 /* turn floor into ceil */
17520 + + 1; /* account for leading sign */
17524 +# ifdef HAVE_LONG_LONG
17525 + if (type == TYPE_LONGLONGINT || type == TYPE_ULONGLONGINT)
17527 + (unsigned int) (sizeof (unsigned long long) * CHAR_BIT
17528 + * 0.333334 /* binary -> octal */
17530 + + 1 /* turn floor into ceil */
17531 + + 1; /* account for leading sign */
17534 + if (type == TYPE_LONGINT || type == TYPE_ULONGINT)
17536 + (unsigned int) (sizeof (unsigned long) * CHAR_BIT
17537 + * 0.333334 /* binary -> octal */
17539 + + 1 /* turn floor into ceil */
17540 + + 1; /* account for leading sign */
17543 + (unsigned int) (sizeof (unsigned int) * CHAR_BIT
17544 + * 0.333334 /* binary -> octal */
17546 + + 1 /* turn floor into ceil */
17547 + + 1; /* account for leading sign */
17550 + case 'x': case 'X':
17551 +# ifdef HAVE_LONG_LONG
17552 + if (type == TYPE_LONGLONGINT || type == TYPE_ULONGLONGINT)
17554 + (unsigned int) (sizeof (unsigned long long) * CHAR_BIT
17555 + * 0.25 /* binary -> hexadecimal */
17557 + + 1 /* turn floor into ceil */
17558 + + 2; /* account for leading sign or alternate form */
17561 + if (type == TYPE_LONGINT || type == TYPE_ULONGINT)
17563 + (unsigned int) (sizeof (unsigned long) * CHAR_BIT
17564 + * 0.25 /* binary -> hexadecimal */
17566 + + 1 /* turn floor into ceil */
17567 + + 2; /* account for leading sign or alternate form */
17570 + (unsigned int) (sizeof (unsigned int) * CHAR_BIT
17571 + * 0.25 /* binary -> hexadecimal */
17573 + + 1 /* turn floor into ceil */
17574 + + 2; /* account for leading sign or alternate form */
17577 + case 'f': case 'F':
17578 +# ifdef HAVE_LONG_DOUBLE
17579 + if (type == TYPE_LONGDOUBLE)
17581 + (unsigned int) (LDBL_MAX_EXP
17582 + * 0.30103 /* binary -> decimal */
17583 + * 2 /* estimate for FLAG_GROUP */
17585 + + 1 /* turn floor into ceil */
17586 + + 10; /* sign, decimal point etc. */
17590 + (unsigned int) (DBL_MAX_EXP
17591 + * 0.30103 /* binary -> decimal */
17592 + * 2 /* estimate for FLAG_GROUP */
17594 + + 1 /* turn floor into ceil */
17595 + + 10; /* sign, decimal point etc. */
17596 + tmp_length = xsum (tmp_length, precision);
17599 + case 'e': case 'E': case 'g': case 'G':
17600 + case 'a': case 'A':
17602 + 12; /* sign, decimal point, exponent etc. */
17603 + tmp_length = xsum (tmp_length, precision);
17607 +# if defined HAVE_WINT_T && !WIDE_CHAR_VERSION
17608 + if (type == TYPE_WIDE_CHAR)
17609 + tmp_length = MB_CUR_MAX;
17616 +# ifdef HAVE_WCHAR_T
17617 + if (type == TYPE_WIDE_STRING)
17620 + local_wcslen (a.arg[dp->arg_index].a.a_wide_string);
17622 +# if !WIDE_CHAR_VERSION
17623 + tmp_length = xtimes (tmp_length, MB_CUR_MAX);
17628 + tmp_length = strlen (a.arg[dp->arg_index].a.a_string);
17633 + (unsigned int) (sizeof (void *) * CHAR_BIT
17634 + * 0.25 /* binary -> hexadecimal */
17636 + + 1 /* turn floor into ceil */
17637 + + 2; /* account for leading 0x */
17644 + if (tmp_length < width)
17645 + tmp_length = width;
17647 + tmp_length = xsum (tmp_length, 1); /* account for trailing NUL */
17650 + if (tmp_length <= sizeof (tmpbuf) / sizeof (CHAR_T))
17654 + size_t tmp_memsize = xtimes (tmp_length, sizeof (CHAR_T));
17656 + if (size_overflow_p (tmp_memsize))
17657 + /* Overflow, would lead to out of memory. */
17658 + goto out_of_memory;
17659 + tmp = (CHAR_T *) malloc (tmp_memsize);
17661 + /* Out of memory. */
17662 + goto out_of_memory;
17666 + /* Construct the format string for calling snprintf or
17670 + if (dp->flags & FLAG_GROUP)
17672 + if (dp->flags & FLAG_LEFT)
17674 + if (dp->flags & FLAG_SHOWSIGN)
17676 + if (dp->flags & FLAG_SPACE)
17678 + if (dp->flags & FLAG_ALT)
17680 + if (dp->flags & FLAG_ZERO)
17682 + if (dp->width_start != dp->width_end)
17684 + size_t n = dp->width_end - dp->width_start;
17685 + memcpy (p, dp->width_start, n * sizeof (CHAR_T));
17688 + if (dp->precision_start != dp->precision_end)
17690 + size_t n = dp->precision_end - dp->precision_start;
17691 + memcpy (p, dp->precision_start, n * sizeof (CHAR_T));
17697 +#ifdef HAVE_LONG_LONG
17698 + case TYPE_LONGLONGINT:
17699 + case TYPE_ULONGLONGINT:
17703 + case TYPE_LONGINT:
17704 + case TYPE_ULONGINT:
17705 +#ifdef HAVE_WINT_T
17706 + case TYPE_WIDE_CHAR:
17708 +#ifdef HAVE_WCHAR_T
17709 + case TYPE_WIDE_STRING:
17713 +#ifdef HAVE_LONG_DOUBLE
17714 + case TYPE_LONGDOUBLE:
17721 + *p = dp->conversion;
17730 + /* Construct the arguments for calling snprintf or sprintf. */
17731 + prefix_count = 0;
17732 + if (dp->width_arg_index != ARG_NONE)
17734 + if (!(a.arg[dp->width_arg_index].type == TYPE_INT))
17736 + prefixes[prefix_count++] = a.arg[dp->width_arg_index].a.a_int;
17738 + if (dp->precision_arg_index != ARG_NONE)
17740 + if (!(a.arg[dp->precision_arg_index].type == TYPE_INT))
17742 + prefixes[prefix_count++] = a.arg[dp->precision_arg_index].a.a_int;
17746 + /* Prepare checking whether snprintf returns the count
17748 + ENSURE_ALLOCATION (xsum (length, 1));
17749 + result[length] = '\0';
17758 + maxlen = allocated - length;
17763 +# define SNPRINTF_BUF(arg) \
17764 + switch (prefix_count) \
17767 + retcount = SNPRINTF (result + length, maxlen, buf, \
17771 + retcount = SNPRINTF (result + length, maxlen, buf, \
17772 + prefixes[0], arg, &count); \
17775 + retcount = SNPRINTF (result + length, maxlen, buf, \
17776 + prefixes[0], prefixes[1], arg, \
17783 +# define SNPRINTF_BUF(arg) \
17784 + switch (prefix_count) \
17787 + count = sprintf (tmp, buf, arg); \
17790 + count = sprintf (tmp, buf, prefixes[0], arg); \
17793 + count = sprintf (tmp, buf, prefixes[0], prefixes[1],\
17805 + int arg = a.arg[dp->arg_index].a.a_schar;
17806 + SNPRINTF_BUF (arg);
17811 + unsigned int arg = a.arg[dp->arg_index].a.a_uchar;
17812 + SNPRINTF_BUF (arg);
17817 + int arg = a.arg[dp->arg_index].a.a_short;
17818 + SNPRINTF_BUF (arg);
17821 + case TYPE_USHORT:
17823 + unsigned int arg = a.arg[dp->arg_index].a.a_ushort;
17824 + SNPRINTF_BUF (arg);
17829 + int arg = a.arg[dp->arg_index].a.a_int;
17830 + SNPRINTF_BUF (arg);
17835 + unsigned int arg = a.arg[dp->arg_index].a.a_uint;
17836 + SNPRINTF_BUF (arg);
17839 + case TYPE_LONGINT:
17841 + long int arg = a.arg[dp->arg_index].a.a_longint;
17842 + SNPRINTF_BUF (arg);
17845 + case TYPE_ULONGINT:
17847 + unsigned long int arg = a.arg[dp->arg_index].a.a_ulongint;
17848 + SNPRINTF_BUF (arg);
17851 +#ifdef HAVE_LONG_LONG
17852 + case TYPE_LONGLONGINT:
17854 + long long int arg = a.arg[dp->arg_index].a.a_longlongint;
17855 + SNPRINTF_BUF (arg);
17858 + case TYPE_ULONGLONGINT:
17860 + unsigned long long int arg = a.arg[dp->arg_index].a.a_ulonglongint;
17861 + SNPRINTF_BUF (arg);
17865 + case TYPE_DOUBLE:
17867 + double arg = a.arg[dp->arg_index].a.a_double;
17868 + SNPRINTF_BUF (arg);
17871 +#ifdef HAVE_LONG_DOUBLE
17872 + case TYPE_LONGDOUBLE:
17874 + long double arg = a.arg[dp->arg_index].a.a_longdouble;
17875 + SNPRINTF_BUF (arg);
17881 + int arg = a.arg[dp->arg_index].a.a_char;
17882 + SNPRINTF_BUF (arg);
17885 +#ifdef HAVE_WINT_T
17886 + case TYPE_WIDE_CHAR:
17888 + wint_t arg = a.arg[dp->arg_index].a.a_wide_char;
17889 + SNPRINTF_BUF (arg);
17893 + case TYPE_STRING:
17895 + const char *arg = a.arg[dp->arg_index].a.a_string;
17896 + SNPRINTF_BUF (arg);
17899 +#ifdef HAVE_WCHAR_T
17900 + case TYPE_WIDE_STRING:
17902 + const wchar_t *arg = a.arg[dp->arg_index].a.a_wide_string;
17903 + SNPRINTF_BUF (arg);
17907 + case TYPE_POINTER:
17909 + void *arg = a.arg[dp->arg_index].a.a_pointer;
17910 + SNPRINTF_BUF (arg);
17918 + /* Portability: Not all implementations of snprintf()
17919 + are ISO C 99 compliant. Determine the number of
17920 + bytes that snprintf() has produced or would have
17924 + /* Verify that snprintf() has NUL-terminated its
17926 + if (count < maxlen && result[length + count] != '\0')
17928 + /* Portability hack. */
17929 + if (retcount > count)
17930 + count = retcount;
17934 + /* snprintf() doesn't understand the '%n'
17936 + if (p[1] != '\0')
17938 + /* Don't use the '%n' directive; instead, look
17939 + at the snprintf() return value. */
17945 + /* Look at the snprintf() return value. */
17946 + if (retcount < 0)
17948 + /* HP-UX 10.20 snprintf() is doubly deficient:
17949 + It doesn't understand the '%n' directive,
17950 + *and* it returns -1 (rather than the length
17951 + that would have been required) when the
17952 + buffer is too small. */
17953 + size_t bigger_need =
17954 + xsum (xtimes (allocated, 2), 12);
17955 + ENSURE_ALLOCATION (bigger_need);
17959 + count = retcount;
17964 + /* Attempt to handle failure. */
17967 + if (!(result == resultbuf || result == NULL))
17969 + if (buf_malloced != NULL)
17970 + free (buf_malloced);
17977 + if (count >= tmp_length)
17978 + /* tmp_length was incorrectly calculated - fix the
17983 + /* Make room for the result. */
17984 + if (count >= maxlen)
17986 + /* Need at least count bytes. But allocate
17987 + proportionally, to avoid looping eternally if
17988 + snprintf() reports a too small count. */
17990 + xmax (xsum (length, count), xtimes (allocated, 2));
17992 + ENSURE_ALLOCATION (n);
17999 + /* The snprintf() result did fit. */
18001 + /* Append the sprintf() result. */
18002 + memcpy (result + length, tmp, count * sizeof (CHAR_T));
18003 + if (tmp != tmpbuf)
18014 + /* Add the final NUL. */
18015 + ENSURE_ALLOCATION (xsum (length, 1));
18016 + result[length] = '\0';
18018 + if (result != resultbuf && length + 1 < allocated)
18020 + /* Shrink the allocated memory if possible. */
18023 + memory = (CHAR_T *) realloc (result, (length + 1) * sizeof (CHAR_T));
18024 + if (memory != NULL)
18028 + if (buf_malloced != NULL)
18029 + free (buf_malloced);
18031 + *lengthp = length;
18035 + if (!(result == resultbuf || result == NULL))
18037 + if (buf_malloced != NULL)
18038 + free (buf_malloced);
18047 +#undef USE_SNPRINTF
18048 +#undef PRINTF_PARSE
18053 --- lrzsz-0.12.20.safe/intl/vasnprintf.h 1969-12-31 19:00:00.000000000 -0500
18054 +++ lrzsz-0.12.20/intl/vasnprintf.h 2004-09-12 14:40:34.667700664 -0400
18056 +/* vsprintf with automatic memory allocation.
18057 + Copyright (C) 2002-2003 Free Software Foundation, Inc.
18059 + This program is free software; you can redistribute it and/or modify it
18060 + under the terms of the GNU Library General Public License as published
18061 + by the Free Software Foundation; either version 2, or (at your option)
18062 + any later version.
18064 + This program is distributed in the hope that it will be useful,
18065 + but WITHOUT ANY WARRANTY; without even the implied warranty of
18066 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18067 + Library General Public License for more details.
18069 + You should have received a copy of the GNU Library General Public
18070 + License along with this program; if not, write to the Free Software
18071 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
18074 +#ifndef _VASNPRINTF_H
18075 +#define _VASNPRINTF_H
18077 +/* Get va_list. */
18078 +#include <stdarg.h>
18081 +#include <stddef.h>
18083 +#ifndef __attribute__
18084 +/* This feature is available in gcc versions 2.5 and later. */
18085 +# if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 5) || __STRICT_ANSI__
18086 +# define __attribute__(Spec) /* empty */
18088 +/* The __-protected variants of `format' and `printf' attributes
18089 + are accepted by gcc versions 2.6.4 (effectively 2.7) and later. */
18090 +# if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 7)
18091 +# define __format__ format
18092 +# define __printf__ printf
18096 +#ifdef __cplusplus
18100 +/* Write formatted output to a string dynamically allocated with malloc().
18101 + You can pass a preallocated buffer for the result in RESULTBUF and its
18102 + size in *LENGTHP; otherwise you pass RESULTBUF = NULL.
18103 + If successful, return the address of the string (this may be = RESULTBUF
18104 + if no dynamic memory allocation was necessary) and set *LENGTHP to the
18105 + number of resulting bytes, excluding the trailing NUL. Upon error, set
18106 + errno and return NULL. */
18107 +extern char * asnprintf (char *resultbuf, size_t *lengthp, const char *format, ...)
18108 + __attribute__ ((__format__ (__printf__, 3, 4)));
18109 +extern char * vasnprintf (char *resultbuf, size_t *lengthp, const char *format, va_list args)
18110 + __attribute__ ((__format__ (__printf__, 3, 0)));
18112 +#ifdef __cplusplus
18116 +#endif /* _VASNPRINTF_H */
18117 --- lrzsz-0.12.20.safe/intl/vasnwprintf.h 1969-12-31 19:00:00.000000000 -0500
18118 +++ lrzsz-0.12.20/intl/vasnwprintf.h 2004-09-12 14:40:34.673699752 -0400
18120 +/* vswprintf with automatic memory allocation.
18121 + Copyright (C) 2002-2003 Free Software Foundation, Inc.
18123 + This program is free software; you can redistribute it and/or modify it
18124 + under the terms of the GNU Library General Public License as published
18125 + by the Free Software Foundation; either version 2, or (at your option)
18126 + any later version.
18128 + This program is distributed in the hope that it will be useful,
18129 + but WITHOUT ANY WARRANTY; without even the implied warranty of
18130 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18131 + Library General Public License for more details.
18133 + You should have received a copy of the GNU Library General Public
18134 + License along with this program; if not, write to the Free Software
18135 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
18138 +#ifndef _VASNWPRINTF_H
18139 +#define _VASNWPRINTF_H
18141 +/* Get va_list. */
18142 +#include <stdarg.h>
18144 +/* Get wchar_t, size_t. */
18145 +#include <stddef.h>
18147 +#ifdef __cplusplus
18151 +/* Write formatted output to a string dynamically allocated with malloc().
18152 + You can pass a preallocated buffer for the result in RESULTBUF and its
18153 + size in *LENGTHP; otherwise you pass RESULTBUF = NULL.
18154 + If successful, return the address of the string (this may be = RESULTBUF
18155 + if no dynamic memory allocation was necessary) and set *LENGTHP to the
18156 + number of resulting bytes, excluding the trailing NUL. Upon error, set
18157 + errno and return NULL. */
18158 +extern wchar_t * asnwprintf (wchar_t *resultbuf, size_t *lengthp, const wchar_t *format, ...);
18159 +extern wchar_t * vasnwprintf (wchar_t *resultbuf, size_t *lengthp, const wchar_t *format, va_list args);
18161 +#ifdef __cplusplus
18165 +#endif /* _VASNWPRINTF_H */
18166 --- lrzsz-0.12.20.safe/intl/VERSION 1998-04-26 09:22:37.000000000 -0400
18167 +++ lrzsz-0.12.20/intl/VERSION 2004-09-12 14:40:34.679698840 -0400
18169 -GNU gettext library from gettext-0.10.32
18170 +GNU gettext library from gettext-0.14.1
18171 --- lrzsz-0.12.20.safe/intl/wprintf-parse.h 1969-12-31 19:00:00.000000000 -0500
18172 +++ lrzsz-0.12.20/intl/wprintf-parse.h 2004-09-12 14:40:34.695696408 -0400
18174 +/* Parse printf format string.
18175 + Copyright (C) 1999, 2002-2003 Free Software Foundation, Inc.
18177 + This program is free software; you can redistribute it and/or modify it
18178 + under the terms of the GNU Library General Public License as published
18179 + by the Free Software Foundation; either version 2, or (at your option)
18180 + any later version.
18182 + This program is distributed in the hope that it will be useful,
18183 + but WITHOUT ANY WARRANTY; without even the implied warranty of
18184 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18185 + Library General Public License for more details.
18187 + You should have received a copy of the GNU Library General Public
18188 + License along with this program; if not, write to the Free Software
18189 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
18192 +#ifndef _WPRINTF_PARSE_H
18193 +#define _WPRINTF_PARSE_H
18195 +#include "printf-args.h"
18199 +#define FLAG_GROUP 1 /* ' flag */
18200 +#define FLAG_LEFT 2 /* - flag */
18201 +#define FLAG_SHOWSIGN 4 /* + flag */
18202 +#define FLAG_SPACE 8 /* space flag */
18203 +#define FLAG_ALT 16 /* # flag */
18204 +#define FLAG_ZERO 32
18206 +/* arg_index value indicating that no argument is consumed. */
18207 +#define ARG_NONE (~(size_t)0)
18209 +/* A parsed directive. */
18212 + const wchar_t* dir_start;
18213 + const wchar_t* dir_end;
18215 + const wchar_t* width_start;
18216 + const wchar_t* width_end;
18217 + size_t width_arg_index;
18218 + const wchar_t* precision_start;
18219 + const wchar_t* precision_end;
18220 + size_t precision_arg_index;
18221 + wchar_t conversion; /* d i o u x X f e E g G c s p n U % but not C S */
18222 + size_t arg_index;
18224 +wchar_t_directive;
18226 +/* A parsed format string. */
18230 + wchar_t_directive *dir;
18231 + size_t max_width_length;
18232 + size_t max_precision_length;
18234 +wchar_t_directives;
18237 +/* Parses the format string. Fills in the number N of directives, and fills
18238 + in directives[0], ..., directives[N-1], and sets directives[N].dir_start
18239 + to the end of the format string. Also fills in the arg_type fields of the
18240 + arguments and the needed count of arguments. */
18246 +int wprintf_parse (const wchar_t *format, wchar_t_directives *d, arguments *a);
18248 +#endif /* _WPRINTF_PARSE_H */
18249 --- lrzsz-0.12.20.safe/intl/xopen-msg.sed 1998-04-26 09:20:52.000000000 -0400
18250 +++ lrzsz-0.12.20/intl/xopen-msg.sed 1969-12-31 19:00:00.000000000 -0500
18252 -# po2msg.sed - Convert Uniforum style .po file to X/Open style .msg file
18253 -# Copyright (C) 1995 Free Software Foundation, Inc.
18254 -# Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
18256 -# This program is free software; you can redistribute it and/or modify
18257 -# it under the terms of the GNU General Public License as published by
18258 -# the Free Software Foundation; either version 2, or (at your option)
18259 -# any later version.
18261 -# This program is distributed in the hope that it will be useful,
18262 -# but WITHOUT ANY WARRANTY; without even the implied warranty of
18263 -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18264 -# GNU General Public License for more details.
18266 -# You should have received a copy of the GNU General Public License
18267 -# along with this program; if not, write to the Free Software
18268 -# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
18271 -# The first directive in the .msg should be the definition of the
18272 -# message set number. We use always set number 1.
18276 -$set 1 # Automatically created by po2msg.sed
18282 -# We copy all comments into the .msg file. Perhaps they can help.
18284 -/^#/ s/^#[ ]*/$ /p
18286 -# We copy the original message as a comment into the .msg file.
18289 -# Does not work now
18292 -# s/$/ ... (more lines following)"/
18294 - s/^msgid[ ]*"\(.*\)"$/$ Original Message: \1/
18298 -# The .msg file contains, other then the .po file, only the translations
18299 -# but each given a unique ID. Starting from 1 and incrementing by 1 for
18300 -# each message we assign them to the messages.
18301 -# It is important that the .po file used to generate the cat-id-tbl.c file
18302 -# (with po-to-tbl) is the same as the one used here. (At least the order
18303 -# of declarations must not be changed.)
18306 - s/msgstr[ ]*"\(.*\)"/\1/
18308 -# The following nice solution is by
18309 -# Bruno <Haible@ma2s2.mathematik.uni-karlsruhe.de>
18311 -# Increment a decimal number in pattern space.
18312 -# First hide trailing `9' digits.
18316 -# Assure at least one digit is available.
18318 -# Increment the last digit.
18328 -# Convert the hidden `9' digits to `0's.
18331 -# Bring the line in the format `<number> <message>'
18334 - s/\(.*\)\n\([0-9]*\)/\2 \1/
18335 -# Clear flag from last substitution.
18337 -# Append the next line.
18340 -# Look whether second part is a continuation line.
18341 - s/\(.*\n\)"\(.*\)"/\1\2/
18342 -# Yes, then branch.
18346 -# Note that `D' includes a jump to the start!!
18347 -# We found a continuation line. But before printing insert '\'.
18349 - s/\(.*\)\(\n.*\)/\1\\\2/
18351 -# We cannot use the sed command `D' here
18356 --- lrzsz-0.12.20.safe/intl/xsize.h 1969-12-31 19:00:00.000000000 -0500
18357 +++ lrzsz-0.12.20/intl/xsize.h 2004-09-12 14:40:34.700695648 -0400
18359 +/* xsize.h -- Checked size_t computations.
18361 + Copyright (C) 2003 Free Software Foundation, Inc.
18363 + This program is free software; you can redistribute it and/or modify it
18364 + under the terms of the GNU Library General Public License as published
18365 + by the Free Software Foundation; either version 2, or (at your option)
18366 + any later version.
18368 + This program is distributed in the hope that it will be useful,
18369 + but WITHOUT ANY WARRANTY; without even the implied warranty of
18370 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18371 + Library General Public License for more details.
18373 + You should have received a copy of the GNU Library General Public
18374 + License along with this program; if not, write to the Free Software
18375 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
18382 +#include <stddef.h>
18384 +/* Get SIZE_MAX. */
18385 +#include <limits.h>
18387 +# include <stdint.h>
18390 +/* The size of memory objects is often computed through expressions of
18391 + type size_t. Example:
18392 + void* p = malloc (header_size + n * element_size).
18393 + These computations can lead to overflow. When this happens, malloc()
18394 + returns a piece of memory that is way too small, and the program then
18395 + crashes while attempting to fill the memory.
18396 + To avoid this, the functions and macros in this file check for overflow.
18397 + The convention is that SIZE_MAX represents overflow.
18398 + malloc (SIZE_MAX) is not guaranteed to fail -- think of a malloc
18399 + implementation that uses mmap --, it's recommended to use size_overflow_p()
18400 + or size_in_bounds_p() before invoking malloc().
18401 + The example thus becomes:
18402 + size_t size = xsum (header_size, xtimes (n, element_size));
18403 + void *p = (size_in_bounds_p (size) ? malloc (size) : NULL);
18406 +/* Convert an arbitrary value >= 0 to type size_t. */
18407 +#define xcast_size_t(N) \
18408 + ((N) <= SIZE_MAX ? (size_t) (N) : SIZE_MAX)
18410 +/* Sum of two sizes, with overflow check. */
18411 +static inline size_t
18413 +__attribute__ ((__pure__))
18415 +xsum (size_t size1, size_t size2)
18417 + size_t sum = size1 + size2;
18418 + return (sum >= size1 ? sum : SIZE_MAX);
18421 +/* Sum of three sizes, with overflow check. */
18422 +static inline size_t
18424 +__attribute__ ((__pure__))
18426 +xsum3 (size_t size1, size_t size2, size_t size3)
18428 + return xsum (xsum (size1, size2), size3);
18431 +/* Sum of four sizes, with overflow check. */
18432 +static inline size_t
18434 +__attribute__ ((__pure__))
18436 +xsum4 (size_t size1, size_t size2, size_t size3, size_t size4)
18438 + return xsum (xsum (xsum (size1, size2), size3), size4);
18441 +/* Maximum of two sizes, with overflow check. */
18442 +static inline size_t
18444 +__attribute__ ((__pure__))
18446 +xmax (size_t size1, size_t size2)
18448 + /* No explicit check is needed here, because for any n:
18449 + max (SIZE_MAX, n) == SIZE_MAX and max (n, SIZE_MAX) == SIZE_MAX. */
18450 + return (size1 >= size2 ? size1 : size2);
18453 +/* Multiplication of a count with an element size, with overflow check.
18454 + The count must be >= 0 and the element size must be > 0.
18455 + This is a macro, not an inline function, so that it works correctly even
18456 + when N is of a wider tupe and N > SIZE_MAX. */
18457 +#define xtimes(N, ELSIZE) \
18458 + ((N) <= SIZE_MAX / (ELSIZE) ? (size_t) (N) * (ELSIZE) : SIZE_MAX)
18460 +/* Check for overflow. */
18461 +#define size_overflow_p(SIZE) \
18462 + ((SIZE) == SIZE_MAX)
18463 +/* Check against overflow. */
18464 +#define size_in_bounds_p(SIZE) \
18465 + ((SIZE) != SIZE_MAX)
18467 +#endif /* _XSIZE_H */
18468 --- lrzsz-0.12.20.safe/m4/ChangeLog 1969-12-31 19:00:00.000000000 -0500
18469 +++ lrzsz-0.12.20/m4/ChangeLog 2004-09-12 14:40:35.054641840 -0400
18471 +2004-09-12 gettextize <bug-gnu-gettext@gnu.org>
18473 + * codeset.m4: New file, from gettext-0.14.1.
18474 + * gettext.m4: New file, from gettext-0.14.1.
18475 + * glibc21.m4: New file, from gettext-0.14.1.
18476 + * iconv.m4: New file, from gettext-0.14.1.
18477 + * intdiv0.m4: New file, from gettext-0.14.1.
18478 + * intmax.m4: New file, from gettext-0.14.1.
18479 + * inttypes.m4: New file, from gettext-0.14.1.
18480 + * inttypes_h.m4: New file, from gettext-0.14.1.
18481 + * inttypes-pri.m4: New file, from gettext-0.14.1.
18482 + * isc-posix.m4: New file, from gettext-0.14.1.
18483 + * lcmessage.m4: New file, from gettext-0.14.1.
18484 + * lib-ld.m4: New file, from gettext-0.14.1.
18485 + * lib-link.m4: New file, from gettext-0.14.1.
18486 + * lib-prefix.m4: New file, from gettext-0.14.1.
18487 + * longdouble.m4: New file, from gettext-0.14.1.
18488 + * longlong.m4: New file, from gettext-0.14.1.
18489 + * nls.m4: New file, from gettext-0.14.1.
18490 + * po.m4: New file, from gettext-0.14.1.
18491 + * printf-posix.m4: New file, from gettext-0.14.1.
18492 + * progtest.m4: New file, from gettext-0.14.1.
18493 + * signed.m4: New file, from gettext-0.14.1.
18494 + * size_max.m4: New file, from gettext-0.14.1.
18495 + * stdint_h.m4: New file, from gettext-0.14.1.
18496 + * uintmax_t.m4: New file, from gettext-0.14.1.
18497 + * ulonglong.m4: New file, from gettext-0.14.1.
18498 + * wchar_t.m4: New file, from gettext-0.14.1.
18499 + * wint_t.m4: New file, from gettext-0.14.1.
18500 + * xsize.m4: New file, from gettext-0.14.1.
18501 + * Makefile.am: New file.
18503 --- lrzsz-0.12.20.safe/m4/codeset.m4 1969-12-31 19:00:00.000000000 -0500
18504 +++ lrzsz-0.12.20/m4/codeset.m4 2004-09-12 14:40:34.820677408 -0400
18506 +# codeset.m4 serial AM1 (gettext-0.10.40)
18507 +dnl Copyright (C) 2000-2002 Free Software Foundation, Inc.
18508 +dnl This file is free software, distributed under the terms of the GNU
18509 +dnl General Public License. As a special exception to the GNU General
18510 +dnl Public License, this file may be distributed as part of a program
18511 +dnl that contains a configuration script generated by Autoconf, under
18512 +dnl the same distribution terms as the rest of that program.
18514 +dnl From Bruno Haible.
18516 +AC_DEFUN([AM_LANGINFO_CODESET],
18518 + AC_CACHE_CHECK([for nl_langinfo and CODESET], am_cv_langinfo_codeset,
18519 + [AC_TRY_LINK([#include <langinfo.h>],
18520 + [char* cs = nl_langinfo(CODESET);],
18521 + am_cv_langinfo_codeset=yes,
18522 + am_cv_langinfo_codeset=no)
18524 + if test $am_cv_langinfo_codeset = yes; then
18525 + AC_DEFINE(HAVE_LANGINFO_CODESET, 1,
18526 + [Define if you have <langinfo.h> and nl_langinfo(CODESET).])
18529 --- lrzsz-0.12.20.safe/m4/gettext.m4 1969-12-31 19:00:00.000000000 -0500
18530 +++ lrzsz-0.12.20/m4/gettext.m4 2004-09-12 14:40:34.826676496 -0400
18532 +# gettext.m4 serial 28 (gettext-0.13)
18533 +dnl Copyright (C) 1995-2003 Free Software Foundation, Inc.
18534 +dnl This file is free software, distributed under the terms of the GNU
18535 +dnl General Public License. As a special exception to the GNU General
18536 +dnl Public License, this file may be distributed as part of a program
18537 +dnl that contains a configuration script generated by Autoconf, under
18538 +dnl the same distribution terms as the rest of that program.
18540 +dnl This file can can be used in projects which are not available under
18541 +dnl the GNU General Public License or the GNU Library General Public
18542 +dnl License but which still want to provide support for the GNU gettext
18543 +dnl functionality.
18544 +dnl Please note that the actual code of the GNU gettext library is covered
18545 +dnl by the GNU Library General Public License, and the rest of the GNU
18546 +dnl gettext package package is covered by the GNU General Public License.
18547 +dnl They are *not* in the public domain.
18550 +dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
18551 +dnl Bruno Haible <haible@clisp.cons.org>, 2000-2003.
18553 +dnl Macro to add for using GNU gettext.
18555 +dnl Usage: AM_GNU_GETTEXT([INTLSYMBOL], [NEEDSYMBOL], [INTLDIR]).
18556 +dnl INTLSYMBOL can be one of 'external', 'no-libtool', 'use-libtool'. The
18557 +dnl default (if it is not specified or empty) is 'no-libtool'.
18558 +dnl INTLSYMBOL should be 'external' for packages with no intl directory,
18559 +dnl and 'no-libtool' or 'use-libtool' for packages with an intl directory.
18560 +dnl If INTLSYMBOL is 'use-libtool', then a libtool library
18561 +dnl $(top_builddir)/intl/libintl.la will be created (shared and/or static,
18562 +dnl depending on --{enable,disable}-{shared,static} and on the presence of
18563 +dnl AM-DISABLE-SHARED). If INTLSYMBOL is 'no-libtool', a static library
18564 +dnl $(top_builddir)/intl/libintl.a will be created.
18565 +dnl If NEEDSYMBOL is specified and is 'need-ngettext', then GNU gettext
18566 +dnl implementations (in libc or libintl) without the ngettext() function
18567 +dnl will be ignored. If NEEDSYMBOL is specified and is
18568 +dnl 'need-formatstring-macros', then GNU gettext implementations that don't
18569 +dnl support the ISO C 99 <inttypes.h> formatstring macros will be ignored.
18570 +dnl INTLDIR is used to find the intl libraries. If empty,
18571 +dnl the value `$(top_builddir)/intl/' is used.
18573 +dnl The result of the configuration is one of three cases:
18574 +dnl 1) GNU gettext, as included in the intl subdirectory, will be compiled
18576 +dnl Catalog format: GNU --> install in $(datadir)
18577 +dnl Catalog extension: .mo after installation, .gmo in source tree
18578 +dnl 2) GNU gettext has been found in the system's C library.
18579 +dnl Catalog format: GNU --> install in $(datadir)
18580 +dnl Catalog extension: .mo after installation, .gmo in source tree
18581 +dnl 3) No internationalization, always use English msgid.
18582 +dnl Catalog format: none
18583 +dnl Catalog extension: none
18584 +dnl If INTLSYMBOL is 'external', only cases 2 and 3 can occur.
18585 +dnl The use of .gmo is historical (it was needed to avoid overwriting the
18586 +dnl GNU format catalogs when building on a platform with an X/Open gettext),
18587 +dnl but we keep it in order not to force irrelevant filename changes on the
18590 +AC_DEFUN([AM_GNU_GETTEXT],
18592 + dnl Argument checking.
18593 + ifelse([$1], [], , [ifelse([$1], [external], , [ifelse([$1], [no-libtool], , [ifelse([$1], [use-libtool], ,
18594 + [errprint([ERROR: invalid first argument to AM_GNU_GETTEXT
18596 + ifelse([$2], [], , [ifelse([$2], [need-ngettext], , [ifelse([$2], [need-formatstring-macros], ,
18597 + [errprint([ERROR: invalid second argument to AM_GNU_GETTEXT
18599 + define(gt_included_intl, ifelse([$1], [external], [no], [yes]))
18600 + define(gt_libtool_suffix_prefix, ifelse([$1], [use-libtool], [l], []))
18602 + AC_REQUIRE([AM_PO_SUBDIRS])dnl
18603 + ifelse(gt_included_intl, yes, [
18604 + AC_REQUIRE([AM_INTL_SUBDIR])dnl
18607 + dnl Prerequisites of AC_LIB_LINKFLAGS_BODY.
18608 + AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
18609 + AC_REQUIRE([AC_LIB_RPATH])
18611 + dnl Sometimes libintl requires libiconv, so first search for libiconv.
18612 + dnl Ideally we would do this search only after the
18613 + dnl if test "$USE_NLS" = "yes"; then
18614 + dnl if test "$gt_cv_func_gnugettext_libc" != "yes"; then
18615 + dnl tests. But if configure.in invokes AM_ICONV after AM_GNU_GETTEXT
18616 + dnl the configure script would need to contain the same shell code
18617 + dnl again, outside any 'if'. There are two solutions:
18618 + dnl - Invoke AM_ICONV_LINKFLAGS_BODY here, outside any 'if'.
18619 + dnl - Control the expansions in more detail using AC_PROVIDE_IFELSE.
18620 + dnl Since AC_PROVIDE_IFELSE is only in autoconf >= 2.52 and not
18621 + dnl documented, we avoid it.
18622 + ifelse(gt_included_intl, yes, , [
18623 + AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY])
18629 + ifelse(gt_included_intl, yes, [
18630 + BUILD_INCLUDED_LIBINTL=no
18631 + USE_INCLUDED_LIBINTL=no
18637 + dnl If we use NLS figure out what method
18638 + if test "$USE_NLS" = "yes"; then
18639 + gt_use_preinstalled_gnugettext=no
18640 + ifelse(gt_included_intl, yes, [
18641 + AC_MSG_CHECKING([whether included gettext is requested])
18642 + AC_ARG_WITH(included-gettext,
18643 + [ --with-included-gettext use the GNU gettext library included here],
18644 + nls_cv_force_use_gnu_gettext=$withval,
18645 + nls_cv_force_use_gnu_gettext=no)
18646 + AC_MSG_RESULT($nls_cv_force_use_gnu_gettext)
18648 + nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
18649 + if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
18651 + dnl User does not insist on using GNU NLS library. Figure out what
18652 + dnl to use. If GNU gettext is available we use this. Else we have
18653 + dnl to fall back to GNU NLS library.
18655 + dnl Add a version number to the cache macros.
18656 + define([gt_api_version], ifelse([$2], [need-formatstring-macros], 3, ifelse([$2], [need-ngettext], 2, 1)))
18657 + define([gt_cv_func_gnugettext_libc], [gt_cv_func_gnugettext]gt_api_version[_libc])
18658 + define([gt_cv_func_gnugettext_libintl], [gt_cv_func_gnugettext]gt_api_version[_libintl])
18660 + AC_CACHE_CHECK([for GNU gettext in libc], gt_cv_func_gnugettext_libc,
18661 + [AC_TRY_LINK([#include <libintl.h>
18662 +]ifelse([$2], [need-formatstring-macros],
18663 +[#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
18664 +#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
18667 +typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
18668 +changequote([,])dnl
18669 +], [])[extern int _nl_msg_cat_cntr;
18670 +extern int *_nl_domain_bindings;],
18671 + [bindtextdomain ("", "");
18672 +return (int) gettext ("")]ifelse([$2], [need-ngettext], [ + (int) ngettext ("", "", 0)], [])[ + _nl_msg_cat_cntr + *_nl_domain_bindings],
18673 + gt_cv_func_gnugettext_libc=yes,
18674 + gt_cv_func_gnugettext_libc=no)])
18676 + if test "$gt_cv_func_gnugettext_libc" != "yes"; then
18677 + dnl Sometimes libintl requires libiconv, so first search for libiconv.
18678 + ifelse(gt_included_intl, yes, , [
18681 + dnl Search for libintl and define LIBINTL, LTLIBINTL and INCINTL
18682 + dnl accordingly. Don't use AC_LIB_LINKFLAGS_BODY([intl],[iconv])
18683 + dnl because that would add "-liconv" to LIBINTL and LTLIBINTL
18684 + dnl even if libiconv doesn't exist.
18685 + AC_LIB_LINKFLAGS_BODY([intl])
18686 + AC_CACHE_CHECK([for GNU gettext in libintl],
18687 + gt_cv_func_gnugettext_libintl,
18688 + [gt_save_CPPFLAGS="$CPPFLAGS"
18689 + CPPFLAGS="$CPPFLAGS $INCINTL"
18690 + gt_save_LIBS="$LIBS"
18691 + LIBS="$LIBS $LIBINTL"
18692 + dnl Now see whether libintl exists and does not depend on libiconv.
18693 + AC_TRY_LINK([#include <libintl.h>
18694 +]ifelse([$2], [need-formatstring-macros],
18695 +[#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
18696 +#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
18699 +typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
18700 +changequote([,])dnl
18701 +], [])[extern int _nl_msg_cat_cntr;
18703 +#ifdef __cplusplus
18706 +const char *_nl_expand_alias ();],
18707 + [bindtextdomain ("", "");
18708 +return (int) gettext ("")]ifelse([$2], [need-ngettext], [ + (int) ngettext ("", "", 0)], [])[ + _nl_msg_cat_cntr + *_nl_expand_alias (0)],
18709 + gt_cv_func_gnugettext_libintl=yes,
18710 + gt_cv_func_gnugettext_libintl=no)
18711 + dnl Now see whether libintl exists and depends on libiconv.
18712 + if test "$gt_cv_func_gnugettext_libintl" != yes && test -n "$LIBICONV"; then
18713 + LIBS="$LIBS $LIBICONV"
18714 + AC_TRY_LINK([#include <libintl.h>
18715 +]ifelse([$2], [need-formatstring-macros],
18716 +[#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
18717 +#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
18720 +typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
18721 +changequote([,])dnl
18722 +], [])[extern int _nl_msg_cat_cntr;
18724 +#ifdef __cplusplus
18727 +const char *_nl_expand_alias ();],
18728 + [bindtextdomain ("", "");
18729 +return (int) gettext ("")]ifelse([$2], [need-ngettext], [ + (int) ngettext ("", "", 0)], [])[ + _nl_msg_cat_cntr + *_nl_expand_alias (0)],
18730 + [LIBINTL="$LIBINTL $LIBICONV"
18731 + LTLIBINTL="$LTLIBINTL $LTLIBICONV"
18732 + gt_cv_func_gnugettext_libintl=yes
18735 + CPPFLAGS="$gt_save_CPPFLAGS"
18736 + LIBS="$gt_save_LIBS"])
18739 + dnl If an already present or preinstalled GNU gettext() is found,
18740 + dnl use it. But if this macro is used in GNU gettext, and GNU
18741 + dnl gettext is already preinstalled in libintl, we update this
18742 + dnl libintl. (Cf. the install rule in intl/Makefile.in.)
18743 + if test "$gt_cv_func_gnugettext_libc" = "yes" \
18744 + || { test "$gt_cv_func_gnugettext_libintl" = "yes" \
18745 + && test "$PACKAGE" != gettext-runtime \
18746 + && test "$PACKAGE" != gettext-tools; }; then
18747 + gt_use_preinstalled_gnugettext=yes
18749 + dnl Reset the values set by searching for libintl.
18755 + ifelse(gt_included_intl, yes, [
18756 + if test "$gt_use_preinstalled_gnugettext" != "yes"; then
18757 + dnl GNU gettext is not found in the C library.
18758 + dnl Fall back on included GNU gettext library.
18759 + nls_cv_use_gnu_gettext=yes
18763 + if test "$nls_cv_use_gnu_gettext" = "yes"; then
18764 + dnl Mark actions used to generate GNU NLS library.
18765 + BUILD_INCLUDED_LIBINTL=yes
18766 + USE_INCLUDED_LIBINTL=yes
18767 + LIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LIBICONV"
18768 + LTLIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LTLIBICONV"
18769 + LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'`
18772 + if test "$gt_use_preinstalled_gnugettext" = "yes" \
18773 + || test "$nls_cv_use_gnu_gettext" = "yes"; then
18774 + dnl Mark actions to use GNU gettext tools.
18779 + if test "$gt_use_preinstalled_gnugettext" = "yes" \
18780 + || test "$nls_cv_use_gnu_gettext" = "yes"; then
18781 + AC_DEFINE(ENABLE_NLS, 1,
18782 + [Define to 1 if translation of program messages to the user's native language
18789 + AC_MSG_CHECKING([whether to use NLS])
18790 + AC_MSG_RESULT([$USE_NLS])
18791 + if test "$USE_NLS" = "yes"; then
18792 + AC_MSG_CHECKING([where the gettext function comes from])
18793 + if test "$gt_use_preinstalled_gnugettext" = "yes"; then
18794 + if test "$gt_cv_func_gnugettext_libintl" = "yes"; then
18795 + gt_source="external libintl"
18800 + gt_source="included intl directory"
18802 + AC_MSG_RESULT([$gt_source])
18805 + if test "$USE_NLS" = "yes"; then
18807 + if test "$gt_use_preinstalled_gnugettext" = "yes"; then
18808 + if test "$gt_cv_func_gnugettext_libintl" = "yes"; then
18809 + AC_MSG_CHECKING([how to link with libintl])
18810 + AC_MSG_RESULT([$LIBINTL])
18811 + AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCINTL])
18814 + dnl For backward compatibility. Some packages may be using this.
18815 + AC_DEFINE(HAVE_GETTEXT, 1,
18816 + [Define if the GNU gettext() function is already present or preinstalled.])
18817 + AC_DEFINE(HAVE_DCGETTEXT, 1,
18818 + [Define if the GNU dcgettext() function is already present or preinstalled.])
18821 + dnl We need to process the po/ directory.
18825 + ifelse(gt_included_intl, yes, [
18826 + dnl If this is used in GNU gettext we have to set BUILD_INCLUDED_LIBINTL
18827 + dnl to 'yes' because some of the testsuite requires it.
18828 + if test "$PACKAGE" = gettext-runtime || test "$PACKAGE" = gettext-tools; then
18829 + BUILD_INCLUDED_LIBINTL=yes
18832 + dnl Make all variables we use known to autoconf.
18833 + AC_SUBST(BUILD_INCLUDED_LIBINTL)
18834 + AC_SUBST(USE_INCLUDED_LIBINTL)
18835 + AC_SUBST(CATOBJEXT)
18837 + dnl For backward compatibility. Some configure.ins may be using this.
18838 + nls_cv_header_intl=
18839 + nls_cv_header_libgt=
18841 + dnl For backward compatibility. Some Makefiles may be using this.
18842 + DATADIRNAME=share
18843 + AC_SUBST(DATADIRNAME)
18845 + dnl For backward compatibility. Some Makefiles may be using this.
18847 + AC_SUBST(INSTOBJEXT)
18849 + dnl For backward compatibility. Some Makefiles may be using this.
18853 + dnl For backward compatibility. Some Makefiles may be using this.
18854 + if test "$USE_INCLUDED_LIBINTL" = yes; then
18855 + INTLOBJS="\$(GETTOBJS)"
18857 + AC_SUBST(INTLOBJS)
18859 + dnl Enable libtool support if the surrounding package wishes it.
18860 + INTL_LIBTOOL_SUFFIX_PREFIX=gt_libtool_suffix_prefix
18861 + AC_SUBST(INTL_LIBTOOL_SUFFIX_PREFIX)
18864 + dnl For backward compatibility. Some Makefiles may be using this.
18865 + INTLLIBS="$LIBINTL"
18866 + AC_SUBST(INTLLIBS)
18868 + dnl Make all documented variables known to autoconf.
18869 + AC_SUBST(LIBINTL)
18870 + AC_SUBST(LTLIBINTL)
18875 +dnl Checks for all prerequisites of the intl subdirectory,
18876 +dnl except for INTL_LIBTOOL_SUFFIX_PREFIX (and possibly LIBTOOL), INTLOBJS,
18877 +dnl USE_INCLUDED_LIBINTL, BUILD_INCLUDED_LIBINTL.
18878 +AC_DEFUN([AM_INTL_SUBDIR],
18880 + AC_REQUIRE([AC_PROG_INSTALL])dnl
18881 + AC_REQUIRE([AM_MKINSTALLDIRS])dnl
18882 + AC_REQUIRE([AC_PROG_CC])dnl
18883 + AC_REQUIRE([AC_CANONICAL_HOST])dnl
18884 + AC_REQUIRE([AC_PROG_RANLIB])dnl
18885 + AC_REQUIRE([AC_ISC_POSIX])dnl
18886 + AC_REQUIRE([AC_HEADER_STDC])dnl
18887 + AC_REQUIRE([AC_C_CONST])dnl
18888 + AC_REQUIRE([bh_C_SIGNED])dnl
18889 + AC_REQUIRE([AC_C_INLINE])dnl
18890 + AC_REQUIRE([AC_TYPE_OFF_T])dnl
18891 + AC_REQUIRE([AC_TYPE_SIZE_T])dnl
18892 + AC_REQUIRE([jm_AC_TYPE_LONG_LONG])dnl
18893 + AC_REQUIRE([gt_TYPE_LONGDOUBLE])dnl
18894 + AC_REQUIRE([gt_TYPE_WCHAR_T])dnl
18895 + AC_REQUIRE([gt_TYPE_WINT_T])dnl
18896 + AC_REQUIRE([jm_AC_HEADER_INTTYPES_H])
18897 + AC_REQUIRE([jm_AC_HEADER_STDINT_H])
18898 + AC_REQUIRE([gt_TYPE_INTMAX_T])
18899 + AC_REQUIRE([gt_PRINTF_POSIX])
18900 + AC_REQUIRE([AC_FUNC_ALLOCA])dnl
18901 + AC_REQUIRE([AC_FUNC_MMAP])dnl
18902 + AC_REQUIRE([jm_GLIBC21])dnl
18903 + AC_REQUIRE([gt_INTDIV0])dnl
18904 + AC_REQUIRE([jm_AC_TYPE_UINTMAX_T])dnl
18905 + AC_REQUIRE([gt_HEADER_INTTYPES_H])dnl
18906 + AC_REQUIRE([gt_INTTYPES_PRI])dnl
18907 + AC_REQUIRE([gl_XSIZE])dnl
18909 + AC_CHECK_TYPE([ptrdiff_t], ,
18910 + [AC_DEFINE([ptrdiff_t], [long],
18911 + [Define as the type of the result of subtracting two pointers, if the system doesn't define it.])
18913 + AC_CHECK_HEADERS([argz.h limits.h locale.h nl_types.h malloc.h stddef.h \
18914 +stdlib.h string.h unistd.h sys/param.h])
18915 + AC_CHECK_FUNCS([asprintf fwprintf getcwd getegid geteuid getgid getuid \
18916 +mempcpy munmap putenv setenv setlocale snprintf stpcpy strcasecmp strdup \
18917 +strtoul tsearch wcslen __argz_count __argz_stringify __argz_next \
18920 + dnl Use the _snprintf function only if it is declared (because on NetBSD it
18921 + dnl is defined as a weak alias of snprintf; we prefer to use the latter).
18922 + gt_CHECK_DECL(_snprintf, [#include <stdio.h>])
18923 + gt_CHECK_DECL(_snwprintf, [#include <stdio.h>])
18925 + dnl Use the *_unlocked functions only if they are declared.
18926 + dnl (because some of them were defined without being declared in Solaris
18927 + dnl 2.5.1 but were removed in Solaris 2.6, whereas we want binaries built
18928 + dnl on Solaris 2.5.1 to run on Solaris 2.6).
18929 + dnl Don't use AC_CHECK_DECLS because it isn't supported in autoconf-2.13.
18930 + gt_CHECK_DECL(feof_unlocked, [#include <stdio.h>])
18931 + gt_CHECK_DECL(fgets_unlocked, [#include <stdio.h>])
18932 + gt_CHECK_DECL(getc_unlocked, [#include <stdio.h>])
18934 + case $gt_cv_func_printf_posix in
18935 + *yes) HAVE_POSIX_PRINTF=1 ;;
18936 + *) HAVE_POSIX_PRINTF=0 ;;
18938 + AC_SUBST([HAVE_POSIX_PRINTF])
18939 + if test "$ac_cv_func_asprintf" = yes; then
18944 + AC_SUBST([HAVE_ASPRINTF])
18945 + if test "$ac_cv_func_snprintf" = yes; then
18950 + AC_SUBST([HAVE_SNPRINTF])
18951 + if test "$ac_cv_func_wprintf" = yes; then
18956 + AC_SUBST([HAVE_WPRINTF])
18959 + AM_LANGINFO_CODESET
18960 + if test $ac_cv_header_locale_h = yes; then
18964 + dnl intl/plural.c is generated from intl/plural.y. It requires bison,
18965 + dnl because plural.y uses bison specific features. It requires at least
18966 + dnl bison-1.26 because earlier versions generate a plural.c that doesn't
18968 + dnl bison is only needed for the maintainer (who touches plural.y). But in
18969 + dnl order to avoid separate Makefiles or --enable-maintainer-mode, we put
18970 + dnl the rule in general Makefile. Now, some people carelessly touch the
18971 + dnl files or have a broken "make" program, hence the plural.c rule will
18972 + dnl sometimes fire. To avoid an error, defines BISON to ":" if it is not
18973 + dnl present or too old.
18974 + AC_CHECK_PROGS([INTLBISON], [bison])
18975 + if test -z "$INTLBISON"; then
18978 + dnl Found it, now check the version.
18979 + AC_MSG_CHECKING([version of bison])
18980 +changequote(<<,>>)dnl
18981 + ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'`
18982 + case $ac_prog_version in
18983 + '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
18984 + 1.2[6-9]* | 1.[3-9][0-9]* | [2-9].*)
18985 +changequote([,])dnl
18986 + ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
18987 + *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
18989 + AC_MSG_RESULT([$ac_prog_version])
18991 + if test $ac_verc_fail = yes; then
18997 +dnl gt_CHECK_DECL(FUNC, INCLUDES)
18998 +dnl Check whether a function is declared.
18999 +AC_DEFUN([gt_CHECK_DECL],
19001 + AC_CACHE_CHECK([whether $1 is declared], ac_cv_have_decl_$1,
19002 + [AC_TRY_COMPILE([$2], [
19004 + char *p = (char *) $1;
19006 +], ac_cv_have_decl_$1=yes, ac_cv_have_decl_$1=no)])
19007 + if test $ac_cv_have_decl_$1 = yes; then
19012 + AC_DEFINE_UNQUOTED([HAVE_DECL_]translit($1, [a-z], [A-Z]), [$gt_value],
19013 + [Define to 1 if you have the declaration of `$1', and to 0 if you don't.])
19017 +dnl Usage: AM_GNU_GETTEXT_VERSION([gettext-version])
19018 +AC_DEFUN([AM_GNU_GETTEXT_VERSION], [])
19019 --- lrzsz-0.12.20.safe/m4/glibc21.m4 1969-12-31 19:00:00.000000000 -0500
19020 +++ lrzsz-0.12.20/m4/glibc21.m4 2004-09-12 14:40:34.833675432 -0400
19022 +# glibc21.m4 serial 2 (fileutils-4.1.3, gettext-0.10.40)
19023 +dnl Copyright (C) 2000-2002 Free Software Foundation, Inc.
19024 +dnl This file is free software, distributed under the terms of the GNU
19025 +dnl General Public License. As a special exception to the GNU General
19026 +dnl Public License, this file may be distributed as part of a program
19027 +dnl that contains a configuration script generated by Autoconf, under
19028 +dnl the same distribution terms as the rest of that program.
19030 +# Test for the GNU C Library, version 2.1 or newer.
19031 +# From Bruno Haible.
19033 +AC_DEFUN([jm_GLIBC21],
19035 + AC_CACHE_CHECK(whether we are using the GNU C Library 2.1 or newer,
19036 + ac_cv_gnu_library_2_1,
19037 + [AC_EGREP_CPP([Lucky GNU user],
19039 +#include <features.h>
19040 +#ifdef __GNU_LIBRARY__
19041 + #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
19046 + ac_cv_gnu_library_2_1=yes,
19047 + ac_cv_gnu_library_2_1=no)
19050 + AC_SUBST(GLIBC21)
19051 + GLIBC21="$ac_cv_gnu_library_2_1"
19054 --- lrzsz-0.12.20.safe/m4/iconv.m4 1969-12-31 19:00:00.000000000 -0500
19055 +++ lrzsz-0.12.20/m4/iconv.m4 2004-09-12 14:40:34.839674520 -0400
19057 +# iconv.m4 serial AM4 (gettext-0.11.3)
19058 +dnl Copyright (C) 2000-2002 Free Software Foundation, Inc.
19059 +dnl This file is free software, distributed under the terms of the GNU
19060 +dnl General Public License. As a special exception to the GNU General
19061 +dnl Public License, this file may be distributed as part of a program
19062 +dnl that contains a configuration script generated by Autoconf, under
19063 +dnl the same distribution terms as the rest of that program.
19065 +dnl From Bruno Haible.
19067 +AC_DEFUN([AM_ICONV_LINKFLAGS_BODY],
19069 + dnl Prerequisites of AC_LIB_LINKFLAGS_BODY.
19070 + AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
19071 + AC_REQUIRE([AC_LIB_RPATH])
19073 + dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV
19075 + AC_LIB_LINKFLAGS_BODY([iconv])
19078 +AC_DEFUN([AM_ICONV_LINK],
19080 + dnl Some systems have iconv in libc, some have it in libiconv (OSF/1 and
19081 + dnl those with the standalone portable GNU libiconv installed).
19083 + dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV
19085 + AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY])
19087 + dnl Add $INCICONV to CPPFLAGS before performing the following checks,
19088 + dnl because if the user has installed libiconv and not disabled its use
19089 + dnl via --without-libiconv-prefix, he wants to use it. The first
19090 + dnl AC_TRY_LINK will then fail, the second AC_TRY_LINK will succeed.
19091 + am_save_CPPFLAGS="$CPPFLAGS"
19092 + AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCICONV])
19094 + AC_CACHE_CHECK(for iconv, am_cv_func_iconv, [
19095 + am_cv_func_iconv="no, consider installing GNU libiconv"
19096 + am_cv_lib_iconv=no
19097 + AC_TRY_LINK([#include <stdlib.h>
19098 +#include <iconv.h>],
19099 + [iconv_t cd = iconv_open("","");
19100 + iconv(cd,NULL,NULL,NULL,NULL);
19101 + iconv_close(cd);],
19102 + am_cv_func_iconv=yes)
19103 + if test "$am_cv_func_iconv" != yes; then
19104 + am_save_LIBS="$LIBS"
19105 + LIBS="$LIBS $LIBICONV"
19106 + AC_TRY_LINK([#include <stdlib.h>
19107 +#include <iconv.h>],
19108 + [iconv_t cd = iconv_open("","");
19109 + iconv(cd,NULL,NULL,NULL,NULL);
19110 + iconv_close(cd);],
19111 + am_cv_lib_iconv=yes
19112 + am_cv_func_iconv=yes)
19113 + LIBS="$am_save_LIBS"
19116 + if test "$am_cv_func_iconv" = yes; then
19117 + AC_DEFINE(HAVE_ICONV, 1, [Define if you have the iconv() function.])
19119 + if test "$am_cv_lib_iconv" = yes; then
19120 + AC_MSG_CHECKING([how to link with libiconv])
19121 + AC_MSG_RESULT([$LIBICONV])
19123 + dnl If $LIBICONV didn't lead to a usable library, we don't need $INCICONV
19125 + CPPFLAGS="$am_save_CPPFLAGS"
19129 + AC_SUBST(LIBICONV)
19130 + AC_SUBST(LTLIBICONV)
19133 +AC_DEFUN([AM_ICONV],
19136 + if test "$am_cv_func_iconv" = yes; then
19137 + AC_MSG_CHECKING([for iconv declaration])
19138 + AC_CACHE_VAL(am_cv_proto_iconv, [
19140 +#include <stdlib.h>
19141 +#include <iconv.h>
19143 +#ifdef __cplusplus
19146 +#if defined(__STDC__) || defined(__cplusplus)
19147 +size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
19151 +], [], am_cv_proto_iconv_arg1="", am_cv_proto_iconv_arg1="const")
19152 + am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"])
19153 + am_cv_proto_iconv=`echo "[$]am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
19154 + AC_MSG_RESULT([$]{ac_t:-
19155 + }[$]am_cv_proto_iconv)
19156 + AC_DEFINE_UNQUOTED(ICONV_CONST, $am_cv_proto_iconv_arg1,
19157 + [Define as const if the declaration of iconv() needs const.])
19160 --- lrzsz-0.12.20.safe/m4/intdiv0.m4 1969-12-31 19:00:00.000000000 -0500
19161 +++ lrzsz-0.12.20/m4/intdiv0.m4 2004-09-12 14:40:34.845673608 -0400
19163 +# intdiv0.m4 serial 1 (gettext-0.11.3)
19164 +dnl Copyright (C) 2002 Free Software Foundation, Inc.
19165 +dnl This file is free software, distributed under the terms of the GNU
19166 +dnl General Public License. As a special exception to the GNU General
19167 +dnl Public License, this file may be distributed as part of a program
19168 +dnl that contains a configuration script generated by Autoconf, under
19169 +dnl the same distribution terms as the rest of that program.
19171 +dnl From Bruno Haible.
19173 +AC_DEFUN([gt_INTDIV0],
19175 + AC_REQUIRE([AC_PROG_CC])dnl
19176 + AC_REQUIRE([AC_CANONICAL_HOST])dnl
19178 + AC_CACHE_CHECK([whether integer division by zero raises SIGFPE],
19179 + gt_cv_int_divbyzero_sigfpe,
19182 +#include <stdlib.h>
19183 +#include <signal.h>
19186 +#ifdef __cplusplus
19187 +sigfpe_handler (int sig)
19189 +sigfpe_handler (sig) int sig;
19192 + /* Exit with code 0 if SIGFPE, with code 1 if any other signal. */
19193 + exit (sig != SIGFPE);
19203 + signal (SIGFPE, sigfpe_handler);
19204 +/* IRIX and AIX (when "xlc -qcheck" is used) yield signal SIGTRAP. */
19205 +#if (defined (__sgi) || defined (_AIX)) && defined (SIGTRAP)
19206 + signal (SIGTRAP, sigfpe_handler);
19208 +/* Linux/SPARC yields signal SIGILL. */
19209 +#if defined (__sparc__) && defined (__linux__)
19210 + signal (SIGILL, sigfpe_handler);
19217 +], gt_cv_int_divbyzero_sigfpe=yes, gt_cv_int_divbyzero_sigfpe=no,
19219 + # Guess based on the CPU.
19220 + case "$host_cpu" in
19221 + alpha* | i[34567]86 | m68k | s390*)
19222 + gt_cv_int_divbyzero_sigfpe="guessing yes";;
19224 + gt_cv_int_divbyzero_sigfpe="guessing no";;
19228 + case "$gt_cv_int_divbyzero_sigfpe" in
19232 + AC_DEFINE_UNQUOTED(INTDIV0_RAISES_SIGFPE, $value,
19233 + [Define if integer division by zero raises signal SIGFPE.])
19235 --- lrzsz-0.12.20.safe/m4/intmax.m4 1969-12-31 19:00:00.000000000 -0500
19236 +++ lrzsz-0.12.20/m4/intmax.m4 2004-09-12 14:40:34.855672088 -0400
19238 +# intmax.m4 serial 1 (gettext-0.12)
19239 +dnl Copyright (C) 2002-2003 Free Software Foundation, Inc.
19240 +dnl This file is free software, distributed under the terms of the GNU
19241 +dnl General Public License. As a special exception to the GNU General
19242 +dnl Public License, this file may be distributed as part of a program
19243 +dnl that contains a configuration script generated by Autoconf, under
19244 +dnl the same distribution terms as the rest of that program.
19246 +dnl From Bruno Haible.
19247 +dnl Test whether the system has the 'intmax_t' type, but don't attempt to
19248 +dnl find a replacement if it is lacking.
19250 +AC_DEFUN([gt_TYPE_INTMAX_T],
19252 + AC_REQUIRE([jm_AC_HEADER_INTTYPES_H])
19253 + AC_REQUIRE([jm_AC_HEADER_STDINT_H])
19254 + AC_CACHE_CHECK(for intmax_t, gt_cv_c_intmax_t,
19255 + [AC_TRY_COMPILE([
19256 +#include <stddef.h>
19257 +#include <stdlib.h>
19258 +#if HAVE_STDINT_H_WITH_UINTMAX
19259 +#include <stdint.h>
19261 +#if HAVE_INTTYPES_H_WITH_UINTMAX
19262 +#include <inttypes.h>
19264 +], [intmax_t x = -1;], gt_cv_c_intmax_t=yes, gt_cv_c_intmax_t=no)])
19265 + if test $gt_cv_c_intmax_t = yes; then
19266 + AC_DEFINE(HAVE_INTMAX_T, 1,
19267 + [Define if you have the 'intmax_t' type in <stdint.h> or <inttypes.h>.])
19270 --- lrzsz-0.12.20.safe/m4/inttypes_h.m4 1969-12-31 19:00:00.000000000 -0500
19271 +++ lrzsz-0.12.20/m4/inttypes_h.m4 2004-09-12 14:40:34.868670112 -0400
19273 +# inttypes_h.m4 serial 5 (gettext-0.12)
19274 +dnl Copyright (C) 1997-2003 Free Software Foundation, Inc.
19275 +dnl This file is free software, distributed under the terms of the GNU
19276 +dnl General Public License. As a special exception to the GNU General
19277 +dnl Public License, this file may be distributed as part of a program
19278 +dnl that contains a configuration script generated by Autoconf, under
19279 +dnl the same distribution terms as the rest of that program.
19281 +dnl From Paul Eggert.
19283 +# Define HAVE_INTTYPES_H_WITH_UINTMAX if <inttypes.h> exists,
19284 +# doesn't clash with <sys/types.h>, and declares uintmax_t.
19286 +AC_DEFUN([jm_AC_HEADER_INTTYPES_H],
19288 + AC_CACHE_CHECK([for inttypes.h], jm_ac_cv_header_inttypes_h,
19290 + [#include <sys/types.h>
19291 +#include <inttypes.h>],
19292 + [uintmax_t i = (uintmax_t) -1;],
19293 + jm_ac_cv_header_inttypes_h=yes,
19294 + jm_ac_cv_header_inttypes_h=no)])
19295 + if test $jm_ac_cv_header_inttypes_h = yes; then
19296 + AC_DEFINE_UNQUOTED(HAVE_INTTYPES_H_WITH_UINTMAX, 1,
19297 + [Define if <inttypes.h> exists, doesn't clash with <sys/types.h>,
19298 + and declares uintmax_t. ])
19301 --- lrzsz-0.12.20.safe/m4/inttypes.m4 1969-12-31 19:00:00.000000000 -0500
19302 +++ lrzsz-0.12.20/m4/inttypes.m4 2004-09-12 14:40:34.861671176 -0400
19304 +# inttypes.m4 serial 1 (gettext-0.11.4)
19305 +dnl Copyright (C) 1997-2002 Free Software Foundation, Inc.
19306 +dnl This file is free software, distributed under the terms of the GNU
19307 +dnl General Public License. As a special exception to the GNU General
19308 +dnl Public License, this file may be distributed as part of a program
19309 +dnl that contains a configuration script generated by Autoconf, under
19310 +dnl the same distribution terms as the rest of that program.
19312 +dnl From Paul Eggert.
19314 +# Define HAVE_INTTYPES_H if <inttypes.h> exists and doesn't clash with
19317 +AC_DEFUN([gt_HEADER_INTTYPES_H],
19319 + AC_CACHE_CHECK([for inttypes.h], gt_cv_header_inttypes_h,
19322 + [#include <sys/types.h>
19323 +#include <inttypes.h>],
19324 + [], gt_cv_header_inttypes_h=yes, gt_cv_header_inttypes_h=no)
19326 + if test $gt_cv_header_inttypes_h = yes; then
19327 + AC_DEFINE_UNQUOTED(HAVE_INTTYPES_H, 1,
19328 + [Define if <inttypes.h> exists and doesn't clash with <sys/types.h>.])
19331 --- lrzsz-0.12.20.safe/m4/inttypes-pri.m4 1969-12-31 19:00:00.000000000 -0500
19332 +++ lrzsz-0.12.20/m4/inttypes-pri.m4 2004-09-12 14:40:34.874669200 -0400
19334 +# inttypes-pri.m4 serial 1 (gettext-0.11.4)
19335 +dnl Copyright (C) 1997-2002 Free Software Foundation, Inc.
19336 +dnl This file is free software, distributed under the terms of the GNU
19337 +dnl General Public License. As a special exception to the GNU General
19338 +dnl Public License, this file may be distributed as part of a program
19339 +dnl that contains a configuration script generated by Autoconf, under
19340 +dnl the same distribution terms as the rest of that program.
19342 +dnl From Bruno Haible.
19344 +# Define PRI_MACROS_BROKEN if <inttypes.h> exists and defines the PRI*
19345 +# macros to non-string values. This is the case on AIX 4.3.3.
19347 +AC_DEFUN([gt_INTTYPES_PRI],
19349 + AC_REQUIRE([gt_HEADER_INTTYPES_H])
19350 + if test $gt_cv_header_inttypes_h = yes; then
19351 + AC_CACHE_CHECK([whether the inttypes.h PRIxNN macros are broken],
19352 + gt_cv_inttypes_pri_broken,
19354 + AC_TRY_COMPILE([#include <inttypes.h>
19358 +], [], gt_cv_inttypes_pri_broken=no, gt_cv_inttypes_pri_broken=yes)
19361 + if test "$gt_cv_inttypes_pri_broken" = yes; then
19362 + AC_DEFINE_UNQUOTED(PRI_MACROS_BROKEN, 1,
19363 + [Define if <inttypes.h> exists and defines unusable PRI* macros.])
19366 --- lrzsz-0.12.20.safe/m4/isc-posix.m4 1969-12-31 19:00:00.000000000 -0500
19367 +++ lrzsz-0.12.20/m4/isc-posix.m4 2004-09-12 14:40:34.885667528 -0400
19369 +# isc-posix.m4 serial 2 (gettext-0.11.2)
19370 +dnl Copyright (C) 1995-2002 Free Software Foundation, Inc.
19371 +dnl This file is free software, distributed under the terms of the GNU
19372 +dnl General Public License. As a special exception to the GNU General
19373 +dnl Public License, this file may be distributed as part of a program
19374 +dnl that contains a configuration script generated by Autoconf, under
19375 +dnl the same distribution terms as the rest of that program.
19377 +# This file is not needed with autoconf-2.53 and newer. Remove it in 2005.
19379 +# This test replaces the one in autoconf.
19380 +# Currently this macro should have the same name as the autoconf macro
19381 +# because gettext's gettext.m4 (distributed in the automake package)
19382 +# still uses it. Otherwise, the use in gettext.m4 makes autoheader
19383 +# give these diagnostics:
19384 +# configure.in:556: AC_TRY_COMPILE was called before AC_ISC_POSIX
19385 +# configure.in:556: AC_TRY_RUN was called before AC_ISC_POSIX
19387 +undefine([AC_ISC_POSIX])
19389 +AC_DEFUN([AC_ISC_POSIX],
19391 + dnl This test replaces the obsolescent AC_ISC_POSIX kludge.
19392 + AC_CHECK_LIB(cposix, strerror, [LIBS="$LIBS -lcposix"])
19395 --- lrzsz-0.12.20.safe/m4/lcmessage.m4 1969-12-31 19:00:00.000000000 -0500
19396 +++ lrzsz-0.12.20/m4/lcmessage.m4 2004-09-12 14:40:34.902664944 -0400
19398 +# lcmessage.m4 serial 3 (gettext-0.11.3)
19399 +dnl Copyright (C) 1995-2002 Free Software Foundation, Inc.
19400 +dnl This file is free software, distributed under the terms of the GNU
19401 +dnl General Public License. As a special exception to the GNU General
19402 +dnl Public License, this file may be distributed as part of a program
19403 +dnl that contains a configuration script generated by Autoconf, under
19404 +dnl the same distribution terms as the rest of that program.
19406 +dnl This file can can be used in projects which are not available under
19407 +dnl the GNU General Public License or the GNU Library General Public
19408 +dnl License but which still want to provide support for the GNU gettext
19409 +dnl functionality.
19410 +dnl Please note that the actual code of the GNU gettext library is covered
19411 +dnl by the GNU Library General Public License, and the rest of the GNU
19412 +dnl gettext package package is covered by the GNU General Public License.
19413 +dnl They are *not* in the public domain.
19416 +dnl Ulrich Drepper <drepper@cygnus.com>, 1995.
19418 +# Check whether LC_MESSAGES is available in <locale.h>.
19420 +AC_DEFUN([AM_LC_MESSAGES],
19422 + AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES,
19423 + [AC_TRY_LINK([#include <locale.h>], [return LC_MESSAGES],
19424 + am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)])
19425 + if test $am_cv_val_LC_MESSAGES = yes; then
19426 + AC_DEFINE(HAVE_LC_MESSAGES, 1,
19427 + [Define if your <locale.h> file defines LC_MESSAGES.])
19430 --- lrzsz-0.12.20.safe/m4/lib-ld.m4 1969-12-31 19:00:00.000000000 -0500
19431 +++ lrzsz-0.12.20/m4/lib-ld.m4 2004-09-12 14:40:34.908664032 -0400
19433 +# lib-ld.m4 serial 3 (gettext-0.13)
19434 +dnl Copyright (C) 1996-2003 Free Software Foundation, Inc.
19435 +dnl This file is free software, distributed under the terms of the GNU
19436 +dnl General Public License. As a special exception to the GNU General
19437 +dnl Public License, this file may be distributed as part of a program
19438 +dnl that contains a configuration script generated by Autoconf, under
19439 +dnl the same distribution terms as the rest of that program.
19441 +dnl Subroutines of libtool.m4,
19442 +dnl with replacements s/AC_/AC_LIB/ and s/lt_cv/acl_cv/ to avoid collision
19443 +dnl with libtool.m4.
19445 +dnl From libtool-1.4. Sets the variable with_gnu_ld to yes or no.
19446 +AC_DEFUN([AC_LIB_PROG_LD_GNU],
19447 +[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], acl_cv_prog_gnu_ld,
19448 +[# I'd rather use --version here, but apparently some GNU ld's only accept -v.
19449 +case `$LD -v 2>&1 </dev/null` in
19450 +*GNU* | *'with BFD'*)
19451 + acl_cv_prog_gnu_ld=yes ;;
19453 + acl_cv_prog_gnu_ld=no ;;
19455 +with_gnu_ld=$acl_cv_prog_gnu_ld
19458 +dnl From libtool-1.4. Sets the variable LD.
19459 +AC_DEFUN([AC_LIB_PROG_LD],
19460 +[AC_ARG_WITH(gnu-ld,
19461 +[ --with-gnu-ld assume the C compiler uses GNU ld [default=no]],
19462 +test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no)
19463 +AC_REQUIRE([AC_PROG_CC])dnl
19464 +AC_REQUIRE([AC_CANONICAL_HOST])dnl
19465 +# Prepare PATH_SEPARATOR.
19466 +# The user is always right.
19467 +if test "${PATH_SEPARATOR+set}" != set; then
19468 + echo "#! /bin/sh" >conf$$.sh
19469 + echo "exit 0" >>conf$$.sh
19470 + chmod +x conf$$.sh
19471 + if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
19472 + PATH_SEPARATOR=';'
19479 +if test "$GCC" = yes; then
19480 + # Check if gcc -print-prog-name=ld gives a path.
19481 + AC_MSG_CHECKING([for ld used by GCC])
19484 + # gcc leaves a trailing carriage return which upsets mingw
19485 + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
19487 + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
19490 + # Accept absolute paths.
19491 + [[\\/]* | [A-Za-z]:[\\/]*)]
19492 + [re_direlt='/[^/][^/]*/\.\./']
19493 + # Canonicalize the path of ld
19494 + ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
19495 + while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
19496 + ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
19498 + test -z "$LD" && LD="$ac_prog"
19501 + # If it fails, then pretend we aren't using GCC.
19505 + # If it is relative, then search for the first ld in PATH.
19506 + with_gnu_ld=unknown
19509 +elif test "$with_gnu_ld" = yes; then
19510 + AC_MSG_CHECKING([for GNU ld])
19512 + AC_MSG_CHECKING([for non-GNU ld])
19514 +AC_CACHE_VAL(acl_cv_path_LD,
19515 +[if test -z "$LD"; then
19516 + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
19517 + for ac_dir in $PATH; do
19518 + test -z "$ac_dir" && ac_dir=.
19519 + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
19520 + acl_cv_path_LD="$ac_dir/$ac_prog"
19521 + # Check to see if the program is GNU ld. I'd rather use --version,
19522 + # but apparently some GNU ld's only accept -v.
19523 + # Break only if it was the GNU/non-GNU ld that we prefer.
19524 + case `"$acl_cv_path_LD" -v 2>&1 < /dev/null` in
19525 + *GNU* | *'with BFD'*)
19526 + test "$with_gnu_ld" != no && break ;;
19528 + test "$with_gnu_ld" != yes && break ;;
19532 + IFS="$ac_save_ifs"
19534 + acl_cv_path_LD="$LD" # Let the user override the test with a path.
19536 +LD="$acl_cv_path_LD"
19537 +if test -n "$LD"; then
19538 + AC_MSG_RESULT($LD)
19540 + AC_MSG_RESULT(no)
19542 +test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
19543 +AC_LIB_PROG_LD_GNU
19545 --- lrzsz-0.12.20.safe/m4/lib-link.m4 1969-12-31 19:00:00.000000000 -0500
19546 +++ lrzsz-0.12.20/m4/lib-link.m4 2004-09-12 14:40:34.914663120 -0400
19548 +# lib-link.m4 serial 4 (gettext-0.12)
19549 +dnl Copyright (C) 2001-2003 Free Software Foundation, Inc.
19550 +dnl This file is free software, distributed under the terms of the GNU
19551 +dnl General Public License. As a special exception to the GNU General
19552 +dnl Public License, this file may be distributed as part of a program
19553 +dnl that contains a configuration script generated by Autoconf, under
19554 +dnl the same distribution terms as the rest of that program.
19556 +dnl From Bruno Haible.
19558 +dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname and
19559 +dnl the libraries corresponding to explicit and implicit dependencies.
19560 +dnl Sets and AC_SUBSTs the LIB${NAME} and LTLIB${NAME} variables and
19561 +dnl augments the CPPFLAGS variable.
19562 +AC_DEFUN([AC_LIB_LINKFLAGS],
19564 + AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
19565 + AC_REQUIRE([AC_LIB_RPATH])
19566 + define([Name],[translit([$1],[./-], [___])])
19567 + define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
19568 + [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
19569 + AC_CACHE_CHECK([how to link with lib[]$1], [ac_cv_lib[]Name[]_libs], [
19570 + AC_LIB_LINKFLAGS_BODY([$1], [$2])
19571 + ac_cv_lib[]Name[]_libs="$LIB[]NAME"
19572 + ac_cv_lib[]Name[]_ltlibs="$LTLIB[]NAME"
19573 + ac_cv_lib[]Name[]_cppflags="$INC[]NAME"
19575 + LIB[]NAME="$ac_cv_lib[]Name[]_libs"
19576 + LTLIB[]NAME="$ac_cv_lib[]Name[]_ltlibs"
19577 + INC[]NAME="$ac_cv_lib[]Name[]_cppflags"
19578 + AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
19579 + AC_SUBST([LIB]NAME)
19580 + AC_SUBST([LTLIB]NAME)
19581 + dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the
19582 + dnl results of this search when this library appears as a dependency.
19583 + HAVE_LIB[]NAME=yes
19588 +dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode)
19589 +dnl searches for libname and the libraries corresponding to explicit and
19590 +dnl implicit dependencies, together with the specified include files and
19591 +dnl the ability to compile and link the specified testcode. If found, it
19592 +dnl sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} and
19593 +dnl LTLIB${NAME} variables and augments the CPPFLAGS variable, and
19594 +dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs
19595 +dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty.
19596 +AC_DEFUN([AC_LIB_HAVE_LINKFLAGS],
19598 + AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
19599 + AC_REQUIRE([AC_LIB_RPATH])
19600 + define([Name],[translit([$1],[./-], [___])])
19601 + define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
19602 + [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
19604 + dnl Search for lib[]Name and define LIB[]NAME, LTLIB[]NAME and INC[]NAME
19606 + AC_LIB_LINKFLAGS_BODY([$1], [$2])
19608 + dnl Add $INC[]NAME to CPPFLAGS before performing the following checks,
19609 + dnl because if the user has installed lib[]Name and not disabled its use
19610 + dnl via --without-lib[]Name-prefix, he wants to use it.
19611 + ac_save_CPPFLAGS="$CPPFLAGS"
19612 + AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
19614 + AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [
19615 + ac_save_LIBS="$LIBS"
19616 + LIBS="$LIBS $LIB[]NAME"
19617 + AC_TRY_LINK([$3], [$4], [ac_cv_lib[]Name=yes], [ac_cv_lib[]Name=no])
19618 + LIBS="$ac_save_LIBS"
19620 + if test "$ac_cv_lib[]Name" = yes; then
19621 + HAVE_LIB[]NAME=yes
19622 + AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the $1 library.])
19623 + AC_MSG_CHECKING([how to link with lib[]$1])
19624 + AC_MSG_RESULT([$LIB[]NAME])
19626 + HAVE_LIB[]NAME=no
19627 + dnl If $LIB[]NAME didn't lead to a usable library, we don't need
19628 + dnl $INC[]NAME either.
19629 + CPPFLAGS="$ac_save_CPPFLAGS"
19633 + AC_SUBST([HAVE_LIB]NAME)
19634 + AC_SUBST([LIB]NAME)
19635 + AC_SUBST([LTLIB]NAME)
19640 +dnl Determine the platform dependent parameters needed to use rpath:
19641 +dnl libext, shlibext, hardcode_libdir_flag_spec, hardcode_libdir_separator,
19642 +dnl hardcode_direct, hardcode_minus_L.
19643 +AC_DEFUN([AC_LIB_RPATH],
19645 + AC_REQUIRE([AC_PROG_CC]) dnl we use $CC, $GCC, $LDFLAGS
19646 + AC_REQUIRE([AC_LIB_PROG_LD]) dnl we use $LD, $with_gnu_ld
19647 + AC_REQUIRE([AC_CANONICAL_HOST]) dnl we use $host
19648 + AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT]) dnl we use $ac_aux_dir
19649 + AC_CACHE_CHECK([for shared library run path origin], acl_cv_rpath, [
19650 + CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
19651 + ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
19653 + rm -f ./conftest.sh
19654 + acl_cv_rpath=done
19657 + libext="$acl_cv_libext"
19658 + shlibext="$acl_cv_shlibext"
19659 + hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
19660 + hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
19661 + hardcode_direct="$acl_cv_hardcode_direct"
19662 + hardcode_minus_L="$acl_cv_hardcode_minus_L"
19663 + dnl Determine whether the user wants rpath handling at all.
19664 + AC_ARG_ENABLE(rpath,
19665 + [ --disable-rpath do not hardcode runtime library paths],
19666 + :, enable_rpath=yes)
19669 +dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname and
19670 +dnl the libraries corresponding to explicit and implicit dependencies.
19671 +dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables.
19672 +AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
19674 + define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
19675 + [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
19676 + dnl By default, look in $includedir and $libdir.
19677 + use_additional=yes
19678 + AC_LIB_WITH_FINAL_PREFIX([
19679 + eval additional_includedir=\"$includedir\"
19680 + eval additional_libdir=\"$libdir\"
19682 + AC_LIB_ARG_WITH([lib$1-prefix],
19683 +[ --with-lib$1-prefix[=DIR] search for lib$1 in DIR/include and DIR/lib
19684 + --without-lib$1-prefix don't search for lib$1 in includedir and libdir],
19686 + if test "X$withval" = "Xno"; then
19687 + use_additional=no
19689 + if test "X$withval" = "X"; then
19690 + AC_LIB_WITH_FINAL_PREFIX([
19691 + eval additional_includedir=\"$includedir\"
19692 + eval additional_libdir=\"$libdir\"
19695 + additional_includedir="$withval/include"
19696 + additional_libdir="$withval/lib"
19700 + dnl Search the library and its dependencies in $additional_libdir and
19701 + dnl $LDFLAGS. Using breadth-first-seach.
19707 + names_already_handled=
19708 + names_next_round='$1 $2'
19709 + while test -n "$names_next_round"; do
19710 + names_this_round="$names_next_round"
19711 + names_next_round=
19712 + for name in $names_this_round; do
19714 + for n in $names_already_handled; do
19715 + if test "$n" = "$name"; then
19716 + already_handled=yes
19720 + if test -z "$already_handled"; then
19721 + names_already_handled="$names_already_handled $name"
19722 + dnl See if it was already located by an earlier AC_LIB_LINKFLAGS
19723 + dnl or AC_LIB_HAVE_LINKFLAGS call.
19724 + uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
19725 + eval value=\"\$HAVE_LIB$uppername\"
19726 + if test -n "$value"; then
19727 + if test "$value" = yes; then
19728 + eval value=\"\$LIB$uppername\"
19729 + test -z "$value" || LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$value"
19730 + eval value=\"\$LTLIB$uppername\"
19731 + test -z "$value" || LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$value"
19733 + dnl An earlier call to AC_LIB_HAVE_LINKFLAGS has determined
19734 + dnl that this library doesn't exist. So just drop it.
19738 + dnl Search the library lib$name in $additional_libdir and $LDFLAGS
19739 + dnl and the already constructed $LIBNAME/$LTLIBNAME.
19744 + if test $use_additional = yes; then
19745 + if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
19746 + found_dir="$additional_libdir"
19747 + found_so="$additional_libdir/lib$name.$shlibext"
19748 + if test -f "$additional_libdir/lib$name.la"; then
19749 + found_la="$additional_libdir/lib$name.la"
19752 + if test -f "$additional_libdir/lib$name.$libext"; then
19753 + found_dir="$additional_libdir"
19754 + found_a="$additional_libdir/lib$name.$libext"
19755 + if test -f "$additional_libdir/lib$name.la"; then
19756 + found_la="$additional_libdir/lib$name.la"
19761 + if test "X$found_dir" = "X"; then
19762 + for x in $LDFLAGS $LTLIB[]NAME; do
19763 + AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
19766 + dir=`echo "X$x" | sed -e 's/^X-L//'`
19767 + if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
19769 + found_so="$dir/lib$name.$shlibext"
19770 + if test -f "$dir/lib$name.la"; then
19771 + found_la="$dir/lib$name.la"
19774 + if test -f "$dir/lib$name.$libext"; then
19776 + found_a="$dir/lib$name.$libext"
19777 + if test -f "$dir/lib$name.la"; then
19778 + found_la="$dir/lib$name.la"
19784 + if test "X$found_dir" != "X"; then
19789 + if test "X$found_dir" != "X"; then
19790 + dnl Found the library.
19791 + LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$found_dir -l$name"
19792 + if test "X$found_so" != "X"; then
19793 + dnl Linking with a shared library. We attempt to hardcode its
19794 + dnl directory into the executable's runpath, unless it's the
19795 + dnl standard /usr/lib.
19796 + if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
19797 + dnl No hardcoding is needed.
19798 + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
19800 + dnl Use an explicit option to hardcode DIR into the resulting
19802 + dnl Potentially add DIR to ltrpathdirs.
19803 + dnl The ltrpathdirs will be appended to $LTLIBNAME at the end.
19805 + for x in $ltrpathdirs; do
19806 + if test "X$x" = "X$found_dir"; then
19811 + if test -z "$haveit"; then
19812 + ltrpathdirs="$ltrpathdirs $found_dir"
19814 + dnl The hardcoding into $LIBNAME is system dependent.
19815 + if test "$hardcode_direct" = yes; then
19816 + dnl Using DIR/libNAME.so during linking hardcodes DIR into the
19817 + dnl resulting binary.
19818 + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
19820 + if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
19821 + dnl Use an explicit option to hardcode DIR into the resulting
19823 + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
19824 + dnl Potentially add DIR to rpathdirs.
19825 + dnl The rpathdirs will be appended to $LIBNAME at the end.
19827 + for x in $rpathdirs; do
19828 + if test "X$x" = "X$found_dir"; then
19833 + if test -z "$haveit"; then
19834 + rpathdirs="$rpathdirs $found_dir"
19837 + dnl Rely on "-L$found_dir".
19838 + dnl But don't add it if it's already contained in the LDFLAGS
19839 + dnl or the already constructed $LIBNAME
19841 + for x in $LDFLAGS $LIB[]NAME; do
19842 + AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
19843 + if test "X$x" = "X-L$found_dir"; then
19848 + if test -z "$haveit"; then
19849 + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir"
19851 + if test "$hardcode_minus_L" != no; then
19852 + dnl FIXME: Not sure whether we should use
19853 + dnl "-L$found_dir -l$name" or "-L$found_dir $found_so"
19855 + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
19857 + dnl We cannot use $hardcode_runpath_var and LD_RUN_PATH
19858 + dnl here, because this doesn't fit in flags passed to the
19859 + dnl compiler. So give up. No hardcoding. This affects only
19860 + dnl very old systems.
19861 + dnl FIXME: Not sure whether we should use
19862 + dnl "-L$found_dir -l$name" or "-L$found_dir $found_so"
19864 + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name"
19870 + if test "X$found_a" != "X"; then
19871 + dnl Linking with a static library.
19872 + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_a"
19874 + dnl We shouldn't come here, but anyway it's good to have a
19876 + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir -l$name"
19879 + dnl Assume the include files are nearby.
19880 + additional_includedir=
19881 + case "$found_dir" in
19883 + basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
19884 + additional_includedir="$basedir/include"
19887 + if test "X$additional_includedir" != "X"; then
19888 + dnl Potentially add $additional_includedir to $INCNAME.
19889 + dnl But don't add it
19890 + dnl 1. if it's the standard /usr/include,
19891 + dnl 2. if it's /usr/local/include and we are using GCC on Linux,
19892 + dnl 3. if it's already present in $CPPFLAGS or the already
19893 + dnl constructed $INCNAME,
19894 + dnl 4. if it doesn't exist as a directory.
19895 + if test "X$additional_includedir" != "X/usr/include"; then
19897 + if test "X$additional_includedir" = "X/usr/local/include"; then
19898 + if test -n "$GCC"; then
19900 + linux*) haveit=yes;;
19904 + if test -z "$haveit"; then
19905 + for x in $CPPFLAGS $INC[]NAME; do
19906 + AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
19907 + if test "X$x" = "X-I$additional_includedir"; then
19912 + if test -z "$haveit"; then
19913 + if test -d "$additional_includedir"; then
19914 + dnl Really add $additional_includedir to $INCNAME.
19915 + INC[]NAME="${INC[]NAME}${INC[]NAME:+ }-I$additional_includedir"
19921 + dnl Look for dependencies.
19922 + if test -n "$found_la"; then
19923 + dnl Read the .la file. It defines the variables
19924 + dnl dlname, library_names, old_library, dependency_libs, current,
19925 + dnl age, revision, installed, dlopen, dlpreopen, libdir.
19926 + save_libdir="$libdir"
19927 + case "$found_la" in
19928 + */* | *\\*) . "$found_la" ;;
19929 + *) . "./$found_la" ;;
19931 + libdir="$save_libdir"
19932 + dnl We use only dependency_libs.
19933 + for dep in $dependency_libs; do
19936 + additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
19937 + dnl Potentially add $additional_libdir to $LIBNAME and $LTLIBNAME.
19938 + dnl But don't add it
19939 + dnl 1. if it's the standard /usr/lib,
19940 + dnl 2. if it's /usr/local/lib and we are using GCC on Linux,
19941 + dnl 3. if it's already present in $LDFLAGS or the already
19942 + dnl constructed $LIBNAME,
19943 + dnl 4. if it doesn't exist as a directory.
19944 + if test "X$additional_libdir" != "X/usr/lib"; then
19946 + if test "X$additional_libdir" = "X/usr/local/lib"; then
19947 + if test -n "$GCC"; then
19949 + linux*) haveit=yes;;
19953 + if test -z "$haveit"; then
19955 + for x in $LDFLAGS $LIB[]NAME; do
19956 + AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
19957 + if test "X$x" = "X-L$additional_libdir"; then
19962 + if test -z "$haveit"; then
19963 + if test -d "$additional_libdir"; then
19964 + dnl Really add $additional_libdir to $LIBNAME.
19965 + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$additional_libdir"
19969 + for x in $LDFLAGS $LTLIB[]NAME; do
19970 + AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
19971 + if test "X$x" = "X-L$additional_libdir"; then
19976 + if test -z "$haveit"; then
19977 + if test -d "$additional_libdir"; then
19978 + dnl Really add $additional_libdir to $LTLIBNAME.
19979 + LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$additional_libdir"
19986 + dir=`echo "X$dep" | sed -e 's/^X-R//'`
19987 + if test "$enable_rpath" != no; then
19988 + dnl Potentially add DIR to rpathdirs.
19989 + dnl The rpathdirs will be appended to $LIBNAME at the end.
19991 + for x in $rpathdirs; do
19992 + if test "X$x" = "X$dir"; then
19997 + if test -z "$haveit"; then
19998 + rpathdirs="$rpathdirs $dir"
20000 + dnl Potentially add DIR to ltrpathdirs.
20001 + dnl The ltrpathdirs will be appended to $LTLIBNAME at the end.
20003 + for x in $ltrpathdirs; do
20004 + if test "X$x" = "X$dir"; then
20009 + if test -z "$haveit"; then
20010 + ltrpathdirs="$ltrpathdirs $dir"
20015 + dnl Handle this in the next round.
20016 + names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
20019 + dnl Handle this in the next round. Throw away the .la's
20020 + dnl directory; it is already contained in a preceding -L
20022 + names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
20025 + dnl Most likely an immediate library name.
20026 + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$dep"
20027 + LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$dep"
20033 + dnl Didn't find the library; assume it is in the system directories
20034 + dnl known to the linker and runtime loader. (All the system
20035 + dnl directories known to the linker should also be known to the
20036 + dnl runtime loader, otherwise the system is severely misconfigured.)
20037 + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name"
20038 + LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-l$name"
20044 + if test "X$rpathdirs" != "X"; then
20045 + if test -n "$hardcode_libdir_separator"; then
20046 + dnl Weird platform: only the last -rpath option counts, the user must
20047 + dnl pass all path elements in one option. We can arrange that for a
20048 + dnl single library, but not when more than one $LIBNAMEs are used.
20050 + for found_dir in $rpathdirs; do
20051 + alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
20053 + dnl Note: hardcode_libdir_flag_spec uses $libdir and $wl.
20054 + acl_save_libdir="$libdir"
20055 + libdir="$alldirs"
20056 + eval flag=\"$hardcode_libdir_flag_spec\"
20057 + libdir="$acl_save_libdir"
20058 + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag"
20060 + dnl The -rpath options are cumulative.
20061 + for found_dir in $rpathdirs; do
20062 + acl_save_libdir="$libdir"
20063 + libdir="$found_dir"
20064 + eval flag=\"$hardcode_libdir_flag_spec\"
20065 + libdir="$acl_save_libdir"
20066 + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag"
20070 + if test "X$ltrpathdirs" != "X"; then
20071 + dnl When using libtool, the option that works for both libraries and
20072 + dnl executables is -R. The -R options are cumulative.
20073 + for found_dir in $ltrpathdirs; do
20074 + LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-R$found_dir"
20079 +dnl AC_LIB_APPENDTOVAR(VAR, CONTENTS) appends the elements of CONTENTS to VAR,
20080 +dnl unless already present in VAR.
20081 +dnl Works only for CPPFLAGS, not for LIB* variables because that sometimes
20082 +dnl contains two or three consecutive elements that belong together.
20083 +AC_DEFUN([AC_LIB_APPENDTOVAR],
20085 + for element in [$2]; do
20087 + for x in $[$1]; do
20088 + AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
20089 + if test "X$x" = "X$element"; then
20094 + if test -z "$haveit"; then
20095 + [$1]="${[$1]}${[$1]:+ }$element"
20099 --- lrzsz-0.12.20.safe/m4/lib-prefix.m4 1969-12-31 19:00:00.000000000 -0500
20100 +++ lrzsz-0.12.20/m4/lib-prefix.m4 2004-09-12 14:40:34.921662056 -0400
20102 +# lib-prefix.m4 serial 3 (gettext-0.13)
20103 +dnl Copyright (C) 2001-2003 Free Software Foundation, Inc.
20104 +dnl This file is free software, distributed under the terms of the GNU
20105 +dnl General Public License. As a special exception to the GNU General
20106 +dnl Public License, this file may be distributed as part of a program
20107 +dnl that contains a configuration script generated by Autoconf, under
20108 +dnl the same distribution terms as the rest of that program.
20110 +dnl From Bruno Haible.
20112 +dnl AC_LIB_ARG_WITH is synonymous to AC_ARG_WITH in autoconf-2.13, and
20113 +dnl similar to AC_ARG_WITH in autoconf 2.52...2.57 except that is doesn't
20114 +dnl require excessive bracketing.
20115 +ifdef([AC_HELP_STRING],
20116 +[AC_DEFUN([AC_LIB_ARG_WITH], [AC_ARG_WITH([$1],[[$2]],[$3],[$4])])],
20117 +[AC_DEFUN([AC_][LIB_ARG_WITH], [AC_ARG_WITH([$1],[$2],[$3],[$4])])])
20119 +dnl AC_LIB_PREFIX adds to the CPPFLAGS and LDFLAGS the flags that are needed
20120 +dnl to access previously installed libraries. The basic assumption is that
20121 +dnl a user will want packages to use other packages he previously installed
20122 +dnl with the same --prefix option.
20123 +dnl This macro is not needed if only AC_LIB_LINKFLAGS is used to locate
20124 +dnl libraries, but is otherwise very convenient.
20125 +AC_DEFUN([AC_LIB_PREFIX],
20127 + AC_BEFORE([$0], [AC_LIB_LINKFLAGS])
20128 + AC_REQUIRE([AC_PROG_CC])
20129 + AC_REQUIRE([AC_CANONICAL_HOST])
20130 + AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
20131 + dnl By default, look in $includedir and $libdir.
20132 + use_additional=yes
20133 + AC_LIB_WITH_FINAL_PREFIX([
20134 + eval additional_includedir=\"$includedir\"
20135 + eval additional_libdir=\"$libdir\"
20137 + AC_LIB_ARG_WITH([lib-prefix],
20138 +[ --with-lib-prefix[=DIR] search for libraries in DIR/include and DIR/lib
20139 + --without-lib-prefix don't search for libraries in includedir and libdir],
20141 + if test "X$withval" = "Xno"; then
20142 + use_additional=no
20144 + if test "X$withval" = "X"; then
20145 + AC_LIB_WITH_FINAL_PREFIX([
20146 + eval additional_includedir=\"$includedir\"
20147 + eval additional_libdir=\"$libdir\"
20150 + additional_includedir="$withval/include"
20151 + additional_libdir="$withval/lib"
20155 + if test $use_additional = yes; then
20156 + dnl Potentially add $additional_includedir to $CPPFLAGS.
20157 + dnl But don't add it
20158 + dnl 1. if it's the standard /usr/include,
20159 + dnl 2. if it's already present in $CPPFLAGS,
20160 + dnl 3. if it's /usr/local/include and we are using GCC on Linux,
20161 + dnl 4. if it doesn't exist as a directory.
20162 + if test "X$additional_includedir" != "X/usr/include"; then
20164 + for x in $CPPFLAGS; do
20165 + AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
20166 + if test "X$x" = "X-I$additional_includedir"; then
20171 + if test -z "$haveit"; then
20172 + if test "X$additional_includedir" = "X/usr/local/include"; then
20173 + if test -n "$GCC"; then
20175 + linux*) haveit=yes;;
20179 + if test -z "$haveit"; then
20180 + if test -d "$additional_includedir"; then
20181 + dnl Really add $additional_includedir to $CPPFLAGS.
20182 + CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }-I$additional_includedir"
20187 + dnl Potentially add $additional_libdir to $LDFLAGS.
20188 + dnl But don't add it
20189 + dnl 1. if it's the standard /usr/lib,
20190 + dnl 2. if it's already present in $LDFLAGS,
20191 + dnl 3. if it's /usr/local/lib and we are using GCC on Linux,
20192 + dnl 4. if it doesn't exist as a directory.
20193 + if test "X$additional_libdir" != "X/usr/lib"; then
20195 + for x in $LDFLAGS; do
20196 + AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
20197 + if test "X$x" = "X-L$additional_libdir"; then
20202 + if test -z "$haveit"; then
20203 + if test "X$additional_libdir" = "X/usr/local/lib"; then
20204 + if test -n "$GCC"; then
20206 + linux*) haveit=yes;;
20210 + if test -z "$haveit"; then
20211 + if test -d "$additional_libdir"; then
20212 + dnl Really add $additional_libdir to $LDFLAGS.
20213 + LDFLAGS="${LDFLAGS}${LDFLAGS:+ }-L$additional_libdir"
20221 +dnl AC_LIB_PREPARE_PREFIX creates variables acl_final_prefix,
20222 +dnl acl_final_exec_prefix, containing the values to which $prefix and
20223 +dnl $exec_prefix will expand at the end of the configure script.
20224 +AC_DEFUN([AC_LIB_PREPARE_PREFIX],
20226 + dnl Unfortunately, prefix and exec_prefix get only finally determined
20227 + dnl at the end of configure.
20228 + if test "X$prefix" = "XNONE"; then
20229 + acl_final_prefix="$ac_default_prefix"
20231 + acl_final_prefix="$prefix"
20233 + if test "X$exec_prefix" = "XNONE"; then
20234 + acl_final_exec_prefix='${prefix}'
20236 + acl_final_exec_prefix="$exec_prefix"
20238 + acl_save_prefix="$prefix"
20239 + prefix="$acl_final_prefix"
20240 + eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
20241 + prefix="$acl_save_prefix"
20244 +dnl AC_LIB_WITH_FINAL_PREFIX([statement]) evaluates statement, with the
20245 +dnl variables prefix and exec_prefix bound to the values they will have
20246 +dnl at the end of the configure script.
20247 +AC_DEFUN([AC_LIB_WITH_FINAL_PREFIX],
20249 + acl_save_prefix="$prefix"
20250 + prefix="$acl_final_prefix"
20251 + acl_save_exec_prefix="$exec_prefix"
20252 + exec_prefix="$acl_final_exec_prefix"
20254 + exec_prefix="$acl_save_exec_prefix"
20255 + prefix="$acl_save_prefix"
20257 --- lrzsz-0.12.20.safe/m4/longdouble.m4 1969-12-31 19:00:00.000000000 -0500
20258 +++ lrzsz-0.12.20/m4/longdouble.m4 2004-09-12 14:40:34.942658864 -0400
20260 +# longdouble.m4 serial 1 (gettext-0.12)
20261 +dnl Copyright (C) 2002-2003 Free Software Foundation, Inc.
20262 +dnl This file is free software, distributed under the terms of the GNU
20263 +dnl General Public License. As a special exception to the GNU General
20264 +dnl Public License, this file may be distributed as part of a program
20265 +dnl that contains a configuration script generated by Autoconf, under
20266 +dnl the same distribution terms as the rest of that program.
20268 +dnl From Bruno Haible.
20269 +dnl Test whether the compiler supports the 'long double' type.
20270 +dnl Prerequisite: AC_PROG_CC
20272 +AC_DEFUN([gt_TYPE_LONGDOUBLE],
20274 + AC_CACHE_CHECK([for long double], gt_cv_c_long_double,
20275 + [if test "$GCC" = yes; then
20276 + gt_cv_c_long_double=yes
20279 + /* The Stardent Vistra knows sizeof(long double), but does not support it. */
20280 + long double foo = 0.0;
20281 + /* On Ultrix 4.3 cc, long double is 4 and double is 8. */
20282 + int array [2*(sizeof(long double) >= sizeof(double)) - 1];
20284 + gt_cv_c_long_double=yes, gt_cv_c_long_double=no)
20286 + if test $gt_cv_c_long_double = yes; then
20287 + AC_DEFINE(HAVE_LONG_DOUBLE, 1, [Define if you have the 'long double' type.])
20290 --- lrzsz-0.12.20.safe/m4/longlong.m4 1969-12-31 19:00:00.000000000 -0500
20291 +++ lrzsz-0.12.20/m4/longlong.m4 2004-09-12 14:40:34.949657800 -0400
20293 +# longlong.m4 serial 4
20294 +dnl Copyright (C) 1999-2003 Free Software Foundation, Inc.
20295 +dnl This file is free software, distributed under the terms of the GNU
20296 +dnl General Public License. As a special exception to the GNU General
20297 +dnl Public License, this file may be distributed as part of a program
20298 +dnl that contains a configuration script generated by Autoconf, under
20299 +dnl the same distribution terms as the rest of that program.
20301 +dnl From Paul Eggert.
20303 +# Define HAVE_LONG_LONG if 'long long' works.
20305 +AC_DEFUN([jm_AC_TYPE_LONG_LONG],
20307 + AC_CACHE_CHECK([for long long], ac_cv_type_long_long,
20308 + [AC_TRY_LINK([long long ll = 1LL; int i = 63;],
20309 + [long long llmax = (long long) -1;
20310 + return ll << i | ll >> i | llmax / ll | llmax % ll;],
20311 + ac_cv_type_long_long=yes,
20312 + ac_cv_type_long_long=no)])
20313 + if test $ac_cv_type_long_long = yes; then
20314 + AC_DEFINE(HAVE_LONG_LONG, 1,
20315 + [Define if you have the 'long long' type.])
20318 --- lrzsz-0.12.20.safe/m4/Makefile.am 1969-12-31 19:00:00.000000000 -0500
20319 +++ lrzsz-0.12.20/m4/Makefile.am 2004-09-12 14:40:35.048642752 -0400
20321 +EXTRA_DIST = codeset.m4 gettext.m4 glibc21.m4 iconv.m4 intdiv0.m4 intmax.m4 inttypes.m4 inttypes_h.m4 inttypes-pri.m4 isc-posix.m4 lcmessage.m4 lib-ld.m4 lib-link.m4 lib-prefix.m4 longdouble.m4 longlong.m4 nls.m4 po.m4 printf-posix.m4 progtest.m4 signed.m4 size_max.m4 stdint_h.m4 uintmax_t.m4 ulonglong.m4 wchar_t.m4 wint_t.m4 xsize.m4
20322 --- lrzsz-0.12.20.safe/m4/nls.m4 1969-12-31 19:00:00.000000000 -0500
20323 +++ lrzsz-0.12.20/m4/nls.m4 2004-09-12 14:40:34.955656888 -0400
20325 +# nls.m4 serial 1 (gettext-0.12)
20326 +dnl Copyright (C) 1995-2003 Free Software Foundation, Inc.
20327 +dnl This file is free software, distributed under the terms of the GNU
20328 +dnl General Public License. As a special exception to the GNU General
20329 +dnl Public License, this file may be distributed as part of a program
20330 +dnl that contains a configuration script generated by Autoconf, under
20331 +dnl the same distribution terms as the rest of that program.
20333 +dnl This file can can be used in projects which are not available under
20334 +dnl the GNU General Public License or the GNU Library General Public
20335 +dnl License but which still want to provide support for the GNU gettext
20336 +dnl functionality.
20337 +dnl Please note that the actual code of the GNU gettext library is covered
20338 +dnl by the GNU Library General Public License, and the rest of the GNU
20339 +dnl gettext package package is covered by the GNU General Public License.
20340 +dnl They are *not* in the public domain.
20343 +dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
20344 +dnl Bruno Haible <haible@clisp.cons.org>, 2000-2003.
20346 +AC_DEFUN([AM_NLS],
20348 + AC_MSG_CHECKING([whether NLS is requested])
20349 + dnl Default is enabled NLS
20350 + AC_ARG_ENABLE(nls,
20351 + [ --disable-nls do not use Native Language Support],
20352 + USE_NLS=$enableval, USE_NLS=yes)
20353 + AC_MSG_RESULT($USE_NLS)
20354 + AC_SUBST(USE_NLS)
20357 +AC_DEFUN([AM_MKINSTALLDIRS],
20359 + dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly
20360 + dnl find the mkinstalldirs script in another subdir but $(top_srcdir).
20361 + dnl Try to locate it.
20363 + if test -n "$ac_aux_dir"; then
20364 + case "$ac_aux_dir" in
20365 + /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;;
20366 + *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;;
20369 + if test -z "$MKINSTALLDIRS"; then
20370 + MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
20372 + AC_SUBST(MKINSTALLDIRS)
20374 --- lrzsz-0.12.20.safe/m4/po.m4 1969-12-31 19:00:00.000000000 -0500
20375 +++ lrzsz-0.12.20/m4/po.m4 2004-09-12 14:40:34.961655976 -0400
20377 +# po.m4 serial 3 (gettext-0.14)
20378 +dnl Copyright (C) 1995-2003 Free Software Foundation, Inc.
20379 +dnl This file is free software, distributed under the terms of the GNU
20380 +dnl General Public License. As a special exception to the GNU General
20381 +dnl Public License, this file may be distributed as part of a program
20382 +dnl that contains a configuration script generated by Autoconf, under
20383 +dnl the same distribution terms as the rest of that program.
20385 +dnl This file can can be used in projects which are not available under
20386 +dnl the GNU General Public License or the GNU Library General Public
20387 +dnl License but which still want to provide support for the GNU gettext
20388 +dnl functionality.
20389 +dnl Please note that the actual code of the GNU gettext library is covered
20390 +dnl by the GNU Library General Public License, and the rest of the GNU
20391 +dnl gettext package package is covered by the GNU General Public License.
20392 +dnl They are *not* in the public domain.
20395 +dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
20396 +dnl Bruno Haible <haible@clisp.cons.org>, 2000-2003.
20398 +dnl Checks for all prerequisites of the po subdirectory.
20399 +AC_DEFUN([AM_PO_SUBDIRS],
20401 + AC_REQUIRE([AC_PROG_MAKE_SET])dnl
20402 + AC_REQUIRE([AC_PROG_INSTALL])dnl
20403 + AC_REQUIRE([AM_MKINSTALLDIRS])dnl
20404 + AC_REQUIRE([AM_NLS])dnl
20406 + dnl Perform the following tests also if --disable-nls has been given,
20407 + dnl because they are needed for "make dist" to work.
20409 + dnl Search for GNU msgfmt in the PATH.
20410 + dnl The first test excludes Solaris msgfmt and early GNU msgfmt versions.
20411 + dnl The second test excludes FreeBSD msgfmt.
20412 + AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
20413 + [$ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
20414 + (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)],
20416 + AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
20418 + dnl Search for GNU xgettext 0.12 or newer in the PATH.
20419 + dnl The first test excludes Solaris xgettext and early GNU xgettext versions.
20420 + dnl The second test excludes FreeBSD xgettext.
20421 + AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
20422 + [$ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
20423 + (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)],
20425 + dnl Remove leftover from FreeBSD xgettext call.
20426 + rm -f messages.po
20428 + dnl Search for GNU msgmerge 0.11 or newer in the PATH.
20429 + AM_PATH_PROG_WITH_TEST(MSGMERGE, msgmerge,
20430 + [$ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1], :)
20432 + dnl This could go away some day; the PATH_PROG_WITH_TEST already does it.
20433 + dnl Test whether we really found GNU msgfmt.
20434 + if test "$GMSGFMT" != ":"; then
20435 + dnl If it is no GNU msgfmt we define it as : so that the
20436 + dnl Makefiles still can work.
20437 + if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
20438 + (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
20441 + GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
20443 + [found $GMSGFMT program is not GNU msgfmt; ignore it])
20448 + dnl This could go away some day; the PATH_PROG_WITH_TEST already does it.
20449 + dnl Test whether we really found GNU xgettext.
20450 + if test "$XGETTEXT" != ":"; then
20451 + dnl If it is no GNU xgettext we define it as : so that the
20452 + dnl Makefiles still can work.
20453 + if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
20454 + (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
20458 + [found xgettext program is not GNU xgettext; ignore it])
20461 + dnl Remove leftover from FreeBSD xgettext call.
20462 + rm -f messages.po
20465 + AC_OUTPUT_COMMANDS([
20466 + for ac_file in $CONFIG_FILES; do
20467 + # Support "outfile[:infile[:infile...]]"
20468 + case "$ac_file" in
20469 + *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
20471 + # PO directories have a Makefile.in generated from Makefile.in.in.
20472 + case "$ac_file" in */Makefile.in)
20473 + # Adjust a relative srcdir.
20474 + ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
20475 + ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`"
20476 + ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
20477 + # In autoconf-2.13 it is called $ac_given_srcdir.
20478 + # In autoconf-2.50 it is called $srcdir.
20479 + test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
20480 + case "$ac_given_srcdir" in
20481 + .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
20482 + /*) top_srcdir="$ac_given_srcdir" ;;
20483 + *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
20485 + if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
20486 + rm -f "$ac_dir/POTFILES"
20487 + test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
20488 + cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
20489 + POMAKEFILEDEPS="POTFILES.in"
20490 + # ALL_LINGUAS, POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES depend
20491 + # on $ac_dir but don't depend on user-specified configuration
20493 + if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
20494 + # The LINGUAS file contains the set of available languages.
20495 + if test -n "$OBSOLETE_ALL_LINGUAS"; then
20496 + test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
20498 + ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
20499 + # Hide the ALL_LINGUAS assigment from automake.
20500 + eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
20501 + POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
20503 + # The set of available languages was given in configure.in.
20504 + eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
20506 + # Compute POFILES
20507 + # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
20508 + # Compute UPDATEPOFILES
20509 + # as $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
20510 + # Compute DUMMYPOFILES
20511 + # as $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
20512 + # Compute GMOFILES
20513 + # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
20514 + case "$ac_given_srcdir" in
20516 + *) srcdirpre='$(srcdir)/' ;;
20522 + for lang in $ALL_LINGUAS; do
20523 + POFILES="$POFILES $srcdirpre$lang.po"
20524 + UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
20525 + DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
20526 + GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
20528 + # CATALOGS depends on both $ac_dir and the user's LINGUAS
20529 + # environment variable.
20531 + if test -n "$ALL_LINGUAS"; then
20532 + for presentlang in $ALL_LINGUAS; do
20534 + if test "%UNSET%" != "$LINGUAS"; then
20535 + desiredlanguages="$LINGUAS"
20537 + desiredlanguages="$ALL_LINGUAS"
20539 + for desiredlang in $desiredlanguages; do
20540 + # Use the presentlang catalog if desiredlang is
20541 + # a. equal to presentlang, or
20542 + # b. a variant of presentlang (because in this case,
20543 + # presentlang can be used as a fallback for messages
20544 + # which are not translated in the desiredlang catalog).
20545 + case "$desiredlang" in
20546 + "$presentlang"*) useit=yes;;
20549 + if test $useit = yes; then
20550 + INST_LINGUAS="$INST_LINGUAS $presentlang"
20555 + if test -n "$INST_LINGUAS"; then
20556 + for lang in $INST_LINGUAS; do
20557 + CATALOGS="$CATALOGS $lang.gmo"
20560 + test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
20561 + sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
20562 + for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
20563 + if test -f "$f"; then
20565 + *.orig | *.bak | *~) ;;
20566 + *) cat "$f" >> "$ac_dir/Makefile" ;;
20574 + [# Capture the value of obsolete ALL_LINGUAS because we need it to compute
20575 + # POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES, CATALOGS. But hide it
20577 + eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
20578 + # Capture the value of LINGUAS because we need it to compute CATALOGS.
20579 + LINGUAS="${LINGUAS-%UNSET%}"
20583 +dnl Postprocesses a Makefile in a directory containing PO files.
20584 +AC_DEFUN([AM_POSTPROCESS_PO_MAKEFILE],
20586 + # When this code is run, in config.status, two variables have already been
20588 + # - OBSOLETE_ALL_LINGUAS is the value of LINGUAS set in configure.in,
20589 + # - LINGUAS is the value of the environment variable LINGUAS at configure
20593 + # Adjust a relative srcdir.
20594 + ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
20595 + ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`"
20596 + ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
20597 + # In autoconf-2.13 it is called $ac_given_srcdir.
20598 + # In autoconf-2.50 it is called $srcdir.
20599 + test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
20600 + case "$ac_given_srcdir" in
20601 + .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
20602 + /*) top_srcdir="$ac_given_srcdir" ;;
20603 + *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
20606 + # Find a way to echo strings without interpreting backslash.
20607 + if test "X`(echo '\t') 2>/dev/null`" = 'X\t'; then
20610 + if test "X`(printf '%s\n' '\t') 2>/dev/null`" = 'X\t'; then
20611 + gt_echo='printf %s\n'
20618 + gt_echo='echo_func'
20622 + # A sed script that extracts the value of VARIABLE from a Makefile.
20624 +# Test if the hold space is empty.
20629 +# Yes it was empty. Look if we have the expected variable definition.
20630 +/^[ ]*VARIABLE[ ]*=/{
20631 + # Seen the first line of the variable definition.
20632 + s/^[ ]*VARIABLE[ ]*=//
20637 +# Here we are processing a line from the variable definition.
20638 +# Remove comment, more precisely replace it with a space.
20640 +# See if the line ends in a backslash.
20644 +# Print the line, without the trailing backslash.
20647 +# There was no trailing backslash. The end of the variable definition is
20648 +# reached. Clear the hold space.
20653 +# A trailing backslash means that the variable definition continues in the
20654 +# next line. Put a nonempty string into the hold space to indicate this.
20659 +changequote([,])dnl
20661 + # Set POTFILES to the value of the Makefile variable POTFILES.
20662 + sed_x_POTFILES="`$gt_echo \"$sed_x_variable\" | sed -e '/^ *#/d' -e 's/VARIABLE/POTFILES/g'`"
20663 + POTFILES=`sed -n -e "$sed_x_POTFILES" < "$ac_file"`
20664 + # Compute POTFILES_DEPS as
20665 + # $(foreach file, $(POTFILES), $(top_srcdir)/$(file))
20667 + for file in $POTFILES; do
20668 + POTFILES_DEPS="$POTFILES_DEPS "'$(top_srcdir)/'"$file"
20670 + POMAKEFILEDEPS=""
20672 + if test -n "$OBSOLETE_ALL_LINGUAS"; then
20673 + test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
20675 + if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
20676 + # The LINGUAS file contains the set of available languages.
20677 + ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
20678 + POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
20680 + # Set ALL_LINGUAS to the value of the Makefile variable LINGUAS.
20681 + sed_x_LINGUAS="`$gt_echo \"$sed_x_variable\" | sed -e '/^ *#/d' -e 's/VARIABLE/LINGUAS/g'`"
20682 + ALL_LINGUAS_=`sed -n -e "$sed_x_LINGUAS" < "$ac_file"`
20684 + # Hide the ALL_LINGUAS assigment from automake.
20685 + eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
20686 + # Compute POFILES
20687 + # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
20688 + # Compute UPDATEPOFILES
20689 + # as $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
20690 + # Compute DUMMYPOFILES
20691 + # as $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
20692 + # Compute GMOFILES
20693 + # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
20694 + # Compute PROPERTIESFILES
20695 + # as $(foreach lang, $(ALL_LINGUAS), $(top_srcdir)/$(DOMAIN)_$(lang).properties)
20696 + # Compute CLASSFILES
20697 + # as $(foreach lang, $(ALL_LINGUAS), $(top_srcdir)/$(DOMAIN)_$(lang).class)
20698 + # Compute QMFILES
20699 + # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).qm)
20700 + # Compute MSGFILES
20701 + # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(frob $(lang)).msg)
20702 + # Compute RESOURCESDLLFILES
20703 + # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(frob $(lang))/$(DOMAIN).resources.dll)
20704 + case "$ac_given_srcdir" in
20706 + *) srcdirpre='$(srcdir)/' ;;
20716 + RESOURCESDLLFILES=
20717 + for lang in $ALL_LINGUAS; do
20718 + POFILES="$POFILES $srcdirpre$lang.po"
20719 + UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
20720 + DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
20721 + GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
20722 + PROPERTIESFILES="$PROPERTIESFILES \$(top_srcdir)/\$(DOMAIN)_$lang.properties"
20723 + CLASSFILES="$CLASSFILES \$(top_srcdir)/\$(DOMAIN)_$lang.class"
20724 + QMFILES="$QMFILES $srcdirpre$lang.qm"
20725 + frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
20726 + MSGFILES="$MSGFILES $srcdirpre$frobbedlang.msg"
20727 + frobbedlang=`echo $lang | sed -e 's/_/-/g'`
20728 + RESOURCESDLLFILES="$RESOURCESDLLFILES $srcdirpre$frobbedlang/\$(DOMAIN).resources.dll"
20730 + # CATALOGS depends on both $ac_dir and the user's LINGUAS
20731 + # environment variable.
20733 + if test -n "$ALL_LINGUAS"; then
20734 + for presentlang in $ALL_LINGUAS; do
20736 + if test "%UNSET%" != "$LINGUAS"; then
20737 + desiredlanguages="$LINGUAS"
20739 + desiredlanguages="$ALL_LINGUAS"
20741 + for desiredlang in $desiredlanguages; do
20742 + # Use the presentlang catalog if desiredlang is
20743 + # a. equal to presentlang, or
20744 + # b. a variant of presentlang (because in this case,
20745 + # presentlang can be used as a fallback for messages
20746 + # which are not translated in the desiredlang catalog).
20747 + case "$desiredlang" in
20748 + "$presentlang"*) useit=yes;;
20751 + if test $useit = yes; then
20752 + INST_LINGUAS="$INST_LINGUAS $presentlang"
20761 + if test -n "$INST_LINGUAS"; then
20762 + for lang in $INST_LINGUAS; do
20763 + CATALOGS="$CATALOGS $lang.gmo"
20764 + JAVACATALOGS="$JAVACATALOGS \$(DOMAIN)_$lang.properties"
20765 + QTCATALOGS="$QTCATALOGS $lang.qm"
20766 + frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
20767 + TCLCATALOGS="$TCLCATALOGS $frobbedlang.msg"
20768 + frobbedlang=`echo $lang | sed -e 's/_/-/g'`
20769 + CSHARPCATALOGS="$CSHARPCATALOGS $frobbedlang/\$(DOMAIN).resources.dll"
20773 + sed -e "s|@POTFILES_DEPS@|$POTFILES_DEPS|g" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@PROPERTIESFILES@|$PROPERTIESFILES|g" -e "s|@CLASSFILES@|$CLASSFILES|g" -e "s|@QMFILES@|$QMFILES|g" -e "s|@MSGFILES@|$MSGFILES|g" -e "s|@RESOURCESDLLFILES@|$RESOURCESDLLFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@JAVACATALOGS@|$JAVACATALOGS|g" -e "s|@QTCATALOGS@|$QTCATALOGS|g" -e "s|@TCLCATALOGS@|$TCLCATALOGS|g" -e "s|@CSHARPCATALOGS@|$CSHARPCATALOGS|g" -e 's,^#distdir:,distdir:,' < "$ac_file" > "$ac_file.tmp"
20774 + if grep -l '@TCLCATALOGS@' "$ac_file" > /dev/null; then
20775 + # Add dependencies that cannot be formulated as a simple suffix rule.
20776 + for lang in $ALL_LINGUAS; do
20777 + frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
20778 + cat >> "$ac_file.tmp" <<EOF
20779 +$frobbedlang.msg: $lang.po
20780 + @echo "\$(MSGFMT) -c --tcl -d \$(srcdir) -l $lang $srcdirpre$lang.po"; \
20781 + \$(MSGFMT) -c --tcl -d "\$(srcdir)" -l $lang $srcdirpre$lang.po || { rm -f "\$(srcdir)/$frobbedlang.msg"; exit 1; }
20785 + if grep -l '@CSHARPCATALOGS@' "$ac_file" > /dev/null; then
20786 + # Add dependencies that cannot be formulated as a simple suffix rule.
20787 + for lang in $ALL_LINGUAS; do
20788 + frobbedlang=`echo $lang | sed -e 's/_/-/g'`
20789 + cat >> "$ac_file.tmp" <<EOF
20790 +$frobbedlang/\$(DOMAIN).resources.dll: $lang.po
20791 + @echo "\$(MSGFMT) -c --csharp -d \$(srcdir) -l $lang $srcdirpre$lang.po -r \$(DOMAIN)"; \
20792 + \$(MSGFMT) -c --csharp -d "\$(srcdir)" -l $lang $srcdirpre$lang.po -r "\$(DOMAIN)" || { rm -f "\$(srcdir)/$frobbedlang.msg"; exit 1; }
20796 + if test -n "$POMAKEFILEDEPS"; then
20797 + cat >> "$ac_file.tmp" <<EOF
20798 +Makefile: $POMAKEFILEDEPS
20801 + mv "$ac_file.tmp" "$ac_file"
20803 --- lrzsz-0.12.20.safe/m4/printf-posix.m4 1969-12-31 19:00:00.000000000 -0500
20804 +++ lrzsz-0.12.20/m4/printf-posix.m4 2004-09-12 14:40:34.974654000 -0400
20806 +# printf-posix.m4 serial 2 (gettext-0.13.1)
20807 +dnl Copyright (C) 2003 Free Software Foundation, Inc.
20808 +dnl This file is free software, distributed under the terms of the GNU
20809 +dnl General Public License. As a special exception to the GNU General
20810 +dnl Public License, this file may be distributed as part of a program
20811 +dnl that contains a configuration script generated by Autoconf, under
20812 +dnl the same distribution terms as the rest of that program.
20814 +dnl From Bruno Haible.
20815 +dnl Test whether the printf() function supports POSIX/XSI format strings with
20818 +AC_DEFUN([gt_PRINTF_POSIX],
20820 + AC_REQUIRE([AC_PROG_CC])
20821 + AC_CACHE_CHECK([whether printf() supports POSIX/XSI format strings],
20822 + gt_cv_func_printf_posix,
20825 +#include <stdio.h>
20826 +#include <string.h>
20827 +/* The string "%2$d %1$d", with dollar characters protected from the shell's
20828 + dollar expansion (possibly an autoconf bug). */
20829 +static char format[] = { '%', '2', '$', 'd', ' ', '%', '1', '$', 'd', '\0' };
20830 +static char buf[100];
20833 + sprintf (buf, format, 33, 55);
20834 + return (strcmp (buf, "55 33") != 0);
20835 +}], gt_cv_func_printf_posix=yes, gt_cv_func_printf_posix=no,
20837 + AC_EGREP_CPP(notposix, [
20838 +#if defined __NetBSD__ || defined _MSC_VER || defined __MINGW32__ || defined __CYGWIN__
20841 + ], gt_cv_func_printf_posix="guessing no",
20842 + gt_cv_func_printf_posix="guessing yes")
20845 + case $gt_cv_func_printf_posix in
20847 + AC_DEFINE(HAVE_POSIX_PRINTF, 1,
20848 + [Define if your printf() function supports format strings with positions.])
20852 --- lrzsz-0.12.20.safe/m4/progtest.m4 1969-12-31 19:00:00.000000000 -0500
20853 +++ lrzsz-0.12.20/m4/progtest.m4 2004-09-12 14:40:34.990651568 -0400
20855 +# progtest.m4 serial 3 (gettext-0.12)
20856 +dnl Copyright (C) 1996-2003 Free Software Foundation, Inc.
20857 +dnl This file is free software, distributed under the terms of the GNU
20858 +dnl General Public License. As a special exception to the GNU General
20859 +dnl Public License, this file may be distributed as part of a program
20860 +dnl that contains a configuration script generated by Autoconf, under
20861 +dnl the same distribution terms as the rest of that program.
20863 +dnl This file can can be used in projects which are not available under
20864 +dnl the GNU General Public License or the GNU Library General Public
20865 +dnl License but which still want to provide support for the GNU gettext
20866 +dnl functionality.
20867 +dnl Please note that the actual code of the GNU gettext library is covered
20868 +dnl by the GNU Library General Public License, and the rest of the GNU
20869 +dnl gettext package package is covered by the GNU General Public License.
20870 +dnl They are *not* in the public domain.
20873 +dnl Ulrich Drepper <drepper@cygnus.com>, 1996.
20875 +# Search path for a program which passes the given test.
20877 +dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR,
20878 +dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]])
20879 +AC_DEFUN([AM_PATH_PROG_WITH_TEST],
20881 +# Prepare PATH_SEPARATOR.
20882 +# The user is always right.
20883 +if test "${PATH_SEPARATOR+set}" != set; then
20884 + echo "#! /bin/sh" >conf$$.sh
20885 + echo "exit 0" >>conf$$.sh
20886 + chmod +x conf$$.sh
20887 + if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
20888 + PATH_SEPARATOR=';'
20895 +# Find out how to test for executable files. Don't use a zero-byte file,
20896 +# as systems may use methods other than mode bits to determine executability.
20897 +cat >conf$$.file <<_ASEOF
20901 +chmod +x conf$$.file
20902 +if test -x conf$$.file >/dev/null 2>&1; then
20903 + ac_executable_p="test -x"
20905 + ac_executable_p="test -f"
20909 +# Extract the first word of "$2", so it can be a program name with args.
20910 +set dummy $2; ac_word=[$]2
20911 +AC_MSG_CHECKING([for $ac_word])
20912 +AC_CACHE_VAL(ac_cv_path_$1,
20914 + [[\\/]]* | ?:[[\\/]]*)
20915 + ac_cv_path_$1="[$]$1" # Let the user override the test with a path.
20918 + ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
20919 + for ac_dir in ifelse([$5], , $PATH, [$5]); do
20920 + IFS="$ac_save_IFS"
20921 + test -z "$ac_dir" && ac_dir=.
20922 + for ac_exec_ext in '' $ac_executable_extensions; do
20923 + if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
20925 + ac_cv_path_$1="$ac_dir/$ac_word$ac_exec_ext"
20931 + IFS="$ac_save_IFS"
20932 +dnl If no 4th arg is given, leave the cache variable unset,
20933 +dnl so AC_PATH_PROGS will keep looking.
20934 +ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4"
20938 +$1="$ac_cv_path_$1"
20939 +if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then
20940 + AC_MSG_RESULT([$]$1)
20942 + AC_MSG_RESULT(no)
20946 --- lrzsz-0.12.20.safe/m4/signed.m4 1969-12-31 19:00:00.000000000 -0500
20947 +++ lrzsz-0.12.20/m4/signed.m4 2004-09-12 14:40:34.996650656 -0400
20949 +# signed.m4 serial 1 (gettext-0.10.40)
20950 +dnl Copyright (C) 2001-2002 Free Software Foundation, Inc.
20951 +dnl This file is free software, distributed under the terms of the GNU
20952 +dnl General Public License. As a special exception to the GNU General
20953 +dnl Public License, this file may be distributed as part of a program
20954 +dnl that contains a configuration script generated by Autoconf, under
20955 +dnl the same distribution terms as the rest of that program.
20957 +dnl From Bruno Haible.
20959 +AC_DEFUN([bh_C_SIGNED],
20961 + AC_CACHE_CHECK([for signed], bh_cv_c_signed,
20962 + [AC_TRY_COMPILE(, [signed char x;], bh_cv_c_signed=yes, bh_cv_c_signed=no)])
20963 + if test $bh_cv_c_signed = no; then
20964 + AC_DEFINE(signed, ,
20965 + [Define to empty if the C compiler doesn't support this keyword.])
20968 --- lrzsz-0.12.20.safe/m4/size_max.m4 1969-12-31 19:00:00.000000000 -0500
20969 +++ lrzsz-0.12.20/m4/size_max.m4 2004-09-12 14:40:35.003649592 -0400
20971 +# size_max.m4 serial 2
20972 +dnl Copyright (C) 2003 Free Software Foundation, Inc.
20973 +dnl This file is free software, distributed under the terms of the GNU
20974 +dnl General Public License. As a special exception to the GNU General
20975 +dnl Public License, this file may be distributed as part of a program
20976 +dnl that contains a configuration script generated by Autoconf, under
20977 +dnl the same distribution terms as the rest of that program.
20979 +dnl From Bruno Haible.
20981 +AC_DEFUN([gl_SIZE_MAX],
20983 + AC_CHECK_HEADERS(stdint.h)
20984 + dnl First test whether the system already has SIZE_MAX.
20985 + AC_MSG_CHECKING([for SIZE_MAX])
20987 + AC_EGREP_CPP([Found it], [
20988 +#include <limits.h>
20990 +#include <stdint.h>
20996 + if test -z "$result"; then
20997 + dnl Define it ourselves. Here we assume that the type 'size_t' is not wider
20998 + dnl than the type 'unsigned long'.
20999 + dnl The _AC_COMPUTE_INT macro works up to LONG_MAX, since it uses 'expr',
21000 + dnl which is guaranteed to work from LONG_MIN to LONG_MAX.
21001 + _AC_COMPUTE_INT([~(size_t)0 / 10], res_hi,
21002 + [#include <stddef.h>], result=?)
21003 + _AC_COMPUTE_INT([~(size_t)0 % 10], res_lo,
21004 + [#include <stddef.h>], result=?)
21005 + _AC_COMPUTE_INT([sizeof (size_t) <= sizeof (unsigned int)], fits_in_uint,
21006 + [#include <stddef.h>], result=?)
21007 + if test "$fits_in_uint" = 1; then
21008 + dnl Even though SIZE_MAX fits in an unsigned int, it must be of type
21009 + dnl 'unsigned long' if the type 'size_t' is the same as 'unsigned long'.
21010 + AC_TRY_COMPILE([#include <stddef.h>
21011 + extern size_t foo;
21012 + extern unsigned long foo;
21013 + ], [], fits_in_uint=0)
21015 + if test -z "$result"; then
21016 + if test "$fits_in_uint" = 1; then
21017 + result="$res_hi$res_lo"U
21019 + result="$res_hi$res_lo"UL
21022 + dnl Shouldn't happen, but who knows...
21023 + result='~(size_t)0'
21026 + AC_MSG_RESULT([$result])
21027 + if test "$result" != yes; then
21028 + AC_DEFINE_UNQUOTED([SIZE_MAX], [$result],
21029 + [Define as the maximum value of type 'size_t', if the system doesn't define it.])
21032 --- lrzsz-0.12.20.safe/m4/stdint_h.m4 1969-12-31 19:00:00.000000000 -0500
21033 +++ lrzsz-0.12.20/m4/stdint_h.m4 2004-09-12 14:40:35.009648680 -0400
21035 +# stdint_h.m4 serial 3 (gettext-0.12)
21036 +dnl Copyright (C) 1997-2003 Free Software Foundation, Inc.
21037 +dnl This file is free software, distributed under the terms of the GNU
21038 +dnl General Public License. As a special exception to the GNU General
21039 +dnl Public License, this file may be distributed as part of a program
21040 +dnl that contains a configuration script generated by Autoconf, under
21041 +dnl the same distribution terms as the rest of that program.
21043 +dnl From Paul Eggert.
21045 +# Define HAVE_STDINT_H_WITH_UINTMAX if <stdint.h> exists,
21046 +# doesn't clash with <sys/types.h>, and declares uintmax_t.
21048 +AC_DEFUN([jm_AC_HEADER_STDINT_H],
21050 + AC_CACHE_CHECK([for stdint.h], jm_ac_cv_header_stdint_h,
21052 + [#include <sys/types.h>
21053 +#include <stdint.h>],
21054 + [uintmax_t i = (uintmax_t) -1;],
21055 + jm_ac_cv_header_stdint_h=yes,
21056 + jm_ac_cv_header_stdint_h=no)])
21057 + if test $jm_ac_cv_header_stdint_h = yes; then
21058 + AC_DEFINE_UNQUOTED(HAVE_STDINT_H_WITH_UINTMAX, 1,
21059 + [Define if <stdint.h> exists, doesn't clash with <sys/types.h>,
21060 + and declares uintmax_t. ])
21063 --- lrzsz-0.12.20.safe/m4/uintmax_t.m4 1969-12-31 19:00:00.000000000 -0500
21064 +++ lrzsz-0.12.20/m4/uintmax_t.m4 2004-09-12 14:40:35.021646856 -0400
21066 +# uintmax_t.m4 serial 7 (gettext-0.12)
21067 +dnl Copyright (C) 1997-2003 Free Software Foundation, Inc.
21068 +dnl This file is free software, distributed under the terms of the GNU
21069 +dnl General Public License. As a special exception to the GNU General
21070 +dnl Public License, this file may be distributed as part of a program
21071 +dnl that contains a configuration script generated by Autoconf, under
21072 +dnl the same distribution terms as the rest of that program.
21074 +dnl From Paul Eggert.
21078 +# Define uintmax_t to 'unsigned long' or 'unsigned long long'
21079 +# if it is not already defined in <stdint.h> or <inttypes.h>.
21081 +AC_DEFUN([jm_AC_TYPE_UINTMAX_T],
21083 + AC_REQUIRE([jm_AC_HEADER_INTTYPES_H])
21084 + AC_REQUIRE([jm_AC_HEADER_STDINT_H])
21085 + if test $jm_ac_cv_header_inttypes_h = no && test $jm_ac_cv_header_stdint_h = no; then
21086 + AC_REQUIRE([jm_AC_TYPE_UNSIGNED_LONG_LONG])
21087 + test $ac_cv_type_unsigned_long_long = yes \
21088 + && ac_type='unsigned long long' \
21089 + || ac_type='unsigned long'
21090 + AC_DEFINE_UNQUOTED(uintmax_t, $ac_type,
21091 + [Define to unsigned long or unsigned long long
21092 + if <stdint.h> and <inttypes.h> don't define.])
21094 + AC_DEFINE(HAVE_UINTMAX_T, 1,
21095 + [Define if you have the 'uintmax_t' type in <stdint.h> or <inttypes.h>.])
21098 --- lrzsz-0.12.20.safe/m4/ulonglong.m4 1969-12-31 19:00:00.000000000 -0500
21099 +++ lrzsz-0.12.20/m4/ulonglong.m4 2004-09-12 14:40:35.028645792 -0400
21101 +# ulonglong.m4 serial 3
21102 +dnl Copyright (C) 1999-2003 Free Software Foundation, Inc.
21103 +dnl This file is free software, distributed under the terms of the GNU
21104 +dnl General Public License. As a special exception to the GNU General
21105 +dnl Public License, this file may be distributed as part of a program
21106 +dnl that contains a configuration script generated by Autoconf, under
21107 +dnl the same distribution terms as the rest of that program.
21109 +dnl From Paul Eggert.
21111 +# Define HAVE_UNSIGNED_LONG_LONG if 'unsigned long long' works.
21113 +AC_DEFUN([jm_AC_TYPE_UNSIGNED_LONG_LONG],
21115 + AC_CACHE_CHECK([for unsigned long long], ac_cv_type_unsigned_long_long,
21116 + [AC_TRY_LINK([unsigned long long ull = 1ULL; int i = 63;],
21117 + [unsigned long long ullmax = (unsigned long long) -1;
21118 + return ull << i | ull >> i | ullmax / ull | ullmax % ull;],
21119 + ac_cv_type_unsigned_long_long=yes,
21120 + ac_cv_type_unsigned_long_long=no)])
21121 + if test $ac_cv_type_unsigned_long_long = yes; then
21122 + AC_DEFINE(HAVE_UNSIGNED_LONG_LONG, 1,
21123 + [Define if you have the 'unsigned long long' type.])
21126 --- lrzsz-0.12.20.safe/m4/wchar_t.m4 1969-12-31 19:00:00.000000000 -0500
21127 +++ lrzsz-0.12.20/m4/wchar_t.m4 2004-09-12 14:40:35.034644880 -0400
21129 +# wchar_t.m4 serial 1 (gettext-0.12)
21130 +dnl Copyright (C) 2002-2003 Free Software Foundation, Inc.
21131 +dnl This file is free software, distributed under the terms of the GNU
21132 +dnl General Public License. As a special exception to the GNU General
21133 +dnl Public License, this file may be distributed as part of a program
21134 +dnl that contains a configuration script generated by Autoconf, under
21135 +dnl the same distribution terms as the rest of that program.
21137 +dnl From Bruno Haible.
21138 +dnl Test whether <stddef.h> has the 'wchar_t' type.
21139 +dnl Prerequisite: AC_PROG_CC
21141 +AC_DEFUN([gt_TYPE_WCHAR_T],
21143 + AC_CACHE_CHECK([for wchar_t], gt_cv_c_wchar_t,
21144 + [AC_TRY_COMPILE([#include <stddef.h>
21145 + wchar_t foo = (wchar_t)'\0';], ,
21146 + gt_cv_c_wchar_t=yes, gt_cv_c_wchar_t=no)])
21147 + if test $gt_cv_c_wchar_t = yes; then
21148 + AC_DEFINE(HAVE_WCHAR_T, 1, [Define if you have the 'wchar_t' type.])
21151 --- lrzsz-0.12.20.safe/m4/wint_t.m4 1969-12-31 19:00:00.000000000 -0500
21152 +++ lrzsz-0.12.20/m4/wint_t.m4 2004-09-12 14:40:35.040643968 -0400
21154 +# wint_t.m4 serial 1 (gettext-0.12)
21155 +dnl Copyright (C) 2003 Free Software Foundation, Inc.
21156 +dnl This file is free software, distributed under the terms of the GNU
21157 +dnl General Public License. As a special exception to the GNU General
21158 +dnl Public License, this file may be distributed as part of a program
21159 +dnl that contains a configuration script generated by Autoconf, under
21160 +dnl the same distribution terms as the rest of that program.
21162 +dnl From Bruno Haible.
21163 +dnl Test whether <wchar.h> has the 'wint_t' type.
21164 +dnl Prerequisite: AC_PROG_CC
21166 +AC_DEFUN([gt_TYPE_WINT_T],
21168 + AC_CACHE_CHECK([for wint_t], gt_cv_c_wint_t,
21169 + [AC_TRY_COMPILE([#include <wchar.h>
21170 + wint_t foo = (wchar_t)'\0';], ,
21171 + gt_cv_c_wint_t=yes, gt_cv_c_wint_t=no)])
21172 + if test $gt_cv_c_wint_t = yes; then
21173 + AC_DEFINE(HAVE_WINT_T, 1, [Define if you have the 'wint_t' type.])
21176 --- lrzsz-0.12.20.safe/m4/xsize.m4 1969-12-31 19:00:00.000000000 -0500
21177 +++ lrzsz-0.12.20/m4/xsize.m4 2004-09-12 14:40:35.047642904 -0400
21179 +# xsize.m4 serial 2
21180 +dnl Copyright (C) 2003 Free Software Foundation, Inc.
21181 +dnl This file is free software, distributed under the terms of the GNU
21182 +dnl General Public License. As a special exception to the GNU General
21183 +dnl Public License, this file may be distributed as part of a program
21184 +dnl that contains a configuration script generated by Autoconf, under
21185 +dnl the same distribution terms as the rest of that program.
21187 +AC_DEFUN([gl_XSIZE],
21189 + dnl Prerequisites of lib/xsize.h.
21190 + AC_REQUIRE([gl_SIZE_MAX])
21191 + AC_CHECK_HEADERS(stdint.h)
21193 --- lrzsz-0.12.20.safe/Makefile.am 1998-12-30 06:19:40.000000000 -0500
21194 +++ lrzsz-0.12.20/Makefile.am 2004-09-12 14:40:35.121631656 -0400
21196 SUBDIRS = lib intl src po man testsuite
21197 -EXTRA_DIST = check.lrzsz COMPATABILITY README.cvs README.isdn4linux \
21198 +EXTRA_DIST = config.rpath check.lrzsz COMPATABILITY README.cvs README.isdn4linux \
21199 README.gettext rpmrc buildrpm systype.in fastcheck.sh README.tests \
21200 beos-runpiped.c fastcheck.beos
21201 noinst_SCRIPTS=systype
21203 rpm: $(PR).tar.gz Specfile
21204 $(srcdir)/buildrpm $(srcdir)
21207 +ACLOCAL_AMFLAGS = -I m4
21208 --- lrzsz-0.12.20.safe/Makefile.in 1998-12-30 11:31:40.000000000 -0500
21209 +++ lrzsz-0.12.20/Makefile.in 2004-09-12 14:40:35.109633480 -0400
21210 @@ -125,7 +125,7 @@
21211 && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
21213 $(ACLOCAL_M4): configure.in acinclude.m4
21214 - cd $(srcdir) && $(ACLOCAL)
21215 + cd $(srcdir) && $(ACLOCAL) -I m4
21217 config.status: $(srcdir)/configure
21218 $(SHELL) ./config.status --recheck
21219 --- lrzsz-0.12.20.safe/mkinstalldirs 1998-04-26 09:20:52.000000000 -0400
21220 +++ lrzsz-0.12.20/mkinstalldirs 2004-09-12 14:40:34.337750824 -0400
21223 # mkinstalldirs --- make directory hierarchy
21224 -# Author: Noah Friedman <friedman@prep.ai.mit.edu>
21226 +scriptversion=2004-02-15.20
21228 +# Original author: Noah Friedman <friedman@prep.ai.mit.edu>
21229 # Created: 1993-05-16
21230 -# Last modified: 1995-03-05
21234 +# This file is maintained in Automake, please report
21235 +# bugs to <bug-automake@gnu.org> or send patches to
21236 +# <automake-patches@gnu.org>.
21241 -for file in ${1+"$@"} ; do
21242 - set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'`
21245 +Usage: mkinstalldirs [-h] [--help] [--version] [-m MODE] DIR ...
21248 - for d in ${1+"$@"} ; do
21249 - pathcomp="$pathcomp$d"
21250 - case "$pathcomp" in
21251 - -* ) pathcomp=./$pathcomp ;;
21253 +Create each directory DIR (with mode MODE, if specified), including all
21254 +leading file name components.
21256 - if test ! -d "$pathcomp"; then
21257 - echo "mkdir $pathcomp" 1>&2
21258 - mkdir "$pathcomp" > /dev/null 2>&1 || lasterr=$?
21260 +Report bugs to <bug-automake@gnu.org>."
21262 - if test ! -d "$pathcomp"; then
21263 +# process command line arguments
21264 +while test $# -gt 0 ; do
21266 + -h | --help | --h*) # -h for help
21270 + -m) # -m PERM arg
21272 + test $# -eq 0 && { echo "$usage" 1>&2; exit 1; }
21277 + echo "$0 $scriptversion"
21280 + --) # stop option processing
21284 + -*) # unknown option
21285 + echo "$usage" 1>&2
21288 + *) # first non-opt arg
21296 + if test -d "$file"; then
21307 +# Solaris 8's mkdir -p isn't thread-safe. If you mkdir -p a/b and
21308 +# mkdir -p a/c at the same time, both will detect that a is missing,
21309 +# one will create a, then the other will try to create a and die with
21310 +# a "File exists" error. This is a problem when calling mkinstalldirs
21311 +# from a parallel make. We use --version in the probe to restrict
21312 +# ourselves to GNU mkdir, which is thread-safe.
21315 + if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then
21316 + echo "mkdir -p -- $*"
21317 + exec mkdir -p -- "$@"
21319 + # On NextStep and OpenStep, the `mkdir' command does not
21320 + # recognize any option. It will interpret all options as
21321 + # directories to create, and then abort because `.' already
21323 + test -d ./-p && rmdir ./-p
21324 + test -d ./--version && rmdir ./--version
21328 + if mkdir -m "$dirmode" -p --version . >/dev/null 2>&1 &&
21329 + test ! -d ./--version; then
21330 + echo "mkdir -m $dirmode -p -- $*"
21331 + exec mkdir -m "$dirmode" -p -- "$@"
21333 + # Clean up after NextStep and OpenStep mkdir.
21334 + for d in ./-m ./-p ./--version "./$dirmode";
21336 + test -d $d && rmdir $d
21344 + set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'`
21350 + pathcomp="$pathcomp$d"
21351 + case $pathcomp in
21352 + -*) pathcomp=./$pathcomp ;;
21355 + if test ! -d "$pathcomp"; then
21356 + echo "mkdir $pathcomp"
21358 + mkdir "$pathcomp" || lasterr=$?
21360 + if test ! -d "$pathcomp"; then
21364 + if test ! -z "$dirmode"; then
21365 + echo "chmod $dirmode $pathcomp"
21367 + chmod "$dirmode" "$pathcomp" || lasterr=$?
21369 - pathcomp="$pathcomp/"
21371 + if test ! -z "$lasterr"; then
21372 + errstatus=$lasterr
21378 + pathcomp="$pathcomp/"
21384 +# Local Variables:
21385 +# mode: shell-script
21386 +# sh-indentation: 2
21387 +# eval: (add-hook 'write-file-hooks 'time-stamp)
21388 +# time-stamp-start: "scriptversion="
21389 +# time-stamp-format: "%:y-%02m-%02d.%02H"
21390 +# time-stamp-end: "$"
21392 --- lrzsz-0.12.20.safe/po/boldquot.sed 1969-12-31 19:00:00.000000000 -0500
21393 +++ lrzsz-0.12.20/po/boldquot.sed 2004-09-12 14:40:34.723692152 -0400
21395 +s/"\([^"]*\)"/“\1”/g
21396 +s/`\([^`']*\)'/‘\1’/g
21397 +s/ '\([^`']*\)' / ‘\1’ /g
21398 +s/ '\([^`']*\)'$/ ‘\1’/g
21399 +s/^'\([^`']*\)' /‘\1’ /g
21405 --- lrzsz-0.12.20.safe/po/cat-id-tbl.c 1998-12-29 04:24:24.000000000 -0500
21406 +++ lrzsz-0.12.20/po/cat-id-tbl.c 1969-12-31 19:00:00.000000000 -0500
21408 -/* Automatically generated by po2tbl.sed from lrzsz.pot. */
21411 -# include <config.h>
21414 -#include "libgettext.h"
21416 -const struct _msg_ent _msg_tbl[] = {
21418 - {"io_mode(,2) in rbsb.c not implemented\n", 2},
21419 - {"caught signal %d; exiting", 3},
21420 - {"command tries", 4},
21421 - {"packetlength", 5},
21422 - {"packetlength out of range 24..%ld", 6},
21423 - {"framelength", 7},
21424 - {"framelength out of range 32..%ld", 8},
21426 - {"min_bps must be >= 0", 10},
21427 - {"min_bps_time", 11},
21428 - {"min_bps_time must be > 1", 12},
21429 - {"hour to large (0..23)", 13},
21430 - {"unparsable stop time\n", 14},
21431 - {"minute to large (0..59)", 15},
21432 - {"stop time to small", 16},
21435 - {"timeout out of range 10..1000", 19},
21436 - {"security violation: can't do that under restricted shell\n", 20},
21437 - {"window size", 21},
21438 - {"cannot turnoff syslog", 22},
21439 - {"startup delay", 23},
21440 - {"out of memory", 24},
21441 - {"this program was never intended to be used setuid\n", 25},
21442 - {"need at least one file to send", 26},
21443 - {"Can't send command in restricted mode\n", 27},
21444 - {"hostname too long\n", 28},
21445 - {"illegal server address\n", 29},
21446 - {"can read only one file from stdin", 30},
21447 - {"Transfer incomplete\n", 31},
21448 - {"Transfer complete\n", 32},
21449 - {"send_pseudo %s: cannot open tmpfile %s: %s", 33},
21450 - {"send_pseudo %s: cannot lstat tmpfile %s: %s", 34},
21451 - {"send_pseudo %s: avoiding symlink trap", 35},
21452 - {"send_pseudo %s: cannot write to tmpfile %s: %s", 36},
21453 - {"send_pseudo %s: failed", 37},
21454 - {"send_pseudo %s: ok", 38},
21455 - {"tcp protocol init failed\n", 39},
21456 - {"Answering TIMESYNC at %s", 40},
21457 - {"timezone", 41},
21458 - {"timezone unknown", 42},
21459 - {"Can't open any requested files.", 43},
21460 - {"security violation: not allowed to upload from %s", 44},
21461 - {"cannot open %s", 45},
21462 - {"is not a file: %s", 46},
21463 - {"%s/%s: error occured", 47},
21464 - {"skipped: %s", 48},
21465 - {"%s/%s: skipped", 49},
21466 - {"Bytes Sent:%7ld BPS:%-8ld \n", 50},
21467 - {"Sending %s, %ld blocks: ", 51},
21468 - {"Give your local XMODEM receive command now.", 52},
21469 - {"Sending: %s\n", 53},
21470 - {"Timeout on pathname", 54},
21471 - {"Receiver Cancelled", 55},
21472 - {"No ACK on EOT", 56},
21473 - {"Xmodem sectors/kbytes sent: %3d/%2dk", 57},
21474 - {"Ymodem sectors/kbytes sent: %3d/%2dk", 58},
21475 - {"Cancelled", 59},
21476 - {"Timeout on sector ACK", 60},
21477 - {"NAK on sector", 61},
21478 - {"Got burst for sector ACK", 62},
21479 - {"Got %02x for sector ACK", 63},
21480 - {"Retry Count Exceeded", 64},
21481 - {"Try `%s --help' for more information.\n", 65},
21482 - {"%s version %s\n", 66},
21483 - {"Usage: %s [options] file ...\n", 67},
21484 - {" or: %s [options] -{c|i} COMMAND\n", 68},
21485 - {"Send file(s) with ZMODEM/YMODEM/XMODEM protocol\n", 69},
21487 - (X) = option applies to XMODEM only\n\
21488 - (Y) = option applies to YMODEM only\n\
21489 - (Z) = option applies to ZMODEM only\n", 70},
21491 - -+, --append append to existing destination file (Z)\n\
21492 - -2, --twostop use 2 stop bits\n\
21493 - -4, --try-4k go up to 4K blocksize\n\
21494 - --start-4k start with 4K blocksize (doesn't try 8)\n\
21495 - -8, --try-8k go up to 8K blocksize\n\
21496 - --start-8k start with 8K blocksize\n\
21497 - -a, --ascii ASCII transfer (change CR/LF to LF)\n\
21498 - -b, --binary binary transfer\n\
21499 - -B, --bufsize N buffer N bytes (N==auto: buffer whole file)\n\
21500 - -c, --command COMMAND execute remote command COMMAND (Z)\n\
21501 - -C, --command-tries N try N times to execute a command (Z)\n\
21502 - -d, --dot-to-slash change '.' to '/' in pathnames (Y/Z)\n\
21503 - --delay-startup N sleep N seconds before doing anything\n\
21504 - -e, --escape escape all control characters (Z)\n\
21505 - -E, --rename force receiver to rename files it already has\n\
21506 - -f, --full-path send full pathname (Y/Z)\n\
21507 - -i, --immediate-command CMD send remote CMD, return immediately (Z)\n\
21508 - -h, --help print this usage message\n\
21509 - -k, --1k send 1024 byte packets (X)\n\
21510 - -L, --packetlen N limit subpacket length to N bytes (Z)\n\
21511 - -l, --framelen N limit frame length to N bytes (l>=L) (Z)\n\
21512 - -m, --min-bps N stop transmission if BPS below N\n\
21513 - -M, --min-bps-time N for at least N seconds (default: 120)\n", 71},
21515 - -n, --newer send file if source newer (Z)\n\
21516 - -N, --newer-or-longer send file if source newer or longer (Z)\n\
21517 - -o, --16-bit-crc use 16 bit CRC instead of 32 bit CRC (Z)\n\
21518 - -O, --disable-timeouts disable timeout code, wait forever\n\
21519 - -p, --protect protect existing destination file (Z)\n\
21520 - -r, --resume resume interrupted file transfer (Z)\n\
21521 - -R, --restricted restricted, more secure mode\n\
21522 - -q, --quiet quiet (no progress reports)\n\
21523 - -s, --stop-at {HH:MM|+N} stop transmission at HH:MM or in N seconds\n\
21524 - --tcp build a TCP connection to transmit files\n\
21525 - --tcp-server open socket, wait for connection\n\
21526 - -u, --unlink unlink file after transmission\n\
21527 - -U, --unrestrict turn off restricted mode (if allowed to)\n\
21528 - -v, --verbose be verbose, provide debugging information\n\
21529 - -w, --windowsize N Window is N bytes (Z)\n\
21530 - -X, --xmodem use XMODEM protocol\n\
21531 - -y, --overwrite overwrite existing files\n\
21532 - -Y, --overwrite-or-skip overwrite existing files, else skip\n\
21533 - --ymodem use YMODEM protocol\n\
21534 - -Z, --zmodem use ZMODEM protocol\n\
21536 -short options use the same arguments as the long ones\n", 72},
21537 - {"got ZRQINIT", 73},
21538 - {"got ZCAN", 74},
21539 - {"blklen now %d\n", 75},
21540 - {"zsendfdata: bps rate %ld below min %ld", 76},
21541 - {"zsendfdata: reached stop time", 77},
21542 - {"Bytes Sent:%7ld/%7ld BPS:%-8ld ETA %02d:%02d ", 78},
21543 - {"calc_blklen: reduced to %d due to error\n", 79},
21544 - {"calc_blklen: returned old value %d due to low bpe diff\n", 80},
21545 - {"calc_blklen: old %ld, new %ld, d %ld\n", 81},
21546 - {"calc_blklen: calc total_bytes=%ld, bpe=%ld, ec=%ld\n", 82},
21547 - {"calc_blklen: blklen %d, ok %ld, failed %ld -> %lu\n", 83},
21548 - {"calc_blklen: returned %d as best\n", 84},
21551 -countem: Total %d %ld\n", 85},
21552 - {"Bad escape sequence %x", 86},
21553 - {"Sender Canceled", 87},
21555 - {"Bad data subpacket", 89},
21556 - {"Data subpacket too long", 90},
21557 - {"Garbage count exceeded", 91},
21559 - {"Retry %d: ", 93},
21560 - {"don't have settimeofday, will not set time\n", 94},
21561 - {"not running as root (this is good!), can not set time\n", 95},
21562 - {"bytes_per_error", 96},
21563 - {"bytes-per-error should be >100", 97},
21564 - {"O_SYNC not supported by the kernel", 98},
21565 - {"garbage on commandline", 99},
21566 - {"Usage: %s [options] [filename.if.xmodem]\n", 100},
21567 - {"Receive files with ZMODEM/YMODEM/XMODEM protocol\n", 101},
21569 - -+, --append append to existing files\n\
21570 - -a, --ascii ASCII transfer (change CR/LF to LF)\n\
21571 - -b, --binary binary transfer\n\
21572 - -B, --bufsize N buffer N bytes (N==auto: buffer whole file)\n\
21573 - -c, --with-crc Use 16 bit CRC (X)\n\
21574 - -C, --allow-remote-commands allow execution of remote commands (Z)\n\
21575 - -D, --null write all received data to /dev/null\n\
21576 - --delay-startup N sleep N seconds before doing anything\n\
21577 - -e, --escape Escape control characters (Z)\n\
21578 - -E, --rename rename any files already existing\n\
21579 - --errors N generate CRC error every N bytes (debugging)\n\
21580 - -h, --help Help, print this usage message\n\
21581 - -m, --min-bps N stop transmission if BPS below N\n\
21582 - -M, --min-bps-time N for at least N seconds (default: 120)\n\
21583 - -O, --disable-timeouts disable timeout code, wait forever for data\n\
21584 - --o-sync open output file(s) in synchronous write mode\n\
21585 - -p, --protect protect existing files\n\
21586 - -q, --quiet quiet, no progress reports\n\
21587 - -r, --resume try to resume interrupted file transfer (Z)\n\
21588 - -R, --restricted restricted, more secure mode\n\
21589 - -s, --stop-at {HH:MM|+N} stop transmission at HH:MM or in N seconds\n\
21590 - -S, --timesync request remote time (twice: set local time)\n\
21591 - --syslog[=off] turn syslog on or off, if possible\n\
21592 - -t, --timeout N set timeout to N tenths of a second\n\
21593 - -u, --keep-uppercase keep upper case filenames\n\
21594 - -U, --unrestrict disable restricted mode (if allowed to)\n\
21595 - -v, --verbose be verbose, provide debugging information\n\
21596 - -w, --windowsize N Window is N bytes (Z)\n\
21597 - -X --xmodem use XMODEM protocol\n\
21598 - -y, --overwrite Yes, clobber existing file if any\n\
21599 - --ymodem use YMODEM protocol\n\
21600 - -Z, --zmodem use ZMODEM protocol\n\
21602 -short options use the same arguments as the long ones\n", 102},
21603 - {"%s waiting to receive.", 103},
21604 - {"\rBytes received: %7ld/%7ld BPS:%-6ld \r\n", 104},
21605 - {"%s: ready to receive %s", 105},
21606 - {"\rBytes received: %7ld BPS:%-6ld \r\n", 106},
21609 -%s: %s removed.\r\n", 107},
21610 - {"Pathname fetch returned EOT", 108},
21611 - {"Received dup Sector", 109},
21612 - {"Sync Error", 110},
21614 - {"Checksum", 112},
21615 - {"Sector number garbled", 113},
21616 - {"Sender Cancelled", 114},
21617 - {"Got 0%o sector header", 115},
21618 - {"file name ends with a /, skipped: %s\n", 116},
21619 - {"zmanag=%d, Lzmanag=%d\n", 117},
21620 - {"zconv=%d\n", 118},
21621 - {"file exists, skipped: %s\n", 119},
21622 - {"TIMESYNC: here %ld, remote %ld, diff %ld seconds\n", 120},
21623 - {"TIMESYNC: cannot set time: %s\n", 121},
21624 - {"cannot tmpfile() for tcp protocol synchronization", 122},
21626 - {"Receiving: %s\n", 124},
21627 - {"Blocks received: %d", 125},
21628 - {"%s: %s exists\n", 126},
21629 - {"%s:\tSecurity Violation", 127},
21630 - {"remote command execution requested", 128},
21631 - {"not executed", 129},
21632 - {"got ZRINIT", 130},
21633 - {"Skipped", 131},
21634 - {"rzfile: bps rate %ld below min %ld", 132},
21635 - {"rzfile: reached stop time", 133},
21636 - {"\rBytes received: %7ld/%7ld BPS:%-6ld ETA %02d:%02d ", 134},
21637 - {"fgets for tcp protocol synchronization failed: ", 135},
21638 - {"file close error", 136},
21641 -int _msg_tbl_length = 136;
21642 --- lrzsz-0.12.20.safe/po/ChangeLog 1998-04-26 09:20:52.000000000 -0400
21643 +++ lrzsz-0.12.20/po/ChangeLog 2004-09-12 14:40:34.793681512 -0400
21645 +2004-09-12 gettextize <bug-gnu-gettext@gnu.org>
21647 + * boldquot.sed: New file, from gettext-0.14.1.
21648 + * en@boldquot.header: New file, from gettext-0.14.1.
21649 + * en@quot.header: New file, from gettext-0.14.1.
21650 + * insert-header.sin: New file, from gettext-0.14.1.
21651 + * quot.sed: New file, from gettext-0.14.1.
21652 + * remove-potcdate.sin: New file, from gettext-0.14.1.
21653 + * Rules-quot: New file, from gettext-0.14.1.
21654 + * cat-id-tbl.c: Remove file.
21655 + * stamp-cat-id: Remove file.
21657 /* Automatically generated by po2tbl.sed from lrzsz.pot. */
21660 --- lrzsz-0.12.20.safe/po/en@boldquot.header 1969-12-31 19:00:00.000000000 -0500
21661 +++ lrzsz-0.12.20/po/en@boldquot.header 2004-09-12 14:40:34.731690936 -0400
21663 +# All this catalog "translates" are quotation characters.
21664 +# The msgids must be ASCII and therefore cannot contain real quotation
21665 +# characters, only substitutes like grave accent (0x60), apostrophe (0x27)
21666 +# and double quote (0x22). These substitutes look strange; see
21667 +# http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
21669 +# This catalog translates grave accent (0x60) and apostrophe (0x27) to
21670 +# left single quotation mark (U+2018) and right single quotation mark (U+2019).
21671 +# It also translates pairs of apostrophe (0x27) to
21672 +# left single quotation mark (U+2018) and right single quotation mark (U+2019)
21673 +# and pairs of quotation mark (0x22) to
21674 +# left double quotation mark (U+201C) and right double quotation mark (U+201D).
21676 +# When output to an UTF-8 terminal, the quotation characters appear perfectly.
21677 +# When output to an ISO-8859-1 terminal, the single quotation marks are
21678 +# transliterated to apostrophes (by iconv in glibc 2.2 or newer) or to
21679 +# grave/acute accent (by libiconv), and the double quotation marks are
21680 +# transliterated to 0x22.
21681 +# When output to an ASCII terminal, the single quotation marks are
21682 +# transliterated to apostrophes, and the double quotation marks are
21683 +# transliterated to 0x22.
21685 +# This catalog furthermore displays the text between the quotation marks in
21686 +# bold face, assuming the VT100/XTerm escape sequences.
21688 --- lrzsz-0.12.20.safe/po/en@quot.header 1969-12-31 19:00:00.000000000 -0500
21689 +++ lrzsz-0.12.20/po/en@quot.header 2004-09-12 14:40:34.737690024 -0400
21691 +# All this catalog "translates" are quotation characters.
21692 +# The msgids must be ASCII and therefore cannot contain real quotation
21693 +# characters, only substitutes like grave accent (0x60), apostrophe (0x27)
21694 +# and double quote (0x22). These substitutes look strange; see
21695 +# http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
21697 +# This catalog translates grave accent (0x60) and apostrophe (0x27) to
21698 +# left single quotation mark (U+2018) and right single quotation mark (U+2019).
21699 +# It also translates pairs of apostrophe (0x27) to
21700 +# left single quotation mark (U+2018) and right single quotation mark (U+2019)
21701 +# and pairs of quotation mark (0x22) to
21702 +# left double quotation mark (U+201C) and right double quotation mark (U+201D).
21704 +# When output to an UTF-8 terminal, the quotation characters appear perfectly.
21705 +# When output to an ISO-8859-1 terminal, the single quotation marks are
21706 +# transliterated to apostrophes (by iconv in glibc 2.2 or newer) or to
21707 +# grave/acute accent (by libiconv), and the double quotation marks are
21708 +# transliterated to 0x22.
21709 +# When output to an ASCII terminal, the single quotation marks are
21710 +# transliterated to apostrophes, and the double quotation marks are
21711 +# transliterated to 0x22.
21713 --- lrzsz-0.12.20.safe/po/insert-header.sin 1969-12-31 19:00:00.000000000 -0500
21714 +++ lrzsz-0.12.20/po/insert-header.sin 2004-09-12 14:40:34.743689112 -0400
21716 +# Sed script that inserts the file called HEADER before the header entry.
21718 +# At each occurrence of a line starting with "msgid ", we execute the following
21719 +# commands. At the first occurrence, insert the file. At the following
21720 +# occurrences, do nothing. The distinction between the first and the following
21721 +# occurrences is achieved by looking at the hold space.
21724 +# Test if the hold space is empty.
21727 +# Yes it was empty. First occurrence. Read the file.
21729 +# Output the file's contents by reading the next line. But don't lose the
21730 +# current line while doing this.
21735 +# The hold space was nonempty. Following occurrences. Do nothing.
21739 --- lrzsz-0.12.20.safe/po/Makevars 1969-12-31 19:00:00.000000000 -0500
21740 +++ lrzsz-0.12.20/po/Makevars 2004-09-12 14:40:34.748688352 -0400
21742 +# Makefile variables for PO directory in any package using GNU gettext.
21744 +# Usually the message domain is the same as the package name.
21745 +DOMAIN = $(PACKAGE)
21747 +# These two variables depend on the location of this directory.
21751 +# These options get passed to xgettext.
21752 +XGETTEXT_OPTIONS = --keyword=_ --keyword=N_
21754 +# This is the copyright holder that gets inserted into the header of the
21755 +# $(DOMAIN).pot file. Set this to the copyright holder of the surrounding
21756 +# package. (Note that the msgstr strings, extracted from the package's
21757 +# sources, belong to the copyright holder of the package.) Translators are
21758 +# expected to transfer the copyright for their translations to this person
21759 +# or entity, or to disclaim their copyright. The empty string stands for
21760 +# the public domain; in this case the translators are expected to disclaim
21761 +# their copyright.
21762 +COPYRIGHT_HOLDER = Free Software Foundation, Inc.
21764 +# This is the email address or URL to which the translators shall report
21765 +# bugs in the untranslated strings:
21766 +# - Strings which are not entire sentences, see the maintainer guidelines
21767 +# in the GNU gettext documentation, section 'Preparing Strings'.
21768 +# - Strings which use unclear terms or require additional context to be
21770 +# - Strings which make invalid assumptions about notation of date, time or
21772 +# - Pluralisation problems.
21773 +# - Incorrect English spelling.
21774 +# - Incorrect formatting.
21775 +# It can be your email address, or a mailing list address where translators
21776 +# can write to without being subscribed, or the URL of a web page through
21777 +# which the translators can contact you.
21778 +MSGID_BUGS_ADDRESS =
21780 +# This is the list of locale categories, beyond LC_MESSAGES, for which the
21781 +# message catalogs shall be used. It is usually empty.
21782 +EXTRA_LOCALE_CATEGORIES =
21783 --- lrzsz-0.12.20.safe/po/quot.sed 1969-12-31 19:00:00.000000000 -0500
21784 +++ lrzsz-0.12.20/po/quot.sed 2004-09-12 14:40:34.754687440 -0400
21786 +s/"\([^"]*\)"/“\1”/g
21787 +s/`\([^`']*\)'/‘\1’/g
21788 +s/ '\([^`']*\)' / ‘\1’ /g
21789 +s/ '\([^`']*\)'$/ ‘\1’/g
21790 +s/^'\([^`']*\)' /‘\1’ /g
21792 --- lrzsz-0.12.20.safe/po/remove-potcdate.sin 1969-12-31 19:00:00.000000000 -0500
21793 +++ lrzsz-0.12.20/po/remove-potcdate.sin 2004-09-12 14:40:34.762686224 -0400
21795 +# Sed script that remove the POT-Creation-Date line in the header entry
21796 +# from a POT file.
21798 +# The distinction between the first and the following occurrences of the
21799 +# pattern is achieved by looking at the hold space.
21800 +/^"POT-Creation-Date: .*"$/{
21802 +# Test if the hold space is empty.
21805 +# Yes it was empty. First occurrence. Remove the line.
21810 +# The hold space was nonempty. Following occurrences. Do nothing.
21814 --- lrzsz-0.12.20.safe/po/Rules-quot 1969-12-31 19:00:00.000000000 -0500
21815 +++ lrzsz-0.12.20/po/Rules-quot 2004-09-12 14:40:34.778683792 -0400
21817 +# Special Makefile rules for English message catalogs with quotation marks.
21819 +DISTFILES.common.extra1 = quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot
21821 +.SUFFIXES: .insert-header .po-update-en
21823 +en@quot.po-create:
21824 + $(MAKE) en@quot.po-update
21825 +en@boldquot.po-create:
21826 + $(MAKE) en@boldquot.po-update
21828 +en@quot.po-update: en@quot.po-update-en
21829 +en@boldquot.po-update: en@boldquot.po-update-en
21831 +.insert-header.po-update-en:
21832 + @lang=`echo $@ | sed -e 's/\.po-update-en$$//'`; \
21833 + if test "$(PACKAGE)" = "gettext"; then PATH=`pwd`/../src:$$PATH; GETTEXTLIBDIR=`cd $(top_srcdir)/src && pwd`; export GETTEXTLIBDIR; fi; \
21835 + echo "$$lang:"; \
21836 + ll=`echo $$lang | sed -e 's/@.*//'`; \
21837 + LC_ALL=C; export LC_ALL; \
21839 + if $(MSGINIT) -i $(DOMAIN).pot --no-translator -l $$ll -o - 2>/dev/null | sed -f $$tmpdir/$$lang.insert-header | $(MSGCONV) -t UTF-8 | $(MSGFILTER) sed -f `echo $$lang | sed -e 's/.*@//'`.sed 2>/dev/null > $$tmpdir/$$lang.new.po; then \
21840 + if cmp $$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \
21841 + rm -f $$tmpdir/$$lang.new.po; \
21843 + if mv -f $$tmpdir/$$lang.new.po $$lang.po; then \
21846 + echo "creation of $$lang.po failed: cannot move $$tmpdir/$$lang.new.po to $$lang.po" 1>&2; \
21851 + echo "creation of $$lang.po failed!" 1>&2; \
21852 + rm -f $$tmpdir/$$lang.new.po; \
21855 +en@quot.insert-header: insert-header.sin
21856 + sed -e '/^#/d' -e 's/HEADER/en@quot.header/g' $(srcdir)/insert-header.sin > en@quot.insert-header
21858 +en@boldquot.insert-header: insert-header.sin
21859 + sed -e '/^#/d' -e 's/HEADER/en@boldquot.header/g' $(srcdir)/insert-header.sin > en@boldquot.insert-header
21861 +mostlyclean: mostlyclean-quot
21863 + rm -f *.insert-header
21864 --- lrzsz-0.12.20.safe/po/stamp-cat-id 1998-12-30 02:50:01.000000000 -0500
21865 +++ lrzsz-0.12.20/po/stamp-cat-id 1969-12-31 19:00:00.000000000 -0500
21868 --- lrzsz-0.12.20.safe/src/Makefile.am 1998-12-28 03:38:47.000000000 -0500
21869 +++ lrzsz-0.12.20/src/Makefile.am 2004-09-12 14:40:53.665812512 -0400
21871 lrz_SOURCES=lrz.c timing.c zperr.c zreadline.c crctab.c rbsb.c zm.c protname.c tcp.c lsyslog.c canit.c
21872 lsz_SOURCES=lsz.c timing.c zperr.c zreadline.c crctab.c rbsb.c zm.c protname.c tcp.c lsyslog.c canit.c
21873 noinst_HEADERS = timing.h zglobal.h zmodem.h
21874 -datadir = $(prefix)/@DATADIRNAME@
21875 +datadir = $(prefix)/share
21876 localedir = $(datadir)/locale
21878 DISTCLEAN_FILES=lrzszbug
21880 -LDADD = ../lib/libzmodem.a @INTLLIBS@
21881 +LDADD = ../lib/libzmodem.a @LIBINTL@
21882 AUTOMAKE_OPTIONS=ansi2knr
21883 EXTRA_DIST = ansi2knr.1 ansi2knr.c lrzszbug.in
21884 INCLUDES = -I.. -I$(srcdir) -I$(top_srcdir)/src -I../intl -I$(top_srcdir)/lib