1#! /bin/sh 2# Generated from testsuite.at by GNU Autoconf 2.69. 3# 4# Copyright (C) 2009-2012 Free Software Foundation, Inc. 5# 6# This test suite is free software; the Free Software Foundation gives 7# unlimited permission to copy, distribute and modify it. 8## -------------------- ## 9## M4sh Initialization. ## 10## -------------------- ## 11 12# Be more Bourne compatible 13DUALCASE=1; export DUALCASE # for MKS sh 14if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 15 emulate sh 16 NULLCMD=: 17 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 18 # is contrary to our usage. Disable this feature. 19 alias -g '${1+"$@"}'='"$@"' 20 setopt NO_GLOB_SUBST 21else 22 case `(set -o) 2>/dev/null` in #( 23 *posix*) : 24 set -o posix ;; #( 25 *) : 26 ;; 27esac 28fi 29 30 31as_nl=' 32' 33export as_nl 34# Printing a long string crashes Solaris 7 /usr/bin/printf. 35as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 36as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 37as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 38# Prefer a ksh shell builtin over an external printf program on Solaris, 39# but without wasting forks for bash or zsh. 40if test -z "$BASH_VERSION$ZSH_VERSION" \ 41 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 42 as_echo='print -r --' 43 as_echo_n='print -rn --' 44elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 45 as_echo='printf %s\n' 46 as_echo_n='printf %s' 47else 48 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 49 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 50 as_echo_n='/usr/ucb/echo -n' 51 else 52 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 53 as_echo_n_body='eval 54 arg=$1; 55 case $arg in #( 56 *"$as_nl"*) 57 expr "X$arg" : "X\\(.*\\)$as_nl"; 58 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 59 esac; 60 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 61 ' 62 export as_echo_n_body 63 as_echo_n='sh -c $as_echo_n_body as_echo' 64 fi 65 export as_echo_body 66 as_echo='sh -c $as_echo_body as_echo' 67fi 68 69# The user is always right. 70if test "${PATH_SEPARATOR+set}" != set; then 71 PATH_SEPARATOR=: 72 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 73 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 74 PATH_SEPARATOR=';' 75 } 76fi 77 78 79# IFS 80# We need space, tab and new line, in precisely that order. Quoting is 81# there to prevent editors from complaining about space-tab. 82# (If _AS_PATH_WALK were called with IFS unset, it would disable word 83# splitting by setting IFS to empty value.) 84IFS=" "" $as_nl" 85 86# Find who we are. Look in the path if we contain no directory separator. 87as_myself= 88case $0 in #(( 89 *[\\/]* ) as_myself=$0 ;; 90 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 91for as_dir in $PATH 92do 93 IFS=$as_save_IFS 94 test -z "$as_dir" && as_dir=. 95 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 96 done 97IFS=$as_save_IFS 98 99 ;; 100esac 101# We did not find ourselves, most probably we were run as `sh COMMAND' 102# in which case we are not to be found in the path. 103if test "x$as_myself" = x; then 104 as_myself=$0 105fi 106if test ! -f "$as_myself"; then 107 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 108 exit 1 109fi 110 111# Unset variables that we do not need and which cause bugs (e.g. in 112# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 113# suppresses any "Segmentation fault" message there. '((' could 114# trigger a bug in pdksh 5.2.14. 115for as_var in BASH_ENV ENV MAIL MAILPATH 116do eval test x\${$as_var+set} = xset \ 117 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 118done 119PS1='$ ' 120PS2='> ' 121PS4='+ ' 122 123# NLS nuisances. 124LC_ALL=C 125export LC_ALL 126LANGUAGE=C 127export LANGUAGE 128 129# CDPATH. 130(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 131 132if test "x$CONFIG_SHELL" = x; then 133 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : 134 emulate sh 135 NULLCMD=: 136 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which 137 # is contrary to our usage. Disable this feature. 138 alias -g '\${1+\"\$@\"}'='\"\$@\"' 139 setopt NO_GLOB_SUBST 140else 141 case \`(set -o) 2>/dev/null\` in #( 142 *posix*) : 143 set -o posix ;; #( 144 *) : 145 ;; 146esac 147fi 148" 149 as_required="as_fn_return () { (exit \$1); } 150as_fn_success () { as_fn_return 0; } 151as_fn_failure () { as_fn_return 1; } 152as_fn_ret_success () { return 0; } 153as_fn_ret_failure () { return 1; } 154 155exitcode=0 156as_fn_success || { exitcode=1; echo as_fn_success failed.; } 157as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } 158as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } 159as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } 160if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : 161 162else 163 exitcode=1; echo positional parameters were not saved. 164fi 165test x\$exitcode = x0 || exit 1 166test -x / || exit 1" 167 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO 168 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO 169 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && 170 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 171test \$(( 1 + 1 )) = 2 || exit 1" 172 if (eval "$as_required") 2>/dev/null; then : 173 as_have_required=yes 174else 175 as_have_required=no 176fi 177 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : 178 179else 180 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 181as_found=false 182for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH 183do 184 IFS=$as_save_IFS 185 test -z "$as_dir" && as_dir=. 186 as_found=: 187 case $as_dir in #( 188 /*) 189 for as_base in sh bash ksh sh5; do 190 # Try only shells that exist, to save several forks. 191 as_shell=$as_dir/$as_base 192 if { test -f "$as_shell" || test -f "$as_shell.exe"; } && 193 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : 194 CONFIG_SHELL=$as_shell as_have_required=yes 195 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : 196 break 2 197fi 198fi 199 done;; 200 esac 201 as_found=false 202done 203$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && 204 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : 205 CONFIG_SHELL=$SHELL as_have_required=yes 206fi; } 207IFS=$as_save_IFS 208 209 210 if test "x$CONFIG_SHELL" != x; then : 211 export CONFIG_SHELL 212 # We cannot yet assume a decent shell, so we have to provide a 213# neutralization value for shells without unset; and this also 214# works around shells that cannot unset nonexistent variables. 215# Preserve -v and -x to the replacement shell. 216BASH_ENV=/dev/null 217ENV=/dev/null 218(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV 219case $- in # (((( 220 *v*x* | *x*v* ) as_opts=-vx ;; 221 *v* ) as_opts=-v ;; 222 *x* ) as_opts=-x ;; 223 * ) as_opts= ;; 224esac 225exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} 226# Admittedly, this is quite paranoid, since all the known shells bail 227# out after a failed `exec'. 228$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 229exit 255 230fi 231 232 if test x$as_have_required = xno; then : 233 $as_echo "$0: This script requires a shell more modern than all" 234 $as_echo "$0: the shells that I found on your system." 235 if test x${ZSH_VERSION+set} = xset ; then 236 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" 237 $as_echo "$0: be upgraded to zsh 4.3.4 or later." 238 else 239 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, 240$0: including any error possibly output before this 241$0: message. Then install a modern shell, or manually run 242$0: the script under such a shell if you do have one." 243 fi 244 exit 1 245fi 246fi 247fi 248SHELL=${CONFIG_SHELL-/bin/sh} 249export SHELL 250# Unset more variables known to interfere with behavior of common tools. 251CLICOLOR_FORCE= GREP_OPTIONS= 252unset CLICOLOR_FORCE GREP_OPTIONS 253 254## --------------------- ## 255## M4sh Shell Functions. ## 256## --------------------- ## 257# as_fn_unset VAR 258# --------------- 259# Portably unset VAR. 260as_fn_unset () 261{ 262 { eval $1=; unset $1;} 263} 264as_unset=as_fn_unset 265 266# as_fn_set_status STATUS 267# ----------------------- 268# Set $? to STATUS, without forking. 269as_fn_set_status () 270{ 271 return $1 272} # as_fn_set_status 273 274# as_fn_exit STATUS 275# ----------------- 276# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 277as_fn_exit () 278{ 279 set +e 280 as_fn_set_status $1 281 exit $1 282} # as_fn_exit 283 284# as_fn_mkdir_p 285# ------------- 286# Create "$as_dir" as a directory, including parents if necessary. 287as_fn_mkdir_p () 288{ 289 290 case $as_dir in #( 291 -*) as_dir=./$as_dir;; 292 esac 293 test -d "$as_dir" || eval $as_mkdir_p || { 294 as_dirs= 295 while :; do 296 case $as_dir in #( 297 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 298 *) as_qdir=$as_dir;; 299 esac 300 as_dirs="'$as_qdir' $as_dirs" 301 as_dir=`$as_dirname -- "$as_dir" || 302$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 303 X"$as_dir" : 'X\(//\)[^/]' \| \ 304 X"$as_dir" : 'X\(//\)$' \| \ 305 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 306$as_echo X"$as_dir" | 307 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 308 s//\1/ 309 q 310 } 311 /^X\(\/\/\)[^/].*/{ 312 s//\1/ 313 q 314 } 315 /^X\(\/\/\)$/{ 316 s//\1/ 317 q 318 } 319 /^X\(\/\).*/{ 320 s//\1/ 321 q 322 } 323 s/.*/./; q'` 324 test -d "$as_dir" && break 325 done 326 test -z "$as_dirs" || eval "mkdir $as_dirs" 327 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 328 329 330} # as_fn_mkdir_p 331 332# as_fn_executable_p FILE 333# ----------------------- 334# Test if FILE is an executable regular file. 335as_fn_executable_p () 336{ 337 test -f "$1" && test -x "$1" 338} # as_fn_executable_p 339# as_fn_append VAR VALUE 340# ---------------------- 341# Append the text in VALUE to the end of the definition contained in VAR. Take 342# advantage of any shell optimizations that allow amortized linear growth over 343# repeated appends, instead of the typical quadratic growth present in naive 344# implementations. 345if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 346 eval 'as_fn_append () 347 { 348 eval $1+=\$2 349 }' 350else 351 as_fn_append () 352 { 353 eval $1=\$$1\$2 354 } 355fi # as_fn_append 356 357# as_fn_arith ARG... 358# ------------------ 359# Perform arithmetic evaluation on the ARGs, and store the result in the 360# global $as_val. Take advantage of shells that can avoid forks. The arguments 361# must be portable across $(()) and expr. 362if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 363 eval 'as_fn_arith () 364 { 365 as_val=$(( $* )) 366 }' 367else 368 as_fn_arith () 369 { 370 as_val=`expr "$@" || test $? -eq 1` 371 } 372fi # as_fn_arith 373 374 375# as_fn_error STATUS ERROR [LINENO LOG_FD] 376# ---------------------------------------- 377# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 378# provided, also output the error to LOG_FD, referencing LINENO. Then exit the 379# script with STATUS, using 1 if that was 0. 380as_fn_error () 381{ 382 as_status=$1; test $as_status -eq 0 && as_status=1 383 if test "$4"; then 384 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 385 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 386 fi 387 $as_echo "$as_me: error: $2" >&2 388 as_fn_exit $as_status 389} # as_fn_error 390 391if expr a : '\(a\)' >/dev/null 2>&1 && 392 test "X`expr 00001 : '.*\(...\)'`" = X001; then 393 as_expr=expr 394else 395 as_expr=false 396fi 397 398if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 399 as_basename=basename 400else 401 as_basename=false 402fi 403 404as_me=`$as_basename -- "$0" || 405$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 406 X"$0" : 'X\(//\)$' \| \ 407 X"$0" : 'X\(/\)' \| . 2>/dev/null || 408$as_echo X/"$0" | 409 sed '/^.*\/\([^/][^/]*\)\/*$/{ 410 s//\1/ 411 q 412 } 413 /^X\/\(\/\/\)$/{ 414 s//\1/ 415 q 416 } 417 /^X\/\(\/\).*/{ 418 s//\1/ 419 q 420 } 421 s/.*/./; q'` 422 423if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 424 as_dirname=dirname 425else 426 as_dirname=false 427fi 428 429# Avoid depending upon Character Ranges. 430as_cr_letters='abcdefghijklmnopqrstuvwxyz' 431as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 432as_cr_Letters=$as_cr_letters$as_cr_LETTERS 433as_cr_digits='0123456789' 434as_cr_alnum=$as_cr_Letters$as_cr_digits 435 436 437 as_lineno_1=$LINENO as_lineno_1a=$LINENO 438 as_lineno_2=$LINENO as_lineno_2a=$LINENO 439 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && 440 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { 441 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) 442 sed -n ' 443 p 444 /[$]LINENO/= 445 ' <$as_myself | 446 sed ' 447 s/[$]LINENO.*/&-/ 448 t lineno 449 b 450 :lineno 451 N 452 :loop 453 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ 454 t loop 455 s/-\n.*// 456 ' >$as_me.lineno && 457 chmod +x "$as_me.lineno" || 458 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } 459 460 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have 461 # already done that, so ensure we don't try to do so again and fall 462 # in an infinite loop. This has already happened in practice. 463 _as_can_reexec=no; export _as_can_reexec 464 # Don't try to exec as it changes $[0], causing all sort of problems 465 # (the dirname of $[0] is not the place where we might find the 466 # original and so on. Autoconf is especially sensitive to this). 467 . "./$as_me.lineno" 468 # Exit status is that of the last command. 469 exit 470} 471 472ECHO_C= ECHO_N= ECHO_T= 473case `echo -n x` in #((((( 474-n*) 475 case `echo 'xy\c'` in 476 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 477 xy) ECHO_C='\c';; 478 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 479 ECHO_T=' ';; 480 esac;; 481*) 482 ECHO_N='-n';; 483esac 484 485rm -f conf$$ conf$$.exe conf$$.file 486if test -d conf$$.dir; then 487 rm -f conf$$.dir/conf$$.file 488else 489 rm -f conf$$.dir 490 mkdir conf$$.dir 2>/dev/null 491fi 492if (echo >conf$$.file) 2>/dev/null; then 493 if ln -s conf$$.file conf$$ 2>/dev/null; then 494 as_ln_s='ln -s' 495 # ... but there are two gotchas: 496 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 497 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 498 # In both cases, we have to default to `cp -pR'. 499 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 500 as_ln_s='cp -pR' 501 elif ln conf$$.file conf$$ 2>/dev/null; then 502 as_ln_s=ln 503 else 504 as_ln_s='cp -pR' 505 fi 506else 507 as_ln_s='cp -pR' 508fi 509rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 510rmdir conf$$.dir 2>/dev/null 511 512if mkdir -p . 2>/dev/null; then 513 as_mkdir_p='mkdir -p "$as_dir"' 514else 515 test -d ./-p && rmdir ./-p 516 as_mkdir_p=false 517fi 518 519as_test_x='test -x' 520as_executable_p=as_fn_executable_p 521 522# Sed expression to map a string onto a valid CPP name. 523as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 524 525# Sed expression to map a string onto a valid variable name. 526as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 527 528 529 530 531 532SHELL=${CONFIG_SHELL-/bin/sh} 533 534# How were we run? 535at_cli_args="$@" 536 537 538# Not all shells have the 'times' builtin; the subshell is needed to make 539# sure we discard the 'times: not found' message from the shell. 540at_times_p=false 541(times) >/dev/null 2>&1 && at_times_p=: 542 543# CLI Arguments to pass to the debugging scripts. 544at_debug_args= 545# -e sets to true 546at_errexit_p=false 547# Shall we be verbose? ':' means no, empty means yes. 548at_verbose=: 549at_quiet= 550# Running several jobs in parallel, 0 means as many as test groups. 551at_jobs=1 552at_traceon=: 553at_trace_echo=: 554at_check_filter_trace=: 555 556# Shall we keep the debug scripts? Must be `:' when the suite is 557# run by a debug script, so that the script doesn't remove itself. 558at_debug_p=false 559# Display help message? 560at_help_p=false 561# Display the version message? 562at_version_p=false 563# List test groups? 564at_list_p=false 565# --clean 566at_clean=false 567# Test groups to run 568at_groups= 569# Whether to rerun failed tests. 570at_recheck= 571# Whether a write failure occurred 572at_write_fail=0 573 574# The directory we run the suite in. Default to . if no -C option. 575at_dir=`pwd` 576# An absolute reference to this testsuite script. 577case $as_myself in 578 [\\/]* | ?:[\\/]* ) at_myself=$as_myself ;; 579 * ) at_myself=$at_dir/$as_myself ;; 580esac 581# Whether -C is in effect. 582at_change_dir=false 583 584# Whether to enable colored test results. 585at_color=no 586# List of the tested programs. 587at_tested='' 588# As many question marks as there are digits in the last test group number. 589# Used to normalize the test group numbers so that `ls' lists them in 590# numerical order. 591at_format='??' 592# Description of all the test groups. 593at_help_all="1;exact.at:17;exact;match exact; 5942;prefix.at:17;prefix;match re; 5953;suffix.at:17;suffix;match suffix; 5964;lev.at:17;Levenshtein;match lev; 5975;nlev.at:17;Levenshtein normalized;match nlev; 5986;dlev.at:17;Damerau-Levenshtein;match dlev; 5997;dnlev.at:17;Damerau-Levenshtein normalized;match ndlev; 6008;soundex.at:17;SOUNDEX;match soundex; 6019;regexp.at:17;Basic regular expressions;match regexp; 60210;re.at:17;Extended regular expressions;match re; 60311;define.at:17;define;define; 60412;mime.at:17;option mime;option mime; 60513;showdb.at:17;show db;show showdb; 60614;showinfo.at:17;show info;show showinfo; 60715;showlang.at:17;show lang info;show lang showlang; 608" 609# List of the all the test groups. 610at_groups_all=`$as_echo "$at_help_all" | sed 's/;.*//'` 611 612# at_fn_validate_ranges NAME... 613# ----------------------------- 614# Validate and normalize the test group number contained in each variable 615# NAME. Leading zeroes are treated as decimal. 616at_fn_validate_ranges () 617{ 618 for at_grp 619 do 620 eval at_value=\$$at_grp 621 if test $at_value -lt 1 || test $at_value -gt 15; then 622 $as_echo "invalid test group: $at_value" >&2 623 exit 1 624 fi 625 case $at_value in 626 0*) # We want to treat leading 0 as decimal, like expr and test, but 627 # AS_VAR_ARITH treats it as octal if it uses $(( )). 628 # With XSI shells, ${at_value#${at_value%%[1-9]*}} avoids the 629 # expr fork, but it is not worth the effort to determine if the 630 # shell supports XSI when the user can just avoid leading 0. 631 eval $at_grp='`expr $at_value + 0`' ;; 632 esac 633 done 634} 635 636at_prev= 637for at_option 638do 639 # If the previous option needs an argument, assign it. 640 if test -n "$at_prev"; then 641 at_option=$at_prev=$at_option 642 at_prev= 643 fi 644 645 case $at_option in 646 *=?*) at_optarg=`expr "X$at_option" : '[^=]*=\(.*\)'` ;; 647 *) at_optarg= ;; 648 esac 649 650 # Accept the important Cygnus configure options, so we can diagnose typos. 651 652 case $at_option in 653 --help | -h ) 654 at_help_p=: 655 ;; 656 657 --list | -l ) 658 at_list_p=: 659 ;; 660 661 --version | -V ) 662 at_version_p=: 663 ;; 664 665 --clean | -c ) 666 at_clean=: 667 ;; 668 669 --color ) 670 at_color=always 671 ;; 672 --color=* ) 673 case $at_optarg in 674 no | never | none) at_color=never ;; 675 auto | tty | if-tty) at_color=auto ;; 676 always | yes | force) at_color=always ;; 677 *) at_optname=`echo " $at_option" | sed 's/^ //; s/=.*//'` 678 as_fn_error $? "unrecognized argument to $at_optname: $at_optarg" ;; 679 esac 680 ;; 681 682 --debug | -d ) 683 at_debug_p=: 684 ;; 685 686 --errexit | -e ) 687 at_debug_p=: 688 at_errexit_p=: 689 ;; 690 691 --verbose | -v ) 692 at_verbose=; at_quiet=: 693 ;; 694 695 --trace | -x ) 696 at_traceon='set -x' 697 at_trace_echo=echo 698 at_check_filter_trace=at_fn_filter_trace 699 ;; 700 701 [0-9] | [0-9][0-9] | [0-9][0-9][0-9] | [0-9][0-9][0-9][0-9]) 702 at_fn_validate_ranges at_option 703 as_fn_append at_groups "$at_option$as_nl" 704 ;; 705 706 # Ranges 707 [0-9]- | [0-9][0-9]- | [0-9][0-9][0-9]- | [0-9][0-9][0-9][0-9]-) 708 at_range_start=`echo $at_option |tr -d X-` 709 at_fn_validate_ranges at_range_start 710 at_range=`$as_echo "$at_groups_all" | \ 711 sed -ne '/^'$at_range_start'$/,$p'` 712 as_fn_append at_groups "$at_range$as_nl" 713 ;; 714 715 -[0-9] | -[0-9][0-9] | -[0-9][0-9][0-9] | -[0-9][0-9][0-9][0-9]) 716 at_range_end=`echo $at_option |tr -d X-` 717 at_fn_validate_ranges at_range_end 718 at_range=`$as_echo "$at_groups_all" | \ 719 sed -ne '1,/^'$at_range_end'$/p'` 720 as_fn_append at_groups "$at_range$as_nl" 721 ;; 722 723 [0-9]-[0-9] | [0-9]-[0-9][0-9] | [0-9]-[0-9][0-9][0-9] | \ 724 [0-9]-[0-9][0-9][0-9][0-9] | [0-9][0-9]-[0-9][0-9] | \ 725 [0-9][0-9]-[0-9][0-9][0-9] | [0-9][0-9]-[0-9][0-9][0-9][0-9] | \ 726 [0-9][0-9][0-9]-[0-9][0-9][0-9] | \ 727 [0-9][0-9][0-9]-[0-9][0-9][0-9][0-9] | \ 728 [0-9][0-9][0-9][0-9]-[0-9][0-9][0-9][0-9] ) 729 at_range_start=`expr $at_option : '\(.*\)-'` 730 at_range_end=`expr $at_option : '.*-\(.*\)'` 731 if test $at_range_start -gt $at_range_end; then 732 at_tmp=$at_range_end 733 at_range_end=$at_range_start 734 at_range_start=$at_tmp 735 fi 736 at_fn_validate_ranges at_range_start at_range_end 737 at_range=`$as_echo "$at_groups_all" | \ 738 sed -ne '/^'$at_range_start'$/,/^'$at_range_end'$/p'` 739 as_fn_append at_groups "$at_range$as_nl" 740 ;; 741 742 # Directory selection. 743 --directory | -C ) 744 at_prev=--directory 745 ;; 746 --directory=* ) 747 at_change_dir=: 748 at_dir=$at_optarg 749 if test x- = "x$at_dir" ; then 750 at_dir=./- 751 fi 752 ;; 753 754 # Parallel execution. 755 --jobs | -j ) 756 at_jobs=0 757 ;; 758 --jobs=* | -j[0-9]* ) 759 if test -n "$at_optarg"; then 760 at_jobs=$at_optarg 761 else 762 at_jobs=`expr X$at_option : 'X-j\(.*\)'` 763 fi 764 case $at_jobs in *[!0-9]*) 765 at_optname=`echo " $at_option" | sed 's/^ //; s/[0-9=].*//'` 766 as_fn_error $? "non-numeric argument to $at_optname: $at_jobs" ;; 767 esac 768 ;; 769 770 # Keywords. 771 --keywords | -k ) 772 at_prev=--keywords 773 ;; 774 --keywords=* ) 775 at_groups_selected=$at_help_all 776 at_save_IFS=$IFS 777 IFS=, 778 set X $at_optarg 779 shift 780 IFS=$at_save_IFS 781 for at_keyword 782 do 783 at_invert= 784 case $at_keyword in 785 '!'*) 786 at_invert="-v" 787 at_keyword=`expr "X$at_keyword" : 'X!\(.*\)'` 788 ;; 789 esac 790 # It is on purpose that we match the test group titles too. 791 at_groups_selected=`$as_echo "$at_groups_selected" | 792 grep -i $at_invert "^[1-9][^;]*;.*[; ]$at_keyword[ ;]"` 793 done 794 # Smash the keywords. 795 at_groups_selected=`$as_echo "$at_groups_selected" | sed 's/;.*//'` 796 as_fn_append at_groups "$at_groups_selected$as_nl" 797 ;; 798 --recheck) 799 at_recheck=: 800 ;; 801 802 *=*) 803 at_envvar=`expr "x$at_option" : 'x\([^=]*\)='` 804 # Reject names that are not valid shell variable names. 805 case $at_envvar in 806 '' | [0-9]* | *[!_$as_cr_alnum]* ) 807 as_fn_error $? "invalid variable name: \`$at_envvar'" ;; 808 esac 809 at_value=`$as_echo "$at_optarg" | sed "s/'/'\\\\\\\\''/g"` 810 # Export now, but save eval for later and for debug scripts. 811 export $at_envvar 812 as_fn_append at_debug_args " $at_envvar='$at_value'" 813 ;; 814 815 *) $as_echo "$as_me: invalid option: $at_option" >&2 816 $as_echo "Try \`$0 --help' for more information." >&2 817 exit 1 818 ;; 819 esac 820done 821 822# Verify our last option didn't require an argument 823if test -n "$at_prev"; then : 824 as_fn_error $? "\`$at_prev' requires an argument" 825fi 826 827# The file containing the suite. 828at_suite_log=$at_dir/$as_me.log 829 830# Selected test groups. 831if test -z "$at_groups$at_recheck"; then 832 at_groups=$at_groups_all 833else 834 if test -n "$at_recheck" && test -r "$at_suite_log"; then 835 at_oldfails=`sed -n ' 836 /^Failed tests:$/,/^Skipped tests:$/{ 837 s/^[ ]*\([1-9][0-9]*\):.*/\1/p 838 } 839 /^Unexpected passes:$/,/^## Detailed failed tests/{ 840 s/^[ ]*\([1-9][0-9]*\):.*/\1/p 841 } 842 /^## Detailed failed tests/q 843 ' "$at_suite_log"` 844 as_fn_append at_groups "$at_oldfails$as_nl" 845 fi 846 # Sort the tests, removing duplicates. 847 at_groups=`$as_echo "$at_groups" | sort -nu | sed '/^$/d'` 848fi 849 850if test x"$at_color" = xalways \ 851 || { test x"$at_color" = xauto && test -t 1; }; then 852 at_red=`printf '\033[0;31m'` 853 at_grn=`printf '\033[0;32m'` 854 at_lgn=`printf '\033[1;32m'` 855 at_blu=`printf '\033[1;34m'` 856 at_std=`printf '\033[m'` 857else 858 at_red= at_grn= at_lgn= at_blu= at_std= 859fi 860 861# Help message. 862if $at_help_p; then 863 cat <<_ATEOF || at_write_fail=1 864Usage: $0 [OPTION]... [VARIABLE=VALUE]... [TESTS] 865 866Run all the tests, or the selected TESTS, given by numeric ranges, and 867save a detailed log file. Upon failure, create debugging scripts. 868 869Do not change environment variables directly. Instead, set them via 870command line arguments. Set \`AUTOTEST_PATH' to select the executables 871to exercise. Each relative directory is expanded as build and source 872directories relative to the top level of this distribution. 873E.g., from within the build directory /tmp/foo-1.0, invoking this: 874 875 $ $0 AUTOTEST_PATH=bin 876 877is equivalent to the following, assuming the source directory is /src/foo-1.0: 878 879 PATH=/tmp/foo-1.0/bin:/src/foo-1.0/bin:\$PATH $0 880_ATEOF 881cat <<_ATEOF || at_write_fail=1 882 883Operation modes: 884 -h, --help print the help message, then exit 885 -V, --version print version number, then exit 886 -c, --clean remove all the files this test suite might create and exit 887 -l, --list describes all the tests, or the selected TESTS 888_ATEOF 889cat <<_ATEOF || at_write_fail=1 890 891Execution tuning: 892 -C, --directory=DIR 893 change to directory DIR before starting 894 --color[=never|auto|always] 895 enable colored test results on terminal, or always 896 -j, --jobs[=N] 897 Allow N jobs at once; infinite jobs with no arg (default 1) 898 -k, --keywords=KEYWORDS 899 select the tests matching all the comma-separated KEYWORDS 900 multiple \`-k' accumulate; prefixed \`!' negates a KEYWORD 901 --recheck select all tests that failed or passed unexpectedly last time 902 -e, --errexit abort as soon as a test fails; implies --debug 903 -v, --verbose force more detailed output 904 default for debugging scripts 905 -d, --debug inhibit clean up and top-level logging 906 default for debugging scripts 907 -x, --trace enable tests shell tracing 908_ATEOF 909cat <<_ATEOF || at_write_fail=1 910 911Report bugs to <bug-dico@gnu.org>. 912General help using GNU software: <http://www.gnu.org/gethelp/>. 913_ATEOF 914 exit $at_write_fail 915fi 916 917# List of tests. 918if $at_list_p; then 919 cat <<_ATEOF || at_write_fail=1 920GNU dico 2.10 test suite test groups: 921 922 NUM: FILE-NAME:LINE TEST-GROUP-NAME 923 KEYWORDS 924 925_ATEOF 926 # Pass an empty line as separator between selected groups and help. 927 $as_echo "$at_groups$as_nl$as_nl$at_help_all" | 928 awk 'NF == 1 && FS != ";" { 929 selected[$ 1] = 1 930 next 931 } 932 /^$/ { FS = ";" } 933 NF > 0 { 934 if (selected[$ 1]) { 935 printf " %3d: %-18s %s\n", $ 1, $ 2, $ 3 936 if ($ 4) { 937 lmax = 79 938 indent = " " 939 line = indent 940 len = length (line) 941 n = split ($ 4, a, " ") 942 for (i = 1; i <= n; i++) { 943 l = length (a[i]) + 1 944 if (i > 1 && len + l > lmax) { 945 print line 946 line = indent " " a[i] 947 len = length (line) 948 } else { 949 line = line " " a[i] 950 len += l 951 } 952 } 953 if (n) 954 print line 955 } 956 } 957 }' || at_write_fail=1 958 exit $at_write_fail 959fi 960if $at_version_p; then 961 $as_echo "$as_me (GNU dico 2.10)" && 962 cat <<\_ATEOF || at_write_fail=1 963 964Copyright (C) 2012 Free Software Foundation, Inc. 965This test suite is free software; the Free Software Foundation gives 966unlimited permission to copy, distribute and modify it. 967_ATEOF 968 exit $at_write_fail 969fi 970 971# Should we print banners? Yes if more than one test is run. 972case $at_groups in #( 973 *$as_nl* ) 974 at_print_banners=: ;; #( 975 * ) at_print_banners=false ;; 976esac 977# Text for banner N, set to a single space once printed. 978# Banner 1. testsuite.at:23 979# Category starts at test group 1. 980at_banner_text_1="Match" 981# Banner 2. testsuite.at:35 982# Category starts at test group 11. 983at_banner_text_2="Define" 984# Banner 3. testsuite.at:39 985# Category starts at test group 13. 986at_banner_text_3="Show" 987 988# Take any -C into account. 989if $at_change_dir ; then 990 test x != "x$at_dir" && cd "$at_dir" \ 991 || as_fn_error $? "unable to change directory" 992 at_dir=`pwd` 993fi 994 995# Load the config files for any default variable assignments. 996for at_file in atconfig atlocal 997do 998 test -r $at_file || continue 999 . ./$at_file || as_fn_error $? "invalid content: $at_file" 1000done 1001 1002# Autoconf <=2.59b set at_top_builddir instead of at_top_build_prefix: 1003: "${at_top_build_prefix=$at_top_builddir}" 1004 1005# Perform any assignments requested during argument parsing. 1006eval "$at_debug_args" 1007 1008# atconfig delivers names relative to the directory the test suite is 1009# in, but the groups themselves are run in testsuite-dir/group-dir. 1010if test -n "$at_top_srcdir"; then 1011 builddir=../.. 1012 for at_dir_var in srcdir top_srcdir top_build_prefix 1013 do 1014 eval at_val=\$at_$at_dir_var 1015 case $at_val in 1016 [\\/$]* | ?:[\\/]* ) at_prefix= ;; 1017 *) at_prefix=../../ ;; 1018 esac 1019 eval "$at_dir_var=\$at_prefix\$at_val" 1020 done 1021fi 1022 1023## -------------------- ## 1024## Directory structure. ## 1025## -------------------- ## 1026 1027# This is the set of directories and files used by this script 1028# (non-literals are capitalized): 1029# 1030# TESTSUITE - the testsuite 1031# TESTSUITE.log - summarizes the complete testsuite run 1032# TESTSUITE.dir/ - created during a run, remains after -d or failed test 1033# + at-groups/ - during a run: status of all groups in run 1034# | + NNN/ - during a run: meta-data about test group NNN 1035# | | + check-line - location (source file and line) of current AT_CHECK 1036# | | + status - exit status of current AT_CHECK 1037# | | + stdout - stdout of current AT_CHECK 1038# | | + stder1 - stderr, including trace 1039# | | + stderr - stderr, with trace filtered out 1040# | | + test-source - portion of testsuite that defines group 1041# | | + times - timestamps for computing duration 1042# | | + pass - created if group passed 1043# | | + xpass - created if group xpassed 1044# | | + fail - created if group failed 1045# | | + xfail - created if group xfailed 1046# | | + skip - created if group skipped 1047# + at-stop - during a run: end the run if this file exists 1048# + at-source-lines - during a run: cache of TESTSUITE line numbers for extraction 1049# + 0..NNN/ - created for each group NNN, remains after -d or failed test 1050# | + TESTSUITE.log - summarizes the group results 1051# | + ... - files created during the group 1052 1053# The directory the whole suite works in. 1054# Should be absolute to let the user `cd' at will. 1055at_suite_dir=$at_dir/$as_me.dir 1056# The file containing the suite ($at_dir might have changed since earlier). 1057at_suite_log=$at_dir/$as_me.log 1058# The directory containing helper files per test group. 1059at_helper_dir=$at_suite_dir/at-groups 1060# Stop file: if it exists, do not start new jobs. 1061at_stop_file=$at_suite_dir/at-stop 1062# The fifo used for the job dispatcher. 1063at_job_fifo=$at_suite_dir/at-job-fifo 1064 1065if $at_clean; then 1066 test -d "$at_suite_dir" && 1067 find "$at_suite_dir" -type d ! -perm -700 -exec chmod u+rwx \{\} \; 1068 rm -f -r "$at_suite_dir" "$at_suite_log" 1069 exit $? 1070fi 1071 1072# Don't take risks: use only absolute directories in PATH. 1073# 1074# For stand-alone test suites (ie. atconfig was not found), 1075# AUTOTEST_PATH is relative to `.'. 1076# 1077# For embedded test suites, AUTOTEST_PATH is relative to the top level 1078# of the package. Then expand it into build/src parts, since users 1079# may create executables in both places. 1080AUTOTEST_PATH=`$as_echo "$AUTOTEST_PATH" | sed "s|:|$PATH_SEPARATOR|g"` 1081at_path= 1082as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 1083for as_dir in $AUTOTEST_PATH $PATH 1084do 1085 IFS=$as_save_IFS 1086 test -z "$as_dir" && as_dir=. 1087 test -n "$at_path" && as_fn_append at_path $PATH_SEPARATOR 1088case $as_dir in 1089 [\\/]* | ?:[\\/]* ) 1090 as_fn_append at_path "$as_dir" 1091 ;; 1092 * ) 1093 if test -z "$at_top_build_prefix"; then 1094 # Stand-alone test suite. 1095 as_fn_append at_path "$as_dir" 1096 else 1097 # Embedded test suite. 1098 as_fn_append at_path "$at_top_build_prefix$as_dir$PATH_SEPARATOR" 1099 as_fn_append at_path "$at_top_srcdir/$as_dir" 1100 fi 1101 ;; 1102esac 1103 done 1104IFS=$as_save_IFS 1105 1106 1107# Now build and simplify PATH. 1108# 1109# There might be directories that don't exist, but don't redirect 1110# builtins' (eg., cd) stderr directly: Ultrix's sh hates that. 1111at_new_path= 1112as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 1113for as_dir in $at_path 1114do 1115 IFS=$as_save_IFS 1116 test -z "$as_dir" && as_dir=. 1117 test -d "$as_dir" || continue 1118case $as_dir in 1119 [\\/]* | ?:[\\/]* ) ;; 1120 * ) as_dir=`(cd "$as_dir" && pwd) 2>/dev/null` ;; 1121esac 1122case $PATH_SEPARATOR$at_new_path$PATH_SEPARATOR in 1123 *$PATH_SEPARATOR$as_dir$PATH_SEPARATOR*) ;; 1124 $PATH_SEPARATOR$PATH_SEPARATOR) at_new_path=$as_dir ;; 1125 *) as_fn_append at_new_path "$PATH_SEPARATOR$as_dir" ;; 1126esac 1127 done 1128IFS=$as_save_IFS 1129 1130PATH=$at_new_path 1131export PATH 1132 1133# Setting up the FDs. 1134 1135 1136 1137# 5 is the log file. Not to be overwritten if `-d'. 1138if $at_debug_p; then 1139 at_suite_log=/dev/null 1140else 1141 : >"$at_suite_log" 1142fi 1143exec 5>>"$at_suite_log" 1144 1145# Banners and logs. 1146$as_echo "## ------------------------- ## 1147## GNU dico 2.10 test suite. ## 1148## ------------------------- ##" 1149{ 1150 $as_echo "## ------------------------- ## 1151## GNU dico 2.10 test suite. ## 1152## ------------------------- ##" 1153 echo 1154 1155 $as_echo "$as_me: command line was:" 1156 $as_echo " \$ $0 $at_cli_args" 1157 echo 1158 1159 # If ChangeLog exists, list a few lines in case it might help determining 1160 # the exact version. 1161 if test -n "$at_top_srcdir" && test -f "$at_top_srcdir/ChangeLog"; then 1162 $as_echo "## ---------- ## 1163## ChangeLog. ## 1164## ---------- ##" 1165 echo 1166 sed 's/^/| /;10q' "$at_top_srcdir/ChangeLog" 1167 echo 1168 fi 1169 1170 { 1171cat <<_ASUNAME 1172## --------- ## 1173## Platform. ## 1174## --------- ## 1175 1176hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` 1177uname -m = `(uname -m) 2>/dev/null || echo unknown` 1178uname -r = `(uname -r) 2>/dev/null || echo unknown` 1179uname -s = `(uname -s) 2>/dev/null || echo unknown` 1180uname -v = `(uname -v) 2>/dev/null || echo unknown` 1181 1182/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` 1183/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` 1184 1185/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` 1186/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` 1187/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` 1188/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` 1189/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` 1190/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` 1191/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` 1192 1193_ASUNAME 1194 1195as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 1196for as_dir in $PATH 1197do 1198 IFS=$as_save_IFS 1199 test -z "$as_dir" && as_dir=. 1200 $as_echo "PATH: $as_dir" 1201 done 1202IFS=$as_save_IFS 1203 1204} 1205 echo 1206 1207 # Contents of the config files. 1208 for at_file in atconfig atlocal 1209 do 1210 test -r $at_file || continue 1211 $as_echo "$as_me: $at_file:" 1212 sed 's/^/| /' $at_file 1213 echo 1214 done 1215} >&5 1216 1217 1218## ------------------------- ## 1219## Autotest shell functions. ## 1220## ------------------------- ## 1221 1222# at_fn_banner NUMBER 1223# ------------------- 1224# Output banner NUMBER, provided the testsuite is running multiple groups and 1225# this particular banner has not yet been printed. 1226at_fn_banner () 1227{ 1228 $at_print_banners || return 0 1229 eval at_banner_text=\$at_banner_text_$1 1230 test "x$at_banner_text" = "x " && return 0 1231 eval "at_banner_text_$1=\" \"" 1232 if test -z "$at_banner_text"; then 1233 $at_first || echo 1234 else 1235 $as_echo "$as_nl$at_banner_text$as_nl" 1236 fi 1237} # at_fn_banner 1238 1239# at_fn_check_prepare_notrace REASON LINE 1240# --------------------------------------- 1241# Perform AT_CHECK preparations for the command at LINE for an untraceable 1242# command; REASON is the reason for disabling tracing. 1243at_fn_check_prepare_notrace () 1244{ 1245 $at_trace_echo "Not enabling shell tracing (command contains $1)" 1246 $as_echo "$2" >"$at_check_line_file" 1247 at_check_trace=: at_check_filter=: 1248 : >"$at_stdout"; : >"$at_stderr" 1249} 1250 1251# at_fn_check_prepare_trace LINE 1252# ------------------------------ 1253# Perform AT_CHECK preparations for the command at LINE for a traceable 1254# command. 1255at_fn_check_prepare_trace () 1256{ 1257 $as_echo "$1" >"$at_check_line_file" 1258 at_check_trace=$at_traceon at_check_filter=$at_check_filter_trace 1259 : >"$at_stdout"; : >"$at_stderr" 1260} 1261 1262# at_fn_check_prepare_dynamic COMMAND LINE 1263# ---------------------------------------- 1264# Decide if COMMAND at LINE is traceable at runtime, and call the appropriate 1265# preparation function. 1266at_fn_check_prepare_dynamic () 1267{ 1268 case $1 in 1269 *$as_nl*) 1270 at_fn_check_prepare_notrace 'an embedded newline' "$2" ;; 1271 *) 1272 at_fn_check_prepare_trace "$2" ;; 1273 esac 1274} 1275 1276# at_fn_filter_trace 1277# ------------------ 1278# Remove the lines in the file "$at_stderr" generated by "set -x" and print 1279# them to stderr. 1280at_fn_filter_trace () 1281{ 1282 mv "$at_stderr" "$at_stder1" 1283 grep '^ *+' "$at_stder1" >&2 1284 grep -v '^ *+' "$at_stder1" >"$at_stderr" 1285} 1286 1287# at_fn_log_failure FILE-LIST 1288# --------------------------- 1289# Copy the files in the list on stdout with a "> " prefix, and exit the shell 1290# with a failure exit code. 1291at_fn_log_failure () 1292{ 1293 for file 1294 do $as_echo "$file:"; sed 's/^/> /' "$file"; done 1295 echo 1 > "$at_status_file" 1296 exit 1 1297} 1298 1299# at_fn_check_skip EXIT-CODE LINE 1300# ------------------------------- 1301# Check whether EXIT-CODE is a special exit code (77 or 99), and if so exit 1302# the test group subshell with that same exit code. Use LINE in any report 1303# about test failure. 1304at_fn_check_skip () 1305{ 1306 case $1 in 1307 99) echo 99 > "$at_status_file"; at_failed=: 1308 $as_echo "$2: hard failure"; exit 99;; 1309 77) echo 77 > "$at_status_file"; exit 77;; 1310 esac 1311} 1312 1313# at_fn_check_status EXPECTED EXIT-CODE LINE 1314# ------------------------------------------ 1315# Check whether EXIT-CODE is the EXPECTED exit code, and if so do nothing. 1316# Otherwise, if it is 77 or 99, exit the test group subshell with that same 1317# exit code; if it is anything else print an error message referring to LINE, 1318# and fail the test. 1319at_fn_check_status () 1320{ 1321 case $2 in 1322 $1 ) ;; 1323 77) echo 77 > "$at_status_file"; exit 77;; 1324 99) echo 99 > "$at_status_file"; at_failed=: 1325 $as_echo "$3: hard failure"; exit 99;; 1326 *) $as_echo "$3: exit code was $2, expected $1" 1327 at_failed=:;; 1328 esac 1329} 1330 1331# at_fn_diff_devnull FILE 1332# ----------------------- 1333# Emit a diff between /dev/null and FILE. Uses "test -s" to avoid useless diff 1334# invocations. 1335at_fn_diff_devnull () 1336{ 1337 test -s "$1" || return 0 1338 $at_diff "$at_devnull" "$1" 1339} 1340 1341# at_fn_test NUMBER 1342# ----------------- 1343# Parse out test NUMBER from the tail of this file. 1344at_fn_test () 1345{ 1346 eval at_sed=\$at_sed$1 1347 sed "$at_sed" "$at_myself" > "$at_test_source" 1348} 1349 1350# at_fn_create_debugging_script 1351# ----------------------------- 1352# Create the debugging script $at_group_dir/run which will reproduce the 1353# current test group. 1354at_fn_create_debugging_script () 1355{ 1356 { 1357 echo "#! /bin/sh" && 1358 echo 'test "${ZSH_VERSION+set}" = set && alias -g '\''${1+"$@"}'\''='\''"$@"'\''' && 1359 $as_echo "cd '$at_dir'" && 1360 $as_echo "exec \${CONFIG_SHELL-$SHELL} \"$at_myself\" -v -d $at_debug_args $at_group \${1+\"\$@\"}" && 1361 echo 'exit 1' 1362 } >"$at_group_dir/run" && 1363 chmod +x "$at_group_dir/run" 1364} 1365 1366## -------------------------------- ## 1367## End of autotest shell functions. ## 1368## -------------------------------- ## 1369{ 1370 $as_echo "## ---------------- ## 1371## Tested programs. ## 1372## ---------------- ##" 1373 echo 1374} >&5 1375 1376# Report what programs are being tested. 1377for at_program in : $at_tested 1378do 1379 test "$at_program" = : && continue 1380 case $at_program in 1381 [\\/]* | ?:[\\/]* ) $at_program_=$at_program ;; 1382 * ) 1383 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 1384for as_dir in $PATH 1385do 1386 IFS=$as_save_IFS 1387 test -z "$as_dir" && as_dir=. 1388 test -f "$as_dir/$at_program" && break 1389 done 1390IFS=$as_save_IFS 1391 1392 at_program_=$as_dir/$at_program ;; 1393 esac 1394 if test -f "$at_program_"; then 1395 { 1396 $as_echo "$at_srcdir/testsuite.at:19: $at_program_ --version" 1397 "$at_program_" --version </dev/null 1398 echo 1399 } >&5 2>&1 1400 else 1401 as_fn_error $? "cannot find $at_program" "$LINENO" 5 1402 fi 1403done 1404 1405{ 1406 $as_echo "## ------------------ ## 1407## Running the tests. ## 1408## ------------------ ##" 1409} >&5 1410 1411at_start_date=`date` 1412at_start_time=`date +%s 2>/dev/null` 1413$as_echo "$as_me: starting at: $at_start_date" >&5 1414 1415# Create the master directory if it doesn't already exist. 1416as_dir="$at_suite_dir"; as_fn_mkdir_p || 1417 as_fn_error $? "cannot create \`$at_suite_dir'" "$LINENO" 5 1418 1419# Can we diff with `/dev/null'? DU 5.0 refuses. 1420if diff /dev/null /dev/null >/dev/null 2>&1; then 1421 at_devnull=/dev/null 1422else 1423 at_devnull=$at_suite_dir/devnull 1424 >"$at_devnull" 1425fi 1426 1427# Use `diff -u' when possible. 1428if at_diff=`diff -u "$at_devnull" "$at_devnull" 2>&1` && test -z "$at_diff" 1429then 1430 at_diff='diff -u' 1431else 1432 at_diff=diff 1433fi 1434 1435# Get the last needed group. 1436for at_group in : $at_groups; do :; done 1437 1438# Extract the start and end lines of each test group at the tail 1439# of this file 1440awk ' 1441BEGIN { FS="" } 1442/^#AT_START_/ { 1443 start = NR 1444} 1445/^#AT_STOP_/ { 1446 test = substr ($ 0, 10) 1447 print "at_sed" test "=\"1," start "d;" (NR-1) "q\"" 1448 if (test == "'"$at_group"'") exit 1449}' "$at_myself" > "$at_suite_dir/at-source-lines" && 1450. "$at_suite_dir/at-source-lines" || 1451 as_fn_error $? "cannot create test line number cache" "$LINENO" 5 1452rm -f "$at_suite_dir/at-source-lines" 1453 1454# Set number of jobs for `-j'; avoid more jobs than test groups. 1455set X $at_groups; shift; at_max_jobs=$# 1456if test $at_max_jobs -eq 0; then 1457 at_jobs=1 1458fi 1459if test $at_jobs -ne 1 && 1460 { test $at_jobs -eq 0 || test $at_jobs -gt $at_max_jobs; }; then 1461 at_jobs=$at_max_jobs 1462fi 1463 1464# If parallel mode, don't output banners, don't split summary lines. 1465if test $at_jobs -ne 1; then 1466 at_print_banners=false 1467 at_quiet=: 1468fi 1469 1470# Set up helper dirs. 1471rm -rf "$at_helper_dir" && 1472mkdir "$at_helper_dir" && 1473cd "$at_helper_dir" && 1474{ test -z "$at_groups" || mkdir $at_groups; } || 1475as_fn_error $? "testsuite directory setup failed" "$LINENO" 5 1476 1477# Functions for running a test group. We leave the actual 1478# test group execution outside of a shell function in order 1479# to avoid hitting zsh 4.x exit status bugs. 1480 1481# at_fn_group_prepare 1482# ------------------- 1483# Prepare for running a test group. 1484at_fn_group_prepare () 1485{ 1486 # The directory for additional per-group helper files. 1487 at_job_dir=$at_helper_dir/$at_group 1488 # The file containing the location of the last AT_CHECK. 1489 at_check_line_file=$at_job_dir/check-line 1490 # The file containing the exit status of the last command. 1491 at_status_file=$at_job_dir/status 1492 # The files containing the output of the tested commands. 1493 at_stdout=$at_job_dir/stdout 1494 at_stder1=$at_job_dir/stder1 1495 at_stderr=$at_job_dir/stderr 1496 # The file containing the code for a test group. 1497 at_test_source=$at_job_dir/test-source 1498 # The file containing dates. 1499 at_times_file=$at_job_dir/times 1500 1501 # Be sure to come back to the top test directory. 1502 cd "$at_suite_dir" 1503 1504 # Clearly separate the test groups when verbose. 1505 $at_first || $at_verbose echo 1506 1507 at_group_normalized=$at_group 1508 1509 eval 'while :; do 1510 case $at_group_normalized in #( 1511 '"$at_format"'*) break;; 1512 esac 1513 at_group_normalized=0$at_group_normalized 1514 done' 1515 1516 1517 # Create a fresh directory for the next test group, and enter. 1518 # If one already exists, the user may have invoked ./run from 1519 # within that directory; we remove the contents, but not the 1520 # directory itself, so that we aren't pulling the rug out from 1521 # under the shell's notion of the current directory. 1522 at_group_dir=$at_suite_dir/$at_group_normalized 1523 at_group_log=$at_group_dir/$as_me.log 1524 if test -d "$at_group_dir"; then 1525 find "$at_group_dir" -type d ! -perm -700 -exec chmod u+rwx {} \; 1526 rm -fr "$at_group_dir"/* "$at_group_dir"/.[!.] "$at_group_dir"/.??* 1527fi || 1528 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: test directory for $at_group_normalized could not be cleaned" >&5 1529$as_echo "$as_me: WARNING: test directory for $at_group_normalized could not be cleaned" >&2;} 1530 # Be tolerant if the above `rm' was not able to remove the directory. 1531 as_dir="$at_group_dir"; as_fn_mkdir_p 1532 1533 echo 0 > "$at_status_file" 1534 1535 # In verbose mode, append to the log file *and* show on 1536 # the standard output; in quiet mode only write to the log. 1537 if test -z "$at_verbose"; then 1538 at_tee_pipe='tee -a "$at_group_log"' 1539 else 1540 at_tee_pipe='cat >> "$at_group_log"' 1541 fi 1542} 1543 1544# at_fn_group_banner ORDINAL LINE DESC PAD [BANNER] 1545# ------------------------------------------------- 1546# Declare the test group ORDINAL, located at LINE with group description DESC, 1547# and residing under BANNER. Use PAD to align the status column. 1548at_fn_group_banner () 1549{ 1550 at_setup_line="$2" 1551 test -n "$5" && at_fn_banner $5 1552 at_desc="$3" 1553 case $1 in 1554 [0-9]) at_desc_line=" $1: ";; 1555 [0-9][0-9]) at_desc_line=" $1: " ;; 1556 *) at_desc_line="$1: " ;; 1557 esac 1558 as_fn_append at_desc_line "$3$4" 1559 $at_quiet $as_echo_n "$at_desc_line" 1560 echo "# -*- compilation -*-" >> "$at_group_log" 1561} 1562 1563# at_fn_group_postprocess 1564# ----------------------- 1565# Perform cleanup after running a test group. 1566at_fn_group_postprocess () 1567{ 1568 # Be sure to come back to the suite directory, in particular 1569 # since below we might `rm' the group directory we are in currently. 1570 cd "$at_suite_dir" 1571 1572 if test ! -f "$at_check_line_file"; then 1573 sed "s/^ */$as_me: WARNING: /" <<_ATEOF 1574 A failure happened in a test group before any test could be 1575 run. This means that test suite is improperly designed. Please 1576 report this failure to <bug-dico@gnu.org>. 1577_ATEOF 1578 $as_echo "$at_setup_line" >"$at_check_line_file" 1579 at_status=99 1580 fi 1581 $at_verbose $as_echo_n "$at_group. $at_setup_line: " 1582 $as_echo_n "$at_group. $at_setup_line: " >> "$at_group_log" 1583 case $at_xfail:$at_status in 1584 yes:0) 1585 at_msg="UNEXPECTED PASS" 1586 at_res=xpass 1587 at_errexit=$at_errexit_p 1588 at_color=$at_red 1589 ;; 1590 no:0) 1591 at_msg="ok" 1592 at_res=pass 1593 at_errexit=false 1594 at_color=$at_grn 1595 ;; 1596 *:77) 1597 at_msg='skipped ('`cat "$at_check_line_file"`')' 1598 at_res=skip 1599 at_errexit=false 1600 at_color=$at_blu 1601 ;; 1602 no:* | *:99) 1603 at_msg='FAILED ('`cat "$at_check_line_file"`')' 1604 at_res=fail 1605 at_errexit=$at_errexit_p 1606 at_color=$at_red 1607 ;; 1608 yes:*) 1609 at_msg='expected failure ('`cat "$at_check_line_file"`')' 1610 at_res=xfail 1611 at_errexit=false 1612 at_color=$at_lgn 1613 ;; 1614 esac 1615 echo "$at_res" > "$at_job_dir/$at_res" 1616 # In parallel mode, output the summary line only afterwards. 1617 if test $at_jobs -ne 1 && test -n "$at_verbose"; then 1618 $as_echo "$at_desc_line $at_color$at_msg$at_std" 1619 else 1620 # Make sure there is a separator even with long titles. 1621 $as_echo " $at_color$at_msg$at_std" 1622 fi 1623 at_log_msg="$at_group. $at_desc ($at_setup_line): $at_msg" 1624 case $at_status in 1625 0|77) 1626 # $at_times_file is only available if the group succeeded. 1627 # We're not including the group log, so the success message 1628 # is written in the global log separately. But we also 1629 # write to the group log in case they're using -d. 1630 if test -f "$at_times_file"; then 1631 at_log_msg="$at_log_msg ("`sed 1d "$at_times_file"`')' 1632 rm -f "$at_times_file" 1633 fi 1634 $as_echo "$at_log_msg" >> "$at_group_log" 1635 $as_echo "$at_log_msg" >&5 1636 1637 # Cleanup the group directory, unless the user wants the files 1638 # or the success was unexpected. 1639 if $at_debug_p || test $at_res = xpass; then 1640 at_fn_create_debugging_script 1641 if test $at_res = xpass && $at_errexit; then 1642 echo stop > "$at_stop_file" 1643 fi 1644 else 1645 if test -d "$at_group_dir"; then 1646 find "$at_group_dir" -type d ! -perm -700 -exec chmod u+rwx \{\} \; 1647 rm -fr "$at_group_dir" 1648 fi 1649 rm -f "$at_test_source" 1650 fi 1651 ;; 1652 *) 1653 # Upon failure, include the log into the testsuite's global 1654 # log. The failure message is written in the group log. It 1655 # is later included in the global log. 1656 $as_echo "$at_log_msg" >> "$at_group_log" 1657 1658 # Upon failure, keep the group directory for autopsy, and create 1659 # the debugging script. With -e, do not start any further tests. 1660 at_fn_create_debugging_script 1661 if $at_errexit; then 1662 echo stop > "$at_stop_file" 1663 fi 1664 ;; 1665 esac 1666} 1667 1668 1669## ------------ ## 1670## Driver loop. ## 1671## ------------ ## 1672 1673 1674if (set -m && set +m && set +b) >/dev/null 2>&1; then 1675 set +b 1676 at_job_control_on='set -m' at_job_control_off='set +m' at_job_group=- 1677else 1678 at_job_control_on=: at_job_control_off=: at_job_group= 1679fi 1680 1681for at_signal in 1 2 15; do 1682 trap 'set +x; set +e 1683 $at_job_control_off 1684 at_signal='"$at_signal"' 1685 echo stop > "$at_stop_file" 1686 trap "" $at_signal 1687 at_pgids= 1688 for at_pgid in `jobs -p 2>/dev/null`; do 1689 at_pgids="$at_pgids $at_job_group$at_pgid" 1690 done 1691 test -z "$at_pgids" || kill -$at_signal $at_pgids 2>/dev/null 1692 wait 1693 if test "$at_jobs" -eq 1 || test -z "$at_verbose"; then 1694 echo >&2 1695 fi 1696 at_signame=`kill -l $at_signal 2>&1 || echo $at_signal` 1697 set x $at_signame 1698 test 0 -gt 2 && at_signame=$at_signal 1699 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: caught signal $at_signame, bailing out" >&5 1700$as_echo "$as_me: WARNING: caught signal $at_signame, bailing out" >&2;} 1701 as_fn_arith 128 + $at_signal && exit_status=$as_val 1702 as_fn_exit $exit_status' $at_signal 1703done 1704 1705rm -f "$at_stop_file" 1706at_first=: 1707 1708if test $at_jobs -ne 1 && 1709 rm -f "$at_job_fifo" && 1710 test -n "$at_job_group" && 1711 ( mkfifo "$at_job_fifo" && trap 'exit 1' PIPE STOP TSTP ) 2>/dev/null 1712then 1713 # FIFO job dispatcher. 1714 1715 trap 'at_pids= 1716 for at_pid in `jobs -p`; do 1717 at_pids="$at_pids $at_job_group$at_pid" 1718 done 1719 if test -n "$at_pids"; then 1720 at_sig=TSTP 1721 test "${TMOUT+set}" = set && at_sig=STOP 1722 kill -$at_sig $at_pids 2>/dev/null 1723 fi 1724 kill -STOP $$ 1725 test -z "$at_pids" || kill -CONT $at_pids 2>/dev/null' TSTP 1726 1727 echo 1728 # Turn jobs into a list of numbers, starting from 1. 1729 at_joblist=`$as_echo "$at_groups" | sed -n 1,${at_jobs}p` 1730 1731 set X $at_joblist 1732 shift 1733 for at_group in $at_groups; do 1734 $at_job_control_on 2>/dev/null 1735 ( 1736 # Start one test group. 1737 $at_job_control_off 1738 if $at_first; then 1739 exec 7>"$at_job_fifo" 1740 else 1741 exec 6<&- 1742 fi 1743 trap 'set +x; set +e 1744 trap "" PIPE 1745 echo stop > "$at_stop_file" 1746 echo >&7 1747 as_fn_exit 141' PIPE 1748 at_fn_group_prepare 1749 if cd "$at_group_dir" && 1750 at_fn_test $at_group && 1751 . "$at_test_source" 1752 then :; else 1753 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unable to parse test group: $at_group" >&5 1754$as_echo "$as_me: WARNING: unable to parse test group: $at_group" >&2;} 1755 at_failed=: 1756 fi 1757 at_fn_group_postprocess 1758 echo >&7 1759 ) & 1760 $at_job_control_off 1761 if $at_first; then 1762 at_first=false 1763 exec 6<"$at_job_fifo" 7>"$at_job_fifo" 1764 fi 1765 shift # Consume one token. 1766 if test $# -gt 0; then :; else 1767 read at_token <&6 || break 1768 set x $* 1769 fi 1770 test -f "$at_stop_file" && break 1771 done 1772 exec 7>&- 1773 # Read back the remaining ($at_jobs - 1) tokens. 1774 set X $at_joblist 1775 shift 1776 if test $# -gt 0; then 1777 shift 1778 for at_job 1779 do 1780 read at_token 1781 done <&6 1782 fi 1783 exec 6<&- 1784 wait 1785else 1786 # Run serially, avoid forks and other potential surprises. 1787 for at_group in $at_groups; do 1788 at_fn_group_prepare 1789 if cd "$at_group_dir" && 1790 at_fn_test $at_group && 1791 . "$at_test_source"; then :; else 1792 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unable to parse test group: $at_group" >&5 1793$as_echo "$as_me: WARNING: unable to parse test group: $at_group" >&2;} 1794 at_failed=: 1795 fi 1796 at_fn_group_postprocess 1797 test -f "$at_stop_file" && break 1798 at_first=false 1799 done 1800fi 1801 1802# Wrap up the test suite with summary statistics. 1803cd "$at_helper_dir" 1804 1805# Use ?..???? when the list must remain sorted, the faster * otherwise. 1806at_pass_list=`for f in */pass; do echo $f; done | sed '/\*/d; s,/pass,,'` 1807at_skip_list=`for f in */skip; do echo $f; done | sed '/\*/d; s,/skip,,'` 1808at_xfail_list=`for f in */xfail; do echo $f; done | sed '/\*/d; s,/xfail,,'` 1809at_xpass_list=`for f in ?/xpass ??/xpass ???/xpass ????/xpass; do 1810 echo $f; done | sed '/?/d; s,/xpass,,'` 1811at_fail_list=`for f in ?/fail ??/fail ???/fail ????/fail; do 1812 echo $f; done | sed '/?/d; s,/fail,,'` 1813 1814set X $at_pass_list $at_xpass_list $at_xfail_list $at_fail_list $at_skip_list 1815shift; at_group_count=$# 1816set X $at_xpass_list; shift; at_xpass_count=$#; at_xpass_list=$* 1817set X $at_xfail_list; shift; at_xfail_count=$# 1818set X $at_fail_list; shift; at_fail_count=$#; at_fail_list=$* 1819set X $at_skip_list; shift; at_skip_count=$# 1820 1821as_fn_arith $at_group_count - $at_skip_count && at_run_count=$as_val 1822as_fn_arith $at_xpass_count + $at_fail_count && at_unexpected_count=$as_val 1823as_fn_arith $at_xfail_count + $at_fail_count && at_total_fail_count=$as_val 1824 1825# Back to the top directory. 1826cd "$at_dir" 1827rm -rf "$at_helper_dir" 1828 1829# Compute the duration of the suite. 1830at_stop_date=`date` 1831at_stop_time=`date +%s 2>/dev/null` 1832$as_echo "$as_me: ending at: $at_stop_date" >&5 1833case $at_start_time,$at_stop_time in 1834 [0-9]*,[0-9]*) 1835 as_fn_arith $at_stop_time - $at_start_time && at_duration_s=$as_val 1836 as_fn_arith $at_duration_s / 60 && at_duration_m=$as_val 1837 as_fn_arith $at_duration_m / 60 && at_duration_h=$as_val 1838 as_fn_arith $at_duration_s % 60 && at_duration_s=$as_val 1839 as_fn_arith $at_duration_m % 60 && at_duration_m=$as_val 1840 at_duration="${at_duration_h}h ${at_duration_m}m ${at_duration_s}s" 1841 $as_echo "$as_me: test suite duration: $at_duration" >&5 1842 ;; 1843esac 1844 1845echo 1846$as_echo "## ------------- ## 1847## Test results. ## 1848## ------------- ##" 1849echo 1850{ 1851 echo 1852 $as_echo "## ------------- ## 1853## Test results. ## 1854## ------------- ##" 1855 echo 1856} >&5 1857 1858if test $at_run_count = 1; then 1859 at_result="1 test" 1860 at_were=was 1861else 1862 at_result="$at_run_count tests" 1863 at_were=were 1864fi 1865if $at_errexit_p && test $at_unexpected_count != 0; then 1866 if test $at_xpass_count = 1; then 1867 at_result="$at_result $at_were run, one passed" 1868 else 1869 at_result="$at_result $at_were run, one failed" 1870 fi 1871 at_result="$at_result unexpectedly and inhibited subsequent tests." 1872 at_color=$at_red 1873else 1874 # Don't you just love exponential explosion of the number of cases? 1875 at_color=$at_red 1876 case $at_xpass_count:$at_fail_count:$at_xfail_count in 1877 # So far, so good. 1878 0:0:0) at_result="$at_result $at_were successful." at_color=$at_grn ;; 1879 0:0:*) at_result="$at_result behaved as expected." at_color=$at_lgn ;; 1880 1881 # Some unexpected failures 1882 0:*:0) at_result="$at_result $at_were run, 1883$at_fail_count failed unexpectedly." ;; 1884 1885 # Some failures, both expected and unexpected 1886 0:*:1) at_result="$at_result $at_were run, 1887$at_total_fail_count failed ($at_xfail_count expected failure)." ;; 1888 0:*:*) at_result="$at_result $at_were run, 1889$at_total_fail_count failed ($at_xfail_count expected failures)." ;; 1890 1891 # No unexpected failures, but some xpasses 1892 *:0:*) at_result="$at_result $at_were run, 1893$at_xpass_count passed unexpectedly." ;; 1894 1895 # No expected failures, but failures and xpasses 1896 *:1:0) at_result="$at_result $at_were run, 1897$at_unexpected_count did not behave as expected ($at_fail_count unexpected failure)." ;; 1898 *:*:0) at_result="$at_result $at_were run, 1899$at_unexpected_count did not behave as expected ($at_fail_count unexpected failures)." ;; 1900 1901 # All of them. 1902 *:*:1) at_result="$at_result $at_were run, 1903$at_xpass_count passed unexpectedly, 1904$at_total_fail_count failed ($at_xfail_count expected failure)." ;; 1905 *:*:*) at_result="$at_result $at_were run, 1906$at_xpass_count passed unexpectedly, 1907$at_total_fail_count failed ($at_xfail_count expected failures)." ;; 1908 esac 1909 1910 if test $at_skip_count = 0 && test $at_run_count -gt 1; then 1911 at_result="All $at_result" 1912 fi 1913fi 1914 1915# Now put skips in the mix. 1916case $at_skip_count in 1917 0) ;; 1918 1) at_result="$at_result 19191 test was skipped." ;; 1920 *) at_result="$at_result 1921$at_skip_count tests were skipped." ;; 1922esac 1923 1924if test $at_unexpected_count = 0; then 1925 echo "$at_color$at_result$at_std" 1926 echo "$at_result" >&5 1927else 1928 echo "${at_color}ERROR: $at_result$at_std" >&2 1929 echo "ERROR: $at_result" >&5 1930 { 1931 echo 1932 $as_echo "## ------------------------ ## 1933## Summary of the failures. ## 1934## ------------------------ ##" 1935 1936 # Summary of failed and skipped tests. 1937 if test $at_fail_count != 0; then 1938 echo "Failed tests:" 1939 $SHELL "$at_myself" $at_fail_list --list 1940 echo 1941 fi 1942 if test $at_skip_count != 0; then 1943 echo "Skipped tests:" 1944 $SHELL "$at_myself" $at_skip_list --list 1945 echo 1946 fi 1947 if test $at_xpass_count != 0; then 1948 echo "Unexpected passes:" 1949 $SHELL "$at_myself" $at_xpass_list --list 1950 echo 1951 fi 1952 if test $at_fail_count != 0; then 1953 $as_echo "## ---------------------- ## 1954## Detailed failed tests. ## 1955## ---------------------- ##" 1956 echo 1957 for at_group in $at_fail_list 1958 do 1959 at_group_normalized=$at_group 1960 1961 eval 'while :; do 1962 case $at_group_normalized in #( 1963 '"$at_format"'*) break;; 1964 esac 1965 at_group_normalized=0$at_group_normalized 1966 done' 1967 1968 cat "$at_suite_dir/$at_group_normalized/$as_me.log" 1969 echo 1970 done 1971 echo 1972 fi 1973 if test -n "$at_top_srcdir"; then 1974 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 1975## ${at_top_build_prefix}config.log ## 1976_ASBOX 1977 sed 's/^/| /' ${at_top_build_prefix}config.log 1978 echo 1979 fi 1980 } >&5 1981 1982 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 1983## $as_me.log was created. ## 1984_ASBOX 1985 1986 echo 1987 if $at_debug_p; then 1988 at_msg='per-test log files' 1989 else 1990 at_msg="\`${at_testdir+${at_testdir}/}$as_me.log'" 1991 fi 1992 $as_echo "Please send $at_msg and all information you think might help: 1993 1994 To: <bug-dico@gnu.org> 1995 Subject: [GNU dico 2.10] $as_me: $at_fail_list${at_fail_list:+ failed${at_xpass_list:+, }}$at_xpass_list${at_xpass_list:+ passed unexpectedly} 1996 1997You may investigate any problem if you feel able to do so, in which 1998case the test suite provides a good starting point. Its output may 1999be found below \`${at_testdir+${at_testdir}/}$as_me.dir'. 2000" 2001 exit 1 2002fi 2003 2004exit 0 2005 2006## ------------- ## 2007## Actual tests. ## 2008## ------------- ## 2009#AT_START_1 2010at_fn_group_banner 1 'exact.at:17' \ 2011 "exact" " " 1 2012at_xfail=no 2013( 2014 $as_echo "1. $at_setup_line: testing $at_desc ..." 2015 $at_traceon 2016 2017 2018 2019cat >input <<'_ATEOF' 2020match dev exact bore 2021quit 2022_ATEOF 2023 2024{ set +x 2025$as_echo "$at_srcdir/exact.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2026at_fn_check_prepare_notrace 'a shell pipeline' "exact.at:19" 2027( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2028) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2029at_status=$? at_failed=false 2030$at_check_filter 2031at_fn_diff_devnull "$at_stderr" || at_failed=: 2032echo >>"$at_stdout"; $as_echo "220 2033152 1 matches found: list follows 2034dev \"BORE\" 2035. 2036250 2037221 2038" | \ 2039 $at_diff - "$at_stdout" || at_failed=: 2040at_fn_check_status 0 $at_status "$at_srcdir/exact.at:19" 2041$at_failed && at_fn_log_failure 2042$at_traceon; } 2043 2044 set +x 2045 $at_times_p && times >"$at_times_file" 2046) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2047read at_status <"$at_status_file" 2048#AT_STOP_1 2049#AT_START_2 2050at_fn_group_banner 2 'prefix.at:17' \ 2051 "prefix" " " 1 2052at_xfail=no 2053( 2054 $as_echo "2. $at_setup_line: testing $at_desc ..." 2055 $at_traceon 2056 2057 2058 2059cat >input <<'_ATEOF' 2060match dev prefix re 2061quit 2062_ATEOF 2063 2064{ set +x 2065$as_echo "$at_srcdir/prefix.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2066at_fn_check_prepare_notrace 'a shell pipeline' "prefix.at:19" 2067( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2068) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2069at_status=$? at_failed=false 2070$at_check_filter 2071at_fn_diff_devnull "$at_stderr" || at_failed=: 2072echo >>"$at_stdout"; $as_echo "220 2073152 58 matches found: list follows 2074dev \"REACH\" 2075dev \"READING\" 2076dev \"REALISM\" 2077dev \"REALITY\" 2078dev \"REALLY\" 2079dev \"REAR\" 2080dev \"REASON\" 2081dev \"REASON\" 2082dev \"REASONABLE\" 2083dev \"REBEL\" 2084dev \"RECOLLECT\" 2085dev \"RECONCILIATION\" 2086dev \"RECONSIDER\" 2087dev \"RECOUNT\" 2088dev \"RECREATION\" 2089dev \"RECRUIT\" 2090dev \"RECTOR\" 2091dev \"RED-SKIN\" 2092dev \"REDEMPTION\" 2093dev \"REDRESS\" 2094dev \"REDUNDANT\" 2095dev \"REFERENDUM\" 2096dev \"REFLECTION\" 2097dev \"REFORM\" 2098dev \"REFUGE\" 2099dev \"REFUSAL\" 2100dev \"REGALIA\" 2101dev \"RELIGION\" 2102dev \"RELIQUARY\" 2103dev \"RENOWN\" 2104dev \"REPARATION\" 2105dev \"REPARTEE\" 2106dev \"REPENTANCE\" 2107dev \"REPLICA\" 2108dev \"REPORTER\" 2109dev \"REPOSE\" 2110dev \"REPRESENTATIVE\" 2111dev \"REPROBATION\" 2112dev \"REPUBLIC\" 2113dev \"REQUIEM\" 2114dev \"RESIDENT\" 2115dev \"RESIGN\" 2116dev \"RESOLUTE\" 2117dev \"RESPECTABILITY\" 2118dev \"RESPIRATOR\" 2119dev \"RESPITE\" 2120dev \"RESPLENDENT\" 2121dev \"RESPOND\" 2122dev \"RESPONSIBILITY\" 2123dev \"RESTITUTIONS\" 2124dev \"RESTITUTOR\" 2125dev \"RETALIATION\" 2126dev \"RETRIBUTION\" 2127dev \"REVEILLE\" 2128dev \"REVELATION\" 2129dev \"REVERENCE\" 2130dev \"REVIEW\" 2131dev \"REVOLUTION\" 2132. 2133250 2134221 2135" | \ 2136 $at_diff - "$at_stdout" || at_failed=: 2137at_fn_check_status 0 $at_status "$at_srcdir/prefix.at:19" 2138$at_failed && at_fn_log_failure 2139$at_traceon; } 2140 2141 set +x 2142 $at_times_p && times >"$at_times_file" 2143) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2144read at_status <"$at_status_file" 2145#AT_STOP_2 2146#AT_START_3 2147at_fn_group_banner 3 'suffix.at:17' \ 2148 "suffix" " " 1 2149at_xfail=no 2150( 2151 $as_echo "3. $at_setup_line: testing $at_desc ..." 2152 $at_traceon 2153 2154 2155 2156cat >input <<'_ATEOF' 2157match dev suffix tion 2158quit 2159_ATEOF 2160 2161{ set +x 2162$as_echo "$at_srcdir/suffix.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2163at_fn_check_prepare_notrace 'a shell pipeline' "suffix.at:19" 2164( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2165) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2166at_status=$? at_failed=false 2167$at_check_filter 2168at_fn_diff_devnull "$at_stderr" || at_failed=: 2169echo >>"$at_stdout"; $as_echo "220 2170152 59 matches found: list follows 2171dev \"ABDICATION\" 2172dev \"ADMINISTRATION\" 2173dev \"ADMIRATION\" 2174dev \"ADMONITION\" 2175dev \"AFFLICTION\" 2176dev \"AMBITION\" 2177dev \"COMMENDATION\" 2178dev \"CONGRATULATION\" 2179dev \"CONSOLATION\" 2180dev \"CONVERSATION\" 2181dev \"CORONATION\" 2182dev \"CORPORATION\" 2183dev \"DEGRADATION\" 2184dev \"DELEGATION\" 2185dev \"DELIBERATION\" 2186dev \"DIGESTION\" 2187dev \"DIVINATION\" 2188dev \"EDUCATION\" 2189dev \"EJECTION\" 2190dev \"EMANCIPATION\" 2191dev \"EMOTION\" 2192dev \"ERUDITION\" 2193dev \"EXCEPTION\" 2194dev \"EXCOMMUNICATION\" 2195dev \"EXPOSTULATION\" 2196dev \"EXTINCTION\" 2197dev \"FOREORDINATION\" 2198dev \"GRAVITATION\" 2199dev \"IMAGINATION\" 2200dev \"IMPOSITION\" 2201dev \"INDIGESTION\" 2202dev \"INDISCRETION\" 2203dev \"INSCRIPTION\" 2204dev \"INSURRECTION\" 2205dev \"INTENTION\" 2206dev \"INTRODUCTION\" 2207dev \"LITIGATION\" 2208dev \"MACHINATION\" 2209dev \"OPPOSITION\" 2210dev \"OVATION\" 2211dev \"PERFECTION\" 2212dev \"PERORATION\" 2213dev \"PREDESTINATION\" 2214dev \"PREDILECTION\" 2215dev \"PRESCRIPTION\" 2216dev \"QUOTATION\" 2217dev \"RECONCILIATION\" 2218dev \"RECREATION\" 2219dev \"REDEMPTION\" 2220dev \"REFLECTION\" 2221dev \"REPARATION\" 2222dev \"REPROBATION\" 2223dev \"RETALIATION\" 2224dev \"RETRIBUTION\" 2225dev \"REVELATION\" 2226dev \"REVOLUTION\" 2227dev \"SCARIFICATION\" 2228dev \"UNCTION\" 2229dev \"VITUPERATION\" 2230. 2231250 2232221 2233" | \ 2234 $at_diff - "$at_stdout" || at_failed=: 2235at_fn_check_status 0 $at_status "$at_srcdir/suffix.at:19" 2236$at_failed && at_fn_log_failure 2237$at_traceon; } 2238 2239 set +x 2240 $at_times_p && times >"$at_times_file" 2241) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2242read at_status <"$at_status_file" 2243#AT_STOP_3 2244#AT_START_4 2245at_fn_group_banner 4 'lev.at:17' \ 2246 "Levenshtein" " " 1 2247at_xfail=no 2248( 2249 $as_echo "4. $at_setup_line: testing $at_desc ..." 2250 $at_traceon 2251 2252 2253 2254cat >input <<'_ATEOF' 2255match dev lev til 2256quit 2257_ATEOF 2258 2259{ set +x 2260$as_echo "$at_srcdir/lev.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2261at_fn_check_prepare_notrace 'a shell pipeline' "lev.at:19" 2262( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2263) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2264at_status=$? at_failed=false 2265$at_check_filter 2266at_fn_diff_devnull "$at_stderr" || at_failed=: 2267echo >>"$at_stdout"; $as_echo "220 2268152 1 matches found: list follows 2269dev \"TAIL\" 2270. 2271250 2272221 2273" | \ 2274 $at_diff - "$at_stdout" || at_failed=: 2275at_fn_check_status 0 $at_status "$at_srcdir/lev.at:19" 2276$at_failed && at_fn_log_failure 2277$at_traceon; } 2278 2279 set +x 2280 $at_times_p && times >"$at_times_file" 2281) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2282read at_status <"$at_status_file" 2283#AT_STOP_4 2284#AT_START_5 2285at_fn_group_banner 5 'nlev.at:17' \ 2286 "Levenshtein normalized" " " 1 2287at_xfail=no 2288( 2289 $as_echo "5. $at_setup_line: testing $at_desc ..." 2290 $at_traceon 2291 2292 2293 2294cat >input <<'_ATEOF' 2295match dev nlev "aprl fool" 2296quit 2297_ATEOF 2298 2299{ set +x 2300$as_echo "$at_srcdir/nlev.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2301at_fn_check_prepare_notrace 'a shell pipeline' "nlev.at:19" 2302( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2303) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2304at_status=$? at_failed=false 2305$at_check_filter 2306at_fn_diff_devnull "$at_stderr" || at_failed=: 2307echo >>"$at_stdout"; $as_echo "220 2308152 1 matches found: list follows 2309dev \"APRIL FOOL\" 2310. 2311250 2312221 2313" | \ 2314 $at_diff - "$at_stdout" || at_failed=: 2315at_fn_check_status 0 $at_status "$at_srcdir/nlev.at:19" 2316$at_failed && at_fn_log_failure 2317$at_traceon; } 2318 2319 set +x 2320 $at_times_p && times >"$at_times_file" 2321) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2322read at_status <"$at_status_file" 2323#AT_STOP_5 2324#AT_START_6 2325at_fn_group_banner 6 'dlev.at:17' \ 2326 "Damerau-Levenshtein" " " 1 2327at_xfail=no 2328( 2329 $as_echo "6. $at_setup_line: testing $at_desc ..." 2330 $at_traceon 2331 2332 2333 2334cat >input <<'_ATEOF' 2335match dev dlev cpaital 2336quit 2337_ATEOF 2338 2339{ set +x 2340$as_echo "$at_srcdir/dlev.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2341at_fn_check_prepare_notrace 'a shell pipeline' "dlev.at:19" 2342( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2343) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2344at_status=$? at_failed=false 2345$at_check_filter 2346at_fn_diff_devnull "$at_stderr" || at_failed=: 2347echo >>"$at_stdout"; $as_echo "220 2348152 1 matches found: list follows 2349dev \"CAPITAL\" 2350. 2351250 2352221 2353" | \ 2354 $at_diff - "$at_stdout" || at_failed=: 2355at_fn_check_status 0 $at_status "$at_srcdir/dlev.at:19" 2356$at_failed && at_fn_log_failure 2357$at_traceon; } 2358 2359 set +x 2360 $at_times_p && times >"$at_times_file" 2361) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2362read at_status <"$at_status_file" 2363#AT_STOP_6 2364#AT_START_7 2365at_fn_group_banner 7 'dnlev.at:17' \ 2366 "Damerau-Levenshtein normalized" " " 1 2367at_xfail=no 2368( 2369 $as_echo "7. $at_setup_line: testing $at_desc ..." 2370 $at_traceon 2371 2372 2373 2374cat >input <<'_ATEOF' 2375match dev ndlev "arpil fool" 2376quit 2377_ATEOF 2378 2379{ set +x 2380$as_echo "$at_srcdir/dnlev.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2381at_fn_check_prepare_notrace 'a shell pipeline' "dnlev.at:19" 2382( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2383) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2384at_status=$? at_failed=false 2385$at_check_filter 2386at_fn_diff_devnull "$at_stderr" || at_failed=: 2387echo >>"$at_stdout"; $as_echo "220 2388152 1 matches found: list follows 2389dev \"APRIL FOOL\" 2390. 2391250 2392221 2393" | \ 2394 $at_diff - "$at_stdout" || at_failed=: 2395at_fn_check_status 0 $at_status "$at_srcdir/dnlev.at:19" 2396$at_failed && at_fn_log_failure 2397$at_traceon; } 2398 2399 set +x 2400 $at_times_p && times >"$at_times_file" 2401) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2402read at_status <"$at_status_file" 2403#AT_STOP_7 2404#AT_START_8 2405at_fn_group_banner 8 'soundex.at:17' \ 2406 "SOUNDEX" " " 1 2407at_xfail=no 2408( 2409 $as_echo "8. $at_setup_line: testing $at_desc ..." 2410 $at_traceon 2411 2412 2413 2414cat >input <<'_ATEOF' 2415match dev soundex prejudge 2416quit 2417_ATEOF 2418 2419{ set +x 2420$as_echo "$at_srcdir/soundex.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2421at_fn_check_prepare_notrace 'a shell pipeline' "soundex.at:19" 2422( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2423) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2424at_status=$? at_failed=false 2425$at_check_filter 2426at_fn_diff_devnull "$at_stderr" || at_failed=: 2427echo >>"$at_stdout"; $as_echo "220 2428152 7 matches found: list follows 2429dev \"PRECEDENT\" 2430dev \"PRECEDENT\" 2431dev \"PREHISTORIC\" 2432dev \"PREJUDICE\" 2433dev \"PRESIDE\" 2434dev \"PRESIDENCY\" 2435dev \"PRESIDENT\" 2436. 2437250 2438221 2439" | \ 2440 $at_diff - "$at_stdout" || at_failed=: 2441at_fn_check_status 0 $at_status "$at_srcdir/soundex.at:19" 2442$at_failed && at_fn_log_failure 2443$at_traceon; } 2444 2445 set +x 2446 $at_times_p && times >"$at_times_file" 2447) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2448read at_status <"$at_status_file" 2449#AT_STOP_8 2450#AT_START_9 2451at_fn_group_banner 9 'regexp.at:17' \ 2452 "Basic regular expressions" " " 1 2453at_xfail=no 2454( 2455 $as_echo "9. $at_setup_line: testing $at_desc ..." 2456 $at_traceon 2457 2458 2459 2460cat >input <<'_ATEOF' 2461match dev regexp "ab.*on" 2462quit 2463_ATEOF 2464 2465{ set +x 2466$as_echo "$at_srcdir/regexp.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2467at_fn_check_prepare_notrace 'a shell pipeline' "regexp.at:19" 2468( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2469) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2470at_status=$? at_failed=false 2471$at_check_filter 2472at_fn_diff_devnull "$at_stderr" || at_failed=: 2473echo >>"$at_stdout"; $as_echo "220 2474152 2 matches found: list follows 2475dev \"ABDICATION\" 2476dev \"ABSCOND\" 2477. 2478250 2479221 2480" | \ 2481 $at_diff - "$at_stdout" || at_failed=: 2482at_fn_check_status 0 $at_status "$at_srcdir/regexp.at:19" 2483$at_failed && at_fn_log_failure 2484$at_traceon; } 2485 2486 set +x 2487 $at_times_p && times >"$at_times_file" 2488) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2489read at_status <"$at_status_file" 2490#AT_STOP_9 2491#AT_START_10 2492at_fn_group_banner 10 're.at:17' \ 2493 "Extended regular expressions" " " 1 2494at_xfail=no 2495( 2496 $as_echo "10. $at_setup_line: testing $at_desc ..." 2497 $at_traceon 2498 2499 2500 2501cat >input <<'_ATEOF' 2502match dev re "^a.{4,6}n$" 2503quit 2504_ATEOF 2505 2506{ set +x 2507$as_echo "$at_srcdir/re.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2508at_fn_check_prepare_notrace 'a shell pipeline' "re.at:19" 2509( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2510) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2511at_status=$? at_failed=false 2512$at_check_filter 2513at_fn_diff_devnull "$at_stderr" || at_failed=: 2514echo >>"$at_stdout"; $as_echo "220 2515152 4 matches found: list follows 2516dev \"ABDOMEN\" 2517dev \"AFRICAN\" 2518dev \"ALDERMAN\" 2519dev \"AMBITION\" 2520. 2521250 2522221 2523" | \ 2524 $at_diff - "$at_stdout" || at_failed=: 2525at_fn_check_status 0 $at_status "$at_srcdir/re.at:19" 2526$at_failed && at_fn_log_failure 2527$at_traceon; } 2528 2529 set +x 2530 $at_times_p && times >"$at_times_file" 2531) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2532read at_status <"$at_status_file" 2533#AT_STOP_10 2534#AT_START_11 2535at_fn_group_banner 11 'define.at:17' \ 2536 "define" " " 2 2537at_xfail=no 2538( 2539 $as_echo "11. $at_setup_line: testing $at_desc ..." 2540 $at_traceon 2541 2542 2543 2544cat >input <<'_ATEOF' 2545define dev bore 2546quit 2547_ATEOF 2548 2549{ set +x 2550$as_echo "$at_srcdir/define.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2551at_fn_check_prepare_notrace 'a shell pipeline' "define.at:19" 2552( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2553) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2554at_status=$? at_failed=false 2555$at_check_filter 2556at_fn_diff_devnull "$at_stderr" || at_failed=: 2557echo >>"$at_stdout"; $as_echo "220 2558150 1 definitions found: list follows 2559151 \"bore\" dev \"THE DEVIL'S DICTIONARY ((C)1911 Released April 15 1993)\" 2560BORE, n. A person who talks when you wish him to listen. 2561 2562 2563 2564. 2565250 2566221 2567" | \ 2568 $at_diff - "$at_stdout" || at_failed=: 2569at_fn_check_status 0 $at_status "$at_srcdir/define.at:19" 2570$at_failed && at_fn_log_failure 2571$at_traceon; } 2572 2573 set +x 2574 $at_times_p && times >"$at_times_file" 2575) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2576read at_status <"$at_status_file" 2577#AT_STOP_11 2578#AT_START_12 2579at_fn_group_banner 12 'mime.at:17' \ 2580 "option mime" " " 2 2581at_xfail=no 2582( 2583 $as_echo "12. $at_setup_line: testing $at_desc ..." 2584 $at_traceon 2585 2586 2587 2588cat >input <<'_ATEOF' 2589option mime 2590define dev bore 2591quit 2592_ATEOF 2593 2594{ set +x 2595$as_echo "$at_srcdir/mime.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2596at_fn_check_prepare_notrace 'a shell pipeline' "mime.at:19" 2597( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2598) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2599at_status=$? at_failed=false 2600$at_check_filter 2601at_fn_diff_devnull "$at_stderr" || at_failed=: 2602echo >>"$at_stdout"; $as_echo "220 2603250 2604150 1 definitions found: list follows 2605151 \"bore\" dev \"THE DEVIL'S DICTIONARY ((C)1911 Released April 15 1993)\" 2606Content-Type: text/plain; charset=US-ASCII 2607Content-Transfer-Encoding: 8bit 2608 2609BORE, n. A person who talks when you wish him to listen. 2610 2611 2612 2613. 2614250 2615221 2616" | \ 2617 $at_diff - "$at_stdout" || at_failed=: 2618at_fn_check_status 0 $at_status "$at_srcdir/mime.at:19" 2619$at_failed && at_fn_log_failure 2620$at_traceon; } 2621 2622 set +x 2623 $at_times_p && times >"$at_times_file" 2624) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2625read at_status <"$at_status_file" 2626#AT_STOP_12 2627#AT_START_13 2628at_fn_group_banner 13 'showdb.at:17' \ 2629 "show db" " " 3 2630at_xfail=no 2631( 2632 $as_echo "13. $at_setup_line: testing $at_desc ..." 2633 $at_traceon 2634 2635 2636 2637cat >input <<'_ATEOF' 2638show db 2639quit 2640_ATEOF 2641 2642{ set +x 2643$as_echo "$at_srcdir/showdb.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2644at_fn_check_prepare_notrace 'a shell pipeline' "showdb.at:19" 2645( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2646) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2647at_status=$? at_failed=false 2648$at_check_filter 2649at_fn_diff_devnull "$at_stderr" || at_failed=: 2650echo >>"$at_stdout"; $as_echo "220 2651110 1 databases present 2652dev \"THE DEVIL'S DICTIONARY ((C)1911 Released April 15 1993)\" 2653. 2654250 2655221 2656" | \ 2657 $at_diff - "$at_stdout" || at_failed=: 2658at_fn_check_status 0 $at_status "$at_srcdir/showdb.at:19" 2659$at_failed && at_fn_log_failure 2660$at_traceon; } 2661 2662 set +x 2663 $at_times_p && times >"$at_times_file" 2664) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2665read at_status <"$at_status_file" 2666#AT_STOP_13 2667#AT_START_14 2668at_fn_group_banner 14 'showinfo.at:17' \ 2669 "show info" " " 3 2670at_xfail=no 2671( 2672 $as_echo "14. $at_setup_line: testing $at_desc ..." 2673 $at_traceon 2674 2675 2676 2677cat >input <<'_ATEOF' 2678show info dev 2679quit 2680_ATEOF 2681 2682{ set +x 2683$as_echo "$at_srcdir/showinfo.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2684at_fn_check_prepare_notrace 'a shell pipeline' "showinfo.at:19" 2685( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2686) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2687at_status=$? at_failed=false 2688$at_check_filter 2689at_fn_diff_devnull "$at_stderr" || at_failed=: 2690echo >>"$at_stdout"; $as_echo "220 2691112 information for dev 2692This file was converted from the original database on: 2693Sun May 18 12:45:30 EEST 2008 2694 2695The original data is available from: 2696 http://wiretap.area.com/Gopher/Library/Classic/devils.txt 2697 2698The original data was distributed with the notice shown below. No 2699additional restrictions are claimed. Please redistribute this 2700changed version under the same conditions and restriction that 2701apply to the original version. 2702 2703 2704 2705 The Internet Wiretap 1st Online Edition of 2706 2707 2708 THE DEVIL'S DICTIONARY 2709 2710 by 2711 2712 AMBROSE BIERCE 2713 2714 2715 Copyright 1911 by Albert and Charles Boni, Inc. 2716 A Public Domain Text, Copyright Expired 2717 2718 Released April 15 1993 2719 2720 Entered by Aloysius of &tSftDotIotE 2721 aloysius@west.darkside.com 2722 2723 2724 2725 PREFACE 2726 2727 _The Devil's Dictionary_ was begun in a weekly paper in 1881, and was 2728 continued in a desultory way at long intervals until 1906. In that 2729 year a large part of it was published in covers with the title _The 2730 Cynic's Word Book_, a name which the author had not the power to 2731 reject or happiness to approve. To quote the publishers of the 2732 present work: 2733 \"This more reverent title had previously been forced upon him by 2734 the religious scruples of the last newspaper in which a part of the 2735 work had appeared, with the natural consequence that when it came out 2736 in covers the country already had been flooded by its imitators with a 2737 score of 'cynic' books -- _The Cynic's This_, _The Cynic's That_, and 2738 _The Cynic's t'Other_. Most of these books were merely stupid, though 2739 some of them added the distinction of silliness. Among them, they 2740 brought the word 'cynic' into disfavor so deep that any book bearing 2741 it was discredited in advance of publication.\" 2742 Meantime, too, some of the enterprising humorists of the country 2743 had helped themselves to such parts of the work as served their needs, 2744 and many of its definitions, anecdotes, phrases and so forth, had 2745 become more or less current in popular speech. This explanation is 2746 made, not with any pride of priority in trifles, but in simple denial 2747 of possible charges of plagiarism, which is no trifle. In merely 2748 resuming his own the author hopes to be held guiltless by those to 2749 whom the work is addressed -- enlightened souls who prefer dry wines 2750 to sweet, sense to sentiment, wit to humor and clean English to slang. 2751 A conspicuous, and it is hope not unpleasant, feature of the book 2752 is its abundant illustrative quotations from eminent poets, chief of 2753 whom is that learned and ingenius cleric, Father Gassalasca Jape, 2754 S.J., whose lines bear his initials. To Father Jape's kindly 2755 encouragement and assistance the author of the prose text is greatly 2756 indebted. 2757 A.B. 2758 2759 2760 2761. 2762250 2763221 2764" | \ 2765 $at_diff - "$at_stdout" || at_failed=: 2766at_fn_check_status 0 $at_status "$at_srcdir/showinfo.at:19" 2767$at_failed && at_fn_log_failure 2768$at_traceon; } 2769 2770 set +x 2771 $at_times_p && times >"$at_times_file" 2772) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2773read at_status <"$at_status_file" 2774#AT_STOP_14 2775#AT_START_15 2776at_fn_group_banner 15 'showlang.at:17' \ 2777 "show lang info" " " 3 2778at_xfail=no 2779( 2780 $as_echo "15. $at_setup_line: testing $at_desc ..." 2781 $at_traceon 2782 2783 2784 2785cat >input <<'_ATEOF' 2786show lang info dev 2787quit 2788_ATEOF 2789 2790{ set +x 2791$as_echo "$at_srcdir/showlang.at:19: dicod --config \$abs_builddir/dicod.conf --stderr -i < input | tr -d '\\r' | sed 's/^\\(2[25][0-9]\\) .*/\\1/;s/ *\$//' " 2792at_fn_check_prepare_notrace 'a shell pipeline' "showlang.at:19" 2793( $at_check_trace; dicod --config $abs_builddir/dicod.conf --stderr -i < input | tr -d '\r' | sed 's/^\(2[25][0-9]\) .*/\1/;s/ *$//' 2794) >>"$at_stdout" 2>>"$at_stderr" 5>&- 2795at_status=$? at_failed=false 2796$at_check_filter 2797at_fn_diff_devnull "$at_stderr" || at_failed=: 2798echo >>"$at_stdout"; $as_echo "220 2799280 en : en 2800221 2801" | \ 2802 $at_diff - "$at_stdout" || at_failed=: 2803at_fn_check_status 0 $at_status "$at_srcdir/showlang.at:19" 2804$at_failed && at_fn_log_failure 2805$at_traceon; } 2806 2807 set +x 2808 $at_times_p && times >"$at_times_file" 2809) 5>&1 2>&1 7>&- | eval $at_tee_pipe 2810read at_status <"$at_status_file" 2811#AT_STOP_15 2812