#! /bin/sh # # This is patch #3 to gawk 3.1. cd to gawk-3.1.2 and sh this file. # Then remove all the .orig files and rename the directory gawk-3.1.3 # Changes to files that are automatically recreated have been omitted. # They will be recreated the first time you run make. # First, slight rearranging mv configure.in configure.ac rm doc/pgawk.1 touch test/arrayprm2.ok test/rstest3.ok # Now, apply the patch patch -p1 << \PATCHEOF diff -urN gawk-3.1.2/ABOUT-NLS gawk-3.1.3/ABOUT-NLS --- gawk-3.1.2/ABOUT-NLS 2003-02-20 05:38:01.000000000 -0800 +++ gawk-3.1.3/ABOUT-NLS 2003-06-16 03:25:33.000000000 -0700 @@ -171,232 +171,422 @@ ================== Languages are not equally supported in all packages. The following -matrix shows the current state of internationalization, as of August -2002. The matrix shows, in regard of each package, for which languages -PO files have been submitted to translation coordination, with a +matrix shows the current state of internationalization, as of May 2003. +The matrix shows, in regard of each package, for which languages PO +files have been submitted to translation coordination, with a translation percentage of at least 50%. - Ready PO files be bg ca cs da de el en eo es et fi fr - +----------------------------------------+ - a2ps | [] [] [] [] | - ap-utils | | - bash | [] [] [] [] | - bfd | [] [] | - binutils | [] [] | - bison | [] [] [] [] | - clisp | | - clisp | [] [] [] [] | - clisplow | | - cpio | [] [] [] [] | - darkstat | () | - diffutils | [] [] [] [] [] [] | - enscript | [] [] | - error | [] [] [] | - fetchmail | [] () [] [] [] () | - fileutils | [] [] [] [] [] | - findutils | [] [] [] [] [] [] | - flex | [] [] [] [] [] | - gas | [] [] | - gawk | [] [] [] | - gcal | [] [] | - gcc | [] [] | - gettext | [] [] [] [] [] | - gnupg | [] [] [] [] [] [] [] | - gprof | [] [] | - gpsdrive | () () () () () | - grep | [] [] [] [] [] [] [] [] | - gretl | [] | - gthumb | () () () | - hello | [] [] [] [] [] [] [] [] [] | - id-utils | [] [] [] | - indent | [] [] [] [] [] | - jpilot | () [] [] [] | - jwhois | [] [] | - kbd | [] [] [] | - ld | [] [] | - libc | [] [] [] [] [] [] [] [] | - libiconv | [] [] [] [] | - lifelines | () () | - lilypond | [] [] | - lingoteach | [] [] | - lingoteach_lessons| () () | - lynx | [] [] [] [] [] | - m4 | [] [] [] [] [] | - make | [] [] [] [] | - man-db | [] () () [] () () | - mysecretdiary | [] [] [] | - nano | [] () [] [] [] [] | - nano_1_0 | [] () [] [] [] [] | - opcodes | [] [] [] | - parted | [] [] [] [] [] | - ptx | [] [] [] [] [] [] [] | - python | | - recode | [] [] [] [] [] [] | - sed | [] [] [] [] [] [] [] [] [] [] | - sh-utils | [] [] [] [] | - sharutils | [] [] [] [] [] [] [] | - sketch | () [] () | - soundtracker | [] [] [] | - sp | [] | - tar | [] [] [] [] [] [] | - texinfo | [] [] [] [] [] | - textutils | [] [] [] [] [] | - util-linux | [] [] [] [] [] [] | - vorbis-tools | [] | - wastesedge | | - wdiff | [] [] [] [] [] [] | - wget | [] [] [] [] [] [] [] [] [] [] | - +----------------------------------------+ - be bg ca cs da de el en eo es et fi fr - 0 2 19 10 30 44 9 1 12 44 17 6 53 + Ready PO files am az be bg ca cs da de el en en_GB eo es + +-------------------------------------------+ + a2ps | [] [] [] [] | + aegis | () | + anubis | | + ap-utils | | + bash | [] [] [] | + batchelor | | + bfd | [] [] | + binutils | [] [] | + bison | [] [] [] | + bluez-pin | [] [] | + clisp | | + clisp | [] [] [] | + coreutils | [] [] [] [] | + cpio | [] [] [] | + darkstat | () [] | + diffutils | [] [] [] [] [] [] [] | + e2fsprogs | [] [] | + enscript | [] [] [] [] | + error | [] [] [] [] [] | + fetchmail | [] () [] [] [] [] | + fileutils | [] [] [] | + findutils | [] [] [] [] [] [] | + flex | [] [] [] [] | + gas | [] | + gawk | [] [] [] [] | + gcal | [] | + gcc | [] [] | + gettext | [] [] [] [] [] | + gettext-runtime | [] [] [] [] [] | + gettext-tools | [] [] | + gimp-print | [] [] [] [] [] | + gliv | | + glunarclock | [] [] [] | + gnucash | () [] | + gnucash-glossary | [] () [] | + gnupg | [] () [] [] [] [] | + gpe-calendar | [] | + gpe-conf | [] | + gpe-contacts | [] | + gpe-edit | | + gpe-login | [] | + gpe-ownerinfo | [] | + gpe-sketchbook | [] | + gpe-timesheet | | + gpe-today | [] | + gpe-todo | [] | + gphoto2 | [] [] [] [] | + gprof | [] [] | + gpsdrive | () () () | + grep | [] [] [] [] [] | + gretl | [] | + hello | [] [] [] [] [] [] | + id-utils | [] [] | + indent | [] [] [] [] | + jpilot | [] [] [] [] | + jwhois | [] | + kbd | [] [] [] [] [] | + ld | [] [] | + libc | [] [] [] [] [] [] | + libgpewidget | [] | + libiconv | [] [] [] [] [] | + lifelines | [] () | + lilypond | [] | + lingoteach | | + lingoteach_lessons | () () | + lynx | [] [] [] [] | + m4 | [] [] [] [] | + mailutils | [] [] | + make | [] [] [] | + man-db | [] () [] [] () | + mysecretdiary | [] [] [] | + nano | [] () [] [] [] | + nano_1_0 | [] () [] [] [] | + opcodes | [] [] | + parted | [] [] [] [] [] | + ptx | [] [] [] [] [] | + python | | + radius | | + recode | [] [] [] [] [] [] | + screem | | + sed | [] [] [] [] [] | + sh-utils | [] [] [] | + sharutils | [] [] [] [] [] [] | + sketch | [] () [] | + soundtracker | [] [] [] | + sp | [] | + tar | [] [] [] [] | + texinfo | [] [] [] [] | + textutils | [] [] [] [] | + tin | () () | + util-linux | [] [] [] [] [] | + vorbis-tools | [] [] [] | + wastesedge | () | + wdiff | [] [] [] [] | + wget | [] [] [] [] [] [] [] | + xchat | [] [] [] | + xpad | | + +-------------------------------------------+ + am az be bg ca cs da de el en en_GB eo es + 0 1 4 2 31 17 54 60 14 1 4 12 56 - gl he hr hu id it ja ko lv nb nl nn - +-------------------------------------+ - a2ps | () () [] | - ap-utils | | - bash | [] | - bfd | [] | - binutils | [] | - bison | [] [] [] [] | - clisp | | - clisp | [] | - clisplow | | - cpio | [] [] [] [] | - darkstat | | - diffutils | [] [] [] [] [] | - enscript | [] [] | - error | [] | - fetchmail | [] | - fileutils | [] [] [] | - findutils | [] [] [] [] [] [] [] [] | - flex | [] | - gas | | - gawk | [] | - gcal | | - gcc | [] | - gettext | [] [] | - gnupg | [] [] [] [] | - gprof | [] | - gpsdrive | [] () () | - grep | [] [] [] [] [] [] [] | - gretl | | - gthumb | () () | - hello | [] [] [] [] [] [] [] [] [] [] [] [] | - id-utils | [] [] | - indent | [] [] [] [] | - jpilot | () () | - jwhois | [] [] | - kbd | | - ld | | - libc | [] [] [] [] | - libiconv | [] [] [] | - lifelines | | - lilypond | [] | - lingoteach | [] | - lingoteach_lessons| | - lynx | [] [] [] [] | - m4 | [] [] [] [] | - make | [] [] [] [] [] [] | - man-db | () () | - mysecretdiary | [] | - nano | [] [] [] [] | - nano_1_0 | [] [] [] [] [] | - opcodes | [] [] | - parted | [] [] [] | - ptx | [] [] [] [] [] | - python | | - recode | [] [] [] | - sed | [] [] [] [] [] [] [] [] | - sh-utils | [] [] [] | - sharutils | [] [] [] | - sketch | () | - soundtracker | [] [] | - sp | | - tar | [] [] [] [] [] [] | - texinfo | [] [] [] | - textutils | [] [] [] [] | - util-linux | () [] | - vorbis-tools | [] | - wastesedge | | - wdiff | [] [] [] | - wget | [] [] [] [] [] [] | - +-------------------------------------+ - gl he hr hu id it ja ko lv nb nl nn - 23 9 12 19 16 13 26 9 1 7 19 3 + et fa fi fr ga gl he hr hu id it ja ko + +----------------------------------------+ + a2ps | [] [] [] () () | + aegis | | + anubis | [] | + ap-utils | [] | + bash | [] [] | + batchelor | [] | + bfd | [] [] | + binutils | [] [] | + bison | [] [] [] [] | + bluez-pin | [] [] [] [] | + clisp | | + clisp | [] | + coreutils | [] [] [] [] | + cpio | [] [] [] [] | + darkstat | () [] [] [] | + diffutils | [] [] [] [] [] [] [] | + e2fsprogs | | + enscript | [] [] | + error | [] [] [] [] | + fetchmail | [] | + fileutils | [] [] [] [] [] | + findutils | [] [] [] [] [] [] [] [] [] [] [] | + flex | [] [] | + gas | [] | + gawk | [] [] | + gcal | [] | + gcc | [] | + gettext | [] [] [] | + gettext-runtime | [] [] [] [] | + gettext-tools | [] | + gimp-print | [] [] | + gliv | () | + glunarclock | [] [] [] [] | + gnucash | [] | + gnucash-glossary | [] | + gnupg | [] [] [] [] [] [] [] | + gpe-calendar | [] | + gpe-conf | | + gpe-contacts | [] | + gpe-edit | [] [] | + gpe-login | [] | + gpe-ownerinfo | [] [] [] | + gpe-sketchbook | [] | + gpe-timesheet | [] [] [] | + gpe-today | [] [] | + gpe-todo | [] [] | + gphoto2 | [] [] [] | + gprof | [] [] | + gpsdrive | () [] () () | + grep | [] [] [] [] [] [] [] [] [] [] [] | + gretl | [] | + hello | [] [] [] [] [] [] [] [] [] [] [] [] [] | + id-utils | [] [] [] | + indent | [] [] [] [] [] [] [] [] | + jpilot | [] () | + jwhois | [] [] [] [] | + kbd | [] | + ld | [] | + libc | [] [] [] [] [] [] | + libgpewidget | [] [] [] | + libiconv | [] [] [] [] [] [] [] [] | + lifelines | () | + lilypond | [] | + lingoteach | [] [] | + lingoteach_lessons | | + lynx | [] [] [] [] | + m4 | [] [] [] [] | + mailutils | | + make | [] [] [] [] [] [] | + man-db | [] () () | + mysecretdiary | [] [] | + nano | [] [] [] [] | + nano_1_0 | [] [] [] [] | + opcodes | [] [] | + parted | [] [] [] | + ptx | [] [] [] [] [] [] [] | + python | | + radius | | + recode | [] [] [] [] [] [] | + screem | | + sed | [] [] [] [] [] [] [] [] | + sh-utils | [] [] [] [] [] [] | + sharutils | [] [] [] [] [] | + sketch | [] | + soundtracker | [] [] [] | + sp | [] () | + tar | [] [] [] [] [] [] [] [] [] | + texinfo | [] [] [] [] | + textutils | [] [] [] [] [] | + tin | [] () | + util-linux | [] [] [] [] () [] | + vorbis-tools | [] | + wastesedge | () | + wdiff | [] [] [] [] [] | + wget | [] [] [] [] [] [] [] [] | + xchat | [] [] [] | + xpad | | + +----------------------------------------+ + et fa fi fr ga gl he hr hu id it ja ko + 20 1 15 73 14 24 8 10 30 31 19 31 9 - no pl pt pt_BR ru sk sl sv tr uk zh_CN zh_TW - +----------------------------------------------+ - a2ps | () () () [] [] [] [] [] | 10 - ap-utils | () | 0 - bash | [] | 6 - bfd | [] [] | 5 - binutils | [] [] | 5 - bison | [] [] [] [] | 12 - clisp | | 0 - clisp | | 5 - clisplow | | 0 - cpio | [] [] [] [] | 12 - darkstat | [] [] () () | 2 - diffutils | [] [] [] [] [] [] | 17 - enscript | [] [] [] [] | 8 - error | [] [] [] | 7 - fetchmail | () () [] | 6 - fileutils | [] [] [] [] [] [] | 14 - findutils | [] [] [] [] [] [] [] | 21 - flex | [] [] [] | 9 - gas | [] | 3 - gawk | [] [] | 6 - gcal | [] [] | 4 - gcc | [] | 4 - gettext | [] [] [] [] [] [] | 13 - gnupg | [] [] [] | 14 - gprof | [] [] | 5 - gpsdrive | [] [] | 3 - grep | [] [] [] [] [] | 20 - gretl | | 1 - gthumb | () () [] | 1 - hello | [] [] [] [] [] [] [] | 28 - id-utils | [] [] [] [] | 9 - indent | [] [] [] [] [] | 14 - jpilot | () () [] [] | 5 - jwhois | [] () () [] [] | 7 - kbd | [] [] | 5 - ld | [] [] | 4 - libc | [] [] [] [] [] [] | 18 - libiconv | [] [] [] [] [] | 12 - lifelines | [] | 1 - lilypond | [] | 4 - lingoteach | [] [] | 5 - lingoteach_lessons| () | 0 - lynx | [] [] [] [] | 13 - m4 | [] [] [] [] | 13 - make | [] [] [] [] [] | 15 - man-db | | 3 - mysecretdiary | [] [] [] | 7 - nano | [] [] [] [] | 13 - nano_1_0 | [] [] [] [] | 14 - opcodes | [] [] [] | 8 - parted | [] [] [] [] | 12 - ptx | [] [] [] [] [] [] [] | 19 - python | | 0 - recode | [] [] [] [] [] [] | 15 - sed | [] [] [] [] [] [] | 24 - sh-utils | [] [] | 9 - sharutils | [] [] [] [] | 14 - sketch | [] () [] | 4 - soundtracker | [] | 6 - sp | | 1 - tar | [] [] [] [] [] [] [] | 19 - texinfo | [] [] | 10 - textutils | [] [] [] [] [] | 14 - util-linux | [] [] [] | 10 - vorbis-tools | [] | 3 - wastesedge | | 0 - wdiff | [] [] [] [] [] | 14 - wget | [] [] [] [] [] [] [] [] | 24 - +----------------------------------------------+ - 37 teams no pl pt pt_BR ru sk sl sv tr uk zh_CN zh_TW - 68 domains 4 15 2 28 28 12 10 49 43 4 1 9 609 + lg lt lv ms nb nl nn no pl pt pt_BR ro + +----------------------------------------+ + a2ps | [] [] () () () [] [] | + aegis | () | + anubis | [] [] | + ap-utils | () | + bash | [] | + batchelor | | + bfd | | + binutils | | + bison | [] [] [] [] | + bluez-pin | [] | + clisp | | + clisp | [] | + coreutils | [] | + cpio | [] [] [] | + darkstat | [] [] [] [] | + diffutils | [] [] [] | + e2fsprogs | | + enscript | [] [] | + error | [] [] | + fetchmail | () () | + fileutils | [] | + findutils | [] [] [] [] | + flex | [] | + gas | | + gawk | [] | + gcal | | + gcc | | + gettext | [] | + gettext-runtime | [] | + gettext-tools | | + gimp-print | [] | + gliv | [] | + glunarclock | [] | + gnucash | | + gnucash-glossary | [] [] | + gnupg | | + gpe-calendar | [] [] | + gpe-conf | [] [] | + gpe-contacts | [] | + gpe-edit | [] [] | + gpe-login | [] [] | + gpe-ownerinfo | [] [] | + gpe-sketchbook | [] [] | + gpe-timesheet | [] [] | + gpe-today | [] [] | + gpe-todo | [] [] | + gphoto2 | | + gprof | [] | + gpsdrive | () () () | + grep | [] [] [] [] | + gretl | | + hello | [] [] [] [] [] [] [] [] [] | + id-utils | [] [] [] | + indent | [] [] [] | + jpilot | () () | + jwhois | [] [] [] | + kbd | | + ld | | + libc | [] [] [] [] | + libgpewidget | [] [] | + libiconv | [] [] | + lifelines | | + lilypond | [] | + lingoteach | | + lingoteach_lessons | | + lynx | [] [] | + m4 | [] [] [] [] | + mailutils | | + make | [] [] | + man-db | [] | + mysecretdiary | [] | + nano | [] [] [] [] | + nano_1_0 | [] [] [] [] | + opcodes | [] [] [] | + parted | [] [] [] | + ptx | [] [] [] [] [] [] [] | + python | | + radius | | + recode | [] [] [] | + screem | | + sed | [] [] | + sh-utils | [] | + sharutils | [] | + sketch | [] | + soundtracker | | + sp | | + tar | [] [] [] [] [] [] | + texinfo | [] | + textutils | [] | + tin | | + util-linux | [] [] | + vorbis-tools | [] [] | + wastesedge | | + wdiff | [] [] [] [] | + wget | [] [] [] | + xchat | [] [] | + xpad | [] | + +----------------------------------------+ + lg lt lv ms nb nl nn no pl pt pt_BR ro + 0 0 2 11 7 26 3 4 18 15 34 34 + + ru sk sl sr sv ta tr uk vi wa zh_CN zh_TW + +-------------------------------------------+ + a2ps | [] [] [] [] [] | 16 + aegis | () | 0 + anubis | [] [] | 5 + ap-utils | () | 1 + bash | [] | 7 + batchelor | | 1 + bfd | [] [] [] | 7 + binutils | [] [] [] | 7 + bison | [] [] | 13 + bluez-pin | | 7 + clisp | | 0 + clisp | | 5 + coreutils | [] [] [] [] [] | 14 + cpio | [] [] [] | 13 + darkstat | [] () () | 9 + diffutils | [] [] [] [] | 21 + e2fsprogs | [] | 3 + enscript | [] [] [] | 11 + error | [] [] [] | 14 + fetchmail | [] | 7 + fileutils | [] [] [] [] [] [] | 15 + findutils | [] [] [] [] [] [] | 27 + flex | [] [] [] | 10 + gas | [] | 3 + gawk | [] [] | 9 + gcal | [] [] | 4 + gcc | [] | 4 + gettext | [] [] [] [] [] [] | 15 + gettext-runtime | [] [] [] [] [] [] | 16 + gettext-tools | [] [] | 5 + gimp-print | [] [] | 10 + gliv | | 1 + glunarclock | [] [] [] | 11 + gnucash | [] [] | 4 + gnucash-glossary | [] [] [] | 8 + gnupg | [] [] [] [] | 16 + gpe-calendar | [] | 5 + gpe-conf | | 3 + gpe-contacts | [] | 4 + gpe-edit | [] | 5 + gpe-login | [] | 5 + gpe-ownerinfo | [] | 7 + gpe-sketchbook | [] | 5 + gpe-timesheet | [] | 6 + gpe-today | [] | 6 + gpe-todo | [] | 6 + gphoto2 | [] [] | 9 + gprof | [] [] | 7 + gpsdrive | [] [] | 3 + grep | [] [] [] [] | 24 + gretl | | 2 + hello | [] [] [] [] [] | 33 + id-utils | [] [] [] | 11 + indent | [] [] [] [] | 19 + jpilot | [] [] [] [] [] | 10 + jwhois | () () [] [] | 10 + kbd | [] [] | 8 + ld | [] [] | 5 + libc | [] [] [] [] | 20 + libgpewidget | | 6 + libiconv | [] [] [] [] [] [] | 21 + lifelines | [] | 2 + lilypond | [] | 4 + lingoteach | | 2 + lingoteach_lessons | () | 0 + lynx | [] [] [] [] | 14 + m4 | [] [] [] | 15 + mailutils | | 2 + make | [] [] [] [] | 15 + man-db | [] | 6 + mysecretdiary | [] [] | 8 + nano | [] [] [] | 15 + nano_1_0 | [] [] [] | 15 + opcodes | [] [] | 9 + parted | [] [] | 13 + ptx | [] [] [] | 22 + python | | 0 + radius | | 0 + recode | [] [] [] [] | 19 + screem | [] | 1 + sed | [] [] [] [] [] | 20 + sh-utils | [] [] [] | 13 + sharutils | [] [] [] [] | 16 + sketch | [] | 5 + soundtracker | [] | 7 + sp | [] | 3 + tar | [] [] [] [] [] | 24 + texinfo | [] [] [] [] | 13 + textutils | [] [] [] [] [] | 15 + tin | | 1 + util-linux | [] [] | 14 + vorbis-tools | [] | 7 + wastesedge | | 0 + wdiff | [] [] [] [] | 17 + wget | [] [] [] [] [] [] [] | 25 + xchat | [] [] [] | 11 + xpad | | 1 + +-------------------------------------------+ + 50 teams ru sk sl sr sv ta tr uk vi wa zh_CN zh_TW + 97 domains 32 19 16 0 56 0 48 10 1 1 12 23 913 Some counters in the preceding matrix are higher than the number of visible blocks let us expect. This is because a few extra PO files are @@ -409,7 +599,7 @@ lag between the mere existence a PO file and its wide availability in a distribution. - If August 2002 seems to be old, you may fetch a more recent copy of + If May 2003 seems to be old, you may fetch a more recent copy of this `ABOUT-NLS' file on most GNU archive sites. The most up-to-date matrix with full percentage details can be found at `http://www.iro.umontreal.ca/contrib/po/HTML/matrix.html'. diff -urN gawk-3.1.2/ChangeLog gawk-3.1.3/ChangeLog --- gawk-3.1.2/ChangeLog 2003-03-19 04:10:56.000000000 -0800 +++ gawk-3.1.3/ChangeLog 2003-07-07 11:21:14.000000000 -0700 @@ -1,3 +1,430 @@ +Mon Jul 7 11:01:43 2003 Arnold D. Robbins + + * Release 3.1.3: Release tar file made. + +Mon Jul 7 09:55:49 2003 Arnold D. Robbins + + * main.c (copyleft, usage): Make sure to fflush output fp. Per Jim + Meyering, if error, exit non-zero. + * ext.c (get_argument): Fix array paramater handling. + +2003-07-06 Paul Eggert + + * builtin.c (do_substr): Issue better diagnostics when + d_substr and d_length are NaN, or when 0 < d_length < 1. + Be careful when comparing double to SIZE_MAX, as + the comparison might return the "wrong" answer when + (double) SIZE_MAX is a number that is not equal to + SIZE_MAX. + (do_gensub): Watch out for HOW values that are out of range + or are NaN. + (do_dcngettext): dcngettext wants an argument of type + unsigned long, not long, so use a value of that type. + +Fri Jul 4 10:58:02 2003 Arnold D. Robbins + + * main.c (main): Make option letter 'D' fall through into default + unknown case if not debugging. Let's us have just one version of + `optlist'. + +Thu Jun 26 15:25:57 2003 Arnold D. Robbins + + * array.c (get_actual): Undo Stepan Kasal change of 2003-06-17. + See test/match2.awk. + +Wed Jun 25 15:26:08 2003 Arnold D. Robbins + + * builtin.c (do_rand): Change calculation so that result + obeys constraint: 0 <= N < 1. This is per history and POSIX. + Thanks to Nelson Beebe (beebe@math.utah.edu) for reporting + this issue. + +Mon Jun 23 15:13:39 2003 Arnold D. Robbins + + * io.c (rs1scan): Per advice from Bruno Haible, it's safe + to skip the multibyte checking code if RS is '\n'. See + the comment in the code. Big performance improvement for + multibyte locales. + +2003-06-20 Stepan Kasal + + * eval.c (comp_func): if memcmp returns 0, we have to compare + the lengths. + +2003-06-19 Stepan Kasal + + * eval.c (interpret) : use NULL, not 0, to + initialize the variable list. + (comp_func): array indices no longer are string values, + you have to use ahname_str, ahname_len. + +Tue Jun 17 11:53:46 2003 Arnold D. Robbins + + * array.c (get_actual): Make check for isparam + smarter: also check for FUNC flag. + +2003-06-17 Stepan Kasal + + * array.c (get_actual): even if canfatal is FALSE, don't + tolerate existence of things which can't happen. + +Mon Jun 16 16:21:44 2003 Arnold D. Robbins + + * configure.ac: Removed m4/Makefile. + * m4/Makefile.am: Removed. + +2003-06-16 gettextize + + * configure.ac (AC_OUTPUT): Add m4/Makefile. + (AM_GNU_GETTEXT_VERSION): Bump to 0.12.1. + +Sun Jun 15 20:45:43 2003 Arnold D. Robbins + + * io.c (get_a_record): Enhance logic to fill buffers to include + `|| no_data_left(iop)'. + (rs1scan): Fix logic for setting recm fields for multibyte + character case. + +2003-06-10 Stepan Kasal + + * awkgram.y (release_all_vars): do not try to release a value of + Node_var_new; after get_lhs, use the lhs directly, do not try + to do (*lhs)->var_value; the Node_var case doesn't need + special treatment. + * builtin.c (do_match): `get_param' is successful iff it returns + Node_var_array---if the variable was new, get_param has already + changed the type. + * field.c (do_split): likewise. + +Sun Jun 15 19:36:35 2003 Arnold D. Robbins + + * node.c (r_dupnode): Typo fix in hash tables: stptr -> ahname_str. + Thanks to mary1john8@earthlink.net. + * array.c (get_actual): Add `if (canfatal)' before call to + `cant_happen'. + +Sun Jun 15 19:25:49 2003 Patrick T.J. McPhee + + * awk.h (memcpy_ulong): Add ! WIN32 to ifdefs. + +Mon Jun 9 18:38:20 2003 Arnold D. Robbins + + * custom.h (hpux): Added stuff to (hopefully) get `tzset' + declared on HP/UX 10 and up. + +Mon Jun 9 17:12:24 2003 Patrick T.J. McPhee + + * awk.h (ATTRIBUTE_EXPORTED): New macro for dynamic libs on Windows32. + * CONVMFTidx, stack_ptr, do_lint, lintfunc: Now have this attribute. + +Mon Jun 9 13:11:33 2003 Arnold D. Robbins + + Clean up of Stepan's patches. + + * array.c (get_actual): Renamed from r_get_array. Added second + param canfatal if routine should print fatal message when not an array. + (get_actual): Renamed 'prm' to `isparam'. + (array_vname): Add static msglen var; only realloc string if it grows. + Don't use `s += sprintf(...)'. No good on old systems where sprintf + returns char *. Minor formatting cleanups. + (do_adump): Restored separate `a' and `r' variables; helps for debugging. + + * awk.h (SCALAR, UNINITIALIZED): Removed entirely, renumbered other flags. + (get_array, get_param): New macros, calls get_actual. + (get_actual): Declaration changed from that of r_get_array. + + * awkgram.y (release_all_vars): Restored previous version of code; new + version isn't right for Node_xx variables. + (variable): Minor code cleanup for readability. + + * builtin.c (do_match): Use get_param and print our own message when + third parameter is not an array. + + * eval.c: Added a few comments here and there, removed some no longer + needed comments. + + * field.c (do_split): Use get_param and print our own message when + second parameter is not an array. + +Mon Jun 9 11:46:21 2003 Arnold D. Robbins + + * array.c (do_delete): Initialize hash1 and last to keep gcc -Wall happy. + * io.c (rsnullscan): Comment out label skip_leading for same reason. + +Wed May 28 08:31:23 CEST 2003 Stepan Kasal + + * eval.c (forloops_active, in_function): Nuked. + (pop_all_forloops, pop_fcall_stack): are now inline. + +Wed May 28 07:58:35 2003 Stepan Kasal + + * field.c, awk.h (Null_field): no longer static. + * field.c (init_fields): initial value of $0 can be Nnull_string, + no need to copy it. + * eval.c (r_get_lhs) : test for uninitialized field, + which is Nnull_string for $0 and Null_field for $(>0). + * builtin.c (do_print_rec): test for uninitialized $0. + +Tue May 27 17:03:02 2003 Stepan Kasal + + * awk.h (Node_var_new): New node type for variables which can be + either scalar or array. From now on, Node_var is always scalar. + (Node_gvar_ref): Nuked, its role can be taken by Node_array_ref. + (orig_var): removed, orig_array is enough. + (SCALAR, UNINITIALIZED): Flags nuked. + (var_uninitialized): new macro to distinguish uninitialized vars; + used in several other macros. + * array.c (r_get_array, array_vname, do_adump): adapt to the + above changes. + * awkgram.y, eval.c, field.c, main.c, node.c, profile.c: ditto. + +Tue May 27 14:27:50 2003 Stepan Kasal + + * array.c (r_get_array): New function, which goes all the way + through Node_param_list to actual Node_var_array; if it encounters + non scalar Node_var, it changes it to Node_var_array. + (in_array, do_delete, do_delete_loop, do_adump, assoc_sort_inplace): + Use get_array. + (assoc_lookup): The parameter must be a Node_var_array. + * awk.h (get_array, r_get_array): Declare the new function and define + a macro to speed it up. + * builtin.c (do_match): Use get_array. + * eval.c (interpret) : ditto. + (r_get_lhs) : ditto. + * field.c (do_split): ditto. + +Tue May 27 08:23:51 2003 Stepan Kasal + + Changed node->vname meaning for type Node_array_ref and Node_gvar_ref. + It contains only the reference name; one has to (recursively) follow + node->prev_array to find out the call history for the array. + + * array.c (array_vname): New function to print the array name. + (assoc_lookup, do_delete): Use array_vname. + * eval.c (interpret, r_tree_eval, r_get_lhs): Use array_vname. + (push_args, pop_fcall): Things have simplified. + * awk.h (array_vname): Declare. + (prev_array): Define. + +Sun Jun 8 11:25:36 2003 Stepan Kasal + + * awkgram.y (append_right): when using savetail, remember that it + is not necessarily the tail of the list---it's just a pointer to + the last chunk appended. + +Thu Jun 5 12:01:41 2003 Arnold D. Robbins + + * builtin.c (do_strtonum): Make `strtonum(13)' work. + +Wed Jun 4 17:07:06 2003 Corinna Vinschen + + * io.c (binmode): Include function for __CYGWIN__ too. + +Tue Jun 3 12:40:50 2003 Arnold D. Robbins + + * eval.c (interpret): Node_K_switch. For regex case, don't + call `free_temp' on the result of `force_string' if it's equal to + switch_value. Thanks to John DuBois + for finding the problem. + +Sun Jun 1 13:08:22 2003 Arnold D. Robbins + + * builtin.c (format_tree): For %c, force precision to 1. + +Wed May 28 11:55:48 2003 Arnold D. Robbins + + * awkgram.y (isnoeffect, isassignable): Add Node_TEXTDOMAIN to + switches in both functions. + +Wed May 28 11:38:59 2003 Stepan Kasal + + * awkgram.y (switch_body): remove rule ``switch_body:/*empty/'' + as ``switch_body:case_statements'' covers it---this disambiguation + fixes a reduce/reduce conflict. + +Sun May 25 16:23:43 2003 Corinna Vinschen + + * configure.ac: Remove linking against /usr/lib/automode.o. + * configure: Regenerate. + +Sun May 25 15:19:19 2003 Stepan Kasal + + * awk.h (get_lhs): For an initialized Node_var, you may return + the address of var_value pointer, no matter whether reference + bit was set or not. We were silly slowing down most of the + assignements. + + * (get_a_record): after grow_iop_buffer, move recm.rt_start even + if recm.len == 0. + +Mon May 19 16:55:59 2003 Arnold D. Robbins + + Code for C-style switch statements. Initial version contributed by + Michael Benzinger . + + Disabled by default, use `configure --enable-switch' to turn it on. + + * configure.ac: New AC_ARG_ENABLE for switch statements. + * awk.h (NODETYPE): New types for switch, case, default keywords + and respective lists. + * awkgram.y: New productions for switch statement. Does checking to + avoid duplicate cases. + * eval.c (nodetypes): New entries for new NODETYPEs. + (interpret): New code to do switch execution. + * profile.c (pprint): New code to print switch statements. + +Mon May 19 15:05:43 2003 Arnold D. Robbins + + * configure.ac: Renamed from configure.in. + * fixvers: Now looks in configure.ac. + * Makefile.am: Now cites configure.ac. + + * Misc other: Updated to Automake 1.7.5. + +Sun May 18 12:03:56 2003 Arnold D. Robbins + + * array.c (do_delete_loop): Fix bracing of logic for + tests. + +Wed May 14 09:01:16 2003 Stepan Kasal + + Misc patches: + + * builtin.c (do_match): if third parameter to `match' is supplied, + store all subexpressions which are applicable, even though there + are some unused between them. + + * awkgram.y (yylex): when returning from unterminated REGEXP + (which is /* kludge */), take care to fake a yylval, to + prevent ``internal error'' later. + +Sun May 11 15:51:00 2003 Stepan Kasal + + * io.c (rsnullscan, get_a_record): Boundary condition bug fixes. + +Sun May 11 15:15:20 IDT 2003 Scott Deifik + + * awk.h: Add decls for `memcpy_ulong', `memset_ulong', and + MSC defines. + * regex.c: Include if MSC for size_t. + +Mon May 5 15:11:06 2003 Arnold D. Robbins + + * io.c (get_a_record): Only tweak RT's value in place if the current + RS scanner is the same as the last one. Bug report submitted by + John DuBois (). + +Fri May 2 14:39:48 2003 Arnold D. Robbins + + * io.c (get_a_record): Add logic at end to be smart about setting + RT. Saves considerable time, esp for default case where RS = "\n". + +Wed Apr 30 11:44:38 2003 Arnold D. Robbins + + * field.c (do_split): Add check and code for Node_gvar_ref. + * array.c (in_array, do_delete, asort_actual): Same. + * builtin.c (do_split): Same for 3rd arg array parameter. + * eval.c (interpret): Same for Node_K_array_for. + (push_args): Same for evaluating extra args. + +Tue Apr 29 15:54:28 2003 Arnold D. Robbins + + Record reading code redone/simplified considerably. + + * awk.h (IOBUF): Removed total field, no longer used. + * io.c (at_eof, has_data, no_data_left): New macros. + (RECVALUE, SCANSTATE): New enumerated types. + (rs1get_a_record, rsnull_get_a_record, rsre_get_a_record): Removed. + (get_a_record): Rewritten, again. Now contains just buffer and + record code; searching code moved into these functions: + (rs1scan, rsnullscan, rsrescan): New functions to scan a buffer + for record contents and terminator. Fill in values in: + (struct recmatch): Holds found record and terminator. + (spec_setup): Set iop->dataend to indicate data is already in buffer. + (nextfile, inrec): Use new macros instead of flag and pointer tests. + (set_RS): Set scanning function instead of record function. + + FWIW, it all passes `make test'. + +Sun Apr 27 21:02:39 2003 Arnold D. Robbins + + * io.c (do_close): At end, if do_posix return 0. See comment in code. + +Tue Apr 15 09:56:03 2003 Isamu Hasegawa + + * configure.in: Check existence of wcrtomb, and wcscoll. + * configh.in: Likewise. + * configure: Re-generate. + Thanks to Kimura Koichi for reporting. + +Sun Apr 13 16:02:10 2003 Arnold D. Robbins + + * main.c (main): Add call to `setlocale' for LC_NUMERIC after program is + parsed. + (arg_assign): Switch back to "C" locale for LC_NUMERIC for command + line assignments; this is per POSIX that period is decimal point for + program and command line assignments and the locale's separator + applies for input, output, and string to number conversion. + +2003-03-26 Paul Eggert + + * builtin.c [HAVE_INTTYPES_H]: Include . + [!HAVE_INTTYPES_H && HAVE_STDINT_H]: Include . + (CHAR_BIT, INTMAX_MIN, UINTMAX_MAX): Define if the system does not. + (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): New macros, taken from + coreutils and many other GNU utilities. + (format_tree): When formatting, use widest possible integers + rather than settling with 'long'. + (do_lshift, do_rshift, do_and, do_or, do_xor, do_compl): Likewise, + when doing bitwise operations. + * configure.in (jm_AC_TYPE_LONG_LONG, jm_AC_TYPE_UNSIGNED_LONG_LONG, + jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T): Add, since the mainline + code now needs this. + * doc/gawk.texi (Control Letters, Bitwise Functions): Document this. + * m4/intmax_t.m4: New file, taken from coreutils (but renamed to + avoid collision with our m4/inttypes.m4). + * m4/longlong.m4: New file, taken from coreutils. + * m4/uintmax_t.m4, m4/ulonglong.m4: Remove; superseded by the above + new m4 files. + + * builtin.c (BITS_PER_BYTE): Remove; use CHAR_BIT instead, since + it's the standard name. + (do_lshift, do_rshift): Complain if the shift width is exactly equal + to the word size, too. + +Thu Mar 27 10:44:11 2003 Arnold D. Robbins + + * io.c (rs1_get_a_record, rsnull_get_a_record, rsre_get_a_record): + Enhance check for no data left in file to be only if file has + non-zero size. Linux files such as /proc/filesystems stat as a + regular file of size 0, but actually have contents. Ugh. + Thanks to Martin Schlemmer for the bug report. + +Wed Mar 26 12:19:32 2003 Arnold D. Robbins + + * builtin.c (format_tree): Add a lint warning at label `out_of_range'. + +Tue Mar 25 12:24:38 2003 Arnold D. Robbins + + * awkgram.y (variable): For array subscript, if NAME is in the + symbol table, but not a variable, array, or parameter, generate + a syntax error. + (isarray): New function, tests if a symbol can be an array. + + * custom.h: Add check for HP/UX, needed for GCC. + +Mon Mar 17 09:21:09 2003 Arnold D. Robbins + + Allow simultaneous manipulation of a global array directly + and when passed as a parameter. + + * awk.h (Node_gvar_ref): New nodetype. + [orig_var]: New macro. + * array.c (do_delete_loop, do_delete): Add logic to handle + seeing Node_gvar_ref. + * eval.c (nodetypes): Add Node_gvar_ref. + (r_tree_eval, r_get_lhs): Add Node_gvar_ref case. + Wed Mar 19 14:10:31 2003 Arnold D. Robbins This time for sure. @@ -3586,7 +4013,7 @@ * io.c (get_a_record): replace all occurrences of the test `grRS == FALSE' with `RS_is_null' which makes ` RS = "\0" ' - actually work, is clearer code, and actually makes use of + actually work, is clearer code, and actually makes use of the `RS_is_null' variable! Sun Aug 17 07:15:12 1997 Arnold D. Robbins diff -urN gawk-3.1.2/FUTURES gawk-3.1.3/FUTURES --- gawk-3.1.2/FUTURES 2002-10-06 12:46:30.000000000 -0700 +++ gawk-3.1.3/FUTURES 2003-06-24 09:15:00.000000000 -0700 @@ -34,6 +34,19 @@ For 3.2 ======= + Simplify awk.h. + + Consider moving var_value info into Node_var itself + to reduce memory usage. + + Add IPv6 support. + + Look at ISO C 99 printf features. + + Add %'d for putting in commas in formatting? + + Consider integrating Fred Fish's DBUG library into gawk. + Move the loadable modules interface to libtool. Redo the loadable modules interface from the awk level. @@ -45,12 +58,6 @@ DBM storage of awk arrays. Try to allow multiple dbm packages. - Look at ISO C 99 printf features. - - Add %'d for putting in commas in formatting? - - Consider integrating Fred Fish's DBUG library into gawk. - Consider removing use of and/or need for the protos.h file. Additional manual features: diff -urN gawk-3.1.2/Makefile.am gawk-3.1.3/Makefile.am --- gawk-3.1.2/Makefile.am 2003-03-06 01:31:38.000000000 -0800 +++ gawk-3.1.3/Makefile.am 2003-05-19 04:58:24.000000000 -0700 @@ -27,7 +27,7 @@ AUTOMAKE_OPTIONS = ansi2knr dist-bzip2 # This undocumented variable insures that aclocal runs -# correctly after changing configure.in +# correctly after changing configure.ac ACLOCAL_AMFLAGS = -I m4 # This insures that make flags get passed down to child makes. @@ -166,12 +166,12 @@ else :; fi # These force version and patchlevel to be up to date based -# on what's in configure.in. No-one else but me should have +# on what's in configure.ac. No-one else but me should have # to use them. So there. -patchlev.h: configure.in +patchlev.h: configure.ac $(srcdir)/fixvers -p -version.c: configure.in version.in +version.c: configure.ac version.in $(srcdir)/fixvers -v # This is for my development & testing. diff -urN gawk-3.1.2/Makefile.in gawk-3.1.3/Makefile.in --- gawk-3.1.2/Makefile.in 2003-03-16 02:25:36.000000000 -0800 +++ gawk-3.1.3/Makefile.in 2003-07-04 10:49:07.000000000 -0700 @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.7.3 from Makefile.am. +# Makefile.in generated by automake 1.7.5 from Makefile.am. # @configure_input@ # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 @@ -172,7 +172,7 @@ AUTOMAKE_OPTIONS = ansi2knr dist-bzip2 # This undocumented variable insures that aclocal runs -# correctly after changing configure.in +# correctly after changing configure.ac ACLOCAL_AMFLAGS = -I m4 # This insures that make flags get passed down to child makes. @@ -326,7 +326,7 @@ DIST_COMMON = README ABOUT-NLS AUTHORS COPYING ChangeLog INSTALL \ Makefile.am Makefile.in NEWS acinclude.m4 aclocal.m4 ansi2knr.1 \ ansi2knr.c awkgram.c config.guess config.rpath config.sub \ - configh.in configure configure.in depcomp install-sh missing \ + configh.in configure configure.ac depcomp install-sh missing \ mkinstalldirs ylwrap DIST_SUBDIRS = $(SUBDIRS) SOURCES = $(gawk_SOURCES) $(pgawk_SOURCES) @@ -339,7 +339,7 @@ am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno -$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) +$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && \ $(AUTOMAKE) --gnu Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @@ -347,10 +347,10 @@ $(top_builddir)/config.status: $(srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck -$(srcdir)/configure: $(srcdir)/configure.in $(ACLOCAL_M4) $(CONFIGURE_DEPENDENCIES) +$(srcdir)/configure: $(srcdir)/configure.ac $(ACLOCAL_M4) $(CONFIGURE_DEPENDENCIES) cd $(srcdir) && $(AUTOCONF) -$(ACLOCAL_M4): configure.in acinclude.m4 m4/arch.m4 m4/codeset.m4 m4/gettext.m4 m4/glibc21.m4 m4/iconv.m4 m4/intdiv0.m4 m4/inttypes-pri.m4 m4/inttypes.m4 m4/inttypes_h.m4 m4/isc-posix.m4 m4/lcmessage.m4 m4/lib-ld.m4 m4/lib-link.m4 m4/lib-prefix.m4 m4/progtest.m4 m4/socket.m4 m4/stdint_h.m4 m4/strtod.m4 m4/uintmax_t.m4 m4/ulonglong.m4 +$(ACLOCAL_M4): configure.ac acinclude.m4 m4/arch.m4 m4/codeset.m4 m4/gettext.m4 m4/glibc21.m4 m4/iconv.m4 m4/intdiv0.m4 m4/intmax_t.m4 m4/inttypes-pri.m4 m4/inttypes.m4 m4/inttypes_h.m4 m4/isc-posix.m4 m4/lcmessage.m4 m4/lib-ld.m4 m4/lib-link.m4 m4/lib-prefix.m4 m4/longlong.m4 m4/nls.m4 m4/po.m4 m4/progtest.m4 m4/socket.m4 m4/stdint_h.m4 m4/strtod.m4 m4/uintmax_t.m4 m4/ulonglong.m4 cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) config.h: stamp-h1 @@ -363,7 +363,7 @@ @rm -f stamp-h1 cd $(top_builddir) && $(SHELL) ./config.status config.h -$(srcdir)/configh.in: $(top_srcdir)/configure.in $(ACLOCAL_M4) +$(srcdir)/configh.in: $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && $(AUTOHEADER) touch $(srcdir)/configh.in @@ -447,7 +447,7 @@ .c.o: @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" \ @am__fastdepCC_TRUE@ -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$<; \ -@am__fastdepCC_TRUE@ then mv "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \ +@am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \ @am__fastdepCC_TRUE@ else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; \ @am__fastdepCC_TRUE@ fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @@ -458,7 +458,7 @@ .c.obj: @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" \ @am__fastdepCC_TRUE@ -c -o $@ `if test -f '$<'; then $(CYGPATH_W) '$<'; else $(CYGPATH_W) '$(srcdir)/$<'; fi`; \ -@am__fastdepCC_TRUE@ then mv "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \ +@am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \ @am__fastdepCC_TRUE@ else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; \ @am__fastdepCC_TRUE@ fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @@ -598,9 +598,15 @@ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ + if (etags --etags-include --version) >/dev/null 2>&1; then \ + include_option=--etags-include; \ + else \ + include_option=--include; \ + fi; \ list='$(SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ - test -f $$subdir/TAGS && tags="$$tags -i $$here/$$subdir/TAGS"; \ + test -f $$subdir/TAGS && \ + tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \ fi; \ done; \ list='$(SOURCES) $(HEADERS) configh.in $(LISP) $(TAGS_FILES)'; \ @@ -753,7 +759,7 @@ @echo "$(distdir).tar.gz is ready for distribution" | \ sed 'h;s/./=/g;p;x;p;x' distuninstallcheck: - cd $(distuninstallcheck_dir) \ + @cd $(distuninstallcheck_dir) \ && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ || { echo "ERROR: files left after uninstall:" ; \ if test -n "$(DESTDIR)"; then \ @@ -762,11 +768,11 @@ $(distuninstallcheck_listfiles) ; \ exit 1; } >&2 distcleancheck: distclean - if test '$(srcdir)' = . ; then \ + @if test '$(srcdir)' = . ; then \ echo "ERROR: distcleancheck can only run from a VPATH build" ; \ exit 1 ; \ fi - test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ + @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left in build directory after distclean:" ; \ $(distcleancheck_listfiles) ; \ exit 1; } >&2 @@ -911,12 +917,12 @@ else :; fi # These force version and patchlevel to be up to date based -# on what's in configure.in. No-one else but me should have +# on what's in configure.ac. No-one else but me should have # to use them. So there. -patchlev.h: configure.in +patchlev.h: configure.ac $(srcdir)/fixvers -p -version.c: configure.in version.in +version.c: configure.ac version.in $(srcdir)/fixvers -v # This is for my development & testing. diff -urN gawk-3.1.2/NEWS gawk-3.1.3/NEWS --- gawk-3.1.2/NEWS 2003-03-13 00:16:34.000000000 -0800 +++ gawk-3.1.3/NEWS 2003-06-29 05:58:05.000000000 -0700 @@ -1,3 +1,50 @@ +Changes from 3.1.2 to 3.1.3 +--------------------------- + +1. Gawk now follows POSIX in handling of local numeric formats for + input, output and number/string conversions. + +2. Multibyte detection improved. See README_d/README.multibyte for more + info about multibyte locales. + +3. Handling of `close' made more POSIX-compliant for POSIXLY_CORRECT, + see the documentation. + +4. The record reading code was redone, again. This time it's much + better. Really! + +5. For RS = "\n" and RS = "", gawk now only sets RT when it has changed. + This provides considerable performance improvement. + +6. `match' now sets all the subscripts in the third argument array + correctly, even if not all subexpressions matched. + +7. Updated to Automake 1.7.5. configure.in renamed configure.ac. + +8. C-style switch statements are available, but must be enabled at + compile time via `configure --enable-switch'. For 3.2 they'll be + enabled by default. Thanks to Michael Benzinger for the initial + code. + +9. %c now always prints no more than one character, whatever + precision is provided. + +10. strtonum() now works again. + +11. Gawk is now much better about scalar/array typing of global + uninitiailzed variables passed as parameters. Once the parameter + is then used one way or the other, the global var's type is + adjusted accordingly. Thanks to Stepan Kasal for the original + (considerable) changes. + +12. Dynamic function loading under Windows32 should now be possible. See + README_d/README.pcdynamic. Thanks to Patrick T.J. McPhee for the changes. + +13. Updated to gettext 0.12.1. + +14. Gawk now follows historical practice and POSIX for the return + value of `rand': It's now 0 <= N < 1. + Changes from 3.1.1 to 3.1.2 --------------------------- @@ -49,7 +96,7 @@ will fall back to using plain pipes. 13. Fixed a regex matching across buffer boundaries bug, with a - heuristic. See io.c:rsre_get_a_record(). + heuristic. See io.c:rsre_get_a_record. 14. Profiling no longer dumps core if there are extension functions in place. @@ -92,15 +139,15 @@ 25. More translations. -26. The get_a_record() routine has been revamped (currently by splitting it +26. The `get_a_record' routine has been revamped (currently by splitting it into three variants). This should improve long-term maintainability. -27. match() now adds more entries to 3rd array arg: +27. `match' now adds more entries to 3rd array arg: match("the big dog", /([a-z]+) ([a-z]+) ([a-z]+)/, data) fills in variables: data[1, "start"], data[1, "length"], and so on. -28. New asorti() function with same interface as asort(), but sorts indices +28. New `asorti' function with same interface as `asort', but sorts indices instead of values. 29. Documentation updated to FDL 1.2. @@ -134,7 +181,7 @@ 7. Gawk can now be built with byacc; an accidental bison dependency was removed. -8. yyerror() will no longer dump core on long source lines. +8. `yyerror' will no longer dump core on long source lines. 9. Gawk now correctly queries getgroups(2) to figure out how many groups the process has. @@ -190,7 +237,7 @@ 9. On systems that support it, gawk now sets the `close on exec' flag on all files and pipes it opens. This makes sure that child processes run via - system() or pipes have plenty of file descriptors available. + `system' or pipes have plenty of file descriptors available. 10. New ports: Tandem and BeOS. The Tandem port is unsupported. @@ -209,7 +256,7 @@ though. (NOTE! This is borrowed from ksh: it is not the same as the same operator in csh!) -16. The close() function now takes an optional second string argument +16. The `close' function now takes an optional second string argument that allows closing one or the other end of the two-way pipe to a co-process. This is needed to use `sort' in a co-process, see the doc. @@ -257,7 +304,7 @@ over to using automake. You need Automake 1.4a (from the CVS archive) if you want to muck with the Makefile.am files. -28. New asort() function for sorting arrays. See the doc for details. +28. New `asort' function for sorting arrays. See the doc for details. 29. The match function takes an optional array third argument to hold the text matched by parenthesized sub-expressions. @@ -267,11 +314,11 @@ data is now enabled at runtime with --non-decimal-data command line option. 31. Internationalization features available at the awk level: new TEXTDOMAIN - variable and bindtextdomain() and dcgettext() functions. printf formats + variable and `bindtextdomain' and `dcgettext' functions. printf formats may contain the "%2$3.5d" kind of notation for use in translations. See the texinfo manual for details. -32. The return value from close() has been rationalized. Most notably, +32. The return value from `close' has been rationalized. Most notably, closing something that wasn't open returns -1 but remains non-fatal. 33. The array effeciency change from 3.0.5 was reverted; the semantics were @@ -350,7 +397,7 @@ 12. `b += b += 1' now works correctly. -13. IGNORECASE changing with calls match() now works better. (Fix for +13. IGNORECASE changing with calls `match' now works better. (Fix for semi-obscure bug.) 14. Multicharacter values for RS now generate a lint warning. @@ -401,7 +448,7 @@ 13. Weird problems with number conversions on MIPS and other systems have been fixed. -14. When parsing using FIELDWIDTHS is in effect, split() with no third +14. When parsing using FIELDWIDTHS is in effect, `split' with no third argument will still use the value of FS. 15. Large File Support for Solaris, HP-UX, AIX, and IRIX is now enabled at @@ -446,7 +493,7 @@ The `amiga' directory is now gone; Amiga support is now entirely handled by the POSIX support. -Win32 support has been added in the `pc' directory. See `README_d/README.pc' +Windows32 support has been added in the `pc' directory. See `README_d/README.pc' for more info. The mmap changes are disabled in io.c, and will be removed entirely @@ -500,7 +547,7 @@ Thanks to SSC for their macros. Gawk now behaves like Unix awk and mawk, in that newline acts as white -space for separating fields and for split(), by default. In posix mode, +space for separating fields and for `split', by default. In posix mode, only space and tab separate fields. The documentation has been updated to reflect this. diff -urN gawk-3.1.2/README gawk-3.1.3/README --- gawk-3.1.2/README 2002-07-24 21:28:10.000000000 -0700 +++ gawk-3.1.3/README 2003-06-29 05:50:37.000000000 -0700 @@ -1,6 +1,6 @@ README: -This is GNU Awk 3.1.1. It is upwardly compatible with the Bell Labs +This is GNU Awk 3.1.3. It is upwardly compatible with the Bell Labs research version of awk. It is almost completely compliant with the 1993 POSIX 1003.2 standard for awk. (See the note below about POSIX.) @@ -29,7 +29,7 @@ modifying awkgram.y without bison or yacc will be difficult, at best. You might want to get a copy of bison from the FSF too.) -If you have a Win32, MS-DOS or OS/2 system, use the stuff in the `pc' +If you have a Windows32, MS-DOS or OS/2 system, use the stuff in the `pc' directory. Similarly, there is a separate directory for VMS. Ports for the Atari and Tandem are supplied, but they are unsupported. diff -urN gawk-3.1.2/README_d/README.multibyte gawk-3.1.3/README_d/README.multibyte --- gawk-3.1.2/README_d/README.multibyte 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/README_d/README.multibyte 2003-07-04 10:08:49.000000000 -0700 @@ -0,0 +1,22 @@ +Wed Jun 18 16:47:31 IDT 2003 +============================ + +Multibyte locales can cause occasional weirdness, in particular with +ranges inside brackets: /[....]/. Something that works great for ASCII +will choke for, e.g., en_US.UTF-8. One such program is test/gsubtst5.awk. + +By default, the test suite runs with LC_ALL=C and LANG=C. You +can change this by doing (from a Bourne-style shell): + + $ GAWKLOCALE=some_locale make check + +Then the test suite will set LC_ALL and LANG to the given locale. + +As of this writing, this works for en_US.UTF-8, and all tests +pass except gsubtst5. + +For the normal case of RS = "\n", the locale is largely irrelevant. +For other single byte record separators, using LC_ALL=C will give you +much better performance when reading records. Otherwise, gawk has to +make several function calls, *per input character* to find the record +terminator. You have been warned. diff -urN gawk-3.1.2/README_d/README.pc gawk-3.1.3/README_d/README.pc --- gawk-3.1.2/README_d/README.pc 2003-02-23 06:15:44.000000000 -0800 +++ gawk-3.1.3/README_d/README.pc 2003-06-29 05:52:19.000000000 -0700 @@ -1,10 +1,10 @@ -This is the README for GNU awk 3.1 under Win32, OS/2, and DOS. +This is the README for GNU awk 3.1 under Windows32, OS/2, and DOS. - Gawk has been compiled and tested under OS/2, DOS, and Win32 using + Gawk has been compiled and tested under OS/2, DOS, and Windows32 using the GNU development tools from DJ Delorie (DJGPP; DOS with special support for long filenames under Win95), Eberhard Mattes (EMX; OS/2, -DOS, and Win32 with rsxnt), and Jan-Jaap van der Heijden and Mumit Khan -(Mingw32; Win32). Microsoft Visual C/C++ can be used to build a Win32 +DOS, and Windows32 with rsxnt), and Jan-Jaap van der Heijden and Mumit Khan +(Mingw32; Windows32). Microsoft Visual C/C++ can be used to build a Windows32 version for Windows 9x/NT, and MSC can be used to build 16-bit versions for DOS and OS/2. (As of 3.1.2, the MSC version doesn't work, but the maintainer for it is working on fixing it.) @@ -28,7 +28,7 @@ ------------- Building on DOS or Windows environments can be troublesome, in part due -to shell limitations, the long filename issue, and various Win32 pipe +to shell limitations, the long filename issue, and various Windows32 pipe considerations. The situation is somewhat better on OS/2. The general recommendation is to use tools (especially make) which are compatible or built with the compiler to be used on gawk. @@ -95,7 +95,7 @@ The GNUish Project was designed to bring GNU-like programs to small systems running OS/2 and DOS. Binary distributions of gawk are maintained in GNUish, and include 16bit OS/2 and DOS, 32bit djgpp, -and Win32 versions. Information on GNUish is available via +and Windows32 versions. Information on GNUish is available via http://www.simtel.net/simtel.net/ or @@ -107,7 +107,7 @@ http://www.leo.org/archiv/os2 or ftp://ftp.leo.org -It contains emx-compiled (32bit) versions of gawk for OS/2, DOS, and Win32, +It contains emx-compiled (32bit) versions of gawk for OS/2, DOS, and Windows32, along with many OS/2 utilities. The djgpp collection at @@ -139,12 +139,12 @@ djgpp | DPMI DPMI DPMI DPMI,NoLFN DPMI emx(1) | N N N N OS2 emxbnd(2) | VCPI,DPMI DPMI DPMI,NoLFN DPMI,NoLFN DPMI,OS2 - emxnt(3) | N N Win32 Win32 N + emxnt(3) | N N Windows32 Windows32 N msc(4) | 16 16 16,NoLFN 16,NoLFN 16,DOS msc6bnd | 16 16 16,NoLFN 16,NoLFN 16,DOS,OS2 msc6os2 | N N N N 16,OS2 - vcWin32 | N N Win32 Win32 N - mingw32 | N N Win32 Win32 N + vcWin32 | N N Windows32 Windows32 N + mingw32 | N N Windows32 Windows32 N (1) Requires emxrt. @@ -174,23 +174,23 @@ OS2 Runs as an OS/2 application. - rsxnt Runtimes for use with DPMI or Win32. + rsxnt Runtimes for use with DPMI or Windows32. VCPI Virtual Control Program Interface; program runs as a DOS app. Memory managers (such as emm386) may need adjustment. VCPI cannot be used under OS/2, Win/WfW, Win-95, or NT. See also DPMI. - Win32 Uses/supports Win32 features (such as long filenames). +Windows32 Uses/supports Windows32 features (such as long filenames). -Reportedly, NTEmacs (another Win32 program) can run programs such as -Win32-gawk asynchronously. Similarly, as native OS/2 versions are a -plus under OS/2 even for command-line programs, native Win32 versions +Reportedly, NTEmacs (another Windows32 program) can run programs such as +Windows32-gawk asynchronously. Similarly, as native OS/2 versions are a +plus under OS/2 even for command-line programs, native Windows32 versions may be desired under NT and Win95. -Users interested in Win32 applications may also wish to examine the +Users interested in Windows32 applications may also wish to examine the Cygnus cygwin project at http://sources.redhat.com/cygwin/ or the -Mingw32 work at http://www.mingw.org. Win32 gawk will often require -that utilities run from within gawk be Win32 (e.g., the tests place this +Mingw32 work at http://www.mingw.org. Windows32 gawk will often require +that utilities run from within gawk be Windows32 (e.g., the tests place this requirement on the cat utility). @@ -237,7 +237,7 @@ for emx-compiled programs (although djgpp-bash almost works with emx on DOS). GNU make is recommended if using djgpp-bash. -Beginning with 3.0.4, the MSC (DOS/Win32) and Mingw32 versions write +Beginning with 3.0.4, the MSC (DOS/Windows32) and Mingw32 versions write pipe and system() commands to a temporary file, and then execute with SHELL or COMSPEC. The current mechanism defaults to dos-style shell conventions unless the shell is one of sh, bash, csh, tcsh, sh32, @@ -245,7 +245,7 @@ 4. GNU make is available at LEO for OS/2, in the djgpp collection -for DOS, and in the Mingw32 collection for Win32. +for DOS, and in the Mingw32 collection for Windows32. dmake is by Dennis Vadura (dvadura@watdragon.uwaterloo.ca), CS Dept., University of Waterloo. OS/2 and DOS versions can be found as @@ -358,7 +358,7 @@ we didn't read the relevant portions of the FAQ :). We are indebted to Juan Grigera for the -Visual C++ target, and for additional help on changes for Win32. +Visual C++ target, and for additional help on changes for Windows32. ---- @@ -370,10 +370,10 @@ gawk-maintainer@unixos2.org (OS/2 version) Darrel Hankerson, hankedr@mail.auburn.edu -Support for Win32 started in gawk-3.0.3. Reports on +Support for Windows32 started in gawk-3.0.3. Reports on the Visual C++ version (vcWin32) may be sent to Juan Grigera, juan@biophnet.unlp.edu.ar (Visual C++ version) -with a copy to Scott Deifik. Other Win32 reports may go to Darrel +with a copy to Scott Deifik. Other Windows32 reports may go to Darrel Hankerson. diff -urN gawk-3.1.2/README_d/README.pcdynamic gawk-3.1.3/README_d/README.pcdynamic --- gawk-3.1.2/README_d/README.pcdynamic 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/README_d/README.pcdynamic 2003-07-04 10:09:19.000000000 -0700 @@ -0,0 +1,93 @@ +This is the README for dynamic extension support for GNU awk 3.1.2 under Windows32 +This part of the README is directed to the gawk maintainers. + +The implementation consists of + +pc/dlfcn.h +pc/dlfcn.c + An implementation of the POSIX dynamic loading functions for Windows32. + Bugs and limitations: + the RTLD_* flags are ignored + passing NULL as the module name is not really supported. + dlerror() doesn't always generate useful output. + +pc/w32dynamic.patch + A patch to pc/Makefile. This adds macros to allow dynamic loading + to be compiled in. The macros (DYN_EXP, DYN_OBJ, DYN_FLAGS, and + DYN_MAKEXP) are commented-out by default (which is the default on + Unix as well). I've added definitions only for MS VC and MinGW. + I also added support for pgawk under MS VC and MinGW. + +pc/gawkw32.def + A list of functions to export from gawk.exe. Every function used + in an extension DLL needs to be in this file. I've added the ones + required by the provided examples, but some thought should go into + determining a useful set of API functions. From a maintenance + perspective, it's important that the ordinals (the number following @) + never change. You can use an existing DLL with a gawk.exe which has + new exported functions, but if you change the ordinal of an existing + function, you have to recompile all the extensions that use it. + +extension/Makefile.pc + A make file which compiles a few of the extension examples. + Only readfile, ordchr, and arrayparm are built, since the + other functions didn't compile without sizeable modifications. + +extension/pcext.def + A module definition file which exports dlload. + +extension/w32dynamic.patch + A patch to readfile.c to have it open files in binary mode. Without + this, the bytes read doesn't always match the file size. + +w32dynamic.patch + A patch to awk.h. This makes the temporary variable _t static and + adds an attribute to some data declarations when WIN32_EXTENSION is + defined. The issue is that data imported from a separate module has + a different level of indirection from the same data in the + original module. The difference can be made transparent by adding + __declspec(dllimport)) to the declarations used in the importing module. + Since _t doesn't actually have to be shared, I've just made it + static to the extension module and avoided the problem. + +README_d/README.pcdynamic + This file. + +The remainder of the file is intended for people installing and using gawk +and probably ought to be added to README.pc +--- +To compile gawk with dynamic extension support, uncomment the +definitions of DYN_FLAGS, DYN_EXP, DYN_OBJ, and DYN_MAKEXP in the +configuration section of Makefile. There are two definitions for +DYN_MAKEXP -- pick the one that matches your target. + +To build some of the example extension libraries, cd to the extension +directory and copy Makefile.pc to Makefile. You can then build using the same +two targets. To run the example awk scripts, you'll need to either change the +call to the `extension' function to match the name of the library (for +instance, change "./ordchr.so" to "ordchr.dll" or simply "ordchr"), or rename +the library to match the call (for instance, rename ordchr.dll to ordchr.so). + +If you build gawk.exe with one compiler but want to build an extension library +with the other, you need to copy the import library. Visual C uses a library +called gawk.lib, while MinGW uses a library called libgawk.a. These files +are equivalent and will interoperate if you give them the correct name. +The resulting shared libraries are also interoperable. + +To create your own extension library, you can use the examples as models, but +you're essentially on your own. Post to comp.lang.awk or send e-mail to +ptjm@interlog.com if you have problems getting started. If you need to access +functions or variables which are not exported by gawk.exe, add them to +gawkw32.def and rebuild. You should also add ATTRIBUTE_EXPORTED to the +declaration in awk.h of any variables you add to gawkw32.def. + +Note that extension libraries have the name of the awk executable embedded in +them at link time, so they will work only with gawk.exe. In particular, they won't +work if you rename gawk.exe to awk.exe or if you try to use pgawk.exe. You can +perform profiling by temporarily renaming pgawk.exe to gawk.exe. You can resolve +this problem by changing the program name in the definition of DYN_MAKEXP for +your compiler. + +On Windows32, libraries are sought first in the current directory, then in the +directory containing gawk.exe, and finally through the PATH environment +variable. diff -urN gawk-3.1.2/aclocal.m4 gawk-3.1.3/aclocal.m4 --- gawk-3.1.2/aclocal.m4 2003-03-16 02:25:33.000000000 -0800 +++ gawk-3.1.3/aclocal.m4 2003-07-04 10:48:58.000000000 -0700 @@ -1,4 +1,4 @@ -# generated automatically by aclocal 1.7.3 -*- Autoconf -*- +# generated automatically by aclocal 1.7.5 -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002 # Free Software Foundation, Inc. @@ -23,7 +23,7 @@ # This macro actually does too much some checks are only needed if # your package does certain things. But this isn't really a big deal. -# Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 # Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify @@ -41,14 +41,7 @@ # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA # 02111-1307, USA. -# serial 9 - -# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be -# written in clear, in which case automake, when reading aclocal.m4, -# will think it sees a *use*, and therefore will trigger all it's -# C support machinery. Also note that it means that autoscan, seeing -# CC etc. in the Makefile, will ask for an AC_PROG_CC use... - +# serial 10 AC_PREREQ([2.54]) @@ -177,7 +170,7 @@ # Call AM_AUTOMAKE_VERSION so it can be traced. # This function is AC_REQUIREd by AC_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], - [AM_AUTOMAKE_VERSION([1.7.3])]) + [AM_AUTOMAKE_VERSION([1.7.5])]) # Helper functions for option handling. -*- Autoconf -*- @@ -727,7 +720,7 @@ # Check to see how 'make' treats includes. -*- Autoconf -*- -# Copyright (C) 2001, 2002 Free Software Foundation, Inc. +# Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -752,8 +745,9 @@ AC_DEFUN([AM_MAKE_INCLUDE], [am_make=${MAKE-make} cat > confinc << 'END' -doit: +am__doit: @echo done +.PHONY: am__doit END # If we don't find an include directive, just comment out the code. AC_MSG_CHECKING([for style of include used by $am_make]) @@ -781,9 +775,9 @@ _am_result=BSD fi fi -AC_SUBST(am__include) -AC_SUBST(am__quote) -AC_MSG_RESULT($_am_result) +AC_SUBST([am__include]) +AC_SUBST([am__quote]) +AC_MSG_RESULT([$_am_result]) rm -f confinc confmf ]) @@ -1067,8 +1061,8 @@ AU_DEFUN([fp_C_PROTOTYPES], [AM_C_PROTOTYPES]) -# gettext.m4 serial 17 (gettext-0.11.5) -dnl Copyright (C) 1995-2002 Free Software Foundation, Inc. +# gettext.m4 serial 20 (gettext-0.12) +dnl Copyright (C) 1995-2003 Free Software Foundation, Inc. dnl This file is free software, distributed under the terms of the GNU dnl General Public License. As a special exception to the GNU General dnl Public License, this file may be distributed as part of a program @@ -1086,7 +1080,7 @@ dnl Authors: dnl Ulrich Drepper , 1995-2000. -dnl Bruno Haible , 2000-2002. +dnl Bruno Haible , 2000-2003. dnl Macro to add for using GNU gettext. @@ -1161,13 +1155,8 @@ AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY]) ]) - AC_MSG_CHECKING([whether NLS is requested]) - dnl Default is enabled NLS - AC_ARG_ENABLE(nls, - [ --disable-nls do not use Native Language Support], - USE_NLS=$enableval, USE_NLS=yes) - AC_MSG_RESULT($USE_NLS) - AC_SUBST(USE_NLS) + dnl Set USE_NLS. + AM_NLS ifelse(gt_included_intl, yes, [ BUILD_INCLUDED_LIBINTL=no @@ -1285,7 +1274,8 @@ dnl libintl. (Cf. the install rule in intl/Makefile.in.) if test "$gt_cv_func_gnugettext_libc" = "yes" \ || { test "$gt_cv_func_gnugettext_libintl" = "yes" \ - && test "$PACKAGE" != gettext; }; then + && test "$PACKAGE" != gettext-runtime \ + && test "$PACKAGE" != gettext-tools; }; then gt_use_preinstalled_gnugettext=yes else dnl Reset the values set by searching for libintl. @@ -1304,7 +1294,6 @@ if test "$nls_cv_use_gnu_gettext" = "yes"; then dnl Mark actions used to generate GNU NLS library. - INTLOBJS="\$(GETTOBJS)" BUILD_INCLUDED_LIBINTL=yes USE_INCLUDED_LIBINTL=yes LIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LIBICONV" @@ -1329,6 +1318,22 @@ fi fi + AC_MSG_CHECKING([whether to use NLS]) + AC_MSG_RESULT([$USE_NLS]) + if test "$USE_NLS" = "yes"; then + AC_MSG_CHECKING([where the gettext function comes from]) + if test "$gt_use_preinstalled_gnugettext" = "yes"; then + if test "$gt_cv_func_gnugettext_libintl" = "yes"; then + gt_source="external libintl" + else + gt_source="libc" + fi + else + gt_source="included intl directory" + fi + AC_MSG_RESULT([$gt_source]) + fi + if test "$USE_NLS" = "yes"; then if test "$gt_use_preinstalled_gnugettext" = "yes"; then @@ -1352,7 +1357,7 @@ ifelse(gt_included_intl, yes, [ dnl If this is used in GNU gettext we have to set BUILD_INCLUDED_LIBINTL dnl to 'yes' because some of the testsuite requires it. - if test "$PACKAGE" = gettext; then + if test "$PACKAGE" = gettext-runtime || test "$PACKAGE" = gettext-tools; then BUILD_INCLUDED_LIBINTL=yes fi @@ -1360,7 +1365,6 @@ AC_SUBST(BUILD_INCLUDED_LIBINTL) AC_SUBST(USE_INCLUDED_LIBINTL) AC_SUBST(CATOBJEXT) - AC_SUBST(INTLOBJS) dnl For backward compatibility. Some configure.ins may be using this. nls_cv_header_intl= @@ -1378,6 +1382,12 @@ GENCAT=gencat AC_SUBST(GENCAT) + dnl For backward compatibility. Some Makefiles may be using this. + if test "$USE_INCLUDED_LIBINTL" = yes; then + INTLOBJS="\$(GETTOBJS)" + fi + AC_SUBST(INTLOBJS) + dnl Enable libtool support if the surrounding package wishes it. INTL_LIBTOOL_SUFFIX_PREFIX=gt_libtool_suffix_prefix AC_SUBST(INTL_LIBTOOL_SUFFIX_PREFIX) @@ -1394,13 +1404,107 @@ ]) -dnl Checks for all prerequisites of the po subdirectory, -dnl except for USE_NLS. +dnl Checks for all prerequisites of the intl subdirectory, +dnl except for INTL_LIBTOOL_SUFFIX_PREFIX (and possibly LIBTOOL), INTLOBJS, +dnl USE_INCLUDED_LIBINTL, BUILD_INCLUDED_LIBINTL. +AC_DEFUN([AM_INTL_SUBDIR], +[ + AC_REQUIRE([AC_PROG_INSTALL])dnl + AC_REQUIRE([AM_MKINSTALLDIRS])dnl + AC_REQUIRE([AC_PROG_CC])dnl + AC_REQUIRE([AC_CANONICAL_HOST])dnl + AC_REQUIRE([AC_PROG_RANLIB])dnl + AC_REQUIRE([AC_ISC_POSIX])dnl + AC_REQUIRE([AC_HEADER_STDC])dnl + AC_REQUIRE([AC_C_CONST])dnl + AC_REQUIRE([AC_C_INLINE])dnl + AC_REQUIRE([AC_TYPE_OFF_T])dnl + AC_REQUIRE([AC_TYPE_SIZE_T])dnl + AC_REQUIRE([AC_FUNC_ALLOCA])dnl + AC_REQUIRE([AC_FUNC_MMAP])dnl + AC_REQUIRE([jm_GLIBC21])dnl + AC_REQUIRE([gt_INTDIV0])dnl + AC_REQUIRE([jm_AC_TYPE_UINTMAX_T])dnl + AC_REQUIRE([gt_HEADER_INTTYPES_H])dnl + AC_REQUIRE([gt_INTTYPES_PRI])dnl + + AC_CHECK_HEADERS([argz.h limits.h locale.h nl_types.h malloc.h stddef.h \ +stdlib.h string.h unistd.h sys/param.h]) + AC_CHECK_FUNCS([feof_unlocked fgets_unlocked getc_unlocked getcwd getegid \ +geteuid getgid getuid mempcpy munmap putenv setenv setlocale stpcpy \ +strcasecmp strdup strtoul tsearch __argz_count __argz_stringify __argz_next \ +__fsetlocking]) + + AM_ICONV + AM_LANGINFO_CODESET + if test $ac_cv_header_locale_h = yes; then + AM_LC_MESSAGES + fi + + dnl intl/plural.c is generated from intl/plural.y. It requires bison, + dnl because plural.y uses bison specific features. It requires at least + dnl bison-1.26 because earlier versions generate a plural.c that doesn't + dnl compile. + dnl bison is only needed for the maintainer (who touches plural.y). But in + dnl order to avoid separate Makefiles or --enable-maintainer-mode, we put + dnl the rule in general Makefile. Now, some people carelessly touch the + dnl files or have a broken "make" program, hence the plural.c rule will + dnl sometimes fire. To avoid an error, defines BISON to ":" if it is not + dnl present or too old. + AC_CHECK_PROGS([INTLBISON], [bison]) + if test -z "$INTLBISON"; then + ac_verc_fail=yes + else + dnl Found it, now check the version. + AC_MSG_CHECKING([version of bison]) +changequote(<<,>>)dnl + ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'` + case $ac_prog_version in + '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;; + 1.2[6-9]* | 1.[3-9][0-9]* | [2-9].*) +changequote([,])dnl + ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;; + *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;; + esac + AC_MSG_RESULT([$ac_prog_version]) + fi + if test $ac_verc_fail = yes; then + INTLBISON=: + fi +]) + + +dnl Usage: AM_GNU_GETTEXT_VERSION([gettext-version]) +AC_DEFUN([AM_GNU_GETTEXT_VERSION], []) + +# po.m4 serial 1 (gettext-0.12) +dnl Copyright (C) 1995-2003 Free Software Foundation, Inc. +dnl This file is free software, distributed under the terms of the GNU +dnl General Public License. As a special exception to the GNU General +dnl Public License, this file may be distributed as part of a program +dnl that contains a configuration script generated by Autoconf, under +dnl the same distribution terms as the rest of that program. +dnl +dnl This file can can be used in projects which are not available under +dnl the GNU General Public License or the GNU Library General Public +dnl License but which still want to provide support for the GNU gettext +dnl functionality. +dnl Please note that the actual code of the GNU gettext library is covered +dnl by the GNU Library General Public License, and the rest of the GNU +dnl gettext package package is covered by the GNU General Public License. +dnl They are *not* in the public domain. + +dnl Authors: +dnl Ulrich Drepper , 1995-2000. +dnl Bruno Haible , 2000-2003. + +dnl Checks for all prerequisites of the po subdirectory. AC_DEFUN([AM_PO_SUBDIRS], [ AC_REQUIRE([AC_PROG_MAKE_SET])dnl AC_REQUIRE([AC_PROG_INSTALL])dnl AC_REQUIRE([AM_MKINSTALLDIRS])dnl + AC_REQUIRE([AM_NLS])dnl dnl Perform the following tests also if --disable-nls has been given, dnl because they are needed for "make dist" to work. @@ -1414,12 +1518,12 @@ :) AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) - dnl Search for GNU xgettext 0.11 or newer in the PATH. + dnl Search for GNU xgettext 0.12 or newer in the PATH. dnl The first test excludes Solaris xgettext and early GNU xgettext versions. dnl The second test excludes FreeBSD xgettext. AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, - [$ac_dir/$ac_word --omit-header --copyright-holder= /dev/null >/dev/null 2>&1 && - (if $ac_dir/$ac_word --omit-header --copyright-holder= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)], + [$ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 && + (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)], :) dnl Remove leftover from FreeBSD xgettext call. rm -f messages.po @@ -1449,8 +1553,8 @@ if test "$XGETTEXT" != ":"; then dnl If it is no GNU xgettext we define it as : so that the dnl Makefiles still can work. - if $XGETTEXT --omit-header --copyright-holder= /dev/null >/dev/null 2>&1 && - (if $XGETTEXT --omit-header --copyright-holder= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then + if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 && + (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 : ; else AC_MSG_RESULT( @@ -1485,17 +1589,22 @@ rm -f "$ac_dir/POTFILES" test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES" cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES" + POMAKEFILEDEPS="POTFILES.in" # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend # on $ac_dir but don't depend on user-specified configuration # parameters. if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then # The LINGUAS file contains the set of available languages. - if test -n "$ALL_LINGUAS"; then + if test -n "$OBSOLETE_ALL_LINGUAS"; then test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete" fi ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"` # Hide the ALL_LINGUAS assigment from automake. eval 'ALL_LINGUAS''=$ALL_LINGUAS_' + POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS" + else + # The set of available languages was given in configure.in. + eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS' fi case "$ac_given_srcdir" in .) srcdirpre= ;; @@ -1544,7 +1653,7 @@ done fi test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile" - sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile" + sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile" for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do if test -f "$f"; then case "$f" in @@ -1560,90 +1669,55 @@ [# Capture the value of obsolete ALL_LINGUAS because we need it to compute # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it # from automake. - eval 'ALL_LINGUAS''="$ALL_LINGUAS"' + eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"' # Capture the value of LINGUAS because we need it to compute CATALOGS. LINGUAS="${LINGUAS-%UNSET%}" ]) ]) +# nls.m4 serial 1 (gettext-0.12) +dnl Copyright (C) 1995-2003 Free Software Foundation, Inc. +dnl This file is free software, distributed under the terms of the GNU +dnl General Public License. As a special exception to the GNU General +dnl Public License, this file may be distributed as part of a program +dnl that contains a configuration script generated by Autoconf, under +dnl the same distribution terms as the rest of that program. +dnl +dnl This file can can be used in projects which are not available under +dnl the GNU General Public License or the GNU Library General Public +dnl License but which still want to provide support for the GNU gettext +dnl functionality. +dnl Please note that the actual code of the GNU gettext library is covered +dnl by the GNU Library General Public License, and the rest of the GNU +dnl gettext package package is covered by the GNU General Public License. +dnl They are *not* in the public domain. -dnl Checks for all prerequisites of the intl subdirectory, -dnl except for INTL_LIBTOOL_SUFFIX_PREFIX (and possibly LIBTOOL), INTLOBJS, -dnl USE_INCLUDED_LIBINTL, BUILD_INCLUDED_LIBINTL. -AC_DEFUN([AM_INTL_SUBDIR], -[ - AC_REQUIRE([AC_PROG_INSTALL])dnl - AC_REQUIRE([AM_MKINSTALLDIRS])dnl - AC_REQUIRE([AC_PROG_CC])dnl - AC_REQUIRE([AC_CANONICAL_HOST])dnl - AC_REQUIRE([AC_PROG_RANLIB])dnl - AC_REQUIRE([AC_ISC_POSIX])dnl - AC_REQUIRE([AC_HEADER_STDC])dnl - AC_REQUIRE([AC_C_CONST])dnl - AC_REQUIRE([AC_C_INLINE])dnl - AC_REQUIRE([AC_TYPE_OFF_T])dnl - AC_REQUIRE([AC_TYPE_SIZE_T])dnl - AC_REQUIRE([AC_FUNC_ALLOCA])dnl - AC_REQUIRE([AC_FUNC_MMAP])dnl - AC_REQUIRE([jm_GLIBC21])dnl - AC_REQUIRE([gt_INTDIV0])dnl - AC_REQUIRE([jm_AC_TYPE_UINTMAX_T])dnl - AC_REQUIRE([gt_HEADER_INTTYPES_H])dnl - AC_REQUIRE([gt_INTTYPES_PRI])dnl - - AC_CHECK_HEADERS([argz.h limits.h locale.h nl_types.h malloc.h stddef.h \ -stdlib.h string.h unistd.h sys/param.h]) - AC_CHECK_FUNCS([feof_unlocked fgets_unlocked getc_unlocked getcwd getegid \ -geteuid getgid getuid mempcpy munmap putenv setenv setlocale stpcpy \ -strcasecmp strdup strtoul tsearch __argz_count __argz_stringify __argz_next]) - - AM_ICONV - AM_LANGINFO_CODESET - if test $ac_cv_header_locale_h = yes; then - AM_LC_MESSAGES - fi +dnl Authors: +dnl Ulrich Drepper , 1995-2000. +dnl Bruno Haible , 2000-2003. - dnl intl/plural.c is generated from intl/plural.y. It requires bison, - dnl because plural.y uses bison specific features. It requires at least - dnl bison-1.26 because earlier versions generate a plural.c that doesn't - dnl compile. - dnl bison is only needed for the maintainer (who touches plural.y). But in - dnl order to avoid separate Makefiles or --enable-maintainer-mode, we put - dnl the rule in general Makefile. Now, some people carelessly touch the - dnl files or have a broken "make" program, hence the plural.c rule will - dnl sometimes fire. To avoid an error, defines BISON to ":" if it is not - dnl present or too old. - AC_CHECK_PROGS([INTLBISON], [bison]) - if test -z "$INTLBISON"; then - ac_verc_fail=yes - else - dnl Found it, now check the version. - AC_MSG_CHECKING([version of bison]) -changequote(<<,>>)dnl - ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'` - case $ac_prog_version in - '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;; - 1.2[6-9]* | 1.[3-9][0-9]* | [2-9].*) -changequote([,])dnl - ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;; - *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;; - esac - AC_MSG_RESULT([$ac_prog_version]) - fi - if test $ac_verc_fail = yes; then - INTLBISON=: - fi +AC_DEFUN([AM_NLS], +[ + AC_MSG_CHECKING([whether NLS is requested]) + dnl Default is enabled NLS + AC_ARG_ENABLE(nls, + [ --disable-nls do not use Native Language Support], + USE_NLS=$enableval, USE_NLS=yes) + AC_MSG_RESULT($USE_NLS) + AC_SUBST(USE_NLS) ]) - AC_DEFUN([AM_MKINSTALLDIRS], [ dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly dnl find the mkinstalldirs script in another subdir but $(top_srcdir). - dnl Try to locate is. + dnl Try to locate it. MKINSTALLDIRS= if test -n "$ac_aux_dir"; then - MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" + case "$ac_aux_dir" in + /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;; + *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;; + esac fi if test -z "$MKINSTALLDIRS"; then MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" @@ -1651,12 +1725,100 @@ AC_SUBST(MKINSTALLDIRS) ]) +# progtest.m4 serial 3 (gettext-0.12) +dnl Copyright (C) 1996-2003 Free Software Foundation, Inc. +dnl This file is free software, distributed under the terms of the GNU +dnl General Public License. As a special exception to the GNU General +dnl Public License, this file may be distributed as part of a program +dnl that contains a configuration script generated by Autoconf, under +dnl the same distribution terms as the rest of that program. +dnl +dnl This file can can be used in projects which are not available under +dnl the GNU General Public License or the GNU Library General Public +dnl License but which still want to provide support for the GNU gettext +dnl functionality. +dnl Please note that the actual code of the GNU gettext library is covered +dnl by the GNU Library General Public License, and the rest of the GNU +dnl gettext package package is covered by the GNU General Public License. +dnl They are *not* in the public domain. + +dnl Authors: +dnl Ulrich Drepper , 1996. -dnl Usage: AM_GNU_GETTEXT_VERSION([gettext-version]) -AC_DEFUN([AM_GNU_GETTEXT_VERSION], []) +# Search path for a program which passes the given test. + +dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR, +dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]]) +AC_DEFUN([AM_PATH_PROG_WITH_TEST], +[ +# Prepare PATH_SEPARATOR. +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + echo "#! /bin/sh" >conf$$.sh + echo "exit 0" >>conf$$.sh + chmod +x conf$$.sh + if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then + PATH_SEPARATOR=';' + else + PATH_SEPARATOR=: + fi + rm -f conf$$.sh +fi + +# Find out how to test for executable files. Don't use a zero-byte file, +# as systems may use methods other than mode bits to determine executability. +cat >conf$$.file <<_ASEOF +#! /bin/sh +exit 0 +_ASEOF +chmod +x conf$$.file +if test -x conf$$.file >/dev/null 2>&1; then + ac_executable_p="test -x" +else + ac_executable_p="test -f" +fi +rm -f conf$$.file + +# Extract the first word of "$2", so it can be a program name with args. +set dummy $2; ac_word=[$]2 +AC_MSG_CHECKING([for $ac_word]) +AC_CACHE_VAL(ac_cv_path_$1, +[case "[$]$1" in + [[\\/]]* | ?:[[\\/]]*) + ac_cv_path_$1="[$]$1" # Let the user override the test with a path. + ;; + *) + ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in ifelse([$5], , $PATH, [$5]); do + IFS="$ac_save_IFS" + test -z "$ac_dir" && ac_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then + if [$3]; then + ac_cv_path_$1="$ac_dir/$ac_word$ac_exec_ext" + break 2 + fi + fi + done + done + IFS="$ac_save_IFS" +dnl If no 4th arg is given, leave the cache variable unset, +dnl so AC_PATH_PROGS will keep looking. +ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4" +])dnl + ;; +esac])dnl +$1="$ac_cv_path_$1" +if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then + AC_MSG_RESULT([$]$1) +else + AC_MSG_RESULT(no) +fi +AC_SUBST($1)dnl +]) -# lib-prefix.m4 serial 1 (gettext-0.11) -dnl Copyright (C) 2001-2002 Free Software Foundation, Inc. +# lib-prefix.m4 serial 2 (gettext-0.12) +dnl Copyright (C) 2001-2003 Free Software Foundation, Inc. dnl This file is free software, distributed under the terms of the GNU dnl General Public License. As a special exception to the GNU General dnl Public License, this file may be distributed as part of a program @@ -1665,6 +1827,13 @@ dnl From Bruno Haible. +dnl AC_LIB_ARG_WITH is synonymous to AC_ARG_WITH in autoconf-2.13, and +dnl similar to AC_ARG_WITH in autoconf 2.52...2.57 except that is doesn't +dnl require excessive bracketing. +ifdef([AC_HELP_STRING], +[AC_DEFUN([AC_LIB_ARG_WITH], [AC_ARG_WITH([$1],[[$2]],[$3],[$4])])], +[AC_DEFUN([AC_LIB_ARG_WITH], [AC_ARG_WITH([$1],[$2],[$3],[$4])])]) + dnl AC_LIB_PREFIX adds to the CPPFLAGS and LDFLAGS the flags that are needed dnl to access previously installed libraries. The basic assumption is that dnl a user will want packages to use other packages he previously installed @@ -1683,7 +1852,7 @@ eval additional_includedir=\"$includedir\" eval additional_libdir=\"$libdir\" ]) - AC_ARG_WITH([lib-prefix], + AC_LIB_ARG_WITH([lib-prefix], [ --with-lib-prefix[=DIR] search for libraries in DIR/include and DIR/lib --without-lib-prefix don't search for libraries in includedir and libdir], [ @@ -1804,8 +1973,8 @@ prefix="$acl_save_prefix" ]) -# lib-link.m4 serial 3 (gettext-0.11.3) -dnl Copyright (C) 2001-2002 Free Software Foundation, Inc. +# lib-link.m4 serial 4 (gettext-0.12) +dnl Copyright (C) 2001-2003 Free Software Foundation, Inc. dnl This file is free software, distributed under the terms of the GNU dnl General Public License. As a special exception to the GNU General dnl Public License, this file may be distributed as part of a program @@ -1898,8 +2067,7 @@ dnl Determine the platform dependent parameters needed to use rpath: dnl libext, shlibext, hardcode_libdir_flag_spec, hardcode_libdir_separator, -dnl hardcode_direct, hardcode_minus_L, -dnl sys_lib_search_path_spec, sys_lib_dlsearch_path_spec. +dnl hardcode_direct, hardcode_minus_L. AC_DEFUN([AC_LIB_RPATH], [ AC_REQUIRE([AC_PROG_CC]) dnl we use $CC, $GCC, $LDFLAGS @@ -1920,8 +2088,6 @@ hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" hardcode_direct="$acl_cv_hardcode_direct" hardcode_minus_L="$acl_cv_hardcode_minus_L" - sys_lib_search_path_spec="$acl_cv_sys_lib_search_path_spec" - sys_lib_dlsearch_path_spec="$acl_cv_sys_lib_dlsearch_path_spec" dnl Determine whether the user wants rpath handling at all. AC_ARG_ENABLE(rpath, [ --disable-rpath do not hardcode runtime library paths], @@ -1941,7 +2107,7 @@ eval additional_includedir=\"$includedir\" eval additional_libdir=\"$libdir\" ]) - AC_ARG_WITH([lib$1-prefix], + AC_LIB_ARG_WITH([lib$1-prefix], [ --with-lib$1-prefix[=DIR] search for lib$1 in DIR/include and DIR/lib --without-lib$1-prefix don't search for lib$1 in includedir and libdir], [ @@ -2359,8 +2525,8 @@ done ]) -# lib-ld.m4 serial 1 (gettext-0.11) -dnl Copyright (C) 1996-2002 Free Software Foundation, Inc. +# lib-ld.m4 serial 2 (gettext-0.12) +dnl Copyright (C) 1996-2003 Free Software Foundation, Inc. dnl This file is free software, distributed under the terms of the GNU dnl General Public License. As a special exception to the GNU General dnl Public License, this file may be distributed as part of a program @@ -2390,6 +2556,19 @@ test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no) AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([AC_CANONICAL_HOST])dnl +# Prepare PATH_SEPARATOR. +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + echo "#! /bin/sh" >conf$$.sh + echo "exit 0" >>conf$$.sh + chmod +x conf$$.sh + if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then + PATH_SEPARATOR=';' + else + PATH_SEPARATOR=: + fi + rm -f conf$$.sh +fi ac_prog=ld if test "$GCC" = yes; then # Check if gcc -print-prog-name=ld gives a path. @@ -2561,66 +2740,6 @@ fi ]) -# progtest.m4 serial 2 (gettext-0.10.40) -dnl Copyright (C) 1996-2002 Free Software Foundation, Inc. -dnl This file is free software, distributed under the terms of the GNU -dnl General Public License. As a special exception to the GNU General -dnl Public License, this file may be distributed as part of a program -dnl that contains a configuration script generated by Autoconf, under -dnl the same distribution terms as the rest of that program. -dnl -dnl This file can can be used in projects which are not available under -dnl the GNU General Public License or the GNU Library General Public -dnl License but which still want to provide support for the GNU gettext -dnl functionality. -dnl Please note that the actual code of the GNU gettext library is covered -dnl by the GNU Library General Public License, and the rest of the GNU -dnl gettext package package is covered by the GNU General Public License. -dnl They are *not* in the public domain. - -dnl Authors: -dnl Ulrich Drepper , 1996. - -# Search path for a program which passes the given test. - -dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR, -dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]]) -AC_DEFUN([AM_PATH_PROG_WITH_TEST], -[# Extract the first word of "$2", so it can be a program name with args. -set dummy $2; ac_word=[$]2 -AC_MSG_CHECKING([for $ac_word]) -AC_CACHE_VAL(ac_cv_path_$1, -[case "[$]$1" in - /*) - ac_cv_path_$1="[$]$1" # Let the user override the test with a path. - ;; - *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" - for ac_dir in ifelse([$5], , $PATH, [$5]); do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - if [$3]; then - ac_cv_path_$1="$ac_dir/$ac_word" - break - fi - fi - done - IFS="$ac_save_ifs" -dnl If no 4th arg is given, leave the cache variable unset, -dnl so AC_PATH_PROGS will keep looking. -ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4" -])dnl - ;; -esac])dnl -$1="$ac_cv_path_$1" -if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then - AC_MSG_RESULT([$]$1) -else - AC_MSG_RESULT(no) -fi -AC_SUBST($1)dnl -]) - # glibc21.m4 serial 2 (fileutils-4.1.3, gettext-0.10.40) dnl Copyright (C) 2000-2002 Free Software Foundation, Inc. dnl This file is free software, distributed under the terms of the GNU @@ -2727,103 +2846,60 @@ [Define if integer division by zero raises signal SIGFPE.]) ]) -# uintmax_t.m4 serial 6 (gettext-0.11) -dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. -dnl This file is free software, distributed under the terms of the GNU -dnl General Public License. As a special exception to the GNU General -dnl Public License, this file may be distributed as part of a program -dnl that contains a configuration script generated by Autoconf, under -dnl the same distribution terms as the rest of that program. +#serial 6 dnl From Paul Eggert. -AC_PREREQ(2.13) +AC_PREREQ(2.52) -# Define uintmax_t to `unsigned long' or `unsigned long long' -# if does not exist. +# Define intmax_t to long or long long if doesn't define. -AC_DEFUN([jm_AC_TYPE_UINTMAX_T], +AC_DEFUN([jm_AC_TYPE_INTMAX_T], [ - AC_REQUIRE([jm_AC_HEADER_INTTYPES_H]) - AC_REQUIRE([jm_AC_HEADER_STDINT_H]) - if test $jm_ac_cv_header_inttypes_h = no && test $jm_ac_cv_header_stdint_h = no; then - AC_REQUIRE([jm_AC_TYPE_UNSIGNED_LONG_LONG]) - test $ac_cv_type_unsigned_long_long = yes \ - && ac_type='unsigned long long' \ - || ac_type='unsigned long' - AC_DEFINE_UNQUOTED(uintmax_t, $ac_type, - [Define to unsigned long or unsigned long long - if and don't define.]) - fi + AC_REQUIRE([jm_AC_TYPE_LONG_LONG]) + AC_CHECK_TYPE(intmax_t, , + [test $ac_cv_type_long_long = yes \ + && ac_type='long long' \ + || ac_type='long' + AC_DEFINE_UNQUOTED(intmax_t, $ac_type, + [Define to widest signed type if doesn't define.])]) ]) -# inttypes_h.m4 serial 4 (gettext-0.11.4) -dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. -dnl This file is free software, distributed under the terms of the GNU -dnl General Public License. As a special exception to the GNU General -dnl Public License, this file may be distributed as part of a program -dnl that contains a configuration script generated by Autoconf, under -dnl the same distribution terms as the rest of that program. - -dnl From Paul Eggert. - -# Define HAVE_INTTYPES_H_WITH_UINTMAX if exists, -# doesn't clash with , and declares uintmax_t. +# Define uintmax_t to unsigned long or unsigned long long +# if doesn't define. -AC_DEFUN([jm_AC_HEADER_INTTYPES_H], +AC_DEFUN([jm_AC_TYPE_UINTMAX_T], [ - AC_CACHE_CHECK([for inttypes.h], jm_ac_cv_header_inttypes_h, - [AC_TRY_COMPILE( - [#include -#include ], - [uintmax_t i = (uintmax_t) -1;], - jm_ac_cv_header_inttypes_h=yes, - jm_ac_cv_header_inttypes_h=no)]) - if test $jm_ac_cv_header_inttypes_h = yes; then - AC_DEFINE_UNQUOTED(HAVE_INTTYPES_H_WITH_UINTMAX, 1, -[Define if exists, doesn't clash with , - and declares uintmax_t. ]) - fi + AC_REQUIRE([jm_AC_TYPE_UNSIGNED_LONG_LONG]) + AC_CHECK_TYPE(uintmax_t, , + [test $ac_cv_type_unsigned_long_long = yes \ + && ac_type='unsigned long long' \ + || ac_type='unsigned long' + AC_DEFINE_UNQUOTED(uintmax_t, $ac_type, + [Define to widest unsigned type if doesn't define.])]) ]) -# stdint_h.m4 serial 2 (gettext-0.11.4) -dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. -dnl This file is free software, distributed under the terms of the GNU -dnl General Public License. As a special exception to the GNU General -dnl Public License, this file may be distributed as part of a program -dnl that contains a configuration script generated by Autoconf, under -dnl the same distribution terms as the rest of that program. +#serial 2 dnl From Paul Eggert. -# Define HAVE_STDINT_H_WITH_UINTMAX if exists, -# doesn't clash with , and declares uintmax_t. +# Define HAVE_LONG_LONG if 'long long' works. -AC_DEFUN([jm_AC_HEADER_STDINT_H], +AC_DEFUN([jm_AC_TYPE_LONG_LONG], [ - AC_CACHE_CHECK([for stdint.h], jm_ac_cv_header_stdint_h, - [AC_TRY_COMPILE( - [#include -#include ], - [uintmax_t i = (uintmax_t) -1;], - jm_ac_cv_header_stdint_h=yes, - jm_ac_cv_header_stdint_h=no)]) - if test $jm_ac_cv_header_stdint_h = yes; then - AC_DEFINE_UNQUOTED(HAVE_STDINT_H_WITH_UINTMAX, 1, -[Define if exists, doesn't clash with , - and declares uintmax_t. ]) + AC_CACHE_CHECK([for long long], ac_cv_type_long_long, + [AC_TRY_LINK([long long ll = 1; int i = 63;], + [long long llmax = (long long) -1; + return ll << i | ll >> i | llmax / ll | llmax % ll;], + ac_cv_type_long_long=yes, + ac_cv_type_long_long=no)]) + if test $ac_cv_type_long_long = yes; then + AC_DEFINE(HAVE_LONG_LONG, 1, + [Define if you have the long long type.]) fi ]) -# ulonglong.m4 serial 2 (fileutils-4.0.32, gettext-0.10.40) -dnl Copyright (C) 1999-2002 Free Software Foundation, Inc. -dnl This file is free software, distributed under the terms of the GNU -dnl General Public License. As a special exception to the GNU General -dnl Public License, this file may be distributed as part of a program -dnl that contains a configuration script generated by Autoconf, under -dnl the same distribution terms as the rest of that program. - -dnl From Paul Eggert. +# Define HAVE_UNSIGNED_LONG_LONG if 'unsigned long long' works. AC_DEFUN([jm_AC_TYPE_UNSIGNED_LONG_LONG], [ diff -urN gawk-3.1.2/array.c gawk-3.1.3/array.c --- gawk-3.1.2/array.c 2003-02-18 05:57:44.000000000 -0800 +++ gawk-3.1.3/array.c 2003-07-04 10:12:45.000000000 -0700 @@ -70,6 +70,187 @@ hash = gst_hash_string; } +/* + * get_actual --- proceed to the actual Node_var_array, + * change Node_var_new to an array. + * If canfatal and type isn't good, die fatally, + * otherwise return the final actual value. + */ + +NODE * +get_actual(NODE *symbol, int canfatal) +{ + int isparam = (symbol->type == Node_param_list + && (symbol->flags & FUNC) == 0); + NODE *save_symbol = symbol; + + if (isparam) { + save_symbol = symbol = stack_ptr[symbol->param_cnt]; + if (symbol->type == Node_array_ref) + symbol = symbol->orig_array; + } + + switch (symbol->type) { + case Node_var_new: + symbol->type = Node_var_array; + symbol->var_array = NULL; + /* fall through */ + case Node_var_array: + break; + + case Node_array_ref: + case Node_param_list: + if (canfatal) + cant_happen(); + /* else + fall through */ + + default: + /* notably Node_var but catches also e.g. FS[1] = "x" */ + if (canfatal) + fatal(isparam ? + _("attempt to use scalar parameter `%s' as an array") : + _("attempt to use scalar `%s' as array"), + save_symbol->vname); + else + break; + } + + return symbol; +} + +/* + * array_vname --- print the name of the array + * + * Returns a pointer to a statically maintained dynamically allocated string. + * It's appropriate for printing the name once; if the caller wants + * to save it, they have to make a copy. + * + * Setting MAX_LEN to a positive value (eg. 140) would limit the length + * of the output to _roughly_ that length. + * + * If MAX_LEN == 0, which is the default, the whole stack is printed. + */ +#define MAX_LEN 0 + +char * +array_vname(register const NODE *symbol) +{ + if (symbol->type == Node_param_list) + symbol = stack_ptr[symbol->param_cnt]; + + if (symbol->type != Node_array_ref || symbol->orig_array->type != Node_var_array) + return symbol->vname; + else { + static char *message = NULL; + static size_t msglen = 0; + char *s; + size_t len; + int n; + const NODE *save_symbol = symbol; + const char *from = _("from %s"); + +#if (MAX_LEN <= 0) || !defined(HAVE_SNPRINTF) + /* This is the default branch. */ + + /* First, we have to compute the length of the string: */ + len = strlen(symbol->vname) + 2; /* "%s (" */ + n = 0; + do { + symbol = symbol->prev_array; + len += strlen(symbol->vname); + n++; + } while (symbol->type == Node_array_ref); + /* + * Each node contributes by strlen(from) minus the length + * of "%s" in the translation (which is at least 2) + * plus 2 for ", " or ")\0"; this adds up to strlen(from). + */ + len += n * strlen(from); + + /* (Re)allocate memory: */ + if (message == NULL) { + emalloc(message, char *, len, "array_vname"); + msglen = len; + } else if (len > msglen) { + erealloc(message, char *, len, "array_vname"); + msglen = len; + } /* else + current buffer can hold new name */ + + /* We're ready to print: */ + symbol = save_symbol; + s = message; + /* + * Ancient systems have sprintf() returning char *, not int. + * Thus, `s += sprintf(s, from, name);' is a no-no. + */ + sprintf(s, "%s (", symbol->vname); + s += strlen(s); + for (;;) { + symbol = symbol->prev_array; + sprintf(s, from, symbol->vname); + s += strlen(s); + if (symbol->type != Node_array_ref) + break; + sprintf(s, ", "); + s += strlen(s); + } + sprintf(s, ")"); + +#else /* MAX_LEN > 0 */ + + /* + * The following check fails only on + * abnormally_long_variable_name. + */ +#define PRINT_CHECK \ + if (n <= 0 || n >= len) \ + return save_symbol->vname; \ + s += n; len -= n +#define PRINT(str) \ + n = snprintf(s, len, str); \ + PRINT_CHECK +#define PRINT_vname(str) \ + n = snprintf(s, len, str, symbol->vname); \ + PRINT_CHECK + + if (message == NULL) + emalloc(message, char *, MAX_LEN, "array_vname"); + + s = message; + len = MAX_LEN; + + /* First, print the vname of the node. */ + PRINT_vname("%s ("); + + for (;;) { + symbol = symbol->prev_array; + /* + * When we don't have enough space and this is not + * the last node, shorten the list. + */ + if (len < 40 && symbol->type == Node_array_ref) { + PRINT("..., "); + symbol = symbol->orig_array; + } + PRINT_vname(from); + if (symbol->type != Node_array_ref) + break; + PRINT(", "); + } + PRINT(")"); + +#undef PRINT_CHECK +#undef PRINT +#undef PRINT_vname +#endif /* MAX_LEN <= 0 */ + + return message; + } +} +#undef MAX_LEN + /* concat_exp --- concatenate expression list into a single string */ NODE * @@ -266,14 +447,10 @@ register int hash1; NODE *ret; - if (symbol->type == Node_param_list) - symbol = stack_ptr[symbol->param_cnt]; - if (symbol->type == Node_array_ref) - symbol = symbol->orig_array; - if ((symbol->flags & SCALAR) != 0) - fatal(_("attempt to use scalar `%s' as array"), symbol->vname); + symbol = get_array(symbol); + /* - * evaluate subscript first, it could have side effects + * Evaluate subscript first, it could have side effects. */ subs = concat_exp(subs); /* concat_exp returns a string node */ if (symbol->var_array == NULL) { @@ -304,20 +481,11 @@ register int hash1; register NODE *bucket; - /* protect against silly users, e.g. FS[1] = "x" */ - if (symbol->type != Node_var_array && symbol->type != Node_var) - fatal(_("attempt to use scalar `%s' as array"), symbol->vname); + assert(symbol->type == Node_var_array); (void) force_string(subs); - if ((symbol->flags & SCALAR) != 0) - fatal(_("attempt to use scalar `%s' as array"), symbol->vname); - if (symbol->var_array == NULL) { - if (symbol->type != Node_var_array) { - unref(symbol->var_value); - symbol->type = Node_var_array; - } symbol->array_size = symbol->table_size = 0; /* sanity */ symbol->flags &= ~ARRAYMAXED; grow_table(symbol); @@ -336,13 +504,13 @@ if (do_lint && reference) { subs->stptr[subs->stlen] = '\0'; lintwarn(_("reference to uninitialized element `%s[\"%s\"]'"), - symbol->vname, subs->stptr); + array_vname(symbol), subs->stptr); } /* It's not there, install it. */ if (do_lint && subs->stlen == 0) lintwarn(_("subscript of array `%s' is null string"), - symbol->vname); + array_vname(symbol)); /* first see if we would need to grow the array, before installing */ symbol->table_size++; @@ -389,86 +557,63 @@ */ void -do_delete(NODE *symbol, NODE *tree) +do_delete(NODE *sym, NODE *tree) { register int hash1; register NODE *bucket, *last; NODE *subs; - - /* - * Evaluate subscript first, always, in case there are - * side effects. - */ - if (tree != NULL) - subs = concat_exp(tree); /* concat_exp returns string node */ - else - subs = NULL; - - if (symbol->type == Node_param_list) { - symbol = stack_ptr[symbol->param_cnt]; - if (symbol->type == Node_var) { - if (subs != NULL) { - if (do_lint) - lintwarn(_("delete: index `%s' not in array `%s'"), - subs->stptr, symbol->vname); - free_temp(subs); - } - return; - } - } - if (symbol->type == Node_array_ref) - symbol = symbol->orig_array; - if (symbol->type == Node_var_array) { - if (symbol->var_array == NULL) { - if (subs != NULL) { - if (do_lint) - lintwarn(_("delete: index `%s' not in array `%s'"), - subs->stptr, symbol->vname); - free_temp(subs); - } - return; - } - } else - fatal(_("delete: illegal use of variable `%s' as array"), - symbol->vname); + register NODE *symbol = get_array(sym); if (tree == NULL) { /* delete array */ assoc_clear(symbol); return; } - hash1 = hash(subs->stptr, subs->stlen, (unsigned long) symbol->array_size); + last = NULL; /* shut up gcc -Wall */ + hash1 = 0; /* ditto */ - last = NULL; - for (bucket = symbol->var_array[hash1]; bucket != NULL; - last = bucket, bucket = bucket->ahnext) { - /* - * This used to use cmp_nodes() here. That's wrong. - * Array indexes are strings; compare as such, always! - */ - const char *s1_str; - size_t s1_len; - NODE *s2; - - s1_str = bucket->ahname_str; - s1_len = bucket->ahname_len; - s2 = subs; + /* + * Always evaluate subscript, it could have side effects. + */ + subs = concat_exp(tree); /* concat_exp returns string node */ - if (s1_len == s2->stlen) { - if (s1_len == 0 /* "" is a valid index */ - || STREQN(s1_str, s2->stptr, s1_len)) - break; + if (symbol->var_array != NULL) { + hash1 = hash(subs->stptr, subs->stlen, + (unsigned long) symbol->array_size); + last = NULL; + for (bucket = symbol->var_array[hash1]; bucket != NULL; + last = bucket, bucket = bucket->ahnext) { + /* + * This used to use cmp_nodes() here. That's wrong. + * Array indexes are strings; compare as such, always! + */ + const char *s1_str; + size_t s1_len; + NODE *s2; + + s1_str = bucket->ahname_str; + s1_len = bucket->ahname_len; + s2 = subs; + + if (s1_len == s2->stlen) { + if (s1_len == 0 /* "" is a valid index */ + || STREQN(s1_str, s2->stptr, s1_len)) + break; + } } - } + } else + bucket = NULL; /* The array is empty. */ if (bucket == NULL) { if (do_lint) lintwarn(_("delete: index `%s' not in array `%s'"), - subs->stptr, symbol->vname); + subs->stptr, array_vname(sym)); free_temp(subs); return; } + free_temp(subs); + if (last != NULL) last->ahnext = bucket->ahnext; else @@ -501,19 +646,10 @@ NODE **lhs; Func_ptr after_assign = NULL; - if (symbol->type == Node_param_list) { - symbol = stack_ptr[symbol->param_cnt]; - if (symbol->type == Node_var) - return; - } - if (symbol->type == Node_array_ref) - symbol = symbol->orig_array; - if (symbol->type == Node_var_array) { - if (symbol->var_array == NULL) - return; - } else - fatal(_("delete: illegal use of variable `%s' as array"), - symbol->vname); + symbol = get_array(symbol); + + if (symbol->var_array == NULL) + return; /* get first index value */ for (i = 0; i < symbol->array_size; i++) { @@ -962,32 +1098,17 @@ static NODE * asort_actual(NODE *tree, ASORT_TYPE how) { - NODE *src, *dest; - - src = tree->lnode; - dest = NULL; - - if (src->type == Node_param_list) - src = stack_ptr[src->param_cnt]; - if (src->type == Node_array_ref) - src = src->orig_array; - if (src->type != Node_var_array) - fatal(_("asort: first argument is not an array")); + NODE *array = get_array(tree->lnode); if (tree->rnode != NULL) { /* 2nd optional arg */ - dest = tree->rnode->lnode; - if (dest->type == Node_param_list) - dest = stack_ptr[dest->param_cnt]; - if (dest->type == Node_array_ref) - dest = dest->orig_array; - if (dest->type != Node_var && dest->type != Node_var_array) - fatal(_("asort: second argument is not an array")); - dest->type = Node_var_array; + NODE *dest = get_array(tree->rnode->lnode); + assoc_clear(dest); - dup_table(src, dest); + dup_table(array, dest); + array = dest; } - return dest != NULL ? assoc_sort_inplace(dest, how) : assoc_sort_inplace(src, how); + return assoc_sort_inplace(array, how); } /* do_asort --- sort array by value */ diff -urN gawk-3.1.2/awk.h gawk-3.1.3/awk.h --- gawk-3.1.2/awk.h 2003-03-03 04:30:23.000000000 -0800 +++ gawk-3.1.3/awk.h 2003-06-29 05:52:40.000000000 -0700 @@ -256,6 +256,15 @@ #define __extension__ #endif +/* this is defined by Windows32 extension libraries. It must be added to + * every variable which is exported (including function pointers) */ +#if defined(WIN32_EXTENSION) && !defined(ATTRIBUTE_EXPORTED) +# define ATTRIBUTE_EXPORTED __declspec(dllimport) +#else +# define ATTRIBUTE_EXPORTED +#endif + + /* ------------------ Constants, Structures, Typedefs ------------------ */ #ifndef AWKNUM @@ -339,12 +348,17 @@ Node_rule_list, /* lnode is a rule, rnode is rest of list */ Node_rule_node, /* lnode is pattern, rnode is statement */ Node_statement_list, /* lnode is statement, rnode is more list */ + Node_switch_body, /* lnode is the case list, rnode is default list */ + Node_case_list, /* lnode is the case, rnode is a statement list */ Node_if_branches, /* lnode is to run on true, rnode on false */ Node_expression_list, /* lnode is an exp, rnode is more list */ Node_param_list, /* lnode is a variable, rnode is more list */ /* keywords */ Node_K_if, /* lnode is conditonal, rnode is if_branches */ + Node_K_switch, /* lnode is switch value, rnode is body of case statements */ + Node_K_case, /* lnode is case value, rnode is stuff to run */ + Node_K_default, /* lnode is empty, rnode is stuff to run */ Node_K_while, /* lnode is condtional, rnode is stuff to run */ Node_K_for, /* lnode is for_struct, rnode is stuff to run */ Node_K_arrayfor, /* lnode is for_struct, rnode is stuff to run */ @@ -372,8 +386,9 @@ Node_redirect_twoway, /* subnode is where to redirect */ /* Variables */ - Node_var, /* rnode is value, lnode is array stuff */ - Node_var_array, /* array is ptr to elements, asize num of eles */ + Node_var_new, /* newly created variable, may become an array */ + Node_var, /* scalar variable, lnode is value */ + Node_var_array, /* array is ptr to elements, table_size num of eles */ Node_val, /* node is a value - type in flags */ /* Builtins subnode is explist to work on, builtin is func to call */ @@ -490,12 +505,10 @@ # define MAYBE_NUM 128 /* user input: if NUMERIC then * a NUMBER */ # define ARRAYMAXED 256 /* array is at max size */ -# define SCALAR 512 /* used as scalar, can't be array */ -# define FUNC 1024 /* this parameter is really a - * function name; see awk.y */ -# define FIELD 2048 /* this is a field */ -# define INTLSTR 4096 /* use localized version */ -# define UNINITIALIZED 8192 /* value used before set */ +# define FUNC 512 /* this parameter is really a + * function name; see awkgram.y */ +# define FIELD 1024 /* this is a field */ +# define INTLSTR 2048 /* use localized version */ } NODE; #define vname sub.nodep.name @@ -529,12 +542,17 @@ #define numbr sub.val.fltnum +/* Node_var: */ #define var_value lnode + +/* Node_var_array: */ #define var_array sub.nodep.r.av #define array_size sub.nodep.l.ll #define table_size sub.nodep.x.xl +/* Node_array_ref: */ #define orig_array sub.nodep.x.extra +#define prev_array rnode #define printf_count sub.nodep.x.xl @@ -560,7 +578,6 @@ size_t readsize; /* set from fstat call */ size_t size; /* buffer size */ ssize_t count; /* amount read last time */ - size_t total; /* total num chars read */ size_t scanoff; /* where we were in the buffer when we had to regrow/refill */ int flag; @@ -649,7 +666,7 @@ extern int ORSlen; extern char *OFMT; extern char *CONVFMT; -extern int CONVFMTidx; +ATTRIBUTE_EXPORTED extern int CONVFMTidx; extern int OFMTidx; extern char *TEXTDOMAIN; extern NODE *BINMODE_node, *CONVFMT_node, *FIELDWIDTHS_node, *FILENAME_node; @@ -657,15 +674,21 @@ extern NODE *NR_node, *OFMT_node, *OFS_node, *ORS_node, *RLENGTH_node; extern NODE *RSTART_node, *RS_node, *RT_node, *SUBSEP_node, *PROCINFO_node; extern NODE *LINT_node, *ERRNO_node, *TEXTDOMAIN_node; -extern NODE **stack_ptr; +ATTRIBUTE_EXPORTED extern NODE **stack_ptr; extern NODE *Nnull_string; +extern NODE *Null_field; extern NODE **fields_arr; extern int sourceline; extern char *source; extern NODE *expression_value; #if __GNUC__ < 2 -extern NODE *_t; /* used as temporary in tree_eval */ +# if defined(WIN32_EXTENSION) +static +# else +extern +#endif +NODE *_t; /* used as temporary in tree_eval */ #endif extern NODE *nextfree; @@ -684,7 +707,7 @@ #define do_lint 0 #define do_lint_old 0 #else -extern int do_lint; +ATTRIBUTE_EXPORTED extern int do_lint; extern int do_lint_old; #endif #ifdef MBS_SUPPORT @@ -710,17 +733,19 @@ #define isnondecimal(str) (((str)[0]) == '0' && (ISDIGIT((str)[1]) \ || (str)[1] == 'x' || (str)[1] == 'X')) +#define var_uninitialized(n) ((n)->var_value == Nnull_string) + #ifdef MPROF -#define getnode(n) emalloc((n), NODE *, sizeof(NODE), "getnode"), (n)->flags = UNINITIALIZED, (n)-exec_count = 0; +#define getnode(n) emalloc((n), NODE *, sizeof(NODE), "getnode"), (n)->flags = 0, (n)-exec_count = 0; #define freenode(n) free(n) #else /* not MPROF */ #define getnode(n) if (nextfree) n = nextfree, nextfree = nextfree->nextp;\ else n = more_nodes() #ifndef NO_PROFILING -#define freenode(n) ((n)->flags = UNINITIALIZED,\ +#define freenode(n) ((n)->flags = 0,\ (n)->exec_count = 0, (n)->nextp = nextfree, nextfree = (n)) #else /* not PROFILING */ -#define freenode(n) ((n)->flags = UNINITIALIZED,\ +#define freenode(n) ((n)->flags = 0,\ (n)->nextp = nextfree, nextfree = (n)) #endif /* not PROFILING */ #endif /* not MPROF */ @@ -746,15 +771,19 @@ #define dupnode(n) r_dupnode(n) #endif /* GAWKDEBUG */ +#define get_array(t) get_actual(t, TRUE) /* allowed to die fatally */ +#define get_param(t) get_actual(t, FALSE) /* not allowed */ + #ifdef MEMDEBUG #undef freenode #define get_lhs(p, a, r) r_get_lhs((p), (a), (r)) #define m_tree_eval(t, iscond) r_tree_eval(t, iscond) #else #define get_lhs(p, a, r) ((p)->type == Node_var && \ - ((p)->flags & UNINITIALIZED) == 0 && (r) ? \ - (&(p)->var_value): \ + ! var_uninitialized(p) ? \ + (&(p)->var_value) : \ r_get_lhs((p), (a), (r))) +#define TREE_EVAL_MACRO 1 #if __GNUC__ >= 2 #define m_tree_eval(t, iscond) __extension__ \ ({NODE * _t = (t); \ @@ -767,7 +796,7 @@ _t = r_force_string(_t); \ break; \ case Node_var: \ - if ((_t->flags & UNINITIALIZED) == 0) { \ + if (! var_uninitialized(_t)) { \ _t = _t->var_value; \ break; \ } \ @@ -786,7 +815,7 @@ r_force_string(_t) : \ (_t->type == Node_val ? _t : \ (_t->type == Node_var && \ - (_t->flags & UNINITIALIZED) == 0 ? _t->var_value : \ + ! var_uninitialized(_t) ? _t->var_value : \ r_tree_eval(_t, iscond)))))) #endif /* __GNUC__ */ #endif /* not MEMDEBUG */ @@ -867,6 +896,8 @@ /* ------------- Function prototypes or defs (as appropriate) ------------- */ /* array.c */ +extern NODE *get_actual P((NODE *symbol, int canfatal)); +extern char *array_vname P((const NODE *symbol)); extern void array_init P((void)); extern NODE *concat_exp P((NODE *tree)); extern void assoc_clear P((NODE *symbol)); @@ -991,6 +1022,12 @@ extern size_t optimal_bufsize P((int fd, struct stat *sbuf)); extern int ispath P((const char *file)); extern int isdirpunct P((int c)); +#if defined(_MSC_VER) && !defined(_WIN32) +extern char *memcpy_ulong P((char *dest, const char *src, unsigned long l)); +extern void *memset_ulong P((void *dest, int val, unsigned long l)); +#define memcpy memcpy_ulong +#define memset memset_ulong +#endif /* io.c */ extern void set_FNR P((void)); extern void set_NR P((void)); @@ -1025,6 +1062,7 @@ extern void warning (const char *mesg, ...) ATTRIBUTE_PRINTF_1; extern void set_loc (const char *file, int line); extern void r_fatal (const char *mesg, ...) ATTRIBUTE_PRINTF_1 ATTRIBUTE_NORETURN; +ATTRIBUTE_EXPORTED #if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 2) extern void (*lintfunc) (const char *mesg, ...) ATTRIBUTE_PRINTF_1; #else diff -urN gawk-3.1.2/awkgram.y gawk-3.1.3/awkgram.y --- gawk-3.1.2/awkgram.y 2003-03-19 04:06:57.000000000 -0800 +++ gawk-3.1.3/awkgram.y 2003-07-04 10:25:23.000000000 -0700 @@ -58,6 +58,7 @@ static void dumpintlstr P((const char *str, size_t len)); static void dumpintlstr2 P((const char *str1, size_t len1, const char *str2, size_t len2)); static void count_args P((NODE *n)); +static int isarray P((NODE *n)); enum defref { FUNC_DEFINE, FUNC_USE }; static void func_use P((const char *name, enum defref how)); @@ -119,7 +120,7 @@ %type exp common_exp %type simp_exp non_post_simp_exp %type expression_list opt_expression_list print_expression_list -%type statements statement if_statement opt_param_list +%type statements statement if_statement switch_body case_statements case_statement case_value opt_param_list %type simple_stmt opt_simple_stmt %type opt_exp opt_variable regexp %type input_redir output_redir @@ -134,7 +135,7 @@ %token RELOP IO_OUT IO_IN %token ASSIGNOP ASSIGN MATCHOP CONCAT_OP %token LEX_BEGIN LEX_END LEX_IF LEX_ELSE LEX_RETURN LEX_DELETE -%token LEX_WHILE LEX_DO LEX_FOR LEX_BREAK LEX_CONTINUE +%token LEX_SWITCH LEX_CASE LEX_DEFAULT LEX_WHILE LEX_DO LEX_FOR LEX_BREAK LEX_CONTINUE %token LEX_PRINT LEX_PRINTF LEX_NEXT LEX_EXIT LEX_FUNCTION %token LEX_GETLINE LEX_NEXTFILE %token LEX_IN @@ -183,12 +184,11 @@ | program error { begin_or_end_rule = parsing_end_rule = FALSE; - yyerrok; /* * If errors, give up, don't produce an infinite - * stream of syntax error message. + * stream of syntax error messages. */ - return; + /* yyerrok; */ } ; @@ -365,6 +365,8 @@ { $$ = $2; } | if_statement { $$ = $1; } + | LEX_SWITCH '(' exp r_paren opt_nls l_brace switch_body opt_nls r_brace + { $$ = node($3, Node_K_switch, $7); } | LEX_WHILE '(' exp r_paren opt_nls statement { $$ = node($3, Node_K_while, $6); } | LEX_DO opt_nls statement LEX_WHILE '(' exp r_paren opt_nls @@ -391,10 +393,12 @@ arr = $8->lnode; /* array var */ sub = $8->rnode->lnode; /* index var */ - if ( (arr->type == Node_var + if ( (arr->type == Node_var_new || arr->type == Node_var_array || arr->type == Node_param_list) - && (sub->type == Node_var || sub->type == Node_param_list) + && (sub->type == Node_var_new + || sub->type == Node_var + || sub->type == Node_param_list) && strcmp($3, sub->vname) == 0 && strcmp($5, arr->vname) == 0) { $8->type = Node_K_delete_loop; @@ -547,6 +551,105 @@ { $$ = $1; } ; +switch_body + : case_statements + { + if ($1 == NULL) { + $$ = NULL; + } else { + NODE *dflt = NULL; + NODE *head = $1; + NODE *curr; + + const char **case_values = NULL; + + int maxcount = 128; + int case_count = 0; + int i; + + emalloc(case_values, const char **, sizeof(char*) * maxcount, "switch_body"); + for (curr = $1; curr != NULL; curr = curr->rnode) { + /* Assure that case statement values are unique. */ + if (curr->lnode->type == Node_K_case) { + char *caseval; + + if (curr->lnode->lnode->type == Node_regex) + caseval = curr->lnode->lnode->re_exp->stptr; + else + caseval = force_string(tree_eval(curr->lnode->lnode))->stptr; + + for (i = 0; i < case_count; i++) + if (strcmp(caseval, case_values[i]) == 0) + yyerror(_("duplicate case values in switch body: %s"), caseval); + + if (case_count >= maxcount) { + maxcount += 128; + erealloc(case_values, const char **, sizeof(char*) * maxcount, "switch_body"); + } + case_values[case_count++] = caseval; + } else { + /* Otherwise save a pointer to the default node. */ + if (dflt != NULL) + yyerror(_("Duplicate `default' detected in switch body")); + dflt = curr; + } + } + + free(case_values); + + /* Create the switch body. */ + $$ = node(head, Node_switch_body, dflt); + } + } + ; + +case_statements + : /* empty */ + { $$ = NULL; } + | case_statements case_statement + { + if ($2 == NULL) + $$ = $1; + else { + if (do_lint && isnoeffect($2->type)) + lintwarn(_("statement may have no effect")); + if ($1 == NULL) + $$ = node($2, Node_case_list, (NODE *) NULL); + else + $$ = append_right( + ($1->type == Node_case_list ? $1 : node($1, Node_case_list, (NODE *) NULL)), + ($2->type == Node_case_list ? $2 : node($2, Node_case_list, (NODE *) NULL)) + ); + } + yyerrok; + } + | case_statements error + { $$ = NULL; } + ; + +case_statement + : LEX_CASE case_value colon opt_nls statements + { $$ = node($2, Node_K_case, $5); } + | LEX_DEFAULT colon opt_nls statements + { $$ = node((NODE *) NULL, Node_K_default, $4); } + ; + +case_value + : YNUMBER + { $$ = $1; } + | '-' YNUMBER %prec UNARY + { + $2->numbr = -(force_number($2)); + $$ = $2; + } + | '+' YNUMBER %prec UNARY + { $$ = $2; } + | YSTRING + { $$ = $1; } + | regexp + { $$ = $1; } + ; + print : LEX_PRINT | LEX_PRINTF @@ -828,17 +931,21 @@ variable : NAME - { $$ = variable($1, CAN_FREE, Node_var); } + { $$ = variable($1, CAN_FREE, Node_var_new); } | NAME '[' expression_list ']' - { - if ($3 == NULL) { + { + NODE *n; + + if ((n = lookup($1)) != NULL && ! isarray(n)) + yyerror(_("use of non-array as array")); + else if ($3 == NULL) { fatal(_("invalid subscript expression")); } else if ($3->rnode == NULL) { $$ = node(variable($1, CAN_FREE, Node_var_array), Node_subscript, $3->lnode); freenode($3); } else $$ = node(variable($1, CAN_FREE, Node_var_array), Node_subscript, $3); - } + } | '$' non_post_simp_exp { $$ = node($2, Node_field_spec, (NODE *) NULL); } ; @@ -864,6 +971,10 @@ : ';' { yyerrok; } ; +colon + : ':' { yyerrok; } + ; + comma : ',' opt_nls { yyerrok; } ; @@ -899,12 +1010,18 @@ {"atan2", Node_builtin, LEX_BUILTIN, NOT_OLD|A(2), do_atan2}, {"bindtextdomain", Node_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2), do_bindtextdomain}, {"break", Node_K_break, LEX_BREAK, 0, 0}, +#ifdef ALLOW_SWITCH +{"case", Node_K_case, LEX_CASE, GAWKX, 0}, +#endif {"close", Node_builtin, LEX_BUILTIN, NOT_OLD|A(1)|A(2), do_close}, {"compl", Node_builtin, LEX_BUILTIN, GAWKX|A(1), do_compl}, {"continue", Node_K_continue, LEX_CONTINUE, 0, 0}, {"cos", Node_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_cos}, {"dcgettext", Node_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3), do_dcgettext}, {"dcngettext", Node_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3)|A(4)|A(5), do_dcngettext}, +#ifdef ALLOW_SWITCH +{"default", Node_K_default, LEX_DEFAULT, GAWKX, 0}, +#endif {"delete", Node_K_delete, LEX_DELETE, NOT_OLD, 0}, {"do", Node_K_do, LEX_DO, NOT_OLD, 0}, {"else", Node_illegal, LEX_ELSE, 0, 0}, @@ -947,6 +1064,9 @@ {"strtonum", Node_builtin, LEX_BUILTIN, GAWKX|A(1), do_strtonum}, {"sub", Node_builtin, LEX_BUILTIN, NOT_OLD|A(2)|A(3), do_sub}, {"substr", Node_builtin, LEX_BUILTIN, A(2)|A(3), do_substr}, +#ifdef ALLOW_SWITCH +{"switch", Node_K_switch, LEX_SWITCH, GAWKX, 0}, +#endif {"system", Node_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_system}, {"systime", Node_builtin, LEX_BUILTIN, GAWKX|A(0), do_systime}, {"tolower", Node_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_tolower}, @@ -1479,7 +1599,7 @@ case '\\': if ((c = nextc()) == EOF) { yyerror(_("unterminated regexp ends with `\\' at end of file")); - return lasttok = REGEXP; /* kludge */ + goto end_regexp; /* kludge */ } else if (c == '\n') { sourceline++; continue; @@ -1492,17 +1612,17 @@ case '/': /* end of the regexp */ if (in_brack > 0) break; - +end_regexp: tokadd('\0'); yylval.sval = tokstart; return lasttok = REGEXP; case '\n': pushback(); yyerror(_("unterminated regexp")); - return lasttok = REGEXP; /* kludge */ + goto end_regexp; /* kludge */ case EOF: yyerror(_("unterminated regexp at end of file")); - return lasttok = REGEXP; /* kludge */ + goto end_regexp; /* kludge */ } tokadd(c); } @@ -2051,8 +2171,6 @@ getnode(r); r->type = op; r->flags = MALLOC; - if (r->type == Node_var) - r->flags |= UNINITIALIZED; /* if lookahead is NL, lineno is 1 too high */ if (lexeme && *lexeme == '\n') r->source_line = sourceline - 1; @@ -2182,7 +2300,7 @@ else dumpintlstr(str->stptr, str->stlen); } else if (do_intl /* --gen-po */ - && r->builtin == do_dcngettext /* dcngettext(...) */ + && r->builtin == do_dcngettext /* dcngettext(...) */ && subn->lnode->type == Node_val /* 1st arg is constant */ && (subn->lnode->flags & STRCUR) != 0 /* it's a string constant */ && subn->rnode->lnode->type == Node_val /* 2nd arg is constant too */ @@ -2429,6 +2547,8 @@ fprintf(fp, "%.*s: ", (int) p->hlength, p->hname); if (p->hvalue->type == Node_var_array) fprintf(fp, "array, %ld elements\n", p->hvalue->table_size); + else if (p->hvalue->type == Node_var_new) + fprintf(fp, "unused variable\n"); else if (p->hvalue->type == Node_var) valinfo(p->hvalue->var_value, fp); else { @@ -2460,12 +2580,10 @@ continue; else if (p->hvalue->type == Node_var_array) assoc_clear(p->hvalue); - else if (p->hvalue->type == Node_var) - unref(p->hvalue->var_value); - else { + else if (p->hvalue->type != Node_var_new) { NODE **lhs = get_lhs(p->hvalue, NULL, FALSE); - unref((*lhs)->var_value); + unref(*lhs); } unref(p); } @@ -2609,11 +2727,11 @@ return list; oldlist = list; - if (savefront == oldlist) { - savetail = savetail->rnode = new; - return oldlist; - } else + if (savefront == oldlist) + list = savetail; /* Be careful: maybe list->rnode != NULL */ + else savefront = oldlist; + while (list->rnode != NULL) list = list->rnode; savetail = list->rnode = new; @@ -2886,7 +3004,14 @@ /* * This is the only case in which we may not free the string. */ - return install(name, node(Nnull_string, type, (NODE *) NULL)); + NODE *n; + + if (type == Node_var) + n = node(Nnull_string, type, (NODE *) NULL); + else + n = node((NODE *) NULL, type, (NODE *) NULL); + + return install(name, n); } } if (can_free) @@ -2962,6 +3087,7 @@ case Node_CONVFMT: case Node_BINMODE: case Node_LINT: + case Node_TEXTDOMAIN: return TRUE; default: break; /* keeps gcc -Wall happy */ @@ -2976,6 +3102,7 @@ isassignable(register NODE *n) { switch (n->type) { + case Node_var_new: case Node_var: case Node_FIELDWIDTHS: case Node_RS: @@ -2990,6 +3117,7 @@ case Node_OFS: case Node_LINT: case Node_BINMODE: + case Node_TEXTDOMAIN: case Node_field_spec: case Node_subscript: return TRUE; @@ -3077,3 +3205,24 @@ save_tree->printf_count = count; } + +/* isarray --- can this type be subscripted? */ + +static int +isarray(NODE *n) +{ + switch (n->type) { + case Node_var_new: + case Node_var_array: + return TRUE; + case Node_param_list: + return ((n->flags & FUNC) == 0); + case Node_array_ref: + cant_happen(); + break; + default: + break; /* keeps gcc -Wall happy */ + } + + return FALSE; +} diff -urN gawk-3.1.2/awklib/ChangeLog gawk-3.1.3/awklib/ChangeLog --- gawk-3.1.2/awklib/ChangeLog 2003-03-19 04:24:06.000000000 -0800 +++ gawk-3.1.3/awklib/ChangeLog 2003-07-07 11:02:03.000000000 -0700 @@ -1,3 +1,7 @@ +Mon Jul 7 11:01:43 2003 Arnold D. Robbins + + * Release 3.1.3: Release tar file made. + Wed Mar 19 14:10:31 2003 Arnold D. Robbins This time for sure. diff -urN gawk-3.1.2/awklib/Makefile.in gawk-3.1.3/awklib/Makefile.in --- gawk-3.1.2/awklib/Makefile.in 2003-03-16 02:26:02.000000000 -0800 +++ gawk-3.1.3/awklib/Makefile.in 2003-07-04 10:50:29.000000000 -0700 @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.7.3 from Makefile.am. +# Makefile.in generated by automake 1.7.5 from Makefile.am. # @configure_input@ # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 @@ -178,6 +178,7 @@ nodist_grcat_SOURCES = grcat.c nodist_pwcat_SOURCES = pwcat.c subdir = awklib +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = @@ -213,7 +214,7 @@ .SUFFIXES: .SUFFIXES: .c .o .obj -$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) +$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && \ $(AUTOMAKE) --gnu awklib/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @@ -278,7 +279,7 @@ .c.o: @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" \ @am__fastdepCC_TRUE@ -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$<; \ -@am__fastdepCC_TRUE@ then mv "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \ +@am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \ @am__fastdepCC_TRUE@ else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; \ @am__fastdepCC_TRUE@ fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @@ -289,7 +290,7 @@ .c.obj: @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" \ @am__fastdepCC_TRUE@ -c -o $@ `if test -f '$<'; then $(CYGPATH_W) '$<'; else $(CYGPATH_W) '$(srcdir)/$<'; fi`; \ -@am__fastdepCC_TRUE@ then mv "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \ +@am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \ @am__fastdepCC_TRUE@ else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; \ @am__fastdepCC_TRUE@ fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @@ -389,7 +390,6 @@ installdirs: $(mkinstalldirs) $(DESTDIR)$(libexecdir) $(DESTDIR)$(bindir) - install: install-am install-exec: install-exec-am install-data: install-data-am diff -urN gawk-3.1.2/awklib/eg/lib/grcat.c gawk-3.1.3/awklib/eg/lib/grcat.c --- gawk-3.1.2/awklib/eg/lib/grcat.c 2003-03-19 03:55:32.000000000 -0800 +++ gawk-3.1.3/awklib/eg/lib/grcat.c 2003-07-04 10:50:30.000000000 -0700 @@ -12,7 +12,7 @@ #if HAVE_CONFIG_H #include #endif - + #if defined (STDC_HEADERS) #include #endif diff -urN gawk-3.1.2/awklib/eg/lib/zerofile.awk gawk-3.1.3/awklib/eg/lib/zerofile.awk --- gawk-3.1.2/awklib/eg/lib/zerofile.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/awklib/eg/lib/zerofile.awk 2003-07-04 10:50:30.000000000 -0700 @@ -0,0 +1,19 @@ +# zerofile.awk --- library file to process empty input files +# +# Arnold Robbins, arnold@gnu.org, Public Domain +# June 2003 + +BEGIN { Argind = 0 } + +ARGIND > Argind + 1 { + for (Argind++; Argind < ARGIND; Argind++) + zerofile(ARGV[Argind], Argind) +} + +ARGIND != Argind { Argind = ARGIND } + +END { + if (ARGIND > Argind) + for (Argind++; Argind <= ARGIND; Argind++) + zerofile(ARGV[Argind], Argind) +} diff -urN gawk-3.1.2/awklib/eg/network/coreserv.awk gawk-3.1.3/awklib/eg/network/coreserv.awk --- gawk-3.1.2/awklib/eg/network/coreserv.awk 2003-03-19 03:55:32.000000000 -0800 +++ gawk-3.1.3/awklib/eg/network/coreserv.awk 2003-07-04 10:50:30.000000000 -0700 @@ -46,7 +46,7 @@ print "Content-length:", len |& HttpService print ORS Prompt |& HttpService # ignore all the header lines - while ((HttpService |& getline) > 0) + while ((HttpService |& getline) > 0) continue # stop talking to this client close(HttpService) @@ -75,7 +75,7 @@ PARAM[i] = _CGI_decode(PARAM[i]) j = index(PARAM[i], "=") GETARG[substr(PARAM[i], 1, j-1)] = \ - substr(PARAM[i], j+1) + substr(PARAM[i], j+1) } } else { # there is no "?", no need for splitting PARAMs split(uri, MENU, "[/:]") diff -urN gawk-3.1.2/awklib/eg/network/eliza.awk gawk-3.1.3/awklib/eg/network/eliza.awk --- gawk-3.1.2/awklib/eg/network/eliza.awk 2003-03-19 03:55:32.000000000 -0800 +++ gawk-3.1.3/awklib/eg/network/eliza.awk 2003-07-04 10:50:30.000000000 -0700 @@ -72,7 +72,7 @@ if (w == "-") { # no keyword, take old subject w = wold subj = subjold - } else { # find subject + } else { # find subject subj = substr(q, index(q, w) + length(w)+1) wold = w subjold = subj # remember keyword and subject @@ -228,7 +228,7 @@ r[117] = "WHAT'S ABOUT ME ?" r[118] = "WHY DO YOU ALWAYS BRING UP MY NAME ?" # table for looking up answers that - # fit to a certain keyword + # fit to a certain keyword k["CAN YOU"] = "1 2 3" k["CAN I"] = "4 5" k["YOU ARE"] =\ diff -urN gawk-3.1.2/awklib/eg/network/protbase.awk gawk-3.1.3/awklib/eg/network/protbase.awk --- gawk-3.1.2/awklib/eg/network/protbase.awk 2003-03-19 03:55:33.000000000 -0800 +++ gawk-3.1.3/awklib/eg/network/protbase.awk 2003-07-04 10:50:30.000000000 -0700 @@ -4,7 +4,7 @@ BLASTService = "/inet/tcp/0/www.ncbi.nlm.nih.gov/80" printf "POST /cgi-bin/BLAST/nph-blast_report HTTP/1.0\n" |& BLASTService printf "Content-Length: " length(request) "\n\n" |& BLASTService - printf request |& BLASTService + printf request |& BLASTService while ((BLASTService |& getline) > 0) print $0 close(BLASTService) diff -urN gawk-3.1.2/awklib/eg/network/remconf.awk gawk-3.1.3/awklib/eg/network/remconf.awk --- gawk-3.1.2/awklib/eg/network/remconf.awk 2003-03-19 03:55:32.000000000 -0800 +++ gawk-3.1.3/awklib/eg/network/remconf.awk 2003-07-04 10:50:30.000000000 -0700 @@ -35,7 +35,7 @@ config[GETARG["Param"]] = GETARG["Value"] Document = (GETARG["Param"] " = " GETARG["Value"] ".") } else { - Document = "Parameter " GETARG["Param"] " is invalid." + Document = "Parameter " GETARG["Param"] " is invalid." } } else { Document = "

Change one parameter

\ diff -urN gawk-3.1.2/awklib/eg/network/statist.awk gawk-3.1.3/awklib/eg/network/statist.awk --- gawk-3.1.2/awklib/eg/network/statist.awk 2003-03-19 03:55:32.000000000 -0800 +++ gawk-3.1.3/awklib/eg/network/statist.awk 2003-07-04 10:50:30.000000000 -0700 @@ -73,9 +73,9 @@ \ 2. Count \ - \ + \

" - } else if (MENU[2] ~ "Image") { + } else if (MENU[2] ~ "Image") { Reason = "OK" ORS "Content-type: image/png" #Reason = "OK" ORS "Content-type: application/x-postscript" #Reason = "OK" ORS "Content-type: image/gif" diff -urN gawk-3.1.2/awklib/eg/network/stoxpred.awk gawk-3.1.3/awklib/eg/network/stoxpred.awk --- gawk-3.1.2/awklib/eg/network/stoxpred.awk 2003-03-19 03:55:33.000000000 -0800 +++ gawk-3.1.3/awklib/eg/network/stoxpred.awk 2003-07-04 10:50:30.000000000 -0700 @@ -38,15 +38,15 @@ for (stock = 1; stock <= StockCount; stock++) { if (data[1, stock] > data[2, stock]) { predict[stock] = "up" - } else if (data[1, stock] < data[2, stock]) { - predict[stock] = "down" + } else if (data[1, stock] < data[2, stock]) { + predict[stock] = "down" } else { predict[stock] = "neutral" } if ((data[1, stock] > data[2, stock]) && (data[2, stock] > data[3, stock])) hot[stock] = 1 if ((data[1, stock] < data[2, stock]) && (data[2, stock] < data[3, stock])) - avoid[stock] = 1 + avoid[stock] = 1 } # Do a plausibility check: how many predictions proved correct? for (s = 1; s <= StockCount; s++) { @@ -57,20 +57,20 @@ DownCount++ } else { NeutralCount++ - } + } if (((data[d, s] > data[d+1, s]) && (data[d+1, s] > data[d+2, s])) || ((data[d, s] < data[d+1, s]) && (data[d+1, s] < data[d+2, s])) || ((data[d, s] == data[d+1, s]) && (data[d+1, s] == data[d+2, s]))) CorrectCount++ - } - } + } + } } function Report() { # Generate report report = "\nThis is your daily " report = report "stock market report for "strftime("%A, %B %d, %Y")".\n" report = report "Here are the predictions for today:\n\n" - for (stock = 1; stock <= StockCount; stock++) + for (stock = 1; stock <= StockCount; stock++) report = report "\t" name[stock] "\t" predict[stock] "\n" for (stock in hot) { if (HotCount++ == 0) @@ -83,7 +83,7 @@ report = report "\nThe stock shares to avoid today are these:\n\n" report = report "\t" name[stock] "\t\thttp://biz.yahoo.com/n/" \ tolower(substr(name[stock], 1, 1)) "/" tolower(name[stock]) ".html\n" - } + } report = report "\nThis sums up to " HotCount+0 " winners and " AvoidCount+0 report = report " losers. When using this kind\nof prediction scheme for" report = report " the 12 months which lie behind us,\nwe get " UpCount @@ -97,8 +97,8 @@ report = report "market, this report is, of course, complete nonsense.\n" report = report "If you are stupid enough to believe these predictions\n" report = report "you should visit a doctor who can treat your ailment." -} -function SendMail() { +} +function SendMail() { # send report to customers customer["uncle.scrooge@ducktown.gov"] = "Uncle Scrooge" customer["more@utopia.org" ] = "Sir Thomas More" @@ -113,4 +113,4 @@ print report "\n.\n" | MailPipe close(MailPipe) } -} +} diff -urN gawk-3.1.2/builtin.c gawk-3.1.3/builtin.c --- gawk-3.1.2/builtin.c 2003-02-28 01:04:08.000000000 -0800 +++ gawk-3.1.3/builtin.c 2003-07-06 15:08:08.000000000 -0700 @@ -31,9 +31,35 @@ #undef HUGE #undef CHARBITS #undef INTBITS +#if HAVE_INTTYPES_H +# include +#else +# if HAVE_STDINT_H +# include +# endif +#endif #include #include "random.h" +#ifndef CHAR_BIT +# define CHAR_BIT 8 +#endif + +/* The extra casts work around common compiler bugs. */ +#define TYPE_SIGNED(t) (! ((t) 0 < (t) -1)) +/* The outer cast is needed to work around a bug in Cray C 5.0.3.0. + It is necessary at least when t == time_t. */ +#define TYPE_MINIMUM(t) ((t) (TYPE_SIGNED (t) \ + ? ~ (t) 0 << (sizeof (t) * CHAR_BIT - 1) : (t) 0)) +#define TYPE_MAXIMUM(t) ((t) (~ (t) 0 - TYPE_MINIMUM (t))) + +#ifndef INTMAX_MIN +# define INTMAX_MIN TYPE_MINIMUM (intmax_t) +#endif +#ifndef UINTMAX_MAX +# define UINTMAX_MAX TYPE_MAXIMUM (uintmax_t) +#endif + #ifndef SIZE_MAX /* C99 constant, can't rely on it everywhere */ #define SIZE_MAX ((size_t) -1) #endif @@ -528,7 +554,7 @@ #ifdef sun386 /* Can't cast unsigned (int/long) from ptr->value */ long tmp_uval; /* on 386i 4.0.1 C compiler -- it just hangs */ #endif - unsigned long uval; + uintmax_t uval; int sgn; int base = 0; char cpbuf[30]; /* if we have numbers bigger than 30 */ @@ -843,17 +869,20 @@ tmp_uval = arg->numbr; uval = (unsigned long) tmp_uval; #else - uval = (unsigned long) arg->numbr; + uval = (uintmax_t) arg->numbr; #endif cpbuf[0] = uval; prec = 1; cp = cpbuf; goto pr_tail; } - if (have_prec == FALSE) - prec = 1; - else if (prec > arg->stlen) - prec = arg->stlen; + /* + * As per POSIX, only output first character of a + * string value. Thus, we ignore any provided + * precision, forcing it to 1. (Didn't this + * used to work? 6/2003.) + */ + prec = 1; cp = arg->stptr; goto pr_tail; case 's': @@ -880,17 +909,16 @@ goto pr_tail; if (tmpval < 0) { - if (tmpval < LONG_MIN) + if (tmpval < INTMAX_MIN) goto out_of_range; sgn = TRUE; - uval = - (unsigned long) (long) tmpval; + uval = - (uintmax_t) (intmax_t) tmpval; } else { - /* Use !, so that NaNs are out of range. - The cast avoids a SunOS 4.1.x cc bug. */ - if (! (tmpval <= (unsigned long) ULONG_MAX)) + /* Use !, so that NaNs are out of range. */ + if (! (tmpval <= UINTMAX_MAX)) goto out_of_range; sgn = FALSE; - uval = (unsigned long) tmpval; + uval = (uintmax_t) tmpval; } do { *--cp = (char) ('0' + uval % 10); @@ -958,15 +986,14 @@ goto pr_tail; if (tmpval < 0) { - if (tmpval < LONG_MIN) + if (tmpval < INTMAX_MIN) goto out_of_range; - uval = (unsigned long) (long) tmpval; + uval = (uintmax_t) (intmax_t) tmpval; } else { - /* Use !, so that NaNs are out of range. - The cast avoids a SunOS 4.1.x cc bug. */ - if (! (tmpval <= (unsigned long) ULONG_MAX)) + /* Use !, so that NaNs are out of range. */ + if (! (tmpval <= UINTMAX_MAX)) goto out_of_range; - uval = (unsigned long) tmpval; + uval = (uintmax_t) tmpval; } /* * When to fill with zeroes is of course not simple. @@ -1024,6 +1051,9 @@ out_of_range: /* out of range - emergency use of %g format */ + if (do_lint) + lintwarn(_("[s]printf: value %g is out of range for `%%%c' format"), + tmpval, cs1); cs1 = 'g'; goto format_float; @@ -1202,7 +1232,8 @@ d_index = force_number(t2); free_temp(t2); - if (d_index < 1.0) { + /* the weird `! (foo)' tests help catch NaN values. */ + if (! (d_index >= 1)) { if (do_lint) lintwarn(_("substr: start index %g is invalid, using 1"), d_index); @@ -1226,11 +1257,11 @@ t3 = tree_eval(tree->rnode->rnode->lnode); d_length = force_number(t3); free_temp(t3); - if (d_length <= 0.0) { + if (! (d_length >= 1)) { if (do_lint == LINT_ALL) - lintwarn(_("substr: length %g is <= 0"), d_length); - else if (do_lint == LINT_INVALID && d_length < 0) - lintwarn(_("substr: length %g is < 0"), d_length); + lintwarn(_("substr: length %g is not >= 1"), d_length); + else if (do_lint == LINT_INVALID && ! (d_length >= 0)) + lintwarn(_("substr: length %g is not >= 0"), d_length); free_temp(t1); return Nnull_string; } @@ -1245,7 +1276,7 @@ _("substr: length %g too big for string indexing, truncating to %g"), d_length, (double) SIZE_MAX); } - if (d_length <= SIZE_MAX) + if (d_length < SIZE_MAX) length = d_length; else length = SIZE_MAX; @@ -1545,6 +1576,10 @@ (void) get_field(0L, NULL); /* rebuild record */ f0 = fields_arr[0]; + + if (do_lint && f0 == Nnull_string) + lintwarn(_("reference to uninitialized field `$%d'"), 0); + efwrite(f0->stptr, sizeof(char), f0->stlen, fp, "print", rp, FALSE); if (ORSlen > 0) @@ -1721,7 +1756,12 @@ srandom(1); firstrand = FALSE; } - return tmp_number((AWKNUM) random() / GAWK_RANDOM_MAX); + /* + * Per historical practice and POSIX, return value N is + * + * 0 <= n < 1 + */ + return tmp_number((AWKNUM) (random() % GAWK_RANDOM_MAX) / GAWK_RANDOM_MAX); } /* do_srand --- seed the random number generator */ @@ -1777,15 +1817,11 @@ rp = re_update(tree->lnode); dest = NULL; - if (tree->rnode != NULL) { /* 3rd optional arg for the subpatterns */ - dest = tree->rnode->lnode; - if (dest->type == Node_param_list) - dest = stack_ptr[dest->param_cnt]; - if (dest->type == Node_array_ref) - dest = dest->orig_array; - if (dest->type != Node_var && dest->type != Node_var_array) + if (tree->rnode != NULL) { /* 3rd optional arg for the subpatterns */ + dest = get_param(tree->rnode->lnode); + if (dest->type != Node_var_array) fatal(_("match: third argument is not an array")); - dest->type = Node_var_array; + assoc_clear(dest); } @@ -1799,44 +1835,49 @@ subsepstr = SUBSEP_node->var_value->stptr; subseplen = SUBSEP_node->var_value->stlen; - for (ii = 0; ii < NUMSUBPATS(rp, t1->stptr) - && (s = SUBPATSTART(rp, t1->stptr, ii)) != -1; ii++) { - start = t1->stptr + s; - len = SUBPATEND(rp, t1->stptr, ii) - s; - - it = make_string(start, len); + for (ii = 0; ii < NUMSUBPATS(rp, t1->stptr); ii++) { /* - * assoc_lookup() does free_temp() on 2nd arg. + * Loop over all the subpats; some of them may have + * matched even if all of them did not. */ - *assoc_lookup(dest, tmp_number((AWKNUM) (ii)), FALSE) = it; - - sprintf(buff, "%d", ii); - ilen = strlen(buff); - amt = ilen + subseplen + strlen("length") + 2; - - if (oldamt == 0) { - emalloc(buf, char *, amt, "do_match"); - } else if (amt > oldamt) { - erealloc(buf, char *, amt, "do_match"); + if ((s = SUBPATSTART(rp, t1->stptr, ii)) != -1) { + start = t1->stptr + s; + len = SUBPATEND(rp, t1->stptr, ii) - s; + + it = make_string(start, len); + /* + * assoc_lookup() does free_temp() on 2nd arg. + */ + *assoc_lookup(dest, tmp_number((AWKNUM) (ii)), FALSE) = it; + + sprintf(buff, "%d", ii); + ilen = strlen(buff); + amt = ilen + subseplen + strlen("length") + 2; + + if (oldamt == 0) { + emalloc(buf, char *, amt, "do_match"); + } else if (amt > oldamt) { + erealloc(buf, char *, amt, "do_match"); + } + oldamt = amt; + memcpy(buf, buff, ilen); + memcpy(buf + ilen, subsepstr, subseplen); + memcpy(buf + ilen + subseplen, "start", 6); + + slen = ilen + subseplen + 5; + + it = make_number((AWKNUM) s + 1); + *assoc_lookup(dest, tmp_string(buf, slen), FALSE) = it; + + memcpy(buf, buff, ilen); + memcpy(buf + ilen, subsepstr, subseplen); + memcpy(buf + ilen + subseplen, "length", 7); + + slen = ilen + subseplen + 6; + + it = make_number((AWKNUM) len); + *assoc_lookup(dest, tmp_string(buf, slen), FALSE) = it; } - oldamt = amt; - memcpy(buf, buff, ilen); - memcpy(buf + ilen, subsepstr, subseplen); - memcpy(buf + ilen + subseplen, "start", 6); - - slen = ilen + subseplen + 5; - - it = make_number((AWKNUM) s + 1); - *assoc_lookup(dest, tmp_string(buf, slen), FALSE) = it; - - memcpy(buf, buff, ilen); - memcpy(buf + ilen, subsepstr, subseplen); - memcpy(buf + ilen + subseplen, "length", 7); - - slen = ilen + subseplen + 6; - - it = make_number((AWKNUM) len); - *assoc_lookup(dest, tmp_string(buf, slen), FALSE) = it; } free(buf); @@ -2256,12 +2297,14 @@ how_many = 1; } else { d = force_number(t); - if (d > 0) + if (d < 1) + how_many = 1; + else if (d < LONG_MAX) how_many = d; else - how_many = 1; + how_many = LONG_MAX; if (d == 0) - warning(_("gensub: 3rd argument of 0 treated as 1")); + warning(_("gensub: third argument of 0 treated as 1")); } free_temp(t); @@ -2354,15 +2397,13 @@ } #endif /* GFMT_WORKAROUND */ -#define BITS_PER_BYTE 8 /* if not true, you lose. too bad. */ - /* do_lshift --- perform a << operation */ NODE * do_lshift(NODE *tree) { NODE *s1, *s2; - unsigned long uval, ushift, res; + uintmax_t uval, ushift, res; AWKNUM val, shift; s1 = tree_eval(tree->lnode); @@ -2379,15 +2420,15 @@ lintwarn(_("lshift(%lf, %lf): negative values will give strange results"), val, shift); if (double_to_int(val) != val || double_to_int(shift) != shift) lintwarn(_("lshift(%lf, %lf): fractional values will be truncated"), val, shift); - if (shift > (sizeof(unsigned long) * BITS_PER_BYTE)) + if (shift >= sizeof(uintmax_t) * CHAR_BIT) lintwarn(_("lshift(%lf, %lf): too large shift value will give strange results"), val, shift); } free_temp(s1); free_temp(s2); - uval = (unsigned long) val; - ushift = (unsigned long) shift; + uval = (uintmax_t) val; + ushift = (uintmax_t) shift; res = uval << ushift; return tmp_number((AWKNUM) res); @@ -2399,7 +2440,7 @@ do_rshift(NODE *tree) { NODE *s1, *s2; - unsigned long uval, ushift, res; + uintmax_t uval, ushift, res; AWKNUM val, shift; s1 = tree_eval(tree->lnode); @@ -2416,15 +2457,15 @@ lintwarn(_("rshift(%lf, %lf): negative values will give strange results"), val, shift); if (double_to_int(val) != val || double_to_int(shift) != shift) lintwarn(_("rshift(%lf, %lf): fractional values will be truncated"), val, shift); - if (shift > (sizeof(unsigned long) * BITS_PER_BYTE)) + if (shift >= sizeof(uintmax_t) * CHAR_BIT) lintwarn(_("rshift(%lf, %lf): too large shift value will give strange results"), val, shift); } free_temp(s1); free_temp(s2); - uval = (unsigned long) val; - ushift = (unsigned long) shift; + uval = (uintmax_t) val; + ushift = (uintmax_t) shift; res = uval >> ushift; return tmp_number((AWKNUM) res); @@ -2436,7 +2477,7 @@ do_and(NODE *tree) { NODE *s1, *s2; - unsigned long uleft, uright, res; + uintmax_t uleft, uright, res; AWKNUM left, right; s1 = tree_eval(tree->lnode); @@ -2458,8 +2499,8 @@ free_temp(s1); free_temp(s2); - uleft = (unsigned long) left; - uright = (unsigned long) right; + uleft = (uintmax_t) left; + uright = (uintmax_t) right; res = uleft & uright; return tmp_number((AWKNUM) res); @@ -2471,7 +2512,7 @@ do_or(NODE *tree) { NODE *s1, *s2; - unsigned long uleft, uright, res; + uintmax_t uleft, uright, res; AWKNUM left, right; s1 = tree_eval(tree->lnode); @@ -2493,8 +2534,8 @@ free_temp(s1); free_temp(s2); - uleft = (unsigned long) left; - uright = (unsigned long) right; + uleft = (uintmax_t) left; + uright = (uintmax_t) right; res = uleft | uright; return tmp_number((AWKNUM) res); @@ -2506,7 +2547,7 @@ do_xor(NODE *tree) { NODE *s1, *s2; - unsigned long uleft, uright, res; + uintmax_t uleft, uright, res; AWKNUM left, right; s1 = tree_eval(tree->lnode); @@ -2528,8 +2569,8 @@ free_temp(s1); free_temp(s2); - uleft = (unsigned long) left; - uright = (unsigned long) right; + uleft = (uintmax_t) left; + uright = (uintmax_t) right; res = uleft ^ uright; return tmp_number((AWKNUM) res); @@ -2542,7 +2583,7 @@ { NODE *tmp; double d; - unsigned long uval; + uintmax_t uval; tmp = tree_eval(tree->lnode); d = force_number(tmp); @@ -2557,7 +2598,7 @@ lintwarn(_("compl(%lf): fractional value will be truncated"), d); } - uval = (unsigned long) d; + uval = (uintmax_t) d; uval = ~ uval; return tmp_number((AWKNUM) uval); } @@ -2572,7 +2613,9 @@ tmp = tree_eval(tree->lnode); - if (isnondecimal(tmp->stptr)) + if ((tmp->flags & (NUMBER|NUMCUR)) != 0) + d = (double) force_number(tmp); + else if (isnondecimal(tmp->stptr)) d = nondec2awknum(tmp->stptr, tmp->stlen); else d = (double) force_number(tmp); @@ -2790,7 +2833,7 @@ { NODE *tmp, *t1, *t2, *t3; char *string1, *string2; - long number; + unsigned long number; char *the_result; #if ENABLE_NLS && HAVE_LC_MESSAGES && HAVE_DCGETTEXT int lc_cat; @@ -2806,7 +2849,7 @@ string2 = t2->stptr; tmp = tree->rnode->rnode->lnode; /* third argument */ - number = (long) double_to_int(force_number(tree_eval(tmp))); + number = (unsigned long) double_to_int(force_number(tree_eval(tmp))); t3 = NULL; #if ENABLE_NLS && HAVE_LC_MESSAGES && HAVE_DCGETTEXT diff -urN gawk-3.1.2/config.rpath gawk-3.1.3/config.rpath --- gawk-3.1.2/config.rpath 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/config.rpath 2003-06-16 03:25:33.000000000 -0700 @@ -2,7 +2,7 @@ # Output a system dependent set of variables, describing how to set the # run time search path of shared libraries in an executable. # -# Copyright 1996-2002 Free Software Foundation, Inc. +# Copyright 1996-2003 Free Software Foundation, Inc. # Taken from GNU libtool, 2001 # Originally by Gordon Matzigkeit , 1996 # @@ -34,43 +34,57 @@ # # The set of defined variables is at the end of this script. +# Known limitations: +# - On IRIX 6.5 with CC="cc", the run time search patch must not be longer +# than 256 bytes, otherwise the compiler driver will dump core. The only +# known workaround is to choose shorter directory names for the build +# directory and/or the installation directory. + # All known linkers require a `.a' archive for static linking (except M$VC, # which needs '.lib'). libext=a -shlibext= +shrext=.so host="$1" host_cpu=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` host_vendor=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` host_os=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` +# Code taken from libtool.m4's AC_LIBTOOL_PROG_COMPILER_PIC. + wl= if test "$GCC" = yes; then wl='-Wl,' else case "$host_os" in - aix3* | aix4* | aix5*) + aix*) wl='-Wl,' ;; + mingw* | pw32* | os2*) + ;; hpux9* | hpux10* | hpux11*) wl='-Wl,' ;; - irix5* | irix6*) + irix5* | irix6* | nonstopux*) wl='-Wl,' ;; + newsos6) + ;; linux*) - echo '__INTEL_COMPILER' > conftest.$ac_ext - if $CC -E conftest.$ac_ext >/dev/null | grep __INTEL_COMPILER >/dev/null - then - : - else - # Intel icc - wl='-Qoption,ld,' - fi + case $CC in + icc|ecc) + wl='-Wl,' + ;; + ccc) + wl='-Wl,' + ;; + esac ;; osf3* | osf4* | osf5*) wl='-Wl,' ;; + sco3.2v5*) + ;; solaris*) wl='-Wl,' ;; @@ -78,15 +92,17 @@ wl='-Qoption ld ' ;; sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - if test "x$host_vendor" = xsni; then - wl='-LD' - else - wl='-Wl,' - fi + wl='-Wl,' + ;; + sysv4*MP*) + ;; + uts4*) ;; esac fi +# Code taken from libtool.m4's AC_LIBTOOL_PROG_LD_SHLIBS. + hardcode_libdir_flag_spec= hardcode_libdir_separator= hardcode_direct=no @@ -110,8 +126,10 @@ if test "$with_gnu_ld" = yes; then case "$host_os" in aix3* | aix4* | aix5*) - # On AIX, the GNU linker is very broken - ld_shlibs=no + # On AIX/PPC, the GNU linker is very broken + if test "$host_cpu" != ia64; then + ld_shlibs=no + fi ;; amigaos*) hardcode_libdir_flag_spec='-L$libdir' @@ -135,6 +153,13 @@ # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. hardcode_libdir_flag_spec='-L$libdir' + if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then + : + else + ld_shlibs=no + fi + ;; + netbsd*) ;; solaris* | sysv5*) if $LD -v 2>&1 | egrep 'BFD 2\.8' > /dev/null; then @@ -157,6 +182,8 @@ ;; esac if test "$ld_shlibs" = yes; then + # Unlike libtool, we use -rpath here, not --rpath, since the documented + # option of GNU ld is called -rpath, not --rpath. hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' fi else @@ -209,13 +236,27 @@ fi esac fi + # Begin _LT_AC_SYS_LIBPATH_AIX. + echo 'int main () { return 0; }' > conftest.c + ${CC} ${LDFLAGS} conftest.c -o conftest + aix_libpath=`dump -H conftest 2>/dev/null | sed -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } +}'` + if test -z "$aix_libpath"; then + aix_libpath=`dump -HX64 conftest 2>/dev/null | sed -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } +}'` + fi + if test -z "$aix_libpath"; then + aix_libpath="/usr/lib:/lib" + fi + rm -f conftest.c conftest + # End _LT_AC_SYS_LIBPATH_AIX. if test "$aix_use_runtimelinking" = yes; then - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:/usr/lib:/lib' + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" else if test "$host_cpu" = ia64; then hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' else - hardcode_libdir_flag_spec='${wl}-bnolibpath ${wl}-blibpath:$libdir:/usr/lib:/lib' + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" fi fi ;; @@ -225,6 +266,8 @@ # see comment about different semantics on the GNU ld section ld_shlibs=no ;; + bsdi4*) + ;; cygwin* | mingw* | pw32*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++. @@ -234,7 +277,12 @@ libext=lib ;; darwin* | rhapsody*) - hardcode_direct=yes + if $CC -v 2>&1 | grep 'Apple' >/dev/null ; then + hardcode_direct=no + fi + ;; + dgux*) + hardcode_libdir_flag_spec='-L$libdir' ;; freebsd1*) ld_shlibs=no @@ -251,14 +299,41 @@ hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes ;; - hpux9* | hpux10* | hpux11*) + hpux9*) hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' hardcode_libdir_separator=: hardcode_direct=yes - hardcode_minus_L=yes # Not in the search PATH, but as the default - # location of the library. + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes ;; - irix5* | irix6*) + hpux10* | hpux11*) + if test "$with_gnu_ld" = no; then + case "$host_cpu" in + hppa*64*) + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_direct=no + ;; + ia64*) + hardcode_libdir_flag_spec='-L$libdir' + hardcode_direct=no + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + ;; + *) + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + ;; + esac + fi + ;; + irix5* | irix6* | nonstopux*) hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator=: ;; @@ -314,23 +389,20 @@ hardcode_minus_L=yes ;; sysv4) - if test "x$host_vendor" = xsno; then - hardcode_direct=yes # is this really true??? - else - hardcode_direct=no # Motorola manual says yes, but my tests say they lie - fi + case $host_vendor in + sni) + hardcode_direct=yes # is this really true??? + ;; + siemens) + hardcode_direct=no + ;; + motorola) + hardcode_direct=no #Motorola manual says yes, but my tests say they lie + ;; + esac ;; sysv4.3*) ;; - sysv5*) - hardcode_libdir_flag_spec= - ;; - uts4*) - hardcode_libdir_flag_spec='-L$libdir' - ;; - dgux*) - hardcode_libdir_flag_spec='-L$libdir' - ;; sysv4*MP*) if test -d /usr/nec; then ld_shlibs=yes @@ -340,7 +412,13 @@ hardcode_direct=yes hardcode_minus_L=no ;; - sysv5uw7* | unixware7*) + sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*) + ;; + sysv5*) + hardcode_libdir_flag_spec= + ;; + uts4*) + hardcode_libdir_flag_spec='-L$libdir' ;; *) ld_shlibs=no @@ -349,134 +427,97 @@ fi # Check dynamic linker characteristics +# Code taken from libtool.m4's AC_LIBTOOL_SYS_DYNAMIC_LINKER. libname_spec='lib$name' -sys_lib_dlsearch_path_spec="/lib /usr/lib" -sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" case "$host_os" in aix3*) - shlibext=so ;; aix4* | aix5*) - shlibext=so ;; amigaos*) - shlibext=ixlibrary ;; beos*) - shlibext=so ;; bsdi4*) - shlibext=so - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" ;; cygwin* | mingw* | pw32*) - case $GCC,$host_os in - yes,cygwin*) - shlibext=dll.a - ;; - yes,mingw*) - shlibext=dll - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | sed -e "s/^libraries://" -e "s/;/ /g"` - ;; - yes,pw32*) - shlibext=dll - ;; - *) - shlibext=dll - ;; - esac + shrext=.dll ;; darwin* | rhapsody*) - shlibext=dylib + shrext=.dylib + ;; + dgux*) ;; freebsd1*) ;; freebsd*) - shlibext=so ;; gnu*) - shlibext=so ;; hpux9* | hpux10* | hpux11*) - shlibext=sl + case "$host_cpu" in + ia64*) + shrext=.so + ;; + hppa*64*) + shrext=.sl + ;; + *) + shrext=.sl + ;; + esac ;; - irix5* | irix6*) - shlibext=so + irix5* | irix6* | nonstopux*) case "$host_os" in - irix5*) + irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in - *-32|*"-32 ") libsuff= shlibsuff= ;; - *-n32|*"-n32 ") libsuff=32 shlibsuff=N32 ;; - *-64|*"-64 ") libsuff=64 shlibsuff=64 ;; + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= ;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 ;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 ;; *) libsuff= shlibsuff= ;; esac ;; esac - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" ;; - linux-gnuoldld* | linux-gnuaout* | linux-gnucoff*) + linux*oldld* | linux*aout* | linux*coff*) ;; - linux-gnu*) - shlibext=so + linux*) ;; netbsd*) - shlibext=so ;; newsos6) - shlibext=so + ;; + nto-qnx) ;; openbsd*) - shlibext=so ;; os2*) libname_spec='$name' - shlibext=dll + shrext=.dll ;; osf3* | osf4* | osf5*) - shlibext=so - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" ;; sco3.2v5*) - shlibext=so ;; solaris*) - shlibext=so ;; sunos4*) - shlibext=so ;; sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - shlibext=so - case "$host_vendor" in - motorola) - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - uts4*) - shlibext=so - ;; - dgux*) - shlibext=so ;; sysv4*MP*) - if test -d /usr/nec; then - shlibext=so - fi + ;; + uts4*) ;; esac sed_quote_subst='s/\(["`$\\]\)/\\\1/g' escaped_wl=`echo "X$wl" | sed -e 's/^X//' -e "$sed_quote_subst"` +shlibext=`echo "$shrext" | sed -e 's,^\.,,'` escaped_hardcode_libdir_flag_spec=`echo "X$hardcode_libdir_flag_spec" | sed -e 's/^X//' -e "$sed_quote_subst"` -escaped_sys_lib_search_path_spec=`echo "X$sys_lib_search_path_spec" | sed -e 's/^X//' -e "$sed_quote_subst"` -escaped_sys_lib_dlsearch_path_spec=`echo "X$sys_lib_dlsearch_path_spec" | sed -e 's/^X//' -e "$sed_quote_subst"` sed -e 's/^\([a-zA-Z0-9_]*\)=/acl_cv_\1=/' < exists and doesn't clash with . */ #undef HAVE_INTTYPES_H -/* Define if exists, doesn't clash with , and - declares uintmax_t. */ -#undef HAVE_INTTYPES_H_WITH_UINTMAX - /* Define if you have and nl_langinfo(CODESET). */ #undef HAVE_LANGINFO_CODESET @@ -118,6 +117,9 @@ /* Define to 1 if you have the header file. */ #undef HAVE_LOCALE_H +/* Define if you have the long long type. */ +#undef HAVE_LONG_LONG + /* Define to 1 if you have the header file. */ #undef HAVE_MALLOC_H @@ -178,6 +180,9 @@ /* Define to 1 if you have the header file. */ #undef HAVE_SIGNUM_H +/* Define to 1 if you have the `snprintf' function. */ +#undef HAVE_SNPRINTF + /* we have sockets on this system */ #undef HAVE_SOCKETS @@ -190,10 +195,6 @@ /* Define to 1 if you have the header file. */ #undef HAVE_STDINT_H -/* Define if exists, doesn't clash with , and declares - uintmax_t. */ -#undef HAVE_STDINT_H_WITH_UINTMAX - /* Define to 1 if you have the header file. */ #undef HAVE_STDLIB_H @@ -296,6 +297,12 @@ /* Define to 1 if you have the header file. */ #undef HAVE_WCHAR_H +/* Define to 1 if you have the `wcrtomb' function. */ +#undef HAVE_WCRTOMB + +/* Define to 1 if you have the `wcscoll' function. */ +#undef HAVE_WCSCOLL + /* Define to 1 if you have the header file. */ #undef HAVE_WCTYPE_H @@ -308,6 +315,9 @@ /* Define to 1 if you have the `__argz_stringify' function. */ #undef HAVE___ARGZ_STRINGIFY +/* Define to 1 if you have the `__fsetlocking' function. */ +#undef HAVE___FSETLOCKING + /* Define as const if the declaration of iconv() needs const. */ #undef ICONV_CONST @@ -417,6 +427,9 @@ if it is not supported. */ #undef inline +/* Define to widest signed type if doesn't define. */ +#undef intmax_t + /* Define to `long' if does not define. */ #undef off_t @@ -432,6 +445,5 @@ /* Define to `int' if doesn't define. */ #undef uid_t -/* Define to unsigned long or unsigned long long if and - don't define. */ +/* Define to widest unsigned type if doesn't define. */ #undef uintmax_t diff -urN gawk-3.1.2/configure gawk-3.1.3/configure --- gawk-3.1.2/configure 2003-03-16 02:25:37.000000000 -0800 +++ gawk-3.1.3/configure 2003-07-04 10:49:09.000000000 -0700 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.57 for GNU Awk 3.1.2. +# Generated by GNU Autoconf 2.57 for GNU Awk 3.1.3. # # Report bugs to . # @@ -268,8 +268,8 @@ # Identity of this package. PACKAGE_NAME='GNU Awk' PACKAGE_TARNAME='gawk' -PACKAGE_VERSION='3.1.2' -PACKAGE_STRING='GNU Awk 3.1.2' +PACKAGE_VERSION='3.1.3' +PACKAGE_STRING='GNU Awk 3.1.3' PACKAGE_BUGREPORT='bug-gawk@gnu.org' # Factoring default headers for most tests. @@ -309,7 +309,7 @@ # include #endif" -ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO AMTAR install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM AWK SET_MAKE am__leading_dot EGREP YACC LN_S CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE CPP RANLIB ac_ct_RANLIB U ANSI2KNR MKINSTALLDIRS MSGFMT GMSGFMT XGETTEXT MSGMERGE build build_cpu build_vendor build_os host host_cpu host_vendor host_os ALLOCA GLIBC21 LIBICONV LTLIBICONV INTLBISON USE_NLS BUILD_INCLUDED_LIBINTL USE_INCLUDED_LIBINTL CATOBJEXT INTLOBJS DATADIRNAME INSTOBJEXT GENCAT INTL_LIBTOOL_SUFFIX_PREFIX INTLLIBS LIBINTL LTLIBINTL POSUB LIBOBJS SOCKET_LIBS LTLIBOBJS' +ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO AMTAR install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM AWK SET_MAKE am__leading_dot EGREP YACC LN_S CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE CPP RANLIB ac_ct_RANLIB U ANSI2KNR MKINSTALLDIRS USE_NLS MSGFMT GMSGFMT XGETTEXT MSGMERGE build build_cpu build_vendor build_os host host_cpu host_vendor host_os ALLOCA GLIBC21 LIBICONV LTLIBICONV INTLBISON BUILD_INCLUDED_LIBINTL USE_INCLUDED_LIBINTL CATOBJEXT DATADIRNAME INSTOBJEXT GENCAT INTLOBJS INTL_LIBTOOL_SUFFIX_PREFIX INTLLIBS LIBINTL LTLIBINTL POSUB LIBOBJS SOCKET_LIBS LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. @@ -778,7 +778,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures GNU Awk 3.1.2 to adapt to many kinds of systems. +\`configure' configures GNU Awk 3.1.3 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -844,7 +844,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of GNU Awk 3.1.2:";; + short | recursive ) echo "Configuration of GNU Awk 3.1.3:";; esac cat <<\_ACEOF @@ -853,21 +853,22 @@ --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --enable-portals Enable /p as path prefix for portals --disable-lint Disable gawk lint checking + --enable-switch Enable switch statements for awk programs --disable-dependency-tracking Speeds up one-time builds --enable-dependency-tracking Do not reject slow dependency extractors --disable-largefile omit support for large files - --disable-rpath do not hardcode runtime library paths --disable-nls do not use Native Language Support + --disable-rpath do not hardcode runtime library paths Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) --with-whiny-user-strftime Force use of included version of strftime for deficient systems --with-gnu-ld assume the C compiler uses GNU ld default=no - --with-libiconv-prefix=DIR search for libiconv in DIR/include and DIR/lib + --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib --without-libiconv-prefix don't search for libiconv in includedir and libdir --with-included-gettext use the GNU gettext library included here - --with-libintl-prefix=DIR search for libintl in DIR/include and DIR/lib + --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib --without-libintl-prefix don't search for libintl in includedir and libdir Some influential environment variables: @@ -945,7 +946,7 @@ test -n "$ac_init_help" && exit 0 if $ac_init_version; then cat <<\_ACEOF -GNU Awk configure 3.1.2 +GNU Awk configure 3.1.3 generated by GNU Autoconf 2.57 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002 @@ -960,7 +961,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by GNU Awk $as_me 3.1.2, which was +It was created by GNU Awk $as_me 3.1.3, which was generated by GNU Autoconf 2.57. Invocation command line was $ $0 $@ @@ -1587,7 +1588,7 @@ # Define the identity of the package. PACKAGE=gawk - VERSION=3.1.2 + VERSION=3.1.3 cat >>confdefs.h <<_ACEOF @@ -1717,11 +1718,15 @@ # Check whether --enable-portals or --disable-portals was given. if test "${enable_portals+set}" = set; then enableval="$enable_portals" + if test "$enableval" = yes + then cat >>confdefs.h <<\_ACEOF #define HAVE_PORTALS 1 _ACEOF + fi + fi; # Check whether --with-whiny-user-strftime or --without-whiny-user-strftime was given. @@ -1750,6 +1755,19 @@ fi fi; +# Check whether --enable-switch or --disable-switch was given. +if test "${enable_switch+set}" = set; then + enableval="$enable_switch" + if test "$enableval" = yes + then + +cat >>confdefs.h <<\_ACEOF +#define ALLOW_SWITCH 1 +_ACEOF + + fi + +fi; echo "$as_me:$LINENO: checking for egrep" >&5 echo $ECHO_N "checking for egrep... $ECHO_C" >&6 @@ -2692,8 +2710,9 @@ am_make=${MAKE-make} cat > confinc << 'END' -doit: +am__doit: @echo done +.PHONY: am__doit END # If we don't find an include directive, just comment out the code. echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5 @@ -4544,7 +4563,6 @@ *CYGWIN*) with_libiconv_prefix=no with_libintl_prefix=no - LIBS="$LIBS /usr/lib/automode.o" ;; *) ;; @@ -4553,7 +4571,10 @@ MKINSTALLDIRS= if test -n "$ac_aux_dir"; then - MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" + case "$ac_aux_dir" in + /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;; + *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;; + esac fi if test -z "$MKINSTALLDIRS"; then MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" @@ -4561,9 +4582,52 @@ + echo "$as_me:$LINENO: checking whether NLS is requested" >&5 +echo $ECHO_N "checking whether NLS is requested... $ECHO_C" >&6 + # Check whether --enable-nls or --disable-nls was given. +if test "${enable_nls+set}" = set; then + enableval="$enable_nls" + USE_NLS=$enableval +else + USE_NLS=yes +fi; + echo "$as_me:$LINENO: result: $USE_NLS" >&5 +echo "${ECHO_T}$USE_NLS" >&6 + + - # Extract the first word of "msgfmt", so it can be a program name with args. + + +# Prepare PATH_SEPARATOR. +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + echo "#! /bin/sh" >conf$$.sh + echo "exit 0" >>conf$$.sh + chmod +x conf$$.sh + if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then + PATH_SEPARATOR=';' + else + PATH_SEPARATOR=: + fi + rm -f conf$$.sh +fi + +# Find out how to test for executable files. Don't use a zero-byte file, +# as systems may use methods other than mode bits to determine executability. +cat >conf$$.file <<_ASEOF +#! /bin/sh +exit 0 +_ASEOF +chmod +x conf$$.file +if test -x conf$$.file >/dev/null 2>&1; then + ac_executable_p="test -x" +else + ac_executable_p="test -f" +fi +rm -f conf$$.file + +# Extract the first word of "msgfmt", so it can be a program name with args. set dummy msgfmt; ac_word=$2 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 @@ -4571,24 +4635,27 @@ echo $ECHO_N "(cached) $ECHO_C" >&6 else case "$MSGFMT" in - /*) - ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. - ;; + [\\/]* | ?:[\\/]*) + ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. + ;; *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" - for ac_dir in $PATH; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 && + ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$ac_save_IFS" + test -z "$ac_dir" && ac_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then + if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 && (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then - ac_cv_path_MSGFMT="$ac_dir/$ac_word" - break - fi - fi - done - IFS="$ac_save_ifs" + ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext" + break 2 + fi + fi + done + done + IFS="$ac_save_IFS" test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":" - ;; + ;; esac fi MSGFMT="$ac_cv_path_MSGFMT" @@ -4641,7 +4708,36 @@ fi - # Extract the first word of "xgettext", so it can be a program name with args. + +# Prepare PATH_SEPARATOR. +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + echo "#! /bin/sh" >conf$$.sh + echo "exit 0" >>conf$$.sh + chmod +x conf$$.sh + if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then + PATH_SEPARATOR=';' + else + PATH_SEPARATOR=: + fi + rm -f conf$$.sh +fi + +# Find out how to test for executable files. Don't use a zero-byte file, +# as systems may use methods other than mode bits to determine executability. +cat >conf$$.file <<_ASEOF +#! /bin/sh +exit 0 +_ASEOF +chmod +x conf$$.file +if test -x conf$$.file >/dev/null 2>&1; then + ac_executable_p="test -x" +else + ac_executable_p="test -f" +fi +rm -f conf$$.file + +# Extract the first word of "xgettext", so it can be a program name with args. set dummy xgettext; ac_word=$2 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 @@ -4649,24 +4745,27 @@ echo $ECHO_N "(cached) $ECHO_C" >&6 else case "$XGETTEXT" in - /*) - ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. - ;; + [\\/]* | ?:[\\/]*) + ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. + ;; *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" - for ac_dir in $PATH; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - if $ac_dir/$ac_word --omit-header --copyright-holder= /dev/null >/dev/null 2>&1 && - (if $ac_dir/$ac_word --omit-header --copyright-holder= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then - ac_cv_path_XGETTEXT="$ac_dir/$ac_word" - break - fi - fi - done - IFS="$ac_save_ifs" + ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$ac_save_IFS" + test -z "$ac_dir" && ac_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then + if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 && + (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); then + ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext" + break 2 + fi + fi + done + done + IFS="$ac_save_IFS" test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" - ;; + ;; esac fi XGETTEXT="$ac_cv_path_XGETTEXT" @@ -4680,7 +4779,36 @@ rm -f messages.po - # Extract the first word of "msgmerge", so it can be a program name with args. + +# Prepare PATH_SEPARATOR. +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + echo "#! /bin/sh" >conf$$.sh + echo "exit 0" >>conf$$.sh + chmod +x conf$$.sh + if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then + PATH_SEPARATOR=';' + else + PATH_SEPARATOR=: + fi + rm -f conf$$.sh +fi + +# Find out how to test for executable files. Don't use a zero-byte file, +# as systems may use methods other than mode bits to determine executability. +cat >conf$$.file <<_ASEOF +#! /bin/sh +exit 0 +_ASEOF +chmod +x conf$$.file +if test -x conf$$.file >/dev/null 2>&1; then + ac_executable_p="test -x" +else + ac_executable_p="test -f" +fi +rm -f conf$$.file + +# Extract the first word of "msgmerge", so it can be a program name with args. set dummy msgmerge; ac_word=$2 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 @@ -4688,23 +4816,26 @@ echo $ECHO_N "(cached) $ECHO_C" >&6 else case "$MSGMERGE" in - /*) - ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path. - ;; + [\\/]* | ?:[\\/]*) + ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path. + ;; *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" - for ac_dir in $PATH; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then - ac_cv_path_MSGMERGE="$ac_dir/$ac_word" - break - fi - fi - done - IFS="$ac_save_ifs" + ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$ac_save_IFS" + test -z "$ac_dir" && ac_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then + if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then + ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext" + break 2 + fi + fi + done + done + IFS="$ac_save_IFS" test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":" - ;; + ;; esac fi MSGMERGE="$ac_cv_path_MSGMERGE" @@ -4730,8 +4861,8 @@ fi if test "$XGETTEXT" != ":"; then - if $XGETTEXT --omit-header --copyright-holder= /dev/null >/dev/null 2>&1 && - (if $XGETTEXT --omit-header --copyright-holder= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then + if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 && + (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 : ; else echo "$as_me:$LINENO: result: found xgettext program is not GNU xgettext; ignore it" >&5 @@ -5934,9 +6065,9 @@ - echo "$as_me:$LINENO: checking for inttypes.h" >&5 -echo $ECHO_N "checking for inttypes.h... $ECHO_C" >&6 -if test "${jm_ac_cv_header_inttypes_h+set}" = set; then + echo "$as_me:$LINENO: checking for unsigned long long" >&5 +echo $ECHO_N "checking for unsigned long long... $ECHO_C" >&6 +if test "${ac_cv_type_unsigned_long_long+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF @@ -5946,51 +6077,52 @@ cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ -#include -#include +unsigned long long ull = 1; int i = 63; int main () { -uintmax_t i = (uintmax_t) -1; +unsigned long long ullmax = (unsigned long long) -1; + return ull << i | ull >> i | ullmax / ull | ullmax % ull; ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' + { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - jm_ac_cv_header_inttypes_h=yes + ac_cv_type_unsigned_long_long=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 -jm_ac_cv_header_inttypes_h=no +ac_cv_type_unsigned_long_long=no fi -rm -f conftest.$ac_objext conftest.$ac_ext +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:$LINENO: result: $jm_ac_cv_header_inttypes_h" >&5 -echo "${ECHO_T}$jm_ac_cv_header_inttypes_h" >&6 - if test $jm_ac_cv_header_inttypes_h = yes; then +echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long_long" >&5 +echo "${ECHO_T}$ac_cv_type_unsigned_long_long" >&6 + if test $ac_cv_type_unsigned_long_long = yes; then -cat >>confdefs.h <<_ACEOF -#define HAVE_INTTYPES_H_WITH_UINTMAX 1 +cat >>confdefs.h <<\_ACEOF +#define HAVE_UNSIGNED_LONG_LONG 1 _ACEOF fi - echo "$as_me:$LINENO: checking for stdint.h" >&5 -echo $ECHO_N "checking for stdint.h... $ECHO_C" >&6 -if test "${jm_ac_cv_header_stdint_h+set}" = set; then + + echo "$as_me:$LINENO: checking for uintmax_t" >&5 +echo $ECHO_N "checking for uintmax_t... $ECHO_C" >&6 +if test "${ac_cv_type_uintmax_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF @@ -6000,12 +6132,14 @@ cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ -#include -#include +$ac_includes_default int main () { -uintmax_t i = (uintmax_t) -1; +if ((uintmax_t *) 0) + return 0; +if (sizeof (uintmax_t)) + return 0; ; return 0; } @@ -6022,93 +6156,30 @@ ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - jm_ac_cv_header_stdint_h=yes + ac_cv_type_uintmax_t=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 -jm_ac_cv_header_stdint_h=no +ac_cv_type_uintmax_t=no fi rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:$LINENO: result: $jm_ac_cv_header_stdint_h" >&5 -echo "${ECHO_T}$jm_ac_cv_header_stdint_h" >&6 - if test $jm_ac_cv_header_stdint_h = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_STDINT_H_WITH_UINTMAX 1 -_ACEOF - - fi - - - echo "$as_me:$LINENO: checking for unsigned long long" >&5 -echo $ECHO_N "checking for unsigned long long... $ECHO_C" >&6 -if test "${ac_cv_type_unsigned_long_long+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -#line $LINENO "configure" -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -unsigned long long ull = 1; int i = 63; -int -main () -{ -unsigned long long ullmax = (unsigned long long) -1; - return ull << i | ull >> i | ullmax / ull | ullmax % ull; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_type_unsigned_long_long=yes +echo "$as_me:$LINENO: result: $ac_cv_type_uintmax_t" >&5 +echo "${ECHO_T}$ac_cv_type_uintmax_t" >&6 +if test $ac_cv_type_uintmax_t = yes; then + : else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -ac_cv_type_unsigned_long_long=no -fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext -fi -echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long_long" >&5 -echo "${ECHO_T}$ac_cv_type_unsigned_long_long" >&6 - if test $ac_cv_type_unsigned_long_long = yes; then - -cat >>confdefs.h <<\_ACEOF -#define HAVE_UNSIGNED_LONG_LONG 1 -_ACEOF - - fi - - - - - if test $jm_ac_cv_header_inttypes_h = no && test $jm_ac_cv_header_stdint_h = no; then - - test $ac_cv_type_unsigned_long_long = yes \ - && ac_type='unsigned long long' \ - || ac_type='unsigned long' + test $ac_cv_type_unsigned_long_long = yes \ + && ac_type='unsigned long long' \ + || ac_type='unsigned long' cat >>confdefs.h <<_ACEOF #define uintmax_t $ac_type _ACEOF - fi +fi + echo "$as_me:$LINENO: checking for inttypes.h" >&5 @@ -6252,6 +6323,19 @@ else with_gnu_ld=no fi; +# Prepare PATH_SEPARATOR. +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + echo "#! /bin/sh" >conf$$.sh + echo "exit 0" >>conf$$.sh + chmod +x conf$$.sh + if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then + PATH_SEPARATOR=';' + else + PATH_SEPARATOR=: + fi + rm -f conf$$.sh +fi ac_prog=ld if test "$GCC" = yes; then # Check if gcc -print-prog-name=ld gives a path. @@ -6367,8 +6451,6 @@ hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" hardcode_direct="$acl_cv_hardcode_direct" hardcode_minus_L="$acl_cv_hardcode_minus_L" - sys_lib_search_path_spec="$acl_cv_sys_lib_search_path_spec" - sys_lib_dlsearch_path_spec="$acl_cv_sys_lib_dlsearch_path_spec" # Check whether --enable-rpath or --disable-rpath was given. if test "${enable_rpath+set}" = set; then enableval="$enable_rpath" @@ -6935,9 +7017,11 @@ + for ac_func in feof_unlocked fgets_unlocked getc_unlocked getcwd getegid \ geteuid getgid getuid mempcpy munmap putenv setenv setlocale stpcpy \ -strcasecmp strdup strtoul tsearch __argz_count __argz_stringify __argz_next +strcasecmp strdup strtoul tsearch __argz_count __argz_stringify __argz_next \ +__fsetlocking do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` echo "$as_me:$LINENO: checking for $ac_func" >&5 @@ -7418,6 +7502,7 @@ + echo "$as_me:$LINENO: checking whether NLS is requested" >&5 echo $ECHO_N "checking whether NLS is requested... $ECHO_C" >&6 # Check whether --enable-nls or --disable-nls was given. @@ -7432,6 +7517,7 @@ + BUILD_INCLUDED_LIBINTL=no USE_INCLUDED_LIBINTL=no @@ -8000,7 +8086,8 @@ if test "$gt_cv_func_gnugettext2_libc" = "yes" \ || { test "$gt_cv_func_gnugettext2_libintl" = "yes" \ - && test "$PACKAGE" != gettext; }; then + && test "$PACKAGE" != gettext-runtime \ + && test "$PACKAGE" != gettext-tools; }; then gt_use_preinstalled_gnugettext=yes else LIBINTL= @@ -8015,8 +8102,7 @@ fi if test "$nls_cv_use_gnu_gettext" = "yes"; then - INTLOBJS="\$(GETTOBJS)" - BUILD_INCLUDED_LIBINTL=yes + BUILD_INCLUDED_LIBINTL=yes USE_INCLUDED_LIBINTL=yes LIBINTL="\${top_builddir}/intl/libintl.a $LIBICONV" LTLIBINTL="\${top_builddir}/intl/libintl.a $LTLIBICONV" @@ -8041,6 +8127,26 @@ fi fi + echo "$as_me:$LINENO: checking whether to use NLS" >&5 +echo $ECHO_N "checking whether to use NLS... $ECHO_C" >&6 + echo "$as_me:$LINENO: result: $USE_NLS" >&5 +echo "${ECHO_T}$USE_NLS" >&6 + if test "$USE_NLS" = "yes"; then + echo "$as_me:$LINENO: checking where the gettext function comes from" >&5 +echo $ECHO_N "checking where the gettext function comes from... $ECHO_C" >&6 + if test "$gt_use_preinstalled_gnugettext" = "yes"; then + if test "$gt_cv_func_gnugettext2_libintl" = "yes"; then + gt_source="external libintl" + else + gt_source="libc" + fi + else + gt_source="included intl directory" + fi + echo "$as_me:$LINENO: result: $gt_source" >&5 +echo "${ECHO_T}$gt_source" >&6 + fi + if test "$USE_NLS" = "yes"; then if test "$gt_use_preinstalled_gnugettext" = "yes"; then @@ -8090,7 +8196,7 @@ fi - if test "$PACKAGE" = gettext; then + if test "$PACKAGE" = gettext-runtime || test "$PACKAGE" = gettext-tools; then BUILD_INCLUDED_LIBINTL=yes fi @@ -8098,7 +8204,6 @@ - nls_cv_header_intl= nls_cv_header_libgt= @@ -8111,6 +8216,11 @@ GENCAT=gencat + if test "$USE_INCLUDED_LIBINTL" = yes; then + INTLOBJS="\$(GETTOBJS)" + fi + + INTL_LIBTOOL_SUFFIX_PREFIX= @@ -9156,6 +9266,240 @@ _ACEOF + + echo "$as_me:$LINENO: checking for long long" >&5 +echo $ECHO_N "checking for long long... $ECHO_C" >&6 +if test "${ac_cv_type_long_long+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +long long ll = 1; int i = 63; +int +main () +{ +long long llmax = (long long) -1; + return ll << i | ll >> i | llmax / ll | llmax % ll; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_type_long_long=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_cv_type_long_long=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +fi +echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5 +echo "${ECHO_T}$ac_cv_type_long_long" >&6 + if test $ac_cv_type_long_long = yes; then + +cat >>confdefs.h <<\_ACEOF +#define HAVE_LONG_LONG 1 +_ACEOF + + fi + + + echo "$as_me:$LINENO: checking for unsigned long long" >&5 +echo $ECHO_N "checking for unsigned long long... $ECHO_C" >&6 +if test "${ac_cv_type_unsigned_long_long+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +unsigned long long ull = 1; int i = 63; +int +main () +{ +unsigned long long ullmax = (unsigned long long) -1; + return ull << i | ull >> i | ullmax / ull | ullmax % ull; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_type_unsigned_long_long=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_cv_type_unsigned_long_long=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +fi +echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long_long" >&5 +echo "${ECHO_T}$ac_cv_type_unsigned_long_long" >&6 + if test $ac_cv_type_unsigned_long_long = yes; then + +cat >>confdefs.h <<\_ACEOF +#define HAVE_UNSIGNED_LONG_LONG 1 +_ACEOF + + fi + + + + echo "$as_me:$LINENO: checking for intmax_t" >&5 +echo $ECHO_N "checking for intmax_t... $ECHO_C" >&6 +if test "${ac_cv_type_intmax_t+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +if ((intmax_t *) 0) + return 0; +if (sizeof (intmax_t)) + return 0; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_type_intmax_t=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_cv_type_intmax_t=no +fi +rm -f conftest.$ac_objext conftest.$ac_ext +fi +echo "$as_me:$LINENO: result: $ac_cv_type_intmax_t" >&5 +echo "${ECHO_T}$ac_cv_type_intmax_t" >&6 +if test $ac_cv_type_intmax_t = yes; then + : +else + test $ac_cv_type_long_long = yes \ + && ac_type='long long' \ + || ac_type='long' + +cat >>confdefs.h <<_ACEOF +#define intmax_t $ac_type +_ACEOF + +fi + + + + + echo "$as_me:$LINENO: checking for uintmax_t" >&5 +echo $ECHO_N "checking for uintmax_t... $ECHO_C" >&6 +if test "${ac_cv_type_uintmax_t+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +if ((uintmax_t *) 0) + return 0; +if (sizeof (uintmax_t)) + return 0; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_type_uintmax_t=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_cv_type_uintmax_t=no +fi +rm -f conftest.$ac_objext conftest.$ac_ext +fi +echo "$as_me:$LINENO: result: $ac_cv_type_uintmax_t" >&5 +echo "${ECHO_T}$ac_cv_type_uintmax_t" >&6 +if test $ac_cv_type_uintmax_t = yes; then + : +else + test $ac_cv_type_unsigned_long_long = yes \ + && ac_type='unsigned long long' \ + || ac_type='unsigned long' + +cat >>confdefs.h <<_ACEOF +#define uintmax_t $ac_type +_ACEOF + +fi + + echo "$as_me:$LINENO: checking for ssize_t" >&5 echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6 if test "${ac_cv_type_ssize_t+set}" = set; then @@ -10257,9 +10601,12 @@ -for ac_func in getgrent getgroups memset memcpy memcmp fmod setlocale strchr \ - strerror strftime strncasecmp strtod system tzset mbrlen mbrtowc \ - grantpt + + + +for ac_func in fmod getgrent getgroups grantpt mbrlen mbrtowc memcmp \ + memcpy memset setlocale snprintf strchr strerror \ + strftime strncasecmp strtod system tzset wcrtomb wcscoll do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` echo "$as_me:$LINENO: checking for $ac_func" >&5 @@ -11939,7 +12286,7 @@ } >&5 cat >&5 <<_CSEOF -This file was extended by GNU Awk $as_me 3.1.2, which was +This file was extended by GNU Awk $as_me 3.1.3, which was generated by GNU Autoconf 2.57. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -12002,7 +12349,7 @@ cat >>$CONFIG_STATUS <<_ACEOF ac_cs_version="\\ -GNU Awk config.status 3.1.2 +GNU Awk config.status 3.1.3 configured by $0, generated by GNU Autoconf 2.57, with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\" @@ -12106,7 +12453,7 @@ # Capture the value of obsolete ALL_LINGUAS because we need it to compute # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it # from automake. - eval 'ALL_LINGUAS''="$ALL_LINGUAS"' + eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"' # Capture the value of LINGUAS because we need it to compute CATALOGS. LINGUAS="${LINGUAS-%UNSET%}" @@ -12258,6 +12605,7 @@ s,@U@,$U,;t t s,@ANSI2KNR@,$ANSI2KNR,;t t s,@MKINSTALLDIRS@,$MKINSTALLDIRS,;t t +s,@USE_NLS@,$USE_NLS,;t t s,@MSGFMT@,$MSGFMT,;t t s,@GMSGFMT@,$GMSGFMT,;t t s,@XGETTEXT@,$XGETTEXT,;t t @@ -12275,14 +12623,13 @@ s,@LIBICONV@,$LIBICONV,;t t s,@LTLIBICONV@,$LTLIBICONV,;t t s,@INTLBISON@,$INTLBISON,;t t -s,@USE_NLS@,$USE_NLS,;t t s,@BUILD_INCLUDED_LIBINTL@,$BUILD_INCLUDED_LIBINTL,;t t s,@USE_INCLUDED_LIBINTL@,$USE_INCLUDED_LIBINTL,;t t s,@CATOBJEXT@,$CATOBJEXT,;t t -s,@INTLOBJS@,$INTLOBJS,;t t s,@DATADIRNAME@,$DATADIRNAME,;t t s,@INSTOBJEXT@,$INSTOBJEXT,;t t s,@GENCAT@,$GENCAT,;t t +s,@INTLOBJS@,$INTLOBJS,;t t s,@INTL_LIBTOOL_SUFFIX_PREFIX@,$INTL_LIBTOOL_SUFFIX_PREFIX,;t t s,@INTLLIBS@,$INTLLIBS,;t t s,@LIBINTL@,$LIBINTL,;t t @@ -12915,17 +13262,22 @@ rm -f "$ac_dir/POTFILES" test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES" cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES" + POMAKEFILEDEPS="POTFILES.in" # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend # on $ac_dir but don't depend on user-specified configuration # parameters. if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then # The LINGUAS file contains the set of available languages. - if test -n "$ALL_LINGUAS"; then + if test -n "$OBSOLETE_ALL_LINGUAS"; then test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete" fi ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"` # Hide the ALL_LINGUAS assigment from automake. eval 'ALL_LINGUAS''=$ALL_LINGUAS_' + POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS" + else + # The set of available languages was given in configure.in. + eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS' fi case "$ac_given_srcdir" in .) srcdirpre= ;; @@ -12974,7 +13326,7 @@ done fi test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile" - sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile" + sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile" for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do if test -f "$f"; then case "$f" in diff -urN gawk-3.1.2/configure.ac gawk-3.1.3/configure.ac --- gawk-3.1.2/configure.ac 2003-03-16 02:23:32.000000000 -0800 +++ gawk-3.1.3/configure.ac 2003-07-04 10:26:33.000000000 -0700 @@ -1,5 +1,5 @@ dnl -dnl configure.in --- autoconf input file for gawk +dnl configure.ac --- autoconf input file for gawk dnl dnl Copyright (C) 1995-2003 the Free Software Foundation, Inc. dnl @@ -24,7 +24,7 @@ dnl Process this file with autoconf to produce a configure script. dnl *** IMPORTANT ***: Fix version in both AC_INIT and AM_INIT_AUTOMAKE -AC_INIT([GNU Awk], 3.1.2, bug-gawk@gnu.org, gawk) +AC_INIT([GNU Awk], 3.1.3, bug-gawk@gnu.org, gawk) # This is a hack. Different versions of install on different systems # are just too different. Chuck it and use install-sh. @@ -42,10 +42,15 @@ AC_PREREQ(2.57) AC_CONFIG_HEADERS([config.h:configh.in], [cat $srcdir/custom.h >> config.h]) -AM_INIT_AUTOMAKE(gawk, 3.1.2) +AM_INIT_AUTOMAKE(gawk, 3.1.3) dnl Additional argument stuff -AC_ARG_ENABLE(portals, [ --enable-portals Enable /p as path prefix for portals], AC_DEFINE(HAVE_PORTALS, 1, [we have portals on /p on this system])) +AC_ARG_ENABLE(portals, [ --enable-portals Enable /p as path prefix for portals], + if test "$enableval" = yes + then + AC_DEFINE(HAVE_PORTALS, 1, [we have portals on /p on this system]) + fi +) AC_ARG_WITH(whiny-user-strftime, [ --with-whiny-user-strftime Force use of included version of strftime for deficient systems], if test "$withval" = yes then @@ -59,6 +64,12 @@ AC_DEFINE(NO_LINT, 1, [disable lint checks]) fi ) +AC_ARG_ENABLE(switch, [ --enable-switch Enable switch statements for awk programs], + if test "$enableval" = yes + then + AC_DEFINE(ALLOW_SWITCH, 1, [switch statements are enabled in awk programs]) + fi +) dnl checks for programs AC_PROG_EGREP @@ -118,7 +129,6 @@ *CYGWIN*) with_libiconv_prefix=no with_libintl_prefix=no - LIBS="$LIBS /usr/lib/automode.o" ;; *) ;; @@ -126,7 +136,7 @@ dnl initialize GNU gettext AM_GNU_GETTEXT([no-libtool], [need-ngettext]) -AM_GNU_GETTEXT_VERSION(0.11.5) +AM_GNU_GETTEXT_VERSION(0.12.1) dnl checks for header files AC_HEADER_STDC @@ -149,6 +159,10 @@ AC_TYPE_SIGNAL AC_SIZE_T AC_TYPE_GETGROUPS +jm_AC_TYPE_LONG_LONG +jm_AC_TYPE_UNSIGNED_LONG_LONG +jm_AC_TYPE_INTMAX_T +jm_AC_TYPE_UINTMAX_T AC_CHECK_TYPE(ssize_t, int) AC_EGREP_HEADER([int.*sprintf], stdio.h, AC_DEFINE(SPRINTF_RET, int, [return type of sprintf]), @@ -172,9 +186,9 @@ esac AC_CHECK_LIB(m, fmod) -AC_CHECK_FUNCS(getgrent getgroups memset memcpy memcmp fmod setlocale strchr \ - strerror strftime strncasecmp strtod system tzset mbrlen mbrtowc \ - grantpt) +AC_CHECK_FUNCS(fmod getgrent getgroups grantpt mbrlen mbrtowc memcmp \ + memcpy memset setlocale snprintf strchr strerror \ + strftime strncasecmp strtod system tzset wcrtomb wcscoll) dnl check for dynamic linking dnl This is known to be very primitive diff -urN gawk-3.1.2/custom.h gawk-3.1.3/custom.h --- gawk-3.1.2/custom.h 2002-10-28 00:16:12.000000000 -0800 +++ gawk-3.1.3/custom.h 2003-06-09 08:45:53.000000000 -0700 @@ -11,7 +11,7 @@ */ /* - * Copyright (C) 1995-2002 the Free Software Foundation, Inc. + * Copyright (C) 1995-2003 the Free Software Foundation, Inc. * * This file is part of GAWK, the GNU implementation of the * AWK Programming Language. @@ -95,3 +95,10 @@ #ifdef USE_INCLUDED_STRFTIME #undef HAVE_STRFTIME #endif + +/* For HP/UX with gcc */ +#if defined(hpux) || defined(_HPUX_SOURCE) +#undef HAVE_TZSET +#define HAVE_TZSET 1 +#define _TZSET 1 +#endif diff -urN gawk-3.1.2/doc/ChangeLog gawk-3.1.3/doc/ChangeLog --- gawk-3.1.2/doc/ChangeLog 2003-03-19 04:24:28.000000000 -0800 +++ gawk-3.1.3/doc/ChangeLog 2003-07-07 11:02:06.000000000 -0700 @@ -1,3 +1,27 @@ +Mon Jul 7 11:01:43 2003 Arnold D. Robbins + + * Release 3.1.3: Release tar file made. + +Mon Jun 9 16:06:30 2003 Arnold D. Robbins + + * gawk.texi: Set automatic-xref-title and change all cross + references to be of the single-argument type. Made all + @node lines have just the node name. + + Should have done both of these years ago. + +Sun May 11 16:08:58 2003 Arnold D. Robbins + + * Makefile.am (html, gawk.html, gawkinet.html): New targets. + +Mon Mar 31 17:15:23 2003 Arnold D. Robbins + + * Makefile.am (install-data-hook, uninstall-hook): Added code to + hard link gawk.1 to pgawk.1 upon install and remove pgawk.1 upon + uninstall. Avoids MANPATH search problems, etc. etc. + (man_MANS): Removed pgawk.1 from the list. + * pgawk.1: Removed. + Wed Mar 19 14:10:31 2003 Arnold D. Robbins This time for sure. diff -urN gawk-3.1.2/doc/Makefile.am gawk-3.1.3/doc/Makefile.am --- gawk-3.1.2/doc/Makefile.am 2003-03-11 01:18:41.000000000 -0800 +++ gawk-3.1.3/doc/Makefile.am 2003-05-11 06:08:52.000000000 -0700 @@ -25,7 +25,7 @@ info_TEXINFOS = gawk.texi gawkinet.texi -man_MANS = gawk.1 igawk.1 pgawk.1 +man_MANS = gawk.1 igawk.1 EXTRA_DIST = ChangeLog README.card ad.block setter.outline \ awkcard.in awkforai.txt texinfo.tex cardfonts \ @@ -52,6 +52,22 @@ # to ensure that awkcard.tr is processed by tbl. #AWKCARD = awkcard.nc +# The following is patterned after the main Makefile.am. The point is to +# make pgawk.1 a link to gawk.1 in the installed man directory. + +# We want hard links for install-data-hook, below +LN= ln + +# Link gawk.1 to pgawk.1 +install-data-hook: + (cd $(DESTDIR)$(man1dir); \ + $(LN) gawk.1 pgawk.1 2>/dev/null ; \ + exit 0) + +# Undo the above when uninstalling +uninstall-hook: + cd $(DESTDIR)$(man1dir); rm -f pgawk.1 ; exit 0 + postscript: gawk.ps gawkinet.ps gawk.1.ps igawk.1.ps $(AWKCARD) gawk.ps: gawk.dvi @@ -75,7 +91,15 @@ awkcard.nc: $(CARDFILES) $(TROFF) $(CARDSRC_N) | $(SEDME) | cat $(srcdir)/setter.outline - > awkcard.ps && touch awkcard.nc +html: gawk.html gawkinet.html + +gawk.html: gawk.texi + $(MAKEINFO) --html $< + +gawkinet.html: gawkinet.texi + $(MAKEINFO) --html $< + clean: - rm -f *.ps *~ awkcard.nc awkcard.tr + rm -f *.ps *~ awkcard.nc awkcard.tr *.html distclean: clean diff -urN gawk-3.1.2/doc/Makefile.in gawk-3.1.3/doc/Makefile.in --- gawk-3.1.2/doc/Makefile.in 2003-03-16 02:26:04.000000000 -0800 +++ gawk-3.1.3/doc/Makefile.in 2003-07-04 10:50:33.000000000 -0700 @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.7.3 from Makefile.am. +# Makefile.in generated by automake 1.7.5 from Makefile.am. # @configure_input@ # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 @@ -168,7 +168,7 @@ info_TEXINFOS = gawk.texi gawkinet.texi -man_MANS = gawk.1 igawk.1 pgawk.1 +man_MANS = gawk.1 igawk.1 EXTRA_DIST = ChangeLog README.card ad.block setter.outline \ awkcard.in awkforai.txt texinfo.tex cardfonts \ @@ -188,7 +188,20 @@ # Use this if your troff can correctly handle macros from 'colors' file AWKCARD = awkcard.ps + +# Uncomment the following definition of AWKCARD if your troff can produce +# Postscript but still has troubles with macros from 'colors'. As this +# is not groff you will have to change TROFF macro as well. Do not forget +# to ensure that awkcard.tr is processed by tbl. +#AWKCARD = awkcard.nc + +# The following is patterned after the main Makefile.am. The point is to +# make pgawk.1 a link to gawk.1 in the installed man directory. + +# We want hard links for install-data-hook, below +LN = ln subdir = doc +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = @@ -207,7 +220,7 @@ .SUFFIXES: .SUFFIXES: .dvi .info .pdf .ps .texi -$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) +$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && \ $(AUTOMAKE) --gnu doc/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @@ -382,7 +395,6 @@ installdirs: $(mkinstalldirs) $(DESTDIR)$(infodir) $(DESTDIR)$(man1dir) - install: install-am install-exec: install-exec-am install-data: install-data-am @@ -424,6 +436,8 @@ info-am: $(INFO_DEPS) install-data-am: install-info-am install-man + @$(NORMAL_INSTALL) + $(MAKE) $(AM_MAKEFLAGS) install-data-hook install-exec-am: @@ -477,6 +491,8 @@ ps-am: $(PSS) uninstall-am: uninstall-info-am uninstall-man + @$(NORMAL_INSTALL) + $(MAKE) $(AM_MAKEFLAGS) uninstall-hook uninstall-man: uninstall-man1 @@ -491,11 +507,15 @@ uninstall-info-am uninstall-man uninstall-man1 -# Uncomment the following definition of AWKCARD if your troff can produce -# Postscript but still has troubles with macros from 'colors'. As this -# is not groff you will have to change TROFF macro as well. Do not forget -# to ensure that awkcard.tr is processed by tbl. -#AWKCARD = awkcard.nc +# Link gawk.1 to pgawk.1 +install-data-hook: + (cd $(DESTDIR)$(man1dir); \ + $(LN) gawk.1 pgawk.1 2>/dev/null ; \ + exit 0) + +# Undo the above when uninstalling +uninstall-hook: + cd $(DESTDIR)$(man1dir); rm -f pgawk.1 ; exit 0 postscript: gawk.ps gawkinet.ps gawk.1.ps igawk.1.ps $(AWKCARD) @@ -520,8 +540,16 @@ awkcard.nc: $(CARDFILES) $(TROFF) $(CARDSRC_N) | $(SEDME) | cat $(srcdir)/setter.outline - > awkcard.ps && touch awkcard.nc +html: gawk.html gawkinet.html + +gawk.html: gawk.texi + $(MAKEINFO) --html $< + +gawkinet.html: gawkinet.texi + $(MAKEINFO) --html $< + clean: - rm -f *.ps *~ awkcard.nc awkcard.tr + rm -f *.ps *~ awkcard.nc awkcard.tr *.html distclean: clean # Tell versions [3.59,3.63) of GNU make to not export all variables. diff -urN gawk-3.1.2/doc/awkcard.in gawk-3.1.3/doc/awkcard.in --- gawk-3.1.2/doc/awkcard.in 2003-02-04 05:21:00.000000000 -0800 +++ gawk-3.1.3/doc/awkcard.in 2003-07-06 13:01:15.000000000 -0700 @@ -766,6 +766,19 @@ .ti -.2i \*(CL\*(FCnextfile\*(FR \*(CR(not \*(MK) \*(CLsee \fHInput Control.\fP\*(CD .ti -.2i +.\" --- Start switch statement +\*(CB\*(FCswitch (\*(FIexpression\*(FC) { +.br + case [\*(FIvalue\*(FC|\*(FIregular expression\*(FC] : \*(FIstatement(s)\*(FC +.br + default: \*(FIstatement(s)\*(FC +.br +}\*(FR +.br +switch on \*(FIexpression\*(FR, execute \*(FIcase\*(FR if matched, default if not. +For 3.1.x, requires \*(FC\-\^\-enable\-switch\*(FR option to \*(FCconfigure\*(FR.\*(CD +.ti -.2i +.\" --- End switch statement \*(FCwhile (\*(FIcondition\*(FC) \*(FIstatement \*(FR .br while \*(FIcondition\*(FR is true, execute \*(FIstatement\*(FR. @@ -1466,7 +1479,7 @@ \*(FCexp(\*(FIexpr\*(FC)\*(FR the exponential function (\*(FIe \*(FC^ \*(FIx\*(FR). \*(FCint(\*(FIexpr\*(FC)\*(FR truncates to integer. \*(FClog(\*(FIexpr\*(FC)\*(FR the natural logarithm function (base \*(FIe\^\*(FR). -\*(FCrand()\fP a random number between 0 and 1. +\*(FCrand()\fP a random number between 0 and 1 (0 \(<= \*(FIN\fP < 1). \*(FCsin(\*(FIexpr\*(FC)\*(FR the sine of \*(FIexpr\fP, which is in radians. \*(FCsqrt(\*(FIexpr\*(FC)\*(FR the square root function. \&\*(FCsrand(\*(FR[\*(FIexpr\^\*(FR]\*(FC)\*(FR T{ @@ -1881,7 +1894,7 @@ .ES .nf \*(CDHost: \*(FCftp.gnu.org\*(FR -File: \*(FC/gnu/gawk/gawk-3.1.2.tar.gz\fP +File: \*(FC/gnu/gawk/gawk-3.1.3.tar.gz\fP .in +.2i .fi GNU \*(AK (\*(GK). There may be a later version. diff -urN gawk-3.1.2/doc/gawk.1 gawk-3.1.3/doc/gawk.1 --- gawk-3.1.2/doc/gawk.1 2003-02-04 04:11:53.000000000 -0800 +++ gawk-3.1.3/doc/gawk.1 2003-07-06 13:01:23.000000000 -0700 @@ -14,7 +14,7 @@ . if \w'\(rq' .ds rq "\(rq . \} .\} -.TH GAWK 1 "February 3 2003" "Free Software Foundation" "Utility Commands" +.TH GAWK 1 "June 25 2003" "Free Software Foundation" "Utility Commands" .SH NAME gawk \- pattern scanning and processing language .SH SYNOPSIS @@ -1678,6 +1678,7 @@ \fBdo \fIstatement \fBwhile (\fIcondition\fB)\fR \fBfor (\fIexpr1\fB; \fIexpr2\fB; \fIexpr3\fB) \fIstatement\fR \fBfor (\fIvar \fBin\fI array\fB) \fIstatement\fR +.\" \fBswitch (\fIexpression\fB) { \fBcase [\fIvalue\fB|\fIregex\fB] : \fIstatement \fBdefault: \fIstatement \fB}\fR \fBbreak\fR \fBcontinue\fR \fBdelete \fIarray\^\fB[\^\fIindex\^\fB]\fR @@ -1928,6 +1929,22 @@ .B % character; no argument is converted. .PP +.BR NOTE : +When using the integer format-control letters for values that are +outside the range of a C +.B long +integer, +.I gawk +switches to the +.B %g +format specifier. If +.B \-\^\-lint +is provided on the command line +.I gawk +warns about this. Other versions of +.I awk +may print invalid values or do something else entirely. +.PP Optional, additional parameters may lie between the .B % and the control letter: @@ -2193,7 +2210,10 @@ The natural logarithm function. .TP .B rand() -Returns a random number between 0 and 1. +Returns a random number +.IR N , +between 0 and 1, +such that 0 \(<= \fIN\fP < 1. .TP .BI sin( expr ) Returns the sine of @@ -3319,7 +3339,7 @@ .SH VERSION INFORMATION This man page documents .IR gawk , -version 3.1.0. +version 3.1.3. .SH BUG REPORTS If you find a bug in .IR gawk , diff -urN gawk-3.1.2/doc/gawk.texi gawk-3.1.3/doc/gawk.texi --- gawk-3.1.2/doc/gawk.texi 2003-03-19 03:41:28.000000000 -0800 +++ gawk-3.1.3/doc/gawk.texi 2003-07-04 10:40:47.000000000 -0700 @@ -13,16 +13,16 @@ * awk: (gawk)Invoking gawk. Text scanning and processing. @end direntry -@c @set xref-automatic-section-title +@set xref-automatic-section-title @c The following information should be updated here only! @c This sets the edition of the document, the version of gawk it @c applies to and all the info about who's publishing this edition @c These apply across the board. -@set UPDATE-MONTH February, 2003 +@set UPDATE-MONTH June, 2003 @set VERSION 3.1 -@set PATCHLEVEL 2 +@set PATCHLEVEL 3 @set FSF @@ -232,7 +232,7 @@ @ifnottex @ifnotxml -@node Top, Foreword, (dir), (dir) +@node Top @top General Introduction @c Preface node should come right after the Top @c node, in `unnumbered' sections, then the chapter, `What is gawk'. @@ -436,6 +436,8 @@ some condition is satisfied. * For Statement:: Another looping statement, that provides initialization and increment clauses. +* Switch Statement:: Switch/case evaluation for conditional + execution of statements based on a value. * Break Statement:: Immediately exit the innermost enclosing loop. * Continue Statement:: Skip to the end of the innermost enclosing @@ -532,6 +534,7 @@ transitions. * Rewind Function:: A function for rereading the current file. * File Checking:: Checking that data files are readable. +* Empty Files:: Checking for zero-length files. * Ignoring Assigns:: Treating assignments as file names. * Getopt Function:: A function for processing command-line arguments. @@ -585,10 +588,12 @@ * PC Installation:: Installing and Compiling @command{gawk} on MS-DOS and OS/2. * PC Binary Installation:: Installing a prepared distribution. -* PC Compiling:: Compiling @command{gawk} for MS-DOS, Win32, +* PC Compiling:: Compiling @command{gawk} for MS-DOS, Windows32, and OS/2. -* PC Using:: Running @command{gawk} on MS-DOS, Win32 and +* PC Using:: Running @command{gawk} on MS-DOS, Windows32 and OS/2. +* PC Dynamic:: Compiling @command{gawk} for dynamic + libraries. * Cygwin:: Building and running @command{gawk} for Cygwin. * VMS Installation:: Installing @command{gawk} on VMS. @@ -644,17 +649,17 @@ @summarycontents @contents -@node Foreword, Preface, Top, Top +@node Foreword @unnumbered Foreword Arnold Robbins and I are good friends. We were introduced 11 years ago -by circumstances---and our favorite programming language, AWK. +by circumstances---and our favorite programming language, AWK. The circumstances started a couple of years -earlier. I was working at a new job and noticed an unplugged +earlier. I was working at a new job and noticed an unplugged Unix computer sitting in the corner. No one knew how to use it, and neither did I. However, a couple of days later it was running, and -I was @code{root} and the one-and-only user. +I was @code{root} and the one-and-only user. That day, I began the transition from statistician to Unix programmer. On one of many trips to the library or bookstore in search of @@ -684,12 +689,12 @@ My Unix system started out unplugged from the wall; it certainly was not plugged into a network. So, oblivious to the existence of @command{gawk} and the Unix community in general, and desiring a new @command{awk}, I wrote -my own, called @command{mawk}. +my own, called @command{mawk}. Before I was finished I knew about @command{gawk}, but it was too late to stop, so I eventually posted -to a @code{comp.sources} newsgroup. +to a @code{comp.sources} newsgroup. -A few days after my posting, I got a friendly email +A few days after my posting, I got a friendly email from Arnold introducing himself. He suggested we share design and algorithms and attached a draft of the POSIX standard so @@ -698,7 +703,7 @@ Frankly, if our roles had been reversed, I would not have been so open and we probably would -have never met. I'm glad we did meet. +have never met. I'm glad we did meet. He is an AWK expert's AWK expert and a genuinely nice person. Arnold contributes significant amounts of his expertise and time to the Free Software Foundation. @@ -715,11 +720,11 @@ the power of AWK's basic idioms: data driven control-flow, pattern matching with regular expressions, and associative arrays. -Those looking for something new can try out @command{gawk}'s +Those looking for something new can try out @command{gawk}'s interface to network protocols via special @file{/inet} files. The programs in this book make clear that an AWK program is -typically much smaller and faster to develop than +typically much smaller and faster to develop than a counterpart written in C. Consequently, there is often a payoff to prototype an algorithm or design in AWK to get it running quickly and expose @@ -758,7 +763,7 @@ Author of @command{mawk} @end display -@node Preface, Getting Started, Foreword, Top +@node Preface @unnumbered Preface @c I saw a comment somewhere that the preface should describe the book itself, @c and the introduction should describe what the book covers. @@ -860,7 +865,7 @@ * Acknowledgments:: Acknowledgments. @end menu -@node History, Names, Preface, Preface +@node History @unnumberedsec History of @command{awk} and @command{gawk} @cindex recipe for a programming language @cindex programming language, recipe for @@ -875,7 +880,7 @@ Blend all parts well using @code{lex} and @code{yacc}. Document minimally and release. -After eight years, add another part @code{egrep} and two +After eight years, add another part @code{egrep} and two more parts C. Document very well and release. @end quotation @@ -919,15 +924,15 @@ His code finally became part of the main @command{gawk} distribution with @command{gawk} @value{PVERSION} 3.1. -@xref{Contributors, ,Major Contributors to @command{gawk}}, +@xref{Contributors}, for a complete list of those who made important contributions to @command{gawk}. -@node Names, This Manual, History, Preface +@node Names @section A Rose by Any Other Name @cindex @command{awk}, new vs. old The @command{awk} language has evolved over the years. Full details are -provided in @ref{Language History, ,The Evolution of the @command{awk} Language}. +provided in @ref{Language History}. The language described in this @value{DOCUMENT} is often referred to as ``new @command{awk}'' (@command{nawk}). @@ -959,7 +964,7 @@ we simply use the term @command{awk}. When referring to a feature that is specific to the GNU implementation, we use the term @command{gawk}. -@node This Manual, Conventions, Names, Preface +@node This Manual @section Using This Book @cindex @command{awk}, terms describing @@ -1009,24 +1014,24 @@ to @command{awk}, there is a lot of information here that even the @command{awk} expert should find useful. In particular, the description of POSIX @command{awk} and the example programs in -@ref{Library Functions, ,A Library of @command{awk} Functions}, and in -@ref{Sample Programs, ,Practical @command{awk} Programs}, +@ref{Library Functions}, and in +@ref{Sample Programs}, should be of interest. -@ref{Getting Started, ,Getting Started with @command{awk}}, +@ref{Getting Started}, provides the essentials you need to know to begin using @command{awk}. -@ref{Regexp, ,Regular Expressions}, +@ref{Regexp}, introduces regular expressions in general, and in particular the flavors supported by POSIX @command{awk} and @command{gawk}. -@ref{Reading Files, , Reading Input Files}, +@ref{Reading Files}, describes how @command{awk} reads your data. It introduces the concepts of records and fields, as well as the @code{getline} command. I/O redirection is first described here. -@ref{Printing, , Printing Output}, +@ref{Printing}, describes how @command{awk} programs can produce output with @code{print} and @code{printf}. @@ -1034,12 +1039,12 @@ describes expressions, which are the basic building blocks for getting most things done in a program. -@ref{Patterns and Actions, ,Patterns Actions and Variables}, +@ref{Patterns and Actions}, describes how to write patterns for matching records, actions for doing something when a record is matched, and the built-in variables @command{awk} and @command{gawk} use. -@ref{Arrays, ,Arrays in @command{awk}}, +@ref{Arrays}, covers @command{awk}'s one-and-only data structure: associative arrays. Deleting array elements and whole arrays is also described, as well as sorting arrays in @command{gawk}. @@ -1049,47 +1054,47 @@ @command{gawk} provide, as well as how to define your own functions. -@ref{Internationalization, ,Internationalization with @command{gawk}}, +@ref{Internationalization}, describes special features in @command{gawk} for translating program messages into different languages at runtime. -@ref{Advanced Features, ,Advanced Features of @command{gawk}}, +@ref{Advanced Features}, describes a number of @command{gawk}-specific advanced features. Of particular note are the abilities to have two-way communications with another process, perform TCP/IP networking, and profile your @command{awk} programs. -@ref{Invoking Gawk, ,Running @command{awk} and @command{gawk}}, +@ref{Invoking Gawk}, describes how to run @command{gawk}, the meaning of its command-line options, and how it finds @command{awk} program source files. -@ref{Library Functions, ,A Library of @command{awk} Functions}, and -@ref{Sample Programs, ,Practical @command{awk} Programs}, +@ref{Library Functions}, and +@ref{Sample Programs}, provide many sample @command{awk} programs. Reading them allows you to see @command{awk} solving real problems. -@ref{Language History, ,The Evolution of the @command{awk} Language}, +@ref{Language History}, describes how the @command{awk} language has evolved since first release to present. It also describes how @command{gawk} has acquired features over time. -@ref{Installation, ,Installing @command{gawk}}, +@ref{Installation}, describes how to get @command{gawk}, how to compile it under Unix, and how to compile and use it on different non-Unix systems. It also describes how to report bugs in @command{gawk} and where to get three other freely available implementations of @command{awk}. -@ref{Notes, ,Implementation Notes}, +@ref{Notes}, describes how to disable @command{gawk}'s extensions, as well as how to contribute new code to @command{gawk}, how to write extension libraries, and some possible future directions for @command{gawk} development. -@ref{Basic Concepts, ,Basic Programming Concepts}, +@ref{Basic Concepts}, provides some very cursory background material for those who are completely unfamiliar with computer programming. Also centralized there is a discussion of some of the issues @@ -1101,12 +1106,12 @@ throughout the book. If you find terms that you aren't familiar with, try looking them up here. -@ref{Copying, ,GNU General Public License}, and +@ref{Copying}, and @ref{GNU Free Documentation License}, present the licenses that cover the @command{gawk} source code and this @value{DOCUMENT}, respectively. -@node Conventions, Manual History, This Manual, Preface +@node Conventions @section Typographical Conventions @cindex Texinfo @@ -1181,7 +1186,7 @@ coverage of dark corners is, by definition, something that is incomplete. -@node Manual History, How To Contribute, Conventions, Preface +@node Manual History @unnumberedsec The GNU Project and This Book @cindex FSF (Free Software Foundation) @@ -1208,7 +1213,7 @@ in this @value{DOCUMENT} @end ifnotinfo for your reference -(@pxref{Copying, ,GNU General Public License}). +(@pxref{Copying}). The GPL applies to the C language source code for @command{gawk}. To find out more about the FSF and the GNU Project online, see @uref{http://www.gnu.org, the GNU Project's home page}. @@ -1290,12 +1295,12 @@ but with significant additional material, reflecting the host of new features in @command{gawk} @value{PVERSION} @value{VERSION}. Of particular note is -@ref{Array Sorting, ,Sorting Array Values and Indices with @command{gawk}}, -@ref{Bitwise Functions, ,Using @command{gawk}'s Bit Manipulation Functions}, -@ref{Internationalization, ,Internationalization with @command{gawk}}, -@ref{Advanced Features, ,Advanced Features of @command{gawk}}, +@ref{Array Sorting}, +@ref{Bitwise Functions}, +@ref{Internationalization}, +@ref{Advanced Features}, and -@ref{Dynamic Extensions, ,Adding New Built-in Functions to @command{gawk}}. +@ref{Dynamic Extensions}. @end ignore @cindex Close, Diane @@ -1318,23 +1323,23 @@ but with significant additional material, reflecting the host of new features in @command{gawk} @value{PVERSION} @value{VERSION}. Of particular note is -@ref{Array Sorting, ,Sorting Array Values and Indices with @command{gawk}}, +@ref{Array Sorting}, as well as -@ref{Bitwise Functions, ,Using @command{gawk}'s Bit Manipulation Functions}, -@ref{Internationalization, ,Internationalization with @command{gawk}}, +@ref{Bitwise Functions}, +@ref{Internationalization}, and also -@ref{Advanced Features, ,Advanced Features of @command{gawk}}, +@ref{Advanced Features}, and -@ref{Dynamic Extensions, ,Adding New Built-in Functions to @command{gawk}}. +@ref{Dynamic Extensions}. @cite{@value{TITLE}} will undoubtedly continue to evolve. An electronic version comes with the @command{gawk} distribution from the FSF. If you find an error in this @value{DOCUMENT}, please report it! -@xref{Bugs, ,Reporting Problems and Bugs}, for information on submitting +@xref{Bugs}, for information on submitting problem reports electronically, or write to me in care of the publisher. -@node How To Contribute, Acknowledgments, Manual History, Preface +@node How To Contribute @unnumberedsec How to Contribute As the maintainer of GNU @command{awk}, @@ -1348,7 +1353,7 @@ Making things available on the Internet helps keep the @command{gawk} distribution down to manageable size. -@node Acknowledgments, , How To Contribute, Preface +@node Acknowledgments @unnumberedsec Acknowledgments The initial draft of @cite{The GAWK Manual} had the following acknowledgments: @@ -1500,37 +1505,37 @@ @itemize @bullet @item -@ref{Getting Started, ,Getting Started with @command{awk}}. +@ref{Getting Started}. @item -@ref{Regexp, ,Regular Expressions}. +@ref{Regexp}. @item -@ref{Reading Files, , Reading Input Files}. +@ref{Reading Files}. @item -@ref{Printing, , Printing Output}. +@ref{Printing}. @item @ref{Expressions}. @item -@ref{Patterns and Actions, ,Patterns Actions and Variables}. +@ref{Patterns and Actions}. @item -@ref{Arrays, ,Arrays in @command{awk}}. +@ref{Arrays}. @item @ref{Functions}. @item -@ref{Internationalization, ,Internationalization with @command{gawk}}. +@ref{Internationalization}. @item -@ref{Advanced Features, ,Advanced Features of @command{gawk}}. +@ref{Advanced Features}. @item -@ref{Invoking Gawk, ,Running @command{awk} and @command{gawk}}. +@ref{Invoking Gawk}. @end itemize @page @@ -1539,7 +1544,7 @@ @end iftex @end ignore -@node Getting Started, Regexp, Preface, Top +@node Getting Started @chapter Getting Started with @command{awk} @c @cindex script, definition of @c @cindex rule, definition of @@ -1573,7 +1578,7 @@ tells @command{awk} what to do. The program consists of a series of @dfn{rules}. (It may also contain @dfn{function definitions}, an advanced feature that we will ignore for now. -@xref{User-defined, ,User-Defined Functions}.) Each rule specifies one +@xref{User-defined}.) Each rule specifies one pattern to search for and one action to perform upon finding the pattern. @@ -1604,7 +1609,7 @@ other things. @end menu -@node Running gawk, Sample Data Files, Getting Started, Getting Started +@node Running gawk @section How to Run @command{awk} Programs @cindex @command{awk} programs, running @@ -1640,7 +1645,7 @@ * Quoting:: More discussion of shell quoting issues. @end menu -@node One-shot, Read Terminal, Running gawk, Running gawk +@node One-shot @subsection One-Shot Throwaway @command{awk} Programs Once you are familiar with @command{awk}, you will often type in simple @@ -1672,7 +1677,7 @@ file for the @command{awk} program. A self-contained shell script is more reliable because there are no other files to misplace. -@ref{Very Simple, ,Some Simple Examples}, +@ref{Very Simple}, @ifnotinfo later in this @value{CHAPTER}, @end ifnotinfo @@ -1696,7 +1701,7 @@ @end example @end ignore -@node Read Terminal, Long, One-shot, Running gawk +@node Read Terminal @subsection Running @command{awk} Without Input Files @cindex standard input @@ -1758,7 +1763,7 @@ @kbd{@value{CTL}-d} @end example -@node Long, Executable Scripts, Read Terminal, Running gawk +@node Long @subsection Running Long Programs @cindex @command{awk} programs, running @@ -1800,7 +1805,7 @@ @cindex quoting @noindent This was explained earlier -(@pxref{Read Terminal, ,Running @command{awk} Without Input Files}). +(@pxref{Read Terminal}). Note that you don't usually need single quotes around the @value{FN} that you specify with @option{-f}, because most @value{FN}s don't contain any of the shell's special characters. Notice that in @file{advice}, the @command{awk} @@ -1816,7 +1821,7 @@ affect the execution of the @command{awk} program but it does make ``housekeeping'' easier. -@node Executable Scripts, Comments, Long, Running gawk +@node Executable Scripts @subsection Executable @command{awk} Programs @cindex @command{awk} programs @cindex @code{#} (number sign), @code{#!} (executable scripts) @@ -1891,7 +1896,7 @@ of your script (@samp{advice}). Don't rely on the value of @code{ARGV[0]} to provide your script name. -@node Comments, Quoting, Executable Scripts, Running gawk +@node Comments @subsection Comments in @command{awk} Programs @cindex @code{#} (number sign), commenting @cindex number sign (@code{#}), commenting @@ -1925,7 +1930,7 @@ @cindex single quote (@code{'}), vs. apostrophe @cindex @code{'} (single quote), vs. apostrophe @strong{Caution:} As mentioned in -@ref{One-shot, ,One-Shot Throwaway @command{awk} Programs}, +@ref{One-shot}, you can enclose small to medium programs in single quotes, in order to keep your shell scripts self-contained. When doing so, @emph{don't} put an apostrophe (i.e., a single quote) into a comment (or anywhere else @@ -1958,7 +1963,7 @@ since backslashes are not special inside single quotes. The next @value{SUBSECTION} describes the shell's quoting rules. -@node Quoting, , Comments, Running gawk +@node Quoting @subsection Shell-Quoting Issues @cindex quoting, rules for @@ -2000,7 +2005,7 @@ to the command. It is @emph{impossible} to embed a single quote inside single-quoted text. Refer back to -@ref{Comments, ,Comments in @command{awk} Programs}, +@ref{Comments}, for an example of what happens if you try. @item @@ -2019,7 +2024,7 @@ @ifnotinfo previously @end ifnotinfo -in @ref{Read Terminal, ,Running @command{awk} Without Input Files}, +in @ref{Read Terminal}, is applicable: @example @@ -2050,7 +2055,7 @@ @end example @noindent -In the second case, @command{awk} will attempt to use the text of the program +In the second case, @command{awk} will attempt to use the text of the program as the value of @code{FS}, and the first @value{FN} as the text of the program! This results in syntax errors at best, and confusing behavior at worst. @end itemize @@ -2096,7 +2101,7 @@ program, it is probably best to move it into a separate file, where the shell won't be part of the picture, and you can say what you mean. -@node Sample Data Files, Very Simple, Running gawk, Getting Started +@node Sample Data Files @section @value{DDF}s for the Examples @c For gawk >= 3.2, update these data files. No-one has such slow modems! @@ -2182,12 +2187,12 @@ @cindex Texinfo If you are using the stand-alone version of Info, -see @ref{Extract Program, ,Extracting Programs from Texinfo Source Files}, +see @ref{Extract Program}, for an @command{awk} program that extracts these @value{DF}s from @file{gawk.texi}, the Texinfo source file for this Info file. @end ifinfo -@node Very Simple, Two Rules, Sample Data Files, Getting Started +@node Very Simple @section Some Simple Examples The following command runs a simple @command{awk} program that searches the @@ -2210,7 +2215,7 @@ in the @command{awk} program. The slashes indicate that @samp{foo} is the pattern to search for. This type of pattern is called a @dfn{regular expression}, which is covered in more detail later -(@pxref{Regexp, ,Regular Expressions}). +(@pxref{Regexp}). The pattern is allowed to match parts of words. There are single quotes around the @command{awk} program so that the shell won't @@ -2346,7 +2351,7 @@ the program would print the odd-numbered lines. @end itemize -@node Two Rules, More Complex, Very Simple, Getting Started +@node Two Rules @section An Example with Two Rules @cindex @command{awk} programs @@ -2358,8 +2363,8 @@ After processing all the rules that match the line (and perhaps there are none), @command{awk} reads the next line. (However, -@pxref{Next Statement, ,The @code{next} Statement}, -and also @pxref{Nextfile Statement, ,Using @command{gawk}'s @code{nextfile} Statement}). +@pxref{Next Statement}, +and also @pxref{Nextfile Statement}). This continues until the program reaches the end of the file. For example, the following @command{awk} program contains two rules: @@ -2403,7 +2408,7 @@ Note how the line beginning with @samp{sabafoo} in @file{BBS-list} was printed twice, once for each rule. -@node More Complex, Statements/Lines, Two Rules, Getting Started +@node More Complex @section A More Complex Example Now that we've mastered some simple tasks, let's look at @@ -2426,7 +2431,7 @@ current directory that were last modified in November (of any year). @footnote{In the C shell (@command{csh}), you need to type a semicolon and then a backslash at the end of the first line; see -@ref{Statements/Lines, ,@command{awk} Statements Versus Lines}, for an +@ref{Statements/Lines}, for an explanation. In a POSIX-compliant shell, such as the Bourne shell or @command{bash}, you can type the example as shown. If the command @samp{echo $path} produces an empty output line, you are most likely @@ -2475,13 +2480,13 @@ In this example, the value of @code{sum} is 80600. These more advanced @command{awk} techniques are covered in later sections -(@pxref{Action Overview, ,Actions}). Before you can move on to more +(@pxref{Action Overview}). Before you can move on to more advanced @command{awk} programming, you have to know how @command{awk} interprets your input and displays your output. By manipulating fields and using @code{print} statements, you can produce some very useful and impressive-looking reports. -@node Statements/Lines, Other Features, More Complex, Getting Started +@node Statements/Lines @section @command{awk} Statements Versus Lines @cindex line breaks @cindex newlines @@ -2506,10 +2511,10 @@ A newline at any other point is considered the end of the statement.@footnote{The @samp{?} and @samp{:} referred to here is the three-operand conditional expression described in -@ref{Conditional Exp, ,Conditional Expressions}. +@ref{Conditional Exp}. Splitting lines after @samp{?} and @samp{:} is a minor @command{gawk} extension; if @option{--posix} is specified -(@pxref{Options, , Command-Line Options}), then this extension is disabled.} +(@pxref{Options}), then this extension is disabled.} @cindex @code{\} (backslash), continuing lines and @cindex backslash (@code{\}), continuing lines and @@ -2623,7 +2628,7 @@ language; it was added for consistency with the treatment of statements within an action. -@node Other Features, When, Statements/Lines, Getting Started +@node Other Features @section Other Features of @command{awk} @cindex variables @@ -2640,9 +2645,9 @@ As we develop our presentation of the @command{awk} language, we introduce most of the variables and many of the functions. They are defined systematically in @ref{Built-in Variables}, and -@ref{Built-in, ,Built-in Functions}. +@ref{Built-in}. -@node When, , Other Features, Getting Started +@node When @section When to Use @command{awk} @cindex @command{awk}, uses for @@ -2653,7 +2658,7 @@ complex output. The @command{awk} language is very useful for producing reports from large amounts of raw data, such as summarizing information from the output of other utility programs like @command{ls}. -(@xref{More Complex, ,A More Complex Example}.) +(@xref{More Complex}.) Programs written with @command{awk} are usually much smaller than they would be in other languages. This makes @command{awk} programs easy to compose and @@ -2680,7 +2685,7 @@ of source code than the equivalent @command{awk} programs, but they are easier to maintain and usually run more efficiently. -@node Regexp, Reading Files, Getting Started, Top +@node Regexp @chapter Regular Expressions @cindex regexp, See regular expressions @c STARTOFRANGE regexp @@ -2721,7 +2726,7 @@ * Locales:: How the locale affects things. @end menu -@node Regexp Usage, Escape Sequences, Regexp, Regexp +@node Regexp Usage @section How to Use Regular Expressions @cindex regular expressions, as patterns @@ -2761,7 +2766,7 @@ and @samp{!~} perform regular expression comparisons. Expressions using these operators can be used as patterns, or in @code{if}, @code{while}, @code{for}, and @code{do} statements. -(@xref{Statements, ,Control Statements in Actions}.) +(@xref{Statements}.) For example: @example @@ -2815,7 +2820,7 @@ a @dfn{regexp constant}, much like @code{5.27} is a numeric constant and @code{"foo"} is a string constant. -@node Escape Sequences, Regexp Operators, Regexp Usage, Regexp +@node Escape Sequences @section Escape Sequences @cindex escape sequences @@ -2933,11 +2938,11 @@ In @command{gawk}, a number of additional two-character sequences that begin with a backslash have special meaning in regexps. -@xref{GNU Regexp Operators, ,@command{gawk}-Specific Regexp Operators}. +@xref{GNU Regexp Operators}. In a regexp, a backslash before any character that is not in the previous list and not listed in -@ref{GNU Regexp Operators, ,@command{gawk}-Specific Regexp Operators}, +@ref{GNU Regexp Operators}, means that the next character should be taken literally, even if it would normally be a regexp operator. For example, @code{/a\+b/} matches the three characters @samp{a+b}. @@ -2958,9 +2963,9 @@ @item @command{gawk} processes both regexp constants and dynamic regexps -(@pxref{Computed Regexps, ,Using Dynamic Regexps}), +(@pxref{Computed Regexps}), for the special operators listed in -@ref{GNU Regexp Operators, ,@command{gawk}-Specific Regexp Operators}. +@ref{GNU Regexp Operators}. @item A backslash before any other character means to treat that character @@ -3006,7 +3011,7 @@ Suppose you use an octal or hexadecimal escape to represent a regexp metacharacter. -(See @ref{Regexp Operators, , Regular Expression Operators}.) +(See @ref{Regexp Operators}.) Does @command{awk} treat the character as a literal character or as a regexp operator? @@ -3015,12 +3020,12 @@ @value{DARKCORNER} However, the POSIX standard indicates that they should be treated as real metacharacters, which is what @command{gawk} does. -In compatibility mode (@pxref{Options, ,Command-Line Options}), +In compatibility mode (@pxref{Options}), @command{gawk} treats the characters represented by octal and hexadecimal escape sequences literally when used in regexp constants. Thus, @code{/a\52b/} is equivalent to @code{/a\*b/}. -@node Regexp Operators, Character Lists, Escape Sequences, Regexp +@node Regexp Operators @section Regular Expression Operators @c STARTOFRANGE regexpo @cindex regular expressions, operators @@ -3093,7 +3098,7 @@ @c comma before using does NOT do tertiary @cindex POSIX @command{awk}, period (@code{.}), using -In strict POSIX mode (@pxref{Options, ,Command-Line Options}), +In strict POSIX mode (@pxref{Options}), @samp{.} does not match the @sc{nul} character, which is a character with all bits equal to zero. Otherwise, @sc{nul} is just another character. Other versions of @command{awk} @@ -3113,7 +3118,7 @@ the characters @samp{M}, @samp{V}, or @samp{X} in a string. A full discussion of what can be inside the square brackets of a character list is given in -@ref{Character Lists, ,Using Character Lists}. +@ref{Character Lists}. @cindex character lists, complemented @item [^ @dots{}] @@ -3137,7 +3142,7 @@ The alternation applies to the largest possible regexps on either side. @cindex @code{()} (parentheses) -@cindex parentheses @code{()} +@cindex parentheses @code{()} @item (@dots{}) Parentheses are used for grouping in regular expressions, as in arithmetic. They can be used to concatenate regular expressions @@ -3218,7 +3223,7 @@ However, because old programs may use @samp{@{} and @samp{@}} in regexp constants, by default @command{gawk} does @emph{not} match interval expressions in regexps. If either @option{--posix} or @option{--re-interval} are specified -(@pxref{Options, , Command-Line Options}), then interval expressions +(@pxref{Options}), then interval expressions are allowed in regexps. For new programs that use @samp{@{} and @samp{@}} in regexp constants, @@ -3244,12 +3249,12 @@ @command{awk} treat such a usage as a syntax error. If @command{gawk} is in compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), POSIX character classes and interval expressions are not available in regular expressions. @c ENDOFRANGE regexpo -@node Character Lists, GNU Regexp Operators, Regexp Operators, Regexp +@node Character Lists @section Using Character Lists @c STARTOFRANGE charlist @cindex character lists @@ -3423,7 +3428,7 @@ @c maybe one day ... @c ENDOFRANGE charlist -@node GNU Regexp Operators, Case-sensitivity, Character Lists, Regexp +@node GNU Regexp Operators @section @command{gawk}-Specific Regexp Operators @c This section adapted (long ago) from the regex-0.12 manual @@ -3546,7 +3551,7 @@ @cindex regular expressions, @command{gawk}, command-line options @cindex @command{gawk}, command-line options The various command-line options -(@pxref{Options, ,Command-Line Options}) +(@pxref{Options}) control how @command{gawk} interprets characters in regexps: @table @asis @@ -3559,7 +3564,7 @@ @end ifnotinfo @ifnottex GNU regexp operators described -in @ref{Regexp Operators, ,Regular Expression Operators}. +in @ref{Regexp Operators}. @end ifnottex However, interval expressions are not supported. @@ -3584,7 +3589,7 @@ @c ENDOFRANGE gregexp @c ENDOFRANGE regexpg -@node Case-sensitivity, Leftmost Longest, GNU Regexp Operators, Regexp +@node Case-sensitivity @section Case Sensitivity in Matching @c STARTOFRANGE regexpcs @@ -3605,7 +3610,7 @@ program is to convert the data to a single case, using the @code{tolower} or @code{toupper} built-in string functions (which we haven't discussed yet; -@pxref{String Functions, ,String Manipulation Functions}). +@pxref{String Functions}). For example: @example @@ -3656,8 +3661,8 @@ case-sensitivity on or off for all the rules at once. @code{IGNORECASE} can be set on the command line or in a @code{BEGIN} rule -(@pxref{Other Arguments, ,Other Command-Line Arguments}; also -@pxref{Using BEGIN/END, ,Startup and Cleanup Actions}). +(@pxref{Other Arguments}; also +@pxref{Using BEGIN/END}). Setting @code{IGNORECASE} from the command line is a way to make a program case-insensitive without having to edit it. @@ -3677,12 +3682,12 @@ for use with European languages. The value of @code{IGNORECASE} has no effect if @command{gawk} is in -compatibility mode (@pxref{Options, ,Command-Line Options}). +compatibility mode (@pxref{Options}). Case is always significant in compatibility mode. @c ENDOFRANGE csregexp @c ENDOFRANGE regexpcs -@node Leftmost Longest, Computed Regexps, Case-sensitivity, Regexp +@node Leftmost Longest @section How Much Text Matches? @cindex regular expressions, leftmost longest match @@ -3694,7 +3699,7 @@ @end example This example uses the @code{sub} function (which we haven't discussed yet; -@pxref{String Functions, ,String Manipulation Functions}) +@pxref{String Functions}) to make a change to the input record. Here, the regexp @code{/a+/} indicates ``one or more @samp{a} characters,'' and the replacement text is @samp{}. @@ -3714,14 +3719,14 @@ text matching and substitutions with the @code{match}, @code{sub}, @code{gsub}, and @code{gensub} functions, it is very important. @ifinfo -@xref{String Functions, ,String Manipulation Functions}, +@xref{String Functions}, for more information on these functions. @end ifinfo Understanding this principle is also important for regexp-based record -and field splitting (@pxref{Records, ,How Input Is Split into Records}, -and also @pxref{Field Separators, ,Specifying How Fields Are Separated}). +and field splitting (@pxref{Records}, +and also @pxref{Field Separators}). -@node Computed Regexps, Locales, Leftmost Longest, Regexp +@node Computed Regexps @section Using Dynamic Regexps @c STARTOFRANGE dregexp @@ -3837,7 +3842,7 @@ @c ENDOFRANGE regexpd @c ENDOFRANGE regexp -@node Locales, , Computed Regexps, Regexp +@node Locales @section Where You Are Makes A Difference Modern systems support the notion of @dfn{locales}: a way to tell @@ -3849,7 +3854,7 @@ The following example uses the @code{sub} function, which does text replacement -(@pxref{String Functions, , String-Manipulation Functions}). +(@pxref{String Functions}). Here, the intent is to remove trailing uppercase characters: @example @@ -3868,7 +3873,7 @@ by using the shell statements: @example -LANG=C LC_ALL=C +LANG=C LC_ALL=C export LANG LC_ALL @end example @@ -3877,7 +3882,19 @@ You may wish to put these statements into your shell startup file, e.g., @file{$HOME/.profile}. -@node Reading Files, Printing, Regexp, Top +Similar considerations apply to other ranges. For example, +@samp{["-/]} is perfectly valid in ASCII, but is not valid in many +Unicode locales, such as @samp{en_US.UTF-8}. (In general, such +ranges should be avoided; either list the characters individually, +or use a POSIX character class such as @samp{[[:punct:]]}.) + +For the normal case of @samp{RS = "\n"}, the locale is largely irrelevant. +For other single byte record separators, using @samp{LC_ALL=C} will give you +much better performance when reading records. Otherwise, @command{gawk} has +to make several function calls, @emph{per input character} to find the record +terminator. + +@node Reading Files @chapter Reading Input Files @c STARTOFRANGE infir @@ -3906,7 +3923,7 @@ The @code{getline} command is valuable, both because it can do explicit input from any number of files, and because the files used with it do not have to be named on the @command{awk} command line -(@pxref{Getline, ,Explicit Input with @code{getline}}). +(@pxref{Getline}). @menu * Records:: Controlling how data is split into records. @@ -3920,7 +3937,7 @@ using the @code{getline} function. @end menu -@node Records, Fields, Reading Files, Reading Files +@node Records @section How Input Is Split into Records @c STARTOFRANGE inspl @@ -3953,13 +3970,13 @@ Like any other variable, the value of @code{RS} can be changed in the @command{awk} program with the assignment operator, @samp{=} -(@pxref{Assignment Ops, ,Assignment Expressions}). +(@pxref{Assignment Ops}). The new record-separator character should be enclosed in quotation marks, which indicate a string constant. Often the right time to do this is at the beginning of execution, before any input is processed, so that the very first record is read with the proper separator. To do this, use the special @code{BEGIN} pattern -(@pxref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}). +(@pxref{BEGIN/END}). For example: @cindex @code{BEGIN} pattern @@ -4012,7 +4029,7 @@ @noindent Note that the entry for the @samp{camelot} BBS is not split. In the original @value{DF} -(@pxref{Sample Data Files, ,@value{DDF}s for the Examples}), +(@pxref{Sample Data Files}), the line looks like this: @example @@ -4031,7 +4048,7 @@ @cindex separators, for records Another way to change the record separator is on the command line, using the variable-assignment feature -(@pxref{Other Arguments, ,Other Command-Line Arguments}): +(@pxref{Other Arguments}): @example awk '@{ print $0 @}' RS="/" BBS-list @@ -4063,7 +4080,7 @@ has a special meaning as the value of @code{RS}. It means that records are separated by one or more blank lines and nothing else. -@xref{Multiple Line, ,Multiple-Line Records}, for more details. +@xref{Multiple Line}, for more details. If you change the value of @code{RS} in the middle of an @command{awk} run, the new value is used to delimit subsequent records, but the record @@ -4083,7 +4100,7 @@ When using @command{gawk}, the value of @code{RS} is not limited to a one-character string. It can be any regular expression -(@pxref{Regexp, ,Regular Expressions}). +(@pxref{Regexp}). In general, each record ends at the next string that matches the regular expression; the next record starts at the end of the matching string. This general rule is @@ -4107,9 +4124,9 @@ $ echo record 1 AAAA record 2 BBBB record 3 | > gawk 'BEGIN @{ RS = "\n|( *[[:upper:]]+ *)" @} > @{ print "Record =", $0, "and RT =", RT @}' -@print{} Record = record 1 and RT = AAAA -@print{} Record = record 2 and RT = BBBB -@print{} Record = record 3 and RT = +@print{} Record = record 1 and RT = AAAA +@print{} Record = record 2 and RT = BBBB +@print{} Record = record 3 and RT = @print{} @end example @@ -4117,7 +4134,7 @@ The final line of output has an extra blank line. This is because the value of @code{RT} is a newline, and the @code{print} statement supplies its own terminating newline. -@xref{Simple Sed, ,A Simple Stream Editor}, for a more useful example +@xref{Simple Sed}, for a more useful example of @code{RS} as a regexp and @code{RT}. If you set @code{RS} to a regular expression that allows optional @@ -4132,7 +4149,7 @@ The use of @code{RS} as a regular expression and the @code{RT} variable are @command{gawk} extensions; they are not available in compatibility mode -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). In compatibility mode, only the first character of the value of @code{RS} is used to determine the end of the record. @@ -4177,7 +4194,7 @@ @c ENDOFRANGE inspl @c ENDOFRANGE recspl -@node Fields, Nonconstant Fields, Records, Reading Files +@node Fields @section Examining Fields @cindex examining fields @@ -4257,7 +4274,7 @@ This example prints each record in the file @file{BBS-list} whose first field contains the string @samp{foo}. The operator @samp{~} is called a @dfn{matching operator} -(@pxref{Regexp Usage, , How to Use Regular Expressions}); +(@pxref{Regexp Usage}); it tests whether a string (here, the field @code{$1}) matches a given regular expression. @@ -4274,7 +4291,7 @@ @end example @c ENDOFRANGE fiex -@node Nonconstant Fields, Changing Fields, Fields, Reading Files +@node Nonconstant Fields @section Nonconstant Field Numbers @cindex fields, numbers @cindex field numbers @@ -4310,7 +4327,7 @@ hours of operation (the fourth field) for every line of the file @file{BBS-list}. (All of the @command{awk} operators are listed, in order of decreasing precedence, in -@ref{Precedence, , Operator Precedence (How Operators Nest)}.) +@ref{Precedence}.) If the field number you compute is zero, you get the entire record. Thus, @samp{$(2-2)} has the same value as @code{$0}. Negative field @@ -4320,13 +4337,13 @@ notices this and terminates your program. Other @command{awk} implementations may behave differently.) -As mentioned in @ref{Fields, ,Examining Fields}, +As mentioned in @ref{Fields}, @command{awk} stores the current record's number of fields in the built-in variable @code{NF} (also @pxref{Built-in Variables}). The expression @code{$NF} is not a special feature---it is the direct consequence of evaluating @code{NF} and using its value as a field number. -@node Changing Fields, Field Separators, Nonconstant Fields, Reading Files +@node Changing Fields @section Changing the Contents of a Field @c STARTOFRANGE ficon @@ -4351,7 +4368,7 @@ @code{nboxes}. The @samp{-} sign represents subtraction, so this program reassigns field three, @code{$3}, as the original value of field three minus ten: -@samp{$3 - 10}. (@xref{Arithmetic Ops, ,Arithmetic Operators}.) +@samp{$3 - 10}. (@xref{Arithmetic Ops}.) Then it prints the original and new values for field three. (Someone in the warehouse made a consistent mistake while inventorying the red boxes.) @@ -4361,7 +4378,7 @@ for the computer to do arithmetic on it. The number resulting from the subtraction is converted back to a string of characters that then becomes field three. -@xref{Conversion, ,Conversion of Strings and Numbers}. +@xref{Conversion}. When the value of a field is changed (as perceived by @command{awk}), the text of the input record is recalculated to contain the new field where @@ -4408,7 +4425,7 @@ @cindex output field separator, See @code{OFS} variable @cindex field separators, See Also @code{OFS} This recomputation affects and is affected by -@code{NF} (the number of fields; @pxref{Fields, ,Examining Fields}). +@code{NF} (the number of fields; @pxref{Fields}). For example, the value of @code{NF} is set to the number of the highest field you create. The exact format of @code{$0} is also affected by a feature that has not been discussed yet: @@ -4429,9 +4446,9 @@ @noindent should print @samp{everything is normal}, because @code{NF+1} is certain -to be out of range. (@xref{If Statement, ,The @code{if}-@code{else} Statement}, +to be out of range. (@xref{If Statement}, for more information about @command{awk}'s @code{if-else} statements. -@xref{Typing and Comparison, ,Variable Typing and Comparison Expressions}, +@xref{Typing and Comparison}, for more information about the @samp{!=} operator.) It is important to note that making an assignment to an existing field @@ -4502,10 +4519,10 @@ reparsed into fields using the @emph{current} value of @code{FS}. This also applies to any built-in function that updates @code{$0}, such as @code{sub} and @code{gsub} -(@pxref{String Functions, ,String-Manipulation Functions}). +(@pxref{String Functions}). @c ENDOFRANGE ficon -@node Field Separators, Constant Size, Changing Fields, Reading Files +@node Field Separators @section Specifying How Fields Are Separated @menu @@ -4547,12 +4564,12 @@ @cindex @code{FS} variable, changing value of The value of @code{FS} can be changed in the @command{awk} program with the -assignment operator, @samp{=} (@pxref{Assignment Ops, ,Assignment Expressions}). +assignment operator, @samp{=} (@pxref{Assignment Ops}). Often the right time to do this is at the beginning of execution before any input has been processed, so that the very first record is read with the proper separator. To do this, use the special @code{BEGIN} pattern -(@pxref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}). +(@pxref{BEGIN/END}). For example, here we set the value of @code{FS} to the string @code{","}: @@ -4612,7 +4629,7 @@ space character is the only single character that does not follow these rules. -@node Regexp Field Splitting, Single Character Fields, Field Separators, Field Separators +@node Regexp Field Splitting @subsection Using Regular Expressions to Separate Fields @c STARTOFRANGE regexpfs @@ -4644,7 +4661,7 @@ single spaces to separate fields the way single commas are used. @code{FS} can be set to @w{@code{"[@ ]"}} (left bracket, space, right bracket). This regular expression matches a single space and nothing else -(@pxref{Regexp, ,Regular Expressions}). +(@pxref{Regexp}). There is an important difference between the two cases of @samp{FS = @w{" "}} (a single space) and @samp{FS = @w{"[ \t\n]+"}} @@ -4696,7 +4713,7 @@ @c ENDOFRANGE regexpfs @c ENDOFRANGE fsregexp -@node Single Character Fields, Command Line Field Separator, Regexp Field Splitting, Field Separators +@node Single Character Fields @subsection Making Each Character a Separate Field @cindex differences in @command{awk} and @command{gawk}, single-character fields @@ -4726,11 +4743,11 @@ as only having one field. @value{DARKCORNER} In compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), if @code{FS} is the null string, then @command{gawk} also behaves this way. -@node Command Line Field Separator, Field Splitting Summary, Single Character Fields, Field Separators +@node Command Line Field Separator @subsection Setting @code{FS} from the Command Line @cindex @code{-F} option @cindex options, command-line @@ -4778,7 +4795,7 @@ @c @cindex historical features As a special case, in compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), if the argument to @option{-F} is @samp{t}, then @code{FS} is set to the TAB character. If you type @samp{-F\t} at the shell, without any quotes, the @samp{\} gets deleted, so @command{awk} @@ -4849,7 +4866,7 @@ awk -F: '$2 == ""' /etc/passwd @end example -@node Field Splitting Summary, , Command Line Field Separator, Field Separators +@node Field Splitting Summary @subsection Field-Splitting Summary It is important to remember that when you assign a string constant @@ -4935,7 +4952,7 @@ @subheading Advanced Notes: @code{FS} and @code{IGNORECASE} The @code{IGNORECASE} variable -(@pxref{User-modified, ,Built-in Variables That Control @command{awk}}) +(@pxref{User-modified}) affects field splitting @emph{only} when the value of @code{FS} is a regexp. It has no effect when @code{FS} is a single character, even if that character is a letter. Thus, in the following code: @@ -4956,7 +4973,7 @@ @c ENDOFRANGE fisepr @c ENDOFRANGE fisepg -@node Constant Size, Multiple Line, Field Separators, Reading Files +@node Constant Size @section Reading Fixed-Width Data @ifnotinfo @@ -4985,7 +5002,7 @@ spaces}. Clearly, @command{awk}'s normal field splitting based on @code{FS} does not work well in this case. Although a portable @command{awk} program can use a series of @code{substr} calls on @code{$0} -(@pxref{String Functions, ,String Manipulation Functions}), +(@pxref{String Functions}), this is awkward and inefficient for a large number of fields. @c comma before specifying is part of tertiary @@ -5076,7 +5093,7 @@ without having to know the current value of @code{FS}. In order to tell which kind of field splitting is in effect, use @code{PROCINFO["FS"]} -(@pxref{Auto-set, ,Built-in Variables That Convey Information}). +(@pxref{Auto-set}). The value is @code{"FS"} if regular field splitting is being used, or it is @code{"FIELDWIDTHS"} if fixed-width field splitting is being used: @@ -5090,10 +5107,10 @@ This information is useful when writing a function that needs to temporarily change @code{FS} or @code{FIELDWIDTHS}, read some records, and then restore the original settings -(@pxref{Passwd Functions, ,Reading the User Database}, +(@pxref{Passwd Functions}, for an example of such a function). -@node Multiple Line, Getline, Constant Size, Reading Files +@node Multiple Line @section Multiple-Line Records @c STARTOFRANGE recm @@ -5134,7 +5151,7 @@ at the end of the record and one or more blank lines after the record. In addition, a regular expression always matches the longest possible sequence when there is a choice -(@pxref{Leftmost Longest, ,How Much Text Matches?}). +(@pxref{Leftmost Longest}). So the next record doesn't start until the first nonblank line that follows---no matter how many blank lines appear in a row, they are considered one record separator. @@ -5166,7 +5183,7 @@ want the newline character to separate fields, because there is no way to prevent it. However, you can work around this by using the @code{split} function to break up the record manually -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). If you have a single character field separator, you can work around the special feature in a different way, by making @code{FS} into a regexp for that single character. For example, if the field @@ -5217,15 +5234,15 @@ @print{} Name is: Jane Doe @print{} Address is: 123 Main Street @print{} City and State are: Anywhere, SE 12345-6789 -@print{} +@print{} @print{} Name is: John Smith @print{} Address is: 456 Tree-lined Avenue @print{} City and State are: Smallville, MW 98765-4321 -@print{} +@print{} @dots{} @end example -@xref{Labels Program, ,Printing Mailing Labels}, for a more realistic +@xref{Labels Program}, for a more realistic program that deals with address lists. The following table @@ -5268,7 +5285,7 @@ @c ENDOFRANGE imr @c ENDOFRANGE frm -@node Getline, , Multiple Line, Reading Files +@node Getline @section Explicit Input with @code{getline} @c STARTOFRANGE getl @@ -5316,7 +5333,7 @@ * Getline Summary:: Summary of @code{getline} Variants. @end menu -@node Plain Getline, Getline/Variable, Getline, Getline +@node Plain Getline @subsection Using @code{getline} with No Arguments The @code{getline} command can be used without arguments to read input @@ -5370,9 +5387,9 @@ is lost. By contrast, the @code{next} statement reads a new record but immediately begins processing it normally, starting with the first -rule in the program. @xref{Next Statement, ,The @code{next} Statement}. +rule in the program. @xref{Next Statement}. -@node Getline/Variable, Getline/File, Plain Getline, Getline +@node Getline/Variable @subsection Using @code{getline} into a Variable @c comma before using is NOT for tertiary @cindex variables, @code{getline} command into, using @@ -5422,7 +5439,7 @@ split into fields, so the values of the fields (including @code{$0}) and the value of @code{NF} do not change. -@node Getline/File, Getline/Variable/File, Getline/Variable, Getline +@node Getline/File @subsection Using @code{getline} from a File @cindex input redirection @@ -5462,10 +5479,8 @@ because the concatenation operator is not parenthesized. You should write it as @samp{getline < (dir "/" file)} if you want your program to be portable to other @command{awk} implementations. -(It happens that @command{gawk} gets it right, but you should not -rely on this. Parentheses make it easier to read.) -@node Getline/Variable/File, Getline/Pipe, Getline/File, Getline +@node Getline/Variable/File @subsection Using @code{getline} into a Variable from a File @c comma before using is NOT for tertiary @cindex variables, @code{getline} command into, using @@ -5502,16 +5517,16 @@ The @code{close} function is called to ensure that if two identical @samp{@@include} lines appear in the input, the entire specified file is included twice. -@xref{Close Files And Pipes, ,Closing Input and Output Redirections}. +@xref{Close Files And Pipes}. One deficiency of this program is that it does not process nested @samp{@@include} statements (i.e., @samp{@@include} statements in included files) the way a true macro preprocessor would. -@xref{Igawk Program, ,An Easy Way to Use Library Functions}, for a program +@xref{Igawk Program}, for a program that does handle nested @samp{@@include} statements. -@node Getline/Pipe, Getline/Variable/Pipe, Getline/Variable/File, Getline +@node Getline/Pipe @subsection Using @code{getline} from a Pipe @cindex @code{|} (vertical bar), @code{|} operator (I/O) @@ -5546,7 +5561,7 @@ @samp{@@execute} lines appear in the input, the command is run for each one. @ifnottex -@xref{Close Files And Pipes, ,Closing Input and Output Redirections}. +@xref{Close Files And Pipes}. @end ifnottex @c Exercise!! @c This example is unrealistic, since you could just use system @@ -5593,12 +5608,8 @@ because the concatenation operator is not parenthesized. You should write it as @samp{(@w{"echo "} "date") | getline} if you want your program to be portable to other @command{awk} implementations. -@ifinfo -(It happens that @command{gawk} gets it right, but you should not -rely on this. Parentheses make it easier to read, anyway.) -@end ifinfo -@node Getline/Variable/Pipe, Getline/Coprocess, Getline/Pipe, Getline +@node Getline/Variable/Pipe @subsection Using @code{getline} into a Variable from a Pipe @c comma before using is NOT for tertiary @cindex variables, @code{getline} command into, using @@ -5629,11 +5640,9 @@ because the concatenation operator is not parenthesized. You should write it as @samp{(@w{"echo "} "date") | getline @var{var}} if you want your program to be portable to other @command{awk} implementations. -(It happens that @command{gawk} gets it right, but you should not -rely on this. Parentheses make it easier to read, anyway.) @end ifinfo -@node Getline/Coprocess, Getline/Variable/Coprocess, Getline/Variable/Pipe, Getline +@node Getline/Coprocess @subsection Using @code{getline} from a Coprocess @cindex coprocesses, @code{getline} from @c comma before using is NOT for tertiary @@ -5672,10 +5681,10 @@ Coprocesses are an advanced feature. They are discussed here only because this is the @value{SECTION} on @code{getline}. -@xref{Two-way I/O, ,Two-Way Communications with Another Process}, +@xref{Two-way I/O}, where coprocesses are discussed in more detail. -@node Getline/Variable/Coprocess, Getline Notes, Getline/Coprocess, Getline +@node Getline/Variable/Coprocess @subsection Using @code{getline} into a Variable from a Coprocess @c comma before using is NOT for tertiary @cindex variables, @code{getline} command into, using @@ -5691,11 +5700,11 @@ @ifinfo Coprocesses are an advanced feature. They are discussed here only because this is the @value{SECTION} on @code{getline}. -@xref{Two-way I/O, ,Two-Way Communications with Another Process}, +@xref{Two-way I/O}, where coprocesses are discussed in more detail. @end ifinfo -@node Getline Notes, Getline Summary, Getline/Variable/Coprocess, Getline +@node Getline Notes @subsection Points to Remember About @code{getline} Here are some miscellaneous points about @code{getline} that you should bear in mind: @@ -5731,8 +5740,8 @@ @code{FILENAME} does not have a value inside @code{BEGIN} rules, because you have not yet started to process the command-line @value{DF}s. @value{DARKCORNER} -(@xref{BEGIN/END, , The @code{BEGIN} and @code{END} Special Patterns}, -also @pxref{Auto-set, ,Built-in Variables That Convey Information}.) +(@xref{BEGIN/END}, +also @pxref{Auto-set}.) @item Using @code{FILENAME} with @code{getline} @@ -5745,7 +5754,7 @@ trying to accomplish. @end itemize -@node Getline Summary, , Getline Notes, Getline +@node Getline Summary @subsection Summary of @code{getline} Variants @cindex @code{getline} command, variants @@ -5775,7 +5784,7 @@ @c ENDOFRANGE inex @c ENDOFRANGE infir -@node Printing, Expressions, Reading Files, Top +@node Printing @chapter Printing Output @c STARTOFRANGE prnt @@ -5790,9 +5799,9 @@ you cannot specify @emph{how} to print them---how many columns, whether to use exponential notation or not, and so on. (For the exceptions, @pxref{Output Separators}, and -@ref{OFMT, ,Controlling Numeric Output with @code{print}}.) +@ref{OFMT}.) For printing with specifications, you need the @code{printf} statement -(@pxref{Printf, ,Using @code{printf} Statements for Fancier Printing}). +(@pxref{Printf}). @c STARTOFRANGE prnts @cindex @code{print} statement @@ -5816,7 +5825,7 @@ * Close Files And Pipes:: Closing Input and Output Files and Pipes. @end menu -@node Print, Print Examples, Printing, Printing +@node Print @section The @code{print} Statement The @code{print} statement is used to produce output with simple, standardized @@ -5832,7 +5841,7 @@ The entire list of items may be optionally enclosed in parentheses. The parentheses are necessary if any of the item expressions uses the @samp{>} relational operator; otherwise it could be confused with a redirection -(@pxref{Redirection, ,Redirecting Output of @code{print} and @code{printf}}). +(@pxref{Redirection}). The items to print can be constant strings or numbers, fields of the current record (such as @code{$1}), variables, or any @command{awk} @@ -5850,7 +5859,7 @@ expression, and you will probably get an error. Keep in mind that a space is printed between any two items. -@node Print Examples, Output Separators, Print, Printing +@node Print Examples @section Examples of @code{print} Statements Each @code{print} statement makes at least one line of output. However, it @@ -5907,7 +5916,7 @@ would make it clearer. Let's add some headings to our table of months (@code{$1}) and green crates shipped (@code{$2}). We do this using the @code{BEGIN} pattern -(@pxref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}) +(@pxref{BEGIN/END}) so that the headings are only printed once: @example @@ -5948,17 +5957,17 @@ complicated when there are many columns to fix. Counting spaces for two or three columns is simple, but any more than this can take up a lot of time. This is why the @code{printf} statement was -created (@pxref{Printf, ,Using @code{printf} Statements for Fancier Printing}); +created (@pxref{Printf}); one of its specialties is lining up columns of data. @cindex line continuations, in @code{print} statement @cindex @code{print} statement, line continuations and @strong{Note:} You can continue either a @code{print} or @code{printf} statement simply by putting a newline after any comma -(@pxref{Statements/Lines, ,@command{awk} Statements Versus Lines}). +(@pxref{Statements/Lines}). @c ENDOFRANGE prnts -@node Output Separators, OFMT, Print Examples, Printing +@node Output Separators @section Output Separators @cindex @code{OFS} variable @@ -5984,11 +5993,11 @@ In order to change how output fields and records are separated, assign new values to the variables @code{OFS} and @code{ORS}. The usual place to do this is in the @code{BEGIN} rule -(@pxref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}), so +(@pxref{BEGIN/END}), so that it happens before any input is processed. It can also be done with assignments on the command line, before the names of the input files, or using the @option{-v} command-line option -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). The following example prints the first and second fields of each input record, separated by a semicolon, with a blank line added after each newline: @@ -6008,9 +6017,9 @@ $ awk 'BEGIN @{ OFS = ";"; ORS = "\n\n" @} > @{ print $1, $2 @}' BBS-list @print{} aardvark;555-5553 -@print{} +@print{} @print{} alpo-net;555-3412 -@print{} +@print{} @print{} barfly;555-7685 @dots{} @end example @@ -6018,7 +6027,7 @@ If the value of @code{ORS} does not contain a newline, the program's output is run together on a single line. -@node OFMT, Printf, Output Separators, Printing +@node OFMT @section Controlling Numeric Output with @code{print} @cindex numeric, output format @c the comma does NOT start a secondary @@ -6027,13 +6036,13 @@ @command{awk} internally converts the number to a string of characters and prints that string. @command{awk} uses the @code{sprintf} function to do this conversion -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). For now, it suffices to say that the @code{sprintf} function accepts a @dfn{format specification} that tells it how to format numbers (or strings), and that there are a number of different ways in which numbers can be formatted. The different format specifications are discussed more fully in -@ref{Control Letters, , Format-Control Letters}. +@ref{Control Letters}. @cindex @code{sprintf} function @cindex @code{OFMT} variable @@ -6062,7 +6071,7 @@ if @code{OFMT} contains anything but a floating-point conversion specification. @value{DARKCORNER} -@node Printf, Redirection, OFMT, Printing +@node Printf @section Using @code{printf} Statements for Fancier Printing @c STARTOFRANGE printfs @@ -6086,7 +6095,7 @@ * Printf Examples:: Several examples. @end menu -@node Basic Printf, Control Letters, Printf, Printf +@node Basic Printf @subsection Introduction to the @code{printf} Statement @cindex @code{printf} statement, syntax of @@ -6100,7 +6109,7 @@ The entire list of arguments may optionally be enclosed in parentheses. The parentheses are necessary if any of the item expressions use the @samp{>} relational operator; otherwise, it can be confused with a redirection -(@pxref{Redirection, ,Redirecting Output of @code{print} and @code{printf}}). +(@pxref{Redirection}). @cindex format strings The difference between @code{printf} and @code{print} is the @var{format} @@ -6133,7 +6142,7 @@ Here, neither the @samp{+} nor the @samp{OUCH} appear when the message is printed. -@node Control Letters, Format Modifiers, Basic Printf, Printf +@node Control Letters @subsection Format-Control Letters @cindex @code{printf} statement, format-control characters @cindex format specifiers, @code{printf} statement @@ -6214,13 +6223,15 @@ @cindex dark corner, format-control characters @cindex @command{gawk}, format-control characters @strong{Note:} -When using the integer format-control letters for values that are outside -the range of a C @code{long} integer, @command{gawk} switches to the -@samp{%g} format specifier. Other versions of @command{awk} may print -invalid values or do something else entirely. +When using the integer format-control letters for values that are +outside the range of the widest C integer type, @command{gawk} switches to the +the @samp{%g} format specifier. If @option{--lint} is provided on the +command line (@pxref{Options}), @command{gawk} +warns about this. Other versions of @command{awk} may print invalid +values or do something else entirely. @value{DARKCORNER} -@node Format Modifiers, Printf Examples, Control Letters, Printf +@node Format Modifiers @subsection Modifiers for @code{printf} Formats @c STARTOFRANGE pfm @@ -6259,7 +6270,7 @@ At first glance, this feature doesn't seem to be of much use. It is in fact a @command{gawk} extension, intended for use in translating messages at runtime. -@xref{Printf Ordering, , Rearranging @code{printf} Arguments}, +@xref{Printf Ordering}, which describes how and why to use positional specifiers. For now, we will not use them. @@ -6405,12 +6416,12 @@ modifiers in @code{printf} format strings. These are not valid in @command{awk}. Most @command{awk} implementations silently ignore these modifiers. If @option{--lint} is provided on the command line -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), @command{gawk} warns about their use. If @option{--posix} is supplied, their use is a fatal error. @c ENDOFRANGE pfm -@node Printf Examples, , Format Modifiers, Printf +@node Printf Examples @subsection Examples Using @code{printf} The following is a simple example of @@ -6454,7 +6465,7 @@ The table could be made to look even nicer by adding headings to the tops of the columns. This is done using the @code{BEGIN} pattern -(@pxref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}) +(@pxref{BEGIN/END}) so that the headers are only printed once, at the beginning of the @command{awk} program: @@ -6494,10 +6505,10 @@ @code{printf} statement to line up the headings and table data for the @file{inventory-shipped} example that was covered earlier in the @value{SECTION} on the @code{print} statement -(@pxref{Print, ,The @code{print} Statement}). +(@pxref{Print}). @c ENDOFRANGE printfs -@node Redirection, Special Files, Printf, Printing +@node Redirection @section Redirecting Output of @code{print} and @code{printf} @cindex output redirection @@ -6611,11 +6622,11 @@ The message is built using string concatenation and saved in the variable @code{m}. It's then sent down the pipeline to the @command{mail} program. (The parentheses group the items to concatenate---see -@ref{Concatenation, ,String Concatenation}.) +@ref{Concatenation}.) The @code{close} function is called here because it's a good idea to close the pipe as soon as all the intended output has been sent to it. -@xref{Close Files And Pipes, ,Closing Input and Output Redirections}, +@xref{Close Files And Pipes}, for more information. This example also illustrates the use of a variable to represent @@ -6638,7 +6649,7 @@ This feature is a @command{gawk} extension, and is not available in POSIX @command{awk}. -@xref{Two-way I/O, ,Two-Way Communications with Another Process}, +@xref{Two-way I/O}, for a more complete discussion. @end table @@ -6672,7 +6683,7 @@ @cindex @command{gawk}, implementation issues, pipes @ifnotinfo As mentioned earlier -(@pxref{Getline Notes, ,Points About @code{getline} to Remember}), +(@pxref{Getline Notes}), many @end ifnotinfo @ifnottex @@ -6703,14 +6714,14 @@ The @code{tolower} function returns its argument string with all uppercase characters converted to lowercase -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). The program builds up a list of command lines, using the @command{mv} utility to rename the files. It then sends the list to the shell for execution. @c ENDOFRANGE outre @c ENDOFRANGE reout -@node Special Files, Close Files And Pipes, Redirection, Printing +@node Special Files @section Special @value{FFN}s in @command{gawk} @c STARTOFRANGE gfn @cindex @command{gawk}, @value{FN}s in @@ -6726,7 +6737,7 @@ * Special Caveats:: Things to watch out for. @end menu -@node Special FD, Special Process, Special Files, Special Files +@node Special FD @subsection Special Files for Standard Descriptors @cindex standard input @cindex input, standard @@ -6822,7 +6833,7 @@ to confusing results. @c Exercise: What does it do? :-) -@node Special Process, Special Network, Special FD, Special Files +@node Special Process @subsection Special Files for Process-Related Information @cindex files, for process information @@ -6831,7 +6842,7 @@ about the running @command{gawk} process. Each of these ``files'' provides a single record of information. To read them more than once, they must first be closed with the @code{close} function -(@pxref{Close Files And Pipes, ,Closing Input and Output Redirections}). +(@pxref{Close Files And Pipes}). The @value{FN}s are: @c @cindex @code{/dev/pid} special file @@ -6892,9 +6903,9 @@ @command{gawk} prints a warning message every time you use one of these files. To obtain process-related information, use the @code{PROCINFO} array. -@xref{Auto-set, ,Built-in Variables That Convey Information}. +@xref{Auto-set}. -@node Special Network, Special Caveats, Special Process, Special Files +@node Special Network @subsection Special Files for Network Communications @cindex networks, support for @cindex TCP/IP, support for @@ -6913,12 +6924,12 @@ for making a networking connection. These @value{FN}s are used with the @samp{|&} operator for communicating with a coprocess -(@pxref{Two-way I/O, ,Two-Way Communications with Another Process}). +(@pxref{Two-way I/O}). This is an advanced feature, mentioned here only for completeness. Full discussion is delayed until -@ref{TCP/IP Networking, ,Using @command{gawk} for Network Programming}. +@ref{TCP/IP Networking}. -@node Special Caveats, , Special Network, Special Files +@node Special Caveats @subsection Special @value{FFN} Caveats Here is a list of things to bear in mind when using the @@ -6929,7 +6940,7 @@ @cindex @value{FN}s, in compatibility mode @item Recognition of these special @value{FN}s is disabled if @command{gawk} is in -compatibility mode (@pxref{Options, ,Command-Line Options}). +compatibility mode (@pxref{Options}). @c @cindex automatic warnings @c @cindex warnings, automatic @@ -6969,7 +6980,7 @@ @end itemize @c ENDOFRANGE gfn -@node Close Files And Pipes, , Special Files, Printing +@node Close Files And Pipes @section Closing Input and Output Redirections @cindex files, output, See output files @c STARTOFRANGE ifc @@ -6986,7 +6997,7 @@ If the same @value{FN} or the same shell command is used with @code{getline} more than once during the execution of an @command{awk} program -(@pxref{Getline, ,Explicit Input with @code{getline}}), +(@pxref{Getline}), the file is opened (or the command is executed) the first time only. At that time, the first record of input is read from that file or command. The next time the same file or command is used with @code{getline}, @@ -7140,7 +7151,7 @@ @code{"to"} or @code{"from"}. Case does not matter. As this is an advanced feature, a more complete discussion is delayed until -@ref{Two-way I/O, ,Two-Way Communications with Another Process}, +@ref{Two-way I/O}, which discusses it in more detail and gives an example. @c fakenode --- for prepinfo @@ -7183,6 +7194,15 @@ This value is zero if the close succeeds, or @minus{}1 if it fails. +The POSIX standard is very vague; it says that @code{close} +returns zero on success and non-zero otherwise. In general, +different implementations vary in what they report when closing +pipes; thus the return value cannot be used portably. +@value{DARKCORNER} + +@ignore +@c 4/27/2003: Commenting this out for now, given the above +@c return of 16-bit value The return value for closing a pipeline is particularly useful. It allows you to get the output from a command as well as its exit status. @@ -7209,13 +7229,14 @@ from @code{print} or @code{printf}, the return value from @code{close} is that of the library's @code{pclose} function. +@end ignore @c ENDOFRANGE ifc @c ENDOFRANGE ofc @c ENDOFRANGE pc @c ENDOFRANGE cc @c ENDOFRANGE prnt -@node Expressions, Patterns and Actions, Printing, Top +@node Expressions @chapter Expressions @c STARTOFRANGE exps @cindex expressions @@ -7257,7 +7278,7 @@ * Precedence:: How various operators nest. @end menu -@node Constants, Using Constant Regexps, Expressions, Expressions +@node Constants @section Constant Expressions @cindex constants, types of @@ -7275,7 +7296,7 @@ * Regexp Constants:: Regular Expression constants. @end menu -@node Scalar Constants, Nondecimal-numbers, Constants, Constants +@node Scalar Constants @subsection Numeric and String Constants @cindex numeric, constants @@ -7311,7 +7332,7 @@ Other @command{awk} implementations may have difficulty with some character codes. -@node Nondecimal-numbers, Regexp Constants, Scalar Constants, Constants +@node Nondecimal-numbers @subsection Octal and Hexadecimal Numbers @cindex octal numbers @cindex hexadecimal numbers @@ -7369,14 +7390,14 @@ programs. (If you really need to do this, use the @option{--non-decimal-data} command-line option; -@pxref{Nondecimal Data, ,Allowing Nondecimal Input Data}.) +@pxref{Nondecimal Data}.) If you have octal or hexadecimal data, you can use the @code{strtonum} function -(@pxref{String Functions, ,String Manipulation Functions}) +(@pxref{String Functions}) to convert the data into a number. Most of the time, you will want to use octal or hexadecimal constants when working with the built-in bit manipulation functions; -see @ref{Bitwise Functions, ,Using @command{gawk}'s Bit Manipulation Functions}, +see @ref{Bitwise Functions}, for more information. Unlike some early C implementations, @samp{8} and @samp{9} are not valid @@ -7392,7 +7413,7 @@ @cindex compatibility mode (@command{gawk}), hexadecimal numbers Octal and hexadecimal source code constants are a @command{gawk} extension. If @command{gawk} is in compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), they are not available. @c fakenode --- for prepinfo @@ -7412,7 +7433,7 @@ @print{} 0x11 is <17> @end example -@node Regexp Constants, , Nondecimal-numbers, Constants +@node Regexp Constants @subsection Regular Expression Constants @c STARTOFRANGE rec @@ -7428,7 +7449,7 @@ (which are just ordinary strings or variables that contain a regexp). @c ENDOFRANGE cnst -@node Using Constant Regexps, Variables, Constants, Expressions +@node Using Constant Regexps @section Using Regular Expression Constants @cindex dark corner, regexp constants @@ -7440,7 +7461,7 @@ regexp constant appears by itself, it has the same meaning as if it appeared in a pattern, i.e., @samp{($0 ~ /foo/)} @value{DARKCORNER} -@xref{Expression Patterns, ,Expressions as Patterns}. +@xref{Expression Patterns}. This means that the following two code segments: @example @@ -7501,14 +7522,14 @@ Constant regular expressions are also used as the first argument for the @code{gensub}, @code{sub}, and @code{gsub} functions, and as the second argument of the @code{match} function -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). Modern implementations of @command{awk}, including @command{gawk}, allow the third argument of @code{split} to be a regexp constant, but some older implementations do not. @value{DARKCORNER} This can lead to confusion when attempting to use regexp constants as arguments to user-defined functions -(@pxref{User-defined, ,User-Defined Functions}). +(@pxref{User-defined}). For example: @example @@ -7541,7 +7562,7 @@ this way is probably not what was intended. @c ENDOFRANGE rec -@node Variables, Conversion, Using Constant Regexps, Expressions +@node Variables @section Variables @cindex variables, user-defined @@ -7558,7 +7579,7 @@ advanced method of input. @end menu -@node Using Variables, Assignment Options, Variables, Variables +@node Using Variables @subsection Using Variables in a Program Variables let you give names to values and refer to them later. Variables @@ -7571,7 +7592,7 @@ variable's current value. Variables are given new values with @dfn{assignment operators}, @dfn{increment operators}, and @dfn{decrement operators}. -@xref{Assignment Ops, ,Assignment Expressions}. +@xref{Assignment Ops}. @c NEXT ED: Can also be changed by sub, gsub, split @cindex variables, built-in @@ -7590,7 +7611,7 @@ ``initialize'' each variable explicitly in @command{awk}, which is what you would do in C and in most other traditional languages. -@node Assignment Options, , Using Variables, Variables +@node Assignment Options @subsection Assigning Variables on the Command Line @cindex variables, assigning on command line @c comma before assigning does NOT start tertiary @@ -7598,7 +7619,7 @@ Any @command{awk} variable can be set by including a @dfn{variable assignment} among the arguments on the command line when @command{awk} is invoked -(@pxref{Other Arguments, ,Other Command-Line Arguments}). +(@pxref{Other Arguments}). Such an assignment has the following form: @example @@ -7621,7 +7642,7 @@ the variable is set at the very beginning, even before the @code{BEGIN} rules are run. The @option{-v} option and its assignment must precede all the @value{FN} arguments, as well as the program text. -(@xref{Options, ,Command-Line Options}, for more information about +(@xref{Options}, for more information about the @option{-v} option.) Otherwise, the variable assignment is performed at a time determined by its position among the input file arguments---after the processing of the @@ -7652,13 +7673,13 @@ @cindex dark corner, command-line arguments Command-line arguments are made available for explicit examination by the @command{awk} program in the @code{ARGV} array -(@pxref{ARGC and ARGV, ,Using @code{ARGC} and @code{ARGV}}). +(@pxref{ARGC and ARGV}). @command{awk} processes the values of command-line assignments for escape sequences (@pxref{Escape Sequences}). @value{DARKCORNER} -@node Conversion, Arithmetic Ops, Variables, Expressions +@node Conversion @section Conversion of Strings and Numbers @cindex converting, strings to numbers @@ -7700,7 +7721,7 @@ Numbers are converted using the @code{sprintf} function with @code{CONVFMT} as the format specifier -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). @code{CONVFMT}'s default value is @code{"%.6g"}, which prints a value with at least six significant digits. For some applications, you might want to @@ -7745,10 +7766,46 @@ port your new style program to older implementations of @command{awk}. We recommend that instead of changing your programs, just port @command{gawk} itself. -@xref{Print, ,The @code{print} Statement}, +@xref{Print}, for more information on the @code{print} statement. -@node Arithmetic Ops, Concatenation, Conversion, Expressions +Finally, once again, where you are can matter when it comes to +converting between numbers and strings. In +@ref{Locales}, we mentioned that the +local character set and language (the locale) can affect how @command{gawk} matches +characters. The locale also affects numeric formats. In particular, for @command{awk} +programs, it affects the decimal point character. The @code{"C"} locale, and most +English-language locales, use the period character (@samp{.}) as the decimal point. +However, many (if not most) European and non-English locales use the comma (@samp{,}) +as the decimal point character. + +The POSIX standard says that @command{awk} always uses the period as the decimal +point when reading the @command{awk} program source code, and for command-line +variable assignments (@pxref{Other Arguments}). +However, when interpreting input data, for @code{print} and @code{printf} output, +and for number to string conversion, the local decimal point character is used. +As of @value{PVERSION} 3.1.3, @command{gawk} fully complies with this aspect +of the standard. Here are some examples indicating the difference in behavior, +on a GNU/Linux system: + +@example +$ gawk 'BEGIN @{ printf "%g\n", 3.1415927 @}' +@print{} 3.14159 +$ LC_ALL=en_DK gawk 'BEGIN @{ printf "%g\n", 3.1415927 @}' +@print{} 3,14159 +$ echo 4,321 | gawk '@{ print $1 + 1 @}' +@print{} 5 +$ echo 4,321 | LC_ALL=en_DK gawk '@{ print $1 + 1 @}' +@print{} 5,321 +@end example + +@noindent +The @samp{en_DK} locale is for English in Denmark, where the comma acts as +the decimal point separator. In the normal @code{"C"} locale, @command{gawk} +treats @samp{4,321} as @samp{4}, while in the Danish locale, it's treated +as the full number, @samp{4.321}. + +@node Arithmetic Ops @section Arithmetic Operators @cindex arithmetic operators @cindex operators, arithmetic @@ -7862,7 +7919,7 @@ for exponentiation. For maximum portability, do not use the @samp{**} operator. -@node Concatenation, Assignment Ops, Arithmetic Ops, Expressions +@node Concatenation @section String Concatenation @cindex Kernighan, Brian @quotation @@ -7992,7 +8049,7 @@ when doing concatenation, @emph{parenthesize}. Otherwise, you're never quite sure what you'll get. -@node Assignment Ops, Increment Ops, Concatenation, Expressions +@node Assignment Ops @section Assignment Expressions @c STARTOFRANGE asop @cindex assignment operators @@ -8042,8 +8099,8 @@ @cindex operators, assignment The lefthand operand of an assignment need not be a variable (@pxref{Variables}); it can also be a field -(@pxref{Changing Fields, ,Changing the Contents of a Field}) or -an array element (@pxref{Arrays, ,Arrays in @command{awk}}). +(@pxref{Changing Fields}) or +an array element (@pxref{Arrays}). These are all called @dfn{lvalues}, which means they can appear on the lefthand side of an assignment operator. The righthand operand may be any expression; it produces the new value @@ -8149,7 +8206,7 @@ The indices of @code{bar} are practically guaranteed to be different, because @code{rand} returns different values each time it is called. (Arrays and the @code{rand} function haven't been covered yet. -@xref{Arrays, ,Arrays in @command{awk}}, +@xref{Arrays}, and see @ref{Numeric Functions}, for more information). This example illustrates an important fact about assignment operators: the lefthand expression is only evaluated @emph{once}. @@ -8269,12 +8326,12 @@ @command{gawk} does not have this problem, nor do the other freely available versions described in -@ref{Other Versions, , Other Freely Available @command{awk} Implementations}. +@ref{Other Versions}. @c ENDOFRANGE exas @c ENDOFRANGE opas @c ENDOFRANGE asop -@node Increment Ops, Truth Values, Assignment Ops, Expressions +@node Increment Ops @section Increment and Decrement Operators @c STARTOFRANGE inop @@ -8397,7 +8454,7 @@ @c ENDOFRANGE opde @c ENDOFRANGE deop -@node Truth Values, Typing and Comparison, Increment Ops, Expressions +@node Truth Values @section True and False in @command{awk} @cindex truth values @cindex logical false/true @@ -8432,7 +8489,7 @@ the string constant @code{"0"} is actually true, because it is non-null. @value{DARKCORNER} -@node Typing and Comparison, Boolean Ops, Truth Values, Expressions +@node Typing and Comparison @section Variable Typing and Comparison Expressions @quotation @i{The Guide is definitive. Reality is frequently inaccurate.}@* @@ -8525,15 +8582,15 @@ % \hfil -- infinite glue; has the effect of right-justifying in this case. % # -- replaced by the text (for instance, `STRNUM', in the last row). % \quad -- about the width of an `M'. Just separates the columns. -% +% % The second column (\vrule#) is what generates the vertical rule that % spans table rows. -% +% % The doubled && before the next entry means `repeat the following % template as many times as necessary on each line' -- in our case, twice. -% +% % The template itself, \quad#\hfil, left-justifies with a little space before. -% +% \halign{\strut\hfil#\quad&\vrule#&&\quad#\hfil\cr &&STRING &NUMERIC &STRNUM\cr % The \omit tells TeX to skip inserting the template for this column on @@ -8635,7 +8692,7 @@ Comparison expressions have the value one if true and zero if false. When comparing operands of mixed types, numeric operands are converted to strings using the value of @code{CONVFMT} -(@pxref{Conversion, ,Conversion of Strings and Numbers}). +(@pxref{Conversion}). Strings are compared by comparing the first character of each, then the second character of each, @@ -8730,8 +8787,8 @@ The righthand operand of the @samp{~} and @samp{!~} operators may be either a regexp constant (@code{/@dots{}/}) or an ordinary expression. In the latter case, the value of the expression as a string is used as a -dynamic regexp (@pxref{Regexp Usage, ,How to Use Regular Expressions}; also -@pxref{Computed Regexps, ,Using Dynamic Regexps}). +dynamic regexp (@pxref{Regexp Usage}; also +@pxref{Computed Regexps}). @cindex @command{awk}, regexp constants and @cindex regexp constants @@ -8746,14 +8803,14 @@ One special place where @code{/foo/} is @emph{not} an abbreviation for @samp{$0 ~ /foo/} is when it is the righthand operand of @samp{~} or @samp{!~}. -@xref{Using Constant Regexps, ,Using Regular Expression Constants}, +@xref{Using Constant Regexps}, where this is discussed in more detail. @c ENDOFRANGE comex @c ENDOFRANGE excom @c ENDOFRANGE vartypc @c ENDOFRANGE varting -@node Boolean Ops, Conditional Exp, Typing and Comparison, Expressions +@node Boolean Ops @section Boolean Expressions @cindex and Boolean-logic operator @cindex or Boolean-logic operator @@ -8778,7 +8835,7 @@ Boolean expressions can be used wherever comparison and matching expressions can be used. They can be used in @code{if}, @code{while}, @code{do}, and @code{for} statements -(@pxref{Statements, ,Control Statements in Actions}). +(@pxref{Statements}). They have numeric values (one if true, zero if false) that come into play if the result of the Boolean expression is stored in a variable or used in arithmetic. @@ -8830,7 +8887,7 @@ @end example (The @code{in} operator is described in -@ref{Reference to Elements, ,Referring to an Array Element}.) +@ref{Reference to Elements}.) @end table @cindex short-circuit operators @@ -8848,7 +8905,7 @@ Statements that use @samp{&&} or @samp{||} can be continued simply by putting a newline after them. But you cannot put a newline in front of either of these operators without using backslash continuation -(@pxref{Statements/Lines, ,@command{awk} Statements Versus Lines}). +(@pxref{Statements/Lines}). @cindex @code{!} (exclamation point), @code{!} operator @cindex exclamation point (@code{!}), @code{!} operator @@ -8884,7 +8941,7 @@ @cindex @code{next} statement @strong{Note:} The @code{next} statement is discussed in -@ref{Next Statement, ,The @code{next} Statement}. +@ref{Next Statement}. @code{next} tells @command{awk} to skip the rest of the rules, get the next record, and start processing the rules over again at the top. The reason it's there is to avoid printing the bracketing @@ -8892,7 +8949,7 @@ @c ENDOFRANGE exbo @c ENDOFRANGE boex -@node Conditional Exp, Function Calls, Boolean Ops, Expressions +@node Conditional Exp @section Conditional Expressions @cindex conditional expressions @cindex expressions, conditional @@ -8935,7 +8992,7 @@ This is guaranteed to increment @code{i} exactly once, because each time only one of the two increment expressions is executed and the other is not. -@xref{Arrays, ,Arrays in @command{awk}}, +@xref{Arrays}, for more information about arrays. @cindex differences in @command{awk} and @command{gawk}, line continuations @@ -8946,11 +9003,11 @@ by putting a newline after either character. However, putting a newline in front of either character does not work without using backslash continuation -(@pxref{Statements/Lines, ,@command{awk} Statements Versus Lines}). +(@pxref{Statements/Lines}). If @option{--posix} is specified -(@pxref{Options, , Command-Line Options}), then this extension is disabled. +(@pxref{Options}), then this extension is disabled. -@node Function Calls, Precedence, Conditional Exp, Expressions +@node Function Calls @section Function Calls @cindex function calls @@ -8962,10 +9019,10 @@ @cindex functions, built-in A fixed set of functions are @dfn{built-in}, which means they are available in every @command{awk} program. The @code{sqrt} function is one -of these. @xref{Built-in, ,Built-in Functions}, for a list of built-in +of these. @xref{Built-in}, for a list of built-in functions and their descriptions. In addition, you can define functions for use in your program. -@xref{User-defined, ,User-Defined Functions}, +@xref{User-defined}, for instructions on how to do this. @cindex arguments, in function calls @@ -9004,10 +9061,10 @@ more optional arguments. If those arguments are not supplied, the functions use a reasonable default value. -@xref{Built-in, ,Built-in Functions}, for full details. If arguments +@xref{Built-in}, for full details. If arguments are omitted in calls to user-defined functions, then those arguments are treated as local variables and initialized to the empty string -(@pxref{User-defined, ,User-Defined Functions}). +(@pxref{User-defined}). @cindex side effects, function calls Like every other expression, the function call has a value, which is @@ -9029,7 +9086,7 @@ @kbd{@value{CTL}-d} @end example -@node Precedence, , Function Calls, Expressions +@node Precedence @section Operator Precedence (How Operators Nest) @c STARTOFRANGE prec @cindex precedence @@ -9122,7 +9179,7 @@ @item @r{String Concatenation} No special symbol is used to indicate concatenation. The operands are simply written side by side -(@pxref{Concatenation, ,String Concatenation}). +(@pxref{Concatenation}). @cindex @code{<} (left angle bracket), @code{<} operator @cindex left angle bracket (@code{<}), @code{<} operator @@ -9216,7 +9273,7 @@ @c ENDOFRANGE oppr @c ENDOFRANGE exps -@node Patterns and Actions, Arrays, Expressions, Top +@node Patterns and Actions @chapter Patterns, Actions, and Variables @c STARTOFRANGE pat @cindex patterns @@ -9242,7 +9299,7 @@ * Built-in Variables:: Summarizes the built-in variables. @end menu -@node Pattern Overview, Using Shell Variables, Patterns and Actions, Patterns and Actions +@node Pattern Overview @section Pattern Elements @menu @@ -9262,31 +9319,31 @@ @item /@var{regular expression}/ A regular expression. It matches when the text of the input record fits the regular expression. -(@xref{Regexp, ,Regular Expressions}.) +(@xref{Regexp}.) @item @var{expression} A single expression. It matches when its value is nonzero (if a number) or non-null (if a string). -(@xref{Expression Patterns, ,Expressions as Patterns}.) +(@xref{Expression Patterns}.) @item @var{pat1}, @var{pat2} A pair of patterns separated by a comma, specifying a range of records. The range includes both the initial record that matches @var{pat1} and the final record that matches @var{pat2}. -(@xref{Ranges, ,Specifying Record Ranges with Patterns}.) +(@xref{Ranges}.) @item BEGIN @itemx END Special patterns for you to supply startup or cleanup actions for your @command{awk} program. -(@xref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}.) +(@xref{BEGIN/END}.) @item @var{empty} The empty pattern matches every input record. -(@xref{Empty, ,The Empty Pattern}.) +(@xref{Empty}.) @end table -@node Regexp Patterns, Expression Patterns, Pattern Overview, Pattern Overview +@node Regexp Patterns @subsection Regular Expressions as Patterns @cindex patterns, expressions as @cindex regular expressions, as patterns @@ -9303,7 +9360,7 @@ END @{ print buzzwords, "buzzwords seen" @} @end example -@node Expression Patterns, Ranges, Regexp Patterns, Pattern Overview +@node Expression Patterns @subsection Expressions as Patterns @cindex expressions, as patterns @@ -9319,14 +9376,14 @@ @cindex comparison expressions, as patterns @cindex patterns, comparison expressions as Comparison expressions, using the comparison operators described in -@ref{Typing and Comparison, ,Variable Typing and Comparison Expressions}, +@ref{Typing and Comparison}, are a very common kind of pattern. Regexp matching and nonmatching are also very common expressions. The left operand of the @samp{~} and @samp{!~} operators is a string. The right operand is either a constant regular expression enclosed in slashes (@code{/@var{regexp}/}), or any expression whose string value is used as a dynamic regular expression -(@pxref{Computed Regexps, , Using Dynamic Regexps}). +(@pxref{Computed Regexps}). The following example prints the second field of each input record whose first field is precisely @samp{foo}: @@ -9410,7 +9467,7 @@ which never match any input record, are not expressions and cannot appear inside Boolean patterns. -@node Ranges, BEGIN/END, Expression Patterns, Pattern Overview +@node Ranges @subsection Specifying Record Ranges with Patterns @cindex range patterns @@ -9455,7 +9512,7 @@ A first attempt would be to combine a range pattern that describes the delimited text with the @code{next} statement -(not discussed yet, @pxref{Next Statement, , The @code{next} Statement}). +(not discussed yet, @pxref{Next Statement}). This causes @command{awk} to skip any further processing of the current record and start over again with the next input record. Such a program looks like this: @@ -9499,7 +9556,7 @@ @error{} gawk: cmd. line:2: ^ unexpected newline @end example -@node BEGIN/END, Empty, Ranges, Pattern Overview +@node BEGIN/END @subsection The @code{BEGIN} and @code{END} Special Patterns @c STARTOFRANGE beg @@ -9520,7 +9577,7 @@ * I/O And BEGIN/END:: I/O issues in BEGIN/END rules. @end menu -@node Using BEGIN/END, I/O And BEGIN/END, BEGIN/END, BEGIN/END +@node Using BEGIN/END @subsubsection Startup and Cleanup Actions A @code{BEGIN} rule is executed once only, before the first input record @@ -9564,14 +9621,14 @@ Multiple @code{BEGIN} and @code{END} rules are useful for writing library functions, because each library file can have its own @code{BEGIN} and/or -@code{END} rule to do its own initialization and/or cleanup. +@code{END} rule to do its own initialization and/or cleanup. The order in which library functions are named on the command line controls the order in which their @code{BEGIN} and @code{END} rules are executed. Therefore, you have to be careful when writing such rules in library files so that the order in which they are executed doesn't matter. -@xref{Options, ,Command-Line Options}, for more information on +@xref{Options}, for more information on using library functions. -@xref{Library Functions, ,A Library of @command{awk} Functions}, +@xref{Library Functions}, for a number of useful library functions. If an @command{awk} program has only a @code{BEGIN} rule and no @@ -9582,7 +9639,7 @@ no other rules in the program. This is necessary in case the @code{END} rule checks the @code{FNR} and @code{NR} variables. -@node I/O And BEGIN/END, , Using BEGIN/END, BEGIN/END +@node I/O And BEGIN/END @subsubsection Input/Output from @code{BEGIN} and @code{END} Rules @cindex input/output, from @code{BEGIN} and @code{END} @@ -9594,14 +9651,14 @@ executing @code{BEGIN} rules. References to @code{$0} and the fields yield a null string or zero, depending upon the context. One way to give @code{$0} a real value is to execute a @code{getline} command -without a variable (@pxref{Getline, ,Explicit Input with @code{getline}}). +without a variable (@pxref{Getline}). Another way is simply to assign a value to @code{$0}. @cindex differences in @command{awk} and @command{gawk}, @code{BEGIN}/@code{END} patterns @cindex POSIX @command{awk}, @code{BEGIN}/@code{END} patterns @cindex @code{print} statement, @code{BEGIN}/@code{END} patterns and @cindex @code{BEGIN} pattern, @code{print} statement and -@cindex @code{END} pattern, @code{print} statement and +@cindex @code{END} pattern, @code{print} statement and The second point is similar to the first but from the other direction. Traditionally, due largely to implementation issues, @code{$0} and @code{NF} were @emph{undefined} inside an @code{END} rule. @@ -9626,17 +9683,17 @@ @cindex @code{next} statement, @code{BEGIN}/@code{END} patterns and @cindex @code{nextfile} statement, @code{BEGIN}/@code{END} patterns and @cindex @code{BEGIN} pattern, @code{next}/@code{nextfile} statements and -@cindex @code{END} pattern, @code{next}/@code{nextfile} statements and +@cindex @code{END} pattern, @code{next}/@code{nextfile} statements and Finally, the @code{next} and @code{nextfile} statements are not allowed in a @code{BEGIN} rule, because the implicit read-a-record-and-match-against-the-rules loop has not started yet. Similarly, those statements are not valid in an @code{END} rule, since all the input has been read. -(@xref{Next Statement, ,The @code{next} Statement}, and see -@ref{Nextfile Statement, ,Using @command{gawk}'s @code{nextfile} Statement}.) +(@xref{Next Statement}, and see +@ref{Nextfile Statement}.) @c ENDOFRANGE beg @c ENDOFRANGE end -@node Empty, , BEGIN/END, Pattern Overview +@node Empty @subsection The Empty Pattern @cindex empty pattern @@ -9652,7 +9709,7 @@ prints the first field of every record. @c ENDOFRANGE pat -@node Using Shell Variables, Action Overview, Pattern Overview, Patterns and Actions +@node Using Shell Variables @section Using Shell Variables in Programs @cindex shells, variables @cindex @command{awk} programs, shell variables in @@ -9686,15 +9743,15 @@ Variable substitution via quoting works, but can be potentially messy. It requires a good understanding of the shell's quoting rules -(@pxref{Quoting, ,Shell Quoting Issues}), +(@pxref{Quoting}), and it's often difficult to correctly match up the quotes when reading the program. A better method is to use @command{awk}'s variable assignment feature -(@pxref{Assignment Options, ,Assigning Variables on the Command Line}) +(@pxref{Assignment Options}) to assign the shell variable's value to an @command{awk} variable's value. Then use dynamic regexps to match the pattern -(@pxref{Computed Regexps, ,Using Dynamic Regexps}). +(@pxref{Computed Regexps}). The following shows how to redo the previous example using this technique: @@ -9715,7 +9772,7 @@ the program---for printing, as an array subscript, or for any other use---without requiring the quoting tricks at every point in the program. -@node Action Overview, Statements, Using Shell Variables, Patterns and Actions +@node Action Overview @section Actions @c @cindex action, definition of @c @cindex curly braces @@ -9725,7 +9782,7 @@ An @command{awk} program or script consists of a series of rules and function definitions interspersed. (Functions are -described later. @xref{User-defined, ,User-Defined Functions}.) +described later. @xref{User-defined}.) A rule contains a pattern and an action, either of which (but not both) may be omitted. The purpose of the @dfn{action} is to tell @command{awk} what to do once a match for the pattern is found. Thus, @@ -9767,13 +9824,13 @@ (@pxref{Expressions}). Executing this kind of statement simply computes the value of the expression. This is useful when the expression has side effects -(@pxref{Assignment Ops, ,Assignment Expressions}). +(@pxref{Assignment Ops}). @item Control statements Specify the control flow of @command{awk} programs. The @command{awk} language gives you C-like constructs (@code{if}, @code{for}, @code{while}, and @code{do}) as well as a few -special ones (@pxref{Statements, ,Control Statements in Actions}). +special ones (@pxref{Statements}). @item Compound statements Consist of one or more statements enclosed in @@ -9783,22 +9840,22 @@ @item Input statements Use the @code{getline} command -(@pxref{Getline, ,Explicit Input with @code{getline}}). +(@pxref{Getline}). Also supplied in @command{awk} are the @code{next} -statement (@pxref{Next Statement, ,The @code{next} Statement}), +statement (@pxref{Next Statement}), and the @code{nextfile} statement -(@pxref{Nextfile Statement, ,Using @command{gawk}'s @code{nextfile} Statement}). +(@pxref{Nextfile Statement}). @item Output statements Such as @code{print} and @code{printf}. -@xref{Printing, ,Printing Output}. +@xref{Printing}. @item Deletion statements For deleting array elements. -@xref{Delete, ,The @code{delete} Statement}. +@xref{Delete}. @end table -@node Statements, Built-in Variables, Action Overview, Patterns and Actions +@node Statements @section Control Statements in Actions @c STARTOFRANGE csta @cindex control statements @@ -9838,6 +9895,8 @@ condition is satisfied. * For Statement:: Another looping statement, that provides initialization and increment clauses. +* Switch Statement:: Switch/case evaluation for conditional + execution of statements based on a value. * Break Statement:: Immediately exit the innermost enclosing loop. * Continue Statement:: Skip to the end of the innermost enclosing loop. @@ -9846,7 +9905,7 @@ * Exit Statement:: Stop execution of @command{awk}. @end menu -@node If Statement, While Statement, Statements, Statements +@node If Statement @subsection The @code{if}-@code{else} Statement @cindex @code{if} statement @@ -9894,7 +9953,7 @@ because a human reader might fail to see the @code{else} if it is not the first thing on its line. -@node While Statement, Do Statement, If Statement, Statements +@node While Statement @subsection The @code{while} Statement @cindex @code{while} statement @cindex loops @@ -9954,7 +10013,7 @@ that begins the compound statement is not required either, but the program is harder to read without it. -@node Do Statement, For Statement, While Statement, Statements +@node Do Statement @subsection The @code{do}-@code{while} Statement @cindex @code{do}-@code{while} statement @@ -9998,7 +10057,7 @@ just as well. This situation reflects actual experience; only occasionally is there a real use for a @code{do} statement. -@node For Statement, Break Statement, Do Statement, Statements +@node For Statement @subsection The @code{for} Statement @cindex @code{for} statement @@ -10076,7 +10135,7 @@ @cindex loops, @code{continue} statements and @noindent The only exception is when the @code{continue} statement -(@pxref{Continue Statement, ,The @code{continue} Statement}) is used +(@pxref{Continue Statement}) is used inside the loop. Changing a @code{for} statement to a @code{while} statement in this way can change the effect of the @code{continue} statement inside the loop. @@ -10098,11 +10157,71 @@ @end example @noindent -@xref{Scanning an Array, ,Scanning All Elements of an Array}, +@xref{Scanning an Array}, for more information on this version of the @code{for} loop. @end ifinfo -@node Break Statement, Continue Statement, For Statement, Statements +@node Switch Statement +@subsection The @code{switch} Statement +@cindex @code{switch} statement +@cindex @code{case} keyword +@cindex @code{default} keyword + +@strong{NOTE:} This @value{SUBSECTION} describes an experimental feature +added in @command{gawk} 3.1.3. It is @emph{not} enabled by default. To +enable it, use the @option{--enable-switch} option to @command{configure} +when @command{gawk} is being configured and built. +@xref{Additional Configuration Options}, +for more information. + +The @code{switch} statement allows the evaluation of an expression and +the execution of statements based on a @code{case} match. Case statements +are checked for a match in the order they are defined. If no suitable +@code{case} is found, the @code{default} section is executed, if supplied. The +general form of the @code{switch} statement looks like this: + +@example +switch (@var{expression}) @{ +case @var{value or regular expression}: + @var{case-body} +default: + @var{default-body} +@} +@end example + +The @code{switch} statement works as it does in C. Once a match to a given +case is made, case statement bodies are executed until a @code{break}, +@code{continue}, @code{next}, @code{nextfile} or @code{exit} is encountered, +or the end of the @code{switch} statement itself. For example: + +@example +switch (NR * 2 + 1) @{ +case 3: +case "11": + print NR - 1 + break + +case /2[[:digit:]]+/: + print NR + +default: + print NR + 1 + +case -1: + print NR * -1 +@} +@end example + +Note that if none of the statements specified above halt execution +of a matched @code{case} statement, execution falls through to the +next @code{case} until execution halts. In the above example, for +any case value starting with @samp{2} followed by one or more digits, +the @code{print} statement is executed and then falls through into the +@code{default} section, executing its @code{print} statement. In turn, +the @minus{}1 case will also be executed since the @code{default} does +not halt execution. + +@node Break Statement @subsection The @code{break} Statement @cindex @code{break} statement @cindex loops, exiting @@ -10131,7 +10250,7 @@ that @command{awk} proceeds immediately to the statement following the loop and continues processing. (This is very different from the @code{exit} statement, which stops the entire @command{awk} program. -@xref{Exit Statement, ,The @code{exit} Statement}.) +@xref{Exit Statement}.) Th following program illustrates how the @var{condition} of a @code{for} or @code{while} statement could be replaced with a @code{break} inside @@ -10164,18 +10283,18 @@ used outside the body of a loop. However, although it was never documented, historical implementations of @command{awk} treated the @code{break} statement outside of a loop as if it were a @code{next} statement -(@pxref{Next Statement, ,The @code{next} Statement}). +(@pxref{Next Statement}). Recent versions of Unix @command{awk} no longer allow this usage. @command{gawk} supports this use of @code{break} only if @option{--traditional} has been specified on the command line -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). Otherwise, it is treated as an error, since the POSIX standard specifies that @code{break} should only be used inside the body of a loop. @value{DARKCORNER} -@node Continue Statement, Next Statement, Break Statement, Statements +@node Continue Statement @subsection The @code{continue} Statement @cindex @code{continue} statement @@ -10234,15 +10353,15 @@ statement outside a loop the same way they treated a @code{break} statement outside a loop: as if it were a @code{next} statement -(@pxref{Next Statement, ,The @code{next} Statement}). +(@pxref{Next Statement}). Recent versions of Unix @command{awk} no longer work this way, and @command{gawk} allows it only if @option{--traditional} is specified on -the command line (@pxref{Options, ,Command-Line Options}). Just like the +the command line (@pxref{Options}). Just like the @code{break} statement, the POSIX standard specifies that @code{continue} should only be used inside the body of a loop. @value{DARKCORNER} -@node Next Statement, Nextfile Statement, Continue Statement, Statements +@node Next Statement @subsection The @code{next} Statement @cindex @code{next} statement @@ -10252,7 +10371,7 @@ current rule's action isn't executed. Contrast this with the effect of the @code{getline} function -(@pxref{Getline, ,Explicit Input with @code{getline}}). That also causes +(@pxref{Getline}). That also causes @command{awk} to read the next record immediately, but it does not alter the flow of control in any way (i.e., the rest of the current action executes with a new input record). @@ -10284,12 +10403,12 @@ message is redirected to the standard error output stream, as error messages should be. For more detail see -@ref{Special Files, ,Special @value{FFN}s in @command{gawk}}. +@ref{Special Files}. @c @cindex @command{awk} language, POSIX version @c @cindex @code{next}, inside a user-defined function @cindex @code{BEGIN} pattern, @code{next}/@code{nextfile} statements and -@cindex @code{END} pattern, @code{next}/@code{nextfile} statements and +@cindex @code{END} pattern, @code{next}/@code{nextfile} statements and @cindex POSIX @command{awk}, @code{next}/@code{nextfile} statements and @cindex @code{next} statement, user-defined functions and @cindex functions, user-defined, @code{next}/@code{nextfile} statements and @@ -10299,15 +10418,15 @@ Although POSIX permits it, some other @command{awk} implementations don't allow the @code{next} statement inside function bodies -(@pxref{User-defined, ,User-Defined Functions}). +(@pxref{User-defined}). Just as with any other @code{next} statement, a @code{next} statement inside a function body reads the next record and starts processing it with the first rule in the program. If the @code{next} statement causes the end of the input to be reached, then the code in any @code{END} rules is executed. -@xref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}. +@xref{BEGIN/END}. -@node Nextfile Statement, Exit Statement, Next Statement, Statements +@node Nextfile Statement @subsection Using @command{gawk}'s @code{nextfile} Statement @cindex @code{nextfile} statement @cindex differences in @command{awk} and @command{gawk}, @code{next}/@code{nextfile} statements @@ -10321,7 +10440,7 @@ The @code{nextfile} statement is a @command{gawk} extension. In most other @command{awk} implementations, or if @command{gawk} is in compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), @code{nextfile} is not special. Upon execution of the @code{nextfile} statement, @code{FILENAME} is @@ -10331,7 +10450,7 @@ (@code{ARGIND} hasn't been introduced yet. @xref{Built-in Variables}.) If the @code{nextfile} statement causes the end of the input to be reached, then the code in any @code{END} rules is executed. -@xref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}. +@xref{BEGIN/END}. The @code{nextfile} statement is useful when there are many @value{DF}s to process but it isn't necessary to process every record in every file. @@ -10347,17 +10466,17 @@ If it's necessary to use an @command{awk} version that doesn't support @code{nextfile}, see -@ref{Nextfile Function, ,Implementing @code{nextfile} as a Function}, +@ref{Nextfile Function}, for a user-defined function that simulates the @code{nextfile} statement. @cindex functions, user-defined, @code{next}/@code{nextfile} statements and @cindex @code{nextfile} statement, user-defined functions and The current version of the Bell Laboratories @command{awk} -(@pxref{Other Versions, ,Other Freely Available @command{awk} Implementations}) +(@pxref{Other Versions}) also supports @code{nextfile}. However, it doesn't allow the @code{nextfile} statement inside function bodies -(@pxref{User-defined, ,User-Defined Functions}). +(@pxref{User-defined}). @command{gawk} does; a @code{nextfile} inside a function body reads the next record and starts processing it with the first rule in the program, just as any other @code{nextfile} statement. @@ -10374,7 +10493,7 @@ otherwise, it was a regular identifier. The old usage is no longer accepted; @samp{next file} generates a syntax error. -@node Exit Statement, , Nextfile Statement, Statements +@node Exit Statement @subsection The @code{exit} Statement @cindex @code{exit} statement @@ -10393,7 +10512,7 @@ read. However, if an @code{END} rule is present, as part of executing the @code{exit} statement, the @code{END} rule is executed -(@pxref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}). +(@pxref{BEGIN/END}). If @code{exit} is used as part of an @code{END} rule, it causes the program to stop immediately. @@ -10406,7 +10525,7 @@ if you don't want the @code{END} rule to do its job, set a variable to nonzero before the @code{exit} statement and check that variable in the @code{END} rule. -@xref{Assert Function, ,Assertions}, +@xref{Assert Function}, for an example that does this. @cindex dark corner, @code{exit} statement @@ -10439,7 +10558,7 @@ @c ENDOFRANGE acs @c ENDOFRANGE accs -@node Built-in Variables, , Statements, Patterns and Actions +@node Built-in Variables @section Built-in Variables @c STARTOFRANGE bvar @cindex built-in variables @@ -10468,7 +10587,7 @@ * ARGC and ARGV:: Ways to use @code{ARGC} and @code{ARGV}. @end menu -@node User-modified, Auto-set, Built-in Variables, Built-in Variables +@node User-modified @subsection Built-in Variables That Control @command{awk} @c STARTOFRANGE bvaru @cindex built-in variables, user-modifiable @@ -10495,15 +10614,15 @@ Any other string value is equivalent to @code{"rw"}, but @command{gawk} generates a warning message. @code{BINMODE} is described in more detail in -@ref{PC Using, ,Using @command{gawk} on PC Operating Systems}. +@ref{PC Using}. @cindex differences in @command{awk} and @command{gawk}, @code{BINMODE} variable This variable is a @command{gawk} extension. In other @command{awk} implementations (except @command{mawk}, -@pxref{Other Versions, , Other Freely Available @command{awk} Implementations}), +@pxref{Other Versions}), or if @command{gawk} is in compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), it is not special. @cindex @code{CONVFMT} variable @@ -10512,10 +10631,10 @@ @cindex strings, converting, numbers to @item CONVFMT This string controls conversion of numbers to -strings (@pxref{Conversion, ,Conversion of Strings and Numbers}). +strings (@pxref{Conversion}). It works by being passed, in effect, as the first argument to the @code{sprintf} function -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). Its default value is @code{"%.6g"}. @code{CONVFMT} was introduced by the POSIX standard. @@ -10528,11 +10647,11 @@ how to split input with fixed columnar boundaries. Assigning a value to @code{FIELDWIDTHS} overrides the use of @code{FS} for field splitting. -@xref{Constant Size, ,Reading Fixed-Width Data}, for more information. +@xref{Constant Size}, for more information. @cindex @command{gawk}, @code{FIELDWIDTHS} variable in If @command{gawk} is in compatibility mode -(@pxref{Options, ,Command-Line Options}), then @code{FIELDWIDTHS} +(@pxref{Options}), then @code{FIELDWIDTHS} has no special meaning, and field-splitting operations occur based exclusively on the value of @code{FS}. @@ -10541,7 +10660,7 @@ @cindex field separators @item FS This is the input field separator -(@pxref{Field Separators, ,Specifying How Fields Are Separated}). +(@pxref{Field Separators}). The value is a single-character string or a multi-character regular expression that matches the separations between fields in an input record. If the value is the null string (@code{""}), then each @@ -10585,11 +10704,11 @@ However, the value of @code{IGNORECASE} does @emph{not} affect array subscripting and it does not affect field splitting when using a single-character field separator. -@xref{Case-sensitivity, ,Case Sensitivity in Matching}. +@xref{Case-sensitivity}. @cindex @command{gawk}, @code{IGNORECASE} variable in If @command{gawk} is in compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), then @code{IGNORECASE} has no special meaning. Thus, string and regexp operations are always case-sensitive. @@ -10599,7 +10718,7 @@ @item LINT # When this variable is true (nonzero or non-null), @command{gawk} behaves as if the @option{--lint} command-line option is in effect. -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). With a value of @code{"fatal"}, lint warnings become fatal errors. With a value of @code{"invalid"}, only warnings about things that are actually invalid are issued. (This is not fully implemented yet.) @@ -10621,10 +10740,10 @@ @cindex strings, converting, numbers to @item OFMT This string controls conversion of numbers to -strings (@pxref{Conversion, ,Conversion of Strings and Numbers}) for +strings (@pxref{Conversion}) for printing with the @code{print} statement. It works by being passed as the first argument to the @code{sprintf} function -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). Its default value is @code{"%.6g"}. Earlier versions of @command{awk} also used @code{OFMT} to specify the format for converting numbers to strings in general expressions; this is now done by @code{CONVFMT}. @@ -10656,13 +10775,13 @@ runs of blank lines. If it is a regexp, records are separated by matches of the regexp in the input text. -(@xref{Records, ,How Input Is Split into Records}.) +(@xref{Records}.) The ability for @code{RS} to be a regular expression is a @command{gawk} extension. In most other @command{awk} implementations, or if @command{gawk} is in compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), just the first character of @code{RS}'s value is used. @cindex @code{SUBSEP} variable @@ -10673,7 +10792,7 @@ @code{"\034"} and is used to separate the parts of the indices of a multidimensional array. Thus, the expression @code{@w{foo["A", "B"]}} really accesses @code{foo["A\034B"]} -(@pxref{Multi-dimensional, ,Multidimensional Arrays}). +(@pxref{Multi-dimensional}). @cindex @code{TEXTDOMAIN} variable @cindex differences in @command{awk} and @command{gawk}, @code{TEXTDOMAIN} variable @@ -10683,13 +10802,13 @@ @command{awk} level. It sets the default text domain for specially marked string constants in the source text, as well as for the @code{dcgettext}, @code{dcngettext} and @code{bindtextdomain} functions -(@pxref{Internationalization, ,Internationalization with @command{gawk}}). +(@pxref{Internationalization}). The default value of @code{TEXTDOMAIN} is @code{"messages"}. This variable is a @command{gawk} extension. In other @command{awk} implementations, or if @command{gawk} is in compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), it is not special. @end table @c ENDOFRANGE bvar @@ -10697,7 +10816,7 @@ @c ENDOFRANGE bvaru @c ENDOFRANGE nmbv -@node Auto-set, ARGC and ARGV, User-modified, Built-in Variables +@node Auto-set @subsection Built-in Variables That Convey Information @c STARTOFRANGE bvconi @@ -10716,7 +10835,7 @@ @item ARGC@r{,} ARGV The command-line arguments available to @command{awk} programs are stored in an array called @code{ARGV}. @code{ARGC} is the number of command-line -arguments present. @xref{Other Arguments, ,Other Command-Line Arguments}. +arguments present. @xref{Other Arguments}. Unlike most @command{awk} arrays, @code{ARGV} is indexed from 0 to @code{ARGC} @minus{} 1. In the following example: @@ -10746,7 +10865,7 @@ The value of @code{ARGV[0]} can vary from system to system. Also, you should note that the program text is @emph{not} included in @code{ARGV}, nor are any of @command{awk}'s command-line options. -@xref{ARGC and ARGV, , Using @code{ARGC} and @code{ARGV}}, for information +@xref{ARGC and ARGV}, for information about how @command{awk} uses these variables. @cindex @code{ARGIND} variable @@ -10772,7 +10891,7 @@ This variable is a @command{gawk} extension. In other @command{awk} implementations, or if @command{gawk} is in compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), it is not special. @cindex @code{ENVIRON} variable @@ -10789,7 +10908,7 @@ Some operating systems may not have environment variables. On such systems, the @code{ENVIRON} array is empty (except for @w{@code{ENVIRON["AWKPATH"]}}, -@pxref{AWKPATH Variable, ,The @env{AWKPATH} Environment Variable}). +@pxref{AWKPATH Variable}). @cindex @code{ERRNO} variable @cindex differences in @command{awk} and @command{gawk}, @code{ERRNO} variable @@ -10802,7 +10921,7 @@ This variable is a @command{gawk} extension. In other @command{awk} implementations, or if @command{gawk} is in compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), it is not special. @cindex @code{FILENAME} variable @@ -10812,7 +10931,7 @@ When no @value{DF}s are listed on the command line, @command{awk} reads from the standard input and @code{FILENAME} is set to @code{"-"}. @code{FILENAME} is changed each time a new file is read -(@pxref{Reading Files, ,Reading Input Files}). +(@pxref{Reading Files}). Inside a @code{BEGIN} rule, the value of @code{FILENAME} is @code{""}, since there are no input files being processed yet.@footnote{Some early implementations of Unix @command{awk} initialized @@ -10821,7 +10940,7 @@ upon in your programs.} @value{DARKCORNER} Note, though, that using @code{getline} -(@pxref{Getline, ,Explicit Input with @code{getline}}) +(@pxref{Getline}) inside a @code{BEGIN} rule can give @code{FILENAME} a value. @@ -10829,14 +10948,14 @@ @item FNR The current record number in the current file. @code{FNR} is incremented each time a new record is read -(@pxref{Getline, ,Explicit Input with @code{getline}}). It is reinitialized +(@pxref{Getline}). It is reinitialized to zero each time a new input file is started. @cindex @code{NF} variable @item NF The number of fields in the current input record. @code{NF} is set each time a new record is read, when a new field is -created or when @code{$0} changes (@pxref{Fields, ,Examining Fields}). +created or when @code{$0} changes (@pxref{Fields}). Unlike most of the variables described in this @ifnotinfo @@ -10848,13 +10967,13 @@ assigning a value to @code{NF} has the potential to affect @command{awk}'s internal workings. In particular, assignments to @code{NF} can be used to create or remove fields from the -current record: @xref{Changing Fields, ,Changing the Contents of a Field}. +current record: @xref{Changing Fields}. @cindex @code{NR} variable @item NR The number of input records @command{awk} has processed since the beginning of the program's execution -(@pxref{Records, ,How Input Is Split into Records}). +(@pxref{Records}). @code{NR} is incremented each time a new record is read. @cindex @code{PROCINFO} array @@ -10897,19 +11016,19 @@ through @code{"group@var{N}"} for some @var{N}. @var{N} is the number of supplementary groups that the process has. Use the @code{in} operator to test for these elements -(@pxref{Reference to Elements, , Referring to an Array Element}). +(@pxref{Reference to Elements}). This array is a @command{gawk} extension. In other @command{awk} implementations, or if @command{gawk} is in compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), it is not special. @cindex @code{RLENGTH} variable @item RLENGTH The length of the substring matched by the @code{match} function -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). @code{RLENGTH} is set by invoking the @code{match} function. Its value is the length of the matched string, or @minus{}1 if no match is found. @@ -10917,7 +11036,7 @@ @item RSTART The start-index in characters of the substring that is matched by the @code{match} function -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). @code{RSTART} is set by invoking the @code{match} function. Its value is the position of the string where the matched substring starts, or zero if no match was found. @@ -10931,7 +11050,7 @@ This variable is a @command{gawk} extension. In other @command{awk} implementations, or if @command{gawk} is in compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), it is not special. @end table @c ENDOFRANGE bvconi @@ -10965,18 +11084,18 @@ @noindent Before @code{FNR} was added to the @command{awk} language -(@pxref{V7/SVR3.1, ,Major Changes Between V7 and SVR3.1}), +(@pxref{V7/SVR3.1}), many @command{awk} programs used this feature to track the number of records in a file by resetting @code{NR} to zero when @code{FILENAME} changed. -@node ARGC and ARGV, , Auto-set, Built-in Variables +@node ARGC and ARGV @subsection Using @code{ARGC} and @code{ARGV} @cindex @code{ARGC}/@code{ARGV} variables @cindex arguments, command-line @cindex command line, arguments -@ref{Auto-set, ,Built-in Variables That Convey Information}, +@ref{Auto-set}, presented the following program describing the information contained in @code{ARGC} and @code{ARGV}: @@ -10997,7 +11116,7 @@ Notice that the @command{awk} program is not entered in @code{ARGV}. The other special command-line options, with their arguments, are also not entered. This includes variable assignments done with the @option{-v} -option (@pxref{Options, ,Command-Line Options}). +option (@pxref{Options}). Normal variable assignments on the command line @emph{are} treated as arguments and do show up in the @code{ARGV} array: @@ -11036,12 +11155,12 @@ replaced with the null string. Another option is to use the @code{delete} statement to remove elements from -@code{ARGV} (@pxref{Delete, ,The @code{delete} Statement}). +@code{ARGV} (@pxref{Delete}). All of these actions are typically done in the @code{BEGIN} rule, before actual processing of the input begins. -@xref{Split Program, ,Splitting a Large File into Pieces}, and see -@ref{Tee Program, ,Duplicating Output into Multiple Files}, for examples +@xref{Split Program}, and see +@ref{Tee Program}, for examples of each way of removing elements from @code{ARGV}. The following fragment processes @code{ARGV} in order to examine, and then remove, command-line options: @@ -11090,7 +11209,7 @@ it and the following @option{-v} are passed on to the @command{awk} program. -@node Arrays, Functions, Patterns and Actions, Top +@node Arrays @chapter Arrays in @command{awk} @c STARTOFRANGE arrs @cindex arrays @@ -11114,7 +11233,7 @@ @cindex namespace issues @command{awk} maintains a single set of names that may be used for naming variables, arrays, and functions -(@pxref{User-defined, ,User-Defined Functions}). +(@pxref{User-defined}). Thus, you cannot have a variable and an array with the same name in the same @command{awk} program. @@ -11137,7 +11256,7 @@ * Array Sorting:: Sorting array values and indices. @end menu -@node Array Intro, Reference to Elements, Arrays, Arrays +@node Array Intro @section Introduction to Arrays The @command{awk} language provides one-dimensional arrays @@ -11269,7 +11388,7 @@ numbers and strings as indices. In fact, array subscripts are always strings; this is discussed in more detail in -@ref{Numeric Array Subscripts, ,Using Numbers to Subscript Arrays}. +@ref{Numeric Array Subscripts}. Here, the number @code{1} isn't double-quoted, since @command{awk} automatically converts it to a string. @@ -11282,14 +11401,14 @@ When @command{awk} creates an array (e.g., with the @code{split} built-in function), that array's indices are consecutive integers starting at one. -(@xref{String Functions, ,String Manipulation Functions}.) +(@xref{String Functions}.) @command{awk}'s arrays are efficient---the time to access an element is independent of the number of elements in the array. @c ENDOFRANGE arrin @c ENDOFRANGE inarr -@node Reference to Elements, Assigning Elements, Array Intro, Arrays +@node Reference to Elements @section Referring to an Array Element @cindex arrays, elements, referencing @cindex elements in arrays @@ -11312,7 +11431,7 @@ A reference to an array element that has no recorded value yields a value of @code{""}, the null string. This includes elements that have not been assigned any value as well as elements that have been -deleted (@pxref{Delete, ,The @code{delete} Statement}). Such a reference +deleted (@pxref{Delete}). Such a reference automatically creates that array element, with the null string as its value. (In some cases, this is unfortunate, because it might waste memory inside @command{awk}.) @@ -11351,7 +11470,7 @@ print "Subscript 2 is present." @end example -@node Assigning Elements, Array Example, Reference to Elements, Arrays +@node Assigning Elements @section Assigning Array Elements @cindex arrays, elements, assigning @cindex elements in arrays, assigning @@ -11369,7 +11488,7 @@ assigned a value. The expression @var{value} is the value to assign to that element of the array. -@node Array Example, Scanning an Array, Assigning Elements, Arrays +@node Array Example @section Basic Array Example The following program takes a list of lines, each beginning with a line @@ -11437,7 +11556,7 @@ @} @end example -@node Scanning an Array, Delete, Array Example, Arrays +@node Scanning an Array @section Scanning All Elements of an Array @cindex elements in arrays, scanning @cindex arrays, scanning @@ -11470,7 +11589,7 @@ find all the distinct words that appear in the input. It prints each word that is more than 10 characters long and also prints the number of such words. -@xref{String Functions, ,String Manipulation Functions}, +@xref{String Functions}, for more information on the built-in function @code{length}. @example @@ -11492,7 +11611,7 @@ @end example @noindent -@xref{Word Sorting, ,Generating Word Usage Counts}, +@xref{Word Sorting}, for a more detailed example of this type. @cindex arrays, elements, order of @@ -11505,7 +11624,7 @@ reach them. Similarly, changing @var{var} inside the loop may produce strange results. It is best to avoid such things. -@node Delete, Numeric Array Subscripts, Scanning an Array, Arrays +@node Delete @section The @code{delete} Statement @cindex @code{delete} statement @cindex deleting elements in arrays @@ -11520,7 +11639,7 @@ @end example Once an array element has been deleted, any value the element once -had is no longer available. It is as if the element had never +had is no longer available. It is as if the element had never been referred to or had been given a value. The following is an example of deleting elements in an array: @@ -11555,7 +11674,7 @@ @cindex lint checking, array elements It is not an error to delete an element that does not exist. If @option{--lint} is provided on the command line -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), @command{gawk} issues a warning message when an element that is not in the array is deleted. @@ -11571,7 +11690,7 @@ @end example This ability is a @command{gawk} extension; it is not available in -compatibility mode (@pxref{Options, ,Command-Line Options}). +compatibility mode (@pxref{Options}). Using this version of the @code{delete} statement is about three times more efficient than the equivalent loop that deletes each element one @@ -11589,7 +11708,7 @@ @c comma before deleting does NOT start a tertiary @cindex @code{split} function, array elements, deleting The @code{split} function -(@pxref{String Functions, ,String Manipulation Functions}) +(@pxref{String Functions}) clears out the target array first. This call asks it to split apart the null string. Because there is no data to split out, the function simply clears the array and then returns. @@ -11602,7 +11721,7 @@ a[1] = 3; delete a; a = 3 @end example -@node Numeric Array Subscripts, Uninitialized Subscripts, Delete, Arrays +@node Numeric Array Subscripts @section Using Numbers to Subscript Arrays @cindex numbers, as array subscripts @@ -11612,7 +11731,7 @@ An important aspect about arrays to remember is that @emph{array subscripts are always strings}. When a numeric value is used as a subscript, it is converted to a string value before being used for subscripting -(@pxref{Conversion, ,Conversion of Strings and Numbers}). +(@pxref{Conversion}). This means that the value of the built-in variable @code{CONVFMT} can affect how your program accesses elements of an array. For example: @@ -11640,7 +11759,7 @@ @cindex converting, during subscripting According to the rules for conversions -(@pxref{Conversion, ,Conversion of Strings and Numbers}), integer +(@pxref{Conversion}), integer values are always converted to strings as integers, no matter what the value of @code{CONVFMT} may happen to be. So the usual case of the following works: @@ -11653,7 +11772,7 @@ The ``integer values always convert to strings as integers'' rule has an additional consequence for array indexing. Octal and hexadecimal constants -(@pxref{Nondecimal-numbers, ,Octal and Hexadecimal Numbers}) +(@pxref{Nondecimal-numbers}) are converted internally into numbers, and their original form is forgotten. This means, for example, that @@ -11668,7 +11787,7 @@ knowledge of the actual rules which sometimes can have a subtle effect on your programs. -@node Uninitialized Subscripts, Multi-dimensional, Numeric Array Subscripts, Arrays +@node Uninitialized Subscripts @section Using Uninitialized Variables as Subscripts @c last comma does NOT start a tertiary @@ -11726,9 +11845,9 @@ @value{DARKCORNER} @command{gawk} warns about the use of the null string as a subscript if @option{--lint} is provided -on the command line (@pxref{Options, ,Command-Line Options}). +on the command line (@pxref{Options}). -@node Multi-dimensional, Multi-scanning, Uninitialized Subscripts, Arrays +@node Multi-dimensional @section Multidimensional Arrays @cindex subscripts in arrays, multidimensional @@ -11744,7 +11863,7 @@ Multidimensional arrays are supported in @command{awk} through concatenation of indices into one string. @command{awk} converts the indices into strings -(@pxref{Conversion, ,Conversion of Strings and Numbers}) and +(@pxref{Conversion}) and concatenates them together, with a separator between them. This creates a single string that describes the values of the separate indices. The combined string is used as a single index into an ordinary, @@ -11826,7 +11945,7 @@ 3 2 1 6 @end example -@node Multi-scanning, Array Sorting, Multi-dimensional, Arrays +@node Multi-scanning @section Scanning Multidimensional Arrays There is no special @code{for} statement for scanning a @@ -11839,9 +11958,9 @@ However, if your program has an array that is always accessed as multidimensional, you can get the effect of scanning it by combining the scanning @code{for} statement -(@pxref{Scanning an Array, ,Scanning All Elements of an Array}) with the +(@pxref{Scanning an Array}) with the built-in @code{split} function -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). It works in the following manner: @example @@ -11874,7 +11993,7 @@ @code{separate[2]} to @code{"foo"}. Presto! The original sequence of separate indices is recovered. -@node Array Sorting, , Multi-scanning, Arrays +@node Array Sorting @section Sorting Array Values and Indices with @command{gawk} @cindex arrays, sorting @@ -11890,7 +12009,7 @@ usually that's not the point of the program. @command{gawk} provides the built-in @code{asort} and @code{asorti} functions -(@pxref{String Functions, ,String Manipulation Functions}) +(@pxref{String Functions}) for sorting arrays. For example: @example @@ -11906,7 +12025,7 @@ @code{data[1]} @value{LEQ} @code{data[2]} @value{LEQ} @code{data[3]}, and so on. The comparison of array elements is done using @command{gawk}'s usual comparison rules -(@pxref{Typing and Comparison, ,Variable Typing and Comparison Expressions}). +(@pxref{Typing and Comparison}). @cindex side effects, @code{asort} function An important side effect of calling @code{asort} is that @@ -11983,7 +12102,7 @@ Caveat Emptor. @c ENDOFRANGE arrs -@node Functions, Internationalization, Arrays, Top +@node Functions @chapter Functions @c STARTOFRANGE funcbi @@ -12006,7 +12125,7 @@ * User-defined:: Describes User-defined functions in detail. @end menu -@node Built-in, User-defined, Functions, Functions +@node Built-in @section Built-in Functions @c 2e: USE TEXINFO-2 FUNCTION DEFINITION STUFF!!!!!!!!!!!!! @@ -12028,7 +12147,7 @@ * I18N Functions:: Functions for string translation. @end menu -@node Calling Built-in, Numeric Functions, Built-in, Built-in +@node Calling Built-in @subsection Calling Built-in Functions To call one of @command{awk}'s built-in functions, write the name of @@ -12087,7 +12206,7 @@ first becomes 10, then 11, and @code{atan2} is called with the two arguments 11 and 10. -@node Numeric Functions, String Functions, Calling Built-in, Built-in +@node Numeric Functions @subsection Numeric Functions The following list describes all of @@ -12137,7 +12256,7 @@ @cindex random numbers, @code{rand}/@code{srand} functions This returns a random number. The values of @code{rand} are uniformly distributed between zero and one. -The value is never zero and never one.@footnote{The C version of @code{rand} +The value could be zero but is never one.@footnote{The C version of @code{rand} is known to produce fairly poor sequences of random numbers. However, nothing requires that an @command{awk} implementation use the C @code{rand} to implement the @command{awk} version of @code{rand}. @@ -12214,7 +12333,7 @@ sequences of random numbers. @end table -@node String Functions, I/O Functions, Numeric Functions, Built-in +@node String Functions @subsection String-Manipulation Functions The functions in this @value{SECTION} look at or change the text of one or more @@ -12267,9 +12386,9 @@ @end example The @code{asort} function is described in more detail in -@ref{Array Sorting, ,Sorting Array Values and Indices with @command{gawk}}. +@ref{Array Sorting}. @code{asort} is a @command{gawk} extension; it is not available -in compatibility mode (@pxref{Options, ,Command-Line Options}). +in compatibility mode (@pxref{Options}). @item asorti(@var{source} @r{[}, @var{dest}@r{]}) # @cindex @code{asorti} function (@command{gawk}) @@ -12281,10 +12400,10 @@ @code{IGNORECASE} affects the sorting.) The @code{asorti} function is described in more detail in -@ref{Array Sorting, ,Sorting Array Values and Indices with @command{gawk}}. +@ref{Array Sorting}. It was added in @command{gawk} 3.1.2. @code{asorti} is a @command{gawk} extension; it is not available -in compatibility mode (@pxref{Options, ,Command-Line Options}). +in compatibility mode (@pxref{Options}). @item index(@var{in}, @var{find}) @cindex @code{index} function @@ -12336,7 +12455,7 @@ The @var{regexp} argument may be either a regexp constant (@samp{/@dots{}/}) or a string constant (@var{"@dots{}"}). In the latter case, the string is treated as a regexp to be matched. -@ref{Computed Regexps, ,Using Dynamic Regexps}, for a +@ref{Computed Regexps}, for a discussion of the difference between the two forms, and the implications for writing your program correctly. @@ -12430,10 +12549,15 @@ @print{} 9 7 @end example +There may not be subscripts for the start and index for every parenthesized +subexpressions, since they may not all have matched text; thus they +should be tested for with the @code{in} operator +(@pxref{Reference to Elements}). + @cindex troubleshooting, @code{match} function The @var{array} argument to @code{match} is a @command{gawk} extension. In compatibility mode -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), using a third argument is a fatal error. @item split(@var{string}, @var{array} @r{[}, @var{fieldsep}@r{]}) @@ -12486,7 +12610,7 @@ string. @value{DARKCORNER} The POSIX standard allows this as well. -@ref{Computed Regexps, ,Using Dynamic Regexps}, for a +@ref{Computed Regexps}, for a discussion of the difference between using a string constant or a regexp constant, and the implications for writing your program correctly. @@ -12495,7 +12619,7 @@ If @var{string} is null, the array has no elements. (So this is a portable way to delete an entire array with one statement. -@xref{Delete, ,The @code{delete} Statement}.) +@xref{Delete}.) If @var{string} does not match @var{fieldsep} at all (but is not null), @var{array} has one element only. The value of that element is the original @@ -12505,7 +12629,7 @@ @cindex @code{sprintf} function This returns (without printing) the string that @code{printf} would have printed out with the same arguments -(@pxref{Printf, ,Using @code{printf} Statements for Fancier Printing}). +(@pxref{Printf}). For example: @example @@ -12534,11 +12658,11 @@ to a string value; the automatic coercion of strings to numbers works only for decimal data, not for octal or hexadecimal.@footnote{Unless you use the @option{--non-decimal-data} option, which isn't recommended. -@xref{Nondecimal Data, ,Allowing Nondecimal Input Data}, for more information.} +@xref{Nondecimal Data}, for more information.} @cindex differences in @command{awk} and @command{gawk}, @code{strtonum} function (@command{gawk}) @code{strtonum} is a @command{gawk} extension; it is not available -in compatibility mode (@pxref{Options, ,Command-Line Options}). +in compatibility mode (@pxref{Options}). @item sub(@var{regexp}, @var{replacement} @r{[}, @var{target}@r{]}) @cindex @code{sub} function @@ -12552,7 +12676,7 @@ The @var{regexp} argument may be either a regexp constant (@samp{/@dots{}/}) or a string constant (@var{"@dots{}"}). In the latter case, the string is treated as a regexp to be matched. -@ref{Computed Regexps, ,Using Dynamic Regexps}, for a +@ref{Computed Regexps}, for a discussion of the difference between the two forms, and the implications for writing your program correctly. @@ -12605,7 +12729,7 @@ @noindent This shows how @samp{&} can represent a nonconstant string and also illustrates the ``leftmost, longest'' rule in regexp matching -(@pxref{Leftmost Longest, ,How Much Text Matches?}). +(@pxref{Leftmost Longest}). The effect of this special character (@samp{&}) can be turned off by putting a backslash before it in the string. As usual, to insert one backslash in @@ -12723,7 +12847,7 @@ is the original unchanged value of @var{target}. @code{gensub} is a @command{gawk} extension; it is not available -in compatibility mode (@pxref{Options, ,Command-Line Options}). +in compatibility mode (@pxref{Options}). @item substr(@var{string}, @var{start} @r{[}, @var{length}@r{]}) @cindex @code{substr} function @@ -12798,7 +12922,7 @@ @code{toupper("MiXeD cAsE 123")} returns @code{"MIXED CASE 123"}. @end table -@node Gory Details, , String Functions, String Functions +@node Gory Details @subsubsection More About @samp{\} and @samp{&} with @code{sub}, @code{gsub}, and @code{gensub} @cindex escape processing, @code{gsub}/@code{gensub}/@code{sub} functions @@ -13051,7 +13175,7 @@ @noindent Although this makes a certain amount of sense, it can be surprising. -@node I/O Functions, Time Functions, String Functions, Built-in +@node I/O Functions @subsection Input/Output Functions The following functions relate to input/output (I/O). @@ -13064,7 +13188,7 @@ Close the file @var{filename} for input or output. Alternatively, the argument may be a shell command that was used for creating a coprocess, or for redirecting to or from a pipe; then the coprocess or pipe is closed. -@xref{Close Files And Pipes, ,Closing Input and Output Redirections}, +@xref{Close Files And Pipes}, for more information. When closing a coprocess, it is occasionally useful to first close @@ -13073,7 +13197,7 @@ should be one of the two string values @code{"to"} or @code{"from"}, indicating which end of the pipe to close. Case in the string does not matter. -@xref{Two-way I/O, ,Two-Way Communications with Another Process}, +@xref{Two-way I/O}, which discusses this feature in more detail and gives an example. @item fflush(@r{[}@var{filename}@r{]}) @@ -13099,7 +13223,7 @@ @code{fflush} was added to the Bell Laboratories research version of @command{awk} in 1994; it is not part of the POSIX standard and is not available if @option{--posix} has been specified on the -command line (@pxref{Options, ,Command-Line Options}). +command line (@pxref{Options}). @cindex @command{gawk}, @code{fflush} function in @command{gawk} extends the @code{fflush} function in two ways. The first @@ -13265,7 +13389,7 @@ If @command{awk} did not flush its buffers before calling @code{system}, you would see the latter (undesirable) output. -@node Time Functions, Bitwise Functions, I/O Functions, Built-in +@node Time Functions @subsection Using @command{gawk}'s Timestamp Functions @c STARTOFRANGE tst @@ -13371,7 +13495,7 @@ The @code{strftime} function allows you to easily turn a timestamp into human-readable information. It is similar in nature to the @code{sprintf} function -(@pxref{String Functions, ,String Manipulation Functions}), +(@pxref{String Functions}), in that it copies nonformat specification characters verbatim to the returned string, while substituting date and time values for format specifications in the @var{format} string. @@ -13522,7 +13646,7 @@ it; these facilities are meant to make it easier to ``internationalize'' programs. Other internationalization features are described in -@ref{Internationalization, ,Internationalization with @command{gawk}}.} +@ref{Internationalization}.} (These facilitate compliance with the POSIX @command{date} utility.) @item %% @@ -13551,7 +13675,7 @@ for systems that are not yet fully standards-compliant. It supports all of the just listed format specifications. If that version is -used to compile @command{gawk} (@pxref{Installation, ,Installing @command{gawk}}), +used to compile @command{gawk} (@pxref{Installation}), then the following additional format specifications are available: @table @code @@ -13634,7 +13758,7 @@ @c ENDOFRANGE filogtst @c ENDOFRANGE gawtst -@node Bitwise Functions, I18N Functions, Time Functions, Built-in +@node Bitwise Functions @subsection Bit-Manipulation Functions of @command{gawk} @c STARTOFRANGE bit @cindex bitwise, operations @@ -13781,12 +13905,12 @@ @end multitable For all of these functions, first the double-precision floating-point value is -converted to a C @code{unsigned long}, then the bitwise operation is +converted to the widest C unsigned integer type, then the bitwise operation is performed and then the result is converted back into a C @code{double}. (If you don't understand this paragraph, don't worry about it.) Here is a user-defined function -(@pxref{User-defined, ,User-Defined Functions}) +(@pxref{User-defined}) that illustrates the use of these functions: @cindex @code{bits2str} user-defined function @@ -13882,7 +14006,7 @@ The main code in the @code{BEGIN} rule shows the difference between the decimal and octal values for the same numbers -(@pxref{Nondecimal-numbers, ,Octal and Hexadecimal Numbers}), +(@pxref{Nondecimal-numbers}), and then demonstrates the results of the @code{compl}, @code{lshift}, and @code{rshift} functions. @c ENDOFRANGE bit @@ -13891,7 +14015,7 @@ @c ENDOFRANGE xor @c ENDOFRANGE opbit -@node I18N Functions, , Bitwise Functions, Built-in +@node I18N Functions @subsection Using @command{gawk}'s String-Translation Functions @cindex @command{gawk}, string-translation functions @cindex functions, string-translation @@ -13901,7 +14025,7 @@ @command{gawk} provides facilities for internationalizing @command{awk} programs. These include the functions described in the following list. The descriptions here are purposely brief. -@xref{Internationalization, ,Internationalization with @command{gawk}}, +@xref{Internationalization}, for the full story. Optional parameters are enclosed in square brackets ([ ]): @@ -13939,7 +14063,7 @@ @c ENDOFRANGE funcbi @c ENDOFRANGE bifunc -@node User-defined, , Built-in, Functions +@node User-defined @section User-Defined Functions @c STARTOFRANGE udfunc @@ -13960,7 +14084,7 @@ * Dynamic Typing:: How variable types can change at runtime. @end menu -@node Definition Syntax, Function Example, User-defined, User-defined +@node Definition Syntax @subsection Function Definition Syntax @c STARTOFRANGE fdef @@ -14053,7 +14177,7 @@ abbreviated @code{func}. However, POSIX only specifies the use of the keyword @code{function}. This actually has some practical implications. If @command{gawk} is in POSIX-compatibility mode -(@pxref{Options, ,Command-Line Options}), then the following +(@pxref{Options}), then the following statement does @emph{not} define a function: @example @@ -14074,7 +14198,7 @@ To ensure that your @command{awk} programs are portable, always use the keyword @code{function} when defining a function. -@node Function Example, Function Caveats, Definition Syntax, User-defined +@node Function Example @subsection Function Definition Examples Here is an example of a user-defined function, called @code{myprint}, that @@ -14125,7 +14249,7 @@ When working with arrays, it is often necessary to delete all the elements in an array and start over with a new list of elements -(@pxref{Delete, ,The @code{delete} Statement}). +(@pxref{Delete}). Instead of having to repeat this loop everywhere that you need to clear out an array, your program can just call @code{delarray}. @@ -14161,7 +14285,7 @@ The C @code{ctime} function takes a timestamp and returns it in a string, formatted in a well-known fashion. The following example uses the built-in @code{strftime} function -(@pxref{Time Functions, ,Using @command{gawk}'s Timestamp Functions}) +(@pxref{Time Functions}) to create an @command{awk} version of @code{ctime}: @cindex @code{ctime} user-defined function @@ -14183,7 +14307,7 @@ @end example @c ENDOFRANGE fdef -@node Function Caveats, Return Statement, Function Example, User-defined +@node Function Caveats @subsection Calling User-Defined Functions @c STARTOFRANGE fudc @@ -14302,18 +14426,18 @@ @cindex lint checking, undefined functions If @option{--lint} is specified -(@pxref{Options, ,Command-Line Options}), +(@pxref{Options}), @command{gawk} reports calls to undefined functions. @cindex portability, @code{next} statement in user-defined functions Some @command{awk} implementations generate a runtime error if you use the @code{next} statement -(@pxref{Next Statement, , The @code{next} Statement}) +(@pxref{Next Statement}) inside a user-defined function. @command{gawk} does not have this limitation. @c ENDOFRANGE fudc -@node Return Statement, Dynamic Typing, Function Caveats, User-defined +@node Return Statement @subsection The @code{return} Statement @c comma does NOT start a secondary @cindex @code{return} statement, user-defined functions @@ -14404,7 +14528,7 @@ the program reports (predictably) that @code{99385} is the largest number in the array. -@node Dynamic Typing, , Return Statement, User-defined +@node Dynamic Typing @subsection Functions and Their Effects on Variable Typing @command{awk} is a very fluid language. @@ -14432,7 +14556,7 @@ @c ENDOFRANGE udfunc @c ENDOFRANGE funcud -@node Internationalization, Advanced Features, Functions, Top +@node Internationalization @chapter Internationalization with @command{gawk} Once upon a time, computer makers @@ -14467,7 +14591,7 @@ * Gawk I18N:: @command{gawk} is also internationalized. @end menu -@node I18N and L10N, Explaining gettext, Internationalization, Internationalization +@node I18N and L10N @section Internationalization and Localization @cindex internationalization @@ -14484,7 +14608,7 @@ responses, and information related to how numerical and monetary values are printed and read. -@node Explaining gettext, Programmer i18n, I18N and L10N, Internationalization +@node Explaining gettext @section GNU @code{gettext} @cindex internationalizing a program @@ -14633,7 +14757,7 @@ This information is accessed via the POSIX character classes in regular expressions, such as @code{/[[:alnum:]]/} -(@pxref{Regexp Operators, ,Regular Expression Operators}). +(@pxref{Regexp Operators}). @cindex monetary information, localization @cindex currency symbols, localization @@ -14669,7 +14793,7 @@ @end table @c ENDOFRANGE gettex -@node Programmer i18n, Translator i18n, Explaining gettext, Internationalization +@node Programmer i18n @section Internationalizing @command{awk} Programs @c STARTOFRANGE inap @cindex @command{awk} programs, internationalizing @@ -14704,7 +14828,7 @@ the previous @value{SECTION}. @end ifnotinfo @ifinfo -@ref{Explaining gettext, ,GNU @code{gettext}}. +@ref{Explaining gettext}. @end ifinfo You must also supply a text domain. Use @code{TEXTDOMAIN} if you want to use the current domain. @@ -14751,7 +14875,7 @@ the previous @value{SECTION}, @end ifnotinfo @ifinfo -@ref{Explaining gettext, ,GNU @code{gettext}}, +@ref{Explaining gettext}, @end ifinfo like so: @@ -14761,9 +14885,9 @@ @item Set the variable @code{TEXTDOMAIN} to the text domain of your program. This is best done in a @code{BEGIN} rule -(@pxref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}), +(@pxref{BEGIN/END}), or it can also be done via the @option{-v} command-line -option (@pxref{Options, ,Command-Line Options}): +option (@pxref{Options}): @example BEGIN @{ @@ -14821,11 +14945,11 @@ @end enumerate -@xref{I18N Example, ,A Simple Internationalization Example}, +@xref{I18N Example}, for an example program showing the steps to create and use translations from @command{awk}. -@node Translator i18n, I18N Example, Programmer i18n, Internationalization +@node Translator i18n @section Translating @command{awk} Programs @cindex @code{.po} files @@ -14835,7 +14959,7 @@ Once a program's translatable strings have been marked, they must be extracted to create the initial @file{.po} file. As part of translation, it is often helpful to rearrange the order -in which arguments to @code{printf} are output. +in which arguments to @code{printf} are output. @command{gawk}'s @option{--gen-po} command-line option extracts the messages and is discussed next. @@ -14849,7 +14973,7 @@ * I18N Portability:: @command{awk}-level portability issues. @end menu -@node String Extraction, Printf Ordering, Translator i18n, Translator i18n +@node String Extraction @subsection Extracting Marked Strings @cindex strings, extracting @c comma does NOT start secondary @@ -14880,18 +15004,18 @@ second argument to @code{dcngettext}.@footnote{Starting with @code{gettext} version 0.11.5, the @command{xgettext} utility that comes with GNU @code{gettext} can handle @file{.awk} files.} -@xref{I18N Example, ,A Simple Internationalization Example}, +@xref{I18N Example}, for the full list of steps to go through to create and test translations for @command{guide}. -@node Printf Ordering, I18N Portability, String Extraction, Translator i18n +@node Printf Ordering @subsection Rearranging @code{printf} Arguments @cindex @code{printf} statement, positional specifiers @c comma does NOT start secondary @cindex positional specifiers, @code{printf} statement Format strings for @code{printf} and @code{sprintf} -(@pxref{Printf, ,Using @code{printf} Statements for Fancier Printing}) +(@pxref{Printf}) present a special problem for translation. Consider the following:@footnote{This example is borrowed from the GNU @code{gettext} manual.} @@ -14978,7 +15102,7 @@ format strings into languages different from the one in which the program is first written. -@node I18N Portability, , Printf Ordering, Translator i18n +@node I18N Portability @subsection @command{awk} Portability Issues @cindex portability, internationalization and @@ -15060,7 +15184,7 @@ @end itemize @c ENDOFRANGE inap -@node I18N Example, Gawk I18N, Translator i18n, Internationalization +@node I18N Example @section A Simple Internationalization Example Now let's look at a step-by-step example of how to internationalize and @@ -15180,7 +15304,7 @@ If the three replacement functions for @code{dcgettext}, @code{dcngettext} and @code{bindtextdomain} -(@pxref{I18N Portability, ,@command{awk} Portability Issues}) +(@pxref{I18N Portability}) are in a file named @file{libintl.awk}, then we can run @file{guide.awk} unchanged as follows: @@ -15191,7 +15315,7 @@ @print{} Pardon me, Zaphod who? @end example -@node Gawk I18N, , I18N Example, Internationalization +@node Gawk I18N @section @command{gawk} Can Speak Your Language As of @value{PVERSION} 3.1, @command{gawk} itself has been internationalized @@ -15222,7 +15346,7 @@ for more information. @c ENDOFRANGE inloc -@node Advanced Features, Invoking Gawk, Internationalization, Top +@node Advanced Features @chapter Advanced Features of @command{gawk} @cindex advanced features, network connections, See Also networks, connections @c STARTOFRANGE gawadv @@ -15254,7 +15378,7 @@ can @dfn{profile} an @command{awk} program, making it possible to tune it for performance. -@ref{Dynamic Extensions, ,Adding New Built-in Functions to @command{gawk}}, +@ref{Dynamic Extensions}, discusses the ability to dynamically add new built-in functions to @command{gawk}. As this feature is still immature and likely to change, its description is relegated to an appendix. @@ -15267,7 +15391,7 @@ * Profiling:: Profiling your @command{awk} programs. @end menu -@node Nondecimal Data, Two-way I/O, Advanced Features, Advanced Features +@node Nondecimal Data @section Allowing Nondecimal Input Data @cindex @code{--non-decimal-data} option @cindex advanced features, @command{gawk}, nondecimal input data @@ -15320,11 +15444,11 @@ @emph{Use of this option is not recommended.} It can break old programs very badly. Instead, use the @code{strtonum} function to convert your data -(@pxref{Nondecimal-numbers, ,Octal and Hexadecimal Numbers}). +(@pxref{Nondecimal-numbers}). This makes your programs easier to write and easier to read, and leads to less surprising results. -@node Two-way I/O, TCP/IP Networking, Nondecimal Data, Advanced Features +@node Two-way I/O @section Two-Way Communications with Another Process @cindex Brennan, Michael @cindex programmers, attractiveness of @@ -15440,7 +15564,7 @@ It is possible to close just one end of the two-way pipe to a coprocess, by supplying a second argument to the @code{close} function of either @code{"to"} or @code{"from"} -(@pxref{Close Files And Pipes, ,Closing Input and Output Redirections}). +(@pxref{Close Files And Pipes}). These strings tell @command{gawk} to close the end of the pipe that sends data to the process or the end that reads from it, respectively. @@ -15487,7 +15611,7 @@ two-way communication instead of pipes, if your system supports them. This is done on a per-command basis, by setting a special element in the @code{PROCINFO} array -(@pxref{Auto-set, ,Built-in Variables That Convey Information}), +(@pxref{Auto-set}), like so: @example @@ -15503,7 +15627,7 @@ system's ptys are in use, @command{gawk} automatically falls back to using regular pipes. -@node TCP/IP Networking, Portal Files, Two-way I/O, Advanced Features +@node TCP/IP Networking @section Using @command{gawk} for Network Programming @cindex advanced features, @command{gawk}, network programming @cindex networks, programming @@ -15521,7 +15645,7 @@ In addition to being able to open a two-way pipeline to a coprocess on the same system -(@pxref{Two-way I/O, ,Two-Way Communications with Another Process}), +(@pxref{Two-way I/O}), it is possible to make a two-way connection to another process on another system across an IP networking connection. @@ -15591,7 +15715,7 @@ for a much more complete introduction and discussion, as well as extensive examples. -@node Portal Files, Profiling, TCP/IP Networking, Advanced Features +@node Portal Files @section Using @command{gawk} with BSD Portals @cindex advanced features, @command{gawk}, BSD portals @cindex portal files @@ -15604,7 +15728,7 @@ Similar to the @file{/inet} special files, if @command{gawk} is configured with the @option{--enable-portals} option -(@pxref{Quick Installation, , Compiling @command{gawk} for Unix}), +(@pxref{Quick Installation}), then @command{gawk} treats files whose pathnames begin with @code{/p} as 4.4 BSD-style portals. @@ -15616,7 +15740,7 @@ the corresponding communications with the portal's process. @c ENDOFRANGE tcpip -@node Profiling, , Portal Files, Advanced Features +@node Profiling @section Profiling Your @command{awk} Programs @c STARTOFRANGE awkp @cindex @command{awk} programs, profiling @@ -15793,7 +15917,7 @@ those statements were executed. @cindex @code{@{@}} (braces), @command{pgawk} program -@cindex braces (@code{@{@}}), @command{pgawk} program +@cindex braces (@code{@{@}}), @command{pgawk} program @item The layout uses ``K&R'' style with tabs. Braces are used everywhere, even when @@ -15921,7 +16045,7 @@ @c ENDOFRANGE awkp @c ENDOFRANGE proawk -@node Invoking Gawk, Library Functions, Advanced Features, Top +@node Invoking Gawk @chapter Running @command{awk} and @command{gawk} This @value{CHAPTER} covers how to run awk, both POSIX-standard @@ -15948,7 +16072,7 @@ * Known Bugs:: Known Bugs in @command{gawk}. @end menu -@node Command Line, Options, Invoking Gawk, Invoking Gawk +@node Command Line @section Invoking @command{awk} @cindex command line, invoking @command{awk} from @cindex @command{awk}, invoking @@ -15987,7 +16111,7 @@ been specified on the command line, @command{gawk} issues a warning that the program is empty. -@node Options, Other Arguments, Command Line, Invoking Gawk +@node Options @section Command-Line Options @c STARTOFRANGE ocl @cindex options, command-line @@ -16022,7 +16146,7 @@ @cindex @code{--field-separator} option @cindex @code{FS} variable, @code{--field-separator} option and Sets the @code{FS} variable to @var{fs} -(@pxref{Field Separators, ,Specifying How Fields Are Separated}). +(@pxref{Field Separators}). @item -f @var{source-file} @itemx --file @var{source-file} @@ -16040,7 +16164,7 @@ Sets the variable @var{var} to the value @var{val} @emph{before} execution of the program begins. Such variable values are available inside the @code{BEGIN} rule -(@pxref{Other Arguments, ,Other Command-Line Arguments}). +(@pxref{Other Arguments}). The @option{-v} option can only set one variable, but it can be used more than once, setting another variable each time, like this: @@ -16110,9 +16234,9 @@ the @command{awk} language are disabled, so that @command{gawk} behaves just like the Bell Laboratories research version of Unix @command{awk}. @option{--traditional} is the preferred form of this option. -@xref{POSIX/GNU, ,Extensions in @command{gawk} Not in POSIX @command{awk}}, +@xref{POSIX/GNU}, which summarizes the extensions. Also see -@ref{Compatibility Mode, ,Downward Compatibility and Debugging}. +@ref{Compatibility Mode}. @item -W copyright @itemx --copyright @@ -16154,7 +16278,7 @@ Analyzes the source program and generates a GNU @code{gettext} Portable Object file on standard output for all string constants that have been marked for translation. -@xref{Internationalization, ,Internationalization with @command{gawk}}, +@xref{Internationalization}, for information about this option. @item -W help @@ -16190,7 +16314,7 @@ @cindex @code{--lint-old} option Warns about constructs that are not available in the original version of @command{awk} from Version 7 Unix -(@pxref{V7/SVR3.1, ,Major Changes Between V7 and SVR3.1}). +(@pxref{V7/SVR3.1}). @item -W non-decimal-data @itemx --non-decimal-data @@ -16200,7 +16324,7 @@ @cindex octal values, enabling interpretation of Enable automatic interpretation of octal and hexadecimal values in input data -(@pxref{Nondecimal Data, ,Allowing Nondecimal Input Data}). +(@pxref{Nondecimal Data}). @cindex troubleshooting, @code{--non-decimal-data} option @strong{Caution:} This option can severely break old programs. @@ -16229,15 +16353,15 @@ @item Newlines do not act as whitespace to separate fields when @code{FS} is equal to a single space -(@pxref{Fields, , Examining Fields}). +(@pxref{Fields}). @item Newlines are not allowed after @samp{?} or @samp{:} -(@pxref{Conditional Exp, ,Conditional Expressions}). +(@pxref{Conditional Exp}). @item The synonym @code{func} for the keyword @code{function} is not -recognized (@pxref{Definition Syntax, ,Function Definition Syntax}). +recognized (@pxref{Definition Syntax}). @cindex @code{*} (asterisk), @code{**} operator @cindex asterisk (@code{*}), @code{**} operator @@ -16249,20 +16373,20 @@ @cindex caret (@code{^}), @code{^=} operator @item The @samp{**} and @samp{**=} operators cannot be used in -place of @samp{^} and @samp{^=} (@pxref{Arithmetic Ops, ,Arithmetic Operators}, -and also @pxref{Assignment Ops, ,Assignment Expressions}). +place of @samp{^} and @samp{^=} (@pxref{Arithmetic Ops}, +and also @pxref{Assignment Ops}). @cindex @code{FS} variable, as TAB character @item Specifying @samp{-Ft} on the command-line does not set the value of @code{FS} to be a single TAB character -(@pxref{Field Separators, ,Specifying How Fields Are Separated}). +(@pxref{Field Separators}). @c comma does not start secondary @cindex @code{fflush} function, unsupported @item The @code{fflush} built-in function is not supported -(@pxref{I/O Functions, ,Input/Output Functions}). +(@pxref{I/O Functions}). @end itemize @c @cindex automatic warnings @@ -16278,7 +16402,7 @@ @cindex @code{--profile} option @cindex @command{awk} programs, profiling, enabling Enable profiling of @command{awk} programs -(@pxref{Profiling, ,Profiling Your @command{awk} Programs}). +(@pxref{Profiling}). By default, profiles are created in a file named @file{awkprof.out}. The optional @var{file} argument allows you to specify a different @value{FN} for the profile file. @@ -16293,7 +16417,7 @@ @cindex @code{--re-interval} option @cindex regular expressions, interval expressions and Allows interval expressions -(@pxref{Regexp Operators, , Regular Expression Operators}) +(@pxref{Regexp Operators}) in regexps. Because interval expressions were traditionally not available in @command{awk}, @command{gawk} does not provide them by default. This prevents old @command{awk} @@ -16308,7 +16432,7 @@ Program source code is taken from the @var{program-text}. This is particularly useful when you have library functions that you want to use from your command-line -programs (@pxref{AWKPATH Variable, ,The @env{AWKPATH} Environment Variable}). +programs (@pxref{AWKPATH Variable}). @item -W version @itemx --version @@ -16320,7 +16444,7 @@ with respect to whatever the Free Software Foundation is currently distributing. It is also useful for bug reports -(@pxref{Bugs, , Reporting Problems and Bugs}). +(@pxref{Bugs}). @end table As long as program text has been supplied, @@ -16332,7 +16456,7 @@ to the @option{-F} option is @samp{t}, then @code{FS} is set to the TAB character (@code{"\t"}). This is true only for @option{--traditional} and not for @option{--posix} -(@pxref{Field Separators, ,Specifying How Fields Are Separated}). +(@pxref{Field Separators}). @cindex @code{-f} option, on command line The @option{-f} option may be used more than once on the command line. @@ -16342,7 +16466,7 @@ can be written once and then retrieved from a standard place, instead of having to be included into each individual program. (As mentioned in -@ref{Definition Syntax, ,Function Definition Syntax}, +@ref{Definition Syntax}, function names must be unique.) Library functions can still be used, even if the program is entered at the terminal, @@ -16357,7 +16481,7 @@ @option{--source} option. This does not require you to pre-empt the standard input for your source code; it allows you to easily mix command-line and library source code -(@pxref{AWKPATH Variable, ,The @env{AWKPATH} Environment Variable}). +(@pxref{AWKPATH Variable}). @cindex @code{--source} option If no @option{-f} or @option{--source} option is specified, then @command{gawk} @@ -16400,7 +16524,7 @@ @c ENDOFRANGE ocl @c ENDOFRANGE clo -@node Other Arguments, AWKPATH Variable, Options, Invoking Gawk +@node Other Arguments @section Other Command-Line Arguments @cindex command line, arguments @cindex arguments, command-line @@ -16411,7 +16535,7 @@ the value @var{value} to the variable @var{var}---it does not specify a file at all. (This was discussed earlier in -@ref{Assignment Options, ,Assigning Variables on the Command Line}.) +@ref{Assignment Options}.) @cindex @code{ARGIND} variable, command-line arguments @cindex @code{ARGC}/@code{ARGV} variables, command-line arguments @@ -16434,7 +16558,7 @@ previously specified files have been read. In particular, the values of variables assigned in this fashion are @emph{not} available inside a @code{BEGIN} rule -(@pxref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}), +(@pxref{BEGIN/END}), because such rules are run before @command{awk} begins scanning the argument list. @cindex dark corner, escape sequences @@ -16468,7 +16592,7 @@ the value of @code{FS} is not strictly necessary. It remains for historical compatibility. -@node AWKPATH Variable, Obsolete, Other Arguments, Invoking Gawk +@node AWKPATH Variable @section The @env{AWKPATH} Environment Variable @cindex @env{AWKPATH} environment variable @cindex directories, searching @@ -16507,10 +16631,10 @@ By using both the @option{--source} and @option{-f} options, your command-line @command{awk} programs can use facilities in @command{awk} library files -(@pxref{Library Functions, , A Library of @command{awk} Functions}). +(@pxref{Library Functions}). Path searching is not done if @command{gawk} is in compatibility mode. This is true for both @option{--traditional} and @option{--posix}. -@xref{Options, ,Command-Line Options}. +@xref{Options}. @strong{Note:} If you want files in the current directory to be found, you must include the current directory in the path, either by including @@ -16534,7 +16658,7 @@ source files. Once your program is running, all the files have been found, and @command{gawk} no longer needs to use @env{AWKPATH}. -@node Obsolete, Undocumented, AWKPATH Variable, Invoking Gawk +@node Obsolete @section Obsolete Options and/or Features @cindex features, advanced, See advanced features @@ -16559,12 +16683,12 @@ two-word usage is no longer accepted. The process-related special files described in -@ref{Special Process, ,Special Files for Process-Related Information}, +@ref{Special Process}, work as described, but are now considered deprecated. @command{gawk} prints a warning message every time they are used. (Use @code{PROCINFO} instead; see -@ref{Auto-set, ,Built-in Variables That Convey Information}.) +@ref{Auto-set}.) They will be removed from the next release of @command{gawk}. @ignore @@ -16573,10 +16697,10 @@ in case some option becomes obsolete in a future version of @command{gawk}. @end ignore -@node Undocumented, Known Bugs, Obsolete, Invoking Gawk +@node Undocumented @section Undocumented Options and Features @cindex undocumented features -@cindex features, undocumented +@cindex features, undocumented @cindex Skywalker, Luke @cindex Kenobi, Obi-Wan @cindex Jedi knights @@ -16630,7 +16754,7 @@ @end example @noindent -@xref{Statements/Lines, ,@command{awk} Statements Versus Lines}, for a fuller +@xref{Statements/Lines}, for a fuller explanation. You can insert newlines after the @samp{;} in @code{for} loops. @@ -16654,7 +16778,7 @@ @end ignore -@node Known Bugs, , Undocumented, Invoking Gawk +@node Known Bugs @section Known Bugs in @command{gawk} @cindex @command{gawk}, debugging @cindex debugging @command{gawk} @@ -16666,7 +16790,7 @@ @cindex @code{FS} variable, changing value of @item The @option{-F} option for changing the value of @code{FS} -(@pxref{Options, ,Command-Line Options}) +(@pxref{Options}) is not necessary given the command-line variable assignment feature; it remains only for backward compatibility. @@ -16689,10 +16813,10 @@ @itemize @bullet @item -@ref{Library Functions, ,A Library of @command{awk} Functions}. +@ref{Library Functions}. @item -@ref{Sample Programs, ,Practical @command{awk} Programs}. +@ref{Sample Programs}. @end itemize @@ -16702,7 +16826,7 @@ @end iftex @end ignore -@node Library Functions, Sample Programs, Invoking Gawk, Top +@node Library Functions @chapter A Library of @command{awk} Functions @c STARTOFRANGE libf @cindex libraries of @command{awk} functions @@ -16711,7 +16835,7 @@ @c STARTOFRANGE fudlib @cindex functions, user-defined, library of -@ref{User-defined, ,User-Defined Functions}, describes how to write +@ref{User-defined}, describes how to write your own @command{awk} functions. Writing functions is important, because it allows you to encapsulate algorithms and program tasks in a single place. It simplifies programming, making program development more @@ -16719,7 +16843,7 @@ One valuable way to learn a new programming language is to @emph{read} programs in that language. To that end, this @value{CHAPTER} -and @ref{Sample Programs, ,Practical @command{awk} Programs}, +and @ref{Sample Programs}, provide a good-sized body of code for you to read, and hopefully, to learn from. @@ -16730,7 +16854,7 @@ The functions are presented here in a progression from simple to complex. @cindex Texinfo -@ref{Extract Program, ,Extracting Programs from Texinfo Source Files}, +@ref{Extract Program}, presents a program that you can use to extract the source code for these example library functions and programs from the Texinfo source for this @value{DOCUMENT}. @@ -16739,11 +16863,11 @@ If you have written one or more useful, general-purpose @command{awk} functions and would like to contribute them to the author's collection of @command{awk} programs, see -@ref{How To Contribute, ,How to Contribute}, for more information. +@ref{How To Contribute}, for more information. @cindex portability, example programs The programs in this @value{CHAPTER} and in -@ref{Sample Programs, ,Practical @command{awk} Programs}, +@ref{Sample Programs}, freely use features that are @command{gawk}-specific. Rewriting these programs for different implementations of awk is pretty straightforward. @@ -16752,9 +16876,9 @@ does not have a @file{/dev/stderr}, or if you cannot use @command{gawk}. A number of programs use @code{nextfile} -(@pxref{Nextfile Statement, ,Using @command{gawk}'s @code{nextfile} Statement}) +(@pxref{Nextfile Statement}) to skip any remaining input in the input file. -@ref{Nextfile Function, ,Implementing @code{nextfile} as a Function}, +@ref{Nextfile Function}, shows you how to write a function that does the same thing. @c 12/2000: Thanks to Nelson Beebe for pointing out the output issue. @@ -16789,7 +16913,7 @@ * Group Functions:: Functions for getting group information. @end menu -@node Library Names, General Functions, Library Functions, Library Functions +@node Library Names @section Naming Library Function Global Variables @cindex names, arrays/variables @@ -16808,7 +16932,7 @@ Library functions often need to have global variables that they can use to preserve state information between calls to the function---for example, @code{getopt}'s variable @code{_opti} -(@pxref{Getopt Function, ,Processing Command-Line Options}). +(@pxref{Getopt Function}). Such variables are called @dfn{private}, since the only functions that need to use them are the ones in the library. @@ -16830,7 +16954,7 @@ In addition, several of the library functions use a prefix that helps indicate what function or set of functions use the variables---for example, @code{_pw_byname} in the user database routines -(@pxref{Passwd Functions, ,Reading the User Database}). +(@pxref{Passwd Functions}). This convention is recommended, since it even further decreases the chance of inadvertent conflict among variable names. Note that this convention is used equally well for variable names and for private @@ -16843,7 +16967,7 @@ available for use by a main program, it is a good convention to start that variable's name with a capital letter---for example, @code{getopt}'s @code{Opterr} and @code{Optind} variables -(@pxref{Getopt Function, ,Processing Command-Line Options}). +(@pxref{Getopt Function}). The leading capital letter indicates that it is global, while the fact that the variable name is not all capital letters indicates that the variable is not one of @command{awk}'s built-in variables, such as @code{FS}. @@ -16873,7 +16997,7 @@ associative array to hold the values needed by the library function(s), or ``package.'' This significantly decreases the number of actual global names in use. For example, the functions described in -@ref{Passwd Functions, , Reading the User Database}, +@ref{Passwd Functions}, might have used array elements @code{@w{PW_data["inited"]}}, @code{@w{PW_data["total"]}}, @code{@w{PW_data["count"]}}, and @code{@w{PW_data["awklib"]}}, instead of @code{@w{_pw_inited}}, @code{@w{_pw_awklib}}, @code{@w{_pw_total}}, @@ -16883,7 +17007,7 @@ that: conventions. You are not required to write your programs this way---we merely recommend that you do so. -@node General Functions, Data File Management, Library Names, Library Functions +@node General Functions @section General Programming This @value{SECTION} presents a number of functions that are of general @@ -16903,7 +17027,7 @@ * Gettimeofday Function:: A function to get formatted times. @end menu -@node Nextfile Function, Assert Function, General Functions, General Functions +@node Nextfile Function @subsection Implementing @code{nextfile} as a Function @cindex input files, skipping @@ -16915,7 +17039,7 @@ @cindex @code{nextfile} statement, implementing @cindex @command{gawk}, @code{nextfile} statement in The @code{nextfile} statement, presented in -@ref{Nextfile Statement, ,Using @command{gawk}'s @code{nextfile} Statement}, +@ref{Nextfile Statement}, is a @command{gawk}-specific extension---it is not available in most other implementations of @command{awk}. This @value{SECTION} shows two versions of a @code{nextfile} function that you can use to simulate @command{gawk}'s @@ -16939,7 +17063,7 @@ then the action part of the rule executes a @code{next} statement to go on to the next record. (The use of @samp{_} in the variable name is a convention. It is discussed more fully in -@ref{Library Names, , Naming Library Function Global Variables}.) +@ref{Library Names}.) The use of the @code{next} statement effectively creates a loop that reads all the records from the current @value{DF}. @@ -17035,7 +17159,7 @@ @c ENDOFRANGE flibnex @c ENDOFRANGE nexim -@node Assert Function, Round Function, Nextfile Function, General Functions +@node Assert Function @subsection Assertions @c STARTOFRANGE asse @@ -17153,7 +17277,7 @@ of just a @code{BEGIN} rule, the input files and/or standard input are not read. However, now that the program has an @code{END} rule, @command{awk} attempts to read the input @value{DF}s or standard input -(@pxref{Using BEGIN/END, , Startup and Cleanup Actions}), +(@pxref{Using BEGIN/END}), most likely causing the program to hang as it waits for input. @cindex @code{BEGIN} pattern, @code{assert} user-defined function and @@ -17165,7 +17289,7 @@ @c ENDOFRANGE flibass @c ENDOFRANGE libfass -@node Round Function, Cliff Random Function, Assert Function, General Functions +@node Round Function @subsection Rounding Numbers @cindex rounding @@ -17177,7 +17301,7 @@ @cindex @code{printf} statement, @code{sprintf} function and @cindex @code{sprintf} function, @code{print}/@code{printf} statements and The way @code{printf} and @code{sprintf} -(@pxref{Printf, , Using @code{printf} Statements for Fancier Printing}) +(@pxref{Printf}) perform rounding often depends upon the system's C @code{sprintf} subroutine. On many machines, @code{sprintf} rounding is ``unbiased,'' which means it doesn't always round a trailing @samp{.5} up, contrary @@ -17232,7 +17356,7 @@ @c endfile @end example -@node Cliff Random Function, Ordinal Functions, Round Function, General Functions +@node Cliff Random Function @subsection The Cliff Random Number Generator @cindex random numbers, Cliff @cindex Cliff random numbers @@ -17277,7 +17401,7 @@ (@pxref{Numeric Functions}) isn't random enough, you might try using this function instead. -@node Ordinal Functions, Join Function, Cliff Random Function, General Functions +@node Ordinal Functions @subsection Translating Between Characters and Numbers @cindex libraries of @command{awk} functions, character values as numbers @@ -17397,7 +17521,7 @@ There is a ``test program'' in a @code{BEGIN} rule, to test the function. It is commented out for production use. -@node Join Function, Gettimeofday Function, Ordinal Functions, General Functions +@node Join Function @subsection Merging an Array into a String @cindex libraries of @command{awk} functions, merging arrays into strings @@ -17408,14 +17532,14 @@ all the strings in an array into one long string. The following function, @code{join}, accomplishes this task. It is used later in several of the application programs -(@pxref{Sample Programs, ,Practical @command{awk} Programs}). +(@pxref{Sample Programs}). Good function design is important; this function needs to be general but it should also have a reasonable default behavior. It is called with an array as well as the beginning and ending indices of the elements in the array to be merged. This assumes that the array indices are numeric---a reasonable assumption since the array was likely created with @code{split} -(@pxref{String Functions, ,String Manipulation Functions}): +(@pxref{String Functions}): @cindex @code{join} user-defined function @example @@ -17457,7 +17581,7 @@ The lack of an explicit operator for concatenation makes string operations more difficult than they really need to be.} -@node Gettimeofday Function, , Join Function, General Functions +@node Gettimeofday Function @subsection Managing the Time of Day @cindex libraries of @command{awk} functions, managing, time @@ -17465,7 +17589,7 @@ @cindex timestamps, formatted @cindex time, managing The @code{systime} and @code{strftime} functions described in -@ref{Time Functions, ,Using @command{gawk}'s Timestamp Functions}, +@ref{Time Functions}, provide the minimum functionality necessary for dealing with the time of day in human readable form. While @code{strftime} is extensive, the control formats are not necessarily easy to remember or intuitively obvious when @@ -17551,13 +17675,13 @@ The string indices are easier to use and read than the various formats required by @code{strftime}. The @code{alarm} program presented in -@ref{Alarm Program, ,An Alarm Clock Program}, +@ref{Alarm Program}, uses this function. A more general design for the @code{gettimeofday} function would have allowed the user to supply an optional timestamp value to use instead of the current time. -@node Data File Management, Getopt Function, General Functions, Library Functions +@node Data File Management @section @value{DDF} Management @c STARTOFRANGE dataf @@ -17573,17 +17697,18 @@ * Filetrans Function:: A function for handling data file transitions. * Rewind Function:: A function for rereading the current file. * File Checking:: Checking that data files are readable. +* Empty Files:: Checking for zero-length files. * Ignoring Assigns:: Treating assignments as file names. @end menu -@node Filetrans Function, Rewind Function, Data File Management, Data File Management +@node Filetrans Function @subsection Noting @value{DDF} Boundaries @cindex files, managing, @value{DF} boundaries @cindex files, initialization and cleanup The @code{BEGIN} and @code{END} rules are each executed exactly once at -the beginning and end of your @command{awk} program, respectively -(@pxref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}). +the beginning and end of your @command{awk} program, respectively +(@pxref{BEGIN/END}). We (the @command{gawk} authors) once had a user who mistakenly thought that the @code{BEGIN} rule is executed at the beginning of each @value{DF} and the @code{END} rule is executed at the end of each @value{DF}. When informed @@ -17646,7 +17771,7 @@ @cindex @code{beginfile} user-defined function @cindex @code{endfile} user-defined function This version has same problem as the first version of @code{nextfile} -(@pxref{Nextfile Function, ,Implementing @code{nextfile} as a Function}). +(@pxref{Nextfile Function}). If the same @value{DF} occurs twice in a row on the command line, then @code{endfile} and @code{beginfile} are not executed at the end of the first pass and at the beginning of the second pass. @@ -17678,18 +17803,18 @@ @c endfile @end example -@ref{Wc Program, ,Counting Things}, +@ref{Wc Program}, shows how this library function can be used and how it simplifies writing the main program. -@node Rewind Function, File Checking, Filetrans Function, Data File Management +@node Rewind Function @subsection Rereading the Current File @cindex files, reading Another request for a new built-in function was for a @code{rewind} function that would make it possible to reread the current file. The requesting user didn't want to have to use @code{getline} -(@pxref{Getline, , Explicit Input with @code{getline}}) +(@pxref{Getline}) inside a loop. However, as long as you are not in the @code{END} rule, it is @@ -17730,7 +17855,7 @@ @end example This code relies on the @code{ARGIND} variable -(@pxref{Auto-set, ,Built-in Variables That Convey Information}), +(@pxref{Auto-set}), which is specific to @command{gawk}. If you are not using @command{gawk}, you can use ideas presented in @@ -17738,17 +17863,17 @@ the previous @value{SECTION} @end ifnotinfo @ifinfo -@ref{Filetrans Function, ,Noting @value{DDF} Boundaries}, +@ref{Filetrans Function}, @end ifinfo to either update @code{ARGIND} on your own or modify this code as appropriate. The @code{rewind} function also relies on the @code{nextfile} keyword -(@pxref{Nextfile Statement, ,Using @command{gawk}'s @code{nextfile} Statement}). -@xref{Nextfile Function, ,Implementing @code{nextfile} as a Function}, +(@pxref{Nextfile Statement}). +@xref{Nextfile Function}, for a function version of @code{nextfile}. -@node File Checking, Ignoring Assigns, Rewind Function, Data File Management +@node File Checking @subsection Checking for Readable @value{DDF}s @cindex troubleshooting, readable @value{DF}s @@ -17797,14 +17922,116 @@ @c This doesn't handle /dev/stdin etc. Not worth the hassle to mention or fix. -@node Ignoring Assigns, , File Checking, Data File Management +@node Empty Files +@subsection Checking For Zero-length Files + +All known @command{awk} implementations silently skip over zero-length files. +This is a by-product of @command{awk}'s implicit +read-a-record-and-match-against-the-rules loop: when @command{awk} +tries to read a record from an empty file, it immediately receives an +end of file indication, closes the file, and proceeds on to the next +command-line @value{DF}, @emph{without} executing any user-level +@command{awk} program code. + +Using @command{gawk}'s @code{ARGIND} variable +(@pxref{Built-in Variables}), it is possible to detect when an empty +@value{DF} has been skipped. Similar to the library file presented +in @ref{Filetrans Function}, the following library file calls a function named +@code{zerofile} that the user must provide. The arguments passed are +the @value{FN} and the position in @code{ARGV} where it was found: + +@cindex @code{zerofile.awk} program +@example +@c file eg/lib/zerofile.awk +# zerofile.awk --- library file to process empty input files +@c endfile +@ignore +@c file eg/lib/zerofile.awk +# +# Arnold Robbins, arnold@@gnu.org, Public Domain +# June 2003 + +@c endfile +@end ignore +@c file eg/lib/zerofile.awk +BEGIN @{ Argind = 0 @} + +ARGIND > Argind + 1 @{ + for (Argind++; Argind < ARGIND; Argind++) + zerofile(ARGV[Argind], Argind) +@} + +ARGIND != Argind @{ Argind = ARGIND @} + +END @{ + if (ARGIND > Argind) + for (Argind++; Argind <= ARGIND; Argind++) + zerofile(ARGV[Argind], Argind) +@} +@c endfile +@end example + +The user-level variable @code{Argind} allows the @command{awk} program +to track its progress through @code{ARGV}. Whenever the program detects +that @code{ARGIND} is greater than @samp{Argind + 1}, it means that one or +more empty files were skipped. The action then calls @code{zerofile} for +each such file, incrementing @code{Argind} along the way. + +The @samp{Argind != ARGIND} rule simply keeps @code{Argind} up to date +in the normal case. + +Finally, the @code{END} rule catches the case of any empty files at +the end of the command-line arguments. Note that the test in the +condition of the @code{for} loop uses the @samp{<=} operator, +not @code{<}. + +As an exercise, you might consider whether this same problem can +be solved without relying on @command{gawk}'s @code{ARGIND} variable. + +As a second exercise, revise this code to handle the case where +an intervening value in @code{ARGV} is a variable assignment. + +@ignore +# zerofile2.awk --- same thing, portably +BEGIN @{ + ARGIND = Argind = 0 + for (i = 1; i < ARGC; i++) + Fnames[ARGV[i]]++ + +@} +FNR == 1 @{ + while (ARGV[ARGIND] != FILENAME) + ARGIND++ + Seen[FILENAME]++ + if (Seen[FILENAME] == Fnames[FILENAME]) + do + ARGIND++ + while (ARGV[ARGIND] != FILENAME) +@} +ARGIND > Argind + 1 @{ + for (Argind++; Argind < ARGIND; Argind++) + zerofile(ARGV[Argind], Argind) +@} +ARGIND != Argind @{ + Argind = ARGIND +@} +END @{ + if (ARGIND < ARGC - 1) + ARGIND = ARGC - 1 + if (ARGIND > Argind) + for (Argind++; Argind <= ARGIND; Argind++) + zerofile(ARGV[Argind], Argind) +@} +@end ignore + +@node Ignoring Assigns @subsection Treating Assignments as @value{FFN}s @cindex assignments as filenames @cindex filenames, assignments as Occasionally, you might not want @command{awk} to process command-line variable assignments -(@pxref{Assignment Options, ,Assigning Variables on the Command Line}). +(@pxref{Assignment Options}). In particular, if you have @value{FN}s that contain an @samp{=} character, @command{awk} treats the @value{FN} as an assignment, and does not process it. @@ -17848,7 +18075,7 @@ @end example The function works by looping through the arguments. -It prepends @samp{./} to +It prepends @samp{./} to any argument that matches the form of a variable assignment, turning that argument into a @value{FN}. @@ -17860,7 +18087,7 @@ @c ENDOFRANGE flibdataf @c ENDOFRANGE libfdataf -@node Getopt Function, Passwd Functions, Data File Management, Library Functions +@node Getopt Function @section Processing Command-Line Options @c STARTOFRANGE libfclo @@ -17877,7 +18104,7 @@ Most utilities on POSIX compatible systems take options, or ``switches,'' on the command line that can be used to change the way a program behaves. @command{awk} is an example of such a program -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). Often, options take @dfn{arguments}; i.e., data that the program needs to correctly obey the command-line option. For example, @command{awk}'s @option{-F} option requires a string to use as the field separator. @@ -17973,7 +18200,7 @@ As a side point, @command{gawk} actually uses the GNU @code{getopt_long} function to process both normal and GNU-style long options -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). The abstraction provided by @code{getopt} is very useful and is quite handy in @command{awk} programs as well. Following is an @command{awk} @@ -17981,7 +18208,7 @@ greatest weaknesses in @command{awk}, which is that it is very poor at manipulating single characters. Repeated calls to @code{substr} are necessary for accessing individual characters -(@pxref{String Functions, ,String Manipulation Functions}).@footnote{This +(@pxref{String Functions}).@footnote{This function was written before @command{gawk} acquired the ability to split strings into single characters using @code{""} as the separator. We have left it alone, since using @code{substr} is more portable.} @@ -18203,14 +18430,14 @@ the first @option{--} terminates the arguments to @command{awk}, so that it does not try to interpret the @option{-a}, etc., as its own options. Several of the sample programs presented in -@ref{Sample Programs, ,Practical @command{awk} Programs}, +@ref{Sample Programs}, use @code{getopt} to process their arguments. @c ENDOFRANGE libfclo @c ENDOFRANGE flibclo @c ENDOFRANGE clop @c ENDOFRANGE oclp -@node Passwd Functions, Group Functions, Getopt Function, Library Functions +@node Passwd Functions @section Reading the User Database @c STARTOFRANGE libfudata @@ -18232,7 +18459,7 @@ information to the average user. There needs to be some way to find the user information associated with the user and group ID numbers. This @value{SECTION} presents a suite of functions for retrieving information from the -user database. @xref{Group Functions, ,Reading the Group Database}, +user database. @xref{Group Functions}, for a similar suite that retrieves information from the group database. @cindex @code{getpwent} function (C library) @@ -18575,14 +18802,14 @@ this is not necessary, since most @command{awk} programs are I/O-bound, and it clutters up the code. -The @command{id} program in @ref{Id Program, ,Printing out User Information}, +The @command{id} program in @ref{Id Program}, uses these functions. @c ENDOFRANGE libfudata @c ENDOFRANGE flibudata @c ENDOFRANGE udatar @c ENDOFRANGE dataur -@node Group Functions, , Passwd Functions, Library Functions +@node Group Functions @section Reading the Group Database @c STARTOFRANGE libfgdata @@ -18602,7 +18829,7 @@ @cindex group file @cindex files, group Much of the discussion presented in -@ref{Passwd Functions, ,Reading the User Database}, +@ref{Passwd Functions}, applies to the group database as well. Although there has traditionally been a well-known file (@file{/etc/group}) in a well-known format, the POSIX standard only provides a set of C library routines @@ -18635,7 +18862,7 @@ #if HAVE_CONFIG_H #include #endif - + #if defined (STDC_HEADERS) #include #endif @@ -18818,7 +19045,7 @@ want it to be in a different directory on your system. These routines follow the same general outline as the user database routines -(@pxref{Passwd Functions, ,Reading the User Database}). +(@pxref{Passwd Functions}). The @code{@w{_gr_inited}} variable is used to ensure that the database is scanned no more than once. The @code{@w{_gr_init}} function first saves @code{FS}, @code{FIELDWIDTHS}, @code{RS}, and @@ -18945,7 +19172,7 @@ associative arrays. The functions that the user calls are themselves very simple, relying on @command{awk}'s associative arrays to do work. -The @command{id} program in @ref{Id Program, ,Printing out User Information}, +The @command{id} program in @ref{Id Program}, uses these functions. @c ENDOFRANGE libfgdata @c ENDOFRANGE flibgdata @@ -18955,12 +19182,12 @@ @c ENDOFRANGE fudlib @c ENDOFRANGE datagr -@node Sample Programs, Language History, Library Functions, Top +@node Sample Programs @chapter Practical @command{awk} Programs @c STARTOFRANGE awkpex @cindex @command{awk} programs, examples of -@ref{Library Functions, ,A Library of @command{awk} Functions}, +@ref{Library Functions}, presents the idea that reading programs in a language contributes to learning that language. This @value{CHAPTER} continues that theme, presenting a potpourri of @command{awk} programs for your reading @@ -18985,7 +19212,7 @@ @end ifnotinfo Many of these programs use the library functions presented in -@ref{Library Functions, ,A Library of @command{awk} Functions}. +@ref{Library Functions}. @menu * Running Examples:: How to run these examples. @@ -18993,7 +19220,7 @@ * Miscellaneous Programs:: Some interesting @command{awk} programs. @end menu -@node Running Examples, Clones, Sample Programs, Sample Programs +@node Running Examples @section Running the Example Programs To run a given program, you would typically do something like this: @@ -19008,7 +19235,7 @@ program that start with a @samp{-}, and @var{files} are the actual @value{DF}s. If your system supports the @samp{#!} executable interpreter mechanism -(@pxref{Executable Scripts, , Executable @command{awk} Programs}), +(@pxref{Executable Scripts}), you can instead run your program directly: @example @@ -19021,7 +19248,7 @@ cut.awk -- -c1-8 myfiles > results @end example -@node Clones, Miscellaneous Programs, Running Examples, Sample Programs +@node Clones @section Reinventing Wheels for Fun and Profit @c last comma is part of secondary @c STARTOFRANGE posimawk @@ -19049,7 +19276,7 @@ * Wc Program:: The @command{wc} utility. @end menu -@node Cut Program, Egrep Program, Clones, Clones +@node Cut Program @subsection Cutting out Fields and Columns @cindex @command{cut} utility @@ -19095,9 +19322,9 @@ @end table The @command{awk} implementation of @command{cut} uses the @code{getopt} library -function (@pxref{Getopt Function, ,Processing Command-Line Options}) +function (@pxref{Getopt Function}) and the @code{join} library function -(@pxref{Join Function, ,Merging an Array into a String}). +(@pxref{Join Function}). The program begins with a comment describing the options, the library functions needed, and a @code{usage} function that prints out a usage @@ -19271,7 +19498,7 @@ The @code{set_charlist} function is more complicated than @code{set_fieldlist}. The idea here is to use @command{gawk}'s @code{FIELDWIDTHS} variable -(@pxref{Constant Size, ,Reading Fixed-Width Data}), +(@pxref{Constant Size}), which describes constant-width input. When using a character list, that is exactly what we have. @@ -19368,7 +19595,7 @@ This version of @command{cut} relies on @command{gawk}'s @code{FIELDWIDTHS} variable to do the character-based cutting. While it is possible in other @command{awk} implementations to use @code{substr} -(@pxref{String Functions, ,String Manipulation Functions}), +(@pxref{String Functions}), it is also extremely painful. The @code{FIELDWIDTHS} variable supplies an elegant solution to the problem of picking the input line apart by characters. @@ -19378,7 +19605,7 @@ @c Exercise: Rewrite using split with "". -@node Egrep Program, Id Program, Cut Program, Clones +@node Egrep Program @subsection Searching for Regular Expressions in Files @c STARTOFRANGE regexps @@ -19390,7 +19617,7 @@ @cindex @command{egrep} utility The @command{egrep} utility searches files for patterns. It uses regular expressions that are almost identical to those available in @command{awk} -(@pxref{Regexp, ,Regular Expressions}). +(@pxref{Regexp}). It is used in the following manner: @example @@ -19432,9 +19659,9 @@ @end table This version uses the @code{getopt} library function -(@pxref{Getopt Function, ,Processing Command-Line Options}) +(@pxref{Getopt Function}) and the file transition library program -(@pxref{Filetrans Function, ,Noting @value{DDF} Boundaries}). +(@pxref{Filetrans Function}). The program begins with a descriptive comment and then a @code{BEGIN} rule that processes the command-line arguments with @code{getopt}. The @option{-i} @@ -19673,7 +19900,7 @@ @c ENDOFRANGE sfregexp @c ENDOFRANGE fsregexp -@node Id Program, Split Program, Egrep Program, Clones +@node Id Program @subsection Printing out User Information @cindex printing, user information @@ -19697,9 +19924,9 @@ Here is a simple version of @command{id} written in @command{awk}. It uses the user database library functions -(@pxref{Passwd Functions, ,Reading the User Database}) +(@pxref{Passwd Functions}) and the group database library functions -(@pxref{Group Functions, ,Reading the Group Database}): +(@pxref{Group Functions}): The program is fairly straightforward. All the work is done in the @code{BEGIN} rule. The user and group ID numbers are obtained from @@ -19814,7 +20041,7 @@ arguments and perform in the same way. @end ignore -@node Split Program, Tee Program, Id Program, Clones +@node Split Program @subsection Splitting a Large File into Pieces @c STARTOFRANGE filspl @@ -19838,7 +20065,7 @@ Here is a version of @code{split} in @command{awk}. It uses the @code{ord} and @code{chr} functions presented in -@ref{Ordinal Functions, ,Translating Between Characters and Numbers}. +@ref{Ordinal Functions}. The program first sets its defaults, and then tests to make sure there are not too many arguments. It then looks at each argument in turn. The @@ -19959,7 +20186,7 @@ @c BFD... @c ENDOFRANGE filspl -@node Tee Program, Uniq Program, Split Program, Clones +@node Tee Program @subsection Duplicating Output into Multiple Files @c last comma is part of secondary @@ -19989,7 +20216,7 @@ @code{copy[1]} are deleted. If @code{ARGC} is less than two, then no @value{FN}s were supplied and @code{tee} prints a usage message and exits. Finally, @command{awk} is forced to read the standard input by setting -@code{ARGV[1]} to @code{"-"} and @code{ARGC} to two: +@code{ARGV[1]} to @code{"-"} and @code{ARGC} to two: @c NEXT ED: Add more leading commentary in this program @cindex @code{tee.awk} program @@ -20078,7 +20305,7 @@ @c endfile @end example -@node Uniq Program, Wc Program, Tee Program, Clones +@node Uniq Program @subsection Printing Nonduplicated Lines of Text @c STARTOFRANGE prunt @@ -20132,9 +20359,9 @@ @command{uniq} uses the @code{getopt} library function -(@pxref{Getopt Function, ,Processing Command-Line Options}) +(@pxref{Getopt Function}) and the @code{join} library function -(@pxref{Join Function, ,Merging an Array into a String}). +(@pxref{Join Function}). The program begins with a @code{usage} function and then a brief outline of the options and their meanings in a comment. @@ -20238,7 +20465,7 @@ complicated. If fields have to be skipped, each line is broken into an array using @code{split} -(@pxref{String Functions, ,String Manipulation Functions}); +(@pxref{String Functions}); the desired fields are then joined back into a line using @code{join}. The joined lines are stored in @code{clast} and @code{cline}. If no fields are skipped, @code{clast} and @code{cline} are set to @@ -20337,7 +20564,7 @@ @c ENDOFRANGE prunt @c ENDOFRANGE tpul -@node Wc Program, , Uniq Program, Clones +@node Wc Program @subsection Counting Things @c STARTOFRANGE count @@ -20382,9 +20609,9 @@ and it can easily tell us how long a line is. This uses the @code{getopt} library function -(@pxref{Getopt Function, ,Processing Command-Line Options}) +(@pxref{Getopt Function}) and the file-transition functions -(@pxref{Filetrans Function, ,Noting @value{DDF} Boundaries}). +(@pxref{Filetrans Function}). This version has one notable difference from traditional versions of @command{wc}: it always prints the counts in the order lines, words, @@ -20461,7 +20688,7 @@ totals of lines, words, and characters.@footnote{@command{wc} can't just use the value of @code{FNR} in @code{endfile}. If you examine the code in -@ref{Filetrans Function, , Noting @value{DDF} Boundaries} +@ref{Filetrans Function} you will see that @code{FNR} has already been reset by the time @code{endfile} is called.} It then prints out those numbers @@ -20533,7 +20760,7 @@ @c ENDOFRANGE chco @c ENDOFRANGE posimawk -@node Miscellaneous Programs, , Clones, Sample Programs +@node Miscellaneous Programs @section A Grab Bag of @command{awk} Programs This @value{SECTION} is a large ``grab bag'' of miscellaneous programs. @@ -20554,7 +20781,7 @@ files. @end menu -@node Dupword Program, Alarm Program, Miscellaneous Programs, Miscellaneous Programs +@node Dupword Program @subsection Finding Duplicated Words in a Document @c last comma is part of secondary @@ -20622,7 +20849,7 @@ @c endfile @end example -@node Alarm Program, Translate Program, Dupword Program, Miscellaneous Programs +@node Alarm Program @subsection An Alarm Clock Program @cindex insomnia, cure for @cindex Robbins, Arnold @@ -20642,7 +20869,7 @@ repetitions. This program uses the @code{gettimeofday} function from -@ref{Gettimeofday Function, ,Managing the Time of Day}. +@ref{Gettimeofday Function}. All the work is done in the @code{BEGIN} rule. The first part is argument checking and setting of defaults: the delay, the count, and the message to @@ -20750,7 +20977,7 @@ @cindex @command{sleep} utility Finally, the program uses the @code{system} function -(@pxref{I/O Functions, ,Input/Output Functions}) +(@pxref{I/O Functions}) to call the @command{sleep} utility. The @command{sleep} utility simply pauses for the given number of seconds. If the exit status is not zero, the program assumes that @command{sleep} was interrupted and exits. If @@ -20780,7 +21007,7 @@ @c ENDOFRANGE tialarm @c ENDOFRANGE alaex -@node Translate Program, Labels Program, Alarm Program, Miscellaneous Programs +@node Translate Program @subsection Transliterating Characters @c STARTOFRANGE chtra @@ -20823,7 +21050,7 @@ of standard @command{awk}: dealing with individual characters is very painful, requiring repeated use of the @code{substr}, @code{index}, and @code{gsub} built-in functions -(@pxref{String Functions, ,String Manipulation Functions}).@footnote{This +(@pxref{String Functions}).@footnote{This program was written before @command{gawk} acquired the ability to split each character in a string into separate array elements.} @c Exercise: How might you use this new feature to simplify the program? @@ -20920,7 +21147,7 @@ authors) started to consider adding a built-in function. However, shortly after writing this program, we learned that the System V Release 4 @command{awk} had added the @code{toupper} and @code{tolower} functions -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). These functions handle the vast majority of the cases where character transliteration is necessary, and so we chose to simply add those functions to @command{gawk} as well and then leave well @@ -20932,7 +21159,7 @@ will never change throughout the lifetime of the program. @c ENDOFRANGE chtra -@node Labels Program, Word Sorting, Translate Program, Miscellaneous Programs +@node Labels Program @subsection Printing Mailing Labels @c STARTOFRANGE prml @@ -20955,7 +21182,7 @@ The @code{BEGIN} rule simply sets @code{RS} to the empty string, so that @command{awk} splits records at blank lines -(@pxref{Records, ,How Input Is Split into Records}). +(@pxref{Records}). It sets @code{MAXLINES} to 100, since 100 is the maximum number of lines on the page (20 * 5 = 100). @@ -21055,7 +21282,7 @@ @c ENDOFRANGE prml @c ENDOFRANGE mlprint -@node Word Sorting, History Sorting, Labels Program, Miscellaneous Programs +@node Word Sorting @subsection Generating Word-Usage Counts @c last comma is part of secondary @@ -21088,7 +21315,7 @@ This program has two rules. The first rule, because it has an empty pattern, is executed for every input line. It uses @command{awk}'s field-accessing mechanism -(@pxref{Fields, ,Examining Fields}) to pick out the individual words from +(@pxref{Fields}) to pick out the individual words from the line, and the built-in variable @code{NF} (@pxref{Built-in Variables}) to know how many fields are available. For each input word, it increments an element of the array @code{freq} to @@ -21187,14 +21414,14 @@ to use the @command{sort} program. @c ENDOFRANGE worus -@node History Sorting, Extract Program, Word Sorting, Miscellaneous Programs +@node History Sorting @subsection Removing Duplicates from Unsorted Text @c last comma is part of secondary @c STARTOFRANGE lidu @cindex lines, duplicate, removing The @command{uniq} program -(@pxref{Uniq Program, ,Printing Nonduplicated Lines of Text}), +(@pxref{Uniq Program}), removes duplicate lines from @emph{sorted} data. Suppose, however, you need to remove duplicate lines from a @value{DF} but @@ -21257,7 +21484,7 @@ seen. @c ENDOFRANGE lidu -@node Extract Program, Simple Sed, History Sorting, Miscellaneous Programs +@node Extract Program @subsection Extracting Programs from Texinfo Source Files @c STARTOFRANGE texse @@ -21267,13 +21494,13 @@ @cindex files, Texinfo, extracting programs from @ifnotinfo Both this chapter and the previous chapter -(@ref{Library Functions, ,A Library of @command{awk} Functions}) +(@ref{Library Functions}) present a large number of @command{awk} programs. @end ifnotinfo @ifinfo The nodes -@ref{Library Functions, ,A Library of @command{awk} Functions}, -and @ref{Sample Programs, ,Practical @command{awk} Programs}, +@ref{Library Functions}, +and @ref{Sample Programs}, are the top level nodes for a large number of @command{awk} programs. @end ifinfo If you want to experiment with these programs, it is tedious to have to type @@ -21323,14 +21550,14 @@ Upon seeing @samp{@w{@@c system @dots{}}}, it runs a command, by extracting the command text from the control line and passing it on to the @code{system} function -(@pxref{I/O Functions, ,Input/Output Functions}). +(@pxref{I/O Functions}). Upon seeing @samp{@@c file @var{filename}}, each subsequent line is sent to the file @var{filename}, until @samp{@@c endfile} is encountered. The rules in @file{extract.awk} match either @samp{@@c} or @samp{@@comment} by letting the @samp{omment} part be optional. Lines containing @samp{@@group} and @samp{@@end group} are simply removed. @file{extract.awk} uses the @code{join} library function -(@pxref{Join Function, ,Merging an Array into a String}). +(@pxref{Join Function}). The example programs in the online Texinfo source for @cite{@value{TITLE}} (@file{gawk.texi}) have all been bracketed inside @samp{file} and @@ -21423,7 +21650,7 @@ simple. The @samp{for} loop does the work. It reads lines using @code{getline} -(@pxref{Getline, ,Explicit Input with @code{getline}}). +(@pxref{Getline}). For an unexpected end of file, it calls the @code{@w{unexpected_eof}} function. If the line is an ``endfile'' line, then it breaks out of the loop. @@ -21436,7 +21663,7 @@ Otherwise, each leading @samp{@@} must be stripped off. To remove the @samp{@@} symbols, the line is split into separate elements of the array @code{a}, using the @code{split} function -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). The @samp{@@} symbol is used as the separator character. Each element of @code{a} that is empty indicates two successive @samp{@@} symbols in the original line. For each two empty elements (@samp{@@@@} in @@ -21493,7 +21720,7 @@ An important thing to note is the use of the @samp{>} redirection. Output done with @samp{>} only opens the file once; it stays open and subsequent output is appended to the file -(@pxref{Redirection, , Redirecting Output of @code{print} and @code{printf}}). +(@pxref{Redirection}). This makes it easy to mix program text and explanatory prose for the same sample source file (as has been done here!) without any hassle. The file is only closed when a new data @value{FN} is encountered or at the end of the @@ -21523,7 +21750,7 @@ @c ENDOFRANGE texse @c ENDOFRANGE fitex -@node Simple Sed, Igawk Program, Extract Program, Miscellaneous Programs +@node Simple Sed @subsection A Simple Stream Editor @cindex @command{sed} utility @@ -21543,7 +21770,7 @@ @samp{old} on each input line and globally replace it with the text @samp{new}, i.e., all the occurrences on a line. This is similar to @command{awk}'s @code{gsub} function -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). The following program, @file{awksed.awk}, accepts at least two command-line arguments: the pattern to look for and the text to replace it with. Any @@ -21600,7 +21827,7 @@ The program relies on @command{gawk}'s ability to have @code{RS} be a regexp, as well as on the setting of @code{RT} to the actual text that terminates the -record (@pxref{Records, ,How Input Is Split into Records}). +record (@pxref{Records}). The idea is to have @code{RS} be the pattern to look for. @command{gawk} automatically sets @code{$0} to the text between matches of the pattern. @@ -21614,14 +21841,14 @@ However, if the file did not end in text that matches @code{RS}, @code{RT} is set to the null string. In this case, we can print @code{$0} using @code{printf} -(@pxref{Printf, ,Using @code{printf} Statements for Fancier Printing}). +(@pxref{Printf}). The @code{BEGIN} rule handles the setup, checking for the right number of arguments and calling @code{usage} if there is a problem. Then it sets @code{RS} and @code{ORS} from the command-line arguments and sets @code{ARGV[1]} and @code{ARGV[2]} to the null string, so that they are not treated as @value{FN}s -(@pxref{ARGC and ARGV, , Using @code{ARGC} and @code{ARGV}}). +(@pxref{ARGC and ARGV}). The @code{usage} function prints an error message and exits. Finally, the single rule handles the printing scheme outlined above, @@ -21648,7 +21875,7 @@ Others? @end ignore -@node Igawk Program, , Simple Sed, Miscellaneous Programs +@node Igawk Program @subsection An Easy Way to Use Library Functions @c STARTOFRANGE libfex @@ -21662,7 +21889,7 @@ programs; it is painful when running them, requiring multiple @option{-f} options. If @command{gawk} is unavailable, then so too is the @env{AWKPATH} environment variable and the ability to put @command{awk} functions into a -library directory (@pxref{Options, ,Command-Line Options}). +library directory (@pxref{Options}). It would be nice to be able to write programs in the following manner: @example @@ -21877,7 +22104,7 @@ is stored in the shell variable @code{expand_prog}. Doing this keeps the shell script readable. The @command{awk} program reads through the user's program, one line at a time, using @code{getline} -(@pxref{Getline, ,Explicit Input with @code{getline}}). The input +(@pxref{Getline}). The input @value{FN}s and @samp{@@include} statements are managed using a stack. As each @samp{@@include} is encountered, the current @value{FN} is ``pushed'' onto the stack and the file named in the @samp{@@include} @@ -21889,7 +22116,7 @@ The @code{pathto} function does the work of finding the full path to a file. It simulates @command{gawk}'s behavior when searching the @env{AWKPATH} environment variable -(@pxref{AWKPATH Variable, ,The @env{AWKPATH} Environment Variable}). +(@pxref{AWKPATH Variable}). If a @value{FN} has a @samp{/} in it, no path search is done. Otherwise, the @value{FN} is concatenated with the name of each directory in the path, and an attempt is made to open the generated @value{FN}. @@ -22146,22 +22373,22 @@ @itemize @bullet @item -@ref{Language History, ,The Evolution of the @command{awk} Language}. +@ref{Language History}. @item -@ref{Installation, ,Installing @command{gawk}}. +@ref{Installation}. @item -@ref{Notes, ,Implementation Notes}. +@ref{Notes}. @item -@ref{Basic Concepts, ,Basic Programming Concepts}. +@ref{Basic Concepts}. @item @ref{Glossary}. @item -@ref{Copying, ,GNU General Public License}. +@ref{Copying}. @item @ref{GNU Free Documentation License}. @@ -22173,7 +22400,7 @@ @end iftex @end ignore -@node Language History, Installation, Sample Programs, Top +@node Language History @appendix The Evolution of the @command{awk} Language This @value{DOCUMENT} describes the GNU implementation of @command{awk}, which follows @@ -22201,7 +22428,7 @@ * Contributors:: The major contributors to @command{gawk}. @end menu -@node V7/SVR3.1, SVR4, Language History, Language History +@node V7/SVR3.1 @appendixsec Major Changes Between V7 and SVR3.1 @c STARTOFRANGE gawkv @cindex @command{awk}, versions of @@ -22216,18 +22443,18 @@ @itemize @bullet @item The requirement for @samp{;} to separate rules on a line -(@pxref{Statements/Lines, ,@command{awk} Statements Versus Lines}). +(@pxref{Statements/Lines}). @item User-defined functions and the @code{return} statement -(@pxref{User-defined, ,User-Defined Functions}). +(@pxref{User-defined}). @item -The @code{delete} statement (@pxref{Delete, ,The @code{delete} Statement}). +The @code{delete} statement (@pxref{Delete}). @item The @code{do}-@code{while} statement -(@pxref{Do Statement, ,The @code{do}-@code{while} Statement}). +(@pxref{Do Statement}). @item The built-in functions @code{atan2}, @code{cos}, @code{sin}, @code{rand}, and @@ -22235,11 +22462,11 @@ @item The built-in functions @code{gsub}, @code{sub}, and @code{match} -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). @item The built-in functions @code{close} and @code{system} -(@pxref{I/O Functions, ,Input/Output Functions}). +(@pxref{I/O Functions}). @item The @code{ARGC}, @code{ARGV}, @code{FNR}, @code{RLENGTH}, @code{RSTART}, @@ -22247,26 +22474,26 @@ @item The conditional expression using the ternary operator @samp{?:} -(@pxref{Conditional Exp, ,Conditional Expressions}). +(@pxref{Conditional Exp}). @item The exponentiation operator @samp{^} -(@pxref{Arithmetic Ops, ,Arithmetic Operators}) and its assignment operator -form @samp{^=} (@pxref{Assignment Ops, ,Assignment Expressions}). +(@pxref{Arithmetic Ops}) and its assignment operator +form @samp{^=} (@pxref{Assignment Ops}). @item C-compatible operator precedence, which breaks some old @command{awk} -programs (@pxref{Precedence, ,Operator Precedence (How Operators Nest)}). +programs (@pxref{Precedence}). @item Regexps as the value of @code{FS} -(@pxref{Field Separators, ,Specifying How Fields Are Separated}) and as the +(@pxref{Field Separators}) and as the third argument to the @code{split} function -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). @item Dynamic regexps as operands of the @samp{~} and @samp{!~} operators -(@pxref{Regexp Usage, ,How to Use Regular Expressions}). +(@pxref{Regexp Usage}). @item The escape sequences @samp{\b}, @samp{\f}, and @samp{\r} @@ -22277,19 +22504,19 @@ @item Redirection of input for the @code{getline} function -(@pxref{Getline, ,Explicit Input with @code{getline}}). +(@pxref{Getline}). @item Multiple @code{BEGIN} and @code{END} rules -(@pxref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}). +(@pxref{BEGIN/END}). @item Multidimensional arrays -(@pxref{Multi-dimensional, ,Multidimensional Arrays}). +(@pxref{Multi-dimensional}). @end itemize @c ENDOFRANGE gawkv1 -@node SVR4, POSIX, V7/SVR3.1, Language History +@node SVR4 @appendixsec Changes Between SVR3.1 and SVR4 @cindex @command{awk}, versions of, changes between SVR3.1 and SVR4 @@ -22303,12 +22530,12 @@ @item Multiple @option{-f} options on the command line -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). @c MKS awk @item The @option{-v} option for assigning variables before program execution begins -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). @c GNU, Bell Laboratories & MKS together @item @@ -22326,29 +22553,29 @@ @item The @code{toupper} and @code{tolower} built-in string functions for case translation -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). @item A cleaner specification for the @samp{%c} format-control letter in the @code{printf} function -(@pxref{Control Letters, ,Format-Control Letters}). +(@pxref{Control Letters}). @item The ability to dynamically pass the field width and precision (@code{"%*.*d"}) in the argument list of the @code{printf} function -(@pxref{Control Letters, ,Format-Control Letters}). +(@pxref{Control Letters}). @item The use of regexp constants, such as @code{/foo/}, as expressions, where they are equivalent to using the matching operator, as in @samp{$0 ~ /foo/} -(@pxref{Using Constant Regexps, ,Using Regular Expression Constants}). +(@pxref{Using Constant Regexps}). @item Processing of escape sequences inside command-line variable assignments -(@pxref{Assignment Options, ,Assigning Variables on the Command Line}). +(@pxref{Assignment Options}). @end itemize -@node POSIX, BTL, SVR4, Language History +@node POSIX @appendixsec Changes Between SVR4 and POSIX @command{awk} @cindex @command{awk}, versions of, changes between SVR4 and POSIX @command{awk} @cindex POSIX @command{awk}, changes in @command{awk} versions @@ -22359,15 +22586,15 @@ @itemize @bullet @item The use of @option{-W} for implementation-specific options -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). @item The use of @code{CONVFMT} for controlling the conversion of numbers -to strings (@pxref{Conversion, ,Conversion of Strings and Numbers}). +to strings (@pxref{Conversion}). @item The concept of a numeric string and tighter comparison rules to go -with it (@pxref{Typing and Comparison, ,Variable Typing and Comparison Expressions}). +with it (@pxref{Typing and Comparison}). @item More complete documentation of many of the previously undocumented @@ -22387,33 +22614,33 @@ @item Newlines do not act as whitespace to separate fields when @code{FS} is equal to a single space -(@pxref{Fields, ,Examining Fields}). +(@pxref{Fields}). @item Newlines are not allowed after @samp{?} or @samp{:} -(@pxref{Conditional Exp, ,Conditional Expressions}). +(@pxref{Conditional Exp}). @item The synonym @code{func} for the keyword @code{function} is not -recognized (@pxref{Definition Syntax, ,Function Definition Syntax}). +recognized (@pxref{Definition Syntax}). @item The operators @samp{**} and @samp{**=} cannot be used in -place of @samp{^} and @samp{^=} (@pxref{Arithmetic Ops, ,Arithmetic Operators}, -and @ref{Assignment Ops, ,Assignment Expressions}). +place of @samp{^} and @samp{^=} (@pxref{Arithmetic Ops}, +and @ref{Assignment Ops}). @item Specifying @samp{-Ft} on the command line does not set the value of @code{FS} to be a single TAB character -(@pxref{Field Separators, ,Specifying How Fields Are Separated}). +(@pxref{Field Separators}). @item The @code{fflush} built-in function is not supported -(@pxref{I/O Functions, ,Input/Output Functions}). +(@pxref{I/O Functions}). @end itemize @c ENDOFRANGE gawkv -@node BTL, POSIX/GNU, POSIX, Language History +@node BTL @appendixsec Extensions in the Bell Laboratories @command{awk} @cindex @command{awk}, versions of, See Also Bell Laboratories @command{awk} @@ -22422,7 +22649,7 @@ @cindex Kernighan, Brian Brian Kernighan, one of the original designers of Unix @command{awk}, has made his version available via his home page -(@pxref{Other Versions, ,Other Freely Available @command{awk} Implementations}). +(@pxref{Other Versions}). This @value{SECTION} describes extensions in his version of @command{awk} that are not in POSIX @command{awk}: @@ -22431,23 +22658,23 @@ The @samp{-mf @var{N}} and @samp{-mr @var{N}} command-line options to set the maximum number of fields and the maximum record size, respectively -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). As a side note, his @command{awk} no longer needs these options; it continues to accept them to avoid breaking old programs. @item The @code{fflush} built-in function for flushing buffered output -(@pxref{I/O Functions, ,Input/Output Functions}). +(@pxref{I/O Functions}). @item The @samp{**} and @samp{**=} operators -(@pxref{Arithmetic Ops, ,Arithmetic Operators} +(@pxref{Arithmetic Ops} and -@ref{Assignment Ops, ,Assignment Expressions}). +@ref{Assignment Ops}). @item The use of @code{func} as an abbreviation for @code{function} -(@pxref{Definition Syntax, ,Function Definition Syntax}). +(@pxref{Definition Syntax}). @ignore @item @@ -22469,23 +22696,23 @@ @item The @file{/dev/stdin}, @file{/dev/stdout}, and @file{/dev/stderr} special files -(@pxref{Special Files, ,Special @value{FFN}s in @command{gawk}}). +(@pxref{Special Files}). @item The ability for @code{FS} and for the third argument to @code{split} to be null strings -(@pxref{Single Character Fields, , Making Each Character a Separate Field}). +(@pxref{Single Character Fields}). @item The @code{nextfile} statement -(@pxref{Nextfile Statement, ,Using @command{gawk}'s @code{nextfile} Statement}). +(@pxref{Nextfile Statement}). @item The ability to delete all of an array at once with @samp{delete @var{array}} -(@pxref{Delete, ,The @code{delete} Statement}). +(@pxref{Delete}). @end itemize -@node POSIX/GNU, Contributors, BTL, Language History +@node POSIX/GNU @appendixsec Extensions in @command{gawk} Not in POSIX @command{awk} @ignore @@ -22506,12 +22733,12 @@ @c STARTOFRANGE exgnot @cindex extensions, in @command{gawk}, not in POSIX @command{awk} @c STARTOFRANGE posnot -@cindex POSIX, @command{gawk} extensions not included in +@cindex POSIX, @command{gawk} extensions not included in The GNU implementation, @command{gawk}, adds a large number of features. This @value{SECTION} lists them in the order they were added to @command{gawk}. They can all be disabled with either the @option{--traditional} or @option{--posix} options -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). Version 2.10 of @command{gawk} introduced the following features: @@ -22519,16 +22746,16 @@ @item The @env{AWKPATH} environment variable for specifying a path search for the @option{-f} command-line option -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). @item The @code{IGNORECASE} variable and its effects -(@pxref{Case-sensitivity, ,Case Sensitivity in Matching}). +(@pxref{Case-sensitivity}). @item The @file{/dev/stdin}, @file{/dev/stdout}, @file{/dev/stderr} and @file{/dev/fd/@var{N}} special @value{FN}s -(@pxref{Special Files, ,Special @value{FFN}s in @command{gawk}}). +(@pxref{Special Files}). @end itemize Version 2.13 of @command{gawk} introduced the following features: @@ -22536,25 +22763,25 @@ @itemize @bullet @item The @code{FIELDWIDTHS} variable and its effects -(@pxref{Constant Size, ,Reading Fixed-Width Data}). +(@pxref{Constant Size}). @item The @code{systime} and @code{strftime} built-in functions for obtaining and printing timestamps -(@pxref{Time Functions, ,Using @command{gawk}'s Timestamp Functions}). +(@pxref{Time Functions}). @item The @option{-W lint} option to provide error and portability checking for both the source code and at runtime -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). @item The @option{-W compat} option to turn off the GNU extensions -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). @item The @option{-W posix} option for full POSIX compliance -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). @end itemize Version 2.14 of @command{gawk} introduced the following feature: @@ -22562,7 +22789,7 @@ @itemize @bullet @item The @code{next file} statement for skipping to the next @value{DF} -(@pxref{Nextfile Statement, ,Using @command{gawk}'s @code{nextfile} Statement}). +(@pxref{Nextfile Statement}). @end itemize Version 2.15 of @command{gawk} introduced the following features: @@ -22580,20 +22807,20 @@ @item The @file{/dev/pid}, @file{/dev/ppid}, @file{/dev/pgrpid}, and @file{/dev/user} @value{FN} interpretation -(@pxref{Special Files, ,Special @value{FFN}s in @command{gawk}}). +(@pxref{Special Files}). @item The ability to delete all of an array at once with @samp{delete @var{array}} -(@pxref{Delete, ,The @code{delete} Statement}). +(@pxref{Delete}). @item The ability to use GNU-style long-named options that start with @option{--} -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). @item The @option{--source} option for mixing command-line and library-file source code -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). @end itemize Version 3.0 of @command{gawk} introduced the following features: @@ -22602,66 +22829,66 @@ @item @code{IGNORECASE} changed, now applying to string comparison as well as regexp operations -(@pxref{Case-sensitivity, ,Case Sensitivity in Matching}). +(@pxref{Case-sensitivity}). @item The @code{RT} variable that contains the input text that matched @code{RS} -(@pxref{Records, ,How Input Is Split into Records}). +(@pxref{Records}). @item Full support for both POSIX and GNU regexps -(@pxref{Regexp, , Regular Expressions}). +(@pxref{Regexp}). @item The @code{gensub} function for more powerful text manipulation -(@pxref{String Functions, ,String Manipulation Functions}). +(@pxref{String Functions}). @item The @code{strftime} function acquired a default time format, allowing it to be called with no arguments -(@pxref{Time Functions, ,Using @command{gawk}'s Timestamp Functions}). +(@pxref{Time Functions}). @item The ability for @code{FS} and for the third argument to @code{split} to be null strings -(@pxref{Single Character Fields, , Making Each Character a Separate Field}). +(@pxref{Single Character Fields}). @item The ability for @code{RS} to be a regexp -(@pxref{Records, ,How Input Is Split into Records}). +(@pxref{Records}). @item The @code{next file} statement became @code{nextfile} -(@pxref{Nextfile Statement, ,Using @command{gawk}'s @code{nextfile} Statement}). +(@pxref{Nextfile Statement}). @item The @option{--lint-old} option to warn about constructs that are not available in the original Version 7 Unix version of @command{awk} -(@pxref{V7/SVR3.1, ,Major Changes Between V7 and SVR3.1}). +(@pxref{V7/SVR3.1}). @item The @option{-m} option and the @code{fflush} function from the Bell Laboratories research version of @command{awk} -(@pxref{Options, ,Command-Line Options}; also -@pxref{I/O Functions, ,Input/Output Functions}). +(@pxref{Options}; also +@pxref{I/O Functions}). @item The @option{--re-interval} option to provide interval expressions in regexps -(@pxref{Regexp Operators, , Regular Expression Operators}). +(@pxref{Regexp Operators}). @item The @option{--traditional} option was added as a better name for -@option{--compat} (@pxref{Options, ,Command-Line Options}). +@option{--compat} (@pxref{Options}). @item The use of GNU Autoconf to control the configuration process -(@pxref{Quick Installation, , Compiling @command{gawk} for Unix}). +(@pxref{Quick Installation}). @item Amiga support -(@pxref{Amiga Installation, ,Installing @command{gawk} on an Amiga}). +(@pxref{Amiga Installation}). @end itemize @@ -22671,7 +22898,7 @@ @item The @code{BINMODE} special variable for non-POSIX systems, which allows binary I/O for input and/or output files -(@pxref{PC Using, ,Using @command{gawk} on PC Operating Systems}). +(@pxref{PC Using}). @item The @code{LINT} special variable, which dynamically controls lint warnings @@ -22686,53 +22913,53 @@ internationalization text domain (@pxref{Built-in Variables}, and -@ref{Internationalization, ,Internationalization with @command{gawk}}). +@ref{Internationalization}). @item The ability to use octal and hexadecimal constants in @command{awk} program source code -(@pxref{Nondecimal-numbers, ,Octal and Hexadecimal Numbers}). +(@pxref{Nondecimal-numbers}). @item The @samp{|&} operator for two-way I/O to a coprocess -(@pxref{Two-way I/O, ,Two-Way Communications with Another Process}). +(@pxref{Two-way I/O}). @item The @file{/inet} special files for TCP/IP networking using @samp{|&} -(@pxref{TCP/IP Networking, , Using @command{gawk} for Network Programming}). +(@pxref{TCP/IP Networking}). @item The optional second argument to @code{close} that allows closing one end of a two-way pipe to a coprocess -(@pxref{Two-way I/O, ,Two-Way Communications with Another Process}). +(@pxref{Two-way I/O}). @item The optional third argument to the @code{match} function for capturing text-matching subexpressions within a regexp -(@pxref{String Functions, , String Manipulation Functions}). +(@pxref{String Functions}). @item Positional specifiers in @code{printf} formats for making translations easier -(@pxref{Printf Ordering, , Rearranging @code{printf} Arguments}). +(@pxref{Printf Ordering}). @item The @code{asort} and @code{asorti} functions for sorting arrays -(@pxref{Array Sorting, ,Sorting Array Values and Indices with @command{gawk}}). +(@pxref{Array Sorting}). @item The @code{bindtextdomain}, @code{dcgettext} and @code{dcngettext} functions for internationalization -(@pxref{Programmer i18n, ,Internationalizing @command{awk} Programs}). +(@pxref{Programmer i18n}). @item The @code{extension} built-in function and the ability to add new built-in functions dynamically -(@pxref{Dynamic Extensions, , Adding New Built-in Functions to @command{gawk}}). +(@pxref{Dynamic Extensions}). @item The @code{mktime} built-in function for creating timestamps -(@pxref{Time Functions, ,Using @command{gawk}'s Timestamp Functions}). +(@pxref{Time Functions}). @item The @@ -22745,57 +22972,57 @@ and @code{strtonum} built-in functions -(@pxref{Bitwise Functions, ,Using @command{gawk}'s Bit Manipulation Functions}). +(@pxref{Bitwise Functions}). @item @cindex @code{next file} statement The support for @samp{next file} as two words was removed completely -(@pxref{Nextfile Statement, ,Using @command{gawk}'s @code{nextfile} Statement}). +(@pxref{Nextfile Statement}). @item The @option{--dump-variables} option to print a list of all global variables -(@pxref{Options, ,Command-Line Options}). +(@pxref{Options}). @item The @option{--gen-po} command-line option and the use of a leading underscore to mark strings that should be translated -(@pxref{String Extraction, ,Extracting Marked Strings}). +(@pxref{String Extraction}). @item The @option{--non-decimal-data} option to allow non-decimal input data -(@pxref{Nondecimal Data, ,Allowing Nondecimal Input Data}). +(@pxref{Nondecimal Data}). @item The @option{--profile} option and @command{pgawk}, the profiling version of @command{gawk}, for producing execution profiles of @command{awk} programs -(@pxref{Profiling, ,Profiling Your @command{awk} Programs}). +(@pxref{Profiling}). @item The @option{--enable-portals} configuration option to enable special treatment of pathnames that begin with @file{/p} as BSD portals -(@pxref{Portal Files, , Using @command{gawk} with BSD Portals}). +(@pxref{Portal Files}). @item The use of GNU Automake to help in standardizing the configuration process -(@pxref{Quick Installation, , Compiling @command{gawk} for Unix}). +(@pxref{Quick Installation}). @item The use of GNU @code{gettext} for @command{gawk}'s own message output -(@pxref{Gawk I18N, ,@command{gawk} Can Speak Your Language}). +(@pxref{Gawk I18N}). @item BeOS support -(@pxref{BeOS Installation, , Installing @command{gawk} on BeOS}). +(@pxref{BeOS Installation}). @item Tandem support -(@pxref{Tandem Installation, ,Installing @command{gawk} on a Tandem}). +(@pxref{Tandem Installation}). @item The Atari port became officially unsupported -(@pxref{Atari Installation, ,Installing @command{gawk} on the Atari ST}). +(@pxref{Atari Installation}). @item The source code now uses new-style function definitions, with @@ -22804,7 +23031,7 @@ @item The @option{--disable-lint} configuration option to disable lint checking at compile time -(@pxref{Additional Configuration Options, , Additional Configuration Options}). +(@pxref{Additional Configuration Options}). @end itemize @@ -22814,7 +23041,7 @@ @c ENDOFRANGE exgnot @c ENDOFRANGE posnot -@node Contributors, , POSIX/GNU, Language History +@node Contributors @appendixsec Major Contributors to @command{gawk} @cindex @command{gawk}, list of contributors to @quotation @@ -22920,7 +23147,7 @@ @item @cindex Grigera, Juan Juan Grigera -maintains the port to Win32 systems. +maintains the port to Windows32 systems. @item @cindex Hankerson, Darrel @@ -22973,6 +23200,13 @@ Isamu Hasegawa, of IBM in Japan, contributed support for multibyte characters. +@cindex Benzinger, Michael +Michael Benzinger contributed the initial code for @code{switch} statements. + +@cindex McPhee, Patrick +Patrick T.J.@: McPhee contributed the code for dynamic loading in Windows32 +environments. + @item @cindex Robbins, Arnold Arnold Robbins @@ -22980,7 +23214,7 @@ helping David Trueman, and as the primary maintainer since around 1994. @end itemize -@node Installation, Notes, Language History, Top +@node Installation @appendix Installing @command{gawk} @c last two commas are part of see also @@ -22993,7 +23227,7 @@ various platforms that are supported by the developers. The primary developer supports GNU/Linux (and Unix), whereas the other ports are contributed. -@xref{Bugs, , Reporting Problems and Bugs}, +@xref{Bugs}, for the electronic mail addresses of the people who did the respective ports. @@ -23008,7 +23242,7 @@ implementations. @end menu -@node Gawk Distribution, Unix Installation, Installation, Installation +@node Gawk Distribution @appendixsec The @command{gawk} Distribution @cindex source code, @command{gawk} @@ -23022,7 +23256,7 @@ * Distribution contents:: What is in the distribution. @end menu -@node Getting, Extracting, Gawk Distribution, Gawk Distribution +@node Getting @appendixsubsec Getting the @command{gawk} Distribution @c last comma is part of secondary @cindex @command{gawk}, source code, obtaining @@ -23065,7 +23299,7 @@ Try to use one of the mirrors; they will be less busy, and you can usually find one closer to your site. -@node Extracting, Distribution contents, Getting, Gawk Distribution +@node Extracting @appendixsubsec Extracting the Distribution @command{gawk} is distributed as a @code{tar} file compressed with the GNU Zip program, @code{gzip}. @@ -23099,7 +23333,7 @@ for getting and extracting the @command{gawk} distribution. You should consult a local expert. -@node Distribution contents, , Extracting, Gawk Distribution +@node Distribution contents @appendixsubsec Contents of the @command{gawk} Distribution @c STARTOFRANGE gawdis @cindex @command{gawk}, distribution @@ -23107,7 +23341,7 @@ The @command{gawk} distribution has a number of C source files, documentation files, subdirectories, and files related to the configuration process -(@pxref{Unix Installation, ,Compiling and Installing @command{gawk} on Unix}), +(@pxref{Unix Installation}), as well as several subdirectories related to different non-Unix operating systems: @@ -23198,7 +23432,7 @@ @item doc/igawk.1 The @command{troff} source for a manual page describing the @command{igawk} program presented in -@ref{Igawk Program, ,An Easy Way to Use Library Functions}. +@ref{Igawk Program}. @item doc/Makefile.in The input file used during the configuration process to generate the @@ -23222,7 +23456,7 @@ @itemx m4/* These files and subdirectories are used when configuring @command{gawk} for various Unix systems. They are explained in -@ref{Unix Installation, ,Compiling and Installing @command{gawk} on Unix}. +@ref{Unix Installation}. @item intl/* @itemx po/* @@ -23235,15 +23469,15 @@ @itemx awklib/Makefile.in @itemx awklib/eg/* The @file{awklib} directory contains a copy of @file{extract.awk} -(@pxref{Extract Program, ,Extracting Programs from Texinfo Source Files}), +(@pxref{Extract Program}), which can be used to extract the sample programs from the Texinfo source file for this @value{DOCUMENT}. It also contains a @file{Makefile.in} file, which @command{configure} uses to generate a @file{Makefile}. @file{Makefile.am} is used by GNU Automake to create @file{Makefile.in}. The library functions from -@ref{Library Functions, , A Library of @command{awk} Functions}, +@ref{Library Functions}, and the @command{igawk} program from -@ref{Igawk Program, , An Easy Way to Use Library Functions}, +@ref{Igawk Program}, are included as ready-to-use files in the @command{gawk} distribution. They are installed as part of the installation process. The rest of the programs in this @value{DOCUMENT} are available in appropriate @@ -23251,22 +23485,22 @@ @item unsupported/atari/* Files needed for building @command{gawk} on an Atari ST -(@pxref{Atari Installation, ,Installing @command{gawk} on the Atari ST}, for details). +(@pxref{Atari Installation}, for details). @item unsupported/tandem/* Files needed for building @command{gawk} on a Tandem -(@pxref{Tandem Installation, ,Installing @command{gawk} on a Tandem}, for details). +(@pxref{Tandem Installation}, for details). @item posix/* Files needed for building @command{gawk} on POSIX-compliant systems. @item pc/* Files needed for building @command{gawk} under MS-DOS, MS Windows and OS/2 -(@pxref{PC Installation, ,Installation on PC Operating Systems}, for details). +(@pxref{PC Installation}, for details). @item vms/* Files needed for building @command{gawk} under VMS -(@pxref{VMS Installation, ,How to Compile and Install @command{gawk} on VMS}, for details). +(@pxref{VMS Installation}, for details). @item test/* A test suite for @@ -23277,7 +23511,7 @@ @end table @c ENDOFRANGE gawdis -@node Unix Installation, Non-Unix Installation, Gawk Distribution, Installation +@node Unix Installation @appendixsec Compiling and Installing @command{gawk} on Unix Usually, you can compile and install @command{gawk} by typing only two @@ -23290,7 +23524,7 @@ * Configuration Philosophy:: How it's all supposed to work. @end menu -@node Quick Installation, Additional Configuration Options, Unix Installation, Unix Installation +@node Quick Installation @appendixsubsec Compiling @command{gawk} for Unix @c @cindex installation, unix @@ -23352,9 +23586,9 @@ check the files in the @file{README_d} directory to see if you've found a known problem. If the failure is not described there, please send in a bug report -(@pxref{Bugs, ,Reporting Problems and Bugs}.) +(@pxref{Bugs}.) -@node Additional Configuration Options, Configuration Philosophy, Quick Installation, Unix Installation +@node Additional Configuration Options @appendixsubsec Additional Configuration Options @cindex @command{gawk}, configuring, options @c comma is part of primary @@ -23370,7 +23604,14 @@ Treat pathnames that begin with @file{/p} as BSD portal files when doing two-way I/O with the @samp{|&} operator -(@pxref{Portal Files, , Using @command{gawk} with BSD Portals}). +(@pxref{Portal Files}). + +@cindex @code{--enable-switch} configuration option +@cindex configuration option, @code{--enable-switch} +@item --enable-switch +Enable the recognition and execution of C-style @code{switch} statements +in @command{awk} programs +(@pxref{Switch Statement}.) @cindex Linux @cindex GNU/Linux @@ -23388,10 +23629,10 @@ @item --disable-lint This option disables all lint checking within @code{gawk}. The @option{--lint} and @option{--lint-old} options -(@pxref{Options, , Command-Line Options}) +(@pxref{Options}) are accepted, but silently do nothing. Similarly, setting the @code{LINT} variable -(@pxref{User-modified, , Built-in Variables That Control @command{awk}}) +(@pxref{User-modified}) has no effect on the running @command{awk} program. When used with GCC's automatic dead-code-elimination, this option @@ -23413,7 +23654,7 @@ doesn't work on your system. @end table -@node Configuration Philosophy, , Additional Configuration Options, Unix Installation +@node Configuration Philosophy @appendixsubsec The Configuration Process @cindex @command{gawk}, configuring @@ -23456,12 +23697,12 @@ If you do have a problem, the file @file{configure.in} is the input for @command{autoconf}. You may be able to change this file and generate a new version of @command{configure} that works on your system -(@pxref{Bugs, ,Reporting Problems and Bugs}, +(@pxref{Bugs}, for information on how to report problems in configuring @command{gawk}). The same mechanism may be used to send in updates to @file{configure.in} and/or @file{custom.h}. -@node Non-Unix Installation, Unsupported, Unix Installation, Installation +@node Non-Unix Installation @appendixsec Installation on Other Operating Systems This @value{SECTION} describes how to install @command{gawk} on @@ -23475,7 +23716,7 @@ * VMS Installation:: Installing @command{gawk} on VMS. @end menu -@node Amiga Installation, BeOS Installation, Non-Unix Installation, Non-Unix Installation +@node Amiga Installation @appendixsubsec Installing @command{gawk} on an Amiga @cindex amiga @@ -23511,9 +23752,9 @@ Then run @command{make} and you should be all set! If these steps do not work, please send in a bug report -(@pxref{Bugs, ,Reporting Problems and Bugs}). +(@pxref{Bugs}). -@node BeOS Installation, PC Installation, Amiga Installation, Non-Unix Installation +@node BeOS Installation @appendixsubsec Installing @command{gawk} on BeOS @cindex BeOS @cindex installation, beos @@ -23547,12 +23788,12 @@ BeOS uses @command{bash} as its shell; thus, you use @command{gawk} the same way you would under Unix. If these steps do not work, please send in a bug report -(@pxref{Bugs, ,Reporting Problems and Bugs}). +(@pxref{Bugs}). @c Rewritten by Scott Deifik @c and Darrel Hankerson -@node PC Installation, VMS Installation, BeOS Installation, Non-Unix Installation +@node PC Installation @appendixsubsec Installation on PC Operating Systems @c first comma is part of primary @@ -23561,27 +23802,28 @@ @cindex operating systems, PC, @command{gawk} on, installing This @value{SECTION} covers installation and usage of @command{gawk} on x86 machines running DOS, any version of Windows, or OS/2. -In this @value{SECTION}, the term ``Win32'' +In this @value{SECTION}, the term ``Windows32'' refers to any of Windows-95/98/ME/NT/2000. The limitations of DOS (and DOS shells under Windows or OS/2) has meant that various ``DOS extenders'' are often used with programs such as @command{gawk}. The varying capabilities of Microsoft Windows 3.1 -and Win32 can add to the confusion. For an overview of the +and Windows32 can add to the confusion. For an overview of the considerations, please refer to @file{README_d/README.pc} in the distribution. @menu * PC Binary Installation:: Installing a prepared distribution. -* PC Compiling:: Compiling @command{gawk} for MS-DOS, Win32, +* PC Compiling:: Compiling @command{gawk} for MS-DOS, Windows32, and OS/2. -* PC Using:: Running @command{gawk} on MS-DOS, Win32 and +* PC Dynamic:: Compiling @command{gawk} for dynamic libraries. +* PC Using:: Running @command{gawk} on MS-DOS, Windows32 and OS/2. * Cygwin:: Building and running @command{gawk} for Cygwin. @end menu -@node PC Binary Installation, PC Compiling, PC Installation, PC Installation +@node PC Binary Installation @appendixsubsubsec Installing a Prepared Distribution for PC Systems If you have received a binary distribution prepared by the DOS @@ -23601,7 +23843,7 @@ OS/2 (32 bit, EMX) binary distributions are prepared for the @file{/usr} directory of your preferred drive. Set @env{UNIXROOT} to your installation drive (e.g., @samp{e:}) if you want to install @command{gawk} onto another drive -than the hardcoded default @samp{c:}. Executables appear in @file{/usr/bin}, +than the hardcoded default @samp{c:}. Executables appear in @file{/usr/bin}, libraries under @file{/usr/share/awk}, manual pages under @file{/usr/man}, Texinfo documentation under @file{/usr/info} and NLS files under @file{/usr/share/locale}. If you already have a file @file{/usr/info/dir} from another package @@ -23619,13 +23861,13 @@ The binary distribution may contain a separate file containing additional or more detailed installation instructions. -@node PC Compiling, PC Using, PC Binary Installation, PC Installation +@node PC Compiling @appendixsubsubsec Compiling @command{gawk} for PC Operating Systems -@command{gawk} can be compiled for MS-DOS, Win32, and OS/2 using the GNU +@command{gawk} can be compiled for MS-DOS, Windows32, and OS/2 using the GNU development tools from DJ Delorie (DJGPP; MS-DOS only) or Eberhard -Mattes (EMX; MS-DOS, Win32 and OS/2). Microsoft Visual C/C++ can be used -to build a Win32 version, and Microsoft C/C++ can be +Mattes (EMX; MS-DOS, Windows32 and OS/2). Microsoft Visual C/C++ can be used +to build a Windows32 version, and Microsoft C/C++ can be used to build 16-bit versions for MS-DOS and OS/2. @c FIXME: (As of @command{gawk} 3.1.2, the MSC version doesn't work. However, @@ -23635,7 +23877,7 @@ additional notes, and @file{pc/Makefile} contains important information on compilation options. -To build @command{gawk} for MS-DOS, Win32, and OS/2 (16 bit only; for 32 bit +To build @command{gawk} for MS-DOS, Windows32, and OS/2 (16 bit only; for 32 bit (EMX) you can use the @command{configure} script and skip the following paragraphs; for details see below), copy the files in the @file{pc} directory (@emph{except} for @file{ChangeLog}) to the directory with the rest of the @command{gawk} @@ -23643,7 +23885,7 @@ may need to be edited in order to work with your @command{make} utility. The @file{Makefile} contains a number of targets for building various MS-DOS, -Win32, and OS/2 versions. A list of targets is printed if the @command{make} +Windows32, and OS/2 versions. A list of targets is printed if the @command{make} command is given without a target. As an example, to build @command{gawk} using the DJGPP tools, enter @samp{make djgpp}. @@ -23732,8 +23974,56 @@ version on @uref{http://www.unixos2.org/sw/pub/binary/make/} or on @uref{ftp://hobbes.nmsu.edu/pub/os2/}. +@node PC Dynamic +@appendixsubsubsec Compiling @command{gawk} For Dynamic Libraries + +@c From README_d/README.pcdynamic +@c 11 June 2003 + +To compile @command{gawk} with dynamic extension support, +uncomment the definitions of @code{DYN_FLAGS}, @code{DYN_EXP}, +@code{DYN_OBJ}, and @code{DYN_MAKEXP} in the configuration section of +the @file{Makefile}. There are two definitions for @code{DYN_MAKEXP}: +pick the one that matches your target. + +To build some of the example extension libraries, @command{cd} to the +extension directory and copy @file{Makefile.pc} to @file{Makefile}. You +can then build using the same two targets. To run the example +@command{awk} scripts, you'll need to either change the call to +the @code{extension} function to match the name of the library (for +instance, change @code{"./ordchr.so"} to @code{"ordchr.dll"} or simply +@code{"ordchr"}), or rename the library to match the call (for instance, +rename @file{ordchr.dll} to @file{ordchr.so}). + +If you build @command{gawk.exe} with one compiler but want to build +an extension library with the other, you need to copy the import +library. Visual C uses a library called @file{gawk.lib}, while MinGW uses +a library called @file{libgawk.a}. These files are equivalent and will +interoperate if you give them the correct name. The resulting shared +libraries are also interoperable. + +To create your own extension library, you can use the examples as models, +but you're essentially on your own. Post to @code{comp.lang.awk} or +send electronic mail to @email{ptjm@@interlog.com} if you have problems getting +started. If you need to access functions or variables which are not +exported by @command{gawk.exe}, add them to @file{gawkw32.def} and +rebuild. You should also add @code{ATTRIBUTE_EXPORTED} to the declaration +in @file{awk.h} of any variables you add to @file{gawkw32.def}. + +Note that extension libraries have the name of the @command{awk} +executable embedded in them at link time, so they will work only +with @command{gawk.exe}. In particular, they won't work if you +rename @command{gawk.exe} to @command{awk.exe} or if you try to use +@command{pgawk.exe}. You can perform profiling by temporarily renaming +@command{pgawk.exe} to @command{gawk.exe}. You can resolve this problem +by changing the program name in the definition of @code{DYN_MAKEXP} +for your compiler. + +On Windows32, libraries are sought first in the current directory, then in +the directory containing @command{gawk.exe}, and finally through the +@env{PATH} environment variable. -@node PC Using, Cygwin, PC Compiling, PC Installation +@node PC Using @appendixsubsubsec Using @command{gawk} on PC Operating Systems @c STARTOFRANGE opgawx @cindex operating systems, PC, @command{gawk} on @@ -23742,7 +24032,7 @@ With the exception of the Cygwin environment, the @samp{|&} operator and TCP/IP networking -(@pxref{TCP/IP Networking, , Using @command{gawk} for Network Programming}) +(@pxref{TCP/IP Networking}) are not supported for MS-DOS or MS-Windows. EMX (OS/2 only) does support at least the @samp{|&} operator. @@ -23753,7 +24043,7 @@ @cindex semicolon (@code{;}), @code{AWKPATH} variable and @cindex @code{AWKPATH} environment variable The OS/2 and MS-DOS versions of @command{gawk} search for program files as -described in @ref{AWKPATH Variable, ,The @env{AWKPATH} Environment Variable}. +described in @ref{AWKPATH Variable}. However, semicolons (rather than colons) separate elements in the @env{AWKPATH} variable. If @env{AWKPATH} is not set or is empty, then the default search path for OS/2 (16 bit) and MS-DOS versions is @@ -23823,7 +24113,7 @@ changed mid-stream. The name @code{BINMODE} was chosen to match @command{mawk} -(@pxref{Other Versions, , Other Freely Available @command{awk} Implementations}). +(@pxref{Other Versions}). Both @command{mawk} and @command{gawk} handle @code{BINMODE} similarly; however, @command{mawk} adds a @samp{-W BINMODE=@var{N}} option and an environment variable that can set @code{BINMODE}, @code{RS}, and @code{ORS}. The @@ -23870,7 +24160,7 @@ With proper quoting, in the first example the setting of @code{RS} can be moved into the @code{BEGIN} rule. -@node Cygwin, , PC Using, PC Installation +@node Cygwin @appendixsubsubsec Using @command{gawk} In The Cygwin Environment @command{gawk} can be used ``out of the box'' under Windows if you are @@ -23892,11 +24182,11 @@ and then the @samp{make} proceeds as usual. @strong{Note:} The @samp{|&} operator and TCP/IP networking -(@pxref{TCP/IP Networking, , Using @command{gawk} for Network Programming}) +(@pxref{TCP/IP Networking}) are fully supported in the Cygwin environment. This is not true for any other environment for MS-DOS or MS-Windows. -@node VMS Installation, , PC Installation, Non-Unix Installation +@node VMS Installation @appendixsubsec How to Compile and Install @command{gawk} on VMS @c based on material from Pat Rankin @@ -23912,7 +24202,7 @@ * VMS POSIX:: Alternate instructions for VMS POSIX. @end menu -@node VMS Compilation, VMS Installation Details, VMS Installation, VMS Installation +@node VMS Compilation @appendixsubsubsec Compiling @command{gawk} on VMS To compile @command{gawk} under VMS, there is a @code{DCL} command procedure that @@ -23960,7 +24250,7 @@ @command{gawk} has been tested under VAX/VMS 5.5-1 using VAX C V3.2, and GNU C 1.40 and 2.3. It should work without modifications for VMS V4.6 and up. -@node VMS Installation Details, VMS Running, VMS Compilation, VMS Installation +@node VMS Installation Details @appendixsubsubsec Installing @command{gawk} on VMS To install @command{gawk}, all you need is a ``foreign'' command, which is @@ -24008,7 +24298,7 @@ the file search. If @samp{AWK_LIBRARY} is not defined, that portion of the file search fails benignly. -@node VMS Running, VMS POSIX, VMS Installation Details, VMS Installation +@node VMS Running @appendixsubsubsec Running @command{gawk} on VMS Command-line parsing and quoting conventions are significantly different @@ -24047,7 +24337,7 @@ When defining it, the value should be quoted so that it retains a single translation and not a multitranslation @code{RMS} searchlist. -@node VMS POSIX, , VMS Running, VMS Installation +@node VMS POSIX @appendixsubsubsec Building and Using @command{gawk} on VMS POSIX Ignore the instructions above, although @file{vms/gawk.hlp} should still @@ -24076,7 +24366,7 @@ the normal VMS port of @command{gawk}, no special command-line manipulation is needed in the VMS POSIX environment. -@node Unsupported, Bugs, Non-Unix Installation, Installation +@node Unsupported @appendixsec Unsupported Operating System Ports This sections describes systems for which @@ -24087,7 +24377,7 @@ * Tandem Installation:: Installing @command{gawk} on a Tandem. @end menu -@node Atari Installation, Tandem Installation, Unsupported, Unsupported +@node Atari Installation @appendixsubsec Installing @command{gawk} on the Atari ST The Atari port is no longer supported. It is @@ -24106,7 +24396,7 @@ In order to use @command{gawk}, you need to have a shell, either text or graphics, that does not map all the characters of a command line to uppercase. Maintaining case distinction in option flags is very -important (@pxref{Options, ,Command-Line Options}). +important (@pxref{Options}). These days this is the default and it may only be a problem for some very old machines. If your system does not preserve the case of option flags, you need to upgrade your tools. Support for I/O @@ -24118,7 +24408,7 @@ * Atari Using:: Running @command{gawk} on Atari. @end menu -@node Atari Compiling, Atari Using, Atari Installation, Atari Installation +@node Atari Compiling @appendixsubsubsec Compiling @command{gawk} on the Atari ST A proper compilation of @command{gawk} sources when @code{sizeof(int)} @@ -24146,7 +24436,7 @@ @samp{atarist}. This basically assumes the TOS environment with @command{gcc}. Modify these sections as appropriate if they are not right for your environment. Also see the remarks about @env{AWKPATH} and @code{envsep} in -@ref{Atari Using, ,Running @command{gawk} on the Atari ST}. +@ref{Atari Using}. As shipped, the sample @file{config.h} claims that the @code{system} function is missing from the libraries, which is not true, and an @@ -24156,7 +24446,7 @@ shell and operating system, you might want to change the file to indicate that @code{system} is available. -@node Atari Using, , Atari Compiling, Atari Installation +@node Atari Using @appendixsubsubsec Running @command{gawk} on the Atari ST An executable version of @command{gawk} should be placed, as usual, @@ -24172,7 +24462,7 @@ current directory for its temporary files. The ST version of @command{gawk} searches for its program files, as described in -@ref{AWKPATH Variable, ,The @env{AWKPATH} Environment Variable}. +@ref{AWKPATH Variable}. The default value for the @env{AWKPATH} variable is taken from @code{DEFPATH} defined in @file{Makefile}. The sample @command{gcc}/TOS @file{Makefile} for the ST in the distribution sets @code{DEFPATH} to @@ -24209,7 +24499,7 @@ strings have to be doubled in order to get literal backslashes (@pxref{Escape Sequences}). -@node Tandem Installation, , Atari Installation, Unsupported +@node Tandem Installation @appendixsubsec Installing @command{gawk} on a Tandem @cindex tandem @cindex installation, tandem @@ -24221,10 +24511,10 @@ The Tandem port was done on a Cyclone machine running D20. The port is pretty clean and all facilities seem to work except for the I/O piping facilities -(@pxref{Getline/Pipe, , Using @code{getline} from a Pipe}, -@ref{Getline/Variable/Pipe, ,Using @code{getline} into a Variable from a Pipe}, +(@pxref{Getline/Pipe}, +@ref{Getline/Variable/Pipe}, and -@ref{Redirection, ,Redirecting Output of @code{print} and @code{printf}}), +@ref{Redirection}), which is just too foreign a concept for Tandem. To build a Tandem executable from source, download all of the files so @@ -24246,14 +24536,14 @@ on @code{getline}, @code{print} etc., are supported.) The @samp{-mr @var{val}} option -(@pxref{Options, ,Command-Line Options}) +(@pxref{Options}) has been ``stolen'' to enable Tandem users to process fixed-length records with no ``end-of-line'' character. That is, @samp{-mr 74} tells @command{gawk} to read the input file as fixed 74-byte records. @c ENDOFRANGE opgawx @c ENDOFRANGE pcgawon -@node Bugs, Other Versions, Unsupported, Installation +@node Bugs @appendixsec Reporting Problems and Bugs @cindex archeologists @quotation @@ -24381,7 +24671,7 @@ @c ENDOFRANGE dbugg @c ENDOFRANGE tblgawb -@node Other Versions, , Bugs, Installation +@node Other Versions @appendixsec Other Freely Available @command{awk} Implementations @c STARTOFRANGE awkim @cindex @command{awk}, implementations @@ -24428,7 +24718,7 @@ GCC (the GNU Compiler Collection) works quite nicely. -@xref{BTL, ,Extensions in the Bell Laboratories @command{awk}}, +@xref{BTL}, for a list of extensions in this @command{awk} that are not in POSIX @command{awk}. @cindex Brennan, Michael @@ -24437,7 +24727,7 @@ @item @command{mawk} Michael Brennan has written an independent implementation of @command{awk}, called @command{mawk}. It is available under the GPL -(@pxref{Copying, ,GNU General Public License}), +(@pxref{Copying}), just as @command{gawk} is. You can get it via anonymous @command{ftp} to the host @@ -24447,7 +24737,7 @@ @command{gunzip} may be used to decompress this file. Installation is similar to @command{gawk}'s -(@pxref{Unix Installation, , Compiling and Installing @command{gawk} on Unix}). +(@pxref{Unix Installation}). @cindex extensions, @command{mawk} @command{mawk} has the following extensions that are not in POSIX @command{awk}: @@ -24455,17 +24745,17 @@ @itemize @bullet @item The @code{fflush} built-in function for flushing buffered output -(@pxref{I/O Functions, ,Input/Output Functions}). +(@pxref{I/O Functions}). @item The @samp{**} and @samp{**=} operators -(@pxref{Arithmetic Ops, ,Arithmetic Operators} +(@pxref{Arithmetic Ops} and also see -@ref{Assignment Ops, ,Assignment Expressions}). +@ref{Assignment Ops}). @item The use of @code{func} as an abbreviation for @code{function} -(@pxref{Definition Syntax, ,Function Definition Syntax}). +(@pxref{Definition Syntax}). @item The @samp{\x} escape sequence @@ -24474,25 +24764,25 @@ @item The @file{/dev/stdout}, and @file{/dev/stderr} special files -(@pxref{Special Files, ,Special @value{FFN}s in @command{gawk}}). +(@pxref{Special Files}). Use @code{"-"} instead of @code{"/dev/stdin"} with @command{mawk}. @item The ability for @code{FS} and for the third argument to @code{split} to be null strings -(@pxref{Single Character Fields, , Making Each Character a Separate Field}). +(@pxref{Single Character Fields}). @item The ability to delete all of an array at once with @samp{delete @var{array}} -(@pxref{Delete, ,The @code{delete} Statement}). +(@pxref{Delete}). @item The ability for @code{RS} to be a regexp -(@pxref{Records, ,How Input Is Split into Records}). +(@pxref{Records}). @item The @code{BINMODE} special variable for non-Unix operating systems -(@pxref{PC Using, ,Using @command{gawk} on PC Operating Systems}). +(@pxref{PC Using}). @end itemize The next version of @command{mawk} will support @code{nextfile}. @@ -24519,7 +24809,7 @@ Nelson H.F.@: Beebe at the University of Utah has modified the Bell Labs @command{awk} to provide timing and profiling information. It is different from @command{pgawk} -(@pxref{Profiling, ,Profiling Your @command{awk} Programs}), +(@pxref{Profiling}), in that it uses CPU-based profiling, not line-count profiling. You may find it at either @uref{ftp://ftp.math.utah.edu/pub/pawk/pawk-20020210.tar.gz} @@ -24531,7 +24821,7 @@ @c ENDOFRANGE ingawk @c ENDOFRANGE awkim -@node Notes, Basic Concepts, Installation, Top +@node Notes @appendix Implementation Notes @c STARTOFRANGE gawii @cindex @command{gawk}, implementation issues @@ -24551,7 +24841,7 @@ * Future Extensions:: New features that may be implemented one day. @end menu -@node Compatibility Mode, Additions, Notes, Notes +@node Compatibility Mode @appendixsec Downward Compatibility and Debugging @cindex @command{gawk}, implementation issues, downward compatibility @cindex @command{gawk}, implementation issues, debugging @@ -24559,7 +24849,7 @@ @c first comma is part of primary @cindex implementation issues, @command{gawk}, debugging -@xref{POSIX/GNU, ,Extensions in @command{gawk} Not in POSIX @command{awk}}, +@xref{POSIX/GNU}, for a summary of the GNU extensions to the @command{awk} language and program. All of these features can be turned off by invoking @command{gawk} with the @option{--traditional} option or with the @option{--posix} option. @@ -24577,13 +24867,13 @@ and not for the casual user. It probably has not even been compiled into your version of @command{gawk}, since it slows down execution. -@node Additions, Dynamic Extensions, Compatibility Mode, Notes +@node Additions @appendixsec Making Additions to @command{gawk} If you find that you want to enhance @command{gawk} in a significant fashion, you are perfectly free to do so. That is the point of having free software; the source code is available and you are free to change -it as you want (@pxref{Copying, ,GNU General Public License}). +it as you want (@pxref{Copying}). This @value{SECTION} discusses the ways you might want to change @command{gawk} as well as any considerations you should bear in mind. @@ -24595,7 +24885,7 @@ system. @end menu -@node Adding Code, New Ports, Additions, Additions +@node Adding Code @appendixsubsec Adding New Features @c STARTOFRANGE adfgaw @@ -24613,7 +24903,7 @@ @item Before building the new feature into @command{gawk} itself, consider writing it as an extension module -(@pxref{Dynamic Extensions, ,Adding New Built-in Functions to @command{gawk}}). +(@pxref{Dynamic Extensions}). If that's not possible, continue with the rest of the steps in this list. @item @@ -24621,7 +24911,7 @@ It is much easier for me to integrate changes if they are relative to the most recent distributed version of @command{gawk}. If your version of @command{gawk} is very old, I may not be able to integrate them at all. -(@xref{Getting, ,Getting the @command{gawk} Distribution}, +(@xref{Getting}, for information on getting the latest version of @command{gawk}.) @item @@ -24723,7 +25013,7 @@ effect, or assign the copyright in your changes to the FSF. Both of these actions are easy to do and @emph{many} people have done so already. If you have questions, please contact me -(@pxref{Bugs, , Reporting Problems and Bugs}), +(@pxref{Bugs}), or @email{gnu@@gnu.org}. @cindex Texinfo @@ -24748,7 +25038,7 @@ I recommend using the GNU version of @command{diff}. Send the output produced by either run of @command{diff} to me when you submit your changes. -(@xref{Bugs, , Reporting Problems and Bugs}, for the electronic mail +(@xref{Bugs}, for the electronic mail information.) Using this format makes it easy for me to apply your changes to the @@ -24770,7 +25060,7 @@ @c ENDOFRANGE gawadf @c ENDOFRANGE fadgaw -@node New Ports, , Adding Code, Additions +@node New Ports @appendixsubsec Porting @command{gawk} to a New Operating System @cindex portability, @command{gawk} @cindex operating systems, porting @command{gawk} to @@ -24783,7 +25073,7 @@ @item Follow the guidelines in @ifinfo -@ref{Adding Code, ,Adding New Features}, +@ref{Adding Code}, @end ifinfo @ifnotinfo the previous @value{SECTION} @@ -24801,7 +25091,7 @@ code, I probably will not accept them. In such a case, you can, of course, distribute your changes on your own, as long as you comply with the GPL -(@pxref{Copying, ,GNU General Public License}). +(@pxref{Copying}). @item A number of the files that come with @command{gawk} are maintained by other @@ -24871,7 +25161,7 @@ In the code that you supply and maintain, feel free to use a coding style and brace layout that suits your taste. -@node Dynamic Extensions, Future Extensions, Additions, Notes +@node Dynamic Extensions @appendixsec Adding New Built-in Functions to @command{gawk} @cindex Robinson, Will @cindex robot, the @@ -24907,7 +25197,7 @@ * Sample Library:: A example of new functions. @end menu -@node Internals, Sample Library, Dynamic Extensions, Dynamic Extensions +@node Internals @appendixsubsec A Minimal Introduction to @command{gawk} Internals @c STARTOFRANGE gawint @cindex @command{gawk}, internals @@ -25085,7 +25375,9 @@ An argument that is supposed to be an array needs to be handled with some extra code, in case the array being passed in is actually from a function parameter. -The following boilerplate code shows how to do this: + +In versions of @command{gawk} up to and including 3.1.2, the +following boilerplate code shows how to do this: @smallexample NODE *the_arg; @@ -25109,11 +25401,27 @@ assoc_clear(the_arg); @end smallexample +For versions 3.1.3 and later, the internals changed. In particular, +the interface was actually @emph{simplified} drastically. The +following boilerplate code now suffices: + +@smallexample +NODE *the_arg; + +the_arg = get_argument(tree, 2); /* assume need 3rd arg, 0-based */ + +/* force it to be an array: */ +the_arg = get_array(the_arg); + +/* if necessary, clear it: */ +assoc_clear(the_arg); +@end smallexample + Again, you should spend time studying the @command{gawk} internals; don't just blindly copy this code. @c ENDOFRANGE gawint -@node Sample Library, , Internals, Dynamic Extensions +@node Sample Library @appendixsubsec Directory and File Operation Built-ins @c comma is part of primary @c STARTOFRANGE chdirg @@ -25140,7 +25448,7 @@ * Using Internal File Ops:: How to use an external extension. @end menu -@node Internal File Description, Internal File Ops, Sample Library, Sample Library +@node Internal File Description @appendixsubsubsec Using @code{chdir} and @code{stat} This @value{SECTION} shows how to use the new functions at the @command{awk} @@ -25220,7 +25528,7 @@ The file's last access, modification, and inode update times, respectively. These are numeric timestamps, suitable for formatting with @code{strftime} -(@pxref{Built-in, ,Built-in Functions}). +(@pxref{Built-in}). @item "pmode" The file's ``printable mode.'' This is a string representation of @@ -25263,7 +25571,7 @@ Several additional elements may be present depending upon the operating system and the type of the file. You can test for them in your @command{awk} program by using the @code{in} operator -(@pxref{Reference to Elements, ,Referring to an Array Element}): +(@pxref{Reference to Elements}): @table @code @item "blksize" @@ -25282,7 +25590,7 @@ of that number, respectively. @end table -@node Internal File Ops, Using Internal File Ops, Internal File Description, Sample Library +@node Internal File Ops @appendixsubsubsec C Code for @code{chdir} and @code{stat} Here is the C code for these extensions. They were written for @@ -25481,7 +25789,7 @@ And that's it! As an exercise, consider adding functions to implement system calls such as @code{chown}, @code{chmod}, and @code{umask}. -@node Using Internal File Ops, , Internal File Ops, Sample Library +@node Using Internal File Ops @appendixsubsubsec Integrating the Extensions @c last comma is part of secondary @@ -25529,7 +25837,7 @@ Here are the results of running the program: @example -$ gawk -f testff.awk +$ gawk -f testff.awk @print{} Info for testff.awk @print{} ret = 0 @print{} data["blksize"] = 4096 @@ -25557,7 +25865,7 @@ @c ENDOFRANGE adfugaw @c ENDOFRANGE fubadgaw -@node Future Extensions, , Dynamic Extensions, Notes +@node Future Extensions @appendixsec Probable Future Extensions @ignore From emory!scalpel.netlabs.com!lwall Tue Oct 31 12:43:17 1995 @@ -25654,7 +25962,7 @@ @table @asis @item Loadable module mechanics The current extension mechanism works -(@pxref{Dynamic Extensions, ,Adding New Built-in Functions to @command{gawk}}), +(@pxref{Dynamic Extensions}), but is rather primitive. It requires a fair amount of manual work to create and integrate a loadable module. Nor is the current mechanism as portable as might be desired. @@ -25707,12 +26015,12 @@ Finally, the programs in the test suite could use documenting in this @value{DOCUMENT}. -@xref{Additions, ,Making Additions to @command{gawk}}, +@xref{Additions}, if you are interested in tackling any of these projects. @c ENDOFRANGE impis @c ENDOFRANGE gawii -@node Basic Concepts, Glossary, Notes, Top +@node Basic Concepts @appendix Basic Programming Concepts @cindex programming, concepts @c STARTOFRANGE procon @@ -25732,7 +26040,7 @@ * Floating Point Issues:: Stuff to know about floating-point numbers. @end menu -@node Basic High Level, Basic Data Typing, Basic Concepts, Basic Concepts +@node Basic High Level @appendixsec What a Program Does @cindex processing data @@ -25929,7 +26237,7 @@ data, such as checking arguments, initializing any data you need to work with, and so on. This step corresponds to @command{awk}'s @code{BEGIN} rule -(@pxref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}). +(@pxref{BEGIN/END}). If you were baking a cake, this might consist of laying out all the mixing bowls and the baking pan, and making sure you have all the @@ -25942,7 +26250,7 @@ In most programming languages, you have to manually manage the reading of data, checking to see if there is more each time you read a chunk. @command{awk}'s pattern-action paradigm -(@pxref{Getting Started, ,Getting Started with @command{awk}}) +(@pxref{Getting Started}) handles the mechanics of this for you. In baking a cake, the processing corresponds to the actual labor: @@ -25953,7 +26261,7 @@ Once you've processed all the data, you may have things you need to do before exiting. This step corresponds to @command{awk}'s @code{END} rule -(@pxref{BEGIN/END, ,The @code{BEGIN} and @code{END} Special Patterns}). +(@pxref{BEGIN/END}). After the cake comes out of the oven, you still have to wrap it in plastic wrap to keep anyone from tasting it, as well as wash @@ -25992,7 +26300,7 @@ @command{awk} programs usually makes them both easier to write and easier to read. -@node Basic Data Typing, Floating Point Issues, Basic High Level, Basic Concepts +@node Basic Data Typing @appendixsec Data Values in a Computer @cindex variables @@ -26015,7 +26323,7 @@ Strings are sometimes referred to as @dfn{character data}, since they store the individual characters that comprise them. Individual variables, as well as numeric and string variables, are -referred to as @dfn{scalar} values. +referred to as @dfn{scalar} values. Groups of values, such as arrays, are not scalars. @cindex integers @@ -26049,7 +26357,7 @@ can hold more digits than @dfn{single-precision} floating-point numbers. Floating-point issues are discussed more fully in -@ref{Floating Point Issues, ,Floating-Point Number Caveats}. +@ref{Floating Point Issues}. At the very lowest level, computers store values as groups of binary digits, or @dfn{bits}. Modern computers group bits into groups of eight, called @dfn{bytes}. @@ -26076,7 +26384,7 @@ Thus, binary 1010 represents 1 times 8, plus 0 times 4, plus 1 times 2, plus 0 times 1, or decimal 10. Octal and hexadecimal are discussed more in -@ref{Nondecimal-numbers, ,Octal and Hexadecimal Numbers}. +@ref{Nondecimal-numbers}. Programs are written in programming languages. Hundreds, if not thousands, of programming languages exist. @@ -26100,7 +26408,7 @@ Future versions of @command{gawk} will be as compatible as possible with this standard. -@node Floating Point Issues, , Basic Data Typing, Basic Concepts +@node Floating Point Issues @appendixsec Floating-Point Number Caveats As mentioned earlier, floating-point numbers represent what are called @@ -26121,7 +26429,7 @@ (double-precision floating-point) and the string value for a variable. Separately, @command{awk} keeps track of what type the variable has -(@pxref{Typing and Comparison, ,Variable Typing and Comparison Expressions}), +(@pxref{Typing and Comparison}), which plays a role in how variables are used in comparisons. It is important to note that the string value for a number may not @@ -26212,7 +26520,7 @@ as well as to ``regular'' zero: @smallexample -$ gawk 'BEGIN @{ mz = -0 ; pz = 0 +$ gawk 'BEGIN @{ mz = -0 ; pz = 0 > printf "-0 = %g, +0 = %g, (-0 == +0) -> %d\n", mz, pz, mz == pz > printf "mz == 0 -> %d, pz == 0 -> %d\n", mz == 0, pz == 0 > @}' @@ -26225,7 +26533,7 @@ is noted and can affect comparisons. @c ENDOFRANGE procon -@node Glossary, Copying, Basic Concepts, Top +@node Glossary @unnumbered Glossary @table @asis @@ -26233,7 +26541,7 @@ A series of @command{awk} statements attached to a rule. If the rule's pattern matches an input record, @command{awk} executes the rule's action. Actions are always enclosed in curly braces. -(@xref{Action Overview, ,Actions}.) +(@xref{Action Overview}.) @cindex Spencer, Henry @cindex @command{sed} utility @@ -26280,7 +26588,7 @@ An @command{awk} expression that changes the value of some @command{awk} variable or data object. An object that you can assign to is called an @dfn{lvalue}. The assigned values are called @dfn{rvalues}. -@xref{Assignment Ops, ,Assignment Expressions}. +@xref{Assignment Ops}. @item Associative Array Arrays in which the indices may be numbers or strings, not just @@ -26321,7 +26629,7 @@ @command{awk} lets you work with floating-point numbers and strings. @command{gawk} lets you manipulate bit values with the built-in functions described in -@ref{Bitwise Functions, ,Using @command{gawk}'s Bit Manipulation Functions}. +@ref{Bitwise Functions}. Computers are often defined by how many bits they use to represent integer values. Typical systems are 32-bit systems, but 64-bit systems are @@ -26344,7 +26652,7 @@ substring of a string). @command{gawk} provides functions for timestamp management, bit manipulation, and runtime string translation. -(@xref{Built-in, ,Built-in Functions}.) +(@xref{Built-in}.) @item Built-in Variable @code{ARGC}, @@ -26431,13 +26739,13 @@ @item Compound Statement A series of @command{awk} statements, enclosed in curly braces. Compound statements may be nested. -(@xref{Statements, ,Control Statements in Actions}.) +(@xref{Statements}.) @item Concatenation Concatenating two strings means sticking them together, one after another, producing a new string. For example, the string @samp{foo} concatenated with the string @samp{bar} gives the string @samp{foobar}. -(@xref{Concatenation, ,String Concatenation}.) +(@xref{Concatenation}.) @item Conditional Expression An expression using the @samp{?:} ternary operator, such as @@ -26445,14 +26753,14 @@ @var{expr1} is evaluated; if the result is true, the value of the whole expression is the value of @var{expr2}; otherwise the value is @var{expr3}. In either case, only one of @var{expr2} and @var{expr3} -is evaluated. (@xref{Conditional Exp, ,Conditional Expressions}.) +is evaluated. (@xref{Conditional Exp}.) @item Comparison Expression A relation that is either true or false, such as @samp{(a < b)}. Comparison expressions are used in @code{if}, @code{while}, @code{do}, and @code{for} statements, and in patterns to select which input records to process. -(@xref{Typing and Comparison, ,Variable Typing and Comparison Expressions}.) +(@xref{Typing and Comparison}.) @item Curly Braces The characters @samp{@{} and @samp{@}}. Curly braces are used in @@ -26479,7 +26787,7 @@ @item Data Objects These are numbers and strings of characters. Numbers are converted into strings and vice versa, as needed. -(@xref{Conversion, ,Conversion of Strings and Numbers}.) +(@xref{Conversion}.) @item Deadlock The situation in which two communicating processes are each waiting @@ -26495,7 +26803,7 @@ A dynamic regular expression is a regular expression written as an ordinary expression. It could be a string constant, such as @code{"foo"}, but it may also be an expression whose value can vary. -(@xref{Computed Regexps, , Using Dynamic Regexps}.) +(@xref{Computed Regexps}.) @item Environment A collection of strings, of the form @var{name@code{=}val}, that each @@ -26530,9 +26838,9 @@ change by setting the built-in variable @code{FS}). Such pieces are called fields. If the pieces are of fixed length, you can use the built-in variable @code{FIELDWIDTHS} to describe their lengths. -(@xref{Field Separators, ,Specifying How Fields Are Separated}, +(@xref{Field Separators}, and -@ref{Constant Size, ,Reading Fixed-Width Data}.) +@ref{Constant Size}.) @item Flag A variable whose truth value indicates the existence or nonexistence @@ -26548,7 +26856,7 @@ @code{strftime} and @code{sprintf} functions, and are used in the @code{printf} statement as well. Also, data conversions from numbers to strings are controlled by the format string contained in the built-in variable -@code{CONVFMT}. (@xref{Control Letters, ,Format-Control Letters}.) +@code{CONVFMT}. (@xref{Control Letters}.) @item Free Documentation License This document describes the terms under which this @value{DOCUMENT} @@ -26580,7 +26888,7 @@ @cindex GNU General Public License @item General Public License This document describes the terms under which @command{gawk} and its source -code may be distributed. (@xref{Copying, ,GNU General Public License}.) +code may be distributed. (@xref{Copying}.) @item GMT ``Greenwich Mean Time.'' @@ -26623,7 +26931,7 @@ @item Input Record A single chunk of data that is read in by @command{awk}. Usually, an @command{awk} input record consists of one line of text. -(@xref{Records, ,How Input Is Split into Records}.) +(@xref{Records}.) @item Integer A whole number, i.e., a number that does not have a fractional part. @@ -26743,7 +27051,7 @@ A pattern is an arbitrary conditional expression against which input is tested. If the condition is satisfied, the pattern is said to @dfn{match} the input record. A typical pattern might compare the input record against -a regular expression. (@xref{Pattern Overview, ,Pattern Elements}.) +a regular expression. (@xref{Pattern Overview}.) @item POSIX The name for a series of standards @@ -26763,12 +27071,12 @@ Variables and/or functions that are meant for use exclusively by library functions and not for the main @command{awk} program. Special care must be taken when naming such variables and functions. -(@xref{Library Names, , Naming Library Function Global Variables}.) +(@xref{Library Names}.) @item Range (of input lines) A sequence of consecutive lines from the input file(s). A pattern can specify ranges of input lines for @command{awk} to process or it can -specify single lines. (@xref{Pattern Overview, ,Pattern Elements}.) +specify single lines. (@xref{Pattern Overview}.) @item Recursion When a function calls itself, either directly or indirectly. @@ -26782,8 +27090,8 @@ to a file or a system command, using the @samp{>}, @samp{>>}, @samp{|}, and @samp{|&} operators. You can redirect input to the @code{getline} statement using the @samp{<}, @samp{|}, and @samp{|&} operators. -(@xref{Redirection, ,Redirecting Output of @code{print} and @code{printf}}, -and @ref{Getline, ,Explicit Input with @code{getline}}.) +(@xref{Redirection}, +and @ref{Getline}.) @item Regexp Short for @dfn{regular expression}. A regexp is a pattern that denotes a @@ -26791,7 +27099,7 @@ @samp{R.*xp} matches any string starting with the letter @samp{R} and ending with the letters @samp{xp}. In @command{awk}, regexps are used in patterns and in conditional expressions. Regexps may contain -escape sequences. (@xref{Regexp, ,Regular Expressions}.) +escape sequences. (@xref{Regexp}.) @item Regular Expression See ``regexp.'' @@ -26800,7 +27108,7 @@ A regular expression constant is a regular expression written within slashes, such as @code{/foo/}. This regular expression is chosen when you write the @command{awk} program and cannot be changed during -its execution. (@xref{Regexp Usage, ,How to Use Regular Expressions}.) +its execution. (@xref{Regexp Usage}.) @item Rule A segment of an @command{awk} program that specifies how to process single @@ -26838,13 +27146,13 @@ If the value of the entire expression is determinable from evaluating just the lefthand side of these operators, the righthand side is not evaluated. -(@xref{Boolean Ops, ,Boolean Expressions}.) +(@xref{Boolean Ops}.) @item Side Effect A side effect occurs when an expression has an effect aside from merely producing a value. Assignment expressions, increment and decrement expressions, and function calls have side effects. -(@xref{Assignment Ops, ,Assignment Expressions}.) +(@xref{Assignment Ops}.) @item Single-Precision An internal representation of numbers that can have fractional parts. @@ -26859,7 +27167,7 @@ @item Special File A @value{FN} interpreted internally by @command{gawk}, instead of being handed directly to the underlying operating system---for example, @file{/dev/stderr}. -(@xref{Special Files, ,Special @value{FFN}s in @command{gawk}}.) +(@xref{Special Files}.) @item Stream Editor A program that reads records from an input stream and processes them one @@ -26915,7 +27223,7 @@ record or a string. @end table -@node Copying, GNU Free Documentation License, Glossary, Top +@node Copying @unnumbered GNU General Public License @center Version 2, June 1991 @@ -27770,7 +28078,7 @@ @c End: -@node Index, , GNU Free Documentation License, Top +@node Index @unnumbered Index @printindex cp diff -urN gawk-3.1.2/doc/gawkinet.texi gawk-3.1.3/doc/gawkinet.texi --- gawk-3.1.2/doc/gawkinet.texi 2003-03-19 03:54:56.000000000 -0800 +++ gawk-3.1.3/doc/gawkinet.texi 2003-05-08 09:26:07.000000000 -0700 @@ -1,11 +1,11 @@ -\input texinfo @c -*-texinfo-*- +\input texinfo @c -*-texinfo-*- @c %**start of header (This is for running Texinfo on a region.) @setfilename gawkinet.info @settitle TCP/IP Internetworking With @command{gawk} @c %**end of header (This is for running Texinfo on a region.) @c FIXME: web vs. Web -@dircategory Text creation and manipulation +@dircategory Network applications @direntry * Gawkinet: (gawkinet). TCP/IP Internetworking With `gawk'. @end direntry @@ -1151,10 +1151,10 @@ yy/mm/dd hh:mm:ss deg. deg. km 98/12/14 21:09:22 37.47N 116.30W 0.0 2.3Md 76.4 km S of WARM SPRINGS, NEVA -98/12/14 22:05:09 39.69N 120.41W 11.9 2.1Md 53.8 km WNW of RENO, NEVADA -98/12/15 14:14:19 38.04N 118.60W 2.0 2.3Md 51.0 km S of HAWTHORNE, NEVADA +98/12/14 22:05:09 39.69N 120.41W 11.9 2.1Md 53.8 km WNW of RENO, NEVADA +98/12/15 14:14:19 38.04N 118.60W 2.0 2.3Md 51.0 km S of HAWTHORNE, NEVADA 98/12/17 01:49:02 36.06N 117.58W 13.9 3.0Md 74.9 km SE of LONE PINE, CALIFOR -98/12/17 05:39:26 39.95N 120.87W 6.2 2.6Md 101.6 km WNW of RENO, NEVADA +98/12/17 05:39:26 39.95N 120.87W 6.2 2.6Md 101.6 km WNW of RENO, NEVADA 98/12/22 06:07:42 38.68N 119.82W 5.2 2.3Md 50.7 km S of CARSON CITY, NEVAD @end smallexample @@ -1235,7 +1235,7 @@ @end example Now open another window on the same machine. -Copy the client program given as the first example +Copy the client program given as the first example (@pxref{TCP Connecting, ,Establishing a TCP Connection}) to a new file and edit it, changing the name @samp{daytime} to @samp{8888}. Then start the modified client. You should get a reply @@ -1626,7 +1626,7 @@ # stop talking to this client close(HttpService) # wait for new client request - HttpService |& getline + HttpService |& getline # do some logging print systime(), strftime(), $0 # read request parameters @@ -1706,8 +1706,8 @@ @group if (i > 0) @{ split(substr($2, 1, i-1), MENU, "[/:]") - split(substr($2, i+1), PARAM, "&") - for (i in PARAM) @{ + split(substr($2, i+1), PARAM, "&") + for (i in PARAM) @{ j = index(PARAM[i], "=") GETARG[substr(PARAM[i], 1, j-1)] = \ substr(PARAM[i], j+1) @@ -1874,7 +1874,7 @@ print "Content-length:", len |& HttpService print ORS Prompt |& HttpService # ignore all the header lines - while ((HttpService |& getline) > 0) + while ((HttpService |& getline) > 0) continue # stop talking to this client close(HttpService) @@ -1903,7 +1903,7 @@ PARAM[i] = _CGI_decode(PARAM[i]) j = index(PARAM[i], "=") GETARG[substr(PARAM[i], 1, j-1)] = \ - substr(PARAM[i], j+1) + substr(PARAM[i], j+1) @} @} else @{ # there is no "?", no need for splitting PARAMs split(uri, MENU, "[/:]") @@ -1983,13 +1983,13 @@ @c artificial line wrap in last output line @example -$ gawk -f testserv.awk +$ gawk -f testserv.awk @print{} MENU["4"] = www.gnu.org @print{} MENU["5"] = cgi-bin @print{} MENU["6"] = foo @print{} MENU["1"] = http -@print{} MENU["2"] = -@print{} MENU["3"] = +@print{} MENU["2"] = +@print{} MENU["3"] = @print{} PARAM["1"] = p1=stuff @print{} PARAM["2"] = p2=stuff&junk @print{} PARAM["3"] = percent=a % sign @@ -2139,7 +2139,7 @@ if (w == "-") @{ # no keyword, take old subject w = wold subj = subjold - @} else @{ # find subject + @} else @{ # find subject subj = substr(q, index(q, w) + length(w)+1) wold = w subjold = subj # remember keyword and subject @@ -2317,7 +2317,7 @@ @example @c file eg/network/eliza.awk # table for looking up answers that - # fit to a certain keyword + # fit to a certain keyword k["CAN YOU"] = "1 2 3" k["CAN I"] = "4 5" k["YOU ARE"] =\ @@ -2425,7 +2425,7 @@ Dr.@: Loebner pledged a Grand Prize of $100,000 for the first computer whose responses were indistinguishable from a human's. Each year an annual prize of $2000 and a bronze medal is awarded to the @emph{most} human computer. -The winner of the annual contest is the best entry relative to other entries +The winner of the annual contest is the best entry relative to other entries that year, irrespective of how good it is in an absolute sense. Here is an example of a conversation with the winning program of 1997: @@ -2524,7 +2524,7 @@ @dots{}@* Second, inference is merely the expansion of notation. No matter whether the logic that underlies an AI program is fuzzy, probabilistic, deontic, -defeasible, or deductive, the logic merely defines how strings can be +defeasible, or deductive, the logic merely defines how strings can be transformed into other strings. A language that provides the best support for string processing in the end provides the best support for logic, for the exploration of various logics, and for most forms of @@ -2742,7 +2742,7 @@ Network connections via @command{telnet} or SNMP @item -HTTP connections with HTML GUIs +HTTP connections with HTML GUIs @end itemize In this @value{SECTION}, we look at a solution that uses HTTP connections @@ -2819,7 +2819,7 @@ config[GETARG["Param"]] = GETARG["Value"] Document = (GETARG["Param"] " = " GETARG["Value"] ".") @} else @{ - Document = "Parameter " GETARG["Param"] " is invalid." + Document = "Parameter " GETARG["Param"] " is invalid." @} @} else @{ Document = "

Change one parameter

\ @@ -3201,9 +3201,9 @@ \ 2. Count \ - \ + \

" - @} else if (MENU[2] ~ "Image") @{ + @} else if (MENU[2] ~ "Image") @{ Reason = "OK" ORS "Content-type: image/png" #Reason = "OK" ORS "Content-type: application/x-postscript" #Reason = "OK" ORS "Content-type: image/gif" @@ -4099,7 +4099,7 @@ most recent day gets day number 1 and all other days get consecutive numbers. All quotes are rounded toward the nearest whole number in US Dollars. -@smallexample +@smallexample @c file eg/network/stoxpred.awk function CleanUp() @{ # clean up time series; eliminate incomplete data sets @@ -4139,15 +4139,15 @@ for (stock = 1; stock <= StockCount; stock++) @{ if (data[1, stock] > data[2, stock]) @{ predict[stock] = "up" - @} else if (data[1, stock] < data[2, stock]) @{ - predict[stock] = "down" + @} else if (data[1, stock] < data[2, stock]) @{ + predict[stock] = "down" @} else @{ predict[stock] = "neutral" @} if ((data[1, stock] > data[2, stock]) && (data[2, stock] > data[3, stock])) hot[stock] = 1 if ((data[1, stock] < data[2, stock]) && (data[2, stock] < data[3, stock])) - avoid[stock] = 1 + avoid[stock] = 1 @} # Do a plausibility check: how many predictions proved correct? for (s = 1; s <= StockCount; s++) @{ @@ -4158,13 +4158,13 @@ DownCount++ @} else @{ NeutralCount++ - @} + @} if (((data[d, s] > data[d+1, s]) && (data[d+1, s] > data[d+2, s])) || ((data[d, s] < data[d+1, s]) && (data[d+1, s] < data[d+2, s])) || ((data[d, s] == data[d+1, s]) && (data[d+1, s] == data[d+2, s]))) CorrectCount++ - @} - @} + @} + @} @} @c endfile @end smallexample @@ -4181,7 +4181,7 @@ report = "\nThis is your daily " report = report "stock market report for "strftime("%A, %B %d, %Y")".\n" report = report "Here are the predictions for today:\n\n" - for (stock = 1; stock <= StockCount; stock++) + for (stock = 1; stock <= StockCount; stock++) report = report "\t" name[stock] "\t" predict[stock] "\n" for (stock in hot) @{ if (HotCount++ == 0) @@ -4194,7 +4194,7 @@ report = report "\nThe stock shares to avoid today are these:\n\n" report = report "\t" name[stock] "\t\thttp://biz.yahoo.com/n/" \ tolower(substr(name[stock], 1, 1)) "/" tolower(name[stock]) ".html\n" - @} + @} report = report "\nThis sums up to " HotCount+0 " winners and " AvoidCount+0 report = report " losers. When using this kind\nof prediction scheme for" report = report " the 12 months which lie behind us,\nwe get " UpCount @@ -4208,7 +4208,7 @@ report = report "market, this report is, of course, complete nonsense.\n" report = report "If you are stupid enough to believe these predictions\n" report = report "you should visit a doctor who can treat your ailment." -@} +@} @c endfile @end smallexample @@ -4218,7 +4218,7 @@ @smallexample @c file eg/network/stoxpred.awk -function SendMail() @{ +function SendMail() @{ # send report to customers customer["uncle.scrooge@@ducktown.gov"] = "Uncle Scrooge" customer["more@@utopia.org" ] = "Sir Thomas More" @@ -4233,7 +4233,7 @@ print report "\n.\n" | MailPipe close(MailPipe) @} -@} +@} @c endfile @end smallexample @@ -4261,7 +4261,7 @@ What people are willing to pay reflects human expectations. Human expectations are not necessarily random. On the Internet, you can find an elucidating paper about predictability and human -expectations: +expectations: @uref{http://it.ucsd.edu/IT/Newsletter/archives/meir/05meir.html, @cite{Reflections on ``Universal Prediction of Individual Sequences''}} The authors (Feder, Merhav, Gutman) introduce the reader to the subject @@ -4287,7 +4287,7 @@ opponents was explained by the fact that the human opponents cannot draw completely random bits. -@end quotation +@end quotation @end ignore @node PROTBASE, , STOXPRED, Some Applications and Techniques @@ -4373,12 +4373,12 @@ IUB/IUPAC amino acid and nucleic acid codes, with these exceptions: lower-case letters are accepted and are mapped into upper-case; a single hyphen or dash can be used to represent a gap -of indeterminate length; and in amino acid sequences, @samp{U} and @samp{*} +of indeterminate length; and in amino acid sequences, @samp{U} and @samp{*} are acceptable letters (see below). Before submitting a request, any numerical -digits in the query sequence should either be removed or replaced by +digits in the query sequence should either be removed or replaced by appropriate letter codes (e.g., @samp{N} for unknown nucleic acid residue or @samp{X} for unknown amino acid residue). -The nucleic acid codes supported are: +The nucleic acid codes supported are: @example A --> adenosine M --> A C (amino) @@ -4389,7 +4389,7 @@ R --> G A (purine) H --> A C T Y --> T C (pyrimidine) V --> G C A K --> G T (keto) N --> A G C T (any) - - gap of indeterminate length + - gap of indeterminate length @end example Now you know the alphabet of nucleotide sequences. The last two lines @@ -4397,7 +4397,7 @@ made up only of elements of the alphabet just described. Store this example query into a file named @file{protbase.request}. You are now ready to send it to the server with the demonstration client. - + @example @c file eg/network/protbase.request PROGRAM blastn @@ -4407,7 +4407,7 @@ >GAWK310 the gawking gene GNU AWK tgcttggctgaggagccataggacgagagcttcctggtgaagtgtgtttcttgaaatcat caccaccatggacagcaaa -@c endfile +@c endfile @end example @cindex FASTA/Pearson format @@ -4421,7 +4421,7 @@ FASTA/Pearson format. Each line of information must be less than 80 characters in length. -The ``month'' database contains all new or revised sequences released in the +The ``month'' database contains all new or revised sequences released in the last 30 days and is useful for searching against new sequences. There are five different blast programs, @command{blastn} being the one that compares a nucleotide query sequence against a nucleotide sequence database. @@ -4453,7 +4453,7 @@ BLASTService = "/inet/tcp/0/www.ncbi.nlm.nih.gov/80" printf "POST /cgi-bin/BLAST/nph-blast_report HTTP/1.0\n" |& BLASTService printf "Content-Length: " length(request) "\n\n" |& BLASTService - printf request |& BLASTService + printf request |& BLASTService while ((BLASTService |& getline) > 0) print $0 close(BLASTService) @@ -4500,7 +4500,7 @@ BLAST server depends on the database from which each sequence was obtained. The table below lists the identifiers for the databases from which the sequences were derived. - + @ifinfo @example Database Name Identifier Syntax @@ -4513,8 +4513,8 @@ SWISS-PROT sp|accession|entry name Brookhaven Protein Data Bank pdb|entry|chain Kabat's Sequences of Immuno@dots{} gnl|kabat|identifier -Patents pat|country|number -GenInfo Backbone Id bbs|number +Patents pat|country|number +GenInfo Backbone Id bbs|number @end example @end ifinfo @@ -4533,7 +4533,7 @@ @end multitable @end ifnotinfo - + For example, an identifier might be @samp{gb|AC021182.14|AC021182}, where the @samp{gb} tag indicates that the identifier refers to a GenBank sequence, @samp{AC021182.14} is its GenBank ACCESSION, and @samp{AC021182} is the GenBank LOCUS. @@ -4556,7 +4556,7 @@ Query: 35 tggtgaagtgtgtttcttg 53 ||||||||||||||||||| Sbjct: 69786 tggtgaagtgtgtttcttg 69804 -@end smallexample +@end smallexample This alignment was located on the human chromosome 7. The fragment on which part of the query was found had a total length of 176383. Only 19 of the @@ -4625,25 +4625,25 @@ @item GNUPlot @uref{http://www.cs.dartmouth.edu/gnuplot_info.html} -@item Mark Humphrys' Eliza page +@item Mark Humphrys' Eliza page @uref{http://www.compapp.dcu.ie/~humphrys/eliza.html} -@item Yahoo! Eliza Information +@item Yahoo! Eliza Information @uref{http://dir.yahoo.com/Recreation/Games/Computer_Games/Internet_Games/Web_Games/Artificial_Intelligence} -@item Java versions of Eliza +@item Java versions of Eliza @uref{http://www.tjhsst.edu/Psych/ch1/eliza.html} -@item Java versions of Eliza with source code +@item Java versions of Eliza with source code @uref{http://home.adelphia.net/~lifeisgood/eliza/eliza.htm} -@item Eliza Programs with Explanations +@item Eliza Programs with Explanations @uref{http://chayden.net/chayden/eliza/Eliza.shtml} @item Loebner Contest @uref{http://acm.org/~loebner/loebner-prize.htmlx} -@item Tck/Tk Information +@item Tck/Tk Information @uref{http://www.scriptics.com/} @item Intel 80x86 Processors @@ -4652,7 +4652,7 @@ @item AMD Elan Processors @uref{http://www.amd.com/products/epd/processors/4.32bitcont/32bitcont/index.html} -@item XINU +@item XINU @uref{http://willow.canberra.edu.au/~chrisc/xinu.html } @item GNU/Linux @@ -4661,7 +4661,7 @@ @item Embedded PCs @uref{http://dir.yahoo.com/Business_and_Economy/Business_to_Business/Computers/Hardware/Embedded_Control/} -@item MiniSQL +@item MiniSQL @uref{http://www.hughes.com.au/library/} @item Market Share Surveys @@ -4676,7 +4676,7 @@ @item The VRML FAQ @uref{http://www.vrml.org/technicalinfo/specifications/specifications.htm#FAQ} -@item The UMBC Agent Web +@item The UMBC Agent Web @uref{http://www.cs.umbc.edu/agents } @item Apache Web Server diff -urN gawk-3.1.2/doc/texinfo.tex gawk-3.1.3/doc/texinfo.tex --- gawk-3.1.2/doc/texinfo.tex 2003-03-06 01:11:53.000000000 -0800 +++ gawk-3.1.3/doc/texinfo.tex 2003-05-14 08:27:53.000000000 -0700 @@ -3,7 +3,7 @@ % Load plain if necessary, i.e., if running under initex. \expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi % -\def\texinfoversion{2003-02-03.16} +\def\texinfoversion{2003-05-04.08} % % Copyright (C) 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995, % 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. @@ -34,12 +34,12 @@ % ftp://tug.org/tex/texinfo.tex % (and all CTAN mirrors, see http://www.ctan.org), % and /home/gd/gnu/doc/texinfo.tex on the GNU machines. -% +% % The GNU Texinfo home page is http://www.gnu.org/software/texinfo. -% +% % The texinfo.tex in any given Texinfo distribution could well be out % of date, so if that's what you're using, please check. -% +% % Send bug reports to bug-texinfo@gnu.org. Please include including a % complete document in each bug report with which we can reproduce the % problem. Patches are, of course, greatly appreciated. @@ -55,7 +55,7 @@ % The extra TeX runs get the cross-reference information correct. % Sometimes one run after texindex suffices, and sometimes you need more % than two; texi2dvi does it as many times as necessary. -% +% % It is possible to adapt texinfo.tex for other languages, to some % extent. You can get the existing language-specific files from the % full Texinfo distribution. @@ -71,11 +71,11 @@ \message{Basics,} \chardef\other=12 -% We never want plain's outer \+ definition in Texinfo. +% We never want plain's \outer definition of \+ in Texinfo. % For @tex, we can use \tabalign. \let\+ = \relax -% Save some parts of plain tex whose names we will redefine. +% Save some plain tex macros whose names we will redefine. \let\ptexb=\b \let\ptexbullet=\bullet \let\ptexc=\c @@ -88,10 +88,12 @@ \let\ptexgtr=> \let\ptexhat=^ \let\ptexi=\i +\let\ptexindent=\indent \let\ptexlbrace=\{ \let\ptexless=< \let\ptexplus=+ \let\ptexrbrace=\} +\let\ptexslash=\/ \let\ptexstar=\* \let\ptext=\t @@ -164,8 +166,9 @@ % Hyphenation fixes. \hyphenation{ap-pen-dix} -\hyphenation{mini-buf-fer mini-buf-fers} \hyphenation{eshell} +\hyphenation{mini-buf-fer mini-buf-fers} +\hyphenation{time-stamp} \hyphenation{white-space} % Margin to add to right of even pages, to left of odd pages. @@ -202,7 +205,7 @@ % add check for \lastpenalty to plain's definitions. If the last thing % we did was a \nobreak, we don't want to insert more space. -% +% \def\smallbreak{\ifnum\lastpenalty<10000\par\ifdim\lastskip<\smallskipamount \removelastskip\penalty-50\smallskip\fi\fi} \def\medbreak{\ifnum\lastpenalty<10000\par\ifdim\lastskip<\medskipamount @@ -536,6 +539,9 @@ % @* forces a line break. \def\*{\hfil\break\hbox{}\ignorespaces} +% @/ allows a line break. +\let\/=\allowbreak + % @. is an end-of-sentence period. \def\.{.\spacefactor=3000 } @@ -564,7 +570,7 @@ % explicit \vfill so that the extra space is at the bottom. The % threshold for doing this is if the group is more than \vfilllimit % percent of a page (\vfilllimit can be changed inside of @tex). -% +% \newbox\groupbox \def\vfilllimit{0.7} % @@ -721,8 +727,7 @@ \spacefactor=3000 } - -% @page forces the start of a new page +% @page forces the start of a new page. % \def\page{\par\vfill\supereject} @@ -771,10 +776,10 @@ % @inmargin{TEXT [, RIGHT-TEXT]} % (if RIGHT-TEXT is given, use TEXT for left page, RIGHT-TEXT for right; % else use TEXT for both). -% +% \def\inmargin#1{\parseinmargin #1,,\finish} \def\parseinmargin#1,#2,#3\finish{% not perfect, but better than nothing. - \setbox0 = \hbox{\ignorespaces #2}% + \setbox0 = \hbox{\ignorespaces #2}% \ifdim\wd0 > 0pt \def\lefttext{#1}% have both texts \def\righttext{#2}% @@ -843,8 +848,9 @@ % @paragraphindent NCHARS % We'll use ems for NCHARS, close enough. -% We cannot implement @paragraphindent asis, though. -% +% NCHARS can also be the word `asis' or `none'. +% We cannot feasibly implement @paragraphindent asis, though. +% \def\asisword{asis} % no translation, these are keywords \def\noneword{none} % @@ -879,6 +885,53 @@ \fi } +% @firstparagraphindent WORD +% If WORD is `none', then suppress indentation of the first paragraph +% after a section heading. If WORD is `insert', then do indentat such +% paragraphs. +% +% The paragraph indentation is suppressed or not by calling +% \suppressfirstparagraphindent, which the sectioning commands do. We +% switch the definition of this back and forth according to WORD. By +% default, we suppress indentation. +% +\def\suppressfirstparagraphindent{\dosuppressfirstparagraphindent} +\newdimen\currentparindent +% +\def\insertword{insert} +% +\def\firstparagraphindent{\parsearg\dofirstparagraphindent} +\def\dofirstparagraphindent#1{% + \def\temp{#1}% + \ifx\temp\noneword + \let\suppressfirstparagraphindent = \dosuppressfirstparagraphindent + \else\ifx\temp\insertword + \let\suppressfirstparagraphindent = \relax + \else + \errhelp = \EMsimple + \errmessage{Unknown @firstparagraphindent option `\temp'}% + \fi\fi +} + +% Here is how we actually suppress indentation. Redefine \everypar to +% \kern backwards by \parindent, and then reset itself to empty. +% +% We also make \indent itself not actually do anything until the next +% paragraph. +% +\gdef\dosuppressfirstparagraphindent{% + \gdef\indent{% + \global\let\indent=\ptexindent + \global\everypar = {}% + }% + \global\everypar = {% + \kern-\parindent + \global\let\indent=\ptexindent + \global\everypar = {}% + }% +}% + + % @asis just yields its argument. Used with @table, for example. % \def\asis#1{#1} @@ -887,14 +940,14 @@ % We don't use $'s directly in the definition of \math because we need % to set catcodes according to plain TeX first, to allow for subscripts, % superscripts, special math chars, etc. -% +% \let\implicitmath = $%$ font-lock fix % % One complication: _ usually means subscripts, but it could also mean % an actual _ character, as in @math{@var{some_variable} + 1}. So make % _ within @math be active (mathcode "8000), and distinguish by seeing % if the current family is \slfam, which is what @var uses. -% +% {\catcode\underChar = \active \gdef\mathunderscore{% \catcode\underChar=\active @@ -905,7 +958,7 @@ % FYI, plain.tex uses \\ as a temporary control sequence (why?), but % this is not advertised and we don't care. Texinfo does not % otherwise define @\. -% +% % The \mathchar is class=0=ordinary, family=7=ttfam, position=5C=\. \def\mathbackslash{\ifnum\fam=\ttfam \mathchar"075C \else\backslash \fi} % @@ -920,7 +973,7 @@ % Some active characters (such as <) are spaced differently in math. % We have to reset their definitions in case the @math was an % argument to a command which set the catcodes (such as @item or @section). -% +% { \catcode`^ = \active \catcode`< = \active @@ -1046,8 +1099,8 @@ \def\pdfmakeoutlines{{% \openin 1 \jobname.toc \ifeof 1\else\begingroup - \closein 1 - % Thanh's hack / proper braces in bookmarks + \closein 1 + % Thanh's hack / proper braces in bookmarks \edef\mylbrace{\iftrue \string{\else}\fi}\let\{=\mylbrace \edef\myrbrace{\iffalse{\else\string}\fi}\let\}=\myrbrace % @@ -1076,7 +1129,7 @@ \let\unnumbsubsubsecentry = \subsubsecentry % % Make special characters normal for writing to the pdf file. - % + % \indexnofonts \let\tt=\relax \turnoffactive @@ -1091,7 +1144,7 @@ \let\nextmakelinks=\makelinks \ifnum\lnkcount>0,\fi \picknum{#1}% - \startlink attr{/Border [0 0 0]} + \startlink attr{/Border [0 0 0]} goto name{\pdfmkpgn{\the\pgn}}% \linkcolor #1% \advance\lnkcount by 1% @@ -1146,7 +1199,7 @@ \ifx\first0\adn0 \else\ifx\first1\adn1 \else\ifx\first2\adn2 \else\ifx\first3\adn3 \else\ifx\first4\adn4 \else\ifx\first5\adn5 \else\ifx\first6\adn6 - \else\ifx\first7\adn7 \else\ifx\first8\adn8 \else\ifx\first9\adn9 + \else\ifx\first7\adn7 \else\ifx\first8\adn8 \else\ifx\first9\adn9 \else \ifnum0=\countA\else\makelink\fi \ifx\first.\let\next=\done\else @@ -1400,12 +1453,12 @@ % 8.5x11=90+ smallbook=80 a4=90+ a5=77 % For me, subjectively, the few extra characters that fit aren't worth % the additional smallness of 8pt. So I'm making the default 9pt. -% +% % By the way, for comparison, here's what fits with @example (10pt): % 8.5x11=71 smallbook=60 a4=75 a5=58 -% +% % I wish we used A4 paper on this side of the Atlantic. -% +% % --karl, 24jan03. @@ -1431,7 +1484,8 @@ % \smartitalic{ARG} outputs arg in italics, followed by an italic correction % unless the following character is such as not to need one. -\def\smartitalicx{\ifx\next,\else\ifx\next-\else\ifx\next.\else\/\fi\fi\fi} +\def\smartitalicx{\ifx\next,\else\ifx\next-\else\ifx\next.\else + \ptexslash\fi\fi\fi} \def\smartslanted#1{{\ifusingtt\ttsl\sl #1}\futurelet\next\smartitalicx} \def\smartitalic#1{{\ifusingtt\ttsl\it #1}\futurelet\next\smartitalicx} @@ -1454,7 +1508,7 @@ % Set sfcode to normal for the chars that usually have another value. % Can't use plain's \frenchspacing because it uses the `\x notation, and % sometimes \x has an active definition that messes things up. -% +% \catcode`@=11 \def\frenchspacing{% \sfcode\dotChar =\@m \sfcode\questChar=\@m \sfcode\exclamChar=\@m @@ -1563,7 +1617,7 @@ \gdef\kbdexamplefont{\tt}\gdef\kbdfont{\tt}% \else \errhelp = \EMsimple - \errmessage{Unknown @kbdinputstyle `\arg'}% + \errmessage{Unknown @kbdinputstyle option `\arg'}% \fi\fi\fi } \def\worddistinct{distinct} @@ -1614,7 +1668,7 @@ % rms does not like angle brackets --karl, 17may97. % So now @email is just like @uref, unless we are pdf. -% +% %\def\email#1{\angleleft{\tt #1}\angleright} \ifpdf \def\email#1{\doemail#1,,\finish} @@ -1659,6 +1713,16 @@ % @pounds{} is a sterling sign. \def\pounds{{\it\$}} +% @registeredsymbol - R in a circle. For now, only works in text size; +% we'd have to redo the font mechanism to change the \scriptstyle and +% \scriptscriptstyle font sizes to make it look right in headings. +% Adapted from the plain.tex definition of \copyright. +% +\def\registeredsymbol{% + $^{{\ooalign{\hfil\raise.07ex\hbox{$\scriptstyle\rm R$}\hfil\crcr\Orb}}% + }$% +} + \message{page headings,} @@ -2071,18 +2135,21 @@ \itemizey {#1}{\Eitemize} } -\def\itemizey #1#2{% -\aboveenvbreak % -\itemmax=\itemindent % -\advance \itemmax by -\itemmargin % -\advance \leftskip by \itemindent % -\exdentamount=\itemindent -\parindent = 0pt % -\parskip = \smallskipamount % -\ifdim \parskip=0pt \parskip=2pt \fi% -\def#2{\endgraf\afterenvbreak\endgroup}% -\def\itemcontents{#1}% -\let\item=\itemizeitem} +\def\itemizey#1#2{% + \aboveenvbreak + \itemmax=\itemindent + \advance\itemmax by -\itemmargin + \advance\leftskip by \itemindent + \exdentamount=\itemindent + \parindent=0pt + \parskip=\smallskipamount + \ifdim\parskip=0pt \parskip=2pt \fi + \def#2{\endgraf\afterenvbreak\endgroup}% + \def\itemcontents{#1}% + % @itemize with no arg is equivalent to @itemize @bullet. + \ifx\itemcontents\empty\def\itemcontents{\bullet}\fi + \let\item=\itemizeitem +} % \splitoff TOKENS\endmark defines \first to be the first token in % TOKENS, and \rest to be the remainder. @@ -2493,12 +2560,12 @@ % @deffn ... % @end deffn % @end ignore -% +% % The @end deffn is going to get expanded, because we're trying to allow % nested conditionals. But we don't want to expand the actual @deffn, % since it might be syntactically correct and intended to be ignored. % Since \end checks for \relax, using \empty does not cause an error. -% +% \def\ignoremorecommands{% \let\defcodeindex = \relax \let\defcv = \empty @@ -2903,10 +2970,10 @@ % @synindex foo bar makes index foo feed into index bar. % Do this instead of @defindex foo if you don't want it as a separate index. -% +% % @syncodeindex foo bar similar, but put all entries made for index foo % inside @code. -% +% \def\synindex#1 #2 {\dosynindex\doindex{#1}{#2}} \def\syncodeindex#1 #2 {\dosynindex\docodeindex{#1}{#2}} @@ -2948,13 +3015,13 @@ % Take care of Texinfo commands that can appear in an index entry. % Since there are some commands we want to expand, and others we don't, % we have to laboriously prevent expansion for those that we don't. -% +% \def\indexdummies{% \def\@{@}% change to @@ when we switch to @ as escape char in index files. \def\ {\realbackslash\space }% % Need these in case \tex is in effect and \{ is a \delimiter again. % But can't use \lbracecmd and \rbracecmd because texindex assumes - % braces and backslashes are used only as delimiters. + % braces and backslashes are used only as delimiters. \let\{ = \mylbrace \let\} = \myrbrace % @@ -2963,14 +3030,14 @@ % words, not control letters, because the \space would be incorrect % for control characters, but is needed to separate the control word % from whatever follows. - % + % % For control letters, we have \definedummyletter, which omits the % space. - % + % % These can be used both for control words that take an argument and % those that do not. If it is followed by {arg} in the input, then % that will dutifully get written to the index (or wherever). - % + % \def\definedummyword##1{% \expandafter\def\csname ##1\endcsname{\realbackslash ##1\space}% }% @@ -2983,9 +3050,9 @@ } % For the aux file, @ is the escape character. So we want to redefine -% everything using @ instead of \realbackslash. When everything uses +% everything using @ instead of \realbackslash. When everything uses % @, this will be simpler. -% +% \def\atdummies{% \def\@{@@}% \def\ {@ }% @@ -3006,7 +3073,7 @@ % Called from \indexdummies and \atdummies. \definedummyword and % \definedummyletter must be defined first. -% +% \def\commondummies{% % \normalturnoffactive @@ -3326,6 +3393,7 @@ % \smallfonts \rm \tolerance = 9500 + \everypar = {}% don't want the \kern\-parindent from indentation suppression. \indexbreaks % % See if the index file exists and is nonempty. @@ -3569,7 +3637,7 @@ \wd0=\hsize \wd2=\hsize \hbox to\pagewidth{\box0\hfil\box2}% } -% +% % All done with double columns. \def\enddoublecolumns{% \output = {% @@ -3707,6 +3775,7 @@ \numberedsubsubseczzz{#2} \fi \fi +\suppressfirstparagraphindent } % like \numhead, but chooses appendix heading levels @@ -3726,6 +3795,7 @@ \appendixsubsubseczzz{#2} \fi \fi +\suppressfirstparagraphindent } % like \numhead, but chooses numberless heading levels @@ -3745,6 +3815,7 @@ \unnumberedsubsubseczzz{#2} \fi \fi +\suppressfirstparagraphindent } % @chapter, @appendix, @unnumbered. @@ -4357,7 +4428,7 @@ % @foo ... @end foo. % @point{}, @result{}, @expansion{}, @print{}, @equiv{}. -% +% % Since these characters are used in examples, it should be an even number of % \tt widths. Each \tt character is 1en, so two makes it 1em. % @@ -4369,7 +4440,7 @@ % The @error{} command. % Adapted from the TeXbook's \boxit. -% +% \newbox\errorbox % {\tentt \global\dimen0 = 3em}% Width of the box. @@ -4416,9 +4487,11 @@ \let\equiv=\ptexequiv \let\!=\ptexexclam \let\i=\ptexi + \let\indent=\ptexindent \let\{=\ptexlbrace \let\+=\tabalign \let\}=\ptexrbrace + \let\/=\ptexslash \let\*=\ptexstar \let\t=\ptext % @@ -4668,7 +4741,7 @@ % LaTeX-like @verbatim...@end verbatim and @verb{...} -% If we want to allow any as delimiter, +% If we want to allow any as delimiter, % we need the curly braces so that makeinfo sees the @verb command, eg: % `@verbx...x' would look like the '@verbx' command. --janneke@gnu.org % @@ -4746,8 +4819,8 @@ \everypar{\starttabbox}% } -% Do the @verb magic: verbatim text is quoted by unique -% delimiter characters. Before first delimiter expect a +% Do the @verb magic: verbatim text is quoted by unique +% delimiter characters. Before first delimiter expect a % right brace, after last delimiter expect closing brace: % % \def\doverb'{'#1'}'{#1} @@ -4766,7 +4839,7 @@ % % \def\doverbatim#1@end verbatim{#1} % -% For Texinfo it's a lot easier than for LaTeX, +% For Texinfo it's a lot easier than for LaTeX, % because texinfo's \verbatim doesn't stop at '\end{verbatim}': % we need not redefine '\', '{' and '}'. % @@ -4833,14 +4906,14 @@ % @copying ... @end copying. % Save the text away for @insertcopying later. Many commands won't be % allowed in this context, but that's ok. -% +% % We save the uninterpreted tokens, rather than creating a box. % Saving the text in a box would be much easier, but then all the % typesetting commands (@smallbook, font changes, etc.) have to be done % beforehand -- and a) we want @copying to be done first in the source % file; b) letting users define the frontmatter in as flexible order as % possible is very desirable. -% +% \def\copying{\begingroup % Define a command to swallow text until we reach `@end copying'. % \ is the escape char in this texinfo.tex file, so it is the @@ -4863,15 +4936,15 @@ % end-of-line to be a \par, as would happen with the normal active % definition of ^^M. On the third hand, two ^^M's in a row should still % generate a \par. -% +% % Our approach is to make ^^M insert a space and a penalty1 normally; % then it can also check if \lastpenalty=1. If it does, then manually % do \par. -% +% % This messes up the normal definitions of @c[omment], so we redefine % it. Similarly for @ignore. (These commands are used in the gcc % manual for man page generation.) -% +% % Seems pretty fragile, most line-oriented commands will presumably % fail, but for the limited use of getting the copying text (which % should be quite simple) inserted, we can hope it's ok. @@ -4912,7 +4985,7 @@ \newcount\parencount % We want ()&[] to print specially on the defun line. -% +% \def\activeparens{% \catcode`\(=\active \catcode`\)=\active \catcode`\&=\active @@ -5015,7 +5088,7 @@ % #1 is the \E... control sequence to end the definition (which we define). % #2 is the \...x control sequence (which our caller defines). % #3 is the control sequence to process the header, such as \defunheader. -% +% \def\parsebodycommon#1#2#3{% \begingroup\inENV % If there are two @def commands in a row, we'll have a \nobreak, @@ -5038,7 +5111,7 @@ } % Common part of the \...x definitions. -% +% \def\defxbodycommon{% % As with \parsebodycommon above, allow line break if we have multiple % x headers in a row. It's not a great place, though. @@ -5089,7 +5162,7 @@ % to account for this both in the \...x definition and in parsing the % input at hand. Thus also need a control sequence (passed as #5) for % the \E... definition to assign the category name to. -% +% \def\deftypeopparsebody#1#2#3#4#5 #6 {% \parsebodycommon{#1}{#2}{#3}% \def#2##1 ##2 ##3 {\def#4{##1}% @@ -5194,7 +5267,7 @@ } % This expands the args and terminates the paragraph they comprise. -% +% \def\defunargs#1{\functionparens \sl % Expand, preventing hyphenation at `-' chars. % Note that groups don't affect changes in \hyphenchar. @@ -5456,7 +5529,7 @@ % These definitions are used if you use @defunx (etc.) % anywhere other than immediately after a @defun or @defunx. -% +% \def\defcvx#1 {\errmessage{@defcvx in invalid context}} \def\deffnx#1 {\errmessage{@deffnx in invalid context}} \def\defivarx#1 {\errmessage{@defivarx in invalid context}} @@ -5628,7 +5701,7 @@ % Called by \do from \dounmacro on each macro. The idea is to omit any % macro definitions that have been changed to \relax. -% +% \def\unmacrodo#1{% \ifx#1\relax % remove this @@ -5784,8 +5857,8 @@ % @node's job is to define \lastnode. \def\node{\ENVcheck\parsearg\nodezzz} -\def\nodezzz#1{\nodexxx [#1,]} -\def\nodexxx[#1,#2]{\gdef\lastnode{#1}} +\def\nodezzz#1{\nodexxx #1,\finishnodeparse} +\def\nodexxx#1,#2\finishnodeparse{\gdef\lastnode{#1}} \let\nwnode=\node \let\lastnode=\relax @@ -5823,14 +5896,14 @@ % anchor), namely NAME-title (the corresponding @chapter/etc. name), % NAME-pg (the page number), and NAME-snt (section number and type). % Called from \foonoderef. -% +% % We have to set \indexdummies so commands such as @code in a section % title aren't expanded. It would be nicer not to expand the titles in % the first place, but there's so many layers that that is hard to do. % % Likewise, use \turnoffactive so that punctuation chars such as underscore % and backslash work in node names. -% +% \def\setref#1#2{{% \atdummies \pdfmkdest{#1}% @@ -5913,14 +5986,25 @@ \setbox2 = \hbox{\ignorespaces \refx{#1-snt}{}}% \ifdim \wd2 > 0pt \refx{#1-snt}\space\fi }% - % [mynode], - [\printednodename],\space - % page 3 + % output the `[mynode]' via a macro. + \xrefprintnodename\printednodename + % + % But we always want a comma and a space: + ,\space + % + % output the `page 3'. \turnoffactive \otherbackslash \putwordpage\tie\refx{#1-pg}{}% \fi \endlink \endgroup} +% This macro is called from \xrefX for the `[nodename]' part of xref +% output. It's a separate macro only so it can be changed more easily, +% since not square brackets don't work in some documents. Particularly +% one that Bob is working on :). +% +\def\xrefprintnodename#1{[#1]} + % \dosetq is called from \setref to do the actual \write (\iflinks). % \def\dosetq#1#2{% @@ -5935,7 +6019,7 @@ \def\internalsetq#1#2{@xrdef{#1}{\csname #2\endcsname}} % Things to be expanded by \internalsetq. -% +% \def\Ypagenumber{\folio} \def\Ytitle{\thissection} \def\Ynothing{} @@ -6120,13 +6204,14 @@ % % Auto-number footnotes. Otherwise like plain. \gdef\footnote{% + \let\indent=\ptexindent \global\advance\footnoteno by \@ne \edef\thisfootno{$^{\the\footnoteno}$}% % % In case the footnote comes at the end of a sentence, preserve the % extra spacing after we do the footnote number. \let\@sf\empty - \ifhmode\edef\@sf{\spacefactor\the\spacefactor}\/\fi + \ifhmode\edef\@sf{\spacefactor\the\spacefactor}\ptexslash\fi % % Remove inadvertent blank space before typesetting the footnote number. \unskip @@ -6267,7 +6352,7 @@ \nobreak\bigskip % Usually we'll have text after the image which will insert % \parskip glue, so insert it here too to equalize the space - % above and below. + % above and below. \nobreak\vskip\parskip \nobreak \line\bgroup\hss @@ -6355,7 +6440,7 @@ % Parameters in order: 1) textheight; 2) textwidth; 3) voffset; % 4) hoffset; 5) binding offset; 6) topskip; 7) physical page height; 8) % physical page width. -% +% % We also call \setleading{\textleading}, so the caller should define % \textleading. The caller should also set \parskip. % @@ -6423,7 +6508,7 @@ \parskip = 3pt plus 2pt minus 1pt \textleading = 13.2pt % - % Double-side printing via postscript on Laserjet 4050 + % Double-side printing via postscript on Laserjet 4050 % prints double-sided nicely when \bindingoffset=10mm and \hoffset=-6mm. % To change the settings for a different printer or situation, adjust % \normaloffset until the front-side and back-side texts align. Then @@ -6464,7 +6549,7 @@ \tableindent = 12mm }} -% A specific text layout, 24x15cm overall, intended for A4 paper. +% A specific text layout, 24x15cm overall, intended for A4 paper. \def\afourlatex{{\globaldefs = 1 \afourpaper \internalpagesizes{237mm}{150mm}% @@ -6640,7 +6725,7 @@ % Same as @turnoffactive except outputs \ as {\tt\char`\\} instead of % the literal character `\'. (Thus, \ is not expandable when this is in % effect.) -% +% @def@normalturnoffactive{@turnoffactive @let\=@normalbackslash} % Make _ and + \other characters, temporarily. @@ -6669,7 +6754,7 @@ % Say @foo, not \foo, in error messages. @escapechar = `@@ -% These look ok in all fonts, so just make them not special. +% These look ok in all fonts, so just make them not special. @catcode`@& = @other @catcode`@# = @other @catcode`@% = @other diff -urN gawk-3.1.2/eval.c gawk-3.1.3/eval.c --- gawk-3.1.2/eval.c 2003-03-03 04:35:05.000000000 -0800 +++ gawk-3.1.3/eval.c 2003-06-22 01:56:04.000000000 -0700 @@ -33,15 +33,13 @@ static NODE *op_assign P((NODE *tree)); static NODE *func_call P((NODE *tree)); static NODE *match_op P((NODE *tree)); -static int forloops_active P((void)); static void pop_forloop P((void)); -static void pop_all_forloops P((void)); +static inline void pop_all_forloops P((void)); static void push_forloop P((const char *varname, NODE **elems, size_t nelems)); static void push_args P((int count, NODE *arglist, NODE **oldstack, const char *func_name, char **varnames)); -static void pop_fcall_stack P((void)); +static inline void pop_fcall_stack P((void)); static void pop_fcall P((void)); -static int in_function P((void)); static int comp_func P((const void *p1, const void *p2)); #if __GNUC__ < 2 @@ -190,10 +188,15 @@ "Node_rule_list", "Node_rule_node", "Node_statement_list", + "Node_switch_body", + "Node_case_list", "Node_if_branches", "Node_expression_list", "Node_param_list", "Node_K_if", + "Node_K_switch", + "Node_K_case", + "Node_K_default", "Node_K_while", "Node_K_for", "Node_K_arrayfor", @@ -217,6 +220,7 @@ "Node_redirect_pipein", "Node_redirect_input", "Node_redirect_twoway", + "Node_var_new", "Node_var", "Node_var_array", "Node_val", @@ -278,11 +282,9 @@ { NUMBER, "NUMBER" }, { MAYBE_NUM, "MAYBE_NUM" }, { ARRAYMAXED, "ARRAYMAXED" }, - { SCALAR, "SCALAR" }, { FUNC, "FUNC" }, { FIELD, "FIELD" }, { INTLSTR, "INTLSTR" }, - { UNINITIALIZED, "UNINITIALIZED" }, { 0, NULL }, }; @@ -372,16 +374,12 @@ } break; case TAG_CONTINUE: /* NEXT statement */ - if (forloops_active()) - pop_all_forloops(); - if (in_function()) - pop_fcall_stack(); + pop_all_forloops(); + pop_fcall_stack(); return 1; case TAG_BREAK: /* EXIT statement */ - if (forloops_active()) - pop_all_forloops(); - if (in_function()) - pop_fcall_stack(); + pop_all_forloops(); + pop_fcall_stack(); return 0; default: cant_happen(); @@ -406,6 +404,106 @@ } break; + case Node_K_switch: + { + NODE *switch_value; + NODE *switch_body; + NODE *case_list; + NODE *default_list; + NODE *case_stmt; + + int match_found = FALSE; + + PUSH_BINDING(loop_tag_stack, loop_tag, loop_tag_valid); + INCREMENT(tree->exec_count); + stable_tree = tree; + + switch_value = tree_eval(stable_tree->lnode); + switch_body = stable_tree->rnode; + case_list = switch_body->lnode; + default_list = switch_body->rnode; + + for (; case_list != NULL; case_list = case_list->rnode) { + case_stmt = case_list->lnode; + + /* + * Once a match is found, all cases will be processed as they fall through, + * so continue to execute statements until a break is reached. + */ + if (! match_found) { + if (case_stmt->type == Node_K_default) + ; /* do nothing */ + else if (case_stmt->lnode->type == Node_regex) { + NODE *t1; + Regexp *rp; + + t1 = force_string(switch_value); + rp = re_update(case_stmt->lnode); + + match_found = (research(rp, t1->stptr, 0, t1->stlen, FALSE) >= 0); + if (t1 != switch_value) + free_temp(t1); + } else { + match_found = (cmp_nodes(switch_value, case_stmt->lnode) == 0); + } + } + + /* If a match was found, execute the statements associated with the case. */ + if (match_found) { + INCREMENT(case_stmt->exec_count); + switch (setjmp(loop_tag)) { + case 0: /* Normal non-jump */ + (void) interpret(case_stmt->rnode); + break; + case TAG_CONTINUE: /* continue statement */ + free_temp(switch_value); + RESTORE_BINDING(loop_tag_stack, loop_tag, loop_tag_valid); + longjmp(loop_tag, TAG_CONTINUE); + break; + case TAG_BREAK: /* break statement */ + free_temp(switch_value); + RESTORE_BINDING(loop_tag_stack, loop_tag, loop_tag_valid); + return 1; + default: + cant_happen(); + } + } + + } + + free_temp(switch_value); + + /* + * If a default section was found, execute the statements associated with it + * and execute any trailing case statements if the default falls through. + */ + if (! match_found && default_list != NULL) { + for (case_list = default_list; + case_list != NULL; case_list = case_list->rnode) { + case_stmt = case_list->lnode; + + INCREMENT(case_stmt->exec_count); + switch (setjmp(loop_tag)) { + case 0: /* Normal non-jump */ + (void) interpret(case_stmt->rnode); + break; + case TAG_CONTINUE: /* continue statement */ + RESTORE_BINDING(loop_tag_stack, loop_tag, loop_tag_valid); + longjmp(loop_tag, TAG_CONTINUE); + break; + case TAG_BREAK: /* break statement */ + RESTORE_BINDING(loop_tag_stack, loop_tag, loop_tag_valid); + return 1; + default: + cant_happen(); + } + } + } + + RESTORE_BINDING(loop_tag_stack, loop_tag, loop_tag_valid); + } + break; + case Node_K_while: PUSH_BINDING(loop_tag_stack, loop_tag, loop_tag_valid); @@ -475,8 +573,9 @@ case Node_K_arrayfor: { Func_ptr after_assign = NULL; - NODE **list = 0; + NODE **list = NULL; NODE *volatile array; + NODE *volatile save_array; volatile size_t i, num_elems; size_t j; volatile int retval = 0; @@ -485,19 +584,12 @@ #define hakvar forloop->init #define arrvar forloop->incr /* get the array */ - array = tree->arrvar; - if (array->type == Node_param_list) - array = stack_ptr[array->param_cnt]; - if (array->type == Node_array_ref) - array = array->orig_array; - if ((array->flags & SCALAR) != 0) - fatal(_("attempt to use scalar `%s' as array"), array->vname); + save_array = tree->arrvar; + array = get_array(save_array); /* sanity: do nothing if empty */ - if (array->type == Node_var || array->var_array == NULL - || array->table_size == 0) { + if (array->var_array == NULL || array->table_size == 0) break; /* from switch */ - } /* allocate space for array */ num_elems = array->table_size; @@ -553,7 +645,7 @@ if (do_lint && num_elems != array->table_size) lintwarn(_("for loop: array `%s' changed size from %ld to %ld during loop execution"), - array->vname, (long) num_elems, (long) array->table_size); + array_vname(save_array), (long) num_elems, (long) array->table_size); if (retval == 1) return 1; @@ -652,11 +744,8 @@ * Have to do this cleanup here, since we don't longjump * back to the main awk rule loop (rule_tag). */ - if (forloops_active()) - pop_all_forloops(); - - if (in_function()) - pop_fcall_stack(); + pop_all_forloops(); + pop_fcall_stack(); do_nextfile(); break; @@ -692,7 +781,7 @@ * Appears to be an expression statement. Throw away the * value. */ - if (do_lint && tree->type == Node_var) + if (do_lint && (tree->type == Node_var || tree->type == Node_var_new)) lintwarn(_("statement has no effect")); INCREMENT(tree->exec_count); t = tree_eval(tree); @@ -717,20 +806,20 @@ long lx2; #endif -#ifdef GAWKDEBUG +#ifndef TREE_EVAL_MACRO if (tree == NULL) return Nnull_string; else if (tree->type == Node_val) { if (tree->stref <= 0) cant_happen(); - return tree; + return ((tree->flags & INTLSTR) != 0 + ? r_force_string(tree) + : tree); } else if (tree->type == Node_var) { if (tree->var_value->stref <= 0) cant_happen(); - if ((tree->flags & UNINITIALIZED) != 0) - warning(_("reference to uninitialized variable `%s'"), - tree->vname); - return tree->var_value; + if (! var_uninitialized(tree)) + return tree->var_value; } #endif @@ -748,16 +837,24 @@ return Nnull_string; } - if (do_lint && (tree->flags & UNINITIALIZED) != 0) + if (do_lint && var_uninitialized(tree)) lintwarn(_("reference to uninitialized argument `%s'"), tree->vname); } - if (tree->type == Node_array_ref) - tree = tree->orig_array; switch (tree->type) { + case Node_array_ref: + if (tree->orig_array->type == Node_var_array) + fatal(_("attempt to use array `%s' in a scalar context"), + array_vname(tree)); + tree->orig_array->type = Node_var; + /* fall through */ + case Node_var_new: + tree->type = Node_var; + tree->var_value = Nnull_string; + /* fall through */ case Node_var: - if (do_lint && (tree->flags & UNINITIALIZED) != 0) + if (do_lint && var_uninitialized(tree)) lintwarn(_("reference to uninitialized variable `%s'"), tree->vname); return tree->var_value; @@ -808,7 +905,7 @@ case Node_var_array: fatal(_("attempt to use array `%s' in a scalar context"), - tree->vname); + array_vname(tree)); case Node_unary_minus: t1 = tree_eval(tree->subnode); @@ -937,7 +1034,6 @@ lhs = get_lhs(tree->lnode, &after_assign, FALSE); assign_val(lhs, r); - tree->lnode->flags |= SCALAR; if (after_assign) (*after_assign)(); return *lhs; @@ -1261,7 +1357,6 @@ cant_happen(); } - tree->lnode->flags |= SCALAR; if (after_assign) (*after_assign)(); @@ -1298,15 +1393,6 @@ size_t nloops = 0; /* how many slots there are in the stack */ size_t nloops_active = 0; /* how many loops are actively stacked */ - -/* forloops_active --- return true if there are loops that need popping */ - -static int -forloops_active() -{ - return nloops > 0; -} - /* pop_forloop --- pop one for loop off the stack */ static void @@ -1332,7 +1418,7 @@ /* pop_forloops --- pop the for loops stack all the way */ -static void +static inline void pop_all_forloops() { while (nloops_active > 0) @@ -1374,20 +1460,12 @@ static long fcall_list_size = 0; static long curfcall = -1; -/* in_function --- return true/false if we need to unwind awk functions */ - -static int -in_function() -{ - return (curfcall >= 0); -} - /* pop_fcall --- pop off a single function call */ static void pop_fcall() { - NODE *n, **sp, *arg, *argp; + NODE *n, **sp; int count; struct fcall *f; @@ -1395,71 +1473,25 @@ f = & fcall_list[curfcall]; stack_ptr = f->prevstack; - /* - * here, we pop each parameter and check whether - * it was an array. If so, and if the arg. passed in was - * a simple variable, then the value should be copied back. - * This achieves "call-by-reference" for arrays. - */ sp = f->stack; - count = f->count; - for (argp = f->arglist; count > 0 && argp != NULL; argp = argp->rnode) { - arg = argp->lnode; - if (arg->type == Node_param_list) - arg = stack_ptr[arg->param_cnt]; + for (count = f->count; count > 0; count--) { n = *sp++; - if (n->type == Node_var_array || n->type == Node_array_ref) { - NODETYPE old_type; /* for check, below */ - - old_type = arg->type; - - /* - * We only free n->vname in the same cases in push_fcall() which - * mallocs it. These are when passing a real array in; the - * old type is array and the parameter "copy" is an array ref, - * or when passing an array reference on to another function. - * It helps to be awake when writing code. - */ - if ( (old_type == Node_var_array && n->type == Node_array_ref) - || (old_type == Node_array_ref && n->type == Node_array_ref) ) - free(n->vname); - - if (arg->type == Node_var) { - /* type changed, copy array back for call by reference */ - /* should we free arg->var_value ? */ - arg->var_array = n->var_array; - arg->type = Node_var_array; - arg->array_size = n->array_size; - arg->table_size = n->table_size; - arg->flags = n->flags; - } - } - /* n->lnode overlays the array size, don't unref it if array */ - if (n->type != Node_var_array && n->type != Node_array_ref) - unref(n->lnode); - freenode(n); - count--; - } - while (count-- > 0) { - n = *sp++; - /* if n is a local array, all the elements should be freed */ - if (n->type == Node_var_array) + if (n->type == Node_var) /* local variable */ + unref(n->var_value); + else if (n->type == Node_var_array) /* local array */ assoc_clear(n); - /* n->lnode overlays the array size, don't unref it if array */ - if (n->type != Node_var_array && n->type != Node_array_ref) - unref(n->lnode); freenode(n); } if (f->stack) free((char *) f->stack); - memset(f, '\0', sizeof(struct fcall)); + /* memset(f, '\0', sizeof(struct fcall)); */ curfcall--; } /* pop_fcall_stack --- pop off all function args, don't leak memory */ -static void +static inline void pop_fcall_stack() { while (curfcall >= 0) @@ -1470,17 +1502,14 @@ static void push_args(int count, - NODE *arglist, + NODE *argp, NODE **oldstack, const char *func_name, char **varnames) { struct fcall *f; - NODE *arg, *argp, *r, **sp, *n; + NODE *arg, *r, **sp; int i; - int num_args; - - num_args = count; /* save for later use */ if (fcall_list_size == 0) { /* first time */ emalloc(fcall_list, struct fcall *, 10 * sizeof(struct fcall), @@ -1494,64 +1523,52 @@ fcall_list_size * sizeof(struct fcall), "push_args"); } f = & fcall_list[curfcall]; - memset(f, '\0', sizeof(struct fcall)); if (count > 0) emalloc(f->stack, NODE **, count*sizeof(NODE *), "push_args"); + else + f->stack = NULL; f->count = count; f->fname = func_name; /* not used, for debugging, just in case */ - f->arglist = arglist; + f->arglist = argp; f->prevstack = oldstack; sp = f->stack; /* for each calling arg. add NODE * on stack */ - for (argp = arglist, i = 0; count > 0 && argp != NULL; argp = argp->rnode) { - static const char from[] = N_("%s (from %s)"); - arg = argp->lnode; + for (i = 0; i < count; i++) { getnode(r); - r->type = Node_var; - r->flags = 0; + *sp++ = r; + if (argp == NULL) { + /* local variable */ + r->type = Node_var_new; + r->vname = varnames[i]; + continue; + } + arg = argp->lnode; /* call by reference for arrays; see below also */ if (arg->type == Node_param_list) { /* we must also reassign f here; see below */ f = & fcall_list[curfcall]; arg = f->prevstack[arg->param_cnt]; } - if (arg->type == Node_var_array) { - char *p; - size_t len; - + if (arg->type == Node_var_array || arg->type == Node_var_new) { r->type = Node_array_ref; - r->flags &= ~SCALAR; r->orig_array = arg; - len = strlen(varnames[i]) + strlen(arg->vname) - + strlen(gettext(from)) - 4 + 1; - emalloc(p, char *, len, "push_args"); - sprintf(p, _(from), varnames[i], arg->vname); - r->vname = p; + r->prev_array = arg; } else if (arg->type == Node_array_ref) { - char *p; - size_t len; - *r = *arg; - len = strlen(varnames[i]) + strlen(arg->vname) - + strlen(gettext(from)) - 4 + 1; - emalloc(p, char *, len, "push_args"); - sprintf(p, _(from), varnames[i], arg->vname); - r->vname = p; + r->prev_array = arg; } else { - n = tree_eval(arg); + NODE *n = tree_eval(arg); + + r->type = Node_var; r->lnode = dupnode(n); r->rnode = (NODE *) NULL; - if ((n->flags & SCALAR) != 0) - r->flags |= SCALAR; - r->vname = varnames[i]; free_temp(n); } - *sp++ = r; - i++; - count--; + r->vname = varnames[i]; + argp = argp->rnode; } /* @@ -1574,7 +1591,8 @@ if (arg->type == Node_param_list) arg = f->prevstack[arg->param_cnt]; if (arg->type != Node_var_array && - arg->type != Node_array_ref) + arg->type != Node_array_ref && + arg->type != Node_var_new) free_temp(tree_eval(arg)); /* reassign f, tree_eval could have moved it */ @@ -1582,19 +1600,6 @@ } while ((argp = argp->rnode) != NULL); } - /* add remaining params. on stack with null value */ - while (count-- > 0) { - getnode(r); - r->type = Node_var; - r->lnode = Nnull_string; - r->flags &= ~SCALAR; - r->rnode = (NODE *) NULL; - r->vname = varnames[i++]; - r->flags = UNINITIALIZED; - r->param_cnt = num_args - count; - *sp++ = r; - } - stack_ptr = f->stack; } @@ -1723,18 +1728,30 @@ } switch (ptr->type) { - case Node_array_ref: case Node_var_array: fatal(_("attempt to use array `%s' in a scalar context"), - ptr->vname); + array_vname(ptr)); + /* + * The following goop ensures that uninitialized variables + * used as parameters eventually get their type set correctly + * to scalar (i.e., Node_var). + */ + case Node_array_ref: + if (ptr->orig_array->type == Node_var_array) + fatal(_("attempt to use array `%s' in a scalar context"), + array_vname(ptr)); + ptr->orig_array->type = Node_var; + /* fall through */ + case Node_var_new: + ptr->type = Node_var; + ptr->var_value = Nnull_string; + /* fall through */ case Node_var: - if (do_lint && reference && (ptr->flags & UNINITIALIZED) != 0) + if (do_lint && reference && var_uninitialized(ptr)) lintwarn(_("reference to uninitialized variable `%s'"), ptr->vname); - /* clear the flag, since it's about to be assigned to */ - ptr->flags &= ~UNINITIALIZED; aptr = &(ptr->var_value); #ifdef GAWKDEBUG if (ptr->var_value->stref <= 0) @@ -1860,23 +1877,16 @@ aptr = &fields_arr[0]; if (assign != NULL) *assign = reset_record; - break; - } - aptr = get_field(field_num, assign); + } else + aptr = get_field(field_num, assign); + if (do_lint && reference && (*aptr == Null_field || *aptr == Nnull_string)) + lintwarn(_("reference to uninitialized field `$%d'"), + field_num); break; } case Node_subscript: - n = ptr->lnode; - if (n->type == Node_param_list) { - n = stack_ptr[n->param_cnt]; - if ((n->flags & SCALAR) != 0) - fatal(_("attempt to use scalar parameter `%s' as an array"), n->vname); - } - if (n->type == Node_array_ref) { - n = n->orig_array; - assert(n->type == Node_var_array || n->type == Node_var); - } + n = get_array(ptr->lnode); aptr = assoc_lookup(n, concat_exp(ptr->rnode), reference); break; @@ -2217,6 +2227,7 @@ size_t len1, len2; const char *str1, *str2; const NODE *t1, *t2; + int cmp1; t1 = *((const NODE *const *) p1); t2 = *((const NODE *const *) p2); @@ -2225,15 +2236,15 @@ t1 = force_string(t1); t2 = force_string(t2); */ - len1 = t1->stlen; - str1 = t1->stptr; + len1 = t1->ahname_len; + str1 = t1->ahname_str; - len2 = t2->stlen; - str2 = t2->stptr; + len2 = t2->ahname_len; + str2 = t2->ahname_str; /* Array indexes are strings, compare as such, always! */ - if (len1 == len2 || len1 < len2) - return memcmp(str1, str2, len1); - else - return memcmp(str1, str2, len2); + cmp1 = memcmp(str1, str2, len1 < len2 ? len1 : len2); + /* if prefixes are equal, size matters */ + return (cmp1 != 0 ? cmp1 : + len1 < len2 ? -1 : (len1 > len2)); } diff -urN gawk-3.1.2/ext.c gawk-3.1.3/ext.c --- gawk-3.1.2/ext.c 2003-02-04 04:12:26.000000000 -0800 +++ gawk-3.1.3/ext.c 2003-07-07 11:18:38.000000000 -0700 @@ -150,8 +150,10 @@ if (tree->lnode == Nnull_string) return NULL; - if (tree->type == Node_array_ref) + if (tree->type == Node_array_ref) { tree = tree->orig_array; + return tree; + } if (tree->type == Node_var_array) return tree; diff -urN gawk-3.1.2/extension/Makefile.pc gawk-3.1.3/extension/Makefile.pc --- gawk-3.1.2/extension/Makefile.pc 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/extension/Makefile.pc 2003-06-29 05:53:28.000000000 -0700 @@ -0,0 +1,55 @@ +# Makefile for gawk extensions Mar 2003 + +# - for GNU C (mingw32) [Windows32 executable for Windows 9x/NT] +# - for Microsoft C 7 [16bit ececutable for DOS] + +# see README.pc for comments + +#------------------------------------------------------------------------ +# Some makes do not define MAKE (and ndmake does not allow a define). +# Define MAK to be your make command. +#MAKE = dmake +MAK = $(MAKE) $(MAKEFILE) +#MAK = $(MAKE) +#MAKEFILE = -f Makefile +#MAK = make45 $(MAKEFILE) + +VCCFLAGS=-nologo -O2 -DWIN32 -DWIN32_EXTENSION -D__STDC__=0 -DGAWK -I.. -DHAVE_CONFIG_H -DDYNAMIC +VCLDFLAGS=-LD ../gawk.lib +VCCC=cl -nologo + +MWCFLAGS=-O -shared -DWIN32 -DWIN32_EXTENSION -DGAWK -I.. -DHAVE_CONFIG_H -DDYNAMIC +MWLDFLAGS=-s -Wl,--enable-stdcall-fixup -L.. -lgawk +MWCC=gcc + +# this DEFFILE will work provided the exported function is always called +# dlload +DEFFILE=pcext.def + + +default: + @echo "Enter $(MAK) target " + @echo " where 'target' is chosen from " + @echo " mingw32 . Windows32 exe [Mingw32 GNU C] " + @echo " vcWin32 . Windows32 exe [Microsoft Visual C] " + +.SUFFIXES: .c .dll + +.c.dll: + $(CC) $(CFLAGS) $< -o$@ $(LDFLAGS) $(DEFFILE) + + +# dl.c, fork.c, and filefuncs.c don't compile cleanly... +all : readfile.dll ordchr.dll arrayparm.dll + +vcWin32: + $(MAK) CFLAGS="$(VCCFLAGS)" LDFLAGS="$(VCLDFLAGS)" CC="$(VCCC)" all + +mingw32: + $(MAK) CFLAGS="$(MWCFLAGS)" LDFLAGS="$(MWLDFLAGS)" CC="$(MWCC)" all + +clean: + -rm *.dll + -rm *.o + -rm *.obj + -rm *.lib diff -urN gawk-3.1.2/extension/arrayparm.c gawk-3.1.3/extension/arrayparm.c --- gawk-3.1.2/extension/arrayparm.c 2001-10-17 06:02:35.000000000 -0700 +++ gawk-3.1.3/extension/arrayparm.c 2003-07-07 11:19:07.000000000 -0700 @@ -4,10 +4,12 @@ * Arnold Robbins * arnold@skeeve.com * 10/2001 + * + * Revised 7/2003 */ /* - * Copyright (C) 2001 the Free Software Foundation, Inc. + * Copyright (C) 2001, 2003 the Free Software Foundation, Inc. * * This file is part of GAWK, the GNU implementation of the * AWK Programming Language. @@ -51,6 +53,8 @@ var = get_argument(tree, 0); if (var == NULL) var = stack_ptr[0]; + + var = get_array(var); sub = get_argument(tree, 1); val = get_argument(tree, 2); @@ -58,14 +62,6 @@ printf("sub->type = %s\n", nodetype2str(sub->type)); printf("val->type = %s\n", nodetype2str(val->type)); - if (var->var_array == NULL) { - if (var->type != Node_var_array) { - unref(var->var_value); - var->type = Node_var_array; - } - var->array_size = var->table_size = 0; /* sanity */ - var->flags &= ~ARRAYMAXED; - } assoc_clear(var); elemval = assoc_lookup(var, sub, 0); diff -urN gawk-3.1.2/extension/filefuncs.c gawk-3.1.3/extension/filefuncs.c --- gawk-3.1.2/extension/filefuncs.c 2001-01-21 07:51:53.000000000 -0800 +++ gawk-3.1.3/extension/filefuncs.c 2003-07-01 09:07:18.000000000 -0700 @@ -189,6 +189,8 @@ file = get_argument(tree, 0); array = get_argument(tree, 1); + array = get_array(array); + /* empty out the array */ assoc_clear(array); diff -urN gawk-3.1.2/extension/pcext.def gawk-3.1.3/extension/pcext.def --- gawk-3.1.2/extension/pcext.def 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/extension/pcext.def 2003-03-20 23:32:18.000000000 -0800 @@ -0,0 +1,2 @@ +EXPORTS +dlload @1 diff -urN gawk-3.1.2/extension/readfile.c gawk-3.1.3/extension/readfile.c --- gawk-3.1.2/extension/readfile.c 2002-04-28 07:00:22.000000000 -0700 +++ gawk-3.1.3/extension/readfile.c 2003-06-09 07:05:38.000000000 -0700 @@ -3,10 +3,12 @@ * * Arnold Robbins * Tue Apr 23 17:43:30 IDT 2002 + * Revised per Peter Tillier + * Mon Jun 9 17:05:11 IDT 2003 */ /* - * Copyright (C) 2002 the Free Software Foundation, Inc. + * Copyright (C) 2002, 2003 the Free Software Foundation, Inc. * * This file is part of GAWK, the GNU implementation of the * AWK Programming Language. @@ -29,6 +31,10 @@ #include "awk.h" #include +#ifndef O_BINARY +#define O_BINARY 0 +#endif + /* do_readfile --- read a file into memory */ NODE * @@ -61,7 +67,7 @@ goto done; } - if ((fd = open(filename->stptr, O_RDONLY)) < 0) { + if ((fd = open(filename->stptr, O_RDONLY|O_BINARY)) < 0) { ret = -1; update_ERRNO(); free_temp(filename); diff -urN gawk-3.1.2/field.c gawk-3.1.3/field.c --- gawk-3.1.2/field.c 2003-02-25 03:27:06.000000000 -0800 +++ gawk-3.1.3/field.c 2003-06-15 09:52:46.000000000 -0700 @@ -63,7 +63,7 @@ Regexp *FS_re_yes_case = NULL; Regexp *FS_re_no_case = NULL; Regexp *FS_regexp = NULL; -static NODE *Null_field = NULL; +NODE *Null_field = NULL; /* using_FIELDWIDTHS --- static function, macro to avoid overhead */ #define using_FIELDWIDTHS() (parse_field == fw_parse_field) @@ -73,19 +73,13 @@ void init_fields() { - NODE *n; - emalloc(fields_arr, NODE **, sizeof(NODE *), "init_fields"); - getnode(n); - *n = *Nnull_string; - n->flags |= (SCALAR|FIELD); - n->flags &= ~PERM; - fields_arr[0] = n; + fields_arr[0] = Nnull_string; parse_extent = fields_arr[0]->stptr; save_FS = dupnode(FS_node->var_value); getnode(Null_field); *Null_field = *Nnull_string; - Null_field->flags |= (SCALAR|FIELD); + Null_field->flags |= FIELD; Null_field->flags &= ~(NUMCUR|NUMBER|MAYBE_NUM|PERM); field0_valid = TRUE; } @@ -123,7 +117,7 @@ n = fields_arr[num]; n->stptr = str; n->stlen = len; - n->flags = (STRCUR|STRING|MAYBE_NUM|SCALAR|FIELD); + n->flags = (STRCUR|STRING|MAYBE_NUM|FIELD); } /* rebuild_record --- Someone assigned a value to $(something). @@ -267,7 +261,7 @@ n->stref = 1; n->type = Node_val; n->stfmt = -1; - n->flags = (STRING|STRCUR|MAYBE_NUM|SCALAR|FIELD); + n->flags = (STRING|STRCUR|MAYBE_NUM|FIELD); fields_arr[0] = n; #undef INITIAL_SIZE @@ -809,17 +803,11 @@ src = force_string(tree_eval(tree->lnode)); - arr = tree->rnode->lnode; - - if (arr->type == Node_param_list) - arr = stack_ptr[arr->param_cnt]; - if (arr->type == Node_array_ref) - arr = arr->orig_array; - if (arr->type != Node_var && arr->type != Node_var_array) + arr = get_param(tree->rnode->lnode); + if (arr->type != Node_var_array) fatal(_("split: second argument is not an array")); - arr->type = Node_var_array; - sep = tree->rnode->rnode->lnode; /* 3rd arg */ + sep = tree->rnode->rnode->lnode; if (src->stlen == 0) { /* @@ -832,7 +820,7 @@ if ((sep->re_flags & (FS_DFLT|CONST)) == 0) free_temp(tree_eval(sep->re_exp)); /* - * And now you can safely turn off the array. + * And now we can safely turn off the array. */ assoc_clear(arr); return tmp_number((AWKNUM) 0); diff -urN gawk-3.1.2/fixvers gawk-3.1.3/fixvers --- gawk-3.1.2/fixvers 2002-10-29 00:50:47.000000000 -0800 +++ gawk-3.1.3/fixvers 2003-05-19 04:58:41.000000000 -0700 @@ -1,7 +1,7 @@ #! /bin/sh # fixvers --- make sure version.c and patchlev.h reflect -# the reality in configure.in +# the reality in configure.ac # # Copyright (C) 2001, 2002 the Free Software Foundation, Inc. # @@ -22,7 +22,7 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA -line=`grep '^AM_INIT_AUTOMAKE' configure.in` +line=`grep '^AM_INIT_AUTOMAKE' configure.ac` case $1 in -v) diff -urN gawk-3.1.2/intl/ChangeLog gawk-3.1.3/intl/ChangeLog --- gawk-3.1.2/intl/ChangeLog 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/ChangeLog 2003-06-16 03:25:33.000000000 -0700 @@ -1,4 +1,4 @@ -2002-08-06 GNU +2003-05-22 GNU - * Version 0.11.5 released. + * Version 0.12.1 released. diff -urN gawk-3.1.2/intl/Makefile.in gawk-3.1.3/intl/Makefile.in --- gawk-3.1.2/intl/Makefile.in 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/Makefile.in 2003-06-16 03:25:33.000000000 -0700 @@ -1,5 +1,5 @@ -# Makefile for directory with message catalog handling in GNU NLS Utilities. -# Copyright (C) 1995-1998, 2000-2002 Free Software Foundation, Inc. +# Makefile for directory with message catalog handling library of GNU gettext +# Copyright (C) 1995-1998, 2000-2003 Free Software Foundation, Inc. # # This program is free software; you can redistribute it and/or modify it # under the terms of the GNU Library General Public License as published @@ -24,7 +24,7 @@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = .. -VPATH = @srcdir@ +VPATH = $(srcdir) prefix = @prefix@ exec_prefix = @exec_prefix@ @@ -40,7 +40,7 @@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ MKINSTALLDIRS = @MKINSTALLDIRS@ -mkinstalldirs = $(SHELL) `case "$(MKINSTALLDIRS)" in /*) echo "$(MKINSTALLDIRS)" ;; *) echo "$(top_builddir)/$(MKINSTALLDIRS)" ;; esac` +mkinstalldirs = $(SHELL) $(MKINSTALLDIRS) l = @INTL_LIBTOOL_SUFFIX_PREFIX@ @@ -52,90 +52,189 @@ YFLAGS = --name-prefix=__gettext DEFS = -DLOCALEDIR=\"$(localedir)\" -DLOCALE_ALIAS_PATH=\"$(aliaspath)\" \ --DLIBDIR=\"$(libdir)\" -DIN_LIBINTL @DEFS@ +-DLIBDIR=\"$(libdir)\" -DIN_LIBINTL \ +-DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"$(libdir)\" -DNO_XMALLOC \ +-Dset_relocation_prefix=libintl_set_relocation_prefix \ +-Drelocate=libintl_relocate \ +-DDEPENDS_ON_LIBICONV=1 @DEFS@ CPPFLAGS = @CPPFLAGS@ CFLAGS = @CFLAGS@ LDFLAGS = @LDFLAGS@ +LIBS = @LIBS@ COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) $(XCFLAGS) -HEADERS = $(COMHDRS) libgnuintl.h loadinfo.h -COMHDRS = gmo.h gettextP.h hash-string.h plural-exp.h eval-plural.h os2compat.h -SOURCES = $(COMSRCS) intl-compat.c -COMSRCS = bindtextdom.c dcgettext.c dgettext.c gettext.c \ -finddomain.c loadmsgcat.c localealias.c textdomain.c l10nflist.c \ -explodename.c dcigettext.c dcngettext.c dngettext.c ngettext.c plural.y \ -plural-exp.c localcharset.c localename.c osdep.c os2compat.c -OBJECTS = @INTLOBJS@ bindtextdom.$lo dcgettext.$lo dgettext.$lo gettext.$lo \ -finddomain.$lo loadmsgcat.$lo localealias.$lo textdomain.$lo l10nflist.$lo \ -explodename.$lo dcigettext.$lo dcngettext.$lo dngettext.$lo ngettext.$lo \ -plural.$lo plural-exp.$lo localcharset.$lo localename.$lo osdep.$lo -GETTOBJS = intl-compat.$lo +HEADERS = \ + gmo.h \ + gettextP.h \ + hash-string.h \ + loadinfo.h \ + plural-exp.h \ + eval-plural.h \ + localcharset.h \ + relocatable.h \ + os2compat.h \ + libgnuintl.h.in +SOURCES = \ + bindtextdom.c \ + dcgettext.c \ + dgettext.c \ + gettext.c \ + finddomain.c \ + loadmsgcat.c \ + localealias.c \ + textdomain.c \ + l10nflist.c \ + explodename.c \ + dcigettext.c \ + dcngettext.c \ + dngettext.c \ + ngettext.c \ + plural.y \ + plural-exp.c \ + localcharset.c \ + relocatable.c \ + localename.c \ + log.c \ + osdep.c \ + os2compat.c \ + intl-compat.c +OBJECTS = \ + bindtextdom.$lo \ + dcgettext.$lo \ + dgettext.$lo \ + gettext.$lo \ + finddomain.$lo \ + loadmsgcat.$lo \ + localealias.$lo \ + textdomain.$lo \ + l10nflist.$lo \ + explodename.$lo \ + dcigettext.$lo \ + dcngettext.$lo \ + dngettext.$lo \ + ngettext.$lo \ + plural.$lo \ + plural-exp.$lo \ + localcharset.$lo \ + relocatable.$lo \ + localename.$lo \ + log.$lo \ + osdep.$lo \ + intl-compat.$lo DISTFILES.common = Makefile.in \ config.charset locale.alias ref-add.sin ref-del.sin $(HEADERS) $(SOURCES) DISTFILES.generated = plural.c DISTFILES.normal = VERSION -DISTFILES.gettext = COPYING.LIB-2.0 COPYING.LIB-2.1 libintl.glibc +DISTFILES.gettext = COPYING.LIB-2.0 COPYING.LIB-2.1 libintl.glibc \ +Makefile.vms libgnuintl.h.msvc-shared README.woe32 Makefile.msvc DISTFILES.obsolete = xopen-msg.sed linux-msg.sed po2tbl.sed.in cat-compat.c \ -COPYING.LIB-2 gettext.h libgettext.h plural-eval.c +COPYING.LIB-2 gettext.h libgettext.h plural-eval.c libgnuintl.h + +all: all-@USE_INCLUDED_LIBINTL@ +all-yes: libintl.$la libintl.h charset.alias ref-add.sed ref-del.sed +all-no: all-no-@BUILD_INCLUDED_LIBINTL@ +all-no-yes: libgnuintl.$la +all-no-no: + +libintl.a libgnuintl.a: $(OBJECTS) + rm -f $@ + $(AR) cru $@ $(OBJECTS) + $(RANLIB) $@ + +libintl.la libgnuintl.la: $(OBJECTS) + $(LIBTOOL) --mode=link \ + $(CC) $(CPPFLAGS) $(CFLAGS) $(XCFLAGS) $(LDFLAGS) -o $@ \ + $(OBJECTS) @LTLIBICONV@ $(LIBS) -lc \ + -version-info $(LTV_CURRENT):$(LTV_REVISION):$(LTV_AGE) \ + -rpath $(libdir) \ + -no-undefined # Libtool's library version information for libintl. # Before making a gettext release, the gettext maintainer must change this # according to the libtool documentation, section "Library interface versions". # Maintainers of other packages that include the intl directory must *not* # change these values. -LTV_CURRENT=4 +LTV_CURRENT=5 LTV_REVISION=0 -LTV_AGE=2 +LTV_AGE=3 .SUFFIXES: .SUFFIXES: .c .y .o .lo .sin .sed + .c.o: $(COMPILE) $< -.c.lo: - $(LIBTOOL) --mode=compile $(COMPILE) $< .y.c: $(YACC) $(YFLAGS) --output $@ $< rm -f $*.h -.sin.sed: - sed -e '/^#/d' -e 's/@''PACKAGE''@/@PACKAGE@/g' $< > t-$@ - mv t-$@ $@ - -INCLUDES = -I.. -I. -I$(top_srcdir)/intl +bindtextdom.lo: $(srcdir)/bindtextdom.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/bindtextdom.c +dcgettext.lo: $(srcdir)/dcgettext.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/dcgettext.c +dgettext.lo: $(srcdir)/dgettext.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/dgettext.c +gettext.lo: $(srcdir)/gettext.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/gettext.c +finddomain.lo: $(srcdir)/finddomain.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/finddomain.c +loadmsgcat.lo: $(srcdir)/loadmsgcat.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/loadmsgcat.c +localealias.lo: $(srcdir)/localealias.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/localealias.c +textdomain.lo: $(srcdir)/textdomain.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/textdomain.c +l10nflist.lo: $(srcdir)/l10nflist.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/l10nflist.c +explodename.lo: $(srcdir)/explodename.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/explodename.c +dcigettext.lo: $(srcdir)/dcigettext.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/dcigettext.c +dcngettext.lo: $(srcdir)/dcngettext.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/dcngettext.c +dngettext.lo: $(srcdir)/dngettext.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/dngettext.c +ngettext.lo: $(srcdir)/ngettext.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/ngettext.c +plural.lo: $(srcdir)/plural.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/plural.c +plural-exp.lo: $(srcdir)/plural-exp.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/plural-exp.c +localcharset.lo: $(srcdir)/localcharset.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/localcharset.c +relocatable.lo: $(srcdir)/relocatable.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/relocatable.c +localename.lo: $(srcdir)/localename.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/localename.c +log.lo: $(srcdir)/log.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/log.c +osdep.lo: $(srcdir)/osdep.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/osdep.c +intl-compat.lo: $(srcdir)/intl-compat.c + $(LIBTOOL) --mode=compile $(COMPILE) $(srcdir)/intl-compat.c + +ref-add.sed: $(srcdir)/ref-add.sin + sed -e '/^#/d' -e 's/@''PACKAGE''@/@PACKAGE@/g' $(srcdir)/ref-add.sin > t-ref-add.sed + mv t-ref-add.sed ref-add.sed +ref-del.sed: $(srcdir)/ref-del.sin + sed -e '/^#/d' -e 's/@''PACKAGE''@/@PACKAGE@/g' $(srcdir)/ref-del.sin > t-ref-del.sed + mv t-ref-del.sed ref-del.sed -all: all-@USE_INCLUDED_LIBINTL@ -all-yes: libintl.$la libintl.h charset.alias ref-add.sed ref-del.sed -all-no: all-no-@BUILD_INCLUDED_LIBINTL@ -all-no-yes: libgnuintl.$la -all-no-no: - -libintl.a libgnuintl.a: $(OBJECTS) - rm -f $@ - $(AR) cru $@ $(OBJECTS) - $(RANLIB) $@ +INCLUDES = -I. -I$(srcdir) -I.. -libintl.la libgnuintl.la: $(OBJECTS) - $(LIBTOOL) --mode=link \ - $(CC) $(CPPFLAGS) $(CFLAGS) $(XCFLAGS) $(LDFLAGS) -o $@ \ - $(OBJECTS) @LTLIBICONV@ -lc \ - -version-info $(LTV_CURRENT):$(LTV_REVISION):$(LTV_AGE) \ - -rpath $(libdir) \ - -no-undefined +libgnuintl.h: $(srcdir)/libgnuintl.h.in + cp $(srcdir)/libgnuintl.h.in libgnuintl.h libintl.h: libgnuintl.h - cp $(srcdir)/libgnuintl.h libintl.h + cp libgnuintl.h libintl.h -charset.alias: config.charset +charset.alias: $(srcdir)/config.charset $(SHELL) $(srcdir)/config.charset '@host@' > t-$@ mv t-$@ $@ check: all -# This installation goal is only used in GNU gettext. Packages which -# only use the library should use install instead. - # We must not install the libintl.h/libintl.a files if we are on a # system which has the GNU gettext() function in its C library or in a # separate library. @@ -143,12 +242,30 @@ # package, you have to use `configure --with-included-gettext'. install: install-exec install-data install-exec: all - if test "$(PACKAGE)" = "gettext" \ - && test '@INTLOBJS@' = '$(GETTOBJS)'; then \ + if { test "$(PACKAGE)" = "gettext-runtime" || test "$(PACKAGE)" = "gettext-tools"; } \ + && test '@USE_INCLUDED_LIBINTL@' = yes; then \ $(mkinstalldirs) $(DESTDIR)$(libdir) $(DESTDIR)$(includedir); \ $(INSTALL_DATA) libintl.h $(DESTDIR)$(includedir)/libintl.h; \ $(LIBTOOL) --mode=install \ $(INSTALL_DATA) libintl.$la $(DESTDIR)$(libdir)/libintl.$la; \ + if test "@RELOCATABLE@" = yes; then \ + dependencies=`sed -n -e 's,^dependency_libs=\(.*\),\1,p' < $(DESTDIR)$(libdir)/libintl.la | sed -e "s,^',," -e "s,'\$$,,"`; \ + if test -n "$dependencies"; then \ + rm -f $(DESTDIR)$(libdir)/libintl.la; \ + fi; \ + fi; \ + else \ + : ; \ + fi + if test "$(PACKAGE)" = "gettext-tools" \ + && test '@USE_INCLUDED_LIBINTL@' = no; then \ + $(mkinstalldirs) $(DESTDIR)$(libdir); \ + $(LIBTOOL) --mode=install \ + $(INSTALL_DATA) libgnuintl.$la $(DESTDIR)$(libdir)/libgnuintl.$la; \ + rm -f $(DESTDIR)$(libdir)/preloadable_libintl.so; \ + $(INSTALL_DATA) $(DESTDIR)$(libdir)/libgnuintl.so $(DESTDIR)$(libdir)/preloadable_libintl.so; \ + $(LIBTOOL) --mode=uninstall \ + rm -f $(DESTDIR)$(libdir)/libgnuintl.$la; \ else \ : ; \ fi @@ -182,7 +299,7 @@ : ; \ fi install-data: all - if test "$(PACKAGE)" = "gettext"; then \ + if test "$(PACKAGE)" = "gettext-tools"; then \ $(mkinstalldirs) $(DESTDIR)$(gettextsrcdir); \ $(INSTALL_DATA) VERSION $(DESTDIR)$(gettextsrcdir)/VERSION; \ $(INSTALL_DATA) ChangeLog.inst $(DESTDIR)$(gettextsrcdir)/ChangeLog; \ @@ -209,19 +326,25 @@ install-strip: install installdirs: - if test "$(PACKAGE)" = "gettext" \ - && test '@INTLOBJS@' = '$(GETTOBJS)'; then \ + if { test "$(PACKAGE)" = "gettext-runtime" || test "$(PACKAGE)" = "gettext-tools"; } \ + && test '@USE_INCLUDED_LIBINTL@' = yes; then \ $(mkinstalldirs) $(DESTDIR)$(libdir) $(DESTDIR)$(includedir); \ else \ : ; \ fi + if test "$(PACKAGE)" = "gettext-tools" \ + && test '@USE_INCLUDED_LIBINTL@' = no; then \ + $(mkinstalldirs) $(DESTDIR)$(libdir); \ + else \ + : ; \ + fi if test '@USE_INCLUDED_LIBINTL@' = yes; then \ test @GLIBC21@ != no || $(mkinstalldirs) $(DESTDIR)$(libdir); \ $(mkinstalldirs) $(DESTDIR)$(localedir); \ else \ : ; \ fi - if test "$(PACKAGE)" = "gettext"; then \ + if test "$(PACKAGE)" = "gettext-tools"; then \ $(mkinstalldirs) $(DESTDIR)$(gettextsrcdir); \ else \ : ; \ @@ -231,14 +354,20 @@ installcheck: uninstall: - if test "$(PACKAGE)" = "gettext" \ - && test '@INTLOBJS@' = '$(GETTOBJS)'; then \ + if { test "$(PACKAGE)" = "gettext-runtime" || test "$(PACKAGE)" = "gettext-tools"; } \ + && test '@USE_INCLUDED_LIBINTL@' = yes; then \ rm -f $(DESTDIR)$(includedir)/libintl.h; \ $(LIBTOOL) --mode=uninstall \ rm -f $(DESTDIR)$(libdir)/libintl.$la; \ else \ : ; \ fi + if test "$(PACKAGE)" = "gettext-tools" \ + && test '@USE_INCLUDED_LIBINTL@' = no; then \ + rm -f $(DESTDIR)$(libdir)/preloadable_libintl.so; \ + else \ + : ; \ + fi if test '@USE_INCLUDED_LIBINTL@' = yes; then \ if test -f $(DESTDIR)$(libdir)/charset.alias; then \ temp=$(DESTDIR)$(libdir)/t-charset.alias; \ @@ -265,7 +394,7 @@ else \ : ; \ fi - if test "$(PACKAGE)" = "gettext"; then \ + if test "$(PACKAGE)" = "gettext-tools"; then \ for file in VERSION ChangeLog COPYING.LIB-2.0 COPYING.LIB-2.1 $(DISTFILES.common) $(DISTFILES.generated); do \ rm -f $(DESTDIR)$(gettextsrcdir)/$$file; \ done; \ @@ -273,20 +402,27 @@ : ; \ fi -info dvi: +info dvi ps pdf html: $(OBJECTS): ../config.h libgnuintl.h -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: gettextP.h gmo.h loadinfo.h -dcigettext.$lo: hash-string.h -explodename.$lo l10nflist.$lo: loadinfo.h -dcigettext.$lo loadmsgcat.$lo plural.$lo plural-exp.$lo: plural-exp.h -dcigettext.$lo: eval-plural.h +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 +dcigettext.$lo loadmsgcat.$lo: $(srcdir)/hash-string.h +explodename.$lo l10nflist.$lo: $(srcdir)/loadinfo.h +dcigettext.$lo loadmsgcat.$lo plural.$lo plural-exp.$lo: $(srcdir)/plural-exp.h +dcigettext.$lo: $(srcdir)/eval-plural.h +localcharset.$lo: $(srcdir)/localcharset.h +localealias.$lo localcharset.$lo relocatable.$lo: $(srcdir)/relocatable.h tags: TAGS TAGS: $(HEADERS) $(SOURCES) here=`pwd`; cd $(srcdir) && etags -o $$here/TAGS $(HEADERS) $(SOURCES) +ctags: CTAGS + +CTAGS: $(HEADERS) $(SOURCES) + here=`pwd`; cd $(srcdir) && ctags -o $$here/CTAGS $(HEADERS) $(SOURCES) + id: ID ID: $(HEADERS) $(SOURCES) @@ -294,15 +430,15 @@ mostlyclean: - rm -f *.a *.la *.o *.lo core core.* - rm -f libintl.h charset.alias ref-add.sed ref-del.sed + rm -f *.a *.la *.o *.obj *.lo core core.* + rm -f libgnuintl.h libintl.h charset.alias ref-add.sed ref-del.sed rm -f -r .libs _libs clean: mostlyclean distclean: clean rm -f Makefile ID TAGS - if test "$(PACKAGE)" = gettext; then \ + if test "$(PACKAGE)" = "gettext-runtime" || test "$(PACKAGE)" = "gettext-tools"; then \ rm -f ChangeLog.inst $(DISTFILES.normal); \ else \ : ; \ @@ -317,20 +453,26 @@ # other files which should not be distributed in other packages. distdir = ../$(PACKAGE)-$(VERSION)/$(subdir) dist distdir: Makefile - if test "$(PACKAGE)" = gettext; then \ - additional="$(DISTFILES.gettext)"; \ + if test "$(PACKAGE)" = "gettext-tools"; then \ + : ; \ else \ - additional="$(DISTFILES.normal)"; \ - fi; \ - $(MAKE) $(DISTFILES.common) $(DISTFILES.generated) $$additional; \ - for file in ChangeLog $(DISTFILES.common) $(DISTFILES.generated) $$additional; do \ - if test -f $$file; then dir=.; else dir=$(srcdir); fi; \ - cp -p $$dir/$$file $(distdir); \ - done - -Makefile: Makefile.in ../config.status - cd .. \ - && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status + if test "$(PACKAGE)" = "gettext-runtime"; then \ + additional="$(DISTFILES.gettext)"; \ + else \ + additional="$(DISTFILES.normal)"; \ + fi; \ + $(MAKE) $(DISTFILES.common) $(DISTFILES.generated) $$additional; \ + for file in ChangeLog $(DISTFILES.common) $(DISTFILES.generated) $$additional; do \ + if test -f $$file; then dir=.; else dir=$(srcdir); fi; \ + cp -p $$dir/$$file $(distdir); \ + done; \ + fi + +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + cd $(top_builddir) && $(SHELL) ./config.status +# This would be more efficient, but doesn't work any more with autoconf-2.57, +# when AC_CONFIG_FILES([intl/Makefile:somedir/Makefile.in]) is used. +# cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status # Tell versions [3.59,3.63) of GNU make not to export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff -urN gawk-3.1.2/intl/VERSION gawk-3.1.3/intl/VERSION --- gawk-3.1.2/intl/VERSION 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/VERSION 2003-06-16 03:25:33.000000000 -0700 @@ -1 +1 @@ -GNU gettext library from gettext-0.11.5 +GNU gettext library from gettext-0.12.1 diff -urN gawk-3.1.2/intl/bindtextdom.c gawk-3.1.3/intl/bindtextdom.c --- gawk-3.1.2/intl/bindtextdom.c 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/bindtextdom.c 2003-06-16 03:25:33.000000000 -0700 @@ -58,6 +58,11 @@ /* Contains the default location of the message catalogs. */ extern const char _nl_default_dirname[]; +#ifdef _LIBC +extern const char _nl_default_dirname_internal[] attribute_hidden; +#else +# define INTUSE(name) name +#endif /* List with bindings of specific domains. */ extern struct binding *_nl_domain_bindings; @@ -146,8 +151,8 @@ char *result = binding->dirname; if (strcmp (dirname, result) != 0) { - if (strcmp (dirname, _nl_default_dirname) == 0) - result = (char *) _nl_default_dirname; + if (strcmp (dirname, INTUSE(_nl_default_dirname)) == 0) + result = (char *) INTUSE(_nl_default_dirname); else { #if defined _LIBC || defined HAVE_STRDUP @@ -162,7 +167,7 @@ if (__builtin_expect (result != NULL, 1)) { - if (binding->dirname != _nl_default_dirname) + if (binding->dirname != INTUSE(_nl_default_dirname)) free (binding->dirname); binding->dirname = result; @@ -216,7 +221,7 @@ { /* Simply return the default values. */ if (dirnamep) - *dirnamep = _nl_default_dirname; + *dirnamep = INTUSE(_nl_default_dirname); if (codesetp) *codesetp = NULL; } @@ -238,11 +243,11 @@ if (dirname == NULL) /* The default value. */ - dirname = _nl_default_dirname; + dirname = INTUSE(_nl_default_dirname); else { - if (strcmp (dirname, _nl_default_dirname) == 0) - dirname = _nl_default_dirname; + if (strcmp (dirname, INTUSE(_nl_default_dirname)) == 0) + dirname = INTUSE(_nl_default_dirname); else { char *result; @@ -265,7 +270,7 @@ } else /* The default value. */ - new_binding->dirname = (char *) _nl_default_dirname; + new_binding->dirname = (char *) INTUSE(_nl_default_dirname); new_binding->codeset_cntr = 0; @@ -321,7 +326,7 @@ if (0) { failed_codeset: - if (new_binding->dirname != _nl_default_dirname) + if (new_binding->dirname != INTUSE(_nl_default_dirname)) free (new_binding->dirname); failed_dirname: free (new_binding); diff -urN gawk-3.1.2/intl/config.charset gawk-3.1.3/intl/config.charset --- gawk-3.1.2/intl/config.charset 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/config.charset 2003-06-16 03:25:33.000000000 -0700 @@ -1,7 +1,7 @@ #! /bin/sh # Output a system dependent table of character encoding aliases. # -# Copyright (C) 2000-2002 Free Software Foundation, Inc. +# Copyright (C) 2000-2003 Free Software Foundation, Inc. # # This program is free software; you can redistribute it and/or modify it # under the terms of the GNU Library General Public License as published @@ -71,7 +71,7 @@ # CP1125 dos # CP1129 aix # CP1250 woe32 -# CP1251 glibc woe32 +# CP1251 glibc solaris woe32 # CP1252 aix woe32 # CP1253 woe32 # CP1254 woe32 @@ -231,6 +231,7 @@ echo "ISO8859-9 ISO-8859-9" echo "ISO8859-15 ISO-8859-15" echo "koi8-r KOI8-R" + echo "ansi-1251 CP1251" echo "BIG5 BIG5" echo "Big5-HKSCS BIG5-HKSCS" echo "gb2312 GB2312" diff -urN gawk-3.1.2/intl/dcigettext.c gawk-3.1.3/intl/dcigettext.c --- gawk-3.1.2/intl/dcigettext.c 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/dcigettext.c 2003-06-16 03:25:33.000000000 -0700 @@ -1,5 +1,5 @@ /* Implementation of the internal dcigettext function. - Copyright (C) 1995-1999, 2000-2002 Free Software Foundation, Inc. + Copyright (C) 1995-1999, 2000-2003 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published @@ -33,14 +33,19 @@ # define alloca __builtin_alloca # define HAVE_ALLOCA 1 #else -# if defined HAVE_ALLOCA_H || defined _LIBC -# include +# ifdef _MSC_VER +# include +# define alloca _alloca # else -# ifdef _AIX - #pragma alloca +# if defined HAVE_ALLOCA_H || defined _LIBC +# include # else -# ifndef alloca +# ifdef _AIX + #pragma alloca +# else +# ifndef alloca char *alloca (); +# endif # endif # endif # endif @@ -271,6 +276,13 @@ } #endif +#ifndef INTVARDEF +# define INTVARDEF(name) +#endif +#ifndef INTUSE +# define INTUSE(name) name +#endif + /* Name of the default domain used for gettext(3) prior any call to textdomain(3). The default value for this is "messages". */ const char _nl_default_default_domain[] attribute_hidden = "messages"; @@ -284,6 +296,7 @@ extern const char _nl_default_dirname[]; #else const char _nl_default_dirname[] = LOCALEDIR; +INTVARDEF (_nl_default_dirname) #endif /* List with bindings of specific domains created by bindtextdomain() @@ -296,10 +309,15 @@ const char *translation, size_t translation_len)) internal_function; -static const char *category_to_name PARAMS ((int category)) internal_function; static const char *guess_category_value PARAMS ((int category, const char *categoryname)) internal_function; +#ifdef _LIBC +# include "../locale/localeinfo.h" +# define category_to_name(category) _nl_category_names[category] +#else +static const char *category_to_name PARAMS ((int category)) internal_function; +#endif /* For those loosing systems which don't have `alloca' we have to add @@ -437,6 +455,15 @@ if (msgid1 == NULL) return NULL; +#ifdef _LIBC + if (category < 0 || category >= __LC_LAST || category == LC_ALL) + /* Bogus. */ + return (plural == 0 + ? (char *) msgid1 + /* Use the Germanic plural rule. */ + : n == 1 ? (char *) msgid1 : (char *) msgid2); +#endif + __libc_rwlock_rdlock (_nl_state_lock); /* If DOMAINNAME is NULL, we are interested in the default domain. If @@ -500,7 +527,7 @@ } if (binding == NULL) - dirname = (char *) _nl_default_dirname; + dirname = (char *) INTUSE(_nl_default_dirname); else if (IS_ABSOLUTE_PATH (binding->dirname)) dirname = binding->dirname; else @@ -528,17 +555,9 @@ } if (ret == NULL) - { - /* We cannot get the current working directory. Don't signal an - error but simply return the default string. */ - FREE_BLOCKS (block_list); - __libc_rwlock_unlock (_nl_state_lock); - __set_errno (saved_errno); - return (plural == 0 - ? (char *) msgid1 - /* Use the Germanic plural rule. */ - : n == 1 ? (char *) msgid1 : (char *) msgid2); - } + /* We cannot get the current working directory. Don't signal an + error but simply return the default string. */ + goto return_untranslated; stpcpy (stpcpy (strchr (dirname, '\0'), "/"), binding->dirname); } @@ -595,16 +614,7 @@ domain. Return the MSGID. */ if (strcmp (single_locale, "C") == 0 || strcmp (single_locale, "POSIX") == 0) - { - FREE_BLOCKS (block_list); - __libc_rwlock_unlock (_nl_state_lock); - __set_errno (saved_errno); - return (plural == 0 - ? (char *) msgid1 - /* Use the Germanic plural rule. */ - : n == 1 ? (char *) msgid1 : (char *) msgid2); - } - + break; /* Find structure describing the message catalog matching the DOMAINNAME and CATEGORY. */ @@ -636,7 +646,6 @@ /* Found the translation of MSGID1 in domain DOMAIN: starting at RETVAL, RETLEN bytes. */ FREE_BLOCKS (block_list); - __set_errno (saved_errno); #if defined HAVE_TSEARCH || defined _LIBC if (foundp == NULL) { @@ -675,6 +684,8 @@ (*foundp)->translation_length = retlen; } #endif + __set_errno (saved_errno); + /* Now deal with plural. */ if (plural) retval = plural_lookup (domain, n, retval, retlen); @@ -684,7 +695,30 @@ } } } - /* NOTREACHED */ + + return_untranslated: + /* Return the untranslated MSGID. */ + FREE_BLOCKS (block_list); + __libc_rwlock_unlock (_nl_state_lock); +#ifndef _LIBC + if (!ENABLE_SECURE) + { + extern void _nl_log_untranslated PARAMS ((const char *logfilename, + const char *domainname, + const char *msgid1, + const char *msgid2, + int plural)); + const char *logfilename = getenv ("GETTEXT_LOG_UNTRANSLATED"); + + if (logfilename != NULL && logfilename[0] != '\0') + _nl_log_untranslated (logfilename, domainname, msgid1, msgid2, plural); + } +#endif + __set_errno (saved_errno); + return (plural == 0 + ? (char *) msgid1 + /* Use the Germanic plural rule. */ + : n == 1 ? (char *) msgid1 : (char *) msgid2); } @@ -1038,7 +1072,7 @@ return (char *) p; } - +#ifndef _LIBC /* Return string representation of locale CATEGORY. */ static const char * internal_function @@ -1098,6 +1132,7 @@ return retval; } +#endif /* Guess value of current locale from value of the environment variables. */ static const char * @@ -1120,7 +1155,7 @@ `LC_xxx', and `LANG'. On some systems this can be done by the `setlocale' function itself. */ #ifdef _LIBC - retval = setlocale (category, NULL); + retval = __current_locale_name (category); #else retval = _nl_locale_name (category, categoryname); #endif @@ -1170,8 +1205,7 @@ #ifdef _LIBC /* If we want to free all resources we have to do some work at program's end. */ -static void __attribute__ ((unused)) -free_mem (void) +libc_freeres_fn (free_mem) { void *old; @@ -1179,7 +1213,7 @@ { struct binding *oldp = _nl_domain_bindings; _nl_domain_bindings = _nl_domain_bindings->next; - if (oldp->dirname != _nl_default_dirname) + if (oldp->dirname != INTUSE(_nl_default_dirname)) /* Yes, this is a pointer comparison. */ free (oldp->dirname); free (oldp->codeset); @@ -1201,6 +1235,4 @@ free (old); } } - -text_set_element (__libc_subfreeres, free_mem); #endif diff -urN gawk-3.1.2/intl/dcngettext.c gawk-3.1.3/intl/dcngettext.c --- gawk-3.1.2/intl/dcngettext.c 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/dcngettext.c 2003-06-16 03:25:33.000000000 -0700 @@ -56,6 +56,5 @@ #ifdef _LIBC /* Alias for function name in GNU C Library. */ -INTDEF(__dcngettext) weak_alias (__dcngettext, dcngettext); #endif diff -urN gawk-3.1.2/intl/dngettext.c gawk-3.1.3/intl/dngettext.c --- gawk-3.1.2/intl/dngettext.c 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/dngettext.c 2003-06-16 03:25:33.000000000 -0700 @@ -37,7 +37,7 @@ prefix. So we have to make a difference here. */ #ifdef _LIBC # define DNGETTEXT __dngettext -# define DCNGETTEXT INTUSE(__dcngettext) +# define DCNGETTEXT __dcngettext #else # define DNGETTEXT libintl_dngettext # define DCNGETTEXT libintl_dcngettext diff -urN gawk-3.1.2/intl/finddomain.c gawk-3.1.3/intl/finddomain.c --- gawk-3.1.2/intl/finddomain.c 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/finddomain.c 2003-06-16 03:25:33.000000000 -0700 @@ -178,8 +178,7 @@ #ifdef _LIBC -static void __attribute__ ((unused)) -free_mem (void) +libc_freeres_fn (free_mem) { struct loaded_l10nfile *runp = _nl_loaded_domains; @@ -193,6 +192,4 @@ free (here); } } - -text_set_element (__libc_subfreeres, free_mem); #endif diff -urN gawk-3.1.2/intl/gettextP.h gawk-3.1.3/intl/gettextP.h --- gawk-3.1.2/intl/gettextP.h 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/gettextP.h 2003-06-16 03:25:33.000000000 -0700 @@ -1,5 +1,5 @@ /* Header describing internals of libintl library. - Copyright (C) 1995-1999, 2000-2002 Free Software Foundation, Inc. + Copyright (C) 1995-1999, 2000-2003 Free Software Foundation, Inc. Written by Ulrich Drepper , 1995. This program is free software; you can redistribute it and/or modify it @@ -208,33 +208,15 @@ extern char *__bind_textdomain_codeset PARAMS ((const char *__domainname, const char *__codeset)); #else -extern char *libintl_gettext PARAMS ((const char *__msgid)); -extern char *libintl_dgettext PARAMS ((const char *__domainname, - const char *__msgid)); -extern char *libintl_dcgettext PARAMS ((const char *__domainname, - const char *__msgid, int __category)); -extern char *libintl_ngettext PARAMS ((const char *__msgid1, - const char *__msgid2, - unsigned long int __n)); -extern char *libintl_dngettext PARAMS ((const char *__domainname, - const char *__msgid1, - const char *__msgid2, - unsigned long int __n)); -extern char *libintl_dcngettext PARAMS ((const char *__domainname, - const char *__msgid1, - const char *__msgid2, - unsigned long int __n, - int __category)); +/* Declare the exported libintl_* functions, in a way that allows us to + call them under their real name. */ +# define _INTL_REDIRECT_MACROS +# include "libgnuintl.h" extern char *libintl_dcigettext PARAMS ((const char *__domainname, const char *__msgid1, const char *__msgid2, int __plural, unsigned long int __n, int __category)); -extern char *libintl_textdomain PARAMS ((const char *__domainname)); -extern char *libintl_bindtextdomain PARAMS ((const char *__domainname, - const char *__dirname)); -extern char *libintl_bind_textdomain_codeset PARAMS ((const char *__domainname, - const char *__codeset)); #endif /* @@ begin of epilog @@ */ diff -urN gawk-3.1.2/intl/intl-compat.c gawk-3.1.3/intl/intl-compat.c --- gawk-3.1.2/intl/intl-compat.c 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/intl-compat.c 2003-06-16 03:25:33.000000000 -0700 @@ -1,6 +1,6 @@ /* intl-compat.c - Stub functions to call gettext functions from GNU gettext Library. - Copyright (C) 1995, 2000-2002 Software Foundation, Inc. + Copyright (C) 1995, 2000-2003 Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published @@ -21,8 +21,6 @@ # include #endif -#define _INTL_REDIRECT_MACROS -#include "libgnuintl.h" #include "gettextP.h" /* @@ end of prolog @@ */ @@ -31,7 +29,10 @@ defined in the included GNU libintl library (with "libintl_" prefix). It is compiled into libintl in order to make the AM_GNU_GETTEXT test of gettext <= 0.11.2 work with the libintl library >= 0.11.3 which - has the redirections primarily in the include file. */ + has the redirections primarily in the include file. + It is also compiled into libgnuintl so that libgnuintl.so can be used + as LD_PRELOADable library on glibc systems, to provide the extra + features that the functions in the libc don't have (namely, logging). */ #undef gettext @@ -45,6 +46,17 @@ #undef bind_textdomain_codeset +/* When building a DLL, we must export some functions. Note that because + the functions are only defined for binary backward compatibility, we + don't need to use __declspec(dllimport) in any case. */ +#if defined _MSC_VER && BUILDING_DLL +# define DLL_EXPORTED __declspec(dllexport) +#else +# define DLL_EXPORTED +#endif + + +DLL_EXPORTED char * gettext (msgid) const char *msgid; @@ -53,6 +65,7 @@ } +DLL_EXPORTED char * dgettext (domainname, msgid) const char *domainname; @@ -62,6 +75,7 @@ } +DLL_EXPORTED char * dcgettext (domainname, msgid, category) const char *domainname; @@ -72,6 +86,7 @@ } +DLL_EXPORTED char * ngettext (msgid1, msgid2, n) const char *msgid1; @@ -82,6 +97,7 @@ } +DLL_EXPORTED char * dngettext (domainname, msgid1, msgid2, n) const char *domainname; @@ -93,6 +109,7 @@ } +DLL_EXPORTED char * dcngettext (domainname, msgid1, msgid2, n, category) const char *domainname; @@ -105,6 +122,7 @@ } +DLL_EXPORTED char * textdomain (domainname) const char *domainname; @@ -113,6 +131,7 @@ } +DLL_EXPORTED char * bindtextdomain (domainname, dirname) const char *domainname; @@ -122,6 +141,7 @@ } +DLL_EXPORTED char * bind_textdomain_codeset (domainname, codeset) const char *domainname; diff -urN gawk-3.1.2/intl/libgnuintl.h gawk-3.1.3/intl/libgnuintl.h --- gawk-3.1.2/intl/libgnuintl.h 2003-02-04 03:21:44.000000000 -0800 +++ gawk-3.1.3/intl/libgnuintl.h 1969-12-31 16:00:00.000000000 -0800 @@ -1,296 +0,0 @@ -/* Message catalogs for internationalization. - Copyright (C) 1995-1997, 2000-2002 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify it - under the terms of the GNU Library General Public License as published - by the Free Software Foundation; either version 2, or (at your option) - any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this program; if not, write to the Free Software - Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, - USA. */ - -#ifndef _LIBINTL_H -#define _LIBINTL_H 1 - -#include - -/* The LC_MESSAGES locale category is the category used by the functions - gettext() and dgettext(). It is specified in POSIX, but not in ANSI C. - On systems that don't define it, use an arbitrary value instead. - On Solaris, defines __LOCALE_H (or _LOCALE_H in Solaris 2.5) - then includes (i.e. this file!) and then only defines - LC_MESSAGES. To avoid a redefinition warning, don't define LC_MESSAGES - in this case. */ -#if !defined LC_MESSAGES && !(defined __LOCALE_H || (defined _LOCALE_H && defined __sun)) -# define LC_MESSAGES 1729 -#endif - -/* We define an additional symbol to signal that we use the GNU - implementation of gettext. */ -#define __USE_GNU_GETTEXT 1 - -/* Provide information about the supported file formats. Returns the - maximum minor revision number supported for a given major revision. */ -#define __GNU_GETTEXT_SUPPORTED_REVISION(major) \ - ((major) == 0 ? 1 : -1) - -/* Resolve a platform specific conflict on DJGPP. GNU gettext takes - precedence over _conio_gettext. */ -#ifdef __DJGPP__ -# undef gettext -#endif - -/* Use _INTL_PARAMS, not PARAMS, in order to avoid clashes with identifiers - used by programs. Similarly, test __PROTOTYPES, not PROTOTYPES. */ -#ifndef _INTL_PARAMS -# if __STDC__ || defined __GNUC__ || defined __SUNPRO_C || defined __cplusplus || __PROTOTYPES -# define _INTL_PARAMS(args) args -# else -# define _INTL_PARAMS(args) () -# endif -#endif - -#ifdef __cplusplus -extern "C" { -#endif - - -/* We redirect the functions to those prefixed with "libintl_". This is - necessary, because some systems define gettext/textdomain/... in the C - library (namely, Solaris 2.4 and newer, and GNU libc 2.0 and newer). - If we used the unprefixed names, there would be cases where the - definition in the C library would override the one in the libintl.so - shared library. Recall that on ELF systems, the symbols are looked - up in the following order: - 1. in the executable, - 2. in the shared libraries specified on the link command line, in order, - 3. in the dependencies of the shared libraries specified on the link - command line, - 4. in the dlopen()ed shared libraries, in the order in which they were - dlopen()ed. - The definition in the C library would override the one in libintl.so if - either - * -lc is given on the link command line and -lintl isn't, or - * -lc is given on the link command line before -lintl, or - * libintl.so is a dependency of a dlopen()ed shared library but not - linked to the executable at link time. - Since Solaris gettext() behaves differently than GNU gettext(), this - would be unacceptable. - - The redirection happens by default through macros in C, so that &gettext - is independent of the compilation unit, but through inline functions in - C++, in order not to interfere with the name mangling of class fields or - class methods called 'gettext'. */ - -/* The user can define _INTL_REDIRECT_INLINE or _INTL_REDIRECT_MACROS. - If he doesn't, we choose the method. A third possible method is - _INTL_REDIRECT_ASM, supported only by GCC. */ -#if !(defined _INTL_REDIRECT_INLINE || defined _INTL_REDIRECT_MACROS) -# if __GNUC__ >= 2 && (defined __STDC__ || defined __cplusplus) && !(defined __APPLE_CC__) -# define _INTL_REDIRECT_ASM -# else -# ifdef __cplusplus -# define _INTL_REDIRECT_INLINE -# else -# define _INTL_REDIRECT_MACROS -# endif -# endif -#endif -/* Auxiliary macros. */ -#ifdef _INTL_REDIRECT_ASM -# define _INTL_ASM(cname) __asm__ (_INTL_ASMNAME (__USER_LABEL_PREFIX__, #cname)) -# define _INTL_ASMNAME(prefix,cnamestring) _INTL_STRINGIFY (prefix) cnamestring -# define _INTL_STRINGIFY(prefix) #prefix -#else -# define _INTL_ASM(cname) -#endif - -/* Look up MSGID in the current default message catalog for the current - LC_MESSAGES locale. If not found, returns MSGID itself (the default - text). */ -#ifdef _INTL_REDIRECT_INLINE -extern char *libintl_gettext (const char *__msgid); -static inline char *gettext (const char *__msgid) -{ - return libintl_gettext (__msgid); -} -#else -#ifdef _INTL_REDIRECT_MACROS -# define gettext libintl_gettext -#endif -extern char *gettext _INTL_PARAMS ((const char *__msgid)) - _INTL_ASM (libintl_gettext); -#endif - -/* Look up MSGID in the DOMAINNAME message catalog for the current - LC_MESSAGES locale. */ -#ifdef _INTL_REDIRECT_INLINE -extern char *libintl_dgettext (const char *__domainname, const char *__msgid); -static inline char *dgettext (const char *__domainname, const char *__msgid) -{ - return libintl_dgettext (__domainname, __msgid); -} -#else -#ifdef _INTL_REDIRECT_MACROS -# define dgettext libintl_dgettext -#endif -extern char *dgettext _INTL_PARAMS ((const char *__domainname, - const char *__msgid)) - _INTL_ASM (libintl_dgettext); -#endif - -/* Look up MSGID in the DOMAINNAME message catalog for the current CATEGORY - locale. */ -#ifdef _INTL_REDIRECT_INLINE -extern char *libintl_dcgettext (const char *__domainname, const char *__msgid, - int __category); -static inline char *dcgettext (const char *__domainname, const char *__msgid, - int __category) -{ - return libintl_dcgettext (__domainname, __msgid, __category); -} -#else -#ifdef _INTL_REDIRECT_MACROS -# define dcgettext libintl_dcgettext -#endif -extern char *dcgettext _INTL_PARAMS ((const char *__domainname, - const char *__msgid, - int __category)) - _INTL_ASM (libintl_dcgettext); -#endif - - -/* Similar to `gettext' but select the plural form corresponding to the - number N. */ -#ifdef _INTL_REDIRECT_INLINE -extern char *libintl_ngettext (const char *__msgid1, const char *__msgid2, - unsigned long int __n); -static inline char *ngettext (const char *__msgid1, const char *__msgid2, - unsigned long int __n) -{ - return libintl_ngettext (__msgid1, __msgid2, __n); -} -#else -#ifdef _INTL_REDIRECT_MACROS -# define ngettext libintl_ngettext -#endif -extern char *ngettext _INTL_PARAMS ((const char *__msgid1, - const char *__msgid2, - unsigned long int __n)) - _INTL_ASM (libintl_ngettext); -#endif - -/* Similar to `dgettext' but select the plural form corresponding to the - number N. */ -#ifdef _INTL_REDIRECT_INLINE -extern char *libintl_dngettext (const char *__domainname, const char *__msgid1, - const char *__msgid2, unsigned long int __n); -static inline char *dngettext (const char *__domainname, const char *__msgid1, - const char *__msgid2, unsigned long int __n) -{ - return libintl_dngettext (__domainname, __msgid1, __msgid2, __n); -} -#else -#ifdef _INTL_REDIRECT_MACROS -# define dngettext libintl_dngettext -#endif -extern char *dngettext _INTL_PARAMS ((const char *__domainname, - const char *__msgid1, - const char *__msgid2, - unsigned long int __n)) - _INTL_ASM (libintl_dngettext); -#endif - -/* Similar to `dcgettext' but select the plural form corresponding to the - number N. */ -#ifdef _INTL_REDIRECT_INLINE -extern char *libintl_dcngettext (const char *__domainname, - const char *__msgid1, const char *__msgid2, - unsigned long int __n, int __category); -static inline char *dcngettext (const char *__domainname, - const char *__msgid1, const char *__msgid2, - unsigned long int __n, int __category) -{ - return libintl_dcngettext (__domainname, __msgid1, __msgid2, __n, __category); -} -#else -#ifdef _INTL_REDIRECT_MACROS -# define dcngettext libintl_dcngettext -#endif -extern char *dcngettext _INTL_PARAMS ((const char *__domainname, - const char *__msgid1, - const char *__msgid2, - unsigned long int __n, - int __category)) - _INTL_ASM (libintl_dcngettext); -#endif - - -/* Set the current default message catalog to DOMAINNAME. - If DOMAINNAME is null, return the current default. - If DOMAINNAME is "", reset to the default of "messages". */ -#ifdef _INTL_REDIRECT_INLINE -extern char *libintl_textdomain (const char *__domainname); -static inline char *textdomain (const char *__domainname) -{ - return libintl_textdomain (__domainname); -} -#else -#ifdef _INTL_REDIRECT_MACROS -# define textdomain libintl_textdomain -#endif -extern char *textdomain _INTL_PARAMS ((const char *__domainname)) - _INTL_ASM (libintl_textdomain); -#endif - -/* Specify that the DOMAINNAME message catalog will be found - in DIRNAME rather than in the system locale data base. */ -#ifdef _INTL_REDIRECT_INLINE -extern char *libintl_bindtextdomain (const char *__domainname, - const char *__dirname); -static inline char *bindtextdomain (const char *__domainname, - const char *__dirname) -{ - return libintl_bindtextdomain (__domainname, __dirname); -} -#else -#ifdef _INTL_REDIRECT_MACROS -# define bindtextdomain libintl_bindtextdomain -#endif -extern char *bindtextdomain _INTL_PARAMS ((const char *__domainname, - const char *__dirname)) - _INTL_ASM (libintl_bindtextdomain); -#endif - -/* Specify the character encoding in which the messages from the - DOMAINNAME message catalog will be returned. */ -#ifdef _INTL_REDIRECT_INLINE -extern char *libintl_bind_textdomain_codeset (const char *__domainname, - const char *__codeset); -static inline char *bind_textdomain_codeset (const char *__domainname, - const char *__codeset) -{ - return libintl_bind_textdomain_codeset (__domainname, __codeset); -} -#else -#ifdef _INTL_REDIRECT_MACROS -# define bind_textdomain_codeset libintl_bind_textdomain_codeset -#endif -extern char *bind_textdomain_codeset _INTL_PARAMS ((const char *__domainname, - const char *__codeset)) - _INTL_ASM (libintl_bind_textdomain_codeset); -#endif - - -#ifdef __cplusplus -} -#endif - -#endif /* libintl.h */ diff -urN gawk-3.1.2/intl/libgnuintl.h.in gawk-3.1.3/intl/libgnuintl.h.in --- gawk-3.1.2/intl/libgnuintl.h.in 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/intl/libgnuintl.h.in 2003-06-16 03:25:33.000000000 -0700 @@ -0,0 +1,309 @@ +/* Message catalogs for internationalization. + Copyright (C) 1995-1997, 2000-2003 Free Software Foundation, Inc. + + This program is free software; you can redistribute it and/or modify it + under the terms of the GNU Library General Public License as published + by the Free Software Foundation; either version 2, or (at your option) + any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, + USA. */ + +#ifndef _LIBINTL_H +#define _LIBINTL_H 1 + +#include + +/* The LC_MESSAGES locale category is the category used by the functions + gettext() and dgettext(). It is specified in POSIX, but not in ANSI C. + On systems that don't define it, use an arbitrary value instead. + On Solaris, defines __LOCALE_H (or _LOCALE_H in Solaris 2.5) + then includes (i.e. this file!) and then only defines + LC_MESSAGES. To avoid a redefinition warning, don't define LC_MESSAGES + in this case. */ +#if !defined LC_MESSAGES && !(defined __LOCALE_H || (defined _LOCALE_H && defined __sun)) +# define LC_MESSAGES 1729 +#endif + +/* We define an additional symbol to signal that we use the GNU + implementation of gettext. */ +#define __USE_GNU_GETTEXT 1 + +/* Provide information about the supported file formats. Returns the + maximum minor revision number supported for a given major revision. */ +#define __GNU_GETTEXT_SUPPORTED_REVISION(major) \ + ((major) == 0 ? 1 : -1) + +/* Resolve a platform specific conflict on DJGPP. GNU gettext takes + precedence over _conio_gettext. */ +#ifdef __DJGPP__ +# undef gettext +#endif + +/* Use _INTL_PARAMS, not PARAMS, in order to avoid clashes with identifiers + used by programs. Similarly, test __PROTOTYPES, not PROTOTYPES. */ +#ifndef _INTL_PARAMS +# if __STDC__ || defined __GNUC__ || defined __SUNPRO_C || defined __cplusplus || __PROTOTYPES +# define _INTL_PARAMS(args) args +# else +# define _INTL_PARAMS(args) () +# endif +#endif + +#ifdef __cplusplus +extern "C" { +#endif + + +/* We redirect the functions to those prefixed with "libintl_". This is + necessary, because some systems define gettext/textdomain/... in the C + library (namely, Solaris 2.4 and newer, and GNU libc 2.0 and newer). + If we used the unprefixed names, there would be cases where the + definition in the C library would override the one in the libintl.so + shared library. Recall that on ELF systems, the symbols are looked + up in the following order: + 1. in the executable, + 2. in the shared libraries specified on the link command line, in order, + 3. in the dependencies of the shared libraries specified on the link + command line, + 4. in the dlopen()ed shared libraries, in the order in which they were + dlopen()ed. + The definition in the C library would override the one in libintl.so if + either + * -lc is given on the link command line and -lintl isn't, or + * -lc is given on the link command line before -lintl, or + * libintl.so is a dependency of a dlopen()ed shared library but not + linked to the executable at link time. + Since Solaris gettext() behaves differently than GNU gettext(), this + would be unacceptable. + + The redirection happens by default through macros in C, so that &gettext + is independent of the compilation unit, but through inline functions in + C++, in order not to interfere with the name mangling of class fields or + class methods called 'gettext'. */ + +/* The user can define _INTL_REDIRECT_INLINE or _INTL_REDIRECT_MACROS. + If he doesn't, we choose the method. A third possible method is + _INTL_REDIRECT_ASM, supported only by GCC. */ +#if !(defined _INTL_REDIRECT_INLINE || defined _INTL_REDIRECT_MACROS) +# if __GNUC__ >= 2 && !defined __APPLE_CC__ && (defined __STDC__ || defined __cplusplus) +# define _INTL_REDIRECT_ASM +# else +# ifdef __cplusplus +# define _INTL_REDIRECT_INLINE +# else +# define _INTL_REDIRECT_MACROS +# endif +# endif +#endif +/* Auxiliary macros. */ +#ifdef _INTL_REDIRECT_ASM +# define _INTL_ASM(cname) __asm__ (_INTL_ASMNAME (__USER_LABEL_PREFIX__, #cname)) +# define _INTL_ASMNAME(prefix,cnamestring) _INTL_STRINGIFY (prefix) cnamestring +# define _INTL_STRINGIFY(prefix) #prefix +#else +# define _INTL_ASM(cname) +#endif + +/* Look up MSGID in the current default message catalog for the current + LC_MESSAGES locale. If not found, returns MSGID itself (the default + text). */ +#ifdef _INTL_REDIRECT_INLINE +extern char *libintl_gettext (const char *__msgid); +static inline char *gettext (const char *__msgid) +{ + return libintl_gettext (__msgid); +} +#else +#ifdef _INTL_REDIRECT_MACROS +# define gettext libintl_gettext +#endif +extern char *gettext _INTL_PARAMS ((const char *__msgid)) + _INTL_ASM (libintl_gettext); +#endif + +/* Look up MSGID in the DOMAINNAME message catalog for the current + LC_MESSAGES locale. */ +#ifdef _INTL_REDIRECT_INLINE +extern char *libintl_dgettext (const char *__domainname, const char *__msgid); +static inline char *dgettext (const char *__domainname, const char *__msgid) +{ + return libintl_dgettext (__domainname, __msgid); +} +#else +#ifdef _INTL_REDIRECT_MACROS +# define dgettext libintl_dgettext +#endif +extern char *dgettext _INTL_PARAMS ((const char *__domainname, + const char *__msgid)) + _INTL_ASM (libintl_dgettext); +#endif + +/* Look up MSGID in the DOMAINNAME message catalog for the current CATEGORY + locale. */ +#ifdef _INTL_REDIRECT_INLINE +extern char *libintl_dcgettext (const char *__domainname, const char *__msgid, + int __category); +static inline char *dcgettext (const char *__domainname, const char *__msgid, + int __category) +{ + return libintl_dcgettext (__domainname, __msgid, __category); +} +#else +#ifdef _INTL_REDIRECT_MACROS +# define dcgettext libintl_dcgettext +#endif +extern char *dcgettext _INTL_PARAMS ((const char *__domainname, + const char *__msgid, + int __category)) + _INTL_ASM (libintl_dcgettext); +#endif + + +/* Similar to `gettext' but select the plural form corresponding to the + number N. */ +#ifdef _INTL_REDIRECT_INLINE +extern char *libintl_ngettext (const char *__msgid1, const char *__msgid2, + unsigned long int __n); +static inline char *ngettext (const char *__msgid1, const char *__msgid2, + unsigned long int __n) +{ + return libintl_ngettext (__msgid1, __msgid2, __n); +} +#else +#ifdef _INTL_REDIRECT_MACROS +# define ngettext libintl_ngettext +#endif +extern char *ngettext _INTL_PARAMS ((const char *__msgid1, + const char *__msgid2, + unsigned long int __n)) + _INTL_ASM (libintl_ngettext); +#endif + +/* Similar to `dgettext' but select the plural form corresponding to the + number N. */ +#ifdef _INTL_REDIRECT_INLINE +extern char *libintl_dngettext (const char *__domainname, const char *__msgid1, + const char *__msgid2, unsigned long int __n); +static inline char *dngettext (const char *__domainname, const char *__msgid1, + const char *__msgid2, unsigned long int __n) +{ + return libintl_dngettext (__domainname, __msgid1, __msgid2, __n); +} +#else +#ifdef _INTL_REDIRECT_MACROS +# define dngettext libintl_dngettext +#endif +extern char *dngettext _INTL_PARAMS ((const char *__domainname, + const char *__msgid1, + const char *__msgid2, + unsigned long int __n)) + _INTL_ASM (libintl_dngettext); +#endif + +/* Similar to `dcgettext' but select the plural form corresponding to the + number N. */ +#ifdef _INTL_REDIRECT_INLINE +extern char *libintl_dcngettext (const char *__domainname, + const char *__msgid1, const char *__msgid2, + unsigned long int __n, int __category); +static inline char *dcngettext (const char *__domainname, + const char *__msgid1, const char *__msgid2, + unsigned long int __n, int __category) +{ + return libintl_dcngettext (__domainname, __msgid1, __msgid2, __n, __category); +} +#else +#ifdef _INTL_REDIRECT_MACROS +# define dcngettext libintl_dcngettext +#endif +extern char *dcngettext _INTL_PARAMS ((const char *__domainname, + const char *__msgid1, + const char *__msgid2, + unsigned long int __n, + int __category)) + _INTL_ASM (libintl_dcngettext); +#endif + + +/* Set the current default message catalog to DOMAINNAME. + If DOMAINNAME is null, return the current default. + If DOMAINNAME is "", reset to the default of "messages". */ +#ifdef _INTL_REDIRECT_INLINE +extern char *libintl_textdomain (const char *__domainname); +static inline char *textdomain (const char *__domainname) +{ + return libintl_textdomain (__domainname); +} +#else +#ifdef _INTL_REDIRECT_MACROS +# define textdomain libintl_textdomain +#endif +extern char *textdomain _INTL_PARAMS ((const char *__domainname)) + _INTL_ASM (libintl_textdomain); +#endif + +/* Specify that the DOMAINNAME message catalog will be found + in DIRNAME rather than in the system locale data base. */ +#ifdef _INTL_REDIRECT_INLINE +extern char *libintl_bindtextdomain (const char *__domainname, + const char *__dirname); +static inline char *bindtextdomain (const char *__domainname, + const char *__dirname) +{ + return libintl_bindtextdomain (__domainname, __dirname); +} +#else +#ifdef _INTL_REDIRECT_MACROS +# define bindtextdomain libintl_bindtextdomain +#endif +extern char *bindtextdomain _INTL_PARAMS ((const char *__domainname, + const char *__dirname)) + _INTL_ASM (libintl_bindtextdomain); +#endif + +/* Specify the character encoding in which the messages from the + DOMAINNAME message catalog will be returned. */ +#ifdef _INTL_REDIRECT_INLINE +extern char *libintl_bind_textdomain_codeset (const char *__domainname, + const char *__codeset); +static inline char *bind_textdomain_codeset (const char *__domainname, + const char *__codeset) +{ + return libintl_bind_textdomain_codeset (__domainname, __codeset); +} +#else +#ifdef _INTL_REDIRECT_MACROS +# define bind_textdomain_codeset libintl_bind_textdomain_codeset +#endif +extern char *bind_textdomain_codeset _INTL_PARAMS ((const char *__domainname, + const char *__codeset)) + _INTL_ASM (libintl_bind_textdomain_codeset); +#endif + + +/* Support for relocatable packages. */ + +/* Sets the original and the current installation prefix of the package. + Relocation simply replaces a pathname starting with the original prefix + by the corresponding pathname with the current prefix instead. Both + prefixes should be directory names without trailing slash (i.e. use "" + instead of "/"). */ +#define libintl_set_relocation_prefix libintl_set_relocation_prefix +extern void + libintl_set_relocation_prefix _INTL_PARAMS ((const char *orig_prefix, + const char *curr_prefix)); + + +#ifdef __cplusplus +} +#endif + +#endif /* libintl.h */ diff -urN gawk-3.1.2/intl/loadmsgcat.c gawk-3.1.3/intl/loadmsgcat.c --- gawk-3.1.2/intl/loadmsgcat.c 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/loadmsgcat.c 2003-06-16 03:25:33.000000000 -0700 @@ -1,5 +1,5 @@ /* Load needed message catalogs. - Copyright (C) 1995-1999, 2000-2002 Free Software Foundation, Inc. + Copyright (C) 1995-1999, 2000-2003 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published @@ -34,17 +34,23 @@ #include #ifdef __GNUC__ +# undef alloca # define alloca __builtin_alloca # define HAVE_ALLOCA 1 #else -# if defined HAVE_ALLOCA_H || defined _LIBC -# include +# ifdef _MSC_VER +# include +# define alloca _alloca # else -# ifdef _AIX - #pragma alloca +# if defined HAVE_ALLOCA_H || defined _LIBC +# include # else -# ifndef alloca +# ifdef _AIX + #pragma alloca +# else +# ifndef alloca char *alloca (); +# endif # endif # endif # endif @@ -820,7 +826,7 @@ if (outcharset == NULL || outcharset[0] == '\0') { # ifdef _LIBC - outcharset = (*_nl_current[LC_CTYPE])->values[_NL_ITEM_INDEX (CODESET)].string; + outcharset = _NL_CURRENT (LC_CTYPE, CODESET); # else # if HAVE_ICONV extern const char *locale_charset PARAMS ((void)); diff -urN gawk-3.1.2/intl/localcharset.c gawk-3.1.3/intl/localcharset.c --- gawk-3.1.2/intl/localcharset.c 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/localcharset.c 2003-06-16 03:25:33.000000000 -0700 @@ -1,6 +1,6 @@ /* Determine a canonical name for the current locale's character encoding. - Copyright (C) 2000-2002 Free Software Foundation, Inc. + Copyright (C) 2000-2003 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published @@ -23,6 +23,9 @@ # include #endif +/* Specification. */ +#include "localcharset.h" + #if HAVE_STDDEF_H # include #endif @@ -64,6 +67,12 @@ # include #endif +#if ENABLE_RELOCATABLE +# include "relocatable.h" +#else +# define relocate(pathname) (pathname) +#endif + #if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__ /* Win32, OS/2, DOS */ # define ISSLASH(C) ((C) == '/' || (C) == '\\') @@ -82,11 +91,6 @@ # define getc getc_unlocked #endif -#ifdef __cplusplus -/* When compiling with "gcc -x c++", produce a function with C linkage. */ -extern "C" const char * locale_charset (void); -#endif - /* The following static variable is declared 'volatile' to avoid a possible multithread problem in the function get_charset_aliases. If we are running in a threaded environment, and if two threads initialize @@ -110,9 +114,9 @@ cp = charset_aliases; if (cp == NULL) { -#if !defined WIN32 +#if !(defined VMS || defined WIN32) FILE *fp; - const char *dir = LIBDIR; + const char *dir = relocate (LIBDIR); const char *base = "charset.alias"; char *file_name; @@ -200,11 +204,36 @@ #else +# if defined VMS + /* To avoid the troubles of an extra file charset.alias_vms in the + sources of many GNU packages, simply inline the aliases here. */ + /* The list of encodings is taken from the OpenVMS 7.3-1 documentation + "Compaq C Run-Time Library Reference Manual for OpenVMS systems" + section 10.7 "Handling Different Character Sets". */ + cp = "ISO8859-1" "\0" "ISO-8859-1" "\0" + "ISO8859-2" "\0" "ISO-8859-2" "\0" + "ISO8859-5" "\0" "ISO-8859-5" "\0" + "ISO8859-7" "\0" "ISO-8859-7" "\0" + "ISO8859-8" "\0" "ISO-8859-8" "\0" + "ISO8859-9" "\0" "ISO-8859-9" "\0" + /* Japanese */ + "eucJP" "\0" "EUC-JP" "\0" + "SJIS" "\0" "SHIFT_JIS" "\0" + "DECKANJI" "\0" "DEC-KANJI" "\0" + "SDECKANJI" "\0" "EUC-JP" "\0" + /* Chinese */ + "eucTW" "\0" "EUC-TW" "\0" + "DECHANYU" "\0" "DEC-HANYU" "\0" + "DECHANZI" "\0" "GB2312" "\0" + /* Korean */ + "DECKOREAN" "\0" "EUC-KR" "\0"; +# endif + +# if defined WIN32 /* To avoid the troubles of installing a separate file in the same directory as the DLL and of retrieving the DLL's directory at runtime, simply inline the aliases here. */ -# if defined WIN32 cp = "CP936" "\0" "GBK" "\0" "CP1361" "\0" "JOHAB" "\0" "CP20127" "\0" "ASCII" "\0" diff -urN gawk-3.1.2/intl/localcharset.h gawk-3.1.3/intl/localcharset.h --- gawk-3.1.2/intl/localcharset.h 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/intl/localcharset.h 2003-06-16 03:25:33.000000000 -0700 @@ -0,0 +1,42 @@ +/* Determine a canonical name for the current locale's character encoding. + Copyright (C) 2000-2003 Free Software Foundation, Inc. + This file is part of the GNU CHARSET Library. + + This program is free software; you can redistribute it and/or modify it + under the terms of the GNU Library General Public License as published + by the Free Software Foundation; either version 2, or (at your option) + any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, + USA. */ + +#ifndef _LOCALCHARSET_H +#define _LOCALCHARSET_H + + +#ifdef __cplusplus +extern "C" { +#endif + + +/* Determine the current locale's character encoding, and canonicalize it + into one of the canonical names listed in config.charset. + The result must not be freed; it is statically allocated. + If the canonical name cannot be determined, the result is a non-canonical + name. */ +extern const char * locale_charset (void); + + +#ifdef __cplusplus +} +#endif + + +#endif /* _LOCALCHARSET_H */ diff -urN gawk-3.1.2/intl/localealias.c gawk-3.1.3/intl/localealias.c --- gawk-3.1.2/intl/localealias.c 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/localealias.c 2003-06-16 03:25:33.000000000 -0700 @@ -1,5 +1,5 @@ /* Handle aliases for locale names. - Copyright (C) 1995-1999, 2000, 2001 Free Software Foundation, Inc. + Copyright (C) 1995-1999, 2000-2001, 2003 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published @@ -35,17 +35,23 @@ #include #ifdef __GNUC__ +# undef alloca # define alloca __builtin_alloca # define HAVE_ALLOCA 1 #else -# if defined HAVE_ALLOCA_H || defined _LIBC -# include +# ifdef _MSC_VER +# include +# define alloca _alloca # else -# ifdef _AIX - #pragma alloca +# if defined HAVE_ALLOCA_H || defined _LIBC +# include # else -# ifndef alloca +# ifdef _AIX + #pragma alloca +# else +# ifndef alloca char *alloca (); +# endif # endif # endif # endif @@ -56,6 +62,12 @@ #include "gettextP.h" +#if ENABLE_RELOCATABLE +# include "relocatable.h" +#else +# define relocate(pathname) (pathname) +#endif + /* @@ end of prolog @@ */ #ifdef _LIBC @@ -115,10 +127,14 @@ }; -static char *string_space; +#ifndef _LIBC +# define libc_freeres_ptr(decl) decl +#endif + +libc_freeres_ptr (static char *string_space); static size_t string_space_act; static size_t string_space_max; -static struct alias_map *map; +libc_freeres_ptr (static struct alias_map *map); static size_t nmap; static size_t maxmap; @@ -217,7 +233,7 @@ memcpy (&full_fname[fname_len], aliasfile, sizeof aliasfile); #endif - fp = fopen (full_fname, "r"); + fp = fopen (relocate (full_fname), "r"); freea (full_fname); if (fp == NULL) return 0; @@ -234,8 +250,10 @@ a) we are only interested in the first two fields b) these fields must be usable as file names and so must not be that long - */ - char buf[BUFSIZ]; + We avoid a multi-kilobyte buffer here since this would use up + stack space which we might not have if the program ran out of + memory. */ + char buf[400]; char *alias; char *value; char *cp; @@ -244,19 +262,6 @@ /* EOF reached. */ break; - /* Possibly not the whole line fits into the buffer. Ignore - the rest of the line. */ - if (strchr (buf, '\n') == NULL) - { - char altbuf[BUFSIZ]; - do - if (FGETS (altbuf, sizeof altbuf, fp) == NULL) - /* Make sure the inner loop will be left. The outer loop - will exit at the `feof' test. */ - break; - while (strchr (altbuf, '\n') == NULL); - } - cp = buf; /* Ignore leading white space. */ while (isspace ((unsigned char) cp[0])) @@ -340,6 +345,14 @@ ++added; } } + + /* Possibly not the whole line fits into the buffer. Ignore + the rest of the line. */ + while (strchr (buf, '\n') == NULL) + if (FGETS (buf, sizeof buf, fp) == NULL) + /* Make sure the inner loop will be left. The outer loop + will exit at the `feof' test. */ + break; } /* Should we test for ferror()? I think we have to silently ignore @@ -373,19 +386,6 @@ } -#ifdef _LIBC -static void __attribute__ ((unused)) -free_mem (void) -{ - if (string_space != NULL) - free (string_space); - if (map != NULL) - free (map); -} -text_set_element (__libc_subfreeres, free_mem); -#endif - - static int alias_compare (map1, map2) const struct alias_map *map1; diff -urN gawk-3.1.2/intl/log.c gawk-3.1.3/intl/log.c --- gawk-3.1.2/intl/log.c 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/intl/log.c 2003-06-16 03:25:33.000000000 -0700 @@ -0,0 +1,104 @@ +/* Log file output. + Copyright (C) 2003 Free Software Foundation, Inc. + + This program is free software; you can redistribute it and/or modify it + under the terms of the GNU Library General Public License as published + by the Free Software Foundation; either version 2, or (at your option) + any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, + USA. */ + +/* Written by Bruno Haible . */ + +#ifdef HAVE_CONFIG_H +# include +#endif + +#include +#include +#include + +/* Print an ASCII string with quotes and escape sequences where needed. */ +static void +print_escaped (stream, str) + FILE *stream; + const char *str; +{ + putc ('"', stream); + for (; *str != '\0'; str++) + if (*str == '\n') + { + fputs ("\\n\"", stream); + if (str[1] == '\0') + return; + fputs ("\n\"", stream); + } + else + { + if (*str == '"' || *str == '\\') + putc ('\\', stream); + putc (*str, stream); + } + putc ('"', stream); +} + +/* Add to the log file an entry denoting a failed translation. */ +void +_nl_log_untranslated (logfilename, domainname, msgid1, msgid2, plural) + const char *logfilename; + const char *domainname; + const char *msgid1; + const char *msgid2; + int plural; +{ + static char *last_logfilename = NULL; + static FILE *last_logfile = NULL; + FILE *logfile; + + /* Can we reuse the last opened logfile? */ + if (last_logfilename == NULL || strcmp (logfilename, last_logfilename) != 0) + { + /* Close the last used logfile. */ + if (last_logfilename != NULL) + { + if (last_logfile != NULL) + { + fclose (last_logfile); + last_logfile = NULL; + } + free (last_logfilename); + last_logfilename = NULL; + } + /* Open the logfile. */ + last_logfilename = (char *) malloc (strlen (logfilename) + 1); + if (last_logfilename == NULL) + return; + strcpy (last_logfilename, logfilename); + last_logfile = fopen (logfilename, "a"); + if (last_logfile == NULL) + return; + } + logfile = last_logfile; + + fprintf (logfile, "domain "); + print_escaped (logfile, domainname); + fprintf (logfile, "\nmsgid "); + print_escaped (logfile, msgid1); + if (plural) + { + fprintf (logfile, "\nmsgid_plural "); + print_escaped (logfile, msgid2); + fprintf (logfile, "\nmsgstr[0] \"\"\n"); + } + else + fprintf (logfile, "\nmsgstr \"\"\n"); + putc ('\n', logfile); +} diff -urN gawk-3.1.2/intl/ngettext.c gawk-3.1.3/intl/ngettext.c --- gawk-3.1.2/intl/ngettext.c 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/intl/ngettext.c 2003-06-16 03:25:33.000000000 -0700 @@ -44,7 +44,7 @@ prefix. So we have to make a difference here. */ #ifdef _LIBC # define NGETTEXT __ngettext -# define DCNGETTEXT INTUSE(__dcngettext) +# define DCNGETTEXT __dcngettext #else # define NGETTEXT libintl_ngettext # define DCNGETTEXT libintl_dcngettext diff -urN gawk-3.1.2/intl/plural.c gawk-3.1.3/intl/plural.c --- gawk-3.1.2/intl/plural.c 2002-09-19 01:00:09.000000000 -0700 +++ gawk-3.1.3/intl/plural.c 2003-06-16 03:25:35.000000000 -0700 @@ -1,6 +1,5 @@ - -/* A Bison parser, made from plural.y - by GNU Bison version 1.28 */ +/* A Bison parser, made from plural.y + by GNU bison 1.35. */ #define YYBISON 1 /* Identify Bison output. */ @@ -11,11 +10,11 @@ #define yychar __gettextchar #define yydebug __gettextdebug #define yynerrs __gettextnerrs -#define EQUOP2 257 -#define CMPOP2 258 -#define ADDOP2 259 -#define MULOP2 260 -#define NUMBER 261 +# define EQUOP2 257 +# define CMPOP2 258 +# define ADDOP2 259 +# define MULOP2 260 +# define NUMBER 261 #line 1 "plural.y" @@ -64,11 +63,15 @@ #define YYPARSE_PARAM arg #line 49 "plural.y" +#ifndef YYSTYPE typedef union { unsigned long int num; enum operator op; struct expression *exp; -} YYSTYPE; +} yystype; +# define YYSTYPE yystype +# define YYSTYPE_IS_TRIVIAL 1 +#endif #line 55 "plural.y" /* Prototypes for local functions. */ @@ -167,12 +170,8 @@ return new_exp (3, op, args); } -#include - -#ifndef __cplusplus -#ifndef __STDC__ -#define const -#endif +#ifndef YYDEBUG +# define YYDEBUG 0 #endif @@ -181,129 +180,152 @@ #define YYFLAG -32768 #define YYNTBASE 16 +/* YYTRANSLATE(YYLEX) -- Bison token number corresponding to YYLEX. */ #define YYTRANSLATE(x) ((unsigned)(x) <= 261 ? yytranslate[x] : 18) -static const char yytranslate[] = { 0, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 10, 2, 2, 2, 2, 5, 2, 14, - 15, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 12, 2, 2, - 2, 2, 3, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 13, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 4, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 1, 6, 7, 8, 9, - 11 +/* YYTRANSLATE[YYLEX] -- Bison token number corresponding to YYLEX. */ +static const char yytranslate[] = +{ + 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 10, 2, 2, 2, 2, 5, 2, + 14, 15, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 12, 2, + 2, 2, 2, 3, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 13, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 4, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 1, 6, 7, 8, + 9, 11 }; -#if YYDEBUG != 0 -static const short yyprhs[] = { 0, - 0, 2, 8, 12, 16, 20, 24, 28, 32, 35, - 37, 39 +#if YYDEBUG +static const short yyprhs[] = +{ + 0, 0, 2, 8, 12, 16, 20, 24, 28, 32, + 35, 37, 39 }; - -static const short yyrhs[] = { 17, - 0, 17, 3, 17, 12, 17, 0, 17, 4, 17, - 0, 17, 5, 17, 0, 17, 6, 17, 0, 17, - 7, 17, 0, 17, 8, 17, 0, 17, 9, 17, - 0, 10, 17, 0, 13, 0, 11, 0, 14, 17, - 15, 0 +static const short yyrhs[] = +{ + 17, 0, 17, 3, 17, 12, 17, 0, 17, 4, + 17, 0, 17, 5, 17, 0, 17, 6, 17, 0, + 17, 7, 17, 0, 17, 8, 17, 0, 17, 9, + 17, 0, 10, 17, 0, 13, 0, 11, 0, 14, + 17, 15, 0 }; #endif -#if YYDEBUG != 0 -static const short yyrline[] = { 0, - 174, 182, 186, 190, 194, 198, 202, 206, 210, 214, - 218, 223 +#if YYDEBUG +/* YYRLINE[YYN] -- source line where rule number YYN was defined. */ +static const short yyrline[] = +{ + 0, 174, 182, 186, 190, 194, 198, 202, 206, 210, + 214, 218, 223 }; #endif -#if YYDEBUG != 0 || defined (YYERROR_VERBOSE) +#if (YYDEBUG) || defined YYERROR_VERBOSE -static const char * const yytname[] = { "$","error","$undefined.","'?'","'|'", -"'&'","EQUOP2","CMPOP2","ADDOP2","MULOP2","'!'","NUMBER","':'","'n'","'('","')'", -"start","exp", NULL +/* YYTNAME[TOKEN_NUM] -- String name of the token TOKEN_NUM. */ +static const char *const yytname[] = +{ + "$", "error", "$undefined.", "'?'", "'|'", "'&'", "EQUOP2", "CMPOP2", + "ADDOP2", "MULOP2", "'!'", "NUMBER", "':'", "'n'", "'('", "')'", + "start", "exp", 0 }; #endif -static const short yyr1[] = { 0, - 16, 17, 17, 17, 17, 17, 17, 17, 17, 17, - 17, 17 +/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ +static const short yyr1[] = +{ + 0, 16, 17, 17, 17, 17, 17, 17, 17, 17, + 17, 17, 17 }; -static const short yyr2[] = { 0, - 1, 5, 3, 3, 3, 3, 3, 3, 2, 1, - 1, 3 +/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ +static const short yyr2[] = +{ + 0, 1, 5, 3, 3, 3, 3, 3, 3, 2, + 1, 1, 3 }; -static const short yydefact[] = { 0, - 0, 11, 10, 0, 1, 9, 0, 0, 0, 0, - 0, 0, 0, 0, 12, 0, 3, 4, 5, 6, - 7, 8, 0, 2, 0, 0, 0 +/* YYDEFACT[S] -- default rule to reduce with in state S when YYTABLE + doesn't specify something else to do. Zero means the default is an + error. */ +static const short yydefact[] = +{ + 0, 0, 11, 10, 0, 1, 9, 0, 0, 0, + 0, 0, 0, 0, 0, 12, 0, 3, 4, 5, + 6, 7, 8, 0, 2, 0, 0, 0 }; -static const short yydefgoto[] = { 25, - 5 +static const short yydefgoto[] = +{ + 25, 5 }; -static const short yypact[] = { -9, - -9,-32768,-32768, -9, 34,-32768, 11, -9, -9, -9, - -9, -9, -9, -9,-32768, 24, 39, 43, 16, 26, - -3,-32768, -9, 34, 21, 53,-32768 +static const short yypact[] = +{ + -9, -9,-32768,-32768, -9, 34,-32768, 11, -9, -9, + -9, -9, -9, -9, -9,-32768, 24, 39, 43, 16, + 26, -3,-32768, -9, 34, 21, 53,-32768 }; -static const short yypgoto[] = {-32768, - -1 +static const short yypgoto[] = +{ + -32768, -1 }; #define YYLAST 53 -static const short yytable[] = { 6, - 1, 2, 7, 3, 4, 14, 16, 17, 18, 19, - 20, 21, 22, 8, 9, 10, 11, 12, 13, 14, - 26, 24, 12, 13, 14, 15, 8, 9, 10, 11, - 12, 13, 14, 13, 14, 23, 8, 9, 10, 11, - 12, 13, 14, 10, 11, 12, 13, 14, 11, 12, - 13, 14, 27 +static const short yytable[] = +{ + 6, 1, 2, 7, 3, 4, 14, 16, 17, 18, + 19, 20, 21, 22, 8, 9, 10, 11, 12, 13, + 14, 26, 24, 12, 13, 14, 15, 8, 9, 10, + 11, 12, 13, 14, 13, 14, 23, 8, 9, 10, + 11, 12, 13, 14, 10, 11, 12, 13, 14, 11, + 12, 13, 14, 27 }; -static const short yycheck[] = { 1, - 10, 11, 4, 13, 14, 9, 8, 9, 10, 11, - 12, 13, 14, 3, 4, 5, 6, 7, 8, 9, - 0, 23, 7, 8, 9, 15, 3, 4, 5, 6, - 7, 8, 9, 8, 9, 12, 3, 4, 5, 6, - 7, 8, 9, 5, 6, 7, 8, 9, 6, 7, - 8, 9, 0 +static const short yycheck[] = +{ + 1, 10, 11, 4, 13, 14, 9, 8, 9, 10, + 11, 12, 13, 14, 3, 4, 5, 6, 7, 8, + 9, 0, 23, 7, 8, 9, 15, 3, 4, 5, + 6, 7, 8, 9, 8, 9, 12, 3, 4, 5, + 6, 7, 8, 9, 5, 6, 7, 8, 9, 6, + 7, 8, 9, 0 }; #define YYPURE 1 /* -*-C-*- Note some compilers choke on comments on `#line' lines. */ -#line 3 "/usr/local/share/bison.simple" -/* This file comes from bison-1.28. */ +#line 3 "/usr/local/share/bison/bison.simple" /* Skeleton output parser for bison, - Copyright (C) 1984, 1989, 1990 Free Software Foundation, Inc. + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002 Free Software + Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -325,62 +347,131 @@ This special exception was added by the Free Software Foundation in version 1.24 of Bison. */ -/* This is the parser code that is written into each bison parser - when the %semantic_parser declaration is not specified in the grammar. - It was written by Richard Stallman by simplifying the hairy parser - used when %semantic_parser is specified. */ - -#ifndef YYSTACK_USE_ALLOCA -#ifdef alloca -#define YYSTACK_USE_ALLOCA -#else /* alloca not defined */ -#ifdef __GNUC__ -#define YYSTACK_USE_ALLOCA -#define alloca __builtin_alloca -#else /* not GNU C. */ -#if (!defined (__STDC__) && defined (sparc)) || defined (__sparc__) || defined (__sparc) || defined (__sgi) || (defined (__sun) && defined (__i386)) -#define YYSTACK_USE_ALLOCA -#include -#else /* not sparc */ -/* We think this test detects Watcom and Microsoft C. */ -/* This used to test MSDOS, but that is a bad idea - since that symbol is in the user namespace. */ -#if (defined (_MSDOS) || defined (_MSDOS_)) && !defined (__TURBOC__) -#if 0 /* No need for malloc.h, which pollutes the namespace; - instead, just don't use alloca. */ -#include -#endif -#else /* not MSDOS, or __TURBOC__ */ -#if defined(_AIX) -/* I don't know what this was needed for, but it pollutes the namespace. - So I turned it off. rms, 2 May 1997. */ -/* #include */ - #pragma alloca -#define YYSTACK_USE_ALLOCA -#else /* not MSDOS, or __TURBOC__, or _AIX */ -#if 0 -#ifdef __hpux /* haible@ilog.fr says this works for HPUX 9.05 and up, - and on HPUX 10. Eventually we can turn this on. */ -#define YYSTACK_USE_ALLOCA -#define alloca __builtin_alloca -#endif /* __hpux */ -#endif -#endif /* not _AIX */ -#endif /* not MSDOS, or __TURBOC__ */ -#endif /* not sparc */ -#endif /* not GNU C */ -#endif /* alloca not defined */ -#endif /* YYSTACK_USE_ALLOCA not defined */ +/* This is the parser code that is written into each bison parser when + the %semantic_parser declaration is not specified in the grammar. + It was written by Richard Stallman by simplifying the hairy parser + used when %semantic_parser is specified. */ + +/* All symbols defined below should begin with yy or YY, to avoid + infringing on user name space. This should be done even for local + variables, as they might otherwise be expanded by user macros. + There are some unavoidable exceptions within include files to + define necessary library symbols; they are noted "INFRINGES ON + USER NAME SPACE" below. */ + +#if ! defined (yyoverflow) || defined (YYERROR_VERBOSE) + +/* The parser invokes alloca or malloc; define the necessary symbols. */ + +# if YYSTACK_USE_ALLOCA +# define YYSTACK_ALLOC alloca +# else +# ifndef YYSTACK_USE_ALLOCA +# if defined (alloca) || defined (_ALLOCA_H) +# define YYSTACK_ALLOC alloca +# else +# ifdef __GNUC__ +# define YYSTACK_ALLOC __builtin_alloca +# endif +# endif +# endif +# endif + +# ifdef YYSTACK_ALLOC + /* Pacify GCC's `empty if-body' warning. */ +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0) +# else +# if defined (__STDC__) || defined (__cplusplus) +# include /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t +# endif +# define YYSTACK_ALLOC malloc +# define YYSTACK_FREE free +# endif +#endif /* ! defined (yyoverflow) || defined (YYERROR_VERBOSE) */ + + +#if (! defined (yyoverflow) \ + && (! defined (__cplusplus) \ + || (YYLTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) + +/* A type that is properly aligned for any stack member. */ +union yyalloc +{ + short yyss; + YYSTYPE yyvs; +# if YYLSP_NEEDED + YYLTYPE yyls; +# endif +}; -#ifdef YYSTACK_USE_ALLOCA -#define YYSTACK_ALLOC alloca -#else -#define YYSTACK_ALLOC malloc -#endif +/* The size of the maximum gap between one aligned stack and the next. */ +# define YYSTACK_GAP_MAX (sizeof (union yyalloc) - 1) -/* Note: there must be only one dollar sign in this file. - It is replaced by the list of actions, each action - as one case of the switch. */ +/* The size of an array large to enough to hold all stacks, each with + N elements. */ +# if YYLSP_NEEDED +# define YYSTACK_BYTES(N) \ + ((N) * (sizeof (short) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \ + + 2 * YYSTACK_GAP_MAX) +# else +# define YYSTACK_BYTES(N) \ + ((N) * (sizeof (short) + sizeof (YYSTYPE)) \ + + YYSTACK_GAP_MAX) +# endif + +/* Copy COUNT objects from FROM to TO. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if 1 < __GNUC__ +# define YYCOPY(To, From, Count) \ + __builtin_memcpy (To, From, (Count) * sizeof (*(From))) +# else +# define YYCOPY(To, From, Count) \ + do \ + { \ + register YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (To)[yyi] = (From)[yyi]; \ + } \ + while (0) +# endif +# endif + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack, Stack, yysize); \ + Stack = &yyptr->Stack; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAX; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (0) + +#endif + + +#if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__) +# define YYSIZE_T __SIZE_TYPE__ +#endif +#if ! defined (YYSIZE_T) && defined (size_t) +# define YYSIZE_T size_t +#endif +#if ! defined (YYSIZE_T) +# if defined (__STDC__) || defined (__cplusplus) +# include /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t +# endif +#endif +#if ! defined (YYSIZE_T) +# define YYSIZE_T unsigned int +#endif #define yyerrok (yyerrstatus = 0) #define yyclearin (yychar = YYEMPTY) @@ -389,131 +480,161 @@ #define YYACCEPT goto yyacceptlab #define YYABORT goto yyabortlab #define YYERROR goto yyerrlab1 -/* Like YYERROR except do call yyerror. - This remains here temporarily to ease the - transition to the new meaning of YYERROR, for GCC. +/* Like YYERROR except do call yyerror. This remains here temporarily + to ease the transition to the new meaning of YYERROR, for GCC. Once GCC version 2 has supplanted version 1, this can go. */ #define YYFAIL goto yyerrlab #define YYRECOVERING() (!!yyerrstatus) -#define YYBACKUP(token, value) \ +#define YYBACKUP(Token, Value) \ do \ if (yychar == YYEMPTY && yylen == 1) \ - { yychar = (token), yylval = (value); \ + { \ + yychar = (Token); \ + yylval = (Value); \ yychar1 = YYTRANSLATE (yychar); \ YYPOPSTACK; \ goto yybackup; \ } \ else \ - { yyerror ("syntax error: cannot back up"); YYERROR; } \ + { \ + yyerror ("syntax error: cannot back up"); \ + YYERROR; \ + } \ while (0) #define YYTERROR 1 #define YYERRCODE 256 -#ifndef YYPURE -#define YYLEX yylex() -#endif -#ifdef YYPURE -#ifdef YYLSP_NEEDED -#ifdef YYLEX_PARAM -#define YYLEX yylex(&yylval, &yylloc, YYLEX_PARAM) -#else -#define YYLEX yylex(&yylval, &yylloc) -#endif -#else /* not YYLSP_NEEDED */ -#ifdef YYLEX_PARAM -#define YYLEX yylex(&yylval, YYLEX_PARAM) -#else -#define YYLEX yylex(&yylval) -#endif -#endif /* not YYLSP_NEEDED */ -#endif +/* YYLLOC_DEFAULT -- Compute the default location (before the actions + are run). -/* If nonreentrant, generate the variables here */ - -#ifndef YYPURE - -int yychar; /* the lookahead symbol */ -YYSTYPE yylval; /* the semantic value of the */ - /* lookahead symbol */ - -#ifdef YYLSP_NEEDED -YYLTYPE yylloc; /* location data for the lookahead */ - /* symbol */ + When YYLLOC_DEFAULT is run, CURRENT is set the location of the + first token. By default, to implement support for ranges, extend + its range to the last symbol. */ + +#ifndef YYLLOC_DEFAULT +# define YYLLOC_DEFAULT(Current, Rhs, N) \ + Current.last_line = Rhs[N].last_line; \ + Current.last_column = Rhs[N].last_column; #endif -int yynerrs; /* number of parse errors so far */ -#endif /* not YYPURE */ - -#if YYDEBUG != 0 -int yydebug; /* nonzero means print parse trace */ -/* Since this is uninitialized, it does not stop multiple parsers - from coexisting. */ -#endif -/* YYINITDEPTH indicates the initial size of the parser's stacks */ +/* YYLEX -- calling `yylex' with the right arguments. */ + +#if YYPURE +# if YYLSP_NEEDED +# ifdef YYLEX_PARAM +# define YYLEX yylex (&yylval, &yylloc, YYLEX_PARAM) +# else +# define YYLEX yylex (&yylval, &yylloc) +# endif +# else /* !YYLSP_NEEDED */ +# ifdef YYLEX_PARAM +# define YYLEX yylex (&yylval, YYLEX_PARAM) +# else +# define YYLEX yylex (&yylval) +# endif +# endif /* !YYLSP_NEEDED */ +#else /* !YYPURE */ +# define YYLEX yylex () +#endif /* !YYPURE */ + + +/* Enable debugging if requested. */ +#if YYDEBUG + +# ifndef YYFPRINTF +# include /* INFRINGES ON USER NAME SPACE */ +# define YYFPRINTF fprintf +# endif + +# define YYDPRINTF(Args) \ +do { \ + if (yydebug) \ + YYFPRINTF Args; \ +} while (0) +/* Nonzero means print parse trace. It is left uninitialized so that + multiple parsers can coexist. */ +int yydebug; +#else /* !YYDEBUG */ +# define YYDPRINTF(Args) +#endif /* !YYDEBUG */ +/* YYINITDEPTH -- initial size of the parser's stacks. */ #ifndef YYINITDEPTH -#define YYINITDEPTH 200 +# define YYINITDEPTH 200 #endif -/* YYMAXDEPTH is the maximum size the stacks can grow to - (effective only if the built-in stack extension method is used). */ +/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only + if the built-in stack extension method is used). + + Do not make this value too large; the results are undefined if + SIZE_MAX < YYSTACK_BYTES (YYMAXDEPTH) + evaluated with infinite-precision integer arithmetic. */ #if YYMAXDEPTH == 0 -#undef YYMAXDEPTH +# undef YYMAXDEPTH #endif #ifndef YYMAXDEPTH -#define YYMAXDEPTH 10000 +# define YYMAXDEPTH 10000 #endif -/* Define __yy_memcpy. Note that the size argument - should be passed with type unsigned int, because that is what the non-GCC - definitions require. With GCC, __builtin_memcpy takes an arg - of type size_t, but it can handle unsigned int. */ - -#if __GNUC__ > 1 /* GNU C and GNU C++ define this. */ -#define __yy_memcpy(TO,FROM,COUNT) __builtin_memcpy(TO,FROM,COUNT) -#else /* not GNU C or C++ */ -#ifndef __cplusplus +#ifdef YYERROR_VERBOSE -/* This is the most reliable way to avoid incompatibilities - in available built-in functions on various systems. */ -static void -__yy_memcpy (to, from, count) - char *to; - char *from; - unsigned int count; -{ - register char *f = from; - register char *t = to; - register int i = count; +# ifndef yystrlen +# if defined (__GLIBC__) && defined (_STRING_H) +# define yystrlen strlen +# else +/* Return the length of YYSTR. */ +static YYSIZE_T +# if defined (__STDC__) || defined (__cplusplus) +yystrlen (const char *yystr) +# else +yystrlen (yystr) + const char *yystr; +# endif +{ + register const char *yys = yystr; - while (i-- > 0) - *t++ = *f++; -} + while (*yys++ != '\0') + continue; -#else /* __cplusplus */ + return yys - yystr - 1; +} +# endif +# endif -/* This is the most reliable way to avoid incompatibilities - in available built-in functions on various systems. */ -static void -__yy_memcpy (char *to, char *from, unsigned int count) +# ifndef yystpcpy +# if defined (__GLIBC__) && defined (_STRING_H) && defined (_GNU_SOURCE) +# define yystpcpy stpcpy +# else +/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in + YYDEST. */ +static char * +# if defined (__STDC__) || defined (__cplusplus) +yystpcpy (char *yydest, const char *yysrc) +# else +yystpcpy (yydest, yysrc) + char *yydest; + const char *yysrc; +# endif { - register char *t = to; - register char *f = from; - register int i = count; + register char *yyd = yydest; + register const char *yys = yysrc; - while (i-- > 0) - *t++ = *f++; -} + while ((*yyd++ = *yys++) != '\0') + continue; -#endif + return yyd - 1; +} +# endif +# endif #endif -#line 217 "/usr/local/share/bison.simple" +#line 315 "/usr/local/share/bison/bison.simple" + /* The user can define YYPARSE_PARAM as the name of an argument to be passed into yyparse. The argument should have type void *. @@ -522,76 +643,121 @@ to the proper pointer type. */ #ifdef YYPARSE_PARAM -#ifdef __cplusplus -#define YYPARSE_PARAM_ARG void *YYPARSE_PARAM -#define YYPARSE_PARAM_DECL -#else /* not __cplusplus */ -#define YYPARSE_PARAM_ARG YYPARSE_PARAM -#define YYPARSE_PARAM_DECL void *YYPARSE_PARAM; -#endif /* not __cplusplus */ -#else /* not YYPARSE_PARAM */ -#define YYPARSE_PARAM_ARG -#define YYPARSE_PARAM_DECL -#endif /* not YYPARSE_PARAM */ +# if defined (__STDC__) || defined (__cplusplus) +# define YYPARSE_PARAM_ARG void *YYPARSE_PARAM +# define YYPARSE_PARAM_DECL +# else +# define YYPARSE_PARAM_ARG YYPARSE_PARAM +# define YYPARSE_PARAM_DECL void *YYPARSE_PARAM; +# endif +#else /* !YYPARSE_PARAM */ +# define YYPARSE_PARAM_ARG +# define YYPARSE_PARAM_DECL +#endif /* !YYPARSE_PARAM */ /* Prevent warning if -Wstrict-prototypes. */ #ifdef __GNUC__ -#ifdef YYPARSE_PARAM +# ifdef YYPARSE_PARAM int yyparse (void *); -#else +# else int yyparse (void); +# endif #endif + +/* YY_DECL_VARIABLES -- depending whether we use a pure parser, + variables are global, or local to YYPARSE. */ + +#define YY_DECL_NON_LSP_VARIABLES \ +/* The lookahead symbol. */ \ +int yychar; \ + \ +/* The semantic value of the lookahead symbol. */ \ +YYSTYPE yylval; \ + \ +/* Number of parse errors so far. */ \ +int yynerrs; + +#if YYLSP_NEEDED +# define YY_DECL_VARIABLES \ +YY_DECL_NON_LSP_VARIABLES \ + \ +/* Location data for the lookahead symbol. */ \ +YYLTYPE yylloc; +#else +# define YY_DECL_VARIABLES \ +YY_DECL_NON_LSP_VARIABLES #endif + +/* If nonreentrant, generate the variables here. */ + +#if !YYPURE +YY_DECL_VARIABLES +#endif /* !YYPURE */ + int -yyparse(YYPARSE_PARAM_ARG) +yyparse (YYPARSE_PARAM_ARG) YYPARSE_PARAM_DECL { + /* If reentrant, generate the variables here. */ +#if YYPURE + YY_DECL_VARIABLES +#endif /* !YYPURE */ + register int yystate; register int yyn; + int yyresult; + /* Number of tokens to shift before error messages enabled. */ + int yyerrstatus; + /* Lookahead token as an internal (translated) token number. */ + int yychar1 = 0; + + /* Three stacks and their tools: + `yyss': related to states, + `yyvs': related to semantic values, + `yyls': related to locations. + + Refer to the stacks thru separate pointers, to allow yyoverflow + to reallocate them elsewhere. */ + + /* The state stack. */ + short yyssa[YYINITDEPTH]; + short *yyss = yyssa; register short *yyssp; - register YYSTYPE *yyvsp; - int yyerrstatus; /* number of tokens to shift before error messages enabled */ - int yychar1 = 0; /* lookahead token as an internal (translated) token number */ - short yyssa[YYINITDEPTH]; /* the state stack */ - YYSTYPE yyvsa[YYINITDEPTH]; /* the semantic value stack */ - - short *yyss = yyssa; /* refer to the stacks thru separate pointers */ - YYSTYPE *yyvs = yyvsa; /* to allow yyoverflow to reallocate them elsewhere */ + /* The semantic value stack. */ + YYSTYPE yyvsa[YYINITDEPTH]; + YYSTYPE *yyvs = yyvsa; + register YYSTYPE *yyvsp; -#ifdef YYLSP_NEEDED - YYLTYPE yylsa[YYINITDEPTH]; /* the location stack */ +#if YYLSP_NEEDED + /* The location stack. */ + YYLTYPE yylsa[YYINITDEPTH]; YYLTYPE *yyls = yylsa; YYLTYPE *yylsp; +#endif -#define YYPOPSTACK (yyvsp--, yyssp--, yylsp--) +#if YYLSP_NEEDED +# define YYPOPSTACK (yyvsp--, yyssp--, yylsp--) #else -#define YYPOPSTACK (yyvsp--, yyssp--) +# define YYPOPSTACK (yyvsp--, yyssp--) #endif - int yystacksize = YYINITDEPTH; - int yyfree_stacks = 0; + YYSIZE_T yystacksize = YYINITDEPTH; -#ifdef YYPURE - int yychar; - YYSTYPE yylval; - int yynerrs; -#ifdef YYLSP_NEEDED - YYLTYPE yylloc; -#endif -#endif - YYSTYPE yyval; /* the variable used to return */ - /* semantic values from the action */ - /* routines */ + /* The variables used to return semantic value and location from the + action routines. */ + YYSTYPE yyval; +#if YYLSP_NEEDED + YYLTYPE yyloc; +#endif + /* When reducing, the number of symbols on the RHS of the reduced + rule. */ int yylen; -#if YYDEBUG != 0 - if (yydebug) - fprintf(stderr, "Starting parse\n"); -#endif + YYDPRINTF ((stderr, "Starting parse\n")); yystate = 0; yyerrstatus = 0; @@ -603,110 +769,110 @@ so that they stay on the same level as the state stack. The wasted elements are never initialized. */ - yyssp = yyss - 1; + yyssp = yyss; yyvsp = yyvs; -#ifdef YYLSP_NEEDED +#if YYLSP_NEEDED yylsp = yyls; #endif + goto yysetstate; -/* Push a new state, which is found in yystate . */ -/* In all cases, when you get here, the value and location stacks - have just been pushed. so pushing a state here evens the stacks. */ -yynewstate: +/*------------------------------------------------------------. +| yynewstate -- Push a new state, which is found in yystate. | +`------------------------------------------------------------*/ + yynewstate: + /* In all cases, when you get here, the value and location stacks + have just been pushed. so pushing a state here evens the stacks. + */ + yyssp++; - *++yyssp = yystate; + yysetstate: + *yyssp = yystate; if (yyssp >= yyss + yystacksize - 1) { - /* Give user a chance to reallocate the stack */ - /* Use copies of these so that the &'s don't force the real ones into memory. */ - YYSTYPE *yyvs1 = yyvs; - short *yyss1 = yyss; -#ifdef YYLSP_NEEDED - YYLTYPE *yyls1 = yyls; -#endif - /* Get the current used size of the three stacks, in elements. */ - int size = yyssp - yyss + 1; + YYSIZE_T yysize = yyssp - yyss + 1; #ifdef yyoverflow - /* Each stack pointer address is followed by the size of - the data in use in that stack, in bytes. */ -#ifdef YYLSP_NEEDED - /* This used to be a conditional around just the two extra args, - but that might be undefined if yyoverflow is a macro. */ - yyoverflow("parser stack overflow", - &yyss1, size * sizeof (*yyssp), - &yyvs1, size * sizeof (*yyvsp), - &yyls1, size * sizeof (*yylsp), - &yystacksize); -#else - yyoverflow("parser stack overflow", - &yyss1, size * sizeof (*yyssp), - &yyvs1, size * sizeof (*yyvsp), - &yystacksize); -#endif - - yyss = yyss1; yyvs = yyvs1; -#ifdef YYLSP_NEEDED - yyls = yyls1; -#endif + { + /* Give user a chance to reallocate the stack. Use copies of + these so that the &'s don't force the real ones into + memory. */ + YYSTYPE *yyvs1 = yyvs; + short *yyss1 = yyss; + + /* Each stack pointer address is followed by the size of the + data in use in that stack, in bytes. */ +# if YYLSP_NEEDED + YYLTYPE *yyls1 = yyls; + /* This used to be a conditional around just the two extra args, + but that might be undefined if yyoverflow is a macro. */ + yyoverflow ("parser stack overflow", + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yyls1, yysize * sizeof (*yylsp), + &yystacksize); + yyls = yyls1; +# else + yyoverflow ("parser stack overflow", + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yystacksize); +# endif + yyss = yyss1; + yyvs = yyvs1; + } #else /* no yyoverflow */ +# ifndef YYSTACK_RELOCATE + goto yyoverflowlab; +# else /* Extend the stack our own way. */ if (yystacksize >= YYMAXDEPTH) - { - yyerror("parser stack overflow"); - if (yyfree_stacks) - { - free (yyss); - free (yyvs); -#ifdef YYLSP_NEEDED - free (yyls); -#endif - } - return 2; - } + goto yyoverflowlab; yystacksize *= 2; if (yystacksize > YYMAXDEPTH) yystacksize = YYMAXDEPTH; -#ifndef YYSTACK_USE_ALLOCA - yyfree_stacks = 1; -#endif - yyss = (short *) YYSTACK_ALLOC (yystacksize * sizeof (*yyssp)); - __yy_memcpy ((char *)yyss, (char *)yyss1, - size * (unsigned int) sizeof (*yyssp)); - yyvs = (YYSTYPE *) YYSTACK_ALLOC (yystacksize * sizeof (*yyvsp)); - __yy_memcpy ((char *)yyvs, (char *)yyvs1, - size * (unsigned int) sizeof (*yyvsp)); -#ifdef YYLSP_NEEDED - yyls = (YYLTYPE *) YYSTACK_ALLOC (yystacksize * sizeof (*yylsp)); - __yy_memcpy ((char *)yyls, (char *)yyls1, - size * (unsigned int) sizeof (*yylsp)); -#endif + + { + short *yyss1 = yyss; + union yyalloc *yyptr = + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); + if (! yyptr) + goto yyoverflowlab; + YYSTACK_RELOCATE (yyss); + YYSTACK_RELOCATE (yyvs); +# if YYLSP_NEEDED + YYSTACK_RELOCATE (yyls); +# endif +# undef YYSTACK_RELOCATE + if (yyss1 != yyssa) + YYSTACK_FREE (yyss1); + } +# endif #endif /* no yyoverflow */ - yyssp = yyss + size - 1; - yyvsp = yyvs + size - 1; -#ifdef YYLSP_NEEDED - yylsp = yyls + size - 1; + yyssp = yyss + yysize - 1; + yyvsp = yyvs + yysize - 1; +#if YYLSP_NEEDED + yylsp = yyls + yysize - 1; #endif -#if YYDEBUG != 0 - if (yydebug) - fprintf(stderr, "Stack size increased to %d\n", yystacksize); -#endif + YYDPRINTF ((stderr, "Stack size increased to %lu\n", + (unsigned long int) yystacksize)); if (yyssp >= yyss + yystacksize - 1) YYABORT; } -#if YYDEBUG != 0 - if (yydebug) - fprintf(stderr, "Entering state %d\n", yystate); -#endif + YYDPRINTF ((stderr, "Entering state %d\n", yystate)); goto yybackup; - yybackup: + + +/*-----------. +| yybackup. | +`-----------*/ +yybackup: /* Do appropriate processing given the current state. */ /* Read a lookahead token if we need one and don't already have one. */ @@ -725,10 +891,7 @@ if (yychar == YYEMPTY) { -#if YYDEBUG != 0 - if (yydebug) - fprintf(stderr, "Reading a token: "); -#endif + YYDPRINTF ((stderr, "Reading a token: ")); yychar = YYLEX; } @@ -739,25 +902,25 @@ yychar1 = 0; yychar = YYEOF; /* Don't call YYLEX any more */ -#if YYDEBUG != 0 - if (yydebug) - fprintf(stderr, "Now at end of input.\n"); -#endif + YYDPRINTF ((stderr, "Now at end of input.\n")); } else { - yychar1 = YYTRANSLATE(yychar); + yychar1 = YYTRANSLATE (yychar); -#if YYDEBUG != 0 +#if YYDEBUG + /* We have to keep this `#if YYDEBUG', since we use variables + which are defined only if `YYDEBUG' is set. */ if (yydebug) { - fprintf (stderr, "Next token is %d (%s", yychar, yytname[yychar1]); - /* Give the individual parser a way to print the precise meaning - of a token, for further debugging info. */ -#ifdef YYPRINT + YYFPRINTF (stderr, "Next token is %d (%s", + yychar, yytname[yychar1]); + /* Give the individual parser a way to print the precise + meaning of a token, for further debugging info. */ +# ifdef YYPRINT YYPRINT (stderr, yychar, yylval); -#endif - fprintf (stderr, ")\n"); +# endif + YYFPRINTF (stderr, ")\n"); } #endif } @@ -789,56 +952,78 @@ YYACCEPT; /* Shift the lookahead token. */ - -#if YYDEBUG != 0 - if (yydebug) - fprintf(stderr, "Shifting token %d (%s), ", yychar, yytname[yychar1]); -#endif + YYDPRINTF ((stderr, "Shifting token %d (%s), ", + yychar, yytname[yychar1])); /* Discard the token being shifted unless it is eof. */ if (yychar != YYEOF) yychar = YYEMPTY; *++yyvsp = yylval; -#ifdef YYLSP_NEEDED +#if YYLSP_NEEDED *++yylsp = yylloc; #endif - /* count tokens shifted since error; after three, turn off error status. */ - if (yyerrstatus) yyerrstatus--; + /* Count tokens shifted since error; after three, turn off error + status. */ + if (yyerrstatus) + yyerrstatus--; yystate = yyn; goto yynewstate; -/* Do the default action for the current state. */ -yydefault: +/*-----------------------------------------------------------. +| yydefault -- do the default action for the current state. | +`-----------------------------------------------------------*/ +yydefault: yyn = yydefact[yystate]; if (yyn == 0) goto yyerrlab; + goto yyreduce; -/* Do a reduction. yyn is the number of a rule to reduce with. */ + +/*-----------------------------. +| yyreduce -- Do a reduction. | +`-----------------------------*/ yyreduce: + /* yyn is the number of a rule to reduce with. */ yylen = yyr2[yyn]; - if (yylen > 0) - yyval = yyvsp[1-yylen]; /* implement default value of the action */ -#if YYDEBUG != 0 + /* If YYLEN is nonzero, implement the default value of the action: + `$$ = $1'. + + Otherwise, the following line sets YYVAL to the semantic value of + the lookahead token. This behavior is undocumented and Bison + users should not rely upon it. Assigning to YYVAL + unconditionally makes the parser a bit smaller, and it avoids a + GCC warning that YYVAL may be used uninitialized. */ + yyval = yyvsp[1-yylen]; + +#if YYLSP_NEEDED + /* Similarly for the default location. Let the user run additional + commands if for instance locations are ranges. */ + yyloc = yylsp[1-yylen]; + YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen); +#endif + +#if YYDEBUG + /* We have to keep this `#if YYDEBUG', since we use variables which + are defined only if `YYDEBUG' is set. */ if (yydebug) { - int i; + int yyi; - fprintf (stderr, "Reducing via rule %d (line %d), ", - yyn, yyrline[yyn]); + YYFPRINTF (stderr, "Reducing via rule %d (line %d), ", + yyn, yyrline[yyn]); /* Print the symbols being reduced, and their result. */ - for (i = yyprhs[yyn]; yyrhs[i] > 0; i++) - fprintf (stderr, "%s ", yytname[yyrhs[i]]); - fprintf (stderr, " -> %s\n", yytname[yyr1[yyn]]); + for (yyi = yyprhs[yyn]; yyrhs[yyi] > 0; yyi++) + YYFPRINTF (stderr, "%s ", yytname[yyrhs[yyi]]); + YYFPRINTF (stderr, " -> %s\n", yytname[yyr1[yyn]]); } #endif - switch (yyn) { case 1: @@ -847,119 +1032,105 @@ if (yyvsp[0].exp == NULL) YYABORT; ((struct parse_args *) arg)->res = yyvsp[0].exp; - ; - break;} + } + break; case 2: #line 183 "plural.y" { yyval.exp = new_exp_3 (qmop, yyvsp[-4].exp, yyvsp[-2].exp, yyvsp[0].exp); - ; - break;} + } + break; case 3: #line 187 "plural.y" { yyval.exp = new_exp_2 (lor, yyvsp[-2].exp, yyvsp[0].exp); - ; - break;} + } + break; case 4: #line 191 "plural.y" { yyval.exp = new_exp_2 (land, yyvsp[-2].exp, yyvsp[0].exp); - ; - break;} + } + break; case 5: #line 195 "plural.y" { yyval.exp = new_exp_2 (yyvsp[-1].op, yyvsp[-2].exp, yyvsp[0].exp); - ; - break;} + } + break; case 6: #line 199 "plural.y" { yyval.exp = new_exp_2 (yyvsp[-1].op, yyvsp[-2].exp, yyvsp[0].exp); - ; - break;} + } + break; case 7: #line 203 "plural.y" { yyval.exp = new_exp_2 (yyvsp[-1].op, yyvsp[-2].exp, yyvsp[0].exp); - ; - break;} + } + break; case 8: #line 207 "plural.y" { yyval.exp = new_exp_2 (yyvsp[-1].op, yyvsp[-2].exp, yyvsp[0].exp); - ; - break;} + } + break; case 9: #line 211 "plural.y" { yyval.exp = new_exp_1 (lnot, yyvsp[0].exp); - ; - break;} + } + break; case 10: #line 215 "plural.y" { yyval.exp = new_exp_0 (var); - ; - break;} + } + break; case 11: #line 219 "plural.y" { if ((yyval.exp = new_exp_0 (num)) != NULL) yyval.exp->val.num = yyvsp[0].num; - ; - break;} + } + break; case 12: #line 224 "plural.y" { yyval.exp = yyvsp[-1].exp; - ; - break;} + } + break; } - /* the action file gets copied in in place of this dollarsign */ -#line 543 "/usr/local/share/bison.simple" + +#line 705 "/usr/local/share/bison/bison.simple" + yyvsp -= yylen; yyssp -= yylen; -#ifdef YYLSP_NEEDED +#if YYLSP_NEEDED yylsp -= yylen; #endif -#if YYDEBUG != 0 +#if YYDEBUG if (yydebug) { - short *ssp1 = yyss - 1; - fprintf (stderr, "state stack now"); - while (ssp1 != yyssp) - fprintf (stderr, " %d", *++ssp1); - fprintf (stderr, "\n"); + short *yyssp1 = yyss - 1; + YYFPRINTF (stderr, "state stack now"); + while (yyssp1 != yyssp) + YYFPRINTF (stderr, " %d", *++yyssp1); + YYFPRINTF (stderr, "\n"); } #endif *++yyvsp = yyval; - -#ifdef YYLSP_NEEDED - yylsp++; - if (yylen == 0) - { - yylsp->first_line = yylloc.first_line; - yylsp->first_column = yylloc.first_column; - yylsp->last_line = (yylsp-1)->last_line; - yylsp->last_column = (yylsp-1)->last_column; - yylsp->text = 0; - } - else - { - yylsp->last_line = (yylsp+yylen-1)->last_line; - yylsp->last_column = (yylsp+yylen-1)->last_column; - } +#if YYLSP_NEEDED + *++yylsp = yyloc; #endif - /* Now "shift" the result of the reduction. - Determine what state that goes to, - based on the state we popped back to - and the rule number reduced by. */ + /* Now `shift' the result of the reduction. Determine what state + that goes to, based on the state we popped back to and the rule + number reduced by. */ yyn = yyr1[yyn]; @@ -971,10 +1142,13 @@ goto yynewstate; -yyerrlab: /* here on detecting error */ - if (! yyerrstatus) - /* If not already recovering from an error, report this error. */ +/*------------------------------------. +| yyerrlab -- here on detecting error | +`------------------------------------*/ +yyerrlab: + /* If not already recovering from an error, report this error. */ + if (!yyerrstatus) { ++yynerrs; @@ -983,102 +1157,121 @@ if (yyn > YYFLAG && yyn < YYLAST) { - int size = 0; - char *msg; - int x, count; - - count = 0; - /* Start X at -yyn if nec to avoid negative indexes in yycheck. */ - for (x = (yyn < 0 ? -yyn : 0); - x < (sizeof(yytname) / sizeof(char *)); x++) - if (yycheck[x + yyn] == x) - size += strlen(yytname[x]) + 15, count++; - msg = (char *) malloc(size + 15); - if (msg != 0) + YYSIZE_T yysize = 0; + char *yymsg; + int yyx, yycount; + + yycount = 0; + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. */ + for (yyx = yyn < 0 ? -yyn : 0; + yyx < (int) (sizeof (yytname) / sizeof (char *)); yyx++) + if (yycheck[yyx + yyn] == yyx) + yysize += yystrlen (yytname[yyx]) + 15, yycount++; + yysize += yystrlen ("parse error, unexpected ") + 1; + yysize += yystrlen (yytname[YYTRANSLATE (yychar)]); + yymsg = (char *) YYSTACK_ALLOC (yysize); + if (yymsg != 0) { - strcpy(msg, "parse error"); + char *yyp = yystpcpy (yymsg, "parse error, unexpected "); + yyp = yystpcpy (yyp, yytname[YYTRANSLATE (yychar)]); - if (count < 5) + if (yycount < 5) { - count = 0; - for (x = (yyn < 0 ? -yyn : 0); - x < (sizeof(yytname) / sizeof(char *)); x++) - if (yycheck[x + yyn] == x) + yycount = 0; + for (yyx = yyn < 0 ? -yyn : 0; + yyx < (int) (sizeof (yytname) / sizeof (char *)); + yyx++) + if (yycheck[yyx + yyn] == yyx) { - strcat(msg, count == 0 ? ", expecting `" : " or `"); - strcat(msg, yytname[x]); - strcat(msg, "'"); - count++; + const char *yyq = ! yycount ? ", expecting " : " or "; + yyp = yystpcpy (yyp, yyq); + yyp = yystpcpy (yyp, yytname[yyx]); + yycount++; } } - yyerror(msg); - free(msg); + yyerror (yymsg); + YYSTACK_FREE (yymsg); } else - yyerror ("parse error; also virtual memory exceeded"); + yyerror ("parse error; also virtual memory exhausted"); } else -#endif /* YYERROR_VERBOSE */ - yyerror("parse error"); +#endif /* defined (YYERROR_VERBOSE) */ + yyerror ("parse error"); } - goto yyerrlab1; -yyerrlab1: /* here on error raised explicitly by an action */ + +/*--------------------------------------------------. +| yyerrlab1 -- error raised explicitly by an action | +`--------------------------------------------------*/ +yyerrlab1: if (yyerrstatus == 3) { - /* if just tried and failed to reuse lookahead token after an error, discard it. */ + /* If just tried and failed to reuse lookahead token after an + error, discard it. */ /* return failure if at end of input */ if (yychar == YYEOF) YYABORT; - -#if YYDEBUG != 0 - if (yydebug) - fprintf(stderr, "Discarding token %d (%s).\n", yychar, yytname[yychar1]); -#endif - + YYDPRINTF ((stderr, "Discarding token %d (%s).\n", + yychar, yytname[yychar1])); yychar = YYEMPTY; } - /* Else will try to reuse lookahead token - after shifting the error token. */ + /* Else will try to reuse lookahead token after shifting the error + token. */ yyerrstatus = 3; /* Each real token shifted decrements this */ goto yyerrhandle; -yyerrdefault: /* current state does not do anything special for the error token. */ +/*-------------------------------------------------------------------. +| yyerrdefault -- current state does not do anything special for the | +| error token. | +`-------------------------------------------------------------------*/ +yyerrdefault: #if 0 /* This is wrong; only states that explicitly want error tokens should shift them. */ - yyn = yydefact[yystate]; /* If its default is to accept any token, ok. Otherwise pop it.*/ - if (yyn) goto yydefault; + + /* If its default is to accept any token, ok. Otherwise pop it. */ + yyn = yydefact[yystate]; + if (yyn) + goto yydefault; #endif -yyerrpop: /* pop the current state because it cannot handle the error token */ - if (yyssp == yyss) YYABORT; +/*---------------------------------------------------------------. +| yyerrpop -- pop the current state because it cannot handle the | +| error token | +`---------------------------------------------------------------*/ +yyerrpop: + if (yyssp == yyss) + YYABORT; yyvsp--; yystate = *--yyssp; -#ifdef YYLSP_NEEDED +#if YYLSP_NEEDED yylsp--; #endif -#if YYDEBUG != 0 +#if YYDEBUG if (yydebug) { - short *ssp1 = yyss - 1; - fprintf (stderr, "Error: state stack now"); - while (ssp1 != yyssp) - fprintf (stderr, " %d", *++ssp1); - fprintf (stderr, "\n"); + short *yyssp1 = yyss - 1; + YYFPRINTF (stderr, "Error: state stack now"); + while (yyssp1 != yyssp) + YYFPRINTF (stderr, " %d", *++yyssp1); + YYFPRINTF (stderr, "\n"); } #endif +/*--------------. +| yyerrhandle. | +`--------------*/ yyerrhandle: - yyn = yypact[yystate]; if (yyn == YYFLAG) goto yyerrdefault; @@ -1101,42 +1294,45 @@ if (yyn == YYFINAL) YYACCEPT; -#if YYDEBUG != 0 - if (yydebug) - fprintf(stderr, "Shifting error token, "); -#endif + YYDPRINTF ((stderr, "Shifting error token, ")); *++yyvsp = yylval; -#ifdef YYLSP_NEEDED +#if YYLSP_NEEDED *++yylsp = yylloc; #endif yystate = yyn; goto yynewstate; - yyacceptlab: - /* YYACCEPT comes here. */ - if (yyfree_stacks) - { - free (yyss); - free (yyvs); -#ifdef YYLSP_NEEDED - free (yyls); -#endif - } - return 0; - yyabortlab: - /* YYABORT comes here. */ - if (yyfree_stacks) - { - free (yyss); - free (yyvs); -#ifdef YYLSP_NEEDED - free (yyls); +/*-------------------------------------. +| yyacceptlab -- YYACCEPT comes here. | +`-------------------------------------*/ +yyacceptlab: + yyresult = 0; + goto yyreturn; + +/*-----------------------------------. +| yyabortlab -- YYABORT comes here. | +`-----------------------------------*/ +yyabortlab: + yyresult = 1; + goto yyreturn; + +/*---------------------------------------------. +| yyoverflowab -- parser overflow comes here. | +`---------------------------------------------*/ +yyoverflowlab: + yyerror ("parser stack overflow"); + yyresult = 2; + /* Fall through. */ + +yyreturn: +#ifndef yyoverflow + if (yyss != yyssa) + YYSTACK_FREE (yyss); #endif - } - return 1; + return yyresult; } #line 229 "plural.y" diff -urN gawk-3.1.2/intl/relocatable.c gawk-3.1.3/intl/relocatable.c --- gawk-3.1.2/intl/relocatable.c 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/intl/relocatable.c 2003-06-16 03:25:33.000000000 -0700 @@ -0,0 +1,439 @@ +/* Provide relocatable packages. + Copyright (C) 2003 Free Software Foundation, Inc. + Written by Bruno Haible , 2003. + + This program is free software; you can redistribute it and/or modify it + under the terms of the GNU Library General Public License as published + by the Free Software Foundation; either version 2, or (at your option) + any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, + USA. */ + + +/* Tell glibc's to provide a prototype for getline(). + This must come before because may include + , and once has been included, it's too late. */ +#ifndef _GNU_SOURCE +# define _GNU_SOURCE 1 +#endif + +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif + +/* Specification. */ +#include "relocatable.h" + +#if ENABLE_RELOCATABLE + +#include +#include +#include +#include + +#ifdef NO_XMALLOC +# define xmalloc malloc +#else +# include "xmalloc.h" +#endif + +#if DEPENDS_ON_LIBCHARSET +# include +#endif +#if DEPENDS_ON_LIBICONV && HAVE_ICONV +# include +#endif +#if DEPENDS_ON_LIBINTL && ENABLE_NLS +# include +#endif + +/* Faked cheap 'bool'. */ +#undef bool +#undef false +#undef true +#define bool int +#define false 0 +#define true 1 + +/* Pathname support. + ISSLASH(C) tests whether C is a directory separator character. + IS_PATH_WITH_DIR(P) tests whether P contains a directory specification. + */ +#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__ + /* Win32, OS/2, DOS */ +# define ISSLASH(C) ((C) == '/' || (C) == '\\') +# define HAS_DEVICE(P) \ + ((((P)[0] >= 'A' && (P)[0] <= 'Z') || ((P)[0] >= 'a' && (P)[0] <= 'z')) \ + && (P)[1] == ':') +# define IS_PATH_WITH_DIR(P) \ + (strchr (P, '/') != NULL || strchr (P, '\\') != NULL || HAS_DEVICE (P)) +# define FILESYSTEM_PREFIX_LEN(P) (HAS_DEVICE (P) ? 2 : 0) +#else + /* Unix */ +# define ISSLASH(C) ((C) == '/') +# define IS_PATH_WITH_DIR(P) (strchr (P, '/') != NULL) +# define FILESYSTEM_PREFIX_LEN(P) 0 +#endif + +/* Original installation prefix. */ +static char *orig_prefix; +static size_t orig_prefix_len; +/* Current installation prefix. */ +static char *curr_prefix; +static size_t curr_prefix_len; +/* These prefixes do not end in a slash. Anything that will be concatenated + to them must start with a slash. */ + +/* Sets the original and the current installation prefix of this module. + Relocation simply replaces a pathname starting with the original prefix + by the corresponding pathname with the current prefix instead. Both + prefixes should be directory names without trailing slash (i.e. use "" + instead of "/"). */ +static void +set_this_relocation_prefix (const char *orig_prefix_arg, + const char *curr_prefix_arg) +{ + if (orig_prefix_arg != NULL && curr_prefix_arg != NULL + /* Optimization: if orig_prefix and curr_prefix are equal, the + relocation is a nop. */ + && strcmp (orig_prefix_arg, curr_prefix_arg) != 0) + { + /* Duplicate the argument strings. */ + char *memory; + + orig_prefix_len = strlen (orig_prefix_arg); + curr_prefix_len = strlen (curr_prefix_arg); + memory = (char *) xmalloc (orig_prefix_len + 1 + curr_prefix_len + 1); +#ifdef NO_XMALLOC + if (memory != NULL) +#endif + { + memcpy (memory, orig_prefix_arg, orig_prefix_len + 1); + orig_prefix = memory; + memory += orig_prefix_len + 1; + memcpy (memory, curr_prefix_arg, curr_prefix_len + 1); + curr_prefix = memory; + return; + } + } + orig_prefix = NULL; + curr_prefix = NULL; + /* Don't worry about wasted memory here - this function is usually only + called once. */ +} + +/* Sets the original and the current installation prefix of the package. + Relocation simply replaces a pathname starting with the original prefix + by the corresponding pathname with the current prefix instead. Both + prefixes should be directory names without trailing slash (i.e. use "" + instead of "/"). */ +void +set_relocation_prefix (const char *orig_prefix_arg, const char *curr_prefix_arg) +{ + set_this_relocation_prefix (orig_prefix_arg, curr_prefix_arg); + + /* Now notify all dependent libraries. */ +#if DEPENDS_ON_LIBCHARSET + libcharset_set_relocation_prefix (orig_prefix_arg, curr_prefix_arg); +#endif +#if DEPENDS_ON_LIBICONV && HAVE_ICONV && _LIBICONV_VERSION >= 0x0109 + libiconv_set_relocation_prefix (orig_prefix_arg, curr_prefix_arg); +#endif +#if DEPENDS_ON_LIBINTL && ENABLE_NLS && defined libintl_set_relocation_prefix + libintl_set_relocation_prefix (orig_prefix_arg, curr_prefix_arg); +#endif +} + +/* Convenience function: + Computes the current installation prefix, based on the original + installation prefix, the original installation directory of a particular + file, and the current pathname of this file. Returns NULL upon failure. */ +#ifdef IN_LIBRARY +#define compute_curr_prefix local_compute_curr_prefix +static +#endif +const char * +compute_curr_prefix (const char *orig_installprefix, + const char *orig_installdir, + const char *curr_pathname) +{ + const char *curr_installdir; + const char *rel_installdir; + + if (curr_pathname == NULL) + return NULL; + + /* Determine the relative installation directory, relative to the prefix. + This is simply the difference between orig_installprefix and + orig_installdir. */ + if (strncmp (orig_installprefix, orig_installdir, strlen (orig_installprefix)) + != 0) + /* Shouldn't happen - nothing should be installed outside $(prefix). */ + return NULL; + rel_installdir = orig_installdir + strlen (orig_installprefix); + + /* Determine the current installation directory. */ + { + const char *p_base = curr_pathname + FILESYSTEM_PREFIX_LEN (curr_pathname); + const char *p = curr_pathname + strlen (curr_pathname); + char *q; + + while (p > p_base) + { + p--; + if (ISSLASH (*p)) + break; + } + + q = (char *) xmalloc (p - curr_pathname + 1); +#ifdef NO_XMALLOC + if (q == NULL) + return NULL; +#endif + memcpy (q, curr_pathname, p - curr_pathname); + q[p - curr_pathname] = '\0'; + curr_installdir = q; + } + + /* Compute the current installation prefix by removing the trailing + rel_installdir from it. */ + { + const char *rp = rel_installdir + strlen (rel_installdir); + const char *cp = curr_installdir + strlen (curr_installdir); + const char *cp_base = + curr_installdir + FILESYSTEM_PREFIX_LEN (curr_installdir); + + while (rp > rel_installdir && cp > cp_base) + { + bool same = false; + const char *rpi = rp; + const char *cpi = cp; + + while (rpi > rel_installdir && cpi > cp_base) + { + rpi--; + cpi--; + if (ISSLASH (*rpi) || ISSLASH (*cpi)) + { + if (ISSLASH (*rpi) && ISSLASH (*cpi)) + same = true; + break; + } +#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__ + /* Win32, OS/2, DOS - case insignificant filesystem */ + if ((*rpi >= 'a' && *rpi <= 'z' ? *rpi - 'a' + 'A' : *rpi) + != (*cpi >= 'a' && *cpi <= 'z' ? *cpi - 'a' + 'A' : *cpi)) + break; +#else + if (*rpi != *cpi) + break; +#endif + } + if (!same) + break; + /* The last pathname component was the same. opi and cpi now point + to the slash before it. */ + rp = rpi; + cp = cpi; + } + + if (rp > rel_installdir) + /* Unexpected: The curr_installdir does not end with rel_installdir. */ + return NULL; + + { + size_t curr_prefix_len = cp - curr_installdir; + char *curr_prefix; + + curr_prefix = (char *) xmalloc (curr_prefix_len + 1); +#ifdef NO_XMALLOC + if (curr_prefix == NULL) + return NULL; +#endif + memcpy (curr_prefix, curr_installdir, curr_prefix_len); + curr_prefix[curr_prefix_len] = '\0'; + + return curr_prefix; + } + } +} + +#if defined PIC && defined INSTALLDIR + +/* Full pathname of shared library, or NULL. */ +static char *shared_library_fullname; + +#if defined _WIN32 || defined __WIN32__ + +/* Determine the full pathname of the shared library when it is loaded. */ + +BOOL WINAPI +DllMain (HINSTANCE module_handle, DWORD event, LPVOID reserved) +{ + (void) reserved; + + if (event == DLL_PROCESS_ATTACH) + { + /* The DLL is being loaded into an application's address range. */ + static char location[MAX_PATH]; + + if (!GetModuleFileName (module_handle, location, sizeof (location))) + /* Shouldn't happen. */ + return FALSE; + + if (!IS_PATH_WITH_DIR (location)) + /* Shouldn't happen. */ + return FALSE; + + shared_library_fullname = strdup (location); + } + + return TRUE; +} + +#else /* Unix */ + +static void +find_shared_library_fullname () +{ +#ifdef __linux__ + FILE *fp; + + /* Open the current process' maps file. It describes one VMA per line. */ + fp = fopen ("/proc/self/maps", "r"); + if (fp) + { + unsigned long address = (unsigned long) &find_shared_library_fullname; + for (;;) + { + unsigned long start, end; + int c; + + if (fscanf (fp, "%lx-%lx", &start, &end) != 2) + break; + if (address >= start && address <= end - 1) + { + /* Found it. Now see if this line contains a filename. */ + while (c = getc (fp), c != EOF && c != '\n' && c != '/') + continue; + if (c == '/') + { + size_t size; + int len; + + ungetc (c, fp); + shared_library_fullname = NULL; size = 0; + len = getline (&shared_library_fullname, &size, fp); + if (len >= 0) + { + /* Success: filled shared_library_fullname. */ + if (len > 0 && shared_library_fullname[len - 1] == '\n') + shared_library_fullname[len - 1] = '\0'; + } + } + break; + } + while (c = getc (fp), c != EOF && c != '\n') + continue; + } + fclose (fp); + } +#endif +} + +#endif /* WIN32 / Unix */ + +/* Return the full pathname of the current shared library. + Return NULL if unknown. + Guaranteed to work only on Linux and Woe32. */ +static char * +get_shared_library_fullname () +{ +#if !(defined _WIN32 || defined __WIN32__) + static bool tried_find_shared_library_fullname; + if (!tried_find_shared_library_fullname) + { + find_shared_library_fullname (); + tried_find_shared_library_fullname = true; + } +#endif + return shared_library_fullname; +} + +#endif /* PIC */ + +/* Returns the pathname, relocated according to the current installation + directory. */ +const char * +relocate (const char *pathname) +{ +#if defined PIC && defined INSTALLDIR + static int initialized; + + /* Initialization code for a shared library. */ + if (!initialized) + { + /* At this point, orig_prefix and curr_prefix likely have already been + set through the main program's set_program_name_and_installdir + function. This is sufficient in the case that the library has + initially been installed in the same orig_prefix. But we can do + better, to also cover the cases that 1. it has been installed + in a different prefix before being moved to orig_prefix and (later) + to curr_prefix, 2. unlike the program, it has not moved away from + orig_prefix. */ + const char *orig_installprefix = INSTALLPREFIX; + const char *orig_installdir = INSTALLDIR; + const char *curr_prefix_better; + + curr_prefix_better = + compute_curr_prefix (orig_installprefix, orig_installdir, + get_shared_library_fullname ()); + if (curr_prefix_better == NULL) + curr_prefix_better = curr_prefix; + + set_relocation_prefix (orig_installprefix, curr_prefix_better); + + initialized = 1; + } +#endif + + /* Note: It is not necessary to perform case insensitive comparison here, + even for DOS-like filesystems, because the pathname argument was + typically created from the same Makefile variable as orig_prefix came + from. */ + if (orig_prefix != NULL && curr_prefix != NULL + && strncmp (pathname, orig_prefix, orig_prefix_len) == 0) + { + if (pathname[orig_prefix_len] == '\0') + /* pathname equals orig_prefix. */ + return curr_prefix; + if (ISSLASH (pathname[orig_prefix_len])) + { + /* pathname starts with orig_prefix. */ + const char *pathname_tail = &pathname[orig_prefix_len]; + char *result = + (char *) xmalloc (curr_prefix_len + strlen (pathname_tail) + 1); + +#ifdef NO_XMALLOC + if (result != NULL) +#endif + { + memcpy (result, curr_prefix, curr_prefix_len); + strcpy (result + curr_prefix_len, pathname_tail); + return result; + } + } + } + /* Nothing to relocate. */ + return pathname; +} + +#endif diff -urN gawk-3.1.2/intl/relocatable.h gawk-3.1.3/intl/relocatable.h --- gawk-3.1.2/intl/relocatable.h 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/intl/relocatable.h 2003-06-16 03:25:33.000000000 -0700 @@ -0,0 +1,67 @@ +/* Provide relocatable packages. + Copyright (C) 2003 Free Software Foundation, Inc. + Written by Bruno Haible , 2003. + + This program is free software; you can redistribute it and/or modify it + under the terms of the GNU Library General Public License as published + by the Free Software Foundation; either version 2, or (at your option) + any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, + USA. */ + +#ifndef _RELOCATABLE_H +#define _RELOCATABLE_H + +/* This can be enabled through the configure --enable-relocatable option. */ +#if ENABLE_RELOCATABLE + +/* When building a DLL, we must export some functions. Note that because + this is a private .h file, we don't need to use __declspec(dllimport) + in any case. */ +#if defined _MSC_VER && BUILDING_DLL +# define RELOCATABLE_DLL_EXPORTED __declspec(dllexport) +#else +# define RELOCATABLE_DLL_EXPORTED +#endif + +/* Sets the original and the current installation prefix of the package. + Relocation simply replaces a pathname starting with the original prefix + by the corresponding pathname with the current prefix instead. Both + prefixes should be directory names without trailing slash (i.e. use "" + instead of "/"). */ +extern RELOCATABLE_DLL_EXPORTED void + set_relocation_prefix (const char *orig_prefix, + const char *curr_prefix); + +/* Returns the pathname, relocated according to the current installation + directory. */ +extern const char * relocate (const char *pathname); + +/* Memory management: relocate() leaks memory, because it has to construct + a fresh pathname. If this is a problem because your program calls + relocate() frequently, think about caching the result. */ + +/* Convenience function: + Computes the current installation prefix, based on the original + installation prefix, the original installation directory of a particular + file, and the current pathname of this file. Returns NULL upon failure. */ +extern const char * compute_curr_prefix (const char *orig_installprefix, + const char *orig_installdir, + const char *curr_pathname); + +#else + +/* By default, we use the hardwired pathnames. */ +#define relocate(pathname) (pathname) + +#endif + +#endif /* _RELOCATABLE_H */ diff -urN gawk-3.1.2/io.c gawk-3.1.3/io.c --- gawk-3.1.2/io.c 2003-02-25 02:32:30.000000000 -0800 +++ gawk-3.1.3/io.c 2003-07-04 10:50:58.000000000 -0700 @@ -103,6 +103,51 @@ typedef enum { CLOSE_ALL, CLOSE_TO, CLOSE_FROM } two_way_close_type; +/* Several macros make the code a bit clearer: */ +/* */ +/* */ +/* = */ +#define at_eof(iop) ((iop->flag & IOP_AT_EOF) != 0) +#define has_no_data(iop) (iop->dataend == NULL) +#define no_data_left(iop) (iop->off >= iop->dataend) +/* The key point to the design is to split out the code that searches through */ +/* a buffer looking for the record and the terminator into separate routines, */ +/* with a higher-level routine doing the reading of data and buffer management. */ +/* This makes the code easier to manage; the buffering code is the same independent */ +/* of how we find a record. Communication is via the return value: */ +/* */ +/* */ +/* = */ +typedef enum recvalues { + REC_OK, /* record and terminator found, recmatch struct filled in */ + NOTERM, /* no terminator found, give me more input data */ + TERMATEND, /* found terminator at end of buffer */ + TERMNEAREND, /* found terminator close to end of buffer, for RE might be bigger */ +} RECVALUE; +/* Between calls to a scanning routine, the state is stored in */ +/* an [[enum scanstate]] variable. Not all states apply to all */ +/* variants, but the higher code doesn't really care. */ +/* */ +/* */ +/* = */ +typedef enum scanstate { + NOSTATE, /* scanning not started yet (all) */ + INLEADER, /* skipping leading data (RS = "") */ + INDATA, /* in body of record (all) */ + INTERM, /* scanning terminator (RS = "", RS = regexp) */ +} SCANSTATE; +/* When a record is seen ([[REC_OK]] or [[TERMATEND]]), the following */ +/* structure is filled in. */ +/* */ +/* */ +/* = */ +struct recmatch { + char *start; /* record start */ + size_t len; /* length of record */ + char *rt_start; /* start of terminator */ + size_t rt_len; /* length of terminator */ +}; + static IOBUF *nextfile P((int skipping)); static int inrec P((IOBUF *iop)); static int iop_close P((IOBUF *iop)); @@ -125,11 +170,13 @@ static int two_way_open P((const char *str, struct redirect *rp)); static int pty_vs_pipe P((const char *command)); -static int rs1_get_a_record P((char **out, IOBUF *iop, int rs, Regexp *RSre, int *errcode)); -static int rsnull_get_a_record P((char **out, IOBUF *iop, int rs, Regexp *RSre, int *errcode)); -static int rsre_get_a_record P((char **out, IOBUF *iop, int rs, Regexp *RSre, int *errcode)); +static RECVALUE rs1scan P((IOBUF *iop, struct recmatch *recm, SCANSTATE *state)); +static RECVALUE rsnullscan P((IOBUF *iop, struct recmatch *recm, SCANSTATE *state)); +static RECVALUE rsrescan P((IOBUF *iop, struct recmatch *recm, SCANSTATE *state)); -static int (*get_a_record)P((char **out, IOBUF *iop, int rs, Regexp *RSre, int *errcode)) = rs1_get_a_record; +static RECVALUE (*matchrec) P((IOBUF *iop, struct recmatch *recm, SCANSTATE *state)) = rs1scan; + +static int get_a_record P((char **out, IOBUF *iop, int *errcode)); #if defined(HAVE_POPEN_H) #include "popen.h" @@ -152,7 +199,8 @@ static jmp_buf filebuf; /* for do_nextfile() */ -#if defined(MSDOS) || defined(OS2) || defined(WIN32) || defined(__EMX__) +#if defined(MSDOS) || defined(OS2) || defined(WIN32) \ + || defined(__EMX__) || defined(__CYGWIN__) static const char * binmode(const char *mode) { @@ -210,7 +258,7 @@ return NULL; } if (curfile != NULL) { - if ((curfile->flag & IOP_AT_EOF) != 0 && curfile->off >= curfile->dataend) { + if (at_eof(curfile)) { (void) iop_close(curfile); curfile = NULL; } else @@ -285,12 +333,12 @@ register int cnt; int retval = 0; - if ((iop->flag & IOP_AT_EOF) != 0 && iop->off >= iop->dataend) + if (at_eof(iop) && no_data_left(iop)) cnt = EOF; else if ((iop->flag & IOP_CLOSED) != 0) cnt = EOF; else - cnt = get_a_record(&begin, iop, RS->stptr[0], RS_regexp, NULL); + cnt = get_a_record(&begin, iop, NULL); if (cnt == EOF) { cnt = 0; @@ -785,6 +833,16 @@ fflush(stdout); /* synchronize regular output */ tmp = tmp_number((AWKNUM) close_redir(rp, FALSE, how)); rp = NULL; + /* + * POSIX says close() returns 0 on success, non-zero otherwise. + * For POSIX, at this point we just return 0. Otherwise we + * return the exit status of the process or of pclose(), depending. + * This whole business is a mess. + */ + if (do_posix) { + free_temp(tmp); + return tmp_number((AWKNUM) 0); + } return tmp; } @@ -1336,6 +1394,7 @@ iop->count = 0; iop->size = len; iop->end = iop->buf + len; + iop->dataend = iop->end; iop->fd = -1; iop->flag = IOP_IS_INTERNAL; } @@ -2186,7 +2245,7 @@ return tmp_number((AWKNUM) 0.0); } errcode = 0; - cnt = get_a_record(&s, iop, RS->stptr[0], RS_regexp, &errcode); + cnt = get_a_record(&s, iop, &errcode); if (errcode != 0) { if (! do_traditional) update_ERRNO(); @@ -2364,7 +2423,7 @@ lintwarn(_("data file `%s' is empty"), name); errno = 0; iop->fd = fd; - iop->count = iop->total = iop->scanoff = 0; + iop->count = iop->scanoff = 0; iop->name = name; emalloc(iop->buf, char *, iop->size += 2, "iop_alloc"); iop->off = iop->buf; @@ -2421,817 +2480,497 @@ iop->end = iop->buf + iop->size; } -/* = */ -static int -rs1_get_a_record(char **out, /* pointer to pointer to data */ - IOBUF *iop, /* input IOP */ - register int grRS, /* first char in RS->stptr */ - Regexp *RSre ATTRIBUTE_UNUSED, /* regexp for RS */ - int *errcode) /* pointer to error variable */ +/* Here are the routines. */ +/* */ +/* */ +/* = */ +/* rs1scan --- scan for a single character record terminator */ + +static RECVALUE +rs1scan(IOBUF *iop, struct recmatch *recm, SCANSTATE *state) { - /* We need a pointer into the buffer. */ - /* */ - /* = */ register char *bp; - long retval; + register char rs; #ifdef MBS_SUPPORT - size_t mbclen = 0; - mbstate_t mbs; + size_t mbclen = 0; + mbstate_t mbs; #endif + memset(recm, '\0', sizeof(struct recmatch)); + rs = RS->stptr[0]; + *(iop->dataend) = rs; /* set sentinel */ + recm->start = iop->off; /* beginning of record */ - /* The main code first checks if there was an EOF last */ - /* time around, and then sets up the pointers. */ - /* */ - /* */ - /* = */ - /* Upon EOF, set RT to null, set pointer to null, return EOF. */ - /* We don't do this unless we've also run out of data. */ - /* */ - /* */ - /* = */ - if ((iop->flag & IOP_AT_EOF) != 0 && iop->off >= iop->dataend) { - *out = NULL; - set_RT_to_null(); - return EOF; - } - /* First time around, set it to point to start of current record. */ - /* */ - /* */ - /* = */ bp = iop->off; + if (*state == INDATA) /* skip over data we've already seen */ + bp += iop->scanoff; - /* Most of the work is a for loop that expands the buffer, */ - /* and fills it, until the rs character is found. */ - /* */ - /* */ - /* = */ - for (;;) { - /* = */ - if (/* If there's data in the buffer, and we're pointing at the end of it, */ - /* grow the buffer. */ - /* */ - /* */ - /* = */ - (iop->flag & IOP_AT_EOF) == 0 && - iop->dataend != NULL && bp >= iop->dataend) { - if (iop->off > iop->buf) { - /* Moving the data requires remembering how far off the */ - /* dataend pointer was and the bp pointer too. */ - /* */ - /* = */ - size_t dataend_off = iop->dataend - iop->off; - memmove(iop->buf, iop->off, dataend_off); - iop->off = iop->buf; - bp = iop->dataend = iop->buf + dataend_off; - - /* = */ - bp = iop->dataend; - } else { - /* = */ - iop->scanoff = bp - iop->off; - grow_iop_buffer(iop); - bp = iop->off + iop->scanoff; +#ifdef MBS_SUPPORT + /* + * From: Bruno Haible + * To: Aharon Robbins , gnits@gnits.org + * Subject: Re: multibyte locales: any way to find if a character isn't multibyte? + * Date: Mon, 23 Jun 2003 12:20:16 +0200 + * Cc: isamu@yamato.ibm.com + * + * Hi, + * + * > Is there any way to make the following query to the current locale? + * > + * > Given an 8-bit value, can this value ever appear as part of + * > a multibyte character? + * + * There is no simple answer here. The easiest solution I see is to + * get the current locale's codeset (via locale_charset() which is a + * wrapper around nl_langinfo(CODESET)), and then perform a case-by-case + * treatment of the known multibyte encodings, from GB2312 to EUC-JISX0213; + * for the unibyte encodings, a single btowc() call will tell you. + * + * > This is particularly critical for me for ASCII newline ('\n'). If I + * > can be guaranteed that it never shows up as part of a multibyte character, + * > I can speed up gawk considerably in mulitbyte locales. + * + * This is much simpler to answer! + * In all ASCII based multibyte encodings used for locales today (this + * excludes EBCDIC based doublebyte encodings from IBM, and also excludes + * ISO-2022-JP which is used for email exchange but not as a locale encoding) + * ALL bytes in the range 0x00..0x2F occur only as a single character, not + * as part of a multibyte character. + * + * So it's safe to assume, but deserves a comment in the source. + * + * Bruno + *************************************************************** + * From: Bruno Haible + * To: Aharon Robbins + * Subject: Re: multibyte locales: any way to find if a character isn't multibyte? + * Date: Mon, 23 Jun 2003 14:27:49 +0200 + * + * On Monday 23 June 2003 14:11, you wrote: + * + * > if (rs != '\n' && MB_CUR_MAX > 1) { + * + * If you assume ASCII, you can even write + * + * if (rs >= 0x30 && MB_CUR_MAX > 1) { + * + * (this catches also the space character) but if portability to EBCDIC + * systems is desired, your code is fine as is. + * + * Bruno + */ + /* Thus, the check for \n here; big speedup ! */ + if (rs != '\n' && gawk_mb_cur_max > 1) { + int len = iop->dataend - bp; + int found = 0; + memset(&mbs, 0, sizeof(mbstate_t)); + do { + if (*bp == rs) + found = 1; + mbclen = mbrlen(bp, len, &mbs); + if ((mbclen == 1) || (mbclen == (size_t) -1) + || (mbclen == (size_t) -2) || (mbclen == 0)) { + /* We treat it as a singlebyte character. */ + mbclen = 1; } - } - - /* no data in buffer or ran out of data */ - if ((iop->flag & IOP_AT_EOF) == 0 && (iop->dataend == NULL || bp >= iop->dataend)) { + len -= mbclen; + bp += mbclen; + } while (len > 0 && ! found); + + /* Check that newline found isn't the sentinel. */ + if (found && (bp - mbclen) < iop->dataend) { + /* + * set len to what we have so far, in case this is + * all there is + */ + recm->len = bp - recm->start - mbclen; + recm->rt_start = bp - mbclen; + recm->rt_len = mbclen; + *state = NOSTATE; + return REC_OK; + } else { + /* also set len */ + recm->len = bp - recm->start; + *state = INDATA; iop->scanoff = bp - iop->off; - if (iop->dataend == NULL) { - iop->dataend = iop->buf; /* first read */ - if ((iop->flag & IOP_IS_INTERNAL) != 0) - iop->dataend += strlen(iop->buf); - } - /* Use read to put more data into the buffer. If we've read */ - /* as many characters as in the file, don't try to read more. */ - /* */ - /* */ - /* = */ - if ((iop->flag & IOP_IS_INTERNAL) != 0) { - iop->flag |= IOP_AT_EOF; - } else if (S_ISREG(iop->sbuf.st_mode) && iop->total >= iop->sbuf.st_size) - iop->flag |= IOP_AT_EOF; - else { -#define min(x, y) (x < y ? x : y) - /* subtract one in read count to leave room for sentinel */ - size_t room_left = iop->end - iop->dataend - 1; - size_t amt_to_read = min(iop->readsize, room_left); - - if (amt_to_read < iop->readsize) { - /* = */ - iop->scanoff = bp - iop->off; - grow_iop_buffer(iop); - bp = iop->off + iop->scanoff; - /* recalculate amt_to_read */ - room_left = iop->end - iop->dataend - 1; - amt_to_read = min(iop->readsize, room_left); - } - while (amt_to_read + iop->readsize < room_left) - amt_to_read += iop->readsize; - - iop->count = read(iop->fd, iop->dataend, amt_to_read); - if (iop->count == -1) { - if (! do_traditional && errcode != NULL) { - *errcode = errno; - iop->flag |= IOP_AT_EOF; - break; - } else - fatal(_("error reading input file `%s': %s"), - iop->name, strerror(errno)); - } else if (iop->count == 0) { - /* - * hit EOF before matching RS, so end - * the record and set RT to "" - */ - iop->flag |= IOP_AT_EOF; - } - else { - iop->dataend += iop->count; - iop->total += iop->count; - if (S_ISREG(iop->sbuf.st_mode) && iop->total >= iop->sbuf.st_size) - iop->flag |= IOP_AT_EOF; - /* reset the sentinel */ - /* = */ - *iop->dataend = grRS; - + return NOTERM; + } + } +#endif + while (*bp != rs) + bp++; - } - } + /* set len to what we have so far, in case this is all there is */ + recm->len = bp - recm->start; - bp = iop->off + iop->scanoff; - } + if (bp < iop->dataend) { /* found it in the buffer */ + recm->rt_start = bp; + recm->rt_len = 1; + *state = NOSTATE; + return REC_OK; + } else { + *state = INDATA; + iop->scanoff = bp - iop->off; + return NOTERM; + } +} - /* = */ - *iop->dataend = grRS; +/* = */ +/* rsrescan --- search for a regex match in the buffer */ +static RECVALUE +rsrescan(IOBUF *iop, struct recmatch *recm, SCANSTATE *state) +{ + register char *bp; + size_t restart = 0, reend = 0; + Regexp *RSre = RS_regexp; + memset(recm, '\0', sizeof(struct recmatch)); + recm->start = iop->off; - /* search for rs */ -#ifdef MBS_SUPPORT - if (gawk_mb_cur_max > 1) { - int len = iop->end - bp + 1; - int found = 0; - memset(&mbs, 0, sizeof(mbstate_t)); - do { - if (*bp == grRS) - found = 1; - mbclen = mbrlen(bp, len, &mbs); - if ((mbclen == 1) || (mbclen == (size_t) -1) - || (mbclen == (size_t) -2) || (mbclen == 0)) { - /* We treat it as a singlebyte character. */ - mbclen = 1; - } - len -= mbclen; - bp += mbclen; - } while (len > 0 && ! found); - } else -#endif - while (*bp++ != grRS) - continue; + bp = iop->off; + if (*state == INDATA) + bp += iop->scanoff; - /* At the end of the loop, if the rs char is found in the buffer, */ - /* break. Otherwise, back the pointer up and then check for EOF. */ - /* If an internal file, break. */ - /* If EOF, break. */ - /* */ - /* */ - /* = */ - /* bp is one past newline that marks end of record */ - if (bp <= iop->dataend) /* found it in the buffer, not the sentinel */ - break; +again: + /* case 1, no match */ + if (research(RSre, bp, 0, iop->dataend - bp, TRUE) == -1) { + /* set len, in case this all there is. */ + recm->len = iop->dataend - iop->off - 1; + return NOTERM; + } - if ((iop->flag & IOP_IS_INTERNAL) != 0) { - iop->flag |= IOP_AT_EOF; - break; + /* ok, we matched within the buffer, set start and end */ + restart = RESTART(RSre, iop->off); + reend = REEND(RSre, iop->off); + + /* case 2, null regex match, grow buffer, try again */ + if (restart == reend) { + *state = INDATA; + iop->scanoff = reend + 1; + /* + * If still room in buffer, skip over null match + * and restart search. Otherwise, return. + */ + if (bp + iop->scanoff < iop->dataend) { + bp += iop->scanoff; + goto again; } + recm->len = (bp - iop->off) + restart; + return NOTERM; + } - if ((iop->flag & IOP_AT_EOF) != 0) - break; + /* + * At this point, we have a non-empty match. + * + * First, fill in rest of data. The rest of the cases return + * a record and terminator. + */ + recm->len = restart; + recm->rt_start = bp + restart; + recm->rt_len = reend - restart; + *state = NOSTATE; + + /* + * 3. Match exactly at end: + * if re is a simple string match + * found a simple string match at end, return REC_OK + * else + * grow buffer, add more data, try again + * fi + */ + if (iop->off + reend >= iop->dataend) { + if (reisstring(RS->stptr, RS->stlen, RSre, iop->off)) + return REC_OK; + else + return TERMATEND; + } - /* bp points one past sentinel, back it up for buffer management code */ - bp--; + /* + * 4. Match within xxx bytes of end & maybe islong re: + * return TERMNEAREND + */ + + /* + * case 4, match succeeded, but there may be more in + * the next input buffer. + * + * Consider an RS of xyz(abc)? where the + * exact end of the buffer is xyza and the + * next two, unread, characters are bc. + * + * This matches the "xyz" and ends up putting the + * "abc" into the front of the next record. Ooops. + * + * The remaybelong() function looks to see if the + * regex contains one of: + * ? |. This is a very + * simple heuristic, but in combination with the + * "end of match within a few bytes of end of buffer" + * check, should keep things reasonable. + */ + + /* + * XXX: The reisstring and remaybelong tests should + * really be done once when RS is assigned to and + * then tested as flags here. Maybe one day. + */ + + /* succession of tests is easier to trace in GDB. */ + if (remaybelong(RS->stptr, RS->stlen)) { + char *matchend = iop->off + reend; - /* hit end of data in buffer, continue around to find more */ + if (iop->dataend - matchend < RS->stlen) + return TERMNEAREND; } - /* Once out of the loop, either we hit EOF, or we found the */ - /* character. */ - /* */ - /* */ - /* = */ - /* now out of loop: either we hit EOF, or we found rs */ - /* Upon EOF, set RT to null, set pointer to null, return EOF. */ - /* We don't do this unless we've also run out of data. */ - /* */ - /* */ - /* = */ - if ((iop->flag & IOP_AT_EOF) != 0 && iop->off >= iop->dataend) { - *out = NULL; - set_RT_to_null(); - return EOF; - } + return REC_OK; +} - /* found rs, return the record */ - *out = iop->off; - retval = bp - iop->off - 1; - iop->off = bp; /* set up for next time */ - - /* set RT */ - set_RT(bp - 1, 1); - - return retval; -} -/* This next part deals with the case of RS = "". The goal is to */ -/* 1. skip any leading newlines */ -/* 2. scan through for multiple newlines */ -/* 3. If hit the end of the buffer, shuffle things down and refill */ -/* and keep going. */ -/* */ -/* */ -/* = */ -static int -rsnull_get_a_record(char **out, /* pointer to pointer to data */ - IOBUF *iop, /* input IOP */ - register int grRS, /* first char in RS->stptr */ - Regexp *RSre ATTRIBUTE_UNUSED, /* regexp for RS */ - int *errcode) /* pointer to error variable */ +/* = */ +/* rsnullscan --- handle RS = "" */ + +static RECVALUE +rsnullscan(IOBUF *iop, struct recmatch *recm, SCANSTATE *state) { - /* We will need at least a buffer pointer so that hopefully */ - /* some of the litprog code can be reused. */ - /* */ - /* */ - /* = */ register char *bp; - long retval; - /* 2. Start scanning the buffer for newlines. If we hit one, look for another; */ - /* we need at least 2 successive newlines to terminate the record. */ - /* */ - /* If we find two, save the location of the first one so we can set RT */ - /* correctly. Then continue scanning; if we hit the end of the buffer, */ - /* we may need to save our state in order to expand the buffer. */ - /* */ - /* If we hit the end of the buffer without seeing any newlines, then */ - /* we need to save grow the buffer and keep going. */ - /* */ - /* */ - /* = */ - size_t firstnl = 0; - int restarting = FALSE; - char *rt_start = NULL; - - - /* ensure real sentinel value */ - grRS = '\n'; - - /* Much of the code is similar to the rs1 case: */ - /* */ - /* */ - /* = */ - /* Upon EOF, set RT to null, set pointer to null, return EOF. */ - /* We don't do this unless we've also run out of data. */ - /* */ - /* */ - /* = */ - if ((iop->flag & IOP_AT_EOF) != 0 && iop->off >= iop->dataend) { - *out = NULL; - set_RT_to_null(); - return EOF; - } - /* First time around, set it to point to start of current record. */ - /* */ - /* */ - /* = */ - bp = iop->off; - /* The main loop is similar but not identical. */ - /* */ - /* */ - /* = */ - for (;;) { - /* = */ - if (/* If there's data in the buffer, and we're pointing at the end of it, */ - /* grow the buffer. */ - /* */ - /* */ - /* = */ - (iop->flag & IOP_AT_EOF) == 0 && - iop->dataend != NULL && bp >= iop->dataend) { - if (iop->off > iop->buf) { - /* Moving the data requires remembering how far off the */ - /* dataend pointer was and the bp pointer too. */ - /* */ - /* = */ - size_t dataend_off = iop->dataend - iop->off; - memmove(iop->buf, iop->off, dataend_off); - iop->off = iop->buf; - bp = iop->dataend = iop->buf + dataend_off; - - /* = */ - bp = iop->dataend; - } else { - /* = */ - iop->scanoff = bp - iop->off; - grow_iop_buffer(iop); - bp = iop->off + iop->scanoff; - } - } + if (*state == NOSTATE || *state == INLEADER) + memset(recm, '\0', sizeof(struct recmatch)); - /* no data in buffer or ran out of data */ - if ((iop->flag & IOP_AT_EOF) == 0 && (iop->dataend == NULL || bp >= iop->dataend)) { - iop->scanoff = bp - iop->off; - if (iop->dataend == NULL) { - iop->dataend = iop->buf; /* first read */ - if ((iop->flag & IOP_IS_INTERNAL) != 0) - iop->dataend += strlen(iop->buf); - } - /* Use read to put more data into the buffer. If we've read */ - /* as many characters as in the file, don't try to read more. */ - /* */ - /* */ - /* = */ - if ((iop->flag & IOP_IS_INTERNAL) != 0) { - iop->flag |= IOP_AT_EOF; - } else if (S_ISREG(iop->sbuf.st_mode) && iop->total >= iop->sbuf.st_size) - iop->flag |= IOP_AT_EOF; - else { -#define min(x, y) (x < y ? x : y) - /* subtract one in read count to leave room for sentinel */ - size_t room_left = iop->end - iop->dataend - 1; - size_t amt_to_read = min(iop->readsize, room_left); - - if (amt_to_read < iop->readsize) { - /* = */ - iop->scanoff = bp - iop->off; - grow_iop_buffer(iop); - bp = iop->off + iop->scanoff; - /* recalculate amt_to_read */ - room_left = iop->end - iop->dataend - 1; - amt_to_read = min(iop->readsize, room_left); - } - while (amt_to_read + iop->readsize < room_left) - amt_to_read += iop->readsize; - - iop->count = read(iop->fd, iop->dataend, amt_to_read); - if (iop->count == -1) { - if (! do_traditional && errcode != NULL) { - *errcode = errno; - iop->flag |= IOP_AT_EOF; - break; - } else - fatal(_("error reading input file `%s': %s"), - iop->name, strerror(errno)); - } else if (iop->count == 0) { - /* - * hit EOF before matching RS, so end - * the record and set RT to "" - */ - iop->flag |= IOP_AT_EOF; - } - else { - iop->dataend += iop->count; - iop->total += iop->count; - if (S_ISREG(iop->sbuf.st_mode) && iop->total >= iop->sbuf.st_size) - iop->flag |= IOP_AT_EOF; - /* reset the sentinel */ - /* = */ - *iop->dataend = grRS; + recm->start = iop->off; + bp = iop->off; + if (*state != NOSTATE) + bp += iop->scanoff; - } - } + /* set sentinel */ + *(iop->dataend) = '\n'; - bp = iop->off + iop->scanoff; - } + if (*state == INTERM) + goto find_longest_terminator; + else if (*state == INDATA) + goto scan_data; + /* else + fall into things from beginning, + either NOSTATE or INLEADER */ + +/* skip_leading: */ + /* leading newlines are ignored */ + while (*bp == '\n' && bp < iop->dataend) + bp++; + + if (bp >= iop->dataend) { /* LOTS of leading newlines, sheesh. */ + *state = INLEADER; + iop->scanoff = bp - iop->off; + return NOTERM; + } - /* = */ - *iop->dataend = grRS; + iop->off = recm->start = bp; /* real start of record */ +scan_data: + while (*bp++ != '\n') + continue; + + if (bp >= iop->dataend) { /* no terminator */ + iop->scanoff = recm->len = bp - iop->off - 1; + *state = INDATA; + return NOTERM; + } + /* found one newline before end of buffer, check next char */ + if (*bp != '\n') + goto scan_data; + /* we've now seen at least two newlines */ + *state = INTERM; + recm->len = bp - iop->off - 1; + recm->rt_start = bp - 1; - /* The 2.15.6 logic doesn't seem to do the trick, let's do it */ - /* ourselves. We need to handle the following things. */ - /* */ - /* 1. Skip any leading newlines in front of the record, they don't count. */ - /* NOT leading whitespace, just newlines. See the comment, too. */ - /* */ - /* */ - /* = */ - /* - * skip any newlines at the front of the buffer, - * either in front of first record, or after previous - * record, e.g. if RS changed in the middle - * (see test/nulrsend) - */ - if (*bp == '\n') { - while (bp < iop->dataend && *bp == '\n') - bp++; - if (bp == iop->dataend) { - if ((iop->flag & IOP_AT_EOF) == 0) - continue; /* fill buffer, there's LOTS of leading newlines */ - else { - /* bug out early */ - iop->off = iop->dataend; - *out = NULL; - set_RT_to_null(); - return EOF; - } - } else { - iop->off = bp; - } - } - /* = */ - /* - * This code entered if we previously hit the first - * newline at exactly the end of the buffer. - */ - if (firstnl && restarting) { - restarting = FALSE; - /* - * back up to just before first newline so following - * logic always works. - */ - bp = iop->off + firstnl - 1; - firstnl = 0; - } +find_longest_terminator: + /* find as many newlines as we can, to set RT */ + while (*bp == '\n' && bp < iop->dataend) + bp++; - /* we make use of the sentinel, so we don't have to check bp < iop->dataend */ - more: - while (*bp++ != '\n') - continue; - - if (bp >= iop->dataend && (iop->flag & IOP_AT_EOF) == 0) /* end of buffer */ - continue; /* refill, start over */ - else if (bp == (iop->dataend - 1) && (iop->flag & IOP_AT_EOF) == 0) { - /* one newline exactly at end, AND not at EOF */ - firstnl = bp - iop->off; - restarting = TRUE; - bp++; - continue; /* refill, earlier logic catches */ - } + recm->rt_len = bp - recm->rt_start; + iop->scanoff = bp - iop->off; - /* found one newline */ - if (*bp != '\n' && bp < iop->dataend) - goto more; /* only one */ - - rt_start = bp - 1; /* prev char was first newline, *bp is second */ - while (bp < iop->dataend && *bp == '\n') - bp++; - - if (bp >= iop->dataend && (iop->flag & IOP_AT_EOF) == 0) { - firstnl = bp - iop->off; - restarting = TRUE; - continue; - } else - break; /* got the record, done */ + if (bp >= iop->dataend) + return TERMATEND; + + return REC_OK; +} +/* = */ +/* get_a_record --- read a record from IOP into out, return length of EOF, set RT */ +int +get_a_record(char **out, /* pointer to pointer to data */ + IOBUF *iop, /* input IOP */ + int *errcode) /* pointer to error variable */ +{ + struct recmatch recm; + SCANSTATE state; + RECVALUE ret; + int retval; + NODE *rtval = NULL; + static RECVALUE (*lastmatchrec)P((IOBUF *iop, struct recmatch *recm, SCANSTATE *state)) = NULL; - /* Here's the logic when the record has been identified. */ - /* */ - /* */ - /* = */ + if (at_eof(iop) && no_data_left(iop)) + return EOF; - if ((iop->flag & IOP_IS_INTERNAL) != 0) { + /* = */ + if (has_no_data(iop) || no_data_left(iop)) { + iop->count = read(iop->fd, iop->buf, iop->readsize); + if (iop->count == 0) { iop->flag |= IOP_AT_EOF; - break; + return EOF; + } else if (iop->count == -1) { + if (! do_traditional && errcode != NULL) { + *errcode = errno; + iop->flag |= IOP_AT_EOF; + return EOF; + } else + fatal(_("error reading input file `%s': %s"), + iop->name, strerror(errno)); + } else { + iop->dataend = iop->buf + iop->count; + iop->off = iop->buf; } - - if ((iop->flag & IOP_AT_EOF) != 0) - break; - - - /* hit end of data in buffer, continue around to find more */ } - /* = */ - /* now out of loop: either we hit EOF, or we found rs */ - /* Upon EOF, set RT to null, set pointer to null, return EOF. */ - /* We don't do this unless we've also run out of data. */ - /* */ - /* */ - /* = */ - if ((iop->flag & IOP_AT_EOF) != 0 && iop->off >= iop->dataend) { - *out = NULL; - set_RT_to_null(); - return EOF; - } - set_RT(rt_start, bp - rt_start); - /* found rs, return the record */ - *out = iop->off; - retval = rt_start - iop->off; - iop->off = bp; /* set up for next time */ + /* = */ + state = NOSTATE; + for (;;) { + size_t dataend_off; - return retval; -} -/* Now the hardest part, regex separated records. */ -/* */ -/* */ -/* = */ -static int -rsre_get_a_record(char **out, /* pointer to pointer to data */ - IOBUF *iop, /* input IOP */ - register int grRS, /* first char in RS->stptr */ - Regexp *RSre, /* regexp for RS */ - int *errcode) /* pointer to error variable */ -{ - /* Local vars are similar: */ - /* */ - /* */ - /* = */ - register char *bp; - long retval; - size_t restart = 0, reend = 0; - int set_res = FALSE; + ret = (*matchrec)(iop, & recm, & state); + if (ret == REC_OK) + break; - /* And the basic code is also similar: */ - /* */ - /* */ - /* = */ - /* Upon EOF, set RT to null, set pointer to null, return EOF. */ - /* We don't do this unless we've also run out of data. */ - /* */ - /* */ - /* = */ - if ((iop->flag & IOP_AT_EOF) != 0 && iop->off >= iop->dataend) { - *out = NULL; - set_RT_to_null(); - return EOF; - } - /* First time around, set it to point to start of current record. */ - /* */ - /* */ - /* = */ - bp = iop->off; + /* need to add more data to buffer */ + /* = */ + dataend_off = iop->dataend - iop->off; + memmove(iop->buf, iop->off, dataend_off); + iop->off = iop->buf; + iop->dataend = iop->buf + dataend_off; + + /* = */ + recm.start = iop->off; + if (recm.rt_start != NULL) + recm.rt_start = iop->off + recm.len; + /* = */ + if ((iop->flag & IOP_IS_INTERNAL) != 0) { + iop->flag |= IOP_AT_EOF; + break; + } else { +#define min(x, y) (x < y ? x : y) + /* subtract one in read count to leave room for sentinel */ + size_t room_left = iop->end - iop->dataend - 1; + size_t amt_to_read = min(iop->readsize, room_left); - /* Here is the main loop: */ - /* */ - /* */ - /* = */ - for (;;) { - /* = */ - if (/* If there's data in the buffer, and we're pointing at the end of it, */ - /* grow the buffer. */ - /* */ - /* */ - /* = */ - (iop->flag & IOP_AT_EOF) == 0 && - iop->dataend != NULL && bp >= iop->dataend) { - if (iop->off > iop->buf) { - /* Moving the data requires remembering how far off the */ - /* dataend pointer was and the bp pointer too. */ - /* */ - /* = */ - size_t dataend_off = iop->dataend - iop->off; - memmove(iop->buf, iop->off, dataend_off); - iop->off = iop->buf; - bp = iop->dataend = iop->buf + dataend_off; - - /* = */ - bp = iop->dataend; - } else { - /* = */ - iop->scanoff = bp - iop->off; + if (amt_to_read < iop->readsize) { grow_iop_buffer(iop); - bp = iop->off + iop->scanoff; + /* = */ + recm.start = iop->off; + if (recm.rt_start != NULL) + recm.rt_start = iop->off + recm.len; + + /* recalculate amt_to_read */ + room_left = iop->end - iop->dataend - 1; + amt_to_read = min(iop->readsize, room_left); } - } + while (amt_to_read + iop->readsize < room_left) + amt_to_read += iop->readsize; - /* no data in buffer or ran out of data */ - if ((iop->flag & IOP_AT_EOF) == 0 && (iop->dataend == NULL || bp >= iop->dataend)) { - iop->scanoff = bp - iop->off; - if (iop->dataend == NULL) { - iop->dataend = iop->buf; /* first read */ - if ((iop->flag & IOP_IS_INTERNAL) != 0) - iop->dataend += strlen(iop->buf); - } - /* Use read to put more data into the buffer. If we've read */ - /* as many characters as in the file, don't try to read more. */ - /* */ - /* */ - /* = */ - if ((iop->flag & IOP_IS_INTERNAL) != 0) { - iop->flag |= IOP_AT_EOF; - } else if (S_ISREG(iop->sbuf.st_mode) && iop->total >= iop->sbuf.st_size) - iop->flag |= IOP_AT_EOF; - else { -#define min(x, y) (x < y ? x : y) - /* subtract one in read count to leave room for sentinel */ - size_t room_left = iop->end - iop->dataend - 1; - size_t amt_to_read = min(iop->readsize, room_left); - - if (amt_to_read < iop->readsize) { - /* = */ - iop->scanoff = bp - iop->off; - grow_iop_buffer(iop); - bp = iop->off + iop->scanoff; - /* recalculate amt_to_read */ - room_left = iop->end - iop->dataend - 1; - amt_to_read = min(iop->readsize, room_left); - } - while (amt_to_read + iop->readsize < room_left) - amt_to_read += iop->readsize; - - iop->count = read(iop->fd, iop->dataend, amt_to_read); - if (iop->count == -1) { - if (! do_traditional && errcode != NULL) { - *errcode = errno; - iop->flag |= IOP_AT_EOF; - break; - } else - fatal(_("error reading input file `%s': %s"), - iop->name, strerror(errno)); - } else if (iop->count == 0) { - /* - * hit EOF before matching RS, so end - * the record and set RT to "" - */ + iop->count = read(iop->fd, iop->dataend, amt_to_read); + if (iop->count == -1) { + if (! do_traditional && errcode != NULL) { + *errcode = errno; iop->flag |= IOP_AT_EOF; - } - else { - iop->dataend += iop->count; - iop->total += iop->count; - if (S_ISREG(iop->sbuf.st_mode) && iop->total >= iop->sbuf.st_size) - iop->flag |= IOP_AT_EOF; - /* reset the sentinel */ - /* = */ - *iop->dataend = grRS; + break; + } else + fatal(_("error reading input file `%s': %s"), + iop->name, strerror(errno)); + } else if (iop->count == 0) { + /* + * hit EOF before matching RS, so end + * the record and set RT to "" + */ + iop->flag |= IOP_AT_EOF; + break; + } else + iop->dataend += iop->count; + } - } - } + } - bp = iop->off + iop->scanoff; - } - /* not needed for rsre, but doesn't hurt: */ - /* = */ - *iop->dataend = grRS; + /* = */ + /* + * rtval is not a static pointer to avoid dangling pointer problems + * in case awk code assigns to RT. A remote possibility, to be sure, + * but Bitter Experience teaches us not to make ``that'll never + * happen'' kinds of assumptions. + */ + rtval = RT_node->var_value; - /* The hard part is the logic for regex matching. */ - /* Start by searching the buffer for a match. Cases: */ - /* */ - /* 1. No match */ - /* if not eof then */ - /* grow buffer, add more data, try again */ - /* else */ - /* set RT to null */ - /* return the record */ - /* endif */ - /* */ - /* = */ - /* case 1, no match */ - if (research(RSre, iop->off, 0, iop->dataend - iop->off, TRUE) == -1) { - if ((iop->flag & IOP_AT_EOF) == 0) { - bp = iop->dataend; - continue; - } else { - *out = iop->off; - retval = iop->dataend - iop->off; - iop->off = iop->dataend; - set_RT_to_null(); - return retval; - } - } - /* 1a. Save the match info in variables for debugging, */ - /* and readability. */ - /* */ - /* */ - /* = */ - restart = RESTART(RSre, iop->off); - reend = REEND(RSre, iop->off); - set_res = TRUE; - - /* 2. Match entirely within the bounds of the buffer: */ - /* fill in RT */ - /* break from loop to return record */ - /* */ - /* */ - /* = */ - /* case 2 is simple, just keep going */ - if (restart == reend) { - bp = iop->dataend; - continue; - } - /* 3. Match exactly at end: */ - /* if not eof and re is not a simple string match */ - /* grow buffer, add more data, try again */ - /* else */ - /* break from loop to set RT and return record */ - /* fi */ - /* */ - /* */ - /* = */ - if (iop->off + reend >= iop->dataend) { - if ((iop->flag & IOP_AT_EOF) == 0 - && ! reisstring(RS->stptr, RS->stlen, RSre, iop->off)) { - bp = iop->dataend; - continue; - } else { - break; - } - } - /* 4. Match within xxx bytes of end & maybe islong re: */ - /* if not eof */ - /* grow buffer, add mor data, try again */ - /* else */ - /* fill in RT */ - /* break from loop to return record */ - /* fi */ - /* */ - /* */ - /* = */ + if (recm.rt_len == 0) { + set_RT_to_null(); + lastmatchrec = NULL; + } else { + assert(recm.rt_start != NULL); /* - * case 4, match succeeded, but there may be more in - * the next input buffer. - * - * Consider an RS of xyz(abc)? where the - * exact end of the buffer is xyza and the - * next two, unread, characters are bc. + * Optimization. For rs1 case, don't set RT if + * character is same as last time. This knocks a + * chunk of time off something simple like * - * This matches the "xyz" and ends up putting the - * "abc" into the front of the next record. Ooops. + * gawk '{ print }' /some/big/file * - * The remaybelong() function looks to see if the - * regex contains one of: + * ? |. This is a very - * simple heuristic, but in combination with the - * "end of match within a few bytes of end of buffer" - * check, should keep things reasonable. - */ - - /* - * XXX: The reisstring and remaybelong tests should - * really be done once when RS is assigned to and - * then tested as flags here. Maybe one day. + * Similarly, for rsnull case, if length of new RT is + * shorter than current RT, just bump length down in RT. + * + * Make sure that matchrec didn't change since the last + * check. (Ugh, details, details, details.) */ - - /* succession of tests is easier to trace in GDB. */ - if ((iop->flag & IOP_AT_EOF) == 0) { - if (remaybelong(RS->stptr, RS->stlen)) { - char *matchend = iop->off + reend; - - if (iop->dataend - matchend < RS->stlen) { - bp = iop->dataend; - continue; - } - } - } - - - - /* Here is the end loop logic. */ - /* */ - /* */ - /* = */ - if (bp <= iop->dataend) { - break; + if (lastmatchrec == NULL || lastmatchrec != matchrec) { + lastmatchrec = matchrec; + set_RT(recm.rt_start, recm.rt_len); + } else if (matchrec == rs1scan) { + if (rtval->stlen != 1 || rtval->stptr[0] != recm.rt_start[0]) + set_RT(recm.rt_start, recm.rt_len); + /* else + leave it alone */ + } else if (matchrec == rsnullscan) { + if (rtval->stlen <= recm.rt_len) + rtval->stlen = recm.rt_len; + else + set_RT(recm.rt_start, recm.rt_len); } else - bp--; - - if ((iop->flag & IOP_IS_INTERNAL) != 0) { - iop->flag |= IOP_AT_EOF; - break; - } - - if ((iop->flag & IOP_AT_EOF) != 0) - break; - - - /* hit end of data in buffer, continue around to find more */ + set_RT(recm.rt_start, recm.rt_len); } - /* And the end of function logic: */ - /* */ - /* */ - /* = */ - /* now out of loop: either we hit EOF, or we found rs */ - /* Upon EOF, set RT to null, set pointer to null, return EOF. */ - /* We don't do this unless we've also run out of data. */ - /* */ - /* */ - /* = */ - if ((iop->flag & IOP_AT_EOF) != 0 && iop->off >= iop->dataend) { + + if (recm.len == 0) { *out = NULL; - set_RT_to_null(); - return EOF; + retval = 0; + } else { + assert(recm.start != NULL); + *out = recm.start; + retval = recm.len; } - /* found rs, return the record */ + iop->off += recm.len + recm.rt_len; - assert(set_res); - /* set RT before adjusting pointers in iop. */ - set_RT(iop->off + restart, reend - restart); - - *out = iop->off; - retval = (iop->off + restart) - iop->off; - iop->off += reend; + if (recm.len == 0 && recm.rt_len == 0 && at_eof(iop)) + return EOF; + else + return retval; - return retval; } /* set_RS --- update things as appropriate when RS is set */ @@ -3267,7 +3006,7 @@ } if (RS->stlen == 0) { RS_is_null = TRUE; - get_a_record = rsnull_get_a_record; + matchrec = rsnullscan; } else if (RS->stlen > 1) { static int warned = FALSE; @@ -3275,14 +3014,14 @@ RS_re_no_case = make_regexp(RS->stptr, RS->stlen, TRUE); RS_regexp = (IGNORECASE ? RS_re_no_case : RS_re_yes_case); - get_a_record = rsre_get_a_record; + matchrec = rsrescan; if (do_lint && ! warned) { lintwarn(_("multicharacter value of `RS' is a gawk extension")); warned = TRUE; } } else - get_a_record = rs1_get_a_record; + matchrec = rs1scan; set_FS: if (! using_fieldwidths()) set_FS(); @@ -3336,7 +3075,7 @@ const char * iopflags2str(int flag) { - static struct flagtab values[] = { + static const struct flagtab values[] = { { IOP_IS_TTY, "IOP_IS_TTY" }, { IOP_IS_INTERNAL, "IOP_IS_INTERNAL" }, { IOP_NO_FREE, "IOP_NO_FREE" }, diff -urN gawk-3.1.2/m4/ChangeLog gawk-3.1.3/m4/ChangeLog --- gawk-3.1.2/m4/ChangeLog 2003-03-19 04:23:01.000000000 -0800 +++ gawk-3.1.3/m4/ChangeLog 2003-07-07 11:02:14.000000000 -0700 @@ -1,3 +1,27 @@ +Mon Jul 7 11:01:43 2003 Arnold D. Robbins + + * Release 3.1.3: Release tar file made. + +2003-06-16 gettextize + + * gettext.m4: Upgrade to gettext-0.12.1. + * inttypes_h.m4: Upgrade to gettext-0.12.1. + * lib-ld.m4: Upgrade to gettext-0.12.1. + * lib-link.m4: Upgrade to gettext-0.12.1. + * lib-prefix.m4: Upgrade to gettext-0.12.1. + * nls.m4: New file, from gettext-0.12.1. + * po.m4: New file, from gettext-0.12.1. + * progtest.m4: Upgrade to gettext-0.12.1. + * stdint_h.m4: Upgrade to gettext-0.12.1. + * uintmax_t.m4: New file, from gettext-0.12.1. + * ulonglong.m4: New file, from gettext-0.12.1. + * Makefile.am: New file. + +2003-03-26 Paul Eggert + + * longlong.m4, intmax_t.m4: New files. + * ulonglong.m4, uintmax_t.m4: Removed. + Wed Mar 19 14:10:31 2003 Arnold D. Robbins This time for sure. diff -urN gawk-3.1.2/m4/gettext.m4 gawk-3.1.3/m4/gettext.m4 --- gawk-3.1.2/m4/gettext.m4 2002-09-19 01:00:08.000000000 -0700 +++ gawk-3.1.3/m4/gettext.m4 2003-06-16 03:25:34.000000000 -0700 @@ -1,5 +1,5 @@ -# gettext.m4 serial 17 (gettext-0.11.5) -dnl Copyright (C) 1995-2002 Free Software Foundation, Inc. +# gettext.m4 serial 20 (gettext-0.12) +dnl Copyright (C) 1995-2003 Free Software Foundation, Inc. dnl This file is free software, distributed under the terms of the GNU dnl General Public License. As a special exception to the GNU General dnl Public License, this file may be distributed as part of a program @@ -17,7 +17,7 @@ dnl Authors: dnl Ulrich Drepper , 1995-2000. -dnl Bruno Haible , 2000-2002. +dnl Bruno Haible , 2000-2003. dnl Macro to add for using GNU gettext. @@ -92,13 +92,8 @@ AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY]) ]) - AC_MSG_CHECKING([whether NLS is requested]) - dnl Default is enabled NLS - AC_ARG_ENABLE(nls, - [ --disable-nls do not use Native Language Support], - USE_NLS=$enableval, USE_NLS=yes) - AC_MSG_RESULT($USE_NLS) - AC_SUBST(USE_NLS) + dnl Set USE_NLS. + AM_NLS ifelse(gt_included_intl, yes, [ BUILD_INCLUDED_LIBINTL=no @@ -216,7 +211,8 @@ dnl libintl. (Cf. the install rule in intl/Makefile.in.) if test "$gt_cv_func_gnugettext_libc" = "yes" \ || { test "$gt_cv_func_gnugettext_libintl" = "yes" \ - && test "$PACKAGE" != gettext; }; then + && test "$PACKAGE" != gettext-runtime \ + && test "$PACKAGE" != gettext-tools; }; then gt_use_preinstalled_gnugettext=yes else dnl Reset the values set by searching for libintl. @@ -235,7 +231,6 @@ if test "$nls_cv_use_gnu_gettext" = "yes"; then dnl Mark actions used to generate GNU NLS library. - INTLOBJS="\$(GETTOBJS)" BUILD_INCLUDED_LIBINTL=yes USE_INCLUDED_LIBINTL=yes LIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LIBICONV" @@ -260,6 +255,22 @@ fi fi + AC_MSG_CHECKING([whether to use NLS]) + AC_MSG_RESULT([$USE_NLS]) + if test "$USE_NLS" = "yes"; then + AC_MSG_CHECKING([where the gettext function comes from]) + if test "$gt_use_preinstalled_gnugettext" = "yes"; then + if test "$gt_cv_func_gnugettext_libintl" = "yes"; then + gt_source="external libintl" + else + gt_source="libc" + fi + else + gt_source="included intl directory" + fi + AC_MSG_RESULT([$gt_source]) + fi + if test "$USE_NLS" = "yes"; then if test "$gt_use_preinstalled_gnugettext" = "yes"; then @@ -283,7 +294,7 @@ ifelse(gt_included_intl, yes, [ dnl If this is used in GNU gettext we have to set BUILD_INCLUDED_LIBINTL dnl to 'yes' because some of the testsuite requires it. - if test "$PACKAGE" = gettext; then + if test "$PACKAGE" = gettext-runtime || test "$PACKAGE" = gettext-tools; then BUILD_INCLUDED_LIBINTL=yes fi @@ -291,7 +302,6 @@ AC_SUBST(BUILD_INCLUDED_LIBINTL) AC_SUBST(USE_INCLUDED_LIBINTL) AC_SUBST(CATOBJEXT) - AC_SUBST(INTLOBJS) dnl For backward compatibility. Some configure.ins may be using this. nls_cv_header_intl= @@ -309,6 +319,12 @@ GENCAT=gencat AC_SUBST(GENCAT) + dnl For backward compatibility. Some Makefiles may be using this. + if test "$USE_INCLUDED_LIBINTL" = yes; then + INTLOBJS="\$(GETTOBJS)" + fi + AC_SUBST(INTLOBJS) + dnl Enable libtool support if the surrounding package wishes it. INTL_LIBTOOL_SUFFIX_PREFIX=gt_libtool_suffix_prefix AC_SUBST(INTL_LIBTOOL_SUFFIX_PREFIX) @@ -325,179 +341,6 @@ ]) -dnl Checks for all prerequisites of the po subdirectory, -dnl except for USE_NLS. -AC_DEFUN([AM_PO_SUBDIRS], -[ - AC_REQUIRE([AC_PROG_MAKE_SET])dnl - AC_REQUIRE([AC_PROG_INSTALL])dnl - AC_REQUIRE([AM_MKINSTALLDIRS])dnl - - dnl Perform the following tests also if --disable-nls has been given, - dnl because they are needed for "make dist" to work. - - dnl Search for GNU msgfmt in the PATH. - dnl The first test excludes Solaris msgfmt and early GNU msgfmt versions. - dnl The second test excludes FreeBSD msgfmt. - AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, - [$ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 && - (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)], - :) - AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) - - dnl Search for GNU xgettext 0.11 or newer in the PATH. - dnl The first test excludes Solaris xgettext and early GNU xgettext versions. - dnl The second test excludes FreeBSD xgettext. - AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, - [$ac_dir/$ac_word --omit-header --copyright-holder= /dev/null >/dev/null 2>&1 && - (if $ac_dir/$ac_word --omit-header --copyright-holder= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)], - :) - dnl Remove leftover from FreeBSD xgettext call. - rm -f messages.po - - dnl Search for GNU msgmerge 0.11 or newer in the PATH. - AM_PATH_PROG_WITH_TEST(MSGMERGE, msgmerge, - [$ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1], :) - - dnl This could go away some day; the PATH_PROG_WITH_TEST already does it. - dnl Test whether we really found GNU msgfmt. - if test "$GMSGFMT" != ":"; then - dnl If it is no GNU msgfmt we define it as : so that the - dnl Makefiles still can work. - if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 && - (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then - : ; - else - GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'` - AC_MSG_RESULT( - [found $GMSGFMT program is not GNU msgfmt; ignore it]) - GMSGFMT=":" - fi - fi - - dnl This could go away some day; the PATH_PROG_WITH_TEST already does it. - dnl Test whether we really found GNU xgettext. - if test "$XGETTEXT" != ":"; then - dnl If it is no GNU xgettext we define it as : so that the - dnl Makefiles still can work. - if $XGETTEXT --omit-header --copyright-holder= /dev/null >/dev/null 2>&1 && - (if $XGETTEXT --omit-header --copyright-holder= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then - : ; - else - AC_MSG_RESULT( - [found xgettext program is not GNU xgettext; ignore it]) - XGETTEXT=":" - fi - dnl Remove leftover from FreeBSD xgettext call. - rm -f messages.po - fi - - AC_OUTPUT_COMMANDS([ - for ac_file in $CONFIG_FILES; do - # Support "outfile[:infile[:infile...]]" - case "$ac_file" in - *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; - esac - # PO directories have a Makefile.in generated from Makefile.in.in. - case "$ac_file" in */Makefile.in) - # Adjust a relative srcdir. - ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` - ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`" - ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` - # In autoconf-2.13 it is called $ac_given_srcdir. - # In autoconf-2.50 it is called $srcdir. - test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir" - case "$ac_given_srcdir" in - .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;; - /*) top_srcdir="$ac_given_srcdir" ;; - *) top_srcdir="$ac_dots$ac_given_srcdir" ;; - esac - if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then - rm -f "$ac_dir/POTFILES" - test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES" - cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES" - # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend - # on $ac_dir but don't depend on user-specified configuration - # parameters. - if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then - # The LINGUAS file contains the set of available languages. - if test -n "$ALL_LINGUAS"; then - test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete" - fi - ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"` - # Hide the ALL_LINGUAS assigment from automake. - eval 'ALL_LINGUAS''=$ALL_LINGUAS_' - fi - case "$ac_given_srcdir" in - .) srcdirpre= ;; - *) srcdirpre='$(srcdir)/' ;; - esac - POFILES= - GMOFILES= - UPDATEPOFILES= - DUMMYPOFILES= - for lang in $ALL_LINGUAS; do - POFILES="$POFILES $srcdirpre$lang.po" - GMOFILES="$GMOFILES $srcdirpre$lang.gmo" - UPDATEPOFILES="$UPDATEPOFILES $lang.po-update" - DUMMYPOFILES="$DUMMYPOFILES $lang.nop" - done - # CATALOGS depends on both $ac_dir and the user's LINGUAS - # environment variable. - INST_LINGUAS= - if test -n "$ALL_LINGUAS"; then - for presentlang in $ALL_LINGUAS; do - useit=no - if test "%UNSET%" != "$LINGUAS"; then - desiredlanguages="$LINGUAS" - else - desiredlanguages="$ALL_LINGUAS" - fi - for desiredlang in $desiredlanguages; do - # Use the presentlang catalog if desiredlang is - # a. equal to presentlang, or - # b. a variant of presentlang (because in this case, - # presentlang can be used as a fallback for messages - # which are not translated in the desiredlang catalog). - case "$desiredlang" in - "$presentlang"*) useit=yes;; - esac - done - if test $useit = yes; then - INST_LINGUAS="$INST_LINGUAS $presentlang" - fi - done - fi - CATALOGS= - if test -n "$INST_LINGUAS"; then - for lang in $INST_LINGUAS; do - CATALOGS="$CATALOGS $lang.gmo" - done - fi - test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile" - sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile" - for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do - if test -f "$f"; then - case "$f" in - *.orig | *.bak | *~) ;; - *) cat "$f" >> "$ac_dir/Makefile" ;; - esac - fi - done - fi - ;; - esac - done], - [# Capture the value of obsolete ALL_LINGUAS because we need it to compute - # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it - # from automake. - eval 'ALL_LINGUAS''="$ALL_LINGUAS"' - # Capture the value of LINGUAS because we need it to compute CATALOGS. - LINGUAS="${LINGUAS-%UNSET%}" - ]) -]) - - dnl Checks for all prerequisites of the intl subdirectory, dnl except for INTL_LIBTOOL_SUFFIX_PREFIX (and possibly LIBTOOL), INTLOBJS, dnl USE_INCLUDED_LIBINTL, BUILD_INCLUDED_LIBINTL. @@ -526,7 +369,8 @@ stdlib.h string.h unistd.h sys/param.h]) AC_CHECK_FUNCS([feof_unlocked fgets_unlocked getc_unlocked getcwd getegid \ geteuid getgid getuid mempcpy munmap putenv setenv setlocale stpcpy \ -strcasecmp strdup strtoul tsearch __argz_count __argz_stringify __argz_next]) +strcasecmp strdup strtoul tsearch __argz_count __argz_stringify __argz_next \ +__fsetlocking]) AM_ICONV AM_LANGINFO_CODESET @@ -567,21 +411,5 @@ ]) -AC_DEFUN([AM_MKINSTALLDIRS], -[ - dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly - dnl find the mkinstalldirs script in another subdir but $(top_srcdir). - dnl Try to locate is. - MKINSTALLDIRS= - if test -n "$ac_aux_dir"; then - MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" - fi - if test -z "$MKINSTALLDIRS"; then - MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" - fi - AC_SUBST(MKINSTALLDIRS) -]) - - dnl Usage: AM_GNU_GETTEXT_VERSION([gettext-version]) AC_DEFUN([AM_GNU_GETTEXT_VERSION], []) diff -urN gawk-3.1.2/m4/intmax_t.m4 gawk-3.1.3/m4/intmax_t.m4 --- gawk-3.1.2/m4/intmax_t.m4 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/m4/intmax_t.m4 2003-03-28 00:30:36.000000000 -0800 @@ -0,0 +1,32 @@ +#serial 6 + +dnl From Paul Eggert. + +AC_PREREQ(2.52) + +# Define intmax_t to long or long long if doesn't define. + +AC_DEFUN([jm_AC_TYPE_INTMAX_T], +[ + AC_REQUIRE([jm_AC_TYPE_LONG_LONG]) + AC_CHECK_TYPE(intmax_t, , + [test $ac_cv_type_long_long = yes \ + && ac_type='long long' \ + || ac_type='long' + AC_DEFINE_UNQUOTED(intmax_t, $ac_type, + [Define to widest signed type if doesn't define.])]) +]) + +# Define uintmax_t to unsigned long or unsigned long long +# if doesn't define. + +AC_DEFUN([jm_AC_TYPE_UINTMAX_T], +[ + AC_REQUIRE([jm_AC_TYPE_UNSIGNED_LONG_LONG]) + AC_CHECK_TYPE(uintmax_t, , + [test $ac_cv_type_unsigned_long_long = yes \ + && ac_type='unsigned long long' \ + || ac_type='unsigned long' + AC_DEFINE_UNQUOTED(uintmax_t, $ac_type, + [Define to widest unsigned type if doesn't define.])]) +]) diff -urN gawk-3.1.2/m4/inttypes_h.m4 gawk-3.1.3/m4/inttypes_h.m4 --- gawk-3.1.2/m4/inttypes_h.m4 2002-09-19 01:00:08.000000000 -0700 +++ gawk-3.1.3/m4/inttypes_h.m4 2003-06-16 03:25:34.000000000 -0700 @@ -1,5 +1,5 @@ -# inttypes_h.m4 serial 4 (gettext-0.11.4) -dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. +# inttypes_h.m4 serial 5 (gettext-0.12) +dnl Copyright (C) 1997-2003 Free Software Foundation, Inc. dnl This file is free software, distributed under the terms of the GNU dnl General Public License. As a special exception to the GNU General dnl Public License, this file may be distributed as part of a program @@ -22,7 +22,7 @@ jm_ac_cv_header_inttypes_h=no)]) if test $jm_ac_cv_header_inttypes_h = yes; then AC_DEFINE_UNQUOTED(HAVE_INTTYPES_H_WITH_UINTMAX, 1, -[Define if exists, doesn't clash with , - and declares uintmax_t. ]) + [Define if exists, doesn't clash with , + and declares uintmax_t. ]) fi ]) diff -urN gawk-3.1.2/m4/lib-ld.m4 gawk-3.1.3/m4/lib-ld.m4 --- gawk-3.1.2/m4/lib-ld.m4 2002-09-19 01:00:08.000000000 -0700 +++ gawk-3.1.3/m4/lib-ld.m4 2003-06-16 03:25:34.000000000 -0700 @@ -1,5 +1,5 @@ -# lib-ld.m4 serial 1 (gettext-0.11) -dnl Copyright (C) 1996-2002 Free Software Foundation, Inc. +# lib-ld.m4 serial 2 (gettext-0.12) +dnl Copyright (C) 1996-2003 Free Software Foundation, Inc. dnl This file is free software, distributed under the terms of the GNU dnl General Public License. As a special exception to the GNU General dnl Public License, this file may be distributed as part of a program @@ -29,6 +29,19 @@ test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no) AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([AC_CANONICAL_HOST])dnl +# Prepare PATH_SEPARATOR. +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + echo "#! /bin/sh" >conf$$.sh + echo "exit 0" >>conf$$.sh + chmod +x conf$$.sh + if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then + PATH_SEPARATOR=';' + else + PATH_SEPARATOR=: + fi + rm -f conf$$.sh +fi ac_prog=ld if test "$GCC" = yes; then # Check if gcc -print-prog-name=ld gives a path. diff -urN gawk-3.1.2/m4/lib-link.m4 gawk-3.1.3/m4/lib-link.m4 --- gawk-3.1.2/m4/lib-link.m4 2002-09-19 01:00:08.000000000 -0700 +++ gawk-3.1.3/m4/lib-link.m4 2003-06-16 03:25:34.000000000 -0700 @@ -1,5 +1,5 @@ -# lib-link.m4 serial 3 (gettext-0.11.3) -dnl Copyright (C) 2001-2002 Free Software Foundation, Inc. +# lib-link.m4 serial 4 (gettext-0.12) +dnl Copyright (C) 2001-2003 Free Software Foundation, Inc. dnl This file is free software, distributed under the terms of the GNU dnl General Public License. As a special exception to the GNU General dnl Public License, this file may be distributed as part of a program @@ -92,8 +92,7 @@ dnl Determine the platform dependent parameters needed to use rpath: dnl libext, shlibext, hardcode_libdir_flag_spec, hardcode_libdir_separator, -dnl hardcode_direct, hardcode_minus_L, -dnl sys_lib_search_path_spec, sys_lib_dlsearch_path_spec. +dnl hardcode_direct, hardcode_minus_L. AC_DEFUN([AC_LIB_RPATH], [ AC_REQUIRE([AC_PROG_CC]) dnl we use $CC, $GCC, $LDFLAGS @@ -114,8 +113,6 @@ hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" hardcode_direct="$acl_cv_hardcode_direct" hardcode_minus_L="$acl_cv_hardcode_minus_L" - sys_lib_search_path_spec="$acl_cv_sys_lib_search_path_spec" - sys_lib_dlsearch_path_spec="$acl_cv_sys_lib_dlsearch_path_spec" dnl Determine whether the user wants rpath handling at all. AC_ARG_ENABLE(rpath, [ --disable-rpath do not hardcode runtime library paths], @@ -135,7 +132,7 @@ eval additional_includedir=\"$includedir\" eval additional_libdir=\"$libdir\" ]) - AC_ARG_WITH([lib$1-prefix], + AC_LIB_ARG_WITH([lib$1-prefix], [ --with-lib$1-prefix[=DIR] search for lib$1 in DIR/include and DIR/lib --without-lib$1-prefix don't search for lib$1 in includedir and libdir], [ diff -urN gawk-3.1.2/m4/lib-prefix.m4 gawk-3.1.3/m4/lib-prefix.m4 --- gawk-3.1.2/m4/lib-prefix.m4 2002-09-19 01:00:08.000000000 -0700 +++ gawk-3.1.3/m4/lib-prefix.m4 2003-06-16 03:25:34.000000000 -0700 @@ -1,5 +1,5 @@ -# lib-prefix.m4 serial 1 (gettext-0.11) -dnl Copyright (C) 2001-2002 Free Software Foundation, Inc. +# lib-prefix.m4 serial 2 (gettext-0.12) +dnl Copyright (C) 2001-2003 Free Software Foundation, Inc. dnl This file is free software, distributed under the terms of the GNU dnl General Public License. As a special exception to the GNU General dnl Public License, this file may be distributed as part of a program @@ -8,6 +8,13 @@ dnl From Bruno Haible. +dnl AC_LIB_ARG_WITH is synonymous to AC_ARG_WITH in autoconf-2.13, and +dnl similar to AC_ARG_WITH in autoconf 2.52...2.57 except that is doesn't +dnl require excessive bracketing. +ifdef([AC_HELP_STRING], +[AC_DEFUN([AC_LIB_ARG_WITH], [AC_ARG_WITH([$1],[[$2]],[$3],[$4])])], +[AC_DEFUN([AC_LIB_ARG_WITH], [AC_ARG_WITH([$1],[$2],[$3],[$4])])]) + dnl AC_LIB_PREFIX adds to the CPPFLAGS and LDFLAGS the flags that are needed dnl to access previously installed libraries. The basic assumption is that dnl a user will want packages to use other packages he previously installed @@ -26,7 +33,7 @@ eval additional_includedir=\"$includedir\" eval additional_libdir=\"$libdir\" ]) - AC_ARG_WITH([lib-prefix], + AC_LIB_ARG_WITH([lib-prefix], [ --with-lib-prefix[=DIR] search for libraries in DIR/include and DIR/lib --without-lib-prefix don't search for libraries in includedir and libdir], [ diff -urN gawk-3.1.2/m4/longlong.m4 gawk-3.1.3/m4/longlong.m4 --- gawk-3.1.2/m4/longlong.m4 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/m4/longlong.m4 2003-03-28 00:30:29.000000000 -0800 @@ -0,0 +1,35 @@ +#serial 2 + +dnl From Paul Eggert. + +# Define HAVE_LONG_LONG if 'long long' works. + +AC_DEFUN([jm_AC_TYPE_LONG_LONG], +[ + AC_CACHE_CHECK([for long long], ac_cv_type_long_long, + [AC_TRY_LINK([long long ll = 1; int i = 63;], + [long long llmax = (long long) -1; + return ll << i | ll >> i | llmax / ll | llmax % ll;], + ac_cv_type_long_long=yes, + ac_cv_type_long_long=no)]) + if test $ac_cv_type_long_long = yes; then + AC_DEFINE(HAVE_LONG_LONG, 1, + [Define if you have the long long type.]) + fi +]) + +# Define HAVE_UNSIGNED_LONG_LONG if 'unsigned long long' works. + +AC_DEFUN([jm_AC_TYPE_UNSIGNED_LONG_LONG], +[ + AC_CACHE_CHECK([for unsigned long long], ac_cv_type_unsigned_long_long, + [AC_TRY_LINK([unsigned long long ull = 1; int i = 63;], + [unsigned long long ullmax = (unsigned long long) -1; + return ull << i | ull >> i | ullmax / ull | ullmax % ull;], + ac_cv_type_unsigned_long_long=yes, + ac_cv_type_unsigned_long_long=no)]) + if test $ac_cv_type_unsigned_long_long = yes; then + AC_DEFINE(HAVE_UNSIGNED_LONG_LONG, 1, + [Define if you have the unsigned long long type.]) + fi +]) diff -urN gawk-3.1.2/m4/nls.m4 gawk-3.1.3/m4/nls.m4 --- gawk-3.1.2/m4/nls.m4 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/m4/nls.m4 2003-06-16 03:25:34.000000000 -0700 @@ -0,0 +1,49 @@ +# nls.m4 serial 1 (gettext-0.12) +dnl Copyright (C) 1995-2003 Free Software Foundation, Inc. +dnl This file is free software, distributed under the terms of the GNU +dnl General Public License. As a special exception to the GNU General +dnl Public License, this file may be distributed as part of a program +dnl that contains a configuration script generated by Autoconf, under +dnl the same distribution terms as the rest of that program. +dnl +dnl This file can can be used in projects which are not available under +dnl the GNU General Public License or the GNU Library General Public +dnl License but which still want to provide support for the GNU gettext +dnl functionality. +dnl Please note that the actual code of the GNU gettext library is covered +dnl by the GNU Library General Public License, and the rest of the GNU +dnl gettext package package is covered by the GNU General Public License. +dnl They are *not* in the public domain. + +dnl Authors: +dnl Ulrich Drepper , 1995-2000. +dnl Bruno Haible , 2000-2003. + +AC_DEFUN([AM_NLS], +[ + AC_MSG_CHECKING([whether NLS is requested]) + dnl Default is enabled NLS + AC_ARG_ENABLE(nls, + [ --disable-nls do not use Native Language Support], + USE_NLS=$enableval, USE_NLS=yes) + AC_MSG_RESULT($USE_NLS) + AC_SUBST(USE_NLS) +]) + +AC_DEFUN([AM_MKINSTALLDIRS], +[ + dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly + dnl find the mkinstalldirs script in another subdir but $(top_srcdir). + dnl Try to locate it. + MKINSTALLDIRS= + if test -n "$ac_aux_dir"; then + case "$ac_aux_dir" in + /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;; + *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;; + esac + fi + if test -z "$MKINSTALLDIRS"; then + MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" + fi + AC_SUBST(MKINSTALLDIRS) +]) diff -urN gawk-3.1.2/m4/po.m4 gawk-3.1.3/m4/po.m4 --- gawk-3.1.2/m4/po.m4 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/m4/po.m4 2003-06-16 03:25:34.000000000 -0700 @@ -0,0 +1,197 @@ +# po.m4 serial 1 (gettext-0.12) +dnl Copyright (C) 1995-2003 Free Software Foundation, Inc. +dnl This file is free software, distributed under the terms of the GNU +dnl General Public License. As a special exception to the GNU General +dnl Public License, this file may be distributed as part of a program +dnl that contains a configuration script generated by Autoconf, under +dnl the same distribution terms as the rest of that program. +dnl +dnl This file can can be used in projects which are not available under +dnl the GNU General Public License or the GNU Library General Public +dnl License but which still want to provide support for the GNU gettext +dnl functionality. +dnl Please note that the actual code of the GNU gettext library is covered +dnl by the GNU Library General Public License, and the rest of the GNU +dnl gettext package package is covered by the GNU General Public License. +dnl They are *not* in the public domain. + +dnl Authors: +dnl Ulrich Drepper , 1995-2000. +dnl Bruno Haible , 2000-2003. + +dnl Checks for all prerequisites of the po subdirectory. +AC_DEFUN([AM_PO_SUBDIRS], +[ + AC_REQUIRE([AC_PROG_MAKE_SET])dnl + AC_REQUIRE([AC_PROG_INSTALL])dnl + AC_REQUIRE([AM_MKINSTALLDIRS])dnl + AC_REQUIRE([AM_NLS])dnl + + dnl Perform the following tests also if --disable-nls has been given, + dnl because they are needed for "make dist" to work. + + dnl Search for GNU msgfmt in the PATH. + dnl The first test excludes Solaris msgfmt and early GNU msgfmt versions. + dnl The second test excludes FreeBSD msgfmt. + AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, + [$ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 && + (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)], + :) + AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) + + dnl Search for GNU xgettext 0.12 or newer in the PATH. + dnl The first test excludes Solaris xgettext and early GNU xgettext versions. + dnl The second test excludes FreeBSD xgettext. + AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, + [$ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 && + (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)], + :) + dnl Remove leftover from FreeBSD xgettext call. + rm -f messages.po + + dnl Search for GNU msgmerge 0.11 or newer in the PATH. + AM_PATH_PROG_WITH_TEST(MSGMERGE, msgmerge, + [$ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1], :) + + dnl This could go away some day; the PATH_PROG_WITH_TEST already does it. + dnl Test whether we really found GNU msgfmt. + if test "$GMSGFMT" != ":"; then + dnl If it is no GNU msgfmt we define it as : so that the + dnl Makefiles still can work. + if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 && + (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then + : ; + else + GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'` + AC_MSG_RESULT( + [found $GMSGFMT program is not GNU msgfmt; ignore it]) + GMSGFMT=":" + fi + fi + + dnl This could go away some day; the PATH_PROG_WITH_TEST already does it. + dnl Test whether we really found GNU xgettext. + if test "$XGETTEXT" != ":"; then + dnl If it is no GNU xgettext we define it as : so that the + dnl Makefiles still can work. + if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 && + (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 + : ; + else + AC_MSG_RESULT( + [found xgettext program is not GNU xgettext; ignore it]) + XGETTEXT=":" + fi + dnl Remove leftover from FreeBSD xgettext call. + rm -f messages.po + fi + + AC_OUTPUT_COMMANDS([ + for ac_file in $CONFIG_FILES; do + # Support "outfile[:infile[:infile...]]" + case "$ac_file" in + *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; + esac + # PO directories have a Makefile.in generated from Makefile.in.in. + case "$ac_file" in */Makefile.in) + # Adjust a relative srcdir. + ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` + ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`" + ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` + # In autoconf-2.13 it is called $ac_given_srcdir. + # In autoconf-2.50 it is called $srcdir. + test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir" + case "$ac_given_srcdir" in + .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;; + /*) top_srcdir="$ac_given_srcdir" ;; + *) top_srcdir="$ac_dots$ac_given_srcdir" ;; + esac + if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then + rm -f "$ac_dir/POTFILES" + test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES" + cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES" + POMAKEFILEDEPS="POTFILES.in" + # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend + # on $ac_dir but don't depend on user-specified configuration + # parameters. + if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then + # The LINGUAS file contains the set of available languages. + if test -n "$OBSOLETE_ALL_LINGUAS"; then + test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete" + fi + ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"` + # Hide the ALL_LINGUAS assigment from automake. + eval 'ALL_LINGUAS''=$ALL_LINGUAS_' + POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS" + else + # The set of available languages was given in configure.in. + eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS' + fi + case "$ac_given_srcdir" in + .) srcdirpre= ;; + *) srcdirpre='$(srcdir)/' ;; + esac + POFILES= + GMOFILES= + UPDATEPOFILES= + DUMMYPOFILES= + for lang in $ALL_LINGUAS; do + POFILES="$POFILES $srcdirpre$lang.po" + GMOFILES="$GMOFILES $srcdirpre$lang.gmo" + UPDATEPOFILES="$UPDATEPOFILES $lang.po-update" + DUMMYPOFILES="$DUMMYPOFILES $lang.nop" + done + # CATALOGS depends on both $ac_dir and the user's LINGUAS + # environment variable. + INST_LINGUAS= + if test -n "$ALL_LINGUAS"; then + for presentlang in $ALL_LINGUAS; do + useit=no + if test "%UNSET%" != "$LINGUAS"; then + desiredlanguages="$LINGUAS" + else + desiredlanguages="$ALL_LINGUAS" + fi + for desiredlang in $desiredlanguages; do + # Use the presentlang catalog if desiredlang is + # a. equal to presentlang, or + # b. a variant of presentlang (because in this case, + # presentlang can be used as a fallback for messages + # which are not translated in the desiredlang catalog). + case "$desiredlang" in + "$presentlang"*) useit=yes;; + esac + done + if test $useit = yes; then + INST_LINGUAS="$INST_LINGUAS $presentlang" + fi + done + fi + CATALOGS= + if test -n "$INST_LINGUAS"; then + for lang in $INST_LINGUAS; do + CATALOGS="$CATALOGS $lang.gmo" + done + fi + test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile" + sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile" + for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do + if test -f "$f"; then + case "$f" in + *.orig | *.bak | *~) ;; + *) cat "$f" >> "$ac_dir/Makefile" ;; + esac + fi + done + fi + ;; + esac + done], + [# Capture the value of obsolete ALL_LINGUAS because we need it to compute + # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it + # from automake. + eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"' + # Capture the value of LINGUAS because we need it to compute CATALOGS. + LINGUAS="${LINGUAS-%UNSET%}" + ]) +]) diff -urN gawk-3.1.2/m4/progtest.m4 gawk-3.1.3/m4/progtest.m4 --- gawk-3.1.2/m4/progtest.m4 2002-09-19 01:00:08.000000000 -0700 +++ gawk-3.1.3/m4/progtest.m4 2003-06-16 03:25:34.000000000 -0700 @@ -1,5 +1,5 @@ -# progtest.m4 serial 2 (gettext-0.10.40) -dnl Copyright (C) 1996-2002 Free Software Foundation, Inc. +# progtest.m4 serial 3 (gettext-0.12) +dnl Copyright (C) 1996-2003 Free Software Foundation, Inc. dnl This file is free software, distributed under the terms of the GNU dnl General Public License. As a special exception to the GNU General dnl Public License, this file may be distributed as part of a program @@ -23,31 +23,63 @@ dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR, dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]]) AC_DEFUN([AM_PATH_PROG_WITH_TEST], -[# Extract the first word of "$2", so it can be a program name with args. +[ +# Prepare PATH_SEPARATOR. +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + echo "#! /bin/sh" >conf$$.sh + echo "exit 0" >>conf$$.sh + chmod +x conf$$.sh + if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then + PATH_SEPARATOR=';' + else + PATH_SEPARATOR=: + fi + rm -f conf$$.sh +fi + +# Find out how to test for executable files. Don't use a zero-byte file, +# as systems may use methods other than mode bits to determine executability. +cat >conf$$.file <<_ASEOF +#! /bin/sh +exit 0 +_ASEOF +chmod +x conf$$.file +if test -x conf$$.file >/dev/null 2>&1; then + ac_executable_p="test -x" +else + ac_executable_p="test -f" +fi +rm -f conf$$.file + +# Extract the first word of "$2", so it can be a program name with args. set dummy $2; ac_word=[$]2 AC_MSG_CHECKING([for $ac_word]) AC_CACHE_VAL(ac_cv_path_$1, [case "[$]$1" in - /*) - ac_cv_path_$1="[$]$1" # Let the user override the test with a path. - ;; + [[\\/]]* | ?:[[\\/]]*) + ac_cv_path_$1="[$]$1" # Let the user override the test with a path. + ;; *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" - for ac_dir in ifelse([$5], , $PATH, [$5]); do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - if [$3]; then - ac_cv_path_$1="$ac_dir/$ac_word" - break - fi - fi - done - IFS="$ac_save_ifs" + ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in ifelse([$5], , $PATH, [$5]); do + IFS="$ac_save_IFS" + test -z "$ac_dir" && ac_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then + if [$3]; then + ac_cv_path_$1="$ac_dir/$ac_word$ac_exec_ext" + break 2 + fi + fi + done + done + IFS="$ac_save_IFS" dnl If no 4th arg is given, leave the cache variable unset, dnl so AC_PATH_PROGS will keep looking. ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4" ])dnl - ;; + ;; esac])dnl $1="$ac_cv_path_$1" if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then diff -urN gawk-3.1.2/m4/stdint_h.m4 gawk-3.1.3/m4/stdint_h.m4 --- gawk-3.1.2/m4/stdint_h.m4 2002-09-19 01:00:08.000000000 -0700 +++ gawk-3.1.3/m4/stdint_h.m4 2003-06-16 03:25:34.000000000 -0700 @@ -1,5 +1,5 @@ -# stdint_h.m4 serial 2 (gettext-0.11.4) -dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. +# stdint_h.m4 serial 3 (gettext-0.12) +dnl Copyright (C) 1997-2003 Free Software Foundation, Inc. dnl This file is free software, distributed under the terms of the GNU dnl General Public License. As a special exception to the GNU General dnl Public License, this file may be distributed as part of a program @@ -22,7 +22,7 @@ jm_ac_cv_header_stdint_h=no)]) if test $jm_ac_cv_header_stdint_h = yes; then AC_DEFINE_UNQUOTED(HAVE_STDINT_H_WITH_UINTMAX, 1, -[Define if exists, doesn't clash with , - and declares uintmax_t. ]) + [Define if exists, doesn't clash with , + and declares uintmax_t. ]) fi ]) diff -urN gawk-3.1.2/m4/uintmax_t.m4 gawk-3.1.3/m4/uintmax_t.m4 --- gawk-3.1.2/m4/uintmax_t.m4 2002-09-19 01:00:08.000000000 -0700 +++ gawk-3.1.3/m4/uintmax_t.m4 2003-06-16 03:25:34.000000000 -0700 @@ -1,5 +1,5 @@ -# uintmax_t.m4 serial 6 (gettext-0.11) -dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. +# uintmax_t.m4 serial 7 (gettext-0.12) +dnl Copyright (C) 1997-2003 Free Software Foundation, Inc. dnl This file is free software, distributed under the terms of the GNU dnl General Public License. As a special exception to the GNU General dnl Public License, this file may be distributed as part of a program @@ -10,8 +10,8 @@ AC_PREREQ(2.13) -# Define uintmax_t to `unsigned long' or `unsigned long long' -# if does not exist. +# Define uintmax_t to 'unsigned long' or 'unsigned long long' +# if it is not already defined in or . AC_DEFUN([jm_AC_TYPE_UINTMAX_T], [ @@ -23,7 +23,10 @@ && ac_type='unsigned long long' \ || ac_type='unsigned long' AC_DEFINE_UNQUOTED(uintmax_t, $ac_type, - [Define to unsigned long or unsigned long long - if and don't define.]) + [Define to unsigned long or unsigned long long + if and don't define.]) + else + AC_DEFINE(HAVE_UINTMAX_T, 1, + [Define if you have the 'uintmax_t' type in or .]) fi ]) diff -urN gawk-3.1.2/main.c gawk-3.1.3/main.c --- gawk-3.1.2/main.c 2003-03-19 04:11:18.000000000 -0800 +++ gawk-3.1.3/main.c 2003-07-07 09:55:27.000000000 -0700 @@ -201,7 +201,7 @@ int c; char *scan; /* the + on the front tells GNU getopt not to rearrange argv */ - const char *optlist = "+F:f:v:W;m:"; + const char *optlist = "+F:f:v:W;m:D"; int stopped_early = FALSE; int old_optind; extern int optind; @@ -232,8 +232,10 @@ #endif #if defined(LC_NUMERIC) /* - * Force the issue here. On some systems, gawk ends up - * printing output with commas for the decimal point. + * Force the issue here. According to POSIX 2001, decimal + * point is used for parsing source code and for command-line + * assignments and the locale value for processing input, + * number to string conversion, and printing output. */ setlocale(LC_NUMERIC, "C"); #endif @@ -388,12 +390,6 @@ version(); break; -#ifdef GAWKDEBUG - case 'D': - yydebug = 2; - break; -#endif - case 0: /* * getopt_long found an option that sets a variable @@ -402,6 +398,13 @@ */ break; + case 'D': +#ifdef GAWKDEBUG + yydebug = 2; + break; +#endif + /* if not debugging, fall through */ + case '?': default: /* @@ -548,6 +551,11 @@ init_profiling_signals(); +#if defined(LC_NUMERIC) + /* See comment above. */ + setlocale(LC_NUMERIC, ""); +#endif + /* Whew. Finally, run the program. */ if (begin_block != NULL) { in_begin_rule = TRUE; @@ -657,6 +665,11 @@ fputs(_("Examples:\n\tgawk '{ sum += $1 }; END { print sum }' file\n\ \tgawk -F: '{ print $1 }' /etc/passwd\n"), fp); + fflush(fp); + + if (ferror(fp)) + exit(1); + exit(exitval); } @@ -689,6 +702,10 @@ fputs(_(blurb_part2), stdout); fputs(_(blurb_part3), stdout); fflush(stdout); + + if (ferror(stdout)) + exit(1); + exit(0); } @@ -734,12 +751,10 @@ aptr = assoc_lookup(ARGV_node, tmp_number((AWKNUM) j), FALSE); *aptr = make_string(argv[i], strlen(argv[i])); (*aptr)->flags |= MAYBE_NUM; - (*aptr)->flags &= ~UNINITIALIZED; j++; } ARGC_node = install("ARGC", node(make_number((AWKNUM) j), Node_var, (NODE *) NULL)); - ARGC_node->flags &= ~UNINITIALIZED; } /* @@ -795,8 +810,6 @@ : make_string((char *) vp->strval, strlen(vp->strval)), vp->type, (NODE *) NULL)); - (*(vp->spec))->flags |= SCALAR; - (*(vp->spec))->flags &= ~UNINITIALIZED; if (vp->assign) (*(vp->assign))(); } @@ -831,7 +844,7 @@ aptr = assoc_lookup(ENVIRON_node, tmp_string(var, strlen(var)), FALSE); *aptr = make_string(val, strlen(val)); - (*aptr)->flags |= (MAYBE_NUM|SCALAR); + (*aptr)->flags |= MAYBE_NUM; /* restore '=' so that system() gets a valid environment */ if (val != nullstr) @@ -844,7 +857,6 @@ if (getenv("AWKPATH") == NULL) { aptr = assoc_lookup(ENVIRON_node, tmp_string("AWKPATH", 7), FALSE); *aptr = make_string(defpath, strlen(defpath)); - (*aptr)->flags |= SCALAR; } #endif /* TANDEM */ return ENVIRON_node; @@ -972,7 +984,12 @@ * This makes sense, so we do it too. */ it = make_str_node(cp, strlen(cp), SCAN); - it->flags |= (MAYBE_NUM|SCALAR); + it->flags |= MAYBE_NUM; +#ifdef LC_NUMERIC + setlocale(LC_NUMERIC, "C"); + (void) force_number(it); + setlocale(LC_NUMERIC, ""); +#endif /* LC_NUMERIC */ var = variable(arg, FALSE, Node_var); lhs = get_lhs(var, &after_assign, FALSE); unref(*lhs); diff -urN gawk-3.1.2/missing_d/ChangeLog gawk-3.1.3/missing_d/ChangeLog --- gawk-3.1.2/missing_d/ChangeLog 2003-03-19 04:23:08.000000000 -0800 +++ gawk-3.1.3/missing_d/ChangeLog 2003-07-07 11:02:21.000000000 -0700 @@ -1,3 +1,7 @@ +Mon Jul 7 11:01:43 2003 Arnold D. Robbins + + * Release 3.1.3: Release tar file made. + Wed Mar 19 14:10:31 2003 Arnold D. Robbins This time for sure. diff -urN gawk-3.1.2/node.c gawk-3.1.3/node.c --- gawk-3.1.2/node.c 2003-02-22 13:10:14.000000000 -0800 +++ gawk-3.1.3/node.c 2003-06-15 09:35:22.000000000 -0700 @@ -52,7 +52,6 @@ n->numbr = 0.0; n->flags |= NUMCUR; - n->flags &= ~UNINITIALIZED; if (n->stlen == 0) { if (0 && do_lint) @@ -211,7 +210,6 @@ no_malloc: s->stref = 1; s->flags |= STRCUR; - s->flags &= ~UNINITIALIZED; return s; } @@ -283,7 +281,7 @@ r->ahname_ref = 1; emalloc(r->ahname_str, char *, r->ahname_len + 2, "dupnode"); memcpy(r->ahname_str, n->ahname_str, r->ahname_len); - r->stptr[r->ahname_len] = '\0'; + r->ahname_str[r->ahname_len] = '\0'; } return r; } @@ -314,7 +312,7 @@ getnode(r); r->type = Node_val; r->numbr = x; - r->flags = flags | SCALAR; + r->flags = flags; #ifdef GAWKDEBUG r->stref = 1; r->stptr = NULL; @@ -332,7 +330,7 @@ getnode(r); r->type = Node_val; - r->flags = (STRING|STRCUR|MALLOC|SCALAR); + r->flags = (STRING|STRCUR|MALLOC); if (flags & ALREADY_MALLOCED) r->stptr = s; else { @@ -400,7 +398,6 @@ emalloc(nextfree, NODE *, NODECHUNK * sizeof(NODE), "more_nodes"); for (np = nextfree; np <= &nextfree[NODECHUNK - 1]; np++) { np->flags = 0; - np->flags |= UNINITIALIZED; #ifndef NO_PROFILING np->exec_count = 0; #endif @@ -420,8 +417,6 @@ void freenode(NODE *it) { - it->flags &= ~SCALAR; - it->flags |= UNINITIALIZED; #ifdef MPROF it->stref = 0; free((char *) it); diff -urN gawk-3.1.2/patchlev.h gawk-3.1.3/patchlev.h --- gawk-3.1.2/patchlev.h 2003-03-16 02:25:55.000000000 -0800 +++ gawk-3.1.3/patchlev.h 2003-07-04 10:50:06.000000000 -0700 @@ -1 +1 @@ -#define PATCHLEVEL "2" +#define PATCHLEVEL "3" diff -urN gawk-3.1.2/pc/ChangeLog gawk-3.1.3/pc/ChangeLog --- gawk-3.1.2/pc/ChangeLog 2003-03-19 04:23:15.000000000 -0800 +++ gawk-3.1.3/pc/ChangeLog 2003-07-07 11:02:25.000000000 -0700 @@ -1,3 +1,32 @@ +Mon Jul 7 11:01:43 2003 Arnold D. Robbins + + * Release 3.1.3: Release tar file made. + +Thu Jun 26 15:00:20 2003 Scott Deifik + + * Makefile.tst: Synchronized to main dist. + +Sun Jun 15 19:27:58 2003 Patrick T.J. McPhee + + * config.h: Separate the ifdefs for os_system from ssize_t etc. + +Sun Jun 15 19:05:15 2003 Scott Deifik + + * Makefile.tst: Synchronized to main dist. + +Mon Jun 9 17:12:24 2003 Patrick T.J. McPhee + + * dlfcn.c, dlfcn.h, gawke32.def: New files. + * Makefile: Changes to allow dynamic linking of libraries + under Windows32. + +Sun May 11 15:19:52 2003 Scott Deifik + + * config.h: Update defs for ssize_t, intmax_t, uintmax_t. + * Makefile: Update compile options. + * gawkmisc.pc (memcpy_long, memset_long): New functions. + * Makefile.tst: Synchronized with test/Makefile. + Wed Mar 19 14:10:31 2003 Arnold D. Robbins This time for sure. @@ -175,7 +204,7 @@ Fri May 21 00:00:00 1999 Darrel Hankerson - * popen.c: MSC (on DOS/Win32) and MINGW32 now honor SHELL. + * popen.c: MSC (on DOS/Windows32) and MINGW32 now honor SHELL. * io.c: MINGW32 reports errno==0 after failure in redirect(); assume close_one() in this case. * io.c: Add HAVE_POPEN_H and let pc/config.h deal with the mess. @@ -201,8 +230,8 @@ omitted from 3.0.3. * README.pc updated to clarify the procedure for building - non-LFN versions on LFN systems, and to note that Win32 gawk - may require Win32 utilities. + non-LFN versions on LFN systems, and to note that Windows32 gawk + may require Windows32 utilities. * emxbnd target modified to accomodate older versions of emx. diff -urN gawk-3.1.2/pc/Makefile gawk-3.1.3/pc/Makefile --- gawk-3.1.2/pc/Makefile 2003-03-19 04:49:23.000000000 -0800 +++ gawk-3.1.3/pc/Makefile 2003-06-29 05:54:27.000000000 -0700 @@ -1,9 +1,9 @@ # Makefile for gawk (GNU awk) Dec 2000 # # - for GNU C (djgpp) [32bit executable for DOS] -# - for GNU C (emx) [32bit executable for OS/2 or DOS or Win32] -# - for GNU C (mingw32) [Win32 executable for Windows 9x/NT] -# - for MS-Visual C/C++ 4.x [Win32 executable for Windows 9x/NT] +# - for GNU C (emx) [32bit executable for OS/2 or DOS or Windows32] +# - for GNU C (mingw32) [Windows32 executable for Windows 9x/NT] +# - for MS-Visual C/C++ 4.x [Windows32 executable for Windows 9x/NT] # - for Microsoft C 7 [16bit ececutable for DOS] # - for Microsoft C 6.00A [16bit executable for OS/2 or DOS] @@ -20,12 +20,12 @@ @echo " emx ..... OS/2 32-bit exe [emx/gcc; uses emxlibc.dll] " @echo " emxnt ... NT exe [emx/gcc with RSXNT] " @echo " emxbnd .. OS/2 and DOS 32-bit exe [emx/gcc] " - @echo " mingw32 . Win32 exe [Mingw32 GNU C] " + @echo " mingw32 . Windows32 exe [Mingw32 GNU C] " @echo " msc ..... DOS exe [Microsoft C 7 & 8 (AKA 1.52)] " @echo " msc6 .... DOS exe [Microsoft C 6.00a] " @echo " msc6os2 . OS/2 exe [Microsoft C 6.00a] " @echo " msc6bnd . OS/2 and DOS exe [Microsoft C 6.00a] " - @echo " vcWin32 . Win32 exe [Microsoft Visual C] " + @echo " vcWin32 . Windows32 exe [Microsoft Visual C] " @echo " ----------------------------------------------------- " @echo " test .... Perform tests (see README_d/README.pc) " @echo " install . Install gawk under $(prefix)/ " @@ -83,12 +83,21 @@ # cannot handle such macros, define DO_LNK and DO_BIND for your target # as $(L) and $(B), resp.; e.g., #DO_LNK = $(LvcWin32) -#DO_BIND= $(BvcWin32) +#DO_PLNK = $(PLvcWin32) # and then comment the following: DO_LNK = $($(LNK)) DO_BIND= $($(BIND)) DO_PLNK = $($(PLNK)) DO_PBIND= $($(PBIND)) +#------------------------------------------------------------------------ +# For dynamic extension support, uncomment these lines +# pick the appropriate .def file entry for your compiler +#DYN_FLAGS=-DDYNAMIC +#DYN_EXP=gawk.exp +#DYN_OBJ=dlfcn$O $(DYN_EXP) +#DYN_MAKEXP=$(DMEvcWin32) +#DYN_MAKEXP=$(DMEmingw32) +# #======================================================================== # End of general configuration. Some platform-specific configuration # notes appear below. @@ -167,14 +176,17 @@ #========================== MINGW32 ===================================== #======================================================================== +DMEmingw32 = dlltool -D gawk.exe -d gawkw32.def -e gawk.exp -l libgawk.a + LMINGW32 = $(CC) $(LF) -o $@ $(GAWKOBJS) $(LF2) +PLMINGW32 = $(CC) $(LF) -o $@ $(PGAWKOBJS) $(LF2) # The following might work around command-line length limitations: #LMINGW32 = $(CC) $(LF) -o $@ *.o $(LF2) mingw32: $(MAK) all \ CC=gcc O=.o CF=-O OBJ=popen.o \ - LNK=LMINGW32 LF=-s RSP= + LNK=LMINGW32 PLNK=PLMINGW32 LF=-s RSP= #======================================================================== #========================== MSC ========================================= @@ -189,8 +201,10 @@ # Optimization and library options: # Os == optimize for size, Ot == optimize for speed, G2 == 286 or better #MSCOPT = -Gt3600 -Os -G2 -# MSC seems to be more stable with -Od than with -Ot. -MSCOPT = -Gt3600 -Od # -G2 +# MSC seems to be more stable with -Od than with -Ot, but then regexec.c gives +# "code segment too large" error when compiling. Adding -G2y fixes this and +# lets us keep the -Od. +MSCOPT = -Gt3600 -Od -G2y # Alternate lib, does not use math coprocessor. #MSCLIB = llibca #MSCCL = -FPa @@ -262,7 +276,9 @@ # Windows '9x / NT +DMEvcWin32 = lib /def:gawkw32.def /name:gawk.exe /out:gawk.lib LvcWin32 = link -nologo -subsystem:console -release -out:$@ $(LNKRSP) +PLvcWin32 = link -nologo -subsystem:console -release -out:$@ $(PLDRSP) vcWin32: $(MAK) all \ @@ -293,13 +309,13 @@ # bitwise operations (-DBITOPS) and non-decimal input data (-DNONDECDATA) are # undocumented in 3.0.3. They may be enabled in config.h, or added to CFLAGS. -CFLAGS = $(CF) -DGAWK -I. -DHAVE_CONFIG_H +CFLAGS = $(CF) -DGAWK -I. -DHAVE_CONFIG_H $(DYN_FLAGS) # object files -AWKOBJS1 = array$O builtin$O eval$O field$O gawkmisc$O io$O main$O -AWKOBJS2 = ext$O msg$O node$O profile$O re$O version$O +AWKOBJS1 = array$O builtin$O eval$O field$O gawkmisc$O io$O main$O +AWKOBJS2 = ext$O msg$O node$O profile$O re$O version$O $(DYN_OBJ) PAWKOBJS1 = array$O builtin$O eval_p$O field$O gawkmisc$O io$O main$O -PAWKOBJS2 = ext$O msg$O node$O profile_p$O re$O version$O +PAWKOBJS2 = ext$O msg$O node$O profile_p$O re$O version$O $(DYN_OBJ) AWKOBJS = $(AWKOBJS1) $(AWKOBJS2) ALLOBJS = $(AWKOBJS) awkgram$O getid$O $(OBJ) @@ -309,7 +325,7 @@ LIBOBJS= getopt$O getopt1$O regex$O random$O GAWKOBJS = $(ALLOBJS) $(LIBOBJS) -PGAWKOBJS = $(PAWKOBJS1) $(PAWKOBJS2) awkgram$O getid$O $(OBJ) +PGAWKOBJS = $(PAWKOBJS1) $(PAWKOBJS2) $(LIBOBJS) awkgram$O getid$O $(OBJ) # clear out suffixes list # .SUFFIXES: @@ -347,6 +363,9 @@ getopt1$O: getopt.h +gawk.exp: gawkw32.def + $(DYN_MAKEXP) + main$O: patchlev.h eval_p$O: eval.c @@ -382,7 +401,7 @@ gawk -v prefix=$(prefix) -f install.awk clean: - rm -rf gawk pgawk *.exe gawk.map *.o *.obj core a.out $(RSPFILE) $(PRSPFILE) + rm -rf gawk pgawk *.exe gawk.map *.o *.obj core a.out $(RSPFILE) $(PRSPFILE) $(DYN_EXP) # cd doc && $(MAKE) clean # cd test && $(MAKE) clean # cd awklib && $(MAKE) clean diff -urN gawk-3.1.2/pc/Makefile.tst gawk-3.1.3/pc/Makefile.tst --- gawk-3.1.2/pc/Makefile.tst 2003-03-19 04:59:18.000000000 -0800 +++ gawk-3.1.3/pc/Makefile.tst 2003-06-26 05:44:26.000000000 -0700 @@ -112,31 +112,36 @@ srcdir = . # try to keep these sorted -BASIC_TESTS = addcomma anchgsub argarray arrayparm arrayref arrymem1 arynasty \ - arynocls arysubnm asgext awkpath back89 backgsub childin clobber \ - clsflnam compare compare2 concat1 convfmt datanonl defref delarprm \ - dynlj eofsplit fldchg fldchgnf fnamedat fnarray fnarydel fnaryscl \ - fnasgnm fnmisc fnparydl forsimp fsbs fsrs fstabplus funsemnl funsmnam \ - funstack getline getline2 getline3 getlnbuf getnr2tb getnr2tm gsubasgn gsubtest \ - gsubtst2 gsubtst3 gsubtst4 hsprint inputred intest intprec leaddig leadnl \ - litoct longsub longwrds math membug1 messages minusstr mmap8k \ - nasty nasty2 negexp nfldstr nfneg nfset nlfldsep nlinstr nlstrina \ - noeffect nofmtch noloop1 noloop2 nonl noparms nors nulrsend \ - numindex numsubstr octsub ofmt ofmtbig ofmtfidl ofmts onlynl \ - opasnidx opasnslf paramdup paramtyp parseme pcntplus prdupval prec \ - printf0 printf1 prmarscl prmreuse prt1eval prtoeval psx96sub rand rebt8b1 \ - rebt8b2 redfilnm regeq reindops reparse resplit rs rsnul1nl \ - rstest1 rstest2 rswhite sclforin sclifin splitargv splitarr splitdef \ - splitvar splitwht sprintfc strtod subslash substr swaplns synerr1 \ - tradanch tweakfld uninitialized uninit2 zeroe0 zeroflag +BASIC_TESTS = addcomma anchgsub argarray arrayparm arrayref arrymem1 \ + arrayprm2 arrayprm3 arryref2 arryref3 arryref4 arryref5 arynasty \ + arynocls aryprm1 aryprm2 aryprm3 aryprm4 aryprm5 aryprm6 aryprm7 \ + aryprm8 arysubnm asgext awkpath back89 backgsub childin clobber \ + clsflnam compare compare2 concat1 convfmt datanonl defref \ + delarprm delarpm2 dynlj eofsplit fldchg fldchgnf fmttest fnamedat \ + fnarray fnarray2 fnarydel fnaryscl fnasgnm fnmisc fnparydl \ + forsimp fsbs fsrs fstabplus funsemnl funsmnam funstack getline \ + getline2 getline3 getlnbuf getnr2tb getnr2tm gsubasgn gsubtest \ + gsubtst2 gsubtst3 gsubtst4 gsubtst5 hsprint inputred intest \ + intprec leaddig leadnl litoct longsub longwrds math membug1 \ + messages minusstr mmap8k nasty nasty2 negexp nested nfldstr \ + nfneg nfset nlfldsep nlinstr nlstrina noeffect nofmtch noloop1 \ + noloop2 nonl noparms nors nulrsend numindex numsubstr octsub ofmt \ + ofmtbig ofmtfidl ofmts onlynl opasnidx opasnslf paramdup paramtyp \ + parseme pcntplus prdupval prec printf0 printf1 prmarscl prmreuse \ + prt1eval prtoeval psx96sub rand rebt8b1 rebt8b2 redfilnm regeq \ + reindops reparse resplit rs rsnul1nl rsnulbig rsnulbig2 rstest1 \ + rstest2 rstest3 rstest4 rstest5 rswhite scalar sclforin sclifin \ + sortempty splitargv splitarr splitdef splitvar splitwht sprintfc \ + strtod subslash substr swaplns synerr1 tradanch tweakfld uninit2 \ + uninit3 uninit4 uninitialized zeroe0 zeroflag -UNIX_TESTS = fflush getlnhd pid pipeio1 pipeio2 poundbang space strftlng +UNIX_TESTS = fflush getlnhd pid pipeio1 pipeio2 poundbang poundbang2 space strftlng GAWK_EXT_TESTS = argtest asort asorti badargs clos1way fieldwdth fsfwfs \ gensub gnuops2 gnureops icasefs icasers igncdym igncfs ignrcase lint \ - match1 manyfiles nondec posix procinfs regx8bit rebuf reint shadow \ - sort1 strftime + match1 match2 manyfiles nondec posix procinfs regx8bit rebuf reint \ + shadow sort1 strtonum strftime whiny EXTRA_TESTS = regtest inftest @@ -144,12 +149,14 @@ INET_TESTS = inetechu inetecht inetdayu inetdayt # List of the tests which should be run with --lint option: -NEED_LINT = defref noeffect nofmtch shadow uninitialized uninit2 +NEED_LINT = defref noeffect nofmtch shadow uninit2 uninit3 uninit4 uninitialized # List of the files that appear in manual tests or are for reserve testing: -GENTESTS_UNUSED = Makefile.in gtlnbufv.awk printfloat.awk +GENTESTS_UNUSED = Makefile.in gtlnbufv.awk printfloat.awk switch2.awk -# message stuff is to make it a little easier to follow +# Message stuff is to make it a little easier to follow. +# Make the pass-fail last and dependent on others to avoid +# spurious errors if `make -j' in effect. check: msg \ basic-msg-start basic basic-msg-end \ unix-msg-start unix-tests unix-msg-end \ @@ -210,9 +217,13 @@ fi @-$(CMP) $(srcdir)/poundbang.awk _`basename $@` && rm -f _`basename $@` _pbd.awk +poundbang2: + @echo $@ + @LANG=en_US.UTF-8 LC_ALL=en_US.UTF-8 make poundbang + messages:: @echo $@ - @$(AWK) -f $(srcdir)/messages.awk >out2 2>out3 + @LC_ALL=C LANG=C $(AWK) -f $(srcdir)/messages.awk >out2 2>out3 @-$(CMP) $(srcdir)/out1.ok out1 && $(CMP) $(srcdir)/out2.ok out2 && $(CMP) $(srcdir)/out3.ok out3 && rm -f out1 out2 out3 argarray:: @@ -221,7 +232,7 @@ .) : ;; \ *) cp $(srcdir)/argarray.in . ;; \ esac - @TEST=test echo just a test | $(AWK) -f $(srcdir)/argarray.awk ./argarray.in - >_$@ + @TEST=test echo just a test | LC_ALL=C LANG=C $(AWK) -f $(srcdir)/argarray.awk ./argarray.in - >_$@ @case $(srcdir) in \ .) : ;; \ *) rm -f ./argarray.in ;; \ @@ -239,48 +250,51 @@ @rm -rf junk @mkdir junk @$(AWK) 'BEGIN { for (i = 1; i <= 300; i++) print i, i}' >_$@ - @$(AWK) -f $(srcdir)/manyfiles.awk _$@ _$@ + @LC_ALL=C LANG=C $(AWK) -f $(srcdir)/manyfiles.awk _$@ _$@ @wc -l junk/* | $(AWK) '$$1 != 2' | wc -l | sed 's/ *//g' > _$@ @rm -rf junk ; $(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ compare:: @echo $@ - @$(AWK) -f $(srcdir)/compare.awk 0 1 $(srcdir)/compare.in >_$@ + @LC_ALL=C LANG=C $(AWK) -f $(srcdir)/compare.awk 0 1 $(srcdir)/compare.in >_$@ @-$(CMP) $(srcdir)/compare.ok _$@ && rm -f _$@ inftest:: @echo $@ @echo This test is very machine specific... - @$(AWK) -f $(srcdir)/inftest.awk | sed 's/inf/Inf/g' >_$@ + @echo 'Both MSC 7.0 and 8.0 gawk generate a floating point exception.' + @echo 'EMX gawk uses #INF rather than Inf.' + @LC_ALL=C LANG=C $(AWK) -f $(srcdir)/inftest.awk | sed 's/inf/Inf/g' >_$@ @-$(CMP) $(srcdir)/inftest.ok _$@ && rm -f _$@ getline2:: @echo $@ - @$(AWK) -f $(srcdir)/getline2.awk $(srcdir)/getline2.awk $(srcdir)/getline2.awk >_$@ + @LC_ALL=C LANG=C $(AWK) -f $(srcdir)/getline2.awk $(srcdir)/getline2.awk $(srcdir)/getline2.awk >_$@ @-$(CMP) $(srcdir)/getline2.ok _$@ && rm -f _$@ awkpath:: @echo $@ - @AWKPATH="$(srcdir)$(PATH_SEPARATOR)$(srcdir)/lib" $(AWK) -f awkpath.awk >_$@ + @LC_ALL=C LANG=C AWKPATH="$(srcdir)$(PATH_SEPARATOR)$(srcdir)/lib" $(AWK) -f awkpath.awk >_$@ @-$(CMP) $(srcdir)/awkpath.ok _$@ && rm -f _$@ argtest:: @echo $@ - @$(AWK) -f $(srcdir)/argtest.awk -x -y abc >_$@ + @LC_ALL=C LANG=C $(AWK) -f $(srcdir)/argtest.awk -x -y abc >_$@ @-$(CMP) $(srcdir)/argtest.ok _$@ && rm -f _$@ badargs:: @echo $@ - @-$(AWK) -f 2>&1 | grep -v patchlevel >_$@ + @-LC_ALL=C LANG=C $(AWK) -f 2>&1 | grep -v patchlevel >_$@ @-$(CMP) $(srcdir)/badargs.ok _$@ && rm -f _$@ nonl:: @echo $@ - @-AWKPATH=$(srcdir) $(AWK) --lint -f nonl.awk /dev/null >_$@ 2>&1 +# @-LC_ALL=C LANG=C AWKPATH=$(srcdir) $(AWK) --lint -f nonl.awk /dev/null >_$@ 2>&1 + @-LC_ALL=C LANG=C AWKPATH=$(srcdir) $(AWK) --lint -f nonl.awk NUL >_$@ 2>&1 @-$(CMP) $(srcdir)/nonl.ok _$@ && rm -f _$@ strftime:: - @echo This test could fail on slow machines or on a second boundary, + @echo This test could fail on slow machines or on a minute boundary, @echo so if it does, double check the actual results: @echo $@ @LC_ALL=C; export LC_ALL; LANG=C; export LANG; \ @@ -290,41 +304,41 @@ litoct:: @echo $@ - @echo ab | $(AWK) --traditional -f $(srcdir)/litoct.awk >_$@ + @echo ab | LC_ALL=C LANG=C $(AWK) --traditional -f $(srcdir)/litoct.awk >_$@ @-$(CMP) $(srcdir)/litoct.ok _$@ && rm -f _$@ fflush:: @echo $@ - @$(srcdir)/fflush.sh >_$@ + @LC_ALL=C LANG=C $(srcdir)/fflush.sh >_$@ @-$(CMP) $(srcdir)/fflush.ok _$@ && rm -f _$@ tweakfld:: @echo $@ - @$(AWK) -f $(srcdir)/tweakfld.awk $(srcdir)/tweakfld.in >_$@ + @LC_ALL=C LANG=C $(AWK) -f $(srcdir)/tweakfld.awk $(srcdir)/tweakfld.in >_$@ @rm -f errors.cleanup @-$(CMP) $(srcdir)/tweakfld.ok _$@ && rm -f _$@ mmap8k:: @echo $@ - @$(AWK) '{ print }' $(srcdir)/mmap8k.in >_$@ + @LC_ALL=C LANG=C $(AWK) '{ print }' $(srcdir)/mmap8k.in >_$@ @-$(CMP) $(srcdir)/mmap8k.in _$@ && rm -f _$@ tradanch:: @echo $@ - @$(AWK) --traditional -f $(srcdir)/tradanch.awk $(srcdir)/tradanch.in >_$@ + @LC_ALL=C LANG=C $(AWK) --traditional -f $(srcdir)/tradanch.awk $(srcdir)/tradanch.in >_$@ @-$(CMP) $(srcdir)/tradanch.ok _$@ && rm -f _$@ # AIX /bin/sh exec's the last command in a list, therefore issue a ":" # command so that pid.sh is fork'ed as a child before being exec'ed. pid:: @echo pid - @AWKPATH=$(srcdir) AWK=$(AWKPROG) LC_ALL=C $(SHELL) $(srcdir)/pid.sh $$$$ > _`basename $@` ; : + @AWKPATH=$(srcdir) AWK=$(AWKPROG) LC_ALL=C LANG=C $(SHELL) $(srcdir)/pid.sh $$$$ > _`basename $@` ; : @echo 'Expect pid to fail in DOS.' @-$(CMP) $(srcdir)/pid.ok _`basename $@` && rm -f _`basename $@` _`basename $@`.in strftlng:: @echo $@ - @TZ=UTC; export TZ; $(AWK) -f $(srcdir)/strftlng.awk >_$@ + @TZ=UTC; export TZ; LC_ALL=C LANG=C $(AWK) -f $(srcdir)/strftlng.awk >_$@ @if $(CMP) -s $(srcdir)/strftlng.ok _$@ ; then : ; else \ TZ=UTC0; export TZ; $(AWK) -f $(srcdir)/strftlng.awk >_$@ ; \ fi @@ -337,35 +351,35 @@ reint:: @echo $@ - @$(AWK) --re-interval -f $(srcdir)/reint.awk $(srcdir)/reint.in >_$@ + @LC_ALL=C LANG=C $(AWK) --re-interval -f $(srcdir)/reint.awk $(srcdir)/reint.in >_$@ @-$(CMP) $(srcdir)/reint.ok _$@ && rm -f _$@ pipeio1:: @echo $@ - @$(AWK) -f $(srcdir)/pipeio1.awk >_$@ + @LC_ALL=C LANG=C $(AWK) -f $(srcdir)/pipeio1.awk >_$@ @rm -f test1 test2 @-$(CMP) $(srcdir)/pipeio1.ok _$@ && rm -f _$@ pipeio2:: @echo $@ - @$(AWK) -v SRCDIR=$(srcdir) -f $(srcdir)/pipeio2.awk >_$@ + @LC_ALL=C LANG=C $(AWK) -v SRCDIR=$(srcdir) -f $(srcdir)/pipeio2.awk >_$@ @-$(CMP) $(srcdir)/pipeio2.ok _$@ && rm -f _$@ clobber:: @echo $@ - @$(AWK) -f $(srcdir)/clobber.awk >_$@ + @LC_ALL=C LANG=C $(AWK) -f $(srcdir)/clobber.awk >_$@ @-$(CMP) $(srcdir)/clobber.ok seq && $(CMP) $(srcdir)/clobber.ok _$@ && rm -f _$@ @rm -f seq arynocls:: @echo $@ - @-AWKPATH=$(srcdir) $(AWK) -v INPUT=$(srcdir)/arynocls.in -f arynocls.awk >_$@ + @-AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -v INPUT=$(srcdir)/arynocls.in -f arynocls.awk >_$@ @-$(CMP) $(srcdir)/arynocls.ok _$@ && rm -f _$@ getlnbuf:: @echo $@ - @-AWKPATH=$(srcdir) $(AWK) -f getlnbuf.awk $(srcdir)/getlnbuf.in > _$@ - @-AWKPATH=$(srcdir) $(AWK) -f gtlnbufv.awk $(srcdir)/getlnbuf.in > _2$@ + @-AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f getlnbuf.awk $(srcdir)/getlnbuf.in > _$@ + @-AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f gtlnbufv.awk $(srcdir)/getlnbuf.in > _2$@ @-$(CMP) $(srcdir)/getlnbuf.ok _$@ && $(CMP) $(srcdir)/getlnbuf.ok _2$@ && rm -f _$@ _2$@ inetmesg:: @@ -394,745 +408,914 @@ redfilnm:: @echo $@ - @$(AWK) -f $(srcdir)/redfilnm.awk srcdir=$(srcdir) $(srcdir)/redfilnm.in >_$@ + @LC_ALL=C LANG=C $(AWK) -f $(srcdir)/redfilnm.awk srcdir=$(srcdir) $(srcdir)/redfilnm.in >_$@ @-$(CMP) $(srcdir)/redfilnm.ok _$@ && rm -f _$@ leaddig:: @echo $@ - @$(AWK) -v x=2E -f $(srcdir)/leaddig.awk >_$@ + @LC_ALL=C LANG=C $(AWK) -v x=2E -f $(srcdir)/leaddig.awk >_$@ @-$(CMP) $(srcdir)/leaddig.ok _$@ && rm -f _$@ gsubtst3:: @echo $@ - @$(AWK) --re-interval -f $(srcdir)/$@.awk $(srcdir)/$@.in >_$@ + @LC_ALL=C LANG=C $(AWK) --re-interval -f $(srcdir)/$@.awk $(srcdir)/$@.in >_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ space:: @echo $@ - @echo 'Expect space to fail in DOS.' - @$(AWK) -f ' ' $(srcdir)/space.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @echo 'Expect space to fail with DJGPP.' + @LC_ALL=C LANG=C $(AWK) -f ' ' $(srcdir)/space.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ printf0:: @echo $@ - @$(AWK) --posix -f $(srcdir)/$@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @LC_ALL=C LANG=C $(AWK) --posix -f $(srcdir)/$@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +rsnulbig:: + @echo $@ + @ : Suppose that block size for pipe is at most 128kB: + @$(AWK) 'BEGIN { for (i = 1; i <= 128*64+1; i++) print "abcdefgh123456\n" }' 2>&1 | \ + $(AWK) 'BEGIN { RS = ""; ORS = "\n\n" }; { print }' 2>&1 | \ + $(AWK) '/^[^a]/; END{ print NR }' >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +rsnulbig2:: + @echo $@ + @$(AWK) 'BEGIN { ORS = ""; n = "\n"; for (i = 1; i <= 10; i++) n = (n n); \ + for (i = 1; i <= 128; i++) print n; print "abc\n" }' 2>&1 | \ + $(AWK) 'BEGIN { RS = ""; ORS = "\n\n" };{ print }' 2>&1 | \ + $(AWK) '/^[^a]/; END { print NR }' >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +whiny:: + @echo $@ + @WHINY_USERS=1 $(AWK) -f $(srcdir)/$@.awk $(srcdir)/$@.in >_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + Gt-dummy: # file Maketests, generated from Makefile.am by the Gentests program addcomma: @echo addcomma - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ anchgsub: @echo anchgsub - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ arrayparm: @echo arrayparm - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ arrayref: @echo arrayref - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ arrymem1: @echo arrymem1 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arrayprm2: + @echo arrayprm2 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arrayprm3: + @echo arrayprm3 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arryref2: + @echo arryref2 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arryref3: + @echo arryref3 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arryref4: + @echo arryref4 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arryref5: + @echo arryref5 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ arynasty: @echo arynasty - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm1: + @echo aryprm1 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm2: + @echo aryprm2 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm3: + @echo aryprm3 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm4: + @echo aryprm4 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm5: + @echo aryprm5 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm6: + @echo aryprm6 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm7: + @echo aryprm7 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm8: + @echo aryprm8 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ arysubnm: @echo arysubnm - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ asgext: @echo asgext - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ back89: @echo back89 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ backgsub: @echo backgsub - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ childin: @echo childin - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ clsflnam: @echo clsflnam - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ compare2: @echo compare2 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ concat1: @echo concat1 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ convfmt: @echo convfmt - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ datanonl: @echo datanonl - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ defref: @echo defref - @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ delarprm: @echo delarprm - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +delarpm2: + @echo delarpm2 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ dynlj: @echo dynlj - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ eofsplit: @echo eofsplit - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ fldchg: @echo fldchg - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ fldchgnf: @echo fldchgnf - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +fmttest: + @echo fmttest + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ fnamedat: @echo fnamedat - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ fnarray: @echo fnarray - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +fnarray2: + @echo fnarray2 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ fnarydel: @echo fnarydel - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ fnaryscl: @echo fnaryscl - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ fnasgnm: @echo fnasgnm - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ fnmisc: @echo fnmisc - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ fnparydl: @echo fnparydl - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ forsimp: @echo forsimp - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ fsbs: @echo fsbs - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ fsrs: @echo fsrs - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ fstabplus: @echo fstabplus - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ funsemnl: @echo funsemnl - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ funsmnam: @echo funsmnam - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ funstack: @echo funstack - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @echo 'Expect funstack to fail with MSC DOS versions.' + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ getline: @echo getline - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ getline3: @echo getline3 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ getnr2tb: @echo getnr2tb - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ getnr2tm: @echo getnr2tm - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ gsubasgn: @echo gsubasgn - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ gsubtest: @echo gsubtest - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ gsubtst2: @echo gsubtst2 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ gsubtst4: @echo gsubtst4 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +gsubtst5: + @echo gsubtst5 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ hsprint: @echo hsprint - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @echo 'hsprint may fail due to 1.27e+01 not being equal to' + @echo '1.27e+001 (and similarly for other numbers) for MSC gawk.' + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ inputred: @echo inputred - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ intest: @echo intest - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ intprec: @echo intprec - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ leadnl: @echo leadnl - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ longsub: @echo longsub - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @echo 'Expect longsub to fail with MSC DOS versions.' + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ longwrds: @echo longwrds - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @echo "longwrds may run out of environment space with MSC DOS versions." + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ math: @echo math - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ membug1: @echo membug1 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ minusstr: @echo minusstr - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ nasty: @echo nasty - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ nasty2: @echo nasty2 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ negexp: @echo negexp - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +nested: + @echo nested + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ nfldstr: @echo nfldstr - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ nfneg: @echo nfneg - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ nfset: @echo nfset - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ nlfldsep: @echo nlfldsep - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ nlinstr: @echo nlinstr - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ nlstrina: @echo nlstrina - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ noeffect: @echo noeffect - @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ nofmtch: @echo nofmtch - @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ noloop1: @echo noloop1 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ noloop2: @echo noloop2 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ noparms: @echo noparms - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ nulrsend: @echo nulrsend - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ numindex: @echo numindex - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ numsubstr: @echo numsubstr - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ octsub: @echo octsub - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ofmt: @echo ofmt - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ofmtbig: @echo ofmtbig - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ofmtfidl: @echo ofmtfidl - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ofmts: @echo ofmts - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ onlynl: @echo onlynl - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ opasnidx: @echo opasnidx - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ opasnslf: @echo opasnslf - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ paramdup: @echo paramdup - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ paramtyp: @echo paramtyp - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ parseme: @echo parseme - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ pcntplus: @echo pcntplus - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ prdupval: @echo prdupval - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ prec: @echo prec - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ printf1: @echo printf1 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ prmarscl: @echo prmarscl - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ prmreuse: @echo prmreuse - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ prt1eval: @echo prt1eval - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ prtoeval: @echo prtoeval - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ psx96sub: @echo psx96sub - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ rand: @echo rand - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ rebt8b1: @echo rebt8b1 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ rebt8b2: @echo rebt8b2 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ regeq: @echo regeq - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ reindops: @echo reindops - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ reparse: @echo reparse - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ resplit: @echo resplit - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ rs: @echo rs - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ rsnul1nl: @echo rsnul1nl - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ rstest1: @echo rstest1 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ rstest2: @echo rstest2 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +rstest3: + @echo rstest3 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +rstest4: + @echo rstest4 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +rstest5: + @echo rstest5 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ rswhite: @echo rswhite - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +scalar: + @echo scalar + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ sclforin: @echo sclforin - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ sclifin: @echo sclifin - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +sortempty: + @echo sortempty + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ splitargv: @echo splitargv - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ splitarr: @echo splitarr - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ splitdef: @echo splitdef - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ splitvar: @echo splitvar - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ splitwht: @echo splitwht - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ sprintfc: @echo sprintfc - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ strtod: @echo strtod - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ subslash: @echo subslash - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ substr: @echo substr - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ swaplns: @echo swaplns - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ synerr1: @echo synerr1 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ - @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ - -uninitialized: - @echo uninitialized - @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ uninit2: @echo uninit2 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +uninit3: + @echo uninit3 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +uninit4: + @echo uninit4 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +uninitialized: + @echo uninitialized + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ zeroe0: @echo zeroe0 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ zeroflag: @echo zeroflag - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ getlnhd: @echo getlnhd - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ asort: @echo asort - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ asorti: @echo asorti - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ clos1way: @echo clos1way - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ @echo Expect clos1way to fail with MSC and DJGPP because "|&" is not supported. fieldwdth: @echo fieldwdth - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ fsfwfs: @echo fsfwfs - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ gensub: @echo gensub - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ gnuops2: @echo gnuops2 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ gnureops: @echo gnureops - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ icasefs: @echo icasefs - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ icasers: @echo icasers - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ igncdym: @echo igncdym - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ igncfs: @echo igncfs - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ignrcase: @echo ignrcase - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ lint: @echo lint - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ match1: @echo match1 + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +match2: + @echo match2 @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ nondec: @echo nondec - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ posix: @echo posix - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @echo 'posix test may fail due to 1.500000e+000 not being equal to' + @echo '1.500000e+00 for MSC gawk.' + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ procinfs: @echo procinfs - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ regx8bit: @echo regx8bit - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ rebuf: @echo rebuf - @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ shadow: @echo shadow - @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ sort1: @echo sort1 - @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +strtonum: + @echo strtonum + @AWKPATH=$(srcdir) LC_ALL=C LANG=C $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ # end of file Maketests @@ -1143,7 +1326,7 @@ $(AWK) -f $(srcdir)/Gentests "$<" *.awk *.in > $(srcdir)/Maketests clean: - rm -fr _* core junk out1 out2 out3 strftime.ok test1 test2 seq *~ + rm -fr _* core core.* junk out1 out2 out3 strftime.ok test1 test2 seq *~ # An attempt to print something that can be grepped for in build logs pass-fail: diff -urN gawk-3.1.2/pc/config.h gawk-3.1.3/pc/config.h --- gawk-3.1.2/pc/config.h 2003-02-18 05:47:26.000000000 -0800 +++ gawk-3.1.3/pc/config.h 2003-06-15 09:29:42.000000000 -0700 @@ -340,13 +340,14 @@ # define HAVE_POPEN_H -/* #if defined (_MSC_VER) */ -#define ssize_t long int -/* #endif */ - +#if defined(_MSC_VER) && defined(MSDOS) +#define system(s) os_system(s) +#endif -#if (defined(_MSC_VER) && defined(MSDOS)) || defined(__MINGW32__) -# define system(s) os_system(s) +#if defined(_MSC_VER) || defined(__MINGW32__) +#define ssize_t long int /* DJGPP has ssize_t */ +#define intmax_t long +#define uintmax_t unsigned long #endif #if defined (_MSC_VER) || defined(__EMX__) @@ -357,6 +358,8 @@ #if defined(DJGPP) # define HAVE_LIMITS_H 1 # undef HAVE_POPEN_H +#define intmax_t long long +#define uintmax_t unsigned long long #endif #if defined(__WIN32__) && defined(__CRTRSXNT__) @@ -372,3 +375,6 @@ #if defined(__MINGW32__) #undef HAVE_SYS_PARAM_H #endif + + +/* #define NO_LINT 1 */ diff -urN gawk-3.1.2/pc/dlfcn.c gawk-3.1.3/pc/dlfcn.c --- gawk-3.1.2/pc/dlfcn.c 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/pc/dlfcn.c 2003-03-23 19:43:45.000000000 -0800 @@ -0,0 +1,84 @@ +/* +** dlfcn.c -- limited implementation of posix dynamic loading functions +*/ + +/* + * Copyright (C) 2003 the Free Software Foundation, Inc. + * + * This file is part of GAWK, the GNU implementation of the + * AWK Programming Language. + * + * GAWK is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * GAWK is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA + */ + +#include +#include +#include + +/* open the library file. We currently ignore flags. */ +void *dlopen(const char * libname, int flags) +{ + HMODULE libH; + + + /* if libname is specified, we need to load a library of that name */ + if (libname) { + libH = LoadLibrary(libname); + } + + /* otherwise, we're supposed to return a handle to global symbol + * information, which includes the executable and all libraries loaded + * with RTLD_GLOBAL. For our purposes, it doesn't really matter, so + * we simply return the handle to the .exe */ + else { + libH = GetModuleHandle(NULL); + } + + return (void *)libH; +} + + +/* don't need the library any more */ +int dlclose(void * libH) +{ + int rc; + + if (FreeLibrary((HMODULE)libH)) { + rc = 0; + } + else { + rc = -1; + } + + return rc; +} + +/* find the symbol */ +void *dlsym(void * /*restrict*/ libH, const char * /*restrict*/ fnName) +{ + return (void *)GetProcAddress((HMODULE)libH, fnName); +} + +char *dlerror(void) +{ + static char errbuf[1024]; + + FormatMessage(FORMAT_MESSAGE_FROM_SYSTEM, NULL, GetLastError(), + MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), errbuf, sizeof(errbuf), NULL); + + return errbuf; +} + + diff -urN gawk-3.1.2/pc/dlfcn.h gawk-3.1.3/pc/dlfcn.h --- gawk-3.1.2/pc/dlfcn.h 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/pc/dlfcn.h 2003-03-20 23:16:56.000000000 -0800 @@ -0,0 +1,41 @@ +/* +** dlfcn.h -- limited implementation of posix dynamic loading functions +*/ + +/* + * Copyright (C) 2003 the Free Software Foundation, Inc. + * + * This file is part of GAWK, the GNU implementation of the + * AWK Programming Language. + * + * GAWK is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * GAWK is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA + */ + +#ifndef _DLFCN_H +#define _DLFCN_H + +/* symbols required by susv3. These are not supported here (everything is + * RTLD_NOW, RTLD_GLOBAL) */ +#define RTLD_LAZY 0 +#define RTLD_NOW 1 +#define RTLD_GLOBAL 0 +#define RTLD_LOCAL 2 + +int dlclose(void *); +char *dlerror(void); +void *dlopen(const char *, int); +void *dlsym(void * /*restrict*/, const char * /*restrict*/); + +#endif diff -urN gawk-3.1.2/pc/gawkmisc.pc gawk-3.1.3/pc/gawkmisc.pc --- gawk-3.1.2/pc/gawkmisc.pc 2003-02-04 04:19:35.000000000 -0800 +++ gawk-3.1.3/pc/gawkmisc.pc 2003-05-11 05:13:38.000000000 -0700 @@ -61,6 +61,42 @@ return strlwr(p); } + +/* + * memcpy_long() & memset_ulong() are 32-bit replacements for MSC which + * has a 16-bit size_t. + */ +char * +memcpy_ulong (dest, src, l) +register char *dest; +register const char *src; +register unsigned long l; +{ + register char *ret = dest; + + while (l--) + *dest++ = *src++; + + return ret; +} + + +void * +memset_ulong(dest, val, l) +void *dest; +register int val; +register unsigned long l; +{ + register char *ret = dest; + register char *d = dest; + + while (l--) + *d++ = val; + + return ((void *) ret); +} + + /* os_arg_fixup --- fixup the command line */ void diff -urN gawk-3.1.2/pc/gawkw32.def gawk-3.1.3/pc/gawkw32.def --- gawk-3.1.2/pc/gawkw32.def 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/pc/gawkw32.def 2003-06-29 05:55:47.000000000 -0700 @@ -0,0 +1,37 @@ +;; export definitions for Windows32 gawk +;; this is to support extension libraries -- this should generate a gawk.lib +;; against which they can link +;; don't change the ordinals (the numbers after the function names) + +EXPORTS + +;; functions related directly to adding external functions +get_argument @1 +set_value @2 +make_builtin @3 + +;; functions for manipulating data types +mk_number @11 +tmp_string @12 +unref @13 +r_force_string @14 +r_force_number @15 +nodetype2str @16 + + +;; incidental other functions +assoc_lookup @31 +assoc_clear @32 +r_dupnode @33 +set_loc @34 +update_ERRNO @35 +r_fatal @36 +get_actual @37 + +;; data -- note that this must be redeclared with __declspec(dllimport) in the extension +;; library since the exported symbol is actually a pointer to the data + +CONVFMTidx @101 +lintfunc @102 +do_lint @103 +stack_ptr @104 diff -urN gawk-3.1.2/po/ChangeLog gawk-3.1.3/po/ChangeLog --- gawk-3.1.2/po/ChangeLog 2003-03-19 04:22:47.000000000 -0800 +++ gawk-3.1.3/po/ChangeLog 2003-07-07 11:02:28.000000000 -0700 @@ -1,3 +1,17 @@ +Mon Jul 7 11:01:43 2003 Arnold D. Robbins + + * Release 3.1.3: Release tar file made. + +2003-06-16 gettextize + + * Makefile.in.in: Upgrade to gettext-0.12.1. + * Rules-quot: New file, from gettext-0.12.1. + * boldquot.sed: New file, from gettext-0.12.1. + * en@boldquot.header: New file, from gettext-0.12.1. + * en@quot.header: New file, from gettext-0.12.1. + * insert-header.sin: New file, from gettext-0.12.1. + * quot.sed: New file, from gettext-0.12.1. + Wed Mar 19 14:10:31 2003 Arnold D. Robbins This time for sure. diff -urN gawk-3.1.2/po/LINGUAS gawk-3.1.3/po/LINGUAS --- gawk-3.1.2/po/LINGUAS 2003-02-06 01:25:48.000000000 -0800 +++ gawk-3.1.3/po/LINGUAS 2003-05-08 00:11:27.000000000 -0700 @@ -7,3 +7,4 @@ de da pt_BR +ca diff -urN gawk-3.1.2/po/Makefile.in.in gawk-3.1.3/po/Makefile.in.in --- gawk-3.1.2/po/Makefile.in.in 2002-09-19 01:00:07.000000000 -0700 +++ gawk-3.1.3/po/Makefile.in.in 2003-06-16 03:25:33.000000000 -0700 @@ -1,5 +1,5 @@ # Makefile for PO directory in any package using GNU gettext. -# Copyright (C) 1995-1997, 2000-2002 by Ulrich Drepper +# Copyright (C) 1995-1997, 2000-2003 by Ulrich Drepper # # This file can be copied and used freely without restrictions. It can # be used in projects which are not available under the GNU General Public @@ -27,7 +27,7 @@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ MKINSTALLDIRS = @MKINSTALLDIRS@ -mkinstalldirs = $(SHELL) `case "$(MKINSTALLDIRS)" in /*) echo "$(MKINSTALLDIRS)" ;; *) echo "$(top_builddir)/$(MKINSTALLDIRS)" ;; esac` +mkinstalldirs = $(SHELL) $(MKINSTALLDIRS) GMSGFMT = @GMSGFMT@ MSGFMT = @MSGFMT@ @@ -42,9 +42,9 @@ GMOFILES = @GMOFILES@ UPDATEPOFILES = @UPDATEPOFILES@ DUMMYPOFILES = @DUMMYPOFILES@ -DISTFILES.common = Makefile.in.in Makevars remove-potcdate.sin \ +DISTFILES.common = Makefile.in.in remove-potcdate.sin \ $(DISTFILES.common.extra1) $(DISTFILES.common.extra2) $(DISTFILES.common.extra3) -DISTFILES = $(DISTFILES.common) POTFILES.in $(DOMAIN).pot \ +DISTFILES = $(DISTFILES.common) Makevars POTFILES.in $(DOMAIN).pot stamp-po \ $(POFILES) $(GMOFILES) \ $(DISTFILES.extra1) $(DISTFILES.extra2) $(DISTFILES.extra3) @@ -74,18 +74,35 @@ all: all-@USE_NLS@ -all-yes: $(CATALOGS) +all-yes: stamp-po all-no: +# stamp-po is a timestamp denoting the last time at which the CATALOGS have +# been loosely updated. Its purpose is that when a developer or translator +# checks out the package via CVS, and the $(DOMAIN).pot file is not in CVS, +# "make" will update the $(DOMAIN).pot and the $(CATALOGS), but subsequent +# invocations of "make" will do nothing. This timestamp would not be necessary +# if updating the $(CATALOGS) would always touch them; however, the rule for +# $(POFILES) has been designed to not touch files that don't need to be +# changed. +stamp-po: $(srcdir)/$(DOMAIN).pot + test -z "$(CATALOGS)" || $(MAKE) $(CATALOGS) + @echo "touch stamp-po" + @echo timestamp > stamp-poT + @mv stamp-poT stamp-po + # Note: Target 'all' must not depend on target '$(DOMAIN).pot-update', # otherwise packages like GCC can not be built if only parts of the source # have been downloaded. +# This target rebuilds $(DOMAIN).pot; it is an expensive operation. +# Note that $(DOMAIN).pot is not touched if it doesn't need to be changed. $(DOMAIN).pot-update: $(POTFILES) $(srcdir)/POTFILES.in remove-potcdate.sed $(XGETTEXT) --default-domain=$(DOMAIN) --directory=$(top_srcdir) \ --add-comments=TRANSLATORS: $(XGETTEXT_OPTIONS) \ --files-from=$(srcdir)/POTFILES.in \ - --copyright-holder='$(COPYRIGHT_HOLDER)' + --copyright-holder='$(COPYRIGHT_HOLDER)' \ + --msgid-bugs-address='$(MSGID_BUGS_ADDRESS)' test ! -f $(DOMAIN).po || { \ if test -f $(srcdir)/$(DOMAIN).pot; then \ sed -f remove-potcdate.sed < $(srcdir)/$(DOMAIN).pot > $(DOMAIN).1po && \ @@ -101,9 +118,14 @@ fi; \ } +# This rule has no dependencies: we don't need to update $(DOMAIN).pot at +# every "make" invocation, only create it when it is missing. +# Only "make $(DOMAIN).pot-update" or "make dist" will force an update. $(srcdir)/$(DOMAIN).pot: $(MAKE) $(DOMAIN).pot-update +# This target rebuilds a PO file if $(DOMAIN).pot has changed. +# Note that a PO file is not touched if it doesn't need to be changed. $(POFILES): $(srcdir)/$(DOMAIN).pot @lang=`echo $@ | sed -e 's,.*/,,' -e 's/\.po$$//'`; \ test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \ @@ -114,12 +136,15 @@ install: install-exec install-data install-exec: install-data: install-data-@USE_NLS@ - if test "$(PACKAGE)" = "gettext"; then \ + if test "$(PACKAGE)" = "gettext-tools"; then \ $(mkinstalldirs) $(DESTDIR)$(gettextsrcdir); \ - for file in $(DISTFILES.common); do \ + for file in $(DISTFILES.common) Makevars.template; do \ $(INSTALL_DATA) $(srcdir)/$$file \ $(DESTDIR)$(gettextsrcdir)/$$file; \ done; \ + for file in Makevars; do \ + rm -f $(DESTDIR)$(gettextsrcdir)/$$file; \ + done; \ else \ : ; \ fi @@ -170,7 +195,7 @@ installdirs: installdirs-exec installdirs-data installdirs-exec: installdirs-data: installdirs-data-@USE_NLS@ - if test "$(PACKAGE)" = "gettext"; then \ + if test "$(PACKAGE)" = "gettext-tools"; then \ $(mkinstalldirs) $(DESTDIR)$(gettextsrcdir); \ else \ : ; \ @@ -215,8 +240,8 @@ uninstall: uninstall-exec uninstall-data uninstall-exec: uninstall-data: uninstall-data-@USE_NLS@ - if test "$(PACKAGE)" = "gettext"; then \ - for file in $(DISTFILES.common); do \ + if test "$(PACKAGE)" = "gettext-tools"; then \ + for file in $(DISTFILES.common) Makevars.template; do \ rm -f $(DESTDIR)$(gettextsrcdir)/$$file; \ done; \ else \ @@ -235,10 +260,11 @@ check: all -dvi info tags TAGS ID: +info dvi ps pdf html tags TAGS ctags CTAGS ID: mostlyclean: rm -f remove-potcdate.sed + rm -f stamp-poT rm -f core core.* $(DOMAIN).po $(DOMAIN).1po $(DOMAIN).2po *.new.po rm -fr *.o @@ -250,7 +276,7 @@ maintainer-clean: distclean @echo "This command is intended for maintainers to use;" @echo "it deletes files that may require special tools to rebuild." - rm -f $(GMOFILES) + rm -f stamp-po $(GMOFILES) distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir) dist distdir: @@ -259,7 +285,17 @@ # This is a separate target because 'update-po' must be executed before. dist2: $(DISTFILES) dists="$(DISTFILES)"; \ - if test -f $(srcdir)/ChangeLog; then dists="$$dists ChangeLog"; fi; \ + if test "$(PACKAGE)" = "gettext-tools"; then \ + dists="$$dists Makevars.template"; \ + fi; \ + if test -f $(srcdir)/ChangeLog; then \ + dists="$$dists ChangeLog"; \ + fi; \ + for i in 0 1 2 3 4 5 6 7 8 9; do \ + if test -f $(srcdir)/ChangeLog.$$i; then \ + dists="$$dists ChangeLog.$$i"; \ + fi; \ + done; \ if test -f $(srcdir)/LINGUAS; then dists="$$dists LINGUAS"; fi; \ for file in $$dists; do \ if test -f $$file; then \ @@ -271,14 +307,14 @@ update-po: Makefile $(MAKE) $(DOMAIN).pot-update - $(MAKE) $(UPDATEPOFILES) + test -z "$(UPDATEPOFILES)" || $(MAKE) $(UPDATEPOFILES) $(MAKE) update-gmo # General rule for updating PO files. .nop.po-update: @lang=`echo $@ | sed -e 's/\.po-update$$//'`; \ - if test "$(PACKAGE)" = "gettext"; then PATH=`pwd`/../src:$$PATH; fi; \ + if test "$(PACKAGE)" = "gettext-tools"; then PATH=`pwd`/../src:$$PATH; fi; \ tmpdir=`pwd`; \ echo "$$lang:"; \ test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \ @@ -305,7 +341,7 @@ update-gmo: Makefile $(GMOFILES) @: -Makefile: Makefile.in.in $(top_builddir)/config.status POTFILES.in +Makefile: Makefile.in.in $(top_builddir)/config.status @POMAKEFILEDEPS@ cd $(top_builddir) \ && CONFIG_FILES=$(subdir)/$@.in CONFIG_HEADERS= \ $(SHELL) ./config.status diff -urN gawk-3.1.2/po/Makevars gawk-3.1.3/po/Makevars --- gawk-3.1.2/po/Makevars 2002-02-19 08:06:29.000000000 -0800 +++ gawk-3.1.3/po/Makevars 2003-06-16 03:28:02.000000000 -0700 @@ -20,6 +20,22 @@ # their copyright. COPYRIGHT_HOLDER = Free Software Foundation, Inc. +# This is the email address or URL to which the translators shall report +# bugs in the untranslated strings: +# - Strings which are not entire sentences, see the maintainer guidelines +# in the GNU gettext documentation, section 'Preparing Strings'. +# - Strings which use unclear terms or require additional context to be +# understood. +# - Strings which make invalid assumptions about notation of date, time or +# money. +# - Pluralisation problems. +# - Incorrect English spelling. +# - Incorrect formatting. +# It can be your email address, or a mailing list address where translators +# can write to without being subscribed, or the URL of a web page through +# which the translators can contact you. +MSGID_BUGS_ADDRESS = arnold@skeeve.com + # This is the list of locale categories, beyond LC_MESSAGES, for which the # message catalogs shall be used. It is usually empty. EXTRA_LOCALE_CATEGORIES = diff -urN gawk-3.1.2/po/Rules-quot gawk-3.1.3/po/Rules-quot --- gawk-3.1.2/po/Rules-quot 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/po/Rules-quot 2003-06-16 03:25:34.000000000 -0700 @@ -0,0 +1,42 @@ +# Special Makefile rules for English message catalogs with quotation marks. + +DISTFILES.common.extra1 = quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot + +.SUFFIXES: .insert-header .po-update-en + +en@quot.po-update: en@quot.po-update-en +en@boldquot.po-update: en@boldquot.po-update-en + +.insert-header.po-update-en: + @lang=`echo $@ | sed -e 's/\.po-update-en$$//'`; \ + if test "$(PACKAGE)" = "gettext"; then PATH=`pwd`/../src:$$PATH; GETTEXTLIBDIR=`cd $(top_srcdir)/src && pwd`; export GETTEXTLIBDIR; fi; \ + tmpdir=`pwd`; \ + echo "$$lang:"; \ + ll=`echo $$lang | sed -e 's/@.*//'`; \ + LC_ALL=C; export LC_ALL; \ + cd $(srcdir); \ + 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 \ + if cmp $$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \ + rm -f $$tmpdir/$$lang.new.po; \ + else \ + if mv -f $$tmpdir/$$lang.new.po $$lang.po; then \ + :; \ + else \ + echo "creation of $$lang.po failed: cannot move $$tmpdir/$$lang.new.po to $$lang.po" 1>&2; \ + exit 1; \ + fi; \ + fi; \ + else \ + echo "creation of $$lang.po failed!" 1>&2; \ + rm -f $$tmpdir/$$lang.new.po; \ + fi + +en@quot.insert-header: insert-header.sin + sed -e '/^#/d' -e 's/HEADER/en@quot.header/g' $(srcdir)/insert-header.sin > en@quot.insert-header + +en@boldquot.insert-header: insert-header.sin + sed -e '/^#/d' -e 's/HEADER/en@boldquot.header/g' $(srcdir)/insert-header.sin > en@boldquot.insert-header + +mostlyclean: mostlyclean-quot +mostlyclean-quot: + rm -f *.insert-header diff -urN gawk-3.1.2/po/boldquot.sed gawk-3.1.3/po/boldquot.sed --- gawk-3.1.2/po/boldquot.sed 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/po/boldquot.sed 2003-06-16 03:25:34.000000000 -0700 @@ -0,0 +1,10 @@ +s/"\([^"]*\)"/“\1â€/g +s/`\([^`']*\)'/‘\1’/g +s/ '\([^`']*\)' / ‘\1’ /g +s/ '\([^`']*\)'$/ ‘\1’/g +s/^'\([^`']*\)' /‘\1’ /g +s/“â€/""/g +s/“/“/g +s/â€/â€/g +s/‘/‘/g +s/’/’/g Binary files gawk-3.1.2/po/ca.gmo and gawk-3.1.3/po/ca.gmo differ diff -urN gawk-3.1.2/po/ca.po gawk-3.1.3/po/ca.po --- gawk-3.1.2/po/ca.po 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/po/ca.po 2003-07-07 11:20:35.000000000 -0700 @@ -0,0 +1,1863 @@ +# translation of gawk.po to Catalan +# Copyright (C) 2003 Free Software Foundation, Inc. +# Antoni Bella Perez , 2003. +# +msgid "" +msgstr "" +"Project-Id-Version: gawk 3.1.31\n" +"Report-Msgid-Bugs-To: arnold@skeeve.com\n" +"POT-Creation-Date: 2003-07-07 11:20-0700\n" +"PO-Revision-Date: 2003-05-07 21:13+0100\n" +"Last-Translator: Antoni Bella Perez \n" +"Language-Team: Catalan \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=ISO-8859-1\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: KBabel 1.0.1\n" + +#: array.c:112 +#, c-format +msgid "attempt to use scalar parameter `%s' as an array" +msgstr "s'ha intentat usar un paràmetre escalar «%s» com a una matriu" + +#: array.c:113 +#, c-format +msgid "attempt to use scalar `%s' as array" +msgstr "s'ha intentat usar la dada escalar «%s» com a una matriu" + +#: array.c:151 +#, fuzzy, c-format +msgid "from %s" +msgstr "%s (de %s)" + +#: array.c:506 +#, c-format +msgid "reference to uninitialized element `%s[\"%s\"]'" +msgstr "referència a un element sense valor inicial «%s[\"%s\"]»" + +#: array.c:512 +#, c-format +msgid "subscript of array `%s' is null string" +msgstr "el subscript de la matriu «%s» és una cadena nul·la" + +#: array.c:609 +#, c-format +msgid "delete: index `%s' not in array `%s'" +msgstr "delete: l'índex «%s» no està en la matriu «%s»" + +#: array.c:769 +#, c-format +msgid "%s: empty (null)\n" +msgstr "%s: buit (nul)\n" + +#: array.c:774 +#, c-format +msgid "%s: empty (zero)\n" +msgstr "%s: buit (zero)\n" + +#: array.c:778 +#, c-format +msgid "%s: table_size = %d, array_size = %d\n" +msgstr "%s: mida_taula = %d, mida_matriu = %d\n" + +#: array.c:807 +#, fuzzy, c-format +msgid "%s: is parameter\n" +msgstr "%s: és un paràmetre\n" + +#: array.c:812 +#, c-format +msgid "%s: array_ref to %s\n" +msgstr "%s: ref_matriu a %s\n" + +#: awkgram.y:208 +#, fuzzy, c-format +msgid "%s blocks must have an action part" +msgstr "Els blocs FINAL han de tindre una part d'acció" + +#: awkgram.y:211 +#, fuzzy +msgid "each rule must have a pattern or an action part" +msgstr "Els blocs FINAL han de tindre una part d'acció" + +#: awkgram.y:267 +#, c-format +msgid "`%s' is a built-in function, it cannot be redefined" +msgstr "«%s» és una funció interna, no pot ser redefinida" + +#: awkgram.y:314 +#, c-format +msgid "regexp constant `/%s/' looks like a C comment, but is not" +msgstr "" +"la constant d'expressió regular «/%s/» sembla un comentari en C, perà no ho " +"és" + +#: awkgram.y:340 awkgram.y:615 +msgid "statement may have no effect" +msgstr "la declaració podria no tindre efecte" + +#: awkgram.y:435 awkgram.y:455 +#, fuzzy, c-format +msgid "`%s' used in %s action" +msgstr "«next» és usat dintre de l'acció BEGIN o END" + +#: awkgram.y:448 awkgram.y:451 +msgid "`nextfile' is a gawk extension" +msgstr "«nextfile» és una extensió de gawk" + +#: awkgram.y:465 +msgid "`return' used outside function context" +msgstr "«return» és usat fora del context d'una funció" + +#: awkgram.y:504 +msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'" +msgstr "" +"el «print» simple en la regla BEGIN o END probablement ha de ser «print \"\"»" + +#: awkgram.y:517 awkgram.y:524 +msgid "`delete array' is a gawk extension" +msgstr "«delete array» és una extensió de gawk" + +#: awkgram.y:532 awkgram.y:539 +#, fuzzy +msgid "`delete(array)' is a non-portable tawk extension" +msgstr "«delete array» és una extensió de gawk" + +#: awkgram.y:583 +#, c-format +msgid "duplicate case values in switch body: %s" +msgstr "" + +#: awkgram.y:593 +msgid "Duplicate `default' detected in switch body" +msgstr "" + +#: awkgram.y:681 +msgid "multistage two-way pipelines don't work" +msgstr "les canonades bidireccionals multi-etapes no funcionen" + +#: awkgram.y:772 +msgid "regular expression on right of assignment" +msgstr "expressió regular a la dreta d'una assignació" + +#: awkgram.y:782 +msgid "regular expression on left of `~' or `!~' operator" +msgstr "expressió regular a l'esquerra de l'operador «~» o «!~»" + +#: awkgram.y:790 +msgid "regular expression on right of comparison" +msgstr "expressió regular a la derta de la comparació" + +#: awkgram.y:857 +msgid "non-redirected `getline' undefined inside END action" +msgstr "«getline» no redirigit sense definir dintre de l'acció FINAL" + +#: awkgram.y:884 +msgid "call of `length' without parentheses is not portable" +msgstr "la crida de «length» sense parèntesis no és portable" + +#: awkgram.y:887 +msgid "call of `length' without parentheses is deprecated by POSIX" +msgstr "la crida de «length» sense parèntesis està desaprovada per POSIX" + +#: awkgram.y:940 +msgid "use of non-array as array" +msgstr "" + +#: awkgram.y:942 +msgid "invalid subscript expression" +msgstr "expressió de subscript no vàlida" + +#: awkgram.y:1140 +#, fuzzy +msgid "unexpected newline or end of string" +msgstr "nova línia inesperada" + +#: awkgram.y:1235 +msgid "empty program text on command line" +msgstr "el text del programa en la línia de comandaments està buit" + +#: awkgram.y:1292 +#, c-format +msgid "can't open source file `%s' for reading (%s)" +msgstr "no es pot obrir el fitxer font «%s» per a lectura (%s)" + +#: awkgram.y:1327 +#, c-format +msgid "can't read sourcefile `%s' (%s)" +msgstr "no es pot llegir el fitxer font «%s» (%s)" + +#: awkgram.y:1335 +#, c-format +msgid "source file `%s' is empty" +msgstr "el fitxer font «%s» està buit" + +#: awkgram.y:1537 awkgram.y:1647 awkgram.y:1665 awkgram.y:2015 awkgram.y:2100 +msgid "source file does not end in newline" +msgstr "el fitxer font no finalitza amb un retorn de carro" + +#: awkgram.y:1601 +msgid "unterminated regexp ends with `\\' at end of file" +msgstr "expressió regular sense finalitzar acaba amb «\\» al final del fitxer" + +#: awkgram.y:1621 +msgid "unterminated regexp" +msgstr "expressió regular sense finalitzar" + +#: awkgram.y:1624 +msgid "unterminated regexp at end of file" +msgstr "expressió regular sense finalitzar al final del fitxer" + +#: awkgram.y:1691 +msgid "use of `\\ #...' line continuation is not portable" +msgstr "l'ús de «\\ #...» com a continuació de línia no és portable" + +#: awkgram.y:1703 +msgid "backslash not last character on line" +msgstr "la barra invertida no és l'últim caràcter en la línia" + +#: awkgram.y:1748 +msgid "POSIX does not allow operator `**='" +msgstr "POSIX no permet l'operador «**=»" + +#: awkgram.y:1750 +msgid "old awk does not support operator `**='" +msgstr "l'antic awk no suporta l'operador «**=»" + +#: awkgram.y:1759 +msgid "POSIX does not allow operator `**'" +msgstr "POSIX no permet l'operador «**»" + +#: awkgram.y:1761 +msgid "old awk does not support operator `**'" +msgstr "l'antic awk no suporta l'operador «**=»" + +#: awkgram.y:1792 +msgid "operator `^=' is not supported in old awk" +msgstr "l'operador «^=» no està suportat en l'antic awk" + +#: awkgram.y:1800 +msgid "operator `^' is not supported in old awk" +msgstr "l'operador «^» no està suportat en l'antic awk" + +#: awkgram.y:1884 awkgram.y:1901 +msgid "unterminated string" +msgstr "cadena sense finalitzar" + +#: awkgram.y:2061 +#, c-format +msgid "invalid char '%c' in expression" +msgstr "caràcter «%c» no vàlid en l'expressió" + +#: awkgram.y:2121 +#, c-format +msgid "`%s' is a gawk extension" +msgstr "«%s» és una extensió de gawk" + +#: awkgram.y:2124 +#, c-format +msgid "`%s' is a Bell Labs extension" +msgstr "«%s» és una extensió de Bell Labs" + +#: awkgram.y:2127 +#, c-format +msgid "POSIX does not allow `%s'" +msgstr "POSIX no permet «%s»" + +#: awkgram.y:2131 +#, c-format +msgid "`%s' is not supported in old awk" +msgstr "«%s» no està suportat en l'antic awk" + +#: awkgram.y:2158 +msgid "`goto' considered harmful!\n" +msgstr "«goto» se considera nefast!\n" + +#: awkgram.y:2220 +#, c-format +msgid "%d is invalid as number of arguments for %s" +msgstr "%d no és vàlid com a nombre d'arguments per a %s" + +#: awkgram.y:2239 awkgram.y:2242 +msgid "match: third argument is a gawk extension" +msgstr "match: el tercer argument és una extensió de gawk" + +#: awkgram.y:2255 +#, c-format +msgid "%s: string literal as last arg of substitute has no effect" +msgstr "%s: la cadena literal com a últim argument de substitució no té efecte" + +#: awkgram.y:2258 +#, fuzzy, c-format +msgid "%s third parameter is not a changeable object" +msgstr "sub: el tercer argument no és un objecte intercanviable" + +#: awkgram.y:2285 awkgram.y:2288 +msgid "close: second argument is a gawk extension" +msgstr "close: el segon argument és una extensió de gawk" + +#: awkgram.y:2298 +msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore" +msgstr "" +"l'ús de dcgettext(_\"...\") no és correcte: elimineu el guió baix inicial" + +#: awkgram.y:2313 +#, fuzzy +msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore" +msgstr "" +"l'ús de dcgettext(_\"...\") no és correcte: elimineu el guió baix inicial" + +#: awkgram.y:2384 +#, c-format +msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d" +msgstr "funció «%s»: paràmetre #%d, «%s», duplica al paràmetre #%d" + +#: awkgram.y:2417 +#, c-format +msgid "function `%s': parameter `%s' shadows global variable" +msgstr "funció «%s»: paràmetre «%s» ofusca la variable global" + +#: awkgram.y:2529 +#, c-format +msgid "could not open `%s' for writing (%s)" +msgstr "no es pot obrir «%s» per a escriptura (%s)" + +#: awkgram.y:2530 profile.c:93 +msgid "sending profile to standard error" +msgstr "enviant el perfil a l'eixida d'error estàndard" + +#: awkgram.y:2562 +#, c-format +msgid "%s: close failed (%s)" +msgstr "%s: tancament erroni (%s)" + +#: awkgram.y:2684 +msgid "shadow_funcs() called twice!" +msgstr "shadow_funcs() crida dos vegades!" + +#: awkgram.y:2711 +msgid "there were shadowed variables." +msgstr "" + +#: awkgram.y:2784 +#, c-format +msgid "function `%s': can't use function name as parameter name" +msgstr "funció «%s»: no pot usar el nom de la funció com a paràmetre" + +#: awkgram.y:2794 +#, c-format +msgid "function name `%s' previously defined" +msgstr "nom de la funció «%s» definida prèviament" + +#: awkgram.y:2945 awkgram.y:2951 +#, c-format +msgid "function `%s' called but never defined" +msgstr "es crida a la funció «%s» però no s'ha definit" + +#: awkgram.y:2954 +#, c-format +msgid "function `%s' defined but never called" +msgstr "es defineix la funció «%s» però no s'ha cridat mai" + +#: awkgram.y:2981 +#, c-format +msgid "regexp constant for parameter #%d yields boolean value" +msgstr "" +"l'expressió regular constant per al paràmetre #%d condueix a un valor booleà" + +#: awkgram.y:2994 +#, c-format +msgid "" +"function `%s' called with space between name and `(',\n" +"%s" +msgstr "" +"s'ha cridat a la funció «%s» amb espai entre el nom i el «(»,\n" +"%s" + +#: awkgram.y:2996 +#, fuzzy +msgid "or used as a variable or an array" +msgstr "no es pot usar el nom de la funció «%s» com a variable o matriu" + +#: builtin.c:137 +#, c-format +msgid "%s to \"%s\" failed (%s)" +msgstr "%s a \"%s\" ha fallat (%s)" + +#: builtin.c:138 +msgid "standard output" +msgstr "eixida estàndard" + +#: builtin.c:139 +msgid "reason unknown" +msgstr "motiu desconegut" + +#: builtin.c:152 +msgid "exp: received non-numeric argument" +msgstr "exp: s'ha rebut un argument que no és un número" + +#: builtin.c:158 +#, c-format +msgid "exp: argument %g is out of range" +msgstr "exp: l'argument %g està fora de rang" + +#: builtin.c:216 +#, c-format +msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing" +msgstr "" +"fflush: no es pot netejar: la canonada «%s» s'ha obert per a lectura, no per " +"a escriptura" + +#: builtin.c:219 +#, c-format +msgid "fflush: cannot flush: file `%s' opened for reading, not writing" +msgstr "" +"fflush: no es pot netejar: el fitxer «%s» s'ha obert per a lectura, no per a " +"escriptura" + +#: builtin.c:231 +#, c-format +msgid "fflush: `%s' is not an open file, pipe or co-process" +msgstr "fflush: «%s» no és un fitxer obert, canonada o co-procés" + +#: builtin.c:325 +msgid "index: received non-string first argument" +msgstr "índex: el primer argument rebut no és una cadena" + +#: builtin.c:327 +msgid "index: received non-string second argument" +msgstr "índex: el segon argument rebut no és una cadena" + +#: builtin.c:437 +msgid "int: received non-numeric argument" +msgstr "int: s'ha rebut un argument no numèric" + +#: builtin.c:454 +msgid "length: received non-string argument" +msgstr "length: s'ha rebut un argument que no és una cadena" + +#: builtin.c:470 +msgid "log: received non-numeric argument" +msgstr "log: s'ha rebut un argument no numèric" + +#: builtin.c:473 +#, c-format +msgid "log: received negative argument %g" +msgstr "log: s'ha rebut l'argument negatiu %g" + +#: builtin.c:635 builtin.c:638 +msgid "must use `count$' on all formats or none" +msgstr "" + +#: builtin.c:740 +msgid "`$' is not permitted in awk formats" +msgstr "no es permeten «$» en els formats awk" + +#: builtin.c:746 +msgid "arg count with `$' must be > 0" +msgstr "el compte d'arguments amb «$» ha de ser > 0" + +#: builtin.c:748 +#, fuzzy, c-format +msgid "arg count %ld greater than total number of supplied arguments" +msgstr "" +"el comte d'arguments %d és major que el nombre total d'arguments " +"proporcionats" + +#: builtin.c:750 +msgid "`$' not permitted after period in format" +msgstr "no es permet «$» després d'un punt en el format" + +#: builtin.c:763 +msgid "no `$' supplied for positional field width or precision" +msgstr "no es proporciona «$» per a l'ample o precisió del camp de posició" + +#: builtin.c:821 +msgid "`l' is meaningless in awk formats; ignored" +msgstr "«l» manca de significat en els formats awk; serà ignorat" + +#: builtin.c:825 +msgid "`l' is not permitted in POSIX awk formats" +msgstr "«l» no està permés en els formats POSIX de awk" + +#: builtin.c:836 +msgid "`L' is meaningless in awk formats; ignored" +msgstr "«L» manca de significat en els formats awk; serà ignorat" + +#: builtin.c:840 +msgid "`L' is not permitted in POSIX awk formats" +msgstr "«L» no està permés en els formats POSIX de awk" + +#: builtin.c:851 +msgid "`h' is meaningless in awk formats; ignored" +msgstr "«h» manca de significat en els formats awk; serà ignorat" + +#: builtin.c:855 +msgid "`h' is not permitted in POSIX awk formats" +msgstr "«h» no està permés en els formats POSIX de awk" + +#: builtin.c:1055 +#, c-format +msgid "[s]printf: value %g is out of range for `%%%c' format" +msgstr "" + +#: builtin.c:1108 +msgid "not enough arguments to satisfy format string" +msgstr "no hi ha prou arguments per a satisfer el format d'una cadena" + +#: builtin.c:1110 +msgid "^ ran out for this one" +msgstr "^ desbordament per a aquest" + +#: builtin.c:1115 +msgid "[s]printf: format specifier does not have control letter" +msgstr "[s]printf: l'especificador de format no conté lletra de control" + +#: builtin.c:1118 +msgid "too many arguments supplied for format string" +msgstr "s'han proporcionat masses arguments per a la cadena de format" + +#: builtin.c:1184 builtin.c:1187 +msgid "printf: no arguments" +msgstr "printf: sense arguments" + +#: builtin.c:1211 +msgid "sqrt: received non-numeric argument" +msgstr "sqrt: s'ha rebut un argument no numèric" + +#: builtin.c:1215 +#, c-format +msgid "sqrt: called with negative argument %g" +msgstr "sqrt: cridat amb l'argument negatiu %g" + +#: builtin.c:1238 +#, c-format +msgid "substr: start index %g is invalid, using 1" +msgstr "substr: l'índex d'inici %g no és vàlid, usant 1" + +#: builtin.c:1243 +#, c-format +msgid "substr: non-integer start index %g will be truncated" +msgstr "substr: l'índex d'inici no enter %g serà truncat" + +#: builtin.c:1262 +#, fuzzy, c-format +msgid "substr: length %g is not >= 1" +msgstr "substr: la longitud %g és <= 0" + +#: builtin.c:1264 +#, fuzzy, c-format +msgid "substr: length %g is not >= 0" +msgstr "substr: la longitud %g és <= 0" + +#: builtin.c:1271 +#, c-format +msgid "substr: non-integer length %g will be truncated" +msgstr "substr: la longitud sobre un nombre no enter %g serà truncada" + +#: builtin.c:1276 +#, c-format +msgid "substr: length %g too big for string indexing, truncating to %g" +msgstr "" + +#: builtin.c:1288 +msgid "substr: source string is zero length" +msgstr "substr: la cadena font és de longitud zero" + +#: builtin.c:1294 +#, fuzzy, c-format +msgid "substr: start index %g is past end of string" +msgstr "substr: l'índex d'inici %d sobrepassa l'acabament de la cadena" + +#: builtin.c:1302 +#, fuzzy, c-format +msgid "" +"substr: length %g at start index %g exceeds length of first argument (%lu)" +msgstr "" +"substr: la longitud %d a l'índex d'inici %d excedeix la longitud del 1er " +"argument (%d)" + +#: builtin.c:1337 +#, fuzzy +msgid "strftime: received non-string first argument" +msgstr "strftime: el primer argument rebut no és una cadena" + +#: builtin.c:1343 +msgid "strftime: received empty format string" +msgstr "strftime: s'ha rebut una cadena de format buida" + +#: builtin.c:1352 +#, fuzzy +msgid "strftime: received non-numeric second argument" +msgstr "strftime: el segon argument rebut no és numèric" + +#: builtin.c:1415 +msgid "mktime: received non-string argument" +msgstr "mktime: s'ha rebut un argument que no és una cadena" + +#: builtin.c:1460 +#, fuzzy +msgid "system: received non-string argument" +msgstr "system: s'ha rebut un argument que no és una cadena" + +#: builtin.c:1581 eval.c:1883 +#, fuzzy, c-format +msgid "reference to uninitialized field `$%d'" +msgstr "referència a una variable sense inicialitzar «%s»" + +#: builtin.c:1608 +#, fuzzy +msgid "tolower: received non-string argument" +msgstr "tolower: s'ha rebut un argument que no és una cadena" + +#: builtin.c:1657 +#, fuzzy +msgid "toupper: received non-string argument" +msgstr "toupper: s'ha rebut un argument que no és una cadena" + +#: builtin.c:1702 +msgid "atan2: received non-numeric first argument" +msgstr "atan2: el primer argument rebut no és numèric" + +#: builtin.c:1704 +msgid "atan2: received non-numeric second argument" +msgstr "atan2: el segon argument rebut no és numèric" + +#: builtin.c:1723 +msgid "sin: received non-numeric argument" +msgstr "sin: s'ha rebut un argument que no és numèric" + +#: builtin.c:1739 +msgid "cos: received non-numeric argument" +msgstr "cos: s'ha rebut un argument que no és numèric" + +#: builtin.c:1788 +msgid "srand: received non-numeric argument" +msgstr "srand: s'ha rebut un argument que no és numèric" + +#: builtin.c:1823 +msgid "match: third argument is not an array" +msgstr "match: el tercer argument no és una matriu" + +#: builtin.c:2307 +msgid "gensub: third argument of 0 treated as 1" +msgstr "gensub: el tercer argument de 0 és tractat com a 1" + +#: builtin.c:2416 builtin.c:2418 +msgid "lshift: received non-numeric first argument" +msgstr "lshift: el primer argument rebut no és numèric" + +#: builtin.c:2420 +#, c-format +msgid "lshift(%lf, %lf): negative values will give strange results" +msgstr "lshift(%lf, %lf): els valors negatius donaran resultats estranys" + +#: builtin.c:2422 +#, c-format +msgid "lshift(%lf, %lf): fractional values will be truncated" +msgstr "lshift(%lf, %lf): els valors fraccionaris sernn truncats" + +#: builtin.c:2424 +#, c-format +msgid "lshift(%lf, %lf): too large shift value will give strange results" +msgstr "" +"lshift(%lf, %lf): un valor de desplaçament massa gran donarà resultats " +"estranys" + +#: builtin.c:2453 builtin.c:2455 +msgid "rshift: received non-numeric first argument" +msgstr "rshift: el primer argument rebut no és numèric" + +#: builtin.c:2457 +#, c-format +msgid "rshift(%lf, %lf): negative values will give strange results" +msgstr "rshift(%lf, %lf): els valors negatius donaran resultats estranys" + +#: builtin.c:2459 +#, c-format +msgid "rshift(%lf, %lf): fractional values will be truncated" +msgstr "rshift(%lf, %lf): els valors fraccionaris seran truncats" + +#: builtin.c:2461 +#, c-format +msgid "rshift(%lf, %lf): too large shift value will give strange results" +msgstr "" +"rshift(%lf, %lf): un valor de desplaçament massa gran donarà resultats " +"estranys" + +#: builtin.c:2490 builtin.c:2492 +msgid "and: received non-numeric first argument" +msgstr "and: el primer argument rebut no és numèric" + +#: builtin.c:2494 +#, c-format +msgid "and(%lf, %lf): negative values will give strange results" +msgstr "and(%lf, %lf): els valors negatius donaran resultats estranys" + +#: builtin.c:2496 +#, c-format +msgid "and(%lf, %lf): fractional values will be truncated" +msgstr "and(%lf, %lf): els valors fraccionaris seran truncats" + +#: builtin.c:2525 builtin.c:2527 +msgid "or: received non-numeric first argument" +msgstr "or: el primer argument rebut no és numèric" + +#: builtin.c:2529 +#, c-format +msgid "or(%lf, %lf): negative values will give strange results" +msgstr "or(%lf, %lf): els valors negatius donaran resultats estranys" + +#: builtin.c:2531 +#, c-format +msgid "or(%lf, %lf): fractional values will be truncated" +msgstr "or(%lf, %lf): els valors fraccionaris seran truncats" + +#: builtin.c:2560 builtin.c:2562 +msgid "xor: received non-numeric first argument" +msgstr "xor: el primer argument rebut no és numèric" + +#: builtin.c:2564 +#, c-format +msgid "xor(%lf, %lf): negative values will give strange results" +msgstr "xor(%lf, %lf): els valors negatius donaran resultats estranys" + +#: builtin.c:2566 +#, c-format +msgid "xor(%lf, %lf): fractional values will be truncated" +msgstr "xor(%lf, %lf): els valors fraccionaris seran truncats" + +#: builtin.c:2594 +msgid "compl: received non-numeric argument" +msgstr "compl: s'ha rebut un argument que no és numèric" + +#: builtin.c:2596 +#, c-format +msgid "compl(%lf): negative value will give strange results" +msgstr "compl(%lf): el valor negatiu donarà resultats estranys" + +#: builtin.c:2598 +#, c-format +msgid "compl(%lf): fractional value will be truncated" +msgstr "compl(%lf): el valor fraccionari serà truncat" + +#: builtin.c:2771 +#, c-format +msgid "dcgettext: `%s' is not a valid locale category" +msgstr "dcgettext: «%s» no és una categoria local vàlida" + +#: eval.c:266 +#, c-format +msgid "unknown nodetype %d" +msgstr "tipo de node %d desconegut" + +#: eval.c:312 +msgid "buffer overflow in genflags2str" +msgstr "desbordament del cau temporal en genflags2str" + +#: eval.c:647 +#, fuzzy, c-format +msgid "for loop: array `%s' changed size from %ld to %ld during loop execution" +msgstr "" +"bucle for: la matriu «%s» ha canviat de mida de %d a %d durant l'execució " +"del bucle" + +#: eval.c:668 +msgid "`break' outside a loop is not portable" +msgstr "«break» a fora d'un bucle no és portable" + +#: eval.c:672 +msgid "`break' outside a loop is not allowed" +msgstr "no es permet «break» a fora d'un bucle" + +#: eval.c:689 +msgid "`continue' outside a loop is not portable" +msgstr "«continue» fora d'un bucle no és portable" + +#: eval.c:693 +msgid "`continue' outside a loop is not allowed" +msgstr "no es permet «continue» a fora d'un bucle" + +#: eval.c:727 +msgid "`next' cannot be called from a BEGIN rule" +msgstr "«next» no es pot cridar des d'una regla BEGIN" + +#: eval.c:729 +msgid "`next' cannot be called from an END rule" +msgstr "«next» no es pot cridar des d'una regla FINAL" + +#: eval.c:738 +msgid "`nextfile' cannot be called from a BEGIN rule" +msgstr "«nextfile» no es pot cridar des d'una regla BEGIN" + +#: eval.c:740 +msgid "`nextfile' cannot be called from an END rule" +msgstr "«nextfile» no es pot cridar des d'una regla FINAL" + +#: eval.c:785 +msgid "statement has no effect" +msgstr "la sentència no té efecte" + +#: eval.c:828 eval.c:1726 +#, c-format +msgid "can't use function name `%s' as variable or array" +msgstr "no es pot usar el nom de la funció «%s» com a variable o matriu" + +#: eval.c:835 eval.c:841 +#, c-format +msgid "reference to uninitialized argument `%s'" +msgstr "referència a un argument sense inicialitzar «%s»" + +#: eval.c:848 eval.c:907 eval.c:1732 eval.c:1742 profile.c:807 +#, c-format +msgid "attempt to use array `%s' in a scalar context" +msgstr "s'ha intentat usar la matriu «%s» en un context escalar" + +#: eval.c:858 eval.c:1752 +#, c-format +msgid "reference to uninitialized variable `%s'" +msgstr "referència a una variable sense inicialitzar «%s»" + +#: eval.c:1007 +msgid "" +"concatenation: side effects in one expression have changed the length of " +"another!" +msgstr "" +"concatenació: els efectes colaterals en una expressió han canviat la " +"longitud d'una altra!" + +#: eval.c:1032 +msgid "assignment used in conditional context" +msgstr "assignació usada en un context condicional" + +#: eval.c:1122 +msgid "division by zero attempted" +msgstr "s'ha intentat una divisió per zero" + +#: eval.c:1137 +#, c-format +msgid "division by zero attempted in `%%'" +msgstr "s'ha intentat una divisió per zero en «%%»" + +#: eval.c:1152 profile.c:683 +#, c-format +msgid "illegal type (%s) in tree_eval" +msgstr "tipus il·legal (%s) en tree_eval" + +#: eval.c:1328 +msgid "division by zero attempted in `/='" +msgstr "s'ha intentat una divisió per zero en «/=»" + +#: eval.c:1346 +#, c-format +msgid "division by zero attempted in `%%='" +msgstr "s'ha intentat una divisió per zero en «%%=»" + +#: eval.c:1586 +#, c-format +msgid "function `%s' called with more arguments than declared" +msgstr "s'ha cridat a la funció «%s» amb més arguments dels declarats" + +#: eval.c:1633 +#, c-format +msgid "function `%s' not defined" +msgstr "la funció «%s» no està definida" + +#: eval.c:1639 +#, c-format +msgid "function %s called\n" +msgstr "s'ha cridat a la funció %s\n" + +#: eval.c:1698 +msgid "" +"\n" +"\t# Function Call Stack:\n" +"\n" +msgstr "" +"\n" +"\t# Pila de Crides a les Funcions:\n" +"\n" + +#: eval.c:1701 +msgid "\t# -- main --\n" +msgstr "\t# -- principal --\n" + +#: eval.c:1867 +msgid "attempt to field reference from non-numeric value" +msgstr "s'ha intentat una referència de camp a partir d'un valor no numèric" + +#: eval.c:1869 +msgid "attempt to reference from null string" +msgstr "s'ha intentat una referència a partir d'una cadena nul·la" + +#: eval.c:1875 +#, c-format +msgid "attempt to access field %d" +msgstr "s'ha intentat accedir al camp %d" + +#: eval.c:1896 eval.c:1903 profile.c:900 +msgid "assignment is not allowed to result of builtin function" +msgstr "" +"no es permet l'assignació per a obtindre un resultat d'una funció interna" + +#: eval.c:1951 +msgid "`IGNORECASE' is a gawk extension" +msgstr "«IGNORECASE» és una extensió de gawk" + +#: eval.c:1980 +msgid "`BINMODE' is a gawk extension" +msgstr "«BINMODE» és una extensió de gawk" + +#: eval.c:2092 +#, c-format +msgid "bad `%sFMT' specification `%s'" +msgstr "«%sFMT» especificació errònia «%s»" + +#: eval.c:2170 +msgid "turning off `--lint' due to assignment to `LINT'" +msgstr "desactivant «--lint» degut a una assignació a «LINT»" + +#: ext.c:60 ext.c:64 +msgid "`extension' is a gawk extension" +msgstr "«extension» és una extensió gawk" + +#: ext.c:74 +#, c-format +msgid "extension: cannot open `%s' (%s)\n" +msgstr "extension: no es pot obrir «%s» (%s)\n" + +#: ext.c:82 +#, c-format +msgid "extension: library `%s': cannot call function `%s' (%s)\n" +msgstr "extension: biblioteca «%s»: no es pot cridar a la funció «%s» (%s)\n" + +#: ext.c:183 +msgid "Operation Not Supported" +msgstr "Operació No Suportada" + +#: field.c:315 +msgid "NF set to negative value" +msgstr "NF s'inicialitza sobre un valor negatiu" + +#: field.c:808 +msgid "split: second argument is not an array" +msgstr "split: el segon argument no és una matriu" + +#: field.c:842 +msgid "split: null string for third arg is a gawk extension" +msgstr "split: la cadena nul·la per al tercer argument és una extensió de gawk" + +#: field.c:894 +msgid "`FIELDWIDTHS' is a gawk extension" +msgstr "«FIELDWIDTHS» és una extensió de gawk" + +#: field.c:921 +#, c-format +msgid "field %d in FIELDWIDTHS, must be > 0" +msgstr "el camp %d en FIELDWIDTHS, hauria de ser > 0" + +#: field.c:994 +msgid "null string for `FS' is a gawk extension" +msgstr "la cadena nul·la per a «FS» és una extensió de gawk" + +#: getopt.c:692 getopt.c:704 +#, c-format +msgid "%s: option `%s' is ambiguous\n" +msgstr "%s: l'opció «%s» és ambigua\n" + +#: getopt.c:737 getopt.c:741 +#, c-format +msgid "%s: option `--%s' doesn't allow an argument\n" +msgstr "%s: l'opció «--%s» no admet cap argument\n" + +#: getopt.c:750 getopt.c:755 +#, c-format +msgid "%s: option `%c%s' doesn't allow an argument\n" +msgstr "%s: l'opció «%c%s» no admet cap argument\n" + +#: getopt.c:791 getopt.c:804 getopt.c:1093 getopt.c:1106 +#, c-format +msgid "%s: option `%s' requires an argument\n" +msgstr "%s: l'opció «%s» requereix un argument\n" + +#: getopt.c:842 getopt.c:845 +#, c-format +msgid "%s: unrecognized option `--%s'\n" +msgstr "%s: no es reconeix l'opció «--%s»\n" + +#: getopt.c:853 getopt.c:856 +#, c-format +msgid "%s: unrecognized option `%c%s'\n" +msgstr "%s: no es reconeix l'opció «%c%s»\n" + +#: getopt.c:903 getopt.c:906 +#, c-format +msgid "%s: illegal option -- %c\n" +msgstr "%s: opció il·legal -- %c\n" + +#: getopt.c:912 getopt.c:915 +#, c-format +msgid "%s: invalid option -- %c\n" +msgstr "%s: opció no vàlida -- %c\n" + +#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:434 +#, c-format +msgid "%s: option requires an argument -- %c\n" +msgstr "%s: l'opció requereix un argument -- %c\n" + +#: getopt.c:1025 getopt.c:1036 +#, c-format +msgid "%s: option `-W %s' is ambiguous\n" +msgstr "%s: l'opció «-W %s» és ambigua\n" + +#: getopt.c:1060 getopt.c:1072 +#, c-format +msgid "%s: option `-W %s' doesn't allow an argument\n" +msgstr "%s: l'opció «-W %s» no admet cap argument\n" + +#: io.c:305 +#, c-format +msgid "cannot open file `%s' for reading (%s)" +msgstr "no es pot obrir el fitxer «%s» per a lectura (%s)" + +#: io.c:392 +#, c-format +msgid "close of fd %d (`%s') failed (%s)" +msgstr "la finalització del descriptor fd %d («%s») ha fallat (%s)" + +#: io.c:530 +#, c-format +msgid "invalid tree type %s in redirect()" +msgstr "tipus d'arbre %s no vàlid dintre de redirect()" + +#: io.c:536 +#, c-format +msgid "expression in `%s' redirection only has numeric value" +msgstr "l'expressió en la redirecció «%s» solt té un valor numèric" + +#: io.c:542 +#, c-format +msgid "expression for `%s' redirection has null string value" +msgstr "l'expressió per a la redirecció «%s» té un valor de cadena nul·la" + +#: io.c:547 +#, c-format +msgid "filename `%s' for `%s' redirection may be result of logical expression" +msgstr "" +"el fitxer «%s» per a la redirecció «%s» pot ser resultat d'una expressió " +"lògica" + +#: io.c:569 +#, c-format +msgid "unnecessary mixing of `>' and `>>' for file `%.*s'" +msgstr "mescla innecessària de «>» i «>>» per al fitxer «%.*s»" + +#: io.c:621 +#, c-format +msgid "can't open pipe `%s' for output (%s)" +msgstr "no es pot obrir la canonada «%s» per a l'eixida (%s)" + +#: io.c:630 +#, c-format +msgid "can't open pipe `%s' for input (%s)" +msgstr "no es pot obrir la canonada «%s» per a l'entrada (%s)" + +#: io.c:643 +#, c-format +msgid "can't open two way socket `%s' for input/output (%s)" +msgstr "" +"no es pot obrir un socket bidireccional «%s» per a les entrades/eixides (%s)" + +#: io.c:647 +#, c-format +msgid "can't open two way pipe `%s' for input/output (%s)" +msgstr "" +"no es pot obrir una canonada bidireccional «%s» per a les entrades/eixides (%" +"s)" + +#: io.c:723 +#, c-format +msgid "can't redirect from `%s' (%s)" +msgstr "no es pot redirigir des de «%s» (%s)" + +#: io.c:726 +#, c-format +msgid "can't redirect to `%s' (%s)" +msgstr "no es pot redirigir cap a «%s» (%s)" + +#: io.c:765 +msgid "" +"reached system limit for open files: starting to multiplex file descriptors" +msgstr "" +"s'ha arribat al límit del sistema per a fitxers oberts: es començarà a " +"multiplexar els descriptors de fitxer" + +#: io.c:777 +#, c-format +msgid "close of `%s' failed (%s)." +msgstr "la finalització de «%s» ha fallat (%s)" + +#: io.c:784 +msgid "too many pipes or input files open" +msgstr "masses canonades o fitxers d'entrada oberts" + +#: io.c:807 +msgid "close: second argument must be `to' or `from'" +msgstr "close: el segon argument hauria de ser «to» o «from»" + +#: io.c:821 +#, c-format +msgid "close: `%.*s' is not an open file, pipe or co-process" +msgstr "close: «%.*s» no és un fitxer obert, canonada o co-procés" + +#: io.c:825 +msgid "close of redirection that was never opened" +msgstr "finalització d'una redirecció que no s'ha obert" + +#: io.c:862 +#, c-format +msgid "close: redirection `%s' not opened with `|&', second argument ignored" +msgstr "" +"close: la redirecció «%s» no s'obre amb «|&», s'ignora el segon argument" + +#: io.c:924 +#, c-format +msgid "failure status (%d) on pipe close of `%s' (%s)" +msgstr "estaus de falla (%d) en la finalització de la canonada «%s» (%s)" + +#: io.c:927 +#, c-format +msgid "failure status (%d) on file close of `%s' (%s)" +msgstr "estatus de falla (%d) en la finalització del fitxer «%s» (%s)" + +#: io.c:946 +#, c-format +msgid "no explicit close of socket `%s' provided" +msgstr "no s'aporta la finalització explícita del socket «%s»" + +#: io.c:949 +#, c-format +msgid "no explicit close of co-process `%s' provided" +msgstr "no s'aporta la finalització explícita del co-procés «%s»" + +#: io.c:952 +#, c-format +msgid "no explicit close of pipe `%s' provided" +msgstr "no s'aporta la finalització explícita de la canonada «%s»" + +#: io.c:955 +#, c-format +msgid "no explicit close of file `%s' provided" +msgstr "no s'aporta la finalització explícita del fitxer «%s»" + +#: io.c:984 io.c:1038 +#, c-format +msgid "error writing standard output (%s)" +msgstr "error a l'escriure en l'eixida estàndard (%s)" + +#: io.c:988 io.c:1042 +#, c-format +msgid "error writing standard error (%s)" +msgstr "error a l'escriure en l'eixida d'error estàndard (%s)" + +#: io.c:996 +#, c-format +msgid "pipe flush of `%s' failed (%s)." +msgstr "la neteja de la canonada de «%sx» ha fallat (%s)." + +#: io.c:999 +#, c-format +msgid "co-process flush of pipe to `%s' failed (%s)." +msgstr "la neteja de la canonada per al co-procés de «%sx» ha fallat (%s)." + +#: io.c:1002 +#, c-format +msgid "file flush of `%s' failed (%s)." +msgstr "la neteja del fitxer «%sx» ha fallat (%s)." + +#: io.c:1161 +msgid "/inet/raw client not ready yet, sorry" +msgstr "el client /inet/raw encara no està a punt, ho sento" + +#: io.c:1163 io.c:1200 +msgid "only root may use `/inet/raw'." +msgstr "sols el root pot usar «/inet/raw»." + +#: io.c:1198 +msgid "/inet/raw server not ready yet, sorry" +msgstr "el servidor /inet/raw encara no està a punt, ho sento" + +#: io.c:1288 +#, c-format +msgid "no (known) protocol supplied in special filename `%s'" +msgstr "no s'aporta cap protocol (conegut) en el nom del fitxer especial «%s»" + +#: io.c:1306 +#, c-format +msgid "special file name `%s' is incomplete" +msgstr "el nom del fitxer especial «%s» està incomplet" + +#: io.c:1318 +#, c-format +msgid "local port invalid in `%s'" +msgstr "port local no vàlid en «%s»" + +#: io.c:1330 +msgid "must supply a remote hostname to `/inet'" +msgstr "s'ha de subministrar un nom de sistema remot a «/inet»" + +#: io.c:1345 +msgid "must supply a remote port to `/inet'" +msgstr "s'ha de subministrar un port remot a «/inet»" + +#: io.c:1351 +#, c-format +msgid "remote port invalid in `%s'" +msgstr "port remot no vàlid en «%s»" + +#: io.c:1361 +msgid "TCP/IP communications are not supported" +msgstr "les comunicacions TCP/IP no estan suportades" + +#: io.c:1370 io.c:1551 +#, c-format +msgid "file `%s' is a directory" +msgstr "el fitxer «%s» és un directori" + +#: io.c:1440 +#, c-format +msgid "use `PROCINFO[\"%s\"]' instead of `%s'" +msgstr "useu «PROCINFO[\"%s\"]» en comptes de «%s»" + +#: io.c:1472 +msgid "use `PROCINFO[...]' instead of `/dev/user'" +msgstr "useu «PROCINFO[...]» en comptes de «/dev/user»" + +#: io.c:1537 io.c:1711 +#, c-format +msgid "could not open `%s', mode `%s'" +msgstr "no es pot obrir «%s», mode «%s»" + +#: io.c:1762 +#, fuzzy, c-format +msgid "close of master pty failed (%s)" +msgstr "ha fallat la finalització de la canonada (%s)" + +#: io.c:1764 io.c:1916 io.c:2068 +#, c-format +msgid "close of stdout in child failed (%s)" +msgstr "" +"ha fallat la finalització de l'eixida estàndard en els processos fills (%s)" + +#: io.c:1767 +#, fuzzy, c-format +msgid "moving slave pty to stdout in child failed (dup: %s)" +msgstr "" +"ha fallat la redirecció cap a l'eixida estàndard dels processos fills (dup: %" +"s)" + +#: io.c:1769 io.c:1921 +#, c-format +msgid "close of stdin in child failed (%s)" +msgstr "" +"ha fallat la finalització de l'entrada estàndard en els processos fills (%s)" + +#: io.c:1772 +#, fuzzy, c-format +msgid "moving slave pty to stdin in child failed (dup: %s)" +msgstr "" +"ha fallat la redirecció cap a l'entrada estàndard dels processos fills (dup: " +"%s)" + +#: io.c:1774 io.c:1793 +#, fuzzy, c-format +msgid "close of slave pty failed (%s)" +msgstr "ha fallat la finalització de la canonada (%s)" + +#: io.c:1867 io.c:1919 io.c:2049 io.c:2071 +#, c-format +msgid "moving pipe to stdout in child failed (dup: %s)" +msgstr "" +"ha fallat la redirecció cap a l'eixida estàndard dels processos fills (dup: %" +"s)" + +#: io.c:1871 io.c:1924 +#, c-format +msgid "moving pipe to stdin in child failed (dup: %s)" +msgstr "" +"ha fallat la redirecció cap a l'entrada estàndard dels processos fills (dup: " +"%s)" + +#: io.c:1888 io.c:2062 +msgid "restoring stdout in parent process failed\n" +msgstr "ha fallat la restauració de l'eixida estàndard en el procés pare\n" + +#: io.c:1893 +msgid "restoring stdin in parent process failed\n" +msgstr "ha fallat la restauració de l'entrada estàndard en el procés pare\n" + +#: io.c:1927 io.c:2073 io.c:2084 +#, c-format +msgid "close of pipe failed (%s)" +msgstr "ha fallat la finalització de la canonada (%s)" + +#: io.c:1972 +msgid "`|&' not supported" +msgstr "«|&» no està suportat" + +#: io.c:2039 +#, c-format +msgid "cannot open pipe `%s' (%s)" +msgstr "no es pot obrir la canonada «%s» (%s)" + +#: io.c:2080 +#, c-format +msgid "cannot create child process for `%s' (fork: %s)" +msgstr "no es pot crear el procés fill per a «%s» (fork: %s)" + +#: io.c:2423 +#, c-format +msgid "data file `%s' is empty" +msgstr "el fitxer de dades «%s» està buit" + +#: io.c:2466 io.c:2474 +msgid "could not allocate more input memory" +msgstr "" + +#: io.c:2832 io.c:2895 +#, c-format +msgid "error reading input file `%s': %s" +msgstr "error en llegir el fitxer d'entrada «%s»: %s" + +#: io.c:3020 +msgid "multicharacter value of `RS' is a gawk extension" +msgstr "el valor multicaràcter de «RS» és una extensió de gawk" + +#: main.c:324 +msgid "`-m[fr]' option irrelevant in gawk" +msgstr "l'opción «-m[fr]» és irrellevant en gawk" + +#: main.c:326 +msgid "-m option usage: `-m[fr] nnn'" +msgstr "ús de l'opció -m: «-m[fr] nnn»" + +#: main.c:343 +#, c-format +msgid "%s: option `-W %s' unrecognized, ignored\n" +msgstr "%s: no es reconeix l'opció «-W %s», serà ignorada\n" + +#: main.c:380 +msgid "empty argument to `--source' ignored" +msgstr "s'igonarà l'argument buit per a l'opció «--source»" + +#: main.c:451 +msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'" +msgstr "" +"la variable d'entorn «POSIXLY_CORRECT» està establerta: usant «--posix»" + +#: main.c:456 +msgid "`--posix' overrides `--traditional'" +msgstr "«--posix» solapa a «--traditional»" + +#: main.c:467 +msgid "`--posix'/`--traditional' overrides `--non-decimal-data'" +msgstr "«--posix» i «--traditional» solapen a «--non-decimal-data»" + +#: main.c:471 +#, fuzzy, c-format +msgid "running %s setuid root may be a security problem" +msgstr "executar %s com a setuid root pot ser un problema de seguretat" + +#: main.c:512 +#, fuzzy, c-format +msgid "can't set binary mode on stdin (%s)" +msgstr "no es pot establir el mode en l'entrada estàndard (%s)" + +#: main.c:515 +#, fuzzy, c-format +msgid "can't set binary mode on stdout (%s)" +msgstr "no es pot establir el mode en l'eixida estàndard (%s)" + +#: main.c:517 +#, fuzzy, c-format +msgid "can't set binary mode on stderr (%s)" +msgstr "no es pot establir el mode en l'eixida d'error estàndard (%s)" + +#: main.c:547 +msgid "no program text at all!" +msgstr "no hi ha cap text per al programa!" + +#: main.c:620 +#, c-format +msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n" +msgstr "Ús: %s [opcions d'estil POSIX o GNU] -f fitx_prog [--] fitxer ...\n" + +#: main.c:622 +#, c-format +msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n" +msgstr "Ús: %s [opcions d'estil POSIX o GNU] [--] %cprograma%c fitxer ...\n" + +#: main.c:627 +msgid "POSIX options:\t\tGNU long options:\n" +msgstr "Opcions POSIX:\t\tOpcions llargues GNU:\n" + +#: main.c:628 +msgid "\t-f progfile\t\t--file=progfile\n" +msgstr "\t-f fitx_prog\t\t--file=fitx_prog\n" + +#: main.c:629 +msgid "\t-F fs\t\t\t--field-separator=fs\n" +msgstr "\t-F fs\t\t\t--field-separator=fs (fs=sep_camp)\n" + +#: main.c:630 +msgid "\t-v var=val\t\t--assign=var=val\n" +msgstr "\t-v var=valor\t\t--assign=var=valor\n" + +#: main.c:631 +msgid "\t-m[fr] val\n" +msgstr "\t-m[fr] valor\n" + +#: main.c:632 +msgid "\t-W compat\t\t--compat\n" +msgstr "\t-W compat\t\t--compat\n" + +#: main.c:633 +msgid "\t-W copyleft\t\t--copyleft\n" +msgstr "\t-W copyleft\t\t--copyleft\n" + +#: main.c:634 +msgid "\t-W copyright\t\t--copyright\n" +msgstr "\t-W copyright\t\t--copyright\n" + +#: main.c:635 +msgid "\t-W dump-variables[=file]\t--dump-variables[=file]\n" +msgstr "\t-W dump-variables[=fitxer] --dump-variables[=fitxer]\n" + +#: main.c:636 +msgid "\t-W gen-po\t\t--gen-po\n" +msgstr "\t-W gen-po\t\t--gen-po\n" + +#: main.c:637 +msgid "\t-W help\t\t\t--help\n" +msgstr "\t-W help\t\t\t--help\n" + +#: main.c:638 +msgid "\t-W lint[=fatal]\t\t--lint[=fatal]\n" +msgstr "\t-W lint[=fatal]\t\t--lint[=fatal]\n" + +#: main.c:639 +msgid "\t-W lint-old\t\t--lint-old\n" +msgstr "\t-W lint-old\t\t--lint-old\n" + +#: main.c:640 +msgid "\t-W non-decimal-data\t--non-decimal-data\n" +msgstr "\t-W non-decimal-data\t--non-decimal-data\n" + +#: main.c:642 +msgid "\t-W nostalgia\t\t--nostalgia\n" +msgstr "\t-W nostalgia\t\t--nostalgia\n" + +#: main.c:645 +msgid "\t-W parsedebug\t\t--parsedebug\n" +msgstr "\t-W parsedebug\t\t--parsedebug\n" + +#: main.c:647 +msgid "\t-W profile[=file]\t--profile[=file]\n" +msgstr "\t-W profile[=fitxer]\t--profile[=fitxer]\n" + +#: main.c:648 +msgid "\t-W posix\t\t--posix\n" +msgstr "\t-W posix\t\t--posix\n" + +#: main.c:649 +msgid "\t-W re-interval\t\t--re-interval\n" +msgstr "\t-W re-interval\t\t--re-interval\n" + +#: main.c:650 +msgid "\t-W source=program-text\t--source=program-text\n" +msgstr "\t-W source=text_prog\t--source=text_prog\n" + +#: main.c:651 +msgid "\t-W traditional\t\t--traditional\n" +msgstr "\t-W traditional\t\t--traditional\n" + +#: main.c:652 +msgid "\t-W usage\t\t--usage\n" +msgstr "\t-W usage\t\t--usage\n" + +#: main.c:653 +msgid "\t-W version\t\t--version\n" +msgstr "\t-W version\t\t--version\n" + +#: main.c:657 +#, fuzzy +msgid "" +"\n" +"To report bugs, see node `Bugs' in `gawk.info', which is\n" +"section `Reporting Problems and Bugs' in the printed version.\n" +"\n" +msgstr "a la secció «Reporting Problems and Bugs» de la versió impresa.\n" + +#: main.c:661 +msgid "" +"gawk is a pattern scanning and processing language.\n" +"By default it reads standard input and writes standard output.\n" +"\n" +msgstr "" + +#: main.c:665 +msgid "" +"Examples:\n" +"\tgawk '{ sum += $1 }; END { print sum }' file\n" +"\tgawk -F: '{ print $1 }' /etc/passwd\n" +msgstr "" + +#: main.c:682 +#, c-format +msgid "" +"Copyright (C) 1989, 1991-%d Free Software Foundation.\n" +"\n" +"This program is free software; you can redistribute it and/or modify\n" +"it under the terms of the GNU General Public License as published by\n" +"the Free Software Foundation; either version 2 of the License, or\n" +"(at your option) any later version.\n" +"\n" +msgstr "" +"Copyright (C) 1989, 1991-%d Free Software Foundation.\n" +"\n" +"Aquest programa és programari lliure; pot redistribuir-se i/o modificar-se\n" +"sota els termes de la Llicència Pública General de GNU tal i como està\n" +"publicada per la Free Software Foundation; ja siga en la versió 2 de la\n" +"Llicència, o (a la vostra elecció) qualsevol versió posterior.\n" +"\n" + +#: main.c:690 +msgid "" +"This program is distributed in the hope that it will be useful,\n" +"but WITHOUT ANY WARRANTY; without even the implied warranty of\n" +"MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n" +"GNU General Public License for more details.\n" +"\n" +msgstr "" +"Aquest programa es distribueix amb l'esperança de que serà d'utilitat,\n" +"però SENSE CAP GARANTIA; fins i tot sense la garantia implícita de\n" +"COMERCIABILITAT o IDONEÏTAT PER A UN PROPÒSIT EN PARTICULAR.\n" +"Per a més detalls consulteu la Llicència Pública General de GNU.\n" +"\n" + +#: main.c:696 +msgid "" +"You should have received a copy of the GNU General Public License\n" +"along with this program; if not, write to the Free Software\n" +"Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n" +msgstr "" +"Junt amb aquest programa hauríeu d'haber rebut una còpia de la Llicència\n" +"Pública General de GNU; si no és així, escriviu a la Free Software\n" +"Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n" + +#: main.c:730 +msgid "-Ft does not set FS to tab in POSIX awk" +msgstr "-Ft no permet inicialitzar FS a un tabulador en la versió POSIX de awk" + +#: main.c:956 +#, c-format +msgid "" +"%s: `%s' argument to `-v' not in `var=value' form\n" +"\n" +msgstr "" + +#: main.c:976 +#, c-format +msgid "`%s' is not a legal variable name" +msgstr "" + +#: main.c:979 +#, c-format +msgid "`%s' is not a variable name, looking for file `%s=%s'" +msgstr "" + +#: main.c:1012 +msgid "floating point exception" +msgstr "excepció de coma flotant" + +#: main.c:1019 +msgid "fatal error: internal error" +msgstr "error fatal: error intern" + +#: main.c:1069 +#, c-format +msgid "no pre-opened fd %d" +msgstr "no s'ha pre-obert el descriptor fd per a %d" + +#: main.c:1074 +#, c-format +msgid "could not pre-open /dev/null for fd %d" +msgstr "no es pot pre-obrir /dev/null per al descriptor fd %d" + +#: main.c:1097 main.c:1106 +#, c-format +msgid "could not find groups: %s" +msgstr "no es poden trobar els grups: %s" + +#: msg.c:54 +msgid "cmd. line:" +msgstr "línia cmd.:" + +#: msg.c:120 +msgid "warning: " +msgstr "ADVERTIMENT: " + +#: msg.c:142 +msgid "error: " +msgstr "Error: " + +#: msg.c:178 +msgid "fatal: " +msgstr "Fatal: " + +#: node.c:58 node.c:65 node.c:74 node.c:88 node.c:115 +msgid "can't convert string to float" +msgstr "no es pot convertir la cadena a coma flotant" + +#: node.c:355 +msgid "backslash at end of string" +msgstr "barra invertida al final de la cadena" + +#: node.c:539 +msgid "POSIX does not allow `\\x' escapes" +msgstr "POSIX no permet seqüències d'escapada «\\x»" + +#: node.c:545 +msgid "no hex digits in `\\x' escape sequence" +msgstr "no hi ha dígits hexadecimals en la seqüència d'escapada «\\x»" + +#: node.c:579 +#, c-format +msgid "escape sequence `\\%c' treated as plain `%c'" +msgstr "la seqüència d'escapada «\\%c» és tractada com a una simple «%c»" + +#: posix/gawkmisc.c:172 +#, c-format +msgid "%s %s `%s': could not set close-on-exec: (fcntl: %s)" +msgstr "%s %s «%s»: no es pot inicialitzar close-on-exec: (fcntl: %s)" + +#: profile.c:91 +#, c-format +msgid "could not open `%s' for writing: %s" +msgstr "no es pot obrir «%s» per a escriptura: %s" + +#: profile.c:449 +#, fuzzy, c-format +msgid "internal error: %s with null vname" +msgstr "error intern: Node_var amb vname nul" + +#: profile.c:512 +msgid "# treated internally as `delete'" +msgstr "" + +#: profile.c:1162 +#, c-format +msgid "\t# gawk profile, created %s\n" +msgstr "\t# perfil gawk, creat %s\n" + +#: profile.c:1165 +msgid "" +"\t# BEGIN block(s)\n" +"\n" +msgstr "" +"\t# Bloc(s) INICI\n" +"\n" + +#: profile.c:1175 +msgid "" +"\t# Rule(s)\n" +"\n" +msgstr "" +"\t# Regla(es)\n" +"\n" + +#: profile.c:1181 +msgid "" +"\t# END block(s)\n" +"\n" +msgstr "" +"\t# Bloc(s) FINAL\n" +"\n" + +#: profile.c:1201 +msgid "" +"\n" +"\t# Functions, listed alphabetically\n" +msgstr "" +"\n" +"\t# Funcions, llistades alfabèticament\n" + +#: profile.c:1413 +#, c-format +msgid "unexpected type %s in prec_level" +msgstr "tipus %s inesperat en prec_level" + +#: re.c:193 +#, c-format +msgid "regex match failed, not enough memory to match string \"%.*s%s\"" +msgstr "" + +#: regcomp.c:136 +msgid "Success" +msgstr "Èxit" + +#: regcomp.c:139 +msgid "No match" +msgstr "No hi ha concordança" + +#: regcomp.c:142 +msgid "Invalid regular expression" +msgstr "Expressió regular no vàlida" + +#: regcomp.c:145 +msgid "Invalid collation character" +msgstr "Caràcter de comparació no vàlid" + +#: regcomp.c:148 +msgid "Invalid character class name" +msgstr "Nom de classe de caràcters no vàlid" + +#: regcomp.c:151 +msgid "Trailing backslash" +msgstr "Barra invertida extra al final" + +#: regcomp.c:154 +msgid "Invalid back reference" +msgstr "Referència cap enradera no vàlida" + +#: regcomp.c:157 +msgid "Unmatched [ or [^" +msgstr "[ o [^ desemparellats" + +#: regcomp.c:160 +msgid "Unmatched ( or \\(" +msgstr "( o \\( desemparellats" + +#: regcomp.c:163 +msgid "Unmatched \\{" +msgstr "\\{ desemparellat" + +#: regcomp.c:166 +msgid "Invalid content of \\{\\}" +msgstr "Contingut no vàlid de \\{\\}" + +#: regcomp.c:169 +msgid "Invalid range end" +msgstr "Final de rang no vàlid" + +#: regcomp.c:172 +msgid "Memory exhausted" +msgstr "Memòria exhaurida" + +#: regcomp.c:175 +msgid "Invalid preceding regular expression" +msgstr "Expressió regular precedent no vàlida" + +#: regcomp.c:178 +msgid "Premature end of regular expression" +msgstr "Fí prematura de l'expressió regular" + +#: regcomp.c:181 +msgid "Regular expression too big" +msgstr "L'expressió regular és massa gran" + +#: regcomp.c:184 +msgid "Unmatched ) or \\)" +msgstr ") o \\) desemparellats" + +#: regcomp.c:621 +msgid "No previous regular expression" +msgstr "No hi ha una expressió regular prèvia" + +#, fuzzy +#~ msgid "substr: length %g is < 0" +#~ msgstr "substr: la longitud %g és <= 0" + +#~ msgid "delete: illegal use of variable `%s' as array" +#~ msgstr "delete: ús il·legal de la variable «%s» com a una matriu" + +#, fuzzy +#~ msgid "%s: gvar_ref to %s\n" +#~ msgstr "%s: ref_matriu a %s\n" + +#~ msgid "asort: first argument is not an array" +#~ msgstr "asort: el primer argument no és una matriu" + +#~ msgid "asort: second argument is not an array" +#~ msgstr "asort: el segon argument no és una matriu" + +#, fuzzy +#~ msgid "" +#~ "attempt to use array parameter `%s' that was passed from global scalar `%" +#~ "s'" +#~ msgstr "s'ha intentat usar un paràmetre escalar «%s» com a una matriu" + +#~ msgid "internal error: Node_var_array with null vname" +#~ msgstr "error intern: Node_var_array amb vname nul" + +#~ msgid "" +#~ "\n" +#~ "To report bugs, see node `Bugs' in `gawk.info', which is\n" +#~ msgstr "" +#~ "\n" +#~ "Per a informar d'errors, consulteu el node «Bugs» en «gawk.info», que " +#~ "està\n" + +#~ msgid "invalid syntax in name `%s' for variable assignment" +#~ msgstr "sintaxi no vàlida en el nom «%s» per a l'asignació de la variable" + +#~ msgid "or used in other expression context" +#~ msgstr "o s'ha emprat en un altre context de l'expressió" + +#~ msgid "attempt to use function `%s' as array" +#~ msgstr "s'ha intentat usar la funció «%s» com a una matriu" + +#~ msgid "`%s' is a function, assignment is not allowed" +#~ msgstr "«%s» és una funció, l'assignació no és permesa" + +#~ msgid "BEGIN blocks must have an action part" +#~ msgstr "Els blocs INICI han de tindre una part d'acció" + +#~ msgid "`nextfile' used in BEGIN or END action" +#~ msgstr "«nextfile» és usat dintre de l'acció BEGIN o END" + +#~ msgid "non-redirected `getline' undefined inside BEGIN or END action" +#~ msgstr "«getline» no redirigit sense definir dintre de l'acció BEGIN o END" + +#~ msgid "fptr %x not in tokentab\n" +#~ msgstr "fptr %x no està en la taula de referència\n" + +#~ msgid "gsub third parameter is not a changeable object" +#~ msgstr "gsub: el tercer argument no és un objecte intercanviable" + +#~ msgid "Unfinished \\ escape" +#~ msgstr "seqüència d'escapada \\ sense finalitzar" + +#~ msgid "unfinished repeat count" +#~ msgstr "repetició del comptador sense finalitzar" + +#~ msgid "malformed repeat count" +#~ msgstr "repetició del comptador malformada" + +#~ msgid "Unbalanced [" +#~ msgstr "[ sense aparellar" + +#~ msgid "Unbalanced (" +#~ msgstr "( sense aparellar" + +#~ msgid "No regexp syntax bits specified" +#~ msgstr "No s'especifiquen els bits de sintaxi de l'expressió regular" + +#~ msgid "Unbalanced )" +#~ msgstr ") sense aparellar" + +#~ msgid "out of memory" +#~ msgstr "memòria esgotada" + +#~ msgid "internal error: file `%s', line %d\n" +#~ msgstr "error intern: fitxer «%s», línia %d\n" Binary files gawk-3.1.2/po/da.gmo and gawk-3.1.3/po/da.gmo differ diff -urN gawk-3.1.2/po/da.po gawk-3.1.3/po/da.po --- gawk-3.1.2/po/da.po 2003-03-19 04:25:13.000000000 -0800 +++ gawk-3.1.3/po/da.po 2003-07-07 11:20:34.000000000 -0700 @@ -5,7 +5,8 @@ msgid "" msgstr "" "Project-Id-Version: gawk 3.1.31\n" -"POT-Creation-Date: 2003-03-19 14:25+0200\n" +"Report-Msgid-Bugs-To: arnold@skeeve.com\n" +"POT-Creation-Date: 2003-07-07 11:20-0700\n" "PO-Revision-Date: 2002-11-09 10:09+0100\n" "Last-Translator: Keld Simonsen \n" "Language-Team: Danish \n" @@ -13,64 +14,61 @@ "Content-Type: text/plain; charset=iso-8859-1\n" "Content-Transfer-Encoding: 8bit\n" -#: array.c:274 array.c:309 array.c:314 eval.c:494 +#: array.c:112 +#, c-format +msgid "attempt to use scalar parameter `%s' as an array" +msgstr "forsøg på at bruge skalarparameteren \"%s\" som en vektor" + +#: array.c:113 #, c-format msgid "attempt to use scalar `%s' as array" msgstr "forsøg på at bruge skalaren \"%s\" som vektor" -#: array.c:338 +#: array.c:151 +#, fuzzy, c-format +msgid "from %s" +msgstr "%s (fra %s)" + +#: array.c:506 #, c-format msgid "reference to uninitialized element `%s[\"%s\"]'" msgstr "reference til ikke-initieret element \"%s[\"%s\"]\"" -#: array.c:344 +#: array.c:512 #, c-format msgid "subscript of array `%s' is null string" msgstr "indeks i vektoren \"%s\" er en tom streng" -#: array.c:412 array.c:425 array.c:466 +#: array.c:609 #, c-format msgid "delete: index `%s' not in array `%s'" msgstr "delete: indeks \"%s\" findes ikke i vektoren \"%s\"" -#: array.c:432 array.c:515 -#, c-format -msgid "delete: illegal use of variable `%s' as array" -msgstr "delete: ikke tilladt brug af variablen \"%s\" som vektor" - -#: array.c:633 +#: array.c:769 #, c-format msgid "%s: empty (null)\n" msgstr "%s: tom (nil)\n" -#: array.c:638 +#: array.c:774 #, c-format msgid "%s: empty (zero)\n" msgstr "%s: tom (nul)\n" -#: array.c:642 +#: array.c:778 #, c-format msgid "%s: table_size = %d, array_size = %d\n" msgstr "%s: tabelstørrelse = %d, vektorstørrelse = %d\n" -#: array.c:671 +#: array.c:807 #, fuzzy, c-format msgid "%s: is parameter\n" msgstr "%s: er en parameter\n" -#: array.c:676 +#: array.c:812 #, c-format msgid "%s: array_ref to %s\n" msgstr "%s: vektorreference til %s\n" -#: array.c:975 -msgid "asort: first argument is not an array" -msgstr "asort: første argument er ikke en vektor" - -#: array.c:984 -msgid "asort: second argument is not an array" -msgstr "asort: andet argument er ikke en vektor" - #: awkgram.y:208 #, fuzzy, c-format msgid "%s blocks must have an action part" @@ -91,269 +89,282 @@ msgid "regexp constant `/%s/' looks like a C comment, but is not" msgstr "regexp-konstanten \"/%s/\" ser ud som en C-kommentar, men er det ikke" -#: awkgram.y:340 +#: awkgram.y:340 awkgram.y:615 msgid "statement may have no effect" msgstr "kommandoen har måske ikke nogen effekt" -#: awkgram.y:431 awkgram.y:451 +#: awkgram.y:435 awkgram.y:455 #, fuzzy, c-format msgid "`%s' used in %s action" msgstr "\"next\" brugt i BEGIN- eller END-handling" -#: awkgram.y:444 awkgram.y:447 +#: awkgram.y:448 awkgram.y:451 msgid "`nextfile' is a gawk extension" msgstr "\"nextfile\" er en gawk-udvidelse" -#: awkgram.y:461 +#: awkgram.y:465 msgid "`return' used outside function context" msgstr "\"return\" brugt uden for funktion" -#: awkgram.y:500 +#: awkgram.y:504 msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'" msgstr "" "alenestående \"print\" i BEGIN eller END-regel bør muligvis være 'print \"\"'" -#: awkgram.y:513 awkgram.y:520 +#: awkgram.y:517 awkgram.y:524 msgid "`delete array' is a gawk extension" msgstr "\"delete array\" er en gawk-udvidelse" -#: awkgram.y:528 awkgram.y:535 +#: awkgram.y:532 awkgram.y:539 #, fuzzy msgid "`delete(array)' is a non-portable tawk extension" msgstr "\"delete array\" er en gawk-udvidelse" -#: awkgram.y:578 +#: awkgram.y:583 +#, c-format +msgid "duplicate case values in switch body: %s" +msgstr "" + +#: awkgram.y:593 +msgid "Duplicate `default' detected in switch body" +msgstr "" + +#: awkgram.y:681 msgid "multistage two-way pipelines don't work" msgstr "flertrins dobbeltrettede datakanaler fungerer ikke" -#: awkgram.y:669 +#: awkgram.y:772 msgid "regular expression on right of assignment" msgstr "regulært udtryk i højreleddet af en tildeling" -#: awkgram.y:679 +#: awkgram.y:782 msgid "regular expression on left of `~' or `!~' operator" msgstr "regulært udtryk på venstre side af en \"~\"- eller \"!~\"-operator" -#: awkgram.y:687 +#: awkgram.y:790 msgid "regular expression on right of comparison" msgstr "regulært udtryk i højreleddet af en sammenligning" -#: awkgram.y:754 +#: awkgram.y:857 msgid "non-redirected `getline' undefined inside END action" msgstr "ikke-omdirigeret \"getline\" udefineret inde i END-handling" -#: awkgram.y:781 +#: awkgram.y:884 msgid "call of `length' without parentheses is not portable" msgstr "kald af \"length\" uden parenteser er ikke portabelt" -#: awkgram.y:784 +#: awkgram.y:887 msgid "call of `length' without parentheses is deprecated by POSIX" msgstr "kald af \"length\" uden parenteser er forældet ifølge POSIX" -#: awkgram.y:835 +#: awkgram.y:940 +msgid "use of non-array as array" +msgstr "" + +#: awkgram.y:942 msgid "invalid subscript expression" msgstr "ugyldig indeksudtryk" -#: awkgram.y:1020 +#: awkgram.y:1140 #, fuzzy msgid "unexpected newline or end of string" msgstr "uventet nylinjetegn" -#: awkgram.y:1115 +#: awkgram.y:1235 msgid "empty program text on command line" msgstr "tom programtekst på kommandolinjen" -#: awkgram.y:1172 +#: awkgram.y:1292 #, c-format msgid "can't open source file `%s' for reading (%s)" msgstr "kan ikke åbne kildefilen \"%s\" for læsning (%s)" -#: awkgram.y:1207 +#: awkgram.y:1327 #, c-format msgid "can't read sourcefile `%s' (%s)" msgstr "kan ikke læse kildefilen \"%s\" (%s)" -#: awkgram.y:1215 +#: awkgram.y:1335 #, c-format msgid "source file `%s' is empty" msgstr "kildefilen \"%s\" er tom" -#: awkgram.y:1417 awkgram.y:1527 awkgram.y:1545 awkgram.y:1895 awkgram.y:1980 +#: awkgram.y:1537 awkgram.y:1647 awkgram.y:1665 awkgram.y:2015 awkgram.y:2100 msgid "source file does not end in newline" msgstr "kildefilen slutter ikke med en ny linje" -#: awkgram.y:1481 +#: awkgram.y:1601 msgid "unterminated regexp ends with `\\' at end of file" msgstr "uafsluttet regulært udtryk slutter med \"\\\" i slutningen af filen" -#: awkgram.y:1501 +#: awkgram.y:1621 msgid "unterminated regexp" msgstr "uafsluttet regulært udtryk" -#: awkgram.y:1504 +#: awkgram.y:1624 msgid "unterminated regexp at end of file" msgstr "uafsluttet regulært udtryk i slutningen af filen" -#: awkgram.y:1571 +#: awkgram.y:1691 msgid "use of `\\ #...' line continuation is not portable" msgstr "Brug af \"\\ #...\" for linjefortsættelse er ikke portabelt" -#: awkgram.y:1583 +#: awkgram.y:1703 msgid "backslash not last character on line" msgstr "sidste tegn på linjen er ikke en omvendt skråstreg" -#: awkgram.y:1628 +#: awkgram.y:1748 msgid "POSIX does not allow operator `**='" msgstr "POSIX tillader ikke operatoren \"**=\"" -#: awkgram.y:1630 +#: awkgram.y:1750 msgid "old awk does not support operator `**='" msgstr "gamle awk understøtter ikke operatoren \"**=\"" -#: awkgram.y:1639 +#: awkgram.y:1759 msgid "POSIX does not allow operator `**'" msgstr "POSIX tillader ikke operatoren \"**\"" -#: awkgram.y:1641 +#: awkgram.y:1761 msgid "old awk does not support operator `**'" msgstr "gamle awk understøtter ikke operatoren \"**\"" -#: awkgram.y:1672 +#: awkgram.y:1792 msgid "operator `^=' is not supported in old awk" msgstr "operatoren \"^=\" understøttes ikke i gamle awk" -#: awkgram.y:1680 +#: awkgram.y:1800 msgid "operator `^' is not supported in old awk" msgstr "operatoren \"^\" understøttes ikke i gamle awk" -#: awkgram.y:1764 awkgram.y:1781 +#: awkgram.y:1884 awkgram.y:1901 msgid "unterminated string" msgstr "uafsluttet streng" -#: awkgram.y:1941 +#: awkgram.y:2061 #, c-format msgid "invalid char '%c' in expression" msgstr "ugyldigt tegn \"%c\" i udtryk" -#: awkgram.y:2001 +#: awkgram.y:2121 #, c-format msgid "`%s' is a gawk extension" msgstr "\"%s\" er en gawk-udvidelse" -#: awkgram.y:2004 +#: awkgram.y:2124 #, c-format msgid "`%s' is a Bell Labs extension" msgstr "\"%s\" er en Bell Labs-udvidelse" -#: awkgram.y:2007 +#: awkgram.y:2127 #, c-format msgid "POSIX does not allow `%s'" msgstr "POSIX tillader ikke \"%s\"" -#: awkgram.y:2011 +#: awkgram.y:2131 #, c-format msgid "`%s' is not supported in old awk" msgstr "\"%s\" understøttes ikke i gamle awk" -#: awkgram.y:2038 +#: awkgram.y:2158 msgid "`goto' considered harmful!\n" msgstr "\"goto\" anses for skadlig!\n" -#: awkgram.y:2102 +#: awkgram.y:2220 #, c-format msgid "%d is invalid as number of arguments for %s" msgstr "%d er et ugyldigt antal argumenter for %s" -#: awkgram.y:2121 awkgram.y:2124 +#: awkgram.y:2239 awkgram.y:2242 msgid "match: third argument is a gawk extension" msgstr "match: tredje argument er en gawk-udvidelse" -#: awkgram.y:2137 +#: awkgram.y:2255 #, c-format msgid "%s: string literal as last arg of substitute has no effect" msgstr "" "%s: bogstavelig streng som sidste argument til erstatning har ingen effekt" -#: awkgram.y:2140 +#: awkgram.y:2258 #, fuzzy, c-format msgid "%s third parameter is not a changeable object" msgstr "sub: tredje argument er ikke et ændringsbart objekt" -#: awkgram.y:2167 awkgram.y:2170 +#: awkgram.y:2285 awkgram.y:2288 msgid "close: second argument is a gawk extension" msgstr "close: andet argument er en gawk-udvidelse" -#: awkgram.y:2180 +#: awkgram.y:2298 msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore" msgstr "" "brug af dcgettext(_\"...\") er fejlagtigt: fjern det indledende " "understregningstegn" -#: awkgram.y:2195 +#: awkgram.y:2313 #, fuzzy msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore" msgstr "" "brug af dcgettext(_\"...\") er fejlagtigt: fjern det indledende " "understregningstegn" -#: awkgram.y:2266 +#: awkgram.y:2384 #, c-format msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d" msgstr "funktionen \"%s\": parameter %d, \"%s\", er samme som parameter %d" -#: awkgram.y:2299 +#: awkgram.y:2417 #, c-format msgid "function `%s': parameter `%s' shadows global variable" msgstr "funktionen \"%s\": parameteren \"%s\" overskygger en global variabel" -#: awkgram.y:2411 +#: awkgram.y:2529 #, c-format msgid "could not open `%s' for writing (%s)" msgstr "kunne ikke åbne \"%s\" for skrivning (%s)" -#: awkgram.y:2412 profile.c:93 +#: awkgram.y:2530 profile.c:93 msgid "sending profile to standard error" msgstr "sender profilen til standard fejl" -#: awkgram.y:2442 +#: awkgram.y:2562 #, c-format msgid "%s: close failed (%s)" msgstr "%s: mislykkedes at lukke (%s)" -#: awkgram.y:2566 +#: awkgram.y:2684 msgid "shadow_funcs() called twice!" msgstr "shadow_funcs() kaldt to gange!" -#: awkgram.y:2593 +#: awkgram.y:2711 msgid "there were shadowed variables." msgstr "" -#: awkgram.y:2666 +#: awkgram.y:2784 #, c-format msgid "function `%s': can't use function name as parameter name" msgstr "funktionen \"%s\": kan ikke bruge funktionsnavn som parameternavn" -#: awkgram.y:2676 +#: awkgram.y:2794 #, c-format msgid "function name `%s' previously defined" msgstr "funktionsnavnet \"%s\" er allerede defineret" -#: awkgram.y:2827 awkgram.y:2833 +#: awkgram.y:2945 awkgram.y:2951 #, c-format msgid "function `%s' called but never defined" msgstr "funktionen \"%s\" kaldt, men aldrig defineret" -#: awkgram.y:2836 +#: awkgram.y:2954 #, c-format msgid "function `%s' defined but never called" msgstr "funktionen \"%s\" defineret, men aldrig kaldt" -#: awkgram.y:2863 +#: awkgram.y:2981 #, c-format msgid "regexp constant for parameter #%d yields boolean value" msgstr "konstant regulært udtryk for parameter %d giver en boolesk værdi" -#: awkgram.y:2876 +#: awkgram.y:2994 #, c-format msgid "" "function `%s' called with space between name and `(',\n" @@ -362,192 +373,197 @@ "funktionen \"%s\" kaldt med blanktegn mellem navnet og \"(\",\n" "%s" -#: awkgram.y:2878 +#: awkgram.y:2996 #, fuzzy msgid "or used as a variable or an array" msgstr "kan ikke bruge funktionsnavnet \"%s\" som variabel eller vektor" -#: builtin.c:111 +#: builtin.c:137 #, c-format msgid "%s to \"%s\" failed (%s)" msgstr "%s til \"%s\" mislykkedes (%s)" -#: builtin.c:112 +#: builtin.c:138 msgid "standard output" msgstr "standard ud" -#: builtin.c:113 +#: builtin.c:139 msgid "reason unknown" msgstr "ukendt årsag" -#: builtin.c:126 +#: builtin.c:152 msgid "exp: received non-numeric argument" msgstr "exp: fik et ikke-numerisk argument" -#: builtin.c:132 +#: builtin.c:158 #, c-format msgid "exp: argument %g is out of range" msgstr "exp: argumentet %g er uden for tilladt område" -#: builtin.c:190 +#: builtin.c:216 #, c-format msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing" msgstr "" "fflush: kan ikke spole: datakanalen \"%s\" åbnet for læsning, ikke skrivning" -#: builtin.c:193 +#: builtin.c:219 #, c-format msgid "fflush: cannot flush: file `%s' opened for reading, not writing" msgstr "fflush: kan ikke spole: filen \"%s\" åbnet for læsning, ikke skrivning" -#: builtin.c:205 +#: builtin.c:231 #, c-format msgid "fflush: `%s' is not an open file, pipe or co-process" msgstr "fflush: \"%s\" er ikke en åben fil, datakanal eller ko proces" -#: builtin.c:299 +#: builtin.c:325 msgid "index: received non-string first argument" msgstr "indeks: første argument er ikke en streng" -#: builtin.c:301 +#: builtin.c:327 msgid "index: received non-string second argument" msgstr "indeks: andet argument er ikke en streng" -#: builtin.c:411 +#: builtin.c:437 msgid "int: received non-numeric argument" msgstr "int: fik et ikke-numerisk argument" -#: builtin.c:428 +#: builtin.c:454 msgid "length: received non-string argument" msgstr "length: fik et argument som ikke er en streng" -#: builtin.c:444 +#: builtin.c:470 msgid "log: received non-numeric argument" msgstr "log: fik et ikke-numerisk argument" -#: builtin.c:447 +#: builtin.c:473 #, c-format msgid "log: received negative argument %g" msgstr "log: fik et negativt argument %g" -#: builtin.c:609 builtin.c:612 +#: builtin.c:635 builtin.c:638 msgid "must use `count$' on all formats or none" msgstr "" -#: builtin.c:714 +#: builtin.c:740 msgid "`$' is not permitted in awk formats" msgstr "\"$\" tillades ikke i awkformat" -#: builtin.c:720 +#: builtin.c:746 msgid "arg count with `$' must be > 0" msgstr "argumentantallet med \"$\" skal være > 0" -#: builtin.c:722 +#: builtin.c:748 #, fuzzy, c-format msgid "arg count %ld greater than total number of supplied arguments" msgstr "argumentantallet %d er større end antal givne argumenter" -#: builtin.c:724 +#: builtin.c:750 msgid "`$' not permitted after period in format" msgstr "\"$\" tillades ikke efter et punktum i formatet" -#: builtin.c:737 +#: builtin.c:763 msgid "no `$' supplied for positional field width or precision" msgstr "intet \"$\" angivet for positionsangivet feltbredde eller præcision" -#: builtin.c:795 +#: builtin.c:821 msgid "`l' is meaningless in awk formats; ignored" msgstr "\"l\" er meningsløst i awk-formater, ignoreret" -#: builtin.c:799 +#: builtin.c:825 msgid "`l' is not permitted in POSIX awk formats" msgstr "\"l\" tillades ikke i POSIX awk-formater" -#: builtin.c:810 +#: builtin.c:836 msgid "`L' is meaningless in awk formats; ignored" msgstr "\"L\" er meningsløst i awk-formater, ignoreret" -#: builtin.c:814 +#: builtin.c:840 msgid "`L' is not permitted in POSIX awk formats" msgstr "\"L\" tillades ikke i POSIX awk-formater" -#: builtin.c:825 +#: builtin.c:851 msgid "`h' is meaningless in awk formats; ignored" msgstr "\"h\" er meningsløst i awk-formater, ignoreret" -#: builtin.c:829 +#: builtin.c:855 msgid "`h' is not permitted in POSIX awk formats" msgstr "\"h\" tillades ikke i POSIX awk-formater" -#: builtin.c:1078 +#: builtin.c:1055 +#, c-format +msgid "[s]printf: value %g is out of range for `%%%c' format" +msgstr "" + +#: builtin.c:1108 msgid "not enough arguments to satisfy format string" msgstr "for få argumenter til formatstrengen" -#: builtin.c:1080 +#: builtin.c:1110 msgid "^ ran out for this one" msgstr "^ sluttede her" -#: builtin.c:1085 +#: builtin.c:1115 msgid "[s]printf: format specifier does not have control letter" msgstr "[s]printf: formatspecifiereren har intet kommandobogstav" -#: builtin.c:1088 +#: builtin.c:1118 msgid "too many arguments supplied for format string" msgstr "for mange argumenter til formatstrengen" -#: builtin.c:1154 builtin.c:1157 +#: builtin.c:1184 builtin.c:1187 msgid "printf: no arguments" msgstr "printf: ingen argumenter" -#: builtin.c:1181 +#: builtin.c:1211 msgid "sqrt: received non-numeric argument" msgstr "sqrt: fik ikke-numerisk argument" -#: builtin.c:1185 +#: builtin.c:1215 #, c-format msgid "sqrt: called with negative argument %g" msgstr "sqrt: kaldt med negativt argument %g" -#: builtin.c:1207 +#: builtin.c:1238 #, c-format msgid "substr: start index %g is invalid, using 1" msgstr "substr: startindeks %g er ugyldigt, bruger 1" -#: builtin.c:1212 +#: builtin.c:1243 #, c-format msgid "substr: non-integer start index %g will be truncated" msgstr "substr: startindeks %g som ikke er et heltal bliver trunkeret" -#: builtin.c:1231 -#, c-format -msgid "substr: length %g is <= 0" +#: builtin.c:1262 +#, fuzzy, c-format +msgid "substr: length %g is not >= 1" msgstr "substr: længden %g er <= 0" -#: builtin.c:1233 +#: builtin.c:1264 #, fuzzy, c-format -msgid "substr: length %g is < 0" +msgid "substr: length %g is not >= 0" msgstr "substr: længden %g er <= 0" -#: builtin.c:1240 +#: builtin.c:1271 #, c-format msgid "substr: non-integer length %g will be truncated" msgstr "substr: længden %g som ikke er et heltal bliver trunkeret" -#: builtin.c:1245 +#: builtin.c:1276 #, c-format msgid "substr: length %g too big for string indexing, truncating to %g" msgstr "" -#: builtin.c:1257 +#: builtin.c:1288 msgid "substr: source string is zero length" msgstr "substr: kildestrengen er tom" -#: builtin.c:1263 +#: builtin.c:1294 #, fuzzy, c-format msgid "substr: start index %g is past end of string" msgstr "substr: startindeks %d er forbi slutningen på strengen" -#: builtin.c:1271 +#: builtin.c:1302 #, fuzzy, c-format msgid "" "substr: length %g at start index %g exceeds length of first argument (%lu)" @@ -555,295 +571,295 @@ "substr: længden %d ved startindeks %d overskrider længden af første argument " "(%d)" -#: builtin.c:1306 +#: builtin.c:1337 #, fuzzy msgid "strftime: received non-string first argument" msgstr "strftime: fik et første argument som ikke er en streng" -#: builtin.c:1312 +#: builtin.c:1343 msgid "strftime: received empty format string" msgstr "strftime: fik en tom formatstreng" -#: builtin.c:1321 +#: builtin.c:1352 #, fuzzy msgid "strftime: received non-numeric second argument" msgstr "strftime: fik et ikke-numerisk andet argument" -#: builtin.c:1384 +#: builtin.c:1415 msgid "mktime: received non-string argument" msgstr "mktime: fik et argument som ikke er en streng" -#: builtin.c:1429 +#: builtin.c:1460 #, fuzzy msgid "system: received non-string argument" msgstr "system: fik et argument som ikke er en streng" -#: builtin.c:1573 +#: builtin.c:1581 eval.c:1883 +#, fuzzy, c-format +msgid "reference to uninitialized field `$%d'" +msgstr "reference til ikke-initieret variabel \"%s\"" + +#: builtin.c:1608 #, fuzzy msgid "tolower: received non-string argument" msgstr "tolower: fik et argument som ikke er en streng" -#: builtin.c:1622 +#: builtin.c:1657 #, fuzzy msgid "toupper: received non-string argument" msgstr "toupper: fik et argument som ikke er en streng" -#: builtin.c:1667 +#: builtin.c:1702 msgid "atan2: received non-numeric first argument" msgstr "atan2: fik et ikke-numerisk første argument" -#: builtin.c:1669 +#: builtin.c:1704 msgid "atan2: received non-numeric second argument" msgstr "atan2: fik et ikke-numerisk andet argument" -#: builtin.c:1688 +#: builtin.c:1723 msgid "sin: received non-numeric argument" msgstr "sin: fik et ikke-numerisk argument" -#: builtin.c:1704 +#: builtin.c:1739 msgid "cos: received non-numeric argument" msgstr "cos: fik et ikke-numerisk argument" -#: builtin.c:1748 +#: builtin.c:1788 msgid "srand: received non-numeric argument" msgstr "srand: fik et ikke-numerisk argument" -#: builtin.c:1787 +#: builtin.c:1823 msgid "match: third argument is not an array" msgstr "match: tredje argument er ikke en vektor" -#: builtin.c:2264 -msgid "gensub: 3rd argument of 0 treated as 1" +#: builtin.c:2307 +msgid "gensub: third argument of 0 treated as 1" msgstr "gensub: Nullet i tredje argument behandlet som et ét-tal" -#: builtin.c:2375 builtin.c:2377 +#: builtin.c:2416 builtin.c:2418 msgid "lshift: received non-numeric first argument" msgstr "lshift: fik et ikke-numerisk første argument" -#: builtin.c:2379 +#: builtin.c:2420 #, c-format msgid "lshift(%lf, %lf): negative values will give strange results" msgstr "lshift(%lf, %lf): negative værdier vil give mærkelige resultater" -#: builtin.c:2381 +#: builtin.c:2422 #, c-format msgid "lshift(%lf, %lf): fractional values will be truncated" msgstr "lshift(%lf, %lf): flydendetalsværdier vil blive trunkeret" -#: builtin.c:2383 +#: builtin.c:2424 #, c-format msgid "lshift(%lf, %lf): too large shift value will give strange results" msgstr "" "lshift(%lf, %lf): for store skifteværdier vil give mærkelige resultater" -#: builtin.c:2412 builtin.c:2414 +#: builtin.c:2453 builtin.c:2455 msgid "rshift: received non-numeric first argument" msgstr "rshift: fik et ikke-numerisk første argument" -#: builtin.c:2416 +#: builtin.c:2457 #, c-format msgid "rshift(%lf, %lf): negative values will give strange results" msgstr "rshift(%lf, %lf): negative værdier vil give mærkelige resultater" -#: builtin.c:2418 +#: builtin.c:2459 #, c-format msgid "rshift(%lf, %lf): fractional values will be truncated" msgstr "rshift(%lf, %lf): flydendetalsværdier vil blive trunkeret" -#: builtin.c:2420 +#: builtin.c:2461 #, c-format msgid "rshift(%lf, %lf): too large shift value will give strange results" msgstr "" "rshift(%lf, %lf): for store skifteværdier vil give mærkelige resultater" -#: builtin.c:2449 builtin.c:2451 +#: builtin.c:2490 builtin.c:2492 msgid "and: received non-numeric first argument" msgstr "and: fik et ikke-numerisk første argument" -#: builtin.c:2453 +#: builtin.c:2494 #, c-format msgid "and(%lf, %lf): negative values will give strange results" msgstr "and(%lf, %lf): negative værdier vil give mærkelige resultater" -#: builtin.c:2455 +#: builtin.c:2496 #, c-format msgid "and(%lf, %lf): fractional values will be truncated" msgstr "and(%lf, %lf): flydendetalsværdier vil blive trunkeret" -#: builtin.c:2484 builtin.c:2486 +#: builtin.c:2525 builtin.c:2527 msgid "or: received non-numeric first argument" msgstr "or: fik et ikke-numerisk første argument" -#: builtin.c:2488 +#: builtin.c:2529 #, c-format msgid "or(%lf, %lf): negative values will give strange results" msgstr "or(%lf, %lf): negative værdier vil give mærkelige resultater" -#: builtin.c:2490 +#: builtin.c:2531 #, c-format msgid "or(%lf, %lf): fractional values will be truncated" msgstr "or(%lf, %lf): flydendetalsværdier vil blive trunkeret" -#: builtin.c:2519 builtin.c:2521 +#: builtin.c:2560 builtin.c:2562 msgid "xor: received non-numeric first argument" msgstr "xor: fik et ikke-numerisk første argument" -#: builtin.c:2523 +#: builtin.c:2564 #, c-format msgid "xor(%lf, %lf): negative values will give strange results" msgstr "xor(%lf, %lf): negative værdier vil give mærkelige resultater" -#: builtin.c:2525 +#: builtin.c:2566 #, c-format msgid "xor(%lf, %lf): fractional values will be truncated" msgstr "xor(%lf, %lf): flydendetalsværdier vil blive trunkeret" -#: builtin.c:2553 +#: builtin.c:2594 msgid "compl: received non-numeric argument" msgstr "compl: fik et ikke-numerisk argument" -#: builtin.c:2555 +#: builtin.c:2596 #, c-format msgid "compl(%lf): negative value will give strange results" msgstr "compl(%lf): negative værdier vil give mærkelige resultater" -#: builtin.c:2557 +#: builtin.c:2598 #, c-format msgid "compl(%lf): fractional value will be truncated" msgstr "compl(%lf): flydendetalsværdier vil blive trunkeret" -#: builtin.c:2728 +#: builtin.c:2771 #, c-format msgid "dcgettext: `%s' is not a valid locale category" msgstr "dcgettext: \"%s\" er ikke en gyldig lokalekategori" -#: eval.c:262 +#: eval.c:266 #, c-format msgid "unknown nodetype %d" msgstr "ukendt nodetype %d" -#: eval.c:310 +#: eval.c:312 msgid "buffer overflow in genflags2str" msgstr "bufferoverløb i genflags2str" -#: eval.c:555 +#: eval.c:647 #, fuzzy, c-format msgid "for loop: array `%s' changed size from %ld to %ld during loop execution" msgstr "" "for-løkke: vektoren \"%s\" ændrede størrelse fra %d til %d under løkke-" "udførelsen" -#: eval.c:576 +#: eval.c:668 msgid "`break' outside a loop is not portable" msgstr "\"break\" uden for en løkke er ikke portabelt" -#: eval.c:580 +#: eval.c:672 msgid "`break' outside a loop is not allowed" msgstr "\"break\" uden for en løkke er ikke tilladt" -#: eval.c:597 +#: eval.c:689 msgid "`continue' outside a loop is not portable" msgstr "\"continue\" uden for en løkke er ikke portabelt" -#: eval.c:601 +#: eval.c:693 msgid "`continue' outside a loop is not allowed" msgstr "\"continue\" uden for en løkke er ikke tilladt" -#: eval.c:635 +#: eval.c:727 msgid "`next' cannot be called from a BEGIN rule" msgstr "\"next\" kan ikke kaldes fra en BEGIN-regel" -#: eval.c:637 +#: eval.c:729 msgid "`next' cannot be called from an END rule" msgstr "\"next\" kan ikke kaldes fra en END-regel" -#: eval.c:646 +#: eval.c:738 msgid "`nextfile' cannot be called from a BEGIN rule" msgstr "\"nextfile\" kan ikke kaldes fra en BEGIN-regel" -#: eval.c:648 +#: eval.c:740 msgid "`nextfile' cannot be called from an END rule" msgstr "\"nextfile\" kan ikke kaldes fra en END-regel" -#: eval.c:696 +#: eval.c:785 msgid "statement has no effect" msgstr "kommandoen har ingen effekt" -#: eval.c:731 eval.c:761 eval.c:1733 -#, c-format -msgid "reference to uninitialized variable `%s'" -msgstr "reference til ikke-initieret variabel \"%s\"" - -#: eval.c:739 eval.c:1721 +#: eval.c:828 eval.c:1726 #, c-format msgid "can't use function name `%s' as variable or array" msgstr "kan ikke bruge funktionsnavnet \"%s\" som variabel eller vektor" -#: eval.c:746 eval.c:752 +#: eval.c:835 eval.c:841 #, c-format msgid "reference to uninitialized argument `%s'" msgstr "reference til ikke-initieret argument \"%s\"" -#: eval.c:810 eval.c:1728 profile.c:773 +#: eval.c:848 eval.c:907 eval.c:1732 eval.c:1742 profile.c:807 #, c-format msgid "attempt to use array `%s' in a scalar context" msgstr "forsøg på at bruge vektoren \"%s\" i skalarsammenhæng" -#: eval.c:910 +#: eval.c:858 eval.c:1752 +#, c-format +msgid "reference to uninitialized variable `%s'" +msgstr "reference til ikke-initieret variabel \"%s\"" + +#: eval.c:1007 msgid "" "concatenation: side effects in one expression have changed the length of " "another!" msgstr "" "concatenation: sideeffekter i et udtryk har ændret længden af et andet!" -#: eval.c:935 +#: eval.c:1032 msgid "assignment used in conditional context" msgstr "tildeling brugt i sammenligningsammenhæng" -#: eval.c:1026 +#: eval.c:1122 msgid "division by zero attempted" msgstr "forsøgte at dividere med nul" -#: eval.c:1041 +#: eval.c:1137 #, c-format msgid "division by zero attempted in `%%'" msgstr "forsøgte at dividere med nul i \"%%\"" -#: eval.c:1056 profile.c:649 +#: eval.c:1152 profile.c:683 #, c-format msgid "illegal type (%s) in tree_eval" msgstr "ikke tilladt type (%s) i tree_eval" -#: eval.c:1232 +#: eval.c:1328 msgid "division by zero attempted in `/='" msgstr "forsøgte at dividere med nul i \"/=\"" -#: eval.c:1250 +#: eval.c:1346 #, c-format msgid "division by zero attempted in `%%='" msgstr "forsøgte at dividere med nul i \"%%=\"" -#: eval.c:1510 -#, c-format -msgid "%s (from %s)" -msgstr "%s (fra %s)" - -#: eval.c:1569 +#: eval.c:1586 #, c-format msgid "function `%s' called with more arguments than declared" msgstr "funktionen \"%s\" kaldt med flere argumenter end deklareret" -#: eval.c:1628 +#: eval.c:1633 #, c-format msgid "function `%s' not defined" msgstr "funktionen \"%s\" er ikke defineret" -#: eval.c:1634 +#: eval.c:1639 #, c-format msgid "function %s called\n" msgstr "funktionen %s kaldt\n" -#: eval.c:1693 +#: eval.c:1698 msgid "" "\n" "\t# Function Call Stack:\n" @@ -853,46 +869,41 @@ "\t# Funktionskaldsstak:\n" "\n" -#: eval.c:1696 +#: eval.c:1701 msgid "\t# -- main --\n" msgstr "\t# -- main --\n" -#: eval.c:1850 +#: eval.c:1867 msgid "attempt to field reference from non-numeric value" msgstr "forsøg på at feltreferere fra ikke-numerisk værdi" -#: eval.c:1852 +#: eval.c:1869 msgid "attempt to reference from null string" msgstr "forsøg på at referere fra tom streng" -#: eval.c:1858 +#: eval.c:1875 #, c-format msgid "attempt to access field %d" msgstr "forsøg på at få adgang til felt nummer %d" -#: eval.c:1874 -#, c-format -msgid "attempt to use scalar parameter `%s' as an array" -msgstr "forsøg på at bruge skalarparameteren \"%s\" som en vektor" - -#: eval.c:1886 eval.c:1893 profile.c:865 +#: eval.c:1896 eval.c:1903 profile.c:900 msgid "assignment is not allowed to result of builtin function" msgstr "tildeling er ikke tilladt til resultatet fra en indbygget funktion" -#: eval.c:1941 +#: eval.c:1951 msgid "`IGNORECASE' is a gawk extension" msgstr "\"IGNORECASE\" er en gawk-udvidelse" -#: eval.c:1970 +#: eval.c:1980 msgid "`BINMODE' is a gawk extension" msgstr "\"BINMODE\" er en gawk-udvidelse" -#: eval.c:2082 +#: eval.c:2092 #, c-format msgid "bad `%sFMT' specification `%s'" msgstr "fejlagtig \"%sFMT\"-specifikation \"%s\"" -#: eval.c:2160 +#: eval.c:2170 msgid "turning off `--lint' due to assignment to `LINT'" msgstr "deaktiverer \"--lint\" på grund af en tildeling til \"LINT\"" @@ -910,32 +921,32 @@ msgid "extension: library `%s': cannot call function `%s' (%s)\n" msgstr "extension: bibliotek \"%s\": kan ikke kalde funktionen \"%s\" (%s)\n" -#: ext.c:181 +#: ext.c:183 msgid "Operation Not Supported" msgstr "Operationen understøttes ikke" -#: field.c:321 +#: field.c:315 msgid "NF set to negative value" msgstr "NF sat til en negativ værdi" -#: field.c:819 +#: field.c:808 msgid "split: second argument is not an array" msgstr "split: andet argument er ikke en vektor" -#: field.c:854 +#: field.c:842 msgid "split: null string for third arg is a gawk extension" msgstr "split: tom streng som tredje argument er en gawk-udvidelse" -#: field.c:906 +#: field.c:894 msgid "`FIELDWIDTHS' is a gawk extension" msgstr "\"FIELDWIDTHS\" er en gawk-udvidelse" -#: field.c:933 +#: field.c:921 #, c-format msgid "field %d in FIELDWIDTHS, must be > 0" msgstr "felt %d i FIELDWIDTHS skal være > 0" -#: field.c:1006 +#: field.c:994 msgid "null string for `FS' is a gawk extension" msgstr "tom streng som \"FS\" er en gawk-udvidelse" @@ -979,7 +990,7 @@ msgid "%s: invalid option -- %c\n" msgstr "%s: ugyldig flag -- %c\n" -#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:431 +#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:434 #, c-format msgid "%s: option requires an argument -- %c\n" msgstr "%s: flaget kræver et argument -- %c\n" @@ -994,468 +1005,468 @@ msgid "%s: option `-W %s' doesn't allow an argument\n" msgstr "%s: flaget \"-W %s\" tillader ikke noget argument\n" -#: io.c:257 +#: io.c:305 #, c-format msgid "cannot open file `%s' for reading (%s)" msgstr "kan ikke åbne filen \"%s\" for læsning (%s)" -#: io.c:344 +#: io.c:392 #, c-format msgid "close of fd %d (`%s') failed (%s)" msgstr "lukning af fd %d (\"%s\") mislykkedes (%s)" -#: io.c:482 +#: io.c:530 #, c-format msgid "invalid tree type %s in redirect()" msgstr "ugyldig trætype %s i redirect()" -#: io.c:488 +#: io.c:536 #, c-format msgid "expression in `%s' redirection only has numeric value" msgstr "udtrykket i \"%s\"-omdirigering har kun numerisk værdi" -#: io.c:494 +#: io.c:542 #, c-format msgid "expression for `%s' redirection has null string value" msgstr "udtrykket for \"%s\"-omdirigering har en tom streng som værdi" -#: io.c:499 +#: io.c:547 #, c-format msgid "filename `%s' for `%s' redirection may be result of logical expression" msgstr "" "filnavnet \"%s\" for \"%s\"-omdirigering kan være resultatet af et logisk " "udtryk" -#: io.c:521 +#: io.c:569 #, c-format msgid "unnecessary mixing of `>' and `>>' for file `%.*s'" msgstr "unødig blanding af \">\" og \">>\" for filen \"%.*s\"" -#: io.c:573 +#: io.c:621 #, c-format msgid "can't open pipe `%s' for output (%s)" msgstr "kan ikke åbne røret \"%s\" for udskrivning (%s)" -#: io.c:582 +#: io.c:630 #, c-format msgid "can't open pipe `%s' for input (%s)" msgstr "kan ikke åbne røret \"%s\" for indtastning (%s)" -#: io.c:595 +#: io.c:643 #, c-format msgid "can't open two way socket `%s' for input/output (%s)" msgstr "kan ikke åbne tovejssoklen \"%s\" for ind-/uddata (%s)" -#: io.c:599 +#: io.c:647 #, c-format msgid "can't open two way pipe `%s' for input/output (%s)" msgstr "kan ikke åbne tovejsrøret \"%s\" for ind-/uddata (%s)" -#: io.c:675 +#: io.c:723 #, c-format msgid "can't redirect from `%s' (%s)" msgstr "kan ikke omdirigere fra \"%s\" (%s)" -#: io.c:678 +#: io.c:726 #, c-format msgid "can't redirect to `%s' (%s)" msgstr "kan ikke omdirigere til \"%s\" (%s)" -#: io.c:717 +#: io.c:765 msgid "" "reached system limit for open files: starting to multiplex file descriptors" msgstr "" "nåede systembegrænsningen for åbne filer: begynder at multiplekse " "fildeskriptorer" -#: io.c:729 +#: io.c:777 #, c-format msgid "close of `%s' failed (%s)." msgstr "lukning af \"%s\" mislykkedes (%s)" -#: io.c:736 +#: io.c:784 msgid "too many pipes or input files open" msgstr "for mange rør eller inddatafiler åbne" -#: io.c:759 +#: io.c:807 msgid "close: second argument must be `to' or `from'" msgstr "close: andet argument skal være \"to\" eller \"from\"" -#: io.c:773 +#: io.c:821 #, c-format msgid "close: `%.*s' is not an open file, pipe or co-process" msgstr "close: \"%.*s\" er ikke en åben fil, datakanal eller ko-proces" -#: io.c:777 +#: io.c:825 msgid "close of redirection that was never opened" msgstr "lukning af omdirigering som aldrig åbnedes" -#: io.c:804 +#: io.c:862 #, c-format msgid "close: redirection `%s' not opened with `|&', second argument ignored" msgstr "" "close: omdirigeringen \"%s\" åbnedes ikke med \"|&\", andet argument " "ignoreret" -#: io.c:866 +#: io.c:924 #, c-format msgid "failure status (%d) on pipe close of `%s' (%s)" msgstr "fejlstatus (%d) fra rørlukning af \"%s\" (%s)" -#: io.c:869 +#: io.c:927 #, c-format msgid "failure status (%d) on file close of `%s' (%s)" msgstr "fejlstatus (%d) fra fillukning af \"%s\" (%s)" -#: io.c:888 +#: io.c:946 #, c-format msgid "no explicit close of socket `%s' provided" msgstr "ingen eksplicit lukning af soklen \"%s\" angivet" -#: io.c:891 +#: io.c:949 #, c-format msgid "no explicit close of co-process `%s' provided" msgstr "ingen eksplicit lukning af ko-processen \"%s\" angivet" -#: io.c:894 +#: io.c:952 #, c-format msgid "no explicit close of pipe `%s' provided" msgstr "ingen eksplicit lukning af røret \"%s\" angivet" -#: io.c:897 +#: io.c:955 #, c-format msgid "no explicit close of file `%s' provided" msgstr "ingen eksplicit lukning af filen \"%s\" angivet" -#: io.c:926 io.c:980 +#: io.c:984 io.c:1038 #, c-format msgid "error writing standard output (%s)" msgstr "fejl ved skrivning til standard ud (%s)" -#: io.c:930 io.c:984 +#: io.c:988 io.c:1042 #, c-format msgid "error writing standard error (%s)" msgstr "fejl ved skrivning til standard fejl (%s)" -#: io.c:938 +#: io.c:996 #, c-format msgid "pipe flush of `%s' failed (%s)." msgstr "rørspuling af \"%s\" mislykkedes (%s)" -#: io.c:941 +#: io.c:999 #, c-format msgid "co-process flush of pipe to `%s' failed (%s)." msgstr "ko-processpuling af røret til \"%s\" mislykkedes (%s)" -#: io.c:944 +#: io.c:1002 #, c-format msgid "file flush of `%s' failed (%s)." msgstr "filspuling af \"%s\" mislykkedes (%s)" -#: io.c:1103 +#: io.c:1161 msgid "/inet/raw client not ready yet, sorry" msgstr "/inet/raw-klient er desværre ikke klar endnu" -#: io.c:1105 io.c:1142 +#: io.c:1163 io.c:1200 msgid "only root may use `/inet/raw'." msgstr "kun root kan bruge \"/inet/raw\"." -#: io.c:1140 +#: io.c:1198 msgid "/inet/raw server not ready yet, sorry" msgstr "/inet/raw-server er desværre ikke klar endnu" -#: io.c:1230 +#: io.c:1288 #, c-format msgid "no (known) protocol supplied in special filename `%s'" msgstr "ingen (kendt) protokol opgivet i special-filnavn \"%s\"" -#: io.c:1248 +#: io.c:1306 #, c-format msgid "special file name `%s' is incomplete" msgstr "special-filnavn \"%s\" er ufuldstændigt" -#: io.c:1260 +#: io.c:1318 #, c-format msgid "local port invalid in `%s'" msgstr "lokal port ugyldig i \"%s\"" -#: io.c:1272 +#: io.c:1330 msgid "must supply a remote hostname to `/inet'" msgstr "skal angive et fjernmaskinenavn til \"/inet\"" -#: io.c:1287 +#: io.c:1345 msgid "must supply a remote port to `/inet'" msgstr "skal angive en fjernport til \"/inet\"" -#: io.c:1293 +#: io.c:1351 #, c-format msgid "remote port invalid in `%s'" msgstr "fjernporten ugyldig i \"%s\"" -#: io.c:1303 +#: io.c:1361 msgid "TCP/IP communications are not supported" msgstr "TCP/IP-kommunikation understøttes ikke" -#: io.c:1312 io.c:1492 +#: io.c:1370 io.c:1551 #, c-format msgid "file `%s' is a directory" msgstr "filen \"%s\" er et katalog" -#: io.c:1381 +#: io.c:1440 #, c-format msgid "use `PROCINFO[\"%s\"]' instead of `%s'" msgstr "brug \"PROCINFO[\"%s\"]\" i stedet for \"%s\"" -#: io.c:1413 +#: io.c:1472 msgid "use `PROCINFO[...]' instead of `/dev/user'" msgstr "brug \"PROCINFO[...]\" i stedet for \"dev/user\"" -#: io.c:1478 io.c:1652 +#: io.c:1537 io.c:1711 #, c-format msgid "could not open `%s', mode `%s'" msgstr "kunne ikke åbne \"%s\", tilstand \"%s\"" -#: io.c:1703 +#: io.c:1762 #, fuzzy, c-format msgid "close of master pty failed (%s)" msgstr "lukning af røret mislykkedes (%s)" -#: io.c:1705 io.c:1857 io.c:2009 +#: io.c:1764 io.c:1916 io.c:2068 #, c-format msgid "close of stdout in child failed (%s)" msgstr "lukning af standard ud i barnet mislykkedes (%s)" -#: io.c:1708 +#: io.c:1767 #, fuzzy, c-format msgid "moving slave pty to stdout in child failed (dup: %s)" msgstr "flytning af rør til standard ud i barnet mislykkedes (dup: %s)" -#: io.c:1710 io.c:1862 +#: io.c:1769 io.c:1921 #, c-format msgid "close of stdin in child failed (%s)" msgstr "lukning af standard ind i barnet mislykkedes (%s)" -#: io.c:1713 +#: io.c:1772 #, fuzzy, c-format msgid "moving slave pty to stdin in child failed (dup: %s)" msgstr "flytning af rør til standard ind i barnet mislykkedes (dup: %s)" -#: io.c:1715 io.c:1734 +#: io.c:1774 io.c:1793 #, fuzzy, c-format msgid "close of slave pty failed (%s)" msgstr "lukning af røret mislykkedes (%s)" -#: io.c:1808 io.c:1860 io.c:1990 io.c:2012 +#: io.c:1867 io.c:1919 io.c:2049 io.c:2071 #, c-format msgid "moving pipe to stdout in child failed (dup: %s)" msgstr "flytning af rør til standard ud i barnet mislykkedes (dup: %s)" -#: io.c:1812 io.c:1865 +#: io.c:1871 io.c:1924 #, c-format msgid "moving pipe to stdin in child failed (dup: %s)" msgstr "flytning af rør til standard ind i barnet mislykkedes (dup: %s)" -#: io.c:1829 io.c:2003 +#: io.c:1888 io.c:2062 msgid "restoring stdout in parent process failed\n" msgstr "genskabelse af standard ud i forælderprocessen mislykkedes\n" -#: io.c:1834 +#: io.c:1893 msgid "restoring stdin in parent process failed\n" msgstr "genskabelse af standard ind i forælderprocessen mislykkedes\n" -#: io.c:1868 io.c:2014 io.c:2025 +#: io.c:1927 io.c:2073 io.c:2084 #, c-format msgid "close of pipe failed (%s)" msgstr "lukning af røret mislykkedes (%s)" -#: io.c:1913 +#: io.c:1972 msgid "`|&' not supported" msgstr "\"|&\" understøttes ikke" -#: io.c:1980 +#: io.c:2039 #, c-format msgid "cannot open pipe `%s' (%s)" msgstr "kan ikke åbne røret \"%s\" (%s)" -#: io.c:2021 +#: io.c:2080 #, c-format msgid "cannot create child process for `%s' (fork: %s)" msgstr "kan ikke oprette barneproces for \"%s\" (fork: %s)" -#: io.c:2364 +#: io.c:2423 #, c-format msgid "data file `%s' is empty" msgstr "datafilen \"%s\" er tom" -#: io.c:2407 io.c:2415 +#: io.c:2466 io.c:2474 msgid "could not allocate more input memory" msgstr "" -#: io.c:2540 io.c:2782 io.c:3046 +#: io.c:2832 io.c:2895 #, c-format msgid "error reading input file `%s': %s" msgstr "fejl ved læsning af inddatafilen \"%s\": %s" -#: io.c:3281 +#: io.c:3020 msgid "multicharacter value of `RS' is a gawk extension" msgstr "flertegnsværdien af \"RS\" er en gawk-udvidelse" -#: main.c:322 +#: main.c:324 msgid "`-m[fr]' option irrelevant in gawk" msgstr "\"-m[fr]\"-flaget er irrelevant i gawk" -#: main.c:324 +#: main.c:326 msgid "-m option usage: `-m[fr] nnn'" msgstr "-m-flagets brug: \"-m[fr] nnn\"" -#: main.c:341 +#: main.c:343 #, c-format msgid "%s: option `-W %s' unrecognized, ignored\n" msgstr "%s: flaget \"-W %s\" ukendt, ignoreret\n" -#: main.c:378 +#: main.c:380 msgid "empty argument to `--source' ignored" msgstr "tomt argument til \"--source\" ignoreret" -#: main.c:448 +#: main.c:451 msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'" msgstr "miljøvariablen \"POSIXLY_CORRECT\" sat: aktiverer \"--posix\"" -#: main.c:453 +#: main.c:456 msgid "`--posix' overrides `--traditional'" msgstr "\"--posix\" tilsidesætter \"--traditional\"" -#: main.c:464 +#: main.c:467 msgid "`--posix'/`--traditional' overrides `--non-decimal-data'" msgstr "\"--posix\"/\"--traditional\" tilsidesætter \"--non-decimal-data\"" -#: main.c:468 +#: main.c:471 #, fuzzy, c-format msgid "running %s setuid root may be a security problem" msgstr "at køre %s setuid root kan være et sikkerhedsproblem" -#: main.c:509 +#: main.c:512 #, fuzzy, c-format msgid "can't set binary mode on stdin (%s)" msgstr "kan ikke sætte tilstand på standard ind (%s)" -#: main.c:512 +#: main.c:515 #, fuzzy, c-format msgid "can't set binary mode on stdout (%s)" msgstr "kan ikke sætte tilstand på standard ud (%s)" -#: main.c:514 +#: main.c:517 #, fuzzy, c-format msgid "can't set binary mode on stderr (%s)" msgstr "kan ikke sætte tilstand på standard fejl (%s)" -#: main.c:544 +#: main.c:547 msgid "no program text at all!" msgstr "ingen programtekst overhovedet!" -#: main.c:612 +#: main.c:620 #, c-format msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n" msgstr "Brug: %s [POSIX- eller GNU-stilflag] -f progfil [--] fil ...\n" -#: main.c:614 +#: main.c:622 #, c-format msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n" msgstr "Brug: %s [POSIX- eller GNU-stilflag] %cprogram%c fil ...\n" -#: main.c:619 +#: main.c:627 msgid "POSIX options:\t\tGNU long options:\n" msgstr "POSIX-flag:\t\tGNU lange flag:\n" -#: main.c:620 +#: main.c:628 msgid "\t-f progfile\t\t--file=progfile\n" msgstr "\t-f progfil\t\t--file=progfil\n" -#: main.c:621 +#: main.c:629 msgid "\t-F fs\t\t\t--field-separator=fs\n" msgstr "\t-F fs\t\t\t--field-separator=fs\n" -#: main.c:622 +#: main.c:630 msgid "\t-v var=val\t\t--assign=var=val\n" msgstr "\t-v var=værdi\t\t--assign=var=værdi\n" -#: main.c:623 +#: main.c:631 msgid "\t-m[fr] val\n" msgstr "\t-m[fr] værdi\n" -#: main.c:624 +#: main.c:632 msgid "\t-W compat\t\t--compat\n" msgstr "\t-W compat\t\t--compat\n" -#: main.c:625 +#: main.c:633 msgid "\t-W copyleft\t\t--copyleft\n" msgstr "\t-W copyleft\t\t--copyleft\n" -#: main.c:626 +#: main.c:634 msgid "\t-W copyright\t\t--copyright\n" msgstr "\t-W copyright\t\t--copyright\n" -#: main.c:627 +#: main.c:635 msgid "\t-W dump-variables[=file]\t--dump-variables[=file]\n" msgstr "\t-W dump-variables[=fil]\t--dump-variables[=fil]\n" -#: main.c:628 +#: main.c:636 msgid "\t-W gen-po\t\t--gen-po\n" msgstr "\t-W gen-po\t\t--gen-po\n" -#: main.c:629 +#: main.c:637 msgid "\t-W help\t\t\t--help\n" msgstr "\t-W help\t\t\t--help\n" -#: main.c:630 +#: main.c:638 msgid "\t-W lint[=fatal]\t\t--lint[=fatal]\n" msgstr "\t-W lint[=fatal]\t\t--lint[=fatal]\n" -#: main.c:631 +#: main.c:639 msgid "\t-W lint-old\t\t--lint-old\n" msgstr "\t-W lint-old\t\t--lint-old\n" -#: main.c:632 +#: main.c:640 msgid "\t-W non-decimal-data\t--non-decimal-data\n" msgstr "\t-W non-decimal-data\t--non-decimal-data\n" -#: main.c:634 +#: main.c:642 msgid "\t-W nostalgia\t\t--nostalgia\n" msgstr "\t-W nostalgia\t\t--nostalgia\n" -#: main.c:637 +#: main.c:645 msgid "\t-W parsedebug\t\t--parsedebug\n" msgstr "\t-W parsedebug\t\t--parsedebug\n" -#: main.c:639 +#: main.c:647 msgid "\t-W profile[=file]\t--profile[=file]\n" msgstr "\t-W profile[=fil]\t--profile[=fil]\n" -#: main.c:640 +#: main.c:648 msgid "\t-W posix\t\t--posix\n" msgstr "\t-W posix\t\t--posix\n" -#: main.c:641 +#: main.c:649 msgid "\t-W re-interval\t\t--re-interval\n" msgstr "\t-W re-interval\t\t--re-interval\n" -#: main.c:642 +#: main.c:650 msgid "\t-W source=program-text\t--source=program-text\n" msgstr "\t-W source=programtekst\t--source=programtekst\n" -#: main.c:643 +#: main.c:651 msgid "\t-W traditional\t\t--traditional\n" msgstr "\t-W traditional\t\t--traditional\n" -#: main.c:644 +#: main.c:652 msgid "\t-W usage\t\t--usage\n" msgstr "\t-W usage\t\t--usage\n" -#: main.c:645 +#: main.c:653 msgid "\t-W version\t\t--version\n" msgstr "\t-W version\t\t--version\n" -#: main.c:649 +#: main.c:657 #, fuzzy msgid "" "\n" @@ -1466,21 +1477,21 @@ "sektionen \"Reporting Problems and Bugs\" i den trykte version.\n" "Rapportér synpunkter på oversættelsen til .\n" -#: main.c:653 +#: main.c:661 msgid "" "gawk is a pattern scanning and processing language.\n" "By default it reads standard input and writes standard output.\n" "\n" msgstr "" -#: main.c:657 +#: main.c:665 msgid "" "Examples:\n" "\tgawk '{ sum += $1 }; END { print sum }' file\n" "\tgawk -F: '{ print $1 }' /etc/passwd\n" msgstr "" -#: main.c:669 +#: main.c:682 #, c-format msgid "" "Copyright (C) 1989, 1991-%d Free Software Foundation.\n" @@ -1499,7 +1510,7 @@ "enhver senere version.\n" "\n" -#: main.c:677 +#: main.c:690 msgid "" "This program is distributed in the hope that it will be useful,\n" "but WITHOUT ANY WARRANTY; without even the implied warranty of\n" @@ -1513,7 +1524,7 @@ "General Public License for yderligere information.\n" "\n" -#: main.c:683 +#: main.c:696 msgid "" "You should have received a copy of the GNU General Public License\n" "along with this program; if not, write to the Free Software\n" @@ -1523,46 +1534,46 @@ "med dette program. Hvis ikke, så skriv til Free Software Foundation,\n" "Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n" -#: main.c:713 +#: main.c:730 msgid "-Ft does not set FS to tab in POSIX awk" msgstr "-Ft sætter ikke FS til tab i POSIX-awk" -#: main.c:944 +#: main.c:956 #, c-format msgid "" "%s: `%s' argument to `-v' not in `var=value' form\n" "\n" msgstr "" -#: main.c:964 +#: main.c:976 #, c-format msgid "`%s' is not a legal variable name" msgstr "" -#: main.c:967 +#: main.c:979 #, c-format msgid "`%s' is not a variable name, looking for file `%s=%s'" msgstr "" -#: main.c:995 +#: main.c:1012 msgid "floating point exception" msgstr "flydendetalsundtagelse" -#: main.c:1002 +#: main.c:1019 msgid "fatal error: internal error" msgstr "fatal fejl: intern fejl" -#: main.c:1052 +#: main.c:1069 #, c-format msgid "no pre-opened fd %d" msgstr "ingen for-åbnet fd %d" -#: main.c:1057 +#: main.c:1074 #, c-format msgid "could not pre-open /dev/null for fd %d" msgstr "kunne ikke for-åbne /dev/null for fd %d" -#: main.c:1080 main.c:1089 +#: main.c:1097 main.c:1106 #, c-format msgid "could not find groups: %s" msgstr "kunne ikke finde grupper: %s" @@ -1583,23 +1594,23 @@ msgid "fatal: " msgstr "fatal: " -#: node.c:59 node.c:66 node.c:75 node.c:89 node.c:116 +#: node.c:58 node.c:65 node.c:74 node.c:88 node.c:115 msgid "can't convert string to float" msgstr "kan ikke konvertere en streng til flydende tal" -#: node.c:357 +#: node.c:355 msgid "backslash at end of string" msgstr "omvendt skråstreg i slutningen af strengen" -#: node.c:544 +#: node.c:539 msgid "POSIX does not allow `\\x' escapes" msgstr "POSIX tillader ikke \"\\x\"-kontrolsekvenser" -#: node.c:550 +#: node.c:545 msgid "no hex digits in `\\x' escape sequence" msgstr "ingen heksadecimale cifre i \"\\x\"-kontrolsekvenser" -#: node.c:584 +#: node.c:579 #, c-format msgid "escape sequence `\\%c' treated as plain `%c'" msgstr "kontrolsekvensen \"\\%c\" behandlet som kun \"%c\"" @@ -1614,24 +1625,21 @@ msgid "could not open `%s' for writing: %s" msgstr "kunne ikke åbne \"%s\" for skrivning: %s" -#: profile.c:409 -msgid "internal error: Node_var with null vname" +#: profile.c:449 +#, fuzzy, c-format +msgid "internal error: %s with null vname" msgstr "intern fejl: Node_var med null vname" -#: profile.c:471 +#: profile.c:512 msgid "# treated internally as `delete'" msgstr "" -#: profile.c:545 -msgid "internal error: Node_var_array with null vname" -msgstr "intern fejl: Node_var_vektor med null vname" - -#: profile.c:1127 +#: profile.c:1162 #, c-format msgid "\t# gawk profile, created %s\n" msgstr "\t# gawkprofil, oprettet %s\n" -#: profile.c:1130 +#: profile.c:1165 msgid "" "\t# BEGIN block(s)\n" "\n" @@ -1639,7 +1647,7 @@ "\t# BEGIN-blok\n" "\n" -#: profile.c:1140 +#: profile.c:1175 msgid "" "\t# Rule(s)\n" "\n" @@ -1647,7 +1655,7 @@ "\t# Regel/regler\n" "\n" -#: profile.c:1146 +#: profile.c:1181 msgid "" "\t# END block(s)\n" "\n" @@ -1655,7 +1663,7 @@ "\t# END-blok\n" "\n" -#: profile.c:1166 +#: profile.c:1201 msgid "" "\n" "\t# Functions, listed alphabetically\n" @@ -1663,7 +1671,7 @@ "\n" "\t# Funktioner, listede alfabetisk\n" -#: profile.c:1376 +#: profile.c:1413 #, c-format msgid "unexpected type %s in prec_level" msgstr "uventet type %s i prec_level" @@ -1745,6 +1753,32 @@ msgid "No previous regular expression" msgstr "Intet foregående regulært udtryk" +#, fuzzy +#~ msgid "substr: length %g is < 0" +#~ msgstr "substr: længden %g er <= 0" + +#~ msgid "delete: illegal use of variable `%s' as array" +#~ msgstr "delete: ikke tilladt brug af variablen \"%s\" som vektor" + +#, fuzzy +#~ msgid "%s: gvar_ref to %s\n" +#~ msgstr "%s: vektorreference til %s\n" + +#~ msgid "asort: first argument is not an array" +#~ msgstr "asort: første argument er ikke en vektor" + +#~ msgid "asort: second argument is not an array" +#~ msgstr "asort: andet argument er ikke en vektor" + +#, fuzzy +#~ msgid "" +#~ "attempt to use array parameter `%s' that was passed from global scalar `%" +#~ "s'" +#~ msgstr "forsøg på at bruge skalarparameteren \"%s\" som en vektor" + +#~ msgid "internal error: Node_var_array with null vname" +#~ msgstr "intern fejl: Node_var_vektor med null vname" + #~ msgid "BEGIN blocks must have an action part" #~ msgstr "BEGIN-blok skal have en handlingsdel" Binary files gawk-3.1.2/po/de.gmo and gawk-3.1.3/po/de.gmo differ diff -urN gawk-3.1.2/po/de.po gawk-3.1.3/po/de.po --- gawk-3.1.2/po/de.po 2003-03-19 04:25:13.000000000 -0800 +++ gawk-3.1.3/po/de.po 2003-07-07 11:20:34.000000000 -0700 @@ -5,7 +5,8 @@ msgid "" msgstr "" "Project-Id-Version: gawk 3.1.0\n" -"POT-Creation-Date: 2003-03-19 14:25+0200\n" +"Report-Msgid-Bugs-To: arnold@skeeve.com\n" +"POT-Creation-Date: 2003-07-07 11:20-0700\n" "PO-Revision-Date: 2002-04-03 18:55+02:00\n" "Last-Translator: Christian Kirsch \n" "Language-Team: German \n" @@ -13,64 +14,61 @@ "Content-Type: text/plain; charset=iso-8859-1\n" "Content-Transfer-Encoding: 8bit\n" -#: array.c:274 array.c:309 array.c:314 eval.c:494 +#: array.c:112 +#, c-format +msgid "attempt to use scalar parameter `%s' as an array" +msgstr "Versuch den skalaren Parameter '%s' als Array zu benutzen." + +#: array.c:113 #, c-format msgid "attempt to use scalar `%s' as array" msgstr "Versuch, Skalar '%s' als Array zu verwenden." -#: array.c:338 +#: array.c:151 +#, fuzzy, c-format +msgid "from %s" +msgstr "%s (von %s)" + +#: array.c:506 #, c-format msgid "reference to uninitialized element `%s[\"%s\"]'" msgstr "Bezug auf nicht-initialisiertes Element »%s[\"%s\"]«" -#: array.c:344 +#: array.c:512 #, c-format msgid "subscript of array `%s' is null string" msgstr "Index in Array »%s« ist Nullstring." -#: array.c:412 array.c:425 array.c:466 +#: array.c:609 #, c-format msgid "delete: index `%s' not in array `%s'" msgstr "delete: Index »%s« nicht in Feld »%s« vorhanden." -#: array.c:432 array.c:515 -#, c-format -msgid "delete: illegal use of variable `%s' as array" -msgstr "delete: Benutzung der Variablen »%s« als Array ist nicht zulässig." - -#: array.c:633 +#: array.c:769 #, c-format msgid "%s: empty (null)\n" msgstr "%s: leer (Null)\n" -#: array.c:638 +#: array.c:774 #, c-format msgid "%s: empty (zero)\n" msgstr "%s: leer (0)\n" -#: array.c:642 +#: array.c:778 #, c-format msgid "%s: table_size = %d, array_size = %d\n" msgstr "%s: Table_size = %d, array_size = %d\n" -#: array.c:671 +#: array.c:807 #, fuzzy, c-format msgid "%s: is parameter\n" msgstr "%s: ist ein Parameter\n" -#: array.c:676 +#: array.c:812 #, c-format msgid "%s: array_ref to %s\n" msgstr "%s: Array-Referenz auf %s\n" -#: array.c:975 -msgid "asort: first argument is not an array" -msgstr "asort: Erstes Argument ist kein Array." - -#: array.c:984 -msgid "asort: second argument is not an array" -msgstr "asort: Zweites Argument ist kein array." - #: awkgram.y:208 #, fuzzy, c-format msgid "%s blocks must have an action part" @@ -93,272 +91,285 @@ "Konstanter Regulärer Ausdruck '/%s' sieht wie ein C-Kommentar aus, ist aber " "keiner." -#: awkgram.y:340 +#: awkgram.y:340 awkgram.y:615 msgid "statement may have no effect" msgstr "Statement möglicherweise ohne Effekt." -#: awkgram.y:431 awkgram.y:451 +#: awkgram.y:435 awkgram.y:455 #, fuzzy, c-format msgid "`%s' used in %s action" msgstr "'next' in BEGIN- oder END-Aktion benutzt." -#: awkgram.y:444 awkgram.y:447 +#: awkgram.y:448 awkgram.y:451 msgid "`nextfile' is a gawk extension" msgstr "'nextfile' ist eine gawk-Erweiterung." -#: awkgram.y:461 +#: awkgram.y:465 msgid "`return' used outside function context" msgstr "'return' außerhalb einer Funktion benutzt." -#: awkgram.y:500 +#: awkgram.y:504 msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'" msgstr "" "Einfaches 'print' in BEGIN- oder END-Regel soll vermutlich 'print \"\"' sein." -#: awkgram.y:513 awkgram.y:520 +#: awkgram.y:517 awkgram.y:524 msgid "`delete array' is a gawk extension" msgstr "'delete array' ist eine gawk-Erweiterung." -#: awkgram.y:528 awkgram.y:535 +#: awkgram.y:532 awkgram.y:539 #, fuzzy msgid "`delete(array)' is a non-portable tawk extension" msgstr "'delete array' ist eine gawk-Erweiterung." -#: awkgram.y:578 +#: awkgram.y:583 +#, c-format +msgid "duplicate case values in switch body: %s" +msgstr "" + +#: awkgram.y:593 +msgid "Duplicate `default' detected in switch body" +msgstr "" + +#: awkgram.y:681 msgid "multistage two-way pipelines don't work" msgstr "'multistage' Zweiwege-Pipes funktionieren nicht." -#: awkgram.y:669 +#: awkgram.y:772 msgid "regular expression on right of assignment" msgstr "Regulärer Ausdruck auf der rechten Seite einer Zuweisung." -#: awkgram.y:679 +#: awkgram.y:782 msgid "regular expression on left of `~' or `!~' operator" msgstr "Regulärer Ausdruck links vom '~'- oder '!~'-Operator." -#: awkgram.y:687 +#: awkgram.y:790 msgid "regular expression on right of comparison" msgstr "Regulärer Ausdruck rechts von einem Vergleich." -#: awkgram.y:754 +#: awkgram.y:857 msgid "non-redirected `getline' undefined inside END action" msgstr "" "Nicht-umgelenktes 'getline' ist innerhalb der END-Aktion nicht definiert." -#: awkgram.y:781 +#: awkgram.y:884 msgid "call of `length' without parentheses is not portable" msgstr "Aufruf von 'length' ohne Klammern ist nicht portabel." -#: awkgram.y:784 +#: awkgram.y:887 msgid "call of `length' without parentheses is deprecated by POSIX" msgstr "Aufruf von 'length' ohne Klammern ist in POSIX-Mode veraltet." -#: awkgram.y:835 +#: awkgram.y:940 +msgid "use of non-array as array" +msgstr "" + +#: awkgram.y:942 msgid "invalid subscript expression" msgstr "Ungültiger Index-Ausdruck." -#: awkgram.y:1020 +#: awkgram.y:1140 #, fuzzy msgid "unexpected newline or end of string" msgstr "Unerwartetes Zeilenende" -#: awkgram.y:1115 +#: awkgram.y:1235 msgid "empty program text on command line" msgstr "Kein Programmtext auf der Kommandozeile." -#: awkgram.y:1172 +#: awkgram.y:1292 #, c-format msgid "can't open source file `%s' for reading (%s)" msgstr "Kann Quelldatei '%s' nicht zum Lesen öffnen (%s)." -#: awkgram.y:1207 +#: awkgram.y:1327 #, c-format msgid "can't read sourcefile `%s' (%s)" msgstr "Kann Quelldatei '%s' nicht lesen (%s)." -#: awkgram.y:1215 +#: awkgram.y:1335 #, c-format msgid "source file `%s' is empty" msgstr "Quelldatei '%s' ist leer." -#: awkgram.y:1417 awkgram.y:1527 awkgram.y:1545 awkgram.y:1895 awkgram.y:1980 +#: awkgram.y:1537 awkgram.y:1647 awkgram.y:1665 awkgram.y:2015 awkgram.y:2100 msgid "source file does not end in newline" msgstr "Quelldatei hört nicht mit Zeilenende auf." -#: awkgram.y:1481 +#: awkgram.y:1601 msgid "unterminated regexp ends with `\\' at end of file" msgstr "" "Nicht-beendeter Regulärer Ausdruck (hört mit '\\' auf) am Ende der Datei." -#: awkgram.y:1501 +#: awkgram.y:1621 msgid "unterminated regexp" msgstr "Nicht-beendeter Regulärer Ausdruck" -#: awkgram.y:1504 +#: awkgram.y:1624 msgid "unterminated regexp at end of file" msgstr "Nicht-beendeter Regulärer Ausdruck am Dateiende." -#: awkgram.y:1571 +#: awkgram.y:1691 msgid "use of `\\ #...' line continuation is not portable" msgstr "" "Die Verwendung von '\\#...' zur Fortsetzung von Zeilen ist nicht portabel." -#: awkgram.y:1583 +#: awkgram.y:1703 msgid "backslash not last character on line" msgstr "Backslash ist nicht letztes Zeichen auf der Zeile." -#: awkgram.y:1628 +#: awkgram.y:1748 msgid "POSIX does not allow operator `**='" msgstr "POSIX erlaubt den Operator '**=' nicht." -#: awkgram.y:1630 +#: awkgram.y:1750 msgid "old awk does not support operator `**='" msgstr "Das alte awk erlaubt den Operator '**=' nicht." -#: awkgram.y:1639 +#: awkgram.y:1759 msgid "POSIX does not allow operator `**'" msgstr "POSIX erlaubt den Operator '**' nicht." -#: awkgram.y:1641 +#: awkgram.y:1761 msgid "old awk does not support operator `**'" msgstr "Das alte awk erlaubt den Operator '**' nicht." -#: awkgram.y:1672 +#: awkgram.y:1792 msgid "operator `^=' is not supported in old awk" msgstr "Das alte awk kennt den Operator '^=' nicht." -#: awkgram.y:1680 +#: awkgram.y:1800 msgid "operator `^' is not supported in old awk" msgstr "Das alte awk kennt den Operator '^' nicht." -#: awkgram.y:1764 awkgram.y:1781 +#: awkgram.y:1884 awkgram.y:1901 msgid "unterminated string" msgstr "Nicht-beendeter String" -#: awkgram.y:1941 +#: awkgram.y:2061 #, c-format msgid "invalid char '%c' in expression" msgstr "Ungültiges Zeichen '%c' in einem Ausdruck." -#: awkgram.y:2001 +#: awkgram.y:2121 #, c-format msgid "`%s' is a gawk extension" msgstr "'%s' ist eine gawk-Erweiterung" -#: awkgram.y:2004 +#: awkgram.y:2124 #, c-format msgid "`%s' is a Bell Labs extension" msgstr "'%s' ist eine Erweiterung der Bell Labs." -#: awkgram.y:2007 +#: awkgram.y:2127 #, c-format msgid "POSIX does not allow `%s'" msgstr "POSIX gestattet '%s' nicht." -#: awkgram.y:2011 +#: awkgram.y:2131 #, c-format msgid "`%s' is not supported in old awk" msgstr "Das alte awk gestattet '%s' nicht." -#: awkgram.y:2038 +#: awkgram.y:2158 msgid "`goto' considered harmful!\n" msgstr "'goto' gilt als schlechter Stil!\n" -#: awkgram.y:2102 +#: awkgram.y:2220 #, c-format msgid "%d is invalid as number of arguments for %s" msgstr "Unzulässige Argumentzahl %d für %s." -#: awkgram.y:2121 awkgram.y:2124 +#: awkgram.y:2239 awkgram.y:2242 msgid "match: third argument is a gawk extension" msgstr "match: Das dritte Argument ist eine gawk-Erweiterung." -#: awkgram.y:2137 +#: awkgram.y:2255 #, c-format msgid "%s: string literal as last arg of substitute has no effect" msgstr "%s: Ein String als letztes Argument von substitute hat keinen Effekt." -#: awkgram.y:2140 +#: awkgram.y:2258 #, fuzzy, c-format msgid "%s third parameter is not a changeable object" msgstr "Der dritte Parameter von sub ist ein unveränderliches Objekt." -#: awkgram.y:2167 awkgram.y:2170 +#: awkgram.y:2285 awkgram.y:2288 msgid "close: second argument is a gawk extension" msgstr "close: Das zweite Argument ist eine gawk-Erweiterung." -#: awkgram.y:2180 +#: awkgram.y:2298 msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore" msgstr "" "Fehlerhafte Verwendung von dcgettext(_\"...\"): \n" "Entfernen Sie den führenden Unterstrich." -#: awkgram.y:2195 +#: awkgram.y:2313 #, fuzzy msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore" msgstr "" "Fehlerhafte Verwendung von dcgettext(_\"...\"): \n" "Entfernen Sie den führenden Unterstrich." -#: awkgram.y:2266 +#: awkgram.y:2384 #, c-format msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d" msgstr "Funktion '%s': Parameter #%d, '%s' wiederholt Parameter #%d." -#: awkgram.y:2299 +#: awkgram.y:2417 #, c-format msgid "function `%s': parameter `%s' shadows global variable" msgstr "Funktion '%s': Parameter '%s' verdeckt eine globale Variable." -#: awkgram.y:2411 +#: awkgram.y:2529 #, c-format msgid "could not open `%s' for writing (%s)" msgstr "Kann '%s' nicht zum Schreiben öffnen (%s)." -#: awkgram.y:2412 profile.c:93 +#: awkgram.y:2530 profile.c:93 msgid "sending profile to standard error" msgstr "Schicke Profile auf Stadard-Fehlerausgabe." -#: awkgram.y:2442 +#: awkgram.y:2562 #, c-format msgid "%s: close failed (%s)" msgstr "%s: close gescheitert (%s)." -#: awkgram.y:2566 +#: awkgram.y:2684 msgid "shadow_funcs() called twice!" msgstr "shadow_funcs() zweimal aufgerufen!" -#: awkgram.y:2593 +#: awkgram.y:2711 msgid "there were shadowed variables." msgstr "" -#: awkgram.y:2666 +#: awkgram.y:2784 #, c-format msgid "function `%s': can't use function name as parameter name" msgstr "Funktion '%s': Kann Funktionsnamen nicht als Parameternamen benutzen." -#: awkgram.y:2676 +#: awkgram.y:2794 #, c-format msgid "function name `%s' previously defined" msgstr "Funktion '%s' ist bereits definiert." -#: awkgram.y:2827 awkgram.y:2833 +#: awkgram.y:2945 awkgram.y:2951 #, c-format msgid "function `%s' called but never defined" msgstr "Aufgerufene funktion '%s' ist nirgends definiert." -#: awkgram.y:2836 +#: awkgram.y:2954 #, c-format msgid "function `%s' defined but never called" msgstr "Funktion '%s' wird nirgends aufgerufen." -#: awkgram.y:2863 +#: awkgram.y:2981 #, c-format msgid "regexp constant for parameter #%d yields boolean value" msgstr "" "Konstanter Regulärer Ausdruck für Parameter #%d ergibt einen logischen Wert." -#: awkgram.y:2876 +#: awkgram.y:2994 #, c-format msgid "" "function `%s' called with space between name and `(',\n" @@ -367,196 +378,201 @@ "Funktion '%s' mit Leerzeichen zwischen Name und '(' aufgerufen, \n" "%s" -#: awkgram.y:2878 +#: awkgram.y:2996 #, fuzzy msgid "or used as a variable or an array" msgstr "Kann Funktion '%s' nicht als Variable oder Array verwenden." -#: builtin.c:111 +#: builtin.c:137 #, c-format msgid "%s to \"%s\" failed (%s)" msgstr "%s to \"%s\" fehlgeschlagen (%s)" -#: builtin.c:112 +#: builtin.c:138 msgid "standard output" msgstr "Standardausgabe" -#: builtin.c:113 +#: builtin.c:139 msgid "reason unknown" msgstr "Unbekannte Ursache" -#: builtin.c:126 +#: builtin.c:152 msgid "exp: received non-numeric argument" msgstr "exp: Argument ist keine Zahl." -#: builtin.c:132 +#: builtin.c:158 #, c-format msgid "exp: argument %g is out of range" msgstr "exp: Argument %g außerhalb des gültigen Zahlenbereichs." -#: builtin.c:190 +#: builtin.c:216 #, c-format msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing" msgstr "" "fflush: Leeren der Puffer nicht möglich, Pipe »%s« ist nur zum Lesen " "geöffnet." -#: builtin.c:193 +#: builtin.c:219 #, c-format msgid "fflush: cannot flush: file `%s' opened for reading, not writing" msgstr "" "fflush: Leeren der Puffer nicht möglich, Datei »%s« ist nur zum Lesen " "geöffnet." -#: builtin.c:205 +#: builtin.c:231 #, c-format msgid "fflush: `%s' is not an open file, pipe or co-process" msgstr "fflush: »%s« ist keine geöffnete Datei, Pipe oder Prozess." -#: builtin.c:299 +#: builtin.c:325 msgid "index: received non-string first argument" msgstr "index: Erstes Argument ist kein String." -#: builtin.c:301 +#: builtin.c:327 msgid "index: received non-string second argument" msgstr "index: Zweites Argument ist kein string." -#: builtin.c:411 +#: builtin.c:437 msgid "int: received non-numeric argument" msgstr "Argument ist keine Zahl." -#: builtin.c:428 +#: builtin.c:454 msgid "length: received non-string argument" msgstr "length: Argument ist kein String." -#: builtin.c:444 +#: builtin.c:470 msgid "log: received non-numeric argument" msgstr "log: Argument ist keine Zahl." -#: builtin.c:447 +#: builtin.c:473 #, c-format msgid "log: received negative argument %g" msgstr "log: Negatives Argument %g." -#: builtin.c:609 builtin.c:612 +#: builtin.c:635 builtin.c:638 msgid "must use `count$' on all formats or none" msgstr "" -#: builtin.c:714 +#: builtin.c:740 msgid "`$' is not permitted in awk formats" msgstr "»$« ist in awk-Formaten nicht zulässig." -#: builtin.c:720 +#: builtin.c:746 msgid "arg count with `$' must be > 0" msgstr "Argumentnummer bei »$« muss > 0 sein." -#: builtin.c:722 +#: builtin.c:748 #, fuzzy, c-format msgid "arg count %ld greater than total number of supplied arguments" msgstr "Argumentnummer %d ist größer als Anzahl angegebener Argumente." -#: builtin.c:724 +#: builtin.c:750 msgid "`$' not permitted after period in format" msgstr "»$« nach Punkt in Formatangabe nicht zulässig." -#: builtin.c:737 +#: builtin.c:763 msgid "no `$' supplied for positional field width or precision" msgstr "»$« fehlt in positionsabhängiger Feldbreite oder Genauigkeit." # -#: builtin.c:795 +#: builtin.c:821 msgid "`l' is meaningless in awk formats; ignored" msgstr "»l« ist in awk-Formaten bedeutungslos, ignoriert." -#: builtin.c:799 +#: builtin.c:825 msgid "`l' is not permitted in POSIX awk formats" msgstr "»l« in POSIX-awk-Formaten nicht zulässig." -#: builtin.c:810 +#: builtin.c:836 msgid "`L' is meaningless in awk formats; ignored" msgstr "»L« ist in awk-Formaten bedeutungslos, ignoriert." -#: builtin.c:814 +#: builtin.c:840 msgid "`L' is not permitted in POSIX awk formats" msgstr "»L« in POSIX-awk-Formaten nicht zulässig." -#: builtin.c:825 +#: builtin.c:851 msgid "`h' is meaningless in awk formats; ignored" msgstr "»h« ist in awk-Formaten bedeutungslos, ignoriert." -#: builtin.c:829 +#: builtin.c:855 msgid "`h' is not permitted in POSIX awk formats" msgstr "»h« in POSIX-awk-Formaten nicht zulässig.<" -#: builtin.c:1078 +#: builtin.c:1055 +#, c-format +msgid "[s]printf: value %g is out of range for `%%%c' format" +msgstr "" + +#: builtin.c:1108 msgid "not enough arguments to satisfy format string" msgstr "Nicht genügend Argumente für Formatangabe." -#: builtin.c:1080 +#: builtin.c:1110 msgid "^ ran out for this one" msgstr "^ ran out for this one" -#: builtin.c:1085 +#: builtin.c:1115 msgid "[s]printf: format specifier does not have control letter" msgstr "[s]printf: Format-Specifier hat keinen Controlcode." -#: builtin.c:1088 +#: builtin.c:1118 msgid "too many arguments supplied for format string" msgstr "Zu viele Argumente für Formatstring." -#: builtin.c:1154 builtin.c:1157 +#: builtin.c:1184 builtin.c:1187 msgid "printf: no arguments" msgstr "printf: Keine Argumente" -#: builtin.c:1181 +#: builtin.c:1211 msgid "sqrt: received non-numeric argument" msgstr "sqrt: Argument ist keine Zahl." -#: builtin.c:1185 +#: builtin.c:1215 #, c-format msgid "sqrt: called with negative argument %g" msgstr "sqrt: Argument %g ist negativ." -#: builtin.c:1207 +#: builtin.c:1238 #, c-format msgid "substr: start index %g is invalid, using 1" msgstr "substr: Start-Index %g ist ungültig, 1 wird benutzt." -#: builtin.c:1212 +#: builtin.c:1243 #, c-format msgid "substr: non-integer start index %g will be truncated" msgstr "substr: Start-Wert %g wird abgeschnitten." -#: builtin.c:1231 -#, c-format -msgid "substr: length %g is <= 0" +#: builtin.c:1262 +#, fuzzy, c-format +msgid "substr: length %g is not >= 1" msgstr "substr: Länge %g ist kleiner oder gleich 0." -#: builtin.c:1233 +#: builtin.c:1264 #, fuzzy, c-format -msgid "substr: length %g is < 0" +msgid "substr: length %g is not >= 0" msgstr "substr: Länge %g ist kleiner oder gleich 0." -#: builtin.c:1240 +#: builtin.c:1271 #, c-format msgid "substr: non-integer length %g will be truncated" msgstr "substr: Länge %g wird abgeschnitten." -#: builtin.c:1245 +#: builtin.c:1276 #, c-format msgid "substr: length %g too big for string indexing, truncating to %g" msgstr "" -#: builtin.c:1257 +#: builtin.c:1288 msgid "substr: source string is zero length" msgstr "substr: String ist leer." -#: builtin.c:1263 +#: builtin.c:1294 #, fuzzy, c-format msgid "substr: start index %g is past end of string" msgstr "substr: Start-Wert %d liegt hinter dem Ende des Strings." -#: builtin.c:1271 +#: builtin.c:1302 #, fuzzy, c-format msgid "" "substr: length %g at start index %g exceeds length of first argument (%lu)" @@ -564,242 +580,247 @@ "substr: Länge %d am Start-Wert %d überschreitet Länge des ersten Arguments (%" "d)." -#: builtin.c:1306 +#: builtin.c:1337 #, fuzzy msgid "strftime: received non-string first argument" msgstr "strftime: Erstes Argument ist kein String." -#: builtin.c:1312 +#: builtin.c:1343 msgid "strftime: received empty format string" msgstr "strftime: Format-String ist leer." -#: builtin.c:1321 +#: builtin.c:1352 #, fuzzy msgid "strftime: received non-numeric second argument" msgstr "strftime. Zweites Argument ist keine Zahl." -#: builtin.c:1384 +#: builtin.c:1415 msgid "mktime: received non-string argument" msgstr "mktime: Argument ist kein String." -#: builtin.c:1429 +#: builtin.c:1460 #, fuzzy msgid "system: received non-string argument" msgstr "system: Argument ist kein String." -#: builtin.c:1573 +#: builtin.c:1581 eval.c:1883 +#, fuzzy, c-format +msgid "reference to uninitialized field `$%d'" +msgstr "Referenz auf die nicht-initialisierte Variable '%s'." + +#: builtin.c:1608 #, fuzzy msgid "tolower: received non-string argument" msgstr "tolower: Argument ist kein String." -#: builtin.c:1622 +#: builtin.c:1657 #, fuzzy msgid "toupper: received non-string argument" msgstr "toupper: Argument ist kein String." -#: builtin.c:1667 +#: builtin.c:1702 msgid "atan2: received non-numeric first argument" msgstr "atan2: Erstes Argument ist keine Zahl." -#: builtin.c:1669 +#: builtin.c:1704 msgid "atan2: received non-numeric second argument" msgstr "atan2: Zweites Argument ist keine Zahl." -#: builtin.c:1688 +#: builtin.c:1723 msgid "sin: received non-numeric argument" msgstr "sin: Argument istk eine Zahl." -#: builtin.c:1704 +#: builtin.c:1739 msgid "cos: received non-numeric argument" msgstr "cos: Argument ist keine Zahl." -#: builtin.c:1748 +#: builtin.c:1788 msgid "srand: received non-numeric argument" msgstr "srand: Argument ist keine Zahl." -#: builtin.c:1787 +#: builtin.c:1823 msgid "match: third argument is not an array" msgstr "match: Drittes Argument ist kein Array." -#: builtin.c:2264 -msgid "gensub: 3rd argument of 0 treated as 1" +#: builtin.c:2307 +msgid "gensub: third argument of 0 treated as 1" msgstr "gensub: Drittes Argument 0 als 1 interpretiert" -#: builtin.c:2375 builtin.c:2377 +#: builtin.c:2416 builtin.c:2418 msgid "lshift: received non-numeric first argument" msgstr "lshift: Erstes Argument ist keine Zahl." -#: builtin.c:2379 +#: builtin.c:2420 #, c-format msgid "lshift(%lf, %lf): negative values will give strange results" msgstr "" "lshift(%lf, %lf): Negative Werte werden merkwürdige Ergebnisse liefern." -#: builtin.c:2381 +#: builtin.c:2422 #, c-format msgid "lshift(%lf, %lf): fractional values will be truncated" msgstr "lshift(%lf, %lf): Dezimalteil wird abgeschnitten." -#: builtin.c:2383 +#: builtin.c:2424 #, c-format msgid "lshift(%lf, %lf): too large shift value will give strange results" msgstr "" "lshift(%lf, %lf): Zu große Shift-Werte werden merkwürdige Ergebnisse liefern." -#: builtin.c:2412 builtin.c:2414 +#: builtin.c:2453 builtin.c:2455 msgid "rshift: received non-numeric first argument" msgstr "rshift: Erstes Argument ist keine Zahl." -#: builtin.c:2416 +#: builtin.c:2457 #, c-format msgid "rshift(%lf, %lf): negative values will give strange results" msgstr "" "rshift (%lf, %lf): Negative Werte werden merkwürdige Ergebnisse liefern." -#: builtin.c:2418 +#: builtin.c:2459 #, c-format msgid "rshift(%lf, %lf): fractional values will be truncated" msgstr "rshift(%lf, %lf): Dezimalteil wird abgeschnitten." -#: builtin.c:2420 +#: builtin.c:2461 #, c-format msgid "rshift(%lf, %lf): too large shift value will give strange results" msgstr "" "rshift(%lf, %lf): Zu große Shift-Werte werden merkwürdige Ergebnisse liefern." -#: builtin.c:2449 builtin.c:2451 +#: builtin.c:2490 builtin.c:2492 msgid "and: received non-numeric first argument" msgstr "and: Erstes Argument ist keine Zahl." -#: builtin.c:2453 +#: builtin.c:2494 #, c-format msgid "and(%lf, %lf): negative values will give strange results" msgstr "and(%lf, %lf): Negative Werte werden merkwürdige Ergebnisse liefern." -#: builtin.c:2455 +#: builtin.c:2496 #, c-format msgid "and(%lf, %lf): fractional values will be truncated" msgstr "and(%lf, %lf): Dezimalteil wird abgeschnitten." -#: builtin.c:2484 builtin.c:2486 +#: builtin.c:2525 builtin.c:2527 msgid "or: received non-numeric first argument" msgstr "or: Erstes Argument ist keine Zahl." -#: builtin.c:2488 +#: builtin.c:2529 #, c-format msgid "or(%lf, %lf): negative values will give strange results" msgstr "or(%lf, %lf): Negative Werte werden merkwürdige Ergebnisse liefern." -#: builtin.c:2490 +#: builtin.c:2531 #, c-format msgid "or(%lf, %lf): fractional values will be truncated" msgstr "or(%lf, %lf): Dezimalteil wird abgeschnitten." -#: builtin.c:2519 builtin.c:2521 +#: builtin.c:2560 builtin.c:2562 msgid "xor: received non-numeric first argument" msgstr "xor: Erstes Argument ist keine Zahl." -#: builtin.c:2523 +#: builtin.c:2564 #, c-format msgid "xor(%lf, %lf): negative values will give strange results" msgstr "xor(%lf, %lf: Negative Werte werden merkwürdige Ergebnisse liefern." -#: builtin.c:2525 +#: builtin.c:2566 #, c-format msgid "xor(%lf, %lf): fractional values will be truncated" msgstr "xor(%lf, %lf): Dezimalteil wird abgeschnitten." -#: builtin.c:2553 +#: builtin.c:2594 msgid "compl: received non-numeric argument" msgstr "compl: Erstes Argument ist keine Zahl." -#: builtin.c:2555 +#: builtin.c:2596 #, c-format msgid "compl(%lf): negative value will give strange results" msgstr "compl(%lf): Negativer Wert wird merkwürdige Ergebnisse liefern." -#: builtin.c:2557 +#: builtin.c:2598 #, c-format msgid "compl(%lf): fractional value will be truncated" msgstr "compl(%lf): Dezimalteil wird abgeschnitten." -#: builtin.c:2728 +#: builtin.c:2771 #, c-format msgid "dcgettext: `%s' is not a valid locale category" msgstr "dcgettext: '%s' ist keine gültige Locale-Kategorie." -#: eval.c:262 +#: eval.c:266 #, c-format msgid "unknown nodetype %d" msgstr "Unbekannter Knotentyp %d" -#: eval.c:310 +#: eval.c:312 msgid "buffer overflow in genflags2str" msgstr "Pufferüberlauf in genflags2str." -#: eval.c:555 +#: eval.c:647 #, fuzzy, c-format msgid "for loop: array `%s' changed size from %ld to %ld during loop execution" msgstr "" "for-Schleife: Array '%s' ändert Größse von %d zu %d innerhalb der Schleife." -#: eval.c:576 +#: eval.c:668 msgid "`break' outside a loop is not portable" msgstr "'break' außerhalb einer Schleife ist nicht portabel." -#: eval.c:580 +#: eval.c:672 msgid "`break' outside a loop is not allowed" msgstr "'break' außerhalb einer Schleife ist nicht zulässig." -#: eval.c:597 +#: eval.c:689 msgid "`continue' outside a loop is not portable" msgstr "'continue' außerhalb einer Schleife ist nicht portabel." -#: eval.c:601 +#: eval.c:693 msgid "`continue' outside a loop is not allowed" msgstr "'continue' außerhalb einer Schleife ist nicht zulässig." -#: eval.c:635 +#: eval.c:727 msgid "`next' cannot be called from a BEGIN rule" msgstr "'next' kann nicht in einer BEGIN-Regel benutzt werden." -#: eval.c:637 +#: eval.c:729 msgid "`next' cannot be called from an END rule" msgstr "'next' kann nicht in einer END-Regel benutzt werden." -#: eval.c:646 +#: eval.c:738 msgid "`nextfile' cannot be called from a BEGIN rule" msgstr "'nextfile' kann nicht in einer BEGIN-Regel benutzt werden." -#: eval.c:648 +#: eval.c:740 msgid "`nextfile' cannot be called from an END rule" msgstr "'nextfile' kann nicht in einer END-Regel benutzt werden." -#: eval.c:696 +#: eval.c:785 msgid "statement has no effect" msgstr "Anweisung hat keinen Effekt." -#: eval.c:731 eval.c:761 eval.c:1733 -#, c-format -msgid "reference to uninitialized variable `%s'" -msgstr "Referenz auf die nicht-initialisierte Variable '%s'." - -#: eval.c:739 eval.c:1721 +#: eval.c:828 eval.c:1726 #, c-format msgid "can't use function name `%s' as variable or array" msgstr "Kann Funktion '%s' nicht als Variable oder Array verwenden." -#: eval.c:746 eval.c:752 +#: eval.c:835 eval.c:841 #, c-format msgid "reference to uninitialized argument `%s'" msgstr "Referenz auf nicht-initialisiertes Argument '%s'." -#: eval.c:810 eval.c:1728 profile.c:773 +#: eval.c:848 eval.c:907 eval.c:1732 eval.c:1742 profile.c:807 #, c-format msgid "attempt to use array `%s' in a scalar context" msgstr "Versuch, das Array '%s' in Skalarkontext zu verwenden." -#: eval.c:910 +#: eval.c:858 eval.c:1752 +#, c-format +msgid "reference to uninitialized variable `%s'" +msgstr "Referenz auf die nicht-initialisierte Variable '%s'." + +#: eval.c:1007 msgid "" "concatenation: side effects in one expression have changed the length of " "another!" @@ -807,54 +828,49 @@ "Konkatenierung: Seiteneffekte in einem Ausdruck haben die Länge des anderen\n" "geändert!" -#: eval.c:935 +#: eval.c:1032 msgid "assignment used in conditional context" msgstr "Zuweisung in einer Bedingung." -#: eval.c:1026 +#: eval.c:1122 msgid "division by zero attempted" msgstr "Division durch Null versucht." -#: eval.c:1041 +#: eval.c:1137 #, c-format msgid "division by zero attempted in `%%'" msgstr "Division durch Null versucht in '%%'." -#: eval.c:1056 profile.c:649 +#: eval.c:1152 profile.c:683 #, c-format msgid "illegal type (%s) in tree_eval" msgstr "Illegaler Typ (%s) in tree_eval" -#: eval.c:1232 +#: eval.c:1328 msgid "division by zero attempted in `/='" msgstr "Division durch Null versucht in '/='." -#: eval.c:1250 +#: eval.c:1346 #, c-format msgid "division by zero attempted in `%%='" msgstr "Division durch Null versucht in '%%='." -#: eval.c:1510 -#, c-format -msgid "%s (from %s)" -msgstr "%s (von %s)" - -#: eval.c:1569 +#: eval.c:1586 #, c-format msgid "function `%s' called with more arguments than declared" msgstr "Funktion '%s' mit zu vielen Argumenten aufgerufen." -#: eval.c:1628 +#: eval.c:1633 #, c-format msgid "function `%s' not defined" msgstr "Funktion '%s' ist nicht definiert." -#: eval.c:1634 +#: eval.c:1639 #, c-format msgid "function %s called\n" msgstr "Funktion %s aufgerufen\n" -#: eval.c:1693 +#: eval.c:1698 msgid "" "\n" "\t# Function Call Stack:\n" @@ -864,47 +880,42 @@ "\t# Funktion Aufruf-Stack\n" "\n" -#: eval.c:1696 +#: eval.c:1701 msgid "\t# -- main --\n" msgstr "\t# -- main --\n" -#: eval.c:1850 +#: eval.c:1867 msgid "attempt to field reference from non-numeric value" msgstr "Nicht-numerischer Wert für Feldreferenz verwendet." -#: eval.c:1852 +#: eval.c:1869 msgid "attempt to reference from null string" msgstr "Referenz von einem Null-String" -#: eval.c:1858 +#: eval.c:1875 #, c-format msgid "attempt to access field %d" msgstr "Versuch des Zugriffs auf Feld %d." -#: eval.c:1874 -#, c-format -msgid "attempt to use scalar parameter `%s' as an array" -msgstr "Versuch den skalaren Parameter '%s' als Array zu benutzen." - -#: eval.c:1886 eval.c:1893 profile.c:865 +#: eval.c:1896 eval.c:1903 profile.c:900 msgid "assignment is not allowed to result of builtin function" msgstr "" "Zuweisungen an das Ergebnis einer eingebauten Funktion sind nicht erlaubt." -#: eval.c:1941 +#: eval.c:1951 msgid "`IGNORECASE' is a gawk extension" msgstr "'IGNORECASE' ist eine gawk-Erweiterung" -#: eval.c:1970 +#: eval.c:1980 msgid "`BINMODE' is a gawk extension" msgstr "'BINMODE' ist eine gawk-Erweiterung." -#: eval.c:2082 +#: eval.c:2092 #, c-format msgid "bad `%sFMT' specification `%s'" msgstr "Falsche '%sFMT'-Angabe '%s'" -#: eval.c:2160 +#: eval.c:2170 msgid "turning off `--lint' due to assignment to `LINT'" msgstr "'--lint' wird abgeschaltet, da 'LINT' gesetzt ist." @@ -922,32 +933,32 @@ msgid "extension: library `%s': cannot call function `%s' (%s)\n" msgstr "extension: Bibliothek '%s': kann Funktion '%s' nicht aufrufen (%s)\n" -#: ext.c:181 +#: ext.c:183 msgid "Operation Not Supported" msgstr "Operation nicht möglich." -#: field.c:321 +#: field.c:315 msgid "NF set to negative value" msgstr "" -#: field.c:819 +#: field.c:808 msgid "split: second argument is not an array" msgstr "split: Zweites Argument ist kein Array." -#: field.c:854 +#: field.c:842 msgid "split: null string for third arg is a gawk extension" msgstr "split: Null-String als drittes Argument ist eine gawk-Erweiterung." -#: field.c:906 +#: field.c:894 msgid "`FIELDWIDTHS' is a gawk extension" msgstr "'FIELDWIDTHS' ist eine gawk-Erweiterung." -#: field.c:933 +#: field.c:921 #, c-format msgid "field %d in FIELDWIDTHS, must be > 0" msgstr "Feld %d in FIELDWIDTHS muss > 0 sein." -#: field.c:1006 +#: field.c:994 msgid "null string for `FS' is a gawk extension" msgstr "Null-String für 'FS' ist eine gawk-Erweiterung." @@ -991,7 +1002,7 @@ msgid "%s: invalid option -- %c\n" msgstr "%s: Ungültige Option -- %c.\n" -#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:431 +#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:434 #, c-format msgid "%s: option requires an argument -- %c\n" msgstr "%s Option erfordert ein Argument -- %c.\n" @@ -1006,469 +1017,469 @@ msgid "%s: option `-W %s' doesn't allow an argument\n" msgstr "%s. Option '-W %s' erlaubt kein Argument.\n" -#: io.c:257 +#: io.c:305 #, c-format msgid "cannot open file `%s' for reading (%s)" msgstr "Kann Datei '%s' nicht zum Lesen öffnen (%s)." -#: io.c:344 +#: io.c:392 #, c-format msgid "close of fd %d (`%s') failed (%s)" msgstr "Schließen von Dateideskriptor %d ('%s') gescheitert (%s)." -#: io.c:482 +#: io.c:530 #, c-format msgid "invalid tree type %s in redirect()" msgstr "Ungültiger Tree-Typ %s in redirect()." -#: io.c:488 +#: io.c:536 #, c-format msgid "expression in `%s' redirection only has numeric value" msgstr "Ausdruck in '%s' Umlenkung hat nur einen numerischen Wert." -#: io.c:494 +#: io.c:542 #, c-format msgid "expression for `%s' redirection has null string value" msgstr "Ausdruck für '%s' Umlenkung ist ein leerer String." -#: io.c:499 +#: io.c:547 #, c-format msgid "filename `%s' for `%s' redirection may be result of logical expression" msgstr "" "Dateiname '%s' für '%s' Umlenkung kann Ergebnis eines logischen Ausdrucks " "sein." -#: io.c:521 +#: io.c:569 #, c-format msgid "unnecessary mixing of `>' and `>>' for file `%.*s'" msgstr "Unnötige Kombination von '>' und '>>' für Datei '%.*s'." -#: io.c:573 +#: io.c:621 #, c-format msgid "can't open pipe `%s' for output (%s)" msgstr "Kann Pipe '%s' nicht für Ausgabe öffnen (%s)." -#: io.c:582 +#: io.c:630 #, c-format msgid "can't open pipe `%s' for input (%s)" msgstr "Kann Pipe '%s' nicht für Eingabe öffnen (%s)." -#: io.c:595 +#: io.c:643 #, c-format msgid "can't open two way socket `%s' for input/output (%s)" msgstr "Kann bidirektionalen Socket '%s' nicht für Ein-/Ausgabe öffnen (%s)." -#: io.c:599 +#: io.c:647 #, c-format msgid "can't open two way pipe `%s' for input/output (%s)" msgstr "Kann bidirektionale Pipe '%s' nicht für Ein-/Ausgabe öffnen (%s)." -#: io.c:675 +#: io.c:723 #, c-format msgid "can't redirect from `%s' (%s)" msgstr "Kann nicht von '%s' umlenken (%s)." -#: io.c:678 +#: io.c:726 #, c-format msgid "can't redirect to `%s' (%s)" msgstr "Kann nicht auf '%s' umlenken (%s)." -#: io.c:717 +#: io.c:765 msgid "" "reached system limit for open files: starting to multiplex file descriptors" msgstr "" "Systemgrenze offener Dateien erreicht; beginne mit Multiplexing von " "Dateideskriptoren." -#: io.c:729 +#: io.c:777 #, c-format msgid "close of `%s' failed (%s)." msgstr "Schließen von '%s' gescheitert (%s)." -#: io.c:736 +#: io.c:784 msgid "too many pipes or input files open" msgstr "Zu viele Pipes oder Eingabedateien offen." -#: io.c:759 +#: io.c:807 msgid "close: second argument must be `to' or `from'" msgstr "close: Zweites Argument muss 'to' oder 'from' sein." -#: io.c:773 +#: io.c:821 #, c-format msgid "close: `%.*s' is not an open file, pipe or co-process" msgstr "close: '%.*s' ist keine offene Datei, Pipe oder Ko-Prozess." -#: io.c:777 +#: io.c:825 msgid "close of redirection that was never opened" msgstr "'close' für eine Umlenkung, die nie geöffnet wurde." -#: io.c:804 +#: io.c:862 #, c-format msgid "close: redirection `%s' not opened with `|&', second argument ignored" msgstr "" "close: Umlenkung '%s' nicht mit '[&' geöffnet, zweites Argument wird " "ignoriert." -#: io.c:866 +#: io.c:924 #, c-format msgid "failure status (%d) on pipe close of `%s' (%s)" msgstr "Fehlerstatus (%d) beim Schließen der Pipe '%s' (%s)." -#: io.c:869 +#: io.c:927 #, c-format msgid "failure status (%d) on file close of `%s' (%s)" msgstr "Fehlerstatus (%d) beim Schließen de rDatei '%s' (%s)." -#: io.c:888 +#: io.c:946 #, c-format msgid "no explicit close of socket `%s' provided" msgstr "Das explizite des Sockets '%s' fehlt." -#: io.c:891 +#: io.c:949 #, c-format msgid "no explicit close of co-process `%s' provided" msgstr "Das explizite Schließen des Ko-Prozesses '%s' fehlt." -#: io.c:894 +#: io.c:952 #, c-format msgid "no explicit close of pipe `%s' provided" msgstr "Das explizite Schließen der Pipe '%s' fehlt." -#: io.c:897 +#: io.c:955 #, c-format msgid "no explicit close of file `%s' provided" msgstr "Das explizite Schließen der Datei '%s' fehlt." -#: io.c:926 io.c:980 +#: io.c:984 io.c:1038 #, c-format msgid "error writing standard output (%s)" msgstr "Fehler beim Schreiben auf stdout (%s)." -#: io.c:930 io.c:984 +#: io.c:988 io.c:1042 #, c-format msgid "error writing standard error (%s)" msgstr "Fehler beim Schreiben auf stderr (%s)." -#: io.c:938 +#: io.c:996 #, c-format msgid "pipe flush of `%s' failed (%s)." msgstr "Leeren der Pipe '%s' gescheitert (%s)." -#: io.c:941 +#: io.c:999 #, c-format msgid "co-process flush of pipe to `%s' failed (%s)." msgstr "Ko-Prozess: Leeren der Pipe zu '%s' gescheitert (%s)." -#: io.c:944 +#: io.c:1002 #, c-format msgid "file flush of `%s' failed (%s)." msgstr "Flush der Datei '%s' gescheitert (%s)." -#: io.c:1103 +#: io.c:1161 msgid "/inet/raw client not ready yet, sorry" msgstr "/inet/raw Client noch nicht fertig." -#: io.c:1105 io.c:1142 +#: io.c:1163 io.c:1200 msgid "only root may use `/inet/raw'." msgstr "Nur root darf '/inet/raw' benutzen" -#: io.c:1140 +#: io.c:1198 msgid "/inet/raw server not ready yet, sorry" msgstr "'/inet/raw'-Server noch nicht fertig." -#: io.c:1230 +#: io.c:1288 #, c-format msgid "no (known) protocol supplied in special filename `%s'" msgstr "Kein bekanntes Protokoll in Dateinamen '%s' angegeben." -#: io.c:1248 +#: io.c:1306 #, c-format msgid "special file name `%s' is incomplete" msgstr "Dateiname '%s' ist unvollständig." -#: io.c:1260 +#: io.c:1318 #, c-format msgid "local port invalid in `%s'" msgstr "Lokaler Port in '%s' ist ungültig." -#: io.c:1272 +#: io.c:1330 msgid "must supply a remote hostname to `/inet'" msgstr "Sie müssen einen Rechnernamen in '/inet' angeben." -#: io.c:1287 +#: io.c:1345 msgid "must supply a remote port to `/inet'" msgstr "Sie müssen einen Port in '/inet' angeben." -#: io.c:1293 +#: io.c:1351 #, c-format msgid "remote port invalid in `%s'" msgstr "Port-Angabe in '%s' ist ungültig." -#: io.c:1303 +#: io.c:1361 msgid "TCP/IP communications are not supported" msgstr "TCP/IP-Verbindungen sind nicht möglich." -#: io.c:1312 io.c:1492 +#: io.c:1370 io.c:1551 #, c-format msgid "file `%s' is a directory" msgstr "Datei '%s' ist ein Verzeichnis." -#: io.c:1381 +#: io.c:1440 #, c-format msgid "use `PROCINFO[\"%s\"]' instead of `%s'" msgstr "Benutzen Sie 'PROCINFO[\"%s\"]' statt '%s'" -#: io.c:1413 +#: io.c:1472 msgid "use `PROCINFO[...]' instead of `/dev/user'" msgstr "Benutzen Sie 'PROCINFO[...] statt '/dev/user'." -#: io.c:1478 io.c:1652 +#: io.c:1537 io.c:1711 #, c-format msgid "could not open `%s', mode `%s'" msgstr "Konnte '%s' nicht öffnen, Mode '%s'." -#: io.c:1703 +#: io.c:1762 #, fuzzy, c-format msgid "close of master pty failed (%s)" msgstr "Schließen der Pipe gescheitert (%s)." -#: io.c:1705 io.c:1857 io.c:2009 +#: io.c:1764 io.c:1916 io.c:2068 #, c-format msgid "close of stdout in child failed (%s)" msgstr "Schließen von stdout in Kindprozess gescheitert (%s)." -#: io.c:1708 +#: io.c:1767 #, fuzzy, c-format msgid "moving slave pty to stdout in child failed (dup: %s)" msgstr "Verschieben der Pipe zu stdout in Kindprozess gescheitert (dup: %s)." -#: io.c:1710 io.c:1862 +#: io.c:1769 io.c:1921 #, c-format msgid "close of stdin in child failed (%s)" msgstr "Schließen von stdin im Kindprozess gescheitert (%s)." -#: io.c:1713 +#: io.c:1772 #, fuzzy, c-format msgid "moving slave pty to stdin in child failed (dup: %s)" msgstr "Verschieben der Pipe zu stdin in Kindprozess gescheitert (dup: %s)." -#: io.c:1715 io.c:1734 +#: io.c:1774 io.c:1793 #, fuzzy, c-format msgid "close of slave pty failed (%s)" msgstr "Schließen der Pipe gescheitert (%s)." -#: io.c:1808 io.c:1860 io.c:1990 io.c:2012 +#: io.c:1867 io.c:1919 io.c:2049 io.c:2071 #, c-format msgid "moving pipe to stdout in child failed (dup: %s)" msgstr "Verschieben der Pipe zu stdout in Kindprozess gescheitert (dup: %s)." -#: io.c:1812 io.c:1865 +#: io.c:1871 io.c:1924 #, c-format msgid "moving pipe to stdin in child failed (dup: %s)" msgstr "Verschieben der Pipe zu stdin in Kindprozess gescheitert (dup: %s)." -#: io.c:1829 io.c:2003 +#: io.c:1888 io.c:2062 msgid "restoring stdout in parent process failed\n" msgstr "" -#: io.c:1834 +#: io.c:1893 msgid "restoring stdin in parent process failed\n" msgstr "" -#: io.c:1868 io.c:2014 io.c:2025 +#: io.c:1927 io.c:2073 io.c:2084 #, c-format msgid "close of pipe failed (%s)" msgstr "Schließen der Pipe gescheitert (%s)." -#: io.c:1913 +#: io.c:1972 msgid "`|&' not supported" msgstr "'|&' nicht möglich." -#: io.c:1980 +#: io.c:2039 #, c-format msgid "cannot open pipe `%s' (%s)" msgstr "Kann Pipe '%s' nicht öffnen (%s)." -#: io.c:2021 +#: io.c:2080 #, c-format msgid "cannot create child process for `%s' (fork: %s)" msgstr "Kann Kindprozess für '%s' nicht erzeugen (fork: %s)." -#: io.c:2364 +#: io.c:2423 #, c-format msgid "data file `%s' is empty" msgstr "Datei '%s' ist leer." -#: io.c:2407 io.c:2415 +#: io.c:2466 io.c:2474 msgid "could not allocate more input memory" msgstr "" -#: io.c:2540 io.c:2782 io.c:3046 +#: io.c:2832 io.c:2895 #, c-format msgid "error reading input file `%s': %s" msgstr "Fehler beim Lesen der Eingabedatei '%s': %s." -#: io.c:3281 +#: io.c:3020 msgid "multicharacter value of `RS' is a gawk extension" msgstr "Multicharacter-Wert von 'RS' ist eine gawk-Erweiterung." -#: main.c:322 +#: main.c:324 msgid "`-m[fr]' option irrelevant in gawk" msgstr "Option '-m[fr]' ist in gawk bedeutungslos." -#: main.c:324 +#: main.c:326 msgid "-m option usage: `-m[fr] nnn'" msgstr "Anwendung der Option -m: '-m[fr] nnn'" -#: main.c:341 +#: main.c:343 #, c-format msgid "%s: option `-W %s' unrecognized, ignored\n" msgstr "%s: Option '-W %s' unbekannt, ignoriert.\n" -#: main.c:378 +#: main.c:380 msgid "empty argument to `--source' ignored" msgstr "Leeres Argument für '--source' ignoriert." -#: main.c:448 +#: main.c:451 msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'" msgstr "" "Umgebungsvariable 'POSIXLY_CORRECT' ist gesetzt: '--posix' angeschaltet." -#: main.c:453 +#: main.c:456 msgid "`--posix' overrides `--traditional'" msgstr "'--posix' hat Vorrang vor '--traditional'" -#: main.c:464 +#: main.c:467 msgid "`--posix'/`--traditional' overrides `--non-decimal-data'" msgstr "'--posix' /'--traditional' hat Vorrang vor '--non-decimal-data'." -#: main.c:468 +#: main.c:471 #, fuzzy, c-format msgid "running %s setuid root may be a security problem" msgstr "%s als setuid root auszuführen, kann zu Sicherheitsproblemen führen." -#: main.c:509 +#: main.c:512 #, fuzzy, c-format msgid "can't set binary mode on stdin (%s)" msgstr "Kann Mode für stdin nicht setzen (%s)." -#: main.c:512 +#: main.c:515 #, fuzzy, c-format msgid "can't set binary mode on stdout (%s)" msgstr "Kann Mode für stdout nicht setzen (%s)." -#: main.c:514 +#: main.c:517 #, fuzzy, c-format msgid "can't set binary mode on stderr (%s)" msgstr "Kann Mode für stderr nicht setzen (%s)." -#: main.c:544 +#: main.c:547 msgid "no program text at all!" msgstr "Kein Programmtext." -#: main.c:612 +#: main.c:620 #, c-format msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n" msgstr "Anwendung: %s [POSIX- oder GNU-Optionen] -f PROGRAM [--] Datei ...\n" -#: main.c:614 +#: main.c:622 #, c-format msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n" msgstr "Anwendung: %s [POSIX- oder GNU-Optionen] -- %cPROGRAM%c Datei ...\n" -#: main.c:619 +#: main.c:627 msgid "POSIX options:\t\tGNU long options:\n" msgstr "POSIX-Optionen\t\tGNU-Optionen (lang):\n" -#: main.c:620 +#: main.c:628 msgid "\t-f progfile\t\t--file=progfile\n" msgstr "\t-f PROGRAM\t\t--file=PROGRAM\n" -#: main.c:621 +#: main.c:629 msgid "\t-F fs\t\t\t--field-separator=fs\n" msgstr "\t-F Feldtrenner\t\t\t--field-separator=Feldtrenner\n" -#: main.c:622 +#: main.c:630 msgid "\t-v var=val\t\t--assign=var=val\n" msgstr "\t-v var=Wert\t\t--assign=var=Wert\n" -#: main.c:623 +#: main.c:631 msgid "\t-m[fr] val\n" msgstr "\t-m[fr] Wert\n" -#: main.c:624 +#: main.c:632 msgid "\t-W compat\t\t--compat\n" msgstr "\t-W compat\t\t--compat\n" -#: main.c:625 +#: main.c:633 msgid "\t-W copyleft\t\t--copyleft\n" msgstr "\t-W copyleft\t\t--copyleft\n" -#: main.c:626 +#: main.c:634 msgid "\t-W copyright\t\t--copyright\n" msgstr "\t-W copyright\t\t--copyright\n" -#: main.c:627 +#: main.c:635 msgid "\t-W dump-variables[=file]\t--dump-variables[=file]\n" msgstr "\t-W dump-variables[=Datei]\t--dump-variables[=Datei]\n" -#: main.c:628 +#: main.c:636 msgid "\t-W gen-po\t\t--gen-po\n" msgstr "\t-W gen-po\t\t--gen-po\n" -#: main.c:629 +#: main.c:637 msgid "\t-W help\t\t\t--help\n" msgstr "\t-W help\t\t\t--help\n" -#: main.c:630 +#: main.c:638 msgid "\t-W lint[=fatal]\t\t--lint[=fatal]\n" msgstr "\t-W lint[=fatal]\t\t--lint[=fatal]\n" -#: main.c:631 +#: main.c:639 msgid "\t-W lint-old\t\t--lint-old\n" msgstr "\t-W lint-old\t\t--lint-old\n" -#: main.c:632 +#: main.c:640 msgid "\t-W non-decimal-data\t--non-decimal-data\n" msgstr "\t-W non-decimal-data\t--non-decimal-data\n" -#: main.c:634 +#: main.c:642 msgid "\t-W nostalgia\t\t--nostalgia\n" msgstr "\t-W nostalgia\t\t--nostalgia\n" -#: main.c:637 +#: main.c:645 msgid "\t-W parsedebug\t\t--parsedebug\n" msgstr "\t-W parsedebug\t\t--parsedebug\n" -#: main.c:639 +#: main.c:647 msgid "\t-W profile[=file]\t--profile[=file]\n" msgstr "\t-W profile[=Datei]\t--profile[=Datei]\n" -#: main.c:640 +#: main.c:648 msgid "\t-W posix\t\t--posix\n" msgstr "\t-W posix\t\t--posix\n" -#: main.c:641 +#: main.c:649 msgid "\t-W re-interval\t\t--re-interval\n" msgstr "\t-W re-interval\t\t--re-interval\n" -#: main.c:642 +#: main.c:650 msgid "\t-W source=program-text\t--source=program-text\n" msgstr "\t-W source=Programmtext\t--source=Programmtext\n" -#: main.c:643 +#: main.c:651 msgid "\t-W traditional\t\t--traditional\n" msgstr "\t-W traditional\t\t--traditional\n" -#: main.c:644 +#: main.c:652 msgid "\t-W usage\t\t--usage\n" msgstr "\t-W usage\t\t--usage\n" -#: main.c:645 +#: main.c:653 msgid "\t-W version\t\t--version\n" msgstr "\t-W version\t\t--version\n" -#: main.c:649 +#: main.c:657 #, fuzzy msgid "" "\n" @@ -1479,21 +1490,21 @@ "den Sie im Kapitel 'Reporting Problems and Bugs' in der \n" "gedruckten Version finden.\n" -#: main.c:653 +#: main.c:661 msgid "" "gawk is a pattern scanning and processing language.\n" "By default it reads standard input and writes standard output.\n" "\n" msgstr "" -#: main.c:657 +#: main.c:665 msgid "" "Examples:\n" "\tgawk '{ sum += $1 }; END { print sum }' file\n" "\tgawk -F: '{ print $1 }' /etc/passwd\n" msgstr "" -#: main.c:669 +#: main.c:682 #, fuzzy, c-format msgid "" "Copyright (C) 1989, 1991-%d Free Software Foundation.\n" @@ -1513,7 +1524,7 @@ "spätere Version.\n" "\n" -#: main.c:677 +#: main.c:690 msgid "" "This program is distributed in the hope that it will be useful,\n" "but WITHOUT ANY WARRANTY; without even the implied warranty of\n" @@ -1527,7 +1538,7 @@ "GNU General Public License for more details.\n" "\n" -#: main.c:683 +#: main.c:696 msgid "" "You should have received a copy of the GNU General Public License\n" "along with this program; if not, write to the Free Software\n" @@ -1538,46 +1549,46 @@ "Software Foundation, Inc., 59 Temple Place - Suite 330, Boston MA 02111-" "1307, USA.\n" -#: main.c:713 +#: main.c:730 msgid "-Ft does not set FS to tab in POSIX awk" msgstr "-Ft setzt FS im POSIX-awk nicht auf Tab." -#: main.c:944 +#: main.c:956 #, c-format msgid "" "%s: `%s' argument to `-v' not in `var=value' form\n" "\n" msgstr "" -#: main.c:964 +#: main.c:976 #, c-format msgid "`%s' is not a legal variable name" msgstr "" -#: main.c:967 +#: main.c:979 #, c-format msgid "`%s' is not a variable name, looking for file `%s=%s'" msgstr "" -#: main.c:995 +#: main.c:1012 msgid "floating point exception" msgstr "Floating point exception" -#: main.c:1002 +#: main.c:1019 msgid "fatal error: internal error" msgstr "Fataler Fehler: interner Fehler" -#: main.c:1052 +#: main.c:1069 #, c-format msgid "no pre-opened fd %d" msgstr "Kein geöffneter Dateideskriptor %d" -#: main.c:1057 +#: main.c:1074 #, c-format msgid "could not pre-open /dev/null for fd %d" msgstr "Konnte /dev/null nicht für Dateideskriptor %d öffnen." -#: main.c:1080 main.c:1089 +#: main.c:1097 main.c:1106 #, c-format msgid "could not find groups: %s" msgstr "Konnte Gruppen nicht finden: %s" @@ -1598,23 +1609,23 @@ msgid "fatal: " msgstr "Fatal: " -#: node.c:59 node.c:66 node.c:75 node.c:89 node.c:116 +#: node.c:58 node.c:65 node.c:74 node.c:88 node.c:115 msgid "can't convert string to float" msgstr "Kann String nicht in Gleitkommazahl konvertieren." -#: node.c:357 +#: node.c:355 msgid "backslash at end of string" msgstr "Backslash am String-Ende." -#: node.c:544 +#: node.c:539 msgid "POSIX does not allow `\\x' escapes" msgstr "POSIX erlabut keine '\\x'-Escapes." -#: node.c:550 +#: node.c:545 msgid "no hex digits in `\\x' escape sequence" msgstr "Keine Hex-Ziffern in '\\x'-Escape." -#: node.c:584 +#: node.c:579 #, c-format msgid "escape sequence `\\%c' treated as plain `%c'" msgstr "Escape-Sequenz '\\%c' als '%c' behandelt." @@ -1629,24 +1640,21 @@ msgid "could not open `%s' for writing: %s" msgstr "Konnte '%s' nicht zum Schreiben öffnen: %s" -#: profile.c:409 -msgid "internal error: Node_var with null vname" +#: profile.c:449 +#, fuzzy, c-format +msgid "internal error: %s with null vname" msgstr "Interner Fehler: Node_var with null vname." -#: profile.c:471 +#: profile.c:512 msgid "# treated internally as `delete'" msgstr "" -#: profile.c:545 -msgid "internal error: Node_var_array with null vname" -msgstr "Interner Fehler: Node_var_array with null vname." - -#: profile.c:1127 +#: profile.c:1162 #, c-format msgid "\t# gawk profile, created %s\n" msgstr "\t# gawk-Profil, erzeugt %s\n" -#: profile.c:1130 +#: profile.c:1165 msgid "" "\t# BEGIN block(s)\n" "\n" @@ -1654,7 +1662,7 @@ "\t# BEGIN block(s)\n" "\n" -#: profile.c:1140 +#: profile.c:1175 msgid "" "\t# Rule(s)\n" "\n" @@ -1662,7 +1670,7 @@ "\t# Rule(s)\n" "\n" -#: profile.c:1146 +#: profile.c:1181 msgid "" "\t# END block(s)\n" "\n" @@ -1670,7 +1678,7 @@ "\t# END block(s)\n" "\n" -#: profile.c:1166 +#: profile.c:1201 msgid "" "\n" "\t# Functions, listed alphabetically\n" @@ -1678,7 +1686,7 @@ "\n" "\t# Functionen, alphabetisch sortiert\n" -#: profile.c:1376 +#: profile.c:1413 #, c-format msgid "unexpected type %s in prec_level" msgstr "Unerwarteter Typ %s in prec_level." @@ -1760,6 +1768,32 @@ msgid "No previous regular expression" msgstr "Kein vorangehender Regulärer Ausdruck." +#, fuzzy +#~ msgid "substr: length %g is < 0" +#~ msgstr "substr: Länge %g ist kleiner oder gleich 0." + +#~ msgid "delete: illegal use of variable `%s' as array" +#~ msgstr "delete: Benutzung der Variablen »%s« als Array ist nicht zulässig." + +#, fuzzy +#~ msgid "%s: gvar_ref to %s\n" +#~ msgstr "%s: Array-Referenz auf %s\n" + +#~ msgid "asort: first argument is not an array" +#~ msgstr "asort: Erstes Argument ist kein Array." + +#~ msgid "asort: second argument is not an array" +#~ msgstr "asort: Zweites Argument ist kein array." + +#, fuzzy +#~ msgid "" +#~ "attempt to use array parameter `%s' that was passed from global scalar `%" +#~ "s'" +#~ msgstr "Versuch den skalaren Parameter '%s' als Array zu benutzen." + +#~ msgid "internal error: Node_var_array with null vname" +#~ msgstr "Interner Fehler: Node_var_array with null vname." + #~ msgid "BEGIN blocks must have an action part" #~ msgstr "BEGIN-Blöcke müssen einen Aktionsteil haben." diff -urN gawk-3.1.2/po/en@boldquot.header gawk-3.1.3/po/en@boldquot.header --- gawk-3.1.2/po/en@boldquot.header 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/po/en@boldquot.header 2003-06-16 03:25:34.000000000 -0700 @@ -0,0 +1,25 @@ +# All this catalog "translates" are quotation characters. +# The msgids must be ASCII and therefore cannot contain real quotation +# characters, only substitutes like grave accent (0x60), apostrophe (0x27) +# and double quote (0x22). These substitutes look strange; see +# http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html +# +# This catalog translates grave accent (0x60) and apostrophe (0x27) to +# left single quotation mark (U+2018) and right single quotation mark (U+2019). +# It also translates pairs of apostrophe (0x27) to +# left single quotation mark (U+2018) and right single quotation mark (U+2019) +# and pairs of quotation mark (0x22) to +# left double quotation mark (U+201C) and right double quotation mark (U+201D). +# +# When output to an UTF-8 terminal, the quotation characters appear perfectly. +# When output to an ISO-8859-1 terminal, the single quotation marks are +# transliterated to apostrophes (by iconv in glibc 2.2 or newer) or to +# grave/acute accent (by libiconv), and the double quotation marks are +# transliterated to 0x22. +# When output to an ASCII terminal, the single quotation marks are +# transliterated to apostrophes, and the double quotation marks are +# transliterated to 0x22. +# +# This catalog furthermore displays the text between the quotation marks in +# bold face, assuming the VT100/XTerm escape sequences. +# diff -urN gawk-3.1.2/po/en@quot.header gawk-3.1.3/po/en@quot.header --- gawk-3.1.2/po/en@quot.header 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/po/en@quot.header 2003-06-16 03:25:34.000000000 -0700 @@ -0,0 +1,22 @@ +# All this catalog "translates" are quotation characters. +# The msgids must be ASCII and therefore cannot contain real quotation +# characters, only substitutes like grave accent (0x60), apostrophe (0x27) +# and double quote (0x22). These substitutes look strange; see +# http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html +# +# This catalog translates grave accent (0x60) and apostrophe (0x27) to +# left single quotation mark (U+2018) and right single quotation mark (U+2019). +# It also translates pairs of apostrophe (0x27) to +# left single quotation mark (U+2018) and right single quotation mark (U+2019) +# and pairs of quotation mark (0x22) to +# left double quotation mark (U+201C) and right double quotation mark (U+201D). +# +# When output to an UTF-8 terminal, the quotation characters appear perfectly. +# When output to an ISO-8859-1 terminal, the single quotation marks are +# transliterated to apostrophes (by iconv in glibc 2.2 or newer) or to +# grave/acute accent (by libiconv), and the double quotation marks are +# transliterated to 0x22. +# When output to an ASCII terminal, the single quotation marks are +# transliterated to apostrophes, and the double quotation marks are +# transliterated to 0x22. +# Binary files gawk-3.1.2/po/es.gmo and gawk-3.1.3/po/es.gmo differ diff -urN gawk-3.1.2/po/es.po gawk-3.1.3/po/es.po --- gawk-3.1.2/po/es.po 2003-03-19 04:25:12.000000000 -0800 +++ gawk-3.1.3/po/es.po 2003-07-07 11:20:32.000000000 -0700 @@ -1,76 +1,74 @@ -# Mensajes en español para gawk-3.1.1m. +# Mensajes en español para gawk-3.1.2g. # Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. # Cristian Othón Martínez Vera , 2001, 2002, 2003. # msgid "" msgstr "" -"Project-Id-Version: gawk 3.1.1m\n" -"POT-Creation-Date: 2003-03-19 14:25+0200\n" -"PO-Revision-Date: 2003-02-27 17:38-0600\n" +"Project-Id-Version: gawk 3.1.2g\n" +"Report-Msgid-Bugs-To: arnold@skeeve.com\n" +"POT-Creation-Date: 2003-07-07 11:20-0700\n" +"PO-Revision-Date: 2003-06-29 14:53-0500\n" "Last-Translator: Cristian Othón Martínez Vera \n" "Language-Team: Spanish \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=ISO-8859-1\n" "Content-Transfer-Encoding: 8bit\n" -#: array.c:274 array.c:309 array.c:314 eval.c:494 +#: array.c:112 +#, c-format +msgid "attempt to use scalar parameter `%s' as an array" +msgstr "se intentó usar el parámetro escalar `%s como una matriz'" + +#: array.c:113 #, c-format msgid "attempt to use scalar `%s' as array" -msgstr "se intentó usar el dato escalar `%s' como un arreglo" +msgstr "se intentó usar el dato escalar `%s' como una matriz" + +#: array.c:151 +#, c-format +msgid "from %s" +msgstr "desde %s" -#: array.c:338 +#: array.c:506 #, c-format msgid "reference to uninitialized element `%s[\"%s\"]'" msgstr "referencia al elemento sin valor inicial `%s[\"%s\"]'" -#: array.c:344 +#: array.c:512 #, c-format msgid "subscript of array `%s' is null string" msgstr "el subíndice de la matriz `%s' es la cadena nula" -#: array.c:412 array.c:425 array.c:466 +#: array.c:609 #, c-format msgid "delete: index `%s' not in array `%s'" msgstr "delete: el índice `%s' no está en la matriz `%s'" -#: array.c:432 array.c:515 -#, c-format -msgid "delete: illegal use of variable `%s' as array" -msgstr "delete: uso ilegal de la variable `%s' como una matriz" - -#: array.c:633 +#: array.c:769 #, c-format msgid "%s: empty (null)\n" msgstr "%s: vacío (nulo)\n" -#: array.c:638 +#: array.c:774 #, c-format msgid "%s: empty (zero)\n" msgstr "%s: vacío (cero)\n" -#: array.c:642 +#: array.c:778 #, c-format msgid "%s: table_size = %d, array_size = %d\n" msgstr "%s: tamaño_tabla = %d, tamaño_matriz = %d\n" -#: array.c:671 +#: array.c:807 #, c-format msgid "%s: is parameter\n" msgstr "%s: es un parámetro\n" -#: array.c:676 +#: array.c:812 #, c-format msgid "%s: array_ref to %s\n" msgstr "%s: array_ref a %s\n" -#: array.c:975 -msgid "asort: first argument is not an array" -msgstr "asort: el primer argumento no es una matriz" - -#: array.c:984 -msgid "asort: second argument is not an array" -msgstr "asort: el segundo argumento no es una matriz" - #: awkgram.y:208 #, c-format msgid "%s blocks must have an action part" @@ -92,266 +90,279 @@ "la constante de expresión regular `/%s/' parece un comentario de C, pero no " "lo es" -#: awkgram.y:340 +#: awkgram.y:340 awkgram.y:615 msgid "statement may have no effect" msgstr "la sentencia puede no tener efecto" -#: awkgram.y:431 awkgram.y:451 +#: awkgram.y:435 awkgram.y:455 #, c-format msgid "`%s' used in %s action" msgstr "se usó `%s' en la acción %s" -#: awkgram.y:444 awkgram.y:447 +#: awkgram.y:448 awkgram.y:451 msgid "`nextfile' is a gawk extension" msgstr "`nextfile' es una extensión de gawk" -#: awkgram.y:461 +#: awkgram.y:465 msgid "`return' used outside function context" msgstr "se usó `return' fuera del contexto de la función" -#: awkgram.y:500 +#: awkgram.y:504 msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'" msgstr "" "el `print' simple en la regla BEGIN o END probablemente debe ser `print \"\"'" -#: awkgram.y:513 awkgram.y:520 +#: awkgram.y:517 awkgram.y:524 msgid "`delete array' is a gawk extension" msgstr "`delete array' es una extensión de gawk" -#: awkgram.y:528 awkgram.y:535 +#: awkgram.y:532 awkgram.y:539 msgid "`delete(array)' is a non-portable tawk extension" msgstr "`delete(array)' es una extensión de gawk que no es transportable" -#: awkgram.y:578 +#: awkgram.y:583 +#, c-format +msgid "duplicate case values in switch body: %s" +msgstr "valores case duplicados en el cuerpo de un switch: %s" + +#: awkgram.y:593 +msgid "Duplicate `default' detected in switch body" +msgstr "Se detectó un `default' duplicado en el cuerpo de un switch" + +#: awkgram.y:681 msgid "multistage two-way pipelines don't work" msgstr "las líneas de trabajo de dos vías multiestado no funcionan" -#: awkgram.y:669 +#: awkgram.y:772 msgid "regular expression on right of assignment" msgstr "expresión regular del lado derecho de una asignación" -#: awkgram.y:679 +#: awkgram.y:782 msgid "regular expression on left of `~' or `!~' operator" msgstr "expresión regular a la izquierda del operador `~' o `!~'" -#: awkgram.y:687 +#: awkgram.y:790 msgid "regular expression on right of comparison" msgstr "expresión regular a la derecha de una comparación" -#: awkgram.y:754 +#: awkgram.y:857 msgid "non-redirected `getline' undefined inside END action" msgstr "`getline' no redirigido indefinido dentro de la acción de END" -#: awkgram.y:781 +#: awkgram.y:884 msgid "call of `length' without parentheses is not portable" msgstr "la llamada de `length' sin paréntesis no es transportable" -#: awkgram.y:784 +#: awkgram.y:887 msgid "call of `length' without parentheses is deprecated by POSIX" msgstr "la llamada de `length' sin paréntesis está obsoleta por POSIX" -#: awkgram.y:835 +#: awkgram.y:940 +msgid "use of non-array as array" +msgstr "uso de una matriz que no es matriz" + +#: awkgram.y:942 msgid "invalid subscript expression" msgstr "expresión de subíndice inválida" -#: awkgram.y:1020 +#: awkgram.y:1140 msgid "unexpected newline or end of string" msgstr "nueva línea o fin de la cadena inesperados" -#: awkgram.y:1115 +#: awkgram.y:1235 msgid "empty program text on command line" msgstr "texto de programa vacío en la linea de comando" -#: awkgram.y:1172 +#: awkgram.y:1292 #, c-format msgid "can't open source file `%s' for reading (%s)" msgstr "no se puede abrir el fichero fuente `%s' para lectura (%s)" -#: awkgram.y:1207 +#: awkgram.y:1327 #, c-format msgid "can't read sourcefile `%s' (%s)" msgstr "no se puede leer el fichero fuente `%s' (%s)" -#: awkgram.y:1215 +#: awkgram.y:1335 #, c-format msgid "source file `%s' is empty" msgstr "el fichero fuente `%s' está vacío" -#: awkgram.y:1417 awkgram.y:1527 awkgram.y:1545 awkgram.y:1895 awkgram.y:1980 +#: awkgram.y:1537 awkgram.y:1647 awkgram.y:1665 awkgram.y:2015 awkgram.y:2100 msgid "source file does not end in newline" msgstr "el fichero fuente no termina con línea nueva" -#: awkgram.y:1481 +#: awkgram.y:1601 msgid "unterminated regexp ends with `\\' at end of file" msgstr "expresión regular sin terminar termina con `\\` al final del fichero" -#: awkgram.y:1501 +#: awkgram.y:1621 msgid "unterminated regexp" msgstr "expresión regular sin terminar" -#: awkgram.y:1504 +#: awkgram.y:1624 msgid "unterminated regexp at end of file" msgstr "expresión regular sin terminar al final del fichero" -#: awkgram.y:1571 +#: awkgram.y:1691 msgid "use of `\\ #...' line continuation is not portable" msgstr "el uso de la continuación de línea `\\ #...' no es transportable" -#: awkgram.y:1583 +#: awkgram.y:1703 msgid "backslash not last character on line" msgstr "la barra invertida no es el último caracter en la línea" -#: awkgram.y:1628 +#: awkgram.y:1748 msgid "POSIX does not allow operator `**='" msgstr "POSIX no permite el operador `**='" -#: awkgram.y:1630 +#: awkgram.y:1750 msgid "old awk does not support operator `**='" msgstr "el awk antiguo no da soporte al operador `**='" -#: awkgram.y:1639 +#: awkgram.y:1759 msgid "POSIX does not allow operator `**'" msgstr "POSIX no permite el operador `**'" -#: awkgram.y:1641 +#: awkgram.y:1761 msgid "old awk does not support operator `**'" msgstr "el awk antiguo no da soporte al operador `**='" -#: awkgram.y:1672 +#: awkgram.y:1792 msgid "operator `^=' is not supported in old awk" msgstr "el operador `^=' no tiene soporte en el awk antiguo" -#: awkgram.y:1680 +#: awkgram.y:1800 msgid "operator `^' is not supported in old awk" msgstr "el operador `^' no tiene soporte en el awk antiguo" -#: awkgram.y:1764 awkgram.y:1781 +#: awkgram.y:1884 awkgram.y:1901 msgid "unterminated string" msgstr "cadena sin terminar" -#: awkgram.y:1941 +#: awkgram.y:2061 #, c-format msgid "invalid char '%c' in expression" msgstr "caracter '%c' inválido en la expresión" -#: awkgram.y:2001 +#: awkgram.y:2121 #, c-format msgid "`%s' is a gawk extension" msgstr "`%s' es una extensión de gawk" -#: awkgram.y:2004 +#: awkgram.y:2124 #, c-format msgid "`%s' is a Bell Labs extension" msgstr "`%s' es una extensión de Bell Labs" -#: awkgram.y:2007 +#: awkgram.y:2127 #, c-format msgid "POSIX does not allow `%s'" msgstr "POSIX no permite `%s'" -#: awkgram.y:2011 +#: awkgram.y:2131 #, c-format msgid "`%s' is not supported in old awk" msgstr "`%s' no tiene soporte en el awk antiguo" -#: awkgram.y:2038 +#: awkgram.y:2158 msgid "`goto' considered harmful!\n" msgstr "¡`goto' se considera dañino!\n" -#: awkgram.y:2102 +#: awkgram.y:2220 #, c-format msgid "%d is invalid as number of arguments for %s" msgstr "%d es inválido como número de argumentos para %s" -#: awkgram.y:2121 awkgram.y:2124 +#: awkgram.y:2239 awkgram.y:2242 msgid "match: third argument is a gawk extension" msgstr "match: el tercer argumento es una extensión de gawk" -#: awkgram.y:2137 +#: awkgram.y:2255 #, c-format msgid "%s: string literal as last arg of substitute has no effect" msgstr "" "%s: la literal de cadena como último argumento de substitute no tiene efecto" -#: awkgram.y:2140 +#: awkgram.y:2258 #, c-format msgid "%s third parameter is not a changeable object" msgstr "el tercer argumento de %s no es un objecto que se puede cambiar" -#: awkgram.y:2167 awkgram.y:2170 +#: awkgram.y:2285 awkgram.y:2288 msgid "close: second argument is a gawk extension" msgstr "close: el segundo argumento es una extensión de gawk" -#: awkgram.y:2180 +#: awkgram.y:2298 msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore" msgstr "" "el uso de dcgettext(_\"...\") es incorrecto: quite el subrayado inicial" -#: awkgram.y:2195 +#: awkgram.y:2313 msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore" msgstr "" "el uso de dcngettext(_\"...\") es incorrecto: quite el subrayado inicial" -#: awkgram.y:2266 +#: awkgram.y:2384 #, c-format msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d" msgstr "función `%s': parámetro #%d, `%s', duplica el parámetro #%d" -#: awkgram.y:2299 +#: awkgram.y:2417 #, c-format msgid "function `%s': parameter `%s' shadows global variable" msgstr "función `%s': parámetro `%s' obscurece la variable global" -#: awkgram.y:2411 +#: awkgram.y:2529 #, c-format msgid "could not open `%s' for writing (%s)" msgstr "no se puede abrir `%s' para escritura (%s)" -#: awkgram.y:2412 profile.c:93 +#: awkgram.y:2530 profile.c:93 msgid "sending profile to standard error" msgstr "enviando perfil a la salida estándar de error" -#: awkgram.y:2442 +#: awkgram.y:2562 #, c-format msgid "%s: close failed (%s)" msgstr "%s: falló close (%s)" -#: awkgram.y:2566 +#: awkgram.y:2684 msgid "shadow_funcs() called twice!" msgstr "¡shadow_funcs() llamada dos veces!" -#: awkgram.y:2593 +#: awkgram.y:2711 msgid "there were shadowed variables." msgstr "hay variables opacadas." -#: awkgram.y:2666 +#: awkgram.y:2784 #, c-format msgid "function `%s': can't use function name as parameter name" msgstr "" "función `%s': no se puede usar un nombre de función como nombre de parámetro" -#: awkgram.y:2676 +#: awkgram.y:2794 #, c-format msgid "function name `%s' previously defined" msgstr "el nombre de función `%s' se definió previamente" -#: awkgram.y:2827 awkgram.y:2833 +#: awkgram.y:2945 awkgram.y:2951 #, c-format msgid "function `%s' called but never defined" msgstr "se llamó a la función `%s' pero nunca se definió" -#: awkgram.y:2836 +#: awkgram.y:2954 #, c-format msgid "function `%s' defined but never called" msgstr "la función `%s' está definida pero nunca se llamó" -#: awkgram.y:2863 +#: awkgram.y:2981 #, c-format msgid "regexp constant for parameter #%d yields boolean value" msgstr "" "la constante de expresión regular para el parámetro #%d da un valor booleano" -#: awkgram.y:2876 +#: awkgram.y:2994 #, c-format msgid "" "function `%s' called with space between name and `(',\n" @@ -360,199 +371,204 @@ "se llamó la función `%s' con espacio entre el nombre y el `(',\n" "%s" -#: awkgram.y:2878 +#: awkgram.y:2996 msgid "or used as a variable or an array" msgstr "o se usó como una variable o una matriz" -#: builtin.c:111 +#: builtin.c:137 #, c-format msgid "%s to \"%s\" failed (%s)" msgstr "falló %s a \"%s\" (%s)" -#: builtin.c:112 +#: builtin.c:138 msgid "standard output" msgstr "salida estándar" -#: builtin.c:113 +#: builtin.c:139 msgid "reason unknown" msgstr "razón desconocida" -#: builtin.c:126 +#: builtin.c:152 msgid "exp: received non-numeric argument" msgstr "exp: se recibió un argumento que no es un número" -#: builtin.c:132 +#: builtin.c:158 #, c-format msgid "exp: argument %g is out of range" msgstr "exp: el argumento %g está fuera de rango" -#: builtin.c:190 +#: builtin.c:216 #, c-format msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing" msgstr "" "fflush: no se puede limpiar: se abrió la tubería `%s' para lectura, no para " "escritura" -#: builtin.c:193 +#: builtin.c:219 #, c-format msgid "fflush: cannot flush: file `%s' opened for reading, not writing" msgstr "" "fflush: no se puede limpiar: se abrió el fichero `%s' para lectura, no para " "escritura" -#: builtin.c:205 +#: builtin.c:231 #, c-format msgid "fflush: `%s' is not an open file, pipe or co-process" msgstr "fflush: `%s' no es un fichero abierto, tubería o co-proceso" -#: builtin.c:299 +#: builtin.c:325 msgid "index: received non-string first argument" msgstr "index: el primer argumento recibido no es una cadena" -#: builtin.c:301 +#: builtin.c:327 msgid "index: received non-string second argument" msgstr "index: el segundo argumento recibido no es una cadena" -#: builtin.c:411 +#: builtin.c:437 msgid "int: received non-numeric argument" msgstr "int: se recibió un argumento que no es un número" -#: builtin.c:428 +#: builtin.c:454 msgid "length: received non-string argument" msgstr "length: se recibió un argumento que no es una cadena" -#: builtin.c:444 +#: builtin.c:470 msgid "log: received non-numeric argument" msgstr "log: se recibió un argumento que no es un número" -#: builtin.c:447 +#: builtin.c:473 #, c-format msgid "log: received negative argument %g" msgstr "log: se recibió el argumento negativo %g" -#: builtin.c:609 builtin.c:612 +#: builtin.c:635 builtin.c:638 msgid "must use `count$' on all formats or none" msgstr "se debe utilizar `count$' en todos los formatos o en ninguno" -#: builtin.c:714 +#: builtin.c:740 msgid "`$' is not permitted in awk formats" msgstr "no se permite `$' en los formatos de awk" -#: builtin.c:720 +#: builtin.c:746 msgid "arg count with `$' must be > 0" msgstr "la cuenta de argumentos con `$' debe ser > 0" -#: builtin.c:722 +#: builtin.c:748 #, c-format msgid "arg count %ld greater than total number of supplied arguments" msgstr "" "la cuenta de argumentos %ld es mayor que el número total de argumentos " "proporcionados" -#: builtin.c:724 +#: builtin.c:750 msgid "`$' not permitted after period in format" msgstr "no se permite `$' después de un punto en el formato" -#: builtin.c:737 +#: builtin.c:763 msgid "no `$' supplied for positional field width or precision" msgstr "" "no se proporciona `$' para el ancho o la precisión del campo posicional" -#: builtin.c:795 +#: builtin.c:821 msgid "`l' is meaningless in awk formats; ignored" msgstr "`l' no tiene significado en los formatos de awk; ignorado" -#: builtin.c:799 +#: builtin.c:825 msgid "`l' is not permitted in POSIX awk formats" msgstr "no se permite `l' en los formatos POSIX de awk" -#: builtin.c:810 +#: builtin.c:836 msgid "`L' is meaningless in awk formats; ignored" msgstr "`L' no tiene significado en los formatos de awk; ignorado" -#: builtin.c:814 +#: builtin.c:840 msgid "`L' is not permitted in POSIX awk formats" msgstr "no se permite `L' en los formatos POSIX de awk" -#: builtin.c:825 +#: builtin.c:851 msgid "`h' is meaningless in awk formats; ignored" msgstr "`h' no tiene significado en los formatos de awk; ignorado" -#: builtin.c:829 +#: builtin.c:855 msgid "`h' is not permitted in POSIX awk formats" msgstr "no se permite `h' en los formatos POSIX de awk" -#: builtin.c:1078 +#: builtin.c:1055 +#, c-format +msgid "[s]printf: value %g is out of range for `%%%c' format" +msgstr "[s]printf: el valor %g está fuera del rango del formato `%%%c'" + +#: builtin.c:1108 msgid "not enough arguments to satisfy format string" msgstr "no hay suficientes argumentos para satisfacer a la cadena de formato" -#: builtin.c:1080 +#: builtin.c:1110 msgid "^ ran out for this one" msgstr "se acabó ^ para éste" -#: builtin.c:1085 +#: builtin.c:1115 msgid "[s]printf: format specifier does not have control letter" msgstr "[s]printf: el especificador de formato no tiene letras de control" -#: builtin.c:1088 +#: builtin.c:1118 msgid "too many arguments supplied for format string" msgstr "se proporcionaron demasiados argumentos para la cadena de formato" -#: builtin.c:1154 builtin.c:1157 +#: builtin.c:1184 builtin.c:1187 msgid "printf: no arguments" msgstr "printf: sin argumentos" -#: builtin.c:1181 +#: builtin.c:1211 msgid "sqrt: received non-numeric argument" msgstr "sqrt: se recibió un argumento que no es un número" -#: builtin.c:1185 +#: builtin.c:1215 #, c-format msgid "sqrt: called with negative argument %g" msgstr "sqrt: llamado con el argumento negativo %g" -#: builtin.c:1207 +#: builtin.c:1238 #, c-format msgid "substr: start index %g is invalid, using 1" msgstr "substr: el índice de inicio %g es inválido, usando 1" -#: builtin.c:1212 +#: builtin.c:1243 #, c-format msgid "substr: non-integer start index %g will be truncated" msgstr "substr: el índice de inicio no entero %g será truncado" -#: builtin.c:1231 -#, c-format -msgid "substr: length %g is <= 0" +#: builtin.c:1262 +#, fuzzy, c-format +msgid "substr: length %g is not >= 1" msgstr "substr: la longitud %g es <= 0" -#: builtin.c:1233 -#, c-format -msgid "substr: length %g is < 0" -msgstr "substr: la longitud %g es < 0" +#: builtin.c:1264 +#, fuzzy, c-format +msgid "substr: length %g is not >= 0" +msgstr "substr: la longitud %g es <= 0" -#: builtin.c:1240 +#: builtin.c:1271 #, c-format msgid "substr: non-integer length %g will be truncated" msgstr "substr: la longitud no entera %g será truncada" -#: builtin.c:1245 +#: builtin.c:1276 #, c-format msgid "substr: length %g too big for string indexing, truncating to %g" msgstr "" "substr: la longitud %g es demasiado grande para ser índice de cadena, se " "trunca a %g" -#: builtin.c:1257 +#: builtin.c:1288 msgid "substr: source string is zero length" msgstr "substr: la cadena de origen es de longitud cero" -#: builtin.c:1263 +#: builtin.c:1294 #, c-format msgid "substr: start index %g is past end of string" msgstr "substr: el índice de inicio %g está después del fin de la cadena" -#: builtin.c:1271 +#: builtin.c:1302 #, c-format msgid "" "substr: length %g at start index %g exceeds length of first argument (%lu)" @@ -560,238 +576,243 @@ "substr: la cadena %g en el índice de inicio %g excede la longitud del primer " "argumento (%lu)" -#: builtin.c:1306 +#: builtin.c:1337 msgid "strftime: received non-string first argument" msgstr "strftime: el primer argumento que se recibió no es una cadena" -#: builtin.c:1312 +#: builtin.c:1343 msgid "strftime: received empty format string" msgstr "strftime: se recibió una cadena de formato vacía" -#: builtin.c:1321 +#: builtin.c:1352 msgid "strftime: received non-numeric second argument" msgstr "strftime: el segundo argumento que se recibió no es un número" -#: builtin.c:1384 +#: builtin.c:1415 msgid "mktime: received non-string argument" msgstr "mktime: se recibió un argumento que no es una cadena" -#: builtin.c:1429 +#: builtin.c:1460 msgid "system: received non-string argument" msgstr "system: se recibió un argumento que no es una cadena" -#: builtin.c:1573 +#: builtin.c:1581 eval.c:1883 +#, c-format +msgid "reference to uninitialized field `$%d'" +msgstr "referencia al campo sin inicializar `$%d'" + +#: builtin.c:1608 msgid "tolower: received non-string argument" msgstr "tolower: se recibió un argumento que no es una cadena" -#: builtin.c:1622 +#: builtin.c:1657 msgid "toupper: received non-string argument" msgstr "toupper: se recibió un argumento que no es una cadena" -#: builtin.c:1667 +#: builtin.c:1702 msgid "atan2: received non-numeric first argument" msgstr "atan2: el primer argumento recibido no es un número" -#: builtin.c:1669 +#: builtin.c:1704 msgid "atan2: received non-numeric second argument" msgstr "atan2: el segundo argumento recibido no es un número" -#: builtin.c:1688 +#: builtin.c:1723 msgid "sin: received non-numeric argument" msgstr "sin: se recibió un argumento que no es un número" -#: builtin.c:1704 +#: builtin.c:1739 msgid "cos: received non-numeric argument" msgstr "cos: se recibió un argumento que no es un número" -#: builtin.c:1748 +#: builtin.c:1788 msgid "srand: received non-numeric argument" msgstr "srand: se recibió un argumento que no es un número" -#: builtin.c:1787 +#: builtin.c:1823 msgid "match: third argument is not an array" msgstr "match: el tercer argumento no es una matriz" -#: builtin.c:2264 -msgid "gensub: 3rd argument of 0 treated as 1" +#: builtin.c:2307 +msgid "gensub: third argument of 0 treated as 1" msgstr "gensub: el tercer argumento de 0 se trata como 1" -#: builtin.c:2375 builtin.c:2377 +#: builtin.c:2416 builtin.c:2418 msgid "lshift: received non-numeric first argument" msgstr "lshift: el primer argumento recibido no es un número" -#: builtin.c:2379 +#: builtin.c:2420 #, c-format msgid "lshift(%lf, %lf): negative values will give strange results" msgstr "lshift(%lf, %lf): los valores negativos darán resultados extraños" -#: builtin.c:2381 +#: builtin.c:2422 #, c-format msgid "lshift(%lf, %lf): fractional values will be truncated" msgstr "lshift(%lf, %lf): los valores fraccionarios serán truncados" -#: builtin.c:2383 +#: builtin.c:2424 #, c-format msgid "lshift(%lf, %lf): too large shift value will give strange results" msgstr "" "lshift(%lf, %lf): un valor de desplazamiento muy grande dará resultados " "extraños" -#: builtin.c:2412 builtin.c:2414 +#: builtin.c:2453 builtin.c:2455 msgid "rshift: received non-numeric first argument" msgstr "rshift: el primer argumento recibido no es un número" -#: builtin.c:2416 +#: builtin.c:2457 #, c-format msgid "rshift(%lf, %lf): negative values will give strange results" msgstr "rshift(%lf, %lf): los valores negativos darán resultados extraños" -#: builtin.c:2418 +#: builtin.c:2459 #, c-format msgid "rshift(%lf, %lf): fractional values will be truncated" msgstr "rshift(%lf, %lf): los valores fraccionarios serán truncados" -#: builtin.c:2420 +#: builtin.c:2461 #, c-format msgid "rshift(%lf, %lf): too large shift value will give strange results" msgstr "" "rshift(%lf, %lf): un valor de desplazamiento muy grande dará resultados " "extraños" -#: builtin.c:2449 builtin.c:2451 +#: builtin.c:2490 builtin.c:2492 msgid "and: received non-numeric first argument" msgstr "and: el primer argumento recibido no es un número" -#: builtin.c:2453 +#: builtin.c:2494 #, c-format msgid "and(%lf, %lf): negative values will give strange results" msgstr "and(%lf, %lf): los valores negativos darán resultados extraños" -#: builtin.c:2455 +#: builtin.c:2496 #, c-format msgid "and(%lf, %lf): fractional values will be truncated" msgstr "and(%lf, %lf): los valores fraccionarios serán truncados" -#: builtin.c:2484 builtin.c:2486 +#: builtin.c:2525 builtin.c:2527 msgid "or: received non-numeric first argument" msgstr "or: el primer argumento recibido no es un número" -#: builtin.c:2488 +#: builtin.c:2529 #, c-format msgid "or(%lf, %lf): negative values will give strange results" msgstr "or(%lf, %lf): los valores negativos darán resultados extraños" -#: builtin.c:2490 +#: builtin.c:2531 #, c-format msgid "or(%lf, %lf): fractional values will be truncated" msgstr "or(%lf, %lf): los valores fraccionarios serán truncados" -#: builtin.c:2519 builtin.c:2521 +#: builtin.c:2560 builtin.c:2562 msgid "xor: received non-numeric first argument" msgstr "xor: el primer argumento recibido no es un número" -#: builtin.c:2523 +#: builtin.c:2564 #, c-format msgid "xor(%lf, %lf): negative values will give strange results" msgstr "xor(%lf, %lf): los valores negativos darán resultados extraños" -#: builtin.c:2525 +#: builtin.c:2566 #, c-format msgid "xor(%lf, %lf): fractional values will be truncated" msgstr "xor(%lf, %lf): los valores fraccionarios serán truncados" -#: builtin.c:2553 +#: builtin.c:2594 msgid "compl: received non-numeric argument" msgstr "compl: se recibió un argumento que no es un número" -#: builtin.c:2555 +#: builtin.c:2596 #, c-format msgid "compl(%lf): negative value will give strange results" msgstr "compl(%lf): el valor negativo dará resultados extraños" -#: builtin.c:2557 +#: builtin.c:2598 #, c-format msgid "compl(%lf): fractional value will be truncated" msgstr "compl(%lf): el valor fraccionario será truncado" -#: builtin.c:2728 +#: builtin.c:2771 #, c-format msgid "dcgettext: `%s' is not a valid locale category" msgstr "dcgettext: `%s' no es una categoría local válida" -#: eval.c:262 +#: eval.c:266 #, c-format msgid "unknown nodetype %d" msgstr "tipo de nodo %d desconocido" -#: eval.c:310 +#: eval.c:312 msgid "buffer overflow in genflags2str" msgstr "desbordamiento de almacenamiento temporal en genflags2str" -#: eval.c:555 +#: eval.c:647 #, c-format msgid "for loop: array `%s' changed size from %ld to %ld during loop execution" msgstr "" "ciclo for: la matriz `%s' cambió de tamaño de %ld a %ld durante la ejecución " "del ciclo" -#: eval.c:576 +#: eval.c:668 msgid "`break' outside a loop is not portable" msgstr "`break' fuera de un ciclo no es transportable" -#: eval.c:580 +#: eval.c:672 msgid "`break' outside a loop is not allowed" msgstr "no se permite `break' fuera de un ciclo" -#: eval.c:597 +#: eval.c:689 msgid "`continue' outside a loop is not portable" msgstr "`continue' fuera de un ciclo no es transportable" -#: eval.c:601 +#: eval.c:693 msgid "`continue' outside a loop is not allowed" msgstr "no se permite `continue' fuera de un ciclo" -#: eval.c:635 +#: eval.c:727 msgid "`next' cannot be called from a BEGIN rule" msgstr "`next' no se puede llamar desde una regla BEGIN" -#: eval.c:637 +#: eval.c:729 msgid "`next' cannot be called from an END rule" msgstr "`next' no se puede llamar desde una regla END" -#: eval.c:646 +#: eval.c:738 msgid "`nextfile' cannot be called from a BEGIN rule" msgstr "`nextfile' no se puede llamar desde una regla BEGIN" -#: eval.c:648 +#: eval.c:740 msgid "`nextfile' cannot be called from an END rule" msgstr "`nextfile' no se puede llamar desde una regla END" -#: eval.c:696 +#: eval.c:785 msgid "statement has no effect" msgstr "la sentencia no tiene efecto" -#: eval.c:731 eval.c:761 eval.c:1733 -#, c-format -msgid "reference to uninitialized variable `%s'" -msgstr "referencia a la variable sin iniciar `%s'" - -#: eval.c:739 eval.c:1721 +#: eval.c:828 eval.c:1726 #, c-format msgid "can't use function name `%s' as variable or array" msgstr "no se puede usar el nombre de la función `%s' como variable o matriz" -#: eval.c:746 eval.c:752 +#: eval.c:835 eval.c:841 #, c-format msgid "reference to uninitialized argument `%s'" -msgstr "referencia al argumento sin iniciar `%s'" +msgstr "referencia al argumento sin inicializar `%s'" -#: eval.c:810 eval.c:1728 profile.c:773 +#: eval.c:848 eval.c:907 eval.c:1732 eval.c:1742 profile.c:807 #, c-format msgid "attempt to use array `%s' in a scalar context" msgstr "se intentó usar la matriz `%s' en un contexto escalar" -#: eval.c:910 +#: eval.c:858 eval.c:1752 +#, c-format +msgid "reference to uninitialized variable `%s'" +msgstr "referencia a la variable sin inicializar `%s'" + +#: eval.c:1007 msgid "" "concatenation: side effects in one expression have changed the length of " "another!" @@ -799,54 +820,49 @@ "concatenación: ¡Los efectos laterales en una expresión han cambiado la " "longitud de otra!" -#: eval.c:935 +#: eval.c:1032 msgid "assignment used in conditional context" msgstr "se usó una asignación en un contexto condicional" -#: eval.c:1026 +#: eval.c:1122 msgid "division by zero attempted" msgstr "se intentó una división por cero" -#: eval.c:1041 +#: eval.c:1137 #, c-format msgid "division by zero attempted in `%%'" msgstr "se intentó una división por cero en `%%'" -#: eval.c:1056 profile.c:649 +#: eval.c:1152 profile.c:683 #, c-format msgid "illegal type (%s) in tree_eval" msgstr "tipo ilegal (%s) en tree_eval" -#: eval.c:1232 +#: eval.c:1328 msgid "division by zero attempted in `/='" msgstr "se intentó una división por cero en `/='" -#: eval.c:1250 +#: eval.c:1346 #, c-format msgid "division by zero attempted in `%%='" msgstr "se intentó una división por cero en `%%='" -#: eval.c:1510 -#, c-format -msgid "%s (from %s)" -msgstr "%s (de %s)" - -#: eval.c:1569 +#: eval.c:1586 #, c-format msgid "function `%s' called with more arguments than declared" msgstr "se llamó a la función `%s' con más argumentos de los declarados" -#: eval.c:1628 +#: eval.c:1633 #, c-format msgid "function `%s' not defined" msgstr "la función `%s' no está definida" -#: eval.c:1634 +#: eval.c:1639 #, c-format msgid "function %s called\n" msgstr "se llamó a la función %s\n" -#: eval.c:1693 +#: eval.c:1698 msgid "" "\n" "\t# Function Call Stack:\n" @@ -856,46 +872,41 @@ "\t# Pila de Llamadas de Funciones:\n" "\n" -#: eval.c:1696 +#: eval.c:1701 msgid "\t# -- main --\n" msgstr "\t# -- principal --\n" -#: eval.c:1850 +#: eval.c:1867 msgid "attempt to field reference from non-numeric value" msgstr "se intentó una referencia de campo desde un valor que no es un número" -#: eval.c:1852 +#: eval.c:1869 msgid "attempt to reference from null string" msgstr "se intentó una referencia desde una cadena nula" -#: eval.c:1858 +#: eval.c:1875 #, c-format msgid "attempt to access field %d" msgstr "se intentó accesar al campo %d" -#: eval.c:1874 -#, c-format -msgid "attempt to use scalar parameter `%s' as an array" -msgstr "se intentó usar el parámetro escalar `%s como una matriz'" - -#: eval.c:1886 eval.c:1893 profile.c:865 +#: eval.c:1896 eval.c:1903 profile.c:900 msgid "assignment is not allowed to result of builtin function" msgstr "no se permite asignación como resultado de una función interna" -#: eval.c:1941 +#: eval.c:1951 msgid "`IGNORECASE' is a gawk extension" msgstr "`IGNORECASE' es una extensión de gawk" -#: eval.c:1970 +#: eval.c:1980 msgid "`BINMODE' is a gawk extension" msgstr "`BINMODE' es una extensión de gawk" -#: eval.c:2082 +#: eval.c:2092 #, c-format msgid "bad `%sFMT' specification `%s'" msgstr "especificación `%sFMT' `%s' errónea" -#: eval.c:2160 +#: eval.c:2170 msgid "turning off `--lint' due to assignment to `LINT'" msgstr "desactivando `--lint' debido a una asignación a `LINT'" @@ -914,33 +925,33 @@ msgstr "" "extension: biblioteca `%s': no se puede llamar a la función `%s' (%s)\n" -#: ext.c:181 +#: ext.c:183 msgid "Operation Not Supported" msgstr "No Se Da Soporte A La Operación" -#: field.c:321 +#: field.c:315 msgid "NF set to negative value" msgstr "NF con un valor negativo" -#: field.c:819 +#: field.c:808 msgid "split: second argument is not an array" msgstr "split: el segundo argumento no es una matriz" -#: field.c:854 +#: field.c:842 msgid "split: null string for third arg is a gawk extension" msgstr "" "split: la cadena nula para el tercer argumento es una extensión de gawk" -#: field.c:906 +#: field.c:894 msgid "`FIELDWIDTHS' is a gawk extension" msgstr "`FIELDWIDTHS' es una extensión gawk" -#: field.c:933 +#: field.c:921 #, c-format msgid "field %d in FIELDWIDTHS, must be > 0" msgstr "el campo %d en FIELDWIDTHS, debe ser > 0" -#: field.c:1006 +#: field.c:994 msgid "null string for `FS' is a gawk extension" msgstr "la cadena nula para `FS' es una extensión de gawk" @@ -984,7 +995,7 @@ msgid "%s: invalid option -- %c\n" msgstr "%s: opción inválida -- %c\n" -#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:431 +#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:434 #, c-format msgid "%s: option requires an argument -- %c\n" msgstr "%s: la opción requiere un argumento -- %c\n" @@ -999,484 +1010,484 @@ msgid "%s: option `-W %s' doesn't allow an argument\n" msgstr "%s: la opción `-W %s' no admite ningún argumento\n" -#: io.c:257 +#: io.c:305 #, c-format msgid "cannot open file `%s' for reading (%s)" msgstr "no se puede abrir el fichero `%s' para lectura (%s)" -#: io.c:344 +#: io.c:392 #, c-format msgid "close of fd %d (`%s') failed (%s)" msgstr "falló al cerrar el df %d (`%s') (%s)" -#: io.c:482 +#: io.c:530 #, c-format msgid "invalid tree type %s in redirect()" msgstr "tipo de árbol %s inválido en redirect()" -#: io.c:488 +#: io.c:536 #, c-format msgid "expression in `%s' redirection only has numeric value" msgstr "la expresión en la redirección `%s' sólo tiene un valor numérico" -#: io.c:494 +#: io.c:542 #, c-format msgid "expression for `%s' redirection has null string value" msgstr "la expresión para la redirección `%s' tiene un valor de cadena nula" -#: io.c:499 +#: io.c:547 #, c-format msgid "filename `%s' for `%s' redirection may be result of logical expression" msgstr "" "el fichero `%s' para la redirección `%s' puede ser resultado de una " "expresión lógica" -#: io.c:521 +#: io.c:569 #, c-format msgid "unnecessary mixing of `>' and `>>' for file `%.*s'" msgstr "mezcla innecesaria de `>' y `>>' para el fichero `%.*s'" -#: io.c:573 +#: io.c:621 #, c-format msgid "can't open pipe `%s' for output (%s)" msgstr "no se puede abrir la tubería `%s' para la salida (%s)" -#: io.c:582 +#: io.c:630 #, c-format msgid "can't open pipe `%s' for input (%s)" msgstr "no se puede abrir la tubería `%s' para la entrada (%s)" -#: io.c:595 +#: io.c:643 #, c-format msgid "can't open two way socket `%s' for input/output (%s)" msgstr "" "no se puede abrir el `socket' de dos vías `%s' para entrada/salida (%s)" -#: io.c:599 +#: io.c:647 #, c-format msgid "can't open two way pipe `%s' for input/output (%s)" msgstr "no se puede abrir la tubería de dos vías `%s' para entrada/salida (%s)" -#: io.c:675 +#: io.c:723 #, c-format msgid "can't redirect from `%s' (%s)" msgstr "no se puede redirigir desde `%s' (%s)" -#: io.c:678 +#: io.c:726 #, c-format msgid "can't redirect to `%s' (%s)" msgstr "no se puede redirigir a `%s' (%s)" -#: io.c:717 +#: io.c:765 msgid "" "reached system limit for open files: starting to multiplex file descriptors" msgstr "" "se alcanzó el límite del sistema para ficheros abiertos: comenzando a " "multiplexar los descriptores de fichero" -#: io.c:729 +#: io.c:777 #, c-format msgid "close of `%s' failed (%s)." msgstr "falló al cerrar `%s' (%s)." -#: io.c:736 +#: io.c:784 msgid "too many pipes or input files open" msgstr "demasiadas tuberías o ficheros de entrada abiertos" -#: io.c:759 +#: io.c:807 msgid "close: second argument must be `to' or `from'" msgstr "close: el segundo argumento debe ser `to' o `from'" -#: io.c:773 +#: io.c:821 #, c-format msgid "close: `%.*s' is not an open file, pipe or co-process" msgstr "close: `%.*s' no es un fichero abierto, tubería o co-proceso" -#: io.c:777 +#: io.c:825 msgid "close of redirection that was never opened" msgstr "cerrado de una redirección que nunca fue abierta" -#: io.c:804 +#: io.c:862 #, c-format msgid "close: redirection `%s' not opened with `|&', second argument ignored" msgstr "" "close: la redirección `%s' no se abre con `|&', se ignoró el segundo " "argumento" -#: io.c:866 +#: io.c:924 #, c-format msgid "failure status (%d) on pipe close of `%s' (%s)" msgstr "estado de fallo (%d) al cerrar la tubería de `%s' (%s)" -#: io.c:869 +#: io.c:927 #, c-format msgid "failure status (%d) on file close of `%s' (%s)" msgstr "estado de fallo (%d) al cerrar el fichero de `%s' (%s)" -#: io.c:888 +#: io.c:946 #, c-format msgid "no explicit close of socket `%s' provided" msgstr "no se provee el cerrado explícito del `socket' `%s'" -#: io.c:891 +#: io.c:949 #, c-format msgid "no explicit close of co-process `%s' provided" msgstr "no se provee el cerrado explícito del co-proceso `%s'" -#: io.c:894 +#: io.c:952 #, c-format msgid "no explicit close of pipe `%s' provided" msgstr "no se provee el cerrado explícito del la tubería `%s'" -#: io.c:897 +#: io.c:955 #, c-format msgid "no explicit close of file `%s' provided" msgstr "no se provee el cerrado explícito del fichero `%s'" -#: io.c:926 io.c:980 +#: io.c:984 io.c:1038 #, c-format msgid "error writing standard output (%s)" msgstr "error al escribir en la salida estándar (%s)" -#: io.c:930 io.c:984 +#: io.c:988 io.c:1042 #, c-format msgid "error writing standard error (%s)" msgstr "error al escribir en la salida estándar de error (%s)" -#: io.c:938 +#: io.c:996 #, c-format msgid "pipe flush of `%s' failed (%s)." msgstr "falló la limpieza de la tubería de `%s' (%s)." -#: io.c:941 +#: io.c:999 #, c-format msgid "co-process flush of pipe to `%s' failed (%s)." msgstr "falló la limpieza del co-proceso de la tubería a `%s' (%s)." -#: io.c:944 +#: io.c:1002 #, c-format msgid "file flush of `%s' failed (%s)." msgstr "falló la limpieza del fichero de `%s' (%s)." -#: io.c:1103 +#: io.c:1161 msgid "/inet/raw client not ready yet, sorry" msgstr "el cliente /inet/raw no está listo aún, perdón" -#: io.c:1105 io.c:1142 +#: io.c:1163 io.c:1200 msgid "only root may use `/inet/raw'." msgstr "sólo root puede utilizar `/inet/raw'." -#: io.c:1140 +#: io.c:1198 msgid "/inet/raw server not ready yet, sorry" msgstr "el servidor /inet/raw no está listo aún, perdón" -#: io.c:1230 +#: io.c:1288 #, c-format msgid "no (known) protocol supplied in special filename `%s'" msgstr "" "no se proporciona algún protocolo (conocido) en el nombre de fichero " "especial `%s'" -#: io.c:1248 +#: io.c:1306 #, c-format msgid "special file name `%s' is incomplete" msgstr "el nombre de fichero especial `%s' está incompleto" -#: io.c:1260 +#: io.c:1318 #, c-format msgid "local port invalid in `%s'" msgstr "puerto local inválido en `%s'" -#: io.c:1272 +#: io.c:1330 msgid "must supply a remote hostname to `/inet'" msgstr "se debe proporcionar a `/inet' un nombre de anfitrión remoto" -#: io.c:1287 +#: io.c:1345 msgid "must supply a remote port to `/inet'" msgstr "se debe proporcionar a `/inet' un puerto remoto" -#: io.c:1293 +#: io.c:1351 #, c-format msgid "remote port invalid in `%s'" msgstr "puerto remoto inválido en `%s'" -#: io.c:1303 +#: io.c:1361 msgid "TCP/IP communications are not supported" msgstr "No tienen soporte las comunicaciones TCP/IP" -#: io.c:1312 io.c:1492 +#: io.c:1370 io.c:1551 #, c-format msgid "file `%s' is a directory" msgstr "el fichero `%s' es un directorio" -#: io.c:1381 +#: io.c:1440 #, c-format msgid "use `PROCINFO[\"%s\"]' instead of `%s'" msgstr "use `PROCINFO[\"%s\"]' en lugar de `%s'" -#: io.c:1413 +#: io.c:1472 msgid "use `PROCINFO[...]' instead of `/dev/user'" msgstr "use `PROCINFO[...]' en lugar de `/dev/user'" -#: io.c:1478 io.c:1652 +#: io.c:1537 io.c:1711 #, c-format msgid "could not open `%s', mode `%s'" msgstr "no se puede abrir `%s', modo `%s'" -#: io.c:1703 +#: io.c:1762 #, c-format msgid "close of master pty failed (%s)" msgstr "falló al cerrar el pty maestro (%s)" -#: io.c:1705 io.c:1857 io.c:2009 +#: io.c:1764 io.c:1916 io.c:2068 #, c-format msgid "close of stdout in child failed (%s)" msgstr "falló al cerrar la salida estándar en el hijo (%s)" -#: io.c:1708 +#: io.c:1767 #, c-format msgid "moving slave pty to stdout in child failed (dup: %s)" msgstr "" "falló el movimiento del pty esclavo a la salida estándar en el hijo (dup: %s)" -#: io.c:1710 io.c:1862 +#: io.c:1769 io.c:1921 #, c-format msgid "close of stdin in child failed (%s)" msgstr "falló al cerrar la entrada estándar en el hijo (%s)" -#: io.c:1713 +#: io.c:1772 #, c-format msgid "moving slave pty to stdin in child failed (dup: %s)" msgstr "" "falló el movimiento del pty esclavo a la entrada estándar en el hijo (dup: %" "s)" -#: io.c:1715 io.c:1734 +#: io.c:1774 io.c:1793 #, c-format msgid "close of slave pty failed (%s)" msgstr "falló al cerrar el pty esclavo (%s)" -#: io.c:1808 io.c:1860 io.c:1990 io.c:2012 +#: io.c:1867 io.c:1919 io.c:2049 io.c:2071 #, c-format msgid "moving pipe to stdout in child failed (dup: %s)" msgstr "falló el movimiento a la salida estándar en el hijo (dup: %s)" -#: io.c:1812 io.c:1865 +#: io.c:1871 io.c:1924 #, c-format msgid "moving pipe to stdin in child failed (dup: %s)" msgstr "" "falló el movimiento de la tubería a la entrada estándar en el hijo (dup: %s)" -#: io.c:1829 io.c:2003 +#: io.c:1888 io.c:2062 msgid "restoring stdout in parent process failed\n" msgstr "falló la restauración de la salida estándar en el proceso padre\n" -#: io.c:1834 +#: io.c:1893 msgid "restoring stdin in parent process failed\n" msgstr "falló la restauración de la entrada estándar en el proceso padre\n" -#: io.c:1868 io.c:2014 io.c:2025 +#: io.c:1927 io.c:2073 io.c:2084 #, c-format msgid "close of pipe failed (%s)" msgstr "falló al cerrar la tubería (%s)" -#: io.c:1913 +#: io.c:1972 msgid "`|&' not supported" msgstr "`|&' no tiene soporte" -#: io.c:1980 +#: io.c:2039 #, c-format msgid "cannot open pipe `%s' (%s)" msgstr "no se puede abrir la tubería `%s' (%s)" -#: io.c:2021 +#: io.c:2080 #, c-format msgid "cannot create child process for `%s' (fork: %s)" msgstr "no se puede crear el proceso hijo para `%s' (fork: %s)" -#: io.c:2364 +#: io.c:2423 #, c-format msgid "data file `%s' is empty" msgstr "el fichero de datos `%s' está vacío" -#: io.c:2407 io.c:2415 +#: io.c:2466 io.c:2474 msgid "could not allocate more input memory" msgstr "no se puede reservar más memoria de entrada" -#: io.c:2540 io.c:2782 io.c:3046 +#: io.c:2832 io.c:2895 #, c-format msgid "error reading input file `%s': %s" msgstr "error al leer el fichero de entrada `%s': %s" -#: io.c:3281 +#: io.c:3020 msgid "multicharacter value of `RS' is a gawk extension" msgstr "el valor multicaracter de `RS' es una extensión de gawk" -#: main.c:322 +#: main.c:324 msgid "`-m[fr]' option irrelevant in gawk" msgstr "la opción -m[fr] es irrelevante en gawk" -#: main.c:324 +#: main.c:326 msgid "-m option usage: `-m[fr] nnn'" msgstr "uso de la opción -m: `-m[fr]' nnn" -#: main.c:341 +#: main.c:343 #, c-format msgid "%s: option `-W %s' unrecognized, ignored\n" msgstr "%s: no se reconoce la opción `-W %s', se ignora\n" -#: main.c:378 +#: main.c:380 msgid "empty argument to `--source' ignored" msgstr "se ignora el argumento vacío para `--source'" -#: main.c:448 +#: main.c:451 msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'" msgstr "" "la variable de ambiente `POSIXLY_CORRECT' está establecida: activando `--" "posix'" -#: main.c:453 +#: main.c:456 msgid "`--posix' overrides `--traditional'" msgstr "`--posix' se impone a `--traditional'" -#: main.c:464 +#: main.c:467 msgid "`--posix'/`--traditional' overrides `--non-decimal-data'" msgstr "`--posix'/`--traditional' se imponen a `--non-decimal-data'" -#: main.c:468 +#: main.c:471 #, c-format msgid "running %s setuid root may be a security problem" msgstr "ejecutar %s como setuid root puede ser un problema de seguridad" -#: main.c:509 +#: main.c:512 #, c-format msgid "can't set binary mode on stdin (%s)" msgstr "no se puede establecer el modo binario en la entrada estándar (%s)" -#: main.c:512 +#: main.c:515 #, c-format msgid "can't set binary mode on stdout (%s)" msgstr "no se puede establecer el modo binario en la salida estándar (%s)" -#: main.c:514 +#: main.c:517 #, c-format msgid "can't set binary mode on stderr (%s)" msgstr "" "no se puede establecer el modo binario en la salida estándar de error (%s)" -#: main.c:544 +#: main.c:547 msgid "no program text at all!" msgstr "¡No hay ningún programa de texto!" -#: main.c:612 +#: main.c:620 #, c-format msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n" msgstr "" "Modo de empleo: %s [opciones estilo POSIX o GNU] -f fichprog [--] " "fichero ...\n" -#: main.c:614 +#: main.c:622 #, c-format msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n" msgstr "" "Modo de empleo: %s [opciones estilo POSIX o GNU] [--] %cprograma%c " "fichero ...\n" -#: main.c:619 +#: main.c:627 msgid "POSIX options:\t\tGNU long options:\n" msgstr "Opciones POSIX:\t\tOpciones largas GNU:\n" -#: main.c:620 +#: main.c:628 msgid "\t-f progfile\t\t--file=progfile\n" msgstr "\t-f fichprog\t\t--file=fichprog\n" -#: main.c:621 +#: main.c:629 msgid "\t-F fs\t\t\t--field-separator=fs\n" msgstr "\t-F sc\t\t\t--field-separator=sc\n" -#: main.c:622 +#: main.c:630 msgid "\t-v var=val\t\t--assign=var=val\n" msgstr "\t-v var=valor\t\t--assign=var=valor\n" -#: main.c:623 +#: main.c:631 msgid "\t-m[fr] val\n" msgstr "\t-m[fr] valor\n" -#: main.c:624 +#: main.c:632 msgid "\t-W compat\t\t--compat\n" msgstr "\t-W compat\t\t--compat\n" -#: main.c:625 +#: main.c:633 msgid "\t-W copyleft\t\t--copyleft\n" msgstr "\t-W copyleft\t\t--copyleft\n" -#: main.c:626 +#: main.c:634 msgid "\t-W copyright\t\t--copyright\n" msgstr "\t-W copyright\t\t--copyright\n" -#: main.c:627 +#: main.c:635 msgid "\t-W dump-variables[=file]\t--dump-variables[=file]\n" msgstr "\t-W dump-variables[=fichero]\t--dump-variables[=fichero]\n" -#: main.c:628 +#: main.c:636 msgid "\t-W gen-po\t\t--gen-po\n" msgstr "\t-W gen-po\t\t--gen-po\n" -#: main.c:629 +#: main.c:637 msgid "\t-W help\t\t\t--help\n" msgstr "\t-W help\t\t\t--help\n" -#: main.c:630 +#: main.c:638 msgid "\t-W lint[=fatal]\t\t--lint[=fatal]\n" msgstr "\t-W lint[=fatal]\t\t--lint[=fatal]\n" -#: main.c:631 +#: main.c:639 msgid "\t-W lint-old\t\t--lint-old\n" msgstr "\t-W lint-old\t\t--lint-old\n" -#: main.c:632 +#: main.c:640 msgid "\t-W non-decimal-data\t--non-decimal-data\n" msgstr "\t-W non-decimal-data\t--non-decimal-data\n" -#: main.c:634 +#: main.c:642 msgid "\t-W nostalgia\t\t--nostalgia\n" msgstr "\t-W nostalgia\t\t--nostalgia\n" -#: main.c:637 +#: main.c:645 msgid "\t-W parsedebug\t\t--parsedebug\n" msgstr "\t-W parsedebug\t\t--parsedebug\n" -#: main.c:639 +#: main.c:647 msgid "\t-W profile[=file]\t--profile[=file]\n" msgstr "\t-W profile[=fichero]\t--profile[=fichero]\n" -#: main.c:640 +#: main.c:648 msgid "\t-W posix\t\t--posix\n" msgstr "\t-W posix\t\t--posix\n" -#: main.c:641 +#: main.c:649 msgid "\t-W re-interval\t\t--re-interval\n" msgstr "\t-W re-interval\t\t--re-interval\n" # Esta es la línea más larga de la lista de argumentos. # Probar con gawk para revisar tabuladores. cfuga -#: main.c:642 +#: main.c:650 msgid "\t-W source=program-text\t--source=program-text\n" msgstr "\t-W source=texto-prog\t--source=texto-prog\n" -#: main.c:643 +#: main.c:651 msgid "\t-W traditional\t\t--traditional\n" msgstr "\t-W traditional\t\t--traditional\n" -#: main.c:644 +#: main.c:652 msgid "\t-W usage\t\t--usage\n" msgstr "\t-W usage\t\t--usage\n" -#: main.c:645 +#: main.c:653 msgid "\t-W version\t\t--version\n" msgstr "\t-W version\t\t--version\n" -#: main.c:649 +#: main.c:657 msgid "" "\n" "To report bugs, see node `Bugs' in `gawk.info', which is\n" @@ -1489,7 +1500,7 @@ "impresa.\n" "\n" -#: main.c:653 +#: main.c:661 msgid "" "gawk is a pattern scanning and processing language.\n" "By default it reads standard input and writes standard output.\n" @@ -1499,7 +1510,7 @@ "Por omisión lee la entrada estándar y escribe en la salida estándar.\n" "\n" -#: main.c:657 +#: main.c:665 msgid "" "Examples:\n" "\tgawk '{ sum += $1 }; END { print sum }' file\n" @@ -1509,7 +1520,7 @@ "\tgawk '{ sum += $1 }; END { print sum }' fichero\n" "\tgawk -F: '{ print $1 }' /etc/passwd\n" -#: main.c:669 +#: main.c:682 #, c-format msgid "" "Copyright (C) 1989, 1991-%d Free Software Foundation.\n" @@ -1529,7 +1540,7 @@ "(a su elección) cualquier versión posterior.\n" "\n" -#: main.c:677 +#: main.c:690 msgid "" "This program is distributed in the hope that it will be useful,\n" "but WITHOUT ANY WARRANTY; without even the implied warranty of\n" @@ -1543,7 +1554,7 @@ "Licencia Pública General de GNU para más detalles.\n" "\n" -#: main.c:683 +#: main.c:696 msgid "" "You should have received a copy of the GNU General Public License\n" "along with this program; if not, write to the Free Software\n" @@ -1553,11 +1564,11 @@ "junto con este programa; si no es así, escriba a la Free Software\n" "Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n" -#: main.c:713 +#: main.c:730 msgid "-Ft does not set FS to tab in POSIX awk" msgstr "-Ft no establece FS a tabulador en el awk de POSIX" -#: main.c:944 +#: main.c:956 #, c-format msgid "" "%s: `%s' argument to `-v' not in `var=value' form\n" @@ -1566,35 +1577,35 @@ "%s: el argumento `%s' para `-v' no es de la forma `var=valor'\n" "\n" -#: main.c:964 +#: main.c:976 #, c-format msgid "`%s' is not a legal variable name" msgstr "`%s' no es un nombre de variable legal" -#: main.c:967 +#: main.c:979 #, c-format msgid "`%s' is not a variable name, looking for file `%s=%s'" msgstr "`%s' no es un nombre de variable, se busca el fichero `%s=%s'" -#: main.c:995 +#: main.c:1012 msgid "floating point exception" msgstr "excepción de coma flotante" -#: main.c:1002 +#: main.c:1019 msgid "fatal error: internal error" msgstr "error fatal: error interno" -#: main.c:1052 +#: main.c:1069 #, c-format msgid "no pre-opened fd %d" msgstr "no existe el df %d abierto previamente" -#: main.c:1057 +#: main.c:1074 #, c-format msgid "could not pre-open /dev/null for fd %d" msgstr "no se puede abrir previamente /dev/null para el df %d" -#: main.c:1080 main.c:1089 +#: main.c:1097 main.c:1106 #, c-format msgid "could not find groups: %s" msgstr "no se pueden encontrar los grupos: %s" @@ -1615,23 +1626,23 @@ msgid "fatal: " msgstr "fatal: " -#: node.c:59 node.c:66 node.c:75 node.c:89 node.c:116 +#: node.c:58 node.c:65 node.c:74 node.c:88 node.c:115 msgid "can't convert string to float" msgstr "no se puede convertir una cadena a coma flotante" -#: node.c:357 +#: node.c:355 msgid "backslash at end of string" msgstr "barra invertida al final de la cadena" -#: node.c:544 +#: node.c:539 msgid "POSIX does not allow `\\x' escapes" msgstr "POSIX no permite escapes `\\x'" -#: node.c:550 +#: node.c:545 msgid "no hex digits in `\\x' escape sequence" msgstr "no hay dígitos hexadecimales en la secuencia de escape `\\x'" -#: node.c:584 +#: node.c:579 #, c-format msgid "escape sequence `\\%c' treated as plain `%c'" msgstr "la secuencia de escape `\\%c' tratada como una simple `%c'" @@ -1646,24 +1657,21 @@ msgid "could not open `%s' for writing: %s" msgstr "no se puede abrir `%s' para escritura: %s" -#: profile.c:409 -msgid "internal error: Node_var with null vname" -msgstr "error interno: Node_var con vname nulo" +#: profile.c:449 +#, c-format +msgid "internal error: %s with null vname" +msgstr "error interno: %s con vname nulo" -#: profile.c:471 +#: profile.c:512 msgid "# treated internally as `delete'" msgstr "# se trata internamente como `delete'" -#: profile.c:545 -msgid "internal error: Node_var_array with null vname" -msgstr "error interno: Node_var_array con vname nulo" - -#: profile.c:1127 +#: profile.c:1162 #, c-format msgid "\t# gawk profile, created %s\n" msgstr "\t# perfil de gawk, creado %s\n" -#: profile.c:1130 +#: profile.c:1165 msgid "" "\t# BEGIN block(s)\n" "\n" @@ -1671,7 +1679,7 @@ "\t# bloque(s) BEGIN\n" "\n" -#: profile.c:1140 +#: profile.c:1175 msgid "" "\t# Rule(s)\n" "\n" @@ -1679,7 +1687,7 @@ "\t# Regla(s)\n" "\n" -#: profile.c:1146 +#: profile.c:1181 msgid "" "\t# END block(s)\n" "\n" @@ -1687,7 +1695,7 @@ "\t# bloque(s) END\n" "\n" -#: profile.c:1166 +#: profile.c:1201 msgid "" "\n" "\t# Functions, listed alphabetically\n" @@ -1695,7 +1703,7 @@ "\n" "\t# Funciones, enumeradas alfabéticamente\n" -#: profile.c:1376 +#: profile.c:1413 #, c-format msgid "unexpected type %s in prec_level" msgstr "tipo %s inesperado en prec_level" @@ -1779,6 +1787,21 @@ msgid "No previous regular expression" msgstr "No hay una expresión regular previa" +#~ msgid "substr: length %g is < 0" +#~ msgstr "substr: la longitud %g es < 0" + +#~ msgid "delete: illegal use of variable `%s' as array" +#~ msgstr "delete: uso ilegal de la variable `%s' como una matriz" + +#~ msgid "asort: first argument is not an array" +#~ msgstr "asort: el primer argumento no es una matriz" + +#~ msgid "asort: second argument is not an array" +#~ msgstr "asort: el segundo argumento no es una matriz" + +#~ msgid "internal error: Node_var_array with null vname" +#~ msgstr "error interno: Node_var_array con vname nulo" + #~ msgid "invalid syntax in name `%s' for variable assignment" #~ msgstr "sintaxis inválida en el nombre `%s' para la asignación de variable" Binary files gawk-3.1.2/po/fr.gmo and gawk-3.1.3/po/fr.gmo differ diff -urN gawk-3.1.2/po/fr.po gawk-3.1.3/po/fr.po --- gawk-3.1.2/po/fr.po 2003-03-19 04:25:12.000000000 -0800 +++ gawk-3.1.3/po/fr.po 2003-07-07 11:20:33.000000000 -0700 @@ -4,73 +4,72 @@ # msgid "" msgstr "" -"Project-Id-Version: gawk 3.1.1m\n" -"POT-Creation-Date: 2003-03-19 14:25+0200\n" -"PO-Revision-Date: 2003-02-28 08:00-0500\n" +"Project-Id-Version: gawk 3.1.2g\n" +"Report-Msgid-Bugs-To: arnold@skeeve.com\n" +"POT-Creation-Date: 2003-07-07 11:20-0700\n" +"PO-Revision-Date: 2003-06-26 08:00-0500\n" "Last-Translator: Michel Robitaille \n" "Language-Team: French \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=ISO-8859-1\n" "Content-Transfer-Encoding: 8bit\n" -#: array.c:274 array.c:309 array.c:314 eval.c:494 +#: array.c:112 +#, c-format +msgid "attempt to use scalar parameter `%s' as an array" +msgstr "" +"tentative d'utilisation d'un paramètre scalaire « %s » comme un tableau" + +#: array.c:113 #, c-format msgid "attempt to use scalar `%s' as array" msgstr "tentative d'utilisation du scalaire « %s » comme un tableau" -#: array.c:338 +#: array.c:151 +#, c-format +msgid "from %s" +msgstr "de %s" + +#: array.c:506 #, c-format msgid "reference to uninitialized element `%s[\"%s\"]'" msgstr "référence à un élément non initialisé « %s[\"%s\"] »" -#: array.c:344 +#: array.c:512 #, c-format msgid "subscript of array `%s' is null string" msgstr "sous-description du tableau « %s » contient une chaîne nulle" -#: array.c:412 array.c:425 array.c:466 +#: array.c:609 #, c-format msgid "delete: index `%s' not in array `%s'" msgstr "destruction: index « %s » n'est pas dans le tableau « %s »" -#: array.c:432 array.c:515 -#, c-format -msgid "delete: illegal use of variable `%s' as array" -msgstr "destruction: utilisation illégale d'une variable « %s » comme tableau" - -#: array.c:633 +#: array.c:769 #, c-format msgid "%s: empty (null)\n" msgstr "%s: vide (null)\n" -#: array.c:638 +#: array.c:774 #, c-format msgid "%s: empty (zero)\n" msgstr "%s: vide (zéro)\n" -#: array.c:642 +#: array.c:778 #, c-format msgid "%s: table_size = %d, array_size = %d\n" msgstr "%s: table_size = %d, array_size = %d\n" -#: array.c:671 +#: array.c:807 #, c-format msgid "%s: is parameter\n" msgstr "%s: est un paramètre\n" -#: array.c:676 +#: array.c:812 #, c-format msgid "%s: array_ref to %s\n" msgstr "%s: array_ref de %s\n" -#: array.c:975 -msgid "asort: first argument is not an array" -msgstr "asort(): le premier argument fourni n'est pas dans le tableau" - -#: array.c:984 -msgid "asort: second argument is not an array" -msgstr "asort(): le second argument fourni n'est pas dans le tableau" - #: awkgram.y:208 #, c-format msgid "%s blocks must have an action part" @@ -92,272 +91,285 @@ "la constante d'expression régulière « /%s/ » ressemble à un commentaire en " "C, mais ne l'est pas" -#: awkgram.y:340 +#: awkgram.y:340 awkgram.y:615 msgid "statement may have no effect" msgstr "la déclaration peut n'avoir aucun effet" -#: awkgram.y:431 awkgram.y:451 +#: awkgram.y:435 awkgram.y:455 #, c-format msgid "`%s' used in %s action" msgstr "« %s » utilisé dans l'action %s" -#: awkgram.y:444 awkgram.y:447 +#: awkgram.y:448 awkgram.y:451 msgid "`nextfile' is a gawk extension" msgstr "« nextfile » est une extension de gawk" -#: awkgram.y:461 +#: awkgram.y:465 msgid "`return' used outside function context" msgstr "« return » utilisé en dehors du contexte d'une fonction" -#: awkgram.y:500 +#: awkgram.y:504 msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'" msgstr "" "utilisation de « print » dans une règle BEGIN ou END doit être probablement " "« print \"\" »" -#: awkgram.y:513 awkgram.y:520 +#: awkgram.y:517 awkgram.y:524 msgid "`delete array' is a gawk extension" msgstr "« delete array » est une extension de gawk" -#: awkgram.y:528 awkgram.y:535 +#: awkgram.y:532 awkgram.y:539 msgid "`delete(array)' is a non-portable tawk extension" msgstr "« delete(array) » est une extension tawk non portable" -#: awkgram.y:578 +#: awkgram.y:583 +#, c-format +msgid "duplicate case values in switch body: %s" +msgstr "valeur de case en double dans le corp du switch: %s" + +#: awkgram.y:593 +msgid "Duplicate `default' detected in switch body" +msgstr "Double « default » détecté dans le corps du switch" + +#: awkgram.y:681 msgid "multistage two-way pipelines don't work" msgstr "pipelines bidirectionnel à multi-étapes ne fonctionnent pas" -#: awkgram.y:669 +#: awkgram.y:772 msgid "regular expression on right of assignment" msgstr "expression régulière à la droite de l'affectation" -#: awkgram.y:679 +#: awkgram.y:782 msgid "regular expression on left of `~' or `!~' operator" msgstr "expression régulière sur la gauche de l'opérateur « ~ » ou « !~ »" -#: awkgram.y:687 +#: awkgram.y:790 msgid "regular expression on right of comparison" msgstr "expression régulière sur la droite de la comparaison" -#: awkgram.y:754 +#: awkgram.y:857 msgid "non-redirected `getline' undefined inside END action" msgstr "« getline » non redirigé indéfini à l'intérieur de l'action END" -#: awkgram.y:781 +#: awkgram.y:884 msgid "call of `length' without parentheses is not portable" msgstr "l'appel de « length » sans les parenthèses n'est pas portable" -#: awkgram.y:784 +#: awkgram.y:887 msgid "call of `length' without parentheses is deprecated by POSIX" msgstr "l'appel de « length » sans les parenthèses est déprécié par POSIX" -#: awkgram.y:835 +#: awkgram.y:940 +msgid "use of non-array as array" +msgstr "utilisation d'un non-tableau comme tableau" + +#: awkgram.y:942 msgid "invalid subscript expression" msgstr "sous-expression invalide" -#: awkgram.y:1020 +#: awkgram.y:1140 msgid "unexpected newline or end of string" msgstr "nouvelle ligne inattendue ou fin de chaîne" -#: awkgram.y:1115 +#: awkgram.y:1235 msgid "empty program text on command line" msgstr "texte du programme sur la ligne de commande est vide" -#: awkgram.y:1172 +#: awkgram.y:1292 #, c-format msgid "can't open source file `%s' for reading (%s)" msgstr "ne peut ouvrir le fichier source « %s » pour lecture (%s)" -#: awkgram.y:1207 +#: awkgram.y:1327 #, c-format msgid "can't read sourcefile `%s' (%s)" msgstr "ne peut lire le fichier source « %s » (%s)" -#: awkgram.y:1215 +#: awkgram.y:1335 #, c-format msgid "source file `%s' is empty" msgstr "fichier source « %s » est vide" -#: awkgram.y:1417 awkgram.y:1527 awkgram.y:1545 awkgram.y:1895 awkgram.y:1980 +#: awkgram.y:1537 awkgram.y:1647 awkgram.y:1665 awkgram.y:2015 awkgram.y:2100 msgid "source file does not end in newline" msgstr "fichier source ne se termine pas par un retour de chariot" -#: awkgram.y:1481 +#: awkgram.y:1601 msgid "unterminated regexp ends with `\\' at end of file" msgstr "" "expression régulière non termineé se terminant par « \\ » à la fin du fichier" -#: awkgram.y:1501 +#: awkgram.y:1621 msgid "unterminated regexp" msgstr "expression régulière non terminée" -#: awkgram.y:1504 +#: awkgram.y:1624 msgid "unterminated regexp at end of file" msgstr "expression régulière non terminée à la fin du fichier" -#: awkgram.y:1571 +#: awkgram.y:1691 msgid "use of `\\ #...' line continuation is not portable" msgstr "" "utilisation de « \\ #... » comme continuation de ligne n'est pas portable" -#: awkgram.y:1583 +#: awkgram.y:1703 msgid "backslash not last character on line" msgstr "la barre oblique inverse n'est pas le dernier caractère sur la ligne" -#: awkgram.y:1628 +#: awkgram.y:1748 msgid "POSIX does not allow operator `**='" msgstr "POSIX ne permet un opérateur « **= »" -#: awkgram.y:1630 +#: awkgram.y:1750 msgid "old awk does not support operator `**='" msgstr "l'ancien awk ne supporte pas l'opérateur « **= »" -#: awkgram.y:1639 +#: awkgram.y:1759 msgid "POSIX does not allow operator `**'" msgstr "POSIX ne permet pas l'opérateur « ** »" -#: awkgram.y:1641 +#: awkgram.y:1761 msgid "old awk does not support operator `**'" msgstr "l'ancien awk ne supporte pas l'opérateur « ** »" -#: awkgram.y:1672 +#: awkgram.y:1792 msgid "operator `^=' is not supported in old awk" msgstr "l'opérateur « ^= » n'est pas supporté dans l'ancien awk" -#: awkgram.y:1680 +#: awkgram.y:1800 msgid "operator `^' is not supported in old awk" msgstr "l'opérateur « ^ » n'est pas supporté dans l'ancien awk" -#: awkgram.y:1764 awkgram.y:1781 +#: awkgram.y:1884 awkgram.y:1901 msgid "unterminated string" msgstr "chaîne non complétée" -#: awkgram.y:1941 +#: awkgram.y:2061 #, c-format msgid "invalid char '%c' in expression" msgstr "caractère invalide « %c » dans l'expression" -#: awkgram.y:2001 +#: awkgram.y:2121 #, c-format msgid "`%s' is a gawk extension" msgstr "« %s » est une extension de gawk" -#: awkgram.y:2004 +#: awkgram.y:2124 #, c-format msgid "`%s' is a Bell Labs extension" msgstr "« %s » est une extension de Bell Labs" -#: awkgram.y:2007 +#: awkgram.y:2127 #, c-format msgid "POSIX does not allow `%s'" msgstr "POSIX ne permet pas « %s »" -#: awkgram.y:2011 +#: awkgram.y:2131 #, c-format msgid "`%s' is not supported in old awk" msgstr "« %s » n'est pas supporté dans l'ancien awk" -#: awkgram.y:2038 +#: awkgram.y:2158 msgid "`goto' considered harmful!\n" msgstr "« goto » considéré néfaste!\n" -#: awkgram.y:2102 +#: awkgram.y:2220 #, c-format msgid "%d is invalid as number of arguments for %s" msgstr "%d est invalide comme nombre d'arguments pour %s" -#: awkgram.y:2121 awkgram.y:2124 +#: awkgram.y:2239 awkgram.y:2242 msgid "match: third argument is a gawk extension" msgstr "match: 3e argument est une extension de gawk" -#: awkgram.y:2137 +#: awkgram.y:2255 #, c-format msgid "%s: string literal as last arg of substitute has no effect" msgstr "" "%s: la chaîne litérale comme dernier argument d'une substitution n'a aucun " "effet" -#: awkgram.y:2140 +#: awkgram.y:2258 #, c-format msgid "%s third parameter is not a changeable object" msgstr "3e paramètre %s n'est pas un objet modifiable" -#: awkgram.y:2167 awkgram.y:2170 +#: awkgram.y:2285 awkgram.y:2288 msgid "close: second argument is a gawk extension" msgstr "close: 2e argument est une extension de gawk" -#: awkgram.y:2180 +#: awkgram.y:2298 msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore" msgstr "" "utilisation de dcgettext(_\"...\") est incorrect: enlever les soulignés en " "en-tête" -#: awkgram.y:2195 +#: awkgram.y:2313 msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore" msgstr "" "utilisation de dcgettext(_\"...\") est incorrecte: enlever les soulignés de " "l'en-tête" -#: awkgram.y:2266 +#: awkgram.y:2384 #, c-format msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d" msgstr "fonction « %s »: paramètre #%d, « %s » est un double du paramètre #%d" -#: awkgram.y:2299 +#: awkgram.y:2417 #, c-format msgid "function `%s': parameter `%s' shadows global variable" msgstr "fonction « %s »: paramètre « %s » porte ombrage à la variable globale" -#: awkgram.y:2411 +#: awkgram.y:2529 #, c-format msgid "could not open `%s' for writing (%s)" msgstr "ne peut ourvrir « %s » en écriture (%s)" -#: awkgram.y:2412 profile.c:93 +#: awkgram.y:2530 profile.c:93 msgid "sending profile to standard error" msgstr "redirection du profile vers stderr" -#: awkgram.y:2442 +#: awkgram.y:2562 #, c-format msgid "%s: close failed (%s)" msgstr "%s: échec de fermeture (%s)" -#: awkgram.y:2566 +#: awkgram.y:2684 msgid "shadow_funcs() called twice!" msgstr "shadows_funcs() appelé deux fois!" -#: awkgram.y:2593 +#: awkgram.y:2711 msgid "there were shadowed variables." msgstr "il y a quelques variables qui sont cachées par ombrage" -#: awkgram.y:2666 +#: awkgram.y:2784 #, c-format msgid "function `%s': can't use function name as parameter name" msgstr "fonction « %s »: ne peut utilise le nom de la fonction comme paramètre" -#: awkgram.y:2676 +#: awkgram.y:2794 #, c-format msgid "function name `%s' previously defined" msgstr "nom de la fonction « %s » définie précédemment" -#: awkgram.y:2827 awkgram.y:2833 +#: awkgram.y:2945 awkgram.y:2951 #, c-format msgid "function `%s' called but never defined" msgstr "fonction « %s » appelé mais jamais définie" -#: awkgram.y:2836 +#: awkgram.y:2954 #, c-format msgid "function `%s' defined but never called" msgstr "fonction « %s » définie mais jamais utilisée" -#: awkgram.y:2863 +#: awkgram.y:2981 #, c-format msgid "regexp constant for parameter #%d yields boolean value" msgstr "" "expression régulière constante pour le paramètre #%d conduit à une valeur " "booléenne" -#: awkgram.y:2876 +#: awkgram.y:2994 #, c-format msgid "" "function `%s' called with space between name and `(',\n" @@ -366,195 +378,200 @@ "fonction « %s » appelée avec un espace entre le nom et « ( »,\n" "%s" -#: awkgram.y:2878 +#: awkgram.y:2996 msgid "or used as a variable or an array" msgstr "ou utilisé comme une variable ou un tableau" -#: builtin.c:111 +#: builtin.c:137 #, c-format msgid "%s to \"%s\" failed (%s)" msgstr "%s vers « %s » échec (%s)" -#: builtin.c:112 +#: builtin.c:138 msgid "standard output" msgstr "sortie standard" -#: builtin.c:113 +#: builtin.c:139 msgid "reason unknown" msgstr "raison inconnue" -#: builtin.c:126 +#: builtin.c:152 msgid "exp: received non-numeric argument" msgstr "exp: argument fourni n'est pas numérique" -#: builtin.c:132 +#: builtin.c:158 #, c-format msgid "exp: argument %g is out of range" msgstr "exp: argument fourni %g est hors gamme" -#: builtin.c:190 +#: builtin.c:216 #, c-format msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing" msgstr "" "fflush: ne peut vider: le pipe « %s » est oouvert en lecture, pas en écriture" -#: builtin.c:193 +#: builtin.c:219 #, c-format msgid "fflush: cannot flush: file `%s' opened for reading, not writing" msgstr "" "fflush: ne peut vider: fichier « %s » ouvert en lecture, pas en écriture" -#: builtin.c:205 +#: builtin.c:231 #, c-format msgid "fflush: `%s' is not an open file, pipe or co-process" msgstr "" "fflush: « %s » n'est pas ni un fichier ouvert, un pipe ou un co-processus" -#: builtin.c:299 +#: builtin.c:325 msgid "index: received non-string first argument" msgstr "index: premier argument fourni n'est pas une chaîne" -#: builtin.c:301 +#: builtin.c:327 msgid "index: received non-string second argument" msgstr "index: second argument fourni n'est pas une chaîne" -#: builtin.c:411 +#: builtin.c:437 msgid "int: received non-numeric argument" msgstr "int: argument fourni n'est pas numérique" -#: builtin.c:428 +#: builtin.c:454 msgid "length: received non-string argument" msgstr "length: argument fourni n'est pas une chaîne" -#: builtin.c:444 +#: builtin.c:470 msgid "log: received non-numeric argument" msgstr "log: argument fourni n'est pas numérique" -#: builtin.c:447 +#: builtin.c:473 #, c-format msgid "log: received negative argument %g" msgstr "log: argument fourni négatif %g" -#: builtin.c:609 builtin.c:612 +#: builtin.c:635 builtin.c:638 msgid "must use `count$' on all formats or none" msgstr "doit utiliser « count$ » pour tous les formats ou aucun" -#: builtin.c:714 +#: builtin.c:740 msgid "`$' is not permitted in awk formats" msgstr "« $ » n'est pas permis dans les formats awk" -#: builtin.c:720 +#: builtin.c:746 msgid "arg count with `$' must be > 0" msgstr "décompte d'arguments avec « $ » doit être > 0" -#: builtin.c:722 +#: builtin.c:748 #, c-format msgid "arg count %ld greater than total number of supplied arguments" msgstr "compteur d'arguments %ld est > que le nombre total fournis d'arguments" -#: builtin.c:724 +#: builtin.c:750 msgid "`$' not permitted after period in format" msgstr "« $ » n'est pas permis après le point" -#: builtin.c:737 +#: builtin.c:763 msgid "no `$' supplied for positional field width or precision" msgstr "aucun « $ » fourni dans le champ positionnel (longueur ou précision)" -#: builtin.c:795 +#: builtin.c:821 msgid "`l' is meaningless in awk formats; ignored" msgstr "« l » n'a aucun sens dans les formats de awk; ignoré" -#: builtin.c:799 +#: builtin.c:825 msgid "`l' is not permitted in POSIX awk formats" msgstr "« l » n'est pas permis dans les format POSIX de awk" -#: builtin.c:810 +#: builtin.c:836 msgid "`L' is meaningless in awk formats; ignored" msgstr "« L » n'a aucun sens dans les formats s de awk; ignoré" -#: builtin.c:814 +#: builtin.c:840 msgid "`L' is not permitted in POSIX awk formats" msgstr "« L » n'est pas permis dans les formats POSIX de awk" -#: builtin.c:825 +#: builtin.c:851 msgid "`h' is meaningless in awk formats; ignored" msgstr "« h » n'a aucun send dans les formats de awk; ignoré" -#: builtin.c:829 +#: builtin.c:855 msgid "`h' is not permitted in POSIX awk formats" msgstr "« h » n'est pas permis dans les formats POSIX de awk" -#: builtin.c:1078 +#: builtin.c:1055 +#, c-format +msgid "[s]printf: value %g is out of range for `%%%c' format" +msgstr "[s]printf: valeur %g est hors gamme pour le format « %%%c »" + +#: builtin.c:1108 msgid "not enough arguments to satisfy format string" msgstr "pas assez d'arguments pour satisfaire le format d'une chaîne" -#: builtin.c:1080 +#: builtin.c:1110 msgid "^ ran out for this one" msgstr "^ débordement pour celle-ci" -#: builtin.c:1085 +#: builtin.c:1115 msgid "[s]printf: format specifier does not have control letter" msgstr "" "[s]printf: spécificateur de format ne contient pas de lettre de contrôle" -#: builtin.c:1088 +#: builtin.c:1118 msgid "too many arguments supplied for format string" msgstr "trop d'arguments pour la chaîne de format" -#: builtin.c:1154 builtin.c:1157 +#: builtin.c:1184 builtin.c:1187 msgid "printf: no arguments" msgstr "printf: aucun argument" -#: builtin.c:1181 +#: builtin.c:1211 msgid "sqrt: received non-numeric argument" msgstr "sqrt: argument fourni n'est pas numérique" -#: builtin.c:1185 +#: builtin.c:1215 #, c-format msgid "sqrt: called with negative argument %g" msgstr "sqrt: appelé avec un argument négatif %g" -#: builtin.c:1207 +#: builtin.c:1238 #, c-format msgid "substr: start index %g is invalid, using 1" msgstr "substr: début de l'index %g est invalide, utilise 1" -#: builtin.c:1212 +#: builtin.c:1243 #, c-format msgid "substr: non-integer start index %g will be truncated" msgstr "substr: début avec un nombre non entier %g sera tronqué" -#: builtin.c:1231 -#, c-format -msgid "substr: length %g is <= 0" +#: builtin.c:1262 +#, fuzzy, c-format +msgid "substr: length %g is not >= 1" msgstr "substr: longueur %g est <= 0" -#: builtin.c:1233 -#, c-format -msgid "substr: length %g is < 0" -msgstr "substr: longueur %g est < 0" +#: builtin.c:1264 +#, fuzzy, c-format +msgid "substr: length %g is not >= 0" +msgstr "substr: longueur %g est <= 0" -#: builtin.c:1240 +#: builtin.c:1271 #, c-format msgid "substr: non-integer length %g will be truncated" msgstr "substr: longueur avec un nombre non entier %g sera tronqué" -#: builtin.c:1245 +#: builtin.c:1276 #, c-format msgid "substr: length %g too big for string indexing, truncating to %g" msgstr "" "substr: longueur %g trop grande pour l'indexation de chaîne, troncation à %g" -#: builtin.c:1257 +#: builtin.c:1288 msgid "substr: source string is zero length" msgstr "substr: chaîne de départ est de longueur zéro" -#: builtin.c:1263 +#: builtin.c:1294 #, c-format msgid "substr: start index %g is past end of string" msgstr "substr: début de l'index %g dépasse la fin de la chaîne" -#: builtin.c:1271 +#: builtin.c:1302 #, c-format msgid "" "substr: length %g at start index %g exceeds length of first argument (%lu)" @@ -562,235 +579,240 @@ "substr: longueur %g débute avec l'index %g déborde la longueur du 1er " "argument (%lu)" -#: builtin.c:1306 +#: builtin.c:1337 msgid "strftime: received non-string first argument" msgstr "strftime: premier argument fourni n'est pas une chaîne" -#: builtin.c:1312 +#: builtin.c:1343 msgid "strftime: received empty format string" msgstr "strftime: chaîne de format vide" -#: builtin.c:1321 +#: builtin.c:1352 msgid "strftime: received non-numeric second argument" msgstr "strftime: second argument fourni n'est pas numérique" -#: builtin.c:1384 +#: builtin.c:1415 msgid "mktime: received non-string argument" msgstr "mktime: argument fourni n'est pas une chaîne" -#: builtin.c:1429 +#: builtin.c:1460 msgid "system: received non-string argument" msgstr "system: argument fourni n'est pas une chaîne" -#: builtin.c:1573 +#: builtin.c:1581 eval.c:1883 +#, c-format +msgid "reference to uninitialized field `$%d'" +msgstr "référence à un champ non initialisée « $%d »" + +#: builtin.c:1608 msgid "tolower: received non-string argument" msgstr "tolower: argument fourni n'est pas une chaîne" -#: builtin.c:1622 +#: builtin.c:1657 msgid "toupper: received non-string argument" msgstr "toupper: argument fourni n'est pas une chaîne" -#: builtin.c:1667 +#: builtin.c:1702 msgid "atan2: received non-numeric first argument" msgstr "atan2: premier argument fourni n'est pas numérique" -#: builtin.c:1669 +#: builtin.c:1704 msgid "atan2: received non-numeric second argument" msgstr "atan2: second argument fourni n'est pas numérique" -#: builtin.c:1688 +#: builtin.c:1723 msgid "sin: received non-numeric argument" msgstr "sin: argument fourni n'est pas numérique" -#: builtin.c:1704 +#: builtin.c:1739 msgid "cos: received non-numeric argument" msgstr "cos: argument fourni n'est pas numérique" -#: builtin.c:1748 +#: builtin.c:1788 msgid "srand: received non-numeric argument" msgstr "srand: argument fourni n'est pas numérique" -#: builtin.c:1787 +#: builtin.c:1823 msgid "match: third argument is not an array" msgstr "match: le 3e argument fourni n'est pas un tableau" -#: builtin.c:2264 -msgid "gensub: 3rd argument of 0 treated as 1" +#: builtin.c:2307 +msgid "gensub: third argument of 0 treated as 1" msgstr "gensub: le 3e argument fourni de 0 traité comme un 1" -#: builtin.c:2375 builtin.c:2377 +#: builtin.c:2416 builtin.c:2418 msgid "lshift: received non-numeric first argument" msgstr "lshift: premier argument fourni n'est pas numérique" -#: builtin.c:2379 +#: builtin.c:2420 #, c-format msgid "lshift(%lf, %lf): negative values will give strange results" msgstr "lshift(%lf, %lf): valeurs négatives donneront d'étranges résultats" -#: builtin.c:2381 +#: builtin.c:2422 #, c-format msgid "lshift(%lf, %lf): fractional values will be truncated" msgstr "lshift(%lf, %lf): valeurs fractionnaires seront tronquées" -#: builtin.c:2383 +#: builtin.c:2424 #, c-format msgid "lshift(%lf, %lf): too large shift value will give strange results" msgstr "lshift(%lf, %lf): trop grand déplacement donnera d'étranges résultats" -#: builtin.c:2412 builtin.c:2414 +#: builtin.c:2453 builtin.c:2455 msgid "rshift: received non-numeric first argument" msgstr "rshift: premier argument fourni n'est pas numérique" -#: builtin.c:2416 +#: builtin.c:2457 #, c-format msgid "rshift(%lf, %lf): negative values will give strange results" msgstr "rshift(%lf, %lf): valeurs négatives donneront d'étranges résultats" -#: builtin.c:2418 +#: builtin.c:2459 #, c-format msgid "rshift(%lf, %lf): fractional values will be truncated" msgstr "rshift(%lf, %lf): valeurs fractionnaires seront tronquées" -#: builtin.c:2420 +#: builtin.c:2461 #, c-format msgid "rshift(%lf, %lf): too large shift value will give strange results" msgstr "rshift(%lf, %lf): trop grand déplacement donnera d'étranges résultats" -#: builtin.c:2449 builtin.c:2451 +#: builtin.c:2490 builtin.c:2492 msgid "and: received non-numeric first argument" msgstr "and: premier argument fourni n'est pas numérique" -#: builtin.c:2453 +#: builtin.c:2494 #, c-format msgid "and(%lf, %lf): negative values will give strange results" msgstr "and(%lf, %lf): valeurs négatives donneront d'étranges résultats" -#: builtin.c:2455 +#: builtin.c:2496 #, c-format msgid "and(%lf, %lf): fractional values will be truncated" msgstr "and(%lf, %lf): valeurs fractionnaires seront tronquées" -#: builtin.c:2484 builtin.c:2486 +#: builtin.c:2525 builtin.c:2527 msgid "or: received non-numeric first argument" msgstr "or: premier argument fourni n'est pas numérique" -#: builtin.c:2488 +#: builtin.c:2529 #, c-format msgid "or(%lf, %lf): negative values will give strange results" msgstr "or(%lf, %lf): valeurs négatives donneront d'étranges résultats" -#: builtin.c:2490 +#: builtin.c:2531 #, c-format msgid "or(%lf, %lf): fractional values will be truncated" msgstr "or(%lf, %lf): valeurs fractionnaires seront tronquées" -#: builtin.c:2519 builtin.c:2521 +#: builtin.c:2560 builtin.c:2562 msgid "xor: received non-numeric first argument" msgstr "xor: premier argument fourni n'est pas numérique" -#: builtin.c:2523 +#: builtin.c:2564 #, c-format msgid "xor(%lf, %lf): negative values will give strange results" msgstr "xor(%lf, %lf): valeurs négatives donneront d'étranges résultats" -#: builtin.c:2525 +#: builtin.c:2566 #, c-format msgid "xor(%lf, %lf): fractional values will be truncated" msgstr "xor(%lf, %lf): valeurs fractionnaires seront tronquées" -#: builtin.c:2553 +#: builtin.c:2594 msgid "compl: received non-numeric argument" msgstr "compl: argument fourni n'est pas numérique" -#: builtin.c:2555 +#: builtin.c:2596 #, c-format msgid "compl(%lf): negative value will give strange results" msgstr "compl(%lf): valeurs négatives donneront d'étranges résultats" -#: builtin.c:2557 +#: builtin.c:2598 #, c-format msgid "compl(%lf): fractional value will be truncated" msgstr "compl(%lf): valeurs fractionnaires seront tronquées" -#: builtin.c:2728 +#: builtin.c:2771 #, c-format msgid "dcgettext: `%s' is not a valid locale category" msgstr "dcgettext: « %s » n'est pas dans un catégorie de localisation valide" -#: eval.c:262 +#: eval.c:266 #, c-format msgid "unknown nodetype %d" msgstr "type de noeud inconnu %d" -#: eval.c:310 +#: eval.c:312 msgid "buffer overflow in genflags2str" msgstr "débordement de tampo dans genflag2str" -#: eval.c:555 +#: eval.c:647 #, c-format msgid "for loop: array `%s' changed size from %ld to %ld during loop execution" msgstr "" "for loop: tableau « %s » a changé de taille de %ld à %ld durant l'exécution " "de la boucle" -#: eval.c:576 +#: eval.c:668 msgid "`break' outside a loop is not portable" msgstr "« break » en dehors de la boucle n'est pas portable" -#: eval.c:580 +#: eval.c:672 msgid "`break' outside a loop is not allowed" msgstr "« break » en dehors de la boucle n'est pas permis" -#: eval.c:597 +#: eval.c:689 msgid "`continue' outside a loop is not portable" msgstr "« continue » en dehors de la boucle n'est pas portable" -#: eval.c:601 +#: eval.c:693 msgid "`continue' outside a loop is not allowed" msgstr "« continue » en dehors de la boucle n'est pas permis" -#: eval.c:635 +#: eval.c:727 msgid "`next' cannot be called from a BEGIN rule" msgstr "« next » ne peut être appelé depuis une règle BEGIN" -#: eval.c:637 +#: eval.c:729 msgid "`next' cannot be called from an END rule" msgstr "« next » ne peut être appelé depuis une règle END" -#: eval.c:646 +#: eval.c:738 msgid "`nextfile' cannot be called from a BEGIN rule" msgstr "« nextfile » ne peut être appelé depuis une règle BEGIN" -#: eval.c:648 +#: eval.c:740 msgid "`nextfile' cannot be called from an END rule" msgstr "« nextfile » ne peut être appelé depuis une règle END" -#: eval.c:696 +#: eval.c:785 msgid "statement has no effect" msgstr "la déclaration n'a aucun effet" -#: eval.c:731 eval.c:761 eval.c:1733 -#, c-format -msgid "reference to uninitialized variable `%s'" -msgstr "référence à une variable non initialisée « %s »" - -#: eval.c:739 eval.c:1721 +#: eval.c:828 eval.c:1726 #, c-format msgid "can't use function name `%s' as variable or array" msgstr "" "ne peut utiliser le nom de la fonction « %s » comme variable ou tableau" -#: eval.c:746 eval.c:752 +#: eval.c:835 eval.c:841 #, c-format msgid "reference to uninitialized argument `%s'" msgstr "référence à un argument non initialisé « %s »" -#: eval.c:810 eval.c:1728 profile.c:773 +#: eval.c:848 eval.c:907 eval.c:1732 eval.c:1742 profile.c:807 #, c-format msgid "attempt to use array `%s' in a scalar context" msgstr "tentative d'utilisation du tableau « %s » dans un contexte scalaire" -#: eval.c:910 +#: eval.c:858 eval.c:1752 +#, c-format +msgid "reference to uninitialized variable `%s'" +msgstr "référence à une variable non initialisée « %s »" + +#: eval.c:1007 msgid "" "concatenation: side effects in one expression have changed the length of " "another!" @@ -798,54 +820,49 @@ "concaténation: effects de bord dans une expression a modifié la longueur " "d'une autre!" -#: eval.c:935 +#: eval.c:1032 msgid "assignment used in conditional context" msgstr "affectation utilisé dans un contexte conditionnel" -#: eval.c:1026 +#: eval.c:1122 msgid "division by zero attempted" msgstr "tentative de division par zéro" -#: eval.c:1041 +#: eval.c:1137 #, c-format msgid "division by zero attempted in `%%'" msgstr "tentative de division par zéro dans « %% »" -#: eval.c:1056 profile.c:649 +#: eval.c:1152 profile.c:683 #, c-format msgid "illegal type (%s) in tree_eval" msgstr "type illégal (%s) dans tree_eval" -#: eval.c:1232 +#: eval.c:1328 msgid "division by zero attempted in `/='" msgstr "tentative de division par zéro dans « /= »" -#: eval.c:1250 +#: eval.c:1346 #, c-format msgid "division by zero attempted in `%%='" msgstr "tentative de division par zéro dans « %%= »" -#: eval.c:1510 -#, c-format -msgid "%s (from %s)" -msgstr "%s (de %s)" - -#: eval.c:1569 +#: eval.c:1586 #, c-format msgid "function `%s' called with more arguments than declared" msgstr "fonction « %s » appelée avec plus d'arguments que déclarées" -#: eval.c:1628 +#: eval.c:1633 #, c-format msgid "function `%s' not defined" msgstr "fonction « %s » non définie" -#: eval.c:1634 +#: eval.c:1639 #, c-format msgid "function %s called\n" msgstr "fonction %s appelée\n" -#: eval.c:1693 +#: eval.c:1698 msgid "" "\n" "\t# Function Call Stack:\n" @@ -855,49 +872,43 @@ "\t# Appel d'une fonction sur la pile:\n" "\n" -#: eval.c:1696 +#: eval.c:1701 msgid "\t# -- main --\n" msgstr "#t# -- main --\n" -#: eval.c:1850 +#: eval.c:1867 msgid "attempt to field reference from non-numeric value" msgstr "tentative de référence un champ à partir d'une valeur non numérique" -#: eval.c:1852 +#: eval.c:1869 msgid "attempt to reference from null string" msgstr "tentative de référence à partir d'une chaîne nulle" -#: eval.c:1858 +#: eval.c:1875 #, c-format msgid "attempt to access field %d" msgstr "tentative d'accès du champ %d" -#: eval.c:1874 -#, c-format -msgid "attempt to use scalar parameter `%s' as an array" -msgstr "" -"tentative d'utilisation d'un paramètre scalaire « %s » comme un tableau" - -#: eval.c:1886 eval.c:1893 profile.c:865 +#: eval.c:1896 eval.c:1903 profile.c:900 msgid "assignment is not allowed to result of builtin function" msgstr "" "l'affectation n'est pas permise pour obtenir un résultat d'une fonction " "interne" -#: eval.c:1941 +#: eval.c:1951 msgid "`IGNORECASE' is a gawk extension" msgstr "« IGNORECASE » est une extension de gawk" -#: eval.c:1970 +#: eval.c:1980 msgid "`BINMODE' is a gawk extension" msgstr "« BINMODE » est une extension de gawk" -#: eval.c:2082 +#: eval.c:2092 #, c-format msgid "bad `%sFMT' specification `%s'" msgstr "« %sFMT » spécification erronée « %s »" -#: eval.c:2160 +#: eval.c:2170 msgid "turning off `--lint' due to assignment to `LINT'" msgstr "désactivation « --lint » en raison d'une affectation à « LINT »" @@ -915,32 +926,32 @@ msgid "extension: library `%s': cannot call function `%s' (%s)\n" msgstr "extension: librairie « %s »: ne peut appeler la fonction « %s » (%s)\n" -#: ext.c:181 +#: ext.c:183 msgid "Operation Not Supported" msgstr "Opération non supportée" -#: field.c:321 +#: field.c:315 msgid "NF set to negative value" msgstr "NF initialisé avec une valeur négative" -#: field.c:819 +#: field.c:808 msgid "split: second argument is not an array" msgstr "split: 2e argument n'est pas un tableau" -#: field.c:854 +#: field.c:842 msgid "split: null string for third arg is a gawk extension" msgstr "split: chaîne vide pour le 3e argument est une extension de gawk" -#: field.c:906 +#: field.c:894 msgid "`FIELDWIDTHS' is a gawk extension" msgstr "« FIELDWIDTHS » est une extension de gawk" -#: field.c:933 +#: field.c:921 #, c-format msgid "field %d in FIELDWIDTHS, must be > 0" msgstr "champ %d dans FIELDWIDTHS, doit être > 0" -#: field.c:1006 +#: field.c:994 msgid "null string for `FS' is a gawk extension" msgstr "chaîne vide pour « FS » est une extension de gawk" @@ -984,7 +995,7 @@ msgid "%s: invalid option -- %c\n" msgstr "%s: option invalide -- %c\n" -#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:431 +#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:434 #, c-format msgid "%s: option requires an argument -- %c\n" msgstr "%s: l'option requiert un argument -- %c\n" @@ -999,478 +1010,478 @@ msgid "%s: option `-W %s' doesn't allow an argument\n" msgstr "%s: l'option « -W %s » ne requiert pas d'argument\n" -#: io.c:257 +#: io.c:305 #, c-format msgid "cannot open file `%s' for reading (%s)" msgstr "ne peut ouvrir le fichier « %s » en lecture (%s)" -#: io.c:344 +#: io.c:392 #, c-format msgid "close of fd %d (`%s') failed (%s)" msgstr "fermeture de fd %d (« %s ») en échec (%s)" -#: io.c:482 +#: io.c:530 #, c-format msgid "invalid tree type %s in redirect()" msgstr "type d'arbre invalide %s dans redirect()" -#: io.c:488 +#: io.c:536 #, c-format msgid "expression in `%s' redirection only has numeric value" msgstr "" "l'expression de la redirection de « %s » a seulement une valeur numérique" -#: io.c:494 +#: io.c:542 #, c-format msgid "expression for `%s' redirection has null string value" msgstr "" "l'expression de la redirection de « %s » a une valeur nulle pour la chaîne" -#: io.c:499 +#: io.c:547 #, c-format msgid "filename `%s' for `%s' redirection may be result of logical expression" msgstr "" "nom de fichier « %s » pour le redirection « %s » peut être le résultat d'une " "expression logique" -#: io.c:521 +#: io.c:569 #, c-format msgid "unnecessary mixing of `>' and `>>' for file `%.*s'" msgstr "mélange non nécessaire de « > » et de « >> » pour le fichier « %.*s »" -#: io.c:573 +#: io.c:621 #, c-format msgid "can't open pipe `%s' for output (%s)" msgstr "ne peut ouvrir un pipe « %s » en sortie (%s)" -#: io.c:582 +#: io.c:630 #, c-format msgid "can't open pipe `%s' for input (%s)" msgstr "ne peut ouvrir un pipe « %s » en entrée (%s)" -#: io.c:595 +#: io.c:643 #, c-format msgid "can't open two way socket `%s' for input/output (%s)" msgstr "" "ne peut ouvrir un socket bidirectionnel « %s » pour les entrées/sorties (%s)" -#: io.c:599 +#: io.c:647 #, c-format msgid "can't open two way pipe `%s' for input/output (%s)" msgstr "" "ne peut ouvrir un pipe bidirectionnel « %s » pour les entrées/sorties (%s)" -#: io.c:675 +#: io.c:723 #, c-format msgid "can't redirect from `%s' (%s)" msgstr "ne peut rediriger de « %s » (%s)" -#: io.c:678 +#: io.c:726 #, c-format msgid "can't redirect to `%s' (%s)" msgstr "ne peut rediriger vers « %s » (%s)" -#: io.c:717 +#: io.c:765 msgid "" "reached system limit for open files: starting to multiplex file descriptors" msgstr "" "limite système atteinte pour l'ouverture des fichiers: début du multiplexage " "des descripteurs de fichiers" -#: io.c:729 +#: io.c:777 #, c-format msgid "close of `%s' failed (%s)." msgstr "fermeture de « %s » en échec (%s)" -#: io.c:736 +#: io.c:784 msgid "too many pipes or input files open" msgstr "trop de pipes ou de fichiers en lecture ouverts" -#: io.c:759 +#: io.c:807 msgid "close: second argument must be `to' or `from'" msgstr "close: 2e argument doit être « to » ou « from »" -#: io.c:773 +#: io.c:821 #, c-format msgid "close: `%.*s' is not an open file, pipe or co-process" msgstr "close: « %.*s » n'est pas ni un fichier ouvert, pipe ou co-processus" -#: io.c:777 +#: io.c:825 msgid "close of redirection that was never opened" msgstr "fermeture de la redirection qui n'a jamais été ouverte" -#: io.c:804 +#: io.c:862 #, c-format msgid "close: redirection `%s' not opened with `|&', second argument ignored" msgstr "" "close: redirection « %s » n'a pas été ouverte ave « |& » 2e argument ignoré" -#: io.c:866 +#: io.c:924 #, c-format msgid "failure status (%d) on pipe close of `%s' (%s)" msgstr "constat d'échec (%d) lors de la fermeture du pipe « %s » (%s)" -#: io.c:869 +#: io.c:927 #, c-format msgid "failure status (%d) on file close of `%s' (%s)" msgstr "constat d'échec (%d) lors de la fermeture du fichier « %s » (%s)" -#: io.c:888 +#: io.c:946 #, c-format msgid "no explicit close of socket `%s' provided" msgstr "aucune fermeture explicite du socket « %s » fournie" -#: io.c:891 +#: io.c:949 #, c-format msgid "no explicit close of co-process `%s' provided" msgstr "aucune fermeture explicite du co-processus « %s » fournie" -#: io.c:894 +#: io.c:952 #, c-format msgid "no explicit close of pipe `%s' provided" msgstr "aucune fermeture explicite du pipe « %s » fournie" -#: io.c:897 +#: io.c:955 #, c-format msgid "no explicit close of file `%s' provided" msgstr "aucune fermeture explicite du fichier « %s » fournie" -#: io.c:926 io.c:980 +#: io.c:984 io.c:1038 #, c-format msgid "error writing standard output (%s)" msgstr "erreur lors de l'écriture vers stdout (%s)" -#: io.c:930 io.c:984 +#: io.c:988 io.c:1042 #, c-format msgid "error writing standard error (%s)" msgstr "erreur lors de l'écriture vers stderr (%s)" -#: io.c:938 +#: io.c:996 #, c-format msgid "pipe flush of `%s' failed (%s)." msgstr "vidange du pipie de « %s » en échec (%s)" -#: io.c:941 +#: io.c:999 #, c-format msgid "co-process flush of pipe to `%s' failed (%s)." msgstr "vidange du pipe par le co-processus vers « %s » en échec (%s)" -#: io.c:944 +#: io.c:1002 #, c-format msgid "file flush of `%s' failed (%s)." msgstr "vidange du fichier « %s » en échec (%s)" -#: io.c:1103 +#: io.c:1161 msgid "/inet/raw client not ready yet, sorry" msgstr "le client /inet/raw n'est pas encore prêt, désolé" -#: io.c:1105 io.c:1142 +#: io.c:1163 io.c:1200 msgid "only root may use `/inet/raw'." msgstr "seul root peut utiliser « /inet/raw »" -#: io.c:1140 +#: io.c:1198 msgid "/inet/raw server not ready yet, sorry" msgstr "le serveur /inet/raw n'est pas encore prêt, désolé" -#: io.c:1230 +#: io.c:1288 #, c-format msgid "no (known) protocol supplied in special filename `%s'" msgstr "aucun protocole (connu) fourni dans le nom de fichier spécial « %s »" -#: io.c:1248 +#: io.c:1306 #, c-format msgid "special file name `%s' is incomplete" msgstr "nom spécial de fichier « %s » est incomplet" -#: io.c:1260 +#: io.c:1318 #, c-format msgid "local port invalid in `%s'" msgstr "port local invalide dans « %s »" -#: io.c:1272 +#: io.c:1330 msgid "must supply a remote hostname to `/inet'" msgstr "un nom de hôte distant doit être fourni à « /inet »" -#: io.c:1287 +#: io.c:1345 msgid "must supply a remote port to `/inet'" msgstr "un port distant doit être fournis à « /inet »" -#: io.c:1293 +#: io.c:1351 #, c-format msgid "remote port invalid in `%s'" msgstr "port distant invalide dans « %s »" -#: io.c:1303 +#: io.c:1361 msgid "TCP/IP communications are not supported" msgstr "les communications TCP/IP ne sont pas supportées" -#: io.c:1312 io.c:1492 +#: io.c:1370 io.c:1551 #, c-format msgid "file `%s' is a directory" msgstr "le fichier « %s » est un répertoire" -#: io.c:1381 +#: io.c:1440 #, c-format msgid "use `PROCINFO[\"%s\"]' instead of `%s'" msgstr "utliser « PROCINFO[\"%s\"] » au lieu de « %s »" -#: io.c:1413 +#: io.c:1472 msgid "use `PROCINFO[...]' instead of `/dev/user'" msgstr "utliser « PROCINFO[\"%s\"] » au lieu de « /dev/user »" -#: io.c:1478 io.c:1652 +#: io.c:1537 io.c:1711 #, c-format msgid "could not open `%s', mode `%s'" msgstr "ne peut ouvrir « %s », mode « %s »" -#: io.c:1703 +#: io.c:1762 #, c-format msgid "close of master pty failed (%s)" msgstr "échec de la fermeture du pty maître (%s)" -#: io.c:1705 io.c:1857 io.c:2009 +#: io.c:1764 io.c:1916 io.c:2068 #, c-format msgid "close of stdout in child failed (%s)" msgstr "échec de fermeture de stdout du processus fils (%s)" -#: io.c:1708 +#: io.c:1767 #, c-format msgid "moving slave pty to stdout in child failed (dup: %s)" msgstr "" "échec de redirection du pty esclave vers stdout du processus fils (dup: %s)" -#: io.c:1710 io.c:1862 +#: io.c:1769 io.c:1921 #, c-format msgid "close of stdin in child failed (%s)" msgstr "échec de fermeture de stdin du processus fils (%s)" -#: io.c:1713 +#: io.c:1772 #, c-format msgid "moving slave pty to stdin in child failed (dup: %s)" msgstr "" "échec de redirection du pty esclave vers stdin du processus fils (dup: %s)" -#: io.c:1715 io.c:1734 +#: io.c:1774 io.c:1793 #, c-format msgid "close of slave pty failed (%s)" msgstr "échec de la fermeture du pty esclave (%s)" -#: io.c:1808 io.c:1860 io.c:1990 io.c:2012 +#: io.c:1867 io.c:1919 io.c:2049 io.c:2071 #, c-format msgid "moving pipe to stdout in child failed (dup: %s)" msgstr "échec de redirection du pipe vers stdout du processus fils (dup: %s)" -#: io.c:1812 io.c:1865 +#: io.c:1871 io.c:1924 #, c-format msgid "moving pipe to stdin in child failed (dup: %s)" msgstr "échec de redirection du pipe vers stdin du processus fils (dup: %s)" -#: io.c:1829 io.c:2003 +#: io.c:1888 io.c:2062 msgid "restoring stdout in parent process failed\n" msgstr "restauration de stdout par le processus parent a échoué\n" -#: io.c:1834 +#: io.c:1893 msgid "restoring stdin in parent process failed\n" msgstr "restauration de stdin par le processus parent a échoué\n" -#: io.c:1868 io.c:2014 io.c:2025 +#: io.c:1927 io.c:2073 io.c:2084 #, c-format msgid "close of pipe failed (%s)" msgstr "échec de la fermeture du pipe (%s)" -#: io.c:1913 +#: io.c:1972 msgid "`|&' not supported" msgstr "« |& » non supporté" -#: io.c:1980 +#: io.c:2039 #, c-format msgid "cannot open pipe `%s' (%s)" msgstr "ne ouvrir un pipe « %s » (%s)" -#: io.c:2021 +#: io.c:2080 #, c-format msgid "cannot create child process for `%s' (fork: %s)" msgstr "ne créer le processus fils pour « %s » (fork: %s)" -#: io.c:2364 +#: io.c:2423 #, c-format msgid "data file `%s' is empty" msgstr "le fichier de données « %s » est vide" -#: io.c:2407 io.c:2415 +#: io.c:2466 io.c:2474 msgid "could not allocate more input memory" msgstr "ne peut allouer plus de mémoire pour l'entrée" -#: io.c:2540 io.c:2782 io.c:3046 +#: io.c:2832 io.c:2895 #, c-format msgid "error reading input file `%s': %s" msgstr "erreur lors de la lecture du fichier source « %s »: %s" -#: io.c:3281 +#: io.c:3020 msgid "multicharacter value of `RS' is a gawk extension" msgstr "valeur de « RS » avec multiple caractères est une extension gawk" -#: main.c:322 +#: main.c:324 msgid "`-m[fr]' option irrelevant in gawk" msgstr "« -m[fr] » est une option non pertinente en gawk" -#: main.c:324 +#: main.c:326 msgid "-m option usage: `-m[fr] nnn'" msgstr "-m usage de l'option: « -m[fr] nnn »" -#: main.c:341 +#: main.c:343 #, c-format msgid "%s: option `-W %s' unrecognized, ignored\n" msgstr "%s: l'option « -W %s » n'est pas reconnue, ignorée\n" -#: main.c:378 +#: main.c:380 msgid "empty argument to `--source' ignored" msgstr "argument vide à l'option « --source », ignorée" -#: main.c:448 +#: main.c:451 msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'" msgstr "" "variable d'environnement « POSIXLY__CORRECT » initialisée: utilisation de « " "--posix »" -#: main.c:453 +#: main.c:456 msgid "`--posix' overrides `--traditional'" msgstr "« --posix » écrase « --traditional »" -#: main.c:464 +#: main.c:467 msgid "`--posix'/`--traditional' overrides `--non-decimal-data'" msgstr "« --posix »/« --traditional » écrase « --non-decimal-data »" -#: main.c:468 +#: main.c:471 #, c-format msgid "running %s setuid root may be a security problem" msgstr "" "l'exécution de %s en mode setuid root peut causer un problème de sécurité" -#: main.c:509 +#: main.c:512 #, c-format msgid "can't set binary mode on stdin (%s)" msgstr "ne peut initialiser le mode binaire sur stdin (%s)" -#: main.c:512 +#: main.c:515 #, c-format msgid "can't set binary mode on stdout (%s)" msgstr "ne peut initialiser le mode binaire sur stdout (%s)" -#: main.c:514 +#: main.c:517 #, c-format msgid "can't set binary mode on stderr (%s)" msgstr "ne peut initialiser le mode binaire sur stderr (%s)" -#: main.c:544 +#: main.c:547 msgid "no program text at all!" msgstr "aucun programme!" -#: main.c:612 +#: main.c:620 #, c-format msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n" msgstr "" "Usage: %s [style des options POSIX ou GNU] -f fichierprog [--] fichier ...\n" -#: main.c:614 +#: main.c:622 #, c-format msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n" msgstr "" "Usage: %s [style des options POSIX ou GNU] [--] %cprogram%c fichier ...\n" -#: main.c:619 +#: main.c:627 msgid "POSIX options:\t\tGNU long options:\n" msgstr "Options POSIX:\t\toptions de long format GNU:\n" -#: main.c:620 +#: main.c:628 msgid "\t-f progfile\t\t--file=progfile\n" msgstr "\t-f fichierprog\t\t--file=fichierprog\n" -#: main.c:621 +#: main.c:629 msgid "\t-F fs\t\t\t--field-separator=fs\n" msgstr "#t-F fs\t\t\t--field-separator=fs\n" -#: main.c:622 +#: main.c:630 msgid "\t-v var=val\t\t--assign=var=val\n" msgstr "#t-v var=valeur\t\t--assign=var=valeur\n" -#: main.c:623 +#: main.c:631 msgid "\t-m[fr] val\n" msgstr "\t-m[fr] valeur\n" -#: main.c:624 +#: main.c:632 msgid "\t-W compat\t\t--compat\n" msgstr "\t-W compat\t\t--compat\n" -#: main.c:625 +#: main.c:633 msgid "\t-W copyleft\t\t--copyleft\n" msgstr "\t-W copyleft\t\t--copyleft\n" -#: main.c:626 +#: main.c:634 msgid "\t-W copyright\t\t--copyright\n" msgstr "\t-W copyright\t\t--copyright\n" -#: main.c:627 +#: main.c:635 msgid "\t-W dump-variables[=file]\t--dump-variables[=file]\n" msgstr "\t-W dump-variables[=fichier]\t--dump-variables[=fichier]\n" -#: main.c:628 +#: main.c:636 msgid "\t-W gen-po\t\t--gen-po\n" msgstr "\t-W gen-po\t\t--gen-po\n" -#: main.c:629 +#: main.c:637 msgid "\t-W help\t\t\t--help\n" msgstr "\t-W help\t\t\t--help\n" -#: main.c:630 +#: main.c:638 msgid "\t-W lint[=fatal]\t\t--lint[=fatal]\n" msgstr "\t-W lint[=fatal]\t\t--lint[=fatal]\n" -#: main.c:631 +#: main.c:639 msgid "\t-W lint-old\t\t--lint-old\n" msgstr "\t-W lint-old\t\t--lint-old\n" -#: main.c:632 +#: main.c:640 msgid "\t-W non-decimal-data\t--non-decimal-data\n" msgstr "\t-W non-decimal-data\t--non-decimal-data\n" -#: main.c:634 +#: main.c:642 msgid "\t-W nostalgia\t\t--nostalgia\n" msgstr "\t-W nostalgia\t\t--nostalgia\n" -#: main.c:637 +#: main.c:645 msgid "\t-W parsedebug\t\t--parsedebug\n" msgstr "\t-W parsedebug\t\t--parsedebug\n" -#: main.c:639 +#: main.c:647 msgid "\t-W profile[=file]\t--profile[=file]\n" msgstr "\t-W profile[=fichier]\t--profile[=fichier]\n" -#: main.c:640 +#: main.c:648 msgid "\t-W posix\t\t--posix\n" msgstr "\t-W posix\t\t--posix\n" -#: main.c:641 +#: main.c:649 msgid "\t-W re-interval\t\t--re-interval\n" msgstr "\t-W re-interval\t\t--re-interval\n" -#: main.c:642 +#: main.c:650 msgid "\t-W source=program-text\t--source=program-text\n" msgstr "\t-W source=program-text\t--source=program-text\n" -#: main.c:643 +#: main.c:651 msgid "\t-W traditional\t\t--traditional\n" msgstr "\t-W traditional\t\t--traditional\n" -#: main.c:644 +#: main.c:652 msgid "\t-W usage\t\t--usage\n" msgstr "\t-W usage\t\t--usage\n" -#: main.c:645 +#: main.c:653 msgid "\t-W version\t\t--version\n" msgstr "\t-W version\t\t--version\n" -#: main.c:649 +#: main.c:657 msgid "" "\n" "To report bugs, see node `Bugs' in `gawk.info', which is\n" @@ -1481,7 +1492,7 @@ "Pour rapporter une anomalie, voir la rubrique « Bugs » dans « gawk.info »\n" "dans la section « Reporting Problems and Bugs » de la version imprimée.\n" -#: main.c:653 +#: main.c:661 msgid "" "gawk is a pattern scanning and processing language.\n" "By default it reads standard input and writes standard output.\n" @@ -1491,7 +1502,7 @@ "Par défaut, il lit de l'entrée standard et écrit sur la sortie standard.\n" "\n" -#: main.c:657 +#: main.c:665 msgid "" "Examples:\n" "\tgawk '{ sum += $1 }; END { print sum }' file\n" @@ -1501,7 +1512,7 @@ "\tgawk '{ sum += $1 }; END { print sum }' fichier\n" "\tgawk -F: '{ print $1 }' /etc/passwd\n" -#: main.c:669 +#: main.c:682 #, c-format msgid "" "Copyright (C) 1989, 1991-%d Free Software Foundation.\n" @@ -1520,7 +1531,7 @@ "soit (selon vos préférences) toute version ultérieure.\n" "\n" -#: main.c:677 +#: main.c:690 msgid "" "This program is distributed in the hope that it will be useful,\n" "but WITHOUT ANY WARRANTY; without even the implied warranty of\n" @@ -1535,7 +1546,7 @@ "Pour plus d'informations à ce sujet, consulter la « GNU General Public " "License ».\n" -#: main.c:683 +#: main.c:696 msgid "" "You should have received a copy of the GNU General Public License\n" "along with this program; if not, write to the Free Software\n" @@ -1545,13 +1556,13 @@ "avec ce programme; sinon, écrire à la Free Software Foundation, Inc.,\n" "59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n" -#: main.c:713 +#: main.c:730 msgid "-Ft does not set FS to tab in POSIX awk" msgstr "" "-Ft ne permet pas d'initialiser FS à un tabulateur dans la version POSIX de " "awk" -#: main.c:944 +#: main.c:956 #, c-format msgid "" "%s: `%s' argument to `-v' not in `var=value' form\n" @@ -1560,35 +1571,35 @@ "%s: `%s' argument à `-v' n'a pas le format `var=valeur'\n" "\n" -#: main.c:964 +#: main.c:976 #, c-format msgid "`%s' is not a legal variable name" msgstr "`%s' n'est pas un nom de variable légal" -#: main.c:967 +#: main.c:979 #, c-format msgid "`%s' is not a variable name, looking for file `%s=%s'" msgstr "`%s' n'est pas un nom de variable, recherche du fichier `%s=%s'" -#: main.c:995 +#: main.c:1012 msgid "floating point exception" msgstr "exception de la virgule flottante" -#: main.c:1002 +#: main.c:1019 msgid "fatal error: internal error" msgstr "erreur fatale: erreur interne" -#: main.c:1052 +#: main.c:1069 #, c-format msgid "no pre-opened fd %d" msgstr "aucun fd pré-ouvert pour %d" -#: main.c:1057 +#: main.c:1074 #, c-format msgid "could not pre-open /dev/null for fd %d" msgstr "ne peut pré-ouvrir /dev/null pour le descripteud fd %d" -#: main.c:1080 main.c:1089 +#: main.c:1097 main.c:1106 #, c-format msgid "could not find groups: %s" msgstr "n'a pu trouvé les groupes: %s" @@ -1609,23 +1620,23 @@ msgid "fatal: " msgstr "Fatal: " -#: node.c:59 node.c:66 node.c:75 node.c:89 node.c:116 +#: node.c:58 node.c:65 node.c:74 node.c:88 node.c:115 msgid "can't convert string to float" msgstr "ne peut convertir la chaîne en nombre flottant" -#: node.c:357 +#: node.c:355 msgid "backslash at end of string" msgstr "barre oblique inverse à la fin de la chaîne" -#: node.c:544 +#: node.c:539 msgid "POSIX does not allow `\\x' escapes" msgstr "POSIX ne permet pas de séquence d'échappement « \\x »" -#: node.c:550 +#: node.c:545 msgid "no hex digits in `\\x' escape sequence" msgstr "aucun chiffre hexadécimal dans la séquence d'échappement « \\x » " -#: node.c:584 +#: node.c:579 #, c-format msgid "escape sequence `\\%c' treated as plain `%c'" msgstr "séquence d'échappement « \\%c » traitée simplement comme « %c »" @@ -1640,24 +1651,21 @@ msgid "could not open `%s' for writing: %s" msgstr "ne peut ouvrir « %s » en écriture: %s" -#: profile.c:409 -msgid "internal error: Node_var with null vname" -msgstr "erreur interne: Node_var avec un vname nul" +#: profile.c:449 +#, c-format +msgid "internal error: %s with null vname" +msgstr "erreur interne: %s avec un vname nul" -#: profile.c:471 +#: profile.c:512 msgid "# treated internally as `delete'" msgstr "# traitée de manière interne comme « delete »" -#: profile.c:545 -msgid "internal error: Node_var_array with null vname" -msgstr "erreur interne: Node_var_array avec un vname nul" - -#: profile.c:1127 +#: profile.c:1162 #, c-format msgid "\t# gawk profile, created %s\n" msgstr "\t# profile gawk, créé %s\n" -#: profile.c:1130 +#: profile.c:1165 msgid "" "\t# BEGIN block(s)\n" "\n" @@ -1665,7 +1673,7 @@ "#t# DÉBUT de bloc(s)\n" "\n" -#: profile.c:1140 +#: profile.c:1175 msgid "" "\t# Rule(s)\n" "\n" @@ -1673,7 +1681,7 @@ "\t# Règle(s)\n" "\n" -#: profile.c:1146 +#: profile.c:1181 msgid "" "\t# END block(s)\n" "\n" @@ -1681,7 +1689,7 @@ "\t# FIN de bloc(s)\n" "\n" -#: profile.c:1166 +#: profile.c:1201 msgid "" "\n" "\t# Functions, listed alphabetically\n" @@ -1689,7 +1697,7 @@ "\n" "\t# Liste alphabétique des fonctions\n" -#: profile.c:1376 +#: profile.c:1413 #, c-format msgid "unexpected type %s in prec_level" msgstr "type %s inattendu dans prec_level" @@ -1773,6 +1781,22 @@ msgid "No previous regular expression" msgstr "Aucune expression régulière antérieure" +#~ msgid "substr: length %g is < 0" +#~ msgstr "substr: longueur %g est < 0" + +#~ msgid "delete: illegal use of variable `%s' as array" +#~ msgstr "" +#~ "destruction: utilisation illégale d'une variable « %s » comme tableau" + +#~ msgid "asort: first argument is not an array" +#~ msgstr "asort(): le premier argument fourni n'est pas dans le tableau" + +#~ msgid "asort: second argument is not an array" +#~ msgstr "asort(): le second argument fourni n'est pas dans le tableau" + +#~ msgid "internal error: Node_var_array with null vname" +#~ msgstr "erreur interne: Node_var_array avec un vname nul" + #~ msgid "invalid syntax in name `%s' for variable assignment" #~ msgstr "syntaxe invalide dans le nom « %s » pour l'affectation de variable" diff -urN gawk-3.1.2/po/gawk.pot gawk-3.1.3/po/gawk.pot --- gawk-3.1.2/po/gawk.pot 2003-03-19 04:25:12.000000000 -0800 +++ gawk-3.1.3/po/gawk.pot 2003-07-07 11:20:32.000000000 -0700 @@ -7,7 +7,8 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" -"POT-Creation-Date: 2003-03-19 14:25+0200\n" +"Report-Msgid-Bugs-To: arnold@skeeve.com\n" +"POT-Creation-Date: 2003-07-07 11:20-0700\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -15,64 +16,61 @@ "Content-Type: text/plain; charset=CHARSET\n" "Content-Transfer-Encoding: 8bit\n" -#: array.c:274 array.c:309 array.c:314 eval.c:494 +#: array.c:112 +#, c-format +msgid "attempt to use scalar parameter `%s' as an array" +msgstr "" + +#: array.c:113 #, c-format msgid "attempt to use scalar `%s' as array" msgstr "" -#: array.c:338 +#: array.c:151 #, c-format -msgid "reference to uninitialized element `%s[\"%s\"]'" +msgid "from %s" msgstr "" -#: array.c:344 +#: array.c:506 #, c-format -msgid "subscript of array `%s' is null string" +msgid "reference to uninitialized element `%s[\"%s\"]'" msgstr "" -#: array.c:412 array.c:425 array.c:466 +#: array.c:512 #, c-format -msgid "delete: index `%s' not in array `%s'" +msgid "subscript of array `%s' is null string" msgstr "" -#: array.c:432 array.c:515 +#: array.c:609 #, c-format -msgid "delete: illegal use of variable `%s' as array" +msgid "delete: index `%s' not in array `%s'" msgstr "" -#: array.c:633 +#: array.c:769 #, c-format msgid "%s: empty (null)\n" msgstr "" -#: array.c:638 +#: array.c:774 #, c-format msgid "%s: empty (zero)\n" msgstr "" -#: array.c:642 +#: array.c:778 #, c-format msgid "%s: table_size = %d, array_size = %d\n" msgstr "" -#: array.c:671 +#: array.c:807 #, c-format msgid "%s: is parameter\n" msgstr "" -#: array.c:676 +#: array.c:812 #, c-format msgid "%s: array_ref to %s\n" msgstr "" -#: array.c:975 -msgid "asort: first argument is not an array" -msgstr "" - -#: array.c:984 -msgid "asort: second argument is not an array" -msgstr "" - #: awkgram.y:208 #, c-format msgid "%s blocks must have an action part" @@ -92,780 +90,793 @@ msgid "regexp constant `/%s/' looks like a C comment, but is not" msgstr "" -#: awkgram.y:340 +#: awkgram.y:340 awkgram.y:615 msgid "statement may have no effect" msgstr "" -#: awkgram.y:431 awkgram.y:451 +#: awkgram.y:435 awkgram.y:455 #, c-format msgid "`%s' used in %s action" msgstr "" -#: awkgram.y:444 awkgram.y:447 +#: awkgram.y:448 awkgram.y:451 msgid "`nextfile' is a gawk extension" msgstr "" -#: awkgram.y:461 +#: awkgram.y:465 msgid "`return' used outside function context" msgstr "" -#: awkgram.y:500 +#: awkgram.y:504 msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'" msgstr "" -#: awkgram.y:513 awkgram.y:520 +#: awkgram.y:517 awkgram.y:524 msgid "`delete array' is a gawk extension" msgstr "" -#: awkgram.y:528 awkgram.y:535 +#: awkgram.y:532 awkgram.y:539 msgid "`delete(array)' is a non-portable tawk extension" msgstr "" -#: awkgram.y:578 +#: awkgram.y:583 +#, c-format +msgid "duplicate case values in switch body: %s" +msgstr "" + +#: awkgram.y:593 +msgid "Duplicate `default' detected in switch body" +msgstr "" + +#: awkgram.y:681 msgid "multistage two-way pipelines don't work" msgstr "" -#: awkgram.y:669 +#: awkgram.y:772 msgid "regular expression on right of assignment" msgstr "" -#: awkgram.y:679 +#: awkgram.y:782 msgid "regular expression on left of `~' or `!~' operator" msgstr "" -#: awkgram.y:687 +#: awkgram.y:790 msgid "regular expression on right of comparison" msgstr "" -#: awkgram.y:754 +#: awkgram.y:857 msgid "non-redirected `getline' undefined inside END action" msgstr "" -#: awkgram.y:781 +#: awkgram.y:884 msgid "call of `length' without parentheses is not portable" msgstr "" -#: awkgram.y:784 +#: awkgram.y:887 msgid "call of `length' without parentheses is deprecated by POSIX" msgstr "" -#: awkgram.y:835 +#: awkgram.y:940 +msgid "use of non-array as array" +msgstr "" + +#: awkgram.y:942 msgid "invalid subscript expression" msgstr "" -#: awkgram.y:1020 +#: awkgram.y:1140 msgid "unexpected newline or end of string" msgstr "" -#: awkgram.y:1115 +#: awkgram.y:1235 msgid "empty program text on command line" msgstr "" -#: awkgram.y:1172 +#: awkgram.y:1292 #, c-format msgid "can't open source file `%s' for reading (%s)" msgstr "" -#: awkgram.y:1207 +#: awkgram.y:1327 #, c-format msgid "can't read sourcefile `%s' (%s)" msgstr "" -#: awkgram.y:1215 +#: awkgram.y:1335 #, c-format msgid "source file `%s' is empty" msgstr "" -#: awkgram.y:1417 awkgram.y:1527 awkgram.y:1545 awkgram.y:1895 awkgram.y:1980 +#: awkgram.y:1537 awkgram.y:1647 awkgram.y:1665 awkgram.y:2015 awkgram.y:2100 msgid "source file does not end in newline" msgstr "" -#: awkgram.y:1481 +#: awkgram.y:1601 msgid "unterminated regexp ends with `\\' at end of file" msgstr "" -#: awkgram.y:1501 +#: awkgram.y:1621 msgid "unterminated regexp" msgstr "" -#: awkgram.y:1504 +#: awkgram.y:1624 msgid "unterminated regexp at end of file" msgstr "" -#: awkgram.y:1571 +#: awkgram.y:1691 msgid "use of `\\ #...' line continuation is not portable" msgstr "" -#: awkgram.y:1583 +#: awkgram.y:1703 msgid "backslash not last character on line" msgstr "" -#: awkgram.y:1628 +#: awkgram.y:1748 msgid "POSIX does not allow operator `**='" msgstr "" -#: awkgram.y:1630 +#: awkgram.y:1750 msgid "old awk does not support operator `**='" msgstr "" -#: awkgram.y:1639 +#: awkgram.y:1759 msgid "POSIX does not allow operator `**'" msgstr "" -#: awkgram.y:1641 +#: awkgram.y:1761 msgid "old awk does not support operator `**'" msgstr "" -#: awkgram.y:1672 +#: awkgram.y:1792 msgid "operator `^=' is not supported in old awk" msgstr "" -#: awkgram.y:1680 +#: awkgram.y:1800 msgid "operator `^' is not supported in old awk" msgstr "" -#: awkgram.y:1764 awkgram.y:1781 +#: awkgram.y:1884 awkgram.y:1901 msgid "unterminated string" msgstr "" -#: awkgram.y:1941 +#: awkgram.y:2061 #, c-format msgid "invalid char '%c' in expression" msgstr "" -#: awkgram.y:2001 +#: awkgram.y:2121 #, c-format msgid "`%s' is a gawk extension" msgstr "" -#: awkgram.y:2004 +#: awkgram.y:2124 #, c-format msgid "`%s' is a Bell Labs extension" msgstr "" -#: awkgram.y:2007 +#: awkgram.y:2127 #, c-format msgid "POSIX does not allow `%s'" msgstr "" -#: awkgram.y:2011 +#: awkgram.y:2131 #, c-format msgid "`%s' is not supported in old awk" msgstr "" -#: awkgram.y:2038 +#: awkgram.y:2158 msgid "`goto' considered harmful!\n" msgstr "" -#: awkgram.y:2102 +#: awkgram.y:2220 #, c-format msgid "%d is invalid as number of arguments for %s" msgstr "" -#: awkgram.y:2121 awkgram.y:2124 +#: awkgram.y:2239 awkgram.y:2242 msgid "match: third argument is a gawk extension" msgstr "" -#: awkgram.y:2137 +#: awkgram.y:2255 #, c-format msgid "%s: string literal as last arg of substitute has no effect" msgstr "" -#: awkgram.y:2140 +#: awkgram.y:2258 #, c-format msgid "%s third parameter is not a changeable object" msgstr "" -#: awkgram.y:2167 awkgram.y:2170 +#: awkgram.y:2285 awkgram.y:2288 msgid "close: second argument is a gawk extension" msgstr "" -#: awkgram.y:2180 +#: awkgram.y:2298 msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore" msgstr "" -#: awkgram.y:2195 +#: awkgram.y:2313 msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore" msgstr "" -#: awkgram.y:2266 +#: awkgram.y:2384 #, c-format msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d" msgstr "" -#: awkgram.y:2299 +#: awkgram.y:2417 #, c-format msgid "function `%s': parameter `%s' shadows global variable" msgstr "" -#: awkgram.y:2411 +#: awkgram.y:2529 #, c-format msgid "could not open `%s' for writing (%s)" msgstr "" -#: awkgram.y:2412 profile.c:93 +#: awkgram.y:2530 profile.c:93 msgid "sending profile to standard error" msgstr "" -#: awkgram.y:2442 +#: awkgram.y:2562 #, c-format msgid "%s: close failed (%s)" msgstr "" -#: awkgram.y:2566 +#: awkgram.y:2684 msgid "shadow_funcs() called twice!" msgstr "" -#: awkgram.y:2593 +#: awkgram.y:2711 msgid "there were shadowed variables." msgstr "" -#: awkgram.y:2666 +#: awkgram.y:2784 #, c-format msgid "function `%s': can't use function name as parameter name" msgstr "" -#: awkgram.y:2676 +#: awkgram.y:2794 #, c-format msgid "function name `%s' previously defined" msgstr "" -#: awkgram.y:2827 awkgram.y:2833 +#: awkgram.y:2945 awkgram.y:2951 #, c-format msgid "function `%s' called but never defined" msgstr "" -#: awkgram.y:2836 +#: awkgram.y:2954 #, c-format msgid "function `%s' defined but never called" msgstr "" -#: awkgram.y:2863 +#: awkgram.y:2981 #, c-format msgid "regexp constant for parameter #%d yields boolean value" msgstr "" -#: awkgram.y:2876 +#: awkgram.y:2994 #, c-format msgid "" "function `%s' called with space between name and `(',\n" "%s" msgstr "" -#: awkgram.y:2878 +#: awkgram.y:2996 msgid "or used as a variable or an array" msgstr "" -#: builtin.c:111 +#: builtin.c:137 #, c-format msgid "%s to \"%s\" failed (%s)" msgstr "" -#: builtin.c:112 +#: builtin.c:138 msgid "standard output" msgstr "" -#: builtin.c:113 +#: builtin.c:139 msgid "reason unknown" msgstr "" -#: builtin.c:126 +#: builtin.c:152 msgid "exp: received non-numeric argument" msgstr "" -#: builtin.c:132 +#: builtin.c:158 #, c-format msgid "exp: argument %g is out of range" msgstr "" -#: builtin.c:190 +#: builtin.c:216 #, c-format msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing" msgstr "" -#: builtin.c:193 +#: builtin.c:219 #, c-format msgid "fflush: cannot flush: file `%s' opened for reading, not writing" msgstr "" -#: builtin.c:205 +#: builtin.c:231 #, c-format msgid "fflush: `%s' is not an open file, pipe or co-process" msgstr "" -#: builtin.c:299 +#: builtin.c:325 msgid "index: received non-string first argument" msgstr "" -#: builtin.c:301 +#: builtin.c:327 msgid "index: received non-string second argument" msgstr "" -#: builtin.c:411 +#: builtin.c:437 msgid "int: received non-numeric argument" msgstr "" -#: builtin.c:428 +#: builtin.c:454 msgid "length: received non-string argument" msgstr "" -#: builtin.c:444 +#: builtin.c:470 msgid "log: received non-numeric argument" msgstr "" -#: builtin.c:447 +#: builtin.c:473 #, c-format msgid "log: received negative argument %g" msgstr "" -#: builtin.c:609 builtin.c:612 +#: builtin.c:635 builtin.c:638 msgid "must use `count$' on all formats or none" msgstr "" -#: builtin.c:714 +#: builtin.c:740 msgid "`$' is not permitted in awk formats" msgstr "" -#: builtin.c:720 +#: builtin.c:746 msgid "arg count with `$' must be > 0" msgstr "" -#: builtin.c:722 +#: builtin.c:748 #, c-format msgid "arg count %ld greater than total number of supplied arguments" msgstr "" -#: builtin.c:724 +#: builtin.c:750 msgid "`$' not permitted after period in format" msgstr "" -#: builtin.c:737 +#: builtin.c:763 msgid "no `$' supplied for positional field width or precision" msgstr "" -#: builtin.c:795 +#: builtin.c:821 msgid "`l' is meaningless in awk formats; ignored" msgstr "" -#: builtin.c:799 +#: builtin.c:825 msgid "`l' is not permitted in POSIX awk formats" msgstr "" -#: builtin.c:810 +#: builtin.c:836 msgid "`L' is meaningless in awk formats; ignored" msgstr "" -#: builtin.c:814 +#: builtin.c:840 msgid "`L' is not permitted in POSIX awk formats" msgstr "" -#: builtin.c:825 +#: builtin.c:851 msgid "`h' is meaningless in awk formats; ignored" msgstr "" -#: builtin.c:829 +#: builtin.c:855 msgid "`h' is not permitted in POSIX awk formats" msgstr "" -#: builtin.c:1078 +#: builtin.c:1055 +#, c-format +msgid "[s]printf: value %g is out of range for `%%%c' format" +msgstr "" + +#: builtin.c:1108 msgid "not enough arguments to satisfy format string" msgstr "" -#: builtin.c:1080 +#: builtin.c:1110 msgid "^ ran out for this one" msgstr "" -#: builtin.c:1085 +#: builtin.c:1115 msgid "[s]printf: format specifier does not have control letter" msgstr "" -#: builtin.c:1088 +#: builtin.c:1118 msgid "too many arguments supplied for format string" msgstr "" -#: builtin.c:1154 builtin.c:1157 +#: builtin.c:1184 builtin.c:1187 msgid "printf: no arguments" msgstr "" -#: builtin.c:1181 +#: builtin.c:1211 msgid "sqrt: received non-numeric argument" msgstr "" -#: builtin.c:1185 +#: builtin.c:1215 #, c-format msgid "sqrt: called with negative argument %g" msgstr "" -#: builtin.c:1207 +#: builtin.c:1238 #, c-format msgid "substr: start index %g is invalid, using 1" msgstr "" -#: builtin.c:1212 +#: builtin.c:1243 #, c-format msgid "substr: non-integer start index %g will be truncated" msgstr "" -#: builtin.c:1231 +#: builtin.c:1262 #, c-format -msgid "substr: length %g is <= 0" +msgid "substr: length %g is not >= 1" msgstr "" -#: builtin.c:1233 +#: builtin.c:1264 #, c-format -msgid "substr: length %g is < 0" +msgid "substr: length %g is not >= 0" msgstr "" -#: builtin.c:1240 +#: builtin.c:1271 #, c-format msgid "substr: non-integer length %g will be truncated" msgstr "" -#: builtin.c:1245 +#: builtin.c:1276 #, c-format msgid "substr: length %g too big for string indexing, truncating to %g" msgstr "" -#: builtin.c:1257 +#: builtin.c:1288 msgid "substr: source string is zero length" msgstr "" -#: builtin.c:1263 +#: builtin.c:1294 #, c-format msgid "substr: start index %g is past end of string" msgstr "" -#: builtin.c:1271 +#: builtin.c:1302 #, c-format msgid "" "substr: length %g at start index %g exceeds length of first argument (%lu)" msgstr "" -#: builtin.c:1306 +#: builtin.c:1337 msgid "strftime: received non-string first argument" msgstr "" -#: builtin.c:1312 +#: builtin.c:1343 msgid "strftime: received empty format string" msgstr "" -#: builtin.c:1321 +#: builtin.c:1352 msgid "strftime: received non-numeric second argument" msgstr "" -#: builtin.c:1384 +#: builtin.c:1415 msgid "mktime: received non-string argument" msgstr "" -#: builtin.c:1429 +#: builtin.c:1460 msgid "system: received non-string argument" msgstr "" -#: builtin.c:1573 +#: builtin.c:1581 eval.c:1883 +#, c-format +msgid "reference to uninitialized field `$%d'" +msgstr "" + +#: builtin.c:1608 msgid "tolower: received non-string argument" msgstr "" -#: builtin.c:1622 +#: builtin.c:1657 msgid "toupper: received non-string argument" msgstr "" -#: builtin.c:1667 +#: builtin.c:1702 msgid "atan2: received non-numeric first argument" msgstr "" -#: builtin.c:1669 +#: builtin.c:1704 msgid "atan2: received non-numeric second argument" msgstr "" -#: builtin.c:1688 +#: builtin.c:1723 msgid "sin: received non-numeric argument" msgstr "" -#: builtin.c:1704 +#: builtin.c:1739 msgid "cos: received non-numeric argument" msgstr "" -#: builtin.c:1748 +#: builtin.c:1788 msgid "srand: received non-numeric argument" msgstr "" -#: builtin.c:1787 +#: builtin.c:1823 msgid "match: third argument is not an array" msgstr "" -#: builtin.c:2264 -msgid "gensub: 3rd argument of 0 treated as 1" +#: builtin.c:2307 +msgid "gensub: third argument of 0 treated as 1" msgstr "" -#: builtin.c:2375 builtin.c:2377 +#: builtin.c:2416 builtin.c:2418 msgid "lshift: received non-numeric first argument" msgstr "" -#: builtin.c:2379 +#: builtin.c:2420 #, c-format msgid "lshift(%lf, %lf): negative values will give strange results" msgstr "" -#: builtin.c:2381 +#: builtin.c:2422 #, c-format msgid "lshift(%lf, %lf): fractional values will be truncated" msgstr "" -#: builtin.c:2383 +#: builtin.c:2424 #, c-format msgid "lshift(%lf, %lf): too large shift value will give strange results" msgstr "" -#: builtin.c:2412 builtin.c:2414 +#: builtin.c:2453 builtin.c:2455 msgid "rshift: received non-numeric first argument" msgstr "" -#: builtin.c:2416 +#: builtin.c:2457 #, c-format msgid "rshift(%lf, %lf): negative values will give strange results" msgstr "" -#: builtin.c:2418 +#: builtin.c:2459 #, c-format msgid "rshift(%lf, %lf): fractional values will be truncated" msgstr "" -#: builtin.c:2420 +#: builtin.c:2461 #, c-format msgid "rshift(%lf, %lf): too large shift value will give strange results" msgstr "" -#: builtin.c:2449 builtin.c:2451 +#: builtin.c:2490 builtin.c:2492 msgid "and: received non-numeric first argument" msgstr "" -#: builtin.c:2453 +#: builtin.c:2494 #, c-format msgid "and(%lf, %lf): negative values will give strange results" msgstr "" -#: builtin.c:2455 +#: builtin.c:2496 #, c-format msgid "and(%lf, %lf): fractional values will be truncated" msgstr "" -#: builtin.c:2484 builtin.c:2486 +#: builtin.c:2525 builtin.c:2527 msgid "or: received non-numeric first argument" msgstr "" -#: builtin.c:2488 +#: builtin.c:2529 #, c-format msgid "or(%lf, %lf): negative values will give strange results" msgstr "" -#: builtin.c:2490 +#: builtin.c:2531 #, c-format msgid "or(%lf, %lf): fractional values will be truncated" msgstr "" -#: builtin.c:2519 builtin.c:2521 +#: builtin.c:2560 builtin.c:2562 msgid "xor: received non-numeric first argument" msgstr "" -#: builtin.c:2523 +#: builtin.c:2564 #, c-format msgid "xor(%lf, %lf): negative values will give strange results" msgstr "" -#: builtin.c:2525 +#: builtin.c:2566 #, c-format msgid "xor(%lf, %lf): fractional values will be truncated" msgstr "" -#: builtin.c:2553 +#: builtin.c:2594 msgid "compl: received non-numeric argument" msgstr "" -#: builtin.c:2555 +#: builtin.c:2596 #, c-format msgid "compl(%lf): negative value will give strange results" msgstr "" -#: builtin.c:2557 +#: builtin.c:2598 #, c-format msgid "compl(%lf): fractional value will be truncated" msgstr "" -#: builtin.c:2728 +#: builtin.c:2771 #, c-format msgid "dcgettext: `%s' is not a valid locale category" msgstr "" -#: eval.c:262 +#: eval.c:266 #, c-format msgid "unknown nodetype %d" msgstr "" -#: eval.c:310 +#: eval.c:312 msgid "buffer overflow in genflags2str" msgstr "" -#: eval.c:555 +#: eval.c:647 #, c-format msgid "for loop: array `%s' changed size from %ld to %ld during loop execution" msgstr "" -#: eval.c:576 +#: eval.c:668 msgid "`break' outside a loop is not portable" msgstr "" -#: eval.c:580 +#: eval.c:672 msgid "`break' outside a loop is not allowed" msgstr "" -#: eval.c:597 +#: eval.c:689 msgid "`continue' outside a loop is not portable" msgstr "" -#: eval.c:601 +#: eval.c:693 msgid "`continue' outside a loop is not allowed" msgstr "" -#: eval.c:635 +#: eval.c:727 msgid "`next' cannot be called from a BEGIN rule" msgstr "" -#: eval.c:637 +#: eval.c:729 msgid "`next' cannot be called from an END rule" msgstr "" -#: eval.c:646 +#: eval.c:738 msgid "`nextfile' cannot be called from a BEGIN rule" msgstr "" -#: eval.c:648 +#: eval.c:740 msgid "`nextfile' cannot be called from an END rule" msgstr "" -#: eval.c:696 +#: eval.c:785 msgid "statement has no effect" msgstr "" -#: eval.c:731 eval.c:761 eval.c:1733 -#, c-format -msgid "reference to uninitialized variable `%s'" -msgstr "" - -#: eval.c:739 eval.c:1721 +#: eval.c:828 eval.c:1726 #, c-format msgid "can't use function name `%s' as variable or array" msgstr "" -#: eval.c:746 eval.c:752 +#: eval.c:835 eval.c:841 #, c-format msgid "reference to uninitialized argument `%s'" msgstr "" -#: eval.c:810 eval.c:1728 profile.c:773 +#: eval.c:848 eval.c:907 eval.c:1732 eval.c:1742 profile.c:807 #, c-format msgid "attempt to use array `%s' in a scalar context" msgstr "" -#: eval.c:910 +#: eval.c:858 eval.c:1752 +#, c-format +msgid "reference to uninitialized variable `%s'" +msgstr "" + +#: eval.c:1007 msgid "" "concatenation: side effects in one expression have changed the length of " "another!" msgstr "" -#: eval.c:935 +#: eval.c:1032 msgid "assignment used in conditional context" msgstr "" -#: eval.c:1026 +#: eval.c:1122 msgid "division by zero attempted" msgstr "" -#: eval.c:1041 +#: eval.c:1137 #, c-format msgid "division by zero attempted in `%%'" msgstr "" -#: eval.c:1056 profile.c:649 +#: eval.c:1152 profile.c:683 #, c-format msgid "illegal type (%s) in tree_eval" msgstr "" -#: eval.c:1232 +#: eval.c:1328 msgid "division by zero attempted in `/='" msgstr "" -#: eval.c:1250 +#: eval.c:1346 #, c-format msgid "division by zero attempted in `%%='" msgstr "" -#: eval.c:1510 -#, c-format -msgid "%s (from %s)" -msgstr "" - -#: eval.c:1569 +#: eval.c:1586 #, c-format msgid "function `%s' called with more arguments than declared" msgstr "" -#: eval.c:1628 +#: eval.c:1633 #, c-format msgid "function `%s' not defined" msgstr "" -#: eval.c:1634 +#: eval.c:1639 #, c-format msgid "function %s called\n" msgstr "" -#: eval.c:1693 +#: eval.c:1698 msgid "" "\n" "\t# Function Call Stack:\n" "\n" msgstr "" -#: eval.c:1696 +#: eval.c:1701 msgid "\t# -- main --\n" msgstr "" -#: eval.c:1850 +#: eval.c:1867 msgid "attempt to field reference from non-numeric value" msgstr "" -#: eval.c:1852 +#: eval.c:1869 msgid "attempt to reference from null string" msgstr "" -#: eval.c:1858 +#: eval.c:1875 #, c-format msgid "attempt to access field %d" msgstr "" -#: eval.c:1874 -#, c-format -msgid "attempt to use scalar parameter `%s' as an array" -msgstr "" - -#: eval.c:1886 eval.c:1893 profile.c:865 +#: eval.c:1896 eval.c:1903 profile.c:900 msgid "assignment is not allowed to result of builtin function" msgstr "" -#: eval.c:1941 +#: eval.c:1951 msgid "`IGNORECASE' is a gawk extension" msgstr "" -#: eval.c:1970 +#: eval.c:1980 msgid "`BINMODE' is a gawk extension" msgstr "" -#: eval.c:2082 +#: eval.c:2092 #, c-format msgid "bad `%sFMT' specification `%s'" msgstr "" -#: eval.c:2160 +#: eval.c:2170 msgid "turning off `--lint' due to assignment to `LINT'" msgstr "" @@ -883,32 +894,32 @@ msgid "extension: library `%s': cannot call function `%s' (%s)\n" msgstr "" -#: ext.c:181 +#: ext.c:183 msgid "Operation Not Supported" msgstr "" -#: field.c:321 +#: field.c:315 msgid "NF set to negative value" msgstr "" -#: field.c:819 +#: field.c:808 msgid "split: second argument is not an array" msgstr "" -#: field.c:854 +#: field.c:842 msgid "split: null string for third arg is a gawk extension" msgstr "" -#: field.c:906 +#: field.c:894 msgid "`FIELDWIDTHS' is a gawk extension" msgstr "" -#: field.c:933 +#: field.c:921 #, c-format msgid "field %d in FIELDWIDTHS, must be > 0" msgstr "" -#: field.c:1006 +#: field.c:994 msgid "null string for `FS' is a gawk extension" msgstr "" @@ -952,7 +963,7 @@ msgid "%s: invalid option -- %c\n" msgstr "" -#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:431 +#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:434 #, c-format msgid "%s: option requires an argument -- %c\n" msgstr "" @@ -967,462 +978,462 @@ msgid "%s: option `-W %s' doesn't allow an argument\n" msgstr "" -#: io.c:257 +#: io.c:305 #, c-format msgid "cannot open file `%s' for reading (%s)" msgstr "" -#: io.c:344 +#: io.c:392 #, c-format msgid "close of fd %d (`%s') failed (%s)" msgstr "" -#: io.c:482 +#: io.c:530 #, c-format msgid "invalid tree type %s in redirect()" msgstr "" -#: io.c:488 +#: io.c:536 #, c-format msgid "expression in `%s' redirection only has numeric value" msgstr "" -#: io.c:494 +#: io.c:542 #, c-format msgid "expression for `%s' redirection has null string value" msgstr "" -#: io.c:499 +#: io.c:547 #, c-format msgid "filename `%s' for `%s' redirection may be result of logical expression" msgstr "" -#: io.c:521 +#: io.c:569 #, c-format msgid "unnecessary mixing of `>' and `>>' for file `%.*s'" msgstr "" -#: io.c:573 +#: io.c:621 #, c-format msgid "can't open pipe `%s' for output (%s)" msgstr "" -#: io.c:582 +#: io.c:630 #, c-format msgid "can't open pipe `%s' for input (%s)" msgstr "" -#: io.c:595 +#: io.c:643 #, c-format msgid "can't open two way socket `%s' for input/output (%s)" msgstr "" -#: io.c:599 +#: io.c:647 #, c-format msgid "can't open two way pipe `%s' for input/output (%s)" msgstr "" -#: io.c:675 +#: io.c:723 #, c-format msgid "can't redirect from `%s' (%s)" msgstr "" -#: io.c:678 +#: io.c:726 #, c-format msgid "can't redirect to `%s' (%s)" msgstr "" -#: io.c:717 +#: io.c:765 msgid "" "reached system limit for open files: starting to multiplex file descriptors" msgstr "" -#: io.c:729 +#: io.c:777 #, c-format msgid "close of `%s' failed (%s)." msgstr "" -#: io.c:736 +#: io.c:784 msgid "too many pipes or input files open" msgstr "" -#: io.c:759 +#: io.c:807 msgid "close: second argument must be `to' or `from'" msgstr "" -#: io.c:773 +#: io.c:821 #, c-format msgid "close: `%.*s' is not an open file, pipe or co-process" msgstr "" -#: io.c:777 +#: io.c:825 msgid "close of redirection that was never opened" msgstr "" -#: io.c:804 +#: io.c:862 #, c-format msgid "close: redirection `%s' not opened with `|&', second argument ignored" msgstr "" -#: io.c:866 +#: io.c:924 #, c-format msgid "failure status (%d) on pipe close of `%s' (%s)" msgstr "" -#: io.c:869 +#: io.c:927 #, c-format msgid "failure status (%d) on file close of `%s' (%s)" msgstr "" -#: io.c:888 +#: io.c:946 #, c-format msgid "no explicit close of socket `%s' provided" msgstr "" -#: io.c:891 +#: io.c:949 #, c-format msgid "no explicit close of co-process `%s' provided" msgstr "" -#: io.c:894 +#: io.c:952 #, c-format msgid "no explicit close of pipe `%s' provided" msgstr "" -#: io.c:897 +#: io.c:955 #, c-format msgid "no explicit close of file `%s' provided" msgstr "" -#: io.c:926 io.c:980 +#: io.c:984 io.c:1038 #, c-format msgid "error writing standard output (%s)" msgstr "" -#: io.c:930 io.c:984 +#: io.c:988 io.c:1042 #, c-format msgid "error writing standard error (%s)" msgstr "" -#: io.c:938 +#: io.c:996 #, c-format msgid "pipe flush of `%s' failed (%s)." msgstr "" -#: io.c:941 +#: io.c:999 #, c-format msgid "co-process flush of pipe to `%s' failed (%s)." msgstr "" -#: io.c:944 +#: io.c:1002 #, c-format msgid "file flush of `%s' failed (%s)." msgstr "" -#: io.c:1103 +#: io.c:1161 msgid "/inet/raw client not ready yet, sorry" msgstr "" -#: io.c:1105 io.c:1142 +#: io.c:1163 io.c:1200 msgid "only root may use `/inet/raw'." msgstr "" -#: io.c:1140 +#: io.c:1198 msgid "/inet/raw server not ready yet, sorry" msgstr "" -#: io.c:1230 +#: io.c:1288 #, c-format msgid "no (known) protocol supplied in special filename `%s'" msgstr "" -#: io.c:1248 +#: io.c:1306 #, c-format msgid "special file name `%s' is incomplete" msgstr "" -#: io.c:1260 +#: io.c:1318 #, c-format msgid "local port invalid in `%s'" msgstr "" -#: io.c:1272 +#: io.c:1330 msgid "must supply a remote hostname to `/inet'" msgstr "" -#: io.c:1287 +#: io.c:1345 msgid "must supply a remote port to `/inet'" msgstr "" -#: io.c:1293 +#: io.c:1351 #, c-format msgid "remote port invalid in `%s'" msgstr "" -#: io.c:1303 +#: io.c:1361 msgid "TCP/IP communications are not supported" msgstr "" -#: io.c:1312 io.c:1492 +#: io.c:1370 io.c:1551 #, c-format msgid "file `%s' is a directory" msgstr "" -#: io.c:1381 +#: io.c:1440 #, c-format msgid "use `PROCINFO[\"%s\"]' instead of `%s'" msgstr "" -#: io.c:1413 +#: io.c:1472 msgid "use `PROCINFO[...]' instead of `/dev/user'" msgstr "" -#: io.c:1478 io.c:1652 +#: io.c:1537 io.c:1711 #, c-format msgid "could not open `%s', mode `%s'" msgstr "" -#: io.c:1703 +#: io.c:1762 #, c-format msgid "close of master pty failed (%s)" msgstr "" -#: io.c:1705 io.c:1857 io.c:2009 +#: io.c:1764 io.c:1916 io.c:2068 #, c-format msgid "close of stdout in child failed (%s)" msgstr "" -#: io.c:1708 +#: io.c:1767 #, c-format msgid "moving slave pty to stdout in child failed (dup: %s)" msgstr "" -#: io.c:1710 io.c:1862 +#: io.c:1769 io.c:1921 #, c-format msgid "close of stdin in child failed (%s)" msgstr "" -#: io.c:1713 +#: io.c:1772 #, c-format msgid "moving slave pty to stdin in child failed (dup: %s)" msgstr "" -#: io.c:1715 io.c:1734 +#: io.c:1774 io.c:1793 #, c-format msgid "close of slave pty failed (%s)" msgstr "" -#: io.c:1808 io.c:1860 io.c:1990 io.c:2012 +#: io.c:1867 io.c:1919 io.c:2049 io.c:2071 #, c-format msgid "moving pipe to stdout in child failed (dup: %s)" msgstr "" -#: io.c:1812 io.c:1865 +#: io.c:1871 io.c:1924 #, c-format msgid "moving pipe to stdin in child failed (dup: %s)" msgstr "" -#: io.c:1829 io.c:2003 +#: io.c:1888 io.c:2062 msgid "restoring stdout in parent process failed\n" msgstr "" -#: io.c:1834 +#: io.c:1893 msgid "restoring stdin in parent process failed\n" msgstr "" -#: io.c:1868 io.c:2014 io.c:2025 +#: io.c:1927 io.c:2073 io.c:2084 #, c-format msgid "close of pipe failed (%s)" msgstr "" -#: io.c:1913 +#: io.c:1972 msgid "`|&' not supported" msgstr "" -#: io.c:1980 +#: io.c:2039 #, c-format msgid "cannot open pipe `%s' (%s)" msgstr "" -#: io.c:2021 +#: io.c:2080 #, c-format msgid "cannot create child process for `%s' (fork: %s)" msgstr "" -#: io.c:2364 +#: io.c:2423 #, c-format msgid "data file `%s' is empty" msgstr "" -#: io.c:2407 io.c:2415 +#: io.c:2466 io.c:2474 msgid "could not allocate more input memory" msgstr "" -#: io.c:2540 io.c:2782 io.c:3046 +#: io.c:2832 io.c:2895 #, c-format msgid "error reading input file `%s': %s" msgstr "" -#: io.c:3281 +#: io.c:3020 msgid "multicharacter value of `RS' is a gawk extension" msgstr "" -#: main.c:322 +#: main.c:324 msgid "`-m[fr]' option irrelevant in gawk" msgstr "" -#: main.c:324 +#: main.c:326 msgid "-m option usage: `-m[fr] nnn'" msgstr "" -#: main.c:341 +#: main.c:343 #, c-format msgid "%s: option `-W %s' unrecognized, ignored\n" msgstr "" -#: main.c:378 +#: main.c:380 msgid "empty argument to `--source' ignored" msgstr "" -#: main.c:448 +#: main.c:451 msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'" msgstr "" -#: main.c:453 +#: main.c:456 msgid "`--posix' overrides `--traditional'" msgstr "" -#: main.c:464 +#: main.c:467 msgid "`--posix'/`--traditional' overrides `--non-decimal-data'" msgstr "" -#: main.c:468 +#: main.c:471 #, c-format msgid "running %s setuid root may be a security problem" msgstr "" -#: main.c:509 +#: main.c:512 #, c-format msgid "can't set binary mode on stdin (%s)" msgstr "" -#: main.c:512 +#: main.c:515 #, c-format msgid "can't set binary mode on stdout (%s)" msgstr "" -#: main.c:514 +#: main.c:517 #, c-format msgid "can't set binary mode on stderr (%s)" msgstr "" -#: main.c:544 +#: main.c:547 msgid "no program text at all!" msgstr "" -#: main.c:612 +#: main.c:620 #, c-format msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n" msgstr "" -#: main.c:614 +#: main.c:622 #, c-format msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n" msgstr "" -#: main.c:619 +#: main.c:627 msgid "POSIX options:\t\tGNU long options:\n" msgstr "" -#: main.c:620 +#: main.c:628 msgid "\t-f progfile\t\t--file=progfile\n" msgstr "" -#: main.c:621 +#: main.c:629 msgid "\t-F fs\t\t\t--field-separator=fs\n" msgstr "" -#: main.c:622 +#: main.c:630 msgid "\t-v var=val\t\t--assign=var=val\n" msgstr "" -#: main.c:623 +#: main.c:631 msgid "\t-m[fr] val\n" msgstr "" -#: main.c:624 +#: main.c:632 msgid "\t-W compat\t\t--compat\n" msgstr "" -#: main.c:625 +#: main.c:633 msgid "\t-W copyleft\t\t--copyleft\n" msgstr "" -#: main.c:626 +#: main.c:634 msgid "\t-W copyright\t\t--copyright\n" msgstr "" -#: main.c:627 +#: main.c:635 msgid "\t-W dump-variables[=file]\t--dump-variables[=file]\n" msgstr "" -#: main.c:628 +#: main.c:636 msgid "\t-W gen-po\t\t--gen-po\n" msgstr "" -#: main.c:629 +#: main.c:637 msgid "\t-W help\t\t\t--help\n" msgstr "" -#: main.c:630 +#: main.c:638 msgid "\t-W lint[=fatal]\t\t--lint[=fatal]\n" msgstr "" -#: main.c:631 +#: main.c:639 msgid "\t-W lint-old\t\t--lint-old\n" msgstr "" -#: main.c:632 +#: main.c:640 msgid "\t-W non-decimal-data\t--non-decimal-data\n" msgstr "" -#: main.c:634 +#: main.c:642 msgid "\t-W nostalgia\t\t--nostalgia\n" msgstr "" -#: main.c:637 +#: main.c:645 msgid "\t-W parsedebug\t\t--parsedebug\n" msgstr "" -#: main.c:639 +#: main.c:647 msgid "\t-W profile[=file]\t--profile[=file]\n" msgstr "" -#: main.c:640 +#: main.c:648 msgid "\t-W posix\t\t--posix\n" msgstr "" -#: main.c:641 +#: main.c:649 msgid "\t-W re-interval\t\t--re-interval\n" msgstr "" -#: main.c:642 +#: main.c:650 msgid "\t-W source=program-text\t--source=program-text\n" msgstr "" -#: main.c:643 +#: main.c:651 msgid "\t-W traditional\t\t--traditional\n" msgstr "" -#: main.c:644 +#: main.c:652 msgid "\t-W usage\t\t--usage\n" msgstr "" -#: main.c:645 +#: main.c:653 msgid "\t-W version\t\t--version\n" msgstr "" -#: main.c:649 +#: main.c:657 msgid "" "\n" "To report bugs, see node `Bugs' in `gawk.info', which is\n" @@ -1430,21 +1441,21 @@ "\n" msgstr "" -#: main.c:653 +#: main.c:661 msgid "" "gawk is a pattern scanning and processing language.\n" "By default it reads standard input and writes standard output.\n" "\n" msgstr "" -#: main.c:657 +#: main.c:665 msgid "" "Examples:\n" "\tgawk '{ sum += $1 }; END { print sum }' file\n" "\tgawk -F: '{ print $1 }' /etc/passwd\n" msgstr "" -#: main.c:669 +#: main.c:682 #, c-format msgid "" "Copyright (C) 1989, 1991-%d Free Software Foundation.\n" @@ -1456,7 +1467,7 @@ "\n" msgstr "" -#: main.c:677 +#: main.c:690 msgid "" "This program is distributed in the hope that it will be useful,\n" "but WITHOUT ANY WARRANTY; without even the implied warranty of\n" @@ -1465,53 +1476,53 @@ "\n" msgstr "" -#: main.c:683 +#: main.c:696 msgid "" "You should have received a copy of the GNU General Public License\n" "along with this program; if not, write to the Free Software\n" "Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n" msgstr "" -#: main.c:713 +#: main.c:730 msgid "-Ft does not set FS to tab in POSIX awk" msgstr "" -#: main.c:944 +#: main.c:956 #, c-format msgid "" "%s: `%s' argument to `-v' not in `var=value' form\n" "\n" msgstr "" -#: main.c:964 +#: main.c:976 #, c-format msgid "`%s' is not a legal variable name" msgstr "" -#: main.c:967 +#: main.c:979 #, c-format msgid "`%s' is not a variable name, looking for file `%s=%s'" msgstr "" -#: main.c:995 +#: main.c:1012 msgid "floating point exception" msgstr "" -#: main.c:1002 +#: main.c:1019 msgid "fatal error: internal error" msgstr "" -#: main.c:1052 +#: main.c:1069 #, c-format msgid "no pre-opened fd %d" msgstr "" -#: main.c:1057 +#: main.c:1074 #, c-format msgid "could not pre-open /dev/null for fd %d" msgstr "" -#: main.c:1080 main.c:1089 +#: main.c:1097 main.c:1106 #, c-format msgid "could not find groups: %s" msgstr "" @@ -1532,23 +1543,23 @@ msgid "fatal: " msgstr "" -#: node.c:59 node.c:66 node.c:75 node.c:89 node.c:116 +#: node.c:58 node.c:65 node.c:74 node.c:88 node.c:115 msgid "can't convert string to float" msgstr "" -#: node.c:357 +#: node.c:355 msgid "backslash at end of string" msgstr "" -#: node.c:544 +#: node.c:539 msgid "POSIX does not allow `\\x' escapes" msgstr "" -#: node.c:550 +#: node.c:545 msgid "no hex digits in `\\x' escape sequence" msgstr "" -#: node.c:584 +#: node.c:579 #, c-format msgid "escape sequence `\\%c' treated as plain `%c'" msgstr "" @@ -1563,48 +1574,45 @@ msgid "could not open `%s' for writing: %s" msgstr "" -#: profile.c:409 -msgid "internal error: Node_var with null vname" +#: profile.c:449 +#, c-format +msgid "internal error: %s with null vname" msgstr "" -#: profile.c:471 +#: profile.c:512 msgid "# treated internally as `delete'" msgstr "" -#: profile.c:545 -msgid "internal error: Node_var_array with null vname" -msgstr "" - -#: profile.c:1127 +#: profile.c:1162 #, c-format msgid "\t# gawk profile, created %s\n" msgstr "" -#: profile.c:1130 +#: profile.c:1165 msgid "" "\t# BEGIN block(s)\n" "\n" msgstr "" -#: profile.c:1140 +#: profile.c:1175 msgid "" "\t# Rule(s)\n" "\n" msgstr "" -#: profile.c:1146 +#: profile.c:1181 msgid "" "\t# END block(s)\n" "\n" msgstr "" -#: profile.c:1166 +#: profile.c:1201 msgid "" "\n" "\t# Functions, listed alphabetically\n" msgstr "" -#: profile.c:1376 +#: profile.c:1413 #, c-format msgid "unexpected type %s in prec_level" msgstr "" Binary files gawk-3.1.2/po/he.gmo and gawk-3.1.3/po/he.gmo differ diff -urN gawk-3.1.2/po/he.po gawk-3.1.3/po/he.po --- gawk-3.1.2/po/he.po 2003-03-19 04:25:12.000000000 -0800 +++ gawk-3.1.3/po/he.po 2003-07-07 11:20:33.000000000 -0700 @@ -5,7 +5,8 @@ msgid "" msgstr "" "Project-Id-Version: gawk 3.1.1a\n" -"POT-Creation-Date: 2003-03-19 14:25+0200\n" +"Report-Msgid-Bugs-To: arnold@skeeve.com\n" +"POT-Creation-Date: 2003-07-07 11:20-0700\n" "PO-Revision-Date: 2002-04-28 21:46+0300\n" "Last-Translator: Eli Zaretskii \n" "Language-Team: Hebrew \n" @@ -13,64 +14,63 @@ "Content-Type: text/plain; charset=ISO-8859-8\n" "Content-Transfer-Encoding: 8-bit\n" -#: array.c:274 array.c:309 array.c:314 eval.c:494 +#: array.c:112 +#, c-format +msgid "attempt to use scalar parameter `%s' as an array" +msgstr "êøòî äéä åìéàë `%s' éøì÷ñ øèîøôá ùåîéù ïåéñð" + +#: array.c:113 #, c-format msgid "attempt to use scalar `%s' as array" msgstr "êøòîë `%s' øàì÷ñá éåâù ùåîéù" -#: array.c:338 +# This is not translated because it cannot be reworded in Hebrew +# without looking awkward. +#: array.c:151 +#, fuzzy, c-format +msgid "from %s" +msgstr "%s (from %s)" + +#: array.c:506 #, c-format msgid "reference to uninitialized element `%s[\"%s\"]'" msgstr "ìçåúî åðéàù `%s[\"%s\"]' èðîìàì äééðô" -#: array.c:344 +#: array.c:512 #, c-format msgid "subscript of array `%s' is null string" msgstr "`%s' êøòî ïééöîë ä÷éø úæåøçîá ùåîéù" -#: array.c:412 array.c:425 array.c:466 +#: array.c:609 #, c-format msgid "delete: index `%s' not in array `%s'" msgstr "`%s' ïééöî ìéëî åðéà `%s' êøòî :delete" -#: array.c:432 array.c:515 -#, c-format -msgid "delete: illegal use of variable `%s' as array" -msgstr "êøòîë `%s' äðúùîá éåâù ùåîéù :delete" - -#: array.c:633 +#: array.c:769 #, c-format msgid "%s: empty (null)\n" msgstr "%s: (ñôåàî) ÷éø\n" -#: array.c:638 +#: array.c:774 #, c-format msgid "%s: empty (zero)\n" msgstr "%s: (ä÷éø hash úìáè) ÷éø\n" -#: array.c:642 +#: array.c:778 #, c-format msgid "%s: table_size = %d, array_size = %d\n" msgstr "%s: table_size = %d, array_size = %d\n" -#: array.c:671 +#: array.c:807 #, c-format msgid "%s: is parameter\n" msgstr "øèîøô åðéä %s\n" -#: array.c:676 +#: array.c:812 #, c-format msgid "%s: array_ref to %s\n" msgstr "%s: %s-ì (array_ref) äéðôä\n" -#: array.c:975 -msgid "asort: first argument is not an array" -msgstr "êøòî åðéà ïåùàø èðîåâøà :asort" - -#: array.c:984 -msgid "asort: second argument is not an array" -msgstr "êøòî åðéà éðù èðîåâøà :asort" - #: awkgram.y:208 #, fuzzy, c-format msgid "%s blocks must have an action part" @@ -91,262 +91,275 @@ msgid "regexp constant `/%s/' looks like a C comment, but is not" msgstr "äøòä åðéà êà ,C úôùá äøòä åîë äàøð `/%s/' éøìåâø éåèéá" -#: awkgram.y:340 +#: awkgram.y:340 awkgram.y:615 msgid "statement may have no effect" msgstr "úéìëú íåù äéäú àì äæ éåèéáìù ïëúé" -#: awkgram.y:431 awkgram.y:451 +#: awkgram.y:435 awkgram.y:455 #, fuzzy, c-format msgid "`%s' used in %s action" msgstr "END åà BEGIN ìù äìåòô úøãâäá `next'-á ùåîéù" -#: awkgram.y:444 awkgram.y:447 +#: awkgram.y:448 awkgram.y:451 msgid "`nextfile' is a gawk extension" msgstr "gawk-ì úéôéöôñ äáçøä åðéä `nextfile'" -#: awkgram.y:461 +#: awkgram.y:465 msgid "`return' used outside function context" msgstr "äéö÷ðåô ìù èñ÷èðå÷á àìù `return'-á ùåîéù" -#: awkgram.y:500 +#: awkgram.y:504 msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'" msgstr "`print \"\"' úåéäì íúñä ïî êéøö END åà BEGIN éììëá èåùô `print'" -#: awkgram.y:513 awkgram.y:520 +#: awkgram.y:517 awkgram.y:524 msgid "`delete array' is a gawk extension" msgstr "gawk-ì úéôéöôñ äáçøä åðéä `delete array'" -#: awkgram.y:528 awkgram.y:535 +#: awkgram.y:532 awkgram.y:539 #, fuzzy msgid "`delete(array)' is a non-portable tawk extension" msgstr "gawk-ì úéôéöôñ äáçøä åðéä `delete array'" -#: awkgram.y:578 +#: awkgram.y:583 +#, c-format +msgid "duplicate case values in switch body: %s" +msgstr "" + +#: awkgram.y:593 +msgid "Duplicate `default' detected in switch body" +msgstr "" + +#: awkgram.y:681 msgid "multistage two-way pipelines don't work" msgstr "íéãáåò íðéà íéáìù éáåøî íééðååéë-åã íé÷éôà" -#: awkgram.y:669 +#: awkgram.y:772 msgid "regular expression on right of assignment" msgstr "êøò úîùä úàøåä ìù ïéîé ãöá éøìåâø éåèéá" -#: awkgram.y:679 +#: awkgram.y:782 msgid "regular expression on left of `~' or `!~' operator" msgstr "`!~' åà `~' øåèøôåàì ìàîùî éøìåâø éåèéá" -#: awkgram.y:687 +#: awkgram.y:790 msgid "regular expression on right of comparison" msgstr "äàååùä ìù ïéîé ãöá éøìåâø éåèéá" -#: awkgram.y:754 +#: awkgram.y:857 msgid "non-redirected `getline' undefined inside END action" msgstr "END úìåòô êåúá øãâåî åðéà äééðôä àìì `getline'" -#: awkgram.y:781 +#: awkgram.y:884 msgid "call of `length' without parentheses is not portable" msgstr "úéìéáèøåô äðéà íééøâåñ àìì `length'-ì äàéø÷" -#: awkgram.y:784 +#: awkgram.y:887 msgid "call of `length' without parentheses is deprecated by POSIX" msgstr "POSIX ï÷úì ãåâéðá äðéä íééøâåñ àìì `length'-ì äàéø÷" -#: awkgram.y:835 +#: awkgram.y:940 +msgid "use of non-array as array" +msgstr "" + +#: awkgram.y:942 msgid "invalid subscript expression" msgstr "êøòî ïééöîá éåâù øéáçú ìòá éåèéá" -#: awkgram.y:1020 +#: awkgram.y:1140 #, fuzzy msgid "unexpected newline or end of string" msgstr "éåôö-éúìá íå÷îá äøåù óåñ" -#: awkgram.y:1115 +#: awkgram.y:1235 msgid "empty program text on command line" msgstr "äãå÷ôä úøåùî äìá÷úä ä÷éø úéðëú" -#: awkgram.y:1172 +#: awkgram.y:1292 #, c-format msgid "can't open source file `%s' for reading (%s)" msgstr "åúàéø÷ íùì `%s' øå÷î õáå÷ úçéúôá (%s) äì÷ú" -#: awkgram.y:1207 +#: awkgram.y:1327 #, c-format msgid "can't read sourcefile `%s' (%s)" msgstr "`%s' øå÷î õáå÷î äàéø÷á (%s) äì÷ú" -#: awkgram.y:1215 +#: awkgram.y:1335 #, c-format msgid "source file `%s' is empty" msgstr "÷éø åðéä `%s' øå÷î õáå÷" -#: awkgram.y:1417 awkgram.y:1527 awkgram.y:1545 awkgram.y:1895 awkgram.y:1980 +#: awkgram.y:1537 awkgram.y:1647 awkgram.y:1665 awkgram.y:2015 awkgram.y:2100 msgid "source file does not end in newline" msgstr "äøåù-óåñ åúá íééúñî åðéà øå÷îä õáå÷" -#: awkgram.y:1481 +#: awkgram.y:1601 msgid "unterminated regexp ends with `\\' at end of file" msgstr "õáå÷ä óñá `\\'-á íééúñî øåîâ-éúìá éøìåâø éåèéá" -#: awkgram.y:1501 +#: awkgram.y:1621 msgid "unterminated regexp" msgstr "øåîâ-éúìá éøìåâø éåèéá" -#: awkgram.y:1504 +#: awkgram.y:1624 msgid "unterminated regexp at end of file" msgstr "õáå÷ä óåñá øåîâ-éúìá éøìåâø éåèéá" -#: awkgram.y:1571 +#: awkgram.y:1691 msgid "use of `\\ #...' line continuation is not portable" msgstr "éìéáèøåô åðéà äøåù êùîäì ïîéñë `\\ #...'-á ùåîéù" -#: awkgram.y:1583 +#: awkgram.y:1703 msgid "backslash not last character on line" msgstr "äøåùá ïåøçà åú åðéàù êåôä ïñëåì" -#: awkgram.y:1628 +#: awkgram.y:1748 msgid "POSIX does not allow operator `**='" msgstr "`**=' øåèøôåà äùøî åðéà POSIX" -#: awkgram.y:1630 +#: awkgram.y:1750 msgid "old awk does not support operator `**='" msgstr "`**=' øåèøôåàá êîåú åðéà ïùé awk" -#: awkgram.y:1639 +#: awkgram.y:1759 msgid "POSIX does not allow operator `**'" msgstr "`**' øåèøôåà äùøî åðéà POSIX" -#: awkgram.y:1641 +#: awkgram.y:1761 msgid "old awk does not support operator `**'" msgstr "`**' øåèøôåàá êîåú åðéà ïùé awk" -#: awkgram.y:1672 +#: awkgram.y:1792 msgid "operator `^=' is not supported in old awk" msgstr "ïùé awk-á êîúð åðéà `^=' øåèøôåà" -#: awkgram.y:1680 +#: awkgram.y:1800 msgid "operator `^' is not supported in old awk" msgstr "ïùé awk-á êîúð åðéà `^' øåèøôåà" -#: awkgram.y:1764 awkgram.y:1781 +#: awkgram.y:1884 awkgram.y:1901 msgid "unterminated string" msgstr "äøåîâ-éúìá úæåøçî" -#: awkgram.y:1941 +#: awkgram.y:2061 #, c-format msgid "invalid char '%c' in expression" msgstr "éåèéáá '%c' éåâù åú" -#: awkgram.y:2001 +#: awkgram.y:2121 #, c-format msgid "`%s' is a gawk extension" msgstr "gawk-ì úéôéöôñ äáçøä äðéä `%s'" -#: awkgram.y:2004 +#: awkgram.y:2124 #, c-format msgid "`%s' is a Bell Labs extension" msgstr "Bell úåãáòî úñøâá awk-ì úéôéöôñ äáçøä åðéä `%s'" -#: awkgram.y:2007 +#: awkgram.y:2127 #, c-format msgid "POSIX does not allow `%s'" msgstr "`%s' äùøî åðéà POSIX" -#: awkgram.y:2011 +#: awkgram.y:2131 #, c-format msgid "`%s' is not supported in old awk" msgstr "ïùé awk-á êîúð åðéà `%s'" -#: awkgram.y:2038 +#: awkgram.y:2158 msgid "`goto' considered harmful!\n" msgstr "!òø-òâô áùçð `goto'\n" -#: awkgram.y:2102 +#: awkgram.y:2220 #, c-format msgid "%d is invalid as number of arguments for %s" msgstr "íéèðîåâøà øôñîë %d ìá÷ì ìåëé åðéà %s" -#: awkgram.y:2121 awkgram.y:2124 +#: awkgram.y:2239 awkgram.y:2242 msgid "match: third argument is a gawk extension" msgstr "gawk-ì úéôéöôñ äáçøä åðéä `match' ìù éùéìù èðîåâøà" -#: awkgram.y:2137 +#: awkgram.y:2255 #, c-format msgid "%s: string literal as last arg of substitute has no effect" msgstr "úéìëú íåù äì ïéà `%s' ìù ïåøçà èðîåâøàë äòåá÷ úæåøçî" -#: awkgram.y:2140 +#: awkgram.y:2258 #, fuzzy, c-format msgid "%s third parameter is not a changeable object" msgstr "éåðéù-øá è÷ééáåà åðéà `sub' ìù éùéìù èðîåâøà" -#: awkgram.y:2167 awkgram.y:2170 +#: awkgram.y:2285 awkgram.y:2288 msgid "close: second argument is a gawk extension" msgstr "gawk-ì úéôéöôñ äáçøä åðéä `close' ìù éðù èðîåâøà" -#: awkgram.y:2180 +#: awkgram.y:2298 msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore" msgstr "èðîåâøà úîã÷áù ïåúçú-ó÷î ÷ìñì ùé :dcgettext(_\"...\")-á éåâù ùåîéù" -#: awkgram.y:2195 +#: awkgram.y:2313 msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore" msgstr "èðîåâøà úîã÷áù ïåúçú-ó÷î ÷ìñì ùé :dncgettext(_\"...\")-á éåâù ùåîéù" -#: awkgram.y:2266 +#: awkgram.y:2384 #, c-format msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d" msgstr "`%s' äéö÷ðåôá %d 'ñî øèîøôì ääæ ,`%s' ,%d 'ñî øèîøô ìù åîù" -#: awkgram.y:2299 +#: awkgram.y:2417 #, c-format msgid "function `%s': parameter `%s' shadows global variable" msgstr "éìáåìâ äðúùî ìò ìéôàî `%s' äéö÷ðåôá `%s' øèîøô" -#: awkgram.y:2411 +#: awkgram.y:2529 #, c-format msgid "could not open `%s' for writing (%s)" msgstr "äáéúë íùì `%s' úçéúôá (%s) äì÷ú" -#: awkgram.y:2412 profile.c:93 +#: awkgram.y:2530 profile.c:93 msgid "sending profile to standard error" msgstr "éð÷ú úåàéâù õåøòì çìùð òåöéá ìéôåøô" -#: awkgram.y:2442 +#: awkgram.y:2562 #, c-format msgid "%s: close failed (%s)" msgstr "`%s' úøéâñ úòá (%s) äì÷ú" -#: awkgram.y:2566 +#: awkgram.y:2684 msgid "shadow_funcs() called twice!" msgstr "!íééîòô äàø÷ð shadow_funcs()" -#: awkgram.y:2593 +#: awkgram.y:2711 msgid "there were shadowed variables." msgstr "" -#: awkgram.y:2666 +#: awkgram.y:2784 #, c-format msgid "function `%s': can't use function name as parameter name" msgstr "øèîøô íùë ùîùì ìåëé åðéà äéö÷ðåô íù :`%s' äéö÷ðåôá" -#: awkgram.y:2676 +#: awkgram.y:2794 #, c-format msgid "function name `%s' previously defined" msgstr "úøãâåî øáë `%s' íùá äéö÷ðåô" -#: awkgram.y:2827 awkgram.y:2833 +#: awkgram.y:2945 awkgram.y:2951 #, c-format msgid "function `%s' called but never defined" msgstr "úøãâåî äðéàù `%s' äéö÷ðåôì äàéø÷" -#: awkgram.y:2836 +#: awkgram.y:2954 #, c-format msgid "function `%s' defined but never called" msgstr "úàø÷ð àì êà ,äøãâåä `%s' äéö÷ðåô" -#: awkgram.y:2863 +#: awkgram.y:2981 #, c-format msgid "regexp constant for parameter #%d yields boolean value" msgstr "éðàéìåá êøò áéðî %d 'ñî øèîøôë òåá÷ éøìåâø éåèéá" -#: awkgram.y:2876 +#: awkgram.y:2994 #, c-format msgid "" "function `%s' called with space between name and `(',\n" @@ -355,479 +368,482 @@ ",`(' ïéáì äîù ïéá íéçååø íò `%s' äéö÷ðåôì äàéø÷\n" "%s" -#: awkgram.y:2878 +#: awkgram.y:2996 #, fuzzy msgid "or used as a variable or an array" msgstr "êøòî åà äðúùîë `%s' äéö÷ðåô íùá ùîúùäì ïéà" -#: builtin.c:111 +#: builtin.c:137 #, c-format msgid "%s to \"%s\" failed (%s)" msgstr "%s é\"ò \"%s\"-ì äáéúëá (%s) äì÷ú" -#: builtin.c:112 +#: builtin.c:138 msgid "standard output" msgstr "úéèøãðèñ èìô úãéçé" -#: builtin.c:113 +#: builtin.c:139 msgid "reason unknown" msgstr "äòåãé-éúìá äáéñî" -#: builtin.c:126 +#: builtin.c:152 msgid "exp: received non-numeric argument" msgstr "øôñî åðéà èðîåâøà :exp" -#: builtin.c:132 +#: builtin.c:158 #, c-format msgid "exp: argument %g is out of range" msgstr "øúåîä íåçúá åðéà %g èðîåâøà :exp" -#: builtin.c:190 +#: builtin.c:216 #, c-format msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing" msgstr "äáéúëì àì ,äàéø÷ì çåúô `%s' ÷éôà :õöåçä ï÷åøì ïúéð àì :fflush" -#: builtin.c:193 +#: builtin.c:219 #, c-format msgid "fflush: cannot flush: file `%s' opened for reading, not writing" msgstr "äáéúëì àì ,äàéø÷ì çåúô `%s' õáå÷ :õöåçä ï÷åøì ïúéð àì :fflush" -#: builtin.c:205 +#: builtin.c:231 #, c-format msgid "fflush: `%s' is not an open file, pipe or co-process" msgstr "ìéá÷î êéìäú åà çåúô ÷éôà ,çåúô õáå÷ åðéà `%s' :fflush" -#: builtin.c:299 +#: builtin.c:325 msgid "index: received non-string first argument" msgstr "úæåøçî åðéà ïåùàø èðîåâøà :index" -#: builtin.c:301 +#: builtin.c:327 msgid "index: received non-string second argument" msgstr "úæåøçî åðéà éðù èðîåâøà :index" -#: builtin.c:411 +#: builtin.c:437 msgid "int: received non-numeric argument" msgstr "øôñî åðéà èðîåâøà :int" -#: builtin.c:428 +#: builtin.c:454 msgid "length: received non-string argument" msgstr "úæåøçî åðéà èðîåâøà :length" -#: builtin.c:444 +#: builtin.c:470 msgid "log: received non-numeric argument" msgstr "øôñî åðéà èðîåâøà :log" -#: builtin.c:447 +#: builtin.c:473 #, c-format msgid "log: received negative argument %g" msgstr "%g éìéìù èðîåâøà íò àø÷ð :log" -#: builtin.c:609 builtin.c:612 +#: builtin.c:635 builtin.c:638 msgid "must use `count$' on all formats or none" msgstr "ãçà óàá åà íéèîøåôä ìëá åà øúåî `count$'-á ùåîéù" -#: builtin.c:714 +#: builtin.c:740 msgid "`$' is not permitted in awk formats" msgstr "awk ìù íéèîøåôá ùåîéùì øåñà `$'" -#: builtin.c:720 +#: builtin.c:746 msgid "arg count with `$' must be > 0" msgstr "0-î ìåãâ úåéäì áééç `$' ãéì èðîåâøàä äðåî" -#: builtin.c:722 +#: builtin.c:748 #, fuzzy, c-format msgid "arg count %ld greater than total number of supplied arguments" msgstr "íéèðîåâøàä ìù ììåëä íøôñîî ìåãâ %d èðîåâøàä äðåî" -#: builtin.c:724 +#: builtin.c:750 msgid "`$' not permitted after period in format" msgstr "èîøåôá äãå÷ðä éøçà òéôåäì ìåëé åðéà `$'" -#: builtin.c:737 +#: builtin.c:763 msgid "no `$' supplied for positional field width or precision" msgstr "å÷åéã åà äãù áçåø ïééöîá èðîåâøàä äðåî øåáò `$' àöîð àì" -#: builtin.c:795 +#: builtin.c:821 msgid "`l' is meaningless in awk formats; ignored" msgstr "çðæåä ;awk ìù èîøåôá úåòîùî øñç åðéä `l'" -#: builtin.c:799 +#: builtin.c:825 msgid "`l' is not permitted in POSIX awk formats" msgstr "POSIX éô-ìò awk ìù èîøåôá òéôåäì ìåëé åðéà `l'" -#: builtin.c:810 +#: builtin.c:836 msgid "`L' is meaningless in awk formats; ignored" msgstr "çðæåä ;awk ìù èîøåôá úåòîùî øñç åðéä `L'" -#: builtin.c:814 +#: builtin.c:840 msgid "`L' is not permitted in POSIX awk formats" msgstr "POSIX éô-ìò awk ìù èîøåôá òéôåäì ìåëé åðéà `L'" -#: builtin.c:825 +#: builtin.c:851 msgid "`h' is meaningless in awk formats; ignored" msgstr "çðæåä ;awk ìù èîøåôá úåòîùî øñç åðéä `h'" -#: builtin.c:829 +#: builtin.c:855 msgid "`h' is not permitted in POSIX awk formats" msgstr "POSIX éô-ìò awk ìù èîøåôá òéôåäì ìåëé åðéà `h'" -#: builtin.c:1078 +#: builtin.c:1055 +#, c-format +msgid "[s]printf: value %g is out of range for `%%%c' format" +msgstr "" + +#: builtin.c:1108 msgid "not enough arguments to satisfy format string" msgstr "èîøåôä øåáò íéèðîåâøà ÷éôñî ïéà" -#: builtin.c:1080 +#: builtin.c:1110 msgid "^ ran out for this one" msgstr "^ íéèðîåâøàä éì åøîâð ïàë" -#: builtin.c:1085 +#: builtin.c:1115 msgid "[s]printf: format specifier does not have control letter" msgstr "äøîää úø÷á úåà ìéëî åðéà èîøåôä :[s]printf" -#: builtin.c:1088 +#: builtin.c:1118 msgid "too many arguments supplied for format string" msgstr "èîøåôä øåáò íéèðîåâøà éãî øúåé" -#: builtin.c:1154 builtin.c:1157 +#: builtin.c:1184 builtin.c:1187 msgid "printf: no arguments" msgstr "èðîåâøà óà ïéà :printf" -#: builtin.c:1181 +#: builtin.c:1211 msgid "sqrt: received non-numeric argument" msgstr "øôñî åðéà èðîåâøà :sqrt" -#: builtin.c:1185 +#: builtin.c:1215 #, c-format msgid "sqrt: called with negative argument %g" msgstr "%g éìéìù èðîåâøà íò àø÷ð :sqrt" -#: builtin.c:1207 +#: builtin.c:1238 #, c-format msgid "substr: start index %g is invalid, using 1" msgstr "1-á óìçåä ,éåâù åðéä %g äìçúä ïééöî :substr" -#: builtin.c:1212 +#: builtin.c:1243 #, c-format msgid "substr: non-integer start index %g will be truncated" msgstr "õöå÷é ,íìù øôñî åðéàù, %g äìçúä ïééöî ìù åëøò :substr" -#: builtin.c:1231 -#, c-format -msgid "substr: length %g is <= 0" +#: builtin.c:1262 +#, fuzzy, c-format +msgid "substr: length %g is not >= 1" msgstr "0-î ìåãâ øôñî åððéà %g êøåà :substr" -#: builtin.c:1233 +#: builtin.c:1264 #, fuzzy, c-format -msgid "substr: length %g is < 0" +msgid "substr: length %g is not >= 0" msgstr "0-î ìåãâ øôñî åððéà %g êøåà :substr" -#: builtin.c:1240 +#: builtin.c:1271 #, c-format msgid "substr: non-integer length %g will be truncated" msgstr "õöå÷é ,íìù øôñî åðéàù ,%g êøåà :substr" -#: builtin.c:1245 +#: builtin.c:1276 #, c-format msgid "substr: length %g too big for string indexing, truncating to %g" msgstr "" -#: builtin.c:1257 +#: builtin.c:1288 msgid "substr: source string is zero length" msgstr "ñôà êøåàá äðéä øå÷îä úæåøçî :substr" -#: builtin.c:1263 +#: builtin.c:1294 #, fuzzy, c-format msgid "substr: start index %g is past end of string" msgstr "úæåøçîä óåñì øáòî åðéä %d äìçúä ïééöî :substr" -#: builtin.c:1271 +#: builtin.c:1302 #, fuzzy, c-format msgid "" "substr: length %g at start index %g exceeds length of first argument (%lu)" msgstr "" "%d äëøåàå %d ïééöîá äúìéçúù úæåøçî-úúì ÷éôñî åðéà (%d) úæåøçî êøåà :substr" -#: builtin.c:1306 +#: builtin.c:1337 msgid "strftime: received non-string first argument" msgstr "úæåøçî åðéà ïåùàø èðîåâøà :strftime" -#: builtin.c:1312 +#: builtin.c:1343 msgid "strftime: received empty format string" msgstr "ä÷éø èîøåô úæåøçî :strftime" -#: builtin.c:1321 +#: builtin.c:1352 msgid "strftime: received non-numeric second argument" msgstr "øôñî åðéà éðù èðîåâøà :strftime" -#: builtin.c:1384 +#: builtin.c:1415 msgid "mktime: received non-string argument" msgstr "úæåøçî åðéà èðîåâøà :mktime" -#: builtin.c:1429 +#: builtin.c:1460 msgid "system: received non-string argument" msgstr "úæåøçî åðéà èðîåâøà :system" -#: builtin.c:1573 +#: builtin.c:1581 eval.c:1883 +#, fuzzy, c-format +msgid "reference to uninitialized field `$%d'" +msgstr "`%s' ìçåúî-éúìá äðúùîì äéðôä" + +#: builtin.c:1608 msgid "tolower: received non-string argument" msgstr "úæåøçî åðéà èðîåâøà :tolower" -#: builtin.c:1622 +#: builtin.c:1657 msgid "toupper: received non-string argument" msgstr "úæåøçî åðéà èðîåâøà :toupper" -#: builtin.c:1667 +#: builtin.c:1702 msgid "atan2: received non-numeric first argument" msgstr "øôñî åðéà ïåùàø èðîåâøà :atan2" -#: builtin.c:1669 +#: builtin.c:1704 msgid "atan2: received non-numeric second argument" msgstr "øôñî åðéà éðù èðîåâøà :atan2" -#: builtin.c:1688 +#: builtin.c:1723 msgid "sin: received non-numeric argument" msgstr "øôñî åðéà èðîåâøà :sin" -#: builtin.c:1704 +#: builtin.c:1739 msgid "cos: received non-numeric argument" msgstr "øôñî åðéà èðîåâøà :cos" -#: builtin.c:1748 +#: builtin.c:1788 msgid "srand: received non-numeric argument" msgstr "øôñî åðéà èðîåâøà :srand" -#: builtin.c:1787 +#: builtin.c:1823 msgid "match: third argument is not an array" msgstr "êøòî åðéà éùéìù èðîåâøà :match" -#: builtin.c:2264 -msgid "gensub: 3rd argument of 0 treated as 1" +#: builtin.c:2307 +msgid "gensub: third argument of 0 treated as 1" msgstr "1-á óìçåä 0 åëøòù éùéìù èðîåâøà :gensub" -#: builtin.c:2375 builtin.c:2377 +#: builtin.c:2416 builtin.c:2418 msgid "lshift: received non-numeric first argument" msgstr "øôñî åðéà ïåùàø èðîåâøà :lshift" -#: builtin.c:2379 +#: builtin.c:2420 #, c-format msgid "lshift(%lf, %lf): negative values will give strange results" msgstr "úåéåôö-éúìá úåàöåú åáéðé íééìéìù íéëøò :lshift(%lf, %lf)" -#: builtin.c:2381 +#: builtin.c:2422 #, c-format msgid "lshift(%lf, %lf): fractional values will be truncated" msgstr "åööå÷é íéøåáù íéëøò :lshift(%lf, %lf)" -#: builtin.c:2383 +#: builtin.c:2424 #, c-format msgid "lshift(%lf, %lf): too large shift value will give strange results" msgstr "úåéåôö-éúìá úåàöåú áéðé éãî ìåãâ äææä øåòéù :lshift(%lf, %lf)" -#: builtin.c:2412 builtin.c:2414 +#: builtin.c:2453 builtin.c:2455 msgid "rshift: received non-numeric first argument" msgstr "øôñî åðéà ïåùàø èðîåâøà :rshift" -#: builtin.c:2416 +#: builtin.c:2457 #, c-format msgid "rshift(%lf, %lf): negative values will give strange results" msgstr "úåéåôö-éúìá úåàöåú åáéðé íééìéìù íéëøò :rshift(%lf, %lf)" -#: builtin.c:2418 +#: builtin.c:2459 #, c-format msgid "rshift(%lf, %lf): fractional values will be truncated" msgstr "åööå÷é íéøåáù íéëøò :rshift(%lf, %lf)" -#: builtin.c:2420 +#: builtin.c:2461 #, c-format msgid "rshift(%lf, %lf): too large shift value will give strange results" msgstr "úåéåôö-éúìá úåàöåú áéðé éãî ìåãâ äææä øåòéù :rshift(%lf, %lf)" -#: builtin.c:2449 builtin.c:2451 +#: builtin.c:2490 builtin.c:2492 msgid "and: received non-numeric first argument" msgstr "øôñî åðéà ïåùàø èðîåâøà :and" -#: builtin.c:2453 +#: builtin.c:2494 #, c-format msgid "and(%lf, %lf): negative values will give strange results" msgstr "úåéåôö-éúìá úåàöåú åáéðé íééìéìù íéëøò :and(%lf, %lf)" -#: builtin.c:2455 +#: builtin.c:2496 #, c-format msgid "and(%lf, %lf): fractional values will be truncated" msgstr "åööå÷é íéøåáù íéëøò :and(%lf, %lf)" -#: builtin.c:2484 builtin.c:2486 +#: builtin.c:2525 builtin.c:2527 msgid "or: received non-numeric first argument" msgstr "øôñî åðéà ïåùàø èðîåâøà :or" -#: builtin.c:2488 +#: builtin.c:2529 #, c-format msgid "or(%lf, %lf): negative values will give strange results" msgstr "úåéåôö-éúìá úåàöåú åáéðé íééìéìù íéëøò :or(%lf, %lf)" -#: builtin.c:2490 +#: builtin.c:2531 #, c-format msgid "or(%lf, %lf): fractional values will be truncated" msgstr "åööå÷é íéøåáù íéëøò :or(%lf, %lf)" -#: builtin.c:2519 builtin.c:2521 +#: builtin.c:2560 builtin.c:2562 msgid "xor: received non-numeric first argument" msgstr "øôñî åðéà ïåùàø èðîåâøà :xor" -#: builtin.c:2523 +#: builtin.c:2564 #, c-format msgid "xor(%lf, %lf): negative values will give strange results" msgstr "úåéåôö-éúìá úåàöåú åáéðé íééìéìù íéëøò :xor(%lf, %lf)" -#: builtin.c:2525 +#: builtin.c:2566 #, c-format msgid "xor(%lf, %lf): fractional values will be truncated" msgstr "åööå÷é íéøåáù íéëøò :xor(%lf, %lf)" -#: builtin.c:2553 +#: builtin.c:2594 msgid "compl: received non-numeric argument" msgstr "øôñî åðéà èðîåâøà :compl" -#: builtin.c:2555 +#: builtin.c:2596 #, c-format msgid "compl(%lf): negative value will give strange results" msgstr "úåéåôö-éúìá úåàöåú áéðé éìéìù êøò :compl(%lf)" -#: builtin.c:2557 +#: builtin.c:2598 #, c-format msgid "compl(%lf): fractional value will be truncated" msgstr "õöå÷é øåáù êøò :compl(%lf)" -#: builtin.c:2728 +#: builtin.c:2771 #, c-format msgid "dcgettext: `%s' is not a valid locale category" msgstr "äðé÷ú íå÷éî úééøåâè÷ åðéà `%s' :dcgettext" -#: eval.c:262 +#: eval.c:266 #, c-format msgid "unknown nodetype %d" msgstr "%d ääåæî-éúìá âåñ ìòá node" -#: eval.c:310 +#: eval.c:312 msgid "buffer overflow in genflags2str" msgstr "genflags2str-á õöåç úùéìâ" -#: eval.c:555 +#: eval.c:647 #, fuzzy, c-format msgid "for loop: array `%s' changed size from %ld to %ld during loop execution" msgstr "(`%s' êøòî) äàìåìä òåöéá êìäîá %d-î %d-ì äðåù êøòî ìù åìãåâ :for úàìåì" -#: eval.c:576 +#: eval.c:668 msgid "`break' outside a loop is not portable" msgstr "éìéáèøåô åðéà äàìåìì õåçî `break'" -#: eval.c:580 +#: eval.c:672 msgid "`break' outside a loop is not allowed" msgstr "äàìåìì õåçî `break'-á ùîúùäì ïéà" -#: eval.c:597 +#: eval.c:689 msgid "`continue' outside a loop is not portable" msgstr "éìéáèøåô åðéà äàìåìì õåçî `continue'" -#: eval.c:601 +#: eval.c:693 msgid "`continue' outside a loop is not allowed" msgstr "äàìåìì õåçî `continue'-á ùîúùäì ïéà" -#: eval.c:635 +#: eval.c:727 msgid "`next' cannot be called from a BEGIN rule" msgstr "BEGIN éììë êåúî `next'-ì àåø÷ì ïéà" -#: eval.c:637 +#: eval.c:729 msgid "`next' cannot be called from an END rule" msgstr "END éììë êåúî `next'-ì àåø÷ì ïéà" -#: eval.c:646 +#: eval.c:738 msgid "`nextfile' cannot be called from a BEGIN rule" msgstr "BEGIN éììë êåúî `nextfile'-ì àåø÷ì ïéà" -#: eval.c:648 +#: eval.c:740 msgid "`nextfile' cannot be called from an END rule" msgstr "END éììë êåúî `nextfile'-ì àåø÷ì ïéà" -#: eval.c:696 +#: eval.c:785 msgid "statement has no effect" msgstr "úéìëú-úìåèð äàøåä" -#: eval.c:731 eval.c:761 eval.c:1733 -#, c-format -msgid "reference to uninitialized variable `%s'" -msgstr "`%s' ìçåúî-éúìá äðúùîì äéðôä" - -#: eval.c:739 eval.c:1721 +#: eval.c:828 eval.c:1726 #, c-format msgid "can't use function name `%s' as variable or array" msgstr "êøòî åà äðúùîë `%s' äéö÷ðåô íùá ùîúùäì ïéà" -#: eval.c:746 eval.c:752 +#: eval.c:835 eval.c:841 #, c-format msgid "reference to uninitialized argument `%s'" msgstr "`%s' ìçåúî-éúìá èðîåâøàì äéðôä" -#: eval.c:810 eval.c:1728 profile.c:773 +#: eval.c:848 eval.c:907 eval.c:1732 eval.c:1742 profile.c:807 #, c-format msgid "attempt to use array `%s' in a scalar context" msgstr "øàì÷ñ ùøåãä èñ÷èðå÷á `%s' êøòîá ùåîéù ïåéñð" -#: eval.c:910 +#: eval.c:858 eval.c:1752 +#, c-format +msgid "reference to uninitialized variable `%s'" +msgstr "`%s' ìçåúî-éúìá äðúùîì äéðôä" + +#: eval.c:1007 msgid "" "concatenation: side effects in one expression have changed the length of " "another!" msgstr "" "!øçà éåèéá ìù åëøåà éåðéùì åîøâ ãçà éåèéá áåùéç ìù éàåì-úåòôåú :concatenation" -#: eval.c:935 +#: eval.c:1032 msgid "assignment used in conditional context" msgstr "éàðú ìù èñ÷èðå÷á äîùäá ùåîéù" -#: eval.c:1026 +#: eval.c:1122 msgid "division by zero attempted" msgstr "ñôàá ä÷åìç ïåéñð" -#: eval.c:1041 +#: eval.c:1137 #, c-format msgid "division by zero attempted in `%%'" msgstr "`%%'-á ñôàá ä÷åìç ïåéñð" -#: eval.c:1056 profile.c:649 +#: eval.c:1152 profile.c:683 #, c-format msgid "illegal type (%s) in tree_eval" msgstr "tree_eval-á (%s) éåâù âåñ" -#: eval.c:1232 +#: eval.c:1328 msgid "division by zero attempted in `/='" msgstr "`/='-á ñôàá ä÷åìç ïåéñð" -#: eval.c:1250 +#: eval.c:1346 #, c-format msgid "division by zero attempted in `%%='" msgstr "`%%='-á ñôàá ä÷åìç ïåéñð" -# This is not translated because it cannot be reworded in Hebrew -# without looking awkward. -#: eval.c:1510 -#, c-format -msgid "%s (from %s)" -msgstr "%s (from %s)" - -#: eval.c:1569 +#: eval.c:1586 #, c-format msgid "function `%s' called with more arguments than declared" msgstr "äúæøëäá øùàî íéèðîåâøà øúåé íò `%s' äéö÷ðåôì äàéø÷" -#: eval.c:1628 +#: eval.c:1633 #, c-format msgid "function `%s' not defined" msgstr "úøãâåî äðéà `%s' äéö÷ðåô" -#: eval.c:1634 +#: eval.c:1639 #, c-format msgid "function %s called\n" msgstr "`%s' äéö÷ðåôì äàéø÷\n" -#: eval.c:1693 +#: eval.c:1698 msgid "" "\n" "\t# Function Call Stack:\n" @@ -837,46 +853,41 @@ "\t# :úåéö÷ðåôì úåàéø÷ä úéðñçî\n" "\n" -#: eval.c:1696 +#: eval.c:1701 msgid "\t# -- main --\n" msgstr "\t# -- main --\n" -#: eval.c:1850 +#: eval.c:1867 msgid "attempt to field reference from non-numeric value" msgstr "øôñî åðéàù êøò úåòöîàá äãùì äéðôä ïåéñð" -#: eval.c:1852 +#: eval.c:1869 msgid "attempt to reference from null string" msgstr "ä÷éø úæåøçî úåòöîàá äãùì äéðôä ïåéñð" -#: eval.c:1858 +#: eval.c:1875 #, c-format msgid "attempt to access field %d" msgstr "%d 'ñî äãùì äùéâ ïåéñð" -#: eval.c:1874 -#, c-format -msgid "attempt to use scalar parameter `%s' as an array" -msgstr "êøòî äéä åìéàë `%s' éøì÷ñ øèîøôá ùåîéù ïåéñð" - -#: eval.c:1886 eval.c:1893 profile.c:865 +#: eval.c:1896 eval.c:1903 profile.c:900 msgid "assignment is not allowed to result of builtin function" msgstr "úéðáåî äéö÷ðåô ìù äàöåúá êøò áéöäì ïéà" -#: eval.c:1941 +#: eval.c:1951 msgid "`IGNORECASE' is a gawk extension" msgstr "gawk-ì úéôéöôñ äáçøä åðéä `IGNORECASE'" -#: eval.c:1970 +#: eval.c:1980 msgid "`BINMODE' is a gawk extension" msgstr "gawk-ì úéôéöôñ äáçøä åðéä `BINMODE'" -#: eval.c:2082 +#: eval.c:2092 #, c-format msgid "bad `%sFMT' specification `%s'" msgstr "äðé÷ú `%sFMT' úøãâä åðéà `%s'" -#: eval.c:2160 +#: eval.c:2170 msgid "turning off `--lint' due to assignment to `LINT'" msgstr "`LINT'-ì êøò úîùä á÷ò `--lint' ìèáî" @@ -894,32 +905,32 @@ msgid "extension: library `%s': cannot call function `%s' (%s)\n" msgstr "`%s' äéøôñî `%s' äéö÷ðåôì äàéø÷á (%s) äì÷ú äòøéà :extension\n" -#: ext.c:181 +#: ext.c:183 msgid "Operation Not Supported" msgstr "úëîúð äðéà åæ äìåòô" -#: field.c:321 +#: field.c:315 msgid "NF set to negative value" msgstr "éìéìù êøò ìáé÷ NF" -#: field.c:819 +#: field.c:808 msgid "split: second argument is not an array" msgstr "êøòî åðéà `split' ìù éðùä èðîåâøàä" -#: field.c:854 +#: field.c:842 msgid "split: null string for third arg is a gawk extension" msgstr "gawk-ì úéôéöôñ äáçøä äðéä `split'-ì éùéìù èðåîâøàë úñôåàî úæåøçî" -#: field.c:906 +#: field.c:894 msgid "`FIELDWIDTHS' is a gawk extension" msgstr "gawk-ì úéôéöôñ äáçøä åðéä `FIELDWIDTHS'" -#: field.c:933 +#: field.c:921 #, c-format msgid "field %d in FIELDWIDTHS, must be > 0" msgstr "0-î ìåãâ úåéäì áééç FIELDWIDTHS-á %d 'ñî äãù" -#: field.c:1006 +#: field.c:994 msgid "null string for `FS' is a gawk extension" msgstr "gawk-ì úéôéöôñ äáçøä äðéä `FS'-ë úñôåàî úæåøçî" @@ -967,7 +978,7 @@ msgid "%s: invalid option -- %c\n" msgstr "%s úéðëú øåáò éåâù ïééôàî -- %c\n" -#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:431 +#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:434 #, c-format msgid "%s: option requires an argument -- %c\n" msgstr "%s: èðîåâøà áééçî ïééôàî -- %c\n" @@ -982,466 +993,466 @@ msgid "%s: option `-W %s' doesn't allow an argument\n" msgstr "%s úéðëú øåáò èðîåâøà ìá÷î åðéà `-W %s' ïééôàî\n" -#: io.c:257 +#: io.c:305 #, c-format msgid "cannot open file `%s' for reading (%s)" msgstr "åúàéø÷ íùì `%s' õáå÷ úçéúôá (%s) äì÷ú" -#: io.c:344 +#: io.c:392 #, c-format msgid "close of fd %d (`%s') failed (%s)" msgstr "(%d èìô/èì÷ õåøò) `%s' úøéâñá (%s) äì÷ú" -#: io.c:482 +#: io.c:530 #, c-format msgid "invalid tree type %s in redirect()" msgstr "redirect() äéö÷ðåôá %s éåâù õò âåñ" -#: io.c:488 +#: io.c:536 #, c-format msgid "expression in `%s' redirection only has numeric value" msgstr "ãáìá éøîåð êøò áéðî `%s' èìô/èì÷ úééðôäá éåèéá" -#: io.c:494 +#: io.c:542 #, c-format msgid "expression for `%s' redirection has null string value" msgstr "ä÷éø úæåøçî áéðî `%s' èìô/èì÷ úééðôäá éåèéá" -#: io.c:499 +#: io.c:547 #, c-format msgid "filename `%s' for `%s' redirection may be result of logical expression" msgstr "éâåì éåèéá ìù äàöåú úåéäì ìåìò `%s' õáå÷ íù `%s' èìô/èì÷ úééðôäá" -#: io.c:521 +#: io.c:569 #, c-format msgid "unnecessary mixing of `>' and `>>' for file `%.*s'" msgstr "`%.*s' õáå÷ øåáò `>>'-á ïäå `>'-á ïä øúåéî ùåîéù" -#: io.c:573 +#: io.c:621 #, c-format msgid "can't open pipe `%s' for output (%s)" msgstr "èìô êøåöì `%s' ÷éôà úçéúôá (%s) äì÷ú" -#: io.c:582 +#: io.c:630 #, c-format msgid "can't open pipe `%s' for input (%s)" msgstr "èì÷ êøåöì `%s' ÷éôà úçéúôá (%s) äì÷ú" -#: io.c:595 +#: io.c:643 #, c-format msgid "can't open two way socket `%s' for input/output (%s)" msgstr "èìô/èì÷ êøåöì éðååéë-åã (socket) ò÷ùë `%s' úçéúôá (%s) äì÷ú" -#: io.c:599 +#: io.c:647 #, c-format msgid "can't open two way pipe `%s' for input/output (%s)" msgstr "èìô/èì÷ êøåöì éðååéë-åã (pipe) ÷éôàë `%s' úçéúôá (%s) äì÷ú" -#: io.c:675 +#: io.c:723 #, c-format msgid "can't redirect from `%s' (%s)" msgstr "`%s'-î äééðôäá (%s) äì÷ú" -#: io.c:678 +#: io.c:726 #, c-format msgid "can't redirect to `%s' (%s)" msgstr "`%s' ìà äééðôäá (%s) äì÷ú" -#: io.c:717 +#: io.c:765 msgid "" "reached system limit for open files: starting to multiplex file descriptors" msgstr "èìô/èì÷ éöåøò áåáéø úìéçú ;íéçåúô íéöá÷ øôñî ìù úëøòî úìáâîì äòâä" -#: io.c:729 +#: io.c:777 #, c-format msgid "close of `%s' failed (%s)." msgstr "`%s' úøéâñá (%s) äì÷ú" -#: io.c:736 +#: io.c:784 msgid "too many pipes or input files open" msgstr "úéðîæ-åá íéçåúô èì÷ éöá÷ åà (pipes) íé÷éôà éãî øúåé" -#: io.c:759 +#: io.c:807 msgid "close: second argument must be `to' or `from'" msgstr "`from' åà `to' úåéäì áééç `close' ìù éðùä èðîåâøàä" -#: io.c:773 +#: io.c:821 #, c-format msgid "close: `%.*s' is not an open file, pipe or co-process" msgstr "ìéá÷î êéìäú åà çåúô ÷éôà ,çåúô õáå÷ åðéà `%.*s' :close" -#: io.c:777 +#: io.c:825 msgid "close of redirection that was never opened" msgstr "íìåòî äçúôð àìù äééðôä úøéâñ" -#: io.c:804 +#: io.c:862 #, c-format msgid "close: redirection `%s' not opened with `|&', second argument ignored" msgstr "çðæåä éðùä èðîåâøàä ,`|&' é\"ò äçúôð àì `%s' äééðôä" -#: io.c:866 +#: io.c:924 #, c-format msgid "failure status (%d) on pipe close of `%s' (%s)" msgstr "(%d äì÷ú ãå÷) `%s'-ì ÷éôà úøéâñá (%s) äì÷ú" -#: io.c:869 +#: io.c:927 #, c-format msgid "failure status (%d) on file close of `%s' (%s)" msgstr "(%d äì÷ú ãå÷) `%s' õáå÷ úøéâñá (%s) äì÷ú" -#: io.c:888 +#: io.c:946 #, c-format msgid "no explicit close of socket `%s' provided" msgstr "ùøåôîá øâñð àì (socket) `%s' ò÷ù" -#: io.c:891 +#: io.c:949 #, c-format msgid "no explicit close of co-process `%s' provided" msgstr "ùøåôîá øâñð àì (co-process) `%s' ìéá÷î êéìäú" -#: io.c:894 +#: io.c:952 #, c-format msgid "no explicit close of pipe `%s' provided" msgstr "ùøåôîá øâñð àì (pipe) `%s' ÷éôà" -#: io.c:897 +#: io.c:955 #, c-format msgid "no explicit close of file `%s' provided" msgstr "ùøåôîá øâñð àì `%s' õáå÷" -#: io.c:926 io.c:980 +#: io.c:984 io.c:1038 #, c-format msgid "error writing standard output (%s)" msgstr "éð÷ú èìô õåøòì äáéúëá (%s) äì÷ú" -#: io.c:930 io.c:984 +#: io.c:988 io.c:1042 #, c-format msgid "error writing standard error (%s)" msgstr "éð÷ú úåàéâù õåøòì äáéúëá (%s) äì÷ú" -#: io.c:938 +#: io.c:996 #, c-format msgid "pipe flush of `%s' failed (%s)." msgstr "`%s'-ì ÷éôà ìù õöåç ïå÷éøá (%s) äì÷ú" -#: io.c:941 +#: io.c:999 #, c-format msgid "co-process flush of pipe to `%s' failed (%s)." msgstr "`%s'-ì ìéá÷î êéìäú ÷éôà ìù õöåç ïå÷éøá (%s) äì÷ú" -#: io.c:944 +#: io.c:1002 #, c-format msgid "file flush of `%s' failed (%s)." msgstr "`%s' ìù õáå÷ éðåúð õöåç ïå÷éøá (%s) äì÷ú" -#: io.c:1103 +#: io.c:1161 msgid "/inet/raw client not ready yet, sorry" msgstr "ïëåî íøè /inet/raw çå÷ì ,íéøòèöî" -#: io.c:1105 io.c:1142 +#: io.c:1163 io.c:1200 msgid "only root may use `/inet/raw'." msgstr "ãáìá root ùîúùîì øúåî `inet/raw'-á ùåîéù" -#: io.c:1140 +#: io.c:1198 msgid "/inet/raw server not ready yet, sorry" msgstr "ïëåî íøè /inet/raw úøù ,íéøòèöî" -#: io.c:1230 +#: io.c:1288 #, c-format msgid "no (known) protocol supplied in special filename `%s'" msgstr "`%s' ãçåéî õáå÷ íùá ääåæî-éúìá åà øñç ìå÷åèåøô" -#: io.c:1248 +#: io.c:1306 #, c-format msgid "special file name `%s' is incomplete" msgstr "íìù åðéà `%s' ãçåéî õáå÷" -#: io.c:1260 +#: io.c:1318 #, c-format msgid "local port invalid in `%s'" msgstr "`%s'-á äéåâù úéîå÷î äàéöé" -#: io.c:1272 +#: io.c:1330 msgid "must supply a remote hostname to `/inet'" msgstr "`/inet' øåáò ÷çåøî çøàî-áùçî íù øéãâäì äáåç" -#: io.c:1287 +#: io.c:1345 msgid "must supply a remote port to `/inet'" msgstr "`/inet' øåáò ú÷çåøî äàéöé øéãâäì äáåç" -#: io.c:1293 +#: io.c:1351 #, c-format msgid "remote port invalid in `%s'" msgstr "`%s'-á äéåâù ú÷çåøî äàéöé" -#: io.c:1303 +#: io.c:1361 msgid "TCP/IP communications are not supported" msgstr "TCP/IP úøåù÷úá äëéîú ïéà" -#: io.c:1312 io.c:1492 +#: io.c:1370 io.c:1551 #, c-format msgid "file `%s' is a directory" msgstr "äé÷éú åðéä `%s' õáå÷" -#: io.c:1381 +#: io.c:1440 #, c-format msgid "use `PROCINFO[\"%s\"]' instead of `%s'" msgstr "`PROCINFO[\"%s\"]'-á ùîúùäì óéãò `%s' íå÷îá" -#: io.c:1413 +#: io.c:1472 msgid "use `PROCINFO[...]' instead of `/dev/user'" msgstr "`/dev/user' éðô-ìò óéãò `PROCINFO[...]'-á ùåîéù" # This probably sounds nonsensical in Hebrew, but what can I do, # given the original message text? -#: io.c:1478 io.c:1652 +#: io.c:1537 io.c:1711 #, c-format msgid "could not open `%s', mode `%s'" msgstr "`%s' øåáò `%s' äìåòô ïôåà úçéúôá ïåìùë" -#: io.c:1703 +#: io.c:1762 #, fuzzy, c-format msgid "close of master pty failed (%s)" msgstr "÷éôà úøéâñá (%s) äì÷ú" -#: io.c:1705 io.c:1857 io.c:2009 +#: io.c:1764 io.c:1916 io.c:2068 #, c-format msgid "close of stdout in child failed (%s)" msgstr "úá-úéðëúá stdout úøéâñá (%s) äì÷ú" -#: io.c:1708 +#: io.c:1767 #, fuzzy, c-format msgid "moving slave pty to stdout in child failed (dup: %s)" msgstr "úá-úéðëúá stdout-ì ÷éôà ìåôëùá (dup: %s) äì÷ú" -#: io.c:1710 io.c:1862 +#: io.c:1769 io.c:1921 #, c-format msgid "close of stdin in child failed (%s)" msgstr "úá-úéðëúá stdin úøéâñá (%s) äì÷ú" -#: io.c:1713 +#: io.c:1772 #, fuzzy, c-format msgid "moving slave pty to stdin in child failed (dup: %s)" msgstr "úá-úéðëúá stdin-ì ÷éôà ìåôëùá (dup: %s) äì÷ú" -#: io.c:1715 io.c:1734 +#: io.c:1774 io.c:1793 #, fuzzy, c-format msgid "close of slave pty failed (%s)" msgstr "÷éôà úøéâñá (%s) äì÷ú" -#: io.c:1808 io.c:1860 io.c:1990 io.c:2012 +#: io.c:1867 io.c:1919 io.c:2049 io.c:2071 #, c-format msgid "moving pipe to stdout in child failed (dup: %s)" msgstr "úá-úéðëúá stdout-ì ÷éôà ìåôëùá (dup: %s) äì÷ú" -#: io.c:1812 io.c:1865 +#: io.c:1871 io.c:1924 #, c-format msgid "moving pipe to stdin in child failed (dup: %s)" msgstr "úá-úéðëúá stdin-ì ÷éôà ìåôëùá (dup: %s) äì÷ú" -#: io.c:1829 io.c:2003 +#: io.c:1888 io.c:2062 msgid "restoring stdout in parent process failed\n" msgstr "áà-úéðëúá stdout ÷éôà øåæçùá äì÷ú\n" -#: io.c:1834 +#: io.c:1893 msgid "restoring stdin in parent process failed\n" msgstr "áà-úéðëúá stdin ÷éôà øåæçùá äì÷ú\n" -#: io.c:1868 io.c:2014 io.c:2025 +#: io.c:1927 io.c:2073 io.c:2084 #, c-format msgid "close of pipe failed (%s)" msgstr "÷éôà úøéâñá (%s) äì÷ú" -#: io.c:1913 +#: io.c:1972 msgid "`|&' not supported" msgstr "`|&'-á äëéîú ïéà" -#: io.c:1980 +#: io.c:2039 #, c-format msgid "cannot open pipe `%s' (%s)" msgstr "`%s' ÷éôà úçéúôá (%s) äì÷ú" -#: io.c:2021 +#: io.c:2080 #, c-format msgid "cannot create child process for `%s' (fork: %s)" msgstr "`%s' úá-úéðëúì êéìäú úøéöéá (fork: %s) äì÷ú" -#: io.c:2364 +#: io.c:2423 #, c-format msgid "data file `%s' is empty" msgstr "÷éø åðéä `%s' íéðåúð õáå÷" -#: io.c:2407 io.c:2415 +#: io.c:2466 io.c:2474 msgid "could not allocate more input memory" msgstr "" -#: io.c:2540 io.c:2782 io.c:3046 +#: io.c:2832 io.c:2895 #, c-format msgid "error reading input file `%s': %s" msgstr "`%s' õáå÷ úàéø÷á (%s) äì÷ú" -#: io.c:3281 +#: io.c:3020 msgid "multicharacter value of `RS' is a gawk extension" msgstr "gawk-ì úéôéöôñ äáçøä äðéä `RS' ìù êøòá íéåú øôñîá äëéîú" -#: main.c:322 +#: main.c:324 msgid "`-m[fr]' option irrelevant in gawk" msgstr "gawk øåáò éèðååìø åðéà `-m[fr]' ïééôàî" -#: main.c:324 +#: main.c:326 msgid "-m option usage: `-m[fr] nnn'" msgstr "`-m[fr] nnn' :-m ïééôàîá ùåîéù ïôåà" -#: main.c:341 +#: main.c:343 #, c-format msgid "%s: option `-W %s' unrecognized, ignored\n" msgstr "çðæåä ,%s úéðëú øåáò øëåî åðéà `-W %s' ïééôàî\n" -#: main.c:378 +#: main.c:380 msgid "empty argument to `--source' ignored" msgstr "çðæåä `--source'-ì ÷éø èðîåâøà" -#: main.c:448 +#: main.c:451 msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'" msgstr "`--posix' ìéòôî :øãâåî `POSIXLY_CORRECT' äáéáñ äðúùî" -#: main.c:453 +#: main.c:456 msgid "`--posix' overrides `--traditional'" msgstr "`--traditional' ìò øáåâ `--posix'" -#: main.c:464 +#: main.c:467 msgid "`--posix'/`--traditional' overrides `--non-decimal-data'" msgstr "`--non-decimal-data' ìò øáåâ `--posix'/`--traditional'" -#: main.c:468 +#: main.c:471 #, c-format msgid "running %s setuid root may be a security problem" msgstr "òãéî úçèáàá òåâôì äìåìò setuid root-ë %s úöøä" -#: main.c:509 +#: main.c:512 #, fuzzy, c-format msgid "can't set binary mode on stdin (%s)" msgstr "stdin úìåòô ïôåà úòéá÷á (%s) äì÷ú" -#: main.c:512 +#: main.c:515 #, fuzzy, c-format msgid "can't set binary mode on stdout (%s)" msgstr "stdout úìåòô ïôåà úòéá÷á (%s) äì÷ú" -#: main.c:514 +#: main.c:517 #, fuzzy, c-format msgid "can't set binary mode on stderr (%s)" msgstr "stderr úìåòô ïôåà úòéá÷á (%s) äì÷ú" -#: main.c:544 +#: main.c:547 msgid "no program text at all!" msgstr "!ììë àöîðá äéä àì úéðëú ìù èñ÷è" -#: main.c:612 +#: main.c:620 #, c-format msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n" msgstr "" "%s [GNU åà POSIX ïåðâñá íéðééôàî] -f úéðëú-íù [--] õáå÷-íù ... :ùåîéù ïôåà\n" -#: main.c:614 +#: main.c:622 #, c-format msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n" msgstr "" "%s [GNU åà POSIX ïåðâñá íéðééôàî] [--] %cúéðëú%c õáå÷-íù ... :ùåîéù ïôåà\n" -#: main.c:619 +#: main.c:627 msgid "POSIX options:\t\tGNU long options:\n" msgstr ":POSIX éðééôàî\t\t:íéëåøà GNU éðééôàî\n" -#: main.c:620 +#: main.c:628 msgid "\t-f progfile\t\t--file=progfile\n" msgstr "\t-f úéðëú-õáå÷\t\t--file=úéðëú-õáå÷\n" -#: main.c:621 +#: main.c:629 msgid "\t-F fs\t\t\t--field-separator=fs\n" msgstr "\t-F úåãù-ãéøôî\t\t--field-separator=úåãù-ãéøôî\n" -#: main.c:622 +#: main.c:630 msgid "\t-v var=val\t\t--assign=var=val\n" msgstr "\t-v äðúùî=êøò\t\t--assign=äðúùî=êøò\n" -#: main.c:623 +#: main.c:631 msgid "\t-m[fr] val\n" msgstr "\t-m[fr] êøò\n" -#: main.c:624 +#: main.c:632 msgid "\t-W compat\t\t--compat\n" msgstr "\t-W compat\t\t--compat\n" -#: main.c:625 +#: main.c:633 msgid "\t-W copyleft\t\t--copyleft\n" msgstr "\t-W copyleft\t\t--copyleft\n" -#: main.c:626 +#: main.c:634 msgid "\t-W copyright\t\t--copyright\n" msgstr "\t-W copyright\t\t--copyright\n" -#: main.c:627 +#: main.c:635 msgid "\t-W dump-variables[=file]\t--dump-variables[=file]\n" msgstr "\t-W dump-variables[=õáå÷-íù]\t--dump-variables[=õáå÷-íù]\n" -#: main.c:628 +#: main.c:636 msgid "\t-W gen-po\t\t--gen-po\n" msgstr "\t-W gen-po\t\t--gen-po\n" -#: main.c:629 +#: main.c:637 msgid "\t-W help\t\t\t--help\n" msgstr "\t-W help\t\t\t--help\n" -#: main.c:630 +#: main.c:638 msgid "\t-W lint[=fatal]\t\t--lint[=fatal]\n" msgstr "\t-W lint[=fatal]\t\t--lint[=fatal]\n" -#: main.c:631 +#: main.c:639 msgid "\t-W lint-old\t\t--lint-old\n" msgstr "\t-W lint-old\t\t--lint-old\n" -#: main.c:632 +#: main.c:640 msgid "\t-W non-decimal-data\t--non-decimal-data\n" msgstr "\t-W non-decimal-data\t--non-decimal-data\n" -#: main.c:634 +#: main.c:642 msgid "\t-W nostalgia\t\t--nostalgia\n" msgstr "\t-W nostalgia\t\t--nostalgia\n" -#: main.c:637 +#: main.c:645 msgid "\t-W parsedebug\t\t--parsedebug\n" msgstr "\t-W parsedebug\t\t--parsedebug\n" -#: main.c:639 +#: main.c:647 msgid "\t-W profile[=file]\t--profile[=file]\n" msgstr "\t-W profile[=õáå÷-íù]\t--profile[=õáå÷-íù]\n" -#: main.c:640 +#: main.c:648 msgid "\t-W posix\t\t--posix\n" msgstr "\t-W posix\t\t--posix\n" -#: main.c:641 +#: main.c:649 msgid "\t-W re-interval\t\t--re-interval\n" msgstr "\t-W re-interval\t\t--re-interval\n" -#: main.c:642 +#: main.c:650 msgid "\t-W source=program-text\t--source=program-text\n" msgstr "\t-W source=úéðëú-èñ÷è\t--source=úéðëú-èñ÷è\n" -#: main.c:643 +#: main.c:651 msgid "\t-W traditional\t\t--traditional\n" msgstr "\t-W traditional\t\t--traditional\n" -#: main.c:644 +#: main.c:652 msgid "\t-W usage\t\t--usage\n" msgstr "\t-W usage\t\t--usage\n" -#: main.c:645 +#: main.c:653 msgid "\t-W version\t\t--version\n" msgstr "\t-W version\t\t--version\n" -#: main.c:649 +#: main.c:657 msgid "" "\n" "To report bugs, see node `Bugs' in `gawk.info', which is\n" @@ -1453,7 +1464,7 @@ " .ñôãåîä êéøãîá `Reporting Problems and Bugs' ä÷ñô\n" "\n" -#: main.c:653 +#: main.c:661 msgid "" "gawk is a pattern scanning and processing language.\n" "By default it reads standard input and writes standard output.\n" @@ -1462,7 +1473,7 @@ ".èñ÷è úåéðáú ìù ãåáéòå äé÷øñì äôù åðéä gawk\n" ".éð÷ú èìôì áúåëå éð÷ú èì÷ õåøò àøå÷ àåä ìãçî úøéøáë\n" -#: main.c:657 +#: main.c:665 msgid "" "Examples:\n" "\tgawk '{ sum += $1 }; END { print sum }' file\n" @@ -1472,7 +1483,7 @@ "\tgawk '{ sum += $1 }; END { print sum }' file\n" "\tgawk -F: '{ print $1 }' /etc/passwd\n" -#: main.c:669 +#: main.c:682 #, c-format msgid "" "Copyright (C) 1989, 1991-%d Free Software Foundation.\n" @@ -1490,7 +1501,7 @@ " íàå ,ïåéùøä ìù 2 àñøâá íà ;Free Software Foundation\n" " .øúåé úøçåàî àñøâ ìëá (íëì äøåîùä äéöôåàë)\n" -#: main.c:677 +#: main.c:690 msgid "" "This program is distributed in the hope that it will be useful,\n" "but WITHOUT ANY WARRANTY; without even the implied warranty of\n" @@ -1503,7 +1514,7 @@ ",íéèøôì .úîéåñî úéìëú åæéàì äîàúä åà úåøéçñ ìù\n" " .GNU General Public License-á åðééò àðà\n" -#: main.c:683 +#: main.c:696 msgid "" "You should have received a copy of the GNU General Public License\n" "along with this program; if not, write to the Free Software\n" @@ -1513,48 +1524,48 @@ "Free Software Foundation, Inc.-ì åáúë àðà ,åúåà íúìáé÷ àì íà\n" ".59 Temple Place - Suite 330, Boston, MA 02111-1307, USA\n" -#: main.c:713 +#: main.c:730 msgid "-Ft does not set FS to tab in POSIX awk" msgstr "awk ìù POSIX úñøâá TAB úåéäì FS-ì íøåâ åðéà -Ft" -#: main.c:944 +#: main.c:956 #, c-format msgid "" "%s: `%s' argument to `-v' not in `var=value' form\n" "\n" msgstr "" -#: main.c:964 +#: main.c:976 #, c-format msgid "`%s' is not a legal variable name" msgstr "" -#: main.c:967 +#: main.c:979 #, c-format msgid "`%s' is not a variable name, looking for file `%s=%s'" msgstr "" -#: main.c:995 +#: main.c:1012 msgid "floating point exception" msgstr "äôö äãå÷ð éáåùéçá äâéøç" -#: main.c:1002 +#: main.c:1019 msgid "fatal error: internal error" msgstr "úéîéðô äðëú úàéâù :äøåîç äì÷ú" # FIXME: I wonder how many people will understand what "fd 2" means. -#: main.c:1052 +#: main.c:1069 #, c-format msgid "no pre-opened fd %d" msgstr "ùàøî çåúô åðéà %d èìô/èì÷ õåøò" # FIXME: /dev/null might not be known to all. -#: main.c:1057 +#: main.c:1074 #, c-format msgid "could not pre-open /dev/null for fd %d" msgstr "/dev/null-ì %d èìô/èì÷ õåøò çåúôì ïúéð àì" -#: main.c:1080 main.c:1089 +#: main.c:1097 main.c:1106 #, c-format msgid "could not find groups: %s" msgstr "%s :úëøòîá íéùîúùî úåöåá÷ ìò òãéî ïéà" @@ -1579,23 +1590,23 @@ msgid "fatal: " msgstr "fatal: " -#: node.c:59 node.c:66 node.c:75 node.c:89 node.c:116 +#: node.c:58 node.c:65 node.c:74 node.c:88 node.c:115 msgid "can't convert string to float" msgstr "øôñîì äøîäì úðúéð äðéà úæåøçî" -#: node.c:357 +#: node.c:355 msgid "backslash at end of string" msgstr "úæåøçî óåñá êåôä ïñëåì" -#: node.c:544 +#: node.c:539 msgid "POSIX does not allow `\\x' escapes" msgstr "`\\x' âåñî äø÷á úåøãñ äùøî åðéà POSIX ï÷ú" -#: node.c:550 +#: node.c:545 msgid "no hex digits in `\\x' escape sequence" msgstr "`\\x' äø÷á úøãñá úåéìîéöãñ÷ä úåøôñá ùîúùäì ïéà" -#: node.c:584 +#: node.c:579 #, c-format msgid "escape sequence `\\%c' treated as plain `%c'" msgstr "éìåìéî åúë ìôåè `\\%c' äø÷á úøãñá `%c' åú" @@ -1610,24 +1621,21 @@ msgid "could not open `%s' for writing: %s" msgstr "äáéúë êøåöì `%s' úçéúô úòá (%s) äì÷ú" -#: profile.c:409 -msgid "internal error: Node_var with null vname" +#: profile.c:449 +#, fuzzy, c-format +msgid "internal error: %s with null vname" msgstr "ñôåàî åìù vname-äù Node_var :úéîéðô äðëú úàéâù" -#: profile.c:471 +#: profile.c:512 msgid "# treated internally as `delete'" msgstr "" -#: profile.c:545 -msgid "internal error: Node_var_array with null vname" -msgstr "ñôåàî åìù vname-äù Node_var_array :úéîéðô äðëú úàéâù" - -#: profile.c:1127 +#: profile.c:1162 #, c-format msgid "\t# gawk profile, created %s\n" msgstr "\t# %s êéøàúî gawk ìù ìéôåøô\n" -#: profile.c:1130 +#: profile.c:1165 msgid "" "\t# BEGIN block(s)\n" "\n" @@ -1635,7 +1643,7 @@ "\t# BEGIN ÷åìá\n" "\n" -#: profile.c:1140 +#: profile.c:1175 msgid "" "\t# Rule(s)\n" "\n" @@ -1643,7 +1651,7 @@ "\t# (íé)ììë\n" "\n" -#: profile.c:1146 +#: profile.c:1181 msgid "" "\t# END block(s)\n" "\n" @@ -1651,7 +1659,7 @@ "\t# END ÷åìá\n" "\n" -#: profile.c:1166 +#: profile.c:1201 msgid "" "\n" "\t# Functions, listed alphabetically\n" @@ -1659,7 +1667,7 @@ "\n" "\t# úéá-óìà øãñá ,úåéö÷ðåô\n" -#: profile.c:1376 +#: profile.c:1413 #, c-format msgid "unexpected type %s in prec_level" msgstr "prec_level-á %s éåâù âåñ" @@ -1741,6 +1749,32 @@ msgid "No previous regular expression" msgstr "íãå÷ éøìåâø éåèéá ïéà" +#, fuzzy +#~ msgid "substr: length %g is < 0" +#~ msgstr "0-î ìåãâ øôñî åððéà %g êøåà :substr" + +#~ msgid "delete: illegal use of variable `%s' as array" +#~ msgstr "êøòîë `%s' äðúùîá éåâù ùåîéù :delete" + +#, fuzzy +#~ msgid "%s: gvar_ref to %s\n" +#~ msgstr "%s: %s-ì (array_ref) äéðôä\n" + +#~ msgid "asort: first argument is not an array" +#~ msgstr "êøòî åðéà ïåùàø èðîåâøà :asort" + +#~ msgid "asort: second argument is not an array" +#~ msgstr "êøòî åðéà éðù èðîåâøà :asort" + +#, fuzzy +#~ msgid "" +#~ "attempt to use array parameter `%s' that was passed from global scalar `%" +#~ "s'" +#~ msgstr "êøòî äéä åìéàë `%s' éøì÷ñ øèîøôá ùåîéù ïåéñð" + +#~ msgid "internal error: Node_var_array with null vname" +#~ msgstr "ñôåàî åìù vname-äù Node_var_array :úéîéðô äðëú úàéâù" + #~ msgid "BEGIN blocks must have an action part" #~ msgstr "äìåòô úøãâä ìåìëì áééç BEGIN ÷åìá" diff -urN gawk-3.1.2/po/insert-header.sin gawk-3.1.3/po/insert-header.sin --- gawk-3.1.2/po/insert-header.sin 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/po/insert-header.sin 2003-06-16 03:25:34.000000000 -0700 @@ -0,0 +1,23 @@ +# Sed script that inserts the file called HEADER before the header entry. +# +# At each occurrence of a line starting with "msgid ", we execute the following +# commands. At the first occurrence, insert the file. At the following +# occurrences, do nothing. The distinction between the first and the following +# occurrences is achieved by looking at the hold space. +/^msgid /{ +x +# Test if the hold space is empty. +s/m/m/ +ta +# Yes it was empty. First occurrence. Read the file. +r HEADER +# Output the file's contents by reading the next line. But don't lose the +# current line while doing this. +g +N +bb +:a +# The hold space was nonempty. Following occurrences. Do nothing. +x +:b +} Binary files gawk-3.1.2/po/it.gmo and gawk-3.1.3/po/it.gmo differ diff -urN gawk-3.1.2/po/it.po gawk-3.1.3/po/it.po --- gawk-3.1.2/po/it.po 2003-03-19 04:25:12.000000000 -0800 +++ gawk-3.1.3/po/it.po 2003-07-07 11:20:33.000000000 -0700 @@ -1,76 +1,74 @@ # Italian messages for GNU Awk # Copyright (C) 2002-2003 Free Software Foundation, Inc. -# Antonio Colombo , 2003. +# Antonio Colombo , 2003. # msgid "" msgstr "" "Project-Id-Version: gawk 3.1.35\n" -"POT-Creation-Date: 2003-03-19 14:25+0200\n" -"PO-Revision-Date: 2003-02-18 11:11+0100\n" -"Last-Translator: Antonio Colombo \n" +"Report-Msgid-Bugs-To: arnold@skeeve.com\n" +"POT-Creation-Date: 2003-07-07 11:20-0700\n" +"PO-Revision-Date: 2003-06-10 11:11+0100\n" +"Last-Translator: Antonio Colombo \n" "Language-Team: Italian \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=ISO-8859-8\n" "Content-Transfer-Encoding: 8-bit\n" -#: array.c:274 array.c:309 array.c:314 eval.c:494 +#: array.c:112 +#, c-format +msgid "attempt to use scalar parameter `%s' as an array" +msgstr "tentativo di unare il parametro scalare `%s' come un vettore" + +#: array.c:113 #, c-format msgid "attempt to use scalar `%s' as array" msgstr "tentativo di usare scalare '%s' come vettore" -#: array.c:338 +#: array.c:151 +#, c-format +msgid "from %s" +msgstr "da %s" + +#: array.c:506 #, c-format msgid "reference to uninitialized element `%s[\"%s\"]'" msgstr "referenza a elemento non inizializzato `%s[\"%s\"]'" -#: array.c:344 +#: array.c:512 #, c-format msgid "subscript of array `%s' is null string" msgstr "l'indice del vettore '%s' è una stringa nulla" -#: array.c:412 array.c:425 array.c:466 +#: array.c:609 #, c-format msgid "delete: index `%s' not in array `%s'" msgstr "delete: indice `%s' non presente nel vettore `%s'" -#: array.c:432 array.c:515 -#, c-format -msgid "delete: illegal use of variable `%s' as array" -msgstr "delete: use non permesso della variabile `%s' come vettore" - -#: array.c:633 +#: array.c:769 #, c-format msgid "%s: empty (null)\n" msgstr "%s: vuoto (nullo)\n" -#: array.c:638 +#: array.c:774 #, c-format msgid "%s: empty (zero)\n" msgstr "%s: vuoto (zero)\n" -#: array.c:642 +#: array.c:778 #, c-format msgid "%s: table_size = %d, array_size = %d\n" msgstr "%s: dimensione_tabella = %d, dimensione_vettore = %d\n" -#: array.c:671 +#: array.c:807 #, c-format msgid "%s: is parameter\n" msgstr "%s: è parametro\n" -#: array.c:676 +#: array.c:812 #, c-format msgid "%s: array_ref to %s\n" msgstr "%s: referenza_vettoriale a %s\n" -#: array.c:975 -msgid "asort: first argument is not an array" -msgstr "asort: il primo argomento non è un vettore" - -#: array.c:984 -msgid "asort: second argument is not an array" -msgstr "asort: il secondo argomento non è un vettore" - #: awkgram.y:208 #, c-format msgid "%s blocks must have an action part" @@ -90,264 +88,277 @@ msgid "regexp constant `/%s/' looks like a C comment, but is not" msgstr "costante 'regexp' `/%s/' sembra un commento commento C, ma non lo è" -#: awkgram.y:340 +#: awkgram.y:340 awkgram.y:615 msgid "statement may have no effect" msgstr "istruzione che può non aver alcun effetto" -#: awkgram.y:431 awkgram.y:451 +#: awkgram.y:435 awkgram.y:455 #, c-format msgid "`%s' used in %s action" msgstr "`%s' usato in 'azione' %s" -#: awkgram.y:444 awkgram.y:447 +#: awkgram.y:448 awkgram.y:451 msgid "`nextfile' is a gawk extension" msgstr "`nextfile' è un'estensione gawk" -#: awkgram.y:461 +#: awkgram.y:465 msgid "`return' used outside function context" msgstr "`return' usato fuori da una funzione" -#: awkgram.y:500 +#: awkgram.y:504 msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'" msgstr "`print' da solo in BEGIN o END dovrebbe forse essere `print \"\"'" -#: awkgram.y:513 awkgram.y:520 +#: awkgram.y:517 awkgram.y:524 msgid "`delete array' is a gawk extension" msgstr "`delete array' è un'estensione gawk" -#: awkgram.y:528 awkgram.y:535 +#: awkgram.y:532 awkgram.y:539 msgid "`delete(array)' is a non-portable tawk extension" msgstr "`delete(array)' è un'estensione tawk non-portabile" -#: awkgram.y:578 +#: awkgram.y:583 +#, c-format +msgid "duplicate case values in switch body: %s" +msgstr "valori di 'case' doppi all'interno di uno 'switch': %s" + +#: awkgram.y:593 +msgid "Duplicate `default' detected in switch body" +msgstr "Valori per difetto doppi all'interno di uno 'switch'" + +#: awkgram.y:681 msgid "multistage two-way pipelines don't work" msgstr "'pipelines' multistadio bidirezionali non funzionano" -#: awkgram.y:669 +#: awkgram.y:772 msgid "regular expression on right of assignment" msgstr "espressione regolare usata per assegnare un valore" -#: awkgram.y:679 +#: awkgram.y:782 msgid "regular expression on left of `~' or `!~' operator" msgstr "espressione regolare prima di operatore `~' o `!~'" -#: awkgram.y:687 +#: awkgram.y:790 msgid "regular expression on right of comparison" msgstr "espressione regolare a destra in un confronto" -#: awkgram.y:754 +#: awkgram.y:857 msgid "non-redirected `getline' undefined inside END action" msgstr "`getline' non re-diretta indefinita dentro 'azione' END" -#: awkgram.y:781 +#: awkgram.y:884 msgid "call of `length' without parentheses is not portable" msgstr "chiamata a `length' senza parentesi non portabile" -#: awkgram.y:784 +#: awkgram.y:887 msgid "call of `length' without parentheses is deprecated by POSIX" msgstr "chiamata a `length' senza parentesi sconsigliata da POSIX" -#: awkgram.y:835 +#: awkgram.y:940 +msgid "use of non-array as array" +msgstr "uso di non-vettore come vettore" + +#: awkgram.y:942 msgid "invalid subscript expression" msgstr "espressione indice invalida" -#: awkgram.y:1020 +#: awkgram.y:1140 msgid "unexpected newline or end of string" msgstr "carattere 'a capo' o fine stringa inaspettati" -#: awkgram.y:1115 +#: awkgram.y:1235 msgid "empty program text on command line" msgstr "programma nullo sulla linea comandi" -#: awkgram.y:1172 +#: awkgram.y:1292 #, c-format msgid "can't open source file `%s' for reading (%s)" msgstr "non riesco ad aprire file sorgente `%s' in lettura (%s)" -#: awkgram.y:1207 +#: awkgram.y:1327 #, c-format msgid "can't read sourcefile `%s' (%s)" msgstr "non riesco a leggere file sorgente `%s' (%s)" -#: awkgram.y:1215 +#: awkgram.y:1335 #, c-format msgid "source file `%s' is empty" msgstr "file sorgente `%s' vuoto" -#: awkgram.y:1417 awkgram.y:1527 awkgram.y:1545 awkgram.y:1895 awkgram.y:1980 +#: awkgram.y:1537 awkgram.y:1647 awkgram.y:1665 awkgram.y:2015 awkgram.y:2100 msgid "source file does not end in newline" msgstr "file sorgente non termina con carattere 'a capo'" -#: awkgram.y:1481 +#: awkgram.y:1601 msgid "unterminated regexp ends with `\\' at end of file" msgstr "espressione regolare non completata termina con `\\' a fine file" -#: awkgram.y:1501 +#: awkgram.y:1621 msgid "unterminated regexp" msgstr "espressione regolare non completata" -#: awkgram.y:1504 +#: awkgram.y:1624 msgid "unterminated regexp at end of file" msgstr "espressione regolare non completata a fine file" -#: awkgram.y:1571 +#: awkgram.y:1691 msgid "use of `\\ #...' line continuation is not portable" msgstr "uso di `\\ #...' continuazione linea non portabile" -#: awkgram.y:1583 +#: awkgram.y:1703 msgid "backslash not last character on line" msgstr "'\\' non è l'ultimo carattere della linea" -#: awkgram.y:1628 +#: awkgram.y:1748 msgid "POSIX does not allow operator `**='" msgstr "POSIX non permette l'operatore `**='" -#: awkgram.y:1630 +#: awkgram.y:1750 msgid "old awk does not support operator `**='" msgstr "il vecchio awk non supporta l'operatore `**='" -#: awkgram.y:1639 +#: awkgram.y:1759 msgid "POSIX does not allow operator `**'" msgstr "POSIX non permette l'operatore `**'" -#: awkgram.y:1641 +#: awkgram.y:1761 msgid "old awk does not support operator `**'" msgstr "il vecchio awk non supporta l'operatore `**'" -#: awkgram.y:1672 +#: awkgram.y:1792 msgid "operator `^=' is not supported in old awk" msgstr "l'operatore `^=' non è supportato nel vecchio awk" -#: awkgram.y:1680 +#: awkgram.y:1800 msgid "operator `^' is not supported in old awk" msgstr "l'operatore `^' non è supportato nel vecchio awk" -#: awkgram.y:1764 awkgram.y:1781 +#: awkgram.y:1884 awkgram.y:1901 msgid "unterminated string" msgstr "stringa non terminata" -#: awkgram.y:1941 +#: awkgram.y:2061 #, c-format msgid "invalid char '%c' in expression" msgstr "carattere '%c' invalido in un'espressione" -#: awkgram.y:2001 +#: awkgram.y:2121 #, c-format msgid "`%s' is a gawk extension" msgstr "`%s' è un'estensione gawk" -#: awkgram.y:2004 +#: awkgram.y:2124 #, c-format msgid "`%s' is a Bell Labs extension" msgstr "`%s' è un'estensione Bell Labs" -#: awkgram.y:2007 +#: awkgram.y:2127 #, c-format msgid "POSIX does not allow `%s'" msgstr "POSIX non permette `%s'" -#: awkgram.y:2011 +#: awkgram.y:2131 #, c-format msgid "`%s' is not supported in old awk" msgstr "`%s' non è supportato nel vecchio awk" -#: awkgram.y:2038 +#: awkgram.y:2158 msgid "`goto' considered harmful!\n" msgstr "`goto' considerato pericoloso!\n" -#: awkgram.y:2102 +#: awkgram.y:2220 #, c-format msgid "%d is invalid as number of arguments for %s" msgstr "%d invalido come numero di argomenti per %s" -#: awkgram.y:2121 awkgram.y:2124 +#: awkgram.y:2239 awkgram.y:2242 msgid "match: third argument is a gawk extension" msgstr "match: il terzo argomento è un'estensione gawk" -#: awkgram.y:2137 +#: awkgram.y:2255 #, c-format msgid "%s: string literal as last arg of substitute has no effect" msgstr "%s: una stringa come ultimo argomento di 'substitute' non ha effetto" -#: awkgram.y:2140 +#: awkgram.y:2258 #, c-format msgid "%s third parameter is not a changeable object" msgstr "il terzo parametro di '%s' non è un oggetto modificabile" -#: awkgram.y:2167 awkgram.y:2170 +#: awkgram.y:2285 awkgram.y:2288 msgid "close: second argument is a gawk extension" msgstr "close: il secondo argomento è un'estensione gawk" -#: awkgram.y:2180 +#: awkgram.y:2298 msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore" msgstr "" "uso scorretto di dcgettext(_\"...\"): togliere il carattere '_' iniziale" -#: awkgram.y:2195 +#: awkgram.y:2313 msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore" msgstr "" "uso scorretto di dcngettext(_\"...\"): togliere il carattere '_' iniziale" -#: awkgram.y:2266 +#: awkgram.y:2384 #, c-format msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d" msgstr "funzione `%s': parametro #%d, `%s', duplica parametro #%d" -#: awkgram.y:2299 +#: awkgram.y:2417 #, c-format msgid "function `%s': parameter `%s' shadows global variable" msgstr "funzione `%s': parametro `%s' nasconde variabile globale" -#: awkgram.y:2411 +#: awkgram.y:2529 #, c-format msgid "could not open `%s' for writing (%s)" msgstr "non riesco ad aprire `%s' in scrittura (%s)" -#: awkgram.y:2412 profile.c:93 +#: awkgram.y:2530 profile.c:93 msgid "sending profile to standard error" msgstr "mando profilo a 'standard error'" -#: awkgram.y:2442 +#: awkgram.y:2562 #, c-format msgid "%s: close failed (%s)" msgstr "%s: 'close' fallita (%s)" -#: awkgram.y:2566 +#: awkgram.y:2684 msgid "shadow_funcs() called twice!" msgstr "shadow_funcs() chiamata due volte!" -#: awkgram.y:2593 +#: awkgram.y:2711 msgid "there were shadowed variables." msgstr "c'erano variabili nascoste." -#: awkgram.y:2666 +#: awkgram.y:2784 #, c-format msgid "function `%s': can't use function name as parameter name" msgstr "funzione `%s': non posso usare nome della funzione come nome parametro" -#: awkgram.y:2676 +#: awkgram.y:2794 #, c-format msgid "function name `%s' previously defined" msgstr "funzione di nome `%s' definita in precedenza" -#: awkgram.y:2827 awkgram.y:2833 +#: awkgram.y:2945 awkgram.y:2951 #, c-format msgid "function `%s' called but never defined" msgstr "funzione `%s' chiamata ma mai definita" -#: awkgram.y:2836 +#: awkgram.y:2954 #, c-format msgid "function `%s' defined but never called" msgstr "funzione `%s' definita ma mai chiamata" -#: awkgram.y:2863 +#: awkgram.y:2981 #, c-format msgid "regexp constant for parameter #%d yields boolean value" msgstr "" "espressione regolare di valore costante per parametro #%d genera valore " "booleano" -#: awkgram.y:2876 +#: awkgram.y:2994 #, c-format msgid "" "function `%s' called with space between name and `(',\n" @@ -356,194 +367,199 @@ "funzione `%s' chiamata con spazio tra il nome e `(',\n" "%s" -#: awkgram.y:2878 +#: awkgram.y:2996 msgid "or used as a variable or an array" msgstr "o usato come variabile o come vettore" -#: builtin.c:111 +#: builtin.c:137 #, c-format msgid "%s to \"%s\" failed (%s)" msgstr "%s a \"%s\" fallita (%s)" -#: builtin.c:112 +#: builtin.c:138 msgid "standard output" msgstr "standard output" -#: builtin.c:113 +#: builtin.c:139 msgid "reason unknown" msgstr "ragione indeterminata" -#: builtin.c:126 +#: builtin.c:152 msgid "exp: received non-numeric argument" msgstr "exp: argomento non numerico" -#: builtin.c:132 +#: builtin.c:158 #, c-format msgid "exp: argument %g is out of range" msgstr "exp: argomento %g non accettabile" -#: builtin.c:190 +#: builtin.c:216 #, c-format msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing" msgstr "" "fflush: non posso scaricare: 'pipe' `%s' aperta in lettura, non in scrittura" -#: builtin.c:193 +#: builtin.c:219 #, c-format msgid "fflush: cannot flush: file `%s' opened for reading, not writing" msgstr "" "fflush: non posso scaricare: file `%s' aperto in lettura, non in scrittura" -#: builtin.c:205 +#: builtin.c:231 #, c-format msgid "fflush: `%s' is not an open file, pipe or co-process" msgstr "fflush: `%s' non è un file aperto, una 'pipe' o un co-processo" -#: builtin.c:299 +#: builtin.c:325 msgid "index: received non-string first argument" msgstr "index: il primo argomento non è una stringa" -#: builtin.c:301 +#: builtin.c:327 msgid "index: received non-string second argument" msgstr "index: il secondo argomento non è una stringa" -#: builtin.c:411 +#: builtin.c:437 msgid "int: received non-numeric argument" msgstr "int: argomento non numerico" -#: builtin.c:428 +#: builtin.c:454 msgid "length: received non-string argument" msgstr "length: l'argomento non è una stringa" -#: builtin.c:444 +#: builtin.c:470 msgid "log: received non-numeric argument" msgstr "log: argomento non numerico" -#: builtin.c:447 +#: builtin.c:473 #, c-format msgid "log: received negative argument %g" msgstr "log: argomento negativo %g" -#: builtin.c:609 builtin.c:612 +#: builtin.c:635 builtin.c:638 msgid "must use `count$' on all formats or none" msgstr "'count$' va usato per tutti i formati o per nessuno" -#: builtin.c:714 +#: builtin.c:740 msgid "`$' is not permitted in awk formats" msgstr "`$' non permesso nei 'format' awk" -#: builtin.c:720 +#: builtin.c:746 msgid "arg count with `$' must be > 0" msgstr "il numero di argomento con `$' deve essere > 0" -#: builtin.c:722 +#: builtin.c:748 #, c-format msgid "arg count %ld greater than total number of supplied arguments" msgstr "" "numero di argomenti (%ld) maggiore del numero totale di argomenti specificati" -#: builtin.c:724 +#: builtin.c:750 msgid "`$' not permitted after period in format" msgstr "`$' non permesso dopo un punto nel 'format'" -#: builtin.c:737 +#: builtin.c:763 msgid "no `$' supplied for positional field width or precision" msgstr "" "nessun `$' specificato per larghezza o precisione di un campo posizionale" -#: builtin.c:795 +#: builtin.c:821 msgid "`l' is meaningless in awk formats; ignored" msgstr "`l' non ha senso nei 'format' awk; ignorata" -#: builtin.c:799 +#: builtin.c:825 msgid "`l' is not permitted in POSIX awk formats" msgstr "`l' non permessa nei 'format' awk POSIX" -#: builtin.c:810 +#: builtin.c:836 msgid "`L' is meaningless in awk formats; ignored" msgstr "`L' non ha senso nei 'format' awk; ignorata" -#: builtin.c:814 +#: builtin.c:840 msgid "`L' is not permitted in POSIX awk formats" msgstr "`L' non permessa nei 'format' awk POSIX" -#: builtin.c:825 +#: builtin.c:851 msgid "`h' is meaningless in awk formats; ignored" msgstr "`h' non ha senso nei 'format' awk; ignorata" -#: builtin.c:829 +#: builtin.c:855 msgid "`h' is not permitted in POSIX awk formats" msgstr "`h' non permessa nei 'format' awk POSIX" -#: builtin.c:1078 +#: builtin.c:1055 +#, c-format +msgid "[s]printf: value %g is out of range for `%%%c' format" +msgstr "[s]printf: valore %g non accettabile per il 'format' `%%%c'" + +#: builtin.c:1108 msgid "not enough arguments to satisfy format string" msgstr "mancano argomenti per completare il 'format'" -#: builtin.c:1080 +#: builtin.c:1110 msgid "^ ran out for this one" msgstr "^ uscito per questo" -#: builtin.c:1085 +#: builtin.c:1115 msgid "[s]printf: format specifier does not have control letter" msgstr "[s]printf: il designatore di 'format' non ha una lettera di controllo" -#: builtin.c:1088 +#: builtin.c:1118 msgid "too many arguments supplied for format string" msgstr "troppi argomenti specificati per il 'format'" -#: builtin.c:1154 builtin.c:1157 +#: builtin.c:1184 builtin.c:1187 msgid "printf: no arguments" msgstr "printf: manca argomento" -#: builtin.c:1181 +#: builtin.c:1211 msgid "sqrt: received non-numeric argument" msgstr "sqrt: argomento non numerico" -#: builtin.c:1185 +#: builtin.c:1215 #, c-format msgid "sqrt: called with negative argument %g" msgstr "sqrt: chiamata con argomento negativo %g" -#: builtin.c:1207 +#: builtin.c:1238 #, c-format msgid "substr: start index %g is invalid, using 1" msgstr "substr: indice di partenza %g invalido, uso 1" -#: builtin.c:1212 +#: builtin.c:1243 #, c-format msgid "substr: non-integer start index %g will be truncated" msgstr "substr: indice di partenza non intero %g: sarà troncato" -#: builtin.c:1231 -#, c-format -msgid "substr: length %g is <= 0" +#: builtin.c:1262 +#, fuzzy, c-format +msgid "substr: length %g is not >= 1" msgstr "substr: lunghezza %g <= 0" -#: builtin.c:1233 -#, c-format -msgid "substr: length %g is < 0" -msgstr "substr: lunghezza %g < 0" +#: builtin.c:1264 +#, fuzzy, c-format +msgid "substr: length %g is not >= 0" +msgstr "substr: lunghezza %g <= 0" -#: builtin.c:1240 +#: builtin.c:1271 #, c-format msgid "substr: non-integer length %g will be truncated" msgstr "substr: lunghezza non intera %g: sarà truncata" -#: builtin.c:1245 +#: builtin.c:1276 #, c-format msgid "substr: length %g too big for string indexing, truncating to %g" msgstr "substr: lunghezza %g troppo elevata per indice stringa, tronco a %g" -#: builtin.c:1257 +#: builtin.c:1288 msgid "substr: source string is zero length" msgstr "substr: stringa di partenza lunga zero" -#: builtin.c:1263 +#: builtin.c:1294 #, c-format msgid "substr: start index %g is past end of string" msgstr "substr: indice di partenza %g oltre la fine della stringa" -#: builtin.c:1271 +#: builtin.c:1302 #, c-format msgid "" "substr: length %g at start index %g exceeds length of first argument (%lu)" @@ -551,234 +567,239 @@ "substr: lunghezza %g all'indice di partenza %g supera la lunghezza del primo " "argomento (%lu)" -#: builtin.c:1306 +#: builtin.c:1337 msgid "strftime: received non-string first argument" msgstr "strftime: il primo argomento non è una stringa" -#: builtin.c:1312 +#: builtin.c:1343 msgid "strftime: received empty format string" msgstr "strftime: 'format' è una stringa nulla" -#: builtin.c:1321 +#: builtin.c:1352 msgid "strftime: received non-numeric second argument" msgstr "strftime: il secondo argomento non è numerico" -#: builtin.c:1384 +#: builtin.c:1415 msgid "mktime: received non-string argument" msgstr "mktime: l'argomento non è una stringa" -#: builtin.c:1429 +#: builtin.c:1460 msgid "system: received non-string argument" msgstr "system: l'argomento non è una stringa" -#: builtin.c:1573 +#: builtin.c:1581 eval.c:1883 +#, c-format +msgid "reference to uninitialized field `$%d'" +msgstr "referenza a variabile non inizializzata `$%d'" + +#: builtin.c:1608 msgid "tolower: received non-string argument" msgstr "tolower: l'argomento non è una stringa" -#: builtin.c:1622 +#: builtin.c:1657 msgid "toupper: received non-string argument" msgstr "toupper: l'argomento non è una stringa" -#: builtin.c:1667 +#: builtin.c:1702 msgid "atan2: received non-numeric first argument" msgstr "atan2: il primo argomento non è numerico" -#: builtin.c:1669 +#: builtin.c:1704 msgid "atan2: received non-numeric second argument" msgstr "atan2: il secondo argomento non è numerico" -#: builtin.c:1688 +#: builtin.c:1723 msgid "sin: received non-numeric argument" msgstr "sin: l'argomento non è numerico" -#: builtin.c:1704 +#: builtin.c:1739 msgid "cos: received non-numeric argument" msgstr "cos: l'argomento non è numerico" -#: builtin.c:1748 +#: builtin.c:1788 msgid "srand: received non-numeric argument" msgstr "srand: l'argomento non è numerico" -#: builtin.c:1787 +#: builtin.c:1823 msgid "match: third argument is not an array" msgstr "match: il terzo argomento non è un vettore" -#: builtin.c:2264 -msgid "gensub: 3rd argument of 0 treated as 1" +#: builtin.c:2307 +msgid "gensub: third argument of 0 treated as 1" msgstr "gensub: il terzo argomento è 0, trattato come 1" -#: builtin.c:2375 builtin.c:2377 +#: builtin.c:2416 builtin.c:2418 msgid "lshift: received non-numeric first argument" msgstr "lshift: il primo argomento non è numerico" -#: builtin.c:2379 +#: builtin.c:2420 #, c-format msgid "lshift(%lf, %lf): negative values will give strange results" msgstr "lshift(%lf, %lf): valori negativi daranno risultati strani" -#: builtin.c:2381 +#: builtin.c:2422 #, c-format msgid "lshift(%lf, %lf): fractional values will be truncated" msgstr "lshift(%lf, %lf): valori con decimali verranno troncati" -#: builtin.c:2383 +#: builtin.c:2424 #, c-format msgid "lshift(%lf, %lf): too large shift value will give strange results" msgstr "lshift(%lf, %lf): valori troppo alti daranno risultati strani" -#: builtin.c:2412 builtin.c:2414 +#: builtin.c:2453 builtin.c:2455 msgid "rshift: received non-numeric first argument" msgstr "rshift: il primo argomento non è numerico" -#: builtin.c:2416 +#: builtin.c:2457 #, c-format msgid "rshift(%lf, %lf): negative values will give strange results" msgstr "rshift(%lf, %lf): valori negativi daranno risultati strani" -#: builtin.c:2418 +#: builtin.c:2459 #, c-format msgid "rshift(%lf, %lf): fractional values will be truncated" msgstr "rshift(%lf, %lf): valori con decimali verranno troncati" -#: builtin.c:2420 +#: builtin.c:2461 #, c-format msgid "rshift(%lf, %lf): too large shift value will give strange results" msgstr "rshift(%lf, %lf): valori troppo alti daranno risultati strani" -#: builtin.c:2449 builtin.c:2451 +#: builtin.c:2490 builtin.c:2492 msgid "and: received non-numeric first argument" msgstr "and: il primo argomento non è numerico" -#: builtin.c:2453 +#: builtin.c:2494 #, c-format msgid "and(%lf, %lf): negative values will give strange results" msgstr "and(%lf, %lf): valori negativi daranno risultati strani" -#: builtin.c:2455 +#: builtin.c:2496 #, c-format msgid "and(%lf, %lf): fractional values will be truncated" msgstr "and(%lf, %lf): valori con decimali verranno troncati" -#: builtin.c:2484 builtin.c:2486 +#: builtin.c:2525 builtin.c:2527 msgid "or: received non-numeric first argument" msgstr "or: il primo argomento non è numerico" -#: builtin.c:2488 +#: builtin.c:2529 #, c-format msgid "or(%lf, %lf): negative values will give strange results" msgstr "or(%lf, %lf): valori negativi daranno risultati strani" -#: builtin.c:2490 +#: builtin.c:2531 #, c-format msgid "or(%lf, %lf): fractional values will be truncated" msgstr "or(%lf, %lf): valori con decimali verranno troncati" -#: builtin.c:2519 builtin.c:2521 +#: builtin.c:2560 builtin.c:2562 msgid "xor: received non-numeric first argument" msgstr "xor: il primo argomento non è numerico" -#: builtin.c:2523 +#: builtin.c:2564 #, c-format msgid "xor(%lf, %lf): negative values will give strange results" msgstr "xor(%lf, %lf): valori negativi daranno risultati strani" -#: builtin.c:2525 +#: builtin.c:2566 #, c-format msgid "xor(%lf, %lf): fractional values will be truncated" msgstr "xor(%lf, %lf): valori con decimali verranno troncati" -#: builtin.c:2553 +#: builtin.c:2594 msgid "compl: received non-numeric argument" msgstr "compl: l'argomento non è numerico" -#: builtin.c:2555 +#: builtin.c:2596 #, c-format msgid "compl(%lf): negative value will give strange results" msgstr "compl(%lf): valore negativo darà risultati strani" -#: builtin.c:2557 +#: builtin.c:2598 #, c-format msgid "compl(%lf): fractional value will be truncated" msgstr "compl(%lf): valore con decimali verrà troncato" -#: builtin.c:2728 +#: builtin.c:2771 #, c-format msgid "dcgettext: `%s' is not a valid locale category" msgstr "dcgettext: `%s' non è una categoria 'locale' valida" -#: eval.c:262 +#: eval.c:266 #, c-format msgid "unknown nodetype %d" msgstr "tipo nodo sconosciuto %d" -#: eval.c:310 +#: eval.c:312 msgid "buffer overflow in genflags2str" msgstr "superament limiti buffer in 'genflags2str'" -#: eval.c:555 +#: eval.c:647 #, c-format msgid "for loop: array `%s' changed size from %ld to %ld during loop execution" msgstr "" "ciclo for: vettore `%s' ha cambiato dimensione da %ld a %ld durante " "l'esecuzione del ciclo" -#: eval.c:576 +#: eval.c:668 msgid "`break' outside a loop is not portable" msgstr "`break' all'esterno di un ciclo non è portabile" -#: eval.c:580 +#: eval.c:672 msgid "`break' outside a loop is not allowed" msgstr "`break' all'esterno di un ciclo non è consentito" -#: eval.c:597 +#: eval.c:689 msgid "`continue' outside a loop is not portable" msgstr "`continue' all'esterno di un ciclo non è portabile" -#: eval.c:601 +#: eval.c:693 msgid "`continue' outside a loop is not allowed" msgstr "`continue' all'esterno di un ciclo non è consentito" -#: eval.c:635 +#: eval.c:727 msgid "`next' cannot be called from a BEGIN rule" msgstr "`next' non può essere chiamato da una regola BEGIN" -#: eval.c:637 +#: eval.c:729 msgid "`next' cannot be called from an END rule" msgstr "`next' non può essere chiamato da una regola END" -#: eval.c:646 +#: eval.c:738 msgid "`nextfile' cannot be called from a BEGIN rule" msgstr "`nextfile' non può essere chiamato da una regola BEGIN" -#: eval.c:648 +#: eval.c:740 msgid "`nextfile' cannot be called from an END rule" msgstr "`nextfile' non può essere chiamato da una regola END" -#: eval.c:696 +#: eval.c:785 msgid "statement has no effect" msgstr "istruzione che non fa nulla" -#: eval.c:731 eval.c:761 eval.c:1733 -#, c-format -msgid "reference to uninitialized variable `%s'" -msgstr "referenza a variabile non inizializzata `%s'" - -#: eval.c:739 eval.c:1721 +#: eval.c:828 eval.c:1726 #, c-format msgid "can't use function name `%s' as variable or array" msgstr "non posso usare nome di funzione `%s' come variabile o vettore" -#: eval.c:746 eval.c:752 +#: eval.c:835 eval.c:841 #, c-format msgid "reference to uninitialized argument `%s'" msgstr "referenza ad argomento non inizializzato `%s'" -#: eval.c:810 eval.c:1728 profile.c:773 +#: eval.c:848 eval.c:907 eval.c:1732 eval.c:1742 profile.c:807 #, c-format msgid "attempt to use array `%s' in a scalar context" msgstr "tentativo di usare vettore `%s' in un contesto scalare" -#: eval.c:910 +#: eval.c:858 eval.c:1752 +#, c-format +msgid "reference to uninitialized variable `%s'" +msgstr "referenza a variabile non inizializzata `%s'" + +#: eval.c:1007 msgid "" "concatenation: side effects in one expression have changed the length of " "another!" @@ -786,54 +807,49 @@ "concatenatione: effetti secondari in una espressione hanno modificato la " "lunghezza di un'altra espressione!" -#: eval.c:935 +#: eval.c:1032 msgid "assignment used in conditional context" msgstr "assegnamento usato nel contesto di un test condizionale" -#: eval.c:1026 +#: eval.c:1122 msgid "division by zero attempted" msgstr "tentativo di dividere per zero" -#: eval.c:1041 +#: eval.c:1137 #, c-format msgid "division by zero attempted in `%%'" msgstr "divisione per zero tentata in `%%'" -#: eval.c:1056 profile.c:649 +#: eval.c:1152 profile.c:683 #, c-format msgid "illegal type (%s) in tree_eval" msgstr "tipo non ammesso (%s) in 'tree_eval'" -#: eval.c:1232 +#: eval.c:1328 msgid "division by zero attempted in `/='" msgstr "divisione per zero tentata in `/='" -#: eval.c:1250 +#: eval.c:1346 #, c-format msgid "division by zero attempted in `%%='" msgstr "divisione per zero tentata in `%%='" -#: eval.c:1510 -#, c-format -msgid "%s (from %s)" -msgstr "%s (da %s)" - -#: eval.c:1569 +#: eval.c:1586 #, c-format msgid "function `%s' called with more arguments than declared" msgstr "funzione `%s' chiamata con più argomenti di quelli previsti" -#: eval.c:1628 +#: eval.c:1633 #, c-format msgid "function `%s' not defined" msgstr "funzione `%s' non definita" -#: eval.c:1634 +#: eval.c:1639 #, c-format msgid "function %s called\n" msgstr "funzione %s chiamata\n" -#: eval.c:1693 +#: eval.c:1698 msgid "" "\n" "\t# Function Call Stack:\n" @@ -843,46 +859,41 @@ "\t# 'Stack' (Pila) Chiamate Funzione:\n" "\n" -#: eval.c:1696 +#: eval.c:1701 msgid "\t# -- main --\n" msgstr "\t# -- principale --\n" -#: eval.c:1850 +#: eval.c:1867 msgid "attempt to field reference from non-numeric value" msgstr "tentativo di referenziare campo da valore non numerico" -#: eval.c:1852 +#: eval.c:1869 msgid "attempt to reference from null string" msgstr "tentativo to referenziare da stringa nulla" -#: eval.c:1858 +#: eval.c:1875 #, c-format msgid "attempt to access field %d" msgstr "tentativo di accedere al campo %d" -#: eval.c:1874 -#, c-format -msgid "attempt to use scalar parameter `%s' as an array" -msgstr "tentativo di unare il parametro scalare `%s' come un vettore" - -#: eval.c:1886 eval.c:1893 profile.c:865 +#: eval.c:1896 eval.c:1903 profile.c:900 msgid "assignment is not allowed to result of builtin function" msgstr "assegnamento non permesso al risultato di una funzione interna" -#: eval.c:1941 +#: eval.c:1951 msgid "`IGNORECASE' is a gawk extension" msgstr "`IGNORECASE' è un'estensione gawk" -#: eval.c:1970 +#: eval.c:1980 msgid "`BINMODE' is a gawk extension" msgstr "`BINMODE' è un'estensione gawk" -#: eval.c:2082 +#: eval.c:2092 #, c-format msgid "bad `%sFMT' specification `%s'" msgstr "specificazione invalida `%sFMT' `%s'" -#: eval.c:2160 +#: eval.c:2170 msgid "turning off `--lint' due to assignment to `LINT'" msgstr "disabilito `--lint' a causa di assegnamento a `LINT'" @@ -900,32 +911,32 @@ msgid "extension: library `%s': cannot call function `%s' (%s)\n" msgstr "extension: biblioteca `%s': non riesco a chiamare funzione `%s' (%s)\n" -#: ext.c:181 +#: ext.c:183 msgid "Operation Not Supported" msgstr "Operazione Non Supportata" -#: field.c:321 +#: field.c:315 msgid "NF set to negative value" msgstr "NF impostato a un valore negativo" -#: field.c:819 +#: field.c:808 msgid "split: second argument is not an array" msgstr "split: il secondo argomento non è un vettore" -#: field.c:854 +#: field.c:842 msgid "split: null string for third arg is a gawk extension" msgstr "split: la stringa nulla come terzo arg. è un'estensione gawk" -#: field.c:906 +#: field.c:894 msgid "`FIELDWIDTHS' is a gawk extension" msgstr "`FIELDWIDTHS' è un'estensione gawk" -#: field.c:933 +#: field.c:921 #, c-format msgid "field %d in FIELDWIDTHS, must be > 0" msgstr "campo %d in FIELDWIDTHS, deve essere > 0" -#: field.c:1006 +#: field.c:994 msgid "null string for `FS' is a gawk extension" msgstr "la stringa nulla usata come `FS' è un'estensione gawk" @@ -969,7 +980,7 @@ msgid "%s: invalid option -- %c\n" msgstr "%s: opzione non valida -- %c\n" -#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:431 +#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:434 #, c-format msgid "%s: option requires an argument -- %c\n" msgstr "%s: l'opzione richiede un argomento -- %c\n" @@ -984,471 +995,471 @@ msgid "%s: option `-W %s' doesn't allow an argument\n" msgstr "%s: opzione `-W %s' non prevede un argomento\n" -#: io.c:257 +#: io.c:305 #, c-format msgid "cannot open file `%s' for reading (%s)" msgstr "non riesco ad aprire file `%s' in lettura (%s)" -#: io.c:344 +#: io.c:392 #, c-format msgid "close of fd %d (`%s') failed (%s)" msgstr "chiusura di fd %d (`%s') fallita (%s)" -#: io.c:482 +#: io.c:530 #, c-format msgid "invalid tree type %s in redirect()" msgstr "tipo di albero invalido %s in redirect()" -#: io.c:488 +#: io.c:536 #, c-format msgid "expression in `%s' redirection only has numeric value" msgstr "espressione nella re-direzione `%s' ha solo un valore numerico" -#: io.c:494 +#: io.c:542 #, c-format msgid "expression for `%s' redirection has null string value" msgstr "espressione nella re-direzione `%s' ha per valore la stringa nulla" -#: io.c:499 +#: io.c:547 #, c-format msgid "filename `%s' for `%s' redirection may be result of logical expression" msgstr "" "nome file `%s' per la re-direzione `%s' può essere il risultato di una " "espressione logica" -#: io.c:521 +#: io.c:569 #, c-format msgid "unnecessary mixing of `>' and `>>' for file `%.*s'" msgstr "mistura non necessaria di `>' e `>>' per il file `%.*s'" -#: io.c:573 +#: io.c:621 #, c-format msgid "can't open pipe `%s' for output (%s)" msgstr "non posso aprire 'pipe' `%s' in scrittura (%s)" -#: io.c:582 +#: io.c:630 #, c-format msgid "can't open pipe `%s' for input (%s)" msgstr "non posso aprire 'pipe' `%s' in lettura (%s)" -#: io.c:595 +#: io.c:643 #, c-format msgid "can't open two way socket `%s' for input/output (%s)" msgstr "" "non posso aprire 'socket' bidirezionale `%s' per lettura/scrittura (%s)" -#: io.c:599 +#: io.c:647 #, c-format msgid "can't open two way pipe `%s' for input/output (%s)" msgstr "non posso aprire 'pipe' bidirezionale `%s' per lettura/scrittura (%s)" -#: io.c:675 +#: io.c:723 #, c-format msgid "can't redirect from `%s' (%s)" msgstr "non posso re-dirigere da `%s' (%s)" -#: io.c:678 +#: io.c:726 #, c-format msgid "can't redirect to `%s' (%s)" msgstr "non posso re-dirigere a `%s' (%s)" -#: io.c:717 +#: io.c:765 msgid "" "reached system limit for open files: starting to multiplex file descriptors" msgstr "" "numero massimo consentito di file aperti raggiunto: comincio a riutilizzare " "i descrittori di file" -#: io.c:729 +#: io.c:777 #, c-format msgid "close of `%s' failed (%s)." msgstr "chiusura di `%s' fallita (%s)." -#: io.c:736 +#: io.c:784 msgid "too many pipes or input files open" msgstr "troppe 'pipe' o file di input aperti" -#: io.c:759 +#: io.c:807 msgid "close: second argument must be `to' or `from'" msgstr "close: il secondo argomento deve essere `a' o `da'" -#: io.c:773 +#: io.c:821 #, c-format msgid "close: `%.*s' is not an open file, pipe or co-process" msgstr "close: `%.*s' non è un file aperto, una 'pipe' o un co-processo" -#: io.c:777 +#: io.c:825 msgid "close of redirection that was never opened" msgstr "chiusura di una re-direzione mai aperta" -#: io.c:804 +#: io.c:862 #, c-format msgid "close: redirection `%s' not opened with `|&', second argument ignored" msgstr "close: re-direzione `%s' non aperta con `|&', ignoro secondo argomento" -#: io.c:866 +#: io.c:924 #, c-format msgid "failure status (%d) on pipe close of `%s' (%s)" msgstr "errore ritornato (%d) dalla chiusura della 'pipe' `%s' (%s)" -#: io.c:869 +#: io.c:927 #, c-format msgid "failure status (%d) on file close of `%s' (%s)" msgstr "errore ritornato (%d) dalla chiusura del file `%s' (%s)" -#: io.c:888 +#: io.c:946 #, c-format msgid "no explicit close of socket `%s' provided" msgstr "nessuna chiusura esplicita richiesta per 'socket' `%s'" -#: io.c:891 +#: io.c:949 #, c-format msgid "no explicit close of co-process `%s' provided" msgstr "nessuna chiusura esplicita richiesta per co-processo `%s'" -#: io.c:894 +#: io.c:952 #, c-format msgid "no explicit close of pipe `%s' provided" msgstr "nessuna chiusura esplicita richiesta per 'pipe' `%s'" -#: io.c:897 +#: io.c:955 #, c-format msgid "no explicit close of file `%s' provided" msgstr "nessuna chiusura esplicita richiesta per file `%s'" -#: io.c:926 io.c:980 +#: io.c:984 io.c:1038 #, c-format msgid "error writing standard output (%s)" msgstr "errore scrivendo 'standard output' (%s)" -#: io.c:930 io.c:984 +#: io.c:988 io.c:1042 #, c-format msgid "error writing standard error (%s)" msgstr "errore scrivendo 'standard error' (%s)" -#: io.c:938 +#: io.c:996 #, c-format msgid "pipe flush of `%s' failed (%s)." msgstr "scaricamento di 'pipe' `%s' fallita (%s)." -#: io.c:941 +#: io.c:999 #, c-format msgid "co-process flush of pipe to `%s' failed (%s)." msgstr "scaricamento da co-processo di 'pipe' a `%s' fallita (%s)." -#: io.c:944 +#: io.c:1002 #, c-format msgid "file flush of `%s' failed (%s)." msgstr "scaricamento di file `%s' fallita (%s)." -#: io.c:1103 +#: io.c:1161 msgid "/inet/raw client not ready yet, sorry" msgstr "spiacente, 'client' /inet/raw non ancora pronto" -#: io.c:1105 io.c:1142 +#: io.c:1163 io.c:1200 msgid "only root may use `/inet/raw'." msgstr "solo root può usare `/inet/raw'." -#: io.c:1140 +#: io.c:1198 msgid "/inet/raw server not ready yet, sorry" msgstr "spiacente, 'server' /inet/raw non ancora pronto" -#: io.c:1230 +#: io.c:1288 #, c-format msgid "no (known) protocol supplied in special filename `%s'" msgstr "nessuno protocollo (conosciuto) specificato nel filename speciale `%s'" -#: io.c:1248 +#: io.c:1306 #, c-format msgid "special file name `%s' is incomplete" msgstr "nome file speciale `%s' incompleto" -#: io.c:1260 +#: io.c:1318 #, c-format msgid "local port invalid in `%s'" msgstr "porta locale invalida in `%s'" -#: io.c:1272 +#: io.c:1330 msgid "must supply a remote hostname to `/inet'" msgstr "va fornito nome di 'host' remoto a `/inet'" -#: io.c:1287 +#: io.c:1345 msgid "must supply a remote port to `/inet'" msgstr "va fornita porta remota a `/inet'" -#: io.c:1293 +#: io.c:1351 #, c-format msgid "remote port invalid in `%s'" msgstr "porta remota invalida in `%s'" -#: io.c:1303 +#: io.c:1361 msgid "TCP/IP communications are not supported" msgstr "comunicazioni TCP/IP non supportate" -#: io.c:1312 io.c:1492 +#: io.c:1370 io.c:1551 #, c-format msgid "file `%s' is a directory" msgstr "file `%s' è una 'directory'" -#: io.c:1381 +#: io.c:1440 #, c-format msgid "use `PROCINFO[\"%s\"]' instead of `%s'" msgstr "usa `PROCINFO[\"%s\"]' invece che `%s'" -#: io.c:1413 +#: io.c:1472 msgid "use `PROCINFO[...]' instead of `/dev/user'" msgstr "usa `PROCINFO[...]' invece che `/dev/user'" -#: io.c:1478 io.c:1652 +#: io.c:1537 io.c:1711 #, c-format msgid "could not open `%s', mode `%s'" msgstr "non riesco ad aprire `%s', modo `%s'" -#: io.c:1703 +#: io.c:1762 #, c-format msgid "close of master pty failed (%s)" msgstr "fallita chiusura di 'pty' principale (%s)" -#: io.c:1705 io.c:1857 io.c:2009 +#: io.c:1764 io.c:1916 io.c:2068 #, c-format msgid "close of stdout in child failed (%s)" msgstr "fallita chiusura di 'stdout' nel processo-figlio (%s)" -#: io.c:1708 +#: io.c:1767 #, c-format msgid "moving slave pty to stdout in child failed (dup: %s)" msgstr "" "fallito trasferimento di 'pty' secondaria a 'stdout' nel processo-figlio " "(dup: %s)" -#: io.c:1710 io.c:1862 +#: io.c:1769 io.c:1921 #, c-format msgid "close of stdin in child failed (%s)" msgstr "fallita chiusura di 'stdin' nel processo-figlio (%s)" -#: io.c:1713 +#: io.c:1772 #, c-format msgid "moving slave pty to stdin in child failed (dup: %s)" msgstr "" "fallito trasferimento di 'pty' secondaria a 'stdin' nel processo-figlio " "(dup: %s)" -#: io.c:1715 io.c:1734 +#: io.c:1774 io.c:1793 #, c-format msgid "close of slave pty failed (%s)" msgstr "fallita chiusura di 'pty' secondaria (%s)" -#: io.c:1808 io.c:1860 io.c:1990 io.c:2012 +#: io.c:1867 io.c:1919 io.c:2049 io.c:2071 #, c-format msgid "moving pipe to stdout in child failed (dup: %s)" msgstr "fallito passaggio di 'pipe' a 'stdout' nel processo-figlio (dup: %s)" -#: io.c:1812 io.c:1865 +#: io.c:1871 io.c:1924 #, c-format msgid "moving pipe to stdin in child failed (dup: %s)" msgstr "fallito passaggio di pipe a 'stdin' nel processo-figlio (dup: %s)" -#: io.c:1829 io.c:2003 +#: io.c:1888 io.c:2062 msgid "restoring stdout in parent process failed\n" msgstr "fallito ripristino di 'stdout' nel processo-padre\n" -#: io.c:1834 +#: io.c:1893 msgid "restoring stdin in parent process failed\n" msgstr "fallito ripristino di 'stdin' nel processo-padre\n" -#: io.c:1868 io.c:2014 io.c:2025 +#: io.c:1927 io.c:2073 io.c:2084 #, c-format msgid "close of pipe failed (%s)" msgstr "fallita chiusura di 'pipe' (%s)" -#: io.c:1913 +#: io.c:1972 msgid "`|&' not supported" msgstr "`|&' non supportato" -#: io.c:1980 +#: io.c:2039 #, c-format msgid "cannot open pipe `%s' (%s)" msgstr "non riesco ad aprire 'pipe' `%s' (%s)" -#: io.c:2021 +#: io.c:2080 #, c-format msgid "cannot create child process for `%s' (fork: %s)" msgstr "non riesco a creare processo-figlio per `%s' (fork: %s)" -#: io.c:2364 +#: io.c:2423 #, c-format msgid "data file `%s' is empty" msgstr "file dati `%s' vuoto" -#: io.c:2407 io.c:2415 +#: io.c:2466 io.c:2474 msgid "could not allocate more input memory" msgstr "non riesco ad allocare ulteriore memoria per l'input" -#: io.c:2540 io.c:2782 io.c:3046 +#: io.c:2832 io.c:2895 #, c-format msgid "error reading input file `%s': %s" msgstr "errore leggendo file di input `%s': %s" -#: io.c:3281 +#: io.c:3020 msgid "multicharacter value of `RS' is a gawk extension" msgstr "valore multicarattere per `RS' è un'estensione gawk" -#: main.c:322 +#: main.c:324 msgid "`-m[fr]' option irrelevant in gawk" msgstr "`-m[fr]' opzione irrilevante per gawk" -#: main.c:324 +#: main.c:326 msgid "-m option usage: `-m[fr] nnn'" msgstr "-m uso opzione: `-m[fr] nnn'" -#: main.c:341 +#: main.c:343 #, c-format msgid "%s: option `-W %s' unrecognized, ignored\n" msgstr "%s: opzione `-W %s' non riconosciuta, ignorata\n" -#: main.c:378 +#: main.c:380 msgid "empty argument to `--source' ignored" msgstr "argomento di `--source' mancante, comando ignorato" -#: main.c:448 +#: main.c:451 msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'" msgstr "variable d'ambiente `POSIXLY_CORRECT' impostata: attivo `--posix'" -#: main.c:453 +#: main.c:456 msgid "`--posix' overrides `--traditional'" msgstr "`--posix' annulla `--traditional'" -#: main.c:464 +#: main.c:467 msgid "`--posix'/`--traditional' overrides `--non-decimal-data'" msgstr "`--posix'/`--traditional' annulla `--non-decimal-data'" -#: main.c:468 +#: main.c:471 #, c-format msgid "running %s setuid root may be a security problem" msgstr "eseguire %s con 'setuid' root può essere un rischio per la sicurezza" -#: main.c:509 +#: main.c:512 #, c-format msgid "can't set binary mode on stdin (%s)" msgstr "non posso impostare modalità binaria su 'stdin'(%s)" -#: main.c:512 +#: main.c:515 #, c-format msgid "can't set binary mode on stdout (%s)" msgstr "non posso impostare modalità binaria su 'stdout'(%s)" -#: main.c:514 +#: main.c:517 #, c-format msgid "can't set binary mode on stderr (%s)" msgstr "non posso impostare modalità binaria su 'stderr'(%s)" -#: main.c:544 +#: main.c:547 msgid "no program text at all!" msgstr "manca del tutto il testo del programma!" -#: main.c:612 +#: main.c:620 #, c-format msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n" msgstr "Uso: %s [opzioni in stile POSIX o GNU] -f fileprog [--] file ...\n" -#: main.c:614 +#: main.c:622 #, c-format msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n" msgstr "Usage: %s [opzioni in stile POSIX o GNU] [--] %cprogramma%c file ...\n" -#: main.c:619 +#: main.c:627 msgid "POSIX options:\t\tGNU long options:\n" msgstr "Opzioni POSIX:\t\topzioni lunghe GNU:\n" -#: main.c:620 +#: main.c:628 msgid "\t-f progfile\t\t--file=progfile\n" msgstr "\t-f fileprog\t\t--file=fileprog\n" -#: main.c:621 +#: main.c:629 msgid "\t-F fs\t\t\t--field-separator=fs\n" msgstr "\t-F fs\t\t\t--field-separator=fs\n" -#: main.c:622 +#: main.c:630 msgid "\t-v var=val\t\t--assign=var=val\n" msgstr "\t-v var=valore\t\t--assign=var=valore\n" -#: main.c:623 +#: main.c:631 msgid "\t-m[fr] val\n" msgstr "\t-m[fr] valore\n" -#: main.c:624 +#: main.c:632 msgid "\t-W compat\t\t--compat\n" msgstr "\t-W compat\t\t--compat\n" -#: main.c:625 +#: main.c:633 msgid "\t-W copyleft\t\t--copyleft\n" msgstr "\t-W copyleft\t\t--copyleft\n" -#: main.c:626 +#: main.c:634 msgid "\t-W copyright\t\t--copyright\n" msgstr "\t-W copyright\t\t--copyright\n" -#: main.c:627 +#: main.c:635 msgid "\t-W dump-variables[=file]\t--dump-variables[=file]\n" msgstr "\t-W dump-variables[=file]\t--dump-variables[=file]\n" -#: main.c:628 +#: main.c:636 msgid "\t-W gen-po\t\t--gen-po\n" msgstr "\t-W gen-po\t\t--gen-po\n" -#: main.c:629 +#: main.c:637 msgid "\t-W help\t\t\t--help\n" msgstr "\t-W help\t\t\t--help\n" -#: main.c:630 +#: main.c:638 msgid "\t-W lint[=fatal]\t\t--lint[=fatal]\n" msgstr "\t-W lint[=fatal]\t\t--lint[=fatal]\n" -#: main.c:631 +#: main.c:639 msgid "\t-W lint-old\t\t--lint-old\n" msgstr "\t-W lint-old\t\t--lint-old\n" -#: main.c:632 +#: main.c:640 msgid "\t-W non-decimal-data\t--non-decimal-data\n" msgstr "\t-W non-decimal-data\t--non-decimal-data\n" -#: main.c:634 +#: main.c:642 msgid "\t-W nostalgia\t\t--nostalgia\n" msgstr "\t-W nostalgia\t\t--nostalgia\n" -#: main.c:637 +#: main.c:645 msgid "\t-W parsedebug\t\t--parsedebug\n" msgstr "\t-W parsedebug\t\t--parsedebug\n" -#: main.c:639 +#: main.c:647 msgid "\t-W profile[=file]\t--profile[=file]\n" msgstr "\t-W profile[=file]\t--profile[=file]\n" -#: main.c:640 +#: main.c:648 msgid "\t-W posix\t\t--posix\n" msgstr "\t-W posix\t\t--posix\n" -#: main.c:641 +#: main.c:649 msgid "\t-W re-interval\t\t--re-interval\n" msgstr "\t-W re-interval\t\t--re-interval\n" -#: main.c:642 +#: main.c:650 msgid "\t-W source=program-text\t--source=program-text\n" msgstr "\t-W source=testo-programma\t--source=testo-programma\n" -#: main.c:643 +#: main.c:651 msgid "\t-W traditional\t\t--traditional\n" msgstr "\t-W traditional\t\t--traditional\n" -#: main.c:644 +#: main.c:652 msgid "\t-W usage\t\t--usage\n" msgstr "\t-W usage\t\t--usage\n" -#: main.c:645 +#: main.c:653 msgid "\t-W version\t\t--version\n" msgstr "\t-W version\t\t--version\n" -#: main.c:649 +#: main.c:657 msgid "" "\n" "To report bugs, see node `Bugs' in `gawk.info', which is\n" @@ -1460,7 +1471,7 @@ "sezione `Reporting Problems and Bugs' nella versione a stampa.\n" "\n" -#: main.c:653 +#: main.c:661 msgid "" "gawk is a pattern scanning and processing language.\n" "By default it reads standard input and writes standard output.\n" @@ -1470,7 +1481,7 @@ "Senza parametri, legge da 'standard input' e scrive su 'standard output'.\n" "\n" -#: main.c:657 +#: main.c:665 msgid "" "Examples:\n" "\tgawk '{ sum += $1 }; END { print sum }' file\n" @@ -1480,7 +1491,7 @@ "\tgawk '{ sum += $1 }; END { print sum }' file\n" "\tgawk -F: '{ print $1 }' /etc/passwd\n" -#: main.c:669 +#: main.c:682 #, c-format msgid "" "Copyright (C) 1989, 1991-%d Free Software Foundation.\n" @@ -1499,7 +1510,7 @@ "Licenza, o (a tua scelta) a una qualsiasi versione successiva.\n" "\n" -#: main.c:677 +#: main.c:690 msgid "" "This program is distributed in the hope that it will be useful,\n" "but WITHOUT ANY WARRANTY; without even the implied warranty of\n" @@ -1513,7 +1524,7 @@ "Vedi la 'GNU General Public License' per ulteriori dettagli.\n" "\n" -#: main.c:683 +#: main.c:696 msgid "" "You should have received a copy of the GNU General Public License\n" "along with this program; if not, write to the Free Software\n" @@ -1523,11 +1534,11 @@ "assieme a questo programma; se non è così, scrivi alla Free Software\n" "Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n" -#: main.c:713 +#: main.c:730 msgid "-Ft does not set FS to tab in POSIX awk" msgstr "-Ft non imposta FS a 'tab' nell'awk POSIX" -#: main.c:944 +#: main.c:956 #, c-format msgid "" "%s: `%s' argument to `-v' not in `var=value' form\n" @@ -1536,35 +1547,35 @@ "%s: `%s' argomento di `-v' non in forma `var=valore'\n" "\n" -#: main.c:964 +#: main.c:976 #, c-format msgid "`%s' is not a legal variable name" msgstr "`%s' non è un nome di variabile ammesso" -#: main.c:967 +#: main.c:979 #, c-format msgid "`%s' is not a variable name, looking for file `%s=%s'" msgstr "`%s' non è un nome di variabile, cerco il file `%s=%s'" -#: main.c:995 +#: main.c:1012 msgid "floating point exception" msgstr "eccezione floating point" -#: main.c:1002 +#: main.c:1019 msgid "fatal error: internal error" msgstr "errore fatale: errore interno" -#: main.c:1052 +#: main.c:1069 #, c-format msgid "no pre-opened fd %d" msgstr "manca 'fd' predefinita %d" -#: main.c:1057 +#: main.c:1074 #, c-format msgid "could not pre-open /dev/null for fd %d" msgstr "non riesco a predefinire /dev/null per 'fd' %d" -#: main.c:1080 main.c:1089 +#: main.c:1097 main.c:1106 #, c-format msgid "could not find groups: %s" msgstr "non riesco a trovare gruppi: %s" @@ -1585,23 +1596,23 @@ msgid "fatal: " msgstr "fatale: " -#: node.c:59 node.c:66 node.c:75 node.c:89 node.c:116 +#: node.c:58 node.c:65 node.c:74 node.c:88 node.c:115 msgid "can't convert string to float" msgstr "non riesco a convertire stringa a valore in virgola mobile" -#: node.c:357 +#: node.c:355 msgid "backslash at end of string" msgstr "'\\' a fine stringa" -#: node.c:544 +#: node.c:539 msgid "POSIX does not allow `\\x' escapes" msgstr "POSIX non permette formato `\\x'" -#: node.c:550 +#: node.c:545 msgid "no hex digits in `\\x' escape sequence" msgstr "niente cifre esadecimanli nel formato `\\x'" -#: node.c:584 +#: node.c:579 #, c-format msgid "escape sequence `\\%c' treated as plain `%c'" msgstr " sequenza in formato `\\%c' considerata come semplice `%c'" @@ -1616,24 +1627,21 @@ msgid "could not open `%s' for writing: %s" msgstr "non riesco ad aprire `%s' in scrittura: %s" -#: profile.c:409 -msgid "internal error: Node_var with null vname" -msgstr "errore interno: 'Node_var' con 'vname' nullo" +#: profile.c:449 +#, c-format +msgid "internal error: %s with null vname" +msgstr "errore interno: %s con 'vname' nullo" -#: profile.c:471 +#: profile.c:512 msgid "# treated internally as `delete'" msgstr "# gestito internamente come 'delete' (cancellazione)" -#: profile.c:545 -msgid "internal error: Node_var_array with null vname" -msgstr "errore interno: 'Node_var_array' con 'vname' nullo" - -#: profile.c:1127 +#: profile.c:1162 #, c-format msgid "\t# gawk profile, created %s\n" msgstr "\t# profilo gawk, creato %s\n" -#: profile.c:1130 +#: profile.c:1165 msgid "" "\t# BEGIN block(s)\n" "\n" @@ -1641,7 +1649,7 @@ "\t# blocco(hi) BEGIN\n" "\n" -#: profile.c:1140 +#: profile.c:1175 msgid "" "\t# Rule(s)\n" "\n" @@ -1649,7 +1657,7 @@ "\t# Regola(e)\n" "\n" -#: profile.c:1146 +#: profile.c:1181 msgid "" "\t# END block(s)\n" "\n" @@ -1657,7 +1665,7 @@ "\t# blocco(hi) END\n" "\n" -#: profile.c:1166 +#: profile.c:1201 msgid "" "\n" "\t# Functions, listed alphabetically\n" @@ -1665,7 +1673,7 @@ "\n" "\t# Funzioni, listate in ordine alfabetico\n" -#: profile.c:1376 +#: profile.c:1413 #, c-format msgid "unexpected type %s in prec_level" msgstr "tipo non previsto %s in 'prec_level'" @@ -1748,3 +1756,6 @@ #: regcomp.c:621 msgid "No previous regular expression" msgstr "Nessuna espressione regolare precedente" + +#~ msgid "substr: length %g is < 0" +#~ msgstr "substr: lunghezza %g < 0" Binary files gawk-3.1.2/po/pt_BR.gmo and gawk-3.1.3/po/pt_BR.gmo differ diff -urN gawk-3.1.2/po/pt_BR.po gawk-3.1.3/po/pt_BR.po --- gawk-3.1.2/po/pt_BR.po 2003-03-19 04:25:13.000000000 -0800 +++ gawk-3.1.3/po/pt_BR.po 2003-07-07 11:20:35.000000000 -0700 @@ -5,73 +5,71 @@ # msgid "" msgstr "" -"Project-Id-Version: gawk 3.1.1l\n" -"POT-Creation-Date: 2003-03-19 14:25+0200\n" -"PO-Revision-Date: 2003-02-22 13:25-0300\n" +"Project-Id-Version: gawk 3.1.2g\n" +"Report-Msgid-Bugs-To: arnold@skeeve.com\n" +"POT-Creation-Date: 2003-07-07 11:20-0700\n" +"PO-Revision-Date: 2003-06-26 16:18+0300\n" "Last-Translator: Juan Carlos Castro y Castro \n" "Language-Team: Brazilian Portuguese \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=iso-8859-1\n" "Content-Transfer-Encoding: 8bit\n" -#: array.c:274 array.c:309 array.c:314 eval.c:494 +#: array.c:112 +#, c-format +msgid "attempt to use scalar parameter `%s' as an array" +msgstr "tentativa de usar parâmetro escalar `%s' como vetor" + +#: array.c:113 #, c-format msgid "attempt to use scalar `%s' as array" msgstr "tentativa de usar escalar `%s' como vetor" -#: array.c:338 +#: array.c:151 +#, c-format +msgid "from %s" +msgstr "de %s" + +#: array.c:506 #, c-format msgid "reference to uninitialized element `%s[\"%s\"]'" msgstr "referência a elemento não inicializado `%s[\"%s\"]'" -#: array.c:344 +#: array.c:512 #, c-format msgid "subscript of array `%s' is null string" msgstr "índice do vetor `%s' é uma string nula" -#: array.c:412 array.c:425 array.c:466 +#: array.c:609 #, c-format msgid "delete: index `%s' not in array `%s'" msgstr "delete: índice `%s' não está no vetor `%s'" -#: array.c:432 array.c:515 -#, c-format -msgid "delete: illegal use of variable `%s' as array" -msgstr "delete: uso ilegal da variável `%s' como vetor" - -#: array.c:633 +#: array.c:769 #, c-format msgid "%s: empty (null)\n" msgstr "%s: vazio (nulo)\n" -#: array.c:638 +#: array.c:774 #, c-format msgid "%s: empty (zero)\n" msgstr "%s: vazio (zero)\n" -#: array.c:642 +#: array.c:778 #, c-format msgid "%s: table_size = %d, array_size = %d\n" msgstr "%s: table_size = %d, array_size = %d\n" -#: array.c:671 +#: array.c:807 #, c-format msgid "%s: is parameter\n" msgstr "%s: é parâmetro\n" -#: array.c:676 +#: array.c:812 #, c-format msgid "%s: array_ref to %s\n" msgstr "%s: array_ref para %s\n" -#: array.c:975 -msgid "asort: first argument is not an array" -msgstr "asort: primeiro argumento não é um vetor" - -#: array.c:984 -msgid "asort: second argument is not an array" -msgstr "asort: segundo argumento não é um vetor" - #: awkgram.y:208 #, c-format msgid "%s blocks must have an action part" @@ -91,263 +89,276 @@ msgid "regexp constant `/%s/' looks like a C comment, but is not" msgstr "constante de expr. reg. `/%s/' parece um comentário C, mas não é" -#: awkgram.y:340 +#: awkgram.y:340 awkgram.y:615 msgid "statement may have no effect" msgstr "declaração pode não ter efeito" -#: awkgram.y:431 awkgram.y:451 +#: awkgram.y:435 awkgram.y:455 #, c-format msgid "`%s' used in %s action" msgstr "`%s' usado em ação %s" -#: awkgram.y:444 awkgram.y:447 +#: awkgram.y:448 awkgram.y:451 msgid "`nextfile' is a gawk extension" msgstr "`nextfile' é uma extensão do gawk" -#: awkgram.y:461 +#: awkgram.y:465 msgid "`return' used outside function context" msgstr "`return' usado fora do contexto de função" -#: awkgram.y:500 +#: awkgram.y:504 msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'" msgstr "" "`print' sozinho em regra BEGIN ou END provavelmente deveria ser `print \"\"'" -#: awkgram.y:513 awkgram.y:520 +#: awkgram.y:517 awkgram.y:524 msgid "`delete array' is a gawk extension" msgstr "`delete array' é uma extensão do gawk" -#: awkgram.y:528 awkgram.y:535 +#: awkgram.y:532 awkgram.y:539 msgid "`delete(array)' is a non-portable tawk extension" msgstr "`delete(array)' é uma extensão não-portável do tawk" -#: awkgram.y:578 +#: awkgram.y:583 +#, c-format +msgid "duplicate case values in switch body: %s" +msgstr "valores de case duplicados no corpo do switch: %s" + +#: awkgram.y:593 +msgid "Duplicate `default' detected in switch body" +msgstr "Detectado `default' duplicado no corpo do switch" + +#: awkgram.y:681 msgid "multistage two-way pipelines don't work" msgstr "pipelines bidirecionais de múltiplos estágios não funcionam" -#: awkgram.y:669 +#: awkgram.y:772 msgid "regular expression on right of assignment" msgstr "expressão regular à direita de atribuição" -#: awkgram.y:679 +#: awkgram.y:782 msgid "regular expression on left of `~' or `!~' operator" msgstr "expressão regular à esquerda de operador `~' ou `!~'" -#: awkgram.y:687 +#: awkgram.y:790 msgid "regular expression on right of comparison" msgstr "expressão regular à direita de comparação" -#: awkgram.y:754 +#: awkgram.y:857 msgid "non-redirected `getline' undefined inside END action" msgstr "`getline' não-redirecionado não é definido dentro da ação END" -#: awkgram.y:781 +#: awkgram.y:884 msgid "call of `length' without parentheses is not portable" msgstr "chamada a `length' sem parênteses não é portável" -#: awkgram.y:784 +#: awkgram.y:887 msgid "call of `length' without parentheses is deprecated by POSIX" msgstr "chamada a `length' sem parênteses é obsoleta de acordo com POSIX" -#: awkgram.y:835 +#: awkgram.y:940 +msgid "use of non-array as array" +msgstr "uso de não-vetor como vetor" + +#: awkgram.y:942 msgid "invalid subscript expression" msgstr "expressão de índice inválida" -#: awkgram.y:1020 +#: awkgram.y:1140 msgid "unexpected newline or end of string" msgstr "fim de linha ou de string inesperado" -#: awkgram.y:1115 +#: awkgram.y:1235 msgid "empty program text on command line" msgstr "texto de programa vazio na linha de comando" -#: awkgram.y:1172 +#: awkgram.y:1292 #, c-format msgid "can't open source file `%s' for reading (%s)" msgstr "impossível abrir arquivo-fonte `%s' para leitura (%s)" -#: awkgram.y:1207 +#: awkgram.y:1327 #, c-format msgid "can't read sourcefile `%s' (%s)" msgstr "impossível ler arquivo-fonte `%s' (%s)" -#: awkgram.y:1215 +#: awkgram.y:1335 #, c-format msgid "source file `%s' is empty" msgstr "arquivo-fonte `%s' está vazio" -#: awkgram.y:1417 awkgram.y:1527 awkgram.y:1545 awkgram.y:1895 awkgram.y:1980 +#: awkgram.y:1537 awkgram.y:1647 awkgram.y:1665 awkgram.y:2015 awkgram.y:2100 msgid "source file does not end in newline" msgstr "arquivo-fonte não termina em fim-de-linha" -#: awkgram.y:1481 +#: awkgram.y:1601 msgid "unterminated regexp ends with `\\' at end of file" msgstr "expressão regular inacabada termina com `\\' ao fim do arquivo" -#: awkgram.y:1501 +#: awkgram.y:1621 msgid "unterminated regexp" msgstr "expressão regular inacabada" -#: awkgram.y:1504 +#: awkgram.y:1624 msgid "unterminated regexp at end of file" msgstr "expressão regular inacabada no fim do arquivo" -#: awkgram.y:1571 +#: awkgram.y:1691 msgid "use of `\\ #...' line continuation is not portable" msgstr "uso da continuação de linha `\\ #...' não é portável" -#: awkgram.y:1583 +#: awkgram.y:1703 msgid "backslash not last character on line" msgstr "`\\' não é o último caracter da linha" -#: awkgram.y:1628 +#: awkgram.y:1748 msgid "POSIX does not allow operator `**='" msgstr "POSIX não permite o operador `**='" -#: awkgram.y:1630 +#: awkgram.y:1750 msgid "old awk does not support operator `**='" msgstr "o velho awk não suporta o operador `**='" -#: awkgram.y:1639 +#: awkgram.y:1759 msgid "POSIX does not allow operator `**'" msgstr "POSIX não permite o operador `**'" -#: awkgram.y:1641 +#: awkgram.y:1761 msgid "old awk does not support operator `**'" msgstr "o velho awk não suporta o operador `**'" -#: awkgram.y:1672 +#: awkgram.y:1792 msgid "operator `^=' is not supported in old awk" msgstr "o velho awk não suporta o operador `^='" -#: awkgram.y:1680 +#: awkgram.y:1800 msgid "operator `^' is not supported in old awk" msgstr "o velho awk não suporta o operador `^'" -#: awkgram.y:1764 awkgram.y:1781 +#: awkgram.y:1884 awkgram.y:1901 msgid "unterminated string" msgstr "string inacabada" -#: awkgram.y:1941 +#: awkgram.y:2061 #, c-format msgid "invalid char '%c' in expression" msgstr "caracter inválido '%c' em expressão" -#: awkgram.y:2001 +#: awkgram.y:2121 #, c-format msgid "`%s' is a gawk extension" msgstr "`%s' é uma extensão do gawk" -#: awkgram.y:2004 +#: awkgram.y:2124 #, c-format msgid "`%s' is a Bell Labs extension" msgstr "`%s' é uma extensão da Bell Labs" -#: awkgram.y:2007 +#: awkgram.y:2127 #, c-format msgid "POSIX does not allow `%s'" msgstr "POSIX não permite `%s'" -#: awkgram.y:2011 +#: awkgram.y:2131 #, c-format msgid "`%s' is not supported in old awk" msgstr "`%s' não é suportado no velho awk" -#: awkgram.y:2038 +#: awkgram.y:2158 msgid "`goto' considered harmful!\n" msgstr "`goto' é considerado danoso!\n" -#: awkgram.y:2102 +#: awkgram.y:2220 #, c-format msgid "%d is invalid as number of arguments for %s" msgstr "%d é inválido como número de argumentos para %s" -#: awkgram.y:2121 awkgram.y:2124 +#: awkgram.y:2239 awkgram.y:2242 msgid "match: third argument is a gawk extension" msgstr "match: terceiro argumento é uma extensão do gawk" -#: awkgram.y:2137 +#: awkgram.y:2255 #, c-format msgid "%s: string literal as last arg of substitute has no effect" msgstr "" "%s: string literal como último argumento de substituição não tem efeito" -#: awkgram.y:2140 +#: awkgram.y:2258 #, c-format msgid "%s third parameter is not a changeable object" msgstr "terceiro parâmetro %s não é um objeto modificável" -#: awkgram.y:2167 awkgram.y:2170 +#: awkgram.y:2285 awkgram.y:2288 msgid "close: second argument is a gawk extension" msgstr "close: segundo argumento é uma extensão do gawk" -#: awkgram.y:2180 +#: awkgram.y:2298 msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore" msgstr "uso de dcgettext(_\"...\") é incorreto: remova o `_' precedente" -#: awkgram.y:2195 +#: awkgram.y:2313 msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore" msgstr "uso de dcngettext(_\"...\") é incorreto: remova o `_' precedente" -#: awkgram.y:2266 +#: awkgram.y:2384 #, c-format msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d" msgstr "função `%s': parâmetro #%d, `%s', duplica parâmetro #%d" -#: awkgram.y:2299 +#: awkgram.y:2417 #, c-format msgid "function `%s': parameter `%s' shadows global variable" msgstr "função `%s': parâmetro `%s' encobre variável global" -#: awkgram.y:2411 +#: awkgram.y:2529 #, c-format msgid "could not open `%s' for writing (%s)" msgstr "impossível abrir `%s' para escrita (%s)" -#: awkgram.y:2412 profile.c:93 +#: awkgram.y:2530 profile.c:93 msgid "sending profile to standard error" msgstr "enviando perfil para saída de erros" -#: awkgram.y:2442 +#: awkgram.y:2562 #, c-format msgid "%s: close failed (%s)" msgstr "%s: `close' falhou (%s)" -#: awkgram.y:2566 +#: awkgram.y:2684 msgid "shadow_funcs() called twice!" msgstr "shadow_funcs() chamada duas vezes!" -#: awkgram.y:2593 +#: awkgram.y:2711 msgid "there were shadowed variables." msgstr "houve variáveis encobertas." -#: awkgram.y:2666 +#: awkgram.y:2784 #, c-format msgid "function `%s': can't use function name as parameter name" msgstr "função `%s': não se pode usar o nome da função como nome de parâmetro" -#: awkgram.y:2676 +#: awkgram.y:2794 #, c-format msgid "function name `%s' previously defined" msgstr "nome de função `%s' definido anteriormente" -#: awkgram.y:2827 awkgram.y:2833 +#: awkgram.y:2945 awkgram.y:2951 #, c-format msgid "function `%s' called but never defined" msgstr "função `%s' chamada mas nunca definida" -#: awkgram.y:2836 +#: awkgram.y:2954 #, c-format msgid "function `%s' defined but never called" msgstr "função `%s' definida mas nunca chamada" -#: awkgram.y:2863 +#: awkgram.y:2981 #, c-format msgid "regexp constant for parameter #%d yields boolean value" msgstr "" "constante com expr. regular para parâmetro nº %d retorna valor booleano" -#: awkgram.y:2876 +#: awkgram.y:2994 #, c-format msgid "" "function `%s' called with space between name and `(',\n" @@ -356,192 +367,197 @@ "função `%s' chamada com espaço entre o nome e o `(',\n" "%s" -#: awkgram.y:2878 +#: awkgram.y:2996 msgid "or used as a variable or an array" msgstr "ou usado como uma variável ou vetor" -#: builtin.c:111 +#: builtin.c:137 #, c-format msgid "%s to \"%s\" failed (%s)" msgstr "%s para \"%s\" falhou (%s)" -#: builtin.c:112 +#: builtin.c:138 msgid "standard output" msgstr "saída padrão" -#: builtin.c:113 +#: builtin.c:139 msgid "reason unknown" msgstr "motivo desconhecido" -#: builtin.c:126 +#: builtin.c:152 msgid "exp: received non-numeric argument" msgstr "exp: recebeu argumento não-numérico" -#: builtin.c:132 +#: builtin.c:158 #, c-format msgid "exp: argument %g is out of range" msgstr "exp: argumento %g está fora da faixa" -#: builtin.c:190 +#: builtin.c:216 #, c-format msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing" msgstr "" "fflush: erro ao descarregar: pipe `%s' aberto para leitura, não gravação" -#: builtin.c:193 +#: builtin.c:219 #, c-format msgid "fflush: cannot flush: file `%s' opened for reading, not writing" msgstr "" "fflush: erro ao descarregar: arquivo `%s' aberto para leitura, não gravação" -#: builtin.c:205 +#: builtin.c:231 #, c-format msgid "fflush: `%s' is not an open file, pipe or co-process" msgstr "fflush: `%s' não é um arquivo aberto, pipe ou co-processo" -#: builtin.c:299 +#: builtin.c:325 msgid "index: received non-string first argument" msgstr "index: recebeu primeiro argumento não-string" -#: builtin.c:301 +#: builtin.c:327 msgid "index: received non-string second argument" msgstr "index: recebeu segundo argumento não-string" -#: builtin.c:411 +#: builtin.c:437 msgid "int: received non-numeric argument" msgstr "int: recebeu argumento não-numérico" -#: builtin.c:428 +#: builtin.c:454 msgid "length: received non-string argument" msgstr "length: recebeu argumento não-string" -#: builtin.c:444 +#: builtin.c:470 msgid "log: received non-numeric argument" msgstr "log: recebeu argumento não-numérico" -#: builtin.c:447 +#: builtin.c:473 #, c-format msgid "log: received negative argument %g" msgstr "log: recebeu argumento negativo %g" -#: builtin.c:609 builtin.c:612 +#: builtin.c:635 builtin.c:638 msgid "must use `count$' on all formats or none" msgstr "deve usar `count$' em todos os formatos ou nenhum" -#: builtin.c:714 +#: builtin.c:740 msgid "`$' is not permitted in awk formats" msgstr "`$' não é permitido em formatos awk" -#: builtin.c:720 +#: builtin.c:746 msgid "arg count with `$' must be > 0" msgstr "nº de argumentos com `$' deve ser > 0" -#: builtin.c:722 +#: builtin.c:748 #, c-format msgid "arg count %ld greater than total number of supplied arguments" msgstr "nº de argumentos %ld maior que nº total de argumentos fornecidos" -#: builtin.c:724 +#: builtin.c:750 msgid "`$' not permitted after period in format" msgstr "`$' não é permitido depois de ponto no formato" -#: builtin.c:737 +#: builtin.c:763 msgid "no `$' supplied for positional field width or precision" msgstr "nenhum `$' fornecido para tamanho ou precisão de campo posicional" -#: builtin.c:795 +#: builtin.c:821 msgid "`l' is meaningless in awk formats; ignored" msgstr "`l' não faz sentido em formatos awk; ignorado" -#: builtin.c:799 +#: builtin.c:825 msgid "`l' is not permitted in POSIX awk formats" msgstr "`l' não é permitido em formatos POSIX awk" -#: builtin.c:810 +#: builtin.c:836 msgid "`L' is meaningless in awk formats; ignored" msgstr "`L' não faz sentido em formatos awk; ignorado" -#: builtin.c:814 +#: builtin.c:840 msgid "`L' is not permitted in POSIX awk formats" msgstr "`L' não é permitido em formatos POSIX awk" -#: builtin.c:825 +#: builtin.c:851 msgid "`h' is meaningless in awk formats; ignored" msgstr "`h' não faz sentido em formatos awk; ignorado" -#: builtin.c:829 +#: builtin.c:855 msgid "`h' is not permitted in POSIX awk formats" msgstr "`h' não é permitido em formatos POSIX awk" -#: builtin.c:1078 +#: builtin.c:1055 +#, c-format +msgid "[s]printf: value %g is out of range for `%%%c' format" +msgstr "[s]printf: valor %g fora da faixa para formato `%%%c'" + +#: builtin.c:1108 msgid "not enough arguments to satisfy format string" msgstr "argumentos insuficientes para a string de formato" -#: builtin.c:1080 +#: builtin.c:1110 msgid "^ ran out for this one" msgstr "^ acabou para este aqui" -#: builtin.c:1085 +#: builtin.c:1115 msgid "[s]printf: format specifier does not have control letter" msgstr "[s]printf: declaração de formato não tem letra de controle" -#: builtin.c:1088 +#: builtin.c:1118 msgid "too many arguments supplied for format string" msgstr "excesso de argumentos para a string de formato" -#: builtin.c:1154 builtin.c:1157 +#: builtin.c:1184 builtin.c:1187 msgid "printf: no arguments" msgstr "printf: nenhum argumento" -#: builtin.c:1181 +#: builtin.c:1211 msgid "sqrt: received non-numeric argument" msgstr "sqrt: recebeu argumento não-numérico" -#: builtin.c:1185 +#: builtin.c:1215 #, c-format msgid "sqrt: called with negative argument %g" msgstr "sqrt: chamada com argumento negativo %g" -#: builtin.c:1207 +#: builtin.c:1238 #, c-format msgid "substr: start index %g is invalid, using 1" msgstr "substr: posição inicial %g é inválida, usando 1" -#: builtin.c:1212 +#: builtin.c:1243 #, c-format msgid "substr: non-integer start index %g will be truncated" msgstr "substr: posição inicial %g não-inteira será truncada" -#: builtin.c:1231 -#, c-format -msgid "substr: length %g is <= 0" +#: builtin.c:1262 +#, fuzzy, c-format +msgid "substr: length %g is not >= 1" msgstr "substr: comprimento %g é <= 0" -#: builtin.c:1233 -#, c-format -msgid "substr: length %g is < 0" -msgstr "substr: comprimento %g é < 0" +#: builtin.c:1264 +#, fuzzy, c-format +msgid "substr: length %g is not >= 0" +msgstr "substr: comprimento %g é <= 0" -#: builtin.c:1240 +#: builtin.c:1271 #, c-format msgid "substr: non-integer length %g will be truncated" msgstr "substr: comprimento %g não-inteiro será truncado" -#: builtin.c:1245 +#: builtin.c:1276 #, c-format msgid "substr: length %g too big for string indexing, truncating to %g" msgstr "substr: comprimento %g excessivo para indexação, truncando para %g" -#: builtin.c:1257 +#: builtin.c:1288 msgid "substr: source string is zero length" msgstr "substr: string origem tem comprimento zero" -#: builtin.c:1263 +#: builtin.c:1294 #, c-format msgid "substr: start index %g is past end of string" msgstr "substr: posição inicial %g além do fim da string" -#: builtin.c:1271 +#: builtin.c:1302 #, c-format msgid "" "substr: length %g at start index %g exceeds length of first argument (%lu)" @@ -549,232 +565,238 @@ "substr: comprimento %g a partir da posição %g excede tamanho do 1º argumento " "(%lu)" -#: builtin.c:1306 +#: builtin.c:1337 msgid "strftime: received non-string first argument" msgstr "strftime: recebeu primeiro argumento não-string" -#: builtin.c:1312 +#: builtin.c:1343 msgid "strftime: received empty format string" msgstr "strftime: recebeu string de formato vazia" -#: builtin.c:1321 +#: builtin.c:1352 msgid "strftime: received non-numeric second argument" msgstr "strftime: recebeu segundo argumento não-numérico" -#: builtin.c:1384 +#: builtin.c:1415 msgid "mktime: received non-string argument" msgstr "mktime: recebeu argumento não-string" -#: builtin.c:1429 +#: builtin.c:1460 msgid "system: received non-string argument" msgstr "system: recebeu argumento não-string" -#: builtin.c:1573 +#: builtin.c:1581 eval.c:1883 +#, c-format +msgid "reference to uninitialized field `$%d'" +msgstr "referência a campo não inicializado `$%d'" + +#: builtin.c:1608 msgid "tolower: received non-string argument" msgstr "tolower: recebeu argumento não-string" -#: builtin.c:1622 +#: builtin.c:1657 msgid "toupper: received non-string argument" msgstr "toupper: recebeu argumento não-string" -#: builtin.c:1667 +#: builtin.c:1702 msgid "atan2: received non-numeric first argument" msgstr "atan2: recebeu primeiro argumento não-numérico" -#: builtin.c:1669 +#: builtin.c:1704 msgid "atan2: received non-numeric second argument" msgstr "atan2: recebeu segundo argumento não-numérico" -#: builtin.c:1688 +#: builtin.c:1723 msgid "sin: received non-numeric argument" msgstr "sin: recebeu argumento não-numérico" -#: builtin.c:1704 +#: builtin.c:1739 msgid "cos: received non-numeric argument" msgstr "cos: recebeu argumento não-numérico" -#: builtin.c:1748 +#: builtin.c:1788 msgid "srand: received non-numeric argument" msgstr "srand: recebeu argumento não-numérico" -#: builtin.c:1787 +#: builtin.c:1823 msgid "match: third argument is not an array" msgstr "match: terceiro argumento não é um vetor" -#: builtin.c:2264 -msgid "gensub: 3rd argument of 0 treated as 1" +#: builtin.c:2307 +msgid "gensub: third argument of 0 treated as 1" msgstr "gensub: 3º argumento 0 tratado como 1" -#: builtin.c:2375 builtin.c:2377 +#: builtin.c:2416 builtin.c:2418 msgid "lshift: received non-numeric first argument" msgstr "lshift: recebeu primeiro argumento não-numérico" -#: builtin.c:2379 +#: builtin.c:2420 #, c-format msgid "lshift(%lf, %lf): negative values will give strange results" msgstr "lshift(%lf, %lf): valores negativos darão resultados estranhos" -#: builtin.c:2381 +#: builtin.c:2422 #, c-format msgid "lshift(%lf, %lf): fractional values will be truncated" msgstr "lshift(%lf, %lf): valores fracionários serão truncados" -#: builtin.c:2383 +#: builtin.c:2424 #, c-format msgid "lshift(%lf, %lf): too large shift value will give strange results" msgstr "lshift(%lf, %lf): deslocamento excessivo dará resultados estranhos" -#: builtin.c:2412 builtin.c:2414 +#: builtin.c:2453 builtin.c:2455 msgid "rshift: received non-numeric first argument" msgstr "rshift: recebeu primeiro argumento não-numérico" -#: builtin.c:2416 +#: builtin.c:2457 #, c-format msgid "rshift(%lf, %lf): negative values will give strange results" msgstr "rshift(%lf, %lf): valores negativos darão resultados estranhos" -#: builtin.c:2418 +#: builtin.c:2459 #, c-format msgid "rshift(%lf, %lf): fractional values will be truncated" msgstr "rshift(%lf, %lf): valores fracionários serão truncados" -#: builtin.c:2420 +#: builtin.c:2461 #, c-format msgid "rshift(%lf, %lf): too large shift value will give strange results" msgstr "rshift(%lf, %lf): deslocamento excessivo dará resultados estranhos" -#: builtin.c:2449 builtin.c:2451 +#: builtin.c:2490 builtin.c:2492 msgid "and: received non-numeric first argument" msgstr "and: recebeu primeiro argumento não-numérico" -#: builtin.c:2453 +#: builtin.c:2494 #, c-format msgid "and(%lf, %lf): negative values will give strange results" msgstr "and(%lf, %lf): valores negativos darão resultados estranhos" -#: builtin.c:2455 +#: builtin.c:2496 #, c-format msgid "and(%lf, %lf): fractional values will be truncated" msgstr "and(%lf, %lf): valores fracionários serão truncados" -#: builtin.c:2484 builtin.c:2486 +#: builtin.c:2525 builtin.c:2527 msgid "or: received non-numeric first argument" msgstr "or: recebeu primeiro argumento não-numérico" -#: builtin.c:2488 +#: builtin.c:2529 #, c-format msgid "or(%lf, %lf): negative values will give strange results" msgstr "or(%lf, %lf): valores negativos darão resultados estranhos" -#: builtin.c:2490 +#: builtin.c:2531 #, c-format msgid "or(%lf, %lf): fractional values will be truncated" msgstr "or(%lf, %lf): valores fracionários serão truncados" -#: builtin.c:2519 builtin.c:2521 +#: builtin.c:2560 builtin.c:2562 msgid "xor: received non-numeric first argument" msgstr "xor: recebeu primeiro argumento não-numérico" -#: builtin.c:2523 +#: builtin.c:2564 #, c-format msgid "xor(%lf, %lf): negative values will give strange results" msgstr "xor(%lf, %lf): valores negativos darão resultados estranhos" -#: builtin.c:2525 +#: builtin.c:2566 #, c-format msgid "xor(%lf, %lf): fractional values will be truncated" msgstr "xor(%lf, %lf): valores fracionários serão truncados" -#: builtin.c:2553 +#: builtin.c:2594 msgid "compl: received non-numeric argument" msgstr "compl: recebeu primeiro argumento não-numérico" -#: builtin.c:2555 +#: builtin.c:2596 #, c-format msgid "compl(%lf): negative value will give strange results" msgstr "compl(%lf): valores negativos darão resultados estranhos" -#: builtin.c:2557 +#: builtin.c:2598 #, c-format msgid "compl(%lf): fractional value will be truncated" msgstr "compl(%lf): valores fracionários serão truncados" -#: builtin.c:2728 +#: builtin.c:2771 #, c-format msgid "dcgettext: `%s' is not a valid locale category" msgstr "dcgettext: `%s' não é uma categoria de \"locale\" válida" -#: eval.c:262 +#: eval.c:266 #, c-format msgid "unknown nodetype %d" msgstr "tipo de nodo desconhecido %d" -#: eval.c:310 +#: eval.c:312 msgid "buffer overflow in genflags2str" msgstr "estouro de buffer em genflags2str" -#: eval.c:555 +#: eval.c:647 #, c-format msgid "for loop: array `%s' changed size from %ld to %ld during loop execution" msgstr "" +"loop for: vetor `%s' mudou de tamanho de %ld para %ld durante a execução" -#: eval.c:576 +#: eval.c:668 msgid "`break' outside a loop is not portable" msgstr "`break' fora de um loop não é portável" -#: eval.c:580 +#: eval.c:672 msgid "`break' outside a loop is not allowed" msgstr "`break' fora de um loop não é permitido" -#: eval.c:597 +#: eval.c:689 msgid "`continue' outside a loop is not portable" msgstr "`continue' fora de um loop não é portável" -#: eval.c:601 +#: eval.c:693 msgid "`continue' outside a loop is not allowed" msgstr "`continue' fora de um loop não é permitido" -#: eval.c:635 +#: eval.c:727 msgid "`next' cannot be called from a BEGIN rule" msgstr "`next' não pode ser chamado de uma regra BEGIN" -#: eval.c:637 +#: eval.c:729 msgid "`next' cannot be called from an END rule" msgstr "`next' não pode ser chamado de uma regra END" -#: eval.c:646 +#: eval.c:738 msgid "`nextfile' cannot be called from a BEGIN rule" msgstr "`nextfile' não pode ser chamado de uma regra BEGIN" -#: eval.c:648 +#: eval.c:740 msgid "`nextfile' cannot be called from an END rule" msgstr "`nextfile' não pode ser chamado de uma regra END" -#: eval.c:696 +#: eval.c:785 msgid "statement has no effect" msgstr "declaração não tem efeito" -#: eval.c:731 eval.c:761 eval.c:1733 -#, c-format -msgid "reference to uninitialized variable `%s'" -msgstr "referência a variável não inicializada `%s'" - -#: eval.c:739 eval.c:1721 +#: eval.c:828 eval.c:1726 #, c-format msgid "can't use function name `%s' as variable or array" msgstr "não se pode usar o nome de função `%s' como variável ou vetor" -#: eval.c:746 eval.c:752 +#: eval.c:835 eval.c:841 #, c-format msgid "reference to uninitialized argument `%s'" msgstr "referência a argumento não inicializado `%s'" -#: eval.c:810 eval.c:1728 profile.c:773 +#: eval.c:848 eval.c:907 eval.c:1732 eval.c:1742 profile.c:807 #, c-format msgid "attempt to use array `%s' in a scalar context" msgstr "tentativa de usar vetor `%s' em um contexto escalar" -#: eval.c:910 +#: eval.c:858 eval.c:1752 +#, c-format +msgid "reference to uninitialized variable `%s'" +msgstr "referência a variável não inicializada `%s'" + +#: eval.c:1007 msgid "" "concatenation: side effects in one expression have changed the length of " "another!" @@ -782,54 +804,49 @@ "concatenação: efeitos colaterais em um contexto mudaram o comprimento de " "outro!" -#: eval.c:935 +#: eval.c:1032 msgid "assignment used in conditional context" msgstr "atribuição usada em contexto condicional" -#: eval.c:1026 +#: eval.c:1122 msgid "division by zero attempted" msgstr "tentativa de divisão por zero" -#: eval.c:1041 +#: eval.c:1137 #, c-format msgid "division by zero attempted in `%%'" msgstr "tentativa de divisão por zero em `%%'" -#: eval.c:1056 profile.c:649 +#: eval.c:1152 profile.c:683 #, c-format msgid "illegal type (%s) in tree_eval" msgstr "tipo ilegal (%s) em tree_eval" -#: eval.c:1232 +#: eval.c:1328 msgid "division by zero attempted in `/='" msgstr "tentativa de divisão por zero em `/='" -#: eval.c:1250 +#: eval.c:1346 #, c-format msgid "division by zero attempted in `%%='" msgstr "tentativa de divisão por zero em `%%='" -#: eval.c:1510 -#, c-format -msgid "%s (from %s)" -msgstr "%s (de %s)" - -#: eval.c:1569 +#: eval.c:1586 #, c-format msgid "function `%s' called with more arguments than declared" msgstr "função `%s' chamada com mais argumentos que os declarados" -#: eval.c:1628 +#: eval.c:1633 #, c-format msgid "function `%s' not defined" msgstr "função `%s' não definida" -#: eval.c:1634 +#: eval.c:1639 #, c-format msgid "function %s called\n" msgstr "função %s chamada\n" -#: eval.c:1693 +#: eval.c:1698 msgid "" "\n" "\t# Function Call Stack:\n" @@ -839,46 +856,41 @@ "\t# Pilha de Chamadas de Função:\n" "\n" -#: eval.c:1696 +#: eval.c:1701 msgid "\t# -- main --\n" msgstr "\t# -- main --\n" -#: eval.c:1850 +#: eval.c:1867 msgid "attempt to field reference from non-numeric value" msgstr "tentativa de referência a campo a partir de valor não-numérico" -#: eval.c:1852 +#: eval.c:1869 msgid "attempt to reference from null string" msgstr "tentativa de referência a partir de string nula" -#: eval.c:1858 +#: eval.c:1875 #, c-format msgid "attempt to access field %d" msgstr "tentativa de acessar campo %d" -#: eval.c:1874 -#, c-format -msgid "attempt to use scalar parameter `%s' as an array" -msgstr "tentativa de usar parâmetro escalar `%s' como vetor" - -#: eval.c:1886 eval.c:1893 profile.c:865 +#: eval.c:1896 eval.c:1903 profile.c:900 msgid "assignment is not allowed to result of builtin function" msgstr "atribuição não pode resultar de funções intrínsecas" -#: eval.c:1941 +#: eval.c:1951 msgid "`IGNORECASE' is a gawk extension" msgstr "`IGNORECASE' é uma extensão do gawk" -#: eval.c:1970 +#: eval.c:1980 msgid "`BINMODE' is a gawk extension" msgstr "`BINMODE' é uma extensão do gawk" -#: eval.c:2082 +#: eval.c:2092 #, c-format msgid "bad `%sFMT' specification `%s'" msgstr "especificação `%sFMT' inválida `%s'" -#: eval.c:2160 +#: eval.c:2170 msgid "turning off `--lint' due to assignment to `LINT'" msgstr "desativando `--lint' devido a atribuição a `LINT'" @@ -896,32 +908,32 @@ msgid "extension: library `%s': cannot call function `%s' (%s)\n" msgstr "extension: biblioteca `%s': impossível chamar função `%s' (%s)\n" -#: ext.c:181 +#: ext.c:183 msgid "Operation Not Supported" msgstr "Operação Não Suportada" -#: field.c:321 +#: field.c:315 msgid "NF set to negative value" msgstr "valor negativo atribuído a NF" -#: field.c:819 +#: field.c:808 msgid "split: second argument is not an array" msgstr "split: segundo argumento não é um vetor" -#: field.c:854 +#: field.c:842 msgid "split: null string for third arg is a gawk extension" msgstr "split: string nula para segundo argumento é uma extensão do gawk" -#: field.c:906 +#: field.c:894 msgid "`FIELDWIDTHS' is a gawk extension" msgstr "`FIELDWIDTHS' é uma extensão do gawk" -#: field.c:933 +#: field.c:921 #, c-format msgid "field %d in FIELDWIDTHS, must be > 0" msgstr "campo %d em FIELDWIDTHS deve ser > 0" -#: field.c:1006 +#: field.c:994 msgid "null string for `FS' is a gawk extension" msgstr "string nula para `FS' é uma extensão do gawk" @@ -965,7 +977,7 @@ msgid "%s: invalid option -- %c\n" msgstr "%s: opção inválida -- %c\n" -#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:431 +#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:434 #, c-format msgid "%s: option requires an argument -- %c\n" msgstr "%s: opção requer argumento -- %c\n" @@ -980,469 +992,469 @@ msgid "%s: option `-W %s' doesn't allow an argument\n" msgstr "%s: opção `-W %s' não aceita argumento\n" -#: io.c:257 +#: io.c:305 #, c-format msgid "cannot open file `%s' for reading (%s)" msgstr "impossível abrir arquivo `%s' para leitura (%s)" -#: io.c:344 +#: io.c:392 #, c-format msgid "close of fd %d (`%s') failed (%s)" msgstr "fechamento do descritor %d (`%s') falhou (%s)" -#: io.c:482 +#: io.c:530 #, c-format msgid "invalid tree type %s in redirect()" msgstr "tipo de árvore %s inválido em redirect()" -#: io.c:488 +#: io.c:536 #, c-format msgid "expression in `%s' redirection only has numeric value" msgstr "expressão no redirecionamento `%s' só tem valor numérico" -#: io.c:494 +#: io.c:542 #, c-format msgid "expression for `%s' redirection has null string value" msgstr "expressão para o redirecionamento `%s' tem valor string nulo" -#: io.c:499 +#: io.c:547 #, c-format msgid "filename `%s' for `%s' redirection may be result of logical expression" msgstr "" "nome de arquivo `%s' para redirecionamento `%s' pode ser resultado de " "expressão lógica" -#: io.c:521 +#: io.c:569 #, c-format msgid "unnecessary mixing of `>' and `>>' for file `%.*s'" msgstr "mistura desnecessária de `>' e `>>' para arquivo `%.*s'" -#: io.c:573 +#: io.c:621 #, c-format msgid "can't open pipe `%s' for output (%s)" msgstr "impossível abrir pipe `%s' para saída (%s)" -#: io.c:582 +#: io.c:630 #, c-format msgid "can't open pipe `%s' for input (%s)" msgstr "impossível abrir pipe `%s' para entrada (%s)" -#: io.c:595 +#: io.c:643 #, c-format msgid "can't open two way socket `%s' for input/output (%s)" msgstr "impossível abrir socket bidirecional `%s' para entrada/saída (%s)" -#: io.c:599 +#: io.c:647 #, c-format msgid "can't open two way pipe `%s' for input/output (%s)" msgstr "impossível abrir pipe bidirecional `%s' para entrada/saída (%s)" -#: io.c:675 +#: io.c:723 #, c-format msgid "can't redirect from `%s' (%s)" msgstr "impossível redirecionar de `%s' (%s)" -#: io.c:678 +#: io.c:726 #, c-format msgid "can't redirect to `%s' (%s)" msgstr "impossível redirecionar para `%s' (%s)" -#: io.c:717 +#: io.c:765 msgid "" "reached system limit for open files: starting to multiplex file descriptors" msgstr "" "alcançado limite do sistema para arquivos abertos; começando a multiplexar " "descritores de arquivos" -#: io.c:729 +#: io.c:777 #, c-format msgid "close of `%s' failed (%s)." msgstr "fechamento de `%s' falhou (%s)" -#: io.c:736 +#: io.c:784 msgid "too many pipes or input files open" msgstr "excesso de pipes ou arquivos de entrada abertos" -#: io.c:759 +#: io.c:807 msgid "close: second argument must be `to' or `from'" msgstr "close: segundo argumento deve ser `to' ou `from'" -#: io.c:773 +#: io.c:821 #, c-format msgid "close: `%.*s' is not an open file, pipe or co-process" msgstr "close: `%.*s' não é um arquivo aberto, pipe ou co-processo" -#: io.c:777 +#: io.c:825 msgid "close of redirection that was never opened" msgstr "fechamento de redirecionamento que nunca foi aberto" -#: io.c:804 +#: io.c:862 #, c-format msgid "close: redirection `%s' not opened with `|&', second argument ignored" msgstr "" "close: redirecionamento `%s' não foi aberto com `|&', segundo argumento " "ignorado" -#: io.c:866 +#: io.c:924 #, c-format msgid "failure status (%d) on pipe close of `%s' (%s)" msgstr "status de falha (%d) ao fechar pipe de `%s' (%s)" -#: io.c:869 +#: io.c:927 #, c-format msgid "failure status (%d) on file close of `%s' (%s)" msgstr "status de falha (%d) ao fechar arquivo de `%s' (%s)" -#: io.c:888 +#: io.c:946 #, c-format msgid "no explicit close of socket `%s' provided" msgstr "fechamento explícito do socket `%s' não fornecido" -#: io.c:891 +#: io.c:949 #, c-format msgid "no explicit close of co-process `%s' provided" msgstr "fechamento explícito do co-processo `%s' não fornecido" -#: io.c:894 +#: io.c:952 #, c-format msgid "no explicit close of pipe `%s' provided" msgstr "fechamento explícito do pipe `%s' não fornecido" -#: io.c:897 +#: io.c:955 #, c-format msgid "no explicit close of file `%s' provided" msgstr "fechamento explícito do arquivo `%s' não fornecido" -#: io.c:926 io.c:980 +#: io.c:984 io.c:1038 #, c-format msgid "error writing standard output (%s)" msgstr "erro ao escrever na saída padrão (%s)" -#: io.c:930 io.c:984 +#: io.c:988 io.c:1042 #, c-format msgid "error writing standard error (%s)" msgstr "erro ao escrever na saída padrão de erros (%s)" -#: io.c:938 +#: io.c:996 #, c-format msgid "pipe flush of `%s' failed (%s)." -msgstr "" +msgstr "descarga de pipe de `%s' falhou (%s)." -#: io.c:941 +#: io.c:999 #, c-format msgid "co-process flush of pipe to `%s' failed (%s)." -msgstr "" +msgstr "descarga de co-processo de pipe para `%s' falhou (%s)." -#: io.c:944 +#: io.c:1002 #, c-format msgid "file flush of `%s' failed (%s)." -msgstr "" +msgstr "descarga de arquivo de `%s' falhou (%s)." -#: io.c:1103 +#: io.c:1161 msgid "/inet/raw client not ready yet, sorry" msgstr "infelizmente, o cliente de /inet/raw não está concluído" -#: io.c:1105 io.c:1142 +#: io.c:1163 io.c:1200 msgid "only root may use `/inet/raw'." msgstr "apenas root pode usar `/inet/raw'." -#: io.c:1140 +#: io.c:1198 msgid "/inet/raw server not ready yet, sorry" msgstr "infelizmente, o servidor de /inet/raw não está concluído" -#: io.c:1230 +#: io.c:1288 #, c-format msgid "no (known) protocol supplied in special filename `%s'" msgstr "" "nenhum protocolo (conhecido) fornecido em nome de arquivo especial `%s'" -#: io.c:1248 +#: io.c:1306 #, c-format msgid "special file name `%s' is incomplete" msgstr "nome de arquivo especial `%s' está incompleto" -#: io.c:1260 +#: io.c:1318 #, c-format msgid "local port invalid in `%s'" msgstr "porta local inválida em `%s'" -#: io.c:1272 +#: io.c:1330 msgid "must supply a remote hostname to `/inet'" msgstr "deve ser fornecido um nome de host remoto para `/inet'" -#: io.c:1287 +#: io.c:1345 msgid "must supply a remote port to `/inet'" msgstr "deve ser fornecida uma porta remota para `/inet'" -#: io.c:1293 +#: io.c:1351 #, c-format msgid "remote port invalid in `%s'" msgstr "porta remota inválida em `%s'" -#: io.c:1303 +#: io.c:1361 msgid "TCP/IP communications are not supported" msgstr "comunicação TCP/IP não é suportada" -#: io.c:1312 io.c:1492 +#: io.c:1370 io.c:1551 #, c-format msgid "file `%s' is a directory" msgstr "arquivo `%s' é um diretório" -#: io.c:1381 +#: io.c:1440 #, c-format msgid "use `PROCINFO[\"%s\"]' instead of `%s'" msgstr "use `PROCINFO[\"%s\"]' em vez de `%s'" -#: io.c:1413 +#: io.c:1472 msgid "use `PROCINFO[...]' instead of `/dev/user'" msgstr "use `PROCINFO[...]' em vez de `/dev/user'" -#: io.c:1478 io.c:1652 +#: io.c:1537 io.c:1711 #, c-format msgid "could not open `%s', mode `%s'" msgstr "impossível abrir `%s', modo `%s'" -#: io.c:1703 +#: io.c:1762 #, c-format msgid "close of master pty failed (%s)" msgstr "falha ao fechar pty mestre (%s)" -#: io.c:1705 io.c:1857 io.c:2009 +#: io.c:1764 io.c:1916 io.c:2068 #, c-format msgid "close of stdout in child failed (%s)" msgstr "falha ao fechar stdout em filho (%s)" -#: io.c:1708 +#: io.c:1767 #, c-format msgid "moving slave pty to stdout in child failed (dup: %s)" msgstr "falha ao mover pty escrava para stdout em filho (dup: %s)" -#: io.c:1710 io.c:1862 +#: io.c:1769 io.c:1921 #, c-format msgid "close of stdin in child failed (%s)" msgstr "falha ao fechar stdin em filho (%s)" -#: io.c:1713 +#: io.c:1772 #, c-format msgid "moving slave pty to stdin in child failed (dup: %s)" msgstr "falha ao mover pty escrava para stdin em filho (dup: %s)" -#: io.c:1715 io.c:1734 +#: io.c:1774 io.c:1793 #, c-format msgid "close of slave pty failed (%s)" msgstr "falha ao fechar pty escrava (%s)" -#: io.c:1808 io.c:1860 io.c:1990 io.c:2012 +#: io.c:1867 io.c:1919 io.c:2049 io.c:2071 #, c-format msgid "moving pipe to stdout in child failed (dup: %s)" msgstr "falha ao mover pipe para stdout em processo pai (dup: %s)" -#: io.c:1812 io.c:1865 +#: io.c:1871 io.c:1924 #, c-format msgid "moving pipe to stdin in child failed (dup: %s)" msgstr "falha ao mover pipe para stdin em processo pai (dup: %s)" -#: io.c:1829 io.c:2003 +#: io.c:1888 io.c:2062 msgid "restoring stdout in parent process failed\n" msgstr "falha ao restaurar stdout em processo pai\n" -#: io.c:1834 +#: io.c:1893 msgid "restoring stdin in parent process failed\n" msgstr "falha ao restaurar stdin em processo pai\n" -#: io.c:1868 io.c:2014 io.c:2025 +#: io.c:1927 io.c:2073 io.c:2084 #, c-format msgid "close of pipe failed (%s)" msgstr "falha ao fechar pipe (%s)" -#: io.c:1913 +#: io.c:1972 msgid "`|&' not supported" msgstr "`|&' não suportado" -#: io.c:1980 +#: io.c:2039 #, c-format msgid "cannot open pipe `%s' (%s)" msgstr "impossível abrir pipe `%s' (%s)" -#: io.c:2021 +#: io.c:2080 #, c-format msgid "cannot create child process for `%s' (fork: %s)" msgstr "impossível criar processo filho para `%s' (fork: %s)" -#: io.c:2364 +#: io.c:2423 #, c-format msgid "data file `%s' is empty" msgstr "arquivo de dados `%s' vazio" -#: io.c:2407 io.c:2415 +#: io.c:2466 io.c:2474 msgid "could not allocate more input memory" -msgstr "" +msgstr "impossível alocar mais memória de entrada" -#: io.c:2540 io.c:2782 io.c:3046 +#: io.c:2832 io.c:2895 #, c-format msgid "error reading input file `%s': %s" msgstr "erro ao ler arquivo de entrada `%s': %s" -#: io.c:3281 +#: io.c:3020 msgid "multicharacter value of `RS' is a gawk extension" msgstr "valor de múltiplos caracteres para `RS' é uma extensão do gawk" -#: main.c:322 +#: main.c:324 msgid "`-m[fr]' option irrelevant in gawk" msgstr "opção `-m[fr] é irrelevante no gawk" -#: main.c:324 +#: main.c:326 msgid "-m option usage: `-m[fr] nnn'" msgstr "uso da opção -m: `-m[fr] nnn'" -#: main.c:341 +#: main.c:343 #, c-format msgid "%s: option `-W %s' unrecognized, ignored\n" msgstr "%s: opção `-W %s' não reconhecida, ignorada\n" -#: main.c:378 +#: main.c:380 msgid "empty argument to `--source' ignored" msgstr "argumento vazio para --source ignorado" -#: main.c:448 +#: main.c:451 msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'" msgstr "variável de ambiente `POSIXLY_CORRECT' ativada: ligando `--posix'" -#: main.c:453 +#: main.c:456 msgid "`--posix' overrides `--traditional'" msgstr "`--posix' sobrepõe `--traditional'" -#: main.c:464 +#: main.c:467 msgid "`--posix'/`--traditional' overrides `--non-decimal-data'" msgstr "`--posix'/`--traditional' sobrepõe `--non-decimal-data'" -#: main.c:468 +#: main.c:471 #, c-format msgid "running %s setuid root may be a security problem" msgstr "rodar %s com setuid root pode ser um problema de segurança" -#: main.c:509 +#: main.c:512 #, c-format msgid "can't set binary mode on stdin (%s)" msgstr "impossível ativar modo binário em stdin (%s)" -#: main.c:512 +#: main.c:515 #, c-format msgid "can't set binary mode on stdout (%s)" msgstr "impossível ativar modo binário em stdout (%s)" -#: main.c:514 +#: main.c:517 #, c-format msgid "can't set binary mode on stderr (%s)" msgstr "impossível ativar modo binário em stderr (%s)" -#: main.c:544 +#: main.c:547 msgid "no program text at all!" msgstr "nenhum texto de programa" -#: main.c:612 +#: main.c:620 #, c-format msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n" msgstr "Uso: %s [opções estilo POSIX ou GNU] -f arqprog [--] arquivo ...\n" -#: main.c:614 +#: main.c:622 #, c-format msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n" msgstr "Uso: %s [opções estilo POSIX ou GNU] [--] %cprograma%c arquivo ...\n" -#: main.c:619 +#: main.c:627 msgid "POSIX options:\t\tGNU long options:\n" msgstr "Opções POSIX: \t\tOpções longas GNU:\n" -#: main.c:620 +#: main.c:628 msgid "\t-f progfile\t\t--file=progfile\n" msgstr "\t-f arqprog \t\t--file=arqprog\n" -#: main.c:621 +#: main.c:629 msgid "\t-F fs\t\t\t--field-separator=fs\n" msgstr "\t-F fs\t\t\t--field-separator=fs\n" -#: main.c:622 +#: main.c:630 msgid "\t-v var=val\t\t--assign=var=val\n" msgstr "\t-v var=val\t\t--assign=var=val\n" -#: main.c:623 +#: main.c:631 msgid "\t-m[fr] val\n" msgstr "\t-m[fr] val\n" -#: main.c:624 +#: main.c:632 msgid "\t-W compat\t\t--compat\n" msgstr "\t-W compat\t\t--compat\n" -#: main.c:625 +#: main.c:633 msgid "\t-W copyleft\t\t--copyleft\n" msgstr "\t-W copyleft\t\t--copyleft\n" -#: main.c:626 +#: main.c:634 msgid "\t-W copyright\t\t--copyright\n" msgstr "\t-W copyright\t\t--copyright\n" -#: main.c:627 +#: main.c:635 msgid "\t-W dump-variables[=file]\t--dump-variables[=file]\n" msgstr "\t-W dump-variables[=arq] \t--dump-variables[=arq]\n" -#: main.c:628 +#: main.c:636 msgid "\t-W gen-po\t\t--gen-po\n" msgstr "\t-W gen-po\t\t--gen-po\n" -#: main.c:629 +#: main.c:637 msgid "\t-W help\t\t\t--help\n" msgstr "\t-W help\t\t\t--help\n" -#: main.c:630 +#: main.c:638 msgid "\t-W lint[=fatal]\t\t--lint[=fatal]\n" msgstr "\t-W lint[=fatal]\t\t--lint[=fatal]\n" -#: main.c:631 +#: main.c:639 msgid "\t-W lint-old\t\t--lint-old\n" msgstr "\t-W lint-old\t\t--lint-old\n" -#: main.c:632 +#: main.c:640 msgid "\t-W non-decimal-data\t--non-decimal-data\n" msgstr "\t-W non-decimal-data\t--non-decimal-data\n" -#: main.c:634 +#: main.c:642 msgid "\t-W nostalgia\t\t--nostalgia\n" msgstr "\t-W nostalgia\t\t--nostalgia\n" -#: main.c:637 +#: main.c:645 msgid "\t-W parsedebug\t\t--parsedebug\n" msgstr "\t-W parsedebug\t\t--parsedebug\n" -#: main.c:639 +#: main.c:647 msgid "\t-W profile[=file]\t--profile[=file]\n" msgstr "\t-W profile[=arq] \t--profile[=arq]\n" -#: main.c:640 +#: main.c:648 msgid "\t-W posix\t\t--posix\n" msgstr "\t-W posix\t\t--posix\n" -#: main.c:641 +#: main.c:649 msgid "\t-W re-interval\t\t--re-interval\n" msgstr "\t-W re-interval\t\t--re-interval\n" -#: main.c:642 +#: main.c:650 msgid "\t-W source=program-text\t--source=program-text\n" msgstr "\t-W source=program-text\t--source=program-text\n" -#: main.c:643 +#: main.c:651 msgid "\t-W traditional\t\t--traditional\n" msgstr "\t-W traditional\t\t--traditional\n" -#: main.c:644 +#: main.c:652 msgid "\t-W usage\t\t--usage\n" msgstr "\t-W usage\t\t--usage\n" -#: main.c:645 +#: main.c:653 msgid "\t-W version\t\t--version\n" msgstr "\t-W version\t\t--version\n" -#: main.c:649 +#: main.c:657 msgid "" "\n" "To report bugs, see node `Bugs' in `gawk.info', which is\n" @@ -1454,7 +1466,7 @@ "seção `Reportando Problemas e Bugs' na versão impressa.\n" "\n" -#: main.c:653 +#: main.c:661 msgid "" "gawk is a pattern scanning and processing language.\n" "By default it reads standard input and writes standard output.\n" @@ -1464,7 +1476,7 @@ "Por padrão, o gawk lê a entrada padrão e escreve na saída padrão.\n" "\n" -#: main.c:657 +#: main.c:665 msgid "" "Examples:\n" "\tgawk '{ sum += $1 }; END { print sum }' file\n" @@ -1474,7 +1486,7 @@ "\tgawk '{ soma += $1 }; END { print soma }' arquivo\n" "\tgawk -F: '{ print $1 }' /etc/passwd\n" -#: main.c:669 +#: main.c:682 #, c-format msgid "" "Copyright (C) 1989, 1991-%d Free Software Foundation.\n" @@ -1493,7 +1505,7 @@ "(aoseu critério) qualquer versão posterior.\n" "\n" -#: main.c:677 +#: main.c:690 msgid "" "This program is distributed in the hope that it will be useful,\n" "but WITHOUT ANY WARRANTY; without even the implied warranty of\n" @@ -1505,7 +1517,7 @@ "QUALQUER GARANTIA. Veja a Licença Pública Geral GNU (GNU GPL)\n" "para mais detalhes.\n" -#: main.c:683 +#: main.c:696 msgid "" "You should have received a copy of the GNU General Public License\n" "along with this program; if not, write to the Free Software\n" @@ -1515,11 +1527,11 @@ "junto com este programa; caso contrário, escreva à Free Software\n" "Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n" -#: main.c:713 +#: main.c:730 msgid "-Ft does not set FS to tab in POSIX awk" msgstr "-Ft não faz FS ser tab no awk POSIX" -#: main.c:944 +#: main.c:956 #, c-format msgid "" "%s: `%s' argument to `-v' not in `var=value' form\n" @@ -1528,35 +1540,35 @@ "%s: argumento `%s' para `-v' não está na forma `var=valor'\n" "\n" -#: main.c:964 +#: main.c:976 #, c-format msgid "`%s' is not a legal variable name" msgstr "`%s' não é um nome legal de variável" -#: main.c:967 +#: main.c:979 #, c-format msgid "`%s' is not a variable name, looking for file `%s=%s'" msgstr "`%s' não é um nome de variável, procurando arquivo `%s=%s'" -#: main.c:995 +#: main.c:1012 msgid "floating point exception" msgstr "exceção de ponto flutuante" -#: main.c:1002 +#: main.c:1019 msgid "fatal error: internal error" msgstr "erro fatal: erro interno" -#: main.c:1052 +#: main.c:1069 #, c-format msgid "no pre-opened fd %d" msgstr "nenhum descritor pré-aberto %d" -#: main.c:1057 +#: main.c:1074 #, c-format msgid "could not pre-open /dev/null for fd %d" msgstr "impossível pré-abrir /dev/null para descritor %d" -#: main.c:1080 main.c:1089 +#: main.c:1097 main.c:1106 #, c-format msgid "could not find groups: %s" msgstr "impossível achar grupos: %s" @@ -1577,23 +1589,23 @@ msgid "fatal: " msgstr "fatal: " -#: node.c:59 node.c:66 node.c:75 node.c:89 node.c:116 +#: node.c:58 node.c:65 node.c:74 node.c:88 node.c:115 msgid "can't convert string to float" msgstr "impossível converter string para float" -#: node.c:357 +#: node.c:355 msgid "backslash at end of string" msgstr "barra invertida (\\) no fim da string" -#: node.c:544 +#: node.c:539 msgid "POSIX does not allow `\\x' escapes" msgstr "POSIX não permite escapes do tipo `\\x'" -#: node.c:550 +#: node.c:545 msgid "no hex digits in `\\x' escape sequence" msgstr "nenhum dígito hexa em seqüência de escape `\\x'" -#: node.c:584 +#: node.c:579 #, c-format msgid "escape sequence `\\%c' treated as plain `%c'" msgstr "seqüência de escape `\\%c' tratada como `%c' normal" @@ -1601,111 +1613,118 @@ #: posix/gawkmisc.c:172 #, c-format msgid "%s %s `%s': could not set close-on-exec: (fcntl: %s)" -msgstr "" +msgstr "%s %s `%s': impossível ativar fechar-ao-executar: (fcntl: %s)" #: profile.c:91 #, c-format msgid "could not open `%s' for writing: %s" -msgstr "" +msgstr "impossível abrir `%s' para escrita: %s" -#: profile.c:409 -msgid "internal error: Node_var with null vname" -msgstr "" +#: profile.c:449 +#, c-format +msgid "internal error: %s with null vname" +msgstr "erro interno: %s com vname nulo" -#: profile.c:471 +#: profile.c:512 msgid "# treated internally as `delete'" -msgstr "" +msgstr "# tratado internamente como `delete'" -#: profile.c:545 -msgid "internal error: Node_var_array with null vname" -msgstr "" - -#: profile.c:1127 +#: profile.c:1162 #, c-format msgid "\t# gawk profile, created %s\n" -msgstr "" +msgstr "\t# perfil gawk, criado %s\n" -#: profile.c:1130 +#: profile.c:1165 msgid "" "\t# BEGIN block(s)\n" "\n" msgstr "" +"\t# bloco(s) BEGIN\n" +"\n" -#: profile.c:1140 +#: profile.c:1175 msgid "" "\t# Rule(s)\n" "\n" msgstr "" +"\t# Regra(s)\n" +"\n" -#: profile.c:1146 +#: profile.c:1181 msgid "" "\t# END block(s)\n" "\n" msgstr "" +"\t# bloco(s) END\n" +"\n" -#: profile.c:1166 +#: profile.c:1201 msgid "" "\n" "\t# Functions, listed alphabetically\n" msgstr "" +"\n" +"\t# Funções, listadas alfabeticamente\n" -#: profile.c:1376 +#: profile.c:1413 #, c-format msgid "unexpected type %s in prec_level" -msgstr "" +msgstr "tipo inesperado %s em prec_level" #: re.c:193 #, c-format msgid "regex match failed, not enough memory to match string \"%.*s%s\"" msgstr "" +"busca por exp. reg. falhou, memória insuficiente para testar string \"%.*s%s" +"\"" #: regcomp.c:136 msgid "Success" -msgstr "" +msgstr "Sucesso" #: regcomp.c:139 msgid "No match" -msgstr "" +msgstr "Sem combinação" #: regcomp.c:142 msgid "Invalid regular expression" -msgstr "" +msgstr "Expressão regular inválida" #: regcomp.c:145 msgid "Invalid collation character" -msgstr "" +msgstr "Caracter de combinação inválido" #: regcomp.c:148 msgid "Invalid character class name" -msgstr "" +msgstr "Nome de classe de caracter inválido" #: regcomp.c:151 msgid "Trailing backslash" -msgstr "" +msgstr "contra-barra (\\) finalizando" #: regcomp.c:154 msgid "Invalid back reference" -msgstr "" +msgstr "Referência anterior inválida" #: regcomp.c:157 msgid "Unmatched [ or [^" -msgstr "" +msgstr "[ ou [^ não emparelhado" #: regcomp.c:160 msgid "Unmatched ( or \\(" -msgstr "" +msgstr "( ou \\( não emparelhado" #: regcomp.c:163 msgid "Unmatched \\{" -msgstr "" +msgstr "\\{ não emparelhado" #: regcomp.c:166 msgid "Invalid content of \\{\\}" -msgstr "" +msgstr "Conteúdo inválido de \\{\\}" #: regcomp.c:169 msgid "Invalid range end" -msgstr "" +msgstr "Fim de faixa inválido" #: regcomp.c:172 msgid "Memory exhausted" @@ -1730,3 +1749,18 @@ #: regcomp.c:621 msgid "No previous regular expression" msgstr "Nenhuma expressão regular anterior" + +#~ msgid "substr: length %g is < 0" +#~ msgstr "substr: comprimento %g é < 0" + +#~ msgid "delete: illegal use of variable `%s' as array" +#~ msgstr "delete: uso ilegal da variável `%s' como vetor" + +#~ msgid "asort: first argument is not an array" +#~ msgstr "asort: primeiro argumento não é um vetor" + +#~ msgid "asort: second argument is not an array" +#~ msgstr "asort: segundo argumento não é um vetor" + +#~ msgid "internal error: Node_var_array with null vname" +#~ msgstr "erro interno: Node_var_array com vname nulo" diff -urN gawk-3.1.2/po/quot.sed gawk-3.1.3/po/quot.sed --- gawk-3.1.2/po/quot.sed 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/po/quot.sed 2003-06-16 03:25:34.000000000 -0700 @@ -0,0 +1,6 @@ +s/"\([^"]*\)"/“\1â€/g +s/`\([^`']*\)'/‘\1’/g +s/ '\([^`']*\)' / ‘\1’ /g +s/ '\([^`']*\)'$/ ‘\1’/g +s/^'\([^`']*\)' /‘\1’ /g +s/“â€/""/g diff -urN gawk-3.1.2/po/stamp-po gawk-3.1.3/po/stamp-po --- gawk-3.1.2/po/stamp-po 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/po/stamp-po 2003-07-07 11:20:36.000000000 -0700 @@ -0,0 +1 @@ +timestamp Binary files gawk-3.1.2/po/sv.gmo and gawk-3.1.3/po/sv.gmo differ diff -urN gawk-3.1.2/po/sv.po gawk-3.1.3/po/sv.po --- gawk-3.1.2/po/sv.po 2003-03-19 04:25:12.000000000 -0800 +++ gawk-3.1.3/po/sv.po 2003-07-07 11:20:33.000000000 -0700 @@ -7,7 +7,8 @@ msgid "" msgstr "" "Project-Id-Version: gawk 3.1.1m\n" -"POT-Creation-Date: 2003-03-19 14:25+0200\n" +"Report-Msgid-Bugs-To: arnold@skeeve.com\n" +"POT-Creation-Date: 2003-07-07 11:20-0700\n" "PO-Revision-Date: 2003-02-27 19:54+0100\n" "Last-Translator: Martin Sjögren \n" "Language-Team: Swedish \n" @@ -15,64 +16,61 @@ "Content-Type: text/plain; charset=iso-8859-1\n" "Content-Transfer-Encoding: 8bit\n" -#: array.c:274 array.c:309 array.c:314 eval.c:494 +#: array.c:112 +#, c-format +msgid "attempt to use scalar parameter `%s' as an array" +msgstr "försök att använda skalärparametern \"%s\" som en vektor" + +#: array.c:113 #, c-format msgid "attempt to use scalar `%s' as array" msgstr "försök att använda skalären \"%s\" som vektor" -#: array.c:338 +#: array.c:151 +#, fuzzy, c-format +msgid "from %s" +msgstr "%s (från %s)" + +#: array.c:506 #, c-format msgid "reference to uninitialized element `%s[\"%s\"]'" msgstr "referens till ickeinitierat element \"%s[\"%s\"]\"" -#: array.c:344 +#: array.c:512 #, c-format msgid "subscript of array `%s' is null string" msgstr "index i vektorn \"%s\" är en tom sträng" -#: array.c:412 array.c:425 array.c:466 +#: array.c:609 #, c-format msgid "delete: index `%s' not in array `%s'" msgstr "delete: index \"%s\" finns inte i vektorn \"%s\"" -#: array.c:432 array.c:515 -#, c-format -msgid "delete: illegal use of variable `%s' as array" -msgstr "delete: otillåten användning av variabeln \"%s\" som vektor" - -#: array.c:633 +#: array.c:769 #, c-format msgid "%s: empty (null)\n" msgstr "%s: tom (null)\n" -#: array.c:638 +#: array.c:774 #, c-format msgid "%s: empty (zero)\n" msgstr "%s: tom (noll)\n" -#: array.c:642 +#: array.c:778 #, c-format msgid "%s: table_size = %d, array_size = %d\n" msgstr "%s: tabellstorlek = %d, vektorstorlek = %d\n" -#: array.c:671 +#: array.c:807 #, c-format msgid "%s: is parameter\n" msgstr "%s: är en parameter\n" -#: array.c:676 +#: array.c:812 #, c-format msgid "%s: array_ref to %s\n" msgstr "%s: vektorreferens till %s\n" -#: array.c:975 -msgid "asort: first argument is not an array" -msgstr "asort: första argumentet är inte en vektor" - -#: array.c:984 -msgid "asort: second argument is not an array" -msgstr "asort: andra argumentet är inte en vektor" - #: awkgram.y:208 #, c-format msgid "%s blocks must have an action part" @@ -92,266 +90,279 @@ msgid "regexp constant `/%s/' looks like a C comment, but is not" msgstr "regexp-konstanten \"/%s/\" ser ut som en C-kommentar men är inte det" -#: awkgram.y:340 +#: awkgram.y:340 awkgram.y:615 msgid "statement may have no effect" msgstr "kommandot kanske inte har någon effekt" -#: awkgram.y:431 awkgram.y:451 +#: awkgram.y:435 awkgram.y:455 #, c-format msgid "`%s' used in %s action" msgstr "\"%s\" använd i %s-åtgärden" -#: awkgram.y:444 awkgram.y:447 +#: awkgram.y:448 awkgram.y:451 msgid "`nextfile' is a gawk extension" msgstr "\"nextfile\" är en gawk-utökning" -#: awkgram.y:461 +#: awkgram.y:465 msgid "`return' used outside function context" msgstr "\"return\" använd utanför funktion" -#: awkgram.y:500 +#: awkgram.y:504 msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'" msgstr "" "ensamt \"print\" i BEGIN eller END-regel bör troligen vara 'print \"\"'" -#: awkgram.y:513 awkgram.y:520 +#: awkgram.y:517 awkgram.y:524 msgid "`delete array' is a gawk extension" msgstr "\"delete array\" är en gawk-utökning" -#: awkgram.y:528 awkgram.y:535 +#: awkgram.y:532 awkgram.y:539 msgid "`delete(array)' is a non-portable tawk extension" msgstr "\"delete(array)\" är en icke portabel tawk-utökning" -#: awkgram.y:578 +#: awkgram.y:583 +#, c-format +msgid "duplicate case values in switch body: %s" +msgstr "" + +#: awkgram.y:593 +msgid "Duplicate `default' detected in switch body" +msgstr "" + +#: awkgram.y:681 msgid "multistage two-way pipelines don't work" msgstr "flerstegs dubbelriktade rör fungerar inte" -#: awkgram.y:669 +#: awkgram.y:772 msgid "regular expression on right of assignment" msgstr "reguljärt uttryck i högerledet av en tilldelning" -#: awkgram.y:679 +#: awkgram.y:782 msgid "regular expression on left of `~' or `!~' operator" msgstr "reguljärt uttryck på vänster sida om en \"~\"- eller \"!~\"-operator" -#: awkgram.y:687 +#: awkgram.y:790 msgid "regular expression on right of comparison" msgstr "reguljärt uttryck i högerledet av en jämförelse" -#: awkgram.y:754 +#: awkgram.y:857 msgid "non-redirected `getline' undefined inside END action" msgstr "icke omdirigerad \"getline\" odefinierad inuti END-åtgärd" -#: awkgram.y:781 +#: awkgram.y:884 msgid "call of `length' without parentheses is not portable" msgstr "anrop av \"length\" utan parenteser är inte portabelt" -#: awkgram.y:784 +#: awkgram.y:887 msgid "call of `length' without parentheses is deprecated by POSIX" msgstr "anrop av \"length\" utan parenteser är föråldrat enligt POSIX" -#: awkgram.y:835 +#: awkgram.y:940 +msgid "use of non-array as array" +msgstr "" + +#: awkgram.y:942 msgid "invalid subscript expression" msgstr "ogiltig indexuttryck" -#: awkgram.y:1020 +#: awkgram.y:1140 msgid "unexpected newline or end of string" msgstr "oväntat nyradstecken eller slut på strängen" -#: awkgram.y:1115 +#: awkgram.y:1235 msgid "empty program text on command line" msgstr "tom programtext på kommandoraden" -#: awkgram.y:1172 +#: awkgram.y:1292 #, c-format msgid "can't open source file `%s' for reading (%s)" msgstr "kan inte öppna källfilen \"%s\" för läsning (%s)" -#: awkgram.y:1207 +#: awkgram.y:1327 #, c-format msgid "can't read sourcefile `%s' (%s)" msgstr "kan inte läsa källfilen \"%s\" (%s)" -#: awkgram.y:1215 +#: awkgram.y:1335 #, c-format msgid "source file `%s' is empty" msgstr "källfilen \"%s\" är tom" -#: awkgram.y:1417 awkgram.y:1527 awkgram.y:1545 awkgram.y:1895 awkgram.y:1980 +#: awkgram.y:1537 awkgram.y:1647 awkgram.y:1665 awkgram.y:2015 awkgram.y:2100 msgid "source file does not end in newline" msgstr "källfilen slutar inte med en ny rad" -#: awkgram.y:1481 +#: awkgram.y:1601 msgid "unterminated regexp ends with `\\' at end of file" msgstr "oavslutat reguljärt uttryck slutar med \"\\\" i slutet av filen" -#: awkgram.y:1501 +#: awkgram.y:1621 msgid "unterminated regexp" msgstr "oavslutat reguljärt uttryck" -#: awkgram.y:1504 +#: awkgram.y:1624 msgid "unterminated regexp at end of file" msgstr "oavslutat reguljärt uttryck i slutet av filen" -#: awkgram.y:1571 +#: awkgram.y:1691 msgid "use of `\\ #...' line continuation is not portable" msgstr "Användning av \"\\ #...\" för radfortsättning är inte portabelt" -#: awkgram.y:1583 +#: awkgram.y:1703 msgid "backslash not last character on line" msgstr "sista tecknet på raden är inte ett omvänt snedstreck" -#: awkgram.y:1628 +#: awkgram.y:1748 msgid "POSIX does not allow operator `**='" msgstr "POSIX tillåter inte operatorn \"**=\"" -#: awkgram.y:1630 +#: awkgram.y:1750 msgid "old awk does not support operator `**='" msgstr "gamla awk stöder inte operatorn \"**=\"" -#: awkgram.y:1639 +#: awkgram.y:1759 msgid "POSIX does not allow operator `**'" msgstr "POSIX tillåter inte operatorn \"**\"" -#: awkgram.y:1641 +#: awkgram.y:1761 msgid "old awk does not support operator `**'" msgstr "gamla awk stöder inte operatorn \"**\"" -#: awkgram.y:1672 +#: awkgram.y:1792 msgid "operator `^=' is not supported in old awk" msgstr "operatorn \"^=\" stöds inte i gamla awk" -#: awkgram.y:1680 +#: awkgram.y:1800 msgid "operator `^' is not supported in old awk" msgstr "operatorn \"^\" stöds inte i gamla awk" -#: awkgram.y:1764 awkgram.y:1781 +#: awkgram.y:1884 awkgram.y:1901 msgid "unterminated string" msgstr "oavslutad sträng" -#: awkgram.y:1941 +#: awkgram.y:2061 #, c-format msgid "invalid char '%c' in expression" msgstr "ogiltigt tecken \"%c\" i uttryck" -#: awkgram.y:2001 +#: awkgram.y:2121 #, c-format msgid "`%s' is a gawk extension" msgstr "\"%s\" är en gawk-utökning" -#: awkgram.y:2004 +#: awkgram.y:2124 #, c-format msgid "`%s' is a Bell Labs extension" msgstr "\"%s\" är en Bell Labs-utökning" -#: awkgram.y:2007 +#: awkgram.y:2127 #, c-format msgid "POSIX does not allow `%s'" msgstr "POSIX tillåter inte \"%s\"" -#: awkgram.y:2011 +#: awkgram.y:2131 #, c-format msgid "`%s' is not supported in old awk" msgstr "\"%s\" stöds inte i gamla awk" -#: awkgram.y:2038 +#: awkgram.y:2158 msgid "`goto' considered harmful!\n" msgstr "\"goto\" anses skadlig!\n" -#: awkgram.y:2102 +#: awkgram.y:2220 #, c-format msgid "%d is invalid as number of arguments for %s" msgstr "%d är ett ogiltigt antal argument för %s" -#: awkgram.y:2121 awkgram.y:2124 +#: awkgram.y:2239 awkgram.y:2242 msgid "match: third argument is a gawk extension" msgstr "match: tredje argumentet är en gawk-utökning" -#: awkgram.y:2137 +#: awkgram.y:2255 #, c-format msgid "%s: string literal as last arg of substitute has no effect" msgstr "" "%s: bokstavlig sträng som sista argument till ersättning har ingen effekt" -#: awkgram.y:2140 +#: awkgram.y:2258 #, c-format msgid "%s third parameter is not a changeable object" msgstr "%s: tredje argumentet är inte ett ändringsbart objekt" -#: awkgram.y:2167 awkgram.y:2170 +#: awkgram.y:2285 awkgram.y:2288 msgid "close: second argument is a gawk extension" msgstr "close: andra argumentet är en gawk-utökning" -#: awkgram.y:2180 +#: awkgram.y:2298 msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore" msgstr "" "användandet av dcgettext(_\"...\") är felaktigt: ta bort det inledande " "understrykningstecknet" -#: awkgram.y:2195 +#: awkgram.y:2313 msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore" msgstr "" "användandet av dcngettext(_\"...\") är felaktigt: ta bort det inledande " "understrykningstecknet" -#: awkgram.y:2266 +#: awkgram.y:2384 #, c-format msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d" msgstr "funktionen \"%s\": parameter %d, \"%s\", är samma som parameter %d" -#: awkgram.y:2299 +#: awkgram.y:2417 #, c-format msgid "function `%s': parameter `%s' shadows global variable" msgstr "funktionen \"%s\": parametern \"%s\" överskuggar en global variabel" -#: awkgram.y:2411 +#: awkgram.y:2529 #, c-format msgid "could not open `%s' for writing (%s)" msgstr "kunde inte öpnna \"%s\" för skrivning (%s)" -#: awkgram.y:2412 profile.c:93 +#: awkgram.y:2530 profile.c:93 msgid "sending profile to standard error" msgstr "skickar profilen till standard fel" -#: awkgram.y:2442 +#: awkgram.y:2562 #, c-format msgid "%s: close failed (%s)" msgstr "%s: misslyckades att stänga (%s)" -#: awkgram.y:2566 +#: awkgram.y:2684 msgid "shadow_funcs() called twice!" msgstr "shadow_funcs() anropad två gånger!" -#: awkgram.y:2593 +#: awkgram.y:2711 msgid "there were shadowed variables." msgstr "det fanns överskuggade variabler." -#: awkgram.y:2666 +#: awkgram.y:2784 #, c-format msgid "function `%s': can't use function name as parameter name" msgstr "funktionen \"%s\": kan inte använda funktionsnamn som parameternamn" -#: awkgram.y:2676 +#: awkgram.y:2794 #, c-format msgid "function name `%s' previously defined" msgstr "funktionsnamnet \"%s\" är definierat sedan tidigare" -#: awkgram.y:2827 awkgram.y:2833 +#: awkgram.y:2945 awkgram.y:2951 #, c-format msgid "function `%s' called but never defined" msgstr "funktionen \"%s\" anropad men aldrig definierad" -#: awkgram.y:2836 +#: awkgram.y:2954 #, c-format msgid "function `%s' defined but never called" msgstr "funktionen \"%s\" definierad men aldrig anropad" -#: awkgram.y:2863 +#: awkgram.y:2981 #, c-format msgid "regexp constant for parameter #%d yields boolean value" msgstr "konstant reguljärt uttryck för parameter %d ger ett booleskt värde" -#: awkgram.y:2876 +#: awkgram.y:2994 #, c-format msgid "" "function `%s' called with space between name and `(',\n" @@ -360,192 +371,197 @@ "funktionen \"%s\" anropad med blanktecken mellan namnet och \"(\",\n" "%s" -#: awkgram.y:2878 +#: awkgram.y:2996 msgid "or used as a variable or an array" msgstr "eller använd som variabel eller vektor" -#: builtin.c:111 +#: builtin.c:137 #, c-format msgid "%s to \"%s\" failed (%s)" msgstr "%s till \"%s\" misslyckades (%s)" -#: builtin.c:112 +#: builtin.c:138 msgid "standard output" msgstr "standard ut" -#: builtin.c:113 +#: builtin.c:139 msgid "reason unknown" msgstr "okänd anledning" -#: builtin.c:126 +#: builtin.c:152 msgid "exp: received non-numeric argument" msgstr "exp: fick ett ickenumeriskt argument" -#: builtin.c:132 +#: builtin.c:158 #, c-format msgid "exp: argument %g is out of range" msgstr "exp: argumentet %g är inte inom tillåten gräns" -#: builtin.c:190 +#: builtin.c:216 #, c-format msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing" msgstr "" "fflush: kan inte spola: röret \"%s\" öppnat för läsning, inte skrivning" -#: builtin.c:193 +#: builtin.c:219 #, c-format msgid "fflush: cannot flush: file `%s' opened for reading, not writing" msgstr "" "fflush: kan inte spola: filen \"%s\" öppnad för läsning, inte skrivning" -#: builtin.c:205 +#: builtin.c:231 #, c-format msgid "fflush: `%s' is not an open file, pipe or co-process" msgstr "fflush: \"%s\" är inte en öppen fil, rör eller koprocess" -#: builtin.c:299 +#: builtin.c:325 msgid "index: received non-string first argument" msgstr "index: första argumentet är inte en sträng" -#: builtin.c:301 +#: builtin.c:327 msgid "index: received non-string second argument" msgstr "index: andra argumentet är inte en sträng" -#: builtin.c:411 +#: builtin.c:437 msgid "int: received non-numeric argument" msgstr "int: fick ett ickenumeriskt argument" -#: builtin.c:428 +#: builtin.c:454 msgid "length: received non-string argument" msgstr "length: fick ett argument som inte är en sträng" -#: builtin.c:444 +#: builtin.c:470 msgid "log: received non-numeric argument" msgstr "log: fick ett ickenumeriskt argument" -#: builtin.c:447 +#: builtin.c:473 #, c-format msgid "log: received negative argument %g" msgstr "log: fick ett negativt argumentet %g" -#: builtin.c:609 builtin.c:612 +#: builtin.c:635 builtin.c:638 msgid "must use `count$' on all formats or none" msgstr "måste använda \"count$\" på alla eller inga format" -#: builtin.c:714 +#: builtin.c:740 msgid "`$' is not permitted in awk formats" msgstr "\"$\" tillåts inte i awkformat" -#: builtin.c:720 +#: builtin.c:746 msgid "arg count with `$' must be > 0" msgstr "argumentantalet med \"$\" måste vara > 0" -#: builtin.c:722 +#: builtin.c:748 #, c-format msgid "arg count %ld greater than total number of supplied arguments" msgstr "argumentantalet %ld är större än antalet givna argument" -#: builtin.c:724 +#: builtin.c:750 msgid "`$' not permitted after period in format" msgstr "\"$\" tillåts inte efter en punkt i formatet" -#: builtin.c:737 +#: builtin.c:763 msgid "no `$' supplied for positional field width or precision" msgstr "inget \"$\" bifogat för positionsangiven fältbredd eller precision" -#: builtin.c:795 +#: builtin.c:821 msgid "`l' is meaningless in awk formats; ignored" msgstr "\"l\" är meningslös i awk-format, ignorerad" -#: builtin.c:799 +#: builtin.c:825 msgid "`l' is not permitted in POSIX awk formats" msgstr "\"l\" tillåts inte i POSIX awk-format" -#: builtin.c:810 +#: builtin.c:836 msgid "`L' is meaningless in awk formats; ignored" msgstr "\"L\" är meningslös i awk-format, ignorerad" -#: builtin.c:814 +#: builtin.c:840 msgid "`L' is not permitted in POSIX awk formats" msgstr "\"L\" tillåts inte i POSIX awk-format" -#: builtin.c:825 +#: builtin.c:851 msgid "`h' is meaningless in awk formats; ignored" msgstr "\"h\" är meningslös i awk-format, ignorerad" -#: builtin.c:829 +#: builtin.c:855 msgid "`h' is not permitted in POSIX awk formats" msgstr "\"h\" tillåts inte i POSIX awk-format" -#: builtin.c:1078 +#: builtin.c:1055 +#, c-format +msgid "[s]printf: value %g is out of range for `%%%c' format" +msgstr "" + +#: builtin.c:1108 msgid "not enough arguments to satisfy format string" msgstr "för få argument för formatsträngen" -#: builtin.c:1080 +#: builtin.c:1110 msgid "^ ran out for this one" msgstr "^ tog slut här" -#: builtin.c:1085 +#: builtin.c:1115 msgid "[s]printf: format specifier does not have control letter" msgstr "[s]printf: formatspecifieraren har ingen kommandobokstav" -#: builtin.c:1088 +#: builtin.c:1118 msgid "too many arguments supplied for format string" msgstr "för många argument för formatsträngen" -#: builtin.c:1154 builtin.c:1157 +#: builtin.c:1184 builtin.c:1187 msgid "printf: no arguments" msgstr "printf: inga argument" -#: builtin.c:1181 +#: builtin.c:1211 msgid "sqrt: received non-numeric argument" msgstr "sqrt: fick ickenumeriskt argument" -#: builtin.c:1185 +#: builtin.c:1215 #, c-format msgid "sqrt: called with negative argument %g" msgstr "sqrt: anropad med negativt argument %g" -#: builtin.c:1207 +#: builtin.c:1238 #, c-format msgid "substr: start index %g is invalid, using 1" msgstr "substr: startindex %g är ogiltigt, använder 1" -#: builtin.c:1212 +#: builtin.c:1243 #, c-format msgid "substr: non-integer start index %g will be truncated" msgstr "substr: startindex %g som inte är ett heltal kommer trunkeras" -#: builtin.c:1231 -#, c-format -msgid "substr: length %g is <= 0" +#: builtin.c:1262 +#, fuzzy, c-format +msgid "substr: length %g is not >= 1" msgstr "substr: längden %g är <= 0" -#: builtin.c:1233 -#, c-format -msgid "substr: length %g is < 0" -msgstr "substr: längden %g är < 0" +#: builtin.c:1264 +#, fuzzy, c-format +msgid "substr: length %g is not >= 0" +msgstr "substr: längden %g är <= 0" -#: builtin.c:1240 +#: builtin.c:1271 #, c-format msgid "substr: non-integer length %g will be truncated" msgstr "substr: längden %g som inte är ett heltal kommer trunkeras" -#: builtin.c:1245 +#: builtin.c:1276 #, c-format msgid "substr: length %g too big for string indexing, truncating to %g" msgstr "substr: längden %g är för stor för strängindexering, trunkeras till %g" -#: builtin.c:1257 +#: builtin.c:1288 msgid "substr: source string is zero length" msgstr "substr: källsträngen är tom" -#: builtin.c:1263 +#: builtin.c:1294 #, c-format msgid "substr: start index %g is past end of string" msgstr "substr: startindex %g är bortom strängens slut" -#: builtin.c:1271 +#: builtin.c:1302 #, c-format msgid "" "substr: length %g at start index %g exceeds length of first argument (%lu)" @@ -553,288 +569,288 @@ "substr: längden %g vid startindex %g överskrider det första argumentets " "längd (%lu)" -#: builtin.c:1306 +#: builtin.c:1337 msgid "strftime: received non-string first argument" msgstr "strftime: fick ett första argument som inte är en sträng" -#: builtin.c:1312 +#: builtin.c:1343 msgid "strftime: received empty format string" msgstr "strftime: fick en tom formatsträng" -#: builtin.c:1321 +#: builtin.c:1352 msgid "strftime: received non-numeric second argument" msgstr "strftime: fick ett ickenumeriskt andra argument" -#: builtin.c:1384 +#: builtin.c:1415 msgid "mktime: received non-string argument" msgstr "mktime: fick ett argument som inte är en sträng" -#: builtin.c:1429 +#: builtin.c:1460 msgid "system: received non-string argument" msgstr "system: fick ett argument som inte är en sträng" -#: builtin.c:1573 +#: builtin.c:1581 eval.c:1883 +#, fuzzy, c-format +msgid "reference to uninitialized field `$%d'" +msgstr "referens till icke initierad variabel \"%s\"" + +#: builtin.c:1608 msgid "tolower: received non-string argument" msgstr "tolower: fick ett argument som inte är en sträng" -#: builtin.c:1622 +#: builtin.c:1657 msgid "toupper: received non-string argument" msgstr "toupper: fick ett argument som inte är en sträng" -#: builtin.c:1667 +#: builtin.c:1702 msgid "atan2: received non-numeric first argument" msgstr "atan2: fick ett ickenumeriskt första argument" -#: builtin.c:1669 +#: builtin.c:1704 msgid "atan2: received non-numeric second argument" msgstr "atan2: fick ett ickenumeriskt andra argument" -#: builtin.c:1688 +#: builtin.c:1723 msgid "sin: received non-numeric argument" msgstr "sin: fick ett ickenumeriskt argument" -#: builtin.c:1704 +#: builtin.c:1739 msgid "cos: received non-numeric argument" msgstr "cos: fick ett ickenumeriskt argument" -#: builtin.c:1748 +#: builtin.c:1788 msgid "srand: received non-numeric argument" msgstr "srand: fick ett ickenumeriskt argument" -#: builtin.c:1787 +#: builtin.c:1823 msgid "match: third argument is not an array" msgstr "match: tredje argumentet är inte en vektor" -#: builtin.c:2264 -msgid "gensub: 3rd argument of 0 treated as 1" +#: builtin.c:2307 +msgid "gensub: third argument of 0 treated as 1" msgstr "gensub: Nollan i tredje argumentet behandlad som en etta" -#: builtin.c:2375 builtin.c:2377 +#: builtin.c:2416 builtin.c:2418 msgid "lshift: received non-numeric first argument" msgstr "lshift: fick ett ickenumeriskt första argument" -#: builtin.c:2379 +#: builtin.c:2420 #, c-format msgid "lshift(%lf, %lf): negative values will give strange results" msgstr "lshift(%lf, %lf): negativa värden kommer ge konstiga resultat" -#: builtin.c:2381 +#: builtin.c:2422 #, c-format msgid "lshift(%lf, %lf): fractional values will be truncated" msgstr "lshift(%lf, %lf): flyttalsvärden kommer trunkeras" -#: builtin.c:2383 +#: builtin.c:2424 #, c-format msgid "lshift(%lf, %lf): too large shift value will give strange results" msgstr "lshift(%lf, %lf): för stora skiftvärden kommer ge konstiga resultat" -#: builtin.c:2412 builtin.c:2414 +#: builtin.c:2453 builtin.c:2455 msgid "rshift: received non-numeric first argument" msgstr "rshift: fick ett ickenumeriskt första argument" -#: builtin.c:2416 +#: builtin.c:2457 #, c-format msgid "rshift(%lf, %lf): negative values will give strange results" msgstr "rshift(%lf, %lf): negativa värden kommer ge konstiga resultat" -#: builtin.c:2418 +#: builtin.c:2459 #, c-format msgid "rshift(%lf, %lf): fractional values will be truncated" msgstr "rshift(%lf, %lf): flyttalsvärden kommer trunkeras" -#: builtin.c:2420 +#: builtin.c:2461 #, c-format msgid "rshift(%lf, %lf): too large shift value will give strange results" msgstr "rshift(%lf, %lf): för stora skiftvärden kommer ge konstiga resultat" -#: builtin.c:2449 builtin.c:2451 +#: builtin.c:2490 builtin.c:2492 msgid "and: received non-numeric first argument" msgstr "and: fick ett ickenumeriskt första argument" -#: builtin.c:2453 +#: builtin.c:2494 #, c-format msgid "and(%lf, %lf): negative values will give strange results" msgstr "and(%lf, %lf): negativa värden kommer ge konstiga resultat" -#: builtin.c:2455 +#: builtin.c:2496 #, c-format msgid "and(%lf, %lf): fractional values will be truncated" msgstr "and(%lf, %lf): flyttalsvärden kommer trunkeras" -#: builtin.c:2484 builtin.c:2486 +#: builtin.c:2525 builtin.c:2527 msgid "or: received non-numeric first argument" msgstr "or: fick ett ickenumeriskt första argument" -#: builtin.c:2488 +#: builtin.c:2529 #, c-format msgid "or(%lf, %lf): negative values will give strange results" msgstr "or(%lf, %lf): negativa värden kommer ge konstiga resultat" -#: builtin.c:2490 +#: builtin.c:2531 #, c-format msgid "or(%lf, %lf): fractional values will be truncated" msgstr "or(%lf, %lf): flyttalsvärden kommer trunkeras" -#: builtin.c:2519 builtin.c:2521 +#: builtin.c:2560 builtin.c:2562 msgid "xor: received non-numeric first argument" msgstr "xor: fick ett ickenumeriskt första argument" -#: builtin.c:2523 +#: builtin.c:2564 #, c-format msgid "xor(%lf, %lf): negative values will give strange results" msgstr "xor(%lf, %lf): negativa värden kommer ge konstiga resultat" -#: builtin.c:2525 +#: builtin.c:2566 #, c-format msgid "xor(%lf, %lf): fractional values will be truncated" msgstr "xor(%lf, %lf): flyttalsvärden kommer trunkeras" -#: builtin.c:2553 +#: builtin.c:2594 msgid "compl: received non-numeric argument" msgstr "compl: fick ett ickenumeriskt argument" -#: builtin.c:2555 +#: builtin.c:2596 #, c-format msgid "compl(%lf): negative value will give strange results" msgstr "compl(%lf): negativa värden kommer ge konstiga resultat" -#: builtin.c:2557 +#: builtin.c:2598 #, c-format msgid "compl(%lf): fractional value will be truncated" msgstr "compl(%lf): flyttalsvärden kommer trunkeras" -#: builtin.c:2728 +#: builtin.c:2771 #, c-format msgid "dcgettext: `%s' is not a valid locale category" msgstr "dcgettext: \"%s\" är inte en giltig lokalkategori" -#: eval.c:262 +#: eval.c:266 #, c-format msgid "unknown nodetype %d" msgstr "okänd nodtyp %d" -#: eval.c:310 +#: eval.c:312 msgid "buffer overflow in genflags2str" msgstr "buffertöverflöd i genflags2str" -#: eval.c:555 +#: eval.c:647 #, c-format msgid "for loop: array `%s' changed size from %ld to %ld during loop execution" msgstr "" "forslinga: vektorn \"%s\" ändrade storlek från %ld till %ld under " "slingexekvering" -#: eval.c:576 +#: eval.c:668 msgid "`break' outside a loop is not portable" msgstr "\"break\" utanför en slinga är inte portabelt" -#: eval.c:580 +#: eval.c:672 msgid "`break' outside a loop is not allowed" msgstr "\"break\" utanför en slinga är inte tillåtet" -#: eval.c:597 +#: eval.c:689 msgid "`continue' outside a loop is not portable" msgstr "\"continue\" utanför en slinga är inte portabelt" -#: eval.c:601 +#: eval.c:693 msgid "`continue' outside a loop is not allowed" msgstr "\"continue\" utanför en slinga är inte tillåtet" -#: eval.c:635 +#: eval.c:727 msgid "`next' cannot be called from a BEGIN rule" msgstr "\"next\" kan inte anropas från en BEGIN-regel" -#: eval.c:637 +#: eval.c:729 msgid "`next' cannot be called from an END rule" msgstr "\"next\" kan inte anropas från en END-regel" -#: eval.c:646 +#: eval.c:738 msgid "`nextfile' cannot be called from a BEGIN rule" msgstr "\"nextfile\" kan inte anropas från en BEGIN-regel" -#: eval.c:648 +#: eval.c:740 msgid "`nextfile' cannot be called from an END rule" msgstr "\"nextfile\" kan inte anropas från en END-regel" -#: eval.c:696 +#: eval.c:785 msgid "statement has no effect" msgstr "kommandot har ingen effekt" -#: eval.c:731 eval.c:761 eval.c:1733 -#, c-format -msgid "reference to uninitialized variable `%s'" -msgstr "referens till icke initierad variabel \"%s\"" - -#: eval.c:739 eval.c:1721 +#: eval.c:828 eval.c:1726 #, c-format msgid "can't use function name `%s' as variable or array" msgstr "kan inte använda funktionsnamnet \"%s\" som variabel eller vektor" -#: eval.c:746 eval.c:752 +#: eval.c:835 eval.c:841 #, c-format msgid "reference to uninitialized argument `%s'" msgstr "referens till icke initierat argument \"%s\"" -#: eval.c:810 eval.c:1728 profile.c:773 +#: eval.c:848 eval.c:907 eval.c:1732 eval.c:1742 profile.c:807 #, c-format msgid "attempt to use array `%s' in a scalar context" msgstr "försök att använda vektorn \"%s\" i skalärsammanhang" -#: eval.c:910 +#: eval.c:858 eval.c:1752 +#, c-format +msgid "reference to uninitialized variable `%s'" +msgstr "referens till icke initierad variabel \"%s\"" + +#: eval.c:1007 msgid "" "concatenation: side effects in one expression have changed the length of " "another!" msgstr "" "concatenation: sidoeffekter i ett uttryck har ändrat längden av ett annat!" -#: eval.c:935 +#: eval.c:1032 msgid "assignment used in conditional context" msgstr "tilldelning använt i jämförelsesammanhang" -#: eval.c:1026 +#: eval.c:1122 msgid "division by zero attempted" msgstr "försökte dividera med noll" -#: eval.c:1041 +#: eval.c:1137 #, c-format msgid "division by zero attempted in `%%'" msgstr "försökte dividera med noll i \"%%\"" -#: eval.c:1056 profile.c:649 +#: eval.c:1152 profile.c:683 #, c-format msgid "illegal type (%s) in tree_eval" msgstr "otillåten typ (%s) i tree_eval" -#: eval.c:1232 +#: eval.c:1328 msgid "division by zero attempted in `/='" msgstr "försökte dividera med noll i \"/=\"" -#: eval.c:1250 +#: eval.c:1346 #, c-format msgid "division by zero attempted in `%%='" msgstr "försökte dividera med noll i \"%%=\"" -#: eval.c:1510 -#, c-format -msgid "%s (from %s)" -msgstr "%s (från %s)" - -#: eval.c:1569 +#: eval.c:1586 #, c-format msgid "function `%s' called with more arguments than declared" msgstr "funktionen \"%s\" anropad med fler argument än vad som deklarerats" -#: eval.c:1628 +#: eval.c:1633 #, c-format msgid "function `%s' not defined" msgstr "funktionen \"%s\" är inte definierad" -#: eval.c:1634 +#: eval.c:1639 #, c-format msgid "function %s called\n" msgstr "funktionen %s anropad\n" -#: eval.c:1693 +#: eval.c:1698 msgid "" "\n" "\t# Function Call Stack:\n" @@ -844,46 +860,41 @@ "\t# Funktionsanropsstack:\n" "\n" -#: eval.c:1696 +#: eval.c:1701 msgid "\t# -- main --\n" msgstr "\t# -- main --\n" -#: eval.c:1850 +#: eval.c:1867 msgid "attempt to field reference from non-numeric value" msgstr "försök att fältreferera från ickenumeriskt värde" -#: eval.c:1852 +#: eval.c:1869 msgid "attempt to reference from null string" msgstr "försök att referera från tom sträng" -#: eval.c:1858 +#: eval.c:1875 #, c-format msgid "attempt to access field %d" msgstr "försök att komma åt fält nummer %d" -#: eval.c:1874 -#, c-format -msgid "attempt to use scalar parameter `%s' as an array" -msgstr "försök att använda skalärparametern \"%s\" som en vektor" - -#: eval.c:1886 eval.c:1893 profile.c:865 +#: eval.c:1896 eval.c:1903 profile.c:900 msgid "assignment is not allowed to result of builtin function" msgstr "det är inte tillåtet att tilldela resultatet från en inbyggd funktion" -#: eval.c:1941 +#: eval.c:1951 msgid "`IGNORECASE' is a gawk extension" msgstr "\"IGNORECASE\" är en gawk-utökning" -#: eval.c:1970 +#: eval.c:1980 msgid "`BINMODE' is a gawk extension" msgstr "\"BINMODE\" är en gawk-utökning" -#: eval.c:2082 +#: eval.c:2092 #, c-format msgid "bad `%sFMT' specification `%s'" msgstr "felaktig \"%sFMT\"-specifikation \"%s\"" -#: eval.c:2160 +#: eval.c:2170 msgid "turning off `--lint' due to assignment to `LINT'" msgstr "slår av \"--lint\" på grund av en tilldelning till \"LINT\"" @@ -901,32 +912,32 @@ msgid "extension: library `%s': cannot call function `%s' (%s)\n" msgstr "extension: bibliotek \"%s\": kan inte anropa funktionen \"%s\" (%s)\n" -#: ext.c:181 +#: ext.c:183 msgid "Operation Not Supported" msgstr "Operationen stöds inte" -#: field.c:321 +#: field.c:315 msgid "NF set to negative value" msgstr "NF satt till ett negativt värde" -#: field.c:819 +#: field.c:808 msgid "split: second argument is not an array" msgstr "split: andra argumentet är inte en vektor" -#: field.c:854 +#: field.c:842 msgid "split: null string for third arg is a gawk extension" msgstr "split: tom sträng som tredje argument är en gawk-utökning" -#: field.c:906 +#: field.c:894 msgid "`FIELDWIDTHS' is a gawk extension" msgstr "\"FIELDWIDTHS\" är en gawk-utökning" -#: field.c:933 +#: field.c:921 #, c-format msgid "field %d in FIELDWIDTHS, must be > 0" msgstr "fält %d i FIELDWIDTHS måste vara > 0" -#: field.c:1006 +#: field.c:994 msgid "null string for `FS' is a gawk extension" msgstr "tom sträng som \"FS\" är en gawk-utökning" @@ -970,7 +981,7 @@ msgid "%s: invalid option -- %c\n" msgstr "%s: ogiltig flagga -- %c\n" -#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:431 +#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:434 #, c-format msgid "%s: option requires an argument -- %c\n" msgstr "%s: flaggan kräver ett argument -- %c\n" @@ -985,469 +996,469 @@ msgid "%s: option `-W %s' doesn't allow an argument\n" msgstr "%s: flaggan \"-W %s\" tillåter inte något argument\n" -#: io.c:257 +#: io.c:305 #, c-format msgid "cannot open file `%s' for reading (%s)" msgstr "kan inte öppna filen \"%s\" för läsning (%s)" -#: io.c:344 +#: io.c:392 #, c-format msgid "close of fd %d (`%s') failed (%s)" msgstr "stängning av fd %d (\"%s\") misslyckades (%s)" -#: io.c:482 +#: io.c:530 #, c-format msgid "invalid tree type %s in redirect()" msgstr "ogiltig trädtyp %s i redirect()" -#: io.c:488 +#: io.c:536 #, c-format msgid "expression in `%s' redirection only has numeric value" msgstr "uttrycket i \"%s\"-omdirigering har bara numeriskt värde" -#: io.c:494 +#: io.c:542 #, c-format msgid "expression for `%s' redirection has null string value" msgstr "uttrycket för \"%s\"-omdirigering har en tom sträng som värde" -#: io.c:499 +#: io.c:547 #, c-format msgid "filename `%s' for `%s' redirection may be result of logical expression" msgstr "" "filnamnet \"%s\" för \"%s\"-omdirigering kan vara resultatet av ett logiskt " "uttryck" -#: io.c:521 +#: io.c:569 #, c-format msgid "unnecessary mixing of `>' and `>>' for file `%.*s'" msgstr "onödig blandning av \">\" och \">>\" för filen \"%.*s\"" -#: io.c:573 +#: io.c:621 #, c-format msgid "can't open pipe `%s' for output (%s)" msgstr "kan inte öppna röret \"%s\" för utmatning (%s)" -#: io.c:582 +#: io.c:630 #, c-format msgid "can't open pipe `%s' for input (%s)" msgstr "kan inte öppna röret \"%s\" för inmatning (%s)" -#: io.c:595 +#: io.c:643 #, c-format msgid "can't open two way socket `%s' for input/output (%s)" msgstr "kan inte öppna tvåvägsuttaget \"%s\" för in-/utmatning (%s)" -#: io.c:599 +#: io.c:647 #, c-format msgid "can't open two way pipe `%s' for input/output (%s)" msgstr "kan inte öppna tvåvägsröret \"%s\" för in-/utmatning (%s)" -#: io.c:675 +#: io.c:723 #, c-format msgid "can't redirect from `%s' (%s)" msgstr "kan inte dirigera om från \"%s\" (%s)" -#: io.c:678 +#: io.c:726 #, c-format msgid "can't redirect to `%s' (%s)" msgstr "kan inte dirigera om till \"%s\" (%s)" -#: io.c:717 +#: io.c:765 msgid "" "reached system limit for open files: starting to multiplex file descriptors" msgstr "" "nådde systembegränsningen för öppna filer: börjar multiplexa fildeskriptorer" -#: io.c:729 +#: io.c:777 #, c-format msgid "close of `%s' failed (%s)." msgstr "stängning av \"%s\" misslyckades (%s)" -#: io.c:736 +#: io.c:784 msgid "too many pipes or input files open" msgstr "för många rör eller indatafiler öppna" -#: io.c:759 +#: io.c:807 msgid "close: second argument must be `to' or `from'" msgstr "close: andra argumentet måste vara \"to\" eller \"from\"" -#: io.c:773 +#: io.c:821 #, c-format msgid "close: `%.*s' is not an open file, pipe or co-process" msgstr "close: \"%.*s\" är inte en öppen fil, rör eller koprocess" -#: io.c:777 +#: io.c:825 msgid "close of redirection that was never opened" msgstr "stängning av omdirigering som aldrig öppnades" -#: io.c:804 +#: io.c:862 #, c-format msgid "close: redirection `%s' not opened with `|&', second argument ignored" msgstr "" "close: omdirigeringen \"%s\" öppnades inte med \"|&\", andra argumentet " "ignorerat" -#: io.c:866 +#: io.c:924 #, c-format msgid "failure status (%d) on pipe close of `%s' (%s)" msgstr "felstatus (%d) från rörstängning av \"%s\" (%s)" -#: io.c:869 +#: io.c:927 #, c-format msgid "failure status (%d) on file close of `%s' (%s)" msgstr "felstatus (%d) från filstängning av \"%s\" (%s)" -#: io.c:888 +#: io.c:946 #, c-format msgid "no explicit close of socket `%s' provided" msgstr "ingen explicit stängning av uttaget \"%s\" tillhandahållen" -#: io.c:891 +#: io.c:949 #, c-format msgid "no explicit close of co-process `%s' provided" msgstr "ingen explicit stängning av koprocessen \"%s\" tillhandahållen" -#: io.c:894 +#: io.c:952 #, c-format msgid "no explicit close of pipe `%s' provided" msgstr "ingen explicit stängning av röret \"%s\" tillhandahållen" -#: io.c:897 +#: io.c:955 #, c-format msgid "no explicit close of file `%s' provided" msgstr "ingen explicit stängning av filen \"%s\" tillhandahållen" -#: io.c:926 io.c:980 +#: io.c:984 io.c:1038 #, c-format msgid "error writing standard output (%s)" msgstr "fel vid skrivning till standard ut (%s)" -#: io.c:930 io.c:984 +#: io.c:988 io.c:1042 #, c-format msgid "error writing standard error (%s)" msgstr "fel vid skrivning till standard fel (%s)" -#: io.c:938 +#: io.c:996 #, c-format msgid "pipe flush of `%s' failed (%s)." msgstr "rörspolning av \"%s\" misslyckades (%s)" -#: io.c:941 +#: io.c:999 #, c-format msgid "co-process flush of pipe to `%s' failed (%s)." msgstr "koprocesspolning av röret till \"%s\" misslyckades (%s)" -#: io.c:944 +#: io.c:1002 #, c-format msgid "file flush of `%s' failed (%s)." msgstr "filspolning av \"%s\" misslyckades (%s)" -#: io.c:1103 +#: io.c:1161 msgid "/inet/raw client not ready yet, sorry" msgstr "/inet/raw-klient är tyvärr inte klar än" -#: io.c:1105 io.c:1142 +#: io.c:1163 io.c:1200 msgid "only root may use `/inet/raw'." msgstr "bara root kan använda \"/inet/raw\"." -#: io.c:1140 +#: io.c:1198 msgid "/inet/raw server not ready yet, sorry" msgstr "/inet/raw-server inte redo än, ledsen" -#: io.c:1230 +#: io.c:1288 #, c-format msgid "no (known) protocol supplied in special filename `%s'" msgstr "" "inget (känt) protokoll tillhandahållet i det speciella filnamnet \"%s\"" -#: io.c:1248 +#: io.c:1306 #, c-format msgid "special file name `%s' is incomplete" msgstr "speciellt filnamn \"%s\" är ofullständigt" -#: io.c:1260 +#: io.c:1318 #, c-format msgid "local port invalid in `%s'" msgstr "lokal port ogiltig i \"%s\"" -#: io.c:1272 +#: io.c:1330 msgid "must supply a remote hostname to `/inet'" msgstr "måste tillhandahålla ett fjärrdatornamn till \"/inet\"" -#: io.c:1287 +#: io.c:1345 msgid "must supply a remote port to `/inet'" msgstr "måste tillhandahålla en fjärrport till \"/inet\"" -#: io.c:1293 +#: io.c:1351 #, c-format msgid "remote port invalid in `%s'" msgstr "fjärrporten ogiltig i \"%s\"" -#: io.c:1303 +#: io.c:1361 msgid "TCP/IP communications are not supported" msgstr "TCP/IP-kommunikation stöds inte" -#: io.c:1312 io.c:1492 +#: io.c:1370 io.c:1551 #, c-format msgid "file `%s' is a directory" msgstr "filen \"%s\" är en katalog" -#: io.c:1381 +#: io.c:1440 #, c-format msgid "use `PROCINFO[\"%s\"]' instead of `%s'" msgstr "använd \"PROCINFO[\"%s\"]\" istället för \"%s\"" -#: io.c:1413 +#: io.c:1472 msgid "use `PROCINFO[...]' instead of `/dev/user'" msgstr "använd \"PROCINFO[...]\" istället för \"dev/user\"" -#: io.c:1478 io.c:1652 +#: io.c:1537 io.c:1711 #, c-format msgid "could not open `%s', mode `%s'" msgstr "kunde inte öppna \"%s\", läge \"%s\"" -#: io.c:1703 +#: io.c:1762 #, c-format msgid "close of master pty failed (%s)" msgstr "stängning av huvudpty misslyckades (%s)" -#: io.c:1705 io.c:1857 io.c:2009 +#: io.c:1764 io.c:1916 io.c:2068 #, c-format msgid "close of stdout in child failed (%s)" msgstr "stängning av standard ut i barnet misslyckades (%s)" -#: io.c:1708 +#: io.c:1767 #, c-format msgid "moving slave pty to stdout in child failed (dup: %s)" msgstr "flyttandet av slavpty till standard ut i barnet misslyckades (dup: %s)" -#: io.c:1710 io.c:1862 +#: io.c:1769 io.c:1921 #, c-format msgid "close of stdin in child failed (%s)" msgstr "stängning av standard in i barnet misslyckades (%s)" -#: io.c:1713 +#: io.c:1772 #, c-format msgid "moving slave pty to stdin in child failed (dup: %s)" msgstr "flyttandet av slavpty till standard in i barnet misslyckades (dup: %s)" -#: io.c:1715 io.c:1734 +#: io.c:1774 io.c:1793 #, c-format msgid "close of slave pty failed (%s)" msgstr "stängning av slavpty misslyckades (%s)" -#: io.c:1808 io.c:1860 io.c:1990 io.c:2012 +#: io.c:1867 io.c:1919 io.c:2049 io.c:2071 #, c-format msgid "moving pipe to stdout in child failed (dup: %s)" msgstr "flyttande av rör till standard ut i barnet misslyckades (dup: %s)" -#: io.c:1812 io.c:1865 +#: io.c:1871 io.c:1924 #, c-format msgid "moving pipe to stdin in child failed (dup: %s)" msgstr "flyttande av rör till standard in i barnet misslyckades (dup: %s)" -#: io.c:1829 io.c:2003 +#: io.c:1888 io.c:2062 msgid "restoring stdout in parent process failed\n" msgstr "återställande av standard ut i förälderprocessen misslyckades\n" -#: io.c:1834 +#: io.c:1893 msgid "restoring stdin in parent process failed\n" msgstr "återställande av standard in i förälderprocessen misslyckades\n" -#: io.c:1868 io.c:2014 io.c:2025 +#: io.c:1927 io.c:2073 io.c:2084 #, c-format msgid "close of pipe failed (%s)" msgstr "stängning av röret misslyckades (%s)" -#: io.c:1913 +#: io.c:1972 msgid "`|&' not supported" msgstr "\"|&\" stöds inte" -#: io.c:1980 +#: io.c:2039 #, c-format msgid "cannot open pipe `%s' (%s)" msgstr "kan inte öppna röret \"%s\" (%s)" -#: io.c:2021 +#: io.c:2080 #, c-format msgid "cannot create child process for `%s' (fork: %s)" msgstr "kan inte skapa barnprocess för \"%s\" (fork: %s)" -#: io.c:2364 +#: io.c:2423 #, c-format msgid "data file `%s' is empty" msgstr "datafilen \"%s\" är tom" -#: io.c:2407 io.c:2415 +#: io.c:2466 io.c:2474 msgid "could not allocate more input memory" msgstr "kunde inte allokera mer indataminne" -#: io.c:2540 io.c:2782 io.c:3046 +#: io.c:2832 io.c:2895 #, c-format msgid "error reading input file `%s': %s" msgstr "fel vid läsning av indatafilen \"%s\": %s" -#: io.c:3281 +#: io.c:3020 msgid "multicharacter value of `RS' is a gawk extension" msgstr "flerteckensvärdet av \"RS\" är en gawk-utökning" -#: main.c:322 +#: main.c:324 msgid "`-m[fr]' option irrelevant in gawk" msgstr "\"-m[fr]\"-flaggan är irrelevant i gawk" -#: main.c:324 +#: main.c:326 msgid "-m option usage: `-m[fr] nnn'" msgstr "-m-flaggans användning: \"-m[fr] nnn\"" -#: main.c:341 +#: main.c:343 #, c-format msgid "%s: option `-W %s' unrecognized, ignored\n" msgstr "%s: flaggan \"-W %s\" okänd, ignorerad\n" -#: main.c:378 +#: main.c:380 msgid "empty argument to `--source' ignored" msgstr "tomt argument till \"--source\" ignorerat" -#: main.c:448 +#: main.c:451 msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'" msgstr "miljövariabeln \"POSIXLY_CORRECT\" satt: slår på \"--posix\"" -#: main.c:453 +#: main.c:456 msgid "`--posix' overrides `--traditional'" msgstr "\"--posix\" åsidosätter \"--traditional\"" -#: main.c:464 +#: main.c:467 msgid "`--posix'/`--traditional' overrides `--non-decimal-data'" msgstr "\"--posix\"/\"--traditional\" åsidosätter \"--non-decimal-data\"" -#: main.c:468 +#: main.c:471 #, c-format msgid "running %s setuid root may be a security problem" msgstr "att köra %s setuid root kan vara ett säkerhetsproblem" -#: main.c:509 +#: main.c:512 #, c-format msgid "can't set binary mode on stdin (%s)" msgstr "kan inte sätta binärläge på standard in (%s)" -#: main.c:512 +#: main.c:515 #, c-format msgid "can't set binary mode on stdout (%s)" msgstr "kan inte sätta binärläge på standard ut (%s)" -#: main.c:514 +#: main.c:517 #, c-format msgid "can't set binary mode on stderr (%s)" msgstr "kan inte sätta binärläge på standard fel (%s)" -#: main.c:544 +#: main.c:547 msgid "no program text at all!" msgstr "ingen programtext alls!" -#: main.c:612 +#: main.c:620 #, c-format msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n" msgstr "" "Användning: %s [POSIX- eller GNU-stilsflaggor] -f progfil [--] fil ...\n" -#: main.c:614 +#: main.c:622 #, c-format msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n" msgstr "Användning: %s [POSIX- eller GNU-stilsflaggor] %cprogram%c fil ...\n" -#: main.c:619 +#: main.c:627 msgid "POSIX options:\t\tGNU long options:\n" msgstr "POSIX-flaggor:\t\tGNU långa flaggor:\n" -#: main.c:620 +#: main.c:628 msgid "\t-f progfile\t\t--file=progfile\n" msgstr "\t-f progfil\t\t--file=progfil\n" -#: main.c:621 +#: main.c:629 msgid "\t-F fs\t\t\t--field-separator=fs\n" msgstr "\t-F fs\t\t\t--field-separator=fs\n" -#: main.c:622 +#: main.c:630 msgid "\t-v var=val\t\t--assign=var=val\n" msgstr "\t-v var=värde\t\t--assign=var=värde\n" -#: main.c:623 +#: main.c:631 msgid "\t-m[fr] val\n" msgstr "\t-m[fr] värde\n" -#: main.c:624 +#: main.c:632 msgid "\t-W compat\t\t--compat\n" msgstr "\t-W compat\t\t--compat\n" -#: main.c:625 +#: main.c:633 msgid "\t-W copyleft\t\t--copyleft\n" msgstr "\t-W copyleft\t\t--copyleft\n" -#: main.c:626 +#: main.c:634 msgid "\t-W copyright\t\t--copyright\n" msgstr "\t-W copyright\t\t--copyright\n" -#: main.c:627 +#: main.c:635 msgid "\t-W dump-variables[=file]\t--dump-variables[=file]\n" msgstr "\t-W dump-variables[=fil]\t--dump-variables[=fil]\n" -#: main.c:628 +#: main.c:636 msgid "\t-W gen-po\t\t--gen-po\n" msgstr "\t-W gen-po\t\t--gen-po\n" -#: main.c:629 +#: main.c:637 msgid "\t-W help\t\t\t--help\n" msgstr "\t-W help\t\t\t--help\n" -#: main.c:630 +#: main.c:638 msgid "\t-W lint[=fatal]\t\t--lint[=fatal]\n" msgstr "\t-W lint[=fatal]\t\t--lint[=fatal]\n" -#: main.c:631 +#: main.c:639 msgid "\t-W lint-old\t\t--lint-old\n" msgstr "\t-W lint-old\t\t--lint-old\n" -#: main.c:632 +#: main.c:640 msgid "\t-W non-decimal-data\t--non-decimal-data\n" msgstr "\t-W non-decimal-data\t--non-decimal-data\n" -#: main.c:634 +#: main.c:642 msgid "\t-W nostalgia\t\t--nostalgia\n" msgstr "\t-W nostalgia\t\t--nostalgia\n" -#: main.c:637 +#: main.c:645 msgid "\t-W parsedebug\t\t--parsedebug\n" msgstr "\t-W parsedebug\t\t--parsedebug\n" -#: main.c:639 +#: main.c:647 msgid "\t-W profile[=file]\t--profile[=file]\n" msgstr "\t-W profile[=fil]\t--profile[=fil]\n" -#: main.c:640 +#: main.c:648 msgid "\t-W posix\t\t--posix\n" msgstr "\t-W posix\t\t--posix\n" -#: main.c:641 +#: main.c:649 msgid "\t-W re-interval\t\t--re-interval\n" msgstr "\t-W re-interval\t\t--re-interval\n" -#: main.c:642 +#: main.c:650 msgid "\t-W source=program-text\t--source=program-text\n" msgstr "\t-W source=programtext\t--source=programtext\n" -#: main.c:643 +#: main.c:651 msgid "\t-W traditional\t\t--traditional\n" msgstr "\t-W traditional\t\t--traditional\n" -#: main.c:644 +#: main.c:652 msgid "\t-W usage\t\t--usage\n" msgstr "\t-W usage\t\t--usage\n" -#: main.c:645 +#: main.c:653 msgid "\t-W version\t\t--version\n" msgstr "\t-W version\t\t--version\n" -#: main.c:649 +#: main.c:657 msgid "" "\n" "To report bugs, see node `Bugs' in `gawk.info', which is\n" @@ -1461,7 +1472,7 @@ "Rapportera synpunkter på översättningen till .\n" "\n" -#: main.c:653 +#: main.c:661 msgid "" "gawk is a pattern scanning and processing language.\n" "By default it reads standard input and writes standard output.\n" @@ -1471,7 +1482,7 @@ "Normalt läser det från standard in och skriver till standard ut.\n" "\n" -#: main.c:657 +#: main.c:665 msgid "" "Examples:\n" "\tgawk '{ sum += $1 }; END { print sum }' file\n" @@ -1481,7 +1492,7 @@ "\tgawk '{ sum += $1 }; END { print sum }' fil\n" "\tgawk -F: '{print $1 }' /etc/passwd\n" -#: main.c:669 +#: main.c:682 #, c-format msgid "" "Copyright (C) 1989, 1991-%d Free Software Foundation.\n" @@ -1500,7 +1511,7 @@ "någon senare version.\n" "\n" -#: main.c:677 +#: main.c:690 msgid "" "This program is distributed in the hope that it will be useful,\n" "but WITHOUT ANY WARRANTY; without even the implied warranty of\n" @@ -1514,7 +1525,7 @@ "General Public License för ytterligare information.\n" "\n" -#: main.c:683 +#: main.c:696 msgid "" "You should have received a copy of the GNU General Public License\n" "along with this program; if not, write to the Free Software\n" @@ -1524,46 +1535,46 @@ "med detta program. Om inte, skriv till Free Software Foundation,\n" "Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n" -#: main.c:713 +#: main.c:730 msgid "-Ft does not set FS to tab in POSIX awk" msgstr "-Ft sätter inte FS till tab i POSIX-awk" -#: main.c:944 +#: main.c:956 #, c-format msgid "" "%s: `%s' argument to `-v' not in `var=value' form\n" "\n" msgstr "%s: Argumentet \"%s\" till \"-v\" är inte på formatet \"var=värde\"\n" -#: main.c:964 +#: main.c:976 #, c-format msgid "`%s' is not a legal variable name" msgstr "\"%s\" är inte ett giltigt variabelnamn" -#: main.c:967 +#: main.c:979 #, c-format msgid "`%s' is not a variable name, looking for file `%s=%s'" msgstr "\"%s\" är inte ett variabelnamn, letar efter filen \"%s=%s\"" -#: main.c:995 +#: main.c:1012 msgid "floating point exception" msgstr "flyttalsundantag" -#: main.c:1002 +#: main.c:1019 msgid "fatal error: internal error" msgstr "ödesdigert fel: internt fel" -#: main.c:1052 +#: main.c:1069 #, c-format msgid "no pre-opened fd %d" msgstr "ingen föröppnad fd %d" -#: main.c:1057 +#: main.c:1074 #, c-format msgid "could not pre-open /dev/null for fd %d" msgstr "kunde inte föröppna /dev/null för fd %d" -#: main.c:1080 main.c:1089 +#: main.c:1097 main.c:1106 #, c-format msgid "could not find groups: %s" msgstr "kunde inte hitta grupper: %s" @@ -1584,23 +1595,23 @@ msgid "fatal: " msgstr "ödesdigert: " -#: node.c:59 node.c:66 node.c:75 node.c:89 node.c:116 +#: node.c:58 node.c:65 node.c:74 node.c:88 node.c:115 msgid "can't convert string to float" msgstr "kan inte konvertera en sträng till flyttal" -#: node.c:357 +#: node.c:355 msgid "backslash at end of string" msgstr "omvänt snedstreck i slutet av strängen" -#: node.c:544 +#: node.c:539 msgid "POSIX does not allow `\\x' escapes" msgstr "POSIX tillåter inte \"\\x\"-kontrollsekvenser" -#: node.c:550 +#: node.c:545 msgid "no hex digits in `\\x' escape sequence" msgstr "inga hexadecimala siffror i \"\\x\"-kontrollsekvenser" -#: node.c:584 +#: node.c:579 #, c-format msgid "escape sequence `\\%c' treated as plain `%c'" msgstr "kontrollsekvensen \"\\%c\" behandlad som bara \"%c\"" @@ -1615,24 +1626,21 @@ msgid "could not open `%s' for writing: %s" msgstr "kunde inte öppna \"%s\" för skrivning: %s" -#: profile.c:409 -msgid "internal error: Node_var with null vname" +#: profile.c:449 +#, fuzzy, c-format +msgid "internal error: %s with null vname" msgstr "internt fel: Node_var med null vname" -#: profile.c:471 +#: profile.c:512 msgid "# treated internally as `delete'" msgstr "# behandlad internt som \"delete\"" -#: profile.c:545 -msgid "internal error: Node_var_array with null vname" -msgstr "internt fel: Node_var_vektor med null vname" - -#: profile.c:1127 +#: profile.c:1162 #, c-format msgid "\t# gawk profile, created %s\n" msgstr "\t# gawkprofil, skapad %s\n" -#: profile.c:1130 +#: profile.c:1165 msgid "" "\t# BEGIN block(s)\n" "\n" @@ -1640,7 +1648,7 @@ "\t# BEGIN-block\n" "\n" -#: profile.c:1140 +#: profile.c:1175 msgid "" "\t# Rule(s)\n" "\n" @@ -1648,7 +1656,7 @@ "\t# Regel/regler\n" "\n" -#: profile.c:1146 +#: profile.c:1181 msgid "" "\t# END block(s)\n" "\n" @@ -1656,7 +1664,7 @@ "\t# END-block\n" "\n" -#: profile.c:1166 +#: profile.c:1201 msgid "" "\n" "\t# Functions, listed alphabetically\n" @@ -1664,7 +1672,7 @@ "\n" "\t# Funktioner, listade alfabetiskt\n" -#: profile.c:1376 +#: profile.c:1413 #, c-format msgid "unexpected type %s in prec_level" msgstr "oväntad typ %s i prec_level" @@ -1748,6 +1756,31 @@ msgid "No previous regular expression" msgstr "Inget föregående reguljärt uttryck" +#~ msgid "substr: length %g is < 0" +#~ msgstr "substr: längden %g är < 0" + +#~ msgid "delete: illegal use of variable `%s' as array" +#~ msgstr "delete: otillåten användning av variabeln \"%s\" som vektor" + +#, fuzzy +#~ msgid "%s: gvar_ref to %s\n" +#~ msgstr "%s: vektorreferens till %s\n" + +#~ msgid "asort: first argument is not an array" +#~ msgstr "asort: första argumentet är inte en vektor" + +#~ msgid "asort: second argument is not an array" +#~ msgstr "asort: andra argumentet är inte en vektor" + +#, fuzzy +#~ msgid "" +#~ "attempt to use array parameter `%s' that was passed from global scalar `%" +#~ "s'" +#~ msgstr "försök att använda skalärparametern \"%s\" som en vektor" + +#~ msgid "internal error: Node_var_array with null vname" +#~ msgstr "internt fel: Node_var_vektor med null vname" + #~ msgid "" #~ "\n" #~ "To report bugs, see node `Bugs' in `gawk.info', which is\n" Binary files gawk-3.1.2/po/tr.gmo and gawk-3.1.3/po/tr.gmo differ diff -urN gawk-3.1.2/po/tr.po gawk-3.1.3/po/tr.po --- gawk-3.1.2/po/tr.po 2003-03-19 04:25:12.000000000 -0800 +++ gawk-3.1.3/po/tr.po 2003-07-07 11:20:34.000000000 -0700 @@ -4,74 +4,72 @@ # msgid "" msgstr "" -"Project-Id-Version: gawk 3.1.1k\n" -"POT-Creation-Date: 2003-03-19 14:25+0200\n" -"PO-Revision-Date: 2003-02-04 18:55+0200\n" +"Project-Id-Version: gawk 3.1.2g\n" +"Report-Msgid-Bugs-To: arnold@skeeve.com\n" +"POT-Creation-Date: 2003-07-07 11:20-0700\n" +"PO-Revision-Date: 2003-06-25 07:43+0300\n" "Last-Translator: Nilgün Belma Bugüner \n" "Language-Team: Turkish \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: KBabel 0.9.6\n" +"X-Generator: KBabel 1.0\n" -#: array.c:274 array.c:309 array.c:314 eval.c:494 +#: array.c:112 +#, c-format +msgid "attempt to use scalar parameter `%s' as an array" +msgstr "sayısal paramaetre `%s' bir dizi olarak kullanılmaya çalışılıyor" + +#: array.c:113 #, c-format msgid "attempt to use scalar `%s' as array" msgstr "sayısal `%s' dizi olarak kullanılmaya çalışılıyor" -#: array.c:338 +#: array.c:151 +#, c-format +msgid "from %s" +msgstr "%s'den" + +#: array.c:506 #, c-format msgid "reference to uninitialized element `%s[\"%s\"]'" -msgstr "ön deÄŸer atanmamış öğeye ( %s[\"%s\"] ) baÅŸvuru yapılıyor" +msgstr "ilklendirilmemiÅŸ öğeye ( %s[\"%s\"] ) baÅŸvuru yapılıyor" -#: array.c:344 +#: array.c:512 #, c-format msgid "subscript of array `%s' is null string" msgstr "dizinin indisi `%s' bir null dizge" -#: array.c:412 array.c:425 array.c:466 +#: array.c:609 #, c-format msgid "delete: index `%s' not in array `%s'" msgstr "delete: `%s' indeksi `%s' dizisinde deÄŸil" -#: array.c:432 array.c:515 -#, c-format -msgid "delete: illegal use of variable `%s' as array" -msgstr "delete: `%s' deÄŸiÅŸkeninin dizi olarak kullanımı kuraldışı" - -#: array.c:633 +#: array.c:769 #, c-format msgid "%s: empty (null)\n" msgstr "%s: boÅŸ (null)\n" -#: array.c:638 +#: array.c:774 #, c-format msgid "%s: empty (zero)\n" msgstr "%s: boÅŸ (sıfır)\n" -#: array.c:642 +#: array.c:778 #, c-format msgid "%s: table_size = %d, array_size = %d\n" msgstr "%s: tablo_uzunluÄŸu = %d, dizi_indisi = %d\n" -#: array.c:671 +#: array.c:807 #, c-format msgid "%s: is parameter\n" msgstr "%s: parametredir\n" -#: array.c:676 +#: array.c:812 #, c-format msgid "%s: array_ref to %s\n" msgstr "%s: %s için dizi baÅŸvurusu\n" -#: array.c:975 -msgid "asort: first argument is not an array" -msgstr "asort: ilk argüman bir dizi deÄŸil" - -#: array.c:984 -msgid "asort: second argument is not an array" -msgstr "asort: ikinci argüman bir dizi deÄŸil" - #: awkgram.y:208 #, c-format msgid "%s blocks must have an action part" @@ -91,260 +89,273 @@ msgid "regexp constant `/%s/' looks like a C comment, but is not" msgstr "düzenli ifade sabiti `/%s/' bir C açıklaması gibi görünüyor ama deÄŸil" -#: awkgram.y:340 +#: awkgram.y:340 awkgram.y:615 msgid "statement may have no effect" msgstr "deyim bir etkiye sahip olmayabilir" -#: awkgram.y:431 awkgram.y:451 +#: awkgram.y:435 awkgram.y:455 #, c-format msgid "`%s' used in %s action" msgstr "`%s' %s eyleminde kullanılmış" -#: awkgram.y:444 awkgram.y:447 +#: awkgram.y:448 awkgram.y:451 msgid "`nextfile' is a gawk extension" msgstr "`nextfile' bir gawk uzantısıdır" -#: awkgram.y:461 +#: awkgram.y:465 msgid "`return' used outside function context" msgstr "`return' iÅŸlev baÄŸlamının dışında kullanılmış" -#: awkgram.y:500 +#: awkgram.y:504 msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'" msgstr "BEGIN veya END kuralındaki `print' aslında `print \"\"' olmalıydı" -#: awkgram.y:513 awkgram.y:520 +#: awkgram.y:517 awkgram.y:524 msgid "`delete array' is a gawk extension" msgstr "`delete array' bir gawk uzantısıdır" -#: awkgram.y:528 awkgram.y:535 +#: awkgram.y:532 awkgram.y:539 msgid "`delete(array)' is a non-portable tawk extension" msgstr "`delete array' uyarlanabilir olmayan bir gawk uzantısıdır" -#: awkgram.y:578 +#: awkgram.y:583 +#, c-format +msgid "duplicate case values in switch body: %s" +msgstr "switch içinde yinelenmiÅŸ case deÄŸerleri var: %s" + +#: awkgram.y:593 +msgid "Duplicate `default' detected in switch body" +msgstr "switch içinde yinelenmiÅŸ `default' saptandı" + +#: awkgram.y:681 msgid "multistage two-way pipelines don't work" msgstr "çok katlı iki yönlü veriyolları çalışmaz" -#: awkgram.y:669 +#: awkgram.y:772 msgid "regular expression on right of assignment" msgstr "düzenli ifade atamanın sağında" -#: awkgram.y:679 +#: awkgram.y:782 msgid "regular expression on left of `~' or `!~' operator" msgstr "düzenli ifade `~' ya da `!~' iÅŸlemiminin solunda" -#: awkgram.y:687 +#: awkgram.y:790 msgid "regular expression on right of comparison" msgstr "düzenli ifade karşılaÅŸtırmanın sağında" -#: awkgram.y:754 +#: awkgram.y:857 msgid "non-redirected `getline' undefined inside END action" msgstr "END eyleminin içinde yönlendirme yapmayan `getline' tanımsız" -#: awkgram.y:781 +#: awkgram.y:884 msgid "call of `length' without parentheses is not portable" msgstr "parantezsiz `length' çaÄŸrısı taşınabilir deÄŸil" -#: awkgram.y:784 +#: awkgram.y:887 msgid "call of `length' without parentheses is deprecated by POSIX" msgstr "parantezsiz `length' çaÄŸrısı POSIX'e uygun deÄŸil" -#: awkgram.y:835 +#: awkgram.y:940 +msgid "use of non-array as array" +msgstr "dizi olmayan deÄŸiÅŸken dizi olarak kullanılmış" + +#: awkgram.y:942 msgid "invalid subscript expression" msgstr "indis ifadesi geçersiz" -#: awkgram.y:1020 +#: awkgram.y:1140 msgid "unexpected newline or end of string" msgstr "beklenmeyen satırsonu ya da dizge sonu" -#: awkgram.y:1115 +#: awkgram.y:1235 msgid "empty program text on command line" msgstr "komut satırında boÅŸ program metni" -#: awkgram.y:1172 +#: awkgram.y:1292 #, c-format msgid "can't open source file `%s' for reading (%s)" msgstr "kaynak dosyası `%s' okumak için açılamıyor (%s)" -#: awkgram.y:1207 +#: awkgram.y:1327 #, c-format msgid "can't read sourcefile `%s' (%s)" msgstr "kaynak dosyası `%s' okunamıyor (%s)" -#: awkgram.y:1215 +#: awkgram.y:1335 #, c-format msgid "source file `%s' is empty" msgstr "kaynak dosyası `%s' boÅŸ" -#: awkgram.y:1417 awkgram.y:1527 awkgram.y:1545 awkgram.y:1895 awkgram.y:1980 +#: awkgram.y:1537 awkgram.y:1647 awkgram.y:1665 awkgram.y:2015 awkgram.y:2100 msgid "source file does not end in newline" msgstr "kaynak dosyasının sonunda satırsonu eksik" -#: awkgram.y:1481 +#: awkgram.y:1601 msgid "unterminated regexp ends with `\\' at end of file" msgstr "sonlandırılmamış düzenli ifade dosya sonunda `\\' ile bitiyor" -#: awkgram.y:1501 +#: awkgram.y:1621 msgid "unterminated regexp" msgstr "sonlandırılmamış düzenli ifade" -#: awkgram.y:1504 +#: awkgram.y:1624 msgid "unterminated regexp at end of file" msgstr "dosya sonunda sonlandırılmamış düzenli ifade" -#: awkgram.y:1571 +#: awkgram.y:1691 msgid "use of `\\ #...' line continuation is not portable" msgstr "`\\ #...' satır uzatma kullanımı taşınabilir deÄŸil" -#: awkgram.y:1583 +#: awkgram.y:1703 msgid "backslash not last character on line" msgstr "tersbölü satırdaki son karakter deÄŸil" -#: awkgram.y:1628 +#: awkgram.y:1748 msgid "POSIX does not allow operator `**='" msgstr "`**=' iÅŸlemimi POSIX uyumlu deÄŸil" -#: awkgram.y:1630 +#: awkgram.y:1750 msgid "old awk does not support operator `**='" msgstr "`**=' iÅŸlemimini eski awk desteklemiyor" -#: awkgram.y:1639 +#: awkgram.y:1759 msgid "POSIX does not allow operator `**'" msgstr "`**' iÅŸlemimi POSIX uyumlu deÄŸil" -#: awkgram.y:1641 +#: awkgram.y:1761 msgid "old awk does not support operator `**'" msgstr "`**' iÅŸlemimini eski awk desteklemiyor" -#: awkgram.y:1672 +#: awkgram.y:1792 msgid "operator `^=' is not supported in old awk" msgstr "`^=' iÅŸlemimini eski awk desteklemiyor" -#: awkgram.y:1680 +#: awkgram.y:1800 msgid "operator `^' is not supported in old awk" msgstr "`^' iÅŸlemimini eski awk desteklemiyor" -#: awkgram.y:1764 awkgram.y:1781 +#: awkgram.y:1884 awkgram.y:1901 msgid "unterminated string" msgstr "sonlandırılmamış dizge" -#: awkgram.y:1941 +#: awkgram.y:2061 #, c-format msgid "invalid char '%c' in expression" msgstr "ifade içinde '%c' karakteri geçersiz" -#: awkgram.y:2001 +#: awkgram.y:2121 #, c-format msgid "`%s' is a gawk extension" msgstr "`%s' bir gawk uzantısıdır" -#: awkgram.y:2004 +#: awkgram.y:2124 #, c-format msgid "`%s' is a Bell Labs extension" msgstr "`%s' bir Bell Laboratuarları uzantısıdır" -#: awkgram.y:2007 +#: awkgram.y:2127 #, c-format msgid "POSIX does not allow `%s'" msgstr "`%s' POSIX uyumlu deÄŸil" -#: awkgram.y:2011 +#: awkgram.y:2131 #, c-format msgid "`%s' is not supported in old awk" msgstr "`%s' eski awk tarafından desteklemiyor" -#: awkgram.y:2038 +#: awkgram.y:2158 msgid "`goto' considered harmful!\n" msgstr "`goto' zararlı sayılır!\n" -#: awkgram.y:2102 +#: awkgram.y:2220 #, c-format msgid "%d is invalid as number of arguments for %s" msgstr "%d argüman sayısı olarak %s için geçersiz" -#: awkgram.y:2121 awkgram.y:2124 +#: awkgram.y:2239 awkgram.y:2242 msgid "match: third argument is a gawk extension" msgstr "match: üçüncü argüman bir gawk uzantısı" -#: awkgram.y:2137 +#: awkgram.y:2255 #, c-format msgid "%s: string literal as last arg of substitute has no effect" msgstr "%s: yerine kullanılan son argüman olarak dizge sabiti etkisiz" -#: awkgram.y:2140 +#: awkgram.y:2258 #, c-format msgid "%s third parameter is not a changeable object" msgstr "üçüncü %s parametresi deÄŸiÅŸtirilebilir bir nesne deÄŸil" -#: awkgram.y:2167 awkgram.y:2170 +#: awkgram.y:2285 awkgram.y:2288 msgid "close: second argument is a gawk extension" msgstr "close: ikinci argüman bir gawk uzantısı" -#: awkgram.y:2180 +#: awkgram.y:2298 msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore" msgstr "dcgettext(_\"...\") kullanımı yanlış: altçizgiyi kaldırın" -#: awkgram.y:2195 +#: awkgram.y:2313 msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore" msgstr "dcngettext(_\"...\") kullanımı yanlış: altçizgiyi kaldırın" -#: awkgram.y:2266 +#: awkgram.y:2384 #, c-format msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d" msgstr "`%s' iÅŸlevi: %d. parametre, `%s', %d. parametrenin tekrarı" -#: awkgram.y:2299 +#: awkgram.y:2417 #, c-format msgid "function `%s': parameter `%s' shadows global variable" msgstr "`%s' iÅŸlevi: parametre, `%s'global deÄŸiÅŸkeni gölgeliyor" -#: awkgram.y:2411 +#: awkgram.y:2529 #, c-format msgid "could not open `%s' for writing (%s)" msgstr "`%s' yazmak için açılamadı (%s)" -#: awkgram.y:2412 profile.c:93 +#: awkgram.y:2530 profile.c:93 msgid "sending profile to standard error" msgstr "profil standart hataya gönderiliyor" -#: awkgram.y:2442 +#: awkgram.y:2562 #, c-format msgid "%s: close failed (%s)" msgstr "%s: kapatma baÅŸarısız (%s)" -#: awkgram.y:2566 +#: awkgram.y:2684 msgid "shadow_funcs() called twice!" msgstr "shadow_funcs() iki kere çaÄŸrıldı!" -#: awkgram.y:2593 +#: awkgram.y:2711 msgid "there were shadowed variables." msgstr "gölgeli deÄŸiÅŸkenler vardı." -#: awkgram.y:2666 +#: awkgram.y:2784 #, c-format msgid "function `%s': can't use function name as parameter name" msgstr "iÅŸlev `%s': iÅŸlev ismi parametre ismi olarak kullanılamaz" -#: awkgram.y:2676 +#: awkgram.y:2794 #, c-format msgid "function name `%s' previously defined" msgstr "iÅŸlev ismi `%s' önceden atanmış" -#: awkgram.y:2827 awkgram.y:2833 +#: awkgram.y:2945 awkgram.y:2951 #, c-format msgid "function `%s' called but never defined" msgstr "`%s' iÅŸlevi çaÄŸrıldı ama hiç atanmamış" -#: awkgram.y:2836 +#: awkgram.y:2954 #, c-format msgid "function `%s' defined but never called" msgstr "`%s' iÅŸlevi atanmış ama hiç çaÄŸrılmadı" -#: awkgram.y:2863 +#: awkgram.y:2981 #, c-format msgid "regexp constant for parameter #%d yields boolean value" msgstr "%d numaralı argüman bir düzenli ifade sabiti" -#: awkgram.y:2876 +#: awkgram.y:2994 #, c-format msgid "" "function `%s' called with space between name and `(',\n" @@ -353,196 +364,201 @@ "`%s' iÅŸlevi `(' ile isim arasında boÅŸlukla çaÄŸrılmış,\n" "%s" -#: awkgram.y:2878 +#: awkgram.y:2996 msgid "or used as a variable or an array" msgstr "ya da bir deÄŸiÅŸken ya da dizi olarak kullanılmış" -#: builtin.c:111 +#: builtin.c:137 #, c-format msgid "%s to \"%s\" failed (%s)" msgstr "%s \"%s\"ya yazılamadı (%s)" -#: builtin.c:112 +#: builtin.c:138 msgid "standard output" msgstr "standart çıktı" -#: builtin.c:113 +#: builtin.c:139 msgid "reason unknown" msgstr "sebebi bilinmiyor" -#: builtin.c:126 +#: builtin.c:152 msgid "exp: received non-numeric argument" msgstr "exp: sayısal olmayan argüman alındı" -#: builtin.c:132 +#: builtin.c:158 #, c-format msgid "exp: argument %g is out of range" msgstr "exp: %g kapsamdışı" -#: builtin.c:190 +#: builtin.c:216 #, c-format msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing" msgstr "" "fflush: kanala yazılamadı: veriyolu `%s' okumak için açıldı, yazmak için " "deÄŸil" -#: builtin.c:193 +#: builtin.c:219 #, c-format msgid "fflush: cannot flush: file `%s' opened for reading, not writing" msgstr "" "fflush: kanala yazılamadı: dosya `%s' okumak için açıldı, yazmak için deÄŸil" -#: builtin.c:205 +#: builtin.c:231 #, c-format msgid "fflush: `%s' is not an open file, pipe or co-process" msgstr "fflush: `%s' bir açık dosya, veriyolu ya da bir yan iÅŸlem deÄŸil" -#: builtin.c:299 +#: builtin.c:325 msgid "index: received non-string first argument" msgstr "index: ilk argüman dizge olmayan türde alındı" -#: builtin.c:301 +#: builtin.c:327 msgid "index: received non-string second argument" msgstr "index: ikinci argüman dizge olmayan türde alındı" -#: builtin.c:411 +#: builtin.c:437 msgid "int: received non-numeric argument" msgstr "int: sayısal olmayan argüman alındı" -#: builtin.c:428 +#: builtin.c:454 msgid "length: received non-string argument" msgstr "length: dizge olmayan argüman alındı" -#: builtin.c:444 +#: builtin.c:470 msgid "log: received non-numeric argument" msgstr "log: sayısal olmayan argüman alındı" -#: builtin.c:447 +#: builtin.c:473 #, c-format msgid "log: received negative argument %g" msgstr "log: negatif argüman %g alındı" -#: builtin.c:609 builtin.c:612 +#: builtin.c:635 builtin.c:638 msgid "must use `count$' on all formats or none" msgstr "tüm biçemlerde ya `count$' kullanmalısınız ya da hiçbir ÅŸey" -#: builtin.c:714 +#: builtin.c:740 msgid "`$' is not permitted in awk formats" msgstr "`$' awk biçemlerde kullanılmaz" -#: builtin.c:720 +#: builtin.c:746 msgid "arg count with `$' must be > 0" msgstr "`$' ile birlikte verilen argüman sayısı > 0 olmalıdır" -#: builtin.c:722 +#: builtin.c:748 #, c-format msgid "arg count %ld greater than total number of supplied arguments" msgstr "argüman sayısı %ld saÄŸlanmış toplam argüman sayısından büyük" -#: builtin.c:724 +#: builtin.c:750 msgid "`$' not permitted after period in format" msgstr "`$' biçem içinde noktadan sonra kullanılmaz" -#: builtin.c:737 +#: builtin.c:763 msgid "no `$' supplied for positional field width or precision" msgstr "konumsal alan geniÅŸliÄŸi ya da duyarlığı için `$' kullanılmamış" -#: builtin.c:795 +#: builtin.c:821 msgid "`l' is meaningless in awk formats; ignored" msgstr "`l' awk biçemlerde anlamsız; yoksayıldı" -#: builtin.c:799 +#: builtin.c:825 msgid "`l' is not permitted in POSIX awk formats" msgstr "`l' POSIX awk biçemlerde kullanılmaz" -#: builtin.c:810 +#: builtin.c:836 msgid "`L' is meaningless in awk formats; ignored" msgstr "`L' awk biçemlerde anlamsız; yoksayıldı" -#: builtin.c:814 +#: builtin.c:840 msgid "`L' is not permitted in POSIX awk formats" msgstr "`L' POSIX awk biçemlerde kullanılmaz" -#: builtin.c:825 +#: builtin.c:851 msgid "`h' is meaningless in awk formats; ignored" msgstr "`h' awk biçemlerde anlamsız; yoksayıldı" -#: builtin.c:829 +#: builtin.c:855 msgid "`h' is not permitted in POSIX awk formats" msgstr "`h' POSIX awk biçemlerde kullanılmaz" -#: builtin.c:1078 +#: builtin.c:1055 +#, c-format +msgid "[s]printf: value %g is out of range for `%%%c' format" +msgstr "[s]printf: %g deÄŸeri `%%%c' biçimi için kapsamdışı" + +#: builtin.c:1108 msgid "not enough arguments to satisfy format string" msgstr "biçem dizgesini oluÅŸturacak yeterli argüman yok" -#: builtin.c:1080 +#: builtin.c:1110 msgid "^ ran out for this one" msgstr "bir bunun için ^ tükendi" -#: builtin.c:1085 +#: builtin.c:1115 msgid "[s]printf: format specifier does not have control letter" msgstr "[s]printf: biçem belirteci denetim karakteri içermiyor" -#: builtin.c:1088 +#: builtin.c:1118 msgid "too many arguments supplied for format string" msgstr "biçem dizgesi için çok fazla argüman saÄŸlanmış" -#: builtin.c:1154 builtin.c:1157 +#: builtin.c:1184 builtin.c:1187 msgid "printf: no arguments" msgstr "printf: argüman yok" -#: builtin.c:1181 +#: builtin.c:1211 msgid "sqrt: received non-numeric argument" msgstr "sqrt: sayısal olmayan argüman alındı" -#: builtin.c:1185 +#: builtin.c:1215 #, c-format msgid "sqrt: called with negative argument %g" msgstr "sqrt: negatif argüman %g ile çaÄŸrıldı" -#: builtin.c:1207 +#: builtin.c:1238 #, c-format msgid "substr: start index %g is invalid, using 1" msgstr "substr: baÅŸlangıç indeksi olarak %g geçersiz, 1 kullanılıyor" -#: builtin.c:1212 +#: builtin.c:1243 #, c-format msgid "substr: non-integer start index %g will be truncated" msgstr "" "substr: tamsayı olmayan baÅŸlangıç indeksi %g den ondalık kısım çıkarılacak" -#: builtin.c:1231 -#, c-format -msgid "substr: length %g is <= 0" +#: builtin.c:1262 +#, fuzzy, c-format +msgid "substr: length %g is not >= 1" msgstr "substr: uzunluk %g <= 0 dır" -#: builtin.c:1233 -#, c-format -msgid "substr: length %g is < 0" -msgstr "substr: uzunluk %g < 0" +#: builtin.c:1264 +#, fuzzy, c-format +msgid "substr: length %g is not >= 0" +msgstr "substr: uzunluk %g <= 0 dır" -#: builtin.c:1240 +#: builtin.c:1271 #, c-format msgid "substr: non-integer length %g will be truncated" msgstr "substr: tamsayı olmayan uzunluk %g den ondalık kısım çıkarılacak" -#: builtin.c:1245 +#: builtin.c:1276 #, c-format msgid "substr: length %g too big for string indexing, truncating to %g" msgstr "" "substr: dizge indislemesi için uzunluk olarak %g çok fazla, %g den sonrası " "gözardı ediliyor" -#: builtin.c:1257 +#: builtin.c:1288 msgid "substr: source string is zero length" msgstr "substr: kaynak dizge sıfır uzunlukta" -#: builtin.c:1263 +#: builtin.c:1294 #, c-format msgid "substr: start index %g is past end of string" msgstr "substr: baÅŸlangıç indisi %g dizgenin sonundan sonra" -#: builtin.c:1271 +#: builtin.c:1302 #, c-format msgid "" "substr: length %g at start index %g exceeds length of first argument (%lu)" @@ -550,288 +566,288 @@ "substr: uzunluk %g, %g baÅŸlangıç indisinde ilk argümanın uzunluÄŸunu (%lu) " "aÅŸar" -#: builtin.c:1306 +#: builtin.c:1337 msgid "strftime: received non-string first argument" msgstr "strftime: ilk argüman dizge olmayan türde alındı" -#: builtin.c:1312 +#: builtin.c:1343 msgid "strftime: received empty format string" msgstr "strftime: boÅŸ biçem dizgesi alındı" -#: builtin.c:1321 +#: builtin.c:1352 msgid "strftime: received non-numeric second argument" msgstr "strftime: ikinci argüman sayısal olmayan türde alındı" -#: builtin.c:1384 +#: builtin.c:1415 msgid "mktime: received non-string argument" msgstr "mktime: dizge olmayan argüman alındı" -#: builtin.c:1429 +#: builtin.c:1460 msgid "system: received non-string argument" msgstr "system: dizge olmayan argüman alındı" -#: builtin.c:1573 +#: builtin.c:1581 eval.c:1883 +#, c-format +msgid "reference to uninitialized field `$%d'" +msgstr "ilklendirilmemiÅŸ `$%d' alanına baÅŸvuru" + +#: builtin.c:1608 msgid "tolower: received non-string argument" msgstr "tolower: dizge olmayan argüman alındı" -#: builtin.c:1622 +#: builtin.c:1657 msgid "toupper: received non-string argument" msgstr "toupper: dizge olmayan argüman alındı" -#: builtin.c:1667 +#: builtin.c:1702 msgid "atan2: received non-numeric first argument" msgstr "atan2: ilk argüman sayısal olmayan türde alındı" -#: builtin.c:1669 +#: builtin.c:1704 msgid "atan2: received non-numeric second argument" msgstr "atan2: ikinci argüman sayısal olmayan türde alındı" -#: builtin.c:1688 +#: builtin.c:1723 msgid "sin: received non-numeric argument" msgstr "sin: sayısal olmayan argüman alındı" -#: builtin.c:1704 +#: builtin.c:1739 msgid "cos: received non-numeric argument" msgstr "cos: sayısal olmayan argüman alındı" -#: builtin.c:1748 +#: builtin.c:1788 msgid "srand: received non-numeric argument" msgstr "srand: sayısal olmayan argüman alındı" -#: builtin.c:1787 +#: builtin.c:1823 msgid "match: third argument is not an array" msgstr "match: üçüncü argüman bir dizi deÄŸil" -#: builtin.c:2264 -msgid "gensub: 3rd argument of 0 treated as 1" +#: builtin.c:2307 +msgid "gensub: third argument of 0 treated as 1" msgstr "gensub: 0 olan 3. argüman 1 kabul edildi" -#: builtin.c:2375 builtin.c:2377 +#: builtin.c:2416 builtin.c:2418 msgid "lshift: received non-numeric first argument" msgstr "lshift: ilk argüman sayısal olmayan türde alındı" -#: builtin.c:2379 +#: builtin.c:2420 #, c-format msgid "lshift(%lf, %lf): negative values will give strange results" msgstr "lshift(%lf, %lf): negatif deÄŸerler tuhaf sonuçlar verecek" -#: builtin.c:2381 +#: builtin.c:2422 #, c-format msgid "lshift(%lf, %lf): fractional values will be truncated" msgstr "lshift(%lf, %lf): tamsayı kısım kalacak ÅŸekilde kalanı atılacak" -#: builtin.c:2383 +#: builtin.c:2424 #, c-format msgid "lshift(%lf, %lf): too large shift value will give strange results" msgstr "lshift(%lf, %lf): çok büyük kaydırma deÄŸeri tuhaf sonuçlar verecek" -#: builtin.c:2412 builtin.c:2414 +#: builtin.c:2453 builtin.c:2455 msgid "rshift: received non-numeric first argument" msgstr "rshift: ilk argüman sayısal olmayan türde alındı" -#: builtin.c:2416 +#: builtin.c:2457 #, c-format msgid "rshift(%lf, %lf): negative values will give strange results" msgstr "rshift(%lf, %lf): negatif deÄŸerler tuhaf sonuçlar verecek" -#: builtin.c:2418 +#: builtin.c:2459 #, c-format msgid "rshift(%lf, %lf): fractional values will be truncated" msgstr "rshift(%lf, %lf): tamsayı kısım kalacak ÅŸekilde kalanı atılacak" -#: builtin.c:2420 +#: builtin.c:2461 #, c-format msgid "rshift(%lf, %lf): too large shift value will give strange results" msgstr "rshift(%lf, %lf): çok büyük kaydırma deÄŸeri tuhaf sonuçlar verecek" -#: builtin.c:2449 builtin.c:2451 +#: builtin.c:2490 builtin.c:2492 msgid "and: received non-numeric first argument" msgstr "and: ilk argüman sayısal olmayan türde alındı" -#: builtin.c:2453 +#: builtin.c:2494 #, c-format msgid "and(%lf, %lf): negative values will give strange results" msgstr "and(%lf, %lf): negatif deÄŸerler tuhaf sonuçlar verecek" -#: builtin.c:2455 +#: builtin.c:2496 #, c-format msgid "and(%lf, %lf): fractional values will be truncated" msgstr "and(%lf, %lf): tamsayı kısım kalacak ÅŸekilde kalanı atılacak" -#: builtin.c:2484 builtin.c:2486 +#: builtin.c:2525 builtin.c:2527 msgid "or: received non-numeric first argument" msgstr "or: ilk argüman sayısal olmayan türde alındı" -#: builtin.c:2488 +#: builtin.c:2529 #, c-format msgid "or(%lf, %lf): negative values will give strange results" msgstr "or(%lf, %lf): negatif deÄŸerler tuhaf sonuçlar verecek" -#: builtin.c:2490 +#: builtin.c:2531 #, c-format msgid "or(%lf, %lf): fractional values will be truncated" msgstr "or(%lf, %lf): tamsayı kısım kalacak ÅŸekilde kalanı atılacak" -#: builtin.c:2519 builtin.c:2521 +#: builtin.c:2560 builtin.c:2562 msgid "xor: received non-numeric first argument" msgstr "xor: ilk argüman sayısal olmayan türde alındı" -#: builtin.c:2523 +#: builtin.c:2564 #, c-format msgid "xor(%lf, %lf): negative values will give strange results" msgstr "xor(%lf, %lf): negatif deÄŸerler tuhaf sonuçlar verecek" -#: builtin.c:2525 +#: builtin.c:2566 #, c-format msgid "xor(%lf, %lf): fractional values will be truncated" msgstr "xor(%lf, %lf): tamsayı kısım kalacak ÅŸekilde kalanı atılacak" -#: builtin.c:2553 +#: builtin.c:2594 msgid "compl: received non-numeric argument" msgstr "compl: sayısal olmayan argüman alındı" -#: builtin.c:2555 +#: builtin.c:2596 #, c-format msgid "compl(%lf): negative value will give strange results" msgstr "compl(%lf): negatif deÄŸerler tuhaf sonuçlar verecek" -#: builtin.c:2557 +#: builtin.c:2598 #, c-format msgid "compl(%lf): fractional value will be truncated" msgstr "compl(%lf): tamsayı kısım kalacak ÅŸekilde kalanı atılacak" -#: builtin.c:2728 +#: builtin.c:2771 #, c-format msgid "dcgettext: `%s' is not a valid locale category" msgstr "dcgettext: `%s' geçerli bir yerel kategori deÄŸil" -#: eval.c:262 +#: eval.c:266 #, c-format msgid "unknown nodetype %d" msgstr "%d. düğümtürü bilinmiyor" -#: eval.c:310 +#: eval.c:312 msgid "buffer overflow in genflags2str" msgstr "genflags2str içinde tampon taÅŸtı" -#: eval.c:555 +#: eval.c:647 #, c-format msgid "for loop: array `%s' changed size from %ld to %ld during loop execution" msgstr "" "for loop: `%s' dizisinin boyu döngünün yorumlanması sırasında %ld iken %ld " "oldu" -#: eval.c:576 +#: eval.c:668 msgid "`break' outside a loop is not portable" msgstr "döngü dışında `break' kullanımı taşınabilir deÄŸil" -#: eval.c:580 +#: eval.c:672 msgid "`break' outside a loop is not allowed" msgstr "döngü dışında `break' kullanımı yasak" -#: eval.c:597 +#: eval.c:689 msgid "`continue' outside a loop is not portable" msgstr "döngü dışında `continue' kullanımı taşınabilir deÄŸil" -#: eval.c:601 +#: eval.c:693 msgid "`continue' outside a loop is not allowed" msgstr "döngü dışında `continue' kullanımı yasak" -#: eval.c:635 +#: eval.c:727 msgid "`next' cannot be called from a BEGIN rule" msgstr "`next' bir BEGIN kuralından çaÄŸrılamaz" -#: eval.c:637 +#: eval.c:729 msgid "`next' cannot be called from an END rule" msgstr "`next' bir END kuralından çaÄŸrılamaz" -#: eval.c:646 +#: eval.c:738 msgid "`nextfile' cannot be called from a BEGIN rule" msgstr "`nextfile' bir BEGIN kuralından çaÄŸrılamaz" -#: eval.c:648 +#: eval.c:740 msgid "`nextfile' cannot be called from an END rule" msgstr "`nextfile' bir END kuralından çaÄŸrılamaz" -#: eval.c:696 +#: eval.c:785 msgid "statement has no effect" msgstr "deyim etkisiz" -#: eval.c:731 eval.c:761 eval.c:1733 -#, c-format -msgid "reference to uninitialized variable `%s'" -msgstr "öndeÄŸer ataması yapılmamış `%s' deÄŸiÅŸkenine baÅŸvuru" - -#: eval.c:739 eval.c:1721 +#: eval.c:828 eval.c:1726 #, c-format msgid "can't use function name `%s' as variable or array" msgstr "`%s' iÅŸlev ismi bir deÄŸiÅŸken ya da dizi olarak kullanılamaz" -#: eval.c:746 eval.c:752 +#: eval.c:835 eval.c:841 #, c-format msgid "reference to uninitialized argument `%s'" msgstr "baÅŸlangıç deÄŸeri olmayan `%s' argümanına baÅŸvuru" -#: eval.c:810 eval.c:1728 profile.c:773 +#: eval.c:848 eval.c:907 eval.c:1732 eval.c:1742 profile.c:807 #, c-format msgid "attempt to use array `%s' in a scalar context" msgstr "`%s' dizisi bir sayısal baÄŸlamda kullanılmaya çalışılıyor" -#: eval.c:910 +#: eval.c:858 eval.c:1752 +#, c-format +msgid "reference to uninitialized variable `%s'" +msgstr "öndeÄŸer ataması yapılmamış `%s' deÄŸiÅŸkenine baÅŸvuru" + +#: eval.c:1007 msgid "" "concatenation: side effects in one expression have changed the length of " "another!" msgstr "" "bitiÅŸtirme: bir ifadenin yan etkileri diÄŸerinin uzunluÄŸunu deÄŸiÅŸtirmiÅŸ!" -#: eval.c:935 +#: eval.c:1032 msgid "assignment used in conditional context" msgstr "koÅŸul baÄŸlamında atama yapılmış" -#: eval.c:1026 +#: eval.c:1122 msgid "division by zero attempted" msgstr "sıfırla bölme hatası" -#: eval.c:1041 +#: eval.c:1137 #, c-format msgid "division by zero attempted in `%%'" msgstr "`%%'de sıfırla bölme hatası" -#: eval.c:1056 profile.c:649 +#: eval.c:1152 profile.c:683 #, c-format msgid "illegal type (%s) in tree_eval" msgstr "tree_eval içinde kuraldışı tür (%s)" -#: eval.c:1232 +#: eval.c:1328 msgid "division by zero attempted in `/='" msgstr "`/='de sıfırla bölme hatası" -#: eval.c:1250 +#: eval.c:1346 #, c-format msgid "division by zero attempted in `%%='" msgstr "`%%='de sıfırla bölme hatası" -#: eval.c:1510 -#, c-format -msgid "%s (from %s)" -msgstr "%s (%s'den)" - -#: eval.c:1569 +#: eval.c:1586 #, c-format msgid "function `%s' called with more arguments than declared" msgstr "`%s' iÅŸlevi bildirilenden daha fazla argümanla çaÄŸrıldı" -#: eval.c:1628 +#: eval.c:1633 #, c-format msgid "function `%s' not defined" msgstr "`%s' iÅŸlevi tanımsız" -#: eval.c:1634 +#: eval.c:1639 #, c-format msgid "function %s called\n" msgstr "%s iÅŸlevi çaÄŸrıldı\n" -#: eval.c:1693 +#: eval.c:1698 msgid "" "\n" "\t# Function Call Stack:\n" @@ -841,46 +857,41 @@ "\t# İşlev ÇaÄŸrı Yığını:\n" "\n" -#: eval.c:1696 +#: eval.c:1701 msgid "\t# -- main --\n" msgstr "\t# -- main --\n" -#: eval.c:1850 +#: eval.c:1867 msgid "attempt to field reference from non-numeric value" msgstr "sayısal olmayan deÄŸerden alan baÅŸvurusu" -#: eval.c:1852 +#: eval.c:1869 msgid "attempt to reference from null string" msgstr "null dizgeden alan baÅŸvurusu" -#: eval.c:1858 +#: eval.c:1875 #, c-format msgid "attempt to access field %d" msgstr "%d. alana eriÅŸilmeye çalışılıyor" -#: eval.c:1874 -#, c-format -msgid "attempt to use scalar parameter `%s' as an array" -msgstr "sayısal paramaetre `%s' bir dizi olarak kullanılmaya çalışılıyor" - -#: eval.c:1886 eval.c:1893 profile.c:865 +#: eval.c:1896 eval.c:1903 profile.c:900 msgid "assignment is not allowed to result of builtin function" msgstr "deÄŸiÅŸken ismine yerleÅŸik iÅŸlevin sonucu atanamaz" -#: eval.c:1941 +#: eval.c:1951 msgid "`IGNORECASE' is a gawk extension" msgstr "`IGNORECASE' bir gawk uzantısıdır" -#: eval.c:1970 +#: eval.c:1980 msgid "`BINMODE' is a gawk extension" msgstr "`BINMODE' bir gawk uzantısıdır" -#: eval.c:2082 +#: eval.c:2092 #, c-format msgid "bad `%sFMT' specification `%s'" msgstr "`%sFMT' özelliÄŸi `%s' hatalı" -#: eval.c:2160 +#: eval.c:2170 msgid "turning off `--lint' due to assignment to `LINT'" msgstr "`LINT' atamasından dolayı `--lint' kapatılıyor" @@ -898,32 +909,32 @@ msgid "extension: library `%s': cannot call function `%s' (%s)\n" msgstr "extension: kitaplık `%s': `%s' iÅŸlevi çaÄŸrılamıyor (%s)\n" -#: ext.c:181 +#: ext.c:183 msgid "Operation Not Supported" msgstr "İşlem Desteklenmiyor" -#: field.c:321 +#: field.c:315 msgid "NF set to negative value" msgstr "NF negatif deÄŸere ayarlı" -#: field.c:819 +#: field.c:808 msgid "split: second argument is not an array" msgstr "split: ikinci argüman bir dizi deÄŸil" -#: field.c:854 +#: field.c:842 msgid "split: null string for third arg is a gawk extension" msgstr "split: üçüncü argüman olan null dizge bir gawk uzantısı" -#: field.c:906 +#: field.c:894 msgid "`FIELDWIDTHS' is a gawk extension" msgstr "`FIELDWIDTHS' bir gawk uzantısıdır" -#: field.c:933 +#: field.c:921 #, c-format msgid "field %d in FIELDWIDTHS, must be > 0" msgstr "FIELDWIDTHS içindeki %d. alan > 0 olmalı" -#: field.c:1006 +#: field.c:994 msgid "null string for `FS' is a gawk extension" msgstr "`FS' için null dizge bir gawk uzantısıdır" @@ -967,7 +978,7 @@ msgid "%s: invalid option -- %c\n" msgstr "%s: geçersiz seçenek -- %c\n" -#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:431 +#: getopt.c:962 getopt.c:973 getopt.c:1159 getopt.c:1172 main.c:434 #, c-format msgid "%s: option requires an argument -- %c\n" msgstr "%s: seçenek bir argümanla kullanılır -- %c\n" @@ -982,471 +993,471 @@ msgid "%s: option `-W %s' doesn't allow an argument\n" msgstr "%s: `-W %s' seçeneÄŸi argümansız kullanılır\n" -#: io.c:257 +#: io.c:305 #, c-format msgid "cannot open file `%s' for reading (%s)" msgstr "`%s' okumak için açılamıyor (%s)" -#: io.c:344 +#: io.c:392 #, c-format msgid "close of fd %d (`%s') failed (%s)" msgstr "dosya tanımlayıcı %d (`%s') baÅŸarısız (%s)" -#: io.c:482 +#: io.c:530 #, c-format msgid "invalid tree type %s in redirect()" msgstr "redirect() içindeki aÄŸaç türü %s geçersiz" -#: io.c:488 +#: io.c:536 #, c-format msgid "expression in `%s' redirection only has numeric value" msgstr "`%s' yönlendirmesi içindeki ifade sadece sayısal deÄŸer içeriyor" -#: io.c:494 +#: io.c:542 #, c-format msgid "expression for `%s' redirection has null string value" msgstr "`%s' yönlendirmesi içindeki ifade null dizge deÄŸeri içeriyor" -#: io.c:499 +#: io.c:547 #, c-format msgid "filename `%s' for `%s' redirection may be result of logical expression" msgstr "" "`%s' dosya ismi (`%s' yönlendirmesi için) mantıksal ifadenin sonucu olabilir" -#: io.c:521 +#: io.c:569 #, c-format msgid "unnecessary mixing of `>' and `>>' for file `%.*s'" msgstr "`%.*s' dosyası için `>' ve `>>' karışımı gereksiz" -#: io.c:573 +#: io.c:621 #, c-format msgid "can't open pipe `%s' for output (%s)" msgstr "`%s' veriyolu çıktı için açılamadı (%s)" -#: io.c:582 +#: io.c:630 #, c-format msgid "can't open pipe `%s' for input (%s)" msgstr "`%s' veriyolu girdi için açılamadı (%s)" -#: io.c:595 +#: io.c:643 #, c-format msgid "can't open two way socket `%s' for input/output (%s)" msgstr "iki yönlü `%s' soketi G/Ç için açılamıyor (%s)" -#: io.c:599 +#: io.c:647 #, c-format msgid "can't open two way pipe `%s' for input/output (%s)" msgstr "iki yönlü `%s' veriyolu G/Ç için açılamıyor (%s)" -#: io.c:675 +#: io.c:723 #, c-format msgid "can't redirect from `%s' (%s)" msgstr "`%s'den yönlendirilemiyor (%s)" -#: io.c:678 +#: io.c:726 #, c-format msgid "can't redirect to `%s' (%s)" msgstr "`%s'e yönlendirilemiyor (%s)" -#: io.c:717 +#: io.c:765 msgid "" "reached system limit for open files: starting to multiplex file descriptors" msgstr "" "açık dosyalar için sistem sınırı aşıldı: çoÄŸul dosya tanımlayıcılara " "baÅŸlarken" -#: io.c:729 +#: io.c:777 #, c-format msgid "close of `%s' failed (%s)." msgstr "`%s' kapatılamadı (%s)." -#: io.c:736 +#: io.c:784 msgid "too many pipes or input files open" msgstr "çok fazla veriyolu ya da dosya açık" -#: io.c:759 +#: io.c:807 msgid "close: second argument must be `to' or `from'" msgstr "close: ikinci argüman `to' ya da `from' olmalı" -#: io.c:773 +#: io.c:821 #, c-format msgid "close: `%.*s' is not an open file, pipe or co-process" msgstr "close: `%.*s' bir açık dosya, veriyolu ya da alt-iÅŸlem deÄŸil" -#: io.c:777 +#: io.c:825 msgid "close of redirection that was never opened" msgstr "hiç açılmamış bir yönlendirmenin kapatılması" -#: io.c:804 +#: io.c:862 #, c-format msgid "close: redirection `%s' not opened with `|&', second argument ignored" msgstr "" "close: `%s' yönlendirmesi bir `|&' ile açılmamış, ikinci argüman yoksayıldı" -#: io.c:866 +#: io.c:924 #, c-format msgid "failure status (%d) on pipe close of `%s' (%s)" msgstr "baÅŸarısızlık durumu (%d): `%s' veriyolunun kapatılması (%s)" -#: io.c:869 +#: io.c:927 #, c-format msgid "failure status (%d) on file close of `%s' (%s)" msgstr "baÅŸarısızlık durumu (%d): `%s' dosyasının kapatılması (%s)" -#: io.c:888 +#: io.c:946 #, c-format msgid "no explicit close of socket `%s' provided" msgstr "`%s' soketinin açıkça kapatılması istenmedi" -#: io.c:891 +#: io.c:949 #, c-format msgid "no explicit close of co-process `%s' provided" msgstr "`%s' alt-iÅŸleminin açıkça kapatılması istenmedi" -#: io.c:894 +#: io.c:952 #, c-format msgid "no explicit close of pipe `%s' provided" msgstr "`%s' veriyolunun açıkça kapatılması istenmedi" -#: io.c:897 +#: io.c:955 #, c-format msgid "no explicit close of file `%s' provided" msgstr "`%s' dosyasının açıkça kapatılması istenmedi" -#: io.c:926 io.c:980 +#: io.c:984 io.c:1038 #, c-format msgid "error writing standard output (%s)" msgstr "standart çıktıya yazarken hata (%s)" -#: io.c:930 io.c:984 +#: io.c:988 io.c:1042 #, c-format msgid "error writing standard error (%s)" msgstr "standart hataya yazarken hata (%s)" -#: io.c:938 +#: io.c:996 #, c-format msgid "pipe flush of `%s' failed (%s)." msgstr "`%s'in veriyolu ile veri aktarımı baÅŸarısız (%s)." -#: io.c:941 +#: io.c:999 #, c-format msgid "co-process flush of pipe to `%s' failed (%s)." msgstr "`%s'e veriyolunun alt-iÅŸlemi ile veri aktarımı baÅŸarısız (%s)." -#: io.c:944 +#: io.c:1002 #, c-format msgid "file flush of `%s' failed (%s)." msgstr "`%s'in dosya ile veri aktarımı baÅŸarısız (%s)." -#: io.c:1103 +#: io.c:1161 msgid "/inet/raw client not ready yet, sorry" msgstr "/inet/raw istemci henüz hazır deÄŸil" -#: io.c:1105 io.c:1142 +#: io.c:1163 io.c:1200 msgid "only root may use `/inet/raw'." msgstr "`/inet/raw' sadece root tarafından kullanılabilir" -#: io.c:1140 +#: io.c:1198 msgid "/inet/raw server not ready yet, sorry" msgstr "/inet/raw sunucu henüz hazır deÄŸil" -#: io.c:1230 +#: io.c:1288 #, c-format msgid "no (known) protocol supplied in special filename `%s'" msgstr "özel dosya ismi `%s' içinde (bilinen) bir protokol saÄŸlanmamış" -#: io.c:1248 +#: io.c:1306 #, c-format msgid "special file name `%s' is incomplete" msgstr "özel dosya ismi `%s' tamamlanmamış" -#: io.c:1260 +#: io.c:1318 #, c-format msgid "local port invalid in `%s'" msgstr "`%s' deki yerel port geçersiz" -#: io.c:1272 +#: io.c:1330 msgid "must supply a remote hostname to `/inet'" msgstr "`/inet' e bir karşı makina ismi saÄŸlanmalı" -#: io.c:1287 +#: io.c:1345 msgid "must supply a remote port to `/inet'" msgstr "`/inet' e bir karşı port saÄŸlanmalı" -#: io.c:1293 +#: io.c:1351 #, c-format msgid "remote port invalid in `%s'" msgstr "`%s' de karşı port geçersiz" -#: io.c:1303 +#: io.c:1361 msgid "TCP/IP communications are not supported" msgstr "TCP/IP haberleÅŸmesi desteklenmiyor" -#: io.c:1312 io.c:1492 +#: io.c:1370 io.c:1551 #, c-format msgid "file `%s' is a directory" msgstr "`%s' dosya deÄŸil dizin" -#: io.c:1381 +#: io.c:1440 #, c-format msgid "use `PROCINFO[\"%s\"]' instead of `%s'" msgstr "`PROCINFO[\"%s\"]' kullanın (`%s' yerine)" -#: io.c:1413 +#: io.c:1472 msgid "use `PROCINFO[...]' instead of `/dev/user'" msgstr "`/dev/user' yerine `PROCINFO[...]' kullanın" -#: io.c:1478 io.c:1652 +#: io.c:1537 io.c:1711 #, c-format msgid "could not open `%s', mode `%s'" msgstr "`%s', `%s' kipinde açılamadı" -#: io.c:1703 +#: io.c:1762 #, c-format msgid "close of master pty failed (%s)" msgstr "ana pty kapatılamadı (%s)" -#: io.c:1705 io.c:1857 io.c:2009 +#: io.c:1764 io.c:1916 io.c:2068 #, c-format msgid "close of stdout in child failed (%s)" msgstr "ast süreçte stdÇ kapatılamadı (%s)" -#: io.c:1708 +#: io.c:1767 #, c-format msgid "moving slave pty to stdout in child failed (dup: %s)" msgstr "ast süreçte yardımcı pty standart çıktıya taşınamadı (dup: %s)" -#: io.c:1710 io.c:1862 +#: io.c:1769 io.c:1921 #, c-format msgid "close of stdin in child failed (%s)" msgstr "ast süreçte stdG kapatılamadı (%s)" -#: io.c:1713 +#: io.c:1772 #, c-format msgid "moving slave pty to stdin in child failed (dup: %s)" msgstr "ast süreçte yardımcı pty standart girdiye taşınamadı (dup: %s)" -#: io.c:1715 io.c:1734 +#: io.c:1774 io.c:1793 #, c-format msgid "close of slave pty failed (%s)" msgstr "yardımcı pty kapatılamadı (%s)" -#: io.c:1808 io.c:1860 io.c:1990 io.c:2012 +#: io.c:1867 io.c:1919 io.c:2049 io.c:2071 #, c-format msgid "moving pipe to stdout in child failed (dup: %s)" msgstr "ast süreçte veriyolu standart çıktıya taşınamadı (dup: %s)" -#: io.c:1812 io.c:1865 +#: io.c:1871 io.c:1924 #, c-format msgid "moving pipe to stdin in child failed (dup: %s)" msgstr "ast süreçte veriyolu standart girdiye taşınamadı (dup: %s)" -#: io.c:1829 io.c:2003 +#: io.c:1888 io.c:2062 msgid "restoring stdout in parent process failed\n" msgstr "üst süreçte stdÇ eski durumuna getirilemedi\n" -#: io.c:1834 +#: io.c:1893 msgid "restoring stdin in parent process failed\n" msgstr "üst süreçte stdG eski durumuna getirilemedi\n" -#: io.c:1868 io.c:2014 io.c:2025 +#: io.c:1927 io.c:2073 io.c:2084 #, c-format msgid "close of pipe failed (%s)" msgstr "veriyolu kapatılamadı (%s)" -#: io.c:1913 +#: io.c:1972 msgid "`|&' not supported" msgstr "`|&' desteklenmiyor" -#: io.c:1980 +#: io.c:2039 #, c-format msgid "cannot open pipe `%s' (%s)" msgstr "`%s' veriyolu açılamıyor (%s)" -#: io.c:2021 +#: io.c:2080 #, c-format msgid "cannot create child process for `%s' (fork: %s)" msgstr "`%s' için ast süreç oluÅŸturulamıyor (fork: %s)" -#: io.c:2364 +#: io.c:2423 #, c-format msgid "data file `%s' is empty" msgstr "veri dosyası `%s' boÅŸ" -#: io.c:2407 io.c:2415 +#: io.c:2466 io.c:2474 msgid "could not allocate more input memory" -msgstr "" +msgstr "daha fazla girdi belleÄŸi ayrılamadı" -#: io.c:2540 io.c:2782 io.c:3046 +#: io.c:2832 io.c:2895 #, c-format msgid "error reading input file `%s': %s" msgstr "`%s' girdi dosyası okunurken hata: %s" -#: io.c:3281 +#: io.c:3020 msgid "multicharacter value of `RS' is a gawk extension" msgstr "`RS' çoklu karakter deÄŸeri bir gawk uzantısıdır" -#: main.c:322 +#: main.c:324 msgid "`-m[fr]' option irrelevant in gawk" msgstr "`-m[fr]' seçeneÄŸi gawk'da böyle kullanılmaz" -#: main.c:324 +#: main.c:326 msgid "-m option usage: `-m[fr] nnn'" msgstr "-m seçeneÄŸinin kullanımı: `-m[fr] nnn'" -#: main.c:341 +#: main.c:343 #, c-format msgid "%s: option `-W %s' unrecognized, ignored\n" msgstr "%s: `-W %s' seçeneÄŸi tanımlı deÄŸil, yok sayıldı\n" -#: main.c:378 +#: main.c:380 msgid "empty argument to `--source' ignored" msgstr "`--source' seçeneÄŸi için boÅŸ argüman yoksayıldı" -#: main.c:448 +#: main.c:451 msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'" msgstr "ortam deÄŸiÅŸkeni `POSIXLY_CORRECT' var: `--posix' kullanılıyor" -#: main.c:453 +#: main.c:456 msgid "`--posix' overrides `--traditional'" msgstr "`--posix' seçeneÄŸi `--traditional' seçeneÄŸini etkisiz kılar" -#: main.c:464 +#: main.c:467 msgid "`--posix'/`--traditional' overrides `--non-decimal-data'" msgstr "" "`--posix'/`--traditional' seçenekleri `--non-decimal-data' seçeneÄŸini " "etkisiz kılar" -#: main.c:468 +#: main.c:471 #, c-format msgid "running %s setuid root may be a security problem" msgstr "%s root yetkileriyle çalıştırıldığında güvenlik sorunları olabilir" -#: main.c:509 +#: main.c:512 #, c-format msgid "can't set binary mode on stdin (%s)" msgstr "standart girdi ikilik kipe ayarlanamaz (%s)" -#: main.c:512 +#: main.c:515 #, c-format msgid "can't set binary mode on stdout (%s)" msgstr "standart çıktı ikilik kipe ayarlanamaz (%s)" -#: main.c:514 +#: main.c:517 #, c-format msgid "can't set binary mode on stderr (%s)" msgstr "standart hata ikilik kipe ayarlanamaz (%s)" -#: main.c:544 +#: main.c:547 msgid "no program text at all!" msgstr "program metni hiç yok!" -#: main.c:612 +#: main.c:620 #, c-format msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n" msgstr "" "Kullanımı: %s [POSIX veya GNU tarzı seçenekler] -f progdosyası [--] " "dosya ...\n" -#: main.c:614 +#: main.c:622 #, c-format msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n" msgstr "" "Kullanımı: %s [POSIX veya GNU tarzı seçenekler] %cprogram%c dosya ...\n" -#: main.c:619 +#: main.c:627 msgid "POSIX options:\t\tGNU long options:\n" msgstr "POSIX seçenekleri: GNU uzun seçenekleri:\n" -#: main.c:620 +#: main.c:628 msgid "\t-f progfile\t\t--file=progfile\n" msgstr " -f progDosyası --file=progDosyası\n" -#: main.c:621 +#: main.c:629 msgid "\t-F fs\t\t\t--field-separator=fs\n" msgstr " -F ayraç --field-separator=ayraç\n" -#: main.c:622 +#: main.c:630 msgid "\t-v var=val\t\t--assign=var=val\n" msgstr " -v var=deÄŸer --assign=var=deÄŸer\n" -#: main.c:623 +#: main.c:631 msgid "\t-m[fr] val\n" msgstr " -m[fr] deÄŸer\n" -#: main.c:624 +#: main.c:632 msgid "\t-W compat\t\t--compat\n" msgstr " -W compat --compat\n" -#: main.c:625 +#: main.c:633 msgid "\t-W copyleft\t\t--copyleft\n" msgstr " -W copyleft --copyleft\n" -#: main.c:626 +#: main.c:634 msgid "\t-W copyright\t\t--copyright\n" msgstr " -W copyright --copyright\n" -#: main.c:627 +#: main.c:635 msgid "\t-W dump-variables[=file]\t--dump-variables[=file]\n" msgstr " -W dump-variables[=dosya] --dump-variables[=dosya]\n" -#: main.c:628 +#: main.c:636 msgid "\t-W gen-po\t\t--gen-po\n" msgstr " -W gen-po --gen-po\n" -#: main.c:629 +#: main.c:637 msgid "\t-W help\t\t\t--help\n" msgstr " -W help --help\n" -#: main.c:630 +#: main.c:638 msgid "\t-W lint[=fatal]\t\t--lint[=fatal]\n" msgstr " -W lint[=ölümcül] --lint[=ölümcül]\n" -#: main.c:631 +#: main.c:639 msgid "\t-W lint-old\t\t--lint-old\n" msgstr " -W lint-old --lint-old\n" -#: main.c:632 +#: main.c:640 msgid "\t-W non-decimal-data\t--non-decimal-data\n" msgstr " -W non-decimal-data --non-decimal-data\n" -#: main.c:634 +#: main.c:642 msgid "\t-W nostalgia\t\t--nostalgia\n" msgstr " -W nostalgia --nostalgia\n" -#: main.c:637 +#: main.c:645 msgid "\t-W parsedebug\t\t--parsedebug\n" msgstr " -W parsedebug --parsedebug\n" -#: main.c:639 +#: main.c:647 msgid "\t-W profile[=file]\t--profile[=file]\n" msgstr " -W profile[=dosya] --profile[=dosya]\n" -#: main.c:640 +#: main.c:648 msgid "\t-W posix\t\t--posix\n" msgstr " -W posix --posix\n" -#: main.c:641 +#: main.c:649 msgid "\t-W re-interval\t\t--re-interval\n" msgstr " -W re-interval --re-interval\n" -#: main.c:642 +#: main.c:650 msgid "\t-W source=program-text\t--source=program-text\n" msgstr " -W source=program-metni --source=program-metni\n" -#: main.c:643 +#: main.c:651 msgid "\t-W traditional\t\t--traditional\n" msgstr " -W traditional --traditional\n" -#: main.c:644 +#: main.c:652 msgid "\t-W usage\t\t--usage\n" msgstr " -W usage --usage\n" -#: main.c:645 +#: main.c:653 msgid "\t-W version\t\t--version\n" msgstr " -W version --version\n" -#: main.c:649 +#: main.c:657 msgid "" "\n" "To report bugs, see node `Bugs' in `gawk.info', which is\n" @@ -1460,7 +1471,7 @@ "Çeviri hatalarını adresine bildiriniz.\n" "\n" -#: main.c:653 +#: main.c:661 msgid "" "gawk is a pattern scanning and processing language.\n" "By default it reads standard input and writes standard output.\n" @@ -1470,7 +1481,7 @@ "Öntanımlı olarak standart girdiyi okur ve standart çıktıya yazar.\n" "\n" -#: main.c:657 +#: main.c:665 msgid "" "Examples:\n" "\tgawk '{ sum += $1 }; END { print sum }' file\n" @@ -1480,7 +1491,7 @@ "\tgawk '{ sum += $1 }; END { print sum }' dosya\n" "\tgawk -F: '{ print $1 }' /etc/passwd\n" -#: main.c:669 +#: main.c:682 #, c-format msgid "" "Copyright (C) 1989, 1991-%d Free Software Foundation.\n" @@ -1499,7 +1510,7 @@ "üzerinde deÄŸiÅŸiklik yapabilirsiniz.\n" "\n" -#: main.c:677 +#: main.c:690 msgid "" "This program is distributed in the hope that it will be useful,\n" "but WITHOUT ANY WARRANTY; without even the implied warranty of\n" @@ -1513,7 +1524,7 @@ "edinmek için GNU Genel Kamu Lisansına bakınız.\n" "\n" -#: main.c:683 +#: main.c:696 msgid "" "You should have received a copy of the GNU General Public License\n" "along with this program; if not, write to the Free Software\n" @@ -1523,11 +1534,11 @@ "olacaksınız; yoksa Free Software Foundation, Inc., 59 Temple Place\n" "Suite 330, Boston, MA 02111-1307, USA. adresinden isteyebilirsiniz.\n" -#: main.c:713 +#: main.c:730 msgid "-Ft does not set FS to tab in POSIX awk" msgstr "POSIX awk -Ft ile dosya sistemini belirlemez" -#: main.c:944 +#: main.c:956 #, c-format msgid "" "%s: `%s' argument to `-v' not in `var=value' form\n" @@ -1536,35 +1547,35 @@ "%s: `-v' ile verilen `%s' argümanı `var=deÄŸer' biçiminde deÄŸil\n" "\n" -#: main.c:964 +#: main.c:976 #, c-format msgid "`%s' is not a legal variable name" msgstr "`%s' kurala uygun bir deÄŸiÅŸken ismi deÄŸil" -#: main.c:967 +#: main.c:979 #, c-format msgid "`%s' is not a variable name, looking for file `%s=%s'" msgstr "`%2$s=%3$s' için dosyaya bakınca, `%1$s' bir deÄŸiÅŸken ismi deÄŸil" -#: main.c:995 +#: main.c:1012 msgid "floating point exception" msgstr "Gerçel sayı istisnası" -#: main.c:1002 +#: main.c:1019 msgid "fatal error: internal error" msgstr "ölümcül iç hata" -#: main.c:1052 +#: main.c:1069 #, c-format msgid "no pre-opened fd %d" msgstr "ön açılışlı bir %d dosya tanımlayıcısı yok" -#: main.c:1057 +#: main.c:1074 #, c-format msgid "could not pre-open /dev/null for fd %d" msgstr "%d dosya tanımlayıcısı için /dev/null ön açılışı yapılamadı" -#: main.c:1080 main.c:1089 +#: main.c:1097 main.c:1106 #, c-format msgid "could not find groups: %s" msgstr "gruplar bulunamadı: %s" @@ -1585,23 +1596,23 @@ msgid "fatal: " msgstr "ölümcül: " -#: node.c:59 node.c:66 node.c:75 node.c:89 node.c:116 +#: node.c:58 node.c:65 node.c:74 node.c:88 node.c:115 msgid "can't convert string to float" msgstr "dizge gerçel sayıya dönüştürülemiyor" -#: node.c:357 +#: node.c:355 msgid "backslash at end of string" msgstr "dizge sonunda tersbölü" -#: node.c:544 +#: node.c:539 msgid "POSIX does not allow `\\x' escapes" msgstr "POSIX `\\x' öncelemelerine izin vermez" -#: node.c:550 +#: node.c:545 msgid "no hex digits in `\\x' escape sequence" msgstr "`\\x' önceleme dizgesinde onaltılık rakamlar yok" -#: node.c:584 +#: node.c:579 #, c-format msgid "escape sequence `\\%c' treated as plain `%c'" msgstr "`\\%c' önceleme dizgesi `%c' olarak kullanıldı" @@ -1616,24 +1627,21 @@ msgid "could not open `%s' for writing: %s" msgstr "`%s' yazmak için açılamadı: %s" -#: profile.c:409 -msgid "internal error: Node_var with null vname" -msgstr "iç hata: null vname'li node_var" +#: profile.c:449 +#, c-format +msgid "internal error: %s with null vname" +msgstr "iç hata: null vname'li %s" -#: profile.c:471 +#: profile.c:512 msgid "# treated internally as `delete'" msgstr "# dahili olarak `delete' varsayıldı" -#: profile.c:545 -msgid "internal error: Node_var_array with null vname" -msgstr "iç hata: null vname'li node_var_array" - -#: profile.c:1127 +#: profile.c:1162 #, c-format msgid "\t# gawk profile, created %s\n" msgstr "\t# gawk profili, oluÅŸturuldu: %s\n" -#: profile.c:1130 +#: profile.c:1165 msgid "" "\t# BEGIN block(s)\n" "\n" @@ -1641,7 +1649,7 @@ "\t# BEGIN blokları\n" "\n" -#: profile.c:1140 +#: profile.c:1175 msgid "" "\t# Rule(s)\n" "\n" @@ -1649,7 +1657,7 @@ "\t# Kurallar\n" "\n" -#: profile.c:1146 +#: profile.c:1181 msgid "" "\t# END block(s)\n" "\n" @@ -1657,7 +1665,7 @@ "\t# END blokları\n" "\n" -#: profile.c:1166 +#: profile.c:1201 msgid "" "\n" "\t# Functions, listed alphabetically\n" @@ -1665,7 +1673,7 @@ "\n" "\t# İşlevler, alfabetik sırayla\n" -#: profile.c:1376 +#: profile.c:1413 #, c-format msgid "unexpected type %s in prec_level" msgstr "prec_level'da anlaşılamayan tür %s" @@ -1749,6 +1757,21 @@ msgid "No previous regular expression" msgstr "Daha önce düzenli ifade yok" +#~ msgid "substr: length %g is < 0" +#~ msgstr "substr: uzunluk %g < 0" + +#~ msgid "delete: illegal use of variable `%s' as array" +#~ msgstr "delete: `%s' deÄŸiÅŸkeninin dizi olarak kullanımı kuraldışı" + +#~ msgid "asort: first argument is not an array" +#~ msgstr "asort: ilk argüman bir dizi deÄŸil" + +#~ msgid "asort: second argument is not an array" +#~ msgstr "asort: ikinci argüman bir dizi deÄŸil" + +#~ msgid "internal error: Node_var_array with null vname" +#~ msgstr "iç hata: null vname'li node_var_array" + #~ msgid "invalid syntax in name `%s' for variable assignment" #~ msgstr "deÄŸiÅŸken ismi `%s' de sözdizimi hatası" diff -urN gawk-3.1.2/posix/ChangeLog gawk-3.1.3/posix/ChangeLog --- gawk-3.1.2/posix/ChangeLog 2003-03-19 04:23:34.000000000 -0800 +++ gawk-3.1.3/posix/ChangeLog 2003-07-07 11:02:40.000000000 -0700 @@ -1,3 +1,11 @@ +Mon Jul 7 11:01:43 2003 Arnold D. Robbins + + * Release 3.1.3: Release tar file made. + +Sun May 25 16:23:43 2003 Corinna Vinschen + + * gawkmisc.c (cygwin_premain0): New function. + Wed Mar 19 14:10:31 2003 Arnold D. Robbins This time for sure. diff -urN gawk-3.1.2/posix/gawkmisc.c gawk-3.1.3/posix/gawkmisc.c --- gawk-3.1.2/posix/gawkmisc.c 2003-03-06 01:26:20.000000000 -0800 +++ gawk-3.1.3/posix/gawkmisc.c 2003-05-25 06:26:19.000000000 -0700 @@ -219,3 +219,20 @@ /* no-op */ return; } + +#ifdef __CYGWIN__ +#include + +extern int _fmode; +void +cygwin_premain0 (int argc, char **argv, struct per_process *myself) +{ + static struct __cygwin_perfile pf[] = + { + {"", O_RDONLY | O_TEXT}, + /*{"", O_WRONLY | O_BINARY},*/ + {NULL, 0} + }; + cygwin_internal (CW_PERFILE, pf); +} +#endif diff -urN gawk-3.1.2/profile.c gawk-3.1.3/profile.c --- gawk-3.1.2/profile.c 2003-02-28 00:47:00.000000000 -0800 +++ gawk-3.1.3/profile.c 2003-06-08 07:26:46.000000000 -0700 @@ -250,6 +250,44 @@ fprintf(prof_fp, "}\n"); break; + case Node_K_switch: + indent(tree->exec_count); + fprintf(prof_fp, "switch ("); + in_expr++; + pprint(tree->lnode); + in_expr--; + fprintf(prof_fp, ") {\n"); + pprint(tree->rnode); + indent(SPACEOVER); + fprintf(prof_fp, "}\n"); + break; + + case Node_switch_body: + case Node_case_list: + pprint(tree->lnode); + pprint(tree->rnode); + break; + + case Node_K_case: + indent(tree->exec_count); + fprintf(prof_fp, "case "); + in_expr++; + pprint(tree->lnode); + in_expr--; + fprintf(prof_fp, ":\n"); + indent_in(); + pprint(tree->rnode); + indent_out(); + break; + + case Node_K_default: + indent(tree->exec_count); + fprintf(prof_fp, "default:\n"); + indent_in(); + pprint(tree->rnode); + indent_out(); + break; + case Node_K_while: indent(tree->exec_count); fprintf(prof_fp, "while ("); @@ -402,11 +440,14 @@ fprintf(prof_fp, "%s", fparms[tree->param_cnt]); return; + case Node_var_new: case Node_var: + case Node_var_array: if (tree->vname != NULL) fprintf(prof_fp, "%s", tree->vname); else - fatal(_("internal error: Node_var with null vname")); + fatal(_("internal error: %s with null vname"), + nodetype2str(tree->type)); return; case Node_val: @@ -538,13 +579,6 @@ pp_lhs(tree); return; - case Node_var_array: - if (tree->vname != NULL) - fprintf(prof_fp, "%s", tree->vname); - else - fatal(_("internal error: Node_var_array with null vname")); - return; - case Node_unary_minus: fprintf(prof_fp, " -"); if (is_scalar(tree->subnode->type)) @@ -773,6 +807,7 @@ fatal(_("attempt to use array `%s' in a scalar context"), ptr->vname); + case Node_var_new: case Node_var: fprintf(prof_fp, "%s", ptr->vname); break; @@ -1254,6 +1289,7 @@ is_scalar(NODETYPE type) { switch (type) { + case Node_var_new: case Node_var: case Node_var_array: case Node_val: @@ -1284,6 +1320,7 @@ prec_level(NODETYPE type) { switch (type) { + case Node_var_new: case Node_var: case Node_var_array: case Node_param_list: diff -urN gawk-3.1.2/re.c gawk-3.1.3/re.c --- gawk-3.1.2/re.c 2003-02-24 03:28:17.000000000 -0800 +++ gawk-3.1.3/re.c 2003-06-18 00:05:40.000000000 -0700 @@ -318,3 +318,38 @@ return FALSE; } + +/* reflags2str --- make a regex flags value readable */ + +const char * +reflags2str(int flagval) +{ + static const struct flagtab values[] = { + { RE_BACKSLASH_ESCAPE_IN_LISTS, "RE_BACKSLASH_ESCAPE_IN_LISTS" }, + { RE_BK_PLUS_QM, "RE_BK_PLUS_QM" }, + { RE_CHAR_CLASSES, "RE_CHAR_CLASSES" }, + { RE_CONTEXT_INDEP_ANCHORS, "RE_CONTEXT_INDEP_ANCHORS" }, + { RE_CONTEXT_INDEP_OPS, "RE_CONTEXT_INDEP_OPS" }, + { RE_CONTEXT_INVALID_OPS, "RE_CONTEXT_INVALID_OPS" }, + { RE_DOT_NEWLINE, "RE_DOT_NEWLINE" }, + { RE_DOT_NOT_NULL, "RE_DOT_NOT_NULL" }, + { RE_HAT_LISTS_NOT_NEWLINE, "RE_HAT_LISTS_NOT_NEWLINE" }, + { RE_INTERVALS, "RE_INTERVALS" }, + { RE_LIMITED_OPS, "RE_LIMITED_OPS" }, + { RE_NEWLINE_ALT, "RE_NEWLINE_ALT" }, + { RE_NO_BK_BRACES, "RE_NO_BK_BRACES" }, + { RE_NO_BK_PARENS, "RE_NO_BK_PARENS" }, + { RE_NO_BK_REFS, "RE_NO_BK_REFS" }, + { RE_NO_BK_VBAR, "RE_NO_BK_VBAR" }, + { RE_NO_EMPTY_RANGES, "RE_NO_EMPTY_RANGES" }, + { RE_UNMATCHED_RIGHT_PAREN_ORD, "RE_UNMATCHED_RIGHT_PAREN_ORD" }, + { RE_NO_POSIX_BACKTRACKING, "RE_NO_POSIX_BACKTRACKING" }, + { RE_NO_GNU_OPS, "RE_NO_GNU_OPS" }, + { RE_DEBUG, "RE_DEBUG" }, + { RE_INVALID_INTERVAL_ORD, "RE_INVALID_INTERVAL_ORD" }, + { RE_ICASE, "RE_ICASE" }, + { 0, NULL }, + }; + + return genflags2str(flagval, values); +} diff -urN gawk-3.1.2/regex.c gawk-3.1.3/regex.c --- gawk-3.1.2/regex.c 2003-03-19 03:45:30.000000000 -0800 +++ gawk-3.1.3/regex.c 2003-05-11 05:21:17.000000000 -0700 @@ -48,6 +48,11 @@ /* POSIX says that must be included (by the caller) before . */ #include + +#if defined (_MSC_VER) +#include /* for size_t */ +#endif + #include #include #include "regex_internal.h" diff -urN gawk-3.1.2/test/ChangeLog gawk-3.1.3/test/ChangeLog --- gawk-3.1.2/test/ChangeLog 2003-03-19 04:56:02.000000000 -0800 +++ gawk-3.1.3/test/ChangeLog 2003-07-07 11:02:44.000000000 -0700 @@ -1,3 +1,97 @@ +Mon Jul 7 11:01:43 2003 Arnold D. Robbins + + * Release 3.1.3: Release tar file made. + +Fri Jul 4 11:12:07 2003 Arnold D. Robbins + + * Makefile.am (poundbang2): Removed. + (poundbang): Added env var settings. + +Thu Jun 26 15:44:33 2003 Arnold D. Robbins + + * Makefile.am (match2, whiny): new test. + * match2.awk, match2.ok: new files. + * whiny.awk, whiny.ok: new files. + +Thu Jun 26 14:51:40 2003 Arnold D. Robbins + + * Makefile.am: Use double quotes for sed invocation to make + life easier (eventually) for DOS version of Makefile. + * pipeio2.awk, pipio2.ok: Ditto. + +Wed Jun 18 12:32:14 2003 Arnold D. Robbins + + * Makefile.am (AWK): Use LC_ALL=$${GAWKLOCALE:-C} and + same for LANG when running awk. Provides sane locale for + tests with ability to override it if need be. + (all tests): Removed explicit setting of LC_ALL and LANG. + * Gentests: Ditto. + +Wed May 28 08:02:33 CEST 2003 Stepan Kasal + + * Makefile.am (uninit4): new test. + * uninit4.awk, uninit4.ok: new files. + +Wed May 28 06:30:23 2003 Stepan Kasal + + * Makefile.am (aryprm4 aryprm5 aryprm6 aryprm7 aryprm8 scalar uninit3): + new tests. + * aryprm4.awk aryprm4.ok aryprm5.awk aryprm5.ok aryprm6.awk aryprm6.ok: + aryprm7.awk aryprm7.ok aryprm8.awk aryprm8.ok scalar.awk scalar.ok: + uninit3.awk uninit3.ok: new files. + +Tue May 27 14:27:50 2003 Stepan Kasal + + * Makefile.am (aryprm1, aryprm2, aryprm3, sortempty): New tests. + * aryprm1.awk, aryprm1.ok, aryprm2.awk, aryprm2.ok: New files. + * aryprm3.awk, aryprm3.ok, sortempty.awk, sortempty.ok: dtto + * prmarscl.ok: The actual error message has changed. + +Tue May 27 08:23:51 2003 Stepan Kasal + + * arrayref3.ok, arrayref4.ok, fnaryscl.ok: Error messages reformatted. + +Sun Jun 8 17:18:06 2003 Arnold D. Robbins + + * Makefile.am (fmttest, strtonum, nested, gsubtst5, delarpm2): New tests. + * fmttest.awk, fmttest.ok: New files. From Nelson Beebe, + . + * strtonum.awk, strtonum.ok: New files. + * nested.awk, nested.in, nested.ok: New files. + * gsubtst5.awk, gsubtst5.in, gsubtst5.ok: New files. + * delarpm2.awk, delarpm2.ok: New files. (Also from Nelson Beebe.) + + * switch2.awk: Currently unused test for switch code. + +Wed May 14 16:49:53 2003 Arnold D. Robbins + + * Gentests: Add LC_ALL=C LANG=C to generated tests. + * Makefile.am: All other manual tests: ditto. + +Sun May 11 15:27:55 2003 Stepan Kasal + + * Makefile.am (rsnulbig, rsnulbig2): New tests. + * rsnulbig.ok, rsnulbig2.ok: New files. + +Sun May 11 15:00:20 2003 Arnold D. Robbins + + * Makefile.am (arrayprm2, arrayprm3, arryref2, arryref3, arryref4, + arryref5, rstest3, rstest4, rstest5): New tests. + * arrayprm2.awk, arrayprm2.ok, arrayprm3.awk, arrayprm3.ok, arryref2.ok, + arryref3.ok, arryref4.ok, arryref5.ok, rstest3.awk, rstest3.ok, rstest4.awk, + rstest4.ok, rstest5.awk, rstest5.ok: New files. + +Sun May 11 12:20:59 2003 Arnold D. Robbins + + * strftime.awk: Remove seconds from input and strftime output, + to decrease chance of failing on second boundary. + * Makefile.am (strftime): Tweak message appropriately. + +Tue Mar 25 08:35:42 2003 Arnold D. Robbins + + * Makefile.am (fnarray2): New test. + * fnarray2.awk, fnarray2.ok: New files. + Wed Mar 19 14:10:31 2003 Arnold D. Robbins This time for sure. @@ -18,7 +112,7 @@ 2003-02-17 Jim Meyering * Makefile.am (check): Don't depend on the pass-fail rule that - reports any failures. Otherwise, `make -j' that rule's commands + reports any failures. Otherwise, for `make -j' that rule's commands could run before all tests had completed, resulting in spurious failures or potentially, even unreported failures. Instead, just `$(MAKE) pass-fail'. diff -urN gawk-3.1.2/test/Makefile.am gawk-3.1.3/test/Makefile.am --- gawk-3.1.2/test/Makefile.am 2003-03-19 04:20:30.000000000 -0800 +++ gawk-3.1.3/test/Makefile.am 2003-07-04 11:11:59.000000000 -0700 @@ -42,17 +42,45 @@ argtest.ok \ arrayparm.awk \ arrayparm.ok \ + arrayprm2.awk \ + arrayprm2.ok \ + arrayprm3.awk \ + arrayprm3.ok \ arrayref.awk \ arrayref.ok \ + arrymem1.awk \ + arrymem1.ok \ + arryref2.awk \ + arryref2.ok \ + arryref3.awk \ + arryref3.ok \ + arryref4.awk \ + arryref4.ok \ + arryref5.awk \ + arryref5.ok \ arynasty.awk \ arynasty.ok \ arynocls.awk \ arynocls.in \ arynocls.ok \ + aryprm1.awk \ + aryprm1.ok \ + aryprm2.awk \ + aryprm2.ok \ + aryprm3.awk \ + aryprm3.ok \ + aryprm4.awk \ + aryprm4.ok \ + aryprm5.awk \ + aryprm5.ok \ + aryprm6.awk \ + aryprm6.ok \ + aryprm7.awk \ + aryprm7.ok \ + aryprm8.awk \ + aryprm8.ok \ arysubnm.awk \ arysubnm.ok \ - arrymem1.awk \ - arrymem1.ok \ asgext.awk \ asgext.in \ asgext.ok \ @@ -95,6 +123,8 @@ defref.ok \ delarprm.awk \ delarprm.ok \ + delarpm2.awk \ + delarpm2.ok \ dynlj.awk \ dynlj.ok \ eofsplit.awk \ @@ -110,11 +140,15 @@ fldchgnf.awk \ fldchgnf.in \ fldchgnf.ok \ + fmttest.awk \ + fmttest.ok \ fnamedat.awk \ fnamedat.in \ fnamedat.ok \ fnarray.awk \ fnarray.ok \ + fnarray2.awk \ + fnarray2.ok \ fnarydel.awk \ fnarydel.ok \ fnaryscl.awk \ @@ -183,6 +217,9 @@ gsubtst3.ok \ gsubtst4.awk \ gsubtst4.ok \ + gsubtst5.awk \ + gsubtst5.in \ + gsubtst5.ok \ gtlnbufv.awk \ hsprint.awk \ hsprint.ok \ @@ -227,6 +264,8 @@ manyfiles.ok \ match1.awk \ match1.ok \ + match2.awk \ + match2.ok \ math.awk \ math.ok \ membug1.awk \ @@ -242,6 +281,9 @@ nasty2.ok \ negexp.awk \ negexp.ok \ + nested.awk \ + nested.in \ + nested.ok \ nfldstr.awk \ nfldstr.in \ nfldstr.ok \ @@ -339,6 +381,7 @@ printf1.awk \ printf1.ok \ printfloat.awk \ + printlang.awk \ prmarscl.awk \ prmarscl.ok \ prmreuse.awk \ @@ -387,13 +430,23 @@ rsnul1nl.awk \ rsnul1nl.in \ rsnul1nl.ok \ + rsnulbig.ok \ + rsnulbig2.ok \ rstest1.awk \ rstest1.ok \ rstest2.awk \ rstest2.ok \ + rstest3.awk \ + rstest3.ok \ + rstest4.awk \ + rstest4.ok \ + rstest5.awk \ + rstest5.ok \ rswhite.awk \ rswhite.in \ rswhite.ok \ + scalar.awk \ + scalar.ok \ sclforin.awk \ sclforin.ok \ sclifin.awk \ @@ -402,6 +455,8 @@ shadow.ok \ sort1.awk \ sort1.ok \ + sortempty.awk \ + sortempty.ok \ space.ok \ splitargv.awk \ splitargv.in \ @@ -421,6 +476,8 @@ strtod.awk \ strtod.in \ strtod.ok \ + strtonum.awk \ + strtonum.ok \ strftime.awk \ strftlng.awk \ strftlng.ok \ @@ -431,6 +488,7 @@ swaplns.awk \ swaplns.in \ swaplns.ok \ + switch2.awk \ synerr1.awk \ synerr1.ok \ tradanch.awk \ @@ -439,59 +497,75 @@ tweakfld.awk \ tweakfld.in \ tweakfld.ok \ - uninitialized.awk \ - uninitialized.ok \ uninit2.awk \ uninit2.ok \ + uninit3.awk \ + uninit3.ok \ + uninit4.awk \ + uninit4.ok \ + uninitialized.awk \ + uninitialized.ok \ + whiny.awk \ + whiny.in \ + whiny.ok \ zeroe0.awk \ zeroe0.ok \ zeroflag.awk \ zeroflag.ok # try to keep these sorted -BASIC_TESTS = addcomma anchgsub argarray arrayparm arrayref arrymem1 arynasty \ - arynocls arysubnm asgext awkpath back89 backgsub childin clobber \ - clsflnam compare compare2 concat1 convfmt datanonl defref delarprm \ - dynlj eofsplit fldchg fldchgnf fnamedat fnarray fnarydel fnaryscl \ - fnasgnm fnmisc fnparydl forsimp fsbs fsrs fstabplus funsemnl funsmnam \ - funstack getline getline2 getline3 getlnbuf getnr2tb getnr2tm gsubasgn gsubtest \ - gsubtst2 gsubtst3 gsubtst4 hsprint inputred intest intprec leaddig leadnl \ - litoct longsub longwrds math membug1 messages minusstr mmap8k \ - nasty nasty2 negexp nfldstr nfneg nfset nlfldsep nlinstr nlstrina \ - noeffect nofmtch noloop1 noloop2 nonl noparms nors nulrsend \ - numindex numsubstr octsub ofmt ofmtbig ofmtfidl ofmts onlynl \ - opasnidx opasnslf paramdup paramtyp parseme pcntplus prdupval prec \ - printf0 printf1 prmarscl prmreuse prt1eval prtoeval psx96sub rand rebt8b1 \ - rebt8b2 redfilnm regeq reindops reparse resplit rs rsnul1nl \ - rstest1 rstest2 rswhite sclforin sclifin splitargv splitarr splitdef \ - splitvar splitwht sprintfc strtod subslash substr swaplns synerr1 \ - tradanch tweakfld uninitialized uninit2 zeroe0 zeroflag +BASIC_TESTS = addcomma anchgsub argarray arrayparm arrayref arrymem1 \ + arrayprm2 arrayprm3 arryref2 arryref3 arryref4 arryref5 arynasty \ + arynocls aryprm1 aryprm2 aryprm3 aryprm4 aryprm5 aryprm6 aryprm7 \ + aryprm8 arysubnm asgext awkpath back89 backgsub childin clobber \ + clsflnam compare compare2 concat1 convfmt datanonl defref \ + delarprm delarpm2 dynlj eofsplit fldchg fldchgnf fmttest fnamedat \ + fnarray fnarray2 fnarydel fnaryscl fnasgnm fnmisc fnparydl \ + forsimp fsbs fsrs fstabplus funsemnl funsmnam funstack getline \ + getline2 getline3 getlnbuf getnr2tb getnr2tm gsubasgn gsubtest \ + gsubtst2 gsubtst3 gsubtst4 gsubtst5 hsprint inputred intest \ + intprec leaddig leadnl litoct longsub longwrds math membug1 \ + messages minusstr mmap8k nasty nasty2 negexp nested nfldstr \ + nfneg nfset nlfldsep nlinstr nlstrina noeffect nofmtch noloop1 \ + noloop2 nonl noparms nors nulrsend numindex numsubstr octsub ofmt \ + ofmtbig ofmtfidl ofmts onlynl opasnidx opasnslf paramdup paramtyp \ + parseme pcntplus prdupval prec printf0 printf1 prmarscl prmreuse \ + prt1eval prtoeval psx96sub rand rebt8b1 rebt8b2 redfilnm regeq \ + reindops reparse resplit rs rsnul1nl rsnulbig rsnulbig2 rstest1 \ + rstest2 rstest3 rstest4 rstest5 rswhite scalar sclforin sclifin \ + sortempty splitargv splitarr splitdef splitvar splitwht sprintfc \ + strtod subslash substr swaplns synerr1 tradanch tweakfld uninit2 \ + uninit3 uninit4 uninitialized zeroe0 zeroflag UNIX_TESTS = fflush getlnhd pid pipeio1 pipeio2 poundbang space strftlng GAWK_EXT_TESTS = argtest asort asorti badargs clos1way fieldwdth fsfwfs \ gensub gnuops2 gnureops icasefs icasers igncdym igncfs ignrcase lint \ - match1 manyfiles nondec posix procinfs regx8bit rebuf reint shadow \ - sort1 strftime + match1 match2 manyfiles nondec posix procinfs regx8bit rebuf reint \ + shadow sort1 strtonum strftime whiny EXTRA_TESTS = regtest inftest INET_TESTS = inetechu inetecht inetdayu inetdayt # List of the tests which should be run with --lint option: -NEED_LINT = defref noeffect nofmtch shadow uninitialized uninit2 +NEED_LINT = defref noeffect nofmtch shadow uninit2 uninit3 uninit4 uninitialized # List of the files that appear in manual tests or are for reserve testing: -GENTESTS_UNUSED = Makefile.in gtlnbufv.awk printfloat.awk +GENTESTS_UNUSED = Makefile.in gtlnbufv.awk printfloat.awk switch2.awk CMP = cmp AWKPROG = ../gawk$(EXEEXT) -AWK = LC_ALL=C $(AWKPROG) + +# This business forces the locale to be C for running the tests, +# unless we override it to something else for testing. +AWK = LC_ALL=$${GAWKLOCALE:-C} LANG=$${GAWKLOCALE:-C} $(AWKPROG) # Message stuff is to make it a little easier to follow. # Make the pass-fail last and dependent on others to avoid # spurious errors if `make -j' in effect. check: msg \ + printlang \ basic-msg-start basic basic-msg-end \ unix-msg-start unix-tests unix-msg-end \ extend-msg-start gawk-extensions extend-msg-end @@ -514,6 +588,9 @@ @echo 'some systems may omit a leading zero and the floating point' @echo 'precision may lead to slightly different output in a few cases.' +printlang:: + @$(AWK) -f $(srcdir)/printlang.awk + basic-msg-start: @echo "======== Starting basic tests ========" @@ -547,7 +624,7 @@ else \ sed "s;/tmp/gawk;../$(AWKPROG);" < $(srcdir)/poundbang.awk > ./_pbd.awk ; \ chmod +x ./_pbd.awk ; \ - ./_pbd.awk $(srcdir)/poundbang.awk > _`basename $@`; \ + LC_ALL=$${GAWKLOCALE:-C} LANG=$${GAWKLOCALE:-C} ./_pbd.awk $(srcdir)/poundbang.awk > _`basename $@`; \ fi @-$(CMP) $(srcdir)/poundbang.awk _`basename $@` && rm -f _`basename $@` _pbd.awk @@ -581,7 +658,7 @@ @mkdir junk @$(AWK) 'BEGIN { for (i = 1; i <= 300; i++) print i, i}' >_$@ @$(AWK) -f $(srcdir)/manyfiles.awk _$@ _$@ - @wc -l junk/* | $(AWK) '$$1 != 2' | wc -l | sed 's/ *//g' > _$@ + @wc -l junk/* | $(AWK) '$$1 != 2' | wc -l | sed "s/ *//g" > _$@ @rm -rf junk ; $(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ compare:: @@ -592,7 +669,7 @@ inftest:: @echo $@ @echo This test is very machine specific... - @$(AWK) -f $(srcdir)/inftest.awk | sed 's/inf/Inf/g' >_$@ + @$(AWK) -f $(srcdir)/inftest.awk | sed "s/inf/Inf/g" >_$@ @-$(CMP) $(srcdir)/inftest.ok _$@ && rm -f _$@ getline2:: @@ -621,7 +698,7 @@ @-$(CMP) $(srcdir)/nonl.ok _$@ && rm -f _$@ strftime:: - @echo This test could fail on slow machines or on a second boundary, + @echo This test could fail on slow machines or on a minute boundary, @echo so if it does, double check the actual results: @echo $@ @LC_ALL=C; export LC_ALL; LANG=C; export LANG; \ @@ -659,7 +736,7 @@ # command so that pid.sh is fork'ed as a child before being exec'ed. pid:: @echo pid - @AWKPATH=$(srcdir) AWK=$(AWKPROG) LC_ALL=C $(SHELL) $(srcdir)/pid.sh $$$$ > _`basename $@` ; : + @AWKPATH=$(srcdir) AWK=$(AWKPROG) $(SHELL) $(srcdir)/pid.sh $$$$ > _`basename $@` ; : @-$(CMP) $(srcdir)/pid.ok _`basename $@` && rm -f _`basename $@` _`basename $@`.in strftlng:: @@ -756,6 +833,27 @@ @$(AWK) --posix -f $(srcdir)/$@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +rsnulbig:: + @echo $@ + @ : Suppose that block size for pipe is at most 128kB: + @$(AWK) 'BEGIN { for (i = 1; i <= 128*64+1; i++) print "abcdefgh123456\n" }' 2>&1 | \ + $(AWK) 'BEGIN { RS = ""; ORS = "\n\n" }; { print }' 2>&1 | \ + $(AWK) '/^[^a]/; END{ print NR }' >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +rsnulbig2:: + @echo $@ + @$(AWK) 'BEGIN { ORS = ""; n = "\n"; for (i = 1; i <= 10; i++) n = (n n); \ + for (i = 1; i <= 128; i++) print n; print "abc\n" }' 2>&1 | \ + $(AWK) 'BEGIN { RS = ""; ORS = "\n\n" };{ print }' 2>&1 | \ + $(AWK) '/^[^a]/; END { print NR }' >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +whiny:: + @echo $@ + @WHINY_USERS=1 $(AWK) -f $(srcdir)/$@.awk $(srcdir)/$@.in >_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + # Targets generated for other tests: include Maketests diff -urN gawk-3.1.2/test/Makefile.in gawk-3.1.3/test/Makefile.in --- gawk-3.1.2/test/Makefile.in 2003-03-19 04:20:47.000000000 -0800 +++ gawk-3.1.3/test/Makefile.in 2003-07-04 11:12:47.000000000 -0700 @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.7.3 from Makefile.am. +# Makefile.in generated by automake 1.7.5 from Makefile.am. # @configure_input@ # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 @@ -67,7 +67,10 @@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ -AWK = LC_ALL=C $(AWKPROG) + +# This business forces the locale to be C for running the tests, +# unless we override it to something else for testing. +AWK = LC_ALL=$${GAWKLOCALE:-C} LANG=$${GAWKLOCALE:-C} $(AWKPROG) BUILD_INCLUDED_LIBINTL = @BUILD_INCLUDED_LIBINTL@ CATOBJEXT = @CATOBJEXT@ CC = @CC@ @@ -184,17 +187,45 @@ argtest.ok \ arrayparm.awk \ arrayparm.ok \ + arrayprm2.awk \ + arrayprm2.ok \ + arrayprm3.awk \ + arrayprm3.ok \ arrayref.awk \ arrayref.ok \ + arrymem1.awk \ + arrymem1.ok \ + arryref2.awk \ + arryref2.ok \ + arryref3.awk \ + arryref3.ok \ + arryref4.awk \ + arryref4.ok \ + arryref5.awk \ + arryref5.ok \ arynasty.awk \ arynasty.ok \ arynocls.awk \ arynocls.in \ arynocls.ok \ + aryprm1.awk \ + aryprm1.ok \ + aryprm2.awk \ + aryprm2.ok \ + aryprm3.awk \ + aryprm3.ok \ + aryprm4.awk \ + aryprm4.ok \ + aryprm5.awk \ + aryprm5.ok \ + aryprm6.awk \ + aryprm6.ok \ + aryprm7.awk \ + aryprm7.ok \ + aryprm8.awk \ + aryprm8.ok \ arysubnm.awk \ arysubnm.ok \ - arrymem1.awk \ - arrymem1.ok \ asgext.awk \ asgext.in \ asgext.ok \ @@ -237,6 +268,8 @@ defref.ok \ delarprm.awk \ delarprm.ok \ + delarpm2.awk \ + delarpm2.ok \ dynlj.awk \ dynlj.ok \ eofsplit.awk \ @@ -252,11 +285,15 @@ fldchgnf.awk \ fldchgnf.in \ fldchgnf.ok \ + fmttest.awk \ + fmttest.ok \ fnamedat.awk \ fnamedat.in \ fnamedat.ok \ fnarray.awk \ fnarray.ok \ + fnarray2.awk \ + fnarray2.ok \ fnarydel.awk \ fnarydel.ok \ fnaryscl.awk \ @@ -325,6 +362,9 @@ gsubtst3.ok \ gsubtst4.awk \ gsubtst4.ok \ + gsubtst5.awk \ + gsubtst5.in \ + gsubtst5.ok \ gtlnbufv.awk \ hsprint.awk \ hsprint.ok \ @@ -369,6 +409,8 @@ manyfiles.ok \ match1.awk \ match1.ok \ + match2.awk \ + match2.ok \ math.awk \ math.ok \ membug1.awk \ @@ -384,6 +426,9 @@ nasty2.ok \ negexp.awk \ negexp.ok \ + nested.awk \ + nested.in \ + nested.ok \ nfldstr.awk \ nfldstr.in \ nfldstr.ok \ @@ -481,6 +526,7 @@ printf1.awk \ printf1.ok \ printfloat.awk \ + printlang.awk \ prmarscl.awk \ prmarscl.ok \ prmreuse.awk \ @@ -529,13 +575,23 @@ rsnul1nl.awk \ rsnul1nl.in \ rsnul1nl.ok \ + rsnulbig.ok \ + rsnulbig2.ok \ rstest1.awk \ rstest1.ok \ rstest2.awk \ rstest2.ok \ + rstest3.awk \ + rstest3.ok \ + rstest4.awk \ + rstest4.ok \ + rstest5.awk \ + rstest5.ok \ rswhite.awk \ rswhite.in \ rswhite.ok \ + scalar.awk \ + scalar.ok \ sclforin.awk \ sclforin.ok \ sclifin.awk \ @@ -544,6 +600,8 @@ shadow.ok \ sort1.awk \ sort1.ok \ + sortempty.awk \ + sortempty.ok \ space.ok \ splitargv.awk \ splitargv.in \ @@ -563,6 +621,8 @@ strtod.awk \ strtod.in \ strtod.ok \ + strtonum.awk \ + strtonum.ok \ strftime.awk \ strftlng.awk \ strftlng.ok \ @@ -573,6 +633,7 @@ swaplns.awk \ swaplns.in \ swaplns.ok \ + switch2.awk \ synerr1.awk \ synerr1.ok \ tradanch.awk \ @@ -581,10 +642,17 @@ tweakfld.awk \ tweakfld.in \ tweakfld.ok \ - uninitialized.awk \ - uninitialized.ok \ uninit2.awk \ uninit2.ok \ + uninit3.awk \ + uninit3.ok \ + uninit4.awk \ + uninit4.ok \ + uninitialized.awk \ + uninitialized.ok \ + whiny.awk \ + whiny.in \ + whiny.ok \ zeroe0.awk \ zeroe0.ok \ zeroflag.awk \ @@ -592,31 +660,36 @@ # try to keep these sorted -BASIC_TESTS = addcomma anchgsub argarray arrayparm arrayref arrymem1 arynasty \ - arynocls arysubnm asgext awkpath back89 backgsub childin clobber \ - clsflnam compare compare2 concat1 convfmt datanonl defref delarprm \ - dynlj eofsplit fldchg fldchgnf fnamedat fnarray fnarydel fnaryscl \ - fnasgnm fnmisc fnparydl forsimp fsbs fsrs fstabplus funsemnl funsmnam \ - funstack getline getline2 getline3 getlnbuf getnr2tb getnr2tm gsubasgn gsubtest \ - gsubtst2 gsubtst3 gsubtst4 hsprint inputred intest intprec leaddig leadnl \ - litoct longsub longwrds math membug1 messages minusstr mmap8k \ - nasty nasty2 negexp nfldstr nfneg nfset nlfldsep nlinstr nlstrina \ - noeffect nofmtch noloop1 noloop2 nonl noparms nors nulrsend \ - numindex numsubstr octsub ofmt ofmtbig ofmtfidl ofmts onlynl \ - opasnidx opasnslf paramdup paramtyp parseme pcntplus prdupval prec \ - printf0 printf1 prmarscl prmreuse prt1eval prtoeval psx96sub rand rebt8b1 \ - rebt8b2 redfilnm regeq reindops reparse resplit rs rsnul1nl \ - rstest1 rstest2 rswhite sclforin sclifin splitargv splitarr splitdef \ - splitvar splitwht sprintfc strtod subslash substr swaplns synerr1 \ - tradanch tweakfld uninitialized uninit2 zeroe0 zeroflag +BASIC_TESTS = addcomma anchgsub argarray arrayparm arrayref arrymem1 \ + arrayprm2 arrayprm3 arryref2 arryref3 arryref4 arryref5 arynasty \ + arynocls aryprm1 aryprm2 aryprm3 aryprm4 aryprm5 aryprm6 aryprm7 \ + aryprm8 arysubnm asgext awkpath back89 backgsub childin clobber \ + clsflnam compare compare2 concat1 convfmt datanonl defref \ + delarprm delarpm2 dynlj eofsplit fldchg fldchgnf fmttest fnamedat \ + fnarray fnarray2 fnarydel fnaryscl fnasgnm fnmisc fnparydl \ + forsimp fsbs fsrs fstabplus funsemnl funsmnam funstack getline \ + getline2 getline3 getlnbuf getnr2tb getnr2tm gsubasgn gsubtest \ + gsubtst2 gsubtst3 gsubtst4 gsubtst5 hsprint inputred intest \ + intprec leaddig leadnl litoct longsub longwrds math membug1 \ + messages minusstr mmap8k nasty nasty2 negexp nested nfldstr \ + nfneg nfset nlfldsep nlinstr nlstrina noeffect nofmtch noloop1 \ + noloop2 nonl noparms nors nulrsend numindex numsubstr octsub ofmt \ + ofmtbig ofmtfidl ofmts onlynl opasnidx opasnslf paramdup paramtyp \ + parseme pcntplus prdupval prec printf0 printf1 prmarscl prmreuse \ + prt1eval prtoeval psx96sub rand rebt8b1 rebt8b2 redfilnm regeq \ + reindops reparse resplit rs rsnul1nl rsnulbig rsnulbig2 rstest1 \ + rstest2 rstest3 rstest4 rstest5 rswhite scalar sclforin sclifin \ + sortempty splitargv splitarr splitdef splitvar splitwht sprintfc \ + strtod subslash substr swaplns synerr1 tradanch tweakfld uninit2 \ + uninit3 uninit4 uninitialized zeroe0 zeroflag UNIX_TESTS = fflush getlnhd pid pipeio1 pipeio2 poundbang space strftlng GAWK_EXT_TESTS = argtest asort asorti badargs clos1way fieldwdth fsfwfs \ gensub gnuops2 gnureops icasefs icasers igncdym igncfs ignrcase lint \ - match1 manyfiles nondec posix procinfs regx8bit rebuf reint shadow \ - sort1 strftime + match1 match2 manyfiles nondec posix procinfs regx8bit rebuf reint \ + shadow sort1 strtonum strftime whiny EXTRA_TESTS = regtest inftest @@ -624,14 +697,15 @@ INET_TESTS = inetechu inetecht inetdayu inetdayt # List of the tests which should be run with --lint option: -NEED_LINT = defref noeffect nofmtch shadow uninitialized uninit2 +NEED_LINT = defref noeffect nofmtch shadow uninit2 uninit3 uninit4 uninitialized # List of the files that appear in manual tests or are for reserve testing: -GENTESTS_UNUSED = Makefile.in gtlnbufv.awk printfloat.awk +GENTESTS_UNUSED = Makefile.in gtlnbufv.awk printfloat.awk switch2.awk CMP = cmp AWKPROG = ../gawk$(EXEEXT) subdir = test +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = @@ -641,7 +715,7 @@ all: all-am .SUFFIXES: -$(srcdir)/Makefile.in: Makefile.am $(srcdir)/Maketests $(top_srcdir)/configure.in $(ACLOCAL_M4) +$(srcdir)/Makefile.in: Makefile.am $(srcdir)/Maketests $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && \ $(AUTOMAKE) --gnu test/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @@ -690,7 +764,6 @@ all-am: Makefile installdirs: - install: install-am install-exec: install-exec-am install-data: install-data-am @@ -773,6 +846,7 @@ # Make the pass-fail last and dependent on others to avoid # spurious errors if `make -j' in effect. check: msg \ + printlang \ basic-msg-start basic basic-msg-end \ unix-msg-start unix-tests unix-msg-end \ extend-msg-start gawk-extensions extend-msg-end @@ -795,6 +869,9 @@ @echo 'some systems may omit a leading zero and the floating point' @echo 'precision may lead to slightly different output in a few cases.' +printlang:: + @$(AWK) -f $(srcdir)/printlang.awk + basic-msg-start: @echo "======== Starting basic tests ========" @@ -827,7 +904,7 @@ else \ sed "s;/tmp/gawk;../$(AWKPROG);" < $(srcdir)/poundbang.awk > ./_pbd.awk ; \ chmod +x ./_pbd.awk ; \ - ./_pbd.awk $(srcdir)/poundbang.awk > _`basename $@`; \ + LC_ALL=$${GAWKLOCALE:-C} LANG=$${GAWKLOCALE:-C} ./_pbd.awk $(srcdir)/poundbang.awk > _`basename $@`; \ fi @-$(CMP) $(srcdir)/poundbang.awk _`basename $@` && rm -f _`basename $@` _pbd.awk @@ -861,7 +938,7 @@ @mkdir junk @$(AWK) 'BEGIN { for (i = 1; i <= 300; i++) print i, i}' >_$@ @$(AWK) -f $(srcdir)/manyfiles.awk _$@ _$@ - @wc -l junk/* | $(AWK) '$$1 != 2' | wc -l | sed 's/ *//g' > _$@ + @wc -l junk/* | $(AWK) '$$1 != 2' | wc -l | sed "s/ *//g" > _$@ @rm -rf junk ; $(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ compare:: @@ -872,7 +949,7 @@ inftest:: @echo $@ @echo This test is very machine specific... - @$(AWK) -f $(srcdir)/inftest.awk | sed 's/inf/Inf/g' >_$@ + @$(AWK) -f $(srcdir)/inftest.awk | sed "s/inf/Inf/g" >_$@ @-$(CMP) $(srcdir)/inftest.ok _$@ && rm -f _$@ getline2:: @@ -901,7 +978,7 @@ @-$(CMP) $(srcdir)/nonl.ok _$@ && rm -f _$@ strftime:: - @echo This test could fail on slow machines or on a second boundary, + @echo This test could fail on slow machines or on a minute boundary, @echo so if it does, double check the actual results: @echo $@ @LC_ALL=C; export LC_ALL; LANG=C; export LANG; \ @@ -939,7 +1016,7 @@ # command so that pid.sh is fork'ed as a child before being exec'ed. pid:: @echo pid - @AWKPATH=$(srcdir) AWK=$(AWKPROG) LC_ALL=C $(SHELL) $(srcdir)/pid.sh $$$$ > _`basename $@` ; : + @AWKPATH=$(srcdir) AWK=$(AWKPROG) $(SHELL) $(srcdir)/pid.sh $$$$ > _`basename $@` ; : @-$(CMP) $(srcdir)/pid.ok _`basename $@` && rm -f _`basename $@` _`basename $@`.in strftlng:: @@ -1035,6 +1112,27 @@ @echo $@ @$(AWK) --posix -f $(srcdir)/$@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +rsnulbig:: + @echo $@ + @ : Suppose that block size for pipe is at most 128kB: + @$(AWK) 'BEGIN { for (i = 1; i <= 128*64+1; i++) print "abcdefgh123456\n" }' 2>&1 | \ + $(AWK) 'BEGIN { RS = ""; ORS = "\n\n" }; { print }' 2>&1 | \ + $(AWK) '/^[^a]/; END{ print NR }' >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +rsnulbig2:: + @echo $@ + @$(AWK) 'BEGIN { ORS = ""; n = "\n"; for (i = 1; i <= 10; i++) n = (n n); \ + for (i = 1; i <= 128; i++) print n; print "abc\n" }' 2>&1 | \ + $(AWK) 'BEGIN { RS = ""; ORS = "\n\n" };{ print }' 2>&1 | \ + $(AWK) '/^[^a]/; END { print NR }' >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +whiny:: + @echo $@ + @WHINY_USERS=1 $(AWK) -f $(srcdir)/$@.awk $(srcdir)/$@.in >_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ Gt-dummy: # file Maketests, generated from Makefile.am by the Gentests program addcomma: @@ -1062,11 +1160,81 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +arrayprm2: + @echo arrayprm2 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arrayprm3: + @echo arrayprm3 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arryref2: + @echo arryref2 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arryref3: + @echo arryref3 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arryref4: + @echo arryref4 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arryref5: + @echo arryref5 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + arynasty: @echo arynasty @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +aryprm1: + @echo aryprm1 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm2: + @echo aryprm2 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm3: + @echo aryprm3 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm4: + @echo aryprm4 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm5: + @echo aryprm5 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm6: + @echo aryprm6 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm7: + @echo aryprm7 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm8: + @echo aryprm8 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + arysubnm: @echo arysubnm @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -1127,6 +1295,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +delarpm2: + @echo delarpm2 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + dynlj: @echo dynlj @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -1147,6 +1320,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +fmttest: + @echo fmttest + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + fnamedat: @echo fnamedat @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -1157,6 +1335,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +fnarray2: + @echo fnarray2 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + fnarydel: @echo fnarydel @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -1257,6 +1440,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +gsubtst5: + @echo gsubtst5 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + hsprint: @echo hsprint @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -1322,6 +1510,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +nested: + @echo nested + @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + nfldstr: @echo nfldstr @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -1547,11 +1740,31 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +rstest3: + @echo rstest3 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +rstest4: + @echo rstest4 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +rstest5: + @echo rstest5 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + rswhite: @echo rswhite @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +scalar: + @echo scalar + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + sclforin: @echo sclforin @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -1562,6 +1775,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +sortempty: + @echo sortempty + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + splitargv: @echo splitargv @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -1617,13 +1835,23 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ -uninitialized: - @echo uninitialized +uninit2: + @echo uninit2 @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ -uninit2: - @echo uninit2 +uninit3: + @echo uninit3 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +uninit4: + @echo uninit4 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +uninitialized: + @echo uninitialized @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ @@ -1717,6 +1945,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +match2: + @echo match2 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + nondec: @echo nondec @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -1752,6 +1985,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +strtonum: + @echo strtonum + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + # end of file Maketests # Targets generated for other tests: diff -urN gawk-3.1.2/test/Maketests gawk-3.1.3/test/Maketests --- gawk-3.1.2/test/Maketests 2003-03-19 04:20:44.000000000 -0800 +++ gawk-3.1.3/test/Maketests 2003-07-04 11:12:44.000000000 -0700 @@ -25,11 +25,81 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +arrayprm2: + @echo arrayprm2 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arrayprm3: + @echo arrayprm3 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arryref2: + @echo arryref2 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arryref3: + @echo arryref3 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arryref4: + @echo arryref4 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +arryref5: + @echo arryref5 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + arynasty: @echo arynasty @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +aryprm1: + @echo aryprm1 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm2: + @echo aryprm2 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm3: + @echo aryprm3 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm4: + @echo aryprm4 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm5: + @echo aryprm5 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm6: + @echo aryprm6 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm7: + @echo aryprm7 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +aryprm8: + @echo aryprm8 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + arysubnm: @echo arysubnm @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -90,6 +160,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +delarpm2: + @echo delarpm2 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + dynlj: @echo dynlj @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -110,6 +185,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +fmttest: + @echo fmttest + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + fnamedat: @echo fnamedat @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -120,6 +200,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +fnarray2: + @echo fnarray2 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + fnarydel: @echo fnarydel @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -220,6 +305,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +gsubtst5: + @echo gsubtst5 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + hsprint: @echo hsprint @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -285,6 +375,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +nested: + @echo nested + @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + nfldstr: @echo nfldstr @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -510,11 +605,31 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +rstest3: + @echo rstest3 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +rstest4: + @echo rstest4 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +rstest5: + @echo rstest5 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + rswhite: @echo rswhite @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +scalar: + @echo scalar + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + sclforin: @echo sclforin @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -525,6 +640,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +sortempty: + @echo sortempty + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + splitargv: @echo splitargv @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -580,13 +700,23 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ -uninitialized: - @echo uninitialized +uninit2: + @echo uninit2 @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ -uninit2: - @echo uninit2 +uninit3: + @echo uninit3 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +uninit4: + @echo uninit4 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + +uninitialized: + @echo uninitialized @AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ @@ -680,6 +810,11 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +match2: + @echo match2 + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + nondec: @echo nondec @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @@ -715,4 +850,9 @@ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ +strtonum: + @echo strtonum + @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ + # end of file Maketests diff -urN gawk-3.1.2/test/arrayprm2.awk gawk-3.1.3/test/arrayprm2.awk --- gawk-3.1.2/test/arrayprm2.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/arrayprm2.awk 2003-05-11 04:46:32.000000000 -0700 @@ -0,0 +1,67 @@ +# From spcecdt@armory.com Wed Apr 30 11:08:48 2003 +# Return-Path: +# Received: from localhost (skeeve [127.0.0.1]) +# by skeeve.com (8.12.5/8.12.5) with ESMTP id h3U7uZWr015489 +# for ; Wed, 30 Apr 2003 11:08:48 +0300 +# Received: from actcom.co.il [192.114.47.1] +# by localhost with POP3 (fetchmail-5.9.0) +# for arnold@localhost (single-drop); Wed, 30 Apr 2003 11:08:48 +0300 (IDT) +# Received: by actcom.co.il (mbox arobbins) +# (with Cubic Circle's cucipop (v1.31 1998/05/13) Wed Apr 30 11:05:01 2003) +# X-From_: spcecdt@armory.com Wed Apr 30 04:06:46 2003 +# Received: from smtp1.actcom.net.il by actcom.co.il with ESMTP +# (8.11.6/actcom-0.2) id h3U16iv04111 for ; +# Wed, 30 Apr 2003 04:06:45 +0300 (EET DST) +# (rfc931-sender: mail.actcom.co.il [192.114.47.13]) +# Received: from f7.net (consort.superb.net [209.61.216.22]) +# by smtp1.actcom.net.il (8.12.8/8.12.8) with ESMTP id h3U16nEv009589 +# for ; Wed, 30 Apr 2003 04:06:50 +0300 +# Received: from fencepost.gnu.org (fencepost.gnu.org [199.232.76.164]) +# by f7.net (8.11.7/8.11.6) with ESMTP id h3U16gj29182 +# for ; Tue, 29 Apr 2003 21:06:42 -0400 +# Received: from monty-python.gnu.org ([199.232.76.173]) +# by fencepost.gnu.org with esmtp (Exim 4.10) +# id 19Ag3W-00029w-00 +# for bug-gawk@gnu.org; Tue, 29 Apr 2003 21:06:42 -0400 +# Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10.13) +# id 19Ag1V-0001AN-00 +# for bug-gawk@gnu.org; Tue, 29 Apr 2003 21:04:39 -0400 +# Received: from deepthought.armory.com ([192.122.209.42] helo=armory.com) +# by monty-python.gnu.org with smtp (Exim 4.10.13) +# id 19Ag1V-0001A3-00 +# for bug-gawk@gnu.org; Tue, 29 Apr 2003 21:04:37 -0400 +# Date: Tue, 29 Apr 2003 18:04:35 -0700 +# From: "John H. DuBois III" +# To: bug-gawk@gnu.org +# Subject: gawk 3.1.2a bug +# Message-ID: <20030430010434.GA4278@armory.com> +# Mime-Version: 1.0 +# Content-Type: text/plain; charset=us-ascii +# Content-Disposition: inline +# User-Agent: Mutt/1.3.28i +# X-Www: http://www.armory.com./~spcecdt/ +# Sender: spcecdt@armory.com +# X-Spam-Status: No, hits=-7.2 required=5.0 +# tests=SIGNATURE_SHORT_DENSE,SPAM_PHRASE_00_01,USER_AGENT, +# USER_AGENT_MUTT +# version=2.41 +# X-Spam-Level: +# X-SpamBouncer: 1.4 (10/07/01) +# X-SBClass: OK +# Status: RO +# +# gawk-3.1.2a 'BEGIN {foo(bar)};function foo(baz){split("x",baz)}' +# gawk-3.1.2a: cmd. line:1: fatal: split: second argument is not an array +# +# John +# -- +# John DuBois spcecdt@armory.com KC6QKZ/AE http://www.armory.com/~spcecdt/ +# +BEGIN { + foo(bar) +} + +function foo(baz) +{ + split("x", baz) +} diff -urN gawk-3.1.2/test/arrayprm3.awk gawk-3.1.3/test/arrayprm3.awk --- gawk-3.1.2/test/arrayprm3.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/arrayprm3.awk 2003-05-11 04:48:22.000000000 -0700 @@ -0,0 +1,56 @@ +# From spcecdt@armory.com Fri May 2 13:24:46 2003 +# Return-Path: +# Received: from localhost (skeeve [127.0.0.1]) +# by skeeve.com (8.12.5/8.12.5) with ESMTP id h42AChum021950 +# for ; Fri, 2 May 2003 13:24:46 +0300 +# Received: from actcom.co.il [192.114.47.1] +# by localhost with POP3 (fetchmail-5.9.0) +# for arnold@localhost (single-drop); Fri, 02 May 2003 13:24:46 +0300 (IDT) +# Received: by actcom.co.il (mbox arobbins) +# (with Cubic Circle's cucipop (v1.31 1998/05/13) Fri May 2 13:23:37 2003) +# X-From_: spcecdt@armory.com Fri May 2 00:43:51 2003 +# Received: from smtp1.actcom.net.il by actcom.co.il with ESMTP +# (8.11.6/actcom-0.2) id h41Lhm500217 for ; +# Fri, 2 May 2003 00:43:49 +0300 (EET DST) +# (rfc931-sender: lmail.actcom.co.il [192.114.47.13]) +# Received: from f7.net (consort.superb.net [209.61.216.22]) +# by smtp1.actcom.net.il (8.12.8/8.12.8) with ESMTP id h41LiGcO022817 +# for ; Fri, 2 May 2003 00:44:18 +0300 +# Received: from armory.com (deepthought.armory.com [192.122.209.42]) +# by f7.net (8.11.7/8.11.6) with SMTP id h41Lhj106516 +# for ; Thu, 1 May 2003 17:43:46 -0400 +# Date: Thu, 1 May 2003 14:43:45 -0700 +# From: "John H. DuBois III" +# To: Aharon Robbins +# Subject: Re: gawk 3.1.2a bug +# Message-ID: <20030501214345.GA24615@armory.com> +# References: <200305011738.h41Hcg76017565@localhost.localdomain> +# Mime-Version: 1.0 +# Content-Type: text/plain; charset=us-ascii +# Content-Disposition: inline +# In-Reply-To: <200305011738.h41Hcg76017565@localhost.localdomain> +# User-Agent: Mutt/1.3.28i +# X-Www: http://www.armory.com./~spcecdt/ +# Sender: spcecdt@armory.com +# X-SpamBouncer: 1.4 (10/07/01) +# X-SBClass: OK +# Status: RO +# +# On Thu, May 01, 2003 at 08:38:42PM +0300, Aharon Robbins wrote: +# > > That worked, thanks. +# > +# > Great. Your report motivated me to find everywhere such additional +# > code ought to be needed. I think I did so. --Arnold +# +# Here's another one (perhaps fixed by your additional work): +# +BEGIN { foo(a) } +function foo(a) { bar(a); print "" in a } +function bar(a) { a[""]; } +# +# Prints 1 with gawk-3.1.1; 0 with 3.1.2a. +# +# John +# -- +# John DuBois spcecdt@armory.com KC6QKZ/AE http://www.armory.com/~spcecdt/ +# diff -urN gawk-3.1.2/test/arrayprm3.ok gawk-3.1.3/test/arrayprm3.ok --- gawk-3.1.2/test/arrayprm3.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/arrayprm3.ok 2003-05-11 04:48:38.000000000 -0700 @@ -0,0 +1 @@ +1 diff -urN gawk-3.1.2/test/arryref2.awk gawk-3.1.3/test/arryref2.awk --- gawk-3.1.2/test/arryref2.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/arryref2.awk 2003-03-24 22:41:11.000000000 -0800 @@ -0,0 +1,18 @@ +BEGIN { + foo(a) + + for (i in a) + print i, a[i] +} + +function foo(b) +{ + bar(b) + b[2] = "local" +} + +function bar(c) +{ + a[3] = "global" + c[1] = "local2" +} diff -urN gawk-3.1.2/test/arryref2.ok gawk-3.1.3/test/arryref2.ok --- gawk-3.1.2/test/arryref2.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/arryref2.ok 2003-05-11 04:56:31.000000000 -0700 @@ -0,0 +1,3 @@ +1 local2 +2 local +3 global diff -urN gawk-3.1.2/test/arryref3.awk gawk-3.1.3/test/arryref3.awk --- gawk-3.1.2/test/arryref3.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/arryref3.awk 2003-03-24 22:37:10.000000000 -0800 @@ -0,0 +1,18 @@ +BEGIN { + foo(a) + + for (i in a) + print i, a[i] +} + +function foo(b) +{ + a[1] = "global" + b[2] = "local" + bar(b) +} + +function bar(c) +{ + c = 12 +} diff -urN gawk-3.1.2/test/arryref3.ok gawk-3.1.3/test/arryref3.ok --- gawk-3.1.2/test/arryref3.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/arryref3.ok 2003-06-08 07:25:12.000000000 -0700 @@ -0,0 +1,2 @@ +gawk: arryref3.awk:17: fatal: attempt to use array `c (from b, from a)' in a scalar context +EXIT CODE: 2 diff -urN gawk-3.1.2/test/arryref4.awk gawk-3.1.3/test/arryref4.awk --- gawk-3.1.2/test/arryref4.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/arryref4.awk 2003-03-24 22:37:10.000000000 -0800 @@ -0,0 +1,17 @@ +BEGIN { + foo(a) + + print a +} + +function foo(b) +{ + a = "global" + b[2] = "local" +# bar(b) +} + +function bar(c) +{ + c = 12 +} diff -urN gawk-3.1.2/test/arryref4.ok gawk-3.1.3/test/arryref4.ok --- gawk-3.1.2/test/arryref4.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/arryref4.ok 2003-06-08 07:25:57.000000000 -0700 @@ -0,0 +1,2 @@ +gawk: arryref4.awk:10: fatal: attempt to use scalar parameter `b' as an array +EXIT CODE: 2 diff -urN gawk-3.1.2/test/arryref5.awk gawk-3.1.3/test/arryref5.awk --- gawk-3.1.2/test/arryref5.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/arryref5.awk 2003-03-24 22:37:10.000000000 -0800 @@ -0,0 +1,17 @@ +BEGIN { + foo(a) + + print a +} + +function foo(b) +{ + b[2] = "local" + a = "global" +# bar(b) +} + +function bar(c) +{ + c = 12 +} diff -urN gawk-3.1.2/test/arryref5.ok gawk-3.1.3/test/arryref5.ok --- gawk-3.1.2/test/arryref5.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/arryref5.ok 2003-05-11 05:00:01.000000000 -0700 @@ -0,0 +1,2 @@ +gawk: arryref5.awk:10: fatal: attempt to use array `a' in a scalar context +EXIT CODE: 2 diff -urN gawk-3.1.2/test/aryprm1.awk gawk-3.1.3/test/aryprm1.awk --- gawk-3.1.2/test/aryprm1.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm1.awk 2003-06-09 02:37:49.000000000 -0700 @@ -0,0 +1,9 @@ +function f(a) { + if (3 in a) + print 7 + a = 5 +} + +BEGIN { + f(arr) +} diff -urN gawk-3.1.2/test/aryprm1.ok gawk-3.1.3/test/aryprm1.ok --- gawk-3.1.2/test/aryprm1.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm1.ok 2003-06-08 07:25:57.000000000 -0700 @@ -0,0 +1,2 @@ +gawk: aryprm1.awk:4: fatal: attempt to use array `a (from arr)' in a scalar context +EXIT CODE: 2 diff -urN gawk-3.1.2/test/aryprm2.awk gawk-3.1.3/test/aryprm2.awk --- gawk-3.1.2/test/aryprm2.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm2.awk 2003-06-09 02:37:53.000000000 -0700 @@ -0,0 +1,8 @@ +function f(a) { + delete a + a *= 5 +} + +BEGIN { + f(arr) +} diff -urN gawk-3.1.2/test/aryprm2.ok gawk-3.1.3/test/aryprm2.ok --- gawk-3.1.2/test/aryprm2.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm2.ok 2003-06-08 07:25:57.000000000 -0700 @@ -0,0 +1,2 @@ +gawk: aryprm2.awk:3: fatal: attempt to use array `a (from arr)' in a scalar context +EXIT CODE: 2 diff -urN gawk-3.1.2/test/aryprm3.awk gawk-3.1.3/test/aryprm3.awk --- gawk-3.1.2/test/aryprm3.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm3.awk 2003-06-08 07:25:57.000000000 -0700 @@ -0,0 +1,10 @@ +function f(a, i) { + for (i in a) + delete a[i] + if (a == 0) + print 7 +} + +BEGIN { + f(arr) +} diff -urN gawk-3.1.2/test/aryprm3.ok gawk-3.1.3/test/aryprm3.ok --- gawk-3.1.2/test/aryprm3.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm3.ok 2003-06-08 07:25:57.000000000 -0700 @@ -0,0 +1,2 @@ +gawk: aryprm3.awk:6: fatal: attempt to use array `a (from arr)' in a scalar context +EXIT CODE: 2 diff -urN gawk-3.1.2/test/aryprm4.awk gawk-3.1.3/test/aryprm4.awk --- gawk-3.1.2/test/aryprm4.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm4.awk 2003-06-09 02:58:16.000000000 -0700 @@ -0,0 +1,7 @@ +function f(x){ + x = 1 +} +BEGIN { + f(a) + a[1] +} diff -urN gawk-3.1.2/test/aryprm4.ok gawk-3.1.3/test/aryprm4.ok --- gawk-3.1.2/test/aryprm4.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm4.ok 2003-06-08 07:26:46.000000000 -0700 @@ -0,0 +1,2 @@ +gawk: aryprm4.awk:6: fatal: attempt to use scalar `a' as array +EXIT CODE: 2 diff -urN gawk-3.1.2/test/aryprm5.awk gawk-3.1.3/test/aryprm5.awk --- gawk-3.1.2/test/aryprm5.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm5.awk 2003-06-09 02:57:57.000000000 -0700 @@ -0,0 +1,6 @@ +function f(x){ + x[1] = x +} +BEGIN { + f(a) +} diff -urN gawk-3.1.2/test/aryprm5.ok gawk-3.1.3/test/aryprm5.ok --- gawk-3.1.2/test/aryprm5.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm5.ok 2003-06-08 07:26:46.000000000 -0700 @@ -0,0 +1,2 @@ +gawk: aryprm5.awk:2: fatal: attempt to use scalar parameter `x' as an array +EXIT CODE: 2 diff -urN gawk-3.1.2/test/aryprm6.awk gawk-3.1.3/test/aryprm6.awk --- gawk-3.1.2/test/aryprm6.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm6.awk 2003-06-09 02:58:03.000000000 -0700 @@ -0,0 +1,7 @@ +function f(x){ + a + x[1] = 3 +} +BEGIN { + f(a) +} diff -urN gawk-3.1.2/test/aryprm6.ok gawk-3.1.3/test/aryprm6.ok --- gawk-3.1.2/test/aryprm6.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm6.ok 2003-06-08 07:26:46.000000000 -0700 @@ -0,0 +1,2 @@ +gawk: aryprm6.awk:3: fatal: attempt to use scalar parameter `x' as an array +EXIT CODE: 2 diff -urN gawk-3.1.2/test/aryprm7.awk gawk-3.1.3/test/aryprm7.awk --- gawk-3.1.2/test/aryprm7.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm7.awk 2003-06-09 02:58:34.000000000 -0700 @@ -0,0 +1,6 @@ +function f(x, y){ + y[1] = x +} +BEGIN { + f(a, a) +} diff -urN gawk-3.1.2/test/aryprm7.ok gawk-3.1.3/test/aryprm7.ok --- gawk-3.1.2/test/aryprm7.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm7.ok 2003-06-08 07:26:46.000000000 -0700 @@ -0,0 +1,2 @@ +gawk: aryprm7.awk:2: fatal: attempt to use scalar parameter `y' as an array +EXIT CODE: 2 diff -urN gawk-3.1.2/test/aryprm8.awk gawk-3.1.3/test/aryprm8.awk --- gawk-3.1.2/test/aryprm8.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm8.awk 2003-06-09 02:58:52.000000000 -0700 @@ -0,0 +1,22 @@ +BEGIN { + f(0, a) # nothing + f(1, a) +} +function f(i, a) { + if (i == 0) return + g(a, a) + pr(a) +} +function g(x, y) { + h(y, x, y) +} +function h(b, c, d) { + b[1] = 1 + c[1] = 2 # rewrite + print b[1], d[1] + c[2] = 1 + b[2] = 2 # should rewrite +} +function pr(x) { + print x[1], x[2] +} diff -urN gawk-3.1.2/test/aryprm8.ok gawk-3.1.3/test/aryprm8.ok --- gawk-3.1.2/test/aryprm8.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/aryprm8.ok 2003-06-08 07:26:46.000000000 -0700 @@ -0,0 +1,2 @@ +2 2 +2 2 diff -urN gawk-3.1.2/test/delarpm2.awk gawk-3.1.3/test/delarpm2.awk --- gawk-3.1.2/test/delarpm2.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/delarpm2.awk 2003-06-08 07:16:42.000000000 -0700 @@ -0,0 +1,95 @@ +# From beebe@math.utah.edu Sat May 17 21:31:27 2003 +# Return-Path: +# Received: from localhost (aahz [127.0.0.1]) +# by skeeve.com (8.12.5/8.12.5) with ESMTP id h4HIQmCw001380 +# for ; Sat, 17 May 2003 21:31:27 +0300 +# Received: from actcom.co.il [192.114.47.1] +# by localhost with POP3 (fetchmail-5.9.0) +# for arnold@localhost (single-drop); Sat, 17 May 2003 21:31:27 +0300 (IDT) +# Received: by actcom.co.il (mbox arobbins) +# (with Cubic Circle's cucipop (v1.31 1998/05/13) Sat May 17 21:34:07 2003) +# X-From_: beebe@sunshine.math.utah.edu Fri May 16 20:38:45 2003 +# Received: from smtp1.actcom.net.il by actcom.co.il with ESMTP +# (8.11.6/actcom-0.2) id h4GHcd226764 for ; +# Fri, 16 May 2003 20:38:40 +0300 (EET DST) +# (rfc931-sender: mail.actcom.co.il [192.114.47.13]) +# Received: from f7.net (consort.superb.net [209.61.216.22]) +# by smtp1.actcom.net.il (8.12.8/8.12.8) with ESMTP id h4GHgBc2023067 +# for ; Fri, 16 May 2003 20:42:13 +0300 +# Received: from sunshine.math.utah.edu (sunshine.math.utah.edu [128.110.198.2]) +# by f7.net (8.11.7/8.11.6) with ESMTP id h4GHcbf09202 +# for ; Fri, 16 May 2003 13:38:37 -0400 +# Received: from suncore.math.utah.edu (IDENT:r8KQWmkF4jVMLBhxpojXGNCAnBZB38ET@suncore.math.utah.edu [128.110.198.5]) +# by sunshine.math.utah.edu (8.9.3p2/8.9.3) with ESMTP id LAA09111; +# Fri, 16 May 2003 11:38:34 -0600 (MDT) +# Received: (from beebe@localhost) +# by suncore.math.utah.edu (8.9.3p2/8.9.3) id LAA01743; +# Fri, 16 May 2003 11:38:34 -0600 (MDT) +# Date: Fri, 16 May 2003 11:38:34 -0600 (MDT) +# From: "Nelson H. F. Beebe" +# To: "Arnold Robbins" +# Cc: beebe@math.utah.edu +# X-US-Mail: "Center for Scientific Computing, Department of Mathematics, 110 +# LCB, University of Utah, 155 S 1400 E RM 233, Salt Lake City, UT +# 84112-0090, USA" +# X-Telephone: +1 801 581 5254 +# X-FAX: +1 801 585 1640, +1 801 581 4148 +# X-URL: http://www.math.utah.edu/~beebe +# Subject: gawk-3.1.2[ab]: bug in delete +# Message-ID: +# +# I discovered yesterday that one of my tools got broken by the upgrade +# to gawk-3.1.2a and gawk-3.1.2b. For now, I've temporarily reset +# /usr/local/bin/gawk on the Sun Solaris and Intel GNU/Linux systems +# back to be gawk-3.1.2. +# +# This morning, I isolated the problem to the following small test case: +# +# % cat bug.awk + BEGIN { + clear_array(table) + foo(table) + for (key in table) + print key, table[k] + clear_array(table) + exit(0) + } + + function clear_array(array, key) + { + for (key in array) + delete array[key] + } + + function foo(a) + { + a[1] = "one" + a[2] = "two" + } +# +# With nawk, mawk, and also gawk-3.1.2 or earlier, I get this: +# +# % mawk -f bug.awk +# 1 +# 2 +# +# However, with the two most recent gawk releases, I get: +# +# % gawk-3.1.2b -f bug.awk +# gawk-3.1.2b: bug.awk:12: fatal: delete: illegal use of variable `table' as +# array +# +# If the first clear_array() statement is commented out, it runs. +# However, the problem is that in a large program, it may not be easy to +# identify places where it is safe to invoke delete, so I believe the +# old behavior is more desirable. +# +# ------------------------------------------------------------------------------- +# - Nelson H. F. Beebe Tel: +1 801 581 5254 - +# - Center for Scientific Computing FAX: +1 801 581 4148 - +# - University of Utah Internet e-mail: beebe@math.utah.edu - +# - Department of Mathematics, 110 LCB beebe@acm.org beebe@computer.org - +# - 155 S 1400 E RM 233 beebe@ieee.org - +# - Salt Lake City, UT 84112-0090, USA URL: http://www.math.utah.edu/~beebe - +# ------------------------------------------------------------------------------- +# diff -urN gawk-3.1.2/test/delarpm2.ok gawk-3.1.3/test/delarpm2.ok --- gawk-3.1.2/test/delarpm2.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/delarpm2.ok 2003-06-08 07:17:02.000000000 -0700 @@ -0,0 +1,2 @@ +1 +2 diff -urN gawk-3.1.2/test/fmttest.awk gawk-3.1.3/test/fmttest.awk --- gawk-3.1.2/test/fmttest.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/fmttest.awk 2003-06-08 03:02:33.000000000 -0700 @@ -0,0 +1,164 @@ +### /u/sy/beebe/xml/shbook/fmttest.awk, Sat May 31 09:13:52 2003 +### Edit by Nelson H. F. Beebe +### ==================================================================== +### Test the degree of support for printf format items in awk +### implementations. +### +### Usage: +### awk -f fmttest.awk +### [31-May-2003] +### ==================================================================== + +BEGIN { + ## ----------------------------------------------------------------- + print "\n\nFormat item: c\n" + + printf("ABC with %%c : %c\n", "ABC") + printf("123 with %%c : %c\n", 123) + + printf("ABC with %%.15c : %.15c\n", "ABC") + printf("123 with %%.15c : %.15c\n", 123) + + printf("ABC with %%15c : %15c\n", "ABC") + printf("123 with %%15c : %15c\n", 123) + + printf("ABC with %%-15c : %-15c\n", "ABC") + printf("123 with %%-15c : %-15c\n", 123) + + ## ----------------------------------------------------------------- + print "\n\nFormat item: d\n" + + printf("ABC with %%d : %d\n", "ABC") + printf("123 with %%d : %d\n", 123) + + printf("ABC with %%.15d : %.15d\n", "ABC") + printf("123 with %%.15d : %.15d\n", 123) + + printf("ABC with %%15d : %15d\n", "ABC") + printf("123 with %%15d : %15d\n", 123) + + printf("ABC with %%-15d : %-15d\n", "ABC") + printf("123 with %%-15d : %-15d\n", 123) + + ## ----------------------------------------------------------------- + print "\n\nFormat item: e\n" + + printf("ABC with %%e : %e\n", "ABC") + printf("123 with %%e : %e\n", 123) + + printf("ABC with %%.25e : %.25e\n", "ABC") + printf("123 with %%.25e : %.25e\n", 123) + + printf("ABC with %%25e : %25e\n", "ABC") + printf("123 with %%25e : %25e\n", 123) + + printf("ABC with %%-25e : %-25e\n", "ABC") + printf("123 with %%-25e : %-25e\n", 123) + + ## ----------------------------------------------------------------- + print "\n\nFormat item: f\n" + + printf("ABC with %%f : %f\n", "ABC") + printf("123 with %%f : %f\n", 123) + + printf("ABC with %%.25f : %.25f\n", "ABC") + printf("123 with %%.25f : %.25f\n", 123) + + printf("ABC with %%25f : %25f\n", "ABC") + printf("123 with %%25f : %25f\n", 123) + + printf("ABC with %%-25f : %-25f\n", "ABC") + printf("123 with %%-25f : %-25f\n", 123) + + ## ----------------------------------------------------------------- + print "\n\nFormat item: g\n" + + printf("ABC with %%g : %g\n", "ABC") + printf("123 with %%g : %g\n", 123) + + printf("ABC with %%.25g : %.25g\n", "ABC") + printf("123 with %%.25g : %.25g\n", 123) + + printf("ABC with %%25g : %25g\n", "ABC") + printf("123 with %%25g : %25g\n", 123) + + printf("ABC with %%-25g : %-25g\n", "ABC") + printf("123 with %%-25g : %-25g\n", 123) + + ## ----------------------------------------------------------------- + print "\n\nFormat item: o\n" + + printf("ABC with %%o : %o\n", "ABC") + printf("123 with %%o : %o\n", 123) + + printf("ABC with %%.15o : %.15o\n", "ABC") + printf("123 with %%.15o : %.15o\n", 123) + + printf("ABC with %%15o : %15o\n", "ABC") + printf("123 with %%15o : %15o\n", 123) + + printf("ABC with %%-15o : %-15o\n", "ABC") + printf("123 with %%-15o : %-15o\n", 123) + + ## ----------------------------------------------------------------- + print "\n\nFormat item: s\n" + + printf("ABC with %%s : %s\n", "ABC") + printf("123 with %%s : %s\n", 123) + + printf("ABC with %%.15s : %.15s\n", "ABC") + printf("123 with %%.15s : %.15s\n", 123) + + printf("ABC with %%15s : %15s\n", "ABC") + printf("123 with %%15s : %15s\n", 123) + + printf("ABC with %%-15s : %-15s\n", "ABC") + printf("123 with %%-15s : %-15s\n", 123) + + ## ----------------------------------------------------------------- + print "\n\nFormat item: u\n" + + printf("ABC with %%u : %u\n", "ABC") + printf("123 with %%u : %u\n", 123) + + printf("ABC with %%.15u : %.15u\n", "ABC") + printf("123 with %%.15u : %.15u\n", 123) + + printf("ABC with %%15u : %15u\n", "ABC") + printf("123 with %%15u : %15u\n", 123) + + printf("ABC with %%-15u : %-15u\n", "ABC") + printf("123 with %%-15u : %-15u\n", 123) + + ## ----------------------------------------------------------------- + print "\n\nFormat item: x\n" + + printf("ABC with %%x : %x\n", "ABC") + printf("123 with %%x : %x\n", 123) + + printf("ABC with %%.15x : %.15x\n", "ABC") + printf("123 with %%.15x : %.15x\n", 123) + + printf("ABC with %%15x : %15x\n", "ABC") + printf("123 with %%15x : %15x\n", 123) + + printf("ABC with %%-15x : %-15x\n", "ABC") + printf("123 with %%-15x : %-15x\n", 123) + + ## ----------------------------------------------------------------- + print "\n\nFormat item: X\n" + + printf("ABC with %%X : %X\n", "ABC") + printf("123 with %%X : %X\n", 123) + + printf("ABC with %%.15X : %.15X\n", "ABC") + printf("123 with %%.15X : %.15X\n", 123) + + printf("ABC with %%15X : %15X\n", "ABC") + printf("123 with %%15X : %15X\n", 123) + + printf("ABC with %%-15X : %-15X\n", "ABC") + printf("123 with %%-15X : %-15X\n", 123) + + exit(0) +} diff -urN gawk-3.1.2/test/fmttest.ok gawk-3.1.3/test/fmttest.ok --- gawk-3.1.2/test/fmttest.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/fmttest.ok 2003-06-08 03:02:50.000000000 -0700 @@ -0,0 +1,120 @@ + + +Format item: c + +ABC with %c : A +123 with %c : { +ABC with %.15c : A +123 with %.15c : { +ABC with %15c : A +123 with %15c : { +ABC with %-15c : A +123 with %-15c : { + + +Format item: d + +ABC with %d : 0 +123 with %d : 123 +ABC with %.15d : 000000000000000 +123 with %.15d : 000000000000123 +ABC with %15d : 0 +123 with %15d : 123 +ABC with %-15d : 0 +123 with %-15d : 123 + + +Format item: e + +ABC with %e : 0.000000e+00 +123 with %e : 1.230000e+02 +ABC with %.25e : 0.0000000000000000000000000e+00 +123 with %.25e : 1.2300000000000000000000000e+02 +ABC with %25e : 0.000000e+00 +123 with %25e : 1.230000e+02 +ABC with %-25e : 0.000000e+00 +123 with %-25e : 1.230000e+02 + + +Format item: f + +ABC with %f : 0.000000 +123 with %f : 123.000000 +ABC with %.25f : 0.0000000000000000000000000 +123 with %.25f : 123.0000000000000000000000000 +ABC with %25f : 0.000000 +123 with %25f : 123.000000 +ABC with %-25f : 0.000000 +123 with %-25f : 123.000000 + + +Format item: g + +ABC with %g : 0 +123 with %g : 123 +ABC with %.25g : 0 +123 with %.25g : 123 +ABC with %25g : 0 +123 with %25g : 123 +ABC with %-25g : 0 +123 with %-25g : 123 + + +Format item: o + +ABC with %o : 0 +123 with %o : 173 +ABC with %.15o : 000000000000000 +123 with %.15o : 000000000000173 +ABC with %15o : 0 +123 with %15o : 173 +ABC with %-15o : 0 +123 with %-15o : 173 + + +Format item: s + +ABC with %s : ABC +123 with %s : 123 +ABC with %.15s : ABC +123 with %.15s : 123 +ABC with %15s : ABC +123 with %15s : 123 +ABC with %-15s : ABC +123 with %-15s : 123 + + +Format item: u + +ABC with %u : 0 +123 with %u : 123 +ABC with %.15u : 000000000000000 +123 with %.15u : 000000000000123 +ABC with %15u : 0 +123 with %15u : 123 +ABC with %-15u : 0 +123 with %-15u : 123 + + +Format item: x + +ABC with %x : 0 +123 with %x : 7b +ABC with %.15x : 000000000000000 +123 with %.15x : 00000000000007b +ABC with %15x : 0 +123 with %15x : 7b +ABC with %-15x : 0 +123 with %-15x : 7b + + +Format item: X + +ABC with %X : 0 +123 with %X : 7B +ABC with %.15X : 000000000000000 +123 with %.15X : 00000000000007B +ABC with %15X : 0 +123 with %15X : 7B +ABC with %-15X : 0 +123 with %-15X : 7B diff -urN gawk-3.1.2/test/fnarray.ok gawk-3.1.3/test/fnarray.ok --- gawk-3.1.2/test/fnarray.ok 2003-02-02 05:38:32.000000000 -0800 +++ gawk-3.1.3/test/fnarray.ok 2003-03-25 06:28:22.000000000 -0800 @@ -1,3 +1,3 @@ -gawk: fnarray.awk:5: fatal: function `foo' called with space between name and `(', -or used as a variable or an array -EXIT CODE: 2 +gawk: fnarray.awk:5: Num = foo[c] +gawk: fnarray.awk:5: ^ use of non-array as array +EXIT CODE: 1 diff -urN gawk-3.1.2/test/fnarray2.awk gawk-3.1.3/test/fnarray2.awk --- gawk-3.1.2/test/fnarray2.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/fnarray2.awk 2003-03-24 22:16:50.000000000 -0800 @@ -0,0 +1,5 @@ +function pile(c, r) +{ + r = ++pile[c] +} +{ pile($1) } diff -urN gawk-3.1.2/test/fnarray2.ok gawk-3.1.3/test/fnarray2.ok --- gawk-3.1.2/test/fnarray2.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/fnarray2.ok 2003-03-24 22:34:11.000000000 -0800 @@ -0,0 +1,3 @@ +gawk: fnarray2.awk:3: r = ++pile[c] +gawk: fnarray2.awk:3: ^ use of non-array as array +EXIT CODE: 1 diff -urN gawk-3.1.2/test/fnaryscl.ok gawk-3.1.3/test/fnaryscl.ok --- gawk-3.1.2/test/fnaryscl.ok 2002-10-28 01:18:30.000000000 -0800 +++ gawk-3.1.3/test/fnaryscl.ok 2003-06-08 07:25:12.000000000 -0700 @@ -1,2 +1,2 @@ -gawk: fnaryscl.awk:10: fatal: attempt to use array `c (from b (from a (from foo)))' in a scalar context +gawk: fnaryscl.awk:10: fatal: attempt to use array `c (from b, from a, from foo)' in a scalar context EXIT CODE: 2 diff -urN gawk-3.1.2/test/gsubtst5.awk gawk-3.1.3/test/gsubtst5.awk --- gawk-3.1.2/test/gsubtst5.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/gsubtst5.awk 2003-06-08 05:11:47.000000000 -0700 @@ -0,0 +1,97 @@ +# From jose@monkey.org Thu Jun 5 11:48:35 2003 +# Return-Path: +# Received: from localhost (skeeve [127.0.0.1]) +# by skeeve.com (8.12.5/8.12.5) with ESMTP id h558eVvA012655 +# for ; Thu, 5 Jun 2003 11:48:35 +0300 +# Received: from actcom.co.il [192.114.47.1] +# by localhost with POP3 (fetchmail-5.9.0) +# for arnold@localhost (single-drop); Thu, 05 Jun 2003 11:48:35 +0300 (IDT) +# Received: by actcom.co.il (mbox arobbins) +# (with Cubic Circle's cucipop (v1.31 1998/05/13) Thu Jun 5 11:47:59 2003) +# X-From_: jose@monkey.org Thu Jun 5 07:14:45 2003 +# Received: from smtp1.actcom.net.il by actcom.co.il with ESMTP +# (8.11.6/actcom-0.2) id h554EdY08108 for ; +# Thu, 5 Jun 2003 07:14:41 +0300 (EET DST) +# (rfc931-sender: smtp.actcom.co.il [192.114.47.13]) +# Received: from f7.net (consort.superb.net [209.61.216.22]) +# by smtp1.actcom.net.il (8.12.8/8.12.8) with ESMTP id h554G3To008304 +# for ; Thu, 5 Jun 2003 07:16:05 +0300 +# Received: from fencepost.gnu.org (fencepost.gnu.org [199.232.76.164]) +# by f7.net (8.11.7/8.11.6) with ESMTP id h554Ean08172 +# for ; Thu, 5 Jun 2003 00:14:36 -0400 +# Received: from monty-python.gnu.org ([199.232.76.173]) +# by fencepost.gnu.org with esmtp (Exim 4.20) +# id 19Nm96-0001xE-1i +# for arnold@gnu.ai.mit.edu; Thu, 05 Jun 2003 00:14:36 -0400 +# Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.20) +# id 19Nm8x-0005ge-Dz +# for arnold@gnu.ai.mit.edu; Thu, 05 Jun 2003 00:14:28 -0400 +# Received: from naughty.monkey.org ([66.93.9.164]) +# by monty-python.gnu.org with esmtp (Exim 4.20) +# id 19Nm8w-0005VM-Ko +# for arnold@gnu.ai.mit.edu; Thu, 05 Jun 2003 00:14:26 -0400 +# Received: by naughty.monkey.org (Postfix, from userid 1203) +# id C15511BA97B; Thu, 5 Jun 2003 00:14:19 -0400 (EDT) +# Received: from localhost (localhost [127.0.0.1]) +# by naughty.monkey.org (Postfix) with ESMTP +# id BF9821BA969; Thu, 5 Jun 2003 00:14:19 -0400 (EDT) +# Date: Thu, 5 Jun 2003 00:14:19 -0400 (EDT) +# From: Jose Nazario +# To: bug-gnu-utils@prep.ai.mit.edu, arnold@gnu.ai.mit.edu, +# netbsd-bugs@netbsd.org +# Subject: bug in gawk/gsub() (not present in nawk) +# Message-ID: +# MIME-Version: 1.0 +# Content-Type: TEXT/PLAIN; charset=US-ASCII +# X-Spam-Status: No, hits=-1.2 required=5.0 +# tests=SPAM_PHRASE_00_01,USER_AGENT_PINE +# version=2.41 +# X-Spam-Level: +# X-SpamBouncer: 1.4 (10/07/01) +# X-SBClass: OK +# Status: R +# +# while playing with some tools in data massaging, i had to migrate from an +# openbsd/nawk system to a netbsd/gawk system. i found the folllowing +# behavior, which seems to be a bug. +# +# the following gsub() pattern has a strange effect under gawk which is not +# visible in nawk (at least as compiled on openbsd). the intention is to +# take a string like "This Is a Title: My Title?" and turn it into a +# normalized string: "ThisIsaTitleMyTitle". to do this, i wrote the +# following gross gsub line in an awk script: +# +# gsub(/[\ \"-\/\\:;\[\]\@\?\.\,\$]/, "", $2) +# print $2 +# +# in gawk, as found in netbsd-macppc/1.5.2, this will drop the first letter +# of every word. the resulting string will be "hissitleyitle", while in nawk +# as built on openbsd-3.3 this will get it correct. +# +# any insights? the inconsistency with this relatively naive pattern seems a +# bit odd. (i would up installing nawk built from openbsd sources.) +# +# thanks. sorry i didn't send a better bug report, netbsd folks, i'm not +# much of a netbsd user, and i dont have send-pr set up. yes, this is a +# slightly older version of netbsd and gawk: +# +# $ uname -a +# NetBSD entropy 1.5.2 NetBSD 1.5.2 (GENERIC) #0: Sun Feb 10 02:00:04 EST +# 2002 jose@entropy:/usr/src/sys/arch/macppc/compile/GENERIC macppc +# $ awk --version +# GNU Awk 3.0.3 +# Copyright (C) 1989, 1991-1997 Free Software Foundation. +# +# +# +# thanks. +# +# ___________________________ +# jose nazario, ph.d. jose@monkey.org +# http://monkey.org/~jose/ +# +# +{ + gsub(/[\ \"-\/\\:;\[\]\@\?\.\,\$]/, "") + print +} diff -urN gawk-3.1.2/test/gsubtst5.in gawk-3.1.3/test/gsubtst5.in --- gawk-3.1.2/test/gsubtst5.in 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/gsubtst5.in 2003-06-08 05:12:00.000000000 -0700 @@ -0,0 +1 @@ +This Is a Title: My Title? diff -urN gawk-3.1.2/test/gsubtst5.ok gawk-3.1.3/test/gsubtst5.ok --- gawk-3.1.2/test/gsubtst5.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/gsubtst5.ok 2003-06-08 05:12:17.000000000 -0700 @@ -0,0 +1 @@ +ThisIsaTitleMyTitle diff -urN gawk-3.1.2/test/match2.awk gawk-3.1.3/test/match2.awk --- gawk-3.1.2/test/match2.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/match2.awk 2003-06-17 01:41:27.000000000 -0700 @@ -0,0 +1,6 @@ +function f(a, b, c) +{ + print match("foo", "bar", f) +} + +BEGIN { f(1, 2, 3) } diff -urN gawk-3.1.2/test/match2.ok gawk-3.1.3/test/match2.ok --- gawk-3.1.2/test/match2.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/match2.ok 2003-06-26 05:27:54.000000000 -0700 @@ -0,0 +1,2 @@ +gawk: match2.awk:3: fatal: match: third argument is not an array +EXIT CODE: 2 diff -urN gawk-3.1.2/test/nested.awk gawk-3.1.3/test/nested.awk --- gawk-3.1.2/test/nested.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/nested.awk 2003-06-08 05:01:53.000000000 -0700 @@ -0,0 +1,123 @@ +# From james@ruari-quinn.demon.co.uk Thu Jun 5 11:43:58 2003 +# Return-Path: +# Received: from localhost (skeeve [127.0.0.1]) +# by skeeve.com (8.12.5/8.12.5) with ESMTP id h558eVui012655 +# for ; Thu, 5 Jun 2003 11:43:58 +0300 +# Received: from actcom.co.il [192.114.47.1] +# by localhost with POP3 (fetchmail-5.9.0) +# for arnold@localhost (single-drop); Thu, 05 Jun 2003 11:43:58 +0300 (IDT) +# Received: by actcom.co.il (mbox arobbins) +# (with Cubic Circle's cucipop (v1.31 1998/05/13) Thu Jun 5 11:43:29 2003) +# X-From_: james@ruari-quinn.demon.co.uk Wed Jun 4 20:09:54 2003 +# Received: from smtp1.actcom.net.il by actcom.co.il with ESMTP +# (8.11.6/actcom-0.2) id h54H9oY05088 for ; +# Wed, 4 Jun 2003 20:09:52 +0300 (EET DST) +# (rfc931-sender: smtp.actcom.co.il [192.114.47.13]) +# Received: from f7.net (consort.superb.net [209.61.216.22]) +# by smtp1.actcom.net.il (8.12.8/8.12.8) with ESMTP id h54HB8To002721 +# for ; Wed, 4 Jun 2003 20:11:09 +0300 +# Received: from fencepost.gnu.org (fencepost.gnu.org [199.232.76.164]) +# by f7.net (8.11.7/8.11.6) with ESMTP id h54H9li15411 +# for ; Wed, 4 Jun 2003 13:09:47 -0400 +# Received: from monty-python.gnu.org ([199.232.76.173]) +# by fencepost.gnu.org with esmtp (Exim 4.20) +# id 19Nbli-0001kD-BL +# for bug-gawk@gnu.org; Wed, 04 Jun 2003 13:09:46 -0400 +# Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.20) +# id 19NbZ5-0004V2-71 +# for bug-gawk@gnu.org; Wed, 04 Jun 2003 12:56:43 -0400 +# Received: from cicero.e-mis.co.uk ([212.240.194.162]) +# by monty-python.gnu.org with esmtp (Exim 4.20) +# id 19NbYK-0003c7-AP +# for bug-gawk@gnu.org; Wed, 04 Jun 2003 12:55:56 -0400 +# Received: from [10.139.58.254] (helo=tacitus) +# by cicero.e-mis.co.uk with esmtp (Exim 3.35 #1 (Debian)) +# id 19NbWO-0007Qv-00 +# for ; Wed, 04 Jun 2003 17:53:56 +0100 +# Received: from james by tacitus with local (Exim 3.36 #1 (Debian)) +# id 19NbWO-0000cK-00 +# for ; Wed, 04 Jun 2003 17:53:56 +0100 +# To: bug-gawk@gnu.org +# Subject: 3.1.0 regression +# Mail-Copies-To: never +# From: James Troup +# User-Agent: Gnus/5.090017 (Oort Gnus v0.17) Emacs/20.7 (gnu/linux) +# Date: Wed, 04 Jun 2003 17:53:56 +0100 +# Message-ID: <874r35wzq3.fsf@nocrew.org> +# MIME-Version: 1.0 +# Content-Type: text/plain; charset=us-ascii +# Sender: James Troup +# X-Spam-Status: No, hits=-3.9 required=5.0 +# tests=EMAIL_ATTRIBUTION,SIGNATURE_SHORT_DENSE,SPAM_PHRASE_00_01, +# USER_AGENT +# version=2.41 +# X-Spam-Level: +# X-SpamBouncer: 1.4 (10/07/01) +# X-SBClass: OK +# Status: R +# +# Hi Aharon, +# +# This bug report comes from the Debian bug tracking system. You can +# view the full log at: +# +# http://bugs.debian.org/188345 +# +# Like my other bug, this is a regression from 3.1.0 and I've reproduced +# this problem with 3.1.2d. +# +# "Nikita V. Youshchenko" writes: +# +# | Package: gawk +# | Version: 1:3.1.2-2 +# | Severity: normal +# | Tags: sid +# | +# | After upgrading gawk from woody to sid, I found one of my scripts not +# | working. I explored this a little and found minimal script to reproduce +# | the problem. +# | +# | File bug.awk is the following: +# | +BEGIN { + WI_total = 0 +} +{ + WI_total++ + { + split ( $1, sws, "_" ) + a = sws[1] + } + print(sws[1]) + print(a) +} +# | +# | The second print should output the same what first print poutputs, but +# | with gawk 3.1.2-2 it outputs nothing: +# | > echo a_b | gawk -f bug.awk +# | a +# | +# | > +# | +# | With gawk from stable I get what expexted: +# | > echo a_b | gawk -f bug.awk +# | a +# | a +# | > +# | +# | If I remove "WI_total++" line, bug disapperas +# | +# | -- System Information: +# | Debian Release: 3.0 +# | Architecture: i386 +# | Kernel: Linux zigzag 2.4.19 16:49:13 MSK 2003 i686 +# | Locale: LANG=ru_RU.KOI8-R, LC_CTYPE=ru_RU.KOI8-R +# | +# | Versions of packages gawk depends on: +# | ii libc6 2.3.1-16 GNU C Library: Shared libraries an +# | +# | -- no debconf information +# +# -- +# James +# diff -urN gawk-3.1.2/test/nested.in gawk-3.1.3/test/nested.in --- gawk-3.1.2/test/nested.in 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/nested.in 2003-06-08 05:02:01.000000000 -0700 @@ -0,0 +1 @@ +a_b diff -urN gawk-3.1.2/test/nested.ok gawk-3.1.3/test/nested.ok --- gawk-3.1.2/test/nested.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/nested.ok 2003-06-08 05:02:12.000000000 -0700 @@ -0,0 +1,2 @@ +a +a diff -urN gawk-3.1.2/test/pipeio2.awk gawk-3.1.3/test/pipeio2.awk --- gawk-3.1.2/test/pipeio2.awk 2000-06-27 06:09:00.000000000 -0700 +++ gawk-3.1.3/test/pipeio2.awk 2003-06-26 04:51:34.000000000 -0700 @@ -28,7 +28,8 @@ while ((com | getline fnam) > 0) { # com_tr = "echo " fnam " | tr [0-9]. ..........." - com_tr = "echo " fnam " | sed 's/[0-9]/./g'" +# com_tr = "echo " fnam " | sed 's/[0-9]/./g'" + com_tr = "echo " fnam " | sed \"s/[0-9]/./g\"" # print "\'" com_tr "\'" print "'" com_tr "'" diff -urN gawk-3.1.2/test/pipeio2.ok gawk-3.1.3/test/pipeio2.ok --- gawk-3.1.2/test/pipeio2.ok 2000-06-27 05:37:13.000000000 -0700 +++ gawk-3.1.3/test/pipeio2.ok 2003-07-01 09:12:35.000000000 -0700 @@ -1,16 +1,16 @@ -'echo January 1997 | sed 's/[0-9]/./g'' +'echo January 1997 | sed "s/[0-9]/./g"' January .... -'echo S M Tu W Th F S | sed 's/[0-9]/./g'' +'echo S M Tu W Th F S | sed "s/[0-9]/./g"' S M Tu W Th F S -'echo 1 2 3 4 | sed 's/[0-9]/./g'' +'echo 1 2 3 4 | sed "s/[0-9]/./g"' . . . . -'echo 5 6 7 8 9 10 11 | sed 's/[0-9]/./g'' +'echo 5 6 7 8 9 10 11 | sed "s/[0-9]/./g"' . . . . . .. .. -'echo 12 13 14 15 16 17 18 | sed 's/[0-9]/./g'' +'echo 12 13 14 15 16 17 18 | sed "s/[0-9]/./g"' .. .. .. .. .. .. .. -'echo 19 20 21 22 23 24 25 | sed 's/[0-9]/./g'' +'echo 19 20 21 22 23 24 25 | sed "s/[0-9]/./g"' .. .. .. .. .. .. .. -'echo 26 27 28 29 30 31 | sed 's/[0-9]/./g'' +'echo 26 27 28 29 30 31 | sed "s/[0-9]/./g"' .. .. .. .. .. .. -'echo | sed 's/[0-9]/./g'' +'echo | sed "s/[0-9]/./g"' diff -urN gawk-3.1.2/test/printlang.awk gawk-3.1.3/test/printlang.awk --- gawk-3.1.2/test/printlang.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/printlang.awk 2003-06-17 08:15:35.000000000 -0700 @@ -0,0 +1,4 @@ +BEGIN { + printf "\nLocale environment:\n\tLC_ALL=\"%s\" LANG=\"%s\"\n\n", + ENVIRON["LC_ALL"], ENVIRON["LANG"] +} diff -urN gawk-3.1.2/test/rsnulbig.ok gawk-3.1.3/test/rsnulbig.ok --- gawk-3.1.2/test/rsnulbig.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/rsnulbig.ok 2003-05-11 05:31:28.000000000 -0700 @@ -0,0 +1 @@ +16386 diff -urN gawk-3.1.2/test/rsnulbig2.ok gawk-3.1.3/test/rsnulbig2.ok --- gawk-3.1.2/test/rsnulbig2.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/rsnulbig2.ok 2003-05-11 05:43:38.000000000 -0700 @@ -0,0 +1 @@ +2 diff -urN gawk-3.1.2/test/rstest3.awk gawk-3.1.3/test/rstest3.awk --- gawk-3.1.2/test/rstest3.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/rstest3.awk 2003-05-11 04:43:03.000000000 -0700 @@ -0,0 +1,73 @@ +# From spcecdt@armory.com Tue Apr 15 17:35:01 2003 +# Return-Path: +# Received: from localhost (aahz [127.0.0.1]) +# by skeeve.com (8.12.5/8.12.5) with ESMTP id h3FEYA6o001541 +# for ; Tue, 15 Apr 2003 17:35:01 +0300 +# Received: from actcom.co.il [192.114.47.1] +# by localhost with POP3 (fetchmail-5.9.0) +# for arnold@localhost (single-drop); Tue, 15 Apr 2003 17:35:01 +0300 (IDT) +# Received: by actcom.co.il (mbox arobbins) +# (with Cubic Circle's cucipop (v1.31 1998/05/13) Tue Apr 15 17:38:46 2003) +# X-From_: spcecdt@armory.com Tue Apr 15 11:09:12 2003 +# Received: from smtp1.actcom.net.il by actcom.co.il with ESMTP +# (8.11.6/actcom-0.2) id h3F88uC19825 for ; +# Tue, 15 Apr 2003 11:09:04 +0300 (EET DST) +# (rfc931-sender: smtp.actcom.co.il [192.114.47.13]) +# Received: from f7.net (consort.superb.net [209.61.216.22]) +# by smtp1.actcom.net.il (8.12.8/8.12.8) with ESMTP id h3F8CgQ7019081 +# for ; Tue, 15 Apr 2003 11:12:47 +0300 +# Received: from fencepost.gnu.org (fencepost.gnu.org [199.232.76.164]) +# by f7.net (8.11.7/8.11.6) with ESMTP id h3F88oW23381 +# for ; Tue, 15 Apr 2003 04:08:50 -0400 +# Received: from monty-python.gnu.org ([199.232.76.173]) +# by fencepost.gnu.org with esmtp (Exim 4.10) +# id 195LUo-0001cv-00 +# for bug-gawk@gnu.org; Tue, 15 Apr 2003 04:08:50 -0400 +# Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10.13) +# id 195LUh-0006n0-00 +# for bug-gawk@gnu.org; Tue, 15 Apr 2003 04:08:44 -0400 +# Received: from deepthought.armory.com ([192.122.209.42] helo=armory.com) +# by monty-python.gnu.org with smtp (Exim 4.10.13) +# id 195LUC-0006JM-00 +# for bug-gawk@gnu.org; Tue, 15 Apr 2003 04:08:13 -0400 +# Date: Tue, 15 Apr 2003 01:08:11 -0700 +# From: "John H. DuBois III" +# To: bug-gawk@gnu.org +# Subject: gawk 3.1.2 fatal bug +# Message-ID: <20030415080811.GA14963@armory.com> +# Mime-Version: 1.0 +# Content-Type: text/plain; charset=us-ascii +# Content-Disposition: inline +# User-Agent: Mutt/1.3.28i +# X-Www: http://www.armory.com./~spcecdt/ +# Sender: spcecdt@armory.com +# X-Spam-Status: No, hits=-7.9 required=5.0 +# tests=SIGNATURE_SHORT_DENSE,SPAM_PHRASE_01_02,USER_AGENT, +# USER_AGENT_MUTT +# version=2.41 +# X-Spam-Level: +# X-SpamBouncer: 1.4 (10/07/01) +# X-SBClass: OK +# Status: RO +# +# This program: +# +# BEGIN { RS = ""; "/bin/echo -n x" | getline } +# +# fails in exactly the same way under SCO OpenServer 5.0.6a using gawk 3.1.2 +# built with gcc 2.95.3 and linux using gawk 3.1.2 built with gcc 3.2.2: +# +# gawk: gawktest:1: fatal error: internal error +# Abort +# +# The same program does not fail with gawk 3.1.1. +# +# John +# -- +# John DuBois spcecdt@armory.com KC6QKZ/AE http://www.armory.com/~spcecdt/ +# +# +BEGIN { + RS = "" + "echo x | tr -d '\\12'" | getline +} diff -urN gawk-3.1.2/test/rstest4.awk gawk-3.1.3/test/rstest4.awk --- gawk-3.1.2/test/rstest4.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/rstest4.awk 2003-05-11 04:51:20.000000000 -0700 @@ -0,0 +1,67 @@ +# From spcecdt@armory.com Mon May 5 14:37:09 2003 +# Return-Path: +# Received: from localhost (skeeve [127.0.0.1]) +# by skeeve.com (8.12.5/8.12.5) with ESMTP id h45B1GvT031993 +# for ; Mon, 5 May 2003 14:37:09 +0300 +# Received: from actcom.co.il [192.114.47.1] +# by localhost with POP3 (fetchmail-5.9.0) +# for arnold@localhost (single-drop); Mon, 05 May 2003 14:37:09 +0300 (IDT) +# Received: by actcom.co.il (mbox arobbins) +# (with Cubic Circle's cucipop (v1.31 1998/05/13) Mon May 5 14:35:11 2003) +# X-From_: spcecdt@armory.com Mon May 5 12:20:20 2003 +# Received: from smtp1.actcom.net.il by actcom.co.il with ESMTP +# (8.11.6/actcom-0.2) id h459KC529186 for ; +# Mon, 5 May 2003 12:20:15 +0300 (EET DST) +# (rfc931-sender: smtp.actcom.co.il [192.114.47.13]) +# Received: from f7.net (consort.superb.net [209.61.216.22]) +# by smtp1.actcom.net.il (8.12.8/8.12.8) with ESMTP id h459LMfl025854 +# for ; Mon, 5 May 2003 12:21:24 +0300 +# Received: from armory.com (deepthought.armory.com [192.122.209.42]) +# by f7.net (8.11.7/8.11.6) with SMTP id h459K9I26841 +# for ; Mon, 5 May 2003 05:20:09 -0400 +# Date: Mon, 5 May 2003 02:20:08 -0700 +# From: "John H. DuBois III" +# To: Aharon Robbins +# Subject: Re: gawk 3.1.2b now available +# Message-ID: <20030505092008.GA15970@armory.com> +# References: <200305041149.h44BnLcm005484@localhost.localdomain> +# Mime-Version: 1.0 +# Content-Type: text/plain; charset=us-ascii +# Content-Disposition: inline +# In-Reply-To: <200305041149.h44BnLcm005484@localhost.localdomain> +# User-Agent: Mutt/1.3.28i +# X-Www: http://www.armory.com./~spcecdt/ +# Sender: spcecdt@armory.com +# X-SpamBouncer: 1.4 (10/07/01) +# X-SBClass: OK +# Status: RO +# +# This is a curious one: +# +# gawk-3.1.2b 'BEGIN { +# while (("echo" | getline) == 1) +# ; +# RS = "" +# "echo \"a\n\nb\"" | getline y +# print x +# }' | hd +# +# The output is: +# +# 0000 00 13 0a ... +# 0003 +# +# (the uninitialized variable 'x' is somehow getting the value ) +# +# John +# -- +# John DuBois spcecdt@armory.com KC6QKZ/AE http://www.armory.com/~spcecdt/ +# +BEGIN { + while (("echo" | getline) == 1) + ; + RS = "" + "echo \"a\n\nb\"" | getline y + printf "y = <%s>\n", y # ADR + printf "x = <%s>\n", x # ADR +} diff -urN gawk-3.1.2/test/rstest4.ok gawk-3.1.3/test/rstest4.ok --- gawk-3.1.2/test/rstest4.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/rstest4.ok 2003-05-11 04:51:17.000000000 -0700 @@ -0,0 +1,2 @@ +y =
+x = <> diff -urN gawk-3.1.2/test/rstest5.awk gawk-3.1.3/test/rstest5.awk --- gawk-3.1.2/test/rstest5.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/rstest5.awk 2003-05-11 04:52:32.000000000 -0700 @@ -0,0 +1,60 @@ +# From spcecdt@armory.com Tue May 6 13:42:34 2003 +# Return-Path: +# Received: from localhost (aahz [127.0.0.1]) +# by skeeve.com (8.12.5/8.12.5) with ESMTP id h46AgG53003519 +# for ; Tue, 6 May 2003 13:42:34 +0300 +# Received: from actcom.co.il [192.114.47.1] +# by localhost with POP3 (fetchmail-5.9.0) +# for arnold@localhost (single-drop); Tue, 06 May 2003 13:42:34 +0300 (IDT) +# Received: by actcom.co.il (mbox arobbins) +# (with Cubic Circle's cucipop (v1.31 1998/05/13) Tue May 6 13:48:46 2003) +# X-From_: spcecdt@armory.com Tue May 6 13:26:09 2003 +# Received: from smtp1.actcom.net.il by actcom.co.il with ESMTP +# (8.11.6/actcom-0.2) id h46AQ6520133 for ; +# Tue, 6 May 2003 13:26:07 +0300 (EET DST) +# (rfc931-sender: lmail.actcom.co.il [192.114.47.13]) +# Received: from f7.net (consort.superb.net [209.61.216.22]) +# by smtp1.actcom.net.il (8.12.8/8.12.8) with ESMTP id h46ARSfl010998 +# for ; Tue, 6 May 2003 13:27:31 +0300 +# Received: from armory.com (deepthought.armory.com [192.122.209.42]) +# by f7.net (8.11.7/8.11.6) with SMTP id h46AQ1I18183 +# for ; Tue, 6 May 2003 06:26:01 -0400 +# Date: Tue, 6 May 2003 03:25:59 -0700 +# From: "John H. DuBois III" +# To: Aharon Robbins +# Subject: Re: gawk 3.1.2b now available +# Message-ID: <20030506102559.GA16105@armory.com> +# References: <200305051157.h45Bv4XO003106@localhost.localdomain> +# Mime-Version: 1.0 +# Content-Type: text/plain; charset=us-ascii +# Content-Disposition: inline +# In-Reply-To: <200305051157.h45Bv4XO003106@localhost.localdomain> +# User-Agent: Mutt/1.3.28i +# X-Www: http://www.armory.com./~spcecdt/ +# Sender: spcecdt@armory.com +# X-SpamBouncer: 1.4 (10/07/01) +# X-SBClass: OK +# Status: RO +# +# The patch fixed the previous case, but here's another one - this prints +# : +# +# BEGIN { +# RS = "" +# "echo 'foo\n\nbaz'" | getline +# "echo 'foo\n\nbaz'" | getline +# "echo 'bar\n\nbaz'" | getline +# print x +# } +# +# John +# -- +# John DuBois spcecdt@armory.com KC6QKZ/AE http://www.armory.com/~spcecdt/ +# +BEGIN { + RS = "" + "echo 'foo\n\nbaz'" | getline ; print + "echo 'foo\n\nbaz'" | getline ; print + "echo 'bar\n\nbaz'" | getline ; print + printf "x = <%s>\n", x +} diff -urN gawk-3.1.2/test/rstest5.ok gawk-3.1.3/test/rstest5.ok --- gawk-3.1.2/test/rstest5.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/rstest5.ok 2003-05-11 04:52:48.000000000 -0700 @@ -0,0 +1,4 @@ +foo +baz +bar +x = <> diff -urN gawk-3.1.2/test/scalar.awk gawk-3.1.3/test/scalar.awk --- gawk-3.1.2/test/scalar.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/scalar.awk 2003-06-08 07:26:46.000000000 -0700 @@ -0,0 +1,4 @@ +BEGIN{ + sub(/x/,"",a) + a[1] +} diff -urN gawk-3.1.2/test/scalar.ok gawk-3.1.3/test/scalar.ok --- gawk-3.1.2/test/scalar.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/scalar.ok 2003-06-08 07:26:46.000000000 -0700 @@ -0,0 +1,2 @@ +gawk: scalar.awk:3: fatal: attempt to use scalar `a' as array +EXIT CODE: 2 diff -urN gawk-3.1.2/test/sortempty.awk gawk-3.1.3/test/sortempty.awk --- gawk-3.1.2/test/sortempty.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/sortempty.awk 2003-06-08 07:25:57.000000000 -0700 @@ -0,0 +1 @@ +BEGIN { print asort(a) } diff -urN gawk-3.1.2/test/sortempty.ok gawk-3.1.3/test/sortempty.ok --- gawk-3.1.2/test/sortempty.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/sortempty.ok 2003-06-08 07:25:57.000000000 -0700 @@ -0,0 +1 @@ +0 diff -urN gawk-3.1.2/test/strftime.awk gawk-3.1.3/test/strftime.awk --- gawk-3.1.2/test/strftime.awk 2000-06-27 05:37:13.000000000 -0700 +++ gawk-3.1.3/test/strftime.awk 2003-05-11 02:18:42.000000000 -0700 @@ -6,10 +6,14 @@ # on cygwin, where the timezone field is empty and there # are two consecutive blanks. +# Additional mucking about to lop off the seconds field; +# helps decrease chance of difference due to a second boundary + { $3 = sprintf("%02d", $3 + 0) + $4 = substr($4, 1, 5) print > "strftime.ok" - $0 = strftime() + $0 = strftime("%a %b %d %H:%M %Z %Y") $NF = $NF print > OUTPUT } diff -urN gawk-3.1.2/test/strtonum.awk gawk-3.1.3/test/strtonum.awk --- gawk-3.1.2/test/strtonum.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/strtonum.awk 2003-06-08 04:57:53.000000000 -0700 @@ -0,0 +1,6 @@ +BEGIN { + print strtonum("0x13") + print strtonum("013") + print strtonum("13") + print strtonum(13) +} diff -urN gawk-3.1.2/test/strtonum.ok gawk-3.1.3/test/strtonum.ok --- gawk-3.1.2/test/strtonum.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/strtonum.ok 2003-06-08 04:58:01.000000000 -0700 @@ -0,0 +1,4 @@ +19 +11 +13 +13 diff -urN gawk-3.1.2/test/switch2.awk gawk-3.1.3/test/switch2.awk --- gawk-3.1.2/test/switch2.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/switch2.awk 2003-06-08 04:15:09.000000000 -0700 @@ -0,0 +1,59 @@ +# From spcecdt@armory.com Tue Jun 3 11:41:49 2003 +# Return-Path: +# Received: from localhost (skeeve [127.0.0.1]) +# by skeeve.com (8.12.5/8.12.5) with ESMTP id h538fVuW018115 +# for ; Tue, 3 Jun 2003 11:41:49 +0300 +# Received: from actcom.co.il [192.114.47.1] +# by localhost with POP3 (fetchmail-5.9.0) +# for arnold@localhost (single-drop); Tue, 03 Jun 2003 11:41:49 +0300 (IDT) +# Received: by actcom.co.il (mbox arobbins) +# (with Cubic Circle's cucipop (v1.31 1998/05/13) Tue Jun 3 11:41:37 2003) +# X-From_: spcecdt@armory.com Mon Jun 2 20:17:30 2003 +# Received: from smtp1.actcom.net.il by actcom.co.il with ESMTP +# (8.11.6/actcom-0.2) id h52HHNY23516 for ; +# Mon, 2 Jun 2003 20:17:24 +0300 (EET DST) +# (rfc931-sender: mail.actcom.co.il [192.114.47.13]) +# Received: from f7.net (consort.superb.net [209.61.216.22]) +# by smtp1.actcom.net.il (8.12.8/8.12.8) with ESMTP id h52HIHqv028728 +# for ; Mon, 2 Jun 2003 20:18:18 +0300 +# Received: from armory.com (deepthought.armory.com [192.122.209.42]) +# by f7.net (8.11.7/8.11.6) with SMTP id h52HHKl31637 +# for ; Mon, 2 Jun 2003 13:17:20 -0400 +# Date: Mon, 2 Jun 2003 10:17:11 -0700 +# From: "John H. DuBois III" +# To: arnold@skeeve.com +# Subject: gawk 3.1.2c coredump +# Message-ID: <20030602171711.GA3958@armory.com> +# Mime-Version: 1.0 +# Content-Type: text/plain; charset=us-ascii +# Content-Disposition: inline +# User-Agent: Mutt/1.3.28i +# X-Www: http://www.armory.com./~spcecdt/ +# Sender: spcecdt@armory.com +# X-SpamBouncer: 1.4 (10/07/01) +# X-SBClass: OK +# Status: R +# +#!/usr/local/bin/gawk -f +BEGIN { + switch (substr("x",1,1)) { + case /ask.com/: + break + case "google": + break + } +} +# +# The stack says: +# +# #0 0x0806fac2 in r_tree_eval (tree=0x8092000, iscond=0) at eval.c:813 +# #1 0x08070413 in r_tree_eval (tree=0x0, iscond=0) at eval.c:1071 +# #2 0x08070413 in r_tree_eval (tree=0x8092000, iscond=0) at eval.c:1071 +# #3 0x08070413 in r_tree_eval (tree=0x8092000, iscond=0) at eval.c:1071 +# [ this continues on indefinitely - I suppose it ran out of stack eventually ] +# +# John +# -- +# John DuBois spcecdt@armory.com KC6QKZ/AE http://www.armory.com/~spcecdt/ +# +# diff -urN gawk-3.1.2/test/uninit3.awk gawk-3.1.3/test/uninit3.awk --- gawk-3.1.2/test/uninit3.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/uninit3.awk 2003-06-08 07:26:46.000000000 -0700 @@ -0,0 +1,7 @@ +function f(x){ + print x +} + +BEGIN { + f(x) +} diff -urN gawk-3.1.2/test/uninit3.ok gawk-3.1.3/test/uninit3.ok --- gawk-3.1.2/test/uninit3.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/uninit3.ok 2003-06-08 07:26:46.000000000 -0700 @@ -0,0 +1,3 @@ +gawk: uninit3.awk:8: warning: function `f': parameter `x' shadows global variable +gawk: uninit3.awk:2: warning: reference to uninitialized variable `x' + diff -urN gawk-3.1.2/test/uninit4.awk gawk-3.1.3/test/uninit4.awk --- gawk-3.1.2/test/uninit4.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/uninit4.awk 2003-07-04 11:16:36.000000000 -0700 @@ -0,0 +1,13 @@ +# test whether --lint catches uninitialized fields: +function pr() +{ + print +} + +BEGIN { + pr() + print $0 + print $(1-1) + print $1 + NF=3; print $2 +} diff -urN gawk-3.1.2/test/uninit4.ok gawk-3.1.3/test/uninit4.ok --- gawk-3.1.2/test/uninit4.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/uninit4.ok 2003-06-09 01:41:24.000000000 -0700 @@ -0,0 +1,10 @@ +gawk: uninit4.awk:4: warning: reference to uninitialized field `$0' + +gawk: uninit4.awk:9: warning: reference to uninitialized field `$0' + +gawk: uninit4.awk:10: warning: reference to uninitialized field `$0' + +gawk: uninit4.awk:11: warning: reference to uninitialized field `$1' + +gawk: uninit4.awk:12: warning: reference to uninitialized field `$2' + diff -urN gawk-3.1.2/test/whiny.awk gawk-3.1.3/test/whiny.awk --- gawk-3.1.2/test/whiny.awk 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/whiny.awk 2003-06-22 01:51:35.000000000 -0700 @@ -0,0 +1,5 @@ +{ word[$0]++ } +END { + for (i in word) + print i +} diff -urN gawk-3.1.2/test/whiny.in gawk-3.1.3/test/whiny.in --- gawk-3.1.2/test/whiny.in 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/whiny.in 2003-06-26 05:39:45.000000000 -0700 @@ -0,0 +1,178 @@ +gawk +pattern +scanning +and +processing +language +or +style +options +file +or +style +options +file +or +style +options +file +or +style +options +file +is +the +Project's +implementation +of +the +programming +language. +It +conforms +to +the +definition +of +the +language +in +the +Command +Language +And +Utilities +Standard. +This +version +in +turn +is +based +on +the +description +in +by +Aho, +Kernighan, +and +Weinberger, +with +the +additional +features +found +in +the +System +V +Release +version +of +also +provides +more +recent +Bell +Laboratories +extensions, +and +a +number +of +extensions. +is +the +profiling +version +of +It +is +identical +in +every +way +to +except +that +programs +run +more +slowly, +and +it +automatically +produces +an +execution +profile +in +the +file +when +done. +See +the +option, +below. +The +command +line +consists +of +options +to +itself, +the +program +text +not +supplied +via +the +or +options), +and +values +to +be +made +available +in +the +and +pre-defined +variables. +options +may +be +either +traditional +one +letter +options, +or +style +long +options. +options +start +with +a +single +while +long +options +start +with +Long +options +are +provided +for +both +features +and +for +features. diff -urN gawk-3.1.2/test/whiny.ok gawk-3.1.3/test/whiny.ok --- gawk-3.1.2/test/whiny.ok 1969-12-31 16:00:00.000000000 -0800 +++ gawk-3.1.3/test/whiny.ok 2003-06-26 05:40:47.000000000 -0700 @@ -0,0 +1,108 @@ +Aho, +And +Bell +Command +It +Kernighan, +Laboratories +Language +Long +Project's +Release +See +Standard. +System +The +This +Utilities +V +Weinberger, +a +additional +also +an +and +are +automatically +available +based +be +below. +both +by +command +conforms +consists +definition +description +done. +either +every +except +execution +extensions, +extensions. +features +features. +file +for +found +gawk +identical +implementation +in +is +it +itself, +language +language. +letter +line +long +made +may +more +not +number +of +on +one +option, +options +options), +options, +options. +or +pattern +pre-defined +processing +produces +profile +profiling +program +programming +programs +provided +provides +recent +run +scanning +single +slowly, +start +style +supplied +text +that +the +to +traditional +turn +values +variables. +version +via +way +when +while +with diff -urN gawk-3.1.2/unsupported/atari/ChangeLog gawk-3.1.3/unsupported/atari/ChangeLog --- gawk-3.1.2/unsupported/atari/ChangeLog 2003-03-19 04:23:44.000000000 -0800 +++ gawk-3.1.3/unsupported/atari/ChangeLog 2003-07-07 11:02:50.000000000 -0700 @@ -1,3 +1,7 @@ +Mon Jul 7 11:01:43 2003 Arnold D. Robbins + + * Release 3.1.3: Release tar file made. + Wed Mar 19 14:10:31 2003 Arnold D. Robbins This time for sure. diff -urN gawk-3.1.2/unsupported/tandem/ChangeLog gawk-3.1.3/unsupported/tandem/ChangeLog --- gawk-3.1.2/unsupported/tandem/ChangeLog 2003-03-19 04:23:49.000000000 -0800 +++ gawk-3.1.3/unsupported/tandem/ChangeLog 2003-07-07 11:02:56.000000000 -0700 @@ -1,3 +1,7 @@ +Mon Jul 7 11:01:43 2003 Arnold D. Robbins + + * Release 3.1.3: Release tar file made. + Wed Mar 19 14:10:31 2003 Arnold D. Robbins This time for sure. diff -urN gawk-3.1.2/vms/ChangeLog gawk-3.1.3/vms/ChangeLog --- gawk-3.1.2/vms/ChangeLog 2003-03-19 04:23:57.000000000 -0800 +++ gawk-3.1.3/vms/ChangeLog 2003-07-07 11:03:05.000000000 -0700 @@ -1,3 +1,12 @@ +Mon Jul 7 11:01:43 2003 Arnold D. Robbins + + * Release 3.1.3: Release tar file made. + +Mon Jun 9 22:15:40 2003 Pat Rankin + + * vms-conf.h: Synchronize with current configh.in. + ALLOW_SWITCH: Define this to enable new `switch' feature. + Wed Mar 19 14:10:31 2003 Arnold D. Robbins This time for sure. diff -urN gawk-3.1.2/vms/descrip.mms gawk-3.1.3/vms/descrip.mms --- gawk-3.1.2/vms/descrip.mms 2003-02-28 00:57:15.000000000 -0800 +++ gawk-3.1.3/vms/descrip.mms 2003-07-06 12:44:43.000000000 -0700 @@ -122,7 +122,7 @@ # Release of gawk REL=3.1 -PATCHLVL=1 +PATCHLVL=3 # generic target all : gawk diff -urN gawk-3.1.2/vms/vms-conf.h gawk-3.1.3/vms/vms-conf.h --- gawk-3.1.2/vms/vms-conf.h 2003-02-04 02:35:39.000000000 -0800 +++ gawk-3.1.3/vms/vms-conf.h 2003-06-15 08:20:07.000000000 -0700 @@ -27,320 +27,476 @@ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA */ +/* switch statements are enabled in awk programs */ +#undef ALLOW_SWITCH + +/* Define to one of `_getb67', `GETB67', `getb67' for Cray-2 and Cray-YMP + systems. This function is required for `alloca.c' support on those systems. + */ +#undef CRAY_STACKSEG_END + #if 0 -/* Define if using alloca.c. */ -#define C_ALLOCA +/* Define to 1 if using alloca.c. */ +#define C_ALLOCA 1 #else #define NO_ALLOCA /* vms/vms_fwrite.c needs this */ #endif -/* Define if type char is unsigned and you are not using gcc. */ -#ifndef __CHAR_UNSIGNED__ -/* #undef __CHAR_UNSIGNED__ */ -#endif - -/* Define to empty if the keyword does not work. */ -/* #undef const */ +/* dynamic loading is possible */ +#undef DYNAMIC -/* Define to one of _getb67, GETB67, getb67 for Cray-2 and Cray-YMP systems. - This function is required for alloca.c support on those systems. */ -/* #undef CRAY_STACKSEG_END */ +/* Define to 1 if translation of program messages to the user's native + language is requested. */ +#undef ENABLE_NLS -/* Define to the type of elements in the array set by `getgroups'. - Usually this is either `int' or `gid_t'. */ +/* Define to the type of elements in the array set by `getgroups'. Usually + this is either `int' or `gid_t'. */ #define GETGROUPS_T int -/* Define if the `getpgrp' function takes no argument. */ +/* Define to 1 if the `getpgrp' function requires zero arguments. */ #define GETPGRP_VOID 1 -/* Define to `int' if doesn't define. */ -/* #undef gid_t */ +/* Define to 1 if you have the `alarm' function. */ +#define HAVE_ALARM 1 -/* Define if you have alloca, as a function or macro. */ +/* Define to 1 if you have `alloca', as a function or macro. */ #undef HAVE_ALLOCA -/* Define if you have and it should be used (not on Ultrix). */ +/* Define to 1 if you have and it should be used (not on Ultrix). + */ #undef HAVE_ALLOCA_H -/* Define if you don't have vprintf but do have _doprnt. */ -/* #undef HAVE_DOPRNT */ +/* Define to 1 if you have the header file. */ +#undef HAVE_ARGZ_H -/* Define if you have a working `mmap' system call. */ -#undef HAVE_MMAP +/* Define if the GNU dcgettext() function is already present or preinstalled. + */ +#undef HAVE_DCGETTEXT -/* Define if your struct stat has st_blksize. */ -#undef HAVE_ST_BLKSIZE +/* Define to 1 if you don't have `vprintf' but do have `_doprnt.' */ +#undef HAVE_DOPRNT -/* Define if you have the ANSI # stringizing operator in cpp. */ -#ifdef VAXC -#undef HAVE_STRINGIZE -#else -#define HAVE_STRINGIZE 1 -#endif +/* Define to 1 if you have the header file. */ +#undef HAVE_FCNTL_H -/* Define if you have that is POSIX.1 compatible. */ -#undef HAVE_SYS_WAIT_H +/* Define to 1 if you have the `feof_unlocked' function. */ +#undef HAVE_FEOF_UNLOCKED -/* Define if your struct tm has tm_zone. */ -#undef HAVE_TM_ZONE +/* Define to 1 if you have the `fgets_unlocked' function. */ +#undef HAVE_FGETS_UNLOCKED -/* Define if you don't have tm_zone but do have the external array - tzname. */ -#define HAVE_TZNAME 1 /* (faked in vms/vms_misc.c) */ +/* Define to 1 if you have the `fmod' function. */ +#define HAVE_FMOD 1 -/* Define if you have the vprintf function. */ -#define HAVE_VPRINTF 1 +/* Define to 1 if you have the `getcwd' function. */ +#define HAVE_GETCWD 1 -/* Define as __inline if that's what the C compiler calls it. */ -/* #undef inline */ +/* Define to 1 if you have the `getc_unlocked' function. */ +#undef HAVE_GETC_UNLOCKED -/* Define if on MINIX. */ -/* #undef _MINIX */ +/* Define to 1 if you have the `getegid' function. */ +#undef HAVE_GETEGID -/* Define to `long' if doesn't define. */ -/* #undef off_t */ +/* Define to 1 if you have the `geteuid' function. */ +#define HAVE_GETEUID 1 -/* Define to `int' if doesn't define. */ -/* #undef pid_t */ +/* Define to 1 if you have the `getgid' function. */ +#define HAVE_GETGID 1 -/* Define if the system does not provide POSIX.1 features except - with this defined. */ -/* #undef _POSIX_1_SOURCE */ +/* Define to 1 if you have the `getgrent' function. */ +#undef HAVE_GETGRENT -/* Define if you need to in order for stat and other things to work. */ -/* #undef _POSIX_SOURCE */ +/* Define to 1 if you have the `getgroups' function. */ +#undef HAVE_GETGROUPS -/* Define as the return type of signal handlers (int or void). */ -#define RETSIGTYPE void +/* Define if you have the getpagesize function. */ +#undef HAVE_GETPAGESIZE -/* Define to `unsigned' if doesn't define. */ -/* #undef size_t */ +/* Define if the GNU gettext() function is already present or preinstalled. */ +#undef HAVE_GETTEXT -/* If using the C implementation of alloca, define if you know the - direction of stack growth for your system; otherwise it will be - automatically deduced at run-time. - STACK_DIRECTION > 0 => grows toward higher addresses - STACK_DIRECTION < 0 => grows toward lower addresses - STACK_DIRECTION = 0 => direction of growth unknown - */ -#define STACK_DIRECTION (-1) +/* Define to 1 if you have the `getuid' function. */ +#define HAVE_GETUID 1 -/* Define if you have the ANSI C header files. */ -#define STDC_HEADERS 1 +/* Define to 1 if you have the `grantpt' function. */ +#undef HAVE_GRANTPT -/* Define if you can safely include both and . */ -#undef TIME_WITH_SYS_TIME +/* Define if you have the iconv() function. */ +#undef HAVE_ICONV -/* Define if your declares struct tm. */ -/* #undef TM_IN_SYS_TIME */ +/* Define if exists and doesn't clash with . */ +#undef HAVE_INTTYPES_H -/* Define to `int' if doesn't define. */ -/* #undef uid_t */ +/* Define if you have and nl_langinfo(CODESET). */ +#undef HAVE_LANGINFO_CODESET -#define REGEX_MALLOC 1 /* use malloc instead of alloca in regex.c */ -#define SPRINTF_RET int /* return type of sprintf */ -#define HAVE_MKTIME 1 /* have the mktime function */ -#undef HAVE_SOCKETS /* don't have sockets on this system by default */ -#undef HAVE_PORTALS /* don't have portals on /p on this system */ -#undef DYNAMIC /* don't allow dynamic addition of builtins */ -#define STRTOD_NOT_C89 1 /* strtod doesn't have C89 semantics */ -#define ssize_t int /* signed version of size_t */ +/* Define if your file defines LC_MESSAGES. */ +#undef HAVE_LC_MESSAGES -/* Define if you have the __argz_count function. */ -#undef HAVE___ARGZ_COUNT +/* Define to 1 if you have the `dl' library (-ldl). */ +#undef HAVE_LIBDL -/* Define if you have the __argz_next function. */ -#undef HAVE___ARGZ_NEXT +/* Define to 1 if you have the header file. */ +#undef HAVE_LIBINTL_H -/* Define if you have the __argz_stringify function. */ -#undef HAVE___ARGZ_STRINGIFY +/* Define to 1 if you have the `m' library (-lm). */ +#undef HAVE_LIBM -/* Define if you have the alarm function. */ -#define HAVE_ALARM 1 +/* Define to 1 if you have the header file. */ +#define HAVE_LIMITS_H 1 -/* Define if you have the dcgettext function. */ -#undef HAVE_DCGETTEXT +/* Define to 1 if you have the header file. */ +#undef HAVE_LOCALE_H -/* Define if you have the fmod function. */ -#define HAVE_FMOD 1 +/* Define if you have the long long type. */ +#undef HAVE_LONG_LONG -/* Define if you have the getcwd function. */ -#define HAVE_GETCWD 1 +/* Define to 1 if you have the header file. */ +#undef HAVE_MALLOC_H -/* Define if you have the getpagesize function. */ -#undef HAVE_GETPAGESIZE +/* Define to 1 if you have the `mbrlen' function. */ +#undef HAVE_MBRLEN + +/* Define to 1 if you have the `mbrtowc' function. */ +#undef HAVE_MBRTOWC + +/* Define to 1 if you have the header file. */ +#undef HAVE_MCHECK_H -/* Define if you have the memcmp function. */ +/* Define to 1 if you have the `memcmp' function. */ #define HAVE_MEMCMP 1 -/* Define if you have the memcpy function. */ +/* Define to 1 if you have the `memcpy' function. */ #define HAVE_MEMCPY 1 -/* Define if you have the memset function. */ +/* Define to 1 if you have the header file. */ +#undef HAVE_MEMORY_H + +/* Define to 1 if you have the `mempcpy' function. */ +#undef HAVE_MEMPCPY + +/* Define to 1 if you have the `memset' function. */ #define HAVE_MEMSET 1 -/* Define if you have the munmap function. */ +/* we have the mktime function */ +#define HAVE_MKTIME 1 + +/* Define to 1 if you have a working `mmap' system call. */ +#undef HAVE_MMAP + +/* Define to 1 if you have the `munmap' function. */ #undef HAVE_MUNMAP -/* Define if you have the putenv function. */ +/* Define to 1 if you have the header file. */ +#undef HAVE_NETDB_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_NETINET_IN_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_NL_TYPES_H + +/* we have portals on /p on this system */ +#undef HAVE_PORTALS + +/* Define to 1 if you have the `putenv' function. */ #undef HAVE_PUTENV -/* Define if you have the setenv function. */ +/* Define to 1 if you have the `setenv' function. */ #undef HAVE_SETENV -/* Define if you have the setlocale function. */ +/* Define to 1 if you have the `setlocale' function. */ #undef HAVE_SETLOCALE -/* Define if you have the stpcpy function. */ +/* Define to 1 if you have the header file. */ +#undef HAVE_SIGNUM_H + +/* Define to 1 if you have the `snprintf' function. */ +#undef HAVE_SNPRINTF + +/* we have sockets on this system */ +#undef HAVE_SOCKETS + +/* Define to 1 if you have the header file. */ +#define HAVE_STDARG_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDDEF_H 1 + +/* Define to 1 if you have the header file. */ +#undef HAVE_STDINT_H + +/* Define to 1 if you have the header file. */ +#define HAVE_STDLIB_H 1 + +/* Define to 1 if you have the `stpcpy' function. */ #undef HAVE_STPCPY -/* Define if you have the strcasecmp function. */ +/* Define to 1 if you have the `strcasecmp' function. */ #undef HAVE_STRCASECMP -/* Define if you have the strchr function. */ +/* Define to 1 if you have the `strchr' function. */ #define HAVE_STRCHR 1 -/* Define if you have the strdup function. */ +/* Define to 1 if you have the `strdup' function. */ #undef HAVE_STRDUP -/* Define if you have the strerror function. */ +/* Define to 1 if you have the `strerror' function. */ #define HAVE_STRERROR 1 -/* Define if you have the strftime function. */ +/* Define to 1 if you have the `strftime' function. */ #undef HAVE_STRFTIME /* use the missing_d/strfime.c version */ -/* Define if you have the strncasecmp function. */ -#undef HAVE_STRNCASECMP - -/* Define if you have the strtod function. */ -#define HAVE_STRTOD 1 +/* Define to 1 if cpp supports the ANSI # stringizing operator. */ +#ifdef VAXC +#undef HAVE_STRINGIZE +#else +#define HAVE_STRINGIZE 1 +#endif -/* Define if you have the system function. */ -#define HAVE_SYSTEM 1 +/* Define to 1 if you have the header file. */ +#undef HAVE_STRINGS_H -/* Define if you have the tzset function. */ -#define HAVE_TZSET 1 /* (faked in vms/vms_misc.c) */ +/* Define to 1 if you have the header file. */ +#define HAVE_STRING_H 1 -/* Define if you have the header file. */ -#undef HAVE_ARGZ_H +/* Define to 1 if you have the `strncasecmp' function. */ +#undef HAVE_STRNCASECMP -/* Define if you have the header file. */ -#undef HAVE_FCNTL_H +/* Define to 1 if you have the header file. */ +#undef HAVE_STROPTS_H -/* Define if you have the header file. */ -#undef HAVE_LIBINTL_H +/* Define to 1 if you have the `strtod' function. */ +#define HAVE_STRTOD 1 -/* Define if you have the header file. */ -#define HAVE_LIMITS_H 1 +/* Define to 1 if you have the `strtoul' function. */ +#define HAVE_STRTOUL 1 -/* Define if you have the header file. */ -#undef HAVE_LOCALE_H +/* Define to 1 if `st_blksize' is member of `struct stat'. */ +#undef HAVE_STRUCT_STAT_ST_BLKSIZE -/* Define if you have the header file. */ -#undef HAVE_MALLOC_H +/* Define to 1 if `tm_zone' is member of `struct tm'. */ +#undef HAVE_STRUCT_TM_TM_ZONE -/* Define if you have the header file. */ -#undef HAVE_MCHECK_H +/* Define to 1 if your `struct stat' has `st_blksize'. Deprecated, use + `HAVE_STRUCT_STAT_ST_BLKSIZE' instead. */ +#undef HAVE_ST_BLKSIZE -/* Define if you have the header file. */ -#undef HAVE_MEMORY_H +/* Define to 1 if you have the `system' function. */ +#define HAVE_SYSTEM 1 -/* Define if you have the header file. */ -#undef HAVE_NETDB_H +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_PARAM_H -/* Define if you have the header file. */ -#undef HAVE_NETINET_IN_H +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_SOCKET_H -/* Define if you have the header file. */ -#undef HAVE_NL_TYPES_H +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_STAT_H -/* Define if you have the header file. */ -#undef HAVE_SIGNUM_H +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_TIME_H -/* Define if you have the header file. */ -#define HAVE_STDARG_H 1 +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_TYPES_H -/* Define if you have the header file. */ -#define HAVE_STDLIB_H 1 +/* Define if you have that is POSIX.1 compatible. */ +#undef HAVE_SYS_WAIT_H -/* Define if you have the header file. */ -#define HAVE_STRING_H 1 +/* Define to 1 if you have the header file. */ +#undef HAVE_TERMIOS_H -/* Define if you have the header file. */ -#undef HAVE_STRINGS_H +/* Define to 1 if your `struct tm' has `tm_zone'. Deprecated, use + `HAVE_STRUCT_TM_TM_ZONE' instead. */ +#undef HAVE_TM_ZONE -/* Define if you have the header file. */ -#undef HAVE_SYS_PARAM_H +/* Define to 1 if you have the `tsearch' function. */ +#undef HAVE_TSEARCH -/* Define if you have the header file. */ -#undef HAVE_SYS_SOCKET_H +/* Define to 1 if you don't have `tm_zone' but do have the external array + `tzname'. */ +#define HAVE_TZNAME 1 /* (faked in vms/vms_misc.c) */ -/* Define if you have the header file. */ -#undef HAVE_SYS_TIME_H +/* Define to 1 if you have the `tzset' function. */ +#define HAVE_TZSET 1 /* (faked in vms/vms_misc.c) */ -/* Define if you have the header file. */ +/* Define to 1 if you have the header file. */ #ifdef __DECC #define HAVE_UNISTD_H 1 #else #undef HAVE_UNISTD_H #endif -/* Define if you have the i library (-li). */ -#undef HAVE_LIBI +/* Define if you have the unsigned long long type. */ +#undef HAVE_UNSIGNED_LONG_LONG -/* Define if you have the intl library (-lintl). */ -#undef HAVE_LIBINTL +/* Define to 1 if you have the `vprintf' function. */ +#define HAVE_VPRINTF 1 -/* Define if you have the m library (-lm). */ -#undef HAVE_LIBM +/* Define to 1 if you have the header file. */ +#undef HAVE_WCHAR_H + +/* Define to 1 if you have the `wcrtomb' function. */ +#undef HAVE_WCRTOMB + +/* Define to 1 if you have the `wcscoll' function. */ +#undef HAVE_WCSCOLL + +/* Define to 1 if you have the header file. */ +#undef HAVE_WCTYPE_H + +/* Define to 1 if you have the `__argz_count' function. */ +#undef HAVE___ARGZ_COUNT + +/* Define to 1 if you have the `__argz_next' function. */ +#undef HAVE___ARGZ_NEXT + +/* Define to 1 if you have the `__argz_stringify' function. */ +#undef HAVE___ARGZ_STRINGIFY + +/* Define as const if the declaration of iconv() needs const. */ +#undef ICONV_CONST + +/* Define if integer division by zero raises signal SIGFPE. */ +#define INTDIV0_RAISES_SIGFPE 1 + +/* disable lint checks */ +#undef NO_LINT /* Name of package */ #define PACKAGE "gawk" +/* Define to the address where bug reports for this package should be sent. */ +#define PACKAGE_BUGREPORT "bug-gawk@gnu.org" + +/* Define to the full name of this package. */ +#define PACKAGE_NAME "GNU Awk" + +/* Define to the full name and version of this package. */ +#define PACKAGE_STRING "GNU Awk 3.1.2" + +/* Define to the one symbol short name of this package. */ +#define PACKAGE_TARNAME "gawk" + +/* Define to the version of this package. */ +#define PACKAGE_VERSION "3.1.2" + +/* Define if exists and defines unusable PRI* macros. */ +#undef PRI_MACROS_BROKEN + +/* Define if compiler has function prototypes */ +#define PROTOTYPES 1 + +/* use malloc instead of alloca in regex.c */ +#define REGEX_MALLOC 1 + +/* Define as the return type of signal handlers (`int' or `void'). */ +#define RETSIGTYPE void + +/* return type of sprintf */ +#define SPRINTF_RET int + +/* If using the C implementation of alloca, define if you know the + direction of stack growth for your system; otherwise it will be + automatically deduced at run-time. + STACK_DIRECTION > 0 => grows toward higher addresses + STACK_DIRECTION < 0 => grows toward lower addresses + STACK_DIRECTION = 0 => direction of growth unknown */ +#define STACK_DIRECTION (-1) + +/* Define to 1 if you have the ANSI C header files. */ +#define STDC_HEADERS 1 + +/* strtod doesn't have C89 semantics */ +#define STRTOD_NOT_C89 1 + +/* some systems define this type here */ +#undef TIME_T_IN_SYS_TYPES_H + +/* Define to 1 if you can safely include both and . */ +#undef TIME_WITH_SYS_TIME + +/* Define to 1 if your declares `struct tm'. */ +#undef TM_IN_SYS_TIME + +/* force use of our version of strftime */ +#define USE_INCLUDED_STRFTIME 1 + /* Version number of package */ -#define VERSION "3.1.1" +#define VERSION "3.1.2" + +/* Define to 1 if on AIX 3. + System headers sometimes define this. + We just want to avoid a redefinition error message. */ +#ifndef _ALL_SOURCE +# undef _ALL_SOURCE +#endif /* Number of bits in a file offset, on hosts where this is settable. */ #undef _FILE_OFFSET_BITS -/* Define to make ftello visible on some hosts (e.g. HP-UX 10.20). */ -#undef _LARGEFILE_SOURCE - /* Define for large files, on AIX-style hosts. */ #undef _LARGE_FILES -/* Define to make ftello visible on some hosts (e.g. glibc 2.1.3). */ -#undef _XOPEN_SOURCE +/* Define to 1 if on MINIX. */ +#undef _MINIX -/* Define if compiler has function prototypes */ -#define PROTOTYPES 1 +/* Define to 2 if the system does not provide POSIX.1 features except with + this defined. */ +#undef _POSIX_1_SOURCE -/* Define to 1 if you have the stpcpy function. */ -#undef HAVE_STPCPY +/* Define to 1 if you need to in order for `stat' and other things to work. */ +#undef _POSIX_SOURCE -/* Define if your locale.h file contains LC_MESSAGES. */ -#undef HAVE_LC_MESSAGES +/* Define to 1 if type `char' is unsigned and you are not using gcc. */ +#ifndef __CHAR_UNSIGNED__ +# undef __CHAR_UNSIGNED__ +#endif -/* Define to 1 if NLS is requested. */ -#undef ENABLE_NLS +/* Define to empty if `const' does not conform to ANSI C. */ +#undef const -/* Define to 1 if you have gettext and don't want to use GNU gettext. */ -#undef HAVE_GETTEXT +/* Define to `int' if doesn't define. */ +#undef gid_t -/* Define as 1 if you have catgets and don't want to use GNU gettext. */ -#undef HAVE_CATGETS +/* Define as `__inline' if that's what the C compiler calls it, or to nothing + if it is not supported. */ +#undef inline -/* Whether `time_t' is an unsigned type. */ -#define TIME_T_UNSIGNED 1 +/* Define to widest signed type if doesn't define. */ +#define intmax_t long int + +/* Define to `long' if doesn't define. */ +#undef off_t + +/* Define to `int' if doesn't define. */ +#undef pid_t + +/* Define to `unsigned' if doesn't define. */ +#undef size_t + +/* Define to `int' if does not define. */ +#define ssize_t int + +/* Define to `int' if doesn't define. */ +#undef uid_t + +/* Define to widest unsigned type if doesn't define. */ +#define uintmax_t unsigned long #if 0 #include /* overrides for stuff autoconf can't deal with */ #else +/* Whether `time_t' is an unsigned type. */ +#define TIME_T_UNSIGNED 1 + /*******************************/ /* Gawk configuration options. */ /*******************************/ +#define ALLOW_SWITCH 1 + /* * DEFPATH * VMS: "/AWK_LIBRARY" => "AWK_LIBRARY:" diff -urN gawk-3.1.2/vms/vmsbuild.com gawk-3.1.3/vms/vmsbuild.com --- gawk-3.1.2/vms/vmsbuild.com 2003-02-28 00:57:18.000000000 -0800 +++ gawk-3.1.3/vms/vmsbuild.com 2003-07-06 12:44:15.000000000 -0700 @@ -9,7 +9,7 @@ $! gawk 3.1.1 revised, Apr'02 $! $ REL = "3.1" !release version number -$ PATCHLVL = "1" +$ PATCHLVL = "3" $! $! $ CCFLAGS = "/noList" ! "/noOpt/Debug" PATCHEOF echo Sleeping and touching files to get timestamps set sleep 2 touch configure configh.in */Makefile.in touch aclocal.m4 configh.in test/Makefile.in touch awklib/Makefile.in doc/Makefile.in Makefile.in sleep 2 touch configure version.c echo Remove any .orig or "'~'" files that may remain. echo Use '"configure && make"' to rebuild any dependent files. echo Use "'make distclean'" to clean up.