Codebase list flex / 04687c4
Update to a new upstream commit for some bug fixes. Signed-off-by: Manoj Srivastava <srivasta@debian.org> Manoj Srivastava 6 years ago
34 changed file(s) with 1414 addition(s) and 263 deletion(s). Raw diff Collapse all Expand all
0 Aaron Stone <sodabrew@users.sourceforge.net>
1 Akim Demaille <akim@lrde.epita.fr>
2 Alastair Hughes <hobbitalastair@gmail.com>
3 Alex Kennedy <alexzanderkennedy@gmail.com>
4 Alexis La Goutte <alexis.lagoutte@gmail.com>
5 Bastian Köcher <git@kchr.de>
6 Christoph Junghans <ottxor@gentoo.org>
7 Christos Zoulas <christos@zoulas.com>
8 Cyril Brulebois <kibi@debian.org>
9 Demi Obenour <demiobenour@gmail.com>
10 Dennis Clarke <dclarke@blastwave.org>
11 Egor Pugin <egor.pugin@gmail.com>
12 Elias Pipping <pipping@users.sourceforge.net>
13 Explorer09 <explorer09@gmail.com>
14 Hans-Bernhard Broeker <HBBroeker@T-Online.de>
15 Harald van Dijk <harald@gigawatt.nl>
16 Hugh Sasse <hgs@dmu.ac.uk>
17 Jaska Uimonen <jaska.uimonen@helsinki.fi>
18 Jeff Smith <whydoubt@gmail.com>
19 John Millaway <john43@users.sourceforge.net>
20 Manoj Srivastava <srivasta@golden-gryphon.com>
21 Mariusz Pluciński <mplucinski@mplucinski.com>
22 Michael Haubenwallner <michael.haubenwallner@ssi-schaefer.com>
23 Michael McConville <mmcconville@mykolab.com> <mmcco@mykolab.com>
24 Michael Reed <m.reed@mykolab.com>
25 Michael van Elst <mlelstv@NetBSD.org>
26 Mightyjo <mightyjo@gmail.com>
27 Mike Frysinger <vapier@gentoo.org>
28 OBATA Akio <obache@NetBSD.org>
29 Robert Larice <Robert.Larice@t-online.de> rlar <rlar>
30 Robert Larice <Robert.Larice@t-online.de> Robert.Larice Robert Larice <Robert.Larice@t-online.de>
31 Robert Minsk <rminsk@users.sourceforge.net>
32 Samuel Thibault <samuel.thibault@ens-lyon.org>
33 Sean McBride <sean@rogue-research.com>
34 Serguey Parkhomovsky <sergueyparkhomovsky@gmail.com> <xindigo@gmail.com>
35 Simon Sobisch <simonsobisch@web.de>
36 Stefan Reinauer <stefan.reinauer@coreboot.org>
37 Thomas Klausner <wiz@NetBSD.org>
38 Till Varoquaux <till.varoquaux@gmail.com>
39 Tobias Klauser <tklauser@distanz.ch>
40 Todd C. Miller <Todd.Miller@courtesan.com>
41 Translation Project <coordinator@translationproject.org> <coordinators@translationproject.org>
42 Translation Project <coordinator@translationproject.org> <translation@translationproject.org>
43 Vern Paxson <vern@ee.lbl.gov>
44 Will Estes <westes575@gmail.com> <wlestes@users.sourceforge.net>
45 Yuri <yuri@tsoft.com>
46 luistung <dongliang1986@gmail.com>
47 lukeallardyce <lukeallardyce@users.sourceforge.net>
48 nomis52 <nomis52@users.sourceforge.net>
49 viktor.shepel <shepelvictor@bigmir.net>
0 #!/bin/bash -ex
1
2 wget -nv https://ftp.gnu.org/gnu/automake/automake-1.15.1.tar.gz{,.sig}
3 gpg2 --keyserver hkp://keys.gnupg.net --recv-keys 94604D37
4 gpg2 automake-1.15.1.tar.gz.sig
5 tar xf automake-1.15.1.tar.gz
6 cd automake-1.15.1
7 ./configure --prefix=$HOME
8 make
9 make install
0 #!/bin/bash -ex
1
2 wget -nv https://ftp.gnu.org/gnu/gettext/gettext-0.19.8.1.tar.lz{,.sig}
3 gpg2 --keyserver hkp://keys.gnupg.net --recv-keys D7E69871
4 gpg2 gettext-0.19.8.1.tar.lz.sig
5 tar xf gettext-0.19.8.1.tar.lz
6 cd gettext-0.19.8.1
7 ./configure --prefix=$HOME
8 make
9 make install
0 language: c
1
2 compiler:
3 - gcc
4
5 addons:
6 apt:
7 sources:
8 - ubuntu-toolchain-r-test
9 packages:
10 - autoconf
11 - bison
12 - gcc-6
13 - help2man
14 - lzip
15 - texinfo
16 - texlive
17
18 before_script:
19 - ./.travis/install-gettext.sh
20 - ./.travis/install-automake.sh
21 - export PATH=$HOME/bin:$PATH
22
23 script: ./autogen.sh && ./configure && make && make check && make distcheck
4848 tests \
4949 tools
5050
51 # Convenience targets to build libfl only
52 # These are actually wrappers around automake- and libtool-generated targets
53
54 libfl:
55 cd src && $(MAKE) $(AM_MAKEFLAGS) libfl.la libfl.pc
56
57 install-libfl:
58 cd src && \
59 $(MAKE) $(AM_MAKEFLAGS) lib_LTLIBRARIES=libfl.la \
60 pkgconfig_DATA=libfl.pc install-libLTLIBRARIES install-pkgconfigDATA
61
62 uninstall-libfl:
63 cd src && \
64 $(MAKE) $(AM_MAKEFLAGS) \
65 lib_LTLIBRARIES=libfl.la pkgconfig_DATA=libfl.pc \
66 uninstall-libLTLIBRARIES uninstall-pkgconfigDATA
67
68 # libfl.pc is cleaned via 'distclean' target
69 clean-libfl:
70 cd src && \
71 $(MAKE) $(AM_MAKEFLAGS) lib_LTLIBRARIES=libfl.la clean-libLTLIBRARIES \
72 clean-libtool
73
5174 # Create the ChangeLog, but only if we're inside a git working directory
5275
5376 ChangeLog: $(srcdir)/tools/git2cl
6285 cd $(DESTDIR)$(bindir) && \
6386 $(LN_S) -f flex$(EXEEXT) flex++$(EXEEXT)
6487
65 .PHONY: ChangeLog indent
88 .PHONY: libfl install-libfl uninstall-libfl clean-libfl \
89 ChangeLog indent
00 flex NEWS
1
2 * Noteworthy changes in release ?.? (????-??-??) [?]
3
4 ** build
5
6 *** Flex now includes its own <config.h> header before including
7 system headers so that any system specific features detected by
8 configure are taken into account during compilation of flex
9 itself.
10
11 *** The flex build system now includes Makefile targets at the top
12 level to allow just building and installing libfl.
13
14 *** The flex distribution now includes a file, src/libfl.pc, to allow
15 using pkgconfig to find out what flags to use when building
16 against libfl from flex.
17
18 *** Various edge cases, mostly involving out-of-tree builds have been
19 accounted for in the autotools build system.
20
21 *** A crash during building on NetBSD has been fixed.
22
23 *** Flex is now automatically built by travis-ci. That should increase
24 the visibility of bugs and help prevent regressions.
25
26 ** documentation
27
28 *** a new Ukrainian translation has been submitted from the Translation Project.
29
30 ** scanner
31
32 *** Some memory leaks have been fixed.
33
34 *** A long standing bug that effected expressions of the form c{i,j}
35 where 'c' is a character and {i,j} describes the number of times
36 to match against 'c' when case sensitivity was turned on has been
37 fixed.
38
39 *** New option: --backup-file allows setting the name of the file
40 written containing backing up information. Useful if you need
41 backing up information from multiple scanners in the same
42 directory.
43
44 *** flex emits correct line number directives when line numbers refer
45 to the file containing the line number directives.
46
47 *** The options {no,}yy{get,set}_column are now supported.
48
49 ** test
50
51 *** Generating the various tableoptions make rules is now more portable.
52
53 *** Tests of the options -C*f and -C*F will now run correctly on
54 filesystems that are not case sensitive.
155
256 * Noteworthy changes in release 2.6.4 (2017-05-06) [stable]
357
3232 * COPYING - flex's copyright and license.
3333 * doc/ - user documentation.
3434 * examples/ - containing examples of some possible flex scanners and a
35 few other things. See the file examples/README for more
35 few other things. See the file examples/README for more
3636 details.
3737 * tests/ - regression tests. See TESTS/README for details.
3838 * po/ - internationalization support files.
4242
4343 * compiler suite - flex is built with gcc
4444 * bash, or a good Bourne-style shell
45 * m4 - m4 -p needs to work; GNU m4 and a few others are suitable
45 * m4 - `m4 -P` needs to work; GNU m4 and a few others are suitable
4646 * GNU bison; to generate parse.c from parse.y
4747 * autoconf; for handling the build system
4848 * automake; for Makefile generation
7373 This script calls the various tools needed to get flex ready for the
7474 GNU-style configure script to be able to work.
7575
76 From this point on, building flex follows the usual routine:
76 From this point on, building flex follows the usual routine:
7777
7878 ```bash
7979 configure && make && make install
8080 ```
81
82 ---
8183
8284 This file is part of flex.
8385
2424 # autoconf requirements and initialization
2525
2626 AC_INIT([the fast lexical analyser generator],[2.6.4],[flex-help@lists.sourceforge.net],[flex])
27 AC_PREREQ([2.60])
2728 AC_CONFIG_SRCDIR([src/scan.l])
2829 AC_CONFIG_AUX_DIR([build-aux])
30 AC_USE_SYSTEM_EXTENSIONS
2931 LT_INIT
30 AM_INIT_AUTOMAKE([1.11.3 -Wno-portability foreign check-news std-options dist-lzip parallel-tests subdir-objects])
32 AM_INIT_AUTOMAKE([1.15 -Wno-portability foreign std-options dist-lzip parallel-tests subdir-objects])
3133 AC_CONFIG_HEADER([src/config.h])
3234 AC_CONFIG_LIBOBJ_DIR([lib])
3335 AC_CONFIG_MACRO_DIR([m4])
3739 # checks for programs
3840
3941 AM_GNU_GETTEXT([external])
40 AM_GNU_GETTEXT_VERSION([0.18])
42 AM_GNU_GETTEXT_VERSION([0.19.7])
4143 AC_PROG_YACC
4244 AS_IF([test "$YACC" != 'bison -y'], [
4345 YACC="\${top_srcdir}/build-aux/missing bison -y"
5254 AC_PROG_LN_S
5355 AC_PROG_AWK
5456 AC_PROG_INSTALL
57
58 pkgconfigdir=${libdir}/pkgconfig
59 AC_SUBST(pkgconfigdir)
5560
5661 # allow passing a variable `WARNINGFLAGS',
5762 # either when invoking `configure', or when invoking `make'
165170 AC_CHECK_FUNCS([dnl
166171 pow dnl Used only by "examples/manual/expr"
167172 setlocale dnl Needed only if NLS is enabled
173 reallocarr dnl NetBSD function. Use reallocarray if not available.
168174 reallocarray dnl OpenBSD function. We have replacement if not available.
169175 ])
170176
175181 examples/fastwc/Makefile
176182 examples/manual/Makefile
177183 po/Makefile.in
184 src/libfl.pc
178185 src/Makefile
179186 tools/Makefile
180187 tests/Makefile
0 ca
1 da
2 de
3 en@quot
4 en@boldquot
5 eo
6 es
7 fi
8 fr
9 ga
10 hr
11 ko
12 nl
13 pl
14 pt_BR
15 ro
16 ru
17 sr
18 sv
19 tr
20 vi
21 zh_CN
22 zh_TW
0 # List of available languages.
1 ca da de en@boldquot en@quot eo es fi fr ga hr ko nl pl pt_BR ro ru sr sv tr uk vi zh_CN zh_TW
0 # Ukrainian translations for flex.
1 # Copyright (C) 2017 The Flex Project (msgids)
2 # This file is distributed under the same license as the flex package.
3 #
4 # Viktor Shepel <shepelvictor@bigmir.net>, 2017.
5 # Yuri Chornoivan <yurchor@ukr.net>, 2017.
6 msgid ""
7 msgstr ""
8 "Project-Id-Version: flex 2.5.38\n"
9 "Report-Msgid-Bugs-To: flex-devel@lists.sourceforge.net\n"
10 "POT-Creation-Date: 2017-05-24 18:00-0400\n"
11 "PO-Revision-Date: 2017-06-17 09:26+0300\n"
12 "Last-Translator: Yuri Chornoivan <yurchor@ukr.net>\n"
13 "Language-Team: Ukrainian <translation-team-uk@lists.sourceforge.net>\n"
14 "Language: uk\n"
15 "MIME-Version: 1.0\n"
16 "Content-Type: text/plain; charset=UTF-8\n"
17 "Content-Transfer-Encoding: 8bit\n"
18 "X-Bugs: Report translation errors to the Language-Team address.\n"
19 "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
20 "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
21 "X-Generator: Lokalize 1.5\n"
22
23 #: src/buf.c:79
24 msgid "Allocation of buffer to print string failed"
25 msgstr "Не вдалось виділити буфер для рядка, що виводиться"
26
27 #: src/buf.c:107
28 msgid "Allocation of buffer for line directive failed"
29 msgstr "Не вдалось виділити буфер для рядкової директиви"
30
31 #: src/buf.c:177
32 msgid "Allocation of buffer for m4 def failed"
33 msgstr "Не вдалось виділити буфер для m4 def"
34
35 #: src/buf.c:198
36 msgid "Allocation of buffer for m4 undef failed"
37 msgstr "Не вдалось виділити буфер для m4 undef"
38
39 #: src/dfa.c:59
40 #, c-format
41 msgid "State #%d is non-accepting -\n"
42 msgstr "Стан #%d не є допустимим -\n"
43
44 #: src/dfa.c:119
45 msgid "dangerous trailing context"
46 msgstr "небезпечний замикаючий контекст"
47
48 #: src/dfa.c:159
49 #, c-format
50 msgid " associated rule line numbers:"
51 msgstr " номера рядків асоційованого правила:"
52
53 #: src/dfa.c:193
54 #, c-format
55 msgid " out-transitions: "
56 msgstr " out-переходи: "
57
58 #: src/dfa.c:201
59 #, c-format
60 msgid ""
61 "\n"
62 " jam-transitions: EOF "
63 msgstr ""
64 "\n"
65 " jam-переходи: EOF "
66
67 #: src/dfa.c:331
68 msgid "consistency check failed in epsclosure()"
69 msgstr "помилка при перевірці на цілісність у epsclosure()"
70
71 #: src/dfa.c:419
72 msgid ""
73 "\n"
74 "\n"
75 "DFA Dump:\n"
76 "\n"
77 msgstr ""
78 "\n"
79 "\n"
80 "Дамп ДСА:\n"
81 "\n"
82
83 #: src/dfa.c:587
84 msgid "could not create unique end-of-buffer state"
85 msgstr "неможливо створити унікальний стан end_of_buffer"
86
87 #: src/dfa.c:608
88 #, c-format
89 msgid "state # %d:\n"
90 msgstr "стан # %d:\n"
91
92 #: src/dfa.c:768
93 msgid "Could not write yynxt_tbl[][]"
94 msgstr "Неможливо записати yynxt_tbl[][]"
95
96 #: src/dfa.c:1028
97 msgid "bad transition character detected in sympartition()"
98 msgstr "виявлено невірний символ переходу в sympartition()"
99
100 #: src/gen.c:480
101 msgid ""
102 "\n"
103 "\n"
104 "Equivalence Classes:\n"
105 "\n"
106 msgstr ""
107 "\n"
108 "\n"
109 "Класи еквівалентності:\n"
110 "\n"
111
112 #: src/gen.c:669 src/gen.c:698 src/gen.c:1218
113 #, c-format
114 msgid "state # %d accepts: [%d]\n"
115 msgstr "стан # %d приймає: [%d]\n"
116
117 #: src/gen.c:1115
118 #, c-format
119 msgid "state # %d accepts: "
120 msgstr "стан # %d приймає: "
121
122 #: src/gen.c:1162
123 msgid "Could not write yyacclist_tbl"
124 msgstr "Неможливо записати yyacclist_tbl"
125
126 #: src/gen.c:1236
127 msgid "Could not write yyacc_tbl"
128 msgstr "Неможливо записати yyacc_tbl"
129
130 #: src/gen.c:1251 src/gen.c:1623 src/gen.c:1646
131 msgid "Could not write ecstbl"
132 msgstr "Неможливо записати ecstbl"
133
134 #: src/gen.c:1271
135 msgid ""
136 "\n"
137 "\n"
138 "Meta-Equivalence Classes:\n"
139 msgstr ""
140 "\n"
141 "\n"
142 "Мета-Еквівалентні Класи:\n"
143
144 #: src/gen.c:1293
145 msgid "Could not write yymeta_tbl"
146 msgstr "Неможливо записати yymeta_tbl"
147
148 #: src/gen.c:1352
149 msgid "Could not write yybase_tbl"
150 msgstr "Неможливо записати yybase_tbl"
151
152 #: src/gen.c:1384
153 msgid "Could not write yydef_tbl"
154 msgstr "Неможливо записати yydef_tbl"
155
156 #: src/gen.c:1422
157 msgid "Could not write yynxt_tbl"
158 msgstr "Неможливо записати yynxt_tbl"
159
160 #: src/gen.c:1456
161 msgid "Could not write yychk_tbl"
162 msgstr "Неможливо записати yychk_tbl"
163
164 #: src/gen.c:1608 src/gen.c:1637
165 msgid "Could not write ftbl"
166 msgstr "Неможливо записати ftbl"
167
168 #: src/gen.c:1614
169 msgid "Could not write ssltbl"
170 msgstr "Неможливо записати ssltbl"
171
172 #: src/gen.c:1665
173 msgid "Could not write eoltbl"
174 msgstr "Неможливо записати eoltbl"
175
176 #: src/gen.c:1722
177 msgid "Could not write yynultrans_tbl"
178 msgstr "Неможливо записати yynultrans_tbl"
179
180 #: src/main.c:178
181 msgid "rule cannot be matched"
182 msgstr "неможливо застосувати правило"
183
184 #: src/main.c:183
185 msgid "-s option given but default rule can be matched"
186 msgstr ""
187 "вказано параметр -s, але правило за замовчуванням може бути застосоване"
188
189 #: src/main.c:221
190 msgid "Can't use -+ with -l option"
191 msgstr "Неможливо використовувати -+ з параметром -l"
192
193 #: src/main.c:224
194 msgid "Can't use -f or -F with -l option"
195 msgstr "Неможливо використовувати -f або -F з параметром -l"
196
197 #: src/main.c:228
198 msgid "Can't use --reentrant or --bison-bridge with -l option"
199 msgstr ""
200 "Неможливо використовувати --reentrant або --bison-bridge з параметром -l"
201
202 #: src/main.c:260
203 msgid "-Cf/-CF and -Cm don't make sense together"
204 msgstr "Параметри -Cf/-CF і -Cm разом не мають сенсу"
205
206 #: src/main.c:263
207 msgid "-Cf/-CF and -I are incompatible"
208 msgstr "Параметри -Cf/-CF і -I несумісні"
209
210 #: src/main.c:267
211 msgid "-Cf/-CF are incompatible with lex-compatibility mode"
212 msgstr "Параметри -Cf/-CF несумісні з режимом lex-compatibility"
213
214 #: src/main.c:272
215 msgid "-Cf and -CF are mutually exclusive"
216 msgstr "Параметри -Cf і -CF є взаємовиключними"
217
218 #: src/main.c:276
219 msgid "Can't use -+ with -CF option"
220 msgstr "Неможливо використовувати -+ з параметром -CF"
221
222 #: src/main.c:279
223 #, c-format
224 msgid "%array incompatible with -+ option"
225 msgstr "%array несумісний з параметром -+"
226
227 #: src/main.c:284
228 msgid "Options -+ and --reentrant are mutually exclusive."
229 msgstr "Параметри -+ і --reentrant є взаємовиключними."
230
231 #: src/main.c:287
232 msgid "bison bridge not supported for the C++ scanner."
233 msgstr "bison bridge не підтримується для сканера C++."
234
235 #: src/main.c:336 src/main.c:419
236 #, c-format
237 msgid "could not create %s"
238 msgstr "неможливо створити %s"
239
240 #: src/main.c:431
241 msgid "could not write tables header"
242 msgstr "Неможливо записати заголовок таблиць"
243
244 #: src/main.c:435
245 #, c-format
246 msgid "can't open skeleton file %s"
247 msgstr "Неможливо відкрити файл-каркас %s"
248
249 #: src/main.c:450
250 msgid "Prefix cannot include '[' or ']'"
251 msgstr "Префікс не може містити «[» або «]»"
252
253 #: src/main.c:474
254 msgid "allocation of macro definition failed"
255 msgstr "Не вдалось розмістити визначення макросу"
256
257 #: src/main.c:521
258 #, c-format
259 msgid "input error reading skeleton file %s"
260 msgstr "помилка читання файла-каркаса %s"
261
262 #: src/main.c:525
263 #, c-format
264 msgid "error closing skeleton file %s"
265 msgstr "помилка при закритті файла-каркаса %s"
266
267 #: src/main.c:711
268 #, c-format
269 msgid "error creating header file %s"
270 msgstr "помилка створення файла-заголовку %s"
271
272 #: src/main.c:719
273 #, c-format
274 msgid "error writing output file %s"
275 msgstr "помилка запису у вихідний файл %s"
276
277 #: src/main.c:723
278 #, c-format
279 msgid "error closing output file %s"
280 msgstr "помилка закриття вихідного файла %s"
281
282 #: src/main.c:727
283 #, c-format
284 msgid "error deleting output file %s"
285 msgstr "помилка видалення вихідного файла %s"
286
287 #: src/main.c:734
288 #, c-format
289 msgid "No backing up.\n"
290 msgstr "Резервне копіювання вимкнено.\n"
291
292 #: src/main.c:738
293 #, c-format
294 msgid "%d backing up (non-accepting) states.\n"
295 msgstr "резервне копіювання %d (недопустимих) станів.\n"
296
297 #: src/main.c:742
298 #, c-format
299 msgid "Compressed tables always back up.\n"
300 msgstr "Створення резервних копій стислих таблиць виконується завжди.\n"
301
302 #: src/main.c:745
303 #, c-format
304 msgid "error writing backup file %s"
305 msgstr "помилка запису резервної копії файла %s"
306
307 #: src/main.c:749
308 #, c-format
309 msgid "error closing backup file %s"
310 msgstr "помилка закриття резервної копії файла %s"
311
312 #: src/main.c:754
313 #, c-format
314 msgid "%s version %s usage statistics:\n"
315 msgstr "статистика використання %s версії %s:\n"
316
317 #: src/main.c:757
318 #, c-format
319 msgid " scanner options: -"
320 msgstr " параметри сканера: -"
321
322 #: src/main.c:836
323 #, c-format
324 msgid " %d/%d NFA states\n"
325 msgstr " %d/%d станів НСА\n"
326
327 #: src/main.c:838
328 #, c-format
329 msgid " %d/%d DFA states (%d words)\n"
330 msgstr " %d/%d станів ДСА (%d слів)\n"
331
332 #: src/main.c:840
333 #, c-format
334 msgid " %d rules\n"
335 msgstr " %d правил\n"
336
337 #: src/main.c:845
338 #, c-format
339 msgid " No backing up\n"
340 msgstr " Резервне копіювання вимкнено\n"
341
342 #: src/main.c:849
343 #, c-format
344 msgid " %d backing-up (non-accepting) states\n"
345 msgstr " резервне копіювання %d (недопустимих) станів\n"
346
347 #: src/main.c:854
348 #, c-format
349 msgid " Compressed tables always back-up\n"
350 msgstr " Створення резервних копій стислих таблиць виконується завжди\n"
351
352 #: src/main.c:858
353 #, c-format
354 msgid " Beginning-of-line patterns used\n"
355 msgstr " Використовуються шаблони початку рядка\n"
356
357 #: src/main.c:860
358 #, c-format
359 msgid " %d/%d start conditions\n"
360 msgstr " %d/%d початкових умов\n"
361
362 #: src/main.c:864
363 #, c-format
364 msgid " %d epsilon states, %d double epsilon states\n"
365 msgstr " %d епсилон-станів, %d подвійних епсилон-станів\n"
366
367 #: src/main.c:868
368 #, c-format
369 msgid " no character classes\n"
370 msgstr " відсутні класи символів\n"
371
372 #: src/main.c:872
373 #, c-format
374 msgid " %d/%d character classes needed %d/%d words of storage, %d reused\n"
375 msgstr ""
376 " %d/%d символьних класів потребують %d/%d слів для зберігання, %d "
377 "використано вдруге\n"
378
379 #: src/main.c:877
380 #, c-format
381 msgid " %d state/nextstate pairs created\n"
382 msgstr " створено %d пар стан/наступний-стан\n"
383
384 #: src/main.c:880
385 #, c-format
386 msgid " %d/%d unique/duplicate transitions\n"
387 msgstr " %d/%d унікальних/повторюваних переходів\n"
388
389 #: src/main.c:885
390 #, c-format
391 msgid " %d table entries\n"
392 msgstr " %d елементів таблиці\n"
393
394 #: src/main.c:893
395 #, c-format
396 msgid " %d/%d base-def entries created\n"
397 msgstr " створено %d/%d base-def елементів\n"
398
399 #: src/main.c:897
400 #, c-format
401 msgid " %d/%d (peak %d) nxt-chk entries created\n"
402 msgstr " створено %d/%d (пік %d) записів nxt-chk\n"
403
404 #: src/main.c:901
405 #, c-format
406 msgid " %d/%d (peak %d) template nxt-chk entries created\n"
407 msgstr " створено %d/%d (пік %d) шаблонних записів nxt-chk\n"
408
409 #: src/main.c:905
410 #, c-format
411 msgid " %d empty table entries\n"
412 msgstr " %d порожніх елементів таблиці\n"
413
414 #: src/main.c:907
415 #, c-format
416 msgid " %d protos created\n"
417 msgstr " створено %d прототипів\n"
418
419 #: src/main.c:910
420 #, c-format
421 msgid " %d templates created, %d uses\n"
422 msgstr " створено %d шаблонів, %d використовується\n"
423
424 #: src/main.c:918
425 #, c-format
426 msgid " %d/%d equivalence classes created\n"
427 msgstr " створено класів еквівалентності %d/%d\n"
428
429 #: src/main.c:926
430 #, c-format
431 msgid " %d/%d meta-equivalence classes created\n"
432 msgstr " створено класів мета-еквівалентності %d/%d\n"
433
434 #: src/main.c:932
435 #, c-format
436 msgid " %d (%d saved) hash collisions, %d DFAs equal\n"
437 msgstr " %d (%d записано) колізій хеш-таблиці, %d еквівалентних ДСА\n"
438
439 #: src/main.c:934
440 #, c-format
441 msgid " %d sets of reallocations needed\n"
442 msgstr " потрібно %d наборів повторних розміщень\n"
443
444 #: src/main.c:936
445 #, c-format
446 msgid " %d total table entries needed\n"
447 msgstr " всього потрібно %d елементів таблиці\n"
448
449 #: src/main.c:1010
450 #, c-format
451 msgid "Internal error. flexopts are malformed.\n"
452 msgstr "Внутрішня помилка. Неправильне значення flexopts.\n"
453
454 #: src/main.c:1020
455 #, c-format
456 msgid "Try `%s --help' for more information.\n"
457 msgstr "Спробуйте «%s --help» для отримання більш докладного опису.\n"
458
459 #: src/main.c:1077
460 #, c-format
461 msgid "unknown -C option '%c'"
462 msgstr "невідоме значення «%c» для параметру -C"
463
464 #: src/main.c:1206
465 #, c-format
466 msgid "%s %s\n"
467 msgstr "%s %s\n"
468
469 #: src/main.c:1486
470 msgid "fatal parse error"
471 msgstr "фатальна помилка розбору"
472
473 #: src/main.c:1518
474 #, c-format
475 msgid "could not create backing-up info file %s"
476 msgstr "неможливо створити резервну копію інформаційного файла %s"
477
478 #: src/main.c:1539
479 #, c-format
480 msgid "-l AT&T lex compatibility option entails a large performance penalty\n"
481 msgstr ""
482 "Параметр -l сумісності з AT&T lex спричиняє значне зниження продуктивності\n"
483
484 #: src/main.c:1542
485 #, c-format
486 msgid " and may be the actual source of other reported performance penalties\n"
487 msgstr "і також може бути істинним джерелом проблем з продуктивністю\n"
488
489 #: src/main.c:1548
490 #, c-format
491 msgid ""
492 "%%option yylineno entails a performance penalty ONLY on rules that can match "
493 "newline characters\n"
494 msgstr ""
495 "%%option yylineno спричиняе значне зниження продуктивності ТІЛЬКИ для "
496 "правил, котрі описують символи нового рядка\n"
497
498 #: src/main.c:1555
499 #, c-format
500 msgid "-I (interactive) entails a minor performance penalty\n"
501 msgstr "-I (інтерактивний) спричиняе незначне зниження продуктивності\n"
502
503 #: src/main.c:1560
504 #, c-format
505 msgid "yymore() entails a minor performance penalty\n"
506 msgstr "yymore() спричиняе незначне зниження продуктивності\n"
507
508 #: src/main.c:1566
509 #, c-format
510 msgid "REJECT entails a large performance penalty\n"
511 msgstr "REJECT спричиняе значне зниження продуктивності\n"
512
513 #: src/main.c:1571
514 #, c-format
515 msgid "Variable trailing context rules entail a large performance penalty\n"
516 msgstr ""
517 "Правила котрі мають замикаючий контекст змінної довжини значно знижують "
518 "продуктивність\n"
519
520 #: src/main.c:1583
521 msgid "REJECT cannot be used with -f or -F"
522 msgstr "REJECT не може бути використано разом з -f або -F"
523
524 #: src/main.c:1586
525 #, c-format
526 msgid "%option yylineno cannot be used with REJECT"
527 msgstr "%option yylineno не може бути використано з REJECT"
528
529 #: src/main.c:1589
530 msgid "variable trailing context rules cannot be used with -f or -F"
531 msgstr ""
532 "Правила котрі мають замикаючий контекст змінної довжини не можуть бути "
533 "використані з -f or -F"
534
535 #: src/main.c:1714
536 #, c-format
537 msgid "%option yyclass only meaningful for C++ scanners"
538 msgstr "%option yyclass має сенс тільки для сканерів C++"
539
540 #: src/main.c:1801
541 #, c-format
542 msgid "Usage: %s [OPTIONS] [FILE]...\n"
543 msgstr "Використання: %s [ПАРАМЕТРИ] [ФАЙЛ]…\n"
544
545 #: src/main.c:1804
546 #, fuzzy, c-format
547 msgid ""
548 "Generates programs that perform pattern-matching on text.\n"
549 "\n"
550 "Table Compression:\n"
551 " -Ca, --align trade off larger tables for better memory alignment\n"
552 " -Ce, --ecs construct equivalence classes\n"
553 " -Cf do not compress tables; use -f representation\n"
554 " -CF do not compress tables; use -F representation\n"
555 " -Cm, --meta-ecs construct meta-equivalence classes\n"
556 " -Cr, --read use read() instead of stdio for scanner input\n"
557 " -f, --full generate fast, large scanner. Same as -Cfr\n"
558 " -F, --fast use alternate table representation. Same as -CFr\n"
559 " -Cem default compression (same as --ecs --meta-ecs)\n"
560 "\n"
561 "Debugging:\n"
562 " -d, --debug enable debug mode in scanner\n"
563 " -b, --backup write backing-up information to %s\n"
564 " -p, --perf-report write performance report to stderr\n"
565 " -s, --nodefault suppress default rule to ECHO unmatched text\n"
566 " -T, --trace %s should run in trace mode\n"
567 " -w, --nowarn do not generate warnings\n"
568 " -v, --verbose write summary of scanner statistics to stdout\n"
569 " --hex use hexadecimal numbers instead of octal in debug "
570 "outputs\n"
571 "\n"
572 "Files:\n"
573 " -o, --outfile=FILE specify output filename\n"
574 " -S, --skel=FILE specify skeleton file\n"
575 " -t, --stdout write scanner on stdout instead of %s\n"
576 " --yyclass=NAME name of C++ class\n"
577 " --header-file=FILE create a C header file in addition to the "
578 "scanner\n"
579 " --tables-file[=FILE] write tables to FILE\n"
580 "\n"
581 "Scanner behavior:\n"
582 " -7, --7bit generate 7-bit scanner\n"
583 " -8, --8bit generate 8-bit scanner\n"
584 " -B, --batch generate batch scanner (opposite of -I)\n"
585 " -i, --case-insensitive ignore case in patterns\n"
586 " -l, --lex-compat maximal compatibility with original lex\n"
587 " -X, --posix-compat maximal compatibility with POSIX lex\n"
588 " -I, --interactive generate interactive scanner (opposite of -B)\n"
589 " --yylineno track line count in yylineno\n"
590 "\n"
591 "Generated code:\n"
592 " -+, --c++ generate C++ scanner class\n"
593 " -Dmacro[=defn] #define macro defn (default defn is '1')\n"
594 " -L, --noline suppress #line directives in scanner\n"
595 " -P, --prefix=STRING use STRING as prefix instead of \"yy\"\n"
596 " -R, --reentrant generate a reentrant C scanner\n"
597 " --bison-bridge scanner for bison pure parser.\n"
598 " --bison-locations include yylloc support.\n"
599 " --stdinit initialize yyin/yyout to stdin/stdout\n"
600 " --nounistd do not include <unistd.h>\n"
601 " --noFUNCTION do not generate a particular FUNCTION\n"
602 "\n"
603 "Miscellaneous:\n"
604 " -c do-nothing POSIX option\n"
605 " -n do-nothing POSIX option\n"
606 " -?\n"
607 " -h, --help produce this help message\n"
608 " -V, --version report %s version\n"
609 msgstr ""
610 "Генерує програми, що знаходять шаблони у тексті.\n"
611 "\n"
612 "Стиснення таблиць:\n"
613 " -Ca, --align вирівняти таблиці у пам'яті збільшивши розмір\n"
614 " їх елементів\n"
615 " -Ce, --ecs створювати класи еквівалентності\n"
616 " -Cf не стискати таблиці; використовувати -f представлення\n"
617 " -CF не стискати таблиці; використовувати -F представлення\n"
618 " -Cm, --meta-ecs створювати класи мета-еквівалентності\n"
619 " -Cr, --read використати read() замість stdio як\n"
620 " вхідні дані сканера\n"
621 " -f, --full створити швидкий, великий сканер. Теж саме, що -Cfr\n"
622 " -F, --fast застосувати альтернативний опис таблиць.\n"
623 " Теж саме, що -CFr\n"
624 " -Cem степінь стиснення за замовчуванням\n"
625 " (теж саме, що --ecs --meta-ecs)\n"
626 "\n"
627 "Налагодження:\n"
628 " -d, --debug увімкнути режим налагодження сканера\n"
629 " -b, --backup записати резервну копію до %s\n"
630 " -p, --perf-report записати звіт про продуктивність до stderr\n"
631 " -s, --nodefault припинити вивід тексту (ECHO до stdout)\n"
632 " що не збігається з жодним правилом\n"
633 " -T, --trace %s повинен запускатися у режимі трасування\n"
634 " -w, --nowarn не видавати попереджень\n"
635 " -v, --verbose записати підсумкову статистику сканера до stdout\n"
636 "\n"
637 "Файли:\n"
638 " -o, --outfile=ФАЙЛ вказати ім'я вихідного файла\n"
639 " -S, --skel=ФАЙЛ вказати файл каркасу\n"
640 " -t, --stdout записати сканер до stdout замість %s\n"
641 " --yyclass=ІМ'Я ім'я класу C++\n"
642 " --header-file=ФАЙЛ створити C файл заголовок сканера\n"
643 " --tables-file[=ФАЙЛ] записати таблиці у ФАЙЛ\n"
644 "\n"
645 "Поведінка сканера:\n"
646 " -7, --7bit створити 7-бітний сканер\n"
647 " -8, --8bit створити 8-бітний сканер\n"
648 " -B, --batch створити пакетний сканер\n"
649 " (протилежна за властивостями до опції -I)\n"
650 " -i, --case-insensitive ігнорувати регістр символів у шаблонах\n"
651 " -l, --lex-compat максимальна сумісність з оригінальним lex\n"
652 " -X, --posix-compat максимальна сумісність з POSIX lex\n"
653 " -I, --interactive створити інтерактивний сканер\n"
654 " (протилежна за властивостями до опції -B)\n"
655 " --yylineno відслідковувати число рядків у yylineno\n"
656 "\n"
657 "Генерація коду:\n"
658 " -+, --c++ створити C++ клас сканера\n"
659 " -Dmacro[=defn] #define macro defn (за замовчуванням defn='1')\n"
660 " -L, --noline не створювати #line директиви для сканера\n"
661 " -P, --prefix=РЯДОК використати РЯДОК як префікс замість «yy»\n"
662 " -R, --reentrant генерувати реентерабельний C-сканер\n"
663 " --bison-bridge сканер тільки для bison аналізатору\n"
664 " --bison-locations додати підтримку yylloc\n"
665 " --stdinit ініціалізувати yyin/yyout до stdin/stdout\n"
666 " --noansi-definitions визначення функцій у застарілому стилі\n"
667 " --noansi-prototypes порожній список параметрів у прототипах\n"
668 " --nounistd не додавати <unistd.h>\n"
669 " --noФУНКЦІЯ не генерувати задану функцію ФУНКЦІЯ\n"
670 "\n"
671 "Інше:\n"
672 " -с недіючий POSIX параметр\n"
673 " -n недіючий POSIX параметр\n"
674 " -?\n"
675 " -h, --help показати цю довідку\n"
676 " -V, --version показати версію %s\n"
677
678 #: src/misc.c:64
679 msgid "allocation of sko_stack failed"
680 msgstr "не вдалось отримати пам’ять під sko_stack"
681
682 #: src/misc.c:100
683 #, c-format
684 msgid "name \"%s\" ridiculously long"
685 msgstr "ім'я «%s» занадто довге"
686
687 #: src/misc.c:149 src/misc.c:162
688 msgid "memory allocation failed in allocate_array()"
689 msgstr "помилка виділення пам'яті у allocate_array()"
690
691 #: src/misc.c:212
692 #, c-format
693 msgid "bad character '%s' detected in check_char()"
694 msgstr "check_char() виявив недопустимий символ «%s»"
695
696 #: src/misc.c:217
697 #, c-format
698 msgid "scanner requires -8 flag to use the character %s"
699 msgstr "для використання символу %s сканер потребує опцію -8"
700
701 #: src/misc.c:236
702 msgid "memory allocation failure in xstrdup()"
703 msgstr "помилка виділення пам'яті у xstrdup()"
704
705 #: src/misc.c:310
706 #, c-format
707 msgid "%s: fatal internal error, %s\n"
708 msgstr "%s: фатальна внутрішня помилка, %s\n"
709
710 #: src/misc.c:671 src/misc.c:683
711 msgid "attempt to increase array size failed"
712 msgstr "помилка при спробі збільшити розмір масиву"
713
714 #: src/misc.c:807
715 msgid "bad line in skeleton file"
716 msgstr "невідомий рядок у файлі-каркасі"
717
718 #: src/misc.c:857
719 msgid "memory allocation failed in yy_flex_xmalloc()"
720 msgstr "помилка виділення пам'яті у yy_flex_xmalloc()"
721
722 #: src/nfa.c:100
723 #, c-format
724 msgid ""
725 "\n"
726 "\n"
727 "********** beginning dump of nfa with start state %d\n"
728 msgstr ""
729 "\n"
730 "\n"
731 "********** початок дампу НСА з початковим станом %d\n"
732
733 #: src/nfa.c:111
734 #, c-format
735 msgid "state # %4d\t"
736 msgstr "стан # %4d\t"
737
738 #: src/nfa.c:126
739 #, c-format
740 msgid "********** end of dump\n"
741 msgstr "********** кінець дампу\n"
742
743 #: src/nfa.c:169
744 msgid "empty machine in dupmachine()"
745 msgstr "порожній автомат у dupmachine()"
746
747 #: src/nfa.c:234
748 #, c-format
749 msgid "Variable trailing context rule at line %d\n"
750 msgstr "Правило із замикаючим контекстом змінної довжини у стрічці %d\n"
751
752 #: src/nfa.c:357
753 msgid "bad state type in mark_beginning_as_normal()"
754 msgstr "невідомий тип стану у mark_beginning_as_normal()"
755
756 #: src/nfa.c:595
757 #, c-format
758 msgid "input rules are too complicated (>= %d NFA states)"
759 msgstr "вхідні правила занадто складні (>= %d станів НСА)"
760
761 #: src/nfa.c:673
762 msgid "found too many transitions in mkxtion()"
763 msgstr "знайдено занадто багато переходів у mkxtion()"
764
765 #: src/nfa.c:699
766 #, c-format
767 msgid "too many rules (> %d)!"
768 msgstr "занадто багато правил (> %d)!"
769
770 #: src/parse.y:159
771 msgid "unknown error processing section 1"
772 msgstr "невідома помилка при обробці розділу 1"
773
774 #: src/parse.y:184 src/parse.y:353
775 msgid "bad start condition list"
776 msgstr "невірний список початкових умов"
777
778 #: src/parse.y:204
779 msgid "Prefix must not contain [ or ]"
780 msgstr "Префікс не може містити символи «[» або «]»"
781
782 #: src/parse.y:317
783 msgid "unrecognized rule"
784 msgstr "нерозпізнане правило"
785
786 #: src/parse.y:436 src/parse.y:449 src/parse.y:518
787 msgid "trailing context used twice"
788 msgstr "замикаючий контекст використано двічі"
789
790 #: src/parse.y:554 src/parse.y:564 src/parse.y:637 src/parse.y:647
791 msgid "bad iteration values"
792 msgstr "невірно сформований діапазон ітерацій"
793
794 #: src/parse.y:582 src/parse.y:600 src/parse.y:665 src/parse.y:683
795 msgid "iteration value must be positive"
796 msgstr "кількість ітерацій повинна бути додатнім числом"
797
798 #: src/parse.y:806 src/parse.y:816
799 #, c-format
800 msgid "the character range [%c-%c] is ambiguous in a case-insensitive scanner"
801 msgstr ""
802 "використання діапазону символів [%c-%c] є двозначним для сканера, що не "
803 "чутливий до регістру символів"
804
805 #: src/parse.y:821
806 msgid "negative range in character class"
807 msgstr ""
808 "символьний клас описано діапазоном, перший елемент котрого більший за "
809 "останній"
810
811 #: src/parse.y:918
812 msgid "[:^lower:] is ambiguous in case insensitive scanner"
813 msgstr ""
814 "використання [:^lower:] є невизначеним для сканера, що не чутливий до "
815 "регістру символів"
816
817 #: src/parse.y:924
818 msgid "[:^upper:] ambiguous in case insensitive scanner"
819 msgstr ""
820 "використання [:^upper:] є невизначеним для сканера, що не чутливий до "
821 "регістру символів"
822
823 #: src/scan.l:82 src/scan.l:646 src/scan.l:704
824 msgid "Input line too long\n"
825 msgstr "Занадто довгий вхідний рядок\n"
826
827 #: src/scan.l:183
828 #, c-format
829 msgid "malformed '%top' directive"
830 msgstr "нерозпізнана директива «%top»"
831
832 #: src/scan.l:205
833 #, no-c-format
834 msgid "unrecognized '%' directive"
835 msgstr "нерозпізнана директива «%»"
836
837 #: src/scan.l:214
838 msgid "Definition name too long\n"
839 msgstr "Визначення має занадто довге ім'я\n"
840
841 #: src/scan.l:309
842 msgid "Unmatched '{'"
843 msgstr "Непарна «{»"
844
845 #: src/scan.l:325
846 #, c-format
847 msgid "Definition value for {%s} too long\n"
848 msgstr "Визначення {%s} має занадто довге значення\n"
849
850 #: src/scan.l:342
851 msgid "incomplete name definition"
852 msgstr "неповне визначення імені"
853
854 #: src/scan.l:469
855 msgid "Option line too long\n"
856 msgstr "Занадто довгий параметр\n"
857
858 #: src/scan.l:477
859 #, c-format
860 msgid "unrecognized %%option: %s"
861 msgstr "нерозпізнаний %%option: %s"
862
863 #: src/scan.l:661 src/scan.l:834
864 msgid "bad character class"
865 msgstr "помилковий символьний клас"
866
867 #: src/scan.l:711
868 #, c-format
869 msgid "undefined definition {%s}"
870 msgstr "нерозпізнане визначення {%s}"
871
872 #: src/scan.l:774
873 msgid "unbalanced parenthesis"
874 msgstr "незбалансовані круглі дужки"
875
876 #: src/scan.l:789
877 #, c-format
878 msgid "bad <start condition>: %s"
879 msgstr "невірно сформованана <умова, що активує правило>: %s"
880
881 #: src/scan.l:802
882 msgid "missing quote"
883 msgstr "відсутні лапки"
884
885 #: src/scan.l:868
886 #, c-format
887 msgid "bad character class expression: %s"
888 msgstr "символьний клас заданий некоректним виразом: %s"
889
890 #: src/scan.l:890
891 msgid "bad character inside {}'s"
892 msgstr "неприйнятний символ всередині {}"
893
894 #: src/scan.l:896
895 msgid "missing }"
896 msgstr "відсутній }"
897
898 #: src/scan.l:974
899 msgid "EOF encountered inside an action"
900 msgstr "знайдено EOF всередині коду котрий асоційований з правилом"
901
902 #: src/scan.l:979
903 msgid "EOF encountered inside pattern"
904 msgstr "знайдено EOF всередині шаблону, що задає правило"
905
906 #: src/scan.l:1012
907 #, c-format
908 msgid "bad character: %s"
909 msgstr "неочікуваний символ: %s"
910
911 #: src/scan.l:1040
912 #, c-format
913 msgid "can't open %s"
914 msgstr "неможливо відкрити %s"
915
916 #: src/scanopt.c:259
917 #, c-format
918 msgid "Usage: %s [OPTIONS]...\n"
919 msgstr "Використання: %s [ПАРАМЕТРИ]…\n"
920
921 #: src/scanopt.c:524
922 #, c-format
923 msgid "option `%s' doesn't allow an argument\n"
924 msgstr "параметр «%s» повинен використовуватись без аргументу\n"
925
926 #: src/scanopt.c:529
927 #, c-format
928 msgid "option `%s' requires an argument\n"
929 msgstr "параметр «% s» повинен використовуватись з аргументом\n"
930
931 #: src/scanopt.c:533
932 #, c-format
933 msgid "option `%s' is ambiguous\n"
934 msgstr "параметр «%s» є двозначним\n"
935
936 #: src/scanopt.c:537
937 #, c-format
938 msgid "Unrecognized option `%s'\n"
939 msgstr "Нерозпізнаний параметр «%s»\n"
940
941 #: src/scanopt.c:541
942 #, c-format
943 msgid "Unknown error=(%d)\n"
944 msgstr "Невідома помилка=(%d)\n"
945
946 #: src/sym.c:92
947 msgid "symbol table memory allocation failed"
948 msgstr "помилка виділення пам'яті для таблиці символів"
949
950 #: src/sym.c:183
951 msgid "name defined twice"
952 msgstr "ім'я визначено двічі"
953
954 #: src/sym.c:231
955 #, c-format
956 msgid "start condition %s declared twice"
957 msgstr "початкова умова %s описана двічі"
958
959 #: src/yylex.c:57
960 msgid "premature EOF"
961 msgstr "неочікуваний EOF"
962
963 #: src/yylex.c:200
964 #, c-format
965 msgid "End Marker\n"
966 msgstr "Мітка кінця\n"
967
968 #: src/yylex.c:206
969 #, c-format
970 msgid "*Something Weird* - tok: %d val: %d\n"
971 msgstr "*Щось не так* — tok: %d val: %d\n"
972
973 #~ msgid "dynamic memory failure in copy_string()"
974 #~ msgstr "помилка під час роботи з динамічною пам’яттю у copy_string()"
00 AM_YFLAGS = -d
11 AM_CPPFLAGS = -DLOCALEDIR=\"$(localedir)\"
22 LIBS = @LIBS@
3 pkgconfigdir = @pkgconfigdir@
34
45 m4 = @M4@
56
1011
1112 if ENABLE_LIBFL
1213 lib_LTLIBRARIES = libfl.la
14 pkgconfig_DATA = libfl.pc
1315 endif
1416 libfl_la_SOURCES = \
1517 libmain.c \
7779 yylex.c
7880
7981 LDADD = $(LIBOBJS) @LIBINTL@
82
83 $(LIBOBJS): $(LIBOBJDIR)$(am__dirstamp)
8084
8185 include_HEADERS = \
8286 FlexLexer.h
7171 ccl_has_nl[cclp] = true;
7272
7373 newpos = ind + len;
74
75 /* For a non-last cclp, expanding the set will overflow and overwrite a
76 * char in the next cclp.
77 * FIXME: Need another allocation scheme for ccl's. */
78 if (cclp != lastccl) {
79 flexfatal(_("internal error: trying to add a char to a non-last ccl.\n"));
80 }
7481
7582 if (newpos >= current_max_ccl_tbl_size) {
7683 current_max_ccl_tbl_size += MAX_CCL_TBL_SIZE_INCREMENT;
4646 va_list ap;
4747
4848 /* allocate and initialize new filter */
49 f = malloc(sizeof(struct filter));
49 f = calloc(sizeof(struct filter), 1);
5050 if (!f)
51 flexerror(_("malloc failed (f) in filter_create_ext"));
52 memset (f, 0, sizeof (*f));
51 flexerror(_("calloc failed (f) in filter_create_ext"));
5352 f->filter_func = NULL;
5453 f->extra = NULL;
5554 f->next = NULL;
9998 struct filter *f;
10099
101100 /* allocate and initialize new filter */
102 f = malloc(sizeof(struct filter));
101 f = calloc(sizeof(struct filter), 1);
103102 if (!f)
104 flexerror(_("malloc failed in filter_create_int"));
105 memset (f, 0, sizeof (*f));
103 flexerror(_("calloc failed in filter_create_int"));
106104 f->next = NULL;
107105 f->argc = 0;
108106 f->argv = NULL;
229227 * header file at the same time.
230228 */
231229
232 const int readsz = 512;
233 char *buf;
230 char buf[512];
234231 int to_cfd = -1;
235232 FILE *to_c = NULL, *to_h = NULL;
236233 bool write_header;
282279 fprintf (to_c, "m4_define( [[M4_YY_OUTFILE_NAME]],[[%s]])m4_dnl\n",
283280 outfilename ? outfilename : "<stdout>");
284281
285 buf = malloc((size_t) readsz);
286 if (!buf)
287 flexerror(_("malloc failed in filter_tee_header"));
288 while (fgets (buf, readsz, stdin)) {
282 while (fgets (buf, sizeof buf, stdin)) {
289283 fputs (buf, to_c);
290284 if (write_header)
291285 fputs (buf, to_h);
325319
326320 FLEX_EXIT (0);
327321 return 0;
322 }
323
324 static bool is_blank_line (const char *str)
325 {
326 while (isspace(*str))
327 str++;
328 return (*str == '\0');
328329 }
329330
330331 /** Adjust the line numbers in the #line directives of the generated scanner.
335336 */
336337 int filter_fix_linedirs (struct filter *chain)
337338 {
338 char *buf;
339 const size_t readsz = 512;
339 char buf[512];
340 const size_t readsz = sizeof buf;
340341 int lineno = 1;
341342 bool in_gen = true; /* in generated code */
342343 bool last_was_blank = false;
343344
344345 if (!chain)
345346 return 0;
346
347 buf = malloc(readsz);
348 if (!buf)
349 flexerror(_("malloc failed in filter_fix_linedirs"));
350347
351348 while (fgets (buf, (int) readsz, stdin)) {
352349
390387 /* Adjust the line directives. */
391388 in_gen = true;
392389 snprintf (buf, readsz, "#line %d \"%s\"\n",
393 lineno, filename);
390 lineno + 1, filename);
394391 }
395392 else {
396393 /* it's a #line directive for code we didn't write */
402399 }
403400
404401 /* squeeze blank lines from generated code */
405 else if (in_gen
406 && regexec (&regex_blank_line, buf, 0, NULL,
407 0) == 0) {
402 else if (in_gen && is_blank_line(buf)) {
408403 if (last_was_blank)
409404 continue;
410405 else
1414 %# The quoting is "[[" and "]]" so we don't interfere with
1515 %# user code.
1616 %#
17 %# All generate macros for the m4 stage contain the text "m4" or "M4"
17 %# All generated macros for the m4 stage contain the text "m4" or "M4"
1818 %# in them. This is to distinguish them from CPP macros.
1919 %# The exception to this rule is YY_G, which is an m4 macro,
2020 %# but it needs to be remain short because it is used everywhere.
217217
218218 /* begin standard C headers. */
219219 %if-c-only
220 m4_ifdef( [[M4_YY_ALWAYS_INTERACTIVE]], ,
221 [[m4_ifdef( [[M4_YY_NEVER_INTERACTIVE]], ,
222 [[#ifndef _POSIX_C_SOURCE
223 #define _POSIX_C_SOURCE 1 /* for fileno() */
224 #ifndef _POSIX_SOURCE
225 #define _POSIX_SOURCE 1
226 #endif
227 #endif]])]])
220228 #include <stdio.h>
221229 #include <string.h>
222230 #include <errno.h>
32913299
32923300 /* Now eat padding. */
32933301 {
3294 int pad;
3295 pad = yypad64(rd->bread);
3296 while(--pad >= 0){
3302 while (rd->bread % (8 * sizeof(flex_uint8_t)) > 0) {
32973303 flex_int8_t t8;
32983304 if(yytbl_read8(&t8,rd) != 0)
32993305 return -1;
4343 #include <stdarg.h>
4444 #include <setjmp.h>
4545 #include <ctype.h>
46 #include <libgen.h> /* for XPG version of basename(3) */
4746 #include <string.h>
4847 #include <math.h>
4948
7675 #include <strings.h>
7776 #include "flexint.h"
7877
79 /* We use gettext. So, when we write strings which should be translated, we mark them with _() */
80 #ifdef ENABLE_NLS
78 /* We use gettext. So, when we write strings which should be translated, we
79 * mark them with _()
80 */
81 #if defined(ENABLE_NLS) && ENABLE_NLS
8182 #ifdef HAVE_LOCALE_H
8283 #include <locale.h>
8384 #endif /* HAVE_LOCALE_H */
630631 extern int tmpuses, totnst, peakpairs, numuniq, numdup, hshsave;
631632 extern int num_backing_up, bol_needed;
632633
633 #ifndef HAVE_REALLOCARRAY
634 void *reallocarray(void *, size_t, size_t);
635 #endif
636
637634 void *allocate_array(int, size_t);
638635 void *reallocate_array(void *, int, size_t);
639636
11301127 * From "regex.c"
11311128 */
11321129
1133 extern regex_t regex_linedir, regex_blank_line;
1130 extern regex_t regex_linedir;
11341131 bool flex_init_regex(void);
11351132 void flex_regcomp(regex_t *preg, const char *regex, int cflags);
11361133 char *regmatch_dup (regmatch_t * m, const char *src);
463463
464464 void genecs (void)
465465 {
466 int i, j;
466 int ch, row;
467467 int numrows;
468468
469469 out_str_dec (get_yy_char_decl (), "yy_ec", csize);
470470
471 for (i = 1; i < csize; ++i) {
472 ecgroup[i] = ABS (ecgroup[i]);
473 mkdata (ecgroup[i]);
471 for (ch = 1; ch < csize; ++ch) {
472 ecgroup[ch] = ABS (ecgroup[ch]);
473 mkdata (ecgroup[ch]);
474474 }
475475
476476 dataend ();
478478 if (trace) {
479479 fputs (_("\n\nEquivalence Classes:\n\n"), stderr);
480480
481 /* Print in 8 columns */
481482 numrows = csize / 8;
482483
483 for (j = 0; j < numrows; ++j) {
484 for (i = j; i < csize; i = i + numrows) {
484 for (row = 0; row < numrows; ++row) {
485 for (ch = row; ch < csize; ch += numrows) {
485486 fprintf (stderr, "%4s = %-2d",
486 readable_form (i), ecgroup[i]);
487 readable_form (ch), ecgroup[ch]);
487488
488489 putc (' ', stderr);
489490 }
12331234 yytbl_data_compress (yyacc_tbl);
12341235 if (yytbl_data_fwrite (&tableswr, yyacc_tbl) < 0)
12351236 flexerror (_("Could not write yyacc_tbl"));
1236 yytbl_data_destroy (yyacc_tbl);
1237 yyacc_tbl = NULL;
1238 }
1237 }
1238 yytbl_data_destroy (yyacc_tbl);
1239 yyacc_tbl = NULL;
12391240 /* End generating yy_accept */
12401241
12411242 if (useecs) {
12881289 if (tablesext) {
12891290 yytbl_data_compress (yymeta_tbl);
12901291 if (yytbl_data_fwrite (&tableswr, yymeta_tbl) < 0)
1291 flexerror (_
1292 ("Could not write yymeta_tbl"));
1293 yytbl_data_destroy (yymeta_tbl);
1294 yymeta_tbl = NULL;
1295 }
1292 flexerror (_("Could not write yymeta_tbl"));
1293 }
1294 yytbl_data_destroy (yymeta_tbl);
1295 yymeta_tbl = NULL;
12961296 /* End generating yy_meta */
12971297 }
12981298
13491349 yytbl_data_compress (yybase_tbl);
13501350 if (yytbl_data_fwrite (&tableswr, yybase_tbl) < 0)
13511351 flexerror (_("Could not write yybase_tbl"));
1352 yytbl_data_destroy (yybase_tbl);
1353 yybase_tbl = NULL;
1354 }
1352 }
1353 yytbl_data_destroy (yybase_tbl);
1354 yybase_tbl = NULL;
13551355 /* End generating yy_base */
13561356
13571357
13811381 yytbl_data_compress (yydef_tbl);
13821382 if (yytbl_data_fwrite (&tableswr, yydef_tbl) < 0)
13831383 flexerror (_("Could not write yydef_tbl"));
1384 yytbl_data_destroy (yydef_tbl);
1385 yydef_tbl = NULL;
1386 }
1384 }
1385 yytbl_data_destroy (yydef_tbl);
1386 yydef_tbl = NULL;
13871387 /* End generating yy_def */
13881388
13891389
14191419 yytbl_data_compress (yynxt_tbl);
14201420 if (yytbl_data_fwrite (&tableswr, yynxt_tbl) < 0)
14211421 flexerror (_("Could not write yynxt_tbl"));
1422 yytbl_data_destroy (yynxt_tbl);
1423 yynxt_tbl = NULL;
1424 }
1422 }
1423 yytbl_data_destroy (yynxt_tbl);
1424 yynxt_tbl = NULL;
14251425 /* End generating yy_nxt */
14261426
14271427 /* Begin generating yy_chk */
14531453 yytbl_data_compress (yychk_tbl);
14541454 if (yytbl_data_fwrite (&tableswr, yychk_tbl) < 0)
14551455 flexerror (_("Could not write yychk_tbl"));
1456 yytbl_data_destroy (yychk_tbl);
1457 yychk_tbl = NULL;
1458 }
1456 }
1457 yytbl_data_destroy (yychk_tbl);
1458 yychk_tbl = NULL;
14591459 /* End generating yy_chk */
14601460
14611461 free(acc_array);
1919 #define _LIBGETTEXT_H 1
2020
2121 /* NLS can be disabled through the configure --disable-nls option. */
22 #if ENABLE_NLS
22 #ifdef ENABLE_NLS
2323
2424 /* Get declarations of GNU message catalog functions. */
2525 # include <libintl.h>
0 prefix=@prefix@
1 exec_prefix=@exec_prefix@
2 libdir=@libdir@
3
4 Name: libfl
5 Description: Flex (the fast lexical analyzer) support library
6 Version: @PACKAGE_VERSION@
7 Libs: -L${libdir} -lfl
116116 char *program_name = "flex";
117117
118118 static const char outfile_template[] = "lex.%s.%s";
119 static const char backing_name[] = "lex.backup";
119 static const char *backing_name = "lex.backup";
120120 static const char tablesfile_template[] = "lex.%s.tables";
121121
122122 /* From scan.l */
196196 /* Wrapper around flex_main, so flex_main can be built as a library. */
197197 int main (int argc, char *argv[])
198198 {
199 #if ENABLE_NLS
199 #if defined(ENABLE_NLS) && ENABLE_NLS
200200 #if HAVE_LOCALE_H
201201 setlocale (LC_MESSAGES, "");
202202 setlocale (LC_CTYPE, "");
647647 "yyget_extra",
648648 "yyget_in",
649649 "yyget_leng",
650 "yyget_column",
650651 "yyget_lineno",
651652 "yyget_lloc",
652653 "yyget_lval",
669670 "yyset_debug",
670671 "yyset_extra",
671672 "yyset_in",
673 "yyset_column",
672674 "yyset_lineno",
673675 "yyset_lloc",
674676 "yyset_lval",
993995 flex_init_regex();
994996
995997 /* Enable C++ if program name ends with '+'. */
996 program_name = basename (argv[0]);
998 program_name = argv[0];
997999
9981000 if (program_name != NULL &&
9991001 program_name[strlen (program_name) - 1] == '+')
10321034 backing_up_report = true;
10331035 break;
10341036
1037 case OPT_BACKUP_FILE:
1038 backing_up_report = true;
1039 backing_name = arg;
1040 break;
1041
10351042 case OPT_DONOTHING:
10361043 break;
10371044
12001207 break;
12011208
12021209 case OPT_VERSION:
1203 printf (_("%s %s\n"), program_name, flex_version);
1210 printf ("%s %s\n", (C_plus_plus ? "flex++" : "flex"), flex_version);
12041211 FLEX_EXIT (0);
12051212
12061213 case OPT_WARN:
13921399 case OPT_NO_YYSET_LINENO:
13931400 //buf_strdefine (&userdef_buf, "YY_NO_SET_LINENO", "1");
13941401 buf_m4_define( &m4defs_buf, "M4_YY_NO_SET_LINENO",0);
1402 break;
1403 case OPT_NO_YYGET_COLUMN:
1404 //buf_strdefine (&userdef_buf, "YY_NO_GET_COLUMN", "1");
1405 buf_m4_define( &m4defs_buf, "M4_YY_NO_GET_COLUMN",0);
1406 break;
1407 case OPT_NO_YYSET_COLUMN:
1408 //buf_strdefine (&userdef_buf, "YY_NO_SET_COLUMN", "1");
1409 buf_m4_define( &m4defs_buf, "M4_YY_NO_SET_COLUMN",0);
13951410 break;
13961411 case OPT_NO_YYGET_IN:
13971412 //buf_strdefine (&userdef_buf, "YY_NO_GET_IN", "1");
18161831 " -t, --stdout write scanner on stdout instead of %s\n"
18171832 " --yyclass=NAME name of C++ class\n"
18181833 " --header-file=FILE create a C header file in addition to the scanner\n"
1819 " --tables-file[=FILE] write tables to FILE\n" "\n"
1834 " --tables-file[=FILE] write tables to FILE\n"
1835 " --backup-file=FILE write backing-up information to FILE\n" "\n"
18201836 "Scanner behavior:\n"
18211837 " -7, --7bit generate 7-bit scanner\n"
18221838 " -8, --8bit generate 8-bit scanner\n"
18431859 " -?\n"
18441860 " -h, --help produce this help message\n"
18451861 " -V, --version report %s version\n"),
1846 backing_name, program_name, outfile_path, program_name);
1862 backing_name, "flex", outfile_path, "flex");
18471863
18481864 }
115115 int len = (int) strlen (new_text);
116116
117117 while (len + action_index >= action_size - 10 /* slop */ ) {
118 int new_size = action_size * 2;
119
120 if (new_size <= 0)
118
119 if (action_size > INT_MAX / 2)
121120 /* Increase just a little, to try to avoid overflow
122121 * on 16-bit machines.
123122 */
124123 action_size += action_size / 8;
125124 else
126 action_size = new_size;
125 action_size = action_size * 2;
127126
128127 action_array =
129128 reallocate_character_array (action_array,
140139
141140 void *allocate_array (int size, size_t element_size)
142141 {
143 void *mem;
144 #if HAVE_REALLOCARRAY
145 /* reallocarray has built-in overflow detection */
146 mem = reallocarray(NULL, (size_t) size, element_size);
142 void *new_array;
143 #if HAVE_REALLOCARR
144 new_array = NULL;
145 if (reallocarr(&new_array, (size_t) size, element_size))
146 flexfatal (_("memory allocation failed in allocate_array()"));
147147 #else
148 # if HAVE_REALLOCARRAY
149 new_array = reallocarray(NULL, (size_t) size, element_size);
150 # else
151 /* Do manual overflow detection */
148152 size_t num_bytes = (size_t) size * element_size;
149 mem = (size && SIZE_MAX / (size_t) size < element_size) ? NULL :
153 new_array = (size && SIZE_MAX / (size_t) size < element_size) ? NULL :
150154 malloc(num_bytes);
155 # endif
156 if (!new_array)
157 flexfatal (_("memory allocation failed in allocate_array()"));
151158 #endif
152 if (!mem)
153 flexfatal (_
154 ("memory allocation failed in allocate_array()"));
155
156 return mem;
159 return new_array;
157160 }
158161
159162
658661 void *reallocate_array (void *array, int size, size_t element_size)
659662 {
660663 void *new_array;
661 #if HAVE_REALLOCARRAY
662 /* reallocarray has built-in overflow detection */
664 #if HAVE_REALLOCARR
665 new_array = array;
666 if (reallocarr(&new_array, (size_t) size, element_size))
667 flexfatal (_("attempt to increase array size failed"));
668 #else
669 # if HAVE_REALLOCARRAY
663670 new_array = reallocarray(array, (size_t) size, element_size);
664 #else
671 # else
672 /* Do manual overflow detection */
665673 size_t num_bytes = (size_t) size * element_size;
666674 new_array = (size && SIZE_MAX / (size_t) size < element_size) ? NULL :
667675 realloc(array, num_bytes);
668 #endif
676 # endif
669677 if (!new_array)
670678 flexfatal (_("attempt to increase array size failed"));
671
679 #endif
672680 return new_array;
673681 }
674682
719727 */
720728 #define cmd_match(s) (strncmp(buf,(s),strlen(s))==0)
721729
722 if (buf[1] == '%') {
730 if (buf[1] == '#') {
731 /* %# indicates comment line to be ignored */
732 }
733 else if (buf[1] == '%') {
723734 /* %% is a break point for skelout() */
724735 return;
725736 }
4747 s/m4_/m4preproc_/g
4848 s/a4_/4_/g
4949 s/[\\"]/\\&/g
50 s/.*/ "&",/'
50 s/[^\r]*/ "&",/'
5151
5252 echo ' 0
5353 };'
497497 mkxtion (finalst[second], orend);
498498 }
499499 }
500
501 firstst[first] = MIN(firstst[first], firstst[second]);
500502
501503 finalst[first] = orend;
502504 return first;
6161 ,
6262 {"--backup", OPT_BACKUP, 0}
6363 , /* Generate backing-up information to lex.backup. */
64 {"--backup-file=FILE", OPT_BACKUP_FILE, 0}
65 , /* Generate backing-up information to FILE. */
6466 {"-B", OPT_BATCH, 0}
6567 ,
6668 {"--batch", OPT_BATCH, 0}
254256 ,
255257 {"--noyyset_lineno", OPT_NO_YYSET_LINENO, 0}
256258 ,
259 {"--noyyget_column", OPT_NO_YYGET_COLUMN, 0}
260 ,
261 {"--noyyset_column", OPT_NO_YYSET_COLUMN, 0}
262 ,
257263 {"--noyyget_in", OPT_NO_YYGET_IN, 0}
258264 ,
259265 {"--noyyset_in", OPT_NO_YYSET_IN, 0}
4545 OPT_ALWAYS_INTERACTIVE,
4646 OPT_ARRAY,
4747 OPT_BACKUP,
48 OPT_BACKUP_FILE,
4849 OPT_BATCH,
4950 OPT_BISON_BRIDGE,
5051 OPT_BISON_BRIDGE_LOCATIONS,
8283 OPT_NO_YYGET_IN,
8384 OPT_NO_YYGET_LENG,
8485 OPT_NO_YYGET_LINENO,
86 OPT_NO_YYGET_COLUMN,
8587 OPT_NO_YYGET_LLOC,
8688 OPT_NO_YYGET_LVAL,
8789 OPT_NO_YYGET_OUT,
9193 OPT_NO_YYSET_EXTRA,
9294 OPT_NO_YYSET_IN,
9395 OPT_NO_YYSET_LINENO,
96 OPT_NO_YYSET_COLUMN,
9497 OPT_NO_YYSET_LLOC,
9598 OPT_NO_YYSET_LVAL,
9699 OPT_NO_YYSET_OUT,
2424
2525
2626 static const char* REGEXP_LINEDIR = "^#line ([[:digit:]]+) \"(.*)\"";
27 static const char* REGEXP_BLANK_LINE = "^[[:space:]]*$";
2827
2928 regex_t regex_linedir; /**< matches line directives */
30 regex_t regex_blank_line; /**< matches blank lines */
3129
3230
3331 /** Initialize the regular expressions.
3634 bool flex_init_regex(void)
3735 {
3836 flex_regcomp(&regex_linedir, REGEXP_LINEDIR, REG_EXTENDED);
39 flex_regcomp(&regex_blank_line, REGEXP_BLANK_LINE, REG_EXTENDED);
40
4137 return true;
4238 }
4339
00 /* scan.l - scanner for flex input -*-C-*- */
1
2 %top{
3 /* flexdef.h includes config.h, which may contain macros that alter the API */
4 /* of libc functions. Must include first before any libc header. */
5 #include "flexdef.h"
6 }
17
28 %{
39 /* Copyright (c) 1990 The Regents of the University of California. */
3137 /* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR */
3238 /* PURPOSE. */
3339
34 #include "flexdef.h"
3540 #include "parse.h"
3641 extern bool tablesverify, tablesext;
3742 extern int trlcontxt; /* Set in parse.y for each rule. */
432437 yyset_extra ACTION_M4_IFDEF("M4""_YY_NO_SET_EXTRA", ! option_sense);
433438 yyget_leng ACTION_M4_IFDEF("M4""_YY_NO_GET_LENG", ! option_sense);
434439 yyget_text ACTION_M4_IFDEF("M4""_YY_NO_GET_TEXT", ! option_sense);
440 yyget_column ACTION_M4_IFDEF("M4""_YY_NO_GET_COLUMN", ! option_sense);
441 yyset_column ACTION_M4_IFDEF("M4""_YY_NO_SET_COLUMN", ! option_sense);
435442 yyget_lineno ACTION_M4_IFDEF("M4""_YY_NO_GET_LINENO", ! option_sense);
436443 yyset_lineno ACTION_M4_IFDEF("M4""_YY_NO_SET_LINENO", ! option_sense);
437444 yyget_in ACTION_M4_IFDEF("M4""_YY_NO_GET_IN", ! option_sense);
6767 static int RVAL(struct _scanopt_t *, int);
6868 static int FLAGS(struct _scanopt_t *, int);
6969 static const char *DESC(struct _scanopt_t *, int);
70 static int scanopt_err(struct _scanopt_t *, int, int);
70 static void scanopt_err(struct _scanopt_t *, int, int);
7171 static int matchlongopt(char *, char **, int *, char **, int *);
7272 static int find_opt(struct _scanopt_t *, int, char *, int, int *, int *opt_offset);
7373
228228 int scanopt_usage (scanopt_t *scanner, FILE *fp, const char *usage)
229229 {
230230 struct _scanopt_t *s;
231 int i, columns, indent = 2;
231 int i, columns;
232 const int indent = 2;
232233 usg_elem *byr_val = NULL; /* option indices sorted by r_val */
233234 usg_elem *store; /* array of preallocated elements. */
234235 int store_idx = 0;
235236 usg_elem *ue;
236 int maxlen[2];
237 int desccol = 0;
237 int opt_col_width = 0, desc_col_width = 0;
238 int desccol;
238239 int print_run = 0;
239
240 maxlen[0] = 0;
241 maxlen[1] = 0;
242240
243241 s = (struct _scanopt_t *) scanner;
244242
246244 fprintf (fp, "%s\n", usage);
247245 }
248246 else {
249 /* Find the basename of argv[0] */
250 const char *p;
251
252 p = s->argv[0] + strlen (s->argv[0]);
253 while (p != s->argv[0] && *p != '/')
254 --p;
255 if (*p == '/')
256 p++;
257
258 fprintf (fp, _("Usage: %s [OPTIONS]...\n"), p);
247 fprintf (fp, _("Usage: %s [OPTIONS]...\n"), s->argv[0]);
259248 }
260249 fprintf (fp, "\n");
261250
323312 /* first pass calculate how much room we need. */
324313 for (ue = byr_val; ue; ue = ue->next) {
325314 usg_elem *ap;
326 int len = 0;
327 int nshort = 0, nlong = 0;
328
329
330 #define CALC_LEN(i) do {\
331 if(FLAGS(s,i) & IS_LONG) \
332 len += (nlong++||nshort) ? 2+PRINTLEN(s,i) : PRINTLEN(s,i);\
333 else\
334 len += (nshort++||nlong)? 2+PRINTLEN(s,i) : PRINTLEN(s,i);\
335 }while(0)
336
337 if (!(FLAGS (s, ue->idx) & IS_LONG))
338 CALC_LEN (ue->idx);
339
340 /* do short aliases first. */
315 int len;
316
317 len = PRINTLEN(s, ue->idx);
318
341319 for (ap = ue->alias; ap; ap = ap->next) {
342 if (FLAGS (s, ap->idx) & IS_LONG)
343 continue;
344 CALC_LEN (ap->idx);
345 }
346
347 if (FLAGS (s, ue->idx) & IS_LONG)
348 CALC_LEN (ue->idx);
349
350 /* repeat the above loop, this time for long aliases. */
351 for (ap = ue->alias; ap; ap = ap->next) {
352 if (!(FLAGS (s, ap->idx) & IS_LONG))
353 continue;
354 CALC_LEN (ap->idx);
355 }
356
357 if (len > maxlen[0])
358 maxlen[0] = len;
320 len += PRINTLEN(s, ap->idx) + (int) strlen(", ");
321 }
322
323 if (len > opt_col_width)
324 opt_col_width = len;
359325
360326 /* It's much easier to calculate length for description column! */
361327 len = (int) strlen (DESC (s, ue->idx));
362 if (len > maxlen[1])
363 maxlen[1] = len;
328 if (len > desc_col_width)
329 desc_col_width = len;
364330 }
365331
366332 /* Determine how much room we have, and how much we will allocate to each col.
367333 * Do not address pathological cases. Output will just be ugly. */
368334 columns = get_cols () - 1;
369 if (maxlen[0] + maxlen[1] + indent * 2 > columns) {
370 /* col 0 gets whatever it wants. we'll wrap the desc col. */
371 maxlen[1] = columns - (maxlen[0] + indent * 2);
372 if (maxlen[1] < 14) /* 14 is arbitrary lower limit on desc width. */
373 maxlen[1] = INT_MAX;
374 }
375 desccol = maxlen[0] + indent * 2;
376
377 #define PRINT_SPACES(fp,n)\
378 do{\
379 int _n;\
380 _n=(n);\
381 while(_n-- > 0)\
382 fputc(' ',(fp));\
383 }while(0)
384
335 if (opt_col_width + desc_col_width + indent * 2 > columns) {
336 /* opt col gets whatever it wants. we'll wrap the desc col. */
337 desc_col_width = columns - (opt_col_width + indent * 2);
338 if (desc_col_width < 14) /* 14 is arbitrary lower limit on desc width. */
339 desc_col_width = INT_MAX;
340 }
341 desccol = opt_col_width + indent * 2;
342
343 #define PRINT_SPACES(fp,n) \
344 fprintf((fp), "%*s", (n), "")
385345
386346 /* Second pass (same as above loop), this time we print. */
387347 /* Sloppy hack: We iterate twice. The first time we print short and long options.
435395 /* pad to desccol */
436396 PRINT_SPACES (fp, desccol - nchars);
437397
438 /* Print description, wrapped to maxlen[1] columns. */
398 /* Print description, wrapped to desc_col_width columns. */
439399 if (1) {
440400 const char *pstart;
441401
446406
447407 p = pstart;
448408
449 while (*p && n < maxlen[1]
409 while (*p && n < desc_col_width
450410 && *p != '\n') {
451411 if (isspace ((unsigned char)(*p))
452412 || *p == '-') lastws =
496456 #endif /* no scanopt_usage */
497457
498458
499 static int scanopt_err (struct _scanopt_t *s, int is_short, int err)
459 static void scanopt_err(struct _scanopt_t *s, int is_short, int err)
500460 {
501461 const char *optname = "";
502462 char optchar[2];
541501 break;
542502 }
543503 }
544 return err;
545504 }
546505
547506
728687
729688 if (!find_opt
730689 (s, 0, pstart, namelen, &errcode, &opt_offset)) {
731 return scanopt_err (s, 1, errcode);
690 scanopt_err(s, 1, errcode);
691 return errcode;
732692 }
733693
734694 optarg = pstart + 1;
747707
748708 /* Look ahead in argv[] to see if there is something
749709 * that we can use as an argument (if needed). */
750 has_next = s->index + 1 < s->argc
751 && strcmp ("--", s->argv[s->index + 1]) != 0;
710 has_next = s->index + 1 < s->argc;
752711
753712 optp = s->options + opt_offset;
754713 auxp = s->aux + opt_offset;
756715 /* case: no args allowed */
757716 if (auxp->flags & ARG_NONE) {
758717 if (optarg && !is_short) {
759 scanopt_err (s, is_short, errcode = SCANOPT_ERR_ARG_NOT_ALLOWED);
718 scanopt_err(s, is_short, SCANOPT_ERR_ARG_NOT_ALLOWED);
760719 INC_INDEX (s, 1);
761 return errcode;
720 return SCANOPT_ERR_ARG_NOT_ALLOWED;
762721 }
763722 else if (!optarg)
764723 INC_INDEX (s, 1);
769728
770729 /* case: required */
771730 if (auxp->flags & ARG_REQ) {
772 if (!optarg && !has_next)
773 return scanopt_err (s, is_short, SCANOPT_ERR_ARG_NOT_FOUND);
731 if (!optarg && !has_next) {
732 scanopt_err(s, is_short, SCANOPT_ERR_ARG_NOT_FOUND);
733 return SCANOPT_ERR_ARG_NOT_FOUND;
734 }
774735
775736 if (!optarg) {
776737 /* Let the next argv element become the argument. */
8686
8787 th->th_magic = YYTBL_MAGIC;
8888 th->th_hsize = (flex_uint32_t) (14 + strlen (version_str) + 1 + strlen (name) + 1);
89 th->th_hsize += yypad64 (th->th_hsize);
89 th->th_hsize += (8 - (th->th_hsize % 8)) % 8; // Pad to 64-bit boundary
9090 th->th_ssize = 0; // Not known at this point.
9191 th->th_flags = 0;
9292 th->th_version = xstrdup(version_str);
123123 /** Write enough padding to bring the file pointer to a 64-bit boundary. */
124124 static int yytbl_write_pad64 (struct yytbl_writer *wr)
125125 {
126 int pad, bwritten = 0;
127
128 pad = yypad64 (wr->total_written);
129 while (pad-- > 0)
126 int bwritten = 0;
127
128 while (wr->total_written % (8 * sizeof(flex_uint8_t)) > 0) {
130129 if (yytbl_write8 (wr, 0) < 0)
131130 return -1;
132131 else
133132 bwritten++;
133 }
134134 return bwritten;
135135 }
136136
6161 #ifndef YYTBL_MAGIC
6262 #define YYTBL_MAGIC 0xF13C57B1
6363 #endif
64
65 /** Calculate (0-7) = number bytes needed to pad n to next 64-bit boundary. */
66 #ifndef yypad64
67 #define yypad64(n) ((8-((n)%8))%8)
68 #endif
69
7064
7165 #ifndef YYTABLES_TYPES
7266 #define YYTABLES_TYPES
444444 # things) and the resultant list is both long an unenlightening. And
445445 # it can be / is generated by a shell script, tableopts.sh.
446446
447 tableopts.am: tableopts.sh
447 $(srcdir)/tableopts.am: tableopts.sh
448448 $(SHELL) $(srcdir)/tableopts.sh > $(srcdir)/tableopts.am
449449
450450 include $(srcdir)/tableopts.am
461461 AM_OPT_LOG_FLAGS = -d $(srcdir) -i $(srcdir)/tableopts.txt -r
462462
463463 tableopts_opt_nr%.c: tableopts.l4 $(FLEX)
464 $(AM_V_LEX)$(FLEX) --unsafe-no-m4-sect3-escape -P $(subst -,_,$(basename $(*F))) $* -o $@ $<
464 $(AM_V_LEX)$(FLEX) --unsafe-no-m4-sect3-escape -P $(subst -,_,$(basename $(*F))) $(*:_F=F) -o $@ $<
465465
466466 tableopts_opt_nr%.$(OBJEXT): tableopts_opt_nr%.c
467467 $(AM_V_CC)$(COMPILE) -c -o $@ $<
468468
469469 tableopts_opt_r%.c: tableopts.l4 $(FLEX)
470 $(AM_V_LEX)$(FLEX) --unsafe-no-m4-sect3-escape -P $(subst -,_,$(basename $(*F))) --reentrant $* -o $@ $<
470 $(AM_V_LEX)$(FLEX) --unsafe-no-m4-sect3-escape -P $(subst -,_,$(basename $(*F))) --reentrant $(subst _F,F,$*) -o $@ $<
471471
472472 tableopts_opt_r%.$(OBJEXT): tableopts_opt_r%.c
473473 $(AM_V_CC)$(COMPILE) -DTEST_IS_REENTRANT -c -o $@ $<
476476 AM_SER_LOG_FLAGS = -d $(builddir) -i $(srcdir)/tableopts.txt -r -t
477477
478478 tableopts_ser_nr%.c: tableopts.l4 $(FLEX)
479 $(AM_V_LEX)$(FLEX) --unsafe-no-m4-sect3-escape -P $(subst -,_,$(basename $(*F))) --tables-file="tableopts_ser_nr$*.ser.tables" $* -o $@ $<
479 $(AM_V_LEX)$(FLEX) --unsafe-no-m4-sect3-escape -P $(subst -,_,$(basename $(*F))) --tables-file="tableopts_ser_nr$*.ser.tables" $(subst _F,F,$*) -o $@ $<
480480
481481 tableopts_ser_nr%.$(OBJEXT): tableopts_ser_nr%.c
482482 $(AM_V_CC)$(COMPILE) -DTEST_HAS_TABLES_EXTERNAL -c -o $@ $<
483483
484484 tableopts_ser_r%.c: tableopts.l4 $(FLEX)
485 $(AM_V_LEX)$(FLEX) --unsafe-no-m4-sect3-escape -P $(subst -,_,$(basename $(*F))) -R --tables-file="tableopts_ser_r$*.ser.tables" $* -o $@ $<
485 $(AM_V_LEX)$(FLEX) --unsafe-no-m4-sect3-escape -P $(subst -,_,$(basename $(*F))) -R --tables-file="tableopts_ser_r$*.ser.tables" $(subst _F,F,$*) -o $@ $<
486486
487487 tableopts_ser_r%.$(OBJEXT): tableopts_ser_r%.c
488488 $(AM_V_CC)$(COMPILE) -DTEST_HAS_TABLES_EXTERNAL -DTEST_IS_REENTRANT -c -o $@ $<
491491 AM_VER_LOG_FLAGS = -d $(builddir) -i $(srcdir)/tableopts.txt -r -t
492492
493493 tableopts_ver_nr%.c: tableopts.l4 $(FLEX)
494 $(AM_V_LEX)$(FLEX) --unsafe-no-m4-sect3-escape -P $(subst -,_,$(basename $(*F))) --tables-file="tableopts_ver_nr$*.ver.tables" --tables-verify $* -o $@ $<
494 $(AM_V_LEX)$(FLEX) --unsafe-no-m4-sect3-escape -P $(subst -,_,$(basename $(*F))) --tables-file="tableopts_ver_nr$*.ver.tables" --tables-verify $(subst _F,F,$*) -o $@ $<
495495
496496 tableopts_ver_nr%.$(OBJEXT): tableopts_ver_nr%.c
497497 $(AM_V_CC)$(COMPILE) -DTEST_HAS_TABLES_EXTERNAL -c -o $@ $<
500500 $(AM_V_CCLD)$(LINK) -o $@ $^
501501
502502 tableopts_ver_r%.c: tableopts.l4 $(FLEX)
503 $(AM_V_LEX)$(FLEX) --unsafe-no-m4-sect3-escape -P $(subst -,_,$(basename $(*F))) -R --tables-file="tableopts_ver_r$*.ver.tables" --tables-verify $* -o $@ $<
503 $(AM_V_LEX)$(FLEX) --unsafe-no-m4-sect3-escape -P $(subst -,_,$(basename $(*F))) -R --tables-file="tableopts_ver_r$*.ver.tables" --tables-verify $(subst _F,F,$*) -o $@ $<
504504
505505 tableopts_ver_r%.$(OBJEXT): tableopts_ver_r%.c
506506 $(AM_V_CC)$(COMPILE) -DTEST_HAS_TABLES_EXTERNAL -DTEST_IS_REENTRANT -c -o $@ $<
1212 tableopts_opt_nr-Cf.opt$(EXEEXT): tableopts_opt_nr-Cf.$(OBJEXT)
1313 $(AM_V_CCLD)$(LINK) -o $@ $<
1414
15 tableopts_opt_nr_CF_opt_SOURCES = tableopts.l4
16
17 tableopts_opt_nr-CF.opt$(EXEEXT): tableopts_opt_nr-CF.$(OBJEXT)
15 tableopts_opt_nr_C_F_opt_SOURCES = tableopts.l4
16
17 tableopts_opt_nr-C_F.opt$(EXEEXT): tableopts_opt_nr-C_F.$(OBJEXT)
1818 $(AM_V_CCLD)$(LINK) -o $@ $<
1919
2020 tableopts_opt_nr_Cm_opt_SOURCES = tableopts.l4
3737 tableopts_opt_nr-Caef.opt$(EXEEXT): tableopts_opt_nr-Caef.$(OBJEXT)
3838 $(AM_V_CCLD)$(LINK) -o $@ $<
3939
40 tableopts_opt_nr_CaeF_opt_SOURCES = tableopts.l4
41
42 tableopts_opt_nr-CaeF.opt$(EXEEXT): tableopts_opt_nr-CaeF.$(OBJEXT)
40 tableopts_opt_nr_Cae_F_opt_SOURCES = tableopts.l4
41
42 tableopts_opt_nr-Cae_F.opt$(EXEEXT): tableopts_opt_nr-Cae_F.$(OBJEXT)
4343 $(AM_V_CCLD)$(LINK) -o $@ $<
4444
4545 tableopts_opt_nr_Cam_opt_SOURCES = tableopts.l4
6767 tableopts_opt_r-Cf.opt$(EXEEXT): tableopts_opt_r-Cf.$(OBJEXT)
6868 $(AM_V_CCLD)$(LINK) -o $@ $<
6969
70 tableopts_opt_r_CF_opt_SOURCES = tableopts.l4
71
72 tableopts_opt_r-CF.opt$(EXEEXT): tableopts_opt_r-CF.$(OBJEXT)
70 tableopts_opt_r_C_F_opt_SOURCES = tableopts.l4
71
72 tableopts_opt_r-C_F.opt$(EXEEXT): tableopts_opt_r-C_F.$(OBJEXT)
7373 $(AM_V_CCLD)$(LINK) -o $@ $<
7474
7575 tableopts_opt_r_Cm_opt_SOURCES = tableopts.l4
9292 tableopts_opt_r-Caef.opt$(EXEEXT): tableopts_opt_r-Caef.$(OBJEXT)
9393 $(AM_V_CCLD)$(LINK) -o $@ $<
9494
95 tableopts_opt_r_CaeF_opt_SOURCES = tableopts.l4
96
97 tableopts_opt_r-CaeF.opt$(EXEEXT): tableopts_opt_r-CaeF.$(OBJEXT)
95 tableopts_opt_r_Cae_F_opt_SOURCES = tableopts.l4
96
97 tableopts_opt_r-Cae_F.opt$(EXEEXT): tableopts_opt_r-Cae_F.$(OBJEXT)
9898 $(AM_V_CCLD)$(LINK) -o $@ $<
9999
100100 tableopts_opt_r_Cam_opt_SOURCES = tableopts.l4
122122 tableopts_ser_nr-Cf.ser$(EXEEXT): tableopts_ser_nr-Cf.$(OBJEXT)
123123 $(AM_V_CCLD)$(LINK) -o $@ $<
124124
125 tableopts_ser_nr_CF_ser_SOURCES = tableopts.l4
126
127 tableopts_ser_nr-CF.ser$(EXEEXT): tableopts_ser_nr-CF.$(OBJEXT)
125 tableopts_ser_nr_C_F_ser_SOURCES = tableopts.l4
126
127 tableopts_ser_nr-C_F.ser$(EXEEXT): tableopts_ser_nr-C_F.$(OBJEXT)
128128 $(AM_V_CCLD)$(LINK) -o $@ $<
129129
130130 tableopts_ser_nr_Cm_ser_SOURCES = tableopts.l4
147147 tableopts_ser_nr-Caef.ser$(EXEEXT): tableopts_ser_nr-Caef.$(OBJEXT)
148148 $(AM_V_CCLD)$(LINK) -o $@ $<
149149
150 tableopts_ser_nr_CaeF_ser_SOURCES = tableopts.l4
151
152 tableopts_ser_nr-CaeF.ser$(EXEEXT): tableopts_ser_nr-CaeF.$(OBJEXT)
150 tableopts_ser_nr_Cae_F_ser_SOURCES = tableopts.l4
151
152 tableopts_ser_nr-Cae_F.ser$(EXEEXT): tableopts_ser_nr-Cae_F.$(OBJEXT)
153153 $(AM_V_CCLD)$(LINK) -o $@ $<
154154
155155 tableopts_ser_nr_Cam_ser_SOURCES = tableopts.l4
177177 tableopts_ser_r-Cf.ser$(EXEEXT): tableopts_ser_r-Cf.$(OBJEXT)
178178 $(AM_V_CCLD)$(LINK) -o $@ $<
179179
180 tableopts_ser_r_CF_ser_SOURCES = tableopts.l4
181
182 tableopts_ser_r-CF.ser$(EXEEXT): tableopts_ser_r-CF.$(OBJEXT)
180 tableopts_ser_r_C_F_ser_SOURCES = tableopts.l4
181
182 tableopts_ser_r-C_F.ser$(EXEEXT): tableopts_ser_r-C_F.$(OBJEXT)
183183 $(AM_V_CCLD)$(LINK) -o $@ $<
184184
185185 tableopts_ser_r_Cm_ser_SOURCES = tableopts.l4
202202 tableopts_ser_r-Caef.ser$(EXEEXT): tableopts_ser_r-Caef.$(OBJEXT)
203203 $(AM_V_CCLD)$(LINK) -o $@ $<
204204
205 tableopts_ser_r_CaeF_ser_SOURCES = tableopts.l4
206
207 tableopts_ser_r-CaeF.ser$(EXEEXT): tableopts_ser_r-CaeF.$(OBJEXT)
205 tableopts_ser_r_Cae_F_ser_SOURCES = tableopts.l4
206
207 tableopts_ser_r-Cae_F.ser$(EXEEXT): tableopts_ser_r-Cae_F.$(OBJEXT)
208208 $(AM_V_CCLD)$(LINK) -o $@ $<
209209
210210 tableopts_ser_r_Cam_ser_SOURCES = tableopts.l4
232232 tableopts_ver_nr-Cf.ver$(EXEEXT): tableopts_ver_nr-Cf.$(OBJEXT)
233233 $(AM_V_CCLD)$(LINK) -o $@ $<
234234
235 tableopts_ver_nr_CF_ver_SOURCES = tableopts.l4
236
237 tableopts_ver_nr-CF.ver$(EXEEXT): tableopts_ver_nr-CF.$(OBJEXT)
235 tableopts_ver_nr_C_F_ver_SOURCES = tableopts.l4
236
237 tableopts_ver_nr-C_F.ver$(EXEEXT): tableopts_ver_nr-C_F.$(OBJEXT)
238238 $(AM_V_CCLD)$(LINK) -o $@ $<
239239
240240 tableopts_ver_nr_Cm_ver_SOURCES = tableopts.l4
257257 tableopts_ver_nr-Caef.ver$(EXEEXT): tableopts_ver_nr-Caef.$(OBJEXT)
258258 $(AM_V_CCLD)$(LINK) -o $@ $<
259259
260 tableopts_ver_nr_CaeF_ver_SOURCES = tableopts.l4
261
262 tableopts_ver_nr-CaeF.ver$(EXEEXT): tableopts_ver_nr-CaeF.$(OBJEXT)
260 tableopts_ver_nr_Cae_F_ver_SOURCES = tableopts.l4
261
262 tableopts_ver_nr-Cae_F.ver$(EXEEXT): tableopts_ver_nr-Cae_F.$(OBJEXT)
263263 $(AM_V_CCLD)$(LINK) -o $@ $<
264264
265265 tableopts_ver_nr_Cam_ver_SOURCES = tableopts.l4
287287 tableopts_ver_r-Cf.ver$(EXEEXT): tableopts_ver_r-Cf.$(OBJEXT)
288288 $(AM_V_CCLD)$(LINK) -o $@ $<
289289
290 tableopts_ver_r_CF_ver_SOURCES = tableopts.l4
291
292 tableopts_ver_r-CF.ver$(EXEEXT): tableopts_ver_r-CF.$(OBJEXT)
290 tableopts_ver_r_C_F_ver_SOURCES = tableopts.l4
291
292 tableopts_ver_r-C_F.ver$(EXEEXT): tableopts_ver_r-C_F.$(OBJEXT)
293293 $(AM_V_CCLD)$(LINK) -o $@ $<
294294
295295 tableopts_ver_r_Cm_ver_SOURCES = tableopts.l4
312312 tableopts_ver_r-Caef.ver$(EXEEXT): tableopts_ver_r-Caef.$(OBJEXT)
313313 $(AM_V_CCLD)$(LINK) -o $@ $<
314314
315 tableopts_ver_r_CaeF_ver_SOURCES = tableopts.l4
316
317 tableopts_ver_r-CaeF.ver$(EXEEXT): tableopts_ver_r-CaeF.$(OBJEXT)
315 tableopts_ver_r_Cae_F_ver_SOURCES = tableopts.l4
316
317 tableopts_ver_r-Cae_F.ver$(EXEEXT): tableopts_ver_r-Cae_F.$(OBJEXT)
318318 $(AM_V_CCLD)$(LINK) -o $@ $<
319319
320320 tableopts_ver_r_Cam_ver_SOURCES = tableopts.l4
327327 tableopts_ver_r-Caem.ver$(EXEEXT): tableopts_ver_r-Caem.$(OBJEXT)
328328 $(AM_V_CCLD)$(LINK) -o $@ $<
329329
330 TABLEOPTS_TESTS = tableopts_opt_nr-Ca.opt tableopts_opt_nr-Ce.opt tableopts_opt_nr-Cf.opt tableopts_opt_nr-CF.opt tableopts_opt_nr-Cm.opt tableopts_opt_nr-Cem.opt tableopts_opt_nr-Cae.opt tableopts_opt_nr-Caef.opt tableopts_opt_nr-CaeF.opt tableopts_opt_nr-Cam.opt tableopts_opt_nr-Caem.opt tableopts_opt_r-Ca.opt tableopts_opt_r-Ce.opt tableopts_opt_r-Cf.opt tableopts_opt_r-CF.opt tableopts_opt_r-Cm.opt tableopts_opt_r-Cem.opt tableopts_opt_r-Cae.opt tableopts_opt_r-Caef.opt tableopts_opt_r-CaeF.opt tableopts_opt_r-Cam.opt tableopts_opt_r-Caem.opt tableopts_ser_nr-Ca.ser tableopts_ser_nr-Ce.ser tableopts_ser_nr-Cf.ser tableopts_ser_nr-CF.ser tableopts_ser_nr-Cm.ser tableopts_ser_nr-Cem.ser tableopts_ser_nr-Cae.ser tableopts_ser_nr-Caef.ser tableopts_ser_nr-CaeF.ser tableopts_ser_nr-Cam.ser tableopts_ser_nr-Caem.ser tableopts_ser_r-Ca.ser tableopts_ser_r-Ce.ser tableopts_ser_r-Cf.ser tableopts_ser_r-CF.ser tableopts_ser_r-Cm.ser tableopts_ser_r-Cem.ser tableopts_ser_r-Cae.ser tableopts_ser_r-Caef.ser tableopts_ser_r-CaeF.ser tableopts_ser_r-Cam.ser tableopts_ser_r-Caem.ser tableopts_ver_nr-Ca.ver tableopts_ver_nr-Ce.ver tableopts_ver_nr-Cf.ver tableopts_ver_nr-CF.ver tableopts_ver_nr-Cm.ver tableopts_ver_nr-Cem.ver tableopts_ver_nr-Cae.ver tableopts_ver_nr-Caef.ver tableopts_ver_nr-CaeF.ver tableopts_ver_nr-Cam.ver tableopts_ver_nr-Caem.ver tableopts_ver_r-Ca.ver tableopts_ver_r-Ce.ver tableopts_ver_r-Cf.ver tableopts_ver_r-CF.ver tableopts_ver_r-Cm.ver tableopts_ver_r-Cem.ver tableopts_ver_r-Cae.ver tableopts_ver_r-Caef.ver tableopts_ver_r-CaeF.ver tableopts_ver_r-Cam.ver tableopts_ver_r-Caem.ver
331
332 tableopts_tables = tableopts_ser_nr-Ca.ser.tables tableopts_ser_nr-Ce.ser.tables tableopts_ser_nr-Cf.ser.tables tableopts_ser_nr-CF.ser.tables tableopts_ser_nr-Cm.ser.tables tableopts_ser_nr-Cem.ser.tables tableopts_ser_nr-Cae.ser.tables tableopts_ser_nr-Caef.ser.tables tableopts_ser_nr-CaeF.ser.tables tableopts_ser_nr-Cam.ser.tables tableopts_ser_nr-Caem.ser.tables tableopts_ser_r-Ca.ser.tables tableopts_ser_r-Ce.ser.tables tableopts_ser_r-Cf.ser.tables tableopts_ser_r-CF.ser.tables tableopts_ser_r-Cm.ser.tables tableopts_ser_r-Cem.ser.tables tableopts_ser_r-Cae.ser.tables tableopts_ser_r-Caef.ser.tables tableopts_ser_r-CaeF.ser.tables tableopts_ser_r-Cam.ser.tables tableopts_ser_r-Caem.ser.tables tableopts_ver_nr-Ca.ver.tables tableopts_ver_nr-Ce.ver.tables tableopts_ver_nr-Cf.ver.tables tableopts_ver_nr-CF.ver.tables tableopts_ver_nr-Cm.ver.tables tableopts_ver_nr-Cem.ver.tables tableopts_ver_nr-Cae.ver.tables tableopts_ver_nr-Caef.ver.tables tableopts_ver_nr-CaeF.ver.tables tableopts_ver_nr-Cam.ver.tables tableopts_ver_nr-Caem.ver.tables tableopts_ver_r-Ca.ver.tables tableopts_ver_r-Ce.ver.tables tableopts_ver_r-Cf.ver.tables tableopts_ver_r-CF.ver.tables tableopts_ver_r-Cm.ver.tables tableopts_ver_r-Cem.ver.tables tableopts_ver_r-Cae.ver.tables tableopts_ver_r-Caef.ver.tables tableopts_ver_r-CaeF.ver.tables tableopts_ver_r-Cam.ver.tables tableopts_ver_r-Caem.ver.tables
330 TABLEOPTS_TESTS = tableopts_opt_nr-Ca.opt tableopts_opt_nr-Ce.opt tableopts_opt_nr-Cf.opt tableopts_opt_nr-C_F.opt tableopts_opt_nr-Cm.opt tableopts_opt_nr-Cem.opt tableopts_opt_nr-Cae.opt tableopts_opt_nr-Caef.opt tableopts_opt_nr-Cae_F.opt tableopts_opt_nr-Cam.opt tableopts_opt_nr-Caem.opt tableopts_opt_r-Ca.opt tableopts_opt_r-Ce.opt tableopts_opt_r-Cf.opt tableopts_opt_r-C_F.opt tableopts_opt_r-Cm.opt tableopts_opt_r-Cem.opt tableopts_opt_r-Cae.opt tableopts_opt_r-Caef.opt tableopts_opt_r-Cae_F.opt tableopts_opt_r-Cam.opt tableopts_opt_r-Caem.opt tableopts_ser_nr-Ca.ser tableopts_ser_nr-Ce.ser tableopts_ser_nr-Cf.ser tableopts_ser_nr-C_F.ser tableopts_ser_nr-Cm.ser tableopts_ser_nr-Cem.ser tableopts_ser_nr-Cae.ser tableopts_ser_nr-Caef.ser tableopts_ser_nr-Cae_F.ser tableopts_ser_nr-Cam.ser tableopts_ser_nr-Caem.ser tableopts_ser_r-Ca.ser tableopts_ser_r-Ce.ser tableopts_ser_r-Cf.ser tableopts_ser_r-C_F.ser tableopts_ser_r-Cm.ser tableopts_ser_r-Cem.ser tableopts_ser_r-Cae.ser tableopts_ser_r-Caef.ser tableopts_ser_r-Cae_F.ser tableopts_ser_r-Cam.ser tableopts_ser_r-Caem.ser tableopts_ver_nr-Ca.ver tableopts_ver_nr-Ce.ver tableopts_ver_nr-Cf.ver tableopts_ver_nr-C_F.ver tableopts_ver_nr-Cm.ver tableopts_ver_nr-Cem.ver tableopts_ver_nr-Cae.ver tableopts_ver_nr-Caef.ver tableopts_ver_nr-Cae_F.ver tableopts_ver_nr-Cam.ver tableopts_ver_nr-Caem.ver tableopts_ver_r-Ca.ver tableopts_ver_r-Ce.ver tableopts_ver_r-Cf.ver tableopts_ver_r-C_F.ver tableopts_ver_r-Cm.ver tableopts_ver_r-Cem.ver tableopts_ver_r-Cae.ver tableopts_ver_r-Caef.ver tableopts_ver_r-Cae_F.ver tableopts_ver_r-Cam.ver tableopts_ver_r-Caem.ver
331
332 tableopts_tables = tableopts_ser_nr-Ca.ser.tables tableopts_ser_nr-Ce.ser.tables tableopts_ser_nr-Cf.ser.tables tableopts_ser_nr-C_F.ser.tables tableopts_ser_nr-Cm.ser.tables tableopts_ser_nr-Cem.ser.tables tableopts_ser_nr-Cae.ser.tables tableopts_ser_nr-Caef.ser.tables tableopts_ser_nr-Cae_F.ser.tables tableopts_ser_nr-Cam.ser.tables tableopts_ser_nr-Caem.ser.tables tableopts_ser_r-Ca.ser.tables tableopts_ser_r-Ce.ser.tables tableopts_ser_r-Cf.ser.tables tableopts_ser_r-C_F.ser.tables tableopts_ser_r-Cm.ser.tables tableopts_ser_r-Cem.ser.tables tableopts_ser_r-Cae.ser.tables tableopts_ser_r-Caef.ser.tables tableopts_ser_r-Cae_F.ser.tables tableopts_ser_r-Cam.ser.tables tableopts_ser_r-Caem.ser.tables tableopts_ver_nr-Ca.ver.tables tableopts_ver_nr-Ce.ver.tables tableopts_ver_nr-Cf.ver.tables tableopts_ver_nr-C_F.ver.tables tableopts_ver_nr-Cm.ver.tables tableopts_ver_nr-Cem.ver.tables tableopts_ver_nr-Cae.ver.tables tableopts_ver_nr-Caef.ver.tables tableopts_ver_nr-Cae_F.ver.tables tableopts_ver_nr-Cam.ver.tables tableopts_ver_nr-Caem.ver.tables tableopts_ver_r-Ca.ver.tables tableopts_ver_r-Ce.ver.tables tableopts_ver_r-Cf.ver.tables tableopts_ver_r-C_F.ver.tables tableopts_ver_r-Cm.ver.tables tableopts_ver_r-Cem.ver.tables tableopts_ver_r-Cae.ver.tables tableopts_ver_r-Caef.ver.tables tableopts_ver_r-Cae_F.ver.tables tableopts_ver_r-Cam.ver.tables tableopts_ver_r-Caem.ver.tables
1616 for kind in opt ser ver ; do
1717 for threading in nr r ; do
1818 for opt in -Ca -Ce -Cf -CF -Cm -Cem -Cae -Caef -CaeF -Cam -Caem ; do
19 testname=tableopts_${kind}_${threading}${opt}.${kind}
19 bare_opt=${opt#-}
20 # The filenames must work on case-insensitive filesystems.
21 bare_opt=`echo ${bare_opt}| sed 's/F$/_F/'`
22
23 testname=tableopts_${kind}_${threading}-${bare_opt}.${kind}
2024 if [ "${TABLEOPTS_TESTS}" = "" ] ;then
2125 TABLEOPTS_TESTS=${testname}
2226 if [ "$kind" = "ser" ] || [ "$kind" = "ver" ] ; then
2933 fi
3034 fi
3135
32 bare_opt=${opt#-}
3336 cat << EOF
3437 tableopts_${kind}_${threading}_${bare_opt}_${kind}_SOURCES = tableopts.l4
3538
36 ${testname}\$(EXEEXT): tableopts_${kind}_${threading}${opt}.\$(OBJEXT)
39 ${testname}\$(EXEEXT): tableopts_${kind}_${threading}-${bare_opt}.\$(OBJEXT)
3740 \$(AM_V_CCLD)\$(LINK) -o \$@ \$<
3841
3942 EOF
00 #!/bin/sh
1 set -vx
1 echo 'set -euvx'
22 set -euvx
33
44 # testwrapper-direct.sh: run some specialized flex tests that care where
00 #!/bin/sh
1 set -vx
1 echo 'set -euvx'
22 set -euvx
33
44 # testwrapper.sh: run a flex test, typically called by a Makefile