diff -Nru ruby1.8-1.8.7.22/array.c ruby1.8-1.8.7.72/array.c --- ruby1.8-1.8.7.22/array.c 2008-06-20 04:38:15.000000000 -0300 +++ ruby1.8-1.8.7.72/array.c 2008-07-01 03:14:29.000000000 -0300 @@ -3,7 +3,7 @@ array.c - $Author: shyouhei $ - $Date: 2008-06-20 16:38:15 +0900 (Fri, 20 Jun 2008) $ + $Date: 2008-07-01 15:14:29 +0900 (Tue, 01 Jul 2008) $ created at: Fri Aug 6 09:46:12 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -2416,10 +2416,13 @@ break; } rb_ary_modify(ary); - end = beg + len; - if (end < 0) { + if (len < 0) { + return ary; + } + if (beg >= ARY_MAX_SIZE || len > ARY_MAX_SIZE - beg) { rb_raise(rb_eArgError, "argument too big"); } + end = beg + len; if (end > RARRAY(ary)->len) { if (end >= RARRAY(ary)->aux.capa) { REALLOC_N(RARRAY(ary)->ptr, VALUE, end); diff -Nru ruby1.8-1.8.7.22/bignum.c ruby1.8-1.8.7.72/bignum.c --- ruby1.8-1.8.7.22/bignum.c 2008-04-01 08:33:27.000000000 -0300 +++ ruby1.8-1.8.7.72/bignum.c 2008-08-04 02:05:38.000000000 -0300 @@ -2,8 +2,8 @@ bignum.c - - $Author: matz $ - $Date: 2008-04-01 20:33:27 +0900 (Tue, 01 Apr 2008) $ + $Author: shyouhei $ + $Date: 2008-08-04 14:05:38 +0900 (Mon, 04 Aug 2008) $ created at: Fri Jun 10 00:48:55 JST 1994 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -11,6 +11,7 @@ **********************************************************************/ #include "ruby.h" +#include "rubysig.h" #include #include @@ -720,6 +721,7 @@ s = RSTRING(ss)->ptr; s[0] = RBIGNUM(x)->sign ? '+' : '-'; + TRAP_BEG; while (i && j > 1) { long k = i; BDIGIT_DBL num = 0; @@ -749,6 +751,7 @@ RSTRING(ss)->len = i; } s[RSTRING(ss)->len] = '\0'; + TRAP_END; return ss; } @@ -1735,11 +1738,13 @@ RBIGNUM(z)->len = len; a2 = bigtrunc(rb_big_mul0(a, b)); len = RBIGNUM(a2)->len; + TRAP_BEG; for (i = 0, num = 0; i < len; i++) { num += (BDIGIT_DBL)BDIGITS(z)[i + k] + ((BDIGIT_DBL)BDIGITS(a2)[i] << 1); BDIGITS(z)[i + k] = BIGLO(num); num = BIGDN(num); } + TRAP_END; if (num) { len = RBIGNUM(z)->len; for (i += k; i < len && num; ++i) { diff -Nru ruby1.8-1.8.7.22/ChangeLog ruby1.8-1.8.7.72/ChangeLog --- ruby1.8-1.8.7.22/ChangeLog 2008-06-20 06:28:35.000000000 -0300 +++ ruby1.8-1.8.7.72/ChangeLog 2008-08-10 21:37:21.000000000 -0300 @@ -1,3 +1,305 @@ +Fri Aug 8 10:53:52 2008 Tanaka Akira + + * lib/resolv.rb: randomize source port and transaction id. + CVE-2008-1447. + + * lib/resolv-replace.rb (UDPSocket#bind): don't resolv host if host is + "". + +Mon Aug 4 14:49:35 2008 URABE Shyouhei + + * lib/net/smtp.rb (Net::SMTP::rcptto): fix a typo. a patch from + Masao Takaku + fix [ruby-dev:35489]. + +Mon Aug 4 14:13:15 2008 Nobuyoshi Nakada + + * regex.c (xmalloc, xrealloc, xfree): not to use ruby managed memory. + + * regex.c (DOUBLE_STACK, re_compile_fastmap0, re_adjust_startpos), + (re_search, re_match_exec): check if failed to allocate memory. + +Mon Aug 4 13:53:42 2008 Nobuyoshi Nakada + + * bignum.c (rb_big2str0, bigsqr): made interruptible. [ruby-Bugs-20622] + +Mon Aug 4 13:31:41 2008 NAKAMURA Usaku + + * numeric.c (check_uint, rb_num2uint, rb_fix2uint): fixed wrong check + about 64bit positive value. +Mon Aug 4 13:31:41 2008 NAKAMURA Usaku + + * numeric.c (check_uint, rb_num2uint, rb_fix2uint): strict check. + fixed [ruby-dev:33683] +Mon Aug 11 09:37:17 2008 Yukihiro Matsumoto + + * ext/dl/dl.c (rb_str_to_ptr): should propagate taint to dlptr. + + * ext/dl/dl.c (rb_ary_to_ptr): ditto. + + * ext/dl/sym.c (rb_dlsym_call): should check taint of DLPtrData as + well. + + +Thu Jul 17 21:42:07 2008 URABE Shyouhei + + * lib/net/smtp.rb (Net::SMTP::start): revert to avoid RFC2821 + violation. [ruby-dev:35487] + +Thu Jul 17 21:32:49 2008 Tanaka Akira + + * string.c (rb_str_format_m): make tmp volatile to avoid possible GC + problem. + +Thu Jul 17 21:30:55 2008 Nobuyoshi Nakada + + * lib/optparse.rb (OptionParser#environment): requires shellwords. + [ruby-dev:35466] + +Thu Jul 17 02:05:10 2008 Nobuyoshi Nakada + + * lib/xmlrpc/client.rb (XMLRPC::Client#do_rpc): requires + webrick/cookie. [ ruby-Bugs-21139 ] + +Thu Jul 17 01:38:31 2008 Yusuke Endoh + + * ext/zlib/zlib.c (rb_gzfile_set_mtime): fix typo. [ruby-core:17713] + +Sun Jul 13 00:08:16 2008 Nobuyoshi Nakada + + * lib/ipaddr.rb (IPAddr#initialize): get rid of ArgumentError in + IPAddr#to_range. a patch from okkez in + [ruby-dev:35091]. + +Sun Jul 13 00:04:38 2008 Tanaka Akira + + * configure.in (erfc): erfc of glibc comes with Debian GNU/Linux Etch + on IA64 is broken. erfc(10000.0) aborts. + use missing/erf.c instead. + http://sources.redhat.com/ml/libc-hacker/2005-08/msg00008.html + +Thu Jul 10 18:50:48 2008 Tanaka Akira + + * common.mk (SPEC_GIT_BASE): update RubySpec GIT URL. + +Thu Jul 10 18:46:28 2008 Nobuyoshi Nakada + + * file.c (rb_file_s_extname): fix for file name with spaces. + [ruby-talk:307404] + +Thu Jul 10 18:42:37 2008 Masatoshi SEKI + + * lib/erb.rb (PercentScanner#scan): fix %% line bug. [ruby-core:17491] + + * test/erb/test_erb.rb (test_percent): ditto. + +Thu Jul 10 18:40:22 2008 Nobuyoshi Nakada + + * lib/net/ftp.rb (Net::FTP#sendport): use divmod. [ruby-core:17557] + +Thu Jul 10 18:36:53 2008 Kazuhiro NISHIYAMA + + * ruby.c: Mac OS X needs origargc times of '\0' in + origargv. [ruby-dev:35308] + +Thu Jul 10 13:53:08 2008 Tanaka Akira + + * include/ruby/ruby.h (POSFIXABLE): use FIXNUM_MAX+1 instead of + FIXNUM_MAX to make it possible to convert to double accurately. + It assumes FLT_RADIX is 2. + fix RubyForge bug #14102. + backported from 1.9. + +Mon Jul 7 16:21:38 2008 Yukihiro Matsumoto + + * lib/net/smtp.rb (Net::SMTP::start): use 'localhost' instead of + 'localhost.localdomain'. [ruby-dev:35333] + + * lib/net/smtp.rb (Net::SMTP::SMTP.start): ditto. + +Mon Jul 7 15:02:13 2008 Nobuyoshi Nakada + + * eval.c (rb_longjmp): duplicate the thrown exception to set backtrace + if it was frozen. clear all raised flags. + + * eval.c (stack_check): leave clearing flag to rb_longjmp. + + * eval.c (rb_thread_set_raised, rb_thread_reset_raised): use generic + flags. + + * eval.c (Init_Proc), gc.c (Init_GC): freeze preallocated special exceptions. + + * gc.c (rb_memerror): use thread raised flag instead of static flag, + and raise nomem_error without backtrace if failed to make backtrace. + [ruby-dev:34724] + + * gc.c (ruby_xmalloc): increase malloc_increase only if malloc + succeeds. failed malloc size can be huge. it may increase + malloc_limit too big which cause less GC and memory full. + (ruby_xrealloc): ditto. + +Mon Jul 7 12:23:05 2008 Masaki Suketa + + * ext/win32ole/win32ole.c: avoid creating Ruby object during + GC. thanks to arton . [ruby-dev:35313] + + * ext/win32ole/tests: add test_win32ole_event.rb, remove + testOLEEVENT.rb + + * ext/win32ole/tests/testWIN32OLE.rb(test_convert_bignum): + fix test. + +Mon Jul 7 12:23:05 2008 Masaki Suketa + + * gc.c: add rb_during_gc(). based on a patch from arton at [ruby-dev:35313]. + + * intern.h: ditto. + +Thu Jul 3 20:13:20 2008 Nobuyoshi Nakada + + * marshal.c (w_object, marshal_dump, r_object0, marshal_load): search + public methods only. [ruby-core:17283] + + * object.c (convert_type): ditto. + + * lib/singleton.rb (Singleton#_dump): conversion method should be + public. + +Wed Jul 2 19:06:43 2008 Nobuyoshi Nakada + + * lib/cgi.rb (CGI::QueryExtension.read_multipart): blanks inside + double quotes are allowed. [ruby-list:45140] + +Wed Jul 2 19:03:37 2008 Tanaka Akira + + * numeric.c (num_coerce): call rb_Float(x) first. don't depend on + evaluation order of function arguments. + +Wed Jul 2 18:57:19 2008 Yukihiro Matsumoto + + * ext/syslog/syslog.c (syslog_write): syslog operations should be + protected from $SAFE level 4. a patch from Keita Yamaguchi + . + + * ext/syslog/syslog.c (mSyslog_close): ditto. + + * ext/syslog/syslog.c (mSyslog_set_mask): ditto. + +Wed Jul 2 18:26:20 2008 Tanaka Akira + + * math.c (domain_check): fix preprocess condition. + +Wed Jul 2 18:22:52 2008 Nobuyoshi Nakada + + * lib/tmpdir.rb (@@systmpdir): prior LOCAL_APPDATA if possible, and + should be clean. based on a patch from arton at [ruby-dev:35269] + +Wed Jul 2 18:16:19 2008 Masaki Suketa + + * ext/win32ole/win32ole.c (date2time_str): fix the overflow in + some situation. [ruby-bugs-20793] + +Tue Jul 1 15:11:14 2008 Nobuyoshi Nakada + + * array.c (rb_ary_fill): check if beg is too big. + +Mon Jun 30 20:35:32 2008 Nobuyoshi Nakada + + * string.c (str_buf_cat): check for self concatenation. + +Sun Jun 29 21:39:54 2008 Tanaka Akira + + * eval.c (rb_obj_respond_to): use RTEST to test the result of + respond_to? method. + +Sun Jun 29 21:20:17 2008 URABE Shyouhei + + * array.c (rb_ary_fill): (compatibility) do not raise + ArgumentError on negative length. This behaviour shall change + in a future release. + +Sun Jun 29 20:08:11 2008 Tanaka Akira + + * time.c (time_timeval): fix rounding negative float. + +Sun Jun 29 19:19:08 2008 Nobuyoshi Nakada + + * test/inlinetest.rb (InlineTest.in_progname): workaround for frozen + $0. [ruby-dev:35261] + + * lib/test/unit/ui/console/testrunner.rb (TestRunner#finished): ditto. + +Sun Jun 29 19:19:08 2008 Nobuyoshi Nakada + + * ruby.c (set_arg0, ruby_prog_init): freeze $0. a patch from Keita + Yamaguchi . + +Sun Jun 29 18:33:33 2008 Tanaka Akira + + * process.c: include sys/resource.h if HAVE_SYS_RESOURCE_H is defined. + pointed by TOYOFUKU Chikanobu. [ruby-dev:35258] + +Sun Jun 29 18:26:01 2008 Yukihiro Matsumoto + + * variable.c (rb_f_trace_var): should not be allowed at safe level 4. + a patch from Keita Yamaguchi . + + * eval.c (rb_call0): wrong condition to check insecure method. + a patch from Keita Yamaguchi . + +Sun Jun 29 18:22:52 2008 Nobuyoshi Nakada + + * array.c (rb_ary_fill): not depend on unspecified behavior at integer + overflow. reported by Vincenzo Iozzo . + +Sun Jun 29 18:22:06 2008 Masaki Suketa + + * ext/win32ole/win32ole.c(ole_invoke): fix memory leak. + [ruby-bugs-20792] + +Sun Jun 29 18:19:11 2008 Akinori MUSHA + + * eval.c (PUSH_FRAME, PUSH_CLASS): Add volatile to avoid a + possible optimization bug on OS X/PPC. This at least makes + build with gcc -O1 and `make test' pass. + +Sun Jun 29 17:24:43 2008 Nobuyoshi Nakada + + * lib/rdoc/parsers/parse_rb.rb (RDoc#collect_first_comment): skip + magic comment. + +Sun Jun 29 17:22:09 2008 Nobuyoshi Nakada + + * ext/stringio/stringio.c (strio_each, strio_readlines): IO#each and + IO#readlines do not affect $_. [ruby-core:17277] + +Sun Jun 29 17:19:59 2008 Nobuyoshi Nakada + + * ext/stringio/stringio.c (strio_readline, strio_each) + (strio_readlines): set lastline. [ruby-core:17257] + +Sun Jun 29 17:15:49 2008 NAKAMURA Usaku + + * ext/openssl/ossl.h: include winsock.h if USE_WINSOCK2 is not defined. + a patch from arton in [ruby-dev:35078] + +Sun Jun 29 17:09:48 2008 wanabe + + * util.c (ruby_strtod): ruby_strtod don't allow a trailing + decimal point like "7.". [ruby-dev:34835] [ruby-dev:35009] + +Sat Jun 28 19:23:40 2008 URABE Shyouhei + + * class.c (clone_method): use rb_copy_node_scope. + fixed [ruby-list:45102] + fixed [ruby-core:17393] + +Sat Jun 28 18:49:50 2008 URABE Shyouhei + + * class.c: revert to r15855. + Fri Jun 20 18:25:18 2008 Nobuyoshi Nakada * string.c (rb_str_buf_append): should infect. diff -Nru ruby1.8-1.8.7.22/class.c ruby1.8-1.8.7.72/class.c --- ruby1.8-1.8.7.22/class.c 2008-05-23 02:22:13.000000000 -0300 +++ ruby1.8-1.8.7.72/class.c 2008-06-28 07:23:54.000000000 -0300 @@ -2,8 +2,8 @@ class.c - - $Author: knu $ - $Date: 2008-05-23 14:22:13 +0900 (Fri, 23 May 2008) $ + $Author: shyouhei $ + $Date: 2008-06-28 19:23:54 +0900 (Sat, 28 Jun 2008) $ created at: Tue Aug 10 15:05:44 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -48,37 +48,26 @@ return rb_class_boot(super); } +struct clone_method_data { + st_table *tbl; + VALUE klass; +}; + static int -clone_method(mid, body, nklass) +clone_method(mid, body, data) ID mid; NODE *body; - VALUE nklass; + struct clone_method_data *data; { NODE *fbody = body->nd_body; - if (fbody) { - VALUE nbody; - - switch (nd_type(fbody)) { - case NODE_SCOPE: - fbody = rb_copy_node_scope(fbody, ruby_cref); - break; - case NODE_BMETHOD: - nbody = rb_block_dup(fbody->nd_cval, nklass, (VALUE)ruby_cref); - fbody = NEW_BMETHOD(nbody); - break; - case NODE_DMETHOD: - nbody = rb_method_dup(fbody->nd_cval, nklass, (VALUE)ruby_cref); - fbody = NEW_DMETHOD(nbody); - break; - } + if (fbody && nd_type(fbody) == NODE_SCOPE) { + fbody = rb_copy_node_scope(fbody, ruby_cref); } - st_insert(RCLASS(nklass)->m_tbl, mid, (st_data_t)NEW_METHOD(fbody, body->nd_noex)); + st_insert(data->tbl, mid, (st_data_t)NEW_METHOD(fbody, body->nd_noex)); return ST_CONTINUE; } -static VALUE singleton_class_clone_int _((VALUE, VALUE)); - /* :nodoc: */ VALUE rb_mod_init_copy(clone, orig) @@ -86,7 +75,8 @@ { rb_obj_init_copy(clone, orig); if (!FL_TEST(CLASS_OF(clone), FL_SINGLETON)) { - RBASIC(clone)->klass = singleton_class_clone_int(orig, clone); + RBASIC(clone)->klass = RBASIC(orig)->klass; + RBASIC(clone)->klass = rb_singleton_class_clone(clone); } RCLASS(clone)->super = RCLASS(orig)->super; if (RCLASS(orig)->iv_tbl) { @@ -99,8 +89,12 @@ st_delete(RCLASS(clone)->iv_tbl, (st_data_t*)&id, 0); } if (RCLASS(orig)->m_tbl) { - RCLASS(clone)->m_tbl = st_init_numtable(); - st_foreach(RCLASS(orig)->m_tbl, clone_method, clone); + struct clone_method_data data; + + data.tbl = RCLASS(clone)->m_tbl = st_init_numtable(); + data.klass = (VALUE)clone; + + st_foreach(RCLASS(orig)->m_tbl, clone_method, (st_data_t)&data); } return clone; @@ -120,9 +114,9 @@ return rb_mod_init_copy(clone, orig); } -static VALUE -singleton_class_clone_int(obj, nklass) - VALUE obj, nklass; +VALUE +rb_singleton_class_clone(obj) + VALUE obj; { VALUE klass = RBASIC(obj)->klass; @@ -146,21 +140,28 @@ if (RCLASS(klass)->iv_tbl) { clone->iv_tbl = st_copy(RCLASS(klass)->iv_tbl); } - clone->m_tbl = st_init_numtable(); - st_foreach(RCLASS(klass)->m_tbl, clone_method, NIL_P(nklass) ? (VALUE)clone : nklass); + { + struct clone_method_data data; + + data.tbl = clone->m_tbl = st_init_numtable(); + switch (TYPE(obj)) { + case T_CLASS: + case T_MODULE: + data.klass = obj; + break; + default: + data.klass = 0; + break; + } + + st_foreach(RCLASS(klass)->m_tbl, clone_method, (st_data_t)&data); + } rb_singleton_class_attached(RBASIC(clone)->klass, (VALUE)clone); FL_SET(clone, FL_SINGLETON); return (VALUE)clone; } } -VALUE -rb_singleton_class_clone(obj) - VALUE obj; -{ - return singleton_class_clone_int(obj, Qnil); -} - void rb_singleton_class_attached(klass, obj) VALUE klass, obj; diff -Nru ruby1.8-1.8.7.22/common.mk ruby1.8-1.8.7.72/common.mk --- ruby1.8-1.8.7.22/common.mk 2008-05-23 02:22:13.000000000 -0300 +++ ruby1.8-1.8.7.72/common.mk 2008-08-04 02:05:38.000000000 -0300 @@ -5,7 +5,7 @@ RUBYLIB = - RUBYOPT = - -SPEC_GIT_BASE = git://github.com/brixen +SPEC_GIT_BASE = git://github.com/rubyspec MSPEC_GIT_URL = $(SPEC_GIT_BASE)/mspec.git RUBYSPEC_GIT_URL = $(SPEC_GIT_BASE)/rubyspec.git @@ -362,7 +362,8 @@ {$(VPATH)}defines.h {$(VPATH)}intern.h {$(VPATH)}missing.h \ {$(VPATH)}util.h {$(VPATH)}st.h bignum.$(OBJEXT): {$(VPATH)}bignum.c {$(VPATH)}ruby.h config.h \ - {$(VPATH)}defines.h {$(VPATH)}intern.h {$(VPATH)}missing.h + {$(VPATH)}defines.h {$(VPATH)}intern.h {$(VPATH)}missing.h \ + {$(VPATH)}rubysig.h class.$(OBJEXT): {$(VPATH)}class.c {$(VPATH)}ruby.h config.h \ {$(VPATH)}defines.h {$(VPATH)}intern.h {$(VPATH)}missing.h \ {$(VPATH)}rubysig.h {$(VPATH)}node.h {$(VPATH)}st.h diff -Nru ruby1.8-1.8.7.22/configure ruby1.8-1.8.7.72/configure --- ruby1.8-1.8.7.22/configure 2008-06-20 06:30:12.000000000 -0300 +++ ruby1.8-1.8.7.72/configure 1969-12-31 21:00:00.000000000 -0300 @@ -1,18898 +0,0 @@ -#! /bin/sh -# Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.61. -# -# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, -# 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. -# This configure script is free software; the Free Software Foundation -# gives unlimited permission to copy, distribute and modify it. -## --------------------- ## -## M4sh Initialization. ## -## --------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then - emulate sh - NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in - *posix*) set -o posix ;; -esac - -fi - - - - -# PATH needs CR -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - echo "#! /bin/sh" >conf$$.sh - echo "exit 0" >>conf$$.sh - chmod +x conf$$.sh - if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then - PATH_SEPARATOR=';' - else - PATH_SEPARATOR=: - fi - rm -f conf$$.sh -fi - -# Support unset when possible. -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then - as_unset=unset -else - as_unset=false -fi - - -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -as_nl=' -' -IFS=" "" $as_nl" - -# Find who we are. Look in the path if we contain no directory separator. -case $0 in - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break -done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - { (exit 1); exit 1; } -fi - -# Work around bugs in pre-3.0 UWIN ksh. -for as_var in ENV MAIL MAILPATH -do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -for as_var in \ - LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ - LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ - LC_TELEPHONE LC_TIME -do - if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then - eval $as_var=C; export $as_var - else - ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var - fi -done - -# Required to use basename. -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - - -# Name of the executable. -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# CDPATH. -$as_unset CDPATH - - -if test "x$CONFIG_SHELL" = x; then - if (eval ":") 2>/dev/null; then - as_have_required=yes -else - as_have_required=no -fi - - if test $as_have_required = yes && (eval ": -(as_func_return () { - (exit \$1) -} -as_func_success () { - as_func_return 0 -} -as_func_failure () { - as_func_return 1 -} -as_func_ret_success () { - return 0 -} -as_func_ret_failure () { - return 1 -} - -exitcode=0 -if as_func_success; then - : -else - exitcode=1 - echo as_func_success failed. -fi - -if as_func_failure; then - exitcode=1 - echo as_func_failure succeeded. -fi - -if as_func_ret_success; then - : -else - exitcode=1 - echo as_func_ret_success failed. -fi - -if as_func_ret_failure; then - exitcode=1 - echo as_func_ret_failure succeeded. -fi - -if ( set x; as_func_ret_success y && test x = \"\$1\" ); then - : -else - exitcode=1 - echo positional parameters were not saved. -fi - -test \$exitcode = 0) || { (exit 1); exit 1; } - -( - as_lineno_1=\$LINENO - as_lineno_2=\$LINENO - test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" && - test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; } -") 2> /dev/null; then - : -else - as_candidate_shells= - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - case $as_dir in - /*) - for as_base in sh bash ksh sh5; do - as_candidate_shells="$as_candidate_shells $as_dir/$as_base" - done;; - esac -done -IFS=$as_save_IFS - - - for as_shell in $as_candidate_shells $SHELL; do - # Try only shells that exist, to save several forks. - if { test -f "$as_shell" || test -f "$as_shell.exe"; } && - { ("$as_shell") 2> /dev/null <<\_ASEOF -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then - emulate sh - NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in - *posix*) set -o posix ;; -esac - -fi - - -: -_ASEOF -}; then - CONFIG_SHELL=$as_shell - as_have_required=yes - if { "$as_shell" 2> /dev/null <<\_ASEOF -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then - emulate sh - NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in - *posix*) set -o posix ;; -esac - -fi - - -: -(as_func_return () { - (exit $1) -} -as_func_success () { - as_func_return 0 -} -as_func_failure () { - as_func_return 1 -} -as_func_ret_success () { - return 0 -} -as_func_ret_failure () { - return 1 -} - -exitcode=0 -if as_func_success; then - : -else - exitcode=1 - echo as_func_success failed. -fi - -if as_func_failure; then - exitcode=1 - echo as_func_failure succeeded. -fi - -if as_func_ret_success; then - : -else - exitcode=1 - echo as_func_ret_success failed. -fi - -if as_func_ret_failure; then - exitcode=1 - echo as_func_ret_failure succeeded. -fi - -if ( set x; as_func_ret_success y && test x = "$1" ); then - : -else - exitcode=1 - echo positional parameters were not saved. -fi - -test $exitcode = 0) || { (exit 1); exit 1; } - -( - as_lineno_1=$LINENO - as_lineno_2=$LINENO - test "x$as_lineno_1" != "x$as_lineno_2" && - test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; } - -_ASEOF -}; then - break -fi - -fi - - done - - if test "x$CONFIG_SHELL" != x; then - for as_var in BASH_ENV ENV - do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var - done - export CONFIG_SHELL - exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} -fi - - - if test $as_have_required = no; then - echo This script requires a shell more modern than all the - echo shells that I found on your system. Please install a - echo modern shell, or manually run the script under such a - echo shell if you do have one. - { (exit 1); exit 1; } -fi - - -fi - -fi - - - -(eval "as_func_return () { - (exit \$1) -} -as_func_success () { - as_func_return 0 -} -as_func_failure () { - as_func_return 1 -} -as_func_ret_success () { - return 0 -} -as_func_ret_failure () { - return 1 -} - -exitcode=0 -if as_func_success; then - : -else - exitcode=1 - echo as_func_success failed. -fi - -if as_func_failure; then - exitcode=1 - echo as_func_failure succeeded. -fi - -if as_func_ret_success; then - : -else - exitcode=1 - echo as_func_ret_success failed. -fi - -if as_func_ret_failure; then - exitcode=1 - echo as_func_ret_failure succeeded. -fi - -if ( set x; as_func_ret_success y && test x = \"\$1\" ); then - : -else - exitcode=1 - echo positional parameters were not saved. -fi - -test \$exitcode = 0") || { - echo No shell found that supports shell functions. - echo Please tell autoconf@gnu.org about your system, - echo including any error possibly output before this - echo message -} - - - - as_lineno_1=$LINENO - as_lineno_2=$LINENO - test "x$as_lineno_1" != "x$as_lineno_2" && - test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || { - - # Create $as_me.lineno as a copy of $as_myself, but with $LINENO - # uniformly replaced by the line number. The first 'sed' inserts a - # line-number line after each line using $LINENO; the second 'sed' - # does the real work. The second script uses 'N' to pair each - # line-number line with the line containing $LINENO, and appends - # trailing '-' during substitution so that $LINENO is not a special - # case at line end. - # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the - # scripts with optimization help from Paolo Bonzini. Blame Lee - # E. McMahon (1931-1989) for sed's syntax. :-) - sed -n ' - p - /[$]LINENO/= - ' <$as_myself | - sed ' - s/[$]LINENO.*/&-/ - t lineno - b - :lineno - N - :loop - s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ - t loop - s/-\n.*// - ' >$as_me.lineno && - chmod +x "$as_me.lineno" || - { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 - { (exit 1); exit 1; }; } - - # Don't try to exec as it changes $[0], causing all sort of problems - # (the dirname of $[0] is not the place where we might find the - # original and so on. Autoconf is especially sensitive to this). - . "./$as_me.lineno" - # Exit status is that of the last command. - exit -} - - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in --n*) - case `echo 'x\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - *) ECHO_C='\c';; - esac;; -*) - ECHO_N='-n';; -esac - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir -fi -echo >conf$$.file -if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -p' -elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln -else - as_ln_s='cp -p' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - -if mkdir -p . 2>/dev/null; then - as_mkdir_p=: -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - -if test -x / >/dev/null 2>&1; then - as_test_x='test -x' -else - if ls -dL / >/dev/null 2>&1; then - as_ls_L_option=L - else - as_ls_L_option= - fi - as_test_x=' - eval sh -c '\'' - if test -d "$1"; then - test -d "$1/."; - else - case $1 in - -*)set "./$1";; - esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in - ???[sx]*):;;*)false;;esac;fi - '\'' sh - ' -fi -as_executable_p=$as_test_x - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - - - -exec 7<&0 &1 - -# Name of the host. -# hostname on some systems (SVR3.2, Linux) returns a bogus exit status, -# so uname gets run too. -ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` - -# -# Initializations. -# -ac_default_prefix=/usr/local -ac_clean_files= -ac_config_libobj_dir=. -LIBOBJS= -cross_compiling=no -subdirs= -MFLAGS= -MAKEFLAGS= -SHELL=${CONFIG_SHELL-/bin/sh} - -# Identity of this package. -PACKAGE_NAME= -PACKAGE_TARNAME= -PACKAGE_VERSION= -PACKAGE_STRING= -PACKAGE_BUGREPORT= - -# Factoring default headers for most tests. -ac_includes_default="\ -#include -#ifdef HAVE_SYS_TYPES_H -# include -#endif -#ifdef HAVE_SYS_STAT_H -# include -#endif -#ifdef STDC_HEADERS -# include -# include -#else -# ifdef HAVE_STDLIB_H -# include -# endif -#endif -#ifdef HAVE_STRING_H -# if !defined STDC_HEADERS && defined HAVE_MEMORY_H -# include -# endif -# include -#endif -#ifdef HAVE_STRINGS_H -# include -#endif -#ifdef HAVE_INTTYPES_H -# include -#endif -#ifdef HAVE_STDINT_H -# include -#endif -#ifdef HAVE_UNISTD_H -# include -#endif" - -ac_subst_vars='SHELL -PATH_SEPARATOR -PACKAGE_NAME -PACKAGE_TARNAME -PACKAGE_VERSION -PACKAGE_STRING -PACKAGE_BUGREPORT -exec_prefix -prefix -program_transform_name -bindir -sbindir -libexecdir -datarootdir -datadir -sysconfdir -sharedstatedir -localstatedir -includedir -oldincludedir -docdir -infodir -htmldir -dvidir -pdfdir -psdir -libdir -localedir -mandir -DEFS -ECHO_C -ECHO_N -ECHO_T -LIBS -build_alias -host_alias -target_alias -MAJOR -MINOR -TEENY -build -build_cpu -build_vendor -build_os -host -host_cpu -host_vendor -host_os -target -target_cpu -target_vendor -target_os -CC -CFLAGS -LDFLAGS -CPPFLAGS -ac_ct_CC -EXEEXT -OBJEXT -CPP -GREP -EGREP -GNU_LD -CPPOUTFILE -OUTFLAG -YACC -YFLAGS -RANLIB -AR -AS -ASFLAGS -NM -WINDRES -DLLWRAP -OBJDUMP -LN_S -SET_MAKE -INSTALL_PROGRAM -INSTALL_SCRIPT -INSTALL_DATA -RM -CP -MAKEDIRS -LIBOBJS -ALLOCA -DLDFLAGS -ARCH_FLAG -STATIC -CCDLFLAGS -LDSHARED -DLEXT -DLEXT2 -LIBEXT -LINK_SO -LIBPATHFLAG -RPATHFLAG -LIBPATHENV -TRY_LINK -STRIP -EXTSTATIC -setup -MINIRUBY -PREP -RUNRUBY -EXTOUT -ARCHFILE -RDOCTARGET -cppflags -cflags -optflags -debugflags -XCFLAGS -XLDFLAGS -LIBRUBY_LDSHARED -LIBRUBY_DLDFLAGS -RUBY_INSTALL_NAME -rubyw_install_name -RUBYW_INSTALL_NAME -RUBY_SO_NAME -LIBRUBY_A -LIBRUBY_SO -LIBRUBY_ALIASES -LIBRUBY -LIBRUBYARG -LIBRUBYARG_STATIC -LIBRUBYARG_SHARED -SOLIBS -DLDLIBS -ENABLE_SHARED -MAINLIBS -COMMON_LIBS -COMMON_MACROS -COMMON_HEADERS -EXPORT_PREFIX -MINIOBJS -MAKEFILES -arch -sitearch -sitedir -vendordir -configure_args -NROFF -MANTYPE -LTLIBOBJS' -ac_subst_files='' - ac_precious_vars='build_alias -host_alias -target_alias -CC -CFLAGS -LDFLAGS -LIBS -CPPFLAGS -CPP -YACC -YFLAGS' - - -# Initialize some variables set by options. -ac_init_help= -ac_init_version=false -# The variables have the same names as the options, with -# dashes changed to underlines. -cache_file=/dev/null -exec_prefix=NONE -no_create= -no_recursion= -prefix=NONE -program_prefix=NONE -program_suffix=NONE -program_transform_name=s,x,x, -silent= -site= -srcdir= -verbose= -x_includes=NONE -x_libraries=NONE - -# Installation directory options. -# These are left unexpanded so users can "make install exec_prefix=/foo" -# and all the variables that are supposed to be based on exec_prefix -# by default will actually change. -# Use braces instead of parens because sh, perl, etc. also accept them. -# (The list follows the same order as the GNU Coding Standards.) -bindir='${exec_prefix}/bin' -sbindir='${exec_prefix}/sbin' -libexecdir='${exec_prefix}/libexec' -datarootdir='${prefix}/share' -datadir='${datarootdir}' -sysconfdir='${prefix}/etc' -sharedstatedir='${prefix}/com' -localstatedir='${prefix}/var' -includedir='${prefix}/include' -oldincludedir='/usr/include' -docdir='${datarootdir}/doc/${PACKAGE}' -infodir='${datarootdir}/info' -htmldir='${docdir}' -dvidir='${docdir}' -pdfdir='${docdir}' -psdir='${docdir}' -libdir='${exec_prefix}/lib' -localedir='${datarootdir}/locale' -mandir='${datarootdir}/man' - -ac_prev= -ac_dashdash= -for ac_option -do - # If the previous option needs an argument, assign it. - if test -n "$ac_prev"; then - eval $ac_prev=\$ac_option - ac_prev= - continue - fi - - case $ac_option in - *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; - *) ac_optarg=yes ;; - esac - - # Accept the important Cygnus configure options, so we can diagnose typos. - - case $ac_dashdash$ac_option in - --) - ac_dashdash=yes ;; - - -bindir | --bindir | --bindi | --bind | --bin | --bi) - ac_prev=bindir ;; - -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) - bindir=$ac_optarg ;; - - -build | --build | --buil | --bui | --bu) - ac_prev=build_alias ;; - -build=* | --build=* | --buil=* | --bui=* | --bu=*) - build_alias=$ac_optarg ;; - - -cache-file | --cache-file | --cache-fil | --cache-fi \ - | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) - ac_prev=cache_file ;; - -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ - | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) - cache_file=$ac_optarg ;; - - --config-cache | -C) - cache_file=config.cache ;; - - -datadir | --datadir | --datadi | --datad) - ac_prev=datadir ;; - -datadir=* | --datadir=* | --datadi=* | --datad=*) - datadir=$ac_optarg ;; - - -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ - | --dataroo | --dataro | --datar) - ac_prev=datarootdir ;; - -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ - | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) - datarootdir=$ac_optarg ;; - - -disable-* | --disable-*) - ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null && - { echo "$as_me: error: invalid feature name: $ac_feature" >&2 - { (exit 1); exit 1; }; } - ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'` - eval enable_$ac_feature=no ;; - - -docdir | --docdir | --docdi | --doc | --do) - ac_prev=docdir ;; - -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) - docdir=$ac_optarg ;; - - -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) - ac_prev=dvidir ;; - -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) - dvidir=$ac_optarg ;; - - -enable-* | --enable-*) - ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null && - { echo "$as_me: error: invalid feature name: $ac_feature" >&2 - { (exit 1); exit 1; }; } - ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'` - eval enable_$ac_feature=\$ac_optarg ;; - - -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ - | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ - | --exec | --exe | --ex) - ac_prev=exec_prefix ;; - -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ - | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ - | --exec=* | --exe=* | --ex=*) - exec_prefix=$ac_optarg ;; - - -gas | --gas | --ga | --g) - # Obsolete; use --with-gas. - with_gas=yes ;; - - -help | --help | --hel | --he | -h) - ac_init_help=long ;; - -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) - ac_init_help=recursive ;; - -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) - ac_init_help=short ;; - - -host | --host | --hos | --ho) - ac_prev=host_alias ;; - -host=* | --host=* | --hos=* | --ho=*) - host_alias=$ac_optarg ;; - - -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) - ac_prev=htmldir ;; - -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ - | --ht=*) - htmldir=$ac_optarg ;; - - -includedir | --includedir | --includedi | --included | --include \ - | --includ | --inclu | --incl | --inc) - ac_prev=includedir ;; - -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ - | --includ=* | --inclu=* | --incl=* | --inc=*) - includedir=$ac_optarg ;; - - -infodir | --infodir | --infodi | --infod | --info | --inf) - ac_prev=infodir ;; - -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) - infodir=$ac_optarg ;; - - -libdir | --libdir | --libdi | --libd) - ac_prev=libdir ;; - -libdir=* | --libdir=* | --libdi=* | --libd=*) - libdir=$ac_optarg ;; - - -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ - | --libexe | --libex | --libe) - ac_prev=libexecdir ;; - -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ - | --libexe=* | --libex=* | --libe=*) - libexecdir=$ac_optarg ;; - - -localedir | --localedir | --localedi | --localed | --locale) - ac_prev=localedir ;; - -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) - localedir=$ac_optarg ;; - - -localstatedir | --localstatedir | --localstatedi | --localstated \ - | --localstate | --localstat | --localsta | --localst | --locals) - ac_prev=localstatedir ;; - -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ - | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) - localstatedir=$ac_optarg ;; - - -mandir | --mandir | --mandi | --mand | --man | --ma | --m) - ac_prev=mandir ;; - -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) - mandir=$ac_optarg ;; - - -nfp | --nfp | --nf) - # Obsolete; use --without-fp. - with_fp=no ;; - - -no-create | --no-create | --no-creat | --no-crea | --no-cre \ - | --no-cr | --no-c | -n) - no_create=yes ;; - - -no-recursion | --no-recursion | --no-recursio | --no-recursi \ - | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) - no_recursion=yes ;; - - -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ - | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ - | --oldin | --oldi | --old | --ol | --o) - ac_prev=oldincludedir ;; - -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ - | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ - | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) - oldincludedir=$ac_optarg ;; - - -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) - ac_prev=prefix ;; - -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) - prefix=$ac_optarg ;; - - -program-prefix | --program-prefix | --program-prefi | --program-pref \ - | --program-pre | --program-pr | --program-p) - ac_prev=program_prefix ;; - -program-prefix=* | --program-prefix=* | --program-prefi=* \ - | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) - program_prefix=$ac_optarg ;; - - -program-suffix | --program-suffix | --program-suffi | --program-suff \ - | --program-suf | --program-su | --program-s) - ac_prev=program_suffix ;; - -program-suffix=* | --program-suffix=* | --program-suffi=* \ - | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) - program_suffix=$ac_optarg ;; - - -program-transform-name | --program-transform-name \ - | --program-transform-nam | --program-transform-na \ - | --program-transform-n | --program-transform- \ - | --program-transform | --program-transfor \ - | --program-transfo | --program-transf \ - | --program-trans | --program-tran \ - | --progr-tra | --program-tr | --program-t) - ac_prev=program_transform_name ;; - -program-transform-name=* | --program-transform-name=* \ - | --program-transform-nam=* | --program-transform-na=* \ - | --program-transform-n=* | --program-transform-=* \ - | --program-transform=* | --program-transfor=* \ - | --program-transfo=* | --program-transf=* \ - | --program-trans=* | --program-tran=* \ - | --progr-tra=* | --program-tr=* | --program-t=*) - program_transform_name=$ac_optarg ;; - - -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) - ac_prev=pdfdir ;; - -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) - pdfdir=$ac_optarg ;; - - -psdir | --psdir | --psdi | --psd | --ps) - ac_prev=psdir ;; - -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) - psdir=$ac_optarg ;; - - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - silent=yes ;; - - -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) - ac_prev=sbindir ;; - -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ - | --sbi=* | --sb=*) - sbindir=$ac_optarg ;; - - -sharedstatedir | --sharedstatedir | --sharedstatedi \ - | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ - | --sharedst | --shareds | --shared | --share | --shar \ - | --sha | --sh) - ac_prev=sharedstatedir ;; - -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ - | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ - | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ - | --sha=* | --sh=*) - sharedstatedir=$ac_optarg ;; - - -site | --site | --sit) - ac_prev=site ;; - -site=* | --site=* | --sit=*) - site=$ac_optarg ;; - - -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) - ac_prev=srcdir ;; - -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) - srcdir=$ac_optarg ;; - - -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ - | --syscon | --sysco | --sysc | --sys | --sy) - ac_prev=sysconfdir ;; - -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ - | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) - sysconfdir=$ac_optarg ;; - - -target | --target | --targe | --targ | --tar | --ta | --t) - ac_prev=target_alias ;; - -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) - target_alias=$ac_optarg ;; - - -v | -verbose | --verbose | --verbos | --verbo | --verb) - verbose=yes ;; - - -version | --version | --versio | --versi | --vers | -V) - ac_init_version=: ;; - - -with-* | --with-*) - ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null && - { echo "$as_me: error: invalid package name: $ac_package" >&2 - { (exit 1); exit 1; }; } - ac_package=`echo $ac_package | sed 's/[-.]/_/g'` - eval with_$ac_package=\$ac_optarg ;; - - -without-* | --without-*) - ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null && - { echo "$as_me: error: invalid package name: $ac_package" >&2 - { (exit 1); exit 1; }; } - ac_package=`echo $ac_package | sed 's/[-.]/_/g'` - eval with_$ac_package=no ;; - - --x) - # Obsolete; use --with-x. - with_x=yes ;; - - -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ - | --x-incl | --x-inc | --x-in | --x-i) - ac_prev=x_includes ;; - -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ - | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) - x_includes=$ac_optarg ;; - - -x-libraries | --x-libraries | --x-librarie | --x-librari \ - | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) - ac_prev=x_libraries ;; - -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ - | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) - x_libraries=$ac_optarg ;; - - -*) { echo "$as_me: error: unrecognized option: $ac_option -Try \`$0 --help' for more information." >&2 - { (exit 1); exit 1; }; } - ;; - - *=*) - ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` - # Reject names that are not valid shell variable names. - expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null && - { echo "$as_me: error: invalid variable name: $ac_envvar" >&2 - { (exit 1); exit 1; }; } - eval $ac_envvar=\$ac_optarg - export $ac_envvar ;; - - *) - # FIXME: should be removed in autoconf 3.0. - echo "$as_me: WARNING: you should use --build, --host, --target" >&2 - expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && - echo "$as_me: WARNING: invalid host type: $ac_option" >&2 - : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} - ;; - - esac -done - -if test -n "$ac_prev"; then - ac_option=--`echo $ac_prev | sed 's/_/-/g'` - { echo "$as_me: error: missing argument to $ac_option" >&2 - { (exit 1); exit 1; }; } -fi - -# Be sure to have absolute directory names. -for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ - datadir sysconfdir sharedstatedir localstatedir includedir \ - oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir -do - eval ac_val=\$$ac_var - case $ac_val in - [\\/$]* | ?:[\\/]* ) continue;; - NONE | '' ) case $ac_var in *prefix ) continue;; esac;; - esac - { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2 - { (exit 1); exit 1; }; } -done - -# There might be people who depend on the old broken behavior: `$host' -# used to hold the argument of --host etc. -# FIXME: To remove some day. -build=$build_alias -host=$host_alias -target=$target_alias - -# FIXME: To remove some day. -if test "x$host_alias" != x; then - if test "x$build_alias" = x; then - cross_compiling=maybe - echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. - If a cross compiler is detected then cross compile mode will be used." >&2 - elif test "x$build_alias" != "x$host_alias"; then - cross_compiling=yes - fi -fi - -ac_tool_prefix= -test -n "$host_alias" && ac_tool_prefix=$host_alias- - -test "$silent" = yes && exec 6>/dev/null - - -ac_pwd=`pwd` && test -n "$ac_pwd" && -ac_ls_di=`ls -di .` && -ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || - { echo "$as_me: error: Working directory cannot be determined" >&2 - { (exit 1); exit 1; }; } -test "X$ac_ls_di" = "X$ac_pwd_ls_di" || - { echo "$as_me: error: pwd does not report name of working directory" >&2 - { (exit 1); exit 1; }; } - - -# Find the source files, if location was not specified. -if test -z "$srcdir"; then - ac_srcdir_defaulted=yes - # Try the directory containing this script, then the parent directory. - ac_confdir=`$as_dirname -- "$0" || -$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$0" : 'X\(//\)[^/]' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -echo X"$0" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - srcdir=$ac_confdir - if test ! -r "$srcdir/$ac_unique_file"; then - srcdir=.. - fi -else - ac_srcdir_defaulted=no -fi -if test ! -r "$srcdir/$ac_unique_file"; then - test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." - { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2 - { (exit 1); exit 1; }; } -fi -ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" -ac_abs_confdir=`( - cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2 - { (exit 1); exit 1; }; } - pwd)` -# When building in place, set srcdir=. -if test "$ac_abs_confdir" = "$ac_pwd"; then - srcdir=. -fi -# Remove unnecessary trailing slashes from srcdir. -# Double slashes in file names in object file debugging info -# mess up M-x gdb in Emacs. -case $srcdir in -*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; -esac -for ac_var in $ac_precious_vars; do - eval ac_env_${ac_var}_set=\${${ac_var}+set} - eval ac_env_${ac_var}_value=\$${ac_var} - eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} - eval ac_cv_env_${ac_var}_value=\$${ac_var} -done - -# -# Report the --help message. -# -if test "$ac_init_help" = "long"; then - # Omit some internal or obsolete options to make the list less imposing. - # This message is too long to be a string in the A/UX 3.1 sh. - cat <<_ACEOF -\`configure' configures this package to adapt to many kinds of systems. - -Usage: $0 [OPTION]... [VAR=VALUE]... - -To assign environment variables (e.g., CC, CFLAGS...), specify them as -VAR=VALUE. See below for descriptions of some of the useful variables. - -Defaults for the options are specified in brackets. - -Configuration: - -h, --help display this help and exit - --help=short display options specific to this package - --help=recursive display the short help of all the included packages - -V, --version display version information and exit - -q, --quiet, --silent do not print \`checking...' messages - --cache-file=FILE cache test results in FILE [disabled] - -C, --config-cache alias for \`--cache-file=config.cache' - -n, --no-create do not create output files - --srcdir=DIR find the sources in DIR [configure dir or \`..'] - -Installation directories: - --prefix=PREFIX install architecture-independent files in PREFIX - [$ac_default_prefix] - --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX - [PREFIX] - -By default, \`make install' will install all the files in -\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify -an installation prefix other than \`$ac_default_prefix' using \`--prefix', -for instance \`--prefix=\$HOME'. - -For better control, use the options below. - -Fine tuning of the installation directories: - --bindir=DIR user executables [EPREFIX/bin] - --sbindir=DIR system admin executables [EPREFIX/sbin] - --libexecdir=DIR program executables [EPREFIX/libexec] - --sysconfdir=DIR read-only single-machine data [PREFIX/etc] - --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] - --localstatedir=DIR modifiable single-machine data [PREFIX/var] - --libdir=DIR object code libraries [EPREFIX/lib] - --includedir=DIR C header files [PREFIX/include] - --oldincludedir=DIR C header files for non-gcc [/usr/include] - --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] - --datadir=DIR read-only architecture-independent data [DATAROOTDIR] - --infodir=DIR info documentation [DATAROOTDIR/info] - --localedir=DIR locale-dependent data [DATAROOTDIR/locale] - --mandir=DIR man documentation [DATAROOTDIR/man] - --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE] - --htmldir=DIR html documentation [DOCDIR] - --dvidir=DIR dvi documentation [DOCDIR] - --pdfdir=DIR pdf documentation [DOCDIR] - --psdir=DIR ps documentation [DOCDIR] -_ACEOF - - cat <<\_ACEOF - -Program names: - --program-prefix=PREFIX prepend PREFIX to installed program names - --program-suffix=SUFFIX append SUFFIX to installed program names - --program-transform-name=PROGRAM run sed PROGRAM on installed program names - -System types: - --build=BUILD configure for building on BUILD [guessed] - --host=HOST cross-compile to build programs to run on HOST [BUILD] - --target=TARGET configure for building compilers for TARGET [HOST] -_ACEOF -fi - -if test -n "$ac_init_help"; then - - cat <<\_ACEOF - -Optional Features: - --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) - --enable-FEATURE[=ARG] include FEATURE [ARG=yes] - --enable-frame-address use GCC __builtin_frame_address(). - --disable-largefile omit support for large files - --enable-pthread use pthread library. - --disable-fastthread do not use the fastthread mutex - --enable-setreuid use setreuid()/setregid() according to need even if obsolete. - --disable-rpath embed run path into extension libraries. - --enable-shared build a shared library for Ruby. - --enable-install-doc build and install rdoc indexes during install - -Optional Packages: - --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] - --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) - --without-gcc never use gcc - --with-winsock2 link winsock2 (MinGW only) - --with-libc_r link libc_r if possible (FreeBSD only) - --with-setjmp-type select setjmp type - --with-default-kcode=CODE specify default value for \$KCODE (utf8|euc|sjis|none) - --with-dln-a-out use dln_a_out if possible - --with-static-linked-ext link external modules statically - --with-sitedir=DIR site libraries in DIR [LIBDIR/ruby/site_ruby] - --with-vendordir=DIR vendor libraries in DIR [LIBDIR/ruby/vendor_ruby] - --with-search-path=DIR specify the additional search path - --with-mantype=TYPE specify man page type; TYPE is one of man and doc - -Some influential environment variables: - CC C compiler command - CFLAGS C compiler flags - LDFLAGS linker flags, e.g. -L if you have libraries in a - nonstandard directory - LIBS libraries to pass to the linker, e.g. -l - CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I if - you have headers in a nonstandard directory - CPP C preprocessor - YACC The `Yet Another C Compiler' implementation to use. Defaults to - the first program found out of: `bison -y', `byacc', `yacc'. - YFLAGS The list of arguments that will be passed by default to $YACC. - This script will default YFLAGS to the empty string to avoid a - default value of `-d' given by some make applications. - -Use these variables to override the choices made by `configure' or to help -it to find libraries and programs with nonstandard names/locations. - -_ACEOF -ac_status=$? -fi - -if test "$ac_init_help" = "recursive"; then - # If there are subdirs, report their specific --help. - for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue - test -d "$ac_dir" || continue - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - cd "$ac_dir" || { ac_status=$?; continue; } - # Check for guested configure. - if test -f "$ac_srcdir/configure.gnu"; then - echo && - $SHELL "$ac_srcdir/configure.gnu" --help=recursive - elif test -f "$ac_srcdir/configure"; then - echo && - $SHELL "$ac_srcdir/configure" --help=recursive - else - echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 - fi || ac_status=$? - cd "$ac_pwd" || { ac_status=$?; break; } - done -fi - -test -n "$ac_init_help" && exit $ac_status -if $ac_init_version; then - cat <<\_ACEOF -configure -generated by GNU Autoconf 2.61 - -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, -2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. -This configure script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it. -_ACEOF - exit -fi -cat >config.log <<_ACEOF -This file contains any messages produced by compilers while -running configure, to aid debugging if configure makes a mistake. - -It was created by $as_me, which was -generated by GNU Autoconf 2.61. Invocation command line was - - $ $0 $@ - -_ACEOF -exec 5>>config.log -{ -cat <<_ASUNAME -## --------- ## -## Platform. ## -## --------- ## - -hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` -uname -m = `(uname -m) 2>/dev/null || echo unknown` -uname -r = `(uname -r) 2>/dev/null || echo unknown` -uname -s = `(uname -s) 2>/dev/null || echo unknown` -uname -v = `(uname -v) 2>/dev/null || echo unknown` - -/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` -/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` - -/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` -/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` -/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` -/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` -/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` -/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` -/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` - -_ASUNAME - -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - echo "PATH: $as_dir" -done -IFS=$as_save_IFS - -} >&5 - -cat >&5 <<_ACEOF - - -## ----------- ## -## Core tests. ## -## ----------- ## - -_ACEOF - - -# Keep a trace of the command line. -# Strip out --no-create and --no-recursion so they do not pile up. -# Strip out --silent because we don't want to record it for future runs. -# Also quote any args containing shell meta-characters. -# Make two passes to allow for proper duplicate-argument suppression. -ac_configure_args= -ac_configure_args0= -ac_configure_args1= -ac_must_keep_next=false -for ac_pass in 1 2 -do - for ac_arg - do - case $ac_arg in - -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - continue ;; - *\'*) - ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - case $ac_pass in - 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;; - 2) - ac_configure_args1="$ac_configure_args1 '$ac_arg'" - if test $ac_must_keep_next = true; then - ac_must_keep_next=false # Got value, back to normal. - else - case $ac_arg in - *=* | --config-cache | -C | -disable-* | --disable-* \ - | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ - | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ - | -with-* | --with-* | -without-* | --without-* | --x) - case "$ac_configure_args0 " in - "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; - esac - ;; - -* ) ac_must_keep_next=true ;; - esac - fi - ac_configure_args="$ac_configure_args '$ac_arg'" - ;; - esac - done -done -$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; } -$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; } - -# When interrupted or exit'd, cleanup temporary files, and complete -# config.log. We remove comments because anyway the quotes in there -# would cause problems or look ugly. -# WARNING: Use '\'' to represent an apostrophe within the trap. -# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. -trap 'exit_status=$? - # Save into config.log some information that might help in debugging. - { - echo - - cat <<\_ASBOX -## ---------------- ## -## Cache variables. ## -## ---------------- ## -_ASBOX - echo - # The following way of writing the cache mishandles newlines in values, -( - for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5 -echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - *) $as_unset $ac_var ;; - esac ;; - esac - done - (set) 2>&1 | - case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - sed -n \ - "s/'\''/'\''\\\\'\'''\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" - ;; #( - *) - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) - echo - - cat <<\_ASBOX -## ----------------- ## -## Output variables. ## -## ----------------- ## -_ASBOX - echo - for ac_var in $ac_subst_vars - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - echo "$ac_var='\''$ac_val'\''" - done | sort - echo - - if test -n "$ac_subst_files"; then - cat <<\_ASBOX -## ------------------- ## -## File substitutions. ## -## ------------------- ## -_ASBOX - echo - for ac_var in $ac_subst_files - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - echo "$ac_var='\''$ac_val'\''" - done | sort - echo - fi - - if test -s confdefs.h; then - cat <<\_ASBOX -## ----------- ## -## confdefs.h. ## -## ----------- ## -_ASBOX - echo - cat confdefs.h - echo - fi - test "$ac_signal" != 0 && - echo "$as_me: caught signal $ac_signal" - echo "$as_me: exit $exit_status" - } >&5 - rm -f core *.core core.conftest.* && - rm -f -r conftest* confdefs* conf$$* $ac_clean_files && - exit $exit_status -' 0 -for ac_signal in 1 2 13 15; do - trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal -done -ac_signal=0 - -# confdefs.h avoids OS command line length limits that DEFS can exceed. -rm -f -r conftest* confdefs.h - -# Predefined preprocessor variables. - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_NAME "$PACKAGE_NAME" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_TARNAME "$PACKAGE_TARNAME" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_VERSION "$PACKAGE_VERSION" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_STRING "$PACKAGE_STRING" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" -_ACEOF - - -# Let the site file select an alternate cache file if it wants to. -# Prefer explicitly selected file to automatically selected ones. -if test -n "$CONFIG_SITE"; then - set x "$CONFIG_SITE" -elif test "x$prefix" != xNONE; then - set x "$prefix/share/config.site" "$prefix/etc/config.site" -else - set x "$ac_default_prefix/share/config.site" \ - "$ac_default_prefix/etc/config.site" -fi -shift -for ac_site_file -do - if test -r "$ac_site_file"; then - { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5 -echo "$as_me: loading site script $ac_site_file" >&6;} - sed 's/^/| /' "$ac_site_file" >&5 - . "$ac_site_file" - fi -done - -if test -r "$cache_file"; then - # Some versions of bash will fail to source /dev/null (special - # files actually), so we avoid doing that. - if test -f "$cache_file"; then - { echo "$as_me:$LINENO: loading cache $cache_file" >&5 -echo "$as_me: loading cache $cache_file" >&6;} - case $cache_file in - [\\/]* | ?:[\\/]* ) . "$cache_file";; - *) . "./$cache_file";; - esac - fi -else - { echo "$as_me:$LINENO: creating cache $cache_file" >&5 -echo "$as_me: creating cache $cache_file" >&6;} - >$cache_file -fi - -# Check that the precious variables saved in the cache have kept the same -# value. -ac_cache_corrupted=false -for ac_var in $ac_precious_vars; do - eval ac_old_set=\$ac_cv_env_${ac_var}_set - eval ac_new_set=\$ac_env_${ac_var}_set - eval ac_old_val=\$ac_cv_env_${ac_var}_value - eval ac_new_val=\$ac_env_${ac_var}_value - case $ac_old_set,$ac_new_set in - set,) - { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 -echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,set) - { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5 -echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,);; - *) - if test "x$ac_old_val" != "x$ac_new_val"; then - { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5 -echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} - { echo "$as_me:$LINENO: former value: $ac_old_val" >&5 -echo "$as_me: former value: $ac_old_val" >&2;} - { echo "$as_me:$LINENO: current value: $ac_new_val" >&5 -echo "$as_me: current value: $ac_new_val" >&2;} - ac_cache_corrupted=: - fi;; - esac - # Pass precious variables to config.status. - if test "$ac_new_set" = set; then - case $ac_new_val in - *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; - *) ac_arg=$ac_var=$ac_new_val ;; - esac - case " $ac_configure_args " in - *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. - *) ac_configure_args="$ac_configure_args '$ac_arg'" ;; - esac - fi -done -if $ac_cache_corrupted; then - { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5 -echo "$as_me: error: changes in the environment can compromise the build" >&2;} - { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 -echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;} - { (exit 1); exit 1; }; } -fi - - - - - - - - - - - - - - - - - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - - - - - - - - - - -unset GREP_OPTIONS -rb_version=`grep RUBY_VERSION $srcdir/version.h` -MAJOR=`expr "$rb_version" : '#define RUBY_VERSION "\([0-9][0-9]*\)\.[0-9][0-9]*\.[0-9][0-9]*"'` -MINOR=`expr "$rb_version" : '#define RUBY_VERSION "[0-9][0-9]*\.\([0-9][0-9]*\)\.[0-9][0-9]*"'` -TEENY=`expr "$rb_version" : '#define RUBY_VERSION "[0-9][0-9]*\.[0-9][0-9]*\.\([0-9][0-9]*\)"'` -if test "$MAJOR" = ""; then - { { echo "$as_me:$LINENO: error: could not determine MAJOR number from version.h" >&5 -echo "$as_me: error: could not determine MAJOR number from version.h" >&2;} - { (exit 1); exit 1; }; } -fi -if test "$MINOR" = ""; then - { { echo "$as_me:$LINENO: error: could not determine MINOR number from version.h" >&5 -echo "$as_me: error: could not determine MINOR number from version.h" >&2;} - { (exit 1); exit 1; }; } -fi -if test "$TEENY" = ""; then - { { echo "$as_me:$LINENO: error: could not determine TEENY number from version.h" >&5 -echo "$as_me: error: could not determine TEENY number from version.h" >&2;} - { (exit 1); exit 1; }; } -fi - - - - -# Check whether --with-gcc was given. -if test "${with_gcc+set}" = set; then - withval=$with_gcc; - case $withval in - no) : ${CC=cc} - ;; - yes) : ${CC=gcc} - ;; - *) CC=$withval - ;; - esac -fi - -if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC" -then - { { echo "$as_me:$LINENO: error: cached CC is different -- throw away $cache_file -(it is also a good idea to do 'make clean' before compiling)" >&5 -echo "$as_me: error: cached CC is different -- throw away $cache_file -(it is also a good idea to do 'make clean' before compiling)" >&2;} - { (exit 1); exit 1; }; } -fi - -if test "$program_prefix" = NONE; then - program_prefix= -fi -ac_aux_dir= -for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do - if test -f "$ac_dir/install-sh"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/install-sh -c" - break - elif test -f "$ac_dir/install.sh"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/install.sh -c" - break - elif test -f "$ac_dir/shtool"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/shtool install -c" - break - fi -done -if test -z "$ac_aux_dir"; then - { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&5 -echo "$as_me: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&2;} - { (exit 1); exit 1; }; } -fi - -# These three variables are undocumented and unsupported, -# and are intended to be withdrawn in a future Autoconf release. -# They can cause serious problems if a builder's source tree is in a directory -# whose full name contains unusual characters. -ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. -ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. -ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. - - -# Make sure we can run config.sub. -$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || - { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5 -echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;} - { (exit 1); exit 1; }; } - -{ echo "$as_me:$LINENO: checking build system type" >&5 -echo $ECHO_N "checking build system type... $ECHO_C" >&6; } -if test "${ac_cv_build+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_build_alias=$build_alias -test "x$ac_build_alias" = x && - ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` -test "x$ac_build_alias" = x && - { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5 -echo "$as_me: error: cannot guess build type; you must specify one" >&2;} - { (exit 1); exit 1; }; } -ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || - { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5 -echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;} - { (exit 1); exit 1; }; } - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_build" >&5 -echo "${ECHO_T}$ac_cv_build" >&6; } -case $ac_cv_build in -*-*-*) ;; -*) { { echo "$as_me:$LINENO: error: invalid value of canonical build" >&5 -echo "$as_me: error: invalid value of canonical build" >&2;} - { (exit 1); exit 1; }; };; -esac -build=$ac_cv_build -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_build -shift -build_cpu=$1 -build_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -build_os=$* -IFS=$ac_save_IFS -case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac - - -{ echo "$as_me:$LINENO: checking host system type" >&5 -echo $ECHO_N "checking host system type... $ECHO_C" >&6; } -if test "${ac_cv_host+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "x$host_alias" = x; then - ac_cv_host=$ac_cv_build -else - ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || - { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5 -echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;} - { (exit 1); exit 1; }; } -fi - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_host" >&5 -echo "${ECHO_T}$ac_cv_host" >&6; } -case $ac_cv_host in -*-*-*) ;; -*) { { echo "$as_me:$LINENO: error: invalid value of canonical host" >&5 -echo "$as_me: error: invalid value of canonical host" >&2;} - { (exit 1); exit 1; }; };; -esac -host=$ac_cv_host -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_host -shift -host_cpu=$1 -host_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -host_os=$* -IFS=$ac_save_IFS -case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac - - -{ echo "$as_me:$LINENO: checking target system type" >&5 -echo $ECHO_N "checking target system type... $ECHO_C" >&6; } -if test "${ac_cv_target+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "x$target_alias" = x; then - ac_cv_target=$ac_cv_host -else - ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || - { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $target_alias failed" >&5 -echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $target_alias failed" >&2;} - { (exit 1); exit 1; }; } -fi - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_target" >&5 -echo "${ECHO_T}$ac_cv_target" >&6; } -case $ac_cv_target in -*-*-*) ;; -*) { { echo "$as_me:$LINENO: error: invalid value of canonical target" >&5 -echo "$as_me: error: invalid value of canonical target" >&2;} - { (exit 1); exit 1; }; };; -esac -target=$ac_cv_target -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_target -shift -target_cpu=$1 -target_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -target_os=$* -IFS=$ac_save_IFS -case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac - - -# The aliases save the names the user supplied, while $host etc. -# will get canonicalized. -test -n "$target_alias" && - test "$program_prefix$program_suffix$program_transform_name" = \ - NONENONEs,x,x, && - program_prefix=${target_alias}- -target_os=`echo $target_os | sed 's/linux-gnu$/linux/;s/linux-gnu/linux-/'` -ac_install_sh='' # unusable for extension libraries. - -fat_binary=no - -case $target_cpu in - i?86) frame_address=yes;; - *) frame_address=no;; -esac -# Check whether --enable-frame-address was given. -if test "${enable_frame_address+set}" = set; then - enableval=$enable_frame_address; frame_address=$enableval -fi - -if test $frame_address = yes; then - cat >>confdefs.h <<\_ACEOF -#define USE_BUILTIN_FRAME_ADDRESS 1 -_ACEOF - -fi - -test "$program_prefix" != NONE && - program_transform_name="s&^&$program_prefix&;$program_transform_name" -# Use a double $ so make ignores it. -test "$program_suffix" != NONE && - program_transform_name="s&\$&$program_suffix&;$program_transform_name" -# Double any \ or $. echo might interpret backslashes. -# By default was `s,x,x', remove it if useless. -cat <<\_ACEOF >conftest.sed -s/[\\$]/&&/g;s/;s,x,x,$// -_ACEOF -program_transform_name=`echo $program_transform_name | sed -f conftest.sed` -rm -f conftest.sed - - - -if test x"${build}" != x"${host}"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. -set dummy ${ac_tool_prefix}gcc; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_CC="${ac_tool_prefix}gcc" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { echo "$as_me:$LINENO: result: $CC" >&5 -echo "${ECHO_T}$CC" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "gcc", so it can be a program name with args. -set dummy gcc; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_CC="gcc" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 -echo "${ECHO_T}$ac_ct_CC" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&5 -echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -else - CC="$ac_cv_prog_CC" -fi - -fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. -set dummy ${ac_tool_prefix}gcc; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_CC="${ac_tool_prefix}gcc" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { echo "$as_me:$LINENO: result: $CC" >&5 -echo "${ECHO_T}$CC" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "gcc", so it can be a program name with args. -set dummy gcc; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_CC="gcc" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 -echo "${ECHO_T}$ac_ct_CC" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&5 -echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -else - CC="$ac_cv_prog_CC" -fi - -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. -set dummy ${ac_tool_prefix}cc; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_CC="${ac_tool_prefix}cc" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { echo "$as_me:$LINENO: result: $CC" >&5 -echo "${ECHO_T}$CC" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - - fi -fi -if test -z "$CC"; then - # Extract the first word of "cc", so it can be a program name with args. -set dummy cc; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else - ac_prog_rejected=no -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then - ac_prog_rejected=yes - continue - fi - ac_cv_prog_CC="cc" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -if test $ac_prog_rejected = yes; then - # We found a bogon in the path, so make sure we never use it. - set dummy $ac_cv_prog_CC - shift - if test $# != 0; then - # We chose a different compiler from the bogus one. - # However, it has the same basename, so the bogon will be chosen - # first if we set CC to just the basename; use the full file name. - shift - ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" - fi -fi -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { echo "$as_me:$LINENO: result: $CC" >&5 -echo "${ECHO_T}$CC" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - -fi -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - for ac_prog in cl.exe - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_CC="$ac_tool_prefix$ac_prog" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { echo "$as_me:$LINENO: result: $CC" >&5 -echo "${ECHO_T}$CC" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - - test -n "$CC" && break - done -fi -if test -z "$CC"; then - ac_ct_CC=$CC - for ac_prog in cl.exe -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_CC="$ac_prog" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 -echo "${ECHO_T}$ac_ct_CC" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - - test -n "$ac_ct_CC" && break -done - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&5 -echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -fi - -fi - - -test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH -See \`config.log' for more details." >&5 -echo "$as_me: error: no acceptable C compiler found in \$PATH -See \`config.log' for more details." >&2;} - { (exit 1); exit 1; }; } - -# Provide some information about the compiler. -echo "$as_me:$LINENO: checking for C compiler version" >&5 -ac_compiler=`set X $ac_compile; echo $2` -{ (ac_try="$ac_compiler --version >&5" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compiler --version >&5") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } -{ (ac_try="$ac_compiler -v >&5" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compiler -v >&5") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } -{ (ac_try="$ac_compiler -V >&5" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compiler -V >&5") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } - -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files a.out a.exe b.out" -# Try to create an executable without -o first, disregard a.out. -# It will help us diagnose broken compilers, and finding out an intuition -# of exeext. -{ echo "$as_me:$LINENO: checking for C compiler default output file name" >&5 -echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; } -ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` -# -# List of possible output files, starting from the most likely. -# The algorithm is not robust to junk in `.', hence go to wildcards (a.*) -# only as a last resort. b.out is created by i960 compilers. -ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out' -# -# The IRIX 6 linker writes into existing files which may not be -# executable, retaining their permissions. Remove them first so a -# subsequent execution test works. -ac_rmfiles= -for ac_file in $ac_files -do - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; - * ) ac_rmfiles="$ac_rmfiles $ac_file";; - esac -done -rm -f $ac_rmfiles - -if { (ac_try="$ac_link_default" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link_default") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. -# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' -# in a Makefile. We should not override ac_cv_exeext if it was cached, -# so that the user can short-circuit this test for compilers unknown to -# Autoconf. -for ac_file in $ac_files '' -do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) - ;; - [ab].out ) - # We found the default executable, but exeext='' is most - # certainly right. - break;; - *.* ) - if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; - then :; else - ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - fi - # We set ac_cv_exeext here because the later test for it is not - # safe: cross compilers may not add the suffix if given an `-o' - # argument, so we may need to know it at that point already. - # Even if this section looks crufty: it has the advantage of - # actually working. - break;; - * ) - break;; - esac -done -test "$ac_cv_exeext" = no && ac_cv_exeext= - -else - ac_file='' -fi - -{ echo "$as_me:$LINENO: result: $ac_file" >&5 -echo "${ECHO_T}$ac_file" >&6; } -if test -z "$ac_file"; then - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { echo "$as_me:$LINENO: error: C compiler cannot create executables -See \`config.log' for more details." >&5 -echo "$as_me: error: C compiler cannot create executables -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } -fi - -ac_exeext=$ac_cv_exeext - -# Check that the compiler produces executables we can run. If not, either -# the compiler is broken, or we cross compile. -{ echo "$as_me:$LINENO: checking whether the C compiler works" >&5 -echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; } -# FIXME: These cross compiler hacks should be removed for Autoconf 3.0 -# If not cross compiling, check that we can run a simple program. -if test "$cross_compiling" != yes; then - if { ac_try='./$ac_file' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - cross_compiling=no - else - if test "$cross_compiling" = maybe; then - cross_compiling=yes - else - { { echo "$as_me:$LINENO: error: cannot run C compiled programs. -If you meant to cross compile, use \`--host'. -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot run C compiled programs. -If you meant to cross compile, use \`--host'. -See \`config.log' for more details." >&2;} - { (exit 1); exit 1; }; } - fi - fi -fi -{ echo "$as_me:$LINENO: result: yes" >&5 -echo "${ECHO_T}yes" >&6; } - -rm -f a.out a.exe conftest$ac_cv_exeext b.out -ac_clean_files=$ac_clean_files_save -# Check that the compiler produces executables we can run. If not, either -# the compiler is broken, or we cross compile. -{ echo "$as_me:$LINENO: checking whether we are cross compiling" >&5 -echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; } -{ echo "$as_me:$LINENO: result: $cross_compiling" >&5 -echo "${ECHO_T}$cross_compiling" >&6; } - -{ echo "$as_me:$LINENO: checking for suffix of executables" >&5 -echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; } -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - # If both `conftest.exe' and `conftest' are `present' (well, observable) -# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will -# work properly (i.e., refer to `conftest.exe'), while it won't with -# `rm'. -for ac_file in conftest.exe conftest conftest.*; do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; - *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - break;; - * ) break;; - esac -done -else - { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute suffix of executables: cannot compile and link -See \`config.log' for more details." >&2;} - { (exit 1); exit 1; }; } -fi - -rm -f conftest$ac_cv_exeext -{ echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5 -echo "${ECHO_T}$ac_cv_exeext" >&6; } - -rm -f conftest.$ac_ext -EXEEXT=$ac_cv_exeext -ac_exeext=$EXEEXT -{ echo "$as_me:$LINENO: checking for suffix of object files" >&5 -echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; } -if test "${ac_cv_objext+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.o conftest.obj -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - for ac_file in conftest.o conftest.obj conftest.*; do - test -f "$ac_file" || continue; - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;; - *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` - break;; - esac -done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute suffix of object files: cannot compile -See \`config.log' for more details." >&2;} - { (exit 1); exit 1; }; } -fi - -rm -f conftest.$ac_cv_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_objext" >&5 -echo "${ECHO_T}$ac_cv_objext" >&6; } -OBJEXT=$ac_cv_objext -ac_objext=$OBJEXT -{ echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5 -echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; } -if test "${ac_cv_c_compiler_gnu+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -int -main () -{ -#ifndef __GNUC__ - choke me -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_compiler_gnu=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_compiler_gnu=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -ac_cv_c_compiler_gnu=$ac_compiler_gnu - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5 -echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; } -GCC=`test $ac_compiler_gnu = yes && echo yes` -ac_test_CFLAGS=${CFLAGS+set} -ac_save_CFLAGS=$CFLAGS -{ echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5 -echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; } -if test "${ac_cv_prog_cc_g+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_save_c_werror_flag=$ac_c_werror_flag - ac_c_werror_flag=yes - ac_cv_prog_cc_g=no - CFLAGS="-g" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_prog_cc_g=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - CFLAGS="" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_c_werror_flag=$ac_save_c_werror_flag - CFLAGS="-g" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_prog_cc_g=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_c_werror_flag=$ac_save_c_werror_flag -fi -{ echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5 -echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; } -if test "$ac_test_CFLAGS" = set; then - CFLAGS=$ac_save_CFLAGS -elif test $ac_cv_prog_cc_g = yes; then - if test "$GCC" = yes; then - CFLAGS="-g -O2" - else - CFLAGS="-g" - fi -else - if test "$GCC" = yes; then - CFLAGS="-O2" - else - CFLAGS= - fi -fi -{ echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5 -echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; } -if test "${ac_cv_prog_cc_c89+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_cv_prog_cc_c89=no -ac_save_CC=$CC -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include -#include -#include -/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ -struct buf { int x; }; -FILE * (*rcsopen) (struct buf *, struct stat *, int); -static char *e (p, i) - char **p; - int i; -{ - return p[i]; -} -static char *f (char * (*g) (char **, int), char **p, ...) -{ - char *s; - va_list v; - va_start (v,p); - s = g (p, va_arg (v,int)); - va_end (v); - return s; -} - -/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has - function prototypes and stuff, but not '\xHH' hex character constants. - These don't provoke an error unfortunately, instead are silently treated - as 'x'. The following induces an error, until -std is added to get - proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an - array size at least. It's necessary to write '\x00'==0 to get something - that's true only with -std. */ -int osf4_cc_array ['\x00' == 0 ? 1 : -1]; - -/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters - inside strings and character constants. */ -#define FOO(x) 'x' -int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; - -int test (int i, double x); -struct s1 {int (*f) (int a);}; -struct s2 {int (*f) (double a);}; -int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); -int argc; -char **argv; -int -main () -{ -return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; - ; - return 0; -} -_ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ - -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" -do - CC="$ac_save_CC $ac_arg" - rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_prog_cc_c89=$ac_arg -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c89" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC - -fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c89" in - x) - { echo "$as_me:$LINENO: result: none needed" >&5 -echo "${ECHO_T}none needed" >&6; } ;; - xno) - { echo "$as_me:$LINENO: result: unsupported" >&5 -echo "${ECHO_T}unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c89" - { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5 -echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;; -esac - - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5 -echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; } -# On Suns, sometimes $CPP names a directory. -if test -n "$CPP" && test -d "$CPP"; then - CPP= -fi -if test -z "$CPP"; then - if test "${ac_cv_prog_CPP+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - # Double quotes because CPP needs to be expanded - for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" - do - ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - : -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - # Broken: fails on valid input. -continue -fi - -rm -f conftest.err conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - # Broken: success on invalid input. -continue -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - # Passes both tests. -ac_preproc_ok=: -break -fi - -rm -f conftest.err conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext -if $ac_preproc_ok; then - break -fi - - done - ac_cv_prog_CPP=$CPP - -fi - CPP=$ac_cv_prog_CPP -else - ac_cv_prog_CPP=$CPP -fi -{ echo "$as_me:$LINENO: result: $CPP" >&5 -echo "${ECHO_T}$CPP" >&6; } -ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - : -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - # Broken: fails on valid input. -continue -fi - -rm -f conftest.err conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - # Broken: success on invalid input. -continue -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - # Passes both tests. -ac_preproc_ok=: -break -fi - -rm -f conftest.err conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext -if $ac_preproc_ok; then - : -else - { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details." >&5 -echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details." >&2;} - { (exit 1); exit 1; }; } -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -{ echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5 -echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; } -if test "${ac_cv_path_GREP+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - # Extract the first word of "grep ggrep" to use in msg output -if test -z "$GREP"; then -set dummy grep ggrep; ac_prog_name=$2 -if test "${ac_cv_path_GREP+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_path_GREP_found=false -# Loop through the user's path and test for each of PROGNAME-LIST -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in grep ggrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" - { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue - # Check for GNU ac_path_GREP and select it if it is found. - # Check for GNU $ac_path_GREP -case `"$ac_path_GREP" --version 2>&1` in -*GNU*) - ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; -*) - ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - echo 'GREP' >> "conftest.nl" - "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - ac_count=`expr $ac_count + 1` - if test $ac_count -gt ${ac_path_GREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_GREP="$ac_path_GREP" - ac_path_GREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - - $ac_path_GREP_found && break 3 - done -done - -done -IFS=$as_save_IFS - - -fi - -GREP="$ac_cv_path_GREP" -if test -z "$GREP"; then - { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 -echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} - { (exit 1); exit 1; }; } -fi - -else - ac_cv_path_GREP=$GREP -fi - - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5 -echo "${ECHO_T}$ac_cv_path_GREP" >&6; } - GREP="$ac_cv_path_GREP" - - -{ echo "$as_me:$LINENO: checking for egrep" >&5 -echo $ECHO_N "checking for egrep... $ECHO_C" >&6; } -if test "${ac_cv_path_EGREP+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 - then ac_cv_path_EGREP="$GREP -E" - else - # Extract the first word of "egrep" to use in msg output -if test -z "$EGREP"; then -set dummy egrep; ac_prog_name=$2 -if test "${ac_cv_path_EGREP+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_path_EGREP_found=false -# Loop through the user's path and test for each of PROGNAME-LIST -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in egrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" - { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue - # Check for GNU ac_path_EGREP and select it if it is found. - # Check for GNU $ac_path_EGREP -case `"$ac_path_EGREP" --version 2>&1` in -*GNU*) - ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; -*) - ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - echo 'EGREP' >> "conftest.nl" - "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - ac_count=`expr $ac_count + 1` - if test $ac_count -gt ${ac_path_EGREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_EGREP="$ac_path_EGREP" - ac_path_EGREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - - $ac_path_EGREP_found && break 3 - done -done - -done -IFS=$as_save_IFS - - -fi - -EGREP="$ac_cv_path_EGREP" -if test -z "$EGREP"; then - { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 -echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} - { (exit 1); exit 1; }; } -fi - -else - ac_cv_path_EGREP=$EGREP -fi - - - fi -fi -{ echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5 -echo "${ECHO_T}$ac_cv_path_EGREP" >&6; } - EGREP="$ac_cv_path_EGREP" - - -if test $ac_cv_c_compiler_gnu = yes; then - { echo "$as_me:$LINENO: checking whether $CC needs -traditional" >&5 -echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6; } -if test "${ac_cv_prog_gcc_traditional+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_pattern="Autoconf.*'x'" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -Autoconf TIOCGETP -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "$ac_pattern" >/dev/null 2>&1; then - ac_cv_prog_gcc_traditional=yes -else - ac_cv_prog_gcc_traditional=no -fi -rm -f conftest* - - - if test $ac_cv_prog_gcc_traditional = no; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -Autoconf TCGETA -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "$ac_pattern" >/dev/null 2>&1; then - ac_cv_prog_gcc_traditional=yes -fi -rm -f conftest* - - fi -fi -{ echo "$as_me:$LINENO: result: $ac_cv_prog_gcc_traditional" >&5 -echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6; } - if test $ac_cv_prog_gcc_traditional = yes; then - CC="$CC -traditional" - fi -fi - -if test "$GCC" = yes; then - linker_flag=-Wl, -else - linker_flag= -fi - -{ echo "$as_me:$LINENO: checking whether the linker is GNU ld" >&5 -echo $ECHO_N "checking whether the linker is GNU ld... $ECHO_C" >&6; } -if test "${rb_cv_prog_gnu_ld+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if `$CC $CFLAGS $CPPFLAGS $LDFLAGS --print-prog-name=ld 2>&1` -v 2>&1 | grep "GNU ld" > /dev/null; then - rb_cv_prog_gnu_ld=yes -else - rb_cv_prog_gnu_ld=no -fi - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_prog_gnu_ld" >&5 -echo "${ECHO_T}$rb_cv_prog_gnu_ld" >&6; } -GNU_LD=$rb_cv_prog_gnu_ld - -{ echo "$as_me:$LINENO: checking whether ${CPP} accepts -o" >&5 -echo $ECHO_N "checking whether ${CPP} accepts -o... $ECHO_C" >&6; } -if test "${rb_cv_cppoutfile+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cppflags=$CPPFLAGS -CPPFLAGS='-o conftest.i' -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - rb_cv_cppoutfile=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_cppoutfile=no -fi - -rm -f conftest.err conftest.$ac_ext -CPPFLAGS=$cppflags -rm -f conftest* -fi -{ echo "$as_me:$LINENO: result: $rb_cv_cppoutfile" >&5 -echo "${ECHO_T}$rb_cv_cppoutfile" >&6; } -if test "$rb_cv_cppoutfile" = yes; then - CPPOUTFILE='-o conftest.i' -elif test "$rb_cv_cppoutfile" = no; then - CPPOUTFILE='> conftest.i' -elif test -n "$rb_cv_cppoutfile"; then - CPPOUTFILE="$rb_cv_cppoutfile" -fi - - -: ${OUTFLAG='-o '} - - -case "$host_os" in -cygwin*) -{ echo "$as_me:$LINENO: checking for mingw32 environment" >&5 -echo $ECHO_N "checking for mingw32 environment... $ECHO_C" >&6; } -if test "${rb_cv_mingw32+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#ifndef __MINGW32__ -# error -#endif - -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - rb_cv_mingw32=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_mingw32=no -fi - -rm -f conftest.err conftest.$ac_ext -rm -f conftest* -fi -{ echo "$as_me:$LINENO: result: $rb_cv_mingw32" >&5 -echo "${ECHO_T}$rb_cv_mingw32" >&6; } -test "$rb_cv_mingw32" = yes && target_os="mingw32" - ;; -esac - -for ac_prog in 'bison -y' byacc -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_YACC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$YACC"; then - ac_cv_prog_YACC="$YACC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_YACC="$ac_prog" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -YACC=$ac_cv_prog_YACC -if test -n "$YACC"; then - { echo "$as_me:$LINENO: result: $YACC" >&5 -echo "${ECHO_T}$YACC" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - - test -n "$YACC" && break -done -test -n "$YACC" || YACC="yacc" - -if test "$YACC" = "yacc"; then - cat >>confdefs.h <<\_ACEOF -#define OLD_YACC 1 -_ACEOF - -fi - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. -set dummy ${ac_tool_prefix}ranlib; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_RANLIB+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$RANLIB"; then - ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -RANLIB=$ac_cv_prog_RANLIB -if test -n "$RANLIB"; then - { echo "$as_me:$LINENO: result: $RANLIB" >&5 -echo "${ECHO_T}$RANLIB" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_RANLIB"; then - ac_ct_RANLIB=$RANLIB - # Extract the first word of "ranlib", so it can be a program name with args. -set dummy ranlib; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$ac_ct_RANLIB"; then - ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_RANLIB="ranlib" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB -if test -n "$ac_ct_RANLIB"; then - { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5 -echo "${ECHO_T}$ac_ct_RANLIB" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - if test "x$ac_ct_RANLIB" = x; then - RANLIB=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&5 -echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&2;} -ac_tool_warned=yes ;; -esac - RANLIB=$ac_ct_RANLIB - fi -else - RANLIB="$ac_cv_prog_RANLIB" -fi - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. -set dummy ${ac_tool_prefix}ar; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_AR+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$AR"; then - ac_cv_prog_AR="$AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_AR="${ac_tool_prefix}ar" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -AR=$ac_cv_prog_AR -if test -n "$AR"; then - { echo "$as_me:$LINENO: result: $AR" >&5 -echo "${ECHO_T}$AR" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_AR"; then - ac_ct_AR=$AR - # Extract the first word of "ar", so it can be a program name with args. -set dummy ar; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_ac_ct_AR+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$ac_ct_AR"; then - ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_AR="ar" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -ac_ct_AR=$ac_cv_prog_ac_ct_AR -if test -n "$ac_ct_AR"; then - { echo "$as_me:$LINENO: result: $ac_ct_AR" >&5 -echo "${ECHO_T}$ac_ct_AR" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - if test "x$ac_ct_AR" = x; then - AR="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&5 -echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&2;} -ac_tool_warned=yes ;; -esac - AR=$ac_ct_AR - fi -else - AR="$ac_cv_prog_AR" -fi - -if test -z "$AR"; then - for ac_prog in aal -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_AR+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$AR"; then - ac_cv_prog_AR="$AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_AR="$ac_prog" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -AR=$ac_cv_prog_AR -if test -n "$AR"; then - { echo "$as_me:$LINENO: result: $AR" >&5 -echo "${ECHO_T}$AR" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - - test -n "$AR" && break -done -test -n "$AR" || AR="ar" - -fi - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args. -set dummy ${ac_tool_prefix}as; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_AS+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$AS"; then - ac_cv_prog_AS="$AS" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_AS="${ac_tool_prefix}as" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -AS=$ac_cv_prog_AS -if test -n "$AS"; then - { echo "$as_me:$LINENO: result: $AS" >&5 -echo "${ECHO_T}$AS" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_AS"; then - ac_ct_AS=$AS - # Extract the first word of "as", so it can be a program name with args. -set dummy as; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_ac_ct_AS+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$ac_ct_AS"; then - ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_AS="as" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -ac_ct_AS=$ac_cv_prog_ac_ct_AS -if test -n "$ac_ct_AS"; then - { echo "$as_me:$LINENO: result: $ac_ct_AS" >&5 -echo "${ECHO_T}$ac_ct_AS" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - if test "x$ac_ct_AS" = x; then - AS="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&5 -echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&2;} -ac_tool_warned=yes ;; -esac - AS=$ac_ct_AS - fi -else - AS="$ac_cv_prog_AS" -fi - -ASFLAGS=$ASFLAGS - - -case "$target_os" in -cygwin*|mingw*) - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}nm", so it can be a program name with args. -set dummy ${ac_tool_prefix}nm; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_NM+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$NM"; then - ac_cv_prog_NM="$NM" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_NM="${ac_tool_prefix}nm" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -NM=$ac_cv_prog_NM -if test -n "$NM"; then - { echo "$as_me:$LINENO: result: $NM" >&5 -echo "${ECHO_T}$NM" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_NM"; then - ac_ct_NM=$NM - # Extract the first word of "nm", so it can be a program name with args. -set dummy nm; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_ac_ct_NM+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$ac_ct_NM"; then - ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_NM="nm" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -ac_ct_NM=$ac_cv_prog_ac_ct_NM -if test -n "$ac_ct_NM"; then - { echo "$as_me:$LINENO: result: $ac_ct_NM" >&5 -echo "${ECHO_T}$ac_ct_NM" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - if test "x$ac_ct_NM" = x; then - NM="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&5 -echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&2;} -ac_tool_warned=yes ;; -esac - NM=$ac_ct_NM - fi -else - NM="$ac_cv_prog_NM" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args. -set dummy ${ac_tool_prefix}windres; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_WINDRES+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$WINDRES"; then - ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_WINDRES="${ac_tool_prefix}windres" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -WINDRES=$ac_cv_prog_WINDRES -if test -n "$WINDRES"; then - { echo "$as_me:$LINENO: result: $WINDRES" >&5 -echo "${ECHO_T}$WINDRES" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_WINDRES"; then - ac_ct_WINDRES=$WINDRES - # Extract the first word of "windres", so it can be a program name with args. -set dummy windres; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$ac_ct_WINDRES"; then - ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_WINDRES="windres" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES -if test -n "$ac_ct_WINDRES"; then - { echo "$as_me:$LINENO: result: $ac_ct_WINDRES" >&5 -echo "${ECHO_T}$ac_ct_WINDRES" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - if test "x$ac_ct_WINDRES" = x; then - WINDRES="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&5 -echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&2;} -ac_tool_warned=yes ;; -esac - WINDRES=$ac_ct_WINDRES - fi -else - WINDRES="$ac_cv_prog_WINDRES" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args. -set dummy ${ac_tool_prefix}dllwrap; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_DLLWRAP+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$DLLWRAP"; then - ac_cv_prog_DLLWRAP="$DLLWRAP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -DLLWRAP=$ac_cv_prog_DLLWRAP -if test -n "$DLLWRAP"; then - { echo "$as_me:$LINENO: result: $DLLWRAP" >&5 -echo "${ECHO_T}$DLLWRAP" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_DLLWRAP"; then - ac_ct_DLLWRAP=$DLLWRAP - # Extract the first word of "dllwrap", so it can be a program name with args. -set dummy dllwrap; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_ac_ct_DLLWRAP+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$ac_ct_DLLWRAP"; then - ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_DLLWRAP="dllwrap" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP -if test -n "$ac_ct_DLLWRAP"; then - { echo "$as_me:$LINENO: result: $ac_ct_DLLWRAP" >&5 -echo "${ECHO_T}$ac_ct_DLLWRAP" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - if test "x$ac_ct_DLLWRAP" = x; then - DLLWRAP="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&5 -echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&2;} -ac_tool_warned=yes ;; -esac - DLLWRAP=$ac_ct_DLLWRAP - fi -else - DLLWRAP="$ac_cv_prog_DLLWRAP" -fi - - target_cpu=`echo $target_cpu | sed s/i.86/i386/` - case "$target_os" in - mingw*) - test "$rb_cv_msvcrt" = "" && unset rb_cv_msvcrt - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. -set dummy ${ac_tool_prefix}objdump; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_OBJDUMP+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$OBJDUMP"; then - ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -OBJDUMP=$ac_cv_prog_OBJDUMP -if test -n "$OBJDUMP"; then - { echo "$as_me:$LINENO: result: $OBJDUMP" >&5 -echo "${ECHO_T}$OBJDUMP" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OBJDUMP"; then - ac_ct_OBJDUMP=$OBJDUMP - # Extract the first word of "objdump", so it can be a program name with args. -set dummy objdump; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_ac_ct_OBJDUMP+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$ac_ct_OBJDUMP"; then - ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_OBJDUMP="objdump" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP -if test -n "$ac_ct_OBJDUMP"; then - { echo "$as_me:$LINENO: result: $ac_ct_OBJDUMP" >&5 -echo "${ECHO_T}$ac_ct_OBJDUMP" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - if test "x$ac_ct_OBJDUMP" = x; then - OBJDUMP="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&5 -echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&2;} -ac_tool_warned=yes ;; -esac - OBJDUMP=$ac_ct_OBJDUMP - fi -else - OBJDUMP="$ac_cv_prog_OBJDUMP" -fi - - { echo "$as_me:$LINENO: checking for mingw32 runtime DLL" >&5 -echo $ECHO_N "checking for mingw32 runtime DLL... $ECHO_C" >&6; } -if test "${rb_cv_msvcrt+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ -FILE* volatile f = stdin; return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - rb_cv_msvcrt=`$OBJDUMP -p conftest$ac_exeext | - tr A-Z a-z | - sed -n '/^[ ]*dll name: \(msvc.*\)\.dll$/{s//\1/p;q;}'` -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_msvcrt=msvcrt -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext - test "$rb_cv_msvcrt" = "" && rb_cv_msvcrt=msvcrt -fi -{ echo "$as_me:$LINENO: result: $rb_cv_msvcrt" >&5 -echo "${ECHO_T}$rb_cv_msvcrt" >&6; } - -# Check whether --with-winsock2 was given. -if test "${with_winsock2+set}" = set; then - withval=$with_winsock2; - case $withval in - yes) with_winsock2=yes;; - *) with_winsock2=no;; - esac -else - with_winsock2=no -fi - - if test "$with_winsock2" = yes; then - cat >>confdefs.h <<\_ACEOF -#define USE_WINSOCK2 1 -_ACEOF - - fi - esac - : ${enable_shared=yes} - ;; -aix*) - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}nm", so it can be a program name with args. -set dummy ${ac_tool_prefix}nm; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_NM+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$NM"; then - ac_cv_prog_NM="$NM" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_dummy="/usr/ccs/bin:$PATH" -for as_dir in $as_dummy -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_NM="${ac_tool_prefix}nm" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -NM=$ac_cv_prog_NM -if test -n "$NM"; then - { echo "$as_me:$LINENO: result: $NM" >&5 -echo "${ECHO_T}$NM" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_NM"; then - ac_ct_NM=$NM - # Extract the first word of "nm", so it can be a program name with args. -set dummy nm; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_prog_ac_ct_NM+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$ac_ct_NM"; then - ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_dummy="/usr/ccs/bin:$PATH" -for as_dir in $as_dummy -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_NM="nm" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -ac_ct_NM=$ac_cv_prog_ac_ct_NM -if test -n "$ac_ct_NM"; then - { echo "$as_me:$LINENO: result: $ac_ct_NM" >&5 -echo "${ECHO_T}$ac_ct_NM" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - if test "x$ac_ct_NM" = x; then - NM="/usr/ccs/bin/nm" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&5 -echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&2;} -ac_tool_warned=yes ;; -esac - NM=$ac_ct_NM - fi -else - NM="$ac_cv_prog_NM" -fi - - ;; -hiuxmpp*) - # by TOYODA Eizi - cat >>confdefs.h <<\_ACEOF -#define __HIUX_MPP__ 1 -_ACEOF - - ;; -esac - -{ echo "$as_me:$LINENO: checking whether ln -s works" >&5 -echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6; } -LN_S=$as_ln_s -if test "$LN_S" = "ln -s"; then - { echo "$as_me:$LINENO: result: yes" >&5 -echo "${ECHO_T}yes" >&6; } -else - { echo "$as_me:$LINENO: result: no, using $LN_S" >&5 -echo "${ECHO_T}no, using $LN_S" >&6; } -fi - -{ echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5 -echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6; } -set x ${MAKE-make}; ac_make=`echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` -if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.make <<\_ACEOF -SHELL = /bin/sh -all: - @echo '@@@%%%=$(MAKE)=@@@%%%' -_ACEOF -# GNU make sometimes prints "make[1]: Entering...", which would confuse us. -case `${MAKE-make} -f conftest.make 2>/dev/null` in - *@@@%%%=?*=@@@%%%*) - eval ac_cv_prog_make_${ac_make}_set=yes;; - *) - eval ac_cv_prog_make_${ac_make}_set=no;; -esac -rm -f conftest.make -fi -if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then - { echo "$as_me:$LINENO: result: yes" >&5 -echo "${ECHO_T}yes" >&6; } - SET_MAKE= -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } - SET_MAKE="MAKE=${MAKE-make}" -fi - -# Find a good install program. We prefer a C program (faster), -# so one script is as good as another. But avoid the broken or -# incompatible versions: -# SysV /etc/install, /usr/sbin/install -# SunOS /usr/etc/install -# IRIX /sbin/install -# AIX /bin/install -# AmigaOS /C/install, which installs bootblocks on floppy discs -# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag -# AFS /usr/afsws/bin/install, which mishandles nonexistent args -# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" -# OS/2's system install, which has a completely different semantic -# ./install, which can be erroneously created by make from ./install.sh. -{ echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5 -echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6; } -if test -z "$INSTALL"; then -if test "${ac_cv_path_install+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - # Account for people who put trailing slashes in PATH elements. -case $as_dir/ in - ./ | .// | /cC/* | \ - /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ - ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \ - /usr/ucb/* ) ;; - *) - # OSF1 and SCO ODT 3.0 have their own names for install. - # Don't use installbsd from OSF since it installs stuff as root - # by default. - for ac_prog in ginstall scoinst install; do - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then - if test $ac_prog = install && - grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # AIX install. It has an incompatible calling convention. - : - elif test $ac_prog = install && - grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # program-specific install script used by HP pwplus--don't use. - : - else - ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" - break 3 - fi - fi - done - done - ;; -esac -done -IFS=$as_save_IFS - - -fi - if test "${ac_cv_path_install+set}" = set; then - INSTALL=$ac_cv_path_install - else - # As a last resort, use the slow shell script. Don't cache a - # value for INSTALL within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - INSTALL=$ac_install_sh - fi -fi -{ echo "$as_me:$LINENO: result: $INSTALL" >&5 -echo "${ECHO_T}$INSTALL" >&6; } - -# Use test -z because SunOS4 sh mishandles braces in ${var-val}. -# It thinks the first close brace ends the variable substitution. -test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' - -test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' - -test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' - - -# checks for UNIX variants that set C preprocessor variables - -{ echo "$as_me:$LINENO: checking for AIX" >&5 -echo $ECHO_N "checking for AIX... $ECHO_C" >&6; } -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#ifdef _AIX - yes -#endif - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then - { echo "$as_me:$LINENO: result: yes" >&5 -echo "${ECHO_T}yes" >&6; } -cat >>confdefs.h <<\_ACEOF -#define _ALL_SOURCE 1 -_ACEOF - -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi -rm -f conftest* - - -{ echo "$as_me:$LINENO: checking for ANSI C header files" >&5 -echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; } -if test "${ac_cv_header_stdc+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include -#include -#include - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_header_stdc=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_header_stdc=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then - : -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then - : -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then - : -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif - -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - : -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -fi -{ echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5 -echo "${ECHO_T}$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then - -cat >>confdefs.h <<\_ACEOF -#define STDC_HEADERS 1 -_ACEOF - -fi - -# On IRIX 5.3, sys/types and inttypes.h are conflicting. - - - - - - - - - -for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ - inttypes.h stdint.h unistd.h -do -as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` -{ echo "$as_me:$LINENO: checking for $ac_header" >&5 -echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - -#include <$ac_header> -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - eval "$as_ac_Header=yes" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_Header=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -ac_res=`eval echo '${'$as_ac_Header'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -if test `eval echo '${'$as_ac_Header'}'` = yes; then - cat >>confdefs.h <<_ACEOF -#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - - -if test "${ac_cv_header_minix_config_h+set}" = set; then - { echo "$as_me:$LINENO: checking for minix/config.h" >&5 -echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6; } -if test "${ac_cv_header_minix_config_h+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -fi -{ echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5 -echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6; } -else - # Is the header compilable? -{ echo "$as_me:$LINENO: checking minix/config.h usability" >&5 -echo $ECHO_N "checking minix/config.h usability... $ECHO_C" >&6; } -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -#include -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_header_compiler=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_header_compiler=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 -echo "${ECHO_T}$ac_header_compiler" >&6; } - -# Is the header present? -{ echo "$as_me:$LINENO: checking minix/config.h presence" >&5 -echo $ECHO_N "checking minix/config.h presence... $ECHO_C" >&6; } -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - ac_header_preproc=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_header_preproc=no -fi - -rm -f conftest.err conftest.$ac_ext -{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 -echo "${ECHO_T}$ac_header_preproc" >&6; } - -# So? What about this header? -case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in - yes:no: ) - { echo "$as_me:$LINENO: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&5 -echo "$as_me: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&2;} - { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the compiler's result" >&5 -echo "$as_me: WARNING: minix/config.h: proceeding with the compiler's result" >&2;} - ac_header_preproc=yes - ;; - no:yes:* ) - { echo "$as_me:$LINENO: WARNING: minix/config.h: present but cannot be compiled" >&5 -echo "$as_me: WARNING: minix/config.h: present but cannot be compiled" >&2;} - { echo "$as_me:$LINENO: WARNING: minix/config.h: check for missing prerequisite headers?" >&5 -echo "$as_me: WARNING: minix/config.h: check for missing prerequisite headers?" >&2;} - { echo "$as_me:$LINENO: WARNING: minix/config.h: see the Autoconf documentation" >&5 -echo "$as_me: WARNING: minix/config.h: see the Autoconf documentation" >&2;} - { echo "$as_me:$LINENO: WARNING: minix/config.h: section \"Present But Cannot Be Compiled\"" >&5 -echo "$as_me: WARNING: minix/config.h: section \"Present But Cannot Be Compiled\"" >&2;} - { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the preprocessor's result" >&5 -echo "$as_me: WARNING: minix/config.h: proceeding with the preprocessor's result" >&2;} - { echo "$as_me:$LINENO: WARNING: minix/config.h: in the future, the compiler will take precedence" >&5 -echo "$as_me: WARNING: minix/config.h: in the future, the compiler will take precedence" >&2;} - - ;; -esac -{ echo "$as_me:$LINENO: checking for minix/config.h" >&5 -echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6; } -if test "${ac_cv_header_minix_config_h+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_cv_header_minix_config_h=$ac_header_preproc -fi -{ echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5 -echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6; } - -fi -if test $ac_cv_header_minix_config_h = yes; then - MINIX=yes -else - MINIX= -fi - - -if test "$MINIX" = yes; then - -cat >>confdefs.h <<\_ACEOF -#define _POSIX_SOURCE 1 -_ACEOF - - -cat >>confdefs.h <<\_ACEOF -#define _POSIX_1_SOURCE 2 -_ACEOF - - -cat >>confdefs.h <<\_ACEOF -#define _MINIX 1 -_ACEOF - -fi - - -RM='rm -f' - -CP='cp' - -if $as_mkdir_p; then - MAKEDIRS='mkdir -p' - -else - MAKEDIRS='install -d' - -fi - -mv confdefs.h confdefs1.h -: > confdefs.h -# Check whether --enable-largefile was given. -if test "${enable_largefile+set}" = set; then - enableval=$enable_largefile; -fi - -if test "$enable_largefile" != no; then - - { echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5 -echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6; } -if test "${ac_cv_sys_largefile_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_cv_sys_largefile_CC=no - if test "$GCC" != yes; then - ac_save_CC=$CC - while :; do - # IRIX 6.2 and later do not support large files by default, - # so use the C compiler's -n32 option if that helps. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - /* Check that off_t can represent 2**63 - 1 correctly. - We can't simply define LARGE_OFF_T to be 9223372036854775807, - since some C++ compilers masquerading as C compilers - incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) - int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 - && LARGE_OFF_T % 2147483647 == 1) - ? 1 : -1]; -int -main () -{ - - ; - return 0; -} -_ACEOF - rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext - CC="$CC -n32" - rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_sys_largefile_CC=' -n32'; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext - break - done - CC=$ac_save_CC - rm -f conftest.$ac_ext - fi -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5 -echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6; } - if test "$ac_cv_sys_largefile_CC" != no; then - CC=$CC$ac_cv_sys_largefile_CC - fi - - { echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5 -echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6; } -if test "${ac_cv_sys_file_offset_bits+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - /* Check that off_t can represent 2**63 - 1 correctly. - We can't simply define LARGE_OFF_T to be 9223372036854775807, - since some C++ compilers masquerading as C compilers - incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) - int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 - && LARGE_OFF_T % 2147483647 == 1) - ? 1 : -1]; -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_sys_file_offset_bits=no; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#define _FILE_OFFSET_BITS 64 -#include - /* Check that off_t can represent 2**63 - 1 correctly. - We can't simply define LARGE_OFF_T to be 9223372036854775807, - since some C++ compilers masquerading as C compilers - incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) - int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 - && LARGE_OFF_T % 2147483647 == 1) - ? 1 : -1]; -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_sys_file_offset_bits=64; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_cv_sys_file_offset_bits=unknown - break -done -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5 -echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6; } -case $ac_cv_sys_file_offset_bits in #( - no | unknown) ;; - *) -cat >>confdefs.h <<_ACEOF -#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits -_ACEOF -;; -esac -rm -f conftest* - if test $ac_cv_sys_file_offset_bits = unknown; then - { echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5 -echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6; } -if test "${ac_cv_sys_large_files+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - /* Check that off_t can represent 2**63 - 1 correctly. - We can't simply define LARGE_OFF_T to be 9223372036854775807, - since some C++ compilers masquerading as C compilers - incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) - int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 - && LARGE_OFF_T % 2147483647 == 1) - ? 1 : -1]; -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_sys_large_files=no; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#define _LARGE_FILES 1 -#include - /* Check that off_t can represent 2**63 - 1 correctly. - We can't simply define LARGE_OFF_T to be 9223372036854775807, - since some C++ compilers masquerading as C compilers - incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) - int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 - && LARGE_OFF_T % 2147483647 == 1) - ? 1 : -1]; -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_sys_large_files=1; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_cv_sys_large_files=unknown - break -done -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5 -echo "${ECHO_T}$ac_cv_sys_large_files" >&6; } -case $ac_cv_sys_large_files in #( - no | unknown) ;; - *) -cat >>confdefs.h <<_ACEOF -#define _LARGE_FILES $ac_cv_sys_large_files -_ACEOF -;; -esac -rm -f conftest* - fi -fi - -mv confdefs.h largefile.h -mv confdefs1.h confdefs.h -cat largefile.h >> confdefs.h - -{ echo "$as_me:$LINENO: checking for long long" >&5 -echo $ECHO_N "checking for long long... $ECHO_C" >&6; } -if test "${ac_cv_type_long_long+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef long long ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_long_long=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_long_long=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5 -echo "${ECHO_T}$ac_cv_type_long_long" >&6; } -if test $ac_cv_type_long_long = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_LONG_LONG 1 -_ACEOF - - -fi -{ echo "$as_me:$LINENO: checking for off_t" >&5 -echo $ECHO_N "checking for off_t... $ECHO_C" >&6; } -if test "${ac_cv_type_off_t+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef off_t ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_off_t=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_off_t=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5 -echo "${ECHO_T}$ac_cv_type_off_t" >&6; } -if test $ac_cv_type_off_t = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_OFF_T 1 -_ACEOF - - -fi - - -{ echo "$as_me:$LINENO: checking for int" >&5 -echo $ECHO_N "checking for int... $ECHO_C" >&6; } -if test "${ac_cv_type_int+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef int ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_int=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_int=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5 -echo "${ECHO_T}$ac_cv_type_int" >&6; } - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ echo "$as_me:$LINENO: checking size of int" >&5 -echo $ECHO_N "checking size of int... $ECHO_C" >&6; } -if test "${ac_cv_sizeof_int+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef int ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef int ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef int ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef int ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef int ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_int=$ac_lo;; -'') if test "$ac_cv_type_int" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (int) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (int) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_int=0 - fi ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef int ac__type_sizeof_; -static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); } -static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (ac__type_sizeof_))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%ld\n", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%lu\n", i); - } - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_int=`cat conftest.val` -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -if test "$ac_cv_type_int" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (int) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (int) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_int=0 - fi -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi -rm -f conftest.val -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5 -echo "${ECHO_T}$ac_cv_sizeof_int" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_INT $ac_cv_sizeof_int -_ACEOF - - -{ echo "$as_me:$LINENO: checking for short" >&5 -echo $ECHO_N "checking for short... $ECHO_C" >&6; } -if test "${ac_cv_type_short+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef short ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_short=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_short=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5 -echo "${ECHO_T}$ac_cv_type_short" >&6; } - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ echo "$as_me:$LINENO: checking size of short" >&5 -echo $ECHO_N "checking size of short... $ECHO_C" >&6; } -if test "${ac_cv_sizeof_short+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef short ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef short ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef short ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef short ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef short ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_short=$ac_lo;; -'') if test "$ac_cv_type_short" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (short) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (short) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_short=0 - fi ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef short ac__type_sizeof_; -static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); } -static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (ac__type_sizeof_))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%ld\n", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%lu\n", i); - } - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_short=`cat conftest.val` -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -if test "$ac_cv_type_short" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (short) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (short) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_short=0 - fi -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi -rm -f conftest.val -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5 -echo "${ECHO_T}$ac_cv_sizeof_short" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_SHORT $ac_cv_sizeof_short -_ACEOF - - -{ echo "$as_me:$LINENO: checking for long" >&5 -echo $ECHO_N "checking for long... $ECHO_C" >&6; } -if test "${ac_cv_type_long+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef long ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_long=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_long=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5 -echo "${ECHO_T}$ac_cv_type_long" >&6; } - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ echo "$as_me:$LINENO: checking size of long" >&5 -echo $ECHO_N "checking size of long... $ECHO_C" >&6; } -if test "${ac_cv_sizeof_long+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef long ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef long ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef long ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef long ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef long ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_long=$ac_lo;; -'') if test "$ac_cv_type_long" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (long) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (long) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_long=0 - fi ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef long ac__type_sizeof_; -static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); } -static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (ac__type_sizeof_))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%ld\n", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%lu\n", i); - } - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_long=`cat conftest.val` -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -if test "$ac_cv_type_long" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (long) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (long) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_long=0 - fi -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi -rm -f conftest.val -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5 -echo "${ECHO_T}$ac_cv_sizeof_long" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_LONG $ac_cv_sizeof_long -_ACEOF - - -{ echo "$as_me:$LINENO: checking for long long" >&5 -echo $ECHO_N "checking for long long... $ECHO_C" >&6; } -if test "${ac_cv_type_long_long+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef long long ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_long_long=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_long_long=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5 -echo "${ECHO_T}$ac_cv_type_long_long" >&6; } - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ echo "$as_me:$LINENO: checking size of long long" >&5 -echo $ECHO_N "checking size of long long... $ECHO_C" >&6; } -if test "${ac_cv_sizeof_long_long+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef long long ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef long long ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef long long ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef long long ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef long long ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_long_long=$ac_lo;; -'') if test "$ac_cv_type_long_long" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (long long) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_long_long=0 - fi ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef long long ac__type_sizeof_; -static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); } -static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (ac__type_sizeof_))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%ld\n", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%lu\n", i); - } - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_long_long=`cat conftest.val` -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -if test "$ac_cv_type_long_long" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (long long) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_long_long=0 - fi -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi -rm -f conftest.val -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5 -echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long -_ACEOF - - -{ echo "$as_me:$LINENO: checking for __int64" >&5 -echo $ECHO_N "checking for __int64... $ECHO_C" >&6; } -if test "${ac_cv_type___int64+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef __int64 ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type___int64=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type___int64=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type___int64" >&5 -echo "${ECHO_T}$ac_cv_type___int64" >&6; } - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ echo "$as_me:$LINENO: checking size of __int64" >&5 -echo $ECHO_N "checking size of __int64... $ECHO_C" >&6; } -if test "${ac_cv_sizeof___int64+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef __int64 ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef __int64 ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef __int64 ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef __int64 ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef __int64 ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof___int64=$ac_lo;; -'') if test "$ac_cv_type___int64" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (__int64) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (__int64) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof___int64=0 - fi ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef __int64 ac__type_sizeof_; -static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); } -static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (ac__type_sizeof_))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%ld\n", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%lu\n", i); - } - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof___int64=`cat conftest.val` -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -if test "$ac_cv_type___int64" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (__int64) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (__int64) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof___int64=0 - fi -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi -rm -f conftest.val -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sizeof___int64" >&5 -echo "${ECHO_T}$ac_cv_sizeof___int64" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF___INT64 $ac_cv_sizeof___int64 -_ACEOF - - -{ echo "$as_me:$LINENO: checking for off_t" >&5 -echo $ECHO_N "checking for off_t... $ECHO_C" >&6; } -if test "${ac_cv_type_off_t+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef off_t ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_off_t=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_off_t=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5 -echo "${ECHO_T}$ac_cv_type_off_t" >&6; } - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ echo "$as_me:$LINENO: checking size of off_t" >&5 -echo $ECHO_N "checking size of off_t... $ECHO_C" >&6; } -if test "${ac_cv_sizeof_off_t+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef off_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef off_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef off_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef off_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef off_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_off_t=$ac_lo;; -'') if test "$ac_cv_type_off_t" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (off_t) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (off_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_off_t=0 - fi ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef off_t ac__type_sizeof_; -static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); } -static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (ac__type_sizeof_))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%ld\n", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%lu\n", i); - } - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_off_t=`cat conftest.val` -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -if test "$ac_cv_type_off_t" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (off_t) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (off_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_off_t=0 - fi -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi -rm -f conftest.val -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5 -echo "${ECHO_T}$ac_cv_sizeof_off_t" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_OFF_T $ac_cv_sizeof_off_t -_ACEOF - - -{ echo "$as_me:$LINENO: checking for void*" >&5 -echo $ECHO_N "checking for void*... $ECHO_C" >&6; } -if test "${ac_cv_type_voidp+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef void* ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_voidp=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_voidp=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_voidp" >&5 -echo "${ECHO_T}$ac_cv_type_voidp" >&6; } - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ echo "$as_me:$LINENO: checking size of void*" >&5 -echo $ECHO_N "checking size of void*... $ECHO_C" >&6; } -if test "${ac_cv_sizeof_voidp+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef void* ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef void* ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef void* ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef void* ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef void* ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_voidp=$ac_lo;; -'') if test "$ac_cv_type_voidp" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (void*) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (void*) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_voidp=0 - fi ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef void* ac__type_sizeof_; -static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); } -static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (ac__type_sizeof_))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%ld\n", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%lu\n", i); - } - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_voidp=`cat conftest.val` -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -if test "$ac_cv_type_voidp" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (void*) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (void*) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_voidp=0 - fi -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi -rm -f conftest.val -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_voidp" >&5 -echo "${ECHO_T}$ac_cv_sizeof_voidp" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_VOIDP $ac_cv_sizeof_voidp -_ACEOF - - -{ echo "$as_me:$LINENO: checking for float" >&5 -echo $ECHO_N "checking for float... $ECHO_C" >&6; } -if test "${ac_cv_type_float+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef float ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_float=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_float=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_float" >&5 -echo "${ECHO_T}$ac_cv_type_float" >&6; } - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ echo "$as_me:$LINENO: checking size of float" >&5 -echo $ECHO_N "checking size of float... $ECHO_C" >&6; } -if test "${ac_cv_sizeof_float+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef float ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef float ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef float ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef float ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef float ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_float=$ac_lo;; -'') if test "$ac_cv_type_float" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (float) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (float) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_float=0 - fi ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef float ac__type_sizeof_; -static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); } -static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (ac__type_sizeof_))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%ld\n", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%lu\n", i); - } - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_float=`cat conftest.val` -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -if test "$ac_cv_type_float" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (float) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (float) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_float=0 - fi -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi -rm -f conftest.val -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_float" >&5 -echo "${ECHO_T}$ac_cv_sizeof_float" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_FLOAT $ac_cv_sizeof_float -_ACEOF - - -{ echo "$as_me:$LINENO: checking for double" >&5 -echo $ECHO_N "checking for double... $ECHO_C" >&6; } -if test "${ac_cv_type_double+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef double ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_double=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_double=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5 -echo "${ECHO_T}$ac_cv_type_double" >&6; } - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ echo "$as_me:$LINENO: checking size of double" >&5 -echo $ECHO_N "checking size of double... $ECHO_C" >&6; } -if test "${ac_cv_sizeof_double+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef double ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef double ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef double ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef double ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef double ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_double=$ac_lo;; -'') if test "$ac_cv_type_double" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (double) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (double) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_double=0 - fi ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef double ac__type_sizeof_; -static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); } -static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (ac__type_sizeof_))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%ld\n", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%lu\n", i); - } - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_double=`cat conftest.val` -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -if test "$ac_cv_type_double" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (double) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (double) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_double=0 - fi -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi -rm -f conftest.val -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_double" >&5 -echo "${ECHO_T}$ac_cv_sizeof_double" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_DOUBLE $ac_cv_sizeof_double -_ACEOF - - -{ echo "$as_me:$LINENO: checking for time_t" >&5 -echo $ECHO_N "checking for time_t... $ECHO_C" >&6; } -if test "${ac_cv_type_time_t+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef time_t ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_time_t=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_time_t=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_time_t" >&5 -echo "${ECHO_T}$ac_cv_type_time_t" >&6; } - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ echo "$as_me:$LINENO: checking size of time_t" >&5 -echo $ECHO_N "checking size of time_t... $ECHO_C" >&6; } -if test "${ac_cv_sizeof_time_t+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef time_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef time_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef time_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef time_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef time_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_time_t=$ac_lo;; -'') if test "$ac_cv_type_time_t" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (time_t) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (time_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_time_t=0 - fi ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - typedef time_t ac__type_sizeof_; -static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); } -static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (ac__type_sizeof_))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%ld\n", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%lu\n", i); - } - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_time_t=`cat conftest.val` -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -if test "$ac_cv_type_time_t" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (time_t) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (time_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_time_t=0 - fi -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi -rm -f conftest.val -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_time_t" >&5 -echo "${ECHO_T}$ac_cv_sizeof_time_t" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_TIME_T $ac_cv_sizeof_time_t -_ACEOF - - - -for id in pid_t gid_t uid_t; do - as_ac_Type=`echo "ac_cv_type_$id" | $as_tr_sh` -{ echo "$as_me:$LINENO: checking for $id" >&5 -echo $ECHO_N "checking for $id... $ECHO_C" >&6; } -if { as_var=$as_ac_Type; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef $id ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - eval "$as_ac_Type=yes" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_Type=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -ac_res=`eval echo '${'$as_ac_Type'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -if test `eval echo '${'$as_ac_Type'}'` = yes; then - typ=$id -else - typ=int -fi - - cat >>confdefs.h <<_ACEOF -#define rb_$id $typ -_ACEOF - -done - -{ echo "$as_me:$LINENO: checking for prototypes" >&5 -echo $ECHO_N "checking for prototypes... $ECHO_C" >&6; } -if test "${rb_cv_have_prototypes+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -int foo(int x) { return 0; } -int -main () -{ -return foo(10); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_have_prototypes=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_have_prototypes=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $rb_cv_have_prototypes" >&5 -echo "${ECHO_T}$rb_cv_have_prototypes" >&6; } -if test "$rb_cv_have_prototypes" = yes; then - cat >>confdefs.h <<\_ACEOF -#define HAVE_PROTOTYPES 1 -_ACEOF - -fi - -{ echo "$as_me:$LINENO: checking token paste string" >&5 -echo $ECHO_N "checking token paste string... $ECHO_C" >&6; } -if test "${rb_cv_tokenpaste+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#define paste(a,b) a##b -int -main () -{ -int xy = 1; return paste(x,y); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_tokenpaste=ansi -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_tokenpaste=knr -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $rb_cv_tokenpaste" >&5 -echo "${ECHO_T}$rb_cv_tokenpaste" >&6; } -if test "$rb_cv_tokenpaste" = ansi; then - cat >>confdefs.h <<\_ACEOF -#define TOKEN_PASTE(x,y) x##y -_ACEOF - -else - cat >>confdefs.h <<\_ACEOF -#define TOKEN_PASTE(x,y) x/**/y -_ACEOF - -fi - -{ echo "$as_me:$LINENO: checking for variable length prototypes and stdarg.h" >&5 -echo $ECHO_N "checking for variable length prototypes and stdarg.h... $ECHO_C" >&6; } -if test "${rb_cv_stdarg+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#include -int foo(int x, ...) { - va_list va; - va_start(va, x); - va_arg(va, int); - va_arg(va, char *); - va_arg(va, double); - return 0; -} - -int -main () -{ -return foo(10, "", 3.14); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_stdarg=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_stdarg=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $rb_cv_stdarg" >&5 -echo "${ECHO_T}$rb_cv_stdarg" >&6; } -if test "$rb_cv_stdarg" = yes; then - cat >>confdefs.h <<\_ACEOF -#define HAVE_STDARG_PROTOTYPES 1 -_ACEOF - -fi - - - - { echo "$as_me:$LINENO: checking for noreturn function attribute" >&5 -echo $ECHO_N "checking for noreturn function attribute... $ECHO_C" >&6; } -if test "${rb_cv_func_noreturn+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - rb_cv_func_noreturn=x -if test "${ac_c_werror_flag+set}"; then - rb_c_werror_flag="$ac_c_werror_flag" -else - unset rb_c_werror_flag -fi -ac_c_werror_flag=yes -for mac in "__attribute__ ((noreturn)) x" "x __attribute__ ((noreturn))" "__declspec(noreturn) x" x; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#define NORETURN(x) $mac - NORETURN(void conftest_attribute_check(void)); -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_func_noreturn="$mac"; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -if test "${rb_c_werror_flag+set}"; then - ac_c_werror_flag="$rb_c_werror_flag" -else - unset ac_c_werror_flag -fi - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_func_noreturn" >&5 -echo "${ECHO_T}$rb_cv_func_noreturn" >&6; } -cat >>confdefs.h <<_ACEOF -#define NORETURN(x) $rb_cv_func_noreturn -_ACEOF - - - - - { echo "$as_me:$LINENO: checking for noinline function attribute" >&5 -echo $ECHO_N "checking for noinline function attribute... $ECHO_C" >&6; } -if test "${rb_cv_func_noinline+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - rb_cv_func_noinline=x -if test "${ac_c_werror_flag+set}"; then - rb_c_werror_flag="$ac_c_werror_flag" -else - unset rb_c_werror_flag -fi -ac_c_werror_flag=yes -for mac in "__attribute__ ((noinline)) x" "x __attribute__ ((noinline))" "__declspec(noinline) x" x; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#define NOINLINE(x) $mac - NOINLINE(void conftest_attribute_check(void)); -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_func_noinline="$mac"; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -if test "${rb_c_werror_flag+set}"; then - ac_c_werror_flag="$rb_c_werror_flag" -else - unset ac_c_werror_flag -fi - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_func_noinline" >&5 -echo "${ECHO_T}$rb_cv_func_noinline" >&6; } -cat >>confdefs.h <<_ACEOF -#define NOINLINE(x) $rb_cv_func_noinline -_ACEOF - - - - - -{ echo "$as_me:$LINENO: checking for RUBY_EXTERN" >&5 -echo $ECHO_N "checking for RUBY_EXTERN... $ECHO_C" >&6; } -if test "${rb_cv_ruby_extern+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - rb_cv_ruby_extern=no -for mac in "__attribute__((dllimport))" "__declspec(dllimport)"; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -extern $mac void conftest(void); -int -main () -{ -rb_cv_ruby_extern="extern $mac"; break - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -fi -{ echo "$as_me:$LINENO: result: $rb_cv_ruby_extern" >&5 -echo "${ECHO_T}$rb_cv_ruby_extern" >&6; } -test "x$rb_cv_ruby_extern" = xno || cat >>confdefs.h <<_ACEOF -#define RUBY_EXTERN $rb_cv_ruby_extern -_ACEOF - - -XCFLAGS="$XCFLAGS -DRUBY_EXPORT" - -{ echo "$as_me:$LINENO: checking whether sys_nerr is declared" >&5 -echo $ECHO_N "checking whether sys_nerr is declared... $ECHO_C" >&6; } -if test "${ac_cv_have_decl_sys_nerr+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -#include - -int -main () -{ -#ifndef sys_nerr - (void) sys_nerr; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_sys_nerr=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_sys_nerr=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_nerr" >&5 -echo "${ECHO_T}$ac_cv_have_decl_sys_nerr" >&6; } -if test $ac_cv_have_decl_sys_nerr = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_SYS_NERR 1 -_ACEOF - - -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_SYS_NERR 0 -_ACEOF - - -fi - - - - -# Check whether --with-libc_r was given. -if test "${with_libc_r+set}" = set; then - withval=$with_libc_r; - case $withval in - yes) with_libc_r=yes;; - *) with_libc_r=no;; - esac -else - with_libc_r=no -fi - - -# Check whether --enable-pthread was given. -if test "${enable_pthread+set}" = set; then - enableval=$enable_pthread; enable_pthread=$enableval -else - enable_pthread=no -fi - - -# Check whether --enable-fastthread was given. -if test "${enable_fastthread+set}" = set; then - enableval=$enable_fastthread; - : handled by ext/thread/extconf.rb - -fi - - -case "$target_os" in -nextstep*) ;; -openstep*) ;; -rhapsody*) ;; -darwin*) LIBS="-lobjc $LIBS" - CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - #if MAC_OS_X_VERSION_MAX_ALLOWED <= 1040 - #error pre OS X 10.4 - [!<===== pre OS X 10.4 =====>] - #endif - -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - - test "x$target_cpu" = xppc && ac_cv_header_ucontext_h=no - -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - - cat >>confdefs.h <<\_ACEOF -#define BROKEN_SETREUID 1 -_ACEOF - - cat >>confdefs.h <<\_ACEOF -#define BROKEN_SETREGID 1 -_ACEOF - - -fi - -rm -f conftest.err conftest.$ac_ext - ;; -hpux*) LIBS="-lm $LIBS" - ac_cv_c_inline=no;; -human*) ac_cv_func_getpgrp_void=yes - ac_cv_func_setitimer=no - ;; -beos*) ac_cv_func_link=no;; -cygwin*) ;; -mingw*) if test "$with_winsock2" = yes; then - LIBS="-lws2_32 $LIBS" - else - LIBS="-lwsock32 $LIBS" - fi - LIBS="-lshell32 $LIBS" - ac_cv_header_a_out_h=no - ac_cv_header_pwd_h=no - ac_cv_header_utime_h=no - ac_cv_header_sys_ioctl_h=no - ac_cv_header_sys_param_h=no - ac_cv_header_sys_resource_h=no - ac_cv_header_sys_select_h=no - ac_cv_header_sys_time_h=no - ac_cv_header_sys_times_h=no - ac_cv_func_times=yes - ac_cv_func_waitpid=yes - ac_cv_func_fsync=yes - ac_cv_func_vsnprintf=yes - ac_cv_func_seekdir=yes - ac_cv_func_telldir=yes - ac_cv_func_isinf=yes - ac_cv_func_isnan=yes - ac_cv_func_finite=yes - ac_cv_func_link=yes - ac_cv_lib_crypt_crypt=no - ac_cv_func_getpgrp_void=no - ac_cv_func_setpgrp_void=yes - ac_cv_func_memcmp_working=yes - ac_cv_lib_dl_dlopen=no - rb_cv_binary_elf=no - rb_cv_negative_time_t=no - enable_pthread=no - ac_cv_func_fcntl=yes - ;; -os2-emx*) LIBS="-lm $LIBS" - ac_cv_lib_dir_opendir=no;; -msdosdjgpp*) LIBS="-lm $LIBS" - ac_cv_func_getpgrp_void=yes - ac_cv_func_setitimer=no - ac_cv_sizeof_rlim_t=4 - ac_cv_func_setrlimit=no - ;; -bsdi*) LIBS="-lm $LIBS" - cat >>confdefs.h <<\_ACEOF -#define BROKEN_SETREUID 1 -_ACEOF - - cat >>confdefs.h <<\_ACEOF -#define BROKEN_SETREGID 1 -_ACEOF - - ac_cv_sizeof_rlim_t=8;; -freebsd*) LIBS="-lm $LIBS" - { echo "$as_me:$LINENO: checking whether -lxpg4 has to be linked" >&5 -echo $ECHO_N "checking whether -lxpg4 has to be linked... $ECHO_C" >&6; } -if test "${rb_cv_lib_xpg4_needed+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#include -#if __FreeBSD_version < 400020 || \ - (__FreeBSD_version >= 500000 && __FreeBSD_version < 500005) -#error needs libxpg4 -#endif - -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - rb_cv_lib_xpg4_needed=no -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_lib_xpg4_needed=yes -fi - -rm -f conftest.err conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $rb_cv_lib_xpg4_needed" >&5 -echo "${ECHO_T}$rb_cv_lib_xpg4_needed" >&6; } - if test "$rb_cv_lib_xpg4_needed" = yes; then - -{ echo "$as_me:$LINENO: checking for setlocale in -lxpg4" >&5 -echo $ECHO_N "checking for setlocale in -lxpg4... $ECHO_C" >&6; } -if test "${ac_cv_lib_xpg4_setlocale+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lxpg4 $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char setlocale (); -int -main () -{ -return setlocale (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_lib_xpg4_setlocale=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_xpg4_setlocale=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ echo "$as_me:$LINENO: result: $ac_cv_lib_xpg4_setlocale" >&5 -echo "${ECHO_T}$ac_cv_lib_xpg4_setlocale" >&6; } -if test $ac_cv_lib_xpg4_setlocale = yes; then - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBXPG4 1 -_ACEOF - - LIBS="-lxpg4 $LIBS" - -fi - - fi - if test "$with_libc_r" = yes; then - { echo "$as_me:$LINENO: checking whether libc_r is supplementary to libc" >&5 -echo $ECHO_N "checking whether libc_r is supplementary to libc... $ECHO_C" >&6; } -if test "${rb_cv_supplementary_lib_c_r+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#include -#if 500016 <= __FreeBSD_version -#error libc_r is supplementary to libc -#endif - -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - rb_cv_supplementary_lib_c_r=no -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_supplementary_lib_c_r=yes -fi - -rm -f conftest.err conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $rb_cv_supplementary_lib_c_r" >&5 -echo "${ECHO_T}$rb_cv_supplementary_lib_c_r" >&6; } - if test "$rb_cv_supplementary_lib_c_r" = yes; then - MAINLIBS="-lc_r $MAINLIBS" - fi - fi - ;; -dragonfly*) LIBS="-lm $LIBS" - ;; -bow) ac_cv_func_setitimer=no - ;; -superux*) ac_cv_func_setitimer=no - ;; -solaris*2.1*) if test -z "$GCC"; then - ac_cv_func_isinf=yes - fi - LIBS="-lm $LIBS" - ;; -*) LIBS="-lm $LIBS";; -esac - -{ echo "$as_me:$LINENO: checking for crypt in -lcrypt" >&5 -echo $ECHO_N "checking for crypt in -lcrypt... $ECHO_C" >&6; } -if test "${ac_cv_lib_crypt_crypt+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lcrypt $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char crypt (); -int -main () -{ -return crypt (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_lib_crypt_crypt=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_crypt_crypt=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ echo "$as_me:$LINENO: result: $ac_cv_lib_crypt_crypt" >&5 -echo "${ECHO_T}$ac_cv_lib_crypt_crypt" >&6; } -if test $ac_cv_lib_crypt_crypt = yes; then - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBCRYPT 1 -_ACEOF - - LIBS="-lcrypt $LIBS" - -fi - - -{ echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 -echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_lib_dl_dlopen=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_dl_dlopen=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 -echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6; } -if test $ac_cv_lib_dl_dlopen = yes; then - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBDL 1 -_ACEOF - - LIBS="-ldl $LIBS" - -fi - # Dynamic linking for SunOS/Solaris and SYSV - -{ echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5 -echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6; } -if test "${ac_cv_lib_dld_shl_load+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char shl_load (); -int -main () -{ -return shl_load (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_lib_dld_shl_load=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_dld_shl_load=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5 -echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6; } -if test $ac_cv_lib_dld_shl_load = yes; then - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBDLD 1 -_ACEOF - - LIBS="-ldld $LIBS" - -fi - # Dynamic linking for HP-UX - -case "$target_cpu" in -alpha*) case "$target_os"::"$GCC" in - *::yes) CFLAGS="-mieee $CFLAGS" ;; # gcc - osf*) CFLAGS="-ieee $CFLAGS" ;; # ccc - esac ;; -esac - - - - - - -ac_header_dirent=no -for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do - as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` -{ echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5 -echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include <$ac_hdr> - -int -main () -{ -if ((DIR *) 0) -return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - eval "$as_ac_Header=yes" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_Header=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -ac_res=`eval echo '${'$as_ac_Header'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -if test `eval echo '${'$as_ac_Header'}'` = yes; then - cat >>confdefs.h <<_ACEOF -#define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 -_ACEOF - -ac_header_dirent=$ac_hdr; break -fi - -done -# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. -if test $ac_header_dirent = dirent.h; then - { echo "$as_me:$LINENO: checking for library containing opendir" >&5 -echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6; } -if test "${ac_cv_search_opendir+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char opendir (); -int -main () -{ -return opendir (); - ; - return 0; -} -_ACEOF -for ac_lib in '' dir; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_search_opendir=$ac_res -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then - break -fi -done -if test "${ac_cv_search_opendir+set}" = set; then - : -else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5 -echo "${ECHO_T}$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - -fi - -else - { echo "$as_me:$LINENO: checking for library containing opendir" >&5 -echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6; } -if test "${ac_cv_search_opendir+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char opendir (); -int -main () -{ -return opendir (); - ; - return 0; -} -_ACEOF -for ac_lib in '' x; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_search_opendir=$ac_res -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then - break -fi -done -if test "${ac_cv_search_opendir+set}" = set; then - : -else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5 -echo "${ECHO_T}$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - -fi - -fi - -{ echo "$as_me:$LINENO: checking for ANSI C header files" >&5 -echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; } -if test "${ac_cv_header_stdc+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include -#include -#include - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_header_stdc=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_header_stdc=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then - : -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then - : -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then - : -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif - -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - : -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -fi -{ echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5 -echo "${ECHO_T}$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then - -cat >>confdefs.h <<\_ACEOF -#define STDC_HEADERS 1 -_ACEOF - -fi - -{ echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5 -echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6; } -if test "${ac_cv_header_sys_wait_h+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include -#ifndef WEXITSTATUS -# define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8) -#endif -#ifndef WIFEXITED -# define WIFEXITED(stat_val) (((stat_val) & 255) == 0) -#endif - -int -main () -{ - int s; - wait (&s); - s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_header_sys_wait_h=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_header_sys_wait_h=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5 -echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6; } -if test $ac_cv_header_sys_wait_h = yes; then - -cat >>confdefs.h <<\_ACEOF -#define HAVE_SYS_WAIT_H 1 -_ACEOF - -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -for ac_header in stdlib.h string.h unistd.h limits.h sys/file.h sys/ioctl.h sys/syscall.h\ - fcntl.h sys/fcntl.h sys/select.h sys/time.h sys/times.h sys/param.h\ - syscall.h pwd.h grp.h a.out.h utime.h memory.h direct.h sys/resource.h \ - sys/mkdev.h sys/utime.h netinet/in_systm.h float.h ieeefp.h pthread.h \ - ucontext.h intrinsics.h -do -as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - { echo "$as_me:$LINENO: checking for $ac_header" >&5 -echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -fi -ac_res=`eval echo '${'$as_ac_Header'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -else - # Is the header compilable? -{ echo "$as_me:$LINENO: checking $ac_header usability" >&5 -echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -#include <$ac_header> -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_header_compiler=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_header_compiler=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 -echo "${ECHO_T}$ac_header_compiler" >&6; } - -# Is the header present? -{ echo "$as_me:$LINENO: checking $ac_header presence" >&5 -echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <$ac_header> -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - ac_header_preproc=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_header_preproc=no -fi - -rm -f conftest.err conftest.$ac_ext -{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 -echo "${ECHO_T}$ac_header_preproc" >&6; } - -# So? What about this header? -case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in - yes:no: ) - { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 -echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} - { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 -echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} - ac_header_preproc=yes - ;; - no:yes:* ) - { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 -echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} - { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 -echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} - { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 -echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} - { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 -echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} - { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 -echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} - { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 -echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} - - ;; -esac -{ echo "$as_me:$LINENO: checking for $ac_header" >&5 -echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - eval "$as_ac_Header=\$ac_header_preproc" -fi -ac_res=`eval echo '${'$as_ac_Header'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } - -fi -if test `eval echo '${'$as_ac_Header'}'` = yes; then - cat >>confdefs.h <<_ACEOF -#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - - -{ echo "$as_me:$LINENO: checking for rlim_t" >&5 -echo $ECHO_N "checking for rlim_t... $ECHO_C" >&6; } -if test "${ac_cv_type_rlim_t+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - - #ifdef HAVE_SYS_TYPES_H - # include - #endif - #ifdef HAVE_SYS_TIME_H - # include - #endif - #ifdef HAVE_SYS_RESOURCE_H - # include - #endif - #ifdef HAVE_UNISTD_H - # include - #endif - #include - - -typedef rlim_t ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_rlim_t=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_rlim_t=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_rlim_t" >&5 -echo "${ECHO_T}$ac_cv_type_rlim_t" >&6; } - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ echo "$as_me:$LINENO: checking size of rlim_t" >&5 -echo $ECHO_N "checking size of rlim_t... $ECHO_C" >&6; } -if test "${ac_cv_sizeof_rlim_t+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - - #ifdef HAVE_SYS_TYPES_H - # include - #endif - #ifdef HAVE_SYS_TIME_H - # include - #endif - #ifdef HAVE_SYS_RESOURCE_H - # include - #endif - #ifdef HAVE_UNISTD_H - # include - #endif - #include - - - typedef rlim_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - - #ifdef HAVE_SYS_TYPES_H - # include - #endif - #ifdef HAVE_SYS_TIME_H - # include - #endif - #ifdef HAVE_SYS_RESOURCE_H - # include - #endif - #ifdef HAVE_UNISTD_H - # include - #endif - #include - - - typedef rlim_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - - #ifdef HAVE_SYS_TYPES_H - # include - #endif - #ifdef HAVE_SYS_TIME_H - # include - #endif - #ifdef HAVE_SYS_RESOURCE_H - # include - #endif - #ifdef HAVE_UNISTD_H - # include - #endif - #include - - - typedef rlim_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - - #ifdef HAVE_SYS_TYPES_H - # include - #endif - #ifdef HAVE_SYS_TIME_H - # include - #endif - #ifdef HAVE_SYS_RESOURCE_H - # include - #endif - #ifdef HAVE_UNISTD_H - # include - #endif - #include - - - typedef rlim_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - - #ifdef HAVE_SYS_TYPES_H - # include - #endif - #ifdef HAVE_SYS_TIME_H - # include - #endif - #ifdef HAVE_SYS_RESOURCE_H - # include - #endif - #ifdef HAVE_UNISTD_H - # include - #endif - #include - - - typedef rlim_t ac__type_sizeof_; -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_rlim_t=$ac_lo;; -'') if test "$ac_cv_type_rlim_t" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (rlim_t) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (rlim_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_rlim_t=0 - fi ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - - #ifdef HAVE_SYS_TYPES_H - # include - #endif - #ifdef HAVE_SYS_TIME_H - # include - #endif - #ifdef HAVE_SYS_RESOURCE_H - # include - #endif - #ifdef HAVE_UNISTD_H - # include - #endif - #include - - - typedef rlim_t ac__type_sizeof_; -static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); } -static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (ac__type_sizeof_))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%ld\n", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (ac__type_sizeof_)))) - return 1; - fprintf (f, "%lu\n", i); - } - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_rlim_t=`cat conftest.val` -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -if test "$ac_cv_type_rlim_t" = yes; then - { { echo "$as_me:$LINENO: error: cannot compute sizeof (rlim_t) -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute sizeof (rlim_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; } - else - ac_cv_sizeof_rlim_t=0 - fi -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi -rm -f conftest.val -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_rlim_t" >&5 -echo "${ECHO_T}$ac_cv_sizeof_rlim_t" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_RLIM_T $ac_cv_sizeof_rlim_t -_ACEOF - - - -{ echo "$as_me:$LINENO: checking for size_t" >&5 -echo $ECHO_N "checking for size_t... $ECHO_C" >&6; } -if test "${ac_cv_type_size_t+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -typedef size_t ac__type_new_; -int -main () -{ -if ((ac__type_new_ *) 0) - return 0; -if (sizeof (ac__type_new_)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_size_t=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_size_t=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5 -echo "${ECHO_T}$ac_cv_type_size_t" >&6; } -if test $ac_cv_type_size_t = yes; then - : -else - -cat >>confdefs.h <<_ACEOF -#define size_t unsigned int -_ACEOF - -fi - -{ echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5 -echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6; } -if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static struct stat ac_aggr; -if (ac_aggr.st_blksize) -return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_member_struct_stat_st_blksize=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static struct stat ac_aggr; -if (sizeof ac_aggr.st_blksize) -return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_member_struct_stat_st_blksize=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_member_struct_stat_st_blksize=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5 -echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6; } -if test $ac_cv_member_struct_stat_st_blksize = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_STRUCT_STAT_ST_BLKSIZE 1 -_ACEOF - - -cat >>confdefs.h <<\_ACEOF -#define HAVE_ST_BLKSIZE 1 -_ACEOF - -fi - - -{ echo "$as_me:$LINENO: checking for struct stat.st_blocks" >&5 -echo $ECHO_N "checking for struct stat.st_blocks... $ECHO_C" >&6; } -if test "${ac_cv_member_struct_stat_st_blocks+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static struct stat ac_aggr; -if (ac_aggr.st_blocks) -return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_member_struct_stat_st_blocks=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static struct stat ac_aggr; -if (sizeof ac_aggr.st_blocks) -return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_member_struct_stat_st_blocks=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_member_struct_stat_st_blocks=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blocks" >&5 -echo "${ECHO_T}$ac_cv_member_struct_stat_st_blocks" >&6; } -if test $ac_cv_member_struct_stat_st_blocks = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_STRUCT_STAT_ST_BLOCKS 1 -_ACEOF - - -cat >>confdefs.h <<\_ACEOF -#define HAVE_ST_BLOCKS 1 -_ACEOF - -else - case " $LIBOBJS " in - *" fileblocks.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS fileblocks.$ac_objext" - ;; -esac - -fi - - -{ echo "$as_me:$LINENO: checking for struct stat.st_rdev" >&5 -echo $ECHO_N "checking for struct stat.st_rdev... $ECHO_C" >&6; } -if test "${ac_cv_member_struct_stat_st_rdev+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static struct stat ac_aggr; -if (ac_aggr.st_rdev) -return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_member_struct_stat_st_rdev=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static struct stat ac_aggr; -if (sizeof ac_aggr.st_rdev) -return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_member_struct_stat_st_rdev=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_member_struct_stat_st_rdev=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_rdev" >&5 -echo "${ECHO_T}$ac_cv_member_struct_stat_st_rdev" >&6; } -if test $ac_cv_member_struct_stat_st_rdev = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_STRUCT_STAT_ST_RDEV 1 -_ACEOF - - -cat >>confdefs.h <<\_ACEOF -#define HAVE_ST_RDEV 1 -_ACEOF - -fi - - - -{ echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5 -echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6; } -if test "${ac_cv_type_uid_t+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "uid_t" >/dev/null 2>&1; then - ac_cv_type_uid_t=yes -else - ac_cv_type_uid_t=no -fi -rm -f conftest* - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5 -echo "${ECHO_T}$ac_cv_type_uid_t" >&6; } -if test $ac_cv_type_uid_t = no; then - -cat >>confdefs.h <<\_ACEOF -#define uid_t int -_ACEOF - - -cat >>confdefs.h <<\_ACEOF -#define gid_t int -_ACEOF - -fi - -{ echo "$as_me:$LINENO: checking type of array argument to getgroups" >&5 -echo $ECHO_N "checking type of array argument to getgroups... $ECHO_C" >&6; } -if test "${ac_cv_type_getgroups+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - ac_cv_type_getgroups=cross -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Thanks to Mike Rendell for this test. */ -$ac_includes_default -#define NGID 256 -#undef MAX -#define MAX(x, y) ((x) > (y) ? (x) : (y)) - -int -main () -{ - gid_t gidset[NGID]; - int i, n; - union { gid_t gval; long int lval; } val; - - val.lval = -1; - for (i = 0; i < NGID; i++) - gidset[i] = val.gval; - n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1, - gidset); - /* Exit non-zero if getgroups seems to require an array of ints. This - happens when gid_t is short int but getgroups modifies an array - of ints. */ - return n > 0 && gidset[n] != val.gval; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_type_getgroups=gid_t -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -ac_cv_type_getgroups=int -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -if test $ac_cv_type_getgroups = cross; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "getgroups.*int.*gid_t" >/dev/null 2>&1; then - ac_cv_type_getgroups=gid_t -else - ac_cv_type_getgroups=int -fi -rm -f conftest* - -fi -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_getgroups" >&5 -echo "${ECHO_T}$ac_cv_type_getgroups" >&6; } - -cat >>confdefs.h <<_ACEOF -#define GETGROUPS_T $ac_cv_type_getgroups -_ACEOF - - -{ echo "$as_me:$LINENO: checking return type of signal handlers" >&5 -echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6; } -if test "${ac_cv_type_signal+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include - -int -main () -{ -return *(signal (0, 0)) (0) == 1; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_type_signal=int -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_signal=void -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5 -echo "${ECHO_T}$ac_cv_type_signal" >&6; } - -cat >>confdefs.h <<_ACEOF -#define RETSIGTYPE $ac_cv_type_signal -_ACEOF - - -case "${target_cpu}-${target_os}" in -powerpc-darwin*) - - ALLOCA=\${LIBOBJDIR}alloca.${ac_objext} - - cat >>confdefs.h <<\_ACEOF -#define C_ALLOCA 1 -_ACEOF - - cat >>confdefs.h <<_ACEOF -#define alloca alloca -_ACEOF - - ;; -*) - # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works -# for constant arguments. Useless! -{ echo "$as_me:$LINENO: checking for working alloca.h" >&5 -echo $ECHO_N "checking for working alloca.h... $ECHO_C" >&6; } -if test "${ac_cv_working_alloca_h+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ -char *p = (char *) alloca (2 * sizeof (int)); - if (p) return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_working_alloca_h=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_working_alloca_h=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_working_alloca_h" >&5 -echo "${ECHO_T}$ac_cv_working_alloca_h" >&6; } -if test $ac_cv_working_alloca_h = yes; then - -cat >>confdefs.h <<\_ACEOF -#define HAVE_ALLOCA_H 1 -_ACEOF - -fi - -{ echo "$as_me:$LINENO: checking for alloca" >&5 -echo $ECHO_N "checking for alloca... $ECHO_C" >&6; } -if test "${ac_cv_func_alloca_works+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#ifdef __GNUC__ -# define alloca __builtin_alloca -#else -# ifdef _MSC_VER -# include -# define alloca _alloca -# else -# ifdef HAVE_ALLOCA_H -# include -# else -# ifdef _AIX - #pragma alloca -# else -# ifndef alloca /* predefined by HP cc +Olibcalls */ -char *alloca (); -# endif -# endif -# endif -# endif -#endif - -int -main () -{ -char *p = (char *) alloca (1); - if (p) return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_func_alloca_works=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func_alloca_works=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_func_alloca_works" >&5 -echo "${ECHO_T}$ac_cv_func_alloca_works" >&6; } - -if test $ac_cv_func_alloca_works = yes; then - -cat >>confdefs.h <<\_ACEOF -#define HAVE_ALLOCA 1 -_ACEOF - -else - # The SVR3 libPW and SVR4 libucb both contain incompatible functions -# that cause trouble. Some versions do not even contain alloca or -# contain a buggy version. If you still want to use their alloca, -# use ar to extract alloca.o from them instead of compiling alloca.c. - -ALLOCA=\${LIBOBJDIR}alloca.$ac_objext - -cat >>confdefs.h <<\_ACEOF -#define C_ALLOCA 1 -_ACEOF - - -{ echo "$as_me:$LINENO: checking whether \`alloca.c' needs Cray hooks" >&5 -echo $ECHO_N "checking whether \`alloca.c' needs Cray hooks... $ECHO_C" >&6; } -if test "${ac_cv_os_cray+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#if defined CRAY && ! defined CRAY2 -webecray -#else -wenotbecray -#endif - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "webecray" >/dev/null 2>&1; then - ac_cv_os_cray=yes -else - ac_cv_os_cray=no -fi -rm -f conftest* - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_os_cray" >&5 -echo "${ECHO_T}$ac_cv_os_cray" >&6; } -if test $ac_cv_os_cray = yes; then - for ac_func in _getb67 GETB67 getb67; do - as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ echo "$as_me:$LINENO: checking for $ac_func" >&5 -echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - eval "$as_ac_var=yes" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval echo '${'$as_ac_var'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -if test `eval echo '${'$as_ac_var'}'` = yes; then - -cat >>confdefs.h <<_ACEOF -#define CRAY_STACKSEG_END $ac_func -_ACEOF - - break -fi - - done -fi - -{ echo "$as_me:$LINENO: checking stack direction for C alloca" >&5 -echo $ECHO_N "checking stack direction for C alloca... $ECHO_C" >&6; } -if test "${ac_cv_c_stack_direction+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - ac_cv_c_stack_direction=0 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -find_stack_direction () -{ - static char *addr = 0; - auto char dummy; - if (addr == 0) - { - addr = &dummy; - return find_stack_direction (); - } - else - return (&dummy > addr) ? 1 : -1; -} - -int -main () -{ - return find_stack_direction () < 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_c_stack_direction=1 -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -ac_cv_c_stack_direction=-1 -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_c_stack_direction" >&5 -echo "${ECHO_T}$ac_cv_c_stack_direction" >&6; } - -cat >>confdefs.h <<_ACEOF -#define STACK_DIRECTION $ac_cv_c_stack_direction -_ACEOF - - -fi - - ;; -esac -{ echo "$as_me:$LINENO: checking for working memcmp" >&5 -echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6; } -if test "${ac_cv_func_memcmp_working+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - ac_cv_func_memcmp_working=no -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ - - /* Some versions of memcmp are not 8-bit clean. */ - char c0 = '\100', c1 = '\200', c2 = '\201'; - if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0) - return 1; - - /* The Next x86 OpenStep bug shows up only when comparing 16 bytes - or more and with at least one buffer not starting on a 4-byte boundary. - William Lewis provided this test program. */ - { - char foo[21]; - char bar[21]; - int i; - for (i = 0; i < 4; i++) - { - char *a = foo + i; - char *b = bar + i; - strcpy (a, "--------01111111"); - strcpy (b, "--------10000000"); - if (memcmp (a, b, 16) >= 0) - return 1; - } - return 0; - } - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_func_memcmp_working=yes -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -ac_cv_func_memcmp_working=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5 -echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6; } -test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in - *" memcmp.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS memcmp.$ac_objext" - ;; -esac - - -{ echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5 -echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6; } -if test "${ac_cv_sys_largefile_source+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include /* for off_t */ - #include -int -main () -{ -int (*fp) (FILE *, off_t, int) = fseeko; - return fseeko (stdin, 0, 0) && fp (stdin, 0, 0); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_sys_largefile_source=no; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#define _LARGEFILE_SOURCE 1 -#include /* for off_t */ - #include -int -main () -{ -int (*fp) (FILE *, off_t, int) = fseeko; - return fseeko (stdin, 0, 0) && fp (stdin, 0, 0); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_sys_largefile_source=1; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext - ac_cv_sys_largefile_source=unknown - break -done -fi -{ echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5 -echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6; } -case $ac_cv_sys_largefile_source in #( - no | unknown) ;; - *) -cat >>confdefs.h <<_ACEOF -#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source -_ACEOF -;; -esac -rm -f conftest* - -# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug -# in glibc 2.1.3, but that breaks too many other things. -# If you want fseeko and ftello with glibc, upgrade to a fixed glibc. -if test $ac_cv_sys_largefile_source != unknown; then - -cat >>confdefs.h <<\_ACEOF -#define HAVE_FSEEKO 1 -_ACEOF - -fi - - -for ac_func in ftello -do -as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ echo "$as_me:$LINENO: checking for $ac_func" >&5 -echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - eval "$as_ac_var=yes" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval echo '${'$as_ac_var'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -if test `eval echo '${'$as_ac_var'}'` = yes; then - cat >>confdefs.h <<_ACEOF -#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - - - - - - - - - - - - - - - - - - - -for ac_func in dup2 memmove strcasecmp strncasecmp strerror strftime\ - strchr strstr strtoul crypt flock vsnprintf\ - isnan finite isinf hypot acosh erf -do -as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ echo "$as_me:$LINENO: checking for $ac_func" >&5 -echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - eval "$as_ac_var=yes" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval echo '${'$as_ac_var'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -if test `eval echo '${'$as_ac_var'}'` = yes; then - cat >>confdefs.h <<_ACEOF -#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -else - case " $LIBOBJS " in - *" $ac_func.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" - ;; -esac - -fi -done - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -for ac_func in fmod killpg wait4 waitpid syscall chroot fsync getcwd eaccess\ - truncate ftruncate chsize times utimes fcntl lockf lstat symlink link\ - readlink setitimer setruid seteuid setreuid setresuid\ - setproctitle setrgid setegid setregid setresgid issetugid pause\ - lchown lchmod getpgrp setpgrp getpgid setpgid initgroups\ - getgroups setgroups getpriority getrlimit setrlimit sysconf\ - group_member dlopen sigprocmask\ - sigaction sigsetjmp _setjmp _longjmp setsid telldir seekdir fchmod\ - mktime timegm gettimeofday\ - cosh sinh tanh round setuid setgid setenv unsetenv -do -as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ echo "$as_me:$LINENO: checking for $ac_func" >&5 -echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - eval "$as_ac_var=yes" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval echo '${'$as_ac_var'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -if test `eval echo '${'$as_ac_var'}'` = yes; then - cat >>confdefs.h <<_ACEOF -#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - - -{ echo "$as_me:$LINENO: checking for __builtin_setjmp" >&5 -echo $ECHO_N "checking for __builtin_setjmp... $ECHO_C" >&6; } -if test "${ac_cv_func___builtin_setjmp+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - jmp_buf jb; void t(v) int v; {__builtin_longjmp(jb, v);} -int -main () -{ -__builtin_setjmp(jb); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_func___builtin_setjmp=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func___builtin_setjmp=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_func___builtin_setjmp" >&5 -echo "${ECHO_T}$ac_cv_func___builtin_setjmp" >&6; } - -test x$ac_cv_func__longjmp = xno && ac_cv_func__setjmp=no - -{ echo "$as_me:$LINENO: checking for setjmp type" >&5 -echo $ECHO_N "checking for setjmp type... $ECHO_C" >&6; } - -# Check whether --with-setjmp-type was given. -if test "${with_setjmp_type+set}" = set; then - withval=$with_setjmp_type; - case $withval in - __builtin_setjmp) setjmp_prefix=__builtin_;; - _setjmp) setjmp_prefix=_;; - sigsetjmp) setjmp_prefix=sig;; - setjmp) setjmp_prefix=;; - '') unset setjmp_prefix;; - *) { { echo "$as_me:$LINENO: error: invalid setjmp type: $withval" >&5 -echo "$as_me: error: invalid setjmp type: $withval" >&2;} - { (exit 1); exit 1; }; };; - esac -else - unset setjmp_prefix -fi - -if test ${setjmp_prefix+set}; then - if test "${setjmp_prefix}" && eval test '$ac_cv_func_'${setjmp_prefix}setjmp = no; then - { { echo "$as_me:$LINENO: error: ${setjmp_prefix}setjmp is not available" >&5 -echo "$as_me: error: ${setjmp_prefix}setjmp is not available" >&2;} - { (exit 1); exit 1; }; } - fi -elif test "$ac_cv_func___builtin_setjmp" = yes; then - setjmp_prefix=__builtin_ -elif test "$ac_cv_func__setjmp" = yes; then - setjmp_prefix=_ -elif test "$ac_cv_func_sigsetjmp" = yes; then - case $target_os in - solaris*|cygwin*) - setjmp_prefix=;; - *) - setjmp_prefix=sig;; - esac -else - setjmp_prefix= -fi -if test x$setjmp_prefix = xsig; then - setjmp_sigmask=yes -else - unset setjmp_sigmask -fi -{ echo "$as_me:$LINENO: result: ${setjmp_prefix}setjmp" >&5 -echo "${ECHO_T}${setjmp_prefix}setjmp" >&6; } -cat >>confdefs.h <<_ACEOF -#define RUBY_SETJMP(env) ${setjmp_prefix}setjmp(env${setjmp_sigmask+,0}) -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define RUBY_LONGJMP(env,val) ${setjmp_prefix}longjmp(env,val) -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define RUBY_JMP_BUF ${setjmp_sigmask+${setjmp_prefix}}jmp_buf -_ACEOF - - -# Check whether --enable-setreuid was given. -if test "${enable_setreuid+set}" = set; then - enableval=$enable_setreuid; use_setreuid=$enableval -fi - -if test "$use_setreuid" = yes; then - cat >>confdefs.h <<\_ACEOF -#define USE_SETREUID 1 -_ACEOF - - cat >>confdefs.h <<\_ACEOF -#define USE_SETREGID 1 -_ACEOF - -fi -{ echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5 -echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6; } -if test "${ac_cv_struct_tm+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include - -int -main () -{ -struct tm tm; - int *p = &tm.tm_sec; - return !p; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_struct_tm=time.h -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_struct_tm=sys/time.h -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5 -echo "${ECHO_T}$ac_cv_struct_tm" >&6; } -if test $ac_cv_struct_tm = sys/time.h; then - -cat >>confdefs.h <<\_ACEOF -#define TM_IN_SYS_TIME 1 -_ACEOF - -fi - -{ echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5 -echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6; } -if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include <$ac_cv_struct_tm> - - -int -main () -{ -static struct tm ac_aggr; -if (ac_aggr.tm_zone) -return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_member_struct_tm_tm_zone=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include <$ac_cv_struct_tm> - - -int -main () -{ -static struct tm ac_aggr; -if (sizeof ac_aggr.tm_zone) -return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_member_struct_tm_tm_zone=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_member_struct_tm_tm_zone=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5 -echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6; } -if test $ac_cv_member_struct_tm_tm_zone = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_STRUCT_TM_TM_ZONE 1 -_ACEOF - - -fi - -if test "$ac_cv_member_struct_tm_tm_zone" = yes; then - -cat >>confdefs.h <<\_ACEOF -#define HAVE_TM_ZONE 1 -_ACEOF - -else - { echo "$as_me:$LINENO: checking whether tzname is declared" >&5 -echo $ECHO_N "checking whether tzname is declared... $ECHO_C" >&6; } -if test "${ac_cv_have_decl_tzname+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -int -main () -{ -#ifndef tzname - (void) tzname; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_tzname=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_tzname=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_tzname" >&5 -echo "${ECHO_T}$ac_cv_have_decl_tzname" >&6; } -if test $ac_cv_have_decl_tzname = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_TZNAME 1 -_ACEOF - - -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_TZNAME 0 -_ACEOF - - -fi - - - { echo "$as_me:$LINENO: checking for tzname" >&5 -echo $ECHO_N "checking for tzname... $ECHO_C" >&6; } -if test "${ac_cv_var_tzname+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#if !HAVE_DECL_TZNAME -extern char *tzname[]; -#endif - -int -main () -{ -return tzname[0][0]; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_var_tzname=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_var_tzname=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5 -echo "${ECHO_T}$ac_cv_var_tzname" >&6; } - if test $ac_cv_var_tzname = yes; then - -cat >>confdefs.h <<\_ACEOF -#define HAVE_TZNAME 1 -_ACEOF - - fi -fi - -{ echo "$as_me:$LINENO: checking for struct tm.tm_gmtoff" >&5 -echo $ECHO_N "checking for struct tm.tm_gmtoff... $ECHO_C" >&6; } -if test "${rb_cv_member_struct_tm_tm_gmtoff+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ -struct tm t; t.tm_gmtoff = 3600; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_member_struct_tm_tm_gmtoff=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_member_struct_tm_tm_gmtoff=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $rb_cv_member_struct_tm_tm_gmtoff" >&5 -echo "${ECHO_T}$rb_cv_member_struct_tm_tm_gmtoff" >&6; } -if test "$rb_cv_member_struct_tm_tm_gmtoff" = yes; then - cat >>confdefs.h <<\_ACEOF -#define HAVE_STRUCT_TM_TM_GMTOFF 1 -_ACEOF - -fi -{ echo "$as_me:$LINENO: checking for external int daylight" >&5 -echo $ECHO_N "checking for external int daylight... $ECHO_C" >&6; } -if test "${rb_cv_have_daylight+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - int i; -int -main () -{ -i = daylight; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - rb_cv_have_daylight=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_have_daylight=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $rb_cv_have_daylight" >&5 -echo "${ECHO_T}$rb_cv_have_daylight" >&6; } -if test "$rb_cv_have_daylight" = yes; then - cat >>confdefs.h <<\_ACEOF -#define HAVE_DAYLIGHT 1 -_ACEOF - -fi - -{ echo "$as_me:$LINENO: checking for external timezone" >&5 -echo $ECHO_N "checking for external timezone... $ECHO_C" >&6; } -if test "${rb_cv_var_timezone+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - rb_cv_var_timezone=no - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#ifndef _XOPEN_SOURCE -#define _XOPEN_SOURCE 1 -#endif -#include -; -const volatile void *volatile t; -int -main () -{ -t = &(&timezone)[0]; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - for t in long int; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#ifndef _XOPEN_SOURCE -#define _XOPEN_SOURCE 1 -#endif -#include -; -extern $t timezone; -const volatile void *volatile t; -int -main () -{ -t = &(&timezone)[0]; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_var_timezone=$t; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $rb_cv_var_timezone" >&5 -echo "${ECHO_T}$rb_cv_var_timezone" >&6; } -if test "$rb_cv_var_timezone" != no; then - cat >>confdefs.h <<\_ACEOF -#define HAVE_VAR_TIMEZONE 1 -_ACEOF - - cat >>confdefs.h <<_ACEOF -#define TYPEOF_VAR_TIMEZONE $rb_cv_var_timezone -_ACEOF - -fi -{ echo "$as_me:$LINENO: checking for external altzone" >&5 -echo $ECHO_N "checking for external altzone... $ECHO_C" >&6; } -if test "${rb_cv_var_altzone+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - rb_cv_var_altzone=no - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#ifndef _XOPEN_SOURCE -#define _XOPEN_SOURCE 1 -#endif -#include -; -const volatile void *volatile t; -int -main () -{ -t = &(&altzone)[0]; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - for t in long int; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#ifndef _XOPEN_SOURCE -#define _XOPEN_SOURCE 1 -#endif -#include -; -extern $t altzone; -const volatile void *volatile t; -int -main () -{ -t = &(&altzone)[0]; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_var_altzone=$t; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $rb_cv_var_altzone" >&5 -echo "${ECHO_T}$rb_cv_var_altzone" >&6; } -if test "$rb_cv_var_altzone" != no; then - cat >>confdefs.h <<\_ACEOF -#define HAVE_VAR_ALTZONE 1 -_ACEOF - - cat >>confdefs.h <<_ACEOF -#define TYPEOF_VAR_ALTZONE $rb_cv_var_altzone -_ACEOF - -fi -if test "$rb_cv_var_timezone" = no; then - -for ac_func in timezone -do -as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ echo "$as_me:$LINENO: checking for $ac_func" >&5 -echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - eval "$as_ac_var=yes" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval echo '${'$as_ac_var'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -if test `eval echo '${'$as_ac_var'}'` = yes; then - cat >>confdefs.h <<_ACEOF -#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - - if test "$ac_cv_func_timezone" = yes; then - { echo "$as_me:$LINENO: checking whether timezone requires zero arguments" >&5 -echo $ECHO_N "checking whether timezone requires zero arguments... $ECHO_C" >&6; } -if test "${rb_cv_func_timezone_void+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ -(void)timezone(0, 0); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_func_timezone_void=no -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_func_timezone_void=yes -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_func_timezone_void" >&5 -echo "${ECHO_T}$rb_cv_func_timezone_void" >&6; } - if test $rb_cv_func_timezone_void = yes; then - cat >>confdefs.h <<\_ACEOF -#define TIMEZONE_VOID 1 -_ACEOF - - fi - fi -fi - -{ echo "$as_me:$LINENO: checking for negative time_t for gmtime(3)" >&5 -echo $ECHO_N "checking for negative time_t for gmtime(3)... $ECHO_C" >&6; } -if test "${rb_cv_negative_time_t+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - rb_cv_negative_time_t=yes -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#include - -void -check(tm, y, m, d, h, s) - struct tm *tm; - int y, m, d, h, s; -{ - if (!tm || - tm->tm_year != y || - tm->tm_mon != m-1 || - tm->tm_mday != d || - tm->tm_hour != h || - tm->tm_sec != s) { - exit(1); - } -} - -int -main() -{ - time_t t = -1; - struct tm *tm; - - check(gmtime(&t), 69, 12, 31, 23, 59); - t = ~(time_t)0 << 31; - check(gmtime(&t), 1, 12, 13, 20, 52); - return 0; -} - -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - rb_cv_negative_time_t=yes -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -rb_cv_negative_time_t=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_negative_time_t" >&5 -echo "${ECHO_T}$rb_cv_negative_time_t" >&6; } -if test "$rb_cv_negative_time_t" = yes; then - cat >>confdefs.h <<\_ACEOF -#define NEGATIVE_TIME_T 1 -_ACEOF - -fi - -if test "$ac_cv_func_sigprocmask" = yes && test "$ac_cv_func_sigaction" = yes; then - cat >>confdefs.h <<\_ACEOF -#define POSIX_SIGNAL 1 -_ACEOF - -else - -for ac_func in sigsetmask -do -as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ echo "$as_me:$LINENO: checking for $ac_func" >&5 -echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - eval "$as_ac_var=yes" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval echo '${'$as_ac_var'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -if test `eval echo '${'$as_ac_var'}'` = yes; then - cat >>confdefs.h <<_ACEOF -#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - - { echo "$as_me:$LINENO: checking for BSD signal semantics" >&5 -echo $ECHO_N "checking for BSD signal semantics... $ECHO_C" >&6; } -if test "${rb_cv_bsd_signal+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - rb_cv_bsd_signal=$ac_cv_func_sigsetmask -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#include -#include - -void -sig_handler(dummy) - int dummy; -{ -} - -int -main() -{ - signal(SIGINT, sig_handler); - kill(getpid(), SIGINT); - kill(getpid(), SIGINT); - return 0; -} - -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - rb_cv_bsd_signal=yes -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -rb_cv_bsd_signal=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_bsd_signal" >&5 -echo "${ECHO_T}$rb_cv_bsd_signal" >&6; } - if test "$rb_cv_bsd_signal" = yes; then - cat >>confdefs.h <<\_ACEOF -#define BSD_SIGNAL 1 -_ACEOF - - fi -fi - -{ echo "$as_me:$LINENO: checking whether getpgrp requires zero arguments" >&5 -echo $ECHO_N "checking whether getpgrp requires zero arguments... $ECHO_C" >&6; } -if test "${ac_cv_func_getpgrp_void+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - # Use it with a single arg. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -getpgrp (0); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_func_getpgrp_void=no -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func_getpgrp_void=yes -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_func_getpgrp_void" >&5 -echo "${ECHO_T}$ac_cv_func_getpgrp_void" >&6; } -if test $ac_cv_func_getpgrp_void = yes; then - -cat >>confdefs.h <<\_ACEOF -#define GETPGRP_VOID 1 -_ACEOF - -fi - -{ echo "$as_me:$LINENO: checking whether setpgrp takes no argument" >&5 -echo $ECHO_N "checking whether setpgrp takes no argument... $ECHO_C" >&6; } -if test "${ac_cv_func_setpgrp_void+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - { { echo "$as_me:$LINENO: error: cannot check setpgrp when cross compiling" >&5 -echo "$as_me: error: cannot check setpgrp when cross compiling" >&2;} - { (exit 1); exit 1; }; } -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -/* If this system has a BSD-style setpgrp which takes arguments, - setpgrp(1, 1) will fail with ESRCH and return -1, in that case - exit successfully. */ - return setpgrp (1,1) != -1; - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_func_setpgrp_void=no -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -ac_cv_func_setpgrp_void=yes -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_func_setpgrp_void" >&5 -echo "${ECHO_T}$ac_cv_func_setpgrp_void" >&6; } -if test $ac_cv_func_setpgrp_void = yes; then - -cat >>confdefs.h <<\_ACEOF -#define SETPGRP_VOID 1 -_ACEOF - -fi - - -{ echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5 -echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6; } -if test "${ac_cv_c_bigendian+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - # See if sys/param.h defines the BYTE_ORDER macro. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include - -int -main () -{ -#if ! (defined BYTE_ORDER && defined BIG_ENDIAN && defined LITTLE_ENDIAN \ - && BYTE_ORDER && BIG_ENDIAN && LITTLE_ENDIAN) - bogus endian macros -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - # It does; now see whether it defined to BIG_ENDIAN or not. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include - -int -main () -{ -#if BYTE_ORDER != BIG_ENDIAN - not big endian -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_c_bigendian=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_c_bigendian=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - # It does not; compile a test program. -if test "$cross_compiling" = yes; then - # try to guess the endianness by grepping values into an object file - ac_cv_c_bigendian=unknown - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -short int ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; -short int ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; -void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; } -short int ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; -short int ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; -void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; } -int -main () -{ - _ascii (); _ebcdic (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then - ac_cv_c_bigendian=yes -fi -if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then - if test "$ac_cv_c_bigendian" = unknown; then - ac_cv_c_bigendian=no - else - # finding both strings is unlikely to happen, but who knows? - ac_cv_c_bigendian=unknown - fi -fi -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ - - /* Are we little or big endian? From Harbison&Steele. */ - union - { - long int l; - char c[sizeof (long int)]; - } u; - u.l = 1; - return u.c[sizeof (long int) - 1] == 1; - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_c_bigendian=no -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -ac_cv_c_bigendian=yes -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5 -echo "${ECHO_T}$ac_cv_c_bigendian" >&6; } -case $ac_cv_c_bigendian in - yes) - -cat >>confdefs.h <<\_ACEOF -#define WORDS_BIGENDIAN 1 -_ACEOF - ;; - no) - ;; - *) - { { echo "$as_me:$LINENO: error: unknown endianness -presetting ac_cv_c_bigendian=no (or yes) will help" >&5 -echo "$as_me: error: unknown endianness -presetting ac_cv_c_bigendian=no (or yes) will help" >&2;} - { (exit 1); exit 1; }; } ;; -esac - -{ echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5 -echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6; } -if test "${ac_cv_c_const+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -int -main () -{ -/* FIXME: Include the comments suggested by Paul. */ -#ifndef __cplusplus - /* Ultrix mips cc rejects this. */ - typedef int charset[2]; - const charset cs; - /* SunOS 4.1.1 cc rejects this. */ - char const *const *pcpcc; - char **ppc; - /* NEC SVR4.0.2 mips cc rejects this. */ - struct point {int x, y;}; - static struct point const zero = {0,0}; - /* AIX XL C 1.02.0.0 rejects this. - It does not let you subtract one const X* pointer from another in - an arm of an if-expression whose if-part is not a constant - expression */ - const char *g = "string"; - pcpcc = &g + (g ? g-g : 0); - /* HPUX 7.0 cc rejects these. */ - ++pcpcc; - ppc = (char**) pcpcc; - pcpcc = (char const *const *) ppc; - { /* SCO 3.2v4 cc rejects this. */ - char *t; - char const *s = 0 ? (char *) 0 : (char const *) 0; - - *t++ = 0; - if (s) return 0; - } - { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ - int x[] = {25, 17}; - const int *foo = &x[0]; - ++foo; - } - { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ - typedef const int *iptr; - iptr p = 0; - ++p; - } - { /* AIX XL C 1.02.0.0 rejects this saying - "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ - struct s { int j; const int *ap[3]; }; - struct s *b; b->j = 5; - } - { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ - const int foo = 10; - if (!foo) return 0; - } - return !cs[0] && !zero.x; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_c_const=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_c_const=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5 -echo "${ECHO_T}$ac_cv_c_const" >&6; } -if test $ac_cv_c_const = no; then - -cat >>confdefs.h <<\_ACEOF -#define const -_ACEOF - -fi - - -{ echo "$as_me:$LINENO: checking whether char is unsigned" >&5 -echo $ECHO_N "checking whether char is unsigned... $ECHO_C" >&6; } -if test "${ac_cv_c_char_unsigned+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((char) -1) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_c_char_unsigned=no -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_c_char_unsigned=yes -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_c_char_unsigned" >&5 -echo "${ECHO_T}$ac_cv_c_char_unsigned" >&6; } -if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then - cat >>confdefs.h <<\_ACEOF -#define __CHAR_UNSIGNED__ 1 -_ACEOF - -fi - -{ echo "$as_me:$LINENO: checking for inline" >&5 -echo $ECHO_N "checking for inline... $ECHO_C" >&6; } -if test "${ac_cv_c_inline+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_cv_c_inline=no -for ac_kw in inline __inline__ __inline; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#ifndef __cplusplus -typedef int foo_t; -static $ac_kw foo_t static_foo () {return 0; } -$ac_kw foo_t foo () {return 0; } -#endif - -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_c_inline=$ac_kw -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - test "$ac_cv_c_inline" != no && break -done - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5 -echo "${ECHO_T}$ac_cv_c_inline" >&6; } - - -case $ac_cv_c_inline in - inline | yes) ;; - *) - case $ac_cv_c_inline in - no) ac_val=;; - *) ac_val=$ac_cv_c_inline;; - esac - cat >>confdefs.h <<_ACEOF -#ifndef __cplusplus -#define inline $ac_val -#endif -_ACEOF - ;; -esac - -{ echo "$as_me:$LINENO: checking for working volatile" >&5 -echo $ECHO_N "checking for working volatile... $ECHO_C" >&6; } -if test "${ac_cv_c_volatile+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -int -main () -{ - -volatile int x; -int * volatile y = (int *) 0; -return !x && !y; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_c_volatile=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_c_volatile=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5 -echo "${ECHO_T}$ac_cv_c_volatile" >&6; } -if test $ac_cv_c_volatile = no; then - -cat >>confdefs.h <<\_ACEOF -#define volatile -_ACEOF - -fi - - -if test x"$target_cpu" = xia64; then - case " $LIBOBJS " in - *" ia64.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS ia64.$ac_objext" - ;; -esac - - { echo "$as_me:$LINENO: checking for __libc_ia64_register_backing_store_base" >&5 -echo $ECHO_N "checking for __libc_ia64_register_backing_store_base... $ECHO_C" >&6; } -if test "${rb_cv___libc_ia64_register_backing_store_base+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - rb_cv___libc_ia64_register_backing_store_base=no - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -extern unsigned long __libc_ia64_register_backing_store_base; -int -main () -{ -unsigned long p = __libc_ia64_register_backing_store_base; - printf("%ld\n", p); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - rb_cv___libc_ia64_register_backing_store_base=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $rb_cv___libc_ia64_register_backing_store_base" >&5 -echo "${ECHO_T}$rb_cv___libc_ia64_register_backing_store_base" >&6; } - if test $rb_cv___libc_ia64_register_backing_store_base = yes; then - cat >>confdefs.h <<\_ACEOF -#define HAVE___LIBC_IA64_REGISTER_BACKING_STORE_BASE 1 -_ACEOF - - fi -fi - -{ echo "$as_me:$LINENO: checking whether right shift preserve sign bit" >&5 -echo $ECHO_N "checking whether right shift preserve sign bit... $ECHO_C" >&6; } -if test "${rb_cv_rshift_sign+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - rb_cv_rshift_sign=yes -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -int -main() -{ - if (-1==(-1>>1)) - return 0; - return 1; -} - -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - rb_cv_rshift_sign=yes -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -rb_cv_rshift_sign=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_rshift_sign" >&5 -echo "${ECHO_T}$rb_cv_rshift_sign" >&6; } -if test "$rb_cv_rshift_sign" = yes; then - cat >>confdefs.h <<\_ACEOF -#define RSHIFT(x,y) ((x)>>(int)y) -_ACEOF - -else - cat >>confdefs.h <<\_ACEOF -#define RSHIFT(x,y) (((x)<0) ? ~((~(x))>>y) : (x)>>y) -_ACEOF - -fi - -{ echo "$as_me:$LINENO: checking read count field in FILE structures" >&5 -echo $ECHO_N "checking read count field in FILE structures... $ECHO_C" >&6; } -if test "${rb_cv_fcnt+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - for fcnt in _cnt __cnt _r readCount _rcount ; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -int -main () -{ -FILE *f = stdin; f->$fcnt = 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_fcnt="$fcnt"; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_fcnt="not found" -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -fi - -if test "$rb_cv_fcnt" = "not found"; then - { echo "$as_me:$LINENO: result: not found(OK if using GNU libc)" >&5 -echo "${ECHO_T}not found(OK if using GNU libc)" >&6; } -else - { echo "$as_me:$LINENO: result: $rb_cv_fcnt" >&5 -echo "${ECHO_T}$rb_cv_fcnt" >&6; } - cat >>confdefs.h <<_ACEOF -#define FILE_COUNT $rb_cv_fcnt -_ACEOF - -fi - -{ echo "$as_me:$LINENO: checking read buffer ptr field in FILE structures" >&5 -echo $ECHO_N "checking read buffer ptr field in FILE structures... $ECHO_C" >&6; } -if test "${rb_cv_frptr+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - for frptr in _IO_read_ptr _ptr __ptr bufpos _p ; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -int -main () -{ -FILE *f = stdin; char buf[256]; f->$frptr = buf; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_frptr="$frptr"; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_frptr="not found" -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -fi - -if test "$rb_cv_frptr" = "not found"; then - { echo "$as_me:$LINENO: result: not found" >&5 -echo "${ECHO_T}not found" >&6; } -else - { echo "$as_me:$LINENO: result: $rb_cv_frptr" >&5 -echo "${ECHO_T}$rb_cv_frptr" >&6; } - cat >>confdefs.h <<_ACEOF -#define FILE_READPTR $rb_cv_frptr -_ACEOF - - - if test "$rb_cv_fcnt" = "not found"; then - { echo "$as_me:$LINENO: checking read buffer end field in FILE structures" >&5 -echo $ECHO_N "checking read buffer end field in FILE structures... $ECHO_C" >&6; } - if test "${rb_cv_frend+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - for frend in _IO_read_end bufread ; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -int -main () -{ -FILE *f = stdin; char buf[256]; f->$frend = buf; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_frend="$frend"; break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_frend="not found" -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -fi - - if test "$rb_cv_frend" = "not found"; then - { echo "$as_me:$LINENO: result: not found" >&5 -echo "${ECHO_T}not found" >&6; } - else - { echo "$as_me:$LINENO: result: $rb_cv_frend" >&5 -echo "${ECHO_T}$rb_cv_frend" >&6; } - cat >>confdefs.h <<_ACEOF -#define FILE_READEND $rb_cv_frend -_ACEOF - - fi - fi -fi - - -{ echo "$as_me:$LINENO: checking whether need to seek between R/W" >&5 -echo $ECHO_N "checking whether need to seek between R/W... $ECHO_C" >&6; } -if test "${rb_cv_need_io_seek_between_rw+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - rb_cv_need_io_seek_between_rw=yes -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#include -#ifndef SEEK_SET -#define SEEK_SET 0 -#endif -#ifndef SEEK_CUR -#define SEEK_CUR 1 -#endif -#define before_seek(f) fflush(f) -#define reset_rw(f) (f,0) -#define do_seek(f, w) (before_seek(f), fseek(f,0,w)) - -char *fn = "conftest.dat"; -char *wombat = "wombat\n"; -char *koara = "koara\n"; -char *kangaroo = "kangaroo\n"; - -int main() -{ - char buf[BUFSIZ]; - FILE *f; - int r = 1; - - if (!(f = fopen(fn, "w+"))) return 1; - fputs(wombat, f); - do_seek(f, SEEK_SET); - if (!fgets(buf, BUFSIZ, f) || strcmp(buf, wombat)) goto fail; - reset_rw(f); - fputs(koara, f); - fputs(kangaroo, f); - do_seek(f, SEEK_SET); - if (!fgets(buf, BUFSIZ, f) || strcmp(buf, wombat)) goto fail; - if (!fgets(buf, BUFSIZ, f) || strcmp(buf, koara)) goto fail; - if (!fgets(buf, BUFSIZ, f) || strcmp(buf, kangaroo)) goto fail; - do_seek(f, SEEK_SET); - if (!fgets(buf, BUFSIZ, f) || strcmp(buf, wombat)) goto fail; - reset_rw(f); - fputc('X', f); - reset_rw(f); - if (!fgets(buf, BUFSIZ, f) || strcmp(buf, koara+1)) goto fail; - if (!fgets(buf, BUFSIZ, f) || strcmp(buf, kangaroo)) goto fail; - do_seek(f, SEEK_SET); - if (!fgets(buf, BUFSIZ, f) || strcmp(buf, wombat)) goto fail; - if (!fgets(buf, BUFSIZ, f) || buf[0] != 'X' || strcmp(buf+1, koara+1)) goto fail; - if (!fgets(buf, BUFSIZ, f) || strcmp(buf, kangaroo)) goto fail; - r = 0; - fail: - fclose(f); - unlink(fn); - return r; -} - -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - rb_cv_need_io_seek_between_rw=no -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -rb_cv_need_io_seek_between_rw=yes -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_need_io_seek_between_rw" >&5 -echo "${ECHO_T}$rb_cv_need_io_seek_between_rw" >&6; } -if test "$rb_cv_need_io_seek_between_rw" = yes; then - cat >>confdefs.h <<\_ACEOF -#define NEED_IO_SEEK_BETWEEN_RW 1 -_ACEOF - -fi - -{ echo "$as_me:$LINENO: checking whether st_ino is huge" >&5 -echo $ECHO_N "checking whether st_ino is huge... $ECHO_C" >&6; } -if test "${rb_cv_huge_st_ino+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#include -struct stat test_stat; - -int -main () -{ -static int test_array [1 - 2 * !(sizeof(test_stat.st_ino)>sizeof(long))]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_huge_st_ino=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_huge_st_ino=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_huge_st_ino" >&5 -echo "${ECHO_T}$rb_cv_huge_st_ino" >&6; } -if test $rb_cv_huge_st_ino = yes; then - cat >>confdefs.h <<\_ACEOF -#define HUGE_ST_INO 1 -_ACEOF - -fi - -if test "$ac_cv_func_sysconf" = yes; then - - { echo "$as_me:$LINENO: checking whether _SC_CLK_TCK is supported" >&5 -echo $ECHO_N "checking whether _SC_CLK_TCK is supported... $ECHO_C" >&6; } -if test "${rb_cv_have_sc_clk_tck+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -int -main () -{ -_SC_CLK_TCK >= 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_have_sc_clk_tck=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_have_sc_clk_tck=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_have_sc_clk_tck" >&5 -echo "${ECHO_T}$rb_cv_have_sc_clk_tck" >&6; } - if test "$rb_cv_have_sc_clk_tck" = yes; then - cat >>confdefs.h <<\_ACEOF -#define HAVE__SC_CLK_TCK 1 -_ACEOF - - fi - -fi - -case "$target_cpu" in -m68*|i?86|ia64|sparc*|alpha*) rb_cv_stack_grow_dir=-1;; -hppa*) rb_cv_stack_grow_dir=+1;; -esac -{ echo "$as_me:$LINENO: checking stack growing direction" >&5 -echo $ECHO_N "checking stack growing direction... $ECHO_C" >&6; } -if test "${rb_cv_stack_grow_dir+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - rb_cv_stack_grow_dir=0 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* recurse to get rid of inlining */ -static int -stack_growup_p(addr, n) - volatile int *addr, n; -{ - volatile int end; - if (n > 0) - return *addr = stack_growup_p(addr, n - 1); - else - return (&end > addr); -} -int main() -{ - int x; - return stack_growup_p(&x, 10); -} - -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - rb_cv_stack_grow_dir=-1 -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -rb_cv_stack_grow_dir=+1 -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_stack_grow_dir" >&5 -echo "${ECHO_T}$rb_cv_stack_grow_dir" >&6; } -cat >>confdefs.h <<_ACEOF -#define STACK_GROW_DIRECTION $rb_cv_stack_grow_dir -_ACEOF - - -if test x"$enable_pthread" = xyes; then - for pthread_lib in pthread pthreads c c_r; do - as_ac_Lib=`echo "ac_cv_lib_$pthread_lib''_pthread_kill" | $as_tr_sh` -{ echo "$as_me:$LINENO: checking for pthread_kill in -l$pthread_lib" >&5 -echo $ECHO_N "checking for pthread_kill in -l$pthread_lib... $ECHO_C" >&6; } -if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-l$pthread_lib $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char pthread_kill (); -int -main () -{ -return pthread_kill (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - eval "$as_ac_Lib=yes" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_Lib=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -ac_res=`eval echo '${'$as_ac_Lib'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -if test `eval echo '${'$as_ac_Lib'}'` = yes; then - rb_with_pthread=yes -else - rb_with_pthread=no -fi - - if test "$rb_with_pthread" = "yes"; then break; fi - done - if test x"$rb_with_pthread" = xyes; then - cat >>confdefs.h <<\_ACEOF -#define _REENTRANT 1 -_ACEOF - - cat >>confdefs.h <<\_ACEOF -#define _THREAD_SAFE 1 -_ACEOF - - cat >>confdefs.h <<\_ACEOF -#define HAVE_LIBPTHREAD 1 -_ACEOF - - case $pthread_lib in - c) - ;; - c_r) - MAINLIBS="-pthread $MAINLIBS" - ;; - *) - LIBS="-l$pthread_lib $LIBS" - ;; - esac - else - { echo "$as_me:$LINENO: WARNING: \"Don't know how to find pthread library on your system -- thread support disabled\"" >&5 -echo "$as_me: WARNING: \"Don't know how to find pthread library on your system -- thread support disabled\"" >&2;} - fi - -for ac_func in nanosleep -do -as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ echo "$as_me:$LINENO: checking for $ac_func" >&5 -echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - eval "$as_ac_var=yes" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval echo '${'$as_ac_var'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -if test `eval echo '${'$as_ac_var'}'` = yes; then - cat >>confdefs.h <<_ACEOF -#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - - if test x"$ac_cv_func_nanosleep" = xno; then - -{ echo "$as_me:$LINENO: checking for nanosleep in -lrt" >&5 -echo $ECHO_N "checking for nanosleep in -lrt... $ECHO_C" >&6; } -if test "${ac_cv_lib_rt_nanosleep+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lrt $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char nanosleep (); -int -main () -{ -return nanosleep (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_lib_rt_nanosleep=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_rt_nanosleep=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ echo "$as_me:$LINENO: result: $ac_cv_lib_rt_nanosleep" >&5 -echo "${ECHO_T}$ac_cv_lib_rt_nanosleep" >&6; } -if test $ac_cv_lib_rt_nanosleep = yes; then - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBRT 1 -_ACEOF - - LIBS="-lrt $LIBS" - -fi - - if test x"$ac_cv_lib_rt_nanosleep" = xyes; then - cat >>confdefs.h <<\_ACEOF -#define HAVE_NANOSLEEP 1 -_ACEOF - - fi - fi -fi -if test x"$ac_cv_header_ucontext_h" = xyes; then - if test x"$rb_with_pthread" = xyes; then - - -for ac_func in getcontext setcontext -do -as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ echo "$as_me:$LINENO: checking for $ac_func" >&5 -echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - eval "$as_ac_var=yes" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval echo '${'$as_ac_var'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -if test `eval echo '${'$as_ac_var'}'` = yes; then - cat >>confdefs.h <<_ACEOF -#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - - fi -fi - -DEFAULT_KCODE="KCODE_NONE" - - -# Check whether --with-default-kcode was given. -if test "${with_default_kcode+set}" = set; then - withval=$with_default_kcode; case $withval in - utf8) DEFAULT_KCODE="KCODE_UTF8";; - euc) DEFAULT_KCODE="KCODE_EUC";; - sjis) DEFAULT_KCODE="KCODE_SJIS";; - none) DEFAULT_KCODE="KCODE_NONE";; - *) { echo "$as_me:$LINENO: WARNING: $withval is not valid kcode; ignored" >&5 -echo "$as_me: WARNING: $withval is not valid kcode; ignored" >&2;};; - esac -fi - -cat >>confdefs.h <<_ACEOF -#define DEFAULT_KCODE $DEFAULT_KCODE -_ACEOF - - - -# Check whether --with-dln-a-out was given. -if test "${with_dln_a_out+set}" = set; then - withval=$with_dln_a_out; - case $withval in - yes) with_dln_a_out=yes;; - *) with_dln_a_out=no;; - esac -else - with_dln_a_out=no -fi - - -{ echo "$as_me:$LINENO: checking whether ELF binaries are produced" >&5 -echo $ECHO_N "checking whether ELF binaries are produced... $ECHO_C" >&6; } -if test "${rb_cv_binary_elf+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - rb_cv_binary_elf=yes -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Test for whether ELF binaries are produced */ -#include -#include -main() { - char buffer[4]; - int i=open("conftest",O_RDONLY); - if(i==-1) - exit(1); /* fail */ - if(read(i,&buffer[0],4)<4) - exit(1); /* fail */ - if(buffer[0] != 127 || buffer[1] != 'E' || - buffer[2] != 'L' || buffer[3] != 'F') - exit(1); /* fail */ - exit(0); /* succeed (yes, it's ELF) */ -} - -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - rb_cv_binary_elf=yes -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -rb_cv_binary_elf=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_binary_elf" >&5 -echo "${ECHO_T}$rb_cv_binary_elf" >&6; } - -if test "$rb_cv_binary_elf" = yes; then - cat >>confdefs.h <<\_ACEOF -#define USE_ELF 1 -_ACEOF - -fi - -case "$target_os" in -linux* | gnu* | k*bsd*-gnu | bsdi*) - if test "$rb_cv_binary_elf" = no; then - with_dln_a_out=yes - else - LDFLAGS="$LDFLAGS -rdynamic" - fi;; -esac -LIBEXT=a - - - -STATIC= -: ${LIBPATHFLAG=' -L%s'} -: ${PATHFLAG=''} - -if test "$with_dln_a_out" != yes; then - rb_cv_dlopen=unknown - { echo "$as_me:$LINENO: checking whether OS depend dynamic link works" >&5 -echo $ECHO_N "checking whether OS depend dynamic link works... $ECHO_C" >&6; } - if test "$GCC" = yes; then - case "$target_os" in - nextstep*) CCDLFLAGS="$CCDLFLAGS -fno-common";; - openstep*) CCDLFLAGS="$CCDLFLAGS -fno-common";; - rhapsody*) CCDLFLAGS="$CCDLFLAGS -fno-common";; - darwin*) CCDLFLAGS="$CCDLFLAGS -fno-common";; - human*|bsdi*|beos*|cygwin*|mingw*|aix*|interix*) ;; - *) CCDLFLAGS="$CCDLFLAGS -fPIC";; - esac - else - case "$target_os" in - hpux*) CCDLFLAGS="$CCDLFLAGS +Z";; - solaris*|irix*) CCDLFLAGS="$CCDLFLAGS -KPIC" ;; - sunos*) CCDLFLAGS="$CCDLFLAGS -PIC" ;; - esix*|uxpds*) CCDLFLAGS="$CCDLFLAGS -KPIC" ;; - *) : ${CCDLFLAGS=""} ;; - esac - fi - - - # Check whether --enable-rpath was given. -if test "${enable_rpath+set}" = set; then - enableval=$enable_rpath; enable_rpath=$enableval -else - enable_rpath="$rb_cv_binary_elf" -fi - - if test "$enable_rpath" = yes; then - LIBPATHFLAG=" -L%1\$-s" - RPATHFLAG=" ${linker_flag}-R%1\$-s" - fi - - case "$target_os" in - hpux*) DLDFLAGS="$DLDFLAGS -E" - : ${LDSHARED='ld -b'} - XLDFLAGS="$XLDFLAGS -Wl,-E" - : ${LIBPATHENV=SHLIB_PATH} - if test "$rb_cv_prog_gnu_ld" = no; then - RPATHFLAG=' +b %1$-s' - fi - rb_cv_dlopen=yes;; - solaris*) if test "$GCC" = yes; then - : ${LDSHARED='$(CC) -shared'} - if test "$rb_cv_prog_gnu_ld" = yes; then - LDFLAGS="$LDFLAGS -Wl,-E" - fi - else - : ${LDSHARED='ld -G'} - fi - rb_cv_dlopen=yes;; - sunos*) : ${LDSHARED='ld -assert nodefinitions'} - rb_cv_dlopen=yes;; - irix*) : ${LDSHARED='ld -shared'} - rb_cv_dlopen=yes;; - sysv4*) : ${LDSHARED='ld -G'} - rb_cv_dlopen=yes;; - nto-qnx*) : ${LDSHARED="qcc -shared"} - rb_cv_dlopen=yes ;; - esix*|uxpds*) : ${LDSHARED="ld -G"} - rb_cv_dlopen=yes ;; - osf*) : ${LDSHARED="ld -shared -expect_unresolved \"*\""} - rb_cv_dlopen=yes ;; - bsdi3*) case "$CC" in - *shlicc*) : ${LDSHARED="$CC -r"} - rb_cv_dlopen=yes ;; - esac ;; - linux* | gnu* | k*bsd*-gnu | netbsd* | bsdi*) - : ${LDSHARED='${CC} -shared'} - if test "$rb_cv_binary_elf" = yes; then - LDFLAGS="$LDFLAGS -Wl,-export-dynamic" - fi - rb_cv_dlopen=yes ;; - interix*) : ${LDSHARED="$CC -shared"} - XLDFLAGS="$XLDFLAGS -Wl,-E" - LIBPATHFLAG=" -L%1\$-s" - rb_cv_dlopen=yes ;; - freebsd*|dragonfly*) : ${LDSHARED="$CC -shared"} - if test "$rb_cv_binary_elf" = yes; then - LDFLAGS="$LDFLAGS -rdynamic" - DLDFLAGS="$DLDFLAGS "'-Wl,-soname,$(.TARGET)' - else - test "$GCC" = yes && test "$rb_cv_prog_gnu_ld" = yes || LDSHARED="ld -Bshareable" - fi - rb_cv_dlopen=yes ;; - openbsd*) : ${LDSHARED="\$(CC) -shared ${CCDLFLAGS}"} - if test "$rb_cv_binary_elf" = yes; then - LDFLAGS="$LDFLAGS -Wl,-E" - fi - rb_cv_dlopen=yes ;; - nextstep*) : ${LDSHARED='cc -r -nostdlib'} - LDFLAGS="$LDFLAGS -u libsys_s" - rb_cv_dlopen=yes ;; - openstep*) : ${LDSHARED='cc -dynamic -bundle -undefined suppress'} - : ${LDFLAGS=""} - rb_cv_dlopen=yes ;; - rhapsody*) : ${LDSHARED='cc -dynamic -bundle -undefined suppress'} - : ${LDFLAGS=""} - rb_cv_dlopen=yes ;; - darwin*) : ${LDSHARED='cc -dynamic -bundle -undefined suppress -flat_namespace'} - : ${LDFLAGS=""} - : ${LIBPATHENV=DYLD_LIBRARY_PATH} - rb_cv_dlopen=yes ;; - aix*) if test "$GCC" = yes; then - : ${LDSHARED='$(CC) -shared'} - else - : ${LDSHARED='$(CC)'} - fi - LDSHARED="$LDSHARED ${linker_flag}-G" - DLDFLAGS='-eInit_$(TARGET)' - XLDFLAGS="${linker_flag}-bE:ruby.imp ${linker_flag}-brtl" - : ${ARCHFILE="ruby.imp"} - TRY_LINK='$(CC) $(LDFLAGS) -oconftest $(INCFLAGS) -I$(hdrdir) $(CPPFLAGS)' - TRY_LINK="$TRY_LINK"' $(CFLAGS) $(src) $(LIBPATH) $(LOCAL_LIBS) $(LIBS)' - : ${LIBPATHENV=SHLIB_PATH} - rb_cv_dlopen=yes ;; - human*) : ${DLDFLAGS=''} - : ${LDSHARED=''} - : ${LDFLAGS=''} - : ${LINK_SO='ar cru $@ $(OBJS)'} - rb_cv_dlopen=yes ;; - beos*) case "$target_cpu" in - powerpc*) - : ${LDSHARED="ld -xms"} - DLDFLAGS="$DLDFLAGS "'-export Init_$(TARGET) -lbe -lroot glue-noinit.a init_term_dyn.o start_dyn.o' - ;; - i586*) - : ${LDSHARED="ld -shared"} - DLDFLAGS="$DLDFLAGS -L/boot/develop/lib/x86 -lbe -lroot" - ;; - esac - : ${LIBPATHENV=LIBRARY_PATH} - rb_cv_dlopen=yes ;; - nto-qnx*) DLDFLAGS="$DLDFLAGS -L/lib -L/usr/lib -L/usr/local/lib" - : ${LDSHARED='ld -Bshareable -x'} - LDFLAGS="$LDFLAGS -L/lib -L/usr/lib -L/usr/local/lib" - rb_cv_dlopen=yes;; - cygwin*|mingw*) : ${LDSHARED="${CC} -shared -s"} - XLDFLAGS="$XLDFLAGS -Wl,--stack,0x02000000" - DLDFLAGS="${DLDFLAGS} -Wl,--enable-auto-image-base,--enable-auto-import,--export-all" - : ${LIBPATHENV=""} - rb_cv_dlopen=yes ;; - hiuxmpp) : ${LDSHARED='ld -r'} ;; - atheos*) : ${LDSHARED="$CC -shared"} - rb_cv_dlopen=yes ;; - os2-emx*) LDFLAGS="$LDFLAGS -Zbsd-signals" - ;; - *) : ${LDSHARED='ld'} ;; - esac - { echo "$as_me:$LINENO: result: $rb_cv_dlopen" >&5 -echo "${ECHO_T}$rb_cv_dlopen" >&6; } -fi - - - -LIBPATHENV="${LIBPATHENV-LD_LIBRARY_PATH}" - - - -dln_a_out_works=no -if test "$ac_cv_header_a_out_h" = yes; then - if test "$with_dln_a_out" = yes || test "$rb_cv_dlopen" = unknown; then - cat confdefs.h > config.h - { echo "$as_me:$LINENO: checking whether matz's dln works" >&5 -echo $ECHO_N "checking whether matz's dln works... $ECHO_C" >&6; } -if test "${rb_cv_dln_a_out+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define USE_DLN_A_OUT -#include "dln.c" - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - rb_cv_dln_a_out=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - rb_cv_dln_a_out=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ echo "$as_me:$LINENO: result: $rb_cv_dln_a_out" >&5 -echo "${ECHO_T}$rb_cv_dln_a_out" >&6; } - if test "$rb_cv_dln_a_out" = yes; then - dln_a_out_works=yes - cat >>confdefs.h <<\_ACEOF -#define USE_DLN_A_OUT 1 -_ACEOF - - fi - fi -fi - -if test "$dln_a_out_works" = yes; then - if test "$GCC" = yes; then - STATIC=-static - else - STATIC=-Bstatic - fi - DLEXT=so - CCDLFLAGS= -else - case "$target_os" in - hpux*) DLEXT=sl;; - nextstep*|openstep*|rhapsody*|darwin*) - DLEXT=bundle;; - os2-emx*) DLEXT=dll;; - cygwin*|mingw*) - DLEXT=so DLEXT2=dll;; - *) DLEXT=so;; - esac -fi -len=2 # .rb -n=`expr "$DLEXT" : '.*'`; test "$n" -gt "$len" && len=$n -n=`expr "$DLEXT2" : '.*'`; test "$n" -gt "$len" && len=$n -cat >>confdefs.h <<_ACEOF -#define DLEXT_MAXLEN `expr $len + 1` -_ACEOF - -test ".$DLEXT" = "." || cat >>confdefs.h <<_ACEOF -#define DLEXT ".$DLEXT" -_ACEOF - -test ".$DLEXT2" = "." || cat >>confdefs.h <<_ACEOF -#define DLEXT2 ".$DLEXT2" -_ACEOF - - -if test "$with_dln_a_out" = yes; then - STRIP=true -else - STRIP=strip -fi - -case "$target_os" in - linux* | gnu* | k*bsd*-gnu) - STRIP='strip -S -x';; - nextstep*) - STRIP='strip -A -n';; - openstep*) - STRIP='strip -A -n';; - rhapsody*) - STRIP='strip -A -n';; - darwin*) - STRIP='strip -A -n';; -esac - -EXTSTATIC= - -# Check whether --with-static-linked-ext was given. -if test "${with_static_linked_ext+set}" = set; then - withval=$with_static_linked_ext; case $withval in - yes) STATIC= - EXTSTATIC=static;; - *) ;; - esac -fi - - -case "$target_os" in - human*) - -{ echo "$as_me:$LINENO: checking for _harderr in -lsignal" >&5 -echo $ECHO_N "checking for _harderr in -lsignal... $ECHO_C" >&6; } -if test "${ac_cv_lib_signal__harderr+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lsignal $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char _harderr (); -int -main () -{ -return _harderr (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_lib_signal__harderr=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_signal__harderr=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ echo "$as_me:$LINENO: result: $ac_cv_lib_signal__harderr" >&5 -echo "${ECHO_T}$ac_cv_lib_signal__harderr" >&6; } -if test $ac_cv_lib_signal__harderr = yes; then - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBSIGNAL 1 -_ACEOF - - LIBS="-lsignal $LIBS" - -fi - - -{ echo "$as_me:$LINENO: checking for hmemset in -lhmem" >&5 -echo $ECHO_N "checking for hmemset in -lhmem... $ECHO_C" >&6; } -if test "${ac_cv_lib_hmem_hmemset+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lhmem $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char hmemset (); -int -main () -{ -return hmemset (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - ac_cv_lib_hmem_hmemset=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_hmem_hmemset=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ echo "$as_me:$LINENO: result: $ac_cv_lib_hmem_hmemset" >&5 -echo "${ECHO_T}$ac_cv_lib_hmem_hmemset" >&6; } -if test $ac_cv_lib_hmem_hmemset = yes; then - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBHMEM 1 -_ACEOF - - LIBS="-lhmem $LIBS" - -fi - - -for ac_func in select -do -as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ echo "$as_me:$LINENO: checking for $ac_func" >&5 -echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && - $as_test_x conftest$ac_exeext; then - eval "$as_ac_var=yes" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval echo '${'$as_ac_var'}'` - { echo "$as_me:$LINENO: result: $ac_res" >&5 -echo "${ECHO_T}$ac_res" >&6; } -if test `eval echo '${'$as_ac_var'}'` = yes; then - cat >>confdefs.h <<_ACEOF -#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - - { echo "$as_me:$LINENO: checking whether PD libc _dtos18 fail to convert big number" >&5 -echo $ECHO_N "checking whether PD libc _dtos18 fail to convert big number... $ECHO_C" >&6; } -if test "${rb_cv_missing__dtos18+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - rb_cv_missing__dtos18=no -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#include -main () -{ - char buf[256]; - sprintf (buf, "%g", 1e+300); - exit (strcmp (buf, "1e+300") ? 0 : 1); -} - -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - rb_cv_missing__dtos18=yes -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -rb_cv_missing__dtos18=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_missing__dtos18" >&5 -echo "${ECHO_T}$rb_cv_missing__dtos18" >&6; } - if test "$rb_cv_missing__dtos18" = yes; then - cat >>confdefs.h <<\_ACEOF -#define MISSING__DTOS18 1 -_ACEOF - - fi - { echo "$as_me:$LINENO: checking whether PD libc fconvert fail to round" >&5 -echo $ECHO_N "checking whether PD libc fconvert fail to round... $ECHO_C" >&6; } -if test "${rb_cv_missing_fconvert+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "$cross_compiling" = yes; then - rb_cv_missing_fconvert=no -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#include -#include -main () -{ - char buf[256]; - sprintf (buf, "%f", log(exp(1.0))); - exit (strcmp (buf, "1.000000") ? 0 : 1); -} - -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - rb_cv_missing_fconvert=yes -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -rb_cv_missing_fconvert=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -{ echo "$as_me:$LINENO: result: $rb_cv_missing_fconvert" >&5 -echo "${ECHO_T}$rb_cv_missing_fconvert" >&6; } - if test "$rb_cv_missing_fconvert" = yes; then - cat >>confdefs.h <<\_ACEOF -#define MISSING_FCONVERT 1 -_ACEOF - - fi - case " $LIBOBJS " in - *" x68.o.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS x68.o.$ac_objext" - ;; -esac - - CFLAGS="$CFLAGS -fansi-only" - XCFLAGS="$XCFLAGS -cc1-stack=262144 -cpp-stack=2694144" - EXEEXT=.x - OBJEXT=o - setup=Setup.x68 - ;; - os2-emx) - case " $LIBOBJS " in - *" os2.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS os2.$ac_objext" - ;; -esac - - setup=Setup.emx - ;; - *djgpp*) - setup=Setup.dj - ;; - *) - setup=Setup - ;; -esac - - - -if test "$prefix" = NONE; then - prefix=$ac_default_prefix -fi - -#if test "$fat_binary" != no ; then -# CFLAGS="$CFLAGS $ARCH_FLAG" -#fi - -if test x"$cross_compiling" = xyes; then - test x"$MINIRUBY" = x && MINIRUBY="${RUBY-ruby} -I`pwd` -rfake" - PREP=fake.rb - RUNRUBY='$(MINIRUBY) -I`cd $(srcdir)/lib; pwd`' -else - MINIRUBY='./miniruby$(EXEEXT) -I$(srcdir)/lib' - MINIRUBY="$MINIRUBY"' -I$(EXTOUT)/common -I./- -r$(srcdir)/ext/purelib.rb' - PREP='miniruby$(EXEEXT)' - RUNRUBY='$(MINIRUBY) $(srcdir)/runruby.rb --extout=$(EXTOUT)' -fi - - - -EXTOUT=${EXTOUT-.ext} - - -FIRSTMAKEFILE="" -LIBRUBY_A='lib$(RUBY_SO_NAME)-static.a' -LIBRUBY='$(LIBRUBY_A)' -LIBRUBYARG_STATIC='-l$(RUBY_SO_NAME)-static' -LIBRUBYARG='$(LIBRUBYARG_STATIC)' -SOLIBS= - -case "$target_os" in - cygwin*|mingw*|beos*|openstep*|nextstep*|rhapsody*|darwin*|os2-emx*) - : ${DLDLIBS=""} - ;; - *) - DLDLIBS="$DLDLIBS -lc" - ;; -esac - -RUBY_SO_NAME='$(RUBY_INSTALL_NAME)' -LIBRUBY_LDSHARED=$LDSHARED -LIBRUBY_DLDFLAGS=$DLDFLAGS -LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR).$(MINOR).$(TEENY)' -LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).so' -ENABLE_SHARED=no - -# Check whether --enable-shared was given. -if test "${enable_shared+set}" = set; then - enableval=$enable_shared; enable_shared=$enableval -fi - -if test "$enable_shared" = 'yes'; then - LIBRUBY='$(LIBRUBY_SO)' - LIBRUBYARG_SHARED='-l$(RUBY_SO_NAME)' - LIBRUBYARG='$(LIBRUBYARG_SHARED)' - CFLAGS="$CFLAGS $CCDLFLAGS" - ENABLE_SHARED=yes - if test "$rb_cv_binary_elf" = yes; then - SOLIBS='$(LIBS)' - fi - case "$target_os" in - sunos4*) - LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).so.$(MAJOR).$(MINOR) lib$(RUBY_SO_NAME).so' - ;; - linux* | gnu* | k*bsd*-gnu | atheos*) - LIBRUBY_DLDFLAGS='-Wl,-soname,lib$(RUBY_SO_NAME).so.$(MAJOR).$(MINOR)' - LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).so.$(MAJOR).$(MINOR) lib$(RUBY_SO_NAME).so' - ;; - freebsd*|dragonfly*) - SOLIBS='$(LIBS)' - LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR)' - if test "$rb_cv_binary_elf" != "yes" ; then - LIBRUBY_SO="$LIBRUBY_SO.\$(TEENY)" - LIBRUBY_ALIASES='' - fi - ;; - netbsd*) - SOLIBS='$(LIBS)' - LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR).$(TEENY)' - LIBRUBY_DLDFLAGS='-Wl,-soname,lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR)' - if test "$rb_cv_binary_elf" = yes; then # ELF platforms - LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR) lib$(RUBY_SO_NAME).so' - else # a.out platforms - LIBRUBY_ALIASES="" - fi - ;; - openbsd*) - SOLIBS='$(LIBS)' - LIBRUBY_SO='lib$(RUBY_INSTALL_NAME).so.$(MAJOR).'`expr ${MINOR} \* 10 + ${TEENY}` - ;; - solaris*) - SOLIBS='$(LIBS)' - LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR)' - LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).so.$(MAJOR).$(MINOR).$(TEENY) lib$(RUBY_SO_NAME).so' - if test "$GCC" = yes; then - LIBRUBY_DLDFLAGS="$DLDFLAGS "'-Wl,-h,$(@F)' - fi - XLDFLAGS="$XLDFLAGS "'-R${libdir}' - ;; - hpux*) - XLDFLAGS="$XLDFLAGS "'-Wl,+s,+b,$(libdir)' - LIBRUBY_SO='lib$(RUBY_SO_NAME).sl.$(MAJOR).$(MINOR).$(TEENY)' - LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).sl.$(MAJOR).$(MINOR) lib$(RUBY_SO_NAME).sl' - ;; - aix*) - LIBRUBY_DLDFLAGS="${linker_flag}-bnoentry $XLDFLAGS" - LIBRUBYARG_SHARED='-L${libdir} -l${RUBY_SO_NAME}' - SOLIBS='-lm -lc' - ;; - beos*) - case "$target_cpu" in - powerpc*) - LIBRUBY_DLDFLAGS='-f ruby.exp -lnet -lbe -lroot glue-noinit.a init_term_dyn.o start_dyn.o' - ;; - esac - ;; - darwin*) - LIBRUBY_SO='lib$(RUBY_SO_NAME).$(MAJOR).$(MINOR).$(TEENY).dylib' - LIBRUBY_LDSHARED='cc -dynamiclib -undefined suppress -flat_namespace' - LIBRUBY_DLDFLAGS='-install_name $(libdir)/lib$(RUBY_SO_NAME).dylib -current_version $(MAJOR).$(MINOR).$(TEENY) -compatibility_version $(MAJOR).$(MINOR)' - LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).$(MAJOR).$(MINOR).dylib lib$(RUBY_SO_NAME).dylib' - ;; - interix*) - LIBRUBYARG_SHARED='-L. -L${libdir} -l$(RUBY_SO_NAME)' - ;; - *) - ;; - esac -fi -if test "$enable_rpath" = yes; then - LIBRUBYARG_SHARED="${linker_flag}-R ${linker_flag}\$(libdir) -L\$(libdir) $LIBRUBYARG_SHARED" -fi - -LDFLAGS="-L. $LDFLAGS" - - -RDOCTARGET="" -# Check whether --enable-install-doc was given. -if test "${enable_install_doc+set}" = set; then - enableval=$enable_install_doc; install_doc=$enableval -else - install_doc=no -fi - -if test "$install_doc" != no; then - RDOCTARGET="install-doc" -fi - - -case "$target_os" in - linux*) - XCFLAGS="$XCFLAGS -D_GNU_SOURCE=1" - ;; - netbsd*) - CFLAGS="$CFLAGS -pipe" - ;; - nextstep*|openstep*) - # The -fno-common is needed if we wish to embed the Ruby interpreter - # into a plugin module of some project (as opposed to embedding it - # within the project's application). The -I/usr/local/include is - # needed because CPP as discovered by configure (cc -E -traditional) - # fails to consult /usr/local/include by default. This causes - # mkmf.rb's have_header() to fail if the desired resource happens to be - # installed in the /usr/local tree. - CFLAGS="$CFLAGS -pipe -fno-common" - CPPFLAGS="$CPPFLAGS -I/usr/local/include" - ;; - rhapsody*) - CFLAGS="$CFLAGS -pipe -no-precomp -fno-common" - ;; - darwin*) - CFLAGS="$CFLAGS -pipe -fno-common" - MINIOBJS=dmydln.o - ;; - os2-emx) - CFLAGS="$CFLAGS -DOS2 -Zmts" - LIBRUBY_A=`echo $LIBRUBY_A | sed 's/^lib//'` - LIBRUBY_SO=`echo $LIBRUBY_SO | sed 's/^lib//'` - LIBRUBY_ALIASES=`for i in $LIBRUBY_ALIASES; do echo "$i"; done | sed 's/^lib//'` - ;; - osf*) - if test "$GCC" != "yes" ; then - # compile something small: taint.c is fine for this. - # the main point is the '-v' flag of 'cc'. - case "`cc -v -I. -c main.c -o /tmp/main.o 2>&1`" in - */gemc_cc*) # we have the new DEC GEM CC - CFLAGS="$CFLAGS -oldc" - ;; - *) # we have the old MIPS CC - ;; - esac - # cleanup - rm -f /tmp/main.o - CFLAGS="$CFLAGS -std" - fi - ;; - beos*) - case "$target_cpu" in - powerpc*) - CFLAGS="$CFLAGS -relax_pointers" - ;; - esac - ;; - cygwin*|mingw*) - case "$target_os" in - cygwin*) - if test x"$enable_shared" = xyes; then - LIBRUBY_SO='cyg$(RUBY_SO_NAME)'${MAJOR}${MINOR}.dll - LIBRUBY='lib$(RUBY_SO_NAME).dll.a' - fi - ;; - mingw*) - RUBY_SO_NAME=${rb_cv_msvcrt}-'$(RUBY_INSTALL_NAME)'${MAJOR}${MINOR} - if test x"$enable_shared" = xyes; then - LIBRUBY_SO='$(RUBY_SO_NAME)'.dll - LIBRUBY='lib$(LIBRUBY_SO).a' - fi - case " $LIBOBJS " in - *" win32.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS win32.$ac_objext" - ;; -esac - - COMMON_LIBS=m -# COMMON_MACROS="WIN32_LEAN_AND_MEAN=" - COMMON_HEADERS="windows.h winsock.h" - ;; - esac - LIBRUBY_DLDFLAGS="${DLDFLAGS}"' -Wl,--out-implib=$(LIBRUBY)' - LIBRUBY_ALIASES='' - FIRSTMAKEFILE=GNUmakefile:cygwin/GNUmakefile.in - SOLIBS='$(LIBS)' - if test x"$enable_shared" = xno; then - LIBRUBY_SO=dummy - LIBRUBY='lib$(RUBY_SO_NAME).a' - LIBRUBYARG='-l$(RUBY_SO_NAME)' - fi - MINIOBJS=dmydln.o - ;; - hpux*) - case "$YACC" in - *yacc*) - XCFLAGS="$XCFLAGS -DYYMAXDEPTH=300" - YACC="$YACC -Nl40000 -Nm40000" - ;; - esac - MINIOBJS=dmydln.o - ;; - *) - ;; -esac - -case "$build_os" in - *msdosdjgpp*) FIRSTMAKEFILE=GNUmakefile:djgpp/GNUmakefile.in;; -esac - -CPPFLAGS="$CPPFLAGS "'$(DEFS)' -test -z "$CFLAGS" || CFLAGS="$CFLAGS "; CFLAGS="$CFLAGS"'${cflags}' -test -z "$CPPFLAGS" || CPPFLAGS="$CPPFLAGS "; CPPFLAGS="$CPPFLAGS"'${cppflags}' -cflags='${optflags} ${debugflags}' - - - - - - - - - - - - - - - - - - - - - - - -MAKEFILES="Makefile `echo $FIRSTMAKEFILE | sed 's/:.*//'`" -MAKEFILES="`echo $MAKEFILES`" - - -ri_prefix= -test "$program_prefix" != NONE && - ri_prefix=$program_prefix - -ri_suffix= -test "$program_suffix" != NONE && - ri_suffix=$program_suffix - -RUBY_INSTALL_NAME="${ri_prefix}ruby${ri_suffix}" -case "$target_os" in - cygwin*|mingw*) - RUBYW_INSTALL_NAME="${ri_prefix}rubyw${ri_suffix}" - rubyw_install_name="$RUBYW_INSTALL_NAME" - ;; -esac -RUBY_LIB_PREFIX=`eval echo \\"${libdir}/ruby\\"` - - -# Check whether --with-sitedir was given. -if test "${with_sitedir+set}" = set; then - withval=$with_sitedir; sitedir=$withval -else - sitedir='${libdir}/ruby/site_ruby' -fi - -SITE_DIR=`eval echo \\"${sitedir}\\"` - -case "$target_os" in - cygwin*|mingw*|*djgpp*|os2-emx*) - RUBY_LIB_PREFIX="`eval echo "$RUBY_LIB_PREFIX" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" - RUBY_SITE_LIB_PATH="`eval echo "$SITE_DIR" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" - ;; - *) - RUBY_LIB_PREFIX="`eval echo \\"$RUBY_LIB_PREFIX\\" | sed 's|^NONE/|'"$prefix"'/|'`" - RUBY_SITE_LIB_PATH="`eval echo \\"$SITE_DIR\\" | sed 's|^NONE/|'"$prefix"'/|'`" - ;; -esac -RUBY_LIB_PATH="${RUBY_LIB_PREFIX}/${MAJOR}.${MINOR}" -RUBY_SITE_LIB_PATH2="${RUBY_SITE_LIB_PATH}/${MAJOR}.${MINOR}" - -cat >>confdefs.h <<_ACEOF -#define RUBY_LIB "${RUBY_LIB_PATH}" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define RUBY_SITE_LIB "${RUBY_SITE_LIB_PATH}" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define RUBY_SITE_LIB2 "${RUBY_SITE_LIB_PATH2}" -_ACEOF - - - -# Check whether --with-vendordir was given. -if test "${with_vendordir+set}" = set; then - withval=$with_vendordir; vendordir=$withval -else - vendordir='${libdir}/ruby/vendor_ruby' -fi - -VENDOR_DIR=`eval echo \\"${vendordir}\\"` -case "$target_os" in - cygwin*|mingw*|*djgpp*|os2-emx*) - RUBY_VENDOR_LIB_PATH="`eval echo "$VENDOR_DIR" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" - ;; - *) - RUBY_VENDOR_LIB_PATH="`eval echo \\"$VENDOR_DIR\\" | sed 's|^NONE/|'"$prefix"'/|'`" - ;; -esac -RUBY_VENDOR_LIB_PATH2="${RUBY_VENDOR_LIB_PATH}/${MAJOR}.${MINOR}" - -cat >>confdefs.h <<_ACEOF -#define RUBY_VENDOR_LIB "${RUBY_VENDOR_LIB_PATH}" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define RUBY_VENDOR_LIB2 "${RUBY_VENDOR_LIB_PATH2}" -_ACEOF - - - -configure_args=$ac_configure_args - -if test "$fat_binary" != no ; then - arch="fat-${target_os}" - - cat >>confdefs.h <<_ACEOF -#define RUBY_THIN_ARCHLIB "${RUBY_LIB_PATH}/" __ARCHITECTURE__ "-${target_os}" -_ACEOF - - - cat >>confdefs.h <<_ACEOF -#define RUBY_SITE_THIN_ARCHLIB "${RUBY_SITE_LIB_PATH}/" __ARCHITECTURE__ "-${target_os}" -_ACEOF - - cat >>confdefs.h <<_ACEOF -#define RUBY_VENDOR_THIN_ARCHLIB "${RUBY_VENDOR_LIB_PATH}/" __ARCHITECTURE__ "-${target_os}" -_ACEOF - - cat >>confdefs.h <<_ACEOF -#define RUBY_PLATFORM __ARCHITECTURE__ "-${target_os}" -_ACEOF - -else - arch="${target_cpu}-${target_os}" - cat >>confdefs.h <<_ACEOF -#define RUBY_PLATFORM "${arch}" -_ACEOF - -fi - -case "$target_os" in - mingw*) sitearch="$target_cpu-$rb_cv_msvcrt" ;; - *) sitearch="${arch}" ;; -esac - -cat >>confdefs.h <<_ACEOF -#define RUBY_ARCHLIB "${RUBY_LIB_PATH}/${arch}" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define RUBY_SITE_ARCHLIB "${RUBY_SITE_LIB_PATH2}/${sitearch}" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define RUBY_VENDOR_ARCHLIB "${RUBY_VENDOR_LIB_PATH2}/${sitearch}" -_ACEOF - - - -# Check whether --with-search-path was given. -if test "${with_search_path+set}" = set; then - withval=$with_search_path; search_path=$withval -fi - -if test "$search_path" != ""; then - cat >>confdefs.h <<_ACEOF -#define RUBY_SEARCH_PATH "$search_path" -_ACEOF - -fi - - -# Check whether --with-mantype was given. -if test "${with_mantype+set}" = set; then - withval=$with_mantype; - case "$withval" in - man|doc) - MANTYPE=$withval - ;; - *) - { { echo "$as_me:$LINENO: error: invalid man type: $withval" >&5 -echo "$as_me: error: invalid man type: $withval" >&2;} - { (exit 1); exit 1; }; } - ;; - esac - -fi - -if test -z "$MANTYPE"; then - for ac_prog in nroff awf -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } -if test "${ac_cv_path_NROFF+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - case $NROFF in - [\\/]* | ?:[\\/]*) - ac_cv_path_NROFF="$NROFF" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_dummy=""/usr/bin:/usr/ucb"" -for as_dir in $as_dummy -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_path_NROFF="$as_dir/$ac_word$ac_exec_ext" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - - ;; -esac -fi -NROFF=$ac_cv_path_NROFF -if test -n "$NROFF"; then - { echo "$as_me:$LINENO: result: $NROFF" >&5 -echo "${ECHO_T}$NROFF" >&6; } -else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } -fi - - - test -n "$NROFF" && break -done -test -n "$NROFF" || NROFF="/bin/false" - - if ${NROFF} -mdoc ${srcdir}/ruby.1 >/dev/null 2>&1; then - MANTYPE=doc - else - MANTYPE=man - fi -fi - - -if test -f config.h && tr -d '\015' < confdefs.h | cmp -s config.h -; then - echo "config.h unchanged" -else - echo "creating config.h" - tr -d '\015' < confdefs.h > config.h -fi -tr -d '\015' < largefile.h > confdefs.h -rm largefile.h - -ac_config_files="$ac_config_files $FIRSTMAKEFILE" - -ac_config_files="$ac_config_files Makefile" - -cat >confcache <<\_ACEOF -# This file is a shell script that caches the results of configure -# tests run on this system so they can be shared between configure -# scripts and configure runs, see configure's option --config-cache. -# It is not useful on other systems. If it contains results you don't -# want to keep, you may remove or edit it. -# -# config.status only pays attention to the cache file if you give it -# the --recheck option to rerun configure. -# -# `ac_cv_env_foo' variables (set or unset) will be overridden when -# loading this file, other *unset* `ac_cv_foo' will be assigned the -# following values. - -_ACEOF - -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, we kill variables containing newlines. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -( - for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5 -echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - *) $as_unset $ac_var ;; - esac ;; - esac - done - - (set) 2>&1 | - case $as_nl`(ac_space=' '; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - # `set' does not quote correctly, so add quotes (double-quote - # substitution turns \\\\ into \\, and sed turns \\ into \). - sed -n \ - "s/'/'\\\\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" - ;; #( - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) | - sed ' - /^ac_cv_env_/b end - t clear - :clear - s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ - t end - s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ - :end' >>confcache -if diff "$cache_file" confcache >/dev/null 2>&1; then :; else - if test -w "$cache_file"; then - test "x$cache_file" != "x/dev/null" && - { echo "$as_me:$LINENO: updating cache $cache_file" >&5 -echo "$as_me: updating cache $cache_file" >&6;} - cat confcache >$cache_file - else - { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5 -echo "$as_me: not updating unwritable cache $cache_file" >&6;} - fi -fi -rm -f confcache - -test "x$prefix" = xNONE && prefix=$ac_default_prefix -# Let make expand exec_prefix. -test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' - -# Transform confdefs.h into DEFS. -# Protect against shell expansion while executing Makefile rules. -# Protect against Makefile macro expansion. -# -# If the first sed substitution is executed (which looks for macros that -# take arguments), then branch to the quote section. Otherwise, -# look for a macro that doesn't take arguments. -ac_script=' -t clear -:clear -s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g -t quote -s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g -t quote -b any -:quote -s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g -s/\[/\\&/g -s/\]/\\&/g -s/\$/$$/g -H -:any -${ - g - s/^\n// - s/\n/ /g - p -} -' -DEFS=`sed -n "$ac_script" confdefs.h` - - -ac_libobjs= -ac_ltlibobjs= -for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue - # 1. Remove the extension, and $U if already installed. - ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' - ac_i=`echo "$ac_i" | sed "$ac_script"` - # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR - # will be set to the directory where LIBOBJS objects are built. - ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext" - ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo' -done -LIBOBJS=$ac_libobjs - -LTLIBOBJS=$ac_ltlibobjs - - - -: ${CONFIG_STATUS=./config.status} -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files $CONFIG_STATUS" -{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5 -echo "$as_me: creating $CONFIG_STATUS" >&6;} -cat >$CONFIG_STATUS <<_ACEOF -#! $SHELL -# Generated by $as_me. -# Run this file to recreate the current configuration. -# Compiler output produced by configure, useful for debugging -# configure, is in config.log if it exists. - -debug=false -ac_cs_recheck=false -ac_cs_silent=false -SHELL=\${CONFIG_SHELL-$SHELL} -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF -## --------------------- ## -## M4sh Initialization. ## -## --------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then - emulate sh - NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in - *posix*) set -o posix ;; -esac - -fi - - - - -# PATH needs CR -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - echo "#! /bin/sh" >conf$$.sh - echo "exit 0" >>conf$$.sh - chmod +x conf$$.sh - if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then - PATH_SEPARATOR=';' - else - PATH_SEPARATOR=: - fi - rm -f conf$$.sh -fi - -# Support unset when possible. -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then - as_unset=unset -else - as_unset=false -fi - - -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -as_nl=' -' -IFS=" "" $as_nl" - -# Find who we are. Look in the path if we contain no directory separator. -case $0 in - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break -done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - { (exit 1); exit 1; } -fi - -# Work around bugs in pre-3.0 UWIN ksh. -for as_var in ENV MAIL MAILPATH -do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -for as_var in \ - LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ - LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ - LC_TELEPHONE LC_TIME -do - if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then - eval $as_var=C; export $as_var - else - ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var - fi -done - -# Required to use basename. -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - - -# Name of the executable. -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# CDPATH. -$as_unset CDPATH - - - - as_lineno_1=$LINENO - as_lineno_2=$LINENO - test "x$as_lineno_1" != "x$as_lineno_2" && - test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || { - - # Create $as_me.lineno as a copy of $as_myself, but with $LINENO - # uniformly replaced by the line number. The first 'sed' inserts a - # line-number line after each line using $LINENO; the second 'sed' - # does the real work. The second script uses 'N' to pair each - # line-number line with the line containing $LINENO, and appends - # trailing '-' during substitution so that $LINENO is not a special - # case at line end. - # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the - # scripts with optimization help from Paolo Bonzini. Blame Lee - # E. McMahon (1931-1989) for sed's syntax. :-) - sed -n ' - p - /[$]LINENO/= - ' <$as_myself | - sed ' - s/[$]LINENO.*/&-/ - t lineno - b - :lineno - N - :loop - s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ - t loop - s/-\n.*// - ' >$as_me.lineno && - chmod +x "$as_me.lineno" || - { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 - { (exit 1); exit 1; }; } - - # Don't try to exec as it changes $[0], causing all sort of problems - # (the dirname of $[0] is not the place where we might find the - # original and so on. Autoconf is especially sensitive to this). - . "./$as_me.lineno" - # Exit status is that of the last command. - exit -} - - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in --n*) - case `echo 'x\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - *) ECHO_C='\c';; - esac;; -*) - ECHO_N='-n';; -esac - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir -fi -echo >conf$$.file -if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -p' -elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln -else - as_ln_s='cp -p' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - -if mkdir -p . 2>/dev/null; then - as_mkdir_p=: -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - -if test -x / >/dev/null 2>&1; then - as_test_x='test -x' -else - if ls -dL / >/dev/null 2>&1; then - as_ls_L_option=L - else - as_ls_L_option= - fi - as_test_x=' - eval sh -c '\'' - if test -d "$1"; then - test -d "$1/."; - else - case $1 in - -*)set "./$1";; - esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in - ???[sx]*):;;*)false;;esac;fi - '\'' sh - ' -fi -as_executable_p=$as_test_x - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - - -exec 6>&1 - -# Save the log message, to keep $[0] and so on meaningful, and to -# report actual input values of CONFIG_FILES etc. instead of their -# values after options handling. -ac_log=" -This file was extended by $as_me, which was -generated by GNU Autoconf 2.61. Invocation command line was - - CONFIG_FILES = $CONFIG_FILES - CONFIG_HEADERS = $CONFIG_HEADERS - CONFIG_LINKS = $CONFIG_LINKS - CONFIG_COMMANDS = $CONFIG_COMMANDS - $ $0 $@ - -on `(hostname || uname -n) 2>/dev/null | sed 1q` -" - -_ACEOF - -cat >>$CONFIG_STATUS <<_ACEOF -# Files that config.status was made for. -config_files="$ac_config_files" - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF -ac_cs_usage="\ -\`$as_me' instantiates files from templates according to the -current configuration. - -Usage: $0 [OPTIONS] [FILE]... - - -h, --help print this help, then exit - -V, --version print version number and configuration settings, then exit - -q, --quiet do not print progress messages - -d, --debug don't remove temporary files - --recheck update $as_me by reconfiguring in the same conditions - --file=FILE[:TEMPLATE] - instantiate the configuration file FILE - -Configuration files: -$config_files - -Report bugs to ." - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF -ac_cs_version="\\ -config.status -configured by $0, generated by GNU Autoconf 2.61, - with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" - -Copyright (C) 2006 Free Software Foundation, Inc. -This config.status script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it." - -ac_pwd='$ac_pwd' -srcdir='$srcdir' -INSTALL='$INSTALL' -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF -# If no file are specified by the user, then we need to provide default -# value. By we need to know if files were specified by the user. -ac_need_defaults=: -while test $# != 0 -do - case $1 in - --*=*) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` - ac_shift=: - ;; - *) - ac_option=$1 - ac_optarg=$2 - ac_shift=shift - ;; - esac - - case $ac_option in - # Handling of the options. - -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) - ac_cs_recheck=: ;; - --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) - echo "$ac_cs_version"; exit ;; - --debug | --debu | --deb | --de | --d | -d ) - debug=: ;; - --file | --fil | --fi | --f ) - $ac_shift - CONFIG_FILES="$CONFIG_FILES $ac_optarg" - ac_need_defaults=false;; - --he | --h | --help | --hel | -h ) - echo "$ac_cs_usage"; exit ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil | --si | --s) - ac_cs_silent=: ;; - - # This is an error. - -*) { echo "$as_me: error: unrecognized option: $1 -Try \`$0 --help' for more information." >&2 - { (exit 1); exit 1; }; } ;; - - *) ac_config_targets="$ac_config_targets $1" - ac_need_defaults=false ;; - - esac - shift -done - -ac_configure_extra_args= - -if $ac_cs_silent; then - exec 6>/dev/null - ac_configure_extra_args="$ac_configure_extra_args --silent" -fi - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF -if \$ac_cs_recheck; then - echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6 - CONFIG_SHELL=$SHELL - export CONFIG_SHELL - exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion -fi - -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF -exec 5>>config.log -{ - echo - sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX -## Running $as_me. ## -_ASBOX - echo "$ac_log" -} >&5 - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF -# -# INIT-COMMANDS -# -RUBY_INSTALL_NAME=$RUBY_INSTALL_NAME EXEEXT=$EXEEXT - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF - -# Handling of arguments. -for ac_config_target in $ac_config_targets -do - case $ac_config_target in - "$FIRSTMAKEFILE") CONFIG_FILES="$CONFIG_FILES $FIRSTMAKEFILE" ;; - "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; - - *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 -echo "$as_me: error: invalid argument: $ac_config_target" >&2;} - { (exit 1); exit 1; }; };; - esac -done - - -# If the user did not use the arguments to specify the items to instantiate, -# then the envvar interface is used. Set only those that are not. -# We use the long form for the default assignment because of an extremely -# bizarre bug on SunOS 4.1.3. -if $ac_need_defaults; then - test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files -fi - -# Have a temporary directory for convenience. Make it in the build tree -# simply because there is no reason against having it here, and in addition, -# creating and moving files from /tmp can sometimes cause problems. -# Hook for its removal unless debugging. -# Note that there is a small window in which the directory will not be cleaned: -# after its creation but before its name has been assigned to `$tmp'. -$debug || -{ - tmp= - trap 'exit_status=$? - { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status -' 0 - trap '{ (exit 1); exit 1; }' 1 2 13 15 -} -# Create a (secure) tmp directory for tmp files. - -{ - tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && - test -n "$tmp" && test -d "$tmp" -} || -{ - tmp=./conf$$-$RANDOM - (umask 077 && mkdir "$tmp") -} || -{ - echo "$me: cannot create a temporary directory in ." >&2 - { (exit 1); exit 1; } -} - -# -# Set up the sed scripts for CONFIG_FILES section. -# - -# No need to generate the scripts if there are no CONFIG_FILES. -# This happens for instance when ./config.status config.h -if test -n "$CONFIG_FILES"; then - -_ACEOF - - - -ac_delim='%!_!# ' -for ac_last_try in false false false false false :; do - cat >conf$$subs.sed <<_ACEOF -SHELL!$SHELL$ac_delim -PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim -PACKAGE_NAME!$PACKAGE_NAME$ac_delim -PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim -PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim -PACKAGE_STRING!$PACKAGE_STRING$ac_delim -PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim -exec_prefix!$exec_prefix$ac_delim -prefix!$prefix$ac_delim -program_transform_name!$program_transform_name$ac_delim -bindir!$bindir$ac_delim -sbindir!$sbindir$ac_delim -libexecdir!$libexecdir$ac_delim -datarootdir!$datarootdir$ac_delim -datadir!$datadir$ac_delim -sysconfdir!$sysconfdir$ac_delim -sharedstatedir!$sharedstatedir$ac_delim -localstatedir!$localstatedir$ac_delim -includedir!$includedir$ac_delim -oldincludedir!$oldincludedir$ac_delim -docdir!$docdir$ac_delim -infodir!$infodir$ac_delim -htmldir!$htmldir$ac_delim -dvidir!$dvidir$ac_delim -pdfdir!$pdfdir$ac_delim -psdir!$psdir$ac_delim -libdir!$libdir$ac_delim -localedir!$localedir$ac_delim -mandir!$mandir$ac_delim -DEFS!$DEFS$ac_delim -ECHO_C!$ECHO_C$ac_delim -ECHO_N!$ECHO_N$ac_delim -ECHO_T!$ECHO_T$ac_delim -LIBS!$LIBS$ac_delim -build_alias!$build_alias$ac_delim -host_alias!$host_alias$ac_delim -target_alias!$target_alias$ac_delim -MAJOR!$MAJOR$ac_delim -MINOR!$MINOR$ac_delim -TEENY!$TEENY$ac_delim -build!$build$ac_delim -build_cpu!$build_cpu$ac_delim -build_vendor!$build_vendor$ac_delim -build_os!$build_os$ac_delim -host!$host$ac_delim -host_cpu!$host_cpu$ac_delim -host_vendor!$host_vendor$ac_delim -host_os!$host_os$ac_delim -target!$target$ac_delim -target_cpu!$target_cpu$ac_delim -target_vendor!$target_vendor$ac_delim -target_os!$target_os$ac_delim -CC!$CC$ac_delim -CFLAGS!$CFLAGS$ac_delim -LDFLAGS!$LDFLAGS$ac_delim -CPPFLAGS!$CPPFLAGS$ac_delim -ac_ct_CC!$ac_ct_CC$ac_delim -EXEEXT!$EXEEXT$ac_delim -OBJEXT!$OBJEXT$ac_delim -CPP!$CPP$ac_delim -GREP!$GREP$ac_delim -EGREP!$EGREP$ac_delim -GNU_LD!$GNU_LD$ac_delim -CPPOUTFILE!$CPPOUTFILE$ac_delim -OUTFLAG!$OUTFLAG$ac_delim -YACC!$YACC$ac_delim -YFLAGS!$YFLAGS$ac_delim -RANLIB!$RANLIB$ac_delim -AR!$AR$ac_delim -AS!$AS$ac_delim -ASFLAGS!$ASFLAGS$ac_delim -NM!$NM$ac_delim -WINDRES!$WINDRES$ac_delim -DLLWRAP!$DLLWRAP$ac_delim -OBJDUMP!$OBJDUMP$ac_delim -LN_S!$LN_S$ac_delim -SET_MAKE!$SET_MAKE$ac_delim -INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim -INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim -INSTALL_DATA!$INSTALL_DATA$ac_delim -RM!$RM$ac_delim -CP!$CP$ac_delim -MAKEDIRS!$MAKEDIRS$ac_delim -LIBOBJS!$LIBOBJS$ac_delim -ALLOCA!$ALLOCA$ac_delim -DLDFLAGS!$DLDFLAGS$ac_delim -ARCH_FLAG!$ARCH_FLAG$ac_delim -STATIC!$STATIC$ac_delim -CCDLFLAGS!$CCDLFLAGS$ac_delim -LDSHARED!$LDSHARED$ac_delim -DLEXT!$DLEXT$ac_delim -DLEXT2!$DLEXT2$ac_delim -LIBEXT!$LIBEXT$ac_delim -LINK_SO!$LINK_SO$ac_delim -LIBPATHFLAG!$LIBPATHFLAG$ac_delim -RPATHFLAG!$RPATHFLAG$ac_delim -LIBPATHENV!$LIBPATHENV$ac_delim -_ACEOF - - if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then - break - elif $ac_last_try; then - { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 -echo "$as_me: error: could not make $CONFIG_STATUS" >&2;} - { (exit 1); exit 1; }; } - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done - -ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed` -if test -n "$ac_eof"; then - ac_eof=`echo "$ac_eof" | sort -nru | sed 1q` - ac_eof=`expr $ac_eof + 1` -fi - -cat >>$CONFIG_STATUS <<_ACEOF -cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof -/@[a-zA-Z_][a-zA-Z_0-9]*@/!b -_ACEOF -sed ' -s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g -s/^/s,@/; s/!/@,|#_!!_#|/ -:n -t n -s/'"$ac_delim"'$/,g/; t -s/$/\\/; p -N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n -' >>$CONFIG_STATUS >$CONFIG_STATUS <<_ACEOF -CEOF$ac_eof -_ACEOF - - -ac_delim='%!_!# ' -for ac_last_try in false false false false false :; do - cat >conf$$subs.sed <<_ACEOF -TRY_LINK!$TRY_LINK$ac_delim -STRIP!$STRIP$ac_delim -EXTSTATIC!$EXTSTATIC$ac_delim -setup!$setup$ac_delim -MINIRUBY!$MINIRUBY$ac_delim -PREP!$PREP$ac_delim -RUNRUBY!$RUNRUBY$ac_delim -EXTOUT!$EXTOUT$ac_delim -ARCHFILE!$ARCHFILE$ac_delim -RDOCTARGET!$RDOCTARGET$ac_delim -cppflags!$cppflags$ac_delim -cflags!$cflags$ac_delim -optflags!$optflags$ac_delim -debugflags!$debugflags$ac_delim -XCFLAGS!$XCFLAGS$ac_delim -XLDFLAGS!$XLDFLAGS$ac_delim -LIBRUBY_LDSHARED!$LIBRUBY_LDSHARED$ac_delim -LIBRUBY_DLDFLAGS!$LIBRUBY_DLDFLAGS$ac_delim -RUBY_INSTALL_NAME!$RUBY_INSTALL_NAME$ac_delim -rubyw_install_name!$rubyw_install_name$ac_delim -RUBYW_INSTALL_NAME!$RUBYW_INSTALL_NAME$ac_delim -RUBY_SO_NAME!$RUBY_SO_NAME$ac_delim -LIBRUBY_A!$LIBRUBY_A$ac_delim -LIBRUBY_SO!$LIBRUBY_SO$ac_delim -LIBRUBY_ALIASES!$LIBRUBY_ALIASES$ac_delim -LIBRUBY!$LIBRUBY$ac_delim -LIBRUBYARG!$LIBRUBYARG$ac_delim -LIBRUBYARG_STATIC!$LIBRUBYARG_STATIC$ac_delim -LIBRUBYARG_SHARED!$LIBRUBYARG_SHARED$ac_delim -SOLIBS!$SOLIBS$ac_delim -DLDLIBS!$DLDLIBS$ac_delim -ENABLE_SHARED!$ENABLE_SHARED$ac_delim -MAINLIBS!$MAINLIBS$ac_delim -COMMON_LIBS!$COMMON_LIBS$ac_delim -COMMON_MACROS!$COMMON_MACROS$ac_delim -COMMON_HEADERS!$COMMON_HEADERS$ac_delim -EXPORT_PREFIX!$EXPORT_PREFIX$ac_delim -MINIOBJS!$MINIOBJS$ac_delim -MAKEFILES!$MAKEFILES$ac_delim -arch!$arch$ac_delim -sitearch!$sitearch$ac_delim -sitedir!$sitedir$ac_delim -vendordir!$vendordir$ac_delim -configure_args!$configure_args$ac_delim -NROFF!$NROFF$ac_delim -MANTYPE!$MANTYPE$ac_delim -LTLIBOBJS!$LTLIBOBJS$ac_delim -_ACEOF - - if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 47; then - break - elif $ac_last_try; then - { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 -echo "$as_me: error: could not make $CONFIG_STATUS" >&2;} - { (exit 1); exit 1; }; } - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done - -ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed` -if test -n "$ac_eof"; then - ac_eof=`echo "$ac_eof" | sort -nru | sed 1q` - ac_eof=`expr $ac_eof + 1` -fi - -cat >>$CONFIG_STATUS <<_ACEOF -cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof -/@[a-zA-Z_][a-zA-Z_0-9]*@/!b end -_ACEOF -sed ' -s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g -s/^/s,@/; s/!/@,|#_!!_#|/ -:n -t n -s/'"$ac_delim"'$/,g/; t -s/$/\\/; p -N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n -' >>$CONFIG_STATUS >$CONFIG_STATUS <<_ACEOF -:end -s/|#_!!_#|//g -CEOF$ac_eof -_ACEOF - - -# VPATH may cause trouble with some makes, so we remove $(srcdir), -# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and -# trailing colons and then remove the whole line if VPATH becomes empty -# (actually we leave an empty line to preserve line numbers). -if test "x$srcdir" = x.; then - ac_vpsub='/^[ ]*VPATH[ ]*=/{ -s/:*\$(srcdir):*/:/ -s/:*\${srcdir}:*/:/ -s/:*@srcdir@:*/:/ -s/^\([^=]*=[ ]*\):*/\1/ -s/:*$// -s/^[^=]*=[ ]*$// -}' -fi - -cat >>$CONFIG_STATUS <<\_ACEOF -fi # test -n "$CONFIG_FILES" - - -for ac_tag in :F $CONFIG_FILES -do - case $ac_tag in - :[FHLC]) ac_mode=$ac_tag; continue;; - esac - case $ac_mode$ac_tag in - :[FHL]*:*);; - :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5 -echo "$as_me: error: Invalid tag $ac_tag." >&2;} - { (exit 1); exit 1; }; };; - :[FH]-) ac_tag=-:-;; - :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; - esac - ac_save_IFS=$IFS - IFS=: - set x $ac_tag - IFS=$ac_save_IFS - shift - ac_file=$1 - shift - - case $ac_mode in - :L) ac_source=$1;; - :[FH]) - ac_file_inputs= - for ac_f - do - case $ac_f in - -) ac_f="$tmp/stdin";; - *) # Look for the file first in the build tree, then in the source tree - # (if the path is not absolute). The absolute path cannot be DOS-style, - # because $ac_f cannot contain `:'. - test -f "$ac_f" || - case $ac_f in - [\\/$]*) false;; - *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; - esac || - { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5 -echo "$as_me: error: cannot find input file: $ac_f" >&2;} - { (exit 1); exit 1; }; };; - esac - ac_file_inputs="$ac_file_inputs $ac_f" - done - - # Let's still pretend it is `configure' which instantiates (i.e., don't - # use $as_me), people would be surprised to read: - # /* config.h. Generated by config.status. */ - configure_input="Generated from "`IFS=: - echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure." - if test x"$ac_file" != x-; then - configure_input="$ac_file. $configure_input" - { echo "$as_me:$LINENO: creating $ac_file" >&5 -echo "$as_me: creating $ac_file" >&6;} - fi - - case $ac_tag in - *:-:* | *:-) cat >"$tmp/stdin";; - esac - ;; - esac - - ac_dir=`$as_dirname -- "$ac_file" || -$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$ac_file" : 'X\(//\)[^/]' \| \ - X"$ac_file" : 'X\(//\)$' \| \ - X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || -echo X"$ac_file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - { as_dir="$ac_dir" - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 -echo "$as_me: error: cannot create directory $as_dir" >&2;} - { (exit 1); exit 1; }; }; } - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - - case $ac_mode in - :F) - # - # CONFIG_FILE - # - - case $INSTALL in - [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; - *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; - esac -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF -# If the template does not know about datarootdir, expand it. -# FIXME: This hack should be removed a few years after 2.60. -ac_datarootdir_hack=; ac_datarootdir_seen= - -case `sed -n '/datarootdir/ { - p - q -} -/@datadir@/p -/@docdir@/p -/@infodir@/p -/@localedir@/p -/@mandir@/p -' $ac_file_inputs` in -*datarootdir*) ac_datarootdir_seen=yes;; -*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) - { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 -echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF - ac_datarootdir_hack=' - s&@datadir@&$datadir&g - s&@docdir@&$docdir&g - s&@infodir@&$infodir&g - s&@localedir@&$localedir&g - s&@mandir@&$mandir&g - s&\\\${datarootdir}&$datarootdir&g' ;; -esac -_ACEOF - -# Neutralize VPATH when `$srcdir' = `.'. -# Shell code in configure.ac might set extrasub. -# FIXME: do we really want to maintain this feature? -cat >>$CONFIG_STATUS <<_ACEOF - sed "$ac_vpsub -$extrasub -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF -:t -/@[a-zA-Z_][a-zA-Z_0-9]*@/!b -s&@configure_input@&$configure_input&;t t -s&@top_builddir@&$ac_top_builddir_sub&;t t -s&@srcdir@&$ac_srcdir&;t t -s&@abs_srcdir@&$ac_abs_srcdir&;t t -s&@top_srcdir@&$ac_top_srcdir&;t t -s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t -s&@builddir@&$ac_builddir&;t t -s&@abs_builddir@&$ac_abs_builddir&;t t -s&@abs_top_builddir@&$ac_abs_top_builddir&;t t -s&@INSTALL@&$ac_INSTALL&;t t -$ac_datarootdir_hack -" $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out - -test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && - { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && - { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && - { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined." >&5 -echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined." >&2;} - - rm -f "$tmp/stdin" - case $ac_file in - -) cat "$tmp/out"; rm -f "$tmp/out";; - *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;; - esac - ;; - - - - esac - - - case $ac_file$ac_mode in - "Makefile":F) { - sed '/^MISSING/s/\$U\././g' Makefile - echo; test x"$EXEEXT" = x || echo 'miniruby: miniruby$(EXEEXT)' - test "$RUBY_INSTALL_NAME$EXEEXT" = ruby || echo 'ruby: $(PROGRAM);' - sed 's/{\$([^(){}]*)[^{}]*}//g' ${srcdir}/common.mk - } >> confmk$$.tmp && mv -f confmk$$.tmp Makefile ;; - - esac -done # for ac_tag - - -{ (exit 0); exit 0; } -_ACEOF -chmod +x $CONFIG_STATUS -ac_clean_files=$ac_clean_files_save - - -# configure is writing to config.log, and then calls config.status. -# config.status does its own redirection, appending to config.log. -# Unfortunately, on DOS this fails, as config.log is still kept open -# by configure, so config.status won't be able to write to it; its -# output is simply discarded. So we exec the FD to /dev/null, -# effectively closing config.log, so it can be properly (re)opened and -# appended to by config.status. When coming back to configure, we -# need to make the FD available again. -if test "$no_create" != yes; then - ac_cs_success=: - ac_config_status_args= - test "$silent" = yes && - ac_config_status_args="$ac_config_status_args --quiet" - exec 5>/dev/null - $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false - exec 5>>config.log - # Use ||, not &&, to avoid exiting from the if with $? = 1, which - # would make configure fail if this is the last instruction. - $ac_cs_success || { (exit 1); exit 1; } -fi - diff -Nru ruby1.8-1.8.7.22/configure.in ruby1.8-1.8.7.72/configure.in --- ruby1.8-1.8.7.22/configure.in 2008-06-15 07:28:47.000000000 -0300 +++ ruby1.8-1.8.7.72/configure.in 2008-07-12 12:06:09.000000000 -0300 @@ -559,6 +559,27 @@ AC_FUNC_MEMCMP AC_FUNC_FSEEKO AC_CHECK_FUNCS(ftello) + +# http://sources.redhat.com/ml/libc-hacker/2005-08/msg00008.html +# Debian GNU/Linux Etch's libc6.1 2.3.6.ds1-13etch5 has this problem. +# Debian GNU/Linux Lenny's libc6.1 2.7-10 has no problem. +AC_CACHE_CHECK(for broken erfc of glibc-2.3.6 on IA64, rb_broken_glibc_ia64_erfc, + [AC_TRY_RUN([ +#include +int +main() +{ + erfc(10000.0); + return 0; +} +], + rb_broken_glibc_ia64_erfc=no, + rb_broken_glibc_ia64_erfc=yes, + rb_broken_glibc_ia64_erfc=no)]) +case $rb_broken_glibc_ia64_erfc in + yes) ac_cv_func_erf=no;; +esac + AC_REPLACE_FUNCS(dup2 memmove strcasecmp strncasecmp strerror strftime\ strchr strstr strtoul crypt flock vsnprintf\ isnan finite isinf hypot acosh erf) diff -Nru ruby1.8-1.8.7.22/.cvsignore ruby1.8-1.8.7.72/.cvsignore --- ruby1.8-1.8.7.22/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,48 +0,0 @@ -*.bak -*.orig -*.rej -*.sav -*~ -.*.list -.*.time -.ccmalloc -.ppack -.ext -.git -.svn -.pc -COPYING.LIB -ChangeLog.pre-alpha -ChangeLog.pre1_1 -Makefile -README.fat-patch -README.v6 -README.atheos -archive -autom4te*.cache -automake -beos -config.cache -config.h -config.h.in -config.log -config.status -configure -libruby.so.* -miniruby -newdate.rb -newver.rb -parse.c -patches -ppack -preview -rbconfig.rb -repack -riscos -rubicon -ruby -ruby-man.rd.gz -tmp -web -y.output -y.tab.c diff -Nru ruby1.8-1.8.7.22/debian/changelog ruby1.8-1.8.7.72/debian/changelog --- ruby1.8-1.8.7.22/debian/changelog 2008-08-23 10:29:46.000000000 -0300 +++ ruby1.8-1.8.7.72/debian/changelog 2008-08-23 10:27:38.000000000 -0300 @@ -1,3 +1,16 @@ +ruby1.8 (1.8.7.72-0ubuntu1) intrepid; urgency=low + + * + + -- H. Gabriel Maculus (gabrielix) Sat, 23 Aug 2008 10:27:08 -0300 + +ruby1.8 (1.8.7.72-0ubuntu0) intrepid; urgency=low + + * bump to 1.8.7.72 + -fix bug 246818 [CVE-2008-2376] + + -- H. Gabriel Maculus Sat, 23 Aug 2008 10:20:17 -0300 + ruby1.8 (1.8.7.22-1) unstable; urgency=high * New upstream release. diff -Nru ruby1.8-1.8.7.22/error.c ruby1.8-1.8.7.72/error.c --- ruby1.8-1.8.7.22/error.c 2008-05-31 10:37:06.000000000 -0300 +++ ruby1.8-1.8.7.72/error.c 2008-08-04 00:24:26.000000000 -0300 @@ -2,8 +2,8 @@ error.c - - $Author: knu $ - $Date: 2008-05-31 22:37:06 +0900 (Sat, 31 May 2008) $ + $Author: shyouhei $ + $Date: 2008-08-04 12:24:26 +0900 (Mon, 04 Aug 2008) $ created at: Mon Aug 9 16:11:34 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -333,7 +333,7 @@ VALUE etype, str; { StringValue(str); - return rb_exc_new(etype, RSTRING(str)->ptr, RSTRING(str)->len); + return rb_funcall(etype, rb_intern("new"), 1, str); } /* diff -Nru ruby1.8-1.8.7.22/eval.c ruby1.8-1.8.7.72/eval.c --- ruby1.8-1.8.7.22/eval.c 2008-05-31 08:44:49.000000000 -0300 +++ ruby1.8-1.8.7.72/eval.c 2008-08-04 00:24:26.000000000 -0300 @@ -2,8 +2,8 @@ eval.c - - $Author: knu $ - $Date: 2008-05-31 20:44:49 +0900 (Sat, 31 May 2008) $ + $Author: shyouhei $ + $Date: 2008-08-04 12:24:26 +0900 (Mon, 04 Aug 2008) $ created at: Thu Jun 10 14:22:17 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -758,7 +758,7 @@ static unsigned long frame_unique = 0; #define PUSH_FRAME() do { \ - struct FRAME _frame; \ + volatile struct FRAME _frame; \ _frame.prev = ruby_frame; \ _frame.tmp = 0; \ _frame.node = ruby_current_node; \ @@ -1055,7 +1055,7 @@ static VALUE ruby_wrapper; /* security wrapper */ #define PUSH_CLASS(c) do { \ - VALUE _class = ruby_class; \ + volatile VALUE _class = ruby_class; \ ruby_class = (c) #define POP_CLASS() ruby_class = _class; \ @@ -1441,9 +1441,6 @@ static void rb_thread_cleanup _((void)); static void rb_thread_wait_other_threads _((void)); -static int thread_set_raised(); -static int thread_reset_raised(); - static int thread_no_ensure _((void)); static VALUE exception_error; @@ -1462,8 +1459,10 @@ int ex; { int status = EXIT_FAILURE; + rb_thread_t th = curr_thread; - if (thread_set_raised()) return EXIT_FAILURE; + if (rb_thread_set_raised(th)) + return EXIT_FAILURE; switch (ex & TAG_MASK) { case 0: status = EXIT_SUCCESS; @@ -1516,7 +1515,7 @@ rb_bug("Unknown longjmp status %d", ex); break; } - thread_reset_raised(); + rb_thread_reset_raised(th); return status; } @@ -2709,6 +2708,7 @@ NODE *node_save; VALUE srcfile; const char *event_name; + rb_thread_t th = curr_thread; if (!trace_func) return; if (tracing) return; @@ -2740,7 +2740,7 @@ } } PUSH_TAG(PROT_NONE); - raised = thread_reset_raised(); + raised = rb_thread_reset_raised(th); if ((state = EXEC_TAG()) == 0) { srcfile = rb_str_new2(ruby_sourcefile?ruby_sourcefile:"(ruby)"); event_name = get_event_name(event); @@ -2752,7 +2752,7 @@ klass), Qundef, 0); } - if (raised) thread_set_raised(); + if (raised) rb_thread_set_raised(th); POP_TAG(); POP_FRAME(); @@ -4233,7 +4233,7 @@ int n = 0; args[n++] = ID2SYM(id); if (priv) args[n++] = Qtrue; - return rb_funcall2(obj, respond_to, n, args); + return RTEST(rb_funcall2(obj, respond_to, n, args)); } } @@ -4571,8 +4571,9 @@ VALUE mesg; { VALUE at; + rb_thread_t th = curr_thread; - if (thread_set_raised()) { + if (rb_thread_set_raised(th)) { ruby_errinfo = exception_error; JUMP_TAG(TAG_FATAL); } @@ -4586,6 +4587,9 @@ at = get_backtrace(mesg); if (NIL_P(at)) { at = make_backtrace(); + if (OBJ_FROZEN(mesg)) { + mesg = rb_obj_dup(mesg); + } set_backtrace(mesg, at); } } @@ -4611,7 +4615,7 @@ ruby_errinfo = mesg; } else if (status) { - thread_reset_raised(); + rb_thread_reset_raised(th); JUMP_TAG(status); } } @@ -4626,11 +4630,20 @@ if (!prot_tag) { error_print(); } - thread_reset_raised(); + rb_thread_raised_clear(th); JUMP_TAG(tag); } void +rb_exc_jump(mesg) + VALUE mesg; +{ + rb_thread_raised_clear(rb_curr_thread); + ruby_errinfo = mesg; + JUMP_TAG(TAG_RAISE); +} + +void rb_exc_raise(mesg) VALUE mesg; { @@ -5578,18 +5591,11 @@ static void stack_check() { - static int overflowing = 0; + rb_thread_t th = rb_curr_thread; - if (!overflowing && ruby_stack_check()) { - int state; - overflowing = 1; - PUSH_TAG(PROT_NONE); - if ((state = EXEC_TAG()) == 0) { - rb_exc_raise(sysstack_error); - } - POP_TAG(); - overflowing = 0; - JUMP_TAG(state); + if (!rb_thread_raised_p(th, RAISED_STACKOVERFLOW) && ruby_stack_check()) { + rb_thread_raised_set(th, RAISED_STACKOVERFLOW); + rb_exc_raise(sysstack_error); } } @@ -5828,8 +5834,7 @@ TMP_PROTECT; volatile int safe = -1; - if (NOEX_SAFE(flags) > ruby_safe_level && - ruby_safe_level == 0 && NOEX_SAFE(flags) > 2) { + if (NOEX_SAFE(flags) > ruby_safe_level && NOEX_SAFE(flags) > 2) { rb_raise(rb_eSecurityError, "calling insecure method: %s", rb_id2name(id)); } @@ -9987,12 +9992,17 @@ rb_define_method(rb_eLocalJumpError, "reason", localjump_reason, 0); rb_global_variable(&exception_error); - exception_error = rb_exc_new2(rb_eFatal, "exception reentered"); + exception_error = rb_exc_new3(rb_eFatal, + rb_obj_freeze(rb_str_new2("exception reentered"))); + OBJ_TAINT(exception_error); + OBJ_FREEZE(exception_error); rb_eSysStackError = rb_define_class("SystemStackError", rb_eStandardError); rb_global_variable(&sysstack_error); - sysstack_error = rb_exc_new2(rb_eSysStackError, "stack level too deep"); + sysstack_error = rb_exc_new3(rb_eSysStackError, + rb_obj_freeze(rb_str_new2("stack level too deep"))); OBJ_TAINT(sysstack_error); + OBJ_FREEZE(sysstack_error); rb_cProc = rb_define_class("Proc", rb_cObject); rb_undef_alloc_func(rb_cProc); @@ -10170,10 +10180,9 @@ # endif #endif -#define THREAD_RAISED 0x200 /* temporary flag */ #define THREAD_TERMINATING 0x400 /* persistent flag */ -#define THREAD_NO_ENSURE 0x800 /* persistent flag */ -#define THREAD_FLAGS_MASK 0xc00 /* mask for persistent flags */ +#define THREAD_NO_ENSURE 0x800 /* persistent flag */ +#define THREAD_FLAGS_MASK 0xfc00 /* mask for persistent flags */ #define FOREACH_THREAD_FROM(f,x) x = f; do { x = x->next; #define END_FOREACH_FROM(f,x) } while (x != f) @@ -10225,19 +10234,25 @@ (dst)->join = (src)->join, \ 0) -static int -thread_set_raised() +int +rb_thread_set_raised(th) + rb_thread_t th; { - if (curr_thread->flags & THREAD_RAISED) return 1; - curr_thread->flags |= THREAD_RAISED; + if (th->flags & RAISED_EXCEPTION) { + return 1; + } + th->flags |= RAISED_EXCEPTION; return 0; } -static int -thread_reset_raised() +int +rb_thread_reset_raised(th) + rb_thread_t th; { - if (!(curr_thread->flags & THREAD_RAISED)) return 0; - curr_thread->flags &= ~THREAD_RAISED; + if (!(th->flags & RAISED_EXCEPTION)) { + return 0; + } + th->flags &= ~RAISED_EXCEPTION; return 1; } @@ -11375,7 +11390,7 @@ if (!rb_thread_dead(th)) return Qfalse; } - if (!NIL_P(th->errinfo) && (th->flags & THREAD_RAISED)) { + if (!NIL_P(th->errinfo) && (th->flags & RAISED_EXCEPTION)) { VALUE oldbt = get_backtrace(th->errinfo); VALUE errat = make_backtrace(); VALUE errinfo = rb_obj_dup(th->errinfo); @@ -12251,7 +12266,7 @@ } if (state && status != THREAD_TO_KILL && !NIL_P(ruby_errinfo)) { - th->flags |= THREAD_RAISED; + th->flags |= RAISED_EXCEPTION; if (state == TAG_FATAL) { /* fatal error within this thread, need to stop whole script */ main_thread->errinfo = ruby_errinfo; @@ -12469,7 +12484,7 @@ rb_thread_t th = rb_thread_check(thread); if (rb_thread_dead(th)) { - if (!NIL_P(th->errinfo) && (th->flags & THREAD_RAISED)) + if (!NIL_P(th->errinfo) && (th->flags & RAISED_EXCEPTION)) return Qnil; return Qfalse; } diff -Nru ruby1.8-1.8.7.22/ext/bigdecimal/.cvsignore ruby1.8-1.8.7.72/ext/bigdecimal/.cvsignore --- ruby1.8-1.8.7.22/ext/bigdecimal/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/bigdecimal/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/curses/.cvsignore ruby1.8-1.8.7.72/ext/curses/.cvsignore --- ruby1.8-1.8.7.22/ext/curses/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/curses/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/.cvsignore ruby1.8-1.8.7.72/ext/.cvsignore --- ruby1.8-1.8.7.22/ext/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,2 +0,0 @@ -extinit.c -*.log diff -Nru ruby1.8-1.8.7.22/ext/dbm/.cvsignore ruby1.8-1.8.7.72/ext/dbm/.cvsignore --- ruby1.8-1.8.7.22/ext/dbm/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/dbm/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/digest/bubblebabble/.cvsignore ruby1.8-1.8.7.72/ext/digest/bubblebabble/.cvsignore --- ruby1.8-1.8.7.22/ext/digest/bubblebabble/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/digest/bubblebabble/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/digest/.cvsignore ruby1.8-1.8.7.72/ext/digest/.cvsignore --- ruby1.8-1.8.7.22/ext/digest/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/digest/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/digest/md5/.cvsignore ruby1.8-1.8.7.72/ext/digest/md5/.cvsignore --- ruby1.8-1.8.7.22/ext/digest/md5/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/digest/md5/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/digest/rmd160/.cvsignore ruby1.8-1.8.7.72/ext/digest/rmd160/.cvsignore --- ruby1.8-1.8.7.22/ext/digest/rmd160/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/digest/rmd160/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/digest/sha1/.cvsignore ruby1.8-1.8.7.72/ext/digest/sha1/.cvsignore --- ruby1.8-1.8.7.22/ext/digest/sha1/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/digest/sha1/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/digest/sha2/.cvsignore ruby1.8-1.8.7.72/ext/digest/sha2/.cvsignore --- ruby1.8-1.8.7.22/ext/digest/sha2/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/digest/sha2/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/dl/.cvsignore ruby1.8-1.8.7.72/ext/dl/.cvsignore --- ruby1.8-1.8.7.22/ext/dl/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/dl/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,8 +0,0 @@ -Makefile -mkmf.log -dlconfig.h -dlconfig.rb -*.func -*.o -*~ -*.def diff -Nru ruby1.8-1.8.7.22/ext/dl/dl.c ruby1.8-1.8.7.72/ext/dl/dl.c --- ruby1.8-1.8.7.22/ext/dl/dl.c 2008-04-15 00:35:55.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/dl/dl.c 2008-08-10 21:37:21.000000000 -0300 @@ -1,5 +1,5 @@ /* - * $Id: dl.c 16025 2008-04-15 03:35:55Z nobu $ + * $Id: dl.c 18479 2008-08-11 00:37:21Z shyouhei $ */ #include @@ -522,12 +522,15 @@ { char *ptr; int len; + VALUE p; len = RSTRING(self)->len; ptr = (char*)dlmalloc(len + 1); memcpy(ptr, RSTRING(self)->ptr, len); ptr[len] = '\0'; - return rb_dlptr_new((void*)ptr,len,dlfree); + p = rb_dlptr_new((void*)ptr,len,dlfree); + OBJ_INFECT(p, self); + return p; } VALUE @@ -545,7 +548,12 @@ ptr = rb_ary2cary(0, self, &size); break; } - return ptr ? rb_dlptr_new(ptr, size, dlfree) : Qnil; + if (ptr) { + VALUE p = rb_dlptr_new(ptr, size, dlfree); + OBJ_INFECT(p, self); + return p; + } + return Qnil; } VALUE @@ -563,7 +571,7 @@ VALUE rb_dl_dlopen(int argc, VALUE argv[], VALUE self) { - rb_secure(4); + rb_secure(2); return rb_class_new_instance(argc, argv, rb_cDLHandle); } diff -Nru ruby1.8-1.8.7.22/ext/dl/sym.c ruby1.8-1.8.7.72/ext/dl/sym.c --- ruby1.8-1.8.7.22/ext/dl/sym.c 2007-07-22 02:33:47.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/dl/sym.c 2008-08-10 21:37:21.000000000 -0300 @@ -1,5 +1,5 @@ /* -*- C -*- - * $Id: sym.c 12835 2007-07-22 05:33:47Z nobu $ + * $Id: sym.c 18479 2008-08-11 00:37:21Z shyouhei $ */ #include @@ -492,6 +492,7 @@ rb_raise(rb_eDLTypeError, "unexpected type of argument #%d", i); } } + rb_check_safe_obj(pval); Data_Get_Struct(pval, struct ptr_data, data); ANY2P(args[i]) = DLVOIDP(data->ptr); } diff -Nru ruby1.8-1.8.7.22/ext/etc/.cvsignore ruby1.8-1.8.7.72/ext/etc/.cvsignore --- ruby1.8-1.8.7.22/ext/etc/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/etc/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/fcntl/.cvsignore ruby1.8-1.8.7.72/ext/fcntl/.cvsignore --- ruby1.8-1.8.7.22/ext/fcntl/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/fcntl/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/gdbm/.cvsignore ruby1.8-1.8.7.72/ext/gdbm/.cvsignore --- ruby1.8-1.8.7.22/ext/gdbm/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/gdbm/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/iconv/.cvsignore ruby1.8-1.8.7.72/ext/iconv/.cvsignore --- ruby1.8-1.8.7.22/ext/iconv/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/iconv/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,5 +0,0 @@ -Makefile -mkmf.log -*.def -iconv.rb -config.charset diff -Nru ruby1.8-1.8.7.22/ext/io/wait/.cvsignore ruby1.8-1.8.7.72/ext/io/wait/.cvsignore --- ruby1.8-1.8.7.22/ext/io/wait/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/io/wait/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,2 +0,0 @@ -Makefile -mkmf.log diff -Nru ruby1.8-1.8.7.22/ext/nkf/.cvsignore ruby1.8-1.8.7.72/ext/nkf/.cvsignore --- ruby1.8-1.8.7.22/ext/nkf/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/nkf/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/openssl/.cvsignore ruby1.8-1.8.7.72/ext/openssl/.cvsignore --- ruby1.8-1.8.7.22/ext/openssl/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/openssl/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,5 +0,0 @@ -GNUmakefile -Makefile -mkmf.log -dep -extconf.h diff -Nru ruby1.8-1.8.7.22/ext/openssl/openssl_missing.h ruby1.8-1.8.7.72/ext/openssl/openssl_missing.h --- ruby1.8-1.8.7.22/ext/openssl/openssl_missing.h 2008-05-19 00:00:52.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/openssl/openssl_missing.h 2008-08-04 01:44:17.000000000 -0300 @@ -1,5 +1,5 @@ /* - * $Id: openssl_missing.h 16467 2008-05-19 03:00:52Z knu $ + * $Id: openssl_missing.h 18335 2008-08-04 04:44:17Z shyouhei $ * 'OpenSSL for Ruby' project * Copyright (C) 2001-2002 Michal Rokos * All rights reserved. @@ -15,6 +15,10 @@ extern "C" { #endif +#ifndef TYPEDEF_D2I_OF +typedef char *d2i_of_void(); +#endif + /* * These functions are not included in headers of OPENSSL <= 0.9.6b */ diff -Nru ruby1.8-1.8.7.22/ext/openssl/ossl.h ruby1.8-1.8.7.72/ext/openssl/ossl.h --- ruby1.8-1.8.7.22/ext/openssl/ossl.h 2007-07-15 10:24:51.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/openssl/ossl.h 2008-06-29 05:16:02.000000000 -0300 @@ -1,5 +1,5 @@ /* - * $Id: ossl.h 12800 2007-07-15 13:24:51Z nobu $ + * $Id: ossl.h 17656 2008-06-29 08:16:02Z shyouhei $ * 'OpenSSL for Ruby' project * Copyright (C) 2001-2002 Michal Rokos * All rights reserved. @@ -46,7 +46,11 @@ #if defined(_WIN32) # define OSSL_NO_CONF_API 1 -# include +# ifdef USE_WINSOCK2 +# include +# else +# include +# endif #endif #include #include diff -Nru ruby1.8-1.8.7.22/ext/pty/.cvsignore ruby1.8-1.8.7.72/ext/pty/.cvsignore --- ruby1.8-1.8.7.22/ext/pty/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/pty/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/racc/cparse/.cvsignore ruby1.8-1.8.7.72/ext/racc/cparse/.cvsignore --- ruby1.8-1.8.7.22/ext/racc/cparse/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/racc/cparse/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/readline/.cvsignore ruby1.8-1.8.7.72/ext/readline/.cvsignore --- ruby1.8-1.8.7.22/ext/readline/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/readline/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/sdbm/.cvsignore ruby1.8-1.8.7.72/ext/sdbm/.cvsignore --- ruby1.8-1.8.7.22/ext/sdbm/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/sdbm/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/socket/.cvsignore ruby1.8-1.8.7.72/ext/socket/.cvsignore --- ruby1.8-1.8.7.22/ext/socket/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/socket/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/stringio/.cvsignore ruby1.8-1.8.7.72/ext/stringio/.cvsignore --- ruby1.8-1.8.7.22/ext/stringio/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/stringio/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/stringio/stringio.c ruby1.8-1.8.7.72/ext/stringio/stringio.c --- ruby1.8-1.8.7.22/ext/stringio/stringio.c 2008-05-27 07:07:07.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/stringio/stringio.c 2008-06-29 05:22:39.000000000 -0300 @@ -2,8 +2,8 @@ stringio.c - - $Author: knu $ - $Date: 2008-05-27 19:07:07 +0900 (Tue, 27 May 2008) $ + $Author: shyouhei $ + $Date: 2008-06-29 17:22:39 +0900 (Sun, 29 Jun 2008) $ $RoughId: stringio.c,v 1.13 2002/03/14 03:24:18 nobu Exp $ created at: Tue Feb 19 04:10:38 JST 2002 @@ -990,7 +990,7 @@ VALUE *argv; VALUE self; { - VALUE line = strio_getline(argc, argv, readable(StringIO(self))); + VALUE line = strio_gets(argc, argv, self); if (NIL_P(line)) rb_eof_error(); return line; } diff -Nru ruby1.8-1.8.7.22/ext/strscan/.cvsignore ruby1.8-1.8.7.72/ext/strscan/.cvsignore --- ruby1.8-1.8.7.22/ext/strscan/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/strscan/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/syck/.cvsignore ruby1.8-1.8.7.72/ext/syck/.cvsignore --- ruby1.8-1.8.7.22/ext/syck/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/syck/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/syslog/.cvsignore ruby1.8-1.8.7.72/ext/syslog/.cvsignore --- ruby1.8-1.8.7.22/ext/syslog/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/syslog/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/syslog/syslog.c ruby1.8-1.8.7.72/ext/syslog/syslog.c --- ruby1.8-1.8.7.22/ext/syslog/syslog.c 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/syslog/syslog.c 2008-07-02 06:58:40.000000000 -0300 @@ -4,7 +4,7 @@ * * * $RoughId: syslog.c,v 1.21 2002/02/25 12:21:17 knu Exp $ - * $Id: syslog.c 11708 2007-02-12 23:01:19Z shyouhei $ + * $Id: syslog.c 17809 2008-07-02 09:58:40Z shyouhei $ */ #include "ruby.h" @@ -22,6 +22,7 @@ { VALUE str; + rb_secure(4); if (argc < 1) { rb_raise(rb_eArgError, "no log message supplied"); } @@ -38,6 +39,7 @@ /* Syslog module methods */ static VALUE mSyslog_close(VALUE self) { + rb_secure(4); if (!syslog_opened) { rb_raise(rb_eRuntimeError, "syslog not opened"); } @@ -132,6 +134,7 @@ static VALUE mSyslog_set_mask(VALUE self, VALUE mask) { + rb_secure(4); if (!syslog_opened) { rb_raise(rb_eRuntimeError, "must open syslog before setting log mask"); } diff -Nru ruby1.8-1.8.7.22/ext/tk/.cvsignore ruby1.8-1.8.7.72/ext/tk/.cvsignore --- ruby1.8-1.8.7.22/ext/tk/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/tk/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.log diff -Nru ruby1.8-1.8.7.22/ext/tk/tkutil/.cvsignore ruby1.8-1.8.7.72/ext/tk/tkutil/.cvsignore --- ruby1.8-1.8.7.22/ext/tk/tkutil/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/tk/tkutil/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -*.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/Win32API/.cvsignore ruby1.8-1.8.7.72/ext/Win32API/.cvsignore --- ruby1.8-1.8.7.22/ext/Win32API/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/Win32API/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -*.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/win32ole/.cvsignore ruby1.8-1.8.7.72/ext/win32ole/.cvsignore --- ruby1.8-1.8.7.22/ext/win32ole/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/win32ole/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,4 +0,0 @@ -Makefile -mkmf.log -*.log -.document diff -Nru ruby1.8-1.8.7.22/ext/win32ole/tests/testall.rb ruby1.8-1.8.7.72/ext/win32ole/tests/testall.rb --- ruby1.8-1.8.7.22/ext/win32ole/tests/testall.rb 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/win32ole/tests/testall.rb 2008-07-07 00:29:28.000000000 -0300 @@ -12,4 +12,5 @@ require "test_ole_methods.rb" require "test_propertyputref.rb" require "test_word.rb" +require "test_win32ole_event.rb" # require "testOLEEVENT" diff -Nru ruby1.8-1.8.7.22/ext/win32ole/tests/testOLEEVENT.rb ruby1.8-1.8.7.72/ext/win32ole/tests/testOLEEVENT.rb --- ruby1.8-1.8.7.22/ext/win32ole/tests/testOLEEVENT.rb 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/win32ole/tests/testOLEEVENT.rb 1969-12-31 21:00:00.000000000 -0300 @@ -1,91 +0,0 @@ -require 'rubyunit' -require 'win32ole' - -class TestWIN32OLE_EVENT < RUNIT::TestCase - def setup - @excel = WIN32OLE.new("Excel.Application") - @excel.visible = true - @event = "" - @event2 = "" - end - def test_on_event - book = @excel.workbooks.Add - value = "" - begin - ev = WIN32OLE_EVENT.new(book, 'WorkbookEvents') - ev.on_event('SheetChange'){|arg1, arg2| - begin - value = arg1.value - rescue - value = $!.message - end - } - book.Worksheets(1).Range("A1").value = "OK" - ensure - book.saved = true - end - assert_equal("OK", value) - end - - def handler1 - @event += "handler1" - end - def handler2 - @event += "handler2" - end - - def handler3 - @event += "handler3" - end - - def test_on_event2 - book = @excel.workbooks.Add - begin - ev = WIN32OLE_EVENT.new(book, 'WorkbookEvents') - ev.on_event('SheetChange'){|arg1, arg2| - handler1 - } - ev.on_event('SheetChange'){|arg1, arg2| - handler2 - } - book.Worksheets(1).Range("A1").value = "OK" - ensure - book.saved = true - end - assert_equal("handler2", @event) - end - - def test_on_event3 - book = @excel.workbooks.Add - begin - ev = WIN32OLE_EVENT.new(book, 'WorkbookEvents') - ev.on_event{ handler1 } - ev.on_event{ handler2 } - book.Worksheets(1).Range("A1").value = "OK" - ensure - book.saved = true - end - assert_equal("handler2", @event) - end - - def test_on_event4 - book = @excel.workbooks.Add - begin - ev = WIN32OLE_EVENT.new(book, 'WorkbookEvents') - ev.on_event{ handler1 } - ev.on_event{ handler2 } - ev.on_event('SheetChange'){|arg1, arg2| handler3 } - book.Worksheets(1).Range("A1").value = "OK" - ensure - book.saved = true - end - assert_equal("handler3", @event) - end - - def teardown - @excel.quit - @excel = nil - GC.start - end -end - diff -Nru ruby1.8-1.8.7.22/ext/win32ole/tests/test_win32ole_event.rb ruby1.8-1.8.7.72/ext/win32ole/tests/test_win32ole_event.rb --- ruby1.8-1.8.7.22/ext/win32ole/tests/test_win32ole_event.rb 1969-12-31 21:00:00.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/win32ole/tests/test_win32ole_event.rb 2008-07-07 04:40:23.000000000 -0300 @@ -0,0 +1,133 @@ +begin + require 'win32ole' +rescue LoadError +end +require 'test/unit' + +if defined?(WIN32OLE_EVENT) + class TestWIN32OLE_EVENT < Test::Unit::TestCase + def create_temp_html + fso = WIN32OLE.new('Scripting.FileSystemObject') + dummy_file = fso.GetTempName + ".html" + cfolder = fso.getFolder(".") + f = cfolder.CreateTextFile(dummy_file) + f.writeLine("This is test HTML file for Win32OLE.") + f.close + dummy_path = cfolder.path + "\\" + dummy_file + dummy_path + end + + def setup + @ie = WIN32OLE.new("InternetExplorer.Application") + @ie.visible = true + @event = "" + @event2 = "" + @event3 = "" + @f = create_temp_html + end + + def default_handler(event, *args) + @event += event + end + + def test_on_event + ev = WIN32OLE_EVENT.new(@ie, 'DWebBrowserEvents') + ev.on_event {|*args| default_handler(*args)} + @ie.navigate("file:///#{@f}") + while @ie.busy + WIN32OLE_EVENT.new(@ie, 'DWebBrowserEvents') + GC.start + sleep 0.1 + end + assert_match(/BeforeNavigate/, @event) + assert_match(/NavigateComplete/, @event) + end + + def test_on_event2 + ev = WIN32OLE_EVENT.new(@ie, 'DWebBrowserEvents') + ev.on_event('BeforeNavigate') {|*args| handler1} + ev.on_event('BeforeNavigate') {|*args| handler2} + @ie.navigate("file:///#{@f}") + while @ie.busy + sleep 0.1 + end + assert_equal("handler2", @event2) + end + + def test_on_event3 + ev = WIN32OLE_EVENT.new(@ie, 'DWebBrowserEvents') + ev.on_event {|*args| handler1} + ev.on_event {|*args| handler2} + @ie.navigate("file:///#{@f}") + while @ie.busy + sleep 0.1 + end + assert_equal("handler2", @event2) + end + + def test_on_event4 + ev = WIN32OLE_EVENT.new(@ie, 'DWebBrowserEvents') + ev.on_event{|*args| handler1} + ev.on_event{|*args| handler2} + ev.on_event('NavigateComplete'){|*args| handler3(*args)} + @ie.navigate("file:///#{@f}") + while @ie.busy + sleep 0.1 + end + assert(@event3!="") + assert("handler2", @event2) + end + + def test_on_event5 + ev = WIN32OLE_EVENT.new(@ie, 'DWebBrowserEvents') + ev.on_event {|*args| default_handler(*args)} + ev.on_event('NavigateComplete'){|*args| handler3(*args)} + @ie.navigate("file:///#{@f}") + while @ie.busy + sleep 0.1 + end + assert_match(/BeforeNavigate/, @event) + assert(/NavigateComplete/ !~ @event) + assert(@event!="") + end + + def test_unadvise + ev = WIN32OLE_EVENT.new(@ie, 'DWebBrowserEvents') + ev.on_event {|*args| default_handler(*args)} + @ie.navigate("file:///#{@f}") + while @ie.busy + sleep 0.1 + end + assert_match(/BeforeNavigate/, @event) + ev.unadvise + @event = "" + @ie.navigate("file:///#{@f}") + while @ie.busy + sleep 0.1 + end + assert_equal("", @event); + assert_raise(WIN32OLERuntimeError) { + ev.on_event {|*args| default_handler(*args)} + } + end + + def handler1 + @event2 = "handler1" + end + + def handler2 + @event2 = "handler2" + end + + def handler3(url) + @event3 += url + end + + def teardown + @ie.quit + @ie = nil + File.unlink(@f) + GC.start + end + end +end diff -Nru ruby1.8-1.8.7.22/ext/win32ole/tests/testWIN32OLE.rb ruby1.8-1.8.7.72/ext/win32ole/tests/testWIN32OLE.rb --- ruby1.8-1.8.7.22/ext/win32ole/tests/testWIN32OLE.rb 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/win32ole/tests/testWIN32OLE.rb 2008-07-07 00:29:28.000000000 -0300 @@ -156,7 +156,8 @@ sheet.range("A3").value = "=A1*10 + 9" assert_equal(9999999999, sheet.range("A2").value) assert_equal(9999999999, sheet.range("A3").value) - + sheet.range("A4").value = "2008/03/04" + assert_equal("2008/03/04 00:00:00", sheet.range("A4").value) ensure book.saved = true end diff -Nru ruby1.8-1.8.7.22/ext/win32ole/win32ole.c ruby1.8-1.8.7.72/ext/win32ole/win32ole.c --- ruby1.8-1.8.7.22/ext/win32ole/win32ole.c 2007-11-17 02:25:09.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/win32ole/win32ole.c 2008-07-07 00:29:28.000000000 -0300 @@ -12,7 +12,7 @@ */ /* - $Date: 2007-11-17 14:25:09 +0900 (Sat, 17 Nov 2007) $ + $Date: 2008-07-07 12:29:28 +0900 (Mon, 07 Jul 2008) $ modified for win32ole (ruby) by Masaki.Suketa */ @@ -29,7 +29,7 @@ #include #define va_init_list(a,b) va_start(a) #endif - +#include #define DOUT fprintf(stderr,"[%d]\n",__LINE__) #define DOUTS(x) fprintf(stderr,"[%d]:" #x "=%s\n",__LINE__,x) @@ -79,7 +79,7 @@ #define WC2VSTR(x) ole_wc2vstr((x), TRUE) -#define WIN32OLE_VERSION "0.7.4" +#define WIN32OLE_VERSION "0.7.6" typedef HRESULT (STDAPICALLTYPE FNCOCREATEINSTANCEEX) (REFCLSID, IUnknown*, DWORD, COSERVERINFO*, DWORD, MULTI_QI*); @@ -157,6 +157,9 @@ static IDispatchVtbl com_vtbl; static UINT cWIN32OLE_cp = CP_ACP; static VARTYPE g_nil_to = VT_ERROR; +static IMessageFilterVtbl message_filter; +static IMessageFilter imessage_filter = { &message_filter }; +static IMessageFilter* previous_filter; struct oledata { IDispatch *pDispatch; @@ -203,6 +206,101 @@ static VALUE ole_variant2val(VARIANT*); static void ole_val2variant(VALUE, VARIANT*); +static HRESULT (STDMETHODCALLTYPE mf_QueryInterface)( + IMessageFilter __RPC_FAR * This, + /* [in] */ REFIID riid, + /* [iid_is][out] */ void __RPC_FAR *__RPC_FAR *ppvObject) +{ + if (MEMCMP(riid, &IID_IUnknown, GUID, 1) == 0 + || MEMCMP(riid, &IID_IMessageFilter, GUID, 1) == 0) + { + *ppvObject = &message_filter; + return S_OK; + } + return E_NOINTERFACE; +} + +static ULONG (STDMETHODCALLTYPE mf_AddRef)( + IMessageFilter __RPC_FAR * This) +{ + return 1; +} + +static ULONG (STDMETHODCALLTYPE mf_Release)( + IMessageFilter __RPC_FAR * This) +{ + return 1; +} + +static DWORD (STDMETHODCALLTYPE mf_HandleInComingCall)( + IMessageFilter __RPC_FAR * pThis, + DWORD dwCallType, //Type of incoming call + HTASK threadIDCaller, //Task handle calling this task + DWORD dwTickCount, //Elapsed tick count + LPINTERFACEINFO lpInterfaceInfo //Pointer to INTERFACEINFO structure + ) +{ +#ifdef DEBUG_MESSAGEFILTER + printf("incoming %08X, %08X, %d\n", dwCallType, threadIDCaller, dwTickCount); + fflush(stdout); +#endif + switch (dwCallType) + { + case CALLTYPE_ASYNC: + case CALLTYPE_TOPLEVEL_CALLPENDING: + case CALLTYPE_ASYNC_CALLPENDING: + if (rb_during_gc()) { + return SERVERCALL_RETRYLATER; + } + break; + default: + break; + } + if (previous_filter) { + return previous_filter->lpVtbl->HandleInComingCall(previous_filter, + dwCallType, + threadIDCaller, + dwTickCount, + lpInterfaceInfo); + } + return SERVERCALL_ISHANDLED; +} + +static DWORD (STDMETHODCALLTYPE mf_RetryRejectedCall)( + IMessageFilter* pThis, + HTASK threadIDCallee, //Server task handle + DWORD dwTickCount, //Elapsed tick count + DWORD dwRejectType //Returned rejection message + ) +{ + if (previous_filter) { + return previous_filter->lpVtbl->RetryRejectedCall(previous_filter, + threadIDCallee, + dwTickCount, + dwRejectType); + } + return 1000; +} + +static DWORD (STDMETHODCALLTYPE mf_MessagePending)( + IMessageFilter* pThis, + HTASK threadIDCallee, //Called applications task handle + DWORD dwTickCount, //Elapsed tick count + DWORD dwPendingType //Call type + ) +{ + if (rb_during_gc()) { + return PENDINGMSG_WAITNOPROCESS; + } + if (previous_filter) { + return previous_filter->lpVtbl->MessagePending(previous_filter, + threadIDCallee, + dwTickCount, + dwPendingType); + } + return PENDINGMSG_WAITNOPROCESS; +} + typedef struct _Win32OLEIDispatch { IDispatch dispatch; @@ -459,7 +557,7 @@ double date; { int y, m, d, hh, mm, ss; - char szTime[20]; + char szTime[40]; double2time(date, &y, &m, &d, &hh, &mm, &ss); sprintf(szTime, "%4.4d/%02.2d/%02.2d %02.2d:%02.2d:%02.2d", @@ -522,6 +620,15 @@ return msg; } +static void +ole_freeexceptinfo(pExInfo) + EXCEPINFO *pExInfo; +{ + SysFreeString(pExInfo->bstrDescription); + SysFreeString(pExInfo->bstrSource); + SysFreeString(pExInfo->bstrHelpFile); +} + static VALUE ole_excepinfo2msg(pExInfo) EXCEPINFO *pExInfo; @@ -561,9 +668,7 @@ } if(pSource) free(pSource); if(pDescription) free(pDescription); - SysFreeString(pExInfo->bstrDescription); - SysFreeString(pExInfo->bstrSource); - SysFreeString(pExInfo->bstrHelpFile); + ole_freeexceptinfo(pExInfo); return error_msg; } @@ -618,6 +723,11 @@ /* atexit((void (*)(void))ole_uninitialize); */ + hr = CoRegisterMessageFilter(&imessage_filter, &previous_filter); + if(FAILED(hr)) { + previous_filter = NULL; + ole_raise(hr, rb_eRuntimeError, "fail: install OLE MessageFilter"); + } } } @@ -2109,6 +2219,9 @@ param = rb_ary_entry(paramS, i-cNamedArgs); ole_val2variant(param, &op.dp.rgvarg[n]); } + if (hr == DISP_E_EXCEPTION) { + ole_freeexceptinfo(&excepinfo); + } memset(&excepinfo, 0, sizeof(EXCEPINFO)); VariantInit(&result); hr = pole->pDispatch->lpVtbl->Invoke(pole->pDispatch, DispID, @@ -2121,6 +2234,9 @@ * hResult == DISP_E_EXCEPTION. this only happens on * functions whose DISPID > 0x8000 */ if ((hr == DISP_E_EXCEPTION || hr == DISP_E_MEMBERNOTFOUND) && DispID > 0x8000) { + if (hr == DISP_E_EXCEPTION) { + ole_freeexceptinfo(&excepinfo); + } memset(&excepinfo, 0, sizeof(EXCEPINFO)); hr = pole->pDispatch->lpVtbl->Invoke(pole->pDispatch, DispID, &IID_NULL, lcid, wFlags, @@ -2140,6 +2256,9 @@ param = rb_ary_entry(paramS, i-cNamedArgs); ole_val2variant2(param, &op.dp.rgvarg[n]); } + if (hr == DISP_E_EXCEPTION) { + ole_freeexceptinfo(&excepinfo); + } memset(&excepinfo, 0, sizeof(EXCEPINFO)); VariantInit(&result); hr = pole->pDispatch->lpVtbl->Invoke(pole->pDispatch, DispID, @@ -6167,6 +6286,14 @@ com_vtbl.GetTypeInfo = GetTypeInfo; com_vtbl.GetIDsOfNames = GetIDsOfNames; com_vtbl.Invoke = Invoke; + + message_filter.QueryInterface = mf_QueryInterface; + message_filter.AddRef = mf_AddRef; + message_filter.Release = mf_Release; + message_filter.HandleInComingCall = mf_HandleInComingCall; + message_filter.RetryRejectedCall = mf_RetryRejectedCall; + message_filter.MessagePending = mf_MessagePending; + com_hash = Data_Wrap_Struct(rb_cData, rb_mark_hash, st_free_table, st_init_numtable()); cWIN32OLE = rb_define_class("WIN32OLE", rb_cObject); diff -Nru ruby1.8-1.8.7.22/ext/zlib/.cvsignore ruby1.8-1.8.7.72/ext/zlib/.cvsignore --- ruby1.8-1.8.7.22/ext/zlib/.cvsignore 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/zlib/.cvsignore 1969-12-31 21:00:00.000000000 -0300 @@ -1,3 +0,0 @@ -Makefile -mkmf.log -*.def diff -Nru ruby1.8-1.8.7.22/ext/zlib/zlib.c ruby1.8-1.8.7.72/ext/zlib/zlib.c --- ruby1.8-1.8.7.22/ext/zlib/zlib.c 2008-06-08 15:28:37.000000000 -0300 +++ ruby1.8-1.8.7.72/ext/zlib/zlib.c 2008-07-16 13:39:00.000000000 -0300 @@ -3,7 +3,7 @@ * * Copyright (C) UENO Katsuhiro 2000-2003 * - * $Id: zlib.c 17033 2008-06-08 18:28:37Z knu $ + * $Id: zlib.c 18089 2008-07-16 16:39:00Z shyouhei $ */ #include @@ -2491,7 +2491,7 @@ rb_raise(cGzError, "header is already written"); } - if (FIXNUM_P(time)) { + if (FIXNUM_P(mtime)) { gz->mtime = FIX2INT(mtime); } else { diff -Nru ruby1.8-1.8.7.22/file.c ruby1.8-1.8.7.72/file.c --- ruby1.8-1.8.7.22/file.c 2008-06-17 03:10:23.000000000 -0300 +++ ruby1.8-1.8.7.72/file.c 2008-07-10 06:47:31.000000000 -0300 @@ -2,8 +2,8 @@ file.c - - $Author: knu $ - $Date: 2008-06-17 15:10:23 +0900 (Tue, 17 Jun 2008) $ + $Author: shyouhei $ + $Date: 2008-07-10 18:47:31 +0900 (Thu, 10 Jul 2008) $ created at: Mon Nov 15 12:24:34 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -3044,7 +3044,7 @@ p = last; break; } - e = dot; + if (*last == '.') e = dot; continue; #else e = p; /* get the last dot of the last component */ diff -Nru ruby1.8-1.8.7.22/gc.c ruby1.8-1.8.7.72/gc.c --- ruby1.8-1.8.7.22/gc.c 2008-06-08 15:21:56.000000000 -0300 +++ ruby1.8-1.8.7.72/gc.c 2008-08-04 00:24:26.000000000 -0300 @@ -2,8 +2,8 @@ gc.c - - $Author: knu $ - $Date: 2008-06-09 03:21:56 +0900 (Mon, 09 Jun 2008) $ + $Author: shyouhei $ + $Date: 2008-08-04 12:24:26 +0900 (Mon, 04 Aug 2008) $ created at: Tue Oct 5 09:44:46 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -78,16 +78,22 @@ int ruby_gc_stress = 0; +NORETURN(void rb_exc_jump _((VALUE))); + void rb_memerror() { - static int recurse = 0; + rb_thread_t th = rb_curr_thread; - if (!nomem_error || (recurse > 0 && rb_safe_level() < 4)) { + if (!nomem_error || + (rb_thread_raised_p(th, RAISED_NOMEMORY) && rb_safe_level() < 4)) { fprintf(stderr, "[FATAL] failed to allocate memory\n"); exit(1); } - recurse++; + if (rb_thread_raised_p(th, RAISED_NOMEMORY)) { + rb_exc_jump(nomem_error); + } + rb_thread_raised_set(th, RAISED_NOMEMORY); rb_exc_raise(nomem_error); } @@ -136,9 +142,8 @@ rb_raise(rb_eNoMemError, "negative allocation size (or too big)"); } if (size == 0) size = 1; - malloc_increase += size; - if (ruby_gc_stress || malloc_increase > malloc_limit) { + if (ruby_gc_stress || (malloc_increase+size) > malloc_limit) { garbage_collect(); } RUBY_CRITICAL(mem = malloc(size)); @@ -149,6 +154,7 @@ rb_memerror(); } } + malloc_increase += size; return mem; } @@ -177,7 +183,6 @@ } if (!ptr) return xmalloc(size); if (size == 0) size = 1; - malloc_increase += size; if (ruby_gc_stress) garbage_collect(); RUBY_CRITICAL(mem = realloc(ptr, size)); if (!mem) { @@ -187,6 +192,7 @@ rb_memerror(); } } + malloc_increase += size; return mem; } @@ -413,6 +419,12 @@ } #define RANY(o) ((RVALUE*)(o)) +int +rb_during_gc() +{ + return during_gc; +} + VALUE rb_newobj() { @@ -2103,7 +2115,10 @@ source_filenames = st_init_strtable(); rb_global_variable(&nomem_error); - nomem_error = rb_exc_new2(rb_eNoMemError, "failed to allocate memory"); + nomem_error = rb_exc_new3(rb_eNoMemError, + rb_obj_freeze(rb_str_new2("failed to allocate memory"))); + OBJ_TAINT(nomem_error); + OBJ_FREEZE(nomem_error); rb_define_method(rb_mKernel, "hash", rb_obj_id, 0); rb_define_method(rb_mKernel, "__id__", rb_obj_id, 0); diff -Nru ruby1.8-1.8.7.22/intern.h ruby1.8-1.8.7.72/intern.h --- ruby1.8-1.8.7.22/intern.h 2008-06-19 20:12:46.000000000 -0300 +++ ruby1.8-1.8.7.72/intern.h 2008-07-07 00:29:28.000000000 -0300 @@ -3,7 +3,7 @@ intern.h - $Author: shyouhei $ - $Date: 2008-06-20 08:12:46 +0900 (Fri, 20 Jun 2008) $ + $Date: 2008-07-07 12:29:28 +0900 (Mon, 07 Jul 2008) $ created at: Thu Jun 10 14:22:17 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -252,6 +252,7 @@ NORETURN(void rb_memerror __((void))); int ruby_stack_check _((void)); int ruby_stack_length _((VALUE**)); +int rb_during_gc _((void)); char *rb_source_filename _((const char*)); void rb_gc_mark_locations _((VALUE*, VALUE*)); void rb_mark_tbl _((struct st_table*)); diff -Nru ruby1.8-1.8.7.22/lib/cgi.rb ruby1.8-1.8.7.72/lib/cgi.rb --- ruby1.8-1.8.7.22/lib/cgi.rb 2008-03-14 05:45:26.000000000 -0200 +++ ruby1.8-1.8.7.72/lib/cgi.rb 2008-07-02 07:06:58.000000000 -0300 @@ -284,7 +284,7 @@ # Standard internet newline sequence EOL = CR + LF - REVISION = '$Id: cgi.rb 15778 2008-03-14 07:45:26Z matz $' #:nodoc: + REVISION = '$Id: cgi.rb 17817 2008-07-02 10:06:58Z shyouhei $' #:nodoc: NEEDS_BINMODE = true if /WIN/ni.match(RUBY_PLATFORM) @@ -1043,7 +1043,7 @@ body.rewind - /Content-Disposition:.* filename=(?:"((?:\\.|[^\"\s])*)"|([^;\s]*))/ni.match(head) + /Content-Disposition:.* filename=(?:"((?:\\.|[^\"])*)"|([^;\s]*))/ni.match(head) filename = ($1 or $2 or "") if /Mac/ni.match(env_table['HTTP_USER_AGENT']) and /Mozilla/ni.match(env_table['HTTP_USER_AGENT']) and diff -Nru ruby1.8-1.8.7.22/lib/erb.rb ruby1.8-1.8.7.72/lib/erb.rb --- ruby1.8-1.8.7.22/lib/erb.rb 2008-06-06 05:05:24.000000000 -0300 +++ ruby1.8-1.8.7.72/lib/erb.rb 2008-07-10 06:43:07.000000000 -0300 @@ -236,7 +236,7 @@ # Rails, the web application framework, uses ERB to create views. # class ERB - Revision = '$Date: 2008-06-06 17:05:24 +0900 (Fri, 06 Jun 2008) $' #' + Revision = '$Date: 2008-07-10 18:43:07 +0900 (Thu, 10 Jul 2008) $' #' # Returns revision information for the erb.rb module. def self.version @@ -427,7 +427,7 @@ Scanner.regist_scanner(SimpleScanner2, nil, false) class PercentScanner < Scanner # :nodoc: - def scan + def scan(&blk) stag_reg = /(.*?)(^%%|^%|<%%|<%=|<%#|<%|\z)/m etag_reg = /(.*?)(%%>|%>|\z)/m scanner = StringScanner.new(@src) @@ -437,11 +437,24 @@ elem = scanner[2] if elem == '%%' - elem = '%' + yield('%') + inline_scan(scanner.scan(/.*?(\n|\z)/), &blk) elsif elem == '%' - elem = PercentLine.new(scanner.scan(/.*?(\n|\z)/).chomp) + yield(PercentLine.new(scanner.scan(/.*?(\n|\z)/).chomp)) + else + yield(elem) end - yield(elem) + end + end + + def inline_scan(line) + stag_reg = /(.*?)(<%%|<%=|<%#|<%|\z)/m + etag_reg = /(.*?)(%%>|%>|\z)/m + scanner = StringScanner.new(line) + while ! scanner.eos? + scanner.scan(@stag ? etag_reg : stag_reg) + yield(scanner[1]) + yield(scanner[2]) end end end diff -Nru ruby1.8-1.8.7.22/lib/ipaddr.rb ruby1.8-1.8.7.72/lib/ipaddr.rb --- ruby1.8-1.8.7.22/lib/ipaddr.rb 2008-03-21 09:16:15.000000000 -0300 +++ ruby1.8-1.8.7.72/lib/ipaddr.rb 2008-07-12 12:08:29.000000000 -0300 @@ -7,7 +7,7 @@ # # You can redistribute and/or modify it under the same terms as Ruby. # -# $Id: ipaddr.rb 15822 2008-03-21 12:16:15Z knu $ +# $Id: ipaddr.rb 18049 2008-07-12 15:08:29Z shyouhei $ # # Contact: # - Akinori MUSHA (current maintainer) @@ -483,7 +483,7 @@ if prefixlen mask!(prefixlen) else - @mask_addr = (family == Socket::AF_INET) ? IN4MASK : IN6MASK + @mask_addr = (@family == Socket::AF_INET) ? IN4MASK : IN6MASK end end diff -Nru ruby1.8-1.8.7.22/lib/net/ftp.rb ruby1.8-1.8.7.72/lib/net/ftp.rb --- ruby1.8-1.8.7.22/lib/net/ftp.rb 2007-05-30 01:27:12.000000000 -0300 +++ ruby1.8-1.8.7.72/lib/net/ftp.rb 2008-07-10 06:40:34.000000000 -0300 @@ -278,12 +278,9 @@ def sendport(host, port) af = (@sock.peeraddr)[0] if af == "AF_INET" - hbytes = host.split(".") - pbytes = [port / 256, port % 256] - bytes = hbytes + pbytes - cmd = "PORT " + bytes.join(",") + cmd = "PORT " + (host.split(".") + port.divmod(256)).join(",") elsif af == "AF_INET6" - cmd = "EPRT |2|" + host + "|" + sprintf("%d", port) + "|" + cmd = sprintf("EPRT |2|%s|%d|", host, port) else raise FTPProtoError, host end diff -Nru ruby1.8-1.8.7.22/lib/net/smtp.rb ruby1.8-1.8.7.72/lib/net/smtp.rb --- ruby1.8-1.8.7.22/lib/net/smtp.rb 2008-04-15 05:50:21.000000000 -0300 +++ ruby1.8-1.8.7.72/lib/net/smtp.rb 2008-08-04 02:51:11.000000000 -0300 @@ -14,7 +14,7 @@ # NOTE: You can find Japanese version of this document at: # http://www.ruby-lang.org/ja/man/html/net_smtp.html # -# $Id: smtp.rb 16034 2008-04-15 08:50:21Z kazu $ +# $Id: smtp.rb 18353 2008-08-04 05:51:11Z shyouhei $ # # See Net::SMTP for documentation. # @@ -172,7 +172,7 @@ # class SMTP - Revision = %q$Revision: 16034 $.split[1] + Revision = %q$Revision: 18353 $.split[1] # The default SMTP port number, 25. def SMTP.default_port @@ -837,7 +837,7 @@ def rcptto(to_addr) if $SAFE > 0 - raise SecurityError, 'tainted to_addr' if to.tainted? + raise SecurityError, 'tainted to_addr' if to_addr.tainted? end getok("RCPT TO:<#{to_addr}>") end diff -Nru ruby1.8-1.8.7.22/lib/optparse.rb ruby1.8-1.8.7.72/lib/optparse.rb --- ruby1.8-1.8.7.22/lib/optparse.rb 2008-06-06 05:05:24.000000000 -0300 +++ ruby1.8-1.8.7.72/lib/optparse.rb 2008-07-17 09:31:06.000000000 -0300 @@ -203,7 +203,7 @@ # class OptionParser # :stopdoc: - RCSID = %w$Id: optparse.rb 16857 2008-06-06 08:05:24Z knu $[1..-1].each {|s| s.freeze}.freeze + RCSID = %w$Id: optparse.rb 18110 2008-07-17 12:31:06Z shyouhei $[1..-1].each {|s| s.freeze}.freeze Version = (RCSID[1].split('.').collect {|s| s.to_i}.extend(Comparable).freeze if RCSID[1]) LastModified = (Time.gm(*RCSID[2, 2].join('-').scan(/\d+/).collect {|s| s.to_i}) if RCSID[2]) Release = RCSID[2] @@ -1476,6 +1476,7 @@ # def environment(env = File.basename($0, '.*')) env = ENV[env] || ENV[env.upcase] or return + require 'shellwords' parse(*Shellwords.shellwords(env)) end diff -Nru ruby1.8-1.8.7.22/lib/rdoc/parsers/parse_rb.rb ruby1.8-1.8.7.72/lib/rdoc/parsers/parse_rb.rb --- ruby1.8-1.8.7.22/lib/rdoc/parsers/parse_rb.rb 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/lib/rdoc/parsers/parse_rb.rb 2008-06-29 05:24:56.000000000 -0300 @@ -1546,10 +1546,15 @@ tk = get_tk while tk.kind_of?(TkCOMMENT) - if first_line && tk.text[0,2] == "#!" + if first_line && /\A#!/ =~ tk.text + skip_tkspace + tk = get_tk + elsif first_line && /\A#\s*-\*-/ =~ tk.text + first_line = false skip_tkspace tk = get_tk else + first_line = false res << tk.text << "\n" tk = get_tk if tk.kind_of? TkNL @@ -1557,7 +1562,6 @@ tk = get_tk end end - first_line = false end unget_tk(tk) res diff -Nru ruby1.8-1.8.7.22/lib/resolv.rb ruby1.8-1.8.7.72/lib/resolv.rb --- ruby1.8-1.8.7.22/lib/resolv.rb 2008-06-06 05:05:24.000000000 -0300 +++ ruby1.8-1.8.7.72/lib/resolv.rb 2008-08-07 22:58:40.000000000 -0300 @@ -3,6 +3,11 @@ require 'timeout' require 'thread' +begin + require 'securerandom' +rescue LoadError +end + # Resolv is a thread-aware DNS resolver library written in Ruby. Resolv can # handle multiple DNS requests concurrently without blocking. The ruby # interpreter. @@ -285,7 +290,7 @@ UDPSize = 512 ## - # Group of DNS resolver threads + # Group of DNS resolver threads (obsolete) DNSThreadGroup = ThreadGroup.new @@ -330,13 +335,6 @@ @mutex.synchronize { unless @initialized @config.lazy_initialize - - if nameserver = @config.single? - @requester = Requester::ConnectedUDP.new(nameserver) - else - @requester = Requester::UnconnectedUDP.new - end - @initialized = true end } @@ -349,8 +347,6 @@ def close @mutex.synchronize { if @initialized - @requester.close if @requester - @requester = nil @initialized = false end } @@ -479,7 +475,7 @@ def each_resource(name, typeclass, &proc) lazy_initialize - q = Queue.new + requester = make_requester senders = {} begin @config.resolv(name) {|candidate, tout, nameserver| @@ -488,11 +484,9 @@ msg.add_question(candidate, typeclass) unless sender = senders[[candidate, nameserver]] sender = senders[[candidate, nameserver]] = - @requester.sender(msg, candidate, q, nameserver) + requester.sender(msg, candidate, nameserver) end - sender.send - reply = reply_name = nil - timeout(tout, ResolvTimeout) { reply, reply_name = q.pop } + reply, reply_name = requester.request(sender, tout) case reply.rcode when RCode::NoError extract_resources(reply, reply_name, typeclass, &proc) @@ -504,7 +498,15 @@ end } ensure - @requester.delete(q) + requester.close + end + end + + def make_requester # :nodoc: + if nameserver = @config.single? + Requester::ConnectedUDP.new(nameserver) + else + Requester::UnconnectedUDP.new end end @@ -539,45 +541,106 @@ } end + if defined? SecureRandom + def self.random(arg) # :nodoc: + begin + SecureRandom.random_number(arg) + rescue NotImplementedError + rand(arg) + end + end + else + def self.random(arg) # :nodoc: + rand(arg) + end + end + + + def self.rangerand(range) # :nodoc: + base = range.begin + len = range.end - range.begin + if !range.exclude_end? + len += 1 + end + base + random(len) + end + + RequestID = {} + RequestIDMutex = Mutex.new + + def self.allocate_request_id(host, port) # :nodoc: + id = nil + RequestIDMutex.synchronize { + h = (RequestID[[host, port]] ||= {}) + begin + id = rangerand(0x0000..0xffff) + end while h[id] + h[id] = true + } + id + end + + def self.free_request_id(host, port, id) # :nodoc: + RequestIDMutex.synchronize { + key = [host, port] + if h = RequestID[key] + h.delete id + if h.empty? + RequestID.delete key + end + end + } + end + + def self.bind_random_port(udpsock) # :nodoc: + begin + port = rangerand(1024..65535) + udpsock.bind("", port) + rescue Errno::EADDRINUSE + retry + end + end + class Requester # :nodoc: def initialize @senders = {} + @sock = nil end - def close - thread, sock, @thread, @sock = @thread, @sock - begin - if thread - thread.kill - thread.join + def request(sender, tout) + timelimit = Time.now + tout + sender.send + while (now = Time.now) < timelimit + timeout = timelimit - now + if !IO.select([@sock], nil, nil, timeout) + raise ResolvTimeout + end + reply, from = recv_reply + begin + msg = Message.decode(reply) + rescue DecodeError + next # broken DNS message ignored + end + if s = @senders[[from,msg.id]] + break + else + # unexpected DNS message ignored end - ensure - sock.close if sock end + return msg, s.data end - def delete(arg) - case arg - when Sender - @senders.delete_if {|k, s| s == arg } - when Queue - @senders.delete_if {|k, s| s.queue == arg } - else - raise ArgumentError.new("neither Sender or Queue: #{arg}") - end + def close + sock = @sock + @sock = nil + sock.close if sock end class Sender # :nodoc: - def initialize(msg, data, sock, queue) + def initialize(msg, data, sock) @msg = msg @data = data @sock = sock - @queue = queue - end - attr_reader :queue - - def recv(msg) - @queue.push([msg, @data]) end end @@ -585,45 +648,38 @@ def initialize super() @sock = UDPSocket.new - @sock.fcntl(Fcntl::F_SETFD, 1) if defined? Fcntl::F_SETFD - @id = {} - @id.default = -1 - @thread = Thread.new { - DNSThreadGroup.add Thread.current - loop { - reply, from = @sock.recvfrom(UDPSize) - msg = begin - Message.decode(reply) - rescue DecodeError - STDERR.print("DNS message decoding error: #{reply.inspect}\n") - next - end - if s = @senders[[[from[3],from[1]],msg.id]] - s.recv msg - else - #STDERR.print("non-handled DNS message: #{msg.inspect} from #{from.inspect}\n") - end - } - } + @sock.fcntl(Fcntl::F_SETFD, Fcntl::FD_CLOEXEC) if defined? Fcntl::F_SETFD + DNS.bind_random_port(@sock) + end + + def recv_reply + reply, from = @sock.recvfrom(UDPSize) + return reply, [from[3],from[1]] end - def sender(msg, data, queue, host, port=Port) + def sender(msg, data, host, port=Port) service = [host, port] - id = Thread.exclusive { - @id[service] = (@id[service] + 1) & 0xffff - } + id = DNS.allocate_request_id(host, port) request = msg.encode request[0,2] = [id].pack('n') return @senders[[service, id]] = - Sender.new(request, data, @sock, host, port, queue) + Sender.new(request, data, @sock, host, port) + end + + def close + super + @senders.each_key {|service, id| + DNS.free_request_id(service[0], service[1], id) + } end class Sender < Requester::Sender # :nodoc: - def initialize(msg, data, sock, host, port, queue) - super(msg, data, sock, queue) + def initialize(msg, data, sock, host, port) + super(msg, data, sock) @host = host @port = port end + attr_reader :data def send @sock.send(@msg, 0, @host, @port) @@ -637,42 +693,38 @@ @host = host @port = port @sock = UDPSocket.new(host.index(':') ? Socket::AF_INET6 : Socket::AF_INET) + DNS.bind_random_port(@sock) @sock.connect(host, port) - @sock.fcntl(Fcntl::F_SETFD, 1) if defined? Fcntl::F_SETFD - @id = -1 - @thread = Thread.new { - DNSThreadGroup.add Thread.current - loop { - reply = @sock.recv(UDPSize) - msg = begin - Message.decode(reply) - rescue DecodeError - STDERR.print("DNS message decoding error: #{reply.inspect}") - next - end - if s = @senders[msg.id] - s.recv msg - else - #STDERR.print("non-handled DNS message: #{msg.inspect}") - end - } - } + @sock.fcntl(Fcntl::F_SETFD, Fcntl::FD_CLOEXEC) if defined? Fcntl::F_SETFD + end + + def recv_reply + reply = @sock.recv(UDPSize) + return reply, nil end - def sender(msg, data, queue, host=@host, port=@port) + def sender(msg, data, host=@host, port=@port) unless host == @host && port == @port raise RequestError.new("host/port don't match: #{host}:#{port}") end - id = Thread.exclusive { @id = (@id + 1) & 0xffff } + id = DNS.allocate_request_id(@host, @port) request = msg.encode request[0,2] = [id].pack('n') - return @senders[id] = Sender.new(request, data, @sock, queue) + return @senders[[nil,id]] = Sender.new(request, data, @sock) + end + + def close + super + @senders.each_key {|from, id| + DNS.free_request_id(@host, @port, id) + } end class Sender < Requester::Sender # :nodoc: def send @sock.send(@msg, 0) end + attr_reader :data end end @@ -681,39 +733,25 @@ super() @host = host @port = port - @sock = TCPSocket.new - @sock.connect(host, port) - @sock.fcntl(Fcntl::F_SETFD, 1) if defined? Fcntl::F_SETFD - @id = -1 + @sock = TCPSocket.new(@host, @port) + @sock.fcntl(Fcntl::F_SETFD, Fcntl::FD_CLOEXEC) if defined? Fcntl::F_SETFD @senders = {} - @thread = Thread.new { - DNSThreadGroup.add Thread.current - loop { - len = @sock.read(2).unpack('n') - reply = @sock.read(len) - msg = begin - Message.decode(reply) - rescue DecodeError - STDERR.print("DNS message decoding error: #{reply.inspect}") - next - end - if s = @senders[msg.id] - s.push msg - else - #STDERR.print("non-handled DNS message: #{msg.inspect}") - end - } - } end - def sender(msg, data, queue, host=@host, port=@port) + def recv_reply + len = @sock.read(2).unpack('n')[0] + reply = @sock.read(len) + return reply, nil + end + + def sender(msg, data, host=@host, port=@port) unless host == @host && port == @port raise RequestError.new("host/port don't match: #{host}:#{port}") end - id = Thread.exclusive { @id = (@id + 1) & 0xffff } + id = DNS.allocate_request_id(@host, @port) request = msg.encode request[0,2] = [request.length, id].pack('nn') - return @senders[id] = Sender.new(request, data, @sock, queue) + return @senders[[nil,id]] = Sender.new(request, data, @sock) end class Sender < Requester::Sender # :nodoc: @@ -721,6 +759,14 @@ @sock.print(@msg) @sock.flush end + attr_reader :data + end + + def close + super + @senders.each_key {|from,id| + DNS.free_request_id(@host, @port, id) + } end end diff -Nru ruby1.8-1.8.7.22/lib/resolv-replace.rb ruby1.8-1.8.7.72/lib/resolv-replace.rb --- ruby1.8-1.8.7.22/lib/resolv-replace.rb 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/lib/resolv-replace.rb 2008-08-07 22:58:40.000000000 -0300 @@ -23,7 +23,8 @@ class UDPSocket alias original_resolv_bind bind def bind(host, port) - original_resolv_bind(IPSocket.getaddress(host), port) + host = IPSocket.getaddress(host) if host != "" + original_resolv_bind(host, port) end alias original_resolv_connect connect diff -Nru ruby1.8-1.8.7.22/lib/singleton.rb ruby1.8-1.8.7.72/lib/singleton.rb --- ruby1.8-1.8.7.22/lib/singleton.rb 2008-05-28 04:16:25.000000000 -0300 +++ ruby1.8-1.8.7.72/lib/singleton.rb 2008-07-03 08:14:50.000000000 -0300 @@ -71,7 +71,6 @@ raise TypeError, "can't dup instance of singleton #{self.class}" end - private # default marshalling strategy def _dump(depth=-1) '' diff -Nru ruby1.8-1.8.7.22/lib/tmpdir.rb ruby1.8-1.8.7.72/lib/tmpdir.rb --- ruby1.8-1.8.7.22/lib/tmpdir.rb 2007-10-24 03:03:48.000000000 -0300 +++ ruby1.8-1.8.7.72/lib/tmpdir.rb 2008-07-02 06:23:13.000000000 -0300 @@ -1,7 +1,7 @@ # # tmpdir - retrieve temporary directory path # -# $Id: tmpdir.rb 13762 2007-10-24 06:03:48Z akr $ +# $Id: tmpdir.rb 17801 2008-07-02 09:23:13Z shyouhei $ # require 'fileutils' @@ -12,16 +12,23 @@ begin require 'Win32API' + CSIDL_LOCAL_APPDATA = 0x001c max_pathlen = 260 windir = ' '*(max_pathlen+1) begin - getdir = Win32API.new('kernel32', 'GetSystemWindowsDirectory', 'PL', 'L') + getdir = Win32API.new('shell32', 'SHGetFolderPath', 'LLLLP', 'L') + raise RuntimeError if getdir.call(0, CSIDL_LOCAL_APPDATA, 0, 0, windir) != 0 + windir = File.expand_path(windir.rstrip) rescue RuntimeError - getdir = Win32API.new('kernel32', 'GetWindowsDirectory', 'PL', 'L') + begin + getdir = Win32API.new('kernel32', 'GetSystemWindowsDirectory', 'PL', 'L') + rescue RuntimeError + getdir = Win32API.new('kernel32', 'GetWindowsDirectory', 'PL', 'L') + end + len = getdir.call(windir, windir.size) + windir = File.expand_path(windir[0, len]) end - len = getdir.call(windir, windir.size) - windir = File.expand_path(windir[0, len]) - temp = File.join(windir, 'temp') + temp = File.join(windir.untaint, 'temp') @@systmpdir = temp if File.directory?(temp) and File.writable?(temp) rescue LoadError end @@ -41,8 +48,8 @@ break end end + File.expand_path(tmp) end - File.expand_path(tmp) end # Dir.mktmpdir creates a temporary directory. diff -Nru ruby1.8-1.8.7.22/lib/webrick/httputils.rb ruby1.8-1.8.7.72/lib/webrick/httputils.rb --- ruby1.8-1.8.7.22/lib/webrick/httputils.rb 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/lib/webrick/httputils.rb 2008-08-04 02:21:05.000000000 -0300 @@ -23,16 +23,8 @@ ret = path.dup ret.gsub!(%r{/+}o, '/') # // => / - while ret.sub!(%r{/\.(/|\Z)}o, '/'); end # /. => / - begin # /foo/.. => /foo - match = ret.sub!(%r{/([^/]+)/\.\.(/|\Z)}o){ - if $1 == ".." - raise "abnormal path `#{path}'" - else - "/" - end - } - end while match + while ret.sub!(%r'/\.(?:/|\Z)', '/'); end # /. => / + while ret.sub!(%r'/(?!\.\./)[^/]+/\.\.(?:/|\Z)', '/'); end # /foo/.. => /foo raise "abnormal path `#{path}'" if %r{/\.\.(/|\Z)} =~ ret ret @@ -154,8 +146,8 @@ module_function :parse_header def split_header_value(str) - str.scan(/((?:"(?:\\.|[^"])+?"|[^",]+)+) - (?:,\s*|\Z)/xn).collect{|v| v[0] } + str.scan(%r'\G((?:"(?:\\.|[^"])+?"|[^",]+)+) + (?:,\s*|\Z)'xn).flatten end module_function :split_header_value diff -Nru ruby1.8-1.8.7.22/lib/xmlrpc/client.rb ruby1.8-1.8.7.72/lib/xmlrpc/client.rb --- ruby1.8-1.8.7.22/lib/xmlrpc/client.rb 2008-04-15 14:11:48.000000000 -0300 +++ ruby1.8-1.8.7.72/lib/xmlrpc/client.rb 2008-07-16 14:07:44.000000000 -0300 @@ -268,7 +268,7 @@ = History - $Id: client.rb 16048 2008-04-15 17:11:48Z knu $ + $Id: client.rb 18091 2008-07-16 17:07:44Z shyouhei $ =end @@ -567,6 +567,7 @@ set_cookies = resp.get_fields("Set-Cookie") if set_cookies and !set_cookies.empty? + require 'webrick/cookie' @cookie = set_cookies.collect do |set_cookie| cookie = WEBrick::Cookie.parse_set_cookie(set_cookie) WEBrick::Cookie.new(cookie.name, cookie.value).to_s diff -Nru ruby1.8-1.8.7.22/marshal.c ruby1.8-1.8.7.72/marshal.c --- ruby1.8-1.8.7.22/marshal.c 2008-06-06 07:39:57.000000000 -0300 +++ ruby1.8-1.8.7.72/marshal.c 2008-07-03 08:14:50.000000000 -0300 @@ -2,8 +2,8 @@ marshal.c - - $Author: knu $ - $Date: 2008-06-06 19:39:57 +0900 (Fri, 06 Jun 2008) $ + $Author: shyouhei $ + $Date: 2008-07-03 20:14:50 +0900 (Thu, 03 Jul 2008) $ created at: Thu Apr 27 16:30:01 JST 1995 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -511,7 +511,7 @@ if (OBJ_TAINTED(obj)) arg->taint = Qtrue; st_add_direct(arg->data, obj, arg->data->num_entries); - if (rb_obj_respond_to(obj, s_mdump, Qtrue)) { + if (rb_respond_to(obj, s_mdump)) { volatile VALUE v; v = rb_funcall(obj, s_mdump, 0, 0); @@ -521,7 +521,7 @@ if (ivtbl) w_ivar(0, &c_arg); return; } - if (rb_obj_respond_to(obj, s_dump, Qtrue)) { + if (rb_respond_to(obj, s_dump)) { VALUE v; v = rb_funcall(obj, s_dump, 1, INT2NUM(limit)); @@ -664,7 +664,7 @@ { VALUE v; - if (!rb_obj_respond_to(obj, s_dump_data, Qtrue)) { + if (!rb_respond_to(obj, s_dump_data)) { rb_raise(rb_eTypeError, "no marshal_dump is defined for class %s", rb_obj_classname(obj)); @@ -765,12 +765,12 @@ arg.str = rb_str_buf_new(0); RBASIC(arg.str)->klass = 0; if (!NIL_P(port)) { - if (!rb_obj_respond_to(port, s_write, Qtrue)) { + if (!rb_respond_to(port, s_write)) { type_error: rb_raise(rb_eTypeError, "instance of IO needed"); } arg.dest = port; - if (rb_obj_respond_to(port, s_binmode, Qtrue)) { + if (rb_respond_to(port, s_binmode)) { rb_funcall2(port, s_binmode, 0, 0); reentrant_check(arg.str, s_dump_data); } @@ -1245,7 +1245,7 @@ VALUE klass = path2class(r_unique(arg)); VALUE data; - if (!rb_obj_respond_to(klass, s_load, Qtrue)) { + if (!rb_respond_to(klass, s_load)) { rb_raise(rb_eTypeError, "class %s needs to have method `_load'", rb_class2name(klass)); } @@ -1272,7 +1272,7 @@ rb_extend_object(v, m); } } - if (!rb_obj_respond_to(v, s_mload, Qtrue)) { + if (!rb_respond_to(v, s_mload)) { rb_raise(rb_eTypeError, "instance of %s needs to have method `marshal_load'", rb_class2name(klass)); } @@ -1299,7 +1299,7 @@ case TYPE_DATA: { VALUE klass = path2class(r_unique(arg)); - if (rb_obj_respond_to(klass, s_alloc, Qtrue)) { + if (rb_respond_to(klass, s_alloc)) { static int warn = Qtrue; if (warn) { rb_warn("define `allocate' instead of `_alloc'"); @@ -1315,7 +1315,7 @@ rb_raise(rb_eArgError, "dump format error"); } r_entry(v, arg); - if (!rb_obj_respond_to(v, s_load_data, Qtrue)) { + if (!rb_respond_to(v, s_load_data)) { rb_raise(rb_eTypeError, "class %s needs to have instance method `_load_data'", rb_class2name(klass)); @@ -1420,8 +1420,8 @@ arg.taint = OBJ_TAINTED(port); /* original taintedness */ port = v; } - else if (rb_obj_respond_to(port, s_getc, Qtrue) && rb_obj_respond_to(port, s_read, Qtrue)) { - if (rb_obj_respond_to(port, s_binmode, Qtrue)) { + else if (rb_respond_to(port, s_getc) && rb_respond_to(port, s_read)) { + if (rb_respond_to(port, s_binmode)) { rb_funcall2(port, s_binmode, 0, 0); } arg.taint = Qtrue; diff -Nru ruby1.8-1.8.7.22/math.c ruby1.8-1.8.7.72/math.c --- ruby1.8-1.8.7.22/math.c 2008-01-25 11:34:13.000000000 -0200 +++ ruby1.8-1.8.7.72/math.c 2008-07-02 06:26:29.000000000 -0300 @@ -2,8 +2,8 @@ math.c - - $Author: mame $ - $Date: 2008-01-25 22:34:13 +0900 (Fri, 25 Jan 2008) $ + $Author: shyouhei $ + $Date: 2008-07-02 18:26:29 +0900 (Wed, 02 Jul 2008) $ created at: Tue Jan 25 14:12:56 JST 1994 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -34,7 +34,7 @@ if (isnan(x)) { #if defined(EDOM) errno = EDOM; -#elif define(ERANGE) +#elif defined(ERANGE) errno = ERANGE; #endif continue; diff -Nru ruby1.8-1.8.7.22/node.h ruby1.8-1.8.7.72/node.h --- ruby1.8-1.8.7.22/node.h 2008-05-22 13:07:42.000000000 -0300 +++ ruby1.8-1.8.7.72/node.h 2008-07-07 03:17:24.000000000 -0300 @@ -2,8 +2,8 @@ node.h - - $Author: knu $ - $Date: 2008-05-23 01:07:42 +0900 (Fri, 23 May 2008) $ + $Author: shyouhei $ + $Date: 2008-07-07 15:17:24 +0900 (Mon, 07 Jul 2008) $ created at: Fri May 28 15:14:02 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -468,6 +468,19 @@ extern rb_thread_t rb_curr_thread; extern rb_thread_t rb_main_thread; +enum { + RAISED_EXCEPTION = 0x1000, + RAISED_STACKOVERFLOW = 0x2000, + RAISED_NOMEMORY = 0x4000, + RAISED_MASK = 0xf000 +}; +int rb_thread_set_raised(rb_thread_t th); +int rb_thread_reset_raised(rb_thread_t th); +#define rb_thread_raised_set(th, f) ((th)->flags |= (f)) +#define rb_thread_raised_reset(th, f) ((th)->flags &= ~(f)) +#define rb_thread_raised_p(th, f) (((th)->flags & (f)) != 0) +#define rb_thread_raised_clear(th) ((th)->flags = 0) + #if defined(__cplusplus) } /* extern "C" { */ #endif diff -Nru ruby1.8-1.8.7.22/numeric.c ruby1.8-1.8.7.72/numeric.c --- ruby1.8-1.8.7.22/numeric.c 2008-05-31 08:44:49.000000000 -0300 +++ ruby1.8-1.8.7.72/numeric.c 2008-08-04 01:36:00.000000000 -0300 @@ -2,8 +2,8 @@ numeric.c - - $Author: knu $ - $Date: 2008-05-31 20:44:49 +0900 (Sat, 31 May 2008) $ + $Author: shyouhei $ + $Date: 2008-08-04 13:36:00 +0900 (Mon, 04 Aug 2008) $ created at: Fri Aug 13 18:33:09 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -121,7 +121,9 @@ { if (CLASS_OF(x) == CLASS_OF(y)) return rb_assoc_new(y, x); - return rb_assoc_new(rb_Float(y), rb_Float(x)); + x = rb_Float(x); + y = rb_Float(y); + return rb_assoc_new(y, x); } static VALUE @@ -1598,11 +1600,21 @@ } static void -check_uint(num) +check_uint(num, sign) unsigned long num; + VALUE sign; { - if (num > UINT_MAX) { - rb_raise(rb_eRangeError, "integer %lu too big to convert to `unsigned int'", num); + static const unsigned long mask = ~(unsigned long)UINT_MAX; + + if (RTEST(sign)) { + /* minus */ + if ((num & mask) != mask || (num & ~mask) <= INT_MAX + 1UL) + rb_raise(rb_eRangeError, "integer %ld too small to convert to `unsigned int'", num); + } + else { + /* plus */ + if ((num & mask) != 0) + rb_raise(rb_eRangeError, "integer %lu too big to convert to `unsigned int'", num); } } @@ -1632,9 +1644,7 @@ { unsigned long num = rb_num2ulong(val); - if (RTEST(rb_funcall(INT2FIX(0), '<', 1, val))) { - check_uint(num); - } + check_uint(num, rb_funcall(val, '<', 1, INT2FIX(0))); return num; } @@ -1648,9 +1658,8 @@ return rb_num2uint(val); } num = FIX2ULONG(val); - if (FIX2LONG(val) > 0) { - check_uint(num); - } + + check_uint(num, rb_funcall(val, '<', 1, INT2FIX(0))); return num; } #else diff -Nru ruby1.8-1.8.7.22/object.c ruby1.8-1.8.7.72/object.c --- ruby1.8-1.8.7.22/object.c 2008-06-06 05:05:24.000000000 -0300 +++ ruby1.8-1.8.7.72/object.c 2008-07-03 08:14:50.000000000 -0300 @@ -2,8 +2,8 @@ object.c - - $Author: knu $ - $Date: 2008-06-06 17:05:24 +0900 (Fri, 06 Jun 2008) $ + $Author: shyouhei $ + $Date: 2008-07-03 20:14:50 +0900 (Thu, 03 Jul 2008) $ created at: Thu Jul 15 12:01:24 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -2205,7 +2205,7 @@ ID m; m = rb_intern(method); - if (!rb_obj_respond_to(val, m, Qtrue)) { + if (!rb_respond_to(val, m)) { if (raise) { rb_raise(rb_eTypeError, "can't convert %s into %s", NIL_P(val) ? "nil" : diff -Nru ruby1.8-1.8.7.22/parse.c ruby1.8-1.8.7.72/parse.c --- ruby1.8-1.8.7.22/parse.c 2008-06-20 06:30:12.000000000 -0300 +++ ruby1.8-1.8.7.72/parse.c 1969-12-31 21:00:00.000000000 -0300 @@ -1,11581 +0,0 @@ -/* A Bison parser, made by GNU Bison 2.3. */ - -/* Skeleton implementation for Bison's Yacc-like parsers in C - - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 - Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2, or (at your option) - any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, - Boston, MA 02110-1301, USA. */ - -/* As a special exception, you may create a larger work that contains - part or all of the Bison parser skeleton and distribute that work - under terms of your choice, so long as that work isn't itself a - parser generator using the skeleton or a modified version thereof - as a parser skeleton. Alternatively, if you modify or redistribute - the parser skeleton itself, you may (at your option) remove this - special exception, which will cause the skeleton and the resulting - Bison output files to be licensed under the GNU General Public - License without this special exception. - - This special exception was added by the Free Software Foundation in - version 2.2 of Bison. */ - -/* C LALR(1) parser skeleton written by Richard Stallman, by - simplifying the original so-called "semantic" parser. */ - -/* All symbols defined below should begin with yy or YY, to avoid - infringing on user name space. This should be done even for local - variables, as they might otherwise be expanded by user macros. - There are some unavoidable exceptions within include files to - define necessary library symbols; they are noted "INFRINGES ON - USER NAME SPACE" below. */ - -/* Identify Bison output. */ -#define YYBISON 1 - -/* Bison version. */ -#define YYBISON_VERSION "2.3" - -/* Skeleton name. */ -#define YYSKELETON_NAME "yacc.c" - -/* Pure parsers. */ -#define YYPURE 0 - -/* Using locations. */ -#define YYLSP_NEEDED 0 - - - -/* Tokens. */ -#ifndef YYTOKENTYPE -# define YYTOKENTYPE - /* Put the tokens into the symbol table, so that GDB and other debuggers - know about them. */ - enum yytokentype { - kCLASS = 258, - kMODULE = 259, - kDEF = 260, - kUNDEF = 261, - kBEGIN = 262, - kRESCUE = 263, - kENSURE = 264, - kEND = 265, - kIF = 266, - kUNLESS = 267, - kTHEN = 268, - kELSIF = 269, - kELSE = 270, - kCASE = 271, - kWHEN = 272, - kWHILE = 273, - kUNTIL = 274, - kFOR = 275, - kBREAK = 276, - kNEXT = 277, - kREDO = 278, - kRETRY = 279, - kIN = 280, - kDO = 281, - kDO_COND = 282, - kDO_BLOCK = 283, - kRETURN = 284, - kYIELD = 285, - kSUPER = 286, - kSELF = 287, - kNIL = 288, - kTRUE = 289, - kFALSE = 290, - kAND = 291, - kOR = 292, - kNOT = 293, - kIF_MOD = 294, - kUNLESS_MOD = 295, - kWHILE_MOD = 296, - kUNTIL_MOD = 297, - kRESCUE_MOD = 298, - kALIAS = 299, - kDEFINED = 300, - klBEGIN = 301, - klEND = 302, - k__LINE__ = 303, - k__FILE__ = 304, - tIDENTIFIER = 305, - tFID = 306, - tGVAR = 307, - tIVAR = 308, - tCONSTANT = 309, - tCVAR = 310, - tINTEGER = 311, - tFLOAT = 312, - tSTRING_CONTENT = 313, - tNTH_REF = 314, - tBACK_REF = 315, - tREGEXP_END = 316, - tUPLUS = 317, - tUMINUS = 318, - tPOW = 319, - tCMP = 320, - tEQ = 321, - tEQQ = 322, - tNEQ = 323, - tGEQ = 324, - tLEQ = 325, - tANDOP = 326, - tOROP = 327, - tMATCH = 328, - tNMATCH = 329, - tDOT2 = 330, - tDOT3 = 331, - tAREF = 332, - tASET = 333, - tLSHFT = 334, - tRSHFT = 335, - tCOLON2 = 336, - tCOLON3 = 337, - tOP_ASGN = 338, - tASSOC = 339, - tLPAREN = 340, - tLPAREN_ARG = 341, - tRPAREN = 342, - tLBRACK = 343, - tLBRACE = 344, - tLBRACE_ARG = 345, - tSTAR = 346, - tAMPER = 347, - tSYMBEG = 348, - tSTRING_BEG = 349, - tXSTRING_BEG = 350, - tREGEXP_BEG = 351, - tWORDS_BEG = 352, - tQWORDS_BEG = 353, - tSTRING_DBEG = 354, - tSTRING_DVAR = 355, - tSTRING_END = 356, - tLOWEST = 357, - tUMINUS_NUM = 358, - tLAST_TOKEN = 359 - }; -#endif -/* Tokens. */ -#define kCLASS 258 -#define kMODULE 259 -#define kDEF 260 -#define kUNDEF 261 -#define kBEGIN 262 -#define kRESCUE 263 -#define kENSURE 264 -#define kEND 265 -#define kIF 266 -#define kUNLESS 267 -#define kTHEN 268 -#define kELSIF 269 -#define kELSE 270 -#define kCASE 271 -#define kWHEN 272 -#define kWHILE 273 -#define kUNTIL 274 -#define kFOR 275 -#define kBREAK 276 -#define kNEXT 277 -#define kREDO 278 -#define kRETRY 279 -#define kIN 280 -#define kDO 281 -#define kDO_COND 282 -#define kDO_BLOCK 283 -#define kRETURN 284 -#define kYIELD 285 -#define kSUPER 286 -#define kSELF 287 -#define kNIL 288 -#define kTRUE 289 -#define kFALSE 290 -#define kAND 291 -#define kOR 292 -#define kNOT 293 -#define kIF_MOD 294 -#define kUNLESS_MOD 295 -#define kWHILE_MOD 296 -#define kUNTIL_MOD 297 -#define kRESCUE_MOD 298 -#define kALIAS 299 -#define kDEFINED 300 -#define klBEGIN 301 -#define klEND 302 -#define k__LINE__ 303 -#define k__FILE__ 304 -#define tIDENTIFIER 305 -#define tFID 306 -#define tGVAR 307 -#define tIVAR 308 -#define tCONSTANT 309 -#define tCVAR 310 -#define tINTEGER 311 -#define tFLOAT 312 -#define tSTRING_CONTENT 313 -#define tNTH_REF 314 -#define tBACK_REF 315 -#define tREGEXP_END 316 -#define tUPLUS 317 -#define tUMINUS 318 -#define tPOW 319 -#define tCMP 320 -#define tEQ 321 -#define tEQQ 322 -#define tNEQ 323 -#define tGEQ 324 -#define tLEQ 325 -#define tANDOP 326 -#define tOROP 327 -#define tMATCH 328 -#define tNMATCH 329 -#define tDOT2 330 -#define tDOT3 331 -#define tAREF 332 -#define tASET 333 -#define tLSHFT 334 -#define tRSHFT 335 -#define tCOLON2 336 -#define tCOLON3 337 -#define tOP_ASGN 338 -#define tASSOC 339 -#define tLPAREN 340 -#define tLPAREN_ARG 341 -#define tRPAREN 342 -#define tLBRACK 343 -#define tLBRACE 344 -#define tLBRACE_ARG 345 -#define tSTAR 346 -#define tAMPER 347 -#define tSYMBEG 348 -#define tSTRING_BEG 349 -#define tXSTRING_BEG 350 -#define tREGEXP_BEG 351 -#define tWORDS_BEG 352 -#define tQWORDS_BEG 353 -#define tSTRING_DBEG 354 -#define tSTRING_DVAR 355 -#define tSTRING_END 356 -#define tLOWEST 357 -#define tUMINUS_NUM 358 -#define tLAST_TOKEN 359 - - - - -/* Copy the first part of user declarations. */ -#line 13 "parse.y" - - -#define YYDEBUG 1 -#define YYERROR_VERBOSE 1 -#ifndef YYSTACK_USE_ALLOCA -#define YYSTACK_USE_ALLOCA 0 -#endif - -#include "ruby.h" -#include "env.h" -#include "intern.h" -#include "node.h" -#include "st.h" -#include -#include -#include - -#define YYMALLOC rb_parser_malloc -#define YYREALLOC rb_parser_realloc -#define YYCALLOC rb_parser_calloc -#define YYFREE rb_parser_free -#define malloc YYMALLOC -#define realloc YYREALLOC -#define calloc YYCALLOC -#define free YYFREE -static void *rb_parser_malloc _((size_t)); -static void *rb_parser_realloc _((void *, size_t)); -static void *rb_parser_calloc _((size_t, size_t)); -static void rb_parser_free _((void *)); - -#define yyparse ruby_yyparse -#define yylex ruby_yylex -#define yyerror ruby_yyerror -#define yylval ruby_yylval -#define yychar ruby_yychar -#define yydebug ruby_yydebug - -#define ID_SCOPE_SHIFT 3 -#define ID_SCOPE_MASK 0x07 -#define ID_LOCAL 0x01 -#define ID_INSTANCE 0x02 -#define ID_GLOBAL 0x03 -#define ID_ATTRSET 0x04 -#define ID_CONST 0x05 -#define ID_CLASS 0x06 -#define ID_JUNK 0x07 -#define ID_INTERNAL ID_JUNK - -#define is_notop_id(id) ((id)>tLAST_TOKEN) -#define is_local_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_LOCAL) -#define is_global_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_GLOBAL) -#define is_instance_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_INSTANCE) -#define is_attrset_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_ATTRSET) -#define is_const_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_CONST) -#define is_class_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_CLASS) -#define is_junk_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_JUNK) - -#define is_asgn_or_id(id) ((is_notop_id(id)) && \ - (((id)&ID_SCOPE_MASK) == ID_GLOBAL || \ - ((id)&ID_SCOPE_MASK) == ID_INSTANCE || \ - ((id)&ID_SCOPE_MASK) == ID_CLASS)) - -NODE *ruby_eval_tree_begin = 0; -NODE *ruby_eval_tree = 0; - -char *ruby_sourcefile; /* current source file */ -int ruby_sourceline; /* current line no. */ - -static int yylex(); -static int yyerror(); - -static enum lex_state { - EXPR_BEG, /* ignore newline, +/- is a sign. */ - EXPR_END, /* newline significant, +/- is an operator. */ - EXPR_ARG, /* newline significant, +/- is an operator. */ - EXPR_CMDARG, /* newline significant, +/- is an operator. */ - EXPR_ENDARG, /* newline significant, +/- is an operator. */ - EXPR_MID, /* newline significant, +/- is an operator. */ - EXPR_FNAME, /* ignore newline, no reserved words. */ - EXPR_DOT, /* right after `.' or `::', no reserved words. */ - EXPR_CLASS, /* immediate after `class', no here document. */ -} lex_state; -static NODE *lex_strterm; - -#ifdef HAVE_LONG_LONG -typedef unsigned LONG_LONG stack_type; -#else -typedef unsigned long stack_type; -#endif - -#define BITSTACK_PUSH(stack, n) (stack = (stack<<1)|((n)&1)) -#define BITSTACK_POP(stack) (stack >>= 1) -#define BITSTACK_LEXPOP(stack) (stack = (stack >> 1) | (stack & 1)) -#define BITSTACK_SET_P(stack) (stack&1) - -static stack_type cond_stack = 0; -#define COND_PUSH(n) BITSTACK_PUSH(cond_stack, n) -#define COND_POP() BITSTACK_POP(cond_stack) -#define COND_LEXPOP() BITSTACK_LEXPOP(cond_stack) -#define COND_P() BITSTACK_SET_P(cond_stack) - -static stack_type cmdarg_stack = 0; -#define CMDARG_PUSH(n) BITSTACK_PUSH(cmdarg_stack, n) -#define CMDARG_POP() BITSTACK_POP(cmdarg_stack) -#define CMDARG_LEXPOP() BITSTACK_LEXPOP(cmdarg_stack) -#define CMDARG_P() BITSTACK_SET_P(cmdarg_stack) - -static int class_nest = 0; -static int in_single = 0; -static int in_def = 0; -static int compile_for_eval = 0; -static ID cur_mid = 0; -static int command_start = Qtrue; - -static NODE *cond(); -static NODE *logop(); -static int cond_negative(); - -static NODE *newline_node(); -static void fixpos(); - -static int value_expr0(); -static void void_expr0(); -static void void_stmts(); -static NODE *remove_begin(); -#define value_expr(node) value_expr0((node) = remove_begin(node)) -#define void_expr(node) void_expr0((node) = remove_begin(node)) - -static NODE *block_append(); -static NODE *list_append(); -static NODE *list_concat(); -static NODE *arg_concat(); -static NODE *arg_prepend(); -static NODE *literal_concat(); -static NODE *new_evstr(); -static NODE *evstr2dstr(); -static NODE *call_op(); -static int in_defined = 0; - -static NODE *negate_lit(); -static NODE *ret_args(); -static NODE *arg_blk_pass(); -static NODE *new_call(); -static NODE *new_fcall(); -static NODE *new_super(); -static NODE *new_yield(); - -static NODE *gettable(); -static NODE *assignable(); -static NODE *aryset(); -static NODE *attrset(); -static void rb_backref_error(); -static NODE *node_assign(); - -static NODE *match_gen(); -static void local_push(); -static void local_pop(); -static int local_append(); -static int local_cnt(); -static int local_id(); -static ID *local_tbl(); -static ID internal_id(); - -static struct RVarmap *dyna_push(); -static void dyna_pop(); -static int dyna_in_block(); -static NODE *dyna_init(); - -static void top_local_init(); -static void top_local_setup(); - -#define RE_OPTION_ONCE 0x80 - -#define NODE_STRTERM NODE_ZARRAY /* nothing to gc */ -#define NODE_HEREDOC NODE_ARRAY /* 1, 3 to gc */ -#define SIGN_EXTEND(x,n) (((1<<(n)-1)^((x)&~(~0<<(n))))-(1<<(n)-1)) -#define nd_func u1.id -#if SIZEOF_SHORT == 2 -#define nd_term(node) ((signed short)(node)->u2.id) -#else -#define nd_term(node) SIGN_EXTEND((node)->u2.id, CHAR_BIT*2) -#endif -#define nd_paren(node) (char)((node)->u2.id >> CHAR_BIT*2) -#define nd_nest u3.id - -#define NEW_BLOCK_VAR(b, v) NEW_NODE(NODE_BLOCK_PASS, 0, b, v) - -/* Older versions of Yacc set YYMAXDEPTH to a very low value by default (150, - for instance). This is too low for Ruby to parse some files, such as - date/format.rb, therefore bump the value up to at least Bison's default. */ -#ifdef OLD_YACC -#ifndef YYMAXDEPTH -#define YYMAXDEPTH 10000 -#endif -#endif - - - -/* Enabling traces. */ -#ifndef YYDEBUG -# define YYDEBUG 0 -#endif - -/* Enabling verbose error messages. */ -#ifdef YYERROR_VERBOSE -# undef YYERROR_VERBOSE -# define YYERROR_VERBOSE 1 -#else -# define YYERROR_VERBOSE 0 -#endif - -/* Enabling the token table. */ -#ifndef YYTOKEN_TABLE -# define YYTOKEN_TABLE 0 -#endif - -#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED -typedef union YYSTYPE -#line 211 "parse.y" -{ - NODE *node; - ID id; - int num; - struct RVarmap *vars; -} -/* Line 187 of yacc.c. */ -#line 509 "parse.c" - YYSTYPE; -# define yystype YYSTYPE /* obsolescent; will be withdrawn */ -# define YYSTYPE_IS_DECLARED 1 -# define YYSTYPE_IS_TRIVIAL 1 -#endif - - - -/* Copy the second part of user declarations. */ - - -/* Line 216 of yacc.c. */ -#line 522 "parse.c" - -#ifdef short -# undef short -#endif - -#ifdef YYTYPE_UINT8 -typedef YYTYPE_UINT8 yytype_uint8; -#else -typedef unsigned char yytype_uint8; -#endif - -#ifdef YYTYPE_INT8 -typedef YYTYPE_INT8 yytype_int8; -#elif (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -typedef signed char yytype_int8; -#else -typedef short int yytype_int8; -#endif - -#ifdef YYTYPE_UINT16 -typedef YYTYPE_UINT16 yytype_uint16; -#else -typedef unsigned short int yytype_uint16; -#endif - -#ifdef YYTYPE_INT16 -typedef YYTYPE_INT16 yytype_int16; -#else -typedef short int yytype_int16; -#endif - -#ifndef YYSIZE_T -# ifdef __SIZE_TYPE__ -# define YYSIZE_T __SIZE_TYPE__ -# elif defined size_t -# define YYSIZE_T size_t -# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -# include /* INFRINGES ON USER NAME SPACE */ -# define YYSIZE_T size_t -# else -# define YYSIZE_T unsigned int -# endif -#endif - -#define YYSIZE_MAXIMUM ((YYSIZE_T) -1) - -#ifndef YY_ -# if YYENABLE_NLS -# if ENABLE_NLS -# include /* INFRINGES ON USER NAME SPACE */ -# define YY_(msgid) dgettext ("bison-runtime", msgid) -# endif -# endif -# ifndef YY_ -# define YY_(msgid) msgid -# endif -#endif - -/* Suppress unused-variable warnings by "using" E. */ -#if ! defined lint || defined __GNUC__ -# define YYUSE(e) ((void) (e)) -#else -# define YYUSE(e) /* empty */ -#endif - -/* Identity function, used to suppress warnings about constant conditions. */ -#ifndef lint -# define YYID(n) (n) -#else -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -static int -YYID (int i) -#else -static int -YYID (i) - int i; -#endif -{ - return i; -} -#endif - -#if ! defined yyoverflow || YYERROR_VERBOSE - -/* The parser invokes alloca or malloc; define the necessary symbols. */ - -# ifdef YYSTACK_USE_ALLOCA -# if YYSTACK_USE_ALLOCA -# ifdef __GNUC__ -# define YYSTACK_ALLOC __builtin_alloca -# elif defined __BUILTIN_VA_ARG_INCR -# include /* INFRINGES ON USER NAME SPACE */ -# elif defined _AIX -# define YYSTACK_ALLOC __alloca -# elif defined _MSC_VER -# include /* INFRINGES ON USER NAME SPACE */ -# define alloca _alloca -# else -# define YYSTACK_ALLOC alloca -# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -# include /* INFRINGES ON USER NAME SPACE */ -# ifndef _STDLIB_H -# define _STDLIB_H 1 -# endif -# endif -# endif -# endif -# endif - -# ifdef YYSTACK_ALLOC - /* Pacify GCC's `empty if-body' warning. */ -# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0)) -# ifndef YYSTACK_ALLOC_MAXIMUM - /* The OS might guarantee only one guard page at the bottom of the stack, - and a page size can be as small as 4096 bytes. So we cannot safely - invoke alloca (N) if N exceeds 4096. Use a slightly smaller number - to allow for a few compiler-allocated temporary stack slots. */ -# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ -# endif -# else -# define YYSTACK_ALLOC YYMALLOC -# define YYSTACK_FREE YYFREE -# ifndef YYSTACK_ALLOC_MAXIMUM -# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM -# endif -# if (defined __cplusplus && ! defined _STDLIB_H \ - && ! ((defined YYMALLOC || defined malloc) \ - && (defined YYFREE || defined free))) -# include /* INFRINGES ON USER NAME SPACE */ -# ifndef _STDLIB_H -# define _STDLIB_H 1 -# endif -# endif -# ifndef YYMALLOC -# define YYMALLOC malloc -# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ -# endif -# endif -# ifndef YYFREE -# define YYFREE free -# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -void free (void *); /* INFRINGES ON USER NAME SPACE */ -# endif -# endif -# endif -#endif /* ! defined yyoverflow || YYERROR_VERBOSE */ - - -#if (! defined yyoverflow \ - && (! defined __cplusplus \ - || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) - -/* A type that is properly aligned for any stack member. */ -union yyalloc -{ - yytype_int16 yyss; - YYSTYPE yyvs; - }; - -/* The size of the maximum gap between one aligned stack and the next. */ -# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) - -/* The size of an array large to enough to hold all stacks, each with - N elements. */ -# define YYSTACK_BYTES(N) \ - ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ - + YYSTACK_GAP_MAXIMUM) - -/* Copy COUNT objects from FROM to TO. The source and destination do - not overlap. */ -# ifndef YYCOPY -# if defined __GNUC__ && 1 < __GNUC__ -# define YYCOPY(To, From, Count) \ - __builtin_memcpy (To, From, (Count) * sizeof (*(From))) -# else -# define YYCOPY(To, From, Count) \ - do \ - { \ - YYSIZE_T yyi; \ - for (yyi = 0; yyi < (Count); yyi++) \ - (To)[yyi] = (From)[yyi]; \ - } \ - while (YYID (0)) -# endif -# endif - -/* Relocate STACK from its old location to the new one. The - local variables YYSIZE and YYSTACKSIZE give the old and new number of - elements in the stack, and YYPTR gives the new location of the - stack. Advance YYPTR to a properly aligned location for the next - stack. */ -# define YYSTACK_RELOCATE(Stack) \ - do \ - { \ - YYSIZE_T yynewbytes; \ - YYCOPY (&yyptr->Stack, Stack, yysize); \ - Stack = &yyptr->Stack; \ - yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ - yyptr += yynewbytes / sizeof (*yyptr); \ - } \ - while (YYID (0)) - -#endif - -/* YYFINAL -- State number of the termination state. */ -#define YYFINAL 3 -/* YYLAST -- Last index in YYTABLE. */ -#define YYLAST 10042 - -/* YYNTOKENS -- Number of terminals. */ -#define YYNTOKENS 132 -/* YYNNTS -- Number of nonterminals. */ -#define YYNNTS 146 -/* YYNRULES -- Number of rules. */ -#define YYNRULES 515 -/* YYNRULES -- Number of states. */ -#define YYNSTATES 919 - -/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ -#define YYUNDEFTOK 2 -#define YYMAXUTOK 359 - -#define YYTRANSLATE(YYX) \ - ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) - -/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ -static const yytype_uint8 yytranslate[] = -{ - 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 130, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 129, 117, 2, 2, 2, 115, 110, 2, - 128, 125, 113, 111, 126, 112, 124, 114, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 105, 131, - 107, 103, 106, 104, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 122, 2, 123, 109, 2, 127, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 120, 108, 121, 118, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, - 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, - 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, - 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, - 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, - 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, - 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, - 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, - 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, - 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, - 95, 96, 97, 98, 99, 100, 101, 102, 116, 119 -}; - -#if YYDEBUG -/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in - YYRHS. */ -static const yytype_uint16 yyprhs[] = -{ - 0, 0, 3, 4, 7, 12, 15, 17, 19, 23, - 26, 27, 32, 36, 40, 44, 47, 51, 55, 59, - 63, 67, 68, 74, 79, 83, 87, 91, 98, 104, - 110, 116, 120, 124, 128, 132, 134, 136, 140, 144, - 147, 150, 152, 154, 156, 158, 161, 164, 167, 169, - 174, 179, 180, 181, 188, 191, 195, 200, 206, 211, - 217, 220, 223, 225, 229, 231, 235, 237, 240, 244, - 247, 250, 252, 254, 258, 261, 265, 267, 272, 276, - 280, 284, 288, 291, 293, 295, 300, 304, 308, 312, - 316, 319, 321, 323, 325, 328, 330, 334, 336, 338, - 340, 342, 344, 346, 348, 350, 352, 354, 355, 360, - 362, 364, 366, 368, 370, 372, 374, 376, 378, 380, - 382, 384, 386, 388, 390, 392, 394, 396, 398, 400, - 402, 404, 406, 408, 410, 412, 414, 416, 418, 420, - 422, 424, 426, 428, 430, 432, 434, 436, 438, 440, - 442, 444, 446, 448, 450, 452, 454, 456, 458, 460, - 462, 464, 466, 468, 470, 472, 474, 476, 478, 480, - 482, 484, 486, 488, 490, 492, 496, 502, 506, 513, - 519, 525, 531, 537, 542, 546, 550, 554, 558, 562, - 566, 570, 574, 578, 583, 588, 591, 594, 598, 602, - 606, 610, 614, 618, 622, 626, 630, 634, 638, 642, - 646, 649, 652, 656, 660, 664, 668, 669, 674, 680, - 682, 684, 686, 689, 692, 698, 701, 705, 709, 714, - 719, 726, 728, 730, 732, 735, 741, 744, 750, 755, - 763, 767, 769, 774, 778, 784, 792, 795, 801, 806, - 813, 821, 831, 835, 837, 838, 841, 843, 844, 848, - 849, 854, 857, 860, 862, 864, 868, 872, 877, 880, - 882, 884, 886, 888, 890, 892, 894, 896, 898, 899, - 904, 905, 911, 915, 919, 922, 927, 931, 935, 937, - 942, 946, 948, 949, 956, 959, 961, 964, 971, 978, - 979, 980, 988, 989, 990, 998, 1004, 1009, 1015, 1016, - 1017, 1027, 1028, 1035, 1036, 1037, 1046, 1047, 1053, 1054, - 1061, 1062, 1063, 1073, 1075, 1077, 1079, 1081, 1083, 1085, - 1087, 1089, 1092, 1094, 1096, 1098, 1100, 1106, 1108, 1111, - 1113, 1115, 1117, 1121, 1123, 1126, 1131, 1139, 1146, 1151, - 1155, 1161, 1166, 1169, 1171, 1174, 1176, 1179, 1181, 1185, - 1186, 1187, 1194, 1197, 1202, 1207, 1210, 1215, 1220, 1224, - 1227, 1229, 1230, 1231, 1238, 1239, 1240, 1247, 1253, 1255, - 1260, 1263, 1265, 1267, 1274, 1276, 1278, 1280, 1282, 1285, - 1287, 1290, 1292, 1294, 1296, 1298, 1300, 1302, 1305, 1309, - 1313, 1317, 1321, 1325, 1326, 1330, 1332, 1335, 1339, 1343, - 1344, 1348, 1349, 1352, 1353, 1356, 1358, 1359, 1363, 1364, - 1369, 1371, 1373, 1375, 1377, 1380, 1382, 1384, 1386, 1388, - 1392, 1394, 1396, 1399, 1402, 1404, 1406, 1408, 1410, 1412, - 1414, 1416, 1418, 1420, 1422, 1424, 1426, 1428, 1430, 1432, - 1434, 1435, 1440, 1443, 1448, 1451, 1458, 1463, 1468, 1471, - 1476, 1479, 1482, 1484, 1485, 1487, 1489, 1491, 1493, 1495, - 1497, 1501, 1505, 1507, 1511, 1513, 1515, 1518, 1520, 1522, - 1524, 1527, 1530, 1532, 1534, 1535, 1541, 1543, 1546, 1549, - 1551, 1555, 1559, 1561, 1563, 1565, 1567, 1569, 1571, 1573, - 1575, 1577, 1579, 1581, 1583, 1584, 1586, 1587, 1589, 1590, - 1592, 1594, 1596, 1598, 1600, 1603 -}; - -/* YYRHS -- A `-1'-separated list of the rules' RHS. */ -static const yytype_int16 yyrhs[] = -{ - 133, 0, -1, -1, 134, 136, -1, 136, 221, 203, - 224, -1, 137, 272, -1, 277, -1, 138, -1, 137, - 276, 138, -1, 1, 138, -1, -1, 44, 160, 139, - 160, -1, 44, 52, 52, -1, 44, 52, 60, -1, - 44, 52, 59, -1, 6, 161, -1, 138, 39, 142, - -1, 138, 40, 142, -1, 138, 41, 142, -1, 138, - 42, 142, -1, 138, 43, 138, -1, -1, 46, 140, - 120, 136, 121, -1, 47, 120, 136, 121, -1, 155, - 103, 143, -1, 149, 103, 143, -1, 248, 83, 143, - -1, 199, 122, 168, 123, 83, 143, -1, 199, 124, - 50, 83, 143, -1, 199, 124, 54, 83, 143, -1, - 199, 81, 50, 83, 143, -1, 249, 83, 143, -1, - 155, 103, 181, -1, 149, 103, 167, -1, 149, 103, - 181, -1, 141, -1, 143, -1, 141, 36, 141, -1, - 141, 37, 141, -1, 38, 141, -1, 117, 143, -1, - 165, -1, 141, -1, 148, -1, 144, -1, 29, 171, - -1, 21, 171, -1, 22, 171, -1, 211, -1, 211, - 124, 269, 173, -1, 211, 81, 269, 173, -1, -1, - -1, 90, 146, 207, 147, 136, 121, -1, 268, 173, - -1, 268, 173, 145, -1, 199, 124, 269, 173, -1, - 199, 124, 269, 173, 145, -1, 199, 81, 269, 173, - -1, 199, 81, 269, 173, 145, -1, 31, 173, -1, - 30, 173, -1, 151, -1, 85, 150, 125, -1, 151, - -1, 85, 150, 125, -1, 153, -1, 153, 152, -1, - 153, 91, 154, -1, 153, 91, -1, 91, 154, -1, - 91, -1, 154, -1, 85, 150, 125, -1, 152, 126, - -1, 153, 152, 126, -1, 246, -1, 199, 122, 168, - 123, -1, 199, 124, 50, -1, 199, 81, 50, -1, - 199, 124, 54, -1, 199, 81, 54, -1, 82, 54, - -1, 249, -1, 246, -1, 199, 122, 168, 123, -1, - 199, 124, 50, -1, 199, 81, 50, -1, 199, 124, - 54, -1, 199, 81, 54, -1, 82, 54, -1, 249, - -1, 50, -1, 54, -1, 82, 156, -1, 156, -1, - 199, 81, 156, -1, 50, -1, 54, -1, 51, -1, - 163, -1, 164, -1, 158, -1, 242, -1, 159, -1, - 244, -1, 160, -1, -1, 161, 126, 162, 160, -1, - 108, -1, 109, -1, 110, -1, 65, -1, 66, -1, - 67, -1, 73, -1, 106, -1, 69, -1, 107, -1, - 70, -1, 79, -1, 80, -1, 111, -1, 112, -1, - 113, -1, 91, -1, 114, -1, 115, -1, 64, -1, - 118, -1, 62, -1, 63, -1, 77, -1, 78, -1, - 127, -1, 48, -1, 49, -1, 46, -1, 47, -1, - 44, -1, 36, -1, 7, -1, 21, -1, 16, -1, - 3, -1, 5, -1, 45, -1, 26, -1, 15, -1, - 14, -1, 10, -1, 9, -1, 35, -1, 20, -1, - 25, -1, 4, -1, 22, -1, 33, -1, 38, -1, - 37, -1, 23, -1, 8, -1, 24, -1, 29, -1, - 32, -1, 31, -1, 13, -1, 34, -1, 6, -1, - 17, -1, 30, -1, 11, -1, 12, -1, 18, -1, - 19, -1, 155, 103, 165, -1, 155, 103, 165, 43, - 165, -1, 248, 83, 165, -1, 199, 122, 168, 123, - 83, 165, -1, 199, 124, 50, 83, 165, -1, 199, - 124, 54, 83, 165, -1, 199, 81, 50, 83, 165, - -1, 199, 81, 54, 83, 165, -1, 82, 54, 83, - 165, -1, 249, 83, 165, -1, 165, 75, 165, -1, - 165, 76, 165, -1, 165, 111, 165, -1, 165, 112, - 165, -1, 165, 113, 165, -1, 165, 114, 165, -1, - 165, 115, 165, -1, 165, 64, 165, -1, 116, 56, - 64, 165, -1, 116, 57, 64, 165, -1, 62, 165, - -1, 63, 165, -1, 165, 108, 165, -1, 165, 109, - 165, -1, 165, 110, 165, -1, 165, 65, 165, -1, - 165, 106, 165, -1, 165, 69, 165, -1, 165, 107, - 165, -1, 165, 70, 165, -1, 165, 66, 165, -1, - 165, 67, 165, -1, 165, 68, 165, -1, 165, 73, - 165, -1, 165, 74, 165, -1, 117, 165, -1, 118, - 165, -1, 165, 79, 165, -1, 165, 80, 165, -1, - 165, 71, 165, -1, 165, 72, 165, -1, -1, 45, - 273, 166, 165, -1, 165, 104, 165, 105, 165, -1, - 182, -1, 165, -1, 277, -1, 148, 273, -1, 180, - 274, -1, 180, 126, 91, 165, 273, -1, 266, 274, - -1, 91, 165, 273, -1, 128, 277, 125, -1, 128, - 171, 273, 125, -1, 128, 211, 273, 125, -1, 128, - 180, 126, 211, 273, 125, -1, 277, -1, 169, -1, - 148, -1, 180, 179, -1, 180, 126, 91, 167, 179, - -1, 266, 179, -1, 266, 126, 91, 167, 179, -1, - 180, 126, 266, 179, -1, 180, 126, 266, 126, 91, - 165, 179, -1, 91, 167, 179, -1, 178, -1, 167, - 126, 180, 179, -1, 167, 126, 178, -1, 167, 126, - 91, 167, 179, -1, 167, 126, 180, 126, 91, 167, - 179, -1, 266, 179, -1, 266, 126, 91, 167, 179, - -1, 167, 126, 266, 179, -1, 167, 126, 180, 126, - 266, 179, -1, 167, 126, 266, 126, 91, 167, 179, - -1, 167, 126, 180, 126, 266, 126, 91, 167, 179, - -1, 91, 167, 179, -1, 178, -1, -1, 174, 175, - -1, 171, -1, -1, 86, 176, 125, -1, -1, 86, - 172, 177, 125, -1, 92, 167, -1, 126, 178, -1, - 277, -1, 167, -1, 180, 126, 167, -1, 180, 126, - 167, -1, 180, 126, 91, 167, -1, 91, 167, -1, - 225, -1, 226, -1, 229, -1, 230, -1, 231, -1, - 234, -1, 247, -1, 249, -1, 51, -1, -1, 7, - 183, 135, 10, -1, -1, 86, 141, 184, 273, 125, - -1, 85, 136, 125, -1, 199, 81, 54, -1, 82, - 54, -1, 199, 122, 168, 123, -1, 88, 168, 123, - -1, 89, 265, 121, -1, 29, -1, 30, 128, 171, - 125, -1, 30, 128, 125, -1, 30, -1, -1, 45, - 273, 128, 185, 141, 125, -1, 268, 213, -1, 212, - -1, 212, 213, -1, 11, 142, 200, 136, 202, 10, - -1, 12, 142, 200, 136, 203, 10, -1, -1, -1, - 18, 186, 142, 201, 187, 136, 10, -1, -1, -1, - 19, 188, 142, 201, 189, 136, 10, -1, 16, 142, - 272, 218, 10, -1, 16, 272, 218, 10, -1, 16, - 272, 15, 136, 10, -1, -1, -1, 20, 204, 25, - 190, 142, 201, 191, 136, 10, -1, -1, 3, 157, - 250, 192, 135, 10, -1, -1, -1, 3, 79, 141, - 193, 275, 194, 135, 10, -1, -1, 4, 157, 195, - 135, 10, -1, -1, 5, 158, 196, 252, 135, 10, - -1, -1, -1, 5, 263, 271, 197, 158, 198, 252, - 135, 10, -1, 21, -1, 22, -1, 23, -1, 24, - -1, 182, -1, 275, -1, 105, -1, 13, -1, 275, - 13, -1, 275, -1, 105, -1, 27, -1, 203, -1, - 14, 142, 200, 136, 202, -1, 277, -1, 15, 136, - -1, 155, -1, 149, -1, 152, -1, 205, 126, 152, - -1, 205, -1, 205, 126, -1, 205, 126, 92, 155, - -1, 205, 126, 91, 155, 126, 92, 155, -1, 205, - 126, 91, 126, 92, 155, -1, 205, 126, 91, 155, - -1, 205, 126, 91, -1, 91, 155, 126, 92, 155, - -1, 91, 126, 92, 155, -1, 91, 155, -1, 91, - -1, 92, 155, -1, 277, -1, 108, 108, -1, 72, - -1, 108, 206, 108, -1, -1, -1, 28, 209, 207, - 210, 136, 10, -1, 148, 208, -1, 211, 124, 269, - 170, -1, 211, 81, 269, 170, -1, 268, 169, -1, - 199, 124, 269, 170, -1, 199, 81, 269, 169, -1, - 199, 81, 270, -1, 31, 169, -1, 31, -1, -1, - -1, 120, 214, 207, 215, 136, 121, -1, -1, -1, - 26, 216, 207, 217, 136, 10, -1, 17, 219, 200, - 136, 220, -1, 180, -1, 180, 126, 91, 167, -1, - 91, 167, -1, 203, -1, 218, -1, 8, 222, 223, - 200, 136, 221, -1, 277, -1, 167, -1, 181, -1, - 277, -1, 84, 155, -1, 277, -1, 9, 136, -1, - 277, -1, 245, -1, 242, -1, 244, -1, 227, -1, - 228, -1, 227, 228, -1, 94, 236, 101, -1, 95, - 237, 101, -1, 96, 237, 61, -1, 97, 129, 101, - -1, 97, 232, 101, -1, -1, 232, 233, 129, -1, - 238, -1, 233, 238, -1, 98, 129, 101, -1, 98, - 235, 101, -1, -1, 235, 58, 129, -1, -1, 236, - 238, -1, -1, 237, 238, -1, 58, -1, -1, 100, - 239, 241, -1, -1, 99, 240, 136, 121, -1, 52, - -1, 53, -1, 55, -1, 249, -1, 93, 243, -1, - 158, -1, 53, -1, 52, -1, 55, -1, 93, 237, - 101, -1, 56, -1, 57, -1, 116, 56, -1, 116, - 57, -1, 50, -1, 53, -1, 52, -1, 54, -1, - 55, -1, 33, -1, 32, -1, 34, -1, 35, -1, - 49, -1, 48, -1, 246, -1, 246, -1, 59, -1, - 60, -1, 275, -1, -1, 107, 251, 142, 275, -1, - 1, 275, -1, 128, 253, 273, 125, -1, 253, 275, - -1, 255, 126, 257, 126, 259, 262, -1, 255, 126, - 257, 262, -1, 255, 126, 259, 262, -1, 255, 262, - -1, 257, 126, 259, 262, -1, 257, 262, -1, 259, - 262, -1, 261, -1, -1, 54, -1, 53, -1, 52, - -1, 55, -1, 50, -1, 254, -1, 255, 126, 254, - -1, 50, 103, 167, -1, 256, -1, 257, 126, 256, - -1, 113, -1, 91, -1, 258, 50, -1, 258, -1, - 110, -1, 92, -1, 260, 50, -1, 126, 261, -1, - 277, -1, 247, -1, -1, 128, 264, 141, 273, 125, - -1, 277, -1, 266, 274, -1, 180, 274, -1, 267, - -1, 266, 126, 267, -1, 167, 84, 167, -1, 50, - -1, 54, -1, 51, -1, 50, -1, 54, -1, 51, - -1, 163, -1, 50, -1, 51, -1, 163, -1, 124, - -1, 81, -1, -1, 276, -1, -1, 130, -1, -1, - 130, -1, 126, -1, 131, -1, 130, -1, 275, -1, - 276, 131, -1, -1 -}; - -/* YYRLINE[YYN] -- source line where rule number YYN was defined. */ -static const yytype_uint16 yyrline[] = -{ - 0, 349, 349, 349, 374, 394, 401, 402, 406, 410, - 416, 416, 420, 424, 431, 436, 440, 449, 458, 470, - 482, 488, 487, 501, 509, 513, 519, 544, 560, 572, - 584, 596, 601, 605, 610, 615, 618, 619, 623, 627, - 631, 635, 638, 645, 646, 647, 651, 655, 661, 662, - 666, 673, 677, 672, 687, 692, 704, 709, 721, 726, - 738, 743, 750, 751, 757, 758, 764, 768, 772, 776, - 780, 784, 790, 791, 797, 801, 807, 811, 815, 819, - 823, 827, 833, 839, 846, 850, 854, 858, 862, 866, - 872, 878, 885, 889, 892, 896, 900, 906, 907, 908, - 909, 914, 921, 922, 925, 929, 932, 936, 936, 942, - 943, 944, 945, 946, 947, 948, 949, 950, 951, 952, - 953, 954, 955, 956, 957, 958, 959, 960, 961, 962, - 963, 964, 965, 966, 967, 970, 970, 970, 970, 971, - 971, 971, 971, 971, 971, 971, 972, 972, 972, 972, - 972, 972, 972, 973, 973, 973, 973, 973, 973, 974, - 974, 974, 974, 974, 974, 974, 975, 975, 975, 975, - 975, 976, 976, 976, 976, 979, 983, 987, 1012, 1028, - 1040, 1052, 1064, 1069, 1074, 1079, 1092, 1105, 1109, 1113, - 1117, 1121, 1125, 1129, 1133, 1137, 1146, 1150, 1154, 1158, - 1162, 1166, 1170, 1174, 1178, 1182, 1186, 1190, 1194, 1198, - 1202, 1206, 1210, 1214, 1218, 1222, 1226, 1226, 1231, 1236, - 1242, 1249, 1250, 1254, 1258, 1263, 1267, 1274, 1278, 1282, - 1286, 1292, 1293, 1296, 1300, 1304, 1309, 1314, 1319, 1324, - 1330, 1334, 1337, 1341, 1345, 1350, 1355, 1360, 1365, 1370, - 1375, 1380, 1385, 1389, 1392, 1392, 1404, 1405, 1405, 1410, - 1410, 1417, 1423, 1427, 1430, 1434, 1440, 1444, 1448, 1454, - 1455, 1456, 1457, 1458, 1459, 1460, 1461, 1462, 1467, 1466, - 1479, 1479, 1484, 1489, 1493, 1497, 1505, 1514, 1518, 1522, - 1526, 1530, 1534, 1534, 1539, 1545, 1546, 1555, 1568, 1581, - 1581, 1581, 1591, 1591, 1591, 1601, 1608, 1612, 1616, 1616, - 1616, 1624, 1623, 1640, 1645, 1639, 1662, 1661, 1678, 1677, - 1695, 1696, 1695, 1710, 1714, 1718, 1722, 1728, 1735, 1736, - 1737, 1738, 1741, 1742, 1743, 1746, 1747, 1756, 1757, 1763, - 1764, 1767, 1771, 1777, 1787, 1791, 1795, 1799, 1803, 1807, - 1811, 1815, 1819, 1823, 1827, 1833, 1834, 1839, 1844, 1852, - 1856, 1851, 1866, 1875, 1879, 1885, 1890, 1895, 1900, 1904, - 1908, 1915, 1919, 1914, 1927, 1931, 1926, 1940, 1947, 1948, - 1952, 1958, 1959, 1962, 1973, 1976, 1980, 1981, 1984, 1988, - 1991, 1999, 2002, 2003, 2007, 2010, 2023, 2024, 2030, 2036, - 2059, 2092, 2096, 2103, 2106, 2112, 2113, 2119, 2123, 2130, - 2133, 2140, 2143, 2150, 2153, 2159, 2161, 2160, 2172, 2171, - 2192, 2193, 2194, 2195, 2198, 2205, 2206, 2207, 2208, 2211, - 2245, 2246, 2247, 2251, 2257, 2258, 2259, 2260, 2261, 2262, - 2263, 2264, 2265, 2266, 2267, 2270, 2276, 2282, 2283, 2286, - 2291, 2290, 2298, 2301, 2307, 2313, 2317, 2321, 2325, 2329, - 2333, 2337, 2341, 2346, 2351, 2355, 2359, 2363, 2367, 2378, - 2379, 2385, 2395, 2400, 2406, 2407, 2410, 2421, 2432, 2433, - 2436, 2446, 2450, 2453, 2458, 2458, 2483, 2484, 2488, 2497, - 2498, 2504, 2510, 2511, 2512, 2515, 2516, 2517, 2518, 2521, - 2522, 2523, 2526, 2527, 2530, 2531, 2534, 2535, 2538, 2539, - 2540, 2543, 2544, 2547, 2548, 2551 -}; -#endif - -#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE -/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. - First, the terminals, then, starting at YYNTOKENS, nonterminals. */ -static const char *const yytname[] = -{ - "$end", "error", "$undefined", "kCLASS", "kMODULE", "kDEF", "kUNDEF", - "kBEGIN", "kRESCUE", "kENSURE", "kEND", "kIF", "kUNLESS", "kTHEN", - "kELSIF", "kELSE", "kCASE", "kWHEN", "kWHILE", "kUNTIL", "kFOR", - "kBREAK", "kNEXT", "kREDO", "kRETRY", "kIN", "kDO", "kDO_COND", - "kDO_BLOCK", "kRETURN", "kYIELD", "kSUPER", "kSELF", "kNIL", "kTRUE", - "kFALSE", "kAND", "kOR", "kNOT", "kIF_MOD", "kUNLESS_MOD", "kWHILE_MOD", - "kUNTIL_MOD", "kRESCUE_MOD", "kALIAS", "kDEFINED", "klBEGIN", "klEND", - "k__LINE__", "k__FILE__", "tIDENTIFIER", "tFID", "tGVAR", "tIVAR", - "tCONSTANT", "tCVAR", "tINTEGER", "tFLOAT", "tSTRING_CONTENT", - "tNTH_REF", "tBACK_REF", "tREGEXP_END", "tUPLUS", "tUMINUS", "tPOW", - "tCMP", "tEQ", "tEQQ", "tNEQ", "tGEQ", "tLEQ", "tANDOP", "tOROP", - "tMATCH", "tNMATCH", "tDOT2", "tDOT3", "tAREF", "tASET", "tLSHFT", - "tRSHFT", "tCOLON2", "tCOLON3", "tOP_ASGN", "tASSOC", "tLPAREN", - "tLPAREN_ARG", "tRPAREN", "tLBRACK", "tLBRACE", "tLBRACE_ARG", "tSTAR", - "tAMPER", "tSYMBEG", "tSTRING_BEG", "tXSTRING_BEG", "tREGEXP_BEG", - "tWORDS_BEG", "tQWORDS_BEG", "tSTRING_DBEG", "tSTRING_DVAR", - "tSTRING_END", "tLOWEST", "'='", "'?'", "':'", "'>'", "'<'", "'|'", - "'^'", "'&'", "'+'", "'-'", "'*'", "'/'", "'%'", "tUMINUS_NUM", "'!'", - "'~'", "tLAST_TOKEN", "'{'", "'}'", "'['", "']'", "'.'", "')'", "','", - "'`'", "'('", "' '", "'\\n'", "';'", "$accept", "program", "@1", - "bodystmt", "compstmt", "stmts", "stmt", "@2", "@3", "expr", - "expr_value", "command_call", "block_command", "cmd_brace_block", "@4", - "@5", "command", "mlhs", "mlhs_entry", "mlhs_basic", "mlhs_item", - "mlhs_head", "mlhs_node", "lhs", "cname", "cpath", "fname", "fsym", - "fitem", "undef_list", "@6", "op", "reswords", "arg", "@7", "arg_value", - "aref_args", "paren_args", "opt_paren_args", "call_args", "call_args2", - "command_args", "@8", "open_args", "@9", "@10", "block_arg", - "opt_block_arg", "args", "mrhs", "primary", "@11", "@12", "@13", "@14", - "@15", "@16", "@17", "@18", "@19", "@20", "@21", "@22", "@23", "@24", - "@25", "@26", "primary_value", "then", "do", "if_tail", "opt_else", - "for_var", "block_par", "block_var", "opt_block_var", "do_block", "@27", - "@28", "block_call", "method_call", "brace_block", "@29", "@30", "@31", - "@32", "case_body", "when_args", "cases", "opt_rescue", "exc_list", - "exc_var", "opt_ensure", "literal", "strings", "string", "string1", - "xstring", "regexp", "words", "word_list", "word", "qwords", - "qword_list", "string_contents", "xstring_contents", "string_content", - "@33", "@34", "string_dvar", "symbol", "sym", "dsym", "numeric", - "variable", "var_ref", "var_lhs", "backref", "superclass", "@35", - "f_arglist", "f_args", "f_norm_arg", "f_arg", "f_opt", "f_optarg", - "restarg_mark", "f_rest_arg", "blkarg_mark", "f_block_arg", - "opt_f_block_arg", "singleton", "@36", "assoc_list", "assocs", "assoc", - "operation", "operation2", "operation3", "dot_or_colon", "opt_terms", - "opt_nl", "trailer", "term", "terms", "none", 0 -}; -#endif - -# ifdef YYPRINT -/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to - token YYLEX-NUM. */ -static const yytype_uint16 yytoknum[] = -{ - 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, - 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, - 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, - 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, - 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, - 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, - 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, - 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, - 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, - 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, - 355, 356, 357, 61, 63, 58, 62, 60, 124, 94, - 38, 43, 45, 42, 47, 37, 358, 33, 126, 359, - 123, 125, 91, 93, 46, 41, 44, 96, 40, 32, - 10, 59 -}; -# endif - -/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ -static const yytype_uint16 yyr1[] = -{ - 0, 132, 134, 133, 135, 136, 137, 137, 137, 137, - 139, 138, 138, 138, 138, 138, 138, 138, 138, 138, - 138, 140, 138, 138, 138, 138, 138, 138, 138, 138, - 138, 138, 138, 138, 138, 138, 141, 141, 141, 141, - 141, 141, 142, 143, 143, 143, 143, 143, 144, 144, - 144, 146, 147, 145, 148, 148, 148, 148, 148, 148, - 148, 148, 149, 149, 150, 150, 151, 151, 151, 151, - 151, 151, 152, 152, 153, 153, 154, 154, 154, 154, - 154, 154, 154, 154, 155, 155, 155, 155, 155, 155, - 155, 155, 156, 156, 157, 157, 157, 158, 158, 158, - 158, 158, 159, 159, 160, 160, 161, 162, 161, 163, - 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, - 163, 163, 163, 163, 163, 163, 163, 163, 163, 163, - 163, 163, 163, 163, 163, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 165, 165, 165, 165, 165, - 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, - 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, - 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, - 165, 165, 165, 165, 165, 165, 166, 165, 165, 165, - 167, 168, 168, 168, 168, 168, 168, 169, 169, 169, - 169, 170, 170, 171, 171, 171, 171, 171, 171, 171, - 171, 171, 172, 172, 172, 172, 172, 172, 172, 172, - 172, 172, 172, 172, 174, 173, 175, 176, 175, 177, - 175, 178, 179, 179, 180, 180, 181, 181, 181, 182, - 182, 182, 182, 182, 182, 182, 182, 182, 183, 182, - 184, 182, 182, 182, 182, 182, 182, 182, 182, 182, - 182, 182, 185, 182, 182, 182, 182, 182, 182, 186, - 187, 182, 188, 189, 182, 182, 182, 182, 190, 191, - 182, 192, 182, 193, 194, 182, 195, 182, 196, 182, - 197, 198, 182, 182, 182, 182, 182, 199, 200, 200, - 200, 200, 201, 201, 201, 202, 202, 203, 203, 204, - 204, 205, 205, 206, 206, 206, 206, 206, 206, 206, - 206, 206, 206, 206, 206, 207, 207, 207, 207, 209, - 210, 208, 211, 211, 211, 212, 212, 212, 212, 212, - 212, 214, 215, 213, 216, 217, 213, 218, 219, 219, - 219, 220, 220, 221, 221, 222, 222, 222, 223, 223, - 224, 224, 225, 225, 225, 226, 227, 227, 228, 229, - 230, 231, 231, 232, 232, 233, 233, 234, 234, 235, - 235, 236, 236, 237, 237, 238, 239, 238, 240, 238, - 241, 241, 241, 241, 242, 243, 243, 243, 243, 244, - 245, 245, 245, 245, 246, 246, 246, 246, 246, 246, - 246, 246, 246, 246, 246, 247, 248, 249, 249, 250, - 251, 250, 250, 252, 252, 253, 253, 253, 253, 253, - 253, 253, 253, 253, 254, 254, 254, 254, 254, 255, - 255, 256, 257, 257, 258, 258, 259, 259, 260, 260, - 261, 262, 262, 263, 264, 263, 265, 265, 265, 266, - 266, 267, 268, 268, 268, 269, 269, 269, 269, 270, - 270, 270, 271, 271, 272, 272, 273, 273, 274, 274, - 274, 275, 275, 276, 276, 277 -}; - -/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ -static const yytype_uint8 yyr2[] = -{ - 0, 2, 0, 2, 4, 2, 1, 1, 3, 2, - 0, 4, 3, 3, 3, 2, 3, 3, 3, 3, - 3, 0, 5, 4, 3, 3, 3, 6, 5, 5, - 5, 3, 3, 3, 3, 1, 1, 3, 3, 2, - 2, 1, 1, 1, 1, 2, 2, 2, 1, 4, - 4, 0, 0, 6, 2, 3, 4, 5, 4, 5, - 2, 2, 1, 3, 1, 3, 1, 2, 3, 2, - 2, 1, 1, 3, 2, 3, 1, 4, 3, 3, - 3, 3, 2, 1, 1, 4, 3, 3, 3, 3, - 2, 1, 1, 1, 2, 1, 3, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 0, 4, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 3, 5, 3, 6, 5, - 5, 5, 5, 4, 3, 3, 3, 3, 3, 3, - 3, 3, 3, 4, 4, 2, 2, 3, 3, 3, - 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, - 2, 2, 3, 3, 3, 3, 0, 4, 5, 1, - 1, 1, 2, 2, 5, 2, 3, 3, 4, 4, - 6, 1, 1, 1, 2, 5, 2, 5, 4, 7, - 3, 1, 4, 3, 5, 7, 2, 5, 4, 6, - 7, 9, 3, 1, 0, 2, 1, 0, 3, 0, - 4, 2, 2, 1, 1, 3, 3, 4, 2, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 0, 4, - 0, 5, 3, 3, 2, 4, 3, 3, 1, 4, - 3, 1, 0, 6, 2, 1, 2, 6, 6, 0, - 0, 7, 0, 0, 7, 5, 4, 5, 0, 0, - 9, 0, 6, 0, 0, 8, 0, 5, 0, 6, - 0, 0, 9, 1, 1, 1, 1, 1, 1, 1, - 1, 2, 1, 1, 1, 1, 5, 1, 2, 1, - 1, 1, 3, 1, 2, 4, 7, 6, 4, 3, - 5, 4, 2, 1, 2, 1, 2, 1, 3, 0, - 0, 6, 2, 4, 4, 2, 4, 4, 3, 2, - 1, 0, 0, 6, 0, 0, 6, 5, 1, 4, - 2, 1, 1, 6, 1, 1, 1, 1, 2, 1, - 2, 1, 1, 1, 1, 1, 1, 2, 3, 3, - 3, 3, 3, 0, 3, 1, 2, 3, 3, 0, - 3, 0, 2, 0, 2, 1, 0, 3, 0, 4, - 1, 1, 1, 1, 2, 1, 1, 1, 1, 3, - 1, 1, 2, 2, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 0, 4, 2, 4, 2, 6, 4, 4, 2, 4, - 2, 2, 1, 0, 1, 1, 1, 1, 1, 1, - 3, 3, 1, 3, 1, 1, 2, 1, 1, 1, - 2, 2, 1, 1, 0, 5, 1, 2, 2, 1, - 3, 3, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 0, 1, 0, 1, 0, 1, - 1, 1, 1, 1, 2, 0 -}; - -/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state - STATE-NUM when YYTABLE doesn't specify something else to do. Zero - means the default is an error. */ -static const yytype_uint16 yydefact[] = -{ - 2, 0, 0, 1, 0, 0, 0, 0, 0, 278, - 0, 0, 504, 299, 302, 0, 323, 324, 325, 326, - 288, 291, 370, 440, 439, 441, 442, 0, 0, 506, - 21, 0, 444, 443, 434, 277, 436, 435, 437, 438, - 430, 431, 447, 448, 0, 0, 0, 0, 0, 515, - 515, 71, 413, 411, 413, 413, 403, 409, 0, 0, - 0, 3, 504, 7, 35, 36, 44, 43, 0, 62, - 0, 66, 72, 0, 41, 219, 0, 48, 295, 269, - 270, 395, 396, 271, 272, 273, 274, 393, 394, 392, - 445, 275, 0, 276, 254, 6, 9, 323, 324, 288, - 291, 370, 506, 92, 93, 0, 0, 0, 0, 95, - 0, 327, 0, 445, 276, 0, 316, 144, 155, 145, - 168, 141, 161, 151, 150, 171, 172, 166, 149, 148, - 143, 169, 173, 174, 153, 142, 156, 160, 162, 154, - 147, 163, 170, 165, 164, 157, 167, 152, 140, 159, - 158, 139, 146, 137, 138, 135, 136, 97, 99, 98, - 130, 131, 128, 112, 113, 114, 117, 119, 115, 132, - 133, 120, 121, 125, 116, 118, 109, 110, 111, 122, - 123, 124, 126, 127, 129, 134, 484, 318, 100, 101, - 483, 0, 164, 157, 167, 152, 135, 136, 97, 98, - 102, 104, 106, 15, 103, 105, 0, 0, 42, 0, - 0, 0, 445, 0, 276, 0, 512, 511, 504, 0, - 513, 505, 0, 0, 0, 340, 339, 0, 0, 445, - 276, 0, 0, 0, 233, 220, 264, 46, 241, 515, - 515, 489, 47, 45, 0, 61, 0, 515, 369, 60, - 39, 0, 10, 507, 216, 0, 0, 195, 0, 196, - 284, 0, 0, 0, 62, 280, 0, 506, 0, 508, - 508, 221, 508, 0, 508, 486, 0, 70, 0, 76, - 83, 427, 426, 428, 425, 0, 424, 0, 0, 0, - 0, 0, 0, 0, 432, 433, 40, 210, 211, 5, - 505, 0, 0, 0, 0, 0, 0, 0, 359, 362, - 0, 74, 0, 69, 67, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 515, 0, 0, 0, 374, 371, 296, - 397, 0, 0, 365, 54, 294, 0, 313, 92, 93, - 94, 432, 433, 0, 450, 311, 449, 0, 515, 0, - 0, 0, 463, 503, 502, 320, 107, 0, 515, 284, - 330, 329, 0, 328, 0, 0, 515, 0, 0, 0, - 0, 0, 0, 0, 0, 514, 0, 0, 284, 0, - 515, 0, 308, 515, 261, 0, 0, 234, 263, 0, - 236, 290, 0, 257, 256, 255, 233, 506, 515, 506, - 0, 12, 14, 13, 0, 292, 0, 0, 0, 0, - 0, 0, 0, 282, 63, 506, 506, 222, 286, 510, - 509, 223, 510, 225, 510, 488, 287, 487, 82, 0, - 515, 0, 415, 418, 416, 429, 414, 398, 412, 399, - 400, 401, 402, 0, 405, 407, 0, 408, 0, 0, - 8, 16, 17, 18, 19, 20, 37, 38, 515, 0, - 25, 33, 0, 34, 0, 68, 75, 24, 175, 264, - 32, 192, 200, 205, 206, 207, 202, 204, 214, 215, - 208, 209, 185, 186, 212, 213, 0, 201, 203, 197, - 198, 199, 187, 188, 189, 190, 191, 495, 500, 496, - 501, 254, 368, 0, 495, 497, 496, 498, 515, 495, - 496, 254, 254, 515, 515, 26, 177, 31, 184, 51, - 55, 0, 452, 0, 0, 92, 93, 96, 0, 0, - 515, 0, 506, 468, 466, 465, 464, 467, 475, 479, - 478, 474, 463, 0, 0, 469, 515, 472, 515, 477, - 515, 0, 462, 0, 0, 279, 515, 515, 384, 515, - 331, 175, 499, 283, 0, 495, 496, 515, 0, 0, - 0, 378, 0, 306, 334, 333, 300, 332, 303, 499, - 283, 0, 495, 496, 0, 0, 240, 491, 0, 265, - 262, 515, 0, 0, 490, 289, 0, 41, 0, 259, - 0, 253, 515, 0, 0, 0, 0, 0, 227, 11, - 0, 217, 0, 23, 183, 63, 0, 226, 0, 265, - 79, 81, 0, 495, 496, 0, 0, 404, 406, 410, - 193, 194, 357, 0, 360, 355, 268, 0, 73, 0, - 0, 0, 0, 367, 58, 285, 0, 0, 232, 366, - 56, 231, 364, 50, 363, 49, 375, 372, 515, 314, - 0, 0, 285, 317, 0, 0, 506, 0, 454, 0, - 458, 482, 0, 460, 476, 0, 461, 480, 321, 108, - 385, 386, 515, 387, 0, 515, 337, 0, 0, 335, - 0, 285, 0, 0, 0, 305, 307, 380, 0, 0, - 0, 0, 285, 0, 515, 0, 238, 515, 515, 0, - 0, 258, 0, 246, 228, 0, 506, 515, 515, 229, - 0, 22, 281, 506, 77, 0, 420, 421, 422, 417, - 423, 353, 0, 356, 341, 343, 0, 0, 0, 266, - 176, 218, 30, 181, 182, 59, 0, 28, 179, 29, - 180, 57, 0, 0, 52, 0, 451, 312, 485, 471, - 0, 319, 470, 515, 515, 481, 0, 473, 515, 463, - 0, 0, 389, 338, 0, 4, 391, 0, 297, 0, - 298, 0, 515, 0, 0, 309, 235, 0, 237, 252, - 0, 243, 515, 515, 260, 0, 0, 293, 224, 419, - 0, 0, 352, 0, 84, 91, 354, 344, 358, 0, - 267, 27, 178, 0, 0, 0, 0, 453, 0, 456, - 457, 459, 0, 388, 0, 390, 0, 379, 381, 382, - 377, 301, 304, 0, 515, 515, 0, 242, 0, 248, - 515, 230, 90, 0, 0, 0, 515, 0, 349, 0, - 342, 361, 376, 373, 0, 315, 515, 0, 515, 515, - 0, 239, 244, 0, 515, 0, 247, 351, 0, 87, - 89, 0, 86, 88, 0, 348, 345, 53, 455, 322, - 383, 336, 310, 515, 0, 249, 515, 350, 85, 0, - 0, 245, 0, 250, 347, 0, 515, 346, 251 -}; - -/* YYDEFGOTO[NTERM-NUM]. */ -static const yytype_int16 yydefgoto[] = -{ - -1, 1, 2, 377, 378, 62, 63, 424, 255, 64, - 209, 65, 66, 540, 678, 835, 67, 68, 263, 69, - 70, 71, 72, 210, 109, 110, 200, 201, 202, 203, - 574, 527, 189, 74, 426, 236, 268, 668, 669, 237, - 619, 245, 246, 415, 620, 730, 610, 407, 269, 483, - 75, 206, 435, 630, 222, 720, 223, 721, 604, 853, - 544, 541, 775, 370, 372, 573, 789, 258, 382, 596, - 708, 709, 228, 755, 756, 654, 309, 478, 757, 77, - 78, 355, 534, 773, 533, 772, 394, 592, 850, 577, - 702, 791, 795, 79, 80, 81, 82, 83, 84, 85, - 291, 463, 86, 293, 287, 285, 456, 646, 645, 749, - 87, 286, 88, 89, 212, 91, 213, 214, 365, 543, - 563, 564, 565, 566, 567, 568, 569, 570, 571, 785, - 690, 191, 371, 273, 270, 241, 115, 548, 522, 375, - 219, 254, 441, 383, 221, 95 -}; - -/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing - STATE-NUM. */ -#define YYPACT_NINF -639 -static const yytype_int16 yypact[] = -{ - -639, 149, 2672, -639, 5966, 8434, 8731, 4199, 5517, -639, - 7305, 7305, 4070, -639, -639, 8533, 6172, 6172, -639, -639, - 6172, 4832, 4935, -639, -639, -639, -639, 7305, 5392, -42, - -639, -9, -639, -639, 4317, 4420, -639, -639, 4523, -639, - -639, -639, -639, -639, 8129, 8129, 123, 3480, 7305, 7408, - 8129, 8830, 5267, -639, -639, -639, 94, 129, 70, 8232, - 8129, -639, -34, 795, 403, -639, -639, 185, 173, -639, - 158, 8632, -639, 183, 9858, 20, 206, 47, 58, -639, - -639, 199, -639, -639, -639, -639, -639, -639, -639, -639, - 136, -639, 240, 298, 69, -639, 795, -639, -639, -639, - 210, 229, -42, 112, 339, 7305, 108, 3611, 429, -639, - 75, -639, 211, -639, -639, 69, -639, -639, -639, -639, - -639, -639, -639, -639, -639, -639, -639, -639, -639, -639, - -639, -639, -639, -639, -639, -639, -639, -639, -639, -639, - -639, -639, -639, -639, 56, 98, 111, 228, -639, -639, - -639, -639, -639, -639, -639, 243, 250, 261, -639, 262, - -639, -639, -639, -639, -639, -639, -639, -639, -639, -639, - -639, -639, -639, -639, -639, -639, -639, -639, -639, -639, - -639, -639, -639, -639, -639, -639, -639, -639, -639, -639, - -639, 267, -639, -639, -639, -639, -639, -639, -639, -639, - -639, -639, -639, 244, -639, -639, 2908, 319, 403, 43, - 275, 340, 73, 309, 145, 43, -639, -639, -34, 236, - -639, 268, 7305, 7305, 358, -639, -639, 457, 427, 77, - 82, 8129, 8129, 8129, -639, 9858, 344, -639, -639, 331, - 353, -639, -639, -639, 5858, -639, 6275, 6172, -639, -639, - -639, 354, -639, -639, 338, 350, 3742, -639, 503, 417, - 399, 3480, 363, 366, 387, 403, 8129, -42, 372, 142, - 159, -639, 323, 383, 159, -639, 456, -639, 536, 545, - 571, -639, -639, -639, -639, 373, -639, 377, 450, 499, - 433, 475, 451, 83, 467, 495, -639, -639, -639, -639, - 3967, 7305, 7305, 7305, 7305, 5966, 7305, 7305, -639, -639, - 7511, -639, 3480, 8830, 438, 7511, 8129, 8129, 8129, 8129, - 8129, 8129, 8129, 8129, 8129, 8129, 8129, 8129, 8129, 8129, - 8129, 8129, 8129, 8129, 8129, 8129, 8129, 8129, 8129, 8129, - 8129, 8129, 8984, 7408, 9050, 9116, 9116, -639, -639, -639, - -639, 8232, 8232, -639, 479, -639, 338, 403, -639, 590, - -639, -639, -639, -34, -639, -639, -639, 9182, 7408, 9116, - 2908, 7305, 553, -639, -639, -639, -639, 570, 577, 154, - -639, -639, 3030, 573, 8129, 9248, 7408, 9314, 8129, 8129, - 3274, 572, 3864, 7614, 581, -639, 60, 60, 84, 9380, - 7408, 9446, -639, 466, -639, 8129, 6378, -639, -639, 6481, - -639, -639, 472, 6069, -639, -639, 185, -42, 478, 37, - 476, -639, -639, -639, 5517, -639, 8129, 3742, 494, 9248, - 9314, 8129, 496, -639, 505, -42, 891, -639, -639, 7717, - -639, -639, 8129, -639, 8129, -639, -639, -639, 590, 9512, - 7408, 9578, -639, -639, -639, -639, -639, -639, -639, -639, - -639, -639, -639, 127, -639, -639, 504, -639, 8129, 8129, - 795, -639, -639, -639, -639, -639, -639, -639, 51, 8129, - -639, 506, 516, -639, 512, -639, -639, -639, 2073, -639, - -639, 417, 1140, 1140, 1140, 1140, 865, 865, 9927, 2348, - 1140, 1140, 9875, 9875, 498, 498, 2757, 865, 865, 404, - 404, 611, 40, 40, 417, 417, 417, 1581, 5038, 2777, - 5141, 229, -639, 497, 437, -639, 490, -639, 4935, -639, - -639, 1277, 1277, 51, 51, -639, 9858, -639, 9858, -639, - -639, -34, -639, 7305, 2908, 370, 44, -639, 229, 526, - 229, 643, 95, 551, -639, -639, -639, -639, -639, -639, - -639, -639, 586, 2908, -34, -639, 535, -639, 544, 623, - 559, 629, -639, 5642, 5517, -639, 7820, 673, -639, 491, - -639, 2329, 4626, 4729, 574, 242, 292, 673, 691, 698, - 8129, 583, 43, -639, -639, -639, -639, -639, -639, 68, - 81, 592, 88, 89, 7305, 624, -639, -639, 8129, 344, - -639, 594, 8129, 344, -639, -639, 8129, 9774, 38, -639, - 596, -639, 601, 609, 6584, 9116, 9116, 617, -639, -639, - 7305, 9858, 615, -639, 9858, 430, 620, -639, 8129, -639, - 370, 44, 628, 135, 138, 3742, 651, -639, -639, -639, - 417, 417, -639, 2550, -639, -639, -639, 7923, -639, 8129, - 8129, 8232, 8129, -639, 479, 604, 8232, 8232, -639, -639, - 479, -639, -639, -639, -639, -639, -639, -639, 51, -639, - -34, 728, -639, -639, 627, 8129, -42, 743, -639, 586, - -639, -639, 269, -639, -639, 91, -639, -639, -639, -639, - 506, -639, 670, -639, 3377, 747, -639, 7305, 748, -639, - 8129, 304, 8129, 8129, 750, -639, -639, -639, 8026, 3152, - 3864, 3864, 90, 60, 466, 6687, -639, 466, 466, 6790, - 632, -639, 6893, -639, -639, 185, 37, 229, 229, -639, - 99, -639, -639, 891, 613, 641, -639, -639, -639, -639, - -639, 2233, 8929, -639, -639, 639, 658, 3864, 8129, 648, - 9858, 9858, -639, 9858, 9858, -639, 8232, -639, 9858, -639, - 9858, -639, 3864, 3742, -639, 2908, -639, -639, -639, -639, - 644, -639, -639, 649, 559, -639, 551, -639, 559, 553, - 8929, 43, -639, -639, 3864, -639, -639, 43, -639, 8129, - -639, 8129, 385, 766, 770, -639, -639, 8129, -639, -639, - 8129, -639, 655, 657, -639, 8129, 660, -639, -639, -639, - 732, 695, 663, 619, 545, 571, -639, 8335, -639, 780, - -639, -639, 9858, 781, 672, 3742, 784, -639, 269, -639, - -639, -639, 2908, -639, 2908, -639, 3030, -639, -639, -639, - -639, -639, -639, 3864, 9795, 466, 6996, -639, 7099, -639, - 466, -639, 590, 8929, 703, 9644, 7408, 9710, 5759, 8929, - -639, -639, -639, -639, 676, -639, 559, 791, 577, 491, - 794, -639, -639, 8129, 679, 8129, -639, -639, 8929, 370, - 44, 683, 379, 408, 716, 685, -639, -639, -639, -639, - -639, -639, -639, 466, 7202, -639, 466, -639, 613, 8929, - 721, -639, 8129, -639, -639, 8929, 466, -639, -639 -}; - -/* YYPGOTO[NTERM-NUM]. */ -static const yytype_int16 yypgoto[] = -{ - -639, -639, -639, -346, 511, -639, 17, -639, -639, 52, - 140, -37, -639, -483, -639, -639, 50, 799, -172, -6, - -66, -639, 21, 507, -41, 809, -1, -639, -21, -639, - -639, 9, -639, 1134, -639, 1619, -342, 18, -472, 35, - -639, 16, -639, -639, -639, -639, 3, 283, 100, -247, - 124, -639, -639, -639, -639, -639, -639, -639, -639, -639, - -639, -639, -639, -639, -639, -639, -639, -2, -203, -386, - -63, -495, -639, -639, -639, -448, -639, -639, -639, -220, - -639, 744, -639, -639, -639, -639, -355, -639, -639, -54, - -639, -639, -639, -639, -639, -639, 745, -639, -639, -639, - -639, -639, -639, -639, -639, 513, -252, -639, -639, -639, - 22, -639, 45, -639, 27, 820, 428, 265, -639, -639, - 41, 270, 150, -639, -638, 152, -639, -609, -639, -344, - -493, -639, -639, -639, 74, -361, 1821, -199, -639, -639, - -19, 110, 376, 59, 769, 1194 -}; - -/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If - positive, shift that token. If negative, reduce the rule which - number is the opposite. If zero, do what YYDEFACT says. - If YYTABLE_NINF, syntax error. */ -#define YYTABLE_NINF -516 -static const yytype_int16 yytable[] = -{ - 76, 523, 76, 112, 112, 314, 187, 252, 211, 211, - 211, 598, 390, 227, 211, 211, 188, 188, 211, 238, - 238, 96, 296, 238, 551, 211, 549, 419, 572, 90, - 204, 90, 113, 113, 113, 458, 588, 188, 249, 464, - 248, 264, 229, 299, 584, 76, 211, 211, 614, 278, - 204, 284, 242, 205, 787, 243, 380, 211, 601, 672, - 674, 188, 208, 208, 208, 360, 234, 234, 490, 278, - 234, 220, 277, 205, 90, 693, 363, 696, 279, 250, - 784, 614, 705, 788, 347, 676, 677, 594, 253, 432, - 240, 240, 714, -87, 240, 347, 216, 217, 279, 267, - 265, -327, -84, 211, 316, 76, -89, -91, 642, -90, - 354, 256, 353, -86, -88, -85, 239, 239, 625, 248, - 239, 220, 405, 652, 274, -283, 294, 295, 345, 111, - 111, 306, 307, 353, 90, 306, 307, -440, -492, 111, - 484, 466, -327, 521, -327, 528, 531, 532, 381, 3, - 272, 215, 218, 339, 340, 341, -446, 357, 358, 653, - -78, 626, 359, -80, 729, 595, -283, 253, -283, 366, - 550, 346, -496, 216, 217, 111, -84, 260, 348, -439, - -440, 765, 364, 559, 467, 452, 521, 771, 528, 348, - 216, 217, -441, -434, -79, 111, -495, 247, 681, 391, - 787, 560, 550, -76, 76, 216, 217, -81, -83, -496, - -82, 648, 356, 308, -78, -80, -77, 687, 572, -446, - 211, 211, -439, 290, 817, 253, 453, 454, 389, 876, - 774, 550, -492, 90, -434, -441, -434, 431, -78, -84, - -492, -80, 211, -78, 211, 211, -80, 238, -91, 238, - 238, 392, 550, 393, 76, 264, 647, -90, 292, 76, - -78, -78, -76, -80, -80, 672, 674, 93, 439, 93, - 114, 114, 440, 480, 208, 208, 310, 220, 487, 412, - 230, 414, 417, 90, 311, 442, 315, 342, 90, 440, - 839, 840, 367, 53, 234, 841, 234, 416, 76, 211, - 211, 211, 211, 76, 211, 211, 264, 848, 211, -442, - 76, 278, 93, 211, 535, 537, 280, 470, 240, 786, - 240, 240, 475, 351, -444, 712, 547, 90, 343, 701, - 344, -443, 90, 368, 485, 369, 280, 805, 244, 90, - 279, 211, -434, -437, 239, -86, 239, 418, 373, 211, - 211, 520, -442, 208, 208, 208, 208, 247, 476, 477, - 558, 559, 396, 397, 614, -493, 211, -444, 76, 211, - 376, 614, 93, 379, -443, 713, 520, 437, 384, 560, - 76, 352, 561, 898, 211, -434, -437, 799, 76, 719, - 76, 374, 388, 267, 520, -88, -499, 90, 211, 395, - 704, -91, 393, 629, 736, -495, 421, -85, 520, 90, - 482, 211, 398, 422, 423, 482, 621, 90, 267, 90, - -437, 385, 542, 552, -83, 76, 737, 738, 405, 836, - 92, 452, 92, 188, -496, 452, 267, 111, 520, 306, - 307, 471, 472, 473, 474, 572, 204, 849, 211, 444, - 267, -499, 402, 440, 90, 597, 597, 406, 520, -493, - -495, -437, 386, -437, 387, 265, 425, -493, 316, 205, - 427, 93, 453, 454, 455, 92, 453, 454, 457, 409, - 611, 316, 431, 329, 330, 361, 362, 622, 433, -496, - -499, 434, -499, 591, -499, 438, 877, 614, -495, -495, - 267, -495, -90, -495, 446, 707, 704, -495, 452, 73, - 448, 73, -64, 61, 336, 337, 338, 339, 340, 341, - 666, 93, 226, 410, 891, -82, 93, 623, -496, 627, - -496, 468, -496, 452, 461, 92, -496, 664, 399, 663, - -86, 211, 76, 614, 670, 636, 637, 673, 675, 453, - 454, 459, 465, 699, 73, -65, -73, 452, 262, 469, - 460, 76, 316, -78, 486, 93, 663, 288, 289, 539, - 93, 90, 698, 667, 453, 454, 462, 93, 280, 400, - 575, 401, 188, 188, 429, 576, 580, 754, 844, 393, - 90, 593, 605, -88, 846, 208, 204, 615, 453, 454, - 679, 628, 211, 553, 624, 554, 555, 556, 557, 337, - 338, 339, 340, 341, 73, 633, -80, 449, 262, 205, - 665, 635, 211, 688, 762, 386, -445, 430, 211, 767, - 769, -73, -264, 649, 92, 93, 553, 658, 554, 555, - 556, 557, 657, 76, 558, 559, 443, 93, 445, 682, - 447, 278, -276, 683, 685, 93, 208, 93, 450, 211, - 451, 689, 684, 560, 211, 211, 561, -445, 550, -445, - 692, -284, 90, 694, 735, 316, 482, 558, 559, 697, - 279, 562, 740, 680, 92, 695, 606, 766, 704, 92, - 329, 330, 93, -276, -285, -276, 560, 711, 611, 561, - 865, 715, 76, 746, 747, 211, 748, -85, 716, 718, - 42, 43, -284, 73, -284, 722, 232, 76, 76, 76, - 725, 731, 337, 338, 339, 340, 341, 732, 92, 831, - -77, 90, 811, 92, 734, -285, 741, -285, 777, 776, - 92, 866, 739, 867, 723, 742, 90, 90, 90, 823, - 823, 744, 778, 781, 790, 76, 794, 814, 798, 208, - 800, 870, 819, 73, 211, 827, 828, 428, 73, 837, - 76, 76, 262, 76, -265, 838, 851, 111, 824, 824, - 852, 856, 597, 858, 90, 861, 862, 863, 823, 864, - 871, 872, 76, 873, 875, 888, 780, 897, 92, 90, - 90, 899, 90, 813, 902, 904, 908, 73, 909, 93, - 92, 910, 73, 915, 225, 116, 901, 824, 92, 73, - 92, 90, 349, 262, 900, 278, 350, 190, 93, 812, - 842, 300, 686, 76, 301, 302, 303, 304, 305, 782, - 76, 783, 76, 0, 76, 0, 816, 797, 0, 0, - 0, 76, 0, 818, 279, 92, 0, 0, 0, 0, - 0, 823, 90, 0, 211, 0, 823, 823, 0, 90, - 0, 90, 0, 90, 520, 111, 111, 73, 0, 0, - 90, 0, 0, 0, 0, 0, 823, 0, 0, 73, - 824, 0, 0, 579, 726, 824, 824, 73, 0, 73, - 0, 587, 0, 589, 0, 733, 0, 823, 0, 0, - 93, 750, 0, 823, 111, 824, 267, 0, 280, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 316, - 884, 0, 0, 0, 73, 0, 824, 0, 632, 0, - 0, 0, 824, 0, 329, 330, 0, 0, 0, 0, - 0, 111, 0, 0, 0, 316, 317, 318, 319, 320, - 321, 322, 323, 324, 325, 326, 327, 328, 0, 93, - 329, 330, 92, 334, 335, 336, 337, 338, 339, 340, - 341, 0, 0, 0, 93, 93, 93, 111, 0, 0, - 0, 92, 111, 111, 0, 331, 0, 332, 333, 334, - 335, 336, 337, 338, 339, 340, 341, 806, 0, 0, - 808, 809, 111, 0, 0, 0, 825, 825, 0, 0, - 0, 253, 93, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 111, 0, 0, 0, 93, 93, 111, - 93, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 73, 0, 0, 0, 825, 0, 0, 0, 93, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 73, 0, 0, 92, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 280, 0, 0, 857, 859, 0, 0, 0, - 93, 0, 0, 0, 0, 0, 0, 93, 0, 93, - 0, 93, 0, 0, 0, 0, 0, 0, 93, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 825, 0, - 0, 0, 92, 825, 825, 0, 0, 881, 882, 0, - 0, 0, 0, 886, 0, 0, 0, 92, 92, 92, - 235, 235, 73, 825, 235, 0, 745, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 905, 0, 0, - 0, 0, 0, 0, 825, 0, 0, 0, 257, 259, - 825, 0, 0, 235, 235, 92, 911, 0, 0, 913, - 0, 0, 0, 297, 298, 0, 0, 0, 0, 918, - 92, 92, 0, 92, 316, -516, -516, -516, -516, 321, - 322, 73, 0, -516, -516, 793, 0, 0, 0, 329, - 330, 0, 92, 0, 0, 0, 73, 73, 73, 0, - 802, 803, 804, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 271, 275, 0, 332, 333, 334, 335, - 336, 337, 338, 339, 340, 341, 0, 0, 822, 826, - 0, 0, 0, 92, 73, 0, 0, 0, 829, 0, - 92, 0, 92, 0, 92, 0, 0, -515, 0, 73, - 73, 92, 73, 833, 834, -515, -515, -515, 0, 0, - -515, -515, -515, 0, -515, 0, 0, 843, 0, 0, - 0, 73, 0, 0, -515, 845, 0, 0, 0, 0, - 0, 0, 0, -515, -515, 0, -515, -515, -515, -515, - -515, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 73, 0, 0, 0, 874, 0, 0, 73, - 0, 73, 0, 73, 0, 878, 0, 879, -515, 0, - 73, 0, 0, 0, 880, 235, 235, 297, 0, 0, - 887, 0, 0, 0, 0, 895, 896, 0, 235, 0, - 235, 235, -515, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 907, 0, 0, -515, 0, - 436, -515, -515, 0, 0, 247, 0, -515, -515, 0, - 0, 0, 0, 0, 0, 0, 914, 0, 0, 0, - 0, 0, 917, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 408, 408, 0, 0, 0, 0, 0, - 0, 420, 0, 0, 235, 0, 0, 0, 0, 488, - 491, 492, 493, 494, 495, 496, 497, 498, 499, 500, - 501, 502, 503, 504, 505, 506, 507, 508, 509, 510, - 511, 512, 513, 514, 515, 516, 0, 235, 0, 0, - 0, 0, 0, 0, 0, 536, 538, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 235, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 581, 0, - 235, 0, 536, 538, 0, 0, 0, 235, 0, 0, - 0, 0, 0, 0, 235, 0, 0, 271, 0, 235, - 235, 0, 0, 235, 0, 0, 0, 617, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 631, 0, 271, 0, 0, 634, 0, 0, 0, 0, - 0, 0, 578, 235, 0, 0, 235, 0, 235, 0, - 271, -499, 0, 0, 235, 0, 0, 0, 0, -499, - -499, -499, 0, 0, 271, -499, -499, 408, -499, 0, - 0, 0, 650, 651, 0, 0, 0, -499, 0, 0, - 0, 0, 408, 235, 0, 0, 0, -499, -499, 0, - -499, -499, -499, -499, -499, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 271, -499, -499, -499, -499, -499, - -499, -499, -499, -499, -499, -499, -499, -499, 0, 0, - -499, -499, -499, 0, 661, 0, 0, 0, 0, 0, - 0, 0, 655, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, -87, -499, 0, -499, -499, -499, - -499, -499, -499, -499, -499, -499, -499, 0, 0, 0, - 0, -499, -499, -499, 0, -499, -499, -79, 0, 0, - 235, -499, -499, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 671, 0, 235, 671, 671, 655, 655, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 235, 0, 671, 0, 235, 0, 0, 0, - 235, 0, 0, 0, 0, 0, 0, 0, 235, 0, - 691, 0, 691, 0, 691, 0, 0, 0, 0, 0, - 703, 706, 743, 706, 0, 0, 0, 0, 0, 0, - 0, 706, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 235, 0, 760, 761, 763, 764, 0, 0, 0, - 768, 770, 0, 0, 0, 408, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 408, 0, 0, 235, - 0, 0, 0, 94, 0, 94, 0, 0, 0, 0, - 0, 94, 94, 94, 0, 0, 0, 94, 94, 0, - 0, 94, 0, 0, 763, 0, 768, 770, 94, 0, - 403, 404, 235, 0, 0, 0, 0, 0, 0, 235, - 0, 0, 0, 235, 0, 0, 235, 0, 94, 94, - 94, 0, 655, 0, 0, 0, 0, 0, 0, 0, - 94, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 235, 0, 0, 0, 792, 0, 0, 796, - 832, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 408, 0, - 0, 408, 408, 0, 0, 0, 94, 0, 94, 481, - 0, 671, 671, 832, 489, 235, 0, 0, 0, 0, - 0, 854, 0, 0, 235, 0, 0, 0, 0, 235, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 691, 691, 0, - 0, 0, 691, 0, 0, 0, 0, 0, 0, 0, - 235, 0, 235, 0, 0, 0, 706, 0, 0, 0, - 235, 0, 0, 0, 0, 0, 408, 408, 0, 0, - 0, 0, 489, 0, 0, 0, 0, 235, 0, 235, - 0, 0, 0, 0, 607, 609, 0, 94, 613, 0, - 0, 0, 618, 0, 0, 0, 0, 0, 235, 0, - 0, 0, 0, 94, 94, 0, 235, 0, 408, 408, - 0, 0, 0, 0, 408, 0, 0, 0, 639, 0, - 271, 613, 0, 639, 0, 94, 0, 94, 94, 0, - 691, 0, 578, 706, 0, 0, 0, 94, 408, 0, - 0, 0, 94, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 408, 656, 0, - 408, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 408, 0, 0, 0, 0, 0, 659, 0, 0, 0, - 0, 94, 94, 94, 94, 94, 94, 94, 94, 0, - 0, 94, 0, 94, 0, 0, 94, 316, 317, 318, - 319, 320, 321, 322, 323, 324, 325, 326, 327, 328, - 0, 0, 329, 330, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 94, 0, 0, 0, 0, 0, - 0, 0, 94, 94, 0, 0, 0, 331, 0, 332, - 333, 334, 335, 336, 337, 338, 339, 340, 341, 94, - 0, 94, 94, 0, 0, 700, 0, 0, 0, -220, - 0, 0, 0, 94, 0, 0, 0, 94, 0, 717, - 0, 94, 0, 94, 0, 0, 0, 0, 0, 0, - 0, 94, 0, 0, 0, 0, 0, 724, 0, 0, - 0, 727, 0, 0, 94, 728, 5, 6, 7, 0, - 9, 0, 0, 609, 10, 11, 0, 0, 94, 12, - 0, 13, 14, 15, 97, 98, 18, 19, 0, 0, - 0, 0, 99, 100, 101, 23, 24, 25, 26, 0, - 0, 94, 0, 0, 0, 0, 759, 0, 102, 0, - 0, 32, 33, 34, 35, 36, 37, 38, 39, 40, - 41, 0, 42, 43, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 779, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 820, 0, 0, 107, 48, - 0, 49, 50, 0, 0, 0, 52, 53, 54, 55, - 56, 57, 0, 0, 0, 0, 0, 639, 0, 0, - 0, 0, 0, 0, 613, 0, 0, 0, 0, 108, - 0, 613, 0, 0, 0, 0, 0, 0, 0, 821, - 0, 0, 0, 0, 94, 94, 0, 0, 0, 0, - 0, 0, 659, 0, 0, 0, 0, 830, 0, 0, - 0, 0, 0, 0, 94, 0, 0, 0, 0, 0, - 0, 0, 0, 316, 317, 318, 319, 320, 321, 322, - 323, 324, 325, 326, 327, 328, 0, 0, 329, 330, - 0, 0, 316, 317, 318, 319, 320, 321, 322, 323, - 847, 325, 326, 0, 0, 94, 0, 329, 330, 855, - 0, 0, 0, 331, 860, 332, 333, 334, 335, 336, - 337, 338, 339, 340, 341, 94, 0, 0, 0, 0, - 0, 94, 0, 0, 332, 333, 334, 335, 336, 337, - 338, 339, 340, 341, 0, 0, 94, 0, 0, 0, - 0, 0, 0, 0, 0, 609, 0, 613, 0, 0, - 0, 0, 94, 0, 0, 0, 0, 94, 94, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 903, 0, 906, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 613, 0, 94, 0, 0, 94, 0, - 0, 916, 0, 0, 0, 0, 0, 0, 0, 0, - 94, 94, 94, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 5, 6, 7, 0, 9, 0, 0, - 0, 10, 11, 0, 0, 0, 12, 0, 13, 14, - 15, 97, 98, 18, 19, 0, 0, 0, 94, 99, - 100, 101, 23, 24, 25, 26, 0, 94, 0, 0, - 0, 0, 0, 94, 94, 102, 94, 0, 32, 33, - 34, 35, 36, 37, 38, 39, 40, 41, 0, 42, - 43, 0, 0, 0, 0, 94, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 276, 0, 0, 312, 48, 0, 49, 50, - 0, 751, 752, 52, 53, 54, 55, 56, 57, 0, - 0, 0, 0, 0, 0, 0, 94, 0, 753, 0, - 0, 0, 0, 94, 0, 94, 108, 94, 0, 0, - 0, 0, -515, 4, 94, 5, 6, 7, 8, 9, - 0, 0, 0, 10, 11, 0, 0, 94, 12, 0, - 13, 14, 15, 16, 17, 18, 19, 0, 0, 0, - 0, 20, 21, 22, 23, 24, 25, 26, 0, 0, - 27, 0, 0, 0, 0, 0, 28, 29, 30, 31, - 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, - 0, 42, 43, 0, 44, 45, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 46, 0, 0, 47, 48, 0, - 49, 50, 0, 51, 0, 52, 53, 54, 55, 56, - 57, 0, 0, 0, 0, 0, 0, -283, 0, 0, - 0, 0, 0, 0, 0, -283, -283, -283, 58, 59, - 60, -283, -283, 0, -283, 0, 0, 0, 0, 0, - 0, 0, -515, -515, 0, 0, 0, 0, 0, 0, - 0, 0, 0, -283, -283, 0, -283, -283, -283, -283, - -283, 316, 317, 318, 319, 320, 321, 322, 323, 324, - 325, 326, 327, 328, 0, 0, 329, 330, 0, 0, - 0, -283, -283, -283, -283, -283, -283, -283, -283, -283, - -283, -283, -283, -283, 0, 0, -283, -283, -283, 0, - 662, 331, 660, 332, 333, 334, 335, 336, 337, 338, - 339, 340, 341, 0, 0, 0, 0, 0, 0, 0, - -89, -283, 0, -283, -283, -283, -283, -283, -283, -283, - -283, -283, -283, 0, 0, 0, 0, 0, -283, -283, - 0, -283, -283, -81, 0, 0, 0, -283, -283, 4, - 0, 5, 6, 7, 8, 9, -515, -515, -515, 10, - 11, 0, 0, -515, 12, 0, 13, 14, 15, 16, - 17, 18, 19, 0, 0, 0, 0, 20, 21, 22, - 23, 24, 25, 26, 0, 0, 27, 0, 0, 0, - 0, 0, 28, 29, 30, 31, 32, 33, 34, 35, - 36, 37, 38, 39, 40, 41, 0, 42, 43, 0, - 44, 45, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 46, 0, 0, 47, 48, 0, 49, 50, 0, 51, - 0, 52, 53, 54, 55, 56, 57, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 58, 59, 60, 0, 0, 0, - 0, 4, 0, 5, 6, 7, 8, 9, -515, -515, - -515, 10, 11, 0, -515, -515, 12, 0, 13, 14, - 15, 16, 17, 18, 19, 0, 0, 0, 0, 20, - 21, 22, 23, 24, 25, 26, 0, 0, 27, 0, - 0, 0, 0, 0, 28, 29, 30, 31, 32, 33, - 34, 35, 36, 37, 38, 39, 40, 41, 0, 42, - 43, 0, 44, 45, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 46, 0, 0, 47, 48, 0, 49, 50, - 0, 51, 0, 52, 53, 54, 55, 56, 57, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 58, 59, 60, 0, - 0, 0, 0, 4, 0, 5, 6, 7, 8, 9, - -515, -515, -515, 10, 11, 0, 0, -515, 12, -515, - 13, 14, 15, 16, 17, 18, 19, 0, 0, 0, - 0, 20, 21, 22, 23, 24, 25, 26, 0, 0, - 27, 0, 0, 0, 0, 0, 28, 29, 30, 31, - 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, - 0, 42, 43, 0, 44, 45, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 46, 0, 0, 47, 48, 0, - 49, 50, 0, 51, 0, 52, 53, 54, 55, 56, - 57, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 58, 59, - 60, 0, 0, 0, 0, 4, 0, 5, 6, 7, - 8, 9, -515, -515, -515, 10, 11, 0, 0, -515, - 12, 0, 13, 14, 15, 16, 17, 18, 19, 0, - 0, 0, 0, 20, 21, 22, 23, 24, 25, 26, - 0, 0, 27, 0, 0, 0, 0, 0, 28, 29, - 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, - 40, 41, 0, 42, 43, 0, 44, 45, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 46, 0, 0, 47, - 48, 0, 49, 50, 0, 51, 0, 52, 53, 54, - 55, 56, 57, 0, 0, 0, 0, 0, 4, 0, - 5, 6, 7, 8, 9, 0, -515, -515, 10, 11, - 58, 59, 60, 12, 0, 13, 14, 15, 16, 17, - 18, 19, 0, 0, -515, -515, 20, 21, 22, 23, - 24, 25, 26, 0, 0, 27, 0, 0, 0, 0, - 0, 28, 29, 30, 31, 32, 33, 34, 35, 36, - 37, 38, 39, 40, 41, 0, 42, 43, 0, 44, - 45, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 46, - 0, 0, 47, 48, 0, 49, 50, 0, 51, 0, - 52, 53, 54, 55, 56, 57, 0, 0, 0, 0, - 0, 4, 0, 5, 6, 7, 8, 9, 0, 0, - 0, 10, 11, 58, 59, 60, 12, 0, 13, 14, - 15, 16, 17, 18, 19, 0, 0, -515, -515, 20, - 21, 22, 23, 24, 25, 26, 0, 0, 27, 0, - 0, 0, 0, 0, 28, 29, 30, 31, 32, 33, - 34, 35, 36, 37, 38, 39, 40, 41, 0, 42, - 43, 0, 44, 45, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 46, 0, 0, 261, 48, 0, 49, 50, - 0, 51, 0, 52, 53, 54, 55, 56, 57, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 58, 59, 60, 0, - 0, 0, 0, 0, 0, -515, 0, 0, 0, 0, - -515, -515, 4, 0, 5, 6, 7, 8, 9, 0, - 0, 0, 10, 11, 0, 0, 0, 12, 0, 13, - 14, 15, 16, 17, 18, 19, 0, 0, 0, 0, - 20, 21, 22, 23, 24, 25, 26, 0, 0, 27, - 0, 0, 0, 0, 0, 28, 29, 30, 31, 32, - 33, 34, 35, 36, 37, 38, 39, 40, 41, 0, - 42, 43, 0, 44, 45, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 46, 0, 0, 47, 48, 0, 49, - 50, 0, 51, 0, 52, 53, 54, 55, 56, 57, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 58, 59, 60, - 0, 0, 0, 0, 0, 0, -515, 0, 0, 0, - 0, -515, -515, 4, 0, 5, 6, 7, 8, 9, - 0, 0, 0, 10, 11, 0, 0, 0, 12, 0, - 13, 14, 15, 16, 17, 18, 19, 0, 0, 0, - 0, 20, 21, 22, 23, 24, 25, 26, 0, 0, - 27, 0, 0, 0, 0, 0, 28, 29, 30, 31, - 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, - 0, 42, 43, 0, 44, 45, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 46, 0, 0, 47, 48, 0, - 49, 50, 0, 51, 0, 52, 53, 54, 55, 56, - 57, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 58, 59, - 60, 0, 0, -515, 0, 4, 0, 5, 6, 7, - 8, 9, -515, -515, -515, 10, 11, 0, 0, 0, - 12, 0, 13, 14, 15, 16, 17, 18, 19, 0, - 0, 0, 0, 20, 21, 22, 23, 24, 25, 26, - 0, 0, 27, 0, 0, 0, 0, 0, 28, 29, - 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, - 40, 41, 0, 42, 43, 0, 44, 45, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 46, 0, 0, 47, - 48, 0, 49, 50, 0, 51, 0, 52, 53, 54, - 55, 56, 57, 0, 0, 0, 0, 0, 0, 0, - 5, 6, 7, 8, 9, 0, 0, 0, 10, 11, - 58, 59, 60, 12, 0, 13, 14, 15, 16, 17, - 18, 19, 0, 0, -515, -515, 20, 21, 22, 23, - 24, 25, 26, 0, 0, 27, 0, 0, 0, 0, - 0, 28, 29, 30, 31, 32, 33, 34, 35, 36, - 37, 38, 39, 40, 41, 0, 42, 43, 0, 44, - 45, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 46, - 0, 0, 47, 48, 0, 49, 50, 0, 51, 0, - 52, 53, 54, 55, 56, 57, 0, 0, 0, 0, - 0, 0, 0, 5, 6, 7, 0, 9, 0, 0, - 0, 10, 11, 58, 59, 60, 12, 0, 13, 14, - 15, 16, 17, 18, 19, 0, 0, 0, 395, 20, - 21, 22, 23, 24, 25, 26, 0, 0, 27, 0, - 0, 0, 0, 0, 0, 29, 0, 0, 32, 33, - 34, 35, 36, 37, 38, 39, 40, 41, 0, 42, - 43, 0, 44, 45, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 207, 0, 0, 107, 48, 0, 49, 50, - 0, 0, 0, 52, 53, 54, 55, 56, 57, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 58, 59, 60, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 216, 217, 117, 118, 119, 120, 121, 122, 123, 124, - 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, - 135, 136, 137, 138, 139, 140, 0, 0, 141, 142, - 143, 144, 145, 146, 147, 148, 149, 150, 0, 0, - 0, 0, 0, 151, 152, 153, 154, 155, 156, 157, - 158, 36, 37, 159, 39, 0, 0, 0, 0, 0, - 0, 160, 161, 162, 163, 164, 165, 0, 166, 167, - 0, 0, 168, 0, 0, 0, 169, 170, 171, 172, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 173, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 174, 175, 176, 177, 178, - 179, 180, 181, 182, 183, 0, 0, 184, 0, 0, - -492, -492, -492, 0, -492, 0, 185, 186, -492, -492, - 0, 0, 0, -492, 0, -492, -492, -492, -492, -492, - -492, -492, 0, -492, 0, 0, -492, -492, -492, -492, - -492, -492, -492, 0, 0, 0, 0, 0, 0, 0, - 0, 0, -492, 0, 0, -492, -492, -492, -492, -492, - -492, -492, -492, -492, -492, 0, -492, -492, 0, -492, - -492, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, -492, - 0, 0, -492, -492, 0, -492, -492, 0, -492, -492, - -492, -492, -492, -492, -492, -492, 0, 0, 0, 0, - 0, 0, 0, -494, -494, -494, 0, -494, 0, 0, - 0, -494, -494, -492, -492, -492, -494, -492, -494, -494, - -494, -494, -494, -494, -494, -492, -494, 0, 0, -494, - -494, -494, -494, -494, -494, -494, 0, 0, 0, 0, - 0, 0, 0, 0, 0, -494, 0, 0, -494, -494, - -494, -494, -494, -494, -494, -494, -494, -494, 0, -494, - -494, 0, -494, -494, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, -494, 0, 0, -494, -494, 0, -494, -494, - 0, -494, -494, -494, -494, -494, -494, -494, -494, 0, - 0, 0, 0, 0, 0, 0, -493, -493, -493, 0, - -493, 0, 0, 0, -493, -493, -494, -494, -494, -493, - -494, -493, -493, -493, -493, -493, -493, -493, -494, -493, - 0, 0, -493, -493, -493, -493, -493, -493, -493, 0, - 0, 0, 0, 0, 0, 0, 0, 0, -493, 0, - 0, -493, -493, -493, -493, -493, -493, -493, -493, -493, - -493, 0, -493, -493, 0, -493, -493, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, -493, 0, 0, -493, -493, - 0, -493, -493, 0, -493, -493, -493, -493, -493, -493, - -493, -493, 0, 0, 0, 0, 0, 0, 0, -495, - -495, -495, 0, -495, 0, 0, 0, -495, -495, -493, - -493, -493, -495, -493, -495, -495, -495, -495, -495, -495, - -495, -493, 0, 0, 0, -495, -495, -495, -495, -495, - -495, -495, 0, 0, 0, 0, 0, 0, 0, 0, - 0, -495, 0, 0, -495, -495, -495, -495, -495, -495, - -495, -495, -495, -495, 0, -495, -495, 0, -495, -495, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, -495, 710, - 0, -495, -495, 0, -495, -495, 0, -495, -495, -495, - -495, -495, -495, -495, -495, 0, 0, 0, 0, -87, - 0, 0, -496, -496, -496, 0, -496, 0, 0, 0, - -496, -496, -495, -495, -495, -496, 0, -496, -496, -496, - -496, -496, -496, -496, -495, 0, 0, 0, -496, -496, - -496, -496, -496, -496, -496, 0, 0, 0, 0, 0, - 0, 0, 0, 0, -496, 0, 0, -496, -496, -496, - -496, -496, -496, -496, -496, -496, -496, 0, -496, -496, - 0, -496, -496, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, -496, 662, 0, -496, -496, 0, -496, -496, 0, - -496, -496, -496, -496, -496, -496, -496, -496, 0, 0, - 0, 0, -89, 0, 0, -254, -254, -254, 0, -254, - 0, 0, 0, -254, -254, -496, -496, -496, -254, 0, - -254, -254, -254, -254, -254, -254, -254, -496, 0, 0, - 0, -254, -254, -254, -254, -254, -254, -254, 0, 0, - 0, 0, 0, 0, 0, 0, 0, -254, 0, 0, - -254, -254, -254, -254, -254, -254, -254, -254, -254, -254, - 0, -254, -254, 0, -254, -254, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, -254, 0, 0, -254, -254, 0, - -254, -254, 0, -254, -254, -254, -254, -254, -254, -254, - -254, 0, 0, 0, 0, 0, 0, 0, -254, -254, - -254, 0, -254, 0, 0, 0, -254, -254, -254, -254, - -254, -254, 0, -254, -254, -254, -254, -254, -254, -254, - 244, 0, 0, 0, -254, -254, -254, -254, -254, -254, - -254, 0, 0, 0, 0, 0, 0, 0, 0, 0, - -254, 0, 0, -254, -254, -254, -254, -254, -254, -254, - -254, -254, -254, 0, -254, -254, 0, -254, -254, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, -254, 0, 0, - -254, -254, 0, -254, -254, 0, -254, -254, -254, -254, - -254, -254, -254, -254, 0, 0, 0, 0, 0, 0, - 0, -497, -497, -497, 0, -497, 0, 0, 0, -497, - -497, -254, -254, -254, -497, 0, -497, -497, -497, -497, - -497, -497, -497, 247, 0, 0, 0, -497, -497, -497, - -497, -497, -497, -497, 0, 0, 0, 0, 0, 0, - 0, 0, 0, -497, 0, 0, -497, -497, -497, -497, - -497, -497, -497, -497, -497, -497, 0, -497, -497, 0, - -497, -497, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - -497, 0, 0, -497, -497, 0, -497, -497, 0, -497, - -497, -497, -497, -497, -497, -497, -497, 0, 0, 0, - 0, 0, 0, 0, -498, -498, -498, 0, -498, 0, - 0, 0, -498, -498, -497, -497, -497, -498, 0, -498, - -498, -498, -498, -498, -498, -498, -497, 0, 0, 0, - -498, -498, -498, -498, -498, -498, -498, 0, 0, 0, - 0, 0, 0, 0, 0, 0, -498, 0, 0, -498, - -498, -498, -498, -498, -498, -498, -498, -498, -498, 0, - -498, -498, 0, -498, -498, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, -498, 0, 0, -498, -498, 0, -498, - -498, 0, -498, -498, -498, -498, -498, -498, -498, -498, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, -498, -498, -498, - 0, 0, 0, 0, 0, 0, 0, 0, 0, -498, - 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, - 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, - 137, 138, 139, 140, 0, 0, 141, 142, 143, 192, - 193, 194, 195, 148, 149, 150, 0, 0, 0, 0, - 0, 151, 152, 153, 154, 196, 197, 198, 158, 281, - 282, 199, 283, 0, 0, 0, 0, 0, 0, 160, - 161, 162, 163, 164, 165, 0, 166, 167, 0, 0, - 168, 0, 0, 0, 169, 170, 171, 172, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 173, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 174, 175, 176, 177, 178, 179, 180, - 181, 182, 183, 0, 0, 184, 0, 0, 0, 0, - 0, 0, 0, 0, 185, 117, 118, 119, 120, 121, - 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, - 132, 133, 134, 135, 136, 137, 138, 139, 140, 0, - 0, 141, 142, 143, 192, 193, 194, 195, 148, 149, - 150, 0, 0, 0, 0, 0, 151, 152, 153, 154, - 196, 197, 198, 158, 251, 0, 199, 0, 0, 0, - 0, 0, 0, 0, 160, 161, 162, 163, 164, 165, - 0, 166, 167, 0, 0, 168, 0, 0, 0, 169, - 170, 171, 172, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 173, 0, 52, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 174, 175, - 176, 177, 178, 179, 180, 181, 182, 183, 0, 0, - 184, 0, 0, 0, 0, 0, 0, 0, 0, 185, - 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, - 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, - 137, 138, 139, 140, 0, 0, 141, 142, 143, 192, - 193, 194, 195, 148, 149, 150, 0, 0, 0, 0, - 0, 151, 152, 153, 154, 196, 197, 198, 158, 0, - 0, 199, 0, 0, 0, 0, 0, 0, 0, 160, - 161, 162, 163, 164, 165, 0, 166, 167, 0, 0, - 168, 0, 0, 0, 169, 170, 171, 172, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 173, 0, - 52, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 174, 175, 176, 177, 178, 179, 180, - 181, 182, 183, 0, 0, 184, 0, 0, 0, 0, - 0, 0, 0, 0, 185, 117, 118, 119, 120, 121, - 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, - 132, 133, 134, 135, 136, 137, 138, 139, 140, 0, - 0, 141, 142, 143, 192, 193, 194, 195, 148, 149, - 150, 0, 0, 0, 0, 0, 151, 152, 153, 154, - 196, 197, 198, 158, 0, 0, 199, 0, 0, 0, - 0, 0, 0, 0, 160, 161, 162, 163, 164, 165, - 0, 166, 167, 0, 0, 168, 0, 0, 0, 169, - 170, 171, 172, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 173, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 174, 175, - 176, 177, 178, 179, 180, 181, 182, 183, 0, 0, - 184, 0, 5, 6, 7, 0, 9, 0, 0, 185, - 10, 11, 0, 0, 0, 12, 0, 13, 14, 15, - 97, 98, 18, 19, 0, 0, 0, 0, 99, 100, - 101, 23, 24, 25, 26, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 102, 0, 0, 32, 33, 34, - 35, 36, 37, 38, 39, 40, 41, 0, 42, 43, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 820, 0, 0, 107, 48, 0, 49, 50, 0, - 0, 0, 52, 53, 54, 55, 56, 57, 0, 0, - 0, 5, 6, 7, 0, 9, 0, 0, 0, 10, - 11, 0, 0, 0, 12, 108, 13, 14, 15, 97, - 98, 18, 19, 0, 0, 894, 0, 99, 21, 22, - 23, 24, 25, 26, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 29, 0, 0, 32, 33, 34, 35, - 36, 37, 38, 39, 40, 41, 0, 42, 43, 0, - 44, 45, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 207, 0, 0, 107, 48, 0, 49, 50, 0, 231, - 232, 52, 53, 54, 55, 56, 57, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, - 6, 7, 8, 9, 58, 233, 60, 10, 11, 0, - 0, 0, 12, 411, 13, 14, 15, 16, 17, 18, - 19, 0, 0, 0, 0, 20, 21, 22, 23, 24, - 25, 26, 0, 0, 27, 0, 0, 0, 0, 0, - 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, - 38, 39, 40, 41, 0, 42, 43, 0, 44, 45, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 46, 0, - 0, 47, 48, 0, 49, 50, 0, 51, 0, 52, - 53, 54, 55, 56, 57, 0, 0, 0, 0, 0, - 0, 0, 5, 6, 7, 0, 9, 0, 0, 0, - 10, 11, 58, 59, 60, 12, 0, 13, 14, 15, - 16, 17, 18, 19, 0, 0, 0, 0, 20, 21, - 22, 23, 24, 25, 26, 0, 0, 27, 0, 0, - 0, 0, 0, 0, 29, 0, 0, 32, 33, 34, - 35, 36, 37, 38, 39, 40, 41, 0, 42, 43, - 0, 44, 45, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 207, 0, 0, 107, 48, 0, 49, 50, 0, - 616, 232, 52, 53, 54, 55, 56, 57, 0, 0, - 0, 0, 0, 0, 0, 5, 6, 7, 0, 9, - 0, 0, 0, 10, 11, 58, 59, 60, 12, 0, - 13, 14, 15, 97, 98, 18, 19, 0, 0, 0, - 0, 99, 21, 22, 23, 24, 25, 26, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 29, 0, 0, - 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, - 0, 42, 43, 0, 44, 45, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 207, 0, 0, 107, 48, 0, - 49, 50, 0, 231, 232, 52, 53, 54, 55, 56, - 57, 0, 0, 0, 0, 0, 0, 0, 5, 6, - 7, 0, 9, 0, 0, 0, 10, 11, 58, 233, - 60, 12, 0, 13, 14, 15, 97, 98, 18, 19, - 0, 0, 0, 0, 99, 21, 22, 23, 24, 25, - 26, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 29, 0, 0, 32, 33, 34, 35, 36, 37, 38, - 39, 40, 41, 0, 42, 43, 0, 44, 45, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 207, 0, 0, - 107, 413, 0, 49, 50, 0, 231, 232, 52, 53, - 54, 55, 56, 57, 0, 0, 0, 0, 0, 0, - 0, 5, 6, 7, 0, 9, 0, 0, 0, 10, - 11, 58, 233, 60, 12, 0, 13, 14, 15, 97, - 98, 18, 19, 0, 0, 0, 0, 99, 100, 101, - 23, 24, 25, 26, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 29, 0, 0, 32, 33, 34, 35, - 36, 37, 38, 39, 40, 41, 0, 42, 43, 0, - 44, 45, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 207, 0, 0, 107, 48, 0, 49, 50, 0, 608, - 232, 52, 53, 54, 55, 56, 57, 0, 0, 0, - 0, 0, 0, 0, 5, 6, 7, 0, 9, 0, - 0, 0, 10, 11, 58, 233, 60, 12, 0, 13, - 14, 15, 97, 98, 18, 19, 0, 0, 0, 0, - 99, 100, 101, 23, 24, 25, 26, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 29, 0, 0, 32, - 33, 34, 35, 36, 37, 38, 39, 40, 41, 0, - 42, 43, 0, 44, 45, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 207, 0, 0, 107, 48, 0, 49, - 50, 0, 612, 232, 52, 53, 54, 55, 56, 57, - 0, 0, 0, 0, 0, 0, 0, 5, 6, 7, - 0, 9, 0, 0, 0, 10, 11, 58, 233, 60, - 12, 0, 13, 14, 15, 97, 98, 18, 19, 0, - 0, 0, 0, 99, 21, 22, 23, 24, 25, 26, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 29, - 0, 0, 32, 33, 34, 35, 36, 37, 38, 39, - 40, 41, 0, 42, 43, 0, 44, 45, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 207, 0, 0, 107, - 48, 0, 49, 50, 0, 608, 232, 52, 53, 54, - 55, 56, 57, 0, 0, 0, 0, 0, 0, 0, - 5, 6, 7, 0, 9, 0, 0, 0, 10, 11, - 58, 233, 60, 12, 0, 13, 14, 15, 97, 98, - 18, 19, 0, 0, 0, 0, 99, 100, 101, 23, - 24, 25, 26, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 29, 0, 0, 32, 33, 34, 35, 36, - 37, 38, 39, 40, 41, 0, 42, 43, 0, 44, - 45, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 207, - 0, 0, 107, 48, 0, 49, 50, 0, 807, 232, - 52, 53, 54, 55, 56, 57, 0, 0, 0, 0, - 0, 0, 0, 5, 6, 7, 0, 9, 0, 0, - 0, 10, 11, 58, 233, 60, 12, 0, 13, 14, - 15, 97, 98, 18, 19, 0, 0, 0, 0, 99, - 100, 101, 23, 24, 25, 26, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 29, 0, 0, 32, 33, - 34, 35, 36, 37, 38, 39, 40, 41, 0, 42, - 43, 0, 44, 45, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 207, 0, 0, 107, 48, 0, 49, 50, - 0, 810, 232, 52, 53, 54, 55, 56, 57, 0, - 0, 0, 0, 0, 0, 0, 5, 6, 7, 0, - 9, 0, 0, 0, 10, 11, 58, 233, 60, 12, - 0, 13, 14, 15, 97, 98, 18, 19, 0, 0, - 0, 0, 99, 100, 101, 23, 24, 25, 26, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 29, 0, - 0, 32, 33, 34, 35, 36, 37, 38, 39, 40, - 41, 0, 42, 43, 0, 44, 45, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 207, 0, 0, 107, 48, - 0, 49, 50, 0, 815, 232, 52, 53, 54, 55, - 56, 57, 0, 0, 0, 0, 0, 0, 0, 5, - 6, 7, 0, 9, 0, 0, 0, 10, 11, 58, - 233, 60, 12, 0, 13, 14, 15, 97, 98, 18, - 19, 0, 0, 0, 0, 99, 100, 101, 23, 24, - 25, 26, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 29, 0, 0, 32, 33, 34, 35, 36, 37, - 38, 39, 40, 41, 0, 42, 43, 0, 44, 45, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 207, 0, - 0, 107, 48, 0, 49, 50, 0, 883, 232, 52, - 53, 54, 55, 56, 57, 0, 0, 0, 0, 0, - 0, 0, 5, 6, 7, 0, 9, 0, 0, 0, - 10, 11, 58, 233, 60, 12, 0, 13, 14, 15, - 97, 98, 18, 19, 0, 0, 0, 0, 99, 100, - 101, 23, 24, 25, 26, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 29, 0, 0, 32, 33, 34, - 35, 36, 37, 38, 39, 40, 41, 0, 42, 43, - 0, 44, 45, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 207, 0, 0, 107, 48, 0, 49, 50, 0, - 885, 232, 52, 53, 54, 55, 56, 57, 0, 0, - 0, 0, 0, 0, 0, 5, 6, 7, 0, 9, - 0, 0, 0, 10, 11, 58, 233, 60, 12, 0, - 13, 14, 15, 97, 98, 18, 19, 0, 0, 0, - 0, 99, 100, 101, 23, 24, 25, 26, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 29, 0, 0, - 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, - 0, 42, 43, 0, 44, 45, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 207, 0, 0, 107, 48, 0, - 49, 50, 0, 912, 232, 52, 53, 54, 55, 56, - 57, 0, 0, 0, 0, 0, 0, 0, 5, 6, - 7, 0, 9, 0, 0, 0, 10, 11, 58, 233, - 60, 12, 0, 13, 14, 15, 16, 17, 18, 19, - 0, 0, 0, 0, 20, 21, 22, 23, 24, 25, - 26, 0, 0, 27, 0, 0, 0, 0, 0, 0, - 29, 0, 0, 32, 33, 34, 35, 36, 37, 38, - 39, 40, 41, 0, 42, 43, 0, 44, 45, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 207, 0, 0, - 107, 48, 0, 49, 50, 0, 0, 0, 52, 53, - 54, 55, 56, 57, 0, 0, 0, 0, 0, 0, - 0, 5, 6, 7, 0, 9, 0, 0, 0, 10, - 11, 58, 59, 60, 12, 0, 13, 14, 15, 97, - 98, 18, 19, 0, 0, 0, 0, 99, 21, 22, - 23, 24, 25, 26, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 29, 0, 0, 32, 33, 34, 35, - 36, 37, 38, 39, 40, 41, 0, 42, 43, 0, - 44, 45, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 207, 0, 0, 107, 48, 0, 49, 50, 0, 266, - 0, 52, 53, 54, 55, 56, 57, 0, 0, 0, - 0, 0, 0, 0, 5, 6, 7, 0, 9, 0, - 0, 0, 10, 11, 58, 233, 60, 12, 0, 13, - 14, 15, 16, 17, 18, 19, 0, 0, 0, 0, - 20, 21, 22, 23, 24, 25, 26, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 29, 0, 0, 32, - 33, 34, 35, 36, 37, 38, 39, 40, 41, 0, - 42, 43, 0, 44, 45, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 207, 0, 0, 107, 48, 0, 49, - 50, 0, 479, 0, 52, 53, 54, 55, 56, 57, - 0, 0, 0, 0, 0, 0, 0, 5, 6, 7, - 0, 9, 0, 0, 0, 10, 11, 58, 233, 60, - 12, 0, 13, 14, 15, 97, 98, 18, 19, 0, - 0, 0, 0, 99, 100, 101, 23, 24, 25, 26, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 29, - 0, 0, 32, 33, 34, 35, 36, 37, 38, 39, - 40, 41, 0, 42, 43, 0, 44, 45, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 207, 0, 0, 107, - 48, 0, 49, 50, 0, 590, 0, 52, 53, 54, - 55, 56, 57, 0, 0, 0, 0, 0, 0, 0, - 5, 6, 7, 0, 9, 0, 0, 0, 10, 11, - 58, 233, 60, 12, 0, 13, 14, 15, 97, 98, - 18, 19, 0, 0, 0, 0, 99, 100, 101, 23, - 24, 25, 26, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 29, 0, 0, 32, 33, 34, 35, 36, - 37, 38, 39, 40, 41, 0, 42, 43, 0, 44, - 45, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 207, - 0, 0, 107, 48, 0, 49, 50, 0, 638, 0, - 52, 53, 54, 55, 56, 57, 0, 0, 0, 0, - 0, 0, 0, 5, 6, 7, 0, 9, 0, 0, - 0, 10, 11, 58, 233, 60, 12, 0, 13, 14, - 15, 97, 98, 18, 19, 0, 0, 0, 0, 99, - 100, 101, 23, 24, 25, 26, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 29, 0, 0, 32, 33, - 34, 35, 36, 37, 38, 39, 40, 41, 0, 42, - 43, 0, 44, 45, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 207, 0, 0, 107, 48, 0, 49, 50, - 0, 479, 0, 52, 53, 54, 55, 56, 57, 0, - 0, 0, 0, 0, 0, 0, 5, 6, 7, 0, - 9, 0, 0, 0, 10, 11, 58, 233, 60, 12, - 0, 13, 14, 15, 97, 98, 18, 19, 0, 0, - 0, 0, 99, 100, 101, 23, 24, 25, 26, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 29, 0, - 0, 32, 33, 34, 35, 36, 37, 38, 39, 40, - 41, 0, 42, 43, 0, 44, 45, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 207, 0, 0, 107, 48, - 0, 49, 50, 0, 758, 0, 52, 53, 54, 55, - 56, 57, 0, 0, 0, 0, 0, 0, 0, 5, - 6, 7, 0, 9, 0, 0, 0, 10, 11, 58, - 233, 60, 12, 0, 13, 14, 15, 97, 98, 18, - 19, 0, 0, 0, 0, 99, 100, 101, 23, 24, - 25, 26, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 29, 0, 0, 32, 33, 34, 35, 36, 37, - 38, 39, 40, 41, 0, 42, 43, 0, 44, 45, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 207, 0, - 0, 107, 48, 0, 49, 50, 0, 801, 0, 52, - 53, 54, 55, 56, 57, 0, 0, 0, 0, 0, - 0, 0, 5, 6, 7, 0, 9, 0, 0, 0, - 10, 11, 58, 233, 60, 12, 0, 13, 14, 15, - 97, 98, 18, 19, 0, 0, 0, 0, 99, 100, - 101, 23, 24, 25, 26, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 29, 0, 0, 32, 33, 34, - 35, 36, 37, 38, 39, 40, 41, 0, 42, 43, - 0, 44, 45, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 207, 0, 0, 107, 48, 0, 49, 50, 0, - 0, 0, 52, 53, 54, 55, 56, 57, 0, 0, - 0, 0, 0, 0, 0, 5, 6, 7, 0, 9, - 0, 0, 0, 10, 11, 58, 233, 60, 12, 0, - 13, 14, 15, 16, 17, 18, 19, 0, 0, 0, - 0, 20, 21, 22, 23, 24, 25, 26, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 29, 0, 0, - 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, - 0, 42, 43, 0, 44, 45, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 207, 0, 0, 107, 48, 0, - 49, 50, 0, 0, 0, 52, 53, 54, 55, 56, - 57, 0, 0, 0, 0, 0, 0, 0, 5, 6, - 7, 0, 9, 0, 0, 0, 10, 11, 58, 233, - 60, 12, 0, 13, 14, 15, 97, 98, 18, 19, - 0, 0, 0, 0, 99, 100, 101, 23, 24, 25, - 26, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 102, 0, 0, 32, 33, 34, 35, 36, 37, 38, - 39, 40, 41, 0, 42, 43, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 276, 0, 0, - 312, 48, 0, 49, 50, 0, 868, 869, 52, 53, - 54, 55, 56, 57, 0, 0, 0, 5, 6, 7, - 0, 9, 0, 0, 0, 10, 11, 0, 0, 0, - 12, 108, 13, 14, 15, 97, 98, 18, 19, 0, - 0, 0, 0, 99, 100, 101, 23, 24, 25, 26, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 102, - 0, 0, 32, 33, 103, 35, 36, 37, 104, 39, - 40, 41, 0, 42, 43, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 105, 0, 0, 106, 0, 0, 107, - 48, 0, 49, 50, 0, 0, 0, 52, 53, 54, - 55, 56, 57, 0, 0, 0, 5, 6, 7, 0, - 9, 0, 0, 0, 10, 11, 0, 0, 0, 12, - 108, 13, 14, 15, 97, 98, 18, 19, 0, 0, - 0, 0, 99, 100, 101, 23, 24, 25, 26, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 102, 0, - 0, 32, 33, 34, 35, 36, 37, 38, 39, 40, - 41, 0, 42, 43, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 224, 0, 0, 47, 48, - 0, 49, 50, 0, 51, 0, 52, 53, 54, 55, - 56, 57, 0, 0, 0, 5, 6, 7, 0, 9, - 0, 0, 0, 10, 11, 0, 0, 0, 12, 108, - 13, 14, 15, 97, 98, 18, 19, 0, 0, 0, - 0, 99, 100, 101, 23, 24, 25, 26, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 102, 0, 0, - 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, - 0, 42, 43, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 276, 0, 0, 312, 48, 0, - 49, 50, 0, 313, 0, 52, 53, 54, 55, 56, - 57, 0, 0, 0, 5, 6, 7, 0, 9, 0, - 0, 0, 10, 11, 0, 0, 0, 12, 108, 13, - 14, 15, 97, 98, 18, 19, 0, 0, 0, 0, - 99, 100, 101, 23, 24, 25, 26, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 102, 0, 0, 32, - 33, 103, 35, 36, 37, 104, 39, 40, 41, 0, - 42, 43, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 106, 0, 0, 107, 48, 0, 49, - 50, 0, 0, 0, 52, 53, 54, 55, 56, 57, - 0, 0, 0, 5, 6, 7, 0, 9, 0, 0, - 0, 10, 11, 0, 0, 0, 12, 108, 13, 14, - 15, 97, 98, 18, 19, 0, 0, 0, 0, 99, - 100, 101, 23, 24, 25, 26, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 102, 0, 0, 32, 33, - 34, 35, 36, 37, 38, 39, 40, 41, 0, 42, - 43, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 276, 0, 0, 107, 48, 0, 49, 50, - 0, 0, 0, 52, 53, 54, 55, 56, 57, 0, - 0, 0, 5, 6, 7, 0, 9, 0, 0, 0, - 10, 11, 0, 0, 0, 12, 108, 13, 14, 15, - 97, 98, 18, 19, 0, 0, 0, 0, 99, 100, - 101, 23, 24, 25, 26, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 102, 0, 0, 32, 33, 34, - 35, 36, 37, 38, 39, 40, 41, 0, 42, 43, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 820, 0, 0, 107, 48, 0, 49, 50, 0, - 0, 0, 52, 53, 54, 55, 56, 57, 0, 0, - 0, 0, 0, 0, 517, 518, 0, 0, 519, 0, - 0, 0, 0, 0, 0, 108, 160, 161, 162, 163, - 164, 165, 0, 166, 167, 0, 0, 168, 0, 0, - 0, 169, 170, 171, 172, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 173, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, - 524, 525, 184, 0, 526, 0, 0, 0, 0, 0, - 0, 185, 160, 161, 162, 163, 164, 165, 0, 166, - 167, 0, 0, 168, 0, 0, 0, 169, 170, 171, - 172, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 173, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 174, 175, 176, 177, - 178, 179, 180, 181, 182, 183, 529, 525, 184, 0, - 530, 0, 0, 0, 0, 0, 0, 185, 160, 161, - 162, 163, 164, 165, 0, 166, 167, 0, 0, 168, - 0, 0, 0, 169, 170, 171, 172, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 173, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 174, 175, 176, 177, 178, 179, 180, 181, - 182, 183, 545, 518, 184, 0, 546, 0, 0, 0, - 0, 0, 0, 185, 160, 161, 162, 163, 164, 165, - 0, 166, 167, 0, 0, 168, 0, 0, 0, 169, - 170, 171, 172, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 173, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 174, 175, - 176, 177, 178, 179, 180, 181, 182, 183, 582, 518, - 184, 0, 583, 0, 0, 0, 0, 0, 0, 185, - 160, 161, 162, 163, 164, 165, 0, 166, 167, 0, - 0, 168, 0, 0, 0, 169, 170, 171, 172, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 173, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 174, 175, 176, 177, 178, 179, - 180, 181, 182, 183, 585, 525, 184, 0, 586, 0, - 0, 0, 0, 0, 0, 185, 160, 161, 162, 163, - 164, 165, 0, 166, 167, 0, 0, 168, 0, 0, - 0, 169, 170, 171, 172, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 173, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, - 599, 518, 184, 0, 600, 0, 0, 0, 0, 0, - 0, 185, 160, 161, 162, 163, 164, 165, 0, 166, - 167, 0, 0, 168, 0, 0, 0, 169, 170, 171, - 172, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 173, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 174, 175, 176, 177, - 178, 179, 180, 181, 182, 183, 602, 525, 184, 0, - 603, 0, 0, 0, 0, 0, 0, 185, 160, 161, - 162, 163, 164, 165, 0, 166, 167, 0, 0, 168, - 0, 0, 0, 169, 170, 171, 172, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 173, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 174, 175, 176, 177, 178, 179, 180, 181, - 182, 183, 640, 518, 184, 0, 641, 0, 0, 0, - 0, 0, 0, 185, 160, 161, 162, 163, 164, 165, - 0, 166, 167, 0, 0, 168, 0, 0, 0, 169, - 170, 171, 172, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 173, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 174, 175, - 176, 177, 178, 179, 180, 181, 182, 183, 643, 525, - 184, 0, 644, 0, 0, 0, 0, 0, 0, 185, - 160, 161, 162, 163, 164, 165, 0, 166, 167, 0, - 0, 168, 0, 0, 0, 169, 170, 171, 172, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 173, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 174, 175, 176, 177, 178, 179, - 180, 181, 182, 183, 889, 518, 184, 0, 890, 0, - 0, 0, 0, 0, 0, 185, 160, 161, 162, 163, - 164, 165, 0, 166, 167, 0, 0, 168, 0, 0, - 0, 169, 170, 171, 172, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 173, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, - 892, 525, 184, 0, 893, 0, 0, 0, 0, 0, - 0, 185, 160, 161, 162, 163, 164, 165, 0, 166, - 167, 0, 0, 168, 0, 0, 0, 169, 170, 171, - 172, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 173, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 174, 175, 176, 177, - 178, 179, 180, 181, 182, 183, 0, 0, 184, 0, - 0, 0, 0, 0, 0, 0, 0, 185, 316, 317, - 318, 319, 320, 321, 322, 323, 324, 325, 326, 327, - 328, 0, 0, 329, 330, 0, 0, 0, -220, 316, - 317, 318, 319, 320, 321, 322, 323, 324, 325, 326, - 327, 328, 0, 0, 329, 330, 0, 0, 331, 0, - 332, 333, 334, 335, 336, 337, 338, 339, 340, 341, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 331, - -220, 332, 333, 334, 335, 336, 337, 338, 339, 340, - 341, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 605, 316, 317, 318, 319, 320, 321, 322, 323, - 324, 325, 326, 327, 328, 0, 0, 329, 330, 316, - 317, 318, 319, 320, 321, 322, 323, 324, 325, 326, - -516, -516, 0, 0, 329, 330, 0, 0, 0, 0, - 0, 0, 331, 0, 332, 333, 334, 335, 336, 337, - 338, 339, 340, 341, 0, 0, 0, 0, 0, 0, - 0, 332, 333, 334, 335, 336, 337, 338, 339, 340, - 341, 316, 317, 318, 319, 320, 321, 322, 0, 0, - 325, 326, 0, 0, 0, 0, 329, 330, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 332, 333, 334, 335, 336, 337, 338, - 339, 340, 341 -}; - -static const yytype_int16 yycheck[] = -{ - 2, 343, 4, 5, 6, 71, 7, 28, 10, 11, - 12, 397, 215, 15, 16, 17, 7, 8, 20, 16, - 17, 4, 59, 20, 370, 27, 368, 247, 372, 2, - 8, 4, 5, 6, 7, 287, 391, 28, 22, 291, - 22, 47, 15, 62, 386, 47, 48, 49, 409, 51, - 28, 52, 17, 8, 692, 20, 13, 59, 400, 531, - 532, 52, 10, 11, 12, 106, 16, 17, 315, 71, - 20, 12, 51, 28, 47, 568, 1, 570, 51, 27, - 689, 442, 577, 692, 26, 533, 534, 27, 130, 261, - 16, 17, 587, 25, 20, 26, 130, 131, 71, 49, - 48, 81, 25, 105, 64, 107, 25, 25, 450, 25, - 94, 120, 94, 25, 25, 25, 16, 17, 81, 101, - 20, 62, 84, 72, 50, 81, 56, 57, 81, 5, - 6, 36, 37, 115, 107, 36, 37, 81, 26, 15, - 312, 58, 122, 342, 124, 344, 345, 346, 105, 0, - 50, 11, 12, 113, 114, 115, 83, 105, 50, 108, - 25, 124, 54, 25, 126, 105, 122, 130, 124, 110, - 369, 124, 128, 130, 131, 51, 103, 54, 120, 81, - 124, 664, 107, 92, 101, 58, 385, 670, 387, 120, - 130, 131, 81, 81, 126, 71, 128, 128, 544, 218, - 838, 110, 401, 126, 206, 130, 131, 126, 126, 128, - 126, 463, 102, 28, 126, 126, 126, 563, 562, 83, - 222, 223, 124, 129, 125, 130, 99, 100, 83, 838, - 678, 430, 120, 206, 122, 124, 124, 83, 103, 103, - 128, 103, 244, 108, 246, 247, 108, 244, 103, 246, - 247, 15, 451, 17, 256, 261, 129, 103, 129, 261, - 125, 126, 126, 125, 126, 737, 738, 2, 126, 4, - 5, 6, 130, 310, 222, 223, 103, 218, 315, 244, - 15, 246, 247, 256, 126, 126, 103, 81, 261, 130, - 783, 784, 81, 94, 244, 788, 246, 247, 300, 301, - 302, 303, 304, 305, 306, 307, 312, 802, 310, 81, - 312, 313, 47, 315, 351, 352, 51, 300, 244, 50, - 246, 247, 305, 83, 81, 83, 367, 300, 122, 576, - 124, 81, 305, 122, 313, 124, 71, 723, 128, 312, - 313, 343, 81, 81, 244, 103, 246, 247, 81, 351, - 352, 342, 124, 301, 302, 303, 304, 128, 306, 307, - 91, 92, 222, 223, 725, 26, 368, 124, 370, 371, - 126, 732, 107, 54, 124, 83, 367, 267, 103, 110, - 382, 83, 113, 876, 386, 124, 124, 83, 390, 592, - 392, 124, 83, 343, 385, 103, 26, 370, 400, 131, - 15, 103, 17, 424, 624, 26, 52, 103, 399, 382, - 310, 413, 54, 59, 60, 315, 413, 390, 368, 392, - 81, 81, 363, 371, 126, 427, 625, 626, 84, 775, - 2, 58, 4, 424, 26, 58, 386, 313, 429, 36, - 37, 301, 302, 303, 304, 789, 424, 802, 450, 126, - 400, 81, 25, 130, 427, 396, 397, 126, 449, 120, - 81, 122, 122, 124, 124, 413, 128, 128, 64, 424, - 120, 206, 99, 100, 101, 47, 99, 100, 101, 126, - 406, 64, 83, 79, 80, 56, 57, 413, 125, 81, - 120, 125, 122, 393, 124, 123, 842, 858, 128, 120, - 450, 122, 103, 124, 121, 14, 15, 128, 58, 2, - 54, 4, 125, 2, 110, 111, 112, 113, 114, 115, - 83, 256, 15, 240, 866, 126, 261, 417, 120, 419, - 122, 64, 124, 58, 101, 107, 128, 521, 81, 521, - 103, 543, 544, 904, 528, 435, 436, 531, 532, 99, - 100, 101, 101, 574, 47, 125, 126, 58, 47, 64, - 61, 563, 64, 126, 126, 300, 548, 54, 55, 90, - 305, 544, 573, 83, 99, 100, 101, 312, 313, 122, - 10, 124, 573, 574, 81, 8, 13, 653, 791, 17, - 563, 10, 126, 103, 797, 543, 574, 125, 99, 100, - 541, 125, 604, 50, 126, 52, 53, 54, 55, 111, - 112, 113, 114, 115, 107, 121, 126, 81, 107, 574, - 123, 125, 624, 564, 661, 122, 81, 124, 630, 666, - 667, 126, 126, 129, 206, 370, 50, 125, 52, 53, - 54, 55, 126, 645, 91, 92, 270, 382, 272, 123, - 274, 653, 81, 10, 103, 390, 604, 392, 122, 661, - 124, 126, 552, 110, 666, 667, 113, 122, 867, 124, - 126, 81, 645, 50, 624, 64, 576, 91, 92, 50, - 653, 128, 630, 543, 256, 126, 403, 83, 15, 261, - 79, 80, 427, 122, 81, 124, 110, 123, 624, 113, - 81, 10, 704, 52, 53, 707, 55, 103, 10, 126, - 59, 60, 122, 206, 124, 123, 92, 719, 720, 721, - 126, 125, 111, 112, 113, 114, 115, 126, 300, 766, - 126, 704, 729, 305, 125, 122, 121, 124, 10, 680, - 312, 122, 125, 124, 604, 125, 719, 720, 721, 751, - 752, 123, 125, 10, 84, 757, 9, 125, 10, 707, - 10, 827, 121, 256, 766, 126, 108, 256, 261, 125, - 772, 773, 261, 775, 126, 126, 10, 653, 751, 752, - 10, 126, 723, 126, 757, 125, 54, 92, 790, 126, - 10, 10, 794, 121, 10, 92, 686, 121, 370, 772, - 773, 10, 775, 729, 10, 126, 123, 300, 92, 544, - 382, 126, 305, 92, 15, 6, 879, 790, 390, 312, - 392, 794, 78, 312, 878, 827, 81, 7, 563, 729, - 789, 62, 562, 835, 39, 40, 41, 42, 43, 689, - 842, 689, 844, -1, 846, -1, 736, 707, -1, -1, - -1, 853, -1, 743, 827, 427, -1, -1, -1, -1, - -1, 863, 835, -1, 866, -1, 868, 869, -1, 842, - -1, 844, -1, 846, 865, 751, 752, 370, -1, -1, - 853, -1, -1, -1, -1, -1, 888, -1, -1, 382, - 863, -1, -1, 382, 611, 868, 869, 390, -1, 392, - -1, 390, -1, 392, -1, 622, -1, 909, -1, -1, - 645, 646, -1, 915, 790, 888, 866, -1, 653, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 64, - 856, -1, -1, -1, 427, -1, 909, -1, 427, -1, - -1, -1, 915, -1, 79, 80, -1, -1, -1, -1, - -1, 827, -1, -1, -1, 64, 65, 66, 67, 68, - 69, 70, 71, 72, 73, 74, 75, 76, -1, 704, - 79, 80, 544, 108, 109, 110, 111, 112, 113, 114, - 115, -1, -1, -1, 719, 720, 721, 863, -1, -1, - -1, 563, 868, 869, -1, 104, -1, 106, 107, 108, - 109, 110, 111, 112, 113, 114, 115, 724, -1, -1, - 727, 728, 888, -1, -1, -1, 751, 752, -1, -1, - -1, 130, 757, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 909, -1, -1, -1, 772, 773, 915, - 775, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 544, -1, -1, -1, 790, -1, -1, -1, 794, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 563, -1, -1, 645, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 827, -1, -1, 812, 813, -1, -1, -1, - 835, -1, -1, -1, -1, -1, -1, 842, -1, 844, - -1, 846, -1, -1, -1, -1, -1, -1, 853, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 863, -1, - -1, -1, 704, 868, 869, -1, -1, 854, 855, -1, - -1, -1, -1, 860, -1, -1, -1, 719, 720, 721, - 16, 17, 645, 888, 20, -1, 645, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 884, -1, -1, - -1, -1, -1, -1, 909, -1, -1, -1, 44, 45, - 915, -1, -1, 49, 50, 757, 903, -1, -1, 906, - -1, -1, -1, 59, 60, -1, -1, -1, -1, 916, - 772, 773, -1, 775, 64, 65, 66, 67, 68, 69, - 70, 704, -1, 73, 74, 704, -1, -1, -1, 79, - 80, -1, 794, -1, -1, -1, 719, 720, 721, -1, - 719, 720, 721, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 49, 50, -1, 106, 107, 108, 109, - 110, 111, 112, 113, 114, 115, -1, -1, 751, 752, - -1, -1, -1, 835, 757, -1, -1, -1, 757, -1, - 842, -1, 844, -1, 846, -1, -1, 0, -1, 772, - 773, 853, 775, 772, 773, 8, 9, 10, -1, -1, - 13, 14, 15, -1, 17, -1, -1, 790, -1, -1, - -1, 794, -1, -1, 27, 794, -1, -1, -1, -1, - -1, -1, -1, 36, 37, -1, 39, 40, 41, 42, - 43, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 835, -1, -1, -1, 835, -1, -1, 842, - -1, 844, -1, 846, -1, 844, -1, 846, 81, -1, - 853, -1, -1, -1, 853, 231, 232, 233, -1, -1, - 863, -1, -1, -1, -1, 868, 869, -1, 244, -1, - 246, 247, 105, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 888, -1, -1, 121, -1, - 266, 124, 125, -1, -1, 128, -1, 130, 131, -1, - -1, -1, -1, -1, -1, -1, 909, -1, -1, -1, - -1, -1, 915, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 239, 240, -1, -1, -1, -1, -1, - -1, 247, -1, -1, 310, -1, -1, -1, -1, 315, - 316, 317, 318, 319, 320, 321, 322, 323, 324, 325, - 326, 327, 328, 329, 330, 331, 332, 333, 334, 335, - 336, 337, 338, 339, 340, 341, -1, 343, -1, -1, - -1, -1, -1, -1, -1, 351, 352, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 368, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 384, -1, - 386, -1, 388, 389, -1, -1, -1, 393, -1, -1, - -1, -1, -1, -1, 400, -1, -1, 343, -1, 405, - 406, -1, -1, 409, -1, -1, -1, 413, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 426, -1, 368, -1, -1, 431, -1, -1, -1, -1, - -1, -1, 378, 439, -1, -1, 442, -1, 444, -1, - 386, 0, -1, -1, 450, -1, -1, -1, -1, 8, - 9, 10, -1, -1, 400, 14, 15, 403, 17, -1, - -1, -1, 468, 469, -1, -1, -1, 26, -1, -1, - -1, -1, 418, 479, -1, -1, -1, 36, 37, -1, - 39, 40, 41, 42, 43, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 450, 64, 65, 66, 67, 68, - 69, 70, 71, 72, 73, 74, 75, 76, -1, -1, - 79, 80, 81, -1, 83, -1, -1, -1, -1, -1, - -1, -1, 478, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 103, 104, -1, 106, 107, 108, - 109, 110, 111, 112, 113, 114, 115, -1, -1, -1, - -1, 120, 121, 122, -1, 124, 125, 126, -1, -1, - 576, 130, 131, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 528, -1, 590, 531, 532, 533, 534, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 608, -1, 550, -1, 612, -1, -1, -1, - 616, -1, -1, -1, -1, -1, -1, -1, 624, -1, - 566, -1, 568, -1, 570, -1, -1, -1, -1, -1, - 576, 577, 638, 579, -1, -1, -1, -1, -1, -1, - -1, 587, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 657, -1, 659, 660, 661, 662, -1, -1, -1, - 666, 667, -1, -1, -1, 611, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 622, -1, -1, 685, - -1, -1, -1, 2, -1, 4, -1, -1, -1, -1, - -1, 10, 11, 12, -1, -1, -1, 16, 17, -1, - -1, 20, -1, -1, 710, -1, 712, 713, 27, -1, - 231, 232, 718, -1, -1, -1, -1, -1, -1, 725, - -1, -1, -1, 729, -1, -1, 732, -1, 47, 48, - 49, -1, 678, -1, -1, -1, -1, -1, -1, -1, - 59, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 758, -1, -1, -1, 702, -1, -1, 705, - 766, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 724, -1, - -1, 727, 728, -1, -1, -1, 105, -1, 107, 310, - -1, 737, 738, 799, 315, 801, -1, -1, -1, -1, - -1, 807, -1, -1, 810, -1, -1, -1, -1, 815, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 783, 784, -1, - -1, -1, 788, -1, -1, -1, -1, -1, -1, -1, - 856, -1, 858, -1, -1, -1, 802, -1, -1, -1, - 866, -1, -1, -1, -1, -1, 812, 813, -1, -1, - -1, -1, 393, -1, -1, -1, -1, 883, -1, 885, - -1, -1, -1, -1, 405, 406, -1, 206, 409, -1, - -1, -1, 413, -1, -1, -1, -1, -1, 904, -1, - -1, -1, -1, 222, 223, -1, 912, -1, 854, 855, - -1, -1, -1, -1, 860, -1, -1, -1, 439, -1, - 866, 442, -1, 444, -1, 244, -1, 246, 247, -1, - 876, -1, 878, 879, -1, -1, -1, 256, 884, -1, - -1, -1, 261, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 903, 479, -1, - 906, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 916, -1, -1, -1, -1, -1, 43, -1, -1, -1, - -1, 300, 301, 302, 303, 304, 305, 306, 307, -1, - -1, 310, -1, 312, -1, -1, 315, 64, 65, 66, - 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, - -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 343, -1, -1, -1, -1, -1, - -1, -1, 351, 352, -1, -1, -1, 104, -1, 106, - 107, 108, 109, 110, 111, 112, 113, 114, 115, 368, - -1, 370, 371, -1, -1, 576, -1, -1, -1, 126, - -1, -1, -1, 382, -1, -1, -1, 386, -1, 590, - -1, 390, -1, 392, -1, -1, -1, -1, -1, -1, - -1, 400, -1, -1, -1, -1, -1, 608, -1, -1, - -1, 612, -1, -1, 413, 616, 3, 4, 5, -1, - 7, -1, -1, 624, 11, 12, -1, -1, 427, 16, - -1, 18, 19, 20, 21, 22, 23, 24, -1, -1, - -1, -1, 29, 30, 31, 32, 33, 34, 35, -1, - -1, 450, -1, -1, -1, -1, 657, -1, 45, -1, - -1, 48, 49, 50, 51, 52, 53, 54, 55, 56, - 57, -1, 59, 60, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 685, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 82, -1, -1, 85, 86, - -1, 88, 89, -1, -1, -1, 93, 94, 95, 96, - 97, 98, -1, -1, -1, -1, -1, 718, -1, -1, - -1, -1, -1, -1, 725, -1, -1, -1, -1, 116, - -1, 732, -1, -1, -1, -1, -1, -1, -1, 126, - -1, -1, -1, -1, 543, 544, -1, -1, -1, -1, - -1, -1, 43, -1, -1, -1, -1, 758, -1, -1, - -1, -1, -1, -1, 563, -1, -1, -1, -1, -1, - -1, -1, -1, 64, 65, 66, 67, 68, 69, 70, - 71, 72, 73, 74, 75, 76, -1, -1, 79, 80, - -1, -1, 64, 65, 66, 67, 68, 69, 70, 71, - 801, 73, 74, -1, -1, 604, -1, 79, 80, 810, - -1, -1, -1, 104, 815, 106, 107, 108, 109, 110, - 111, 112, 113, 114, 115, 624, -1, -1, -1, -1, - -1, 630, -1, -1, 106, 107, 108, 109, 110, 111, - 112, 113, 114, 115, -1, -1, 645, -1, -1, -1, - -1, -1, -1, -1, -1, 856, -1, 858, -1, -1, - -1, -1, 661, -1, -1, -1, -1, 666, 667, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 883, -1, 885, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 904, -1, 704, -1, -1, 707, -1, - -1, 912, -1, -1, -1, -1, -1, -1, -1, -1, - 719, 720, 721, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 3, 4, 5, -1, 7, -1, -1, - -1, 11, 12, -1, -1, -1, 16, -1, 18, 19, - 20, 21, 22, 23, 24, -1, -1, -1, 757, 29, - 30, 31, 32, 33, 34, 35, -1, 766, -1, -1, - -1, -1, -1, 772, 773, 45, 775, -1, 48, 49, - 50, 51, 52, 53, 54, 55, 56, 57, -1, 59, - 60, -1, -1, -1, -1, 794, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 82, -1, -1, 85, 86, -1, 88, 89, - -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, - -1, -1, -1, -1, -1, -1, 835, -1, 108, -1, - -1, -1, -1, 842, -1, 844, 116, 846, -1, -1, - -1, -1, 0, 1, 853, 3, 4, 5, 6, 7, - -1, -1, -1, 11, 12, -1, -1, 866, 16, -1, - 18, 19, 20, 21, 22, 23, 24, -1, -1, -1, - -1, 29, 30, 31, 32, 33, 34, 35, -1, -1, - 38, -1, -1, -1, -1, -1, 44, 45, 46, 47, - 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, - -1, 59, 60, -1, 62, 63, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 82, -1, -1, 85, 86, -1, - 88, 89, -1, 91, -1, 93, 94, 95, 96, 97, - 98, -1, -1, -1, -1, -1, -1, 0, -1, -1, - -1, -1, -1, -1, -1, 8, 9, 10, 116, 117, - 118, 14, 15, -1, 17, -1, -1, -1, -1, -1, - -1, -1, 130, 131, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 36, 37, -1, 39, 40, 41, 42, - 43, 64, 65, 66, 67, 68, 69, 70, 71, 72, - 73, 74, 75, 76, -1, -1, 79, 80, -1, -1, - -1, 64, 65, 66, 67, 68, 69, 70, 71, 72, - 73, 74, 75, 76, -1, -1, 79, 80, 81, -1, - 83, 104, 105, 106, 107, 108, 109, 110, 111, 112, - 113, 114, 115, -1, -1, -1, -1, -1, -1, -1, - 103, 104, -1, 106, 107, 108, 109, 110, 111, 112, - 113, 114, 115, -1, -1, -1, -1, -1, 121, 122, - -1, 124, 125, 126, -1, -1, -1, 130, 131, 1, - -1, 3, 4, 5, 6, 7, 8, 9, 10, 11, - 12, -1, -1, 15, 16, -1, 18, 19, 20, 21, - 22, 23, 24, -1, -1, -1, -1, 29, 30, 31, - 32, 33, 34, 35, -1, -1, 38, -1, -1, -1, - -1, -1, 44, 45, 46, 47, 48, 49, 50, 51, - 52, 53, 54, 55, 56, 57, -1, 59, 60, -1, - 62, 63, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 82, -1, -1, 85, 86, -1, 88, 89, -1, 91, - -1, 93, 94, 95, 96, 97, 98, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 116, 117, 118, -1, -1, -1, - -1, 1, -1, 3, 4, 5, 6, 7, 130, 131, - 10, 11, 12, -1, 14, 15, 16, -1, 18, 19, - 20, 21, 22, 23, 24, -1, -1, -1, -1, 29, - 30, 31, 32, 33, 34, 35, -1, -1, 38, -1, - -1, -1, -1, -1, 44, 45, 46, 47, 48, 49, - 50, 51, 52, 53, 54, 55, 56, 57, -1, 59, - 60, -1, 62, 63, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 82, -1, -1, 85, 86, -1, 88, 89, - -1, 91, -1, 93, 94, 95, 96, 97, 98, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 116, 117, 118, -1, - -1, -1, -1, 1, -1, 3, 4, 5, 6, 7, - 130, 131, 10, 11, 12, -1, -1, 15, 16, 17, - 18, 19, 20, 21, 22, 23, 24, -1, -1, -1, - -1, 29, 30, 31, 32, 33, 34, 35, -1, -1, - 38, -1, -1, -1, -1, -1, 44, 45, 46, 47, - 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, - -1, 59, 60, -1, 62, 63, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 82, -1, -1, 85, 86, -1, - 88, 89, -1, 91, -1, 93, 94, 95, 96, 97, - 98, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 116, 117, - 118, -1, -1, -1, -1, 1, -1, 3, 4, 5, - 6, 7, 130, 131, 10, 11, 12, -1, -1, 15, - 16, -1, 18, 19, 20, 21, 22, 23, 24, -1, - -1, -1, -1, 29, 30, 31, 32, 33, 34, 35, - -1, -1, 38, -1, -1, -1, -1, -1, 44, 45, - 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, - 56, 57, -1, 59, 60, -1, 62, 63, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 82, -1, -1, 85, - 86, -1, 88, 89, -1, 91, -1, 93, 94, 95, - 96, 97, 98, -1, -1, -1, -1, -1, 1, -1, - 3, 4, 5, 6, 7, -1, 9, 10, 11, 12, - 116, 117, 118, 16, -1, 18, 19, 20, 21, 22, - 23, 24, -1, -1, 130, 131, 29, 30, 31, 32, - 33, 34, 35, -1, -1, 38, -1, -1, -1, -1, - -1, 44, 45, 46, 47, 48, 49, 50, 51, 52, - 53, 54, 55, 56, 57, -1, 59, 60, -1, 62, - 63, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 82, - -1, -1, 85, 86, -1, 88, 89, -1, 91, -1, - 93, 94, 95, 96, 97, 98, -1, -1, -1, -1, - -1, 1, -1, 3, 4, 5, 6, 7, -1, -1, - -1, 11, 12, 116, 117, 118, 16, -1, 18, 19, - 20, 21, 22, 23, 24, -1, -1, 130, 131, 29, - 30, 31, 32, 33, 34, 35, -1, -1, 38, -1, - -1, -1, -1, -1, 44, 45, 46, 47, 48, 49, - 50, 51, 52, 53, 54, 55, 56, 57, -1, 59, - 60, -1, 62, 63, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 82, -1, -1, 85, 86, -1, 88, 89, - -1, 91, -1, 93, 94, 95, 96, 97, 98, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 116, 117, 118, -1, - -1, -1, -1, -1, -1, 125, -1, -1, -1, -1, - 130, 131, 1, -1, 3, 4, 5, 6, 7, -1, - -1, -1, 11, 12, -1, -1, -1, 16, -1, 18, - 19, 20, 21, 22, 23, 24, -1, -1, -1, -1, - 29, 30, 31, 32, 33, 34, 35, -1, -1, 38, - -1, -1, -1, -1, -1, 44, 45, 46, 47, 48, - 49, 50, 51, 52, 53, 54, 55, 56, 57, -1, - 59, 60, -1, 62, 63, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 82, -1, -1, 85, 86, -1, 88, - 89, -1, 91, -1, 93, 94, 95, 96, 97, 98, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 116, 117, 118, - -1, -1, -1, -1, -1, -1, 125, -1, -1, -1, - -1, 130, 131, 1, -1, 3, 4, 5, 6, 7, - -1, -1, -1, 11, 12, -1, -1, -1, 16, -1, - 18, 19, 20, 21, 22, 23, 24, -1, -1, -1, - -1, 29, 30, 31, 32, 33, 34, 35, -1, -1, - 38, -1, -1, -1, -1, -1, 44, 45, 46, 47, - 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, - -1, 59, 60, -1, 62, 63, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 82, -1, -1, 85, 86, -1, - 88, 89, -1, 91, -1, 93, 94, 95, 96, 97, - 98, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 116, 117, - 118, -1, -1, 121, -1, 1, -1, 3, 4, 5, - 6, 7, 130, 131, 10, 11, 12, -1, -1, -1, - 16, -1, 18, 19, 20, 21, 22, 23, 24, -1, - -1, -1, -1, 29, 30, 31, 32, 33, 34, 35, - -1, -1, 38, -1, -1, -1, -1, -1, 44, 45, - 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, - 56, 57, -1, 59, 60, -1, 62, 63, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 82, -1, -1, 85, - 86, -1, 88, 89, -1, 91, -1, 93, 94, 95, - 96, 97, 98, -1, -1, -1, -1, -1, -1, -1, - 3, 4, 5, 6, 7, -1, -1, -1, 11, 12, - 116, 117, 118, 16, -1, 18, 19, 20, 21, 22, - 23, 24, -1, -1, 130, 131, 29, 30, 31, 32, - 33, 34, 35, -1, -1, 38, -1, -1, -1, -1, - -1, 44, 45, 46, 47, 48, 49, 50, 51, 52, - 53, 54, 55, 56, 57, -1, 59, 60, -1, 62, - 63, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 82, - -1, -1, 85, 86, -1, 88, 89, -1, 91, -1, - 93, 94, 95, 96, 97, 98, -1, -1, -1, -1, - -1, -1, -1, 3, 4, 5, -1, 7, -1, -1, - -1, 11, 12, 116, 117, 118, 16, -1, 18, 19, - 20, 21, 22, 23, 24, -1, -1, -1, 131, 29, - 30, 31, 32, 33, 34, 35, -1, -1, 38, -1, - -1, -1, -1, -1, -1, 45, -1, -1, 48, 49, - 50, 51, 52, 53, 54, 55, 56, 57, -1, 59, - 60, -1, 62, 63, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 82, -1, -1, 85, 86, -1, 88, 89, - -1, -1, -1, 93, 94, 95, 96, 97, 98, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 116, 117, 118, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 130, 131, 3, 4, 5, 6, 7, 8, 9, 10, - 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, - 21, 22, 23, 24, 25, 26, -1, -1, 29, 30, - 31, 32, 33, 34, 35, 36, 37, 38, -1, -1, - -1, -1, -1, 44, 45, 46, 47, 48, 49, 50, - 51, 52, 53, 54, 55, -1, -1, -1, -1, -1, - -1, 62, 63, 64, 65, 66, 67, -1, 69, 70, - -1, -1, 73, -1, -1, -1, 77, 78, 79, 80, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 91, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 106, 107, 108, 109, 110, - 111, 112, 113, 114, 115, -1, -1, 118, -1, -1, - 3, 4, 5, -1, 7, -1, 127, 128, 11, 12, - -1, -1, -1, 16, -1, 18, 19, 20, 21, 22, - 23, 24, -1, 26, -1, -1, 29, 30, 31, 32, - 33, 34, 35, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 45, -1, -1, 48, 49, 50, 51, 52, - 53, 54, 55, 56, 57, -1, 59, 60, -1, 62, - 63, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 82, - -1, -1, 85, 86, -1, 88, 89, -1, 91, 92, - 93, 94, 95, 96, 97, 98, -1, -1, -1, -1, - -1, -1, -1, 3, 4, 5, -1, 7, -1, -1, - -1, 11, 12, 116, 117, 118, 16, 120, 18, 19, - 20, 21, 22, 23, 24, 128, 26, -1, -1, 29, - 30, 31, 32, 33, 34, 35, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 45, -1, -1, 48, 49, - 50, 51, 52, 53, 54, 55, 56, 57, -1, 59, - 60, -1, 62, 63, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 82, -1, -1, 85, 86, -1, 88, 89, - -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, - -1, -1, -1, -1, -1, -1, 3, 4, 5, -1, - 7, -1, -1, -1, 11, 12, 116, 117, 118, 16, - 120, 18, 19, 20, 21, 22, 23, 24, 128, 26, - -1, -1, 29, 30, 31, 32, 33, 34, 35, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 45, -1, - -1, 48, 49, 50, 51, 52, 53, 54, 55, 56, - 57, -1, 59, 60, -1, 62, 63, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 82, -1, -1, 85, 86, - -1, 88, 89, -1, 91, 92, 93, 94, 95, 96, - 97, 98, -1, -1, -1, -1, -1, -1, -1, 3, - 4, 5, -1, 7, -1, -1, -1, 11, 12, 116, - 117, 118, 16, 120, 18, 19, 20, 21, 22, 23, - 24, 128, -1, -1, -1, 29, 30, 31, 32, 33, - 34, 35, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 45, -1, -1, 48, 49, 50, 51, 52, 53, - 54, 55, 56, 57, -1, 59, 60, -1, 62, 63, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 82, 83, - -1, 85, 86, -1, 88, 89, -1, 91, 92, 93, - 94, 95, 96, 97, 98, -1, -1, -1, -1, 103, - -1, -1, 3, 4, 5, -1, 7, -1, -1, -1, - 11, 12, 116, 117, 118, 16, -1, 18, 19, 20, - 21, 22, 23, 24, 128, -1, -1, -1, 29, 30, - 31, 32, 33, 34, 35, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 45, -1, -1, 48, 49, 50, - 51, 52, 53, 54, 55, 56, 57, -1, 59, 60, - -1, 62, 63, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 82, 83, -1, 85, 86, -1, 88, 89, -1, - 91, 92, 93, 94, 95, 96, 97, 98, -1, -1, - -1, -1, 103, -1, -1, 3, 4, 5, -1, 7, - -1, -1, -1, 11, 12, 116, 117, 118, 16, -1, - 18, 19, 20, 21, 22, 23, 24, 128, -1, -1, - -1, 29, 30, 31, 32, 33, 34, 35, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 45, -1, -1, - 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, - -1, 59, 60, -1, 62, 63, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 82, -1, -1, 85, 86, -1, - 88, 89, -1, 91, 92, 93, 94, 95, 96, 97, - 98, -1, -1, -1, -1, -1, -1, -1, 3, 4, - 5, -1, 7, -1, -1, -1, 11, 12, 116, 117, - 118, 16, -1, 18, 19, 20, 21, 22, 23, 24, - 128, -1, -1, -1, 29, 30, 31, 32, 33, 34, - 35, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 45, -1, -1, 48, 49, 50, 51, 52, 53, 54, - 55, 56, 57, -1, 59, 60, -1, 62, 63, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 82, -1, -1, - 85, 86, -1, 88, 89, -1, 91, 92, 93, 94, - 95, 96, 97, 98, -1, -1, -1, -1, -1, -1, - -1, 3, 4, 5, -1, 7, -1, -1, -1, 11, - 12, 116, 117, 118, 16, -1, 18, 19, 20, 21, - 22, 23, 24, 128, -1, -1, -1, 29, 30, 31, - 32, 33, 34, 35, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 45, -1, -1, 48, 49, 50, 51, - 52, 53, 54, 55, 56, 57, -1, 59, 60, -1, - 62, 63, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 82, -1, -1, 85, 86, -1, 88, 89, -1, 91, - 92, 93, 94, 95, 96, 97, 98, -1, -1, -1, - -1, -1, -1, -1, 3, 4, 5, -1, 7, -1, - -1, -1, 11, 12, 116, 117, 118, 16, -1, 18, - 19, 20, 21, 22, 23, 24, 128, -1, -1, -1, - 29, 30, 31, 32, 33, 34, 35, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 45, -1, -1, 48, - 49, 50, 51, 52, 53, 54, 55, 56, 57, -1, - 59, 60, -1, 62, 63, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 82, -1, -1, 85, 86, -1, 88, - 89, -1, 91, 92, 93, 94, 95, 96, 97, 98, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 116, 117, 118, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 128, - 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, - 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, - 23, 24, 25, 26, -1, -1, 29, 30, 31, 32, - 33, 34, 35, 36, 37, 38, -1, -1, -1, -1, - -1, 44, 45, 46, 47, 48, 49, 50, 51, 52, - 53, 54, 55, -1, -1, -1, -1, -1, -1, 62, - 63, 64, 65, 66, 67, -1, 69, 70, -1, -1, - 73, -1, -1, -1, 77, 78, 79, 80, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 91, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 106, 107, 108, 109, 110, 111, 112, - 113, 114, 115, -1, -1, 118, -1, -1, -1, -1, - -1, -1, -1, -1, 127, 3, 4, 5, 6, 7, - 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, - 18, 19, 20, 21, 22, 23, 24, 25, 26, -1, - -1, 29, 30, 31, 32, 33, 34, 35, 36, 37, - 38, -1, -1, -1, -1, -1, 44, 45, 46, 47, - 48, 49, 50, 51, 52, -1, 54, -1, -1, -1, - -1, -1, -1, -1, 62, 63, 64, 65, 66, 67, - -1, 69, 70, -1, -1, 73, -1, -1, -1, 77, - 78, 79, 80, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 91, -1, 93, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 106, 107, - 108, 109, 110, 111, 112, 113, 114, 115, -1, -1, - 118, -1, -1, -1, -1, -1, -1, -1, -1, 127, - 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, - 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, - 23, 24, 25, 26, -1, -1, 29, 30, 31, 32, - 33, 34, 35, 36, 37, 38, -1, -1, -1, -1, - -1, 44, 45, 46, 47, 48, 49, 50, 51, -1, - -1, 54, -1, -1, -1, -1, -1, -1, -1, 62, - 63, 64, 65, 66, 67, -1, 69, 70, -1, -1, - 73, -1, -1, -1, 77, 78, 79, 80, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 91, -1, - 93, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 106, 107, 108, 109, 110, 111, 112, - 113, 114, 115, -1, -1, 118, -1, -1, -1, -1, - -1, -1, -1, -1, 127, 3, 4, 5, 6, 7, - 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, - 18, 19, 20, 21, 22, 23, 24, 25, 26, -1, - -1, 29, 30, 31, 32, 33, 34, 35, 36, 37, - 38, -1, -1, -1, -1, -1, 44, 45, 46, 47, - 48, 49, 50, 51, -1, -1, 54, -1, -1, -1, - -1, -1, -1, -1, 62, 63, 64, 65, 66, 67, - -1, 69, 70, -1, -1, 73, -1, -1, -1, 77, - 78, 79, 80, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 91, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 106, 107, - 108, 109, 110, 111, 112, 113, 114, 115, -1, -1, - 118, -1, 3, 4, 5, -1, 7, -1, -1, 127, - 11, 12, -1, -1, -1, 16, -1, 18, 19, 20, - 21, 22, 23, 24, -1, -1, -1, -1, 29, 30, - 31, 32, 33, 34, 35, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 45, -1, -1, 48, 49, 50, - 51, 52, 53, 54, 55, 56, 57, -1, 59, 60, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 82, -1, -1, 85, 86, -1, 88, 89, -1, - -1, -1, 93, 94, 95, 96, 97, 98, -1, -1, - -1, 3, 4, 5, -1, 7, -1, -1, -1, 11, - 12, -1, -1, -1, 16, 116, 18, 19, 20, 21, - 22, 23, 24, -1, -1, 126, -1, 29, 30, 31, - 32, 33, 34, 35, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 45, -1, -1, 48, 49, 50, 51, - 52, 53, 54, 55, 56, 57, -1, 59, 60, -1, - 62, 63, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 82, -1, -1, 85, 86, -1, 88, 89, -1, 91, - 92, 93, 94, 95, 96, 97, 98, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 3, - 4, 5, 6, 7, 116, 117, 118, 11, 12, -1, - -1, -1, 16, 125, 18, 19, 20, 21, 22, 23, - 24, -1, -1, -1, -1, 29, 30, 31, 32, 33, - 34, 35, -1, -1, 38, -1, -1, -1, -1, -1, - 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, - 54, 55, 56, 57, -1, 59, 60, -1, 62, 63, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 82, -1, - -1, 85, 86, -1, 88, 89, -1, 91, -1, 93, - 94, 95, 96, 97, 98, -1, -1, -1, -1, -1, - -1, -1, 3, 4, 5, -1, 7, -1, -1, -1, - 11, 12, 116, 117, 118, 16, -1, 18, 19, 20, - 21, 22, 23, 24, -1, -1, -1, -1, 29, 30, - 31, 32, 33, 34, 35, -1, -1, 38, -1, -1, - -1, -1, -1, -1, 45, -1, -1, 48, 49, 50, - 51, 52, 53, 54, 55, 56, 57, -1, 59, 60, - -1, 62, 63, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 82, -1, -1, 85, 86, -1, 88, 89, -1, - 91, 92, 93, 94, 95, 96, 97, 98, -1, -1, - -1, -1, -1, -1, -1, 3, 4, 5, -1, 7, - -1, -1, -1, 11, 12, 116, 117, 118, 16, -1, - 18, 19, 20, 21, 22, 23, 24, -1, -1, -1, - -1, 29, 30, 31, 32, 33, 34, 35, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 45, -1, -1, - 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, - -1, 59, 60, -1, 62, 63, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 82, -1, -1, 85, 86, -1, - 88, 89, -1, 91, 92, 93, 94, 95, 96, 97, - 98, -1, -1, -1, -1, -1, -1, -1, 3, 4, - 5, -1, 7, -1, -1, -1, 11, 12, 116, 117, - 118, 16, -1, 18, 19, 20, 21, 22, 23, 24, - -1, -1, -1, -1, 29, 30, 31, 32, 33, 34, - 35, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 45, -1, -1, 48, 49, 50, 51, 52, 53, 54, - 55, 56, 57, -1, 59, 60, -1, 62, 63, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 82, -1, -1, - 85, 86, -1, 88, 89, -1, 91, 92, 93, 94, - 95, 96, 97, 98, -1, -1, -1, -1, -1, -1, - -1, 3, 4, 5, -1, 7, -1, -1, -1, 11, - 12, 116, 117, 118, 16, -1, 18, 19, 20, 21, - 22, 23, 24, -1, -1, -1, -1, 29, 30, 31, - 32, 33, 34, 35, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 45, -1, -1, 48, 49, 50, 51, - 52, 53, 54, 55, 56, 57, -1, 59, 60, -1, - 62, 63, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 82, -1, -1, 85, 86, -1, 88, 89, -1, 91, - 92, 93, 94, 95, 96, 97, 98, -1, -1, -1, - -1, -1, -1, -1, 3, 4, 5, -1, 7, -1, - -1, -1, 11, 12, 116, 117, 118, 16, -1, 18, - 19, 20, 21, 22, 23, 24, -1, -1, -1, -1, - 29, 30, 31, 32, 33, 34, 35, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 45, -1, -1, 48, - 49, 50, 51, 52, 53, 54, 55, 56, 57, -1, - 59, 60, -1, 62, 63, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 82, -1, -1, 85, 86, -1, 88, - 89, -1, 91, 92, 93, 94, 95, 96, 97, 98, - -1, -1, -1, -1, -1, -1, -1, 3, 4, 5, - -1, 7, -1, -1, -1, 11, 12, 116, 117, 118, - 16, -1, 18, 19, 20, 21, 22, 23, 24, -1, - -1, -1, -1, 29, 30, 31, 32, 33, 34, 35, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 45, - -1, -1, 48, 49, 50, 51, 52, 53, 54, 55, - 56, 57, -1, 59, 60, -1, 62, 63, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 82, -1, -1, 85, - 86, -1, 88, 89, -1, 91, 92, 93, 94, 95, - 96, 97, 98, -1, -1, -1, -1, -1, -1, -1, - 3, 4, 5, -1, 7, -1, -1, -1, 11, 12, - 116, 117, 118, 16, -1, 18, 19, 20, 21, 22, - 23, 24, -1, -1, -1, -1, 29, 30, 31, 32, - 33, 34, 35, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 45, -1, -1, 48, 49, 50, 51, 52, - 53, 54, 55, 56, 57, -1, 59, 60, -1, 62, - 63, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 82, - -1, -1, 85, 86, -1, 88, 89, -1, 91, 92, - 93, 94, 95, 96, 97, 98, -1, -1, -1, -1, - -1, -1, -1, 3, 4, 5, -1, 7, -1, -1, - -1, 11, 12, 116, 117, 118, 16, -1, 18, 19, - 20, 21, 22, 23, 24, -1, -1, -1, -1, 29, - 30, 31, 32, 33, 34, 35, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 45, -1, -1, 48, 49, - 50, 51, 52, 53, 54, 55, 56, 57, -1, 59, - 60, -1, 62, 63, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 82, -1, -1, 85, 86, -1, 88, 89, - -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, - -1, -1, -1, -1, -1, -1, 3, 4, 5, -1, - 7, -1, -1, -1, 11, 12, 116, 117, 118, 16, - -1, 18, 19, 20, 21, 22, 23, 24, -1, -1, - -1, -1, 29, 30, 31, 32, 33, 34, 35, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 45, -1, - -1, 48, 49, 50, 51, 52, 53, 54, 55, 56, - 57, -1, 59, 60, -1, 62, 63, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 82, -1, -1, 85, 86, - -1, 88, 89, -1, 91, 92, 93, 94, 95, 96, - 97, 98, -1, -1, -1, -1, -1, -1, -1, 3, - 4, 5, -1, 7, -1, -1, -1, 11, 12, 116, - 117, 118, 16, -1, 18, 19, 20, 21, 22, 23, - 24, -1, -1, -1, -1, 29, 30, 31, 32, 33, - 34, 35, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 45, -1, -1, 48, 49, 50, 51, 52, 53, - 54, 55, 56, 57, -1, 59, 60, -1, 62, 63, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 82, -1, - -1, 85, 86, -1, 88, 89, -1, 91, 92, 93, - 94, 95, 96, 97, 98, -1, -1, -1, -1, -1, - -1, -1, 3, 4, 5, -1, 7, -1, -1, -1, - 11, 12, 116, 117, 118, 16, -1, 18, 19, 20, - 21, 22, 23, 24, -1, -1, -1, -1, 29, 30, - 31, 32, 33, 34, 35, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 45, -1, -1, 48, 49, 50, - 51, 52, 53, 54, 55, 56, 57, -1, 59, 60, - -1, 62, 63, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 82, -1, -1, 85, 86, -1, 88, 89, -1, - 91, 92, 93, 94, 95, 96, 97, 98, -1, -1, - -1, -1, -1, -1, -1, 3, 4, 5, -1, 7, - -1, -1, -1, 11, 12, 116, 117, 118, 16, -1, - 18, 19, 20, 21, 22, 23, 24, -1, -1, -1, - -1, 29, 30, 31, 32, 33, 34, 35, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 45, -1, -1, - 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, - -1, 59, 60, -1, 62, 63, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 82, -1, -1, 85, 86, -1, - 88, 89, -1, 91, 92, 93, 94, 95, 96, 97, - 98, -1, -1, -1, -1, -1, -1, -1, 3, 4, - 5, -1, 7, -1, -1, -1, 11, 12, 116, 117, - 118, 16, -1, 18, 19, 20, 21, 22, 23, 24, - -1, -1, -1, -1, 29, 30, 31, 32, 33, 34, - 35, -1, -1, 38, -1, -1, -1, -1, -1, -1, - 45, -1, -1, 48, 49, 50, 51, 52, 53, 54, - 55, 56, 57, -1, 59, 60, -1, 62, 63, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 82, -1, -1, - 85, 86, -1, 88, 89, -1, -1, -1, 93, 94, - 95, 96, 97, 98, -1, -1, -1, -1, -1, -1, - -1, 3, 4, 5, -1, 7, -1, -1, -1, 11, - 12, 116, 117, 118, 16, -1, 18, 19, 20, 21, - 22, 23, 24, -1, -1, -1, -1, 29, 30, 31, - 32, 33, 34, 35, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 45, -1, -1, 48, 49, 50, 51, - 52, 53, 54, 55, 56, 57, -1, 59, 60, -1, - 62, 63, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 82, -1, -1, 85, 86, -1, 88, 89, -1, 91, - -1, 93, 94, 95, 96, 97, 98, -1, -1, -1, - -1, -1, -1, -1, 3, 4, 5, -1, 7, -1, - -1, -1, 11, 12, 116, 117, 118, 16, -1, 18, - 19, 20, 21, 22, 23, 24, -1, -1, -1, -1, - 29, 30, 31, 32, 33, 34, 35, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 45, -1, -1, 48, - 49, 50, 51, 52, 53, 54, 55, 56, 57, -1, - 59, 60, -1, 62, 63, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 82, -1, -1, 85, 86, -1, 88, - 89, -1, 91, -1, 93, 94, 95, 96, 97, 98, - -1, -1, -1, -1, -1, -1, -1, 3, 4, 5, - -1, 7, -1, -1, -1, 11, 12, 116, 117, 118, - 16, -1, 18, 19, 20, 21, 22, 23, 24, -1, - -1, -1, -1, 29, 30, 31, 32, 33, 34, 35, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 45, - -1, -1, 48, 49, 50, 51, 52, 53, 54, 55, - 56, 57, -1, 59, 60, -1, 62, 63, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 82, -1, -1, 85, - 86, -1, 88, 89, -1, 91, -1, 93, 94, 95, - 96, 97, 98, -1, -1, -1, -1, -1, -1, -1, - 3, 4, 5, -1, 7, -1, -1, -1, 11, 12, - 116, 117, 118, 16, -1, 18, 19, 20, 21, 22, - 23, 24, -1, -1, -1, -1, 29, 30, 31, 32, - 33, 34, 35, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 45, -1, -1, 48, 49, 50, 51, 52, - 53, 54, 55, 56, 57, -1, 59, 60, -1, 62, - 63, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 82, - -1, -1, 85, 86, -1, 88, 89, -1, 91, -1, - 93, 94, 95, 96, 97, 98, -1, -1, -1, -1, - -1, -1, -1, 3, 4, 5, -1, 7, -1, -1, - -1, 11, 12, 116, 117, 118, 16, -1, 18, 19, - 20, 21, 22, 23, 24, -1, -1, -1, -1, 29, - 30, 31, 32, 33, 34, 35, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 45, -1, -1, 48, 49, - 50, 51, 52, 53, 54, 55, 56, 57, -1, 59, - 60, -1, 62, 63, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 82, -1, -1, 85, 86, -1, 88, 89, - -1, 91, -1, 93, 94, 95, 96, 97, 98, -1, - -1, -1, -1, -1, -1, -1, 3, 4, 5, -1, - 7, -1, -1, -1, 11, 12, 116, 117, 118, 16, - -1, 18, 19, 20, 21, 22, 23, 24, -1, -1, - -1, -1, 29, 30, 31, 32, 33, 34, 35, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 45, -1, - -1, 48, 49, 50, 51, 52, 53, 54, 55, 56, - 57, -1, 59, 60, -1, 62, 63, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 82, -1, -1, 85, 86, - -1, 88, 89, -1, 91, -1, 93, 94, 95, 96, - 97, 98, -1, -1, -1, -1, -1, -1, -1, 3, - 4, 5, -1, 7, -1, -1, -1, 11, 12, 116, - 117, 118, 16, -1, 18, 19, 20, 21, 22, 23, - 24, -1, -1, -1, -1, 29, 30, 31, 32, 33, - 34, 35, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 45, -1, -1, 48, 49, 50, 51, 52, 53, - 54, 55, 56, 57, -1, 59, 60, -1, 62, 63, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 82, -1, - -1, 85, 86, -1, 88, 89, -1, 91, -1, 93, - 94, 95, 96, 97, 98, -1, -1, -1, -1, -1, - -1, -1, 3, 4, 5, -1, 7, -1, -1, -1, - 11, 12, 116, 117, 118, 16, -1, 18, 19, 20, - 21, 22, 23, 24, -1, -1, -1, -1, 29, 30, - 31, 32, 33, 34, 35, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 45, -1, -1, 48, 49, 50, - 51, 52, 53, 54, 55, 56, 57, -1, 59, 60, - -1, 62, 63, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 82, -1, -1, 85, 86, -1, 88, 89, -1, - -1, -1, 93, 94, 95, 96, 97, 98, -1, -1, - -1, -1, -1, -1, -1, 3, 4, 5, -1, 7, - -1, -1, -1, 11, 12, 116, 117, 118, 16, -1, - 18, 19, 20, 21, 22, 23, 24, -1, -1, -1, - -1, 29, 30, 31, 32, 33, 34, 35, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 45, -1, -1, - 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, - -1, 59, 60, -1, 62, 63, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 82, -1, -1, 85, 86, -1, - 88, 89, -1, -1, -1, 93, 94, 95, 96, 97, - 98, -1, -1, -1, -1, -1, -1, -1, 3, 4, - 5, -1, 7, -1, -1, -1, 11, 12, 116, 117, - 118, 16, -1, 18, 19, 20, 21, 22, 23, 24, - -1, -1, -1, -1, 29, 30, 31, 32, 33, 34, - 35, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 45, -1, -1, 48, 49, 50, 51, 52, 53, 54, - 55, 56, 57, -1, 59, 60, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 82, -1, -1, - 85, 86, -1, 88, 89, -1, 91, 92, 93, 94, - 95, 96, 97, 98, -1, -1, -1, 3, 4, 5, - -1, 7, -1, -1, -1, 11, 12, -1, -1, -1, - 16, 116, 18, 19, 20, 21, 22, 23, 24, -1, - -1, -1, -1, 29, 30, 31, 32, 33, 34, 35, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 45, - -1, -1, 48, 49, 50, 51, 52, 53, 54, 55, - 56, 57, -1, 59, 60, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 79, -1, -1, 82, -1, -1, 85, - 86, -1, 88, 89, -1, -1, -1, 93, 94, 95, - 96, 97, 98, -1, -1, -1, 3, 4, 5, -1, - 7, -1, -1, -1, 11, 12, -1, -1, -1, 16, - 116, 18, 19, 20, 21, 22, 23, 24, -1, -1, - -1, -1, 29, 30, 31, 32, 33, 34, 35, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 45, -1, - -1, 48, 49, 50, 51, 52, 53, 54, 55, 56, - 57, -1, 59, 60, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 82, -1, -1, 85, 86, - -1, 88, 89, -1, 91, -1, 93, 94, 95, 96, - 97, 98, -1, -1, -1, 3, 4, 5, -1, 7, - -1, -1, -1, 11, 12, -1, -1, -1, 16, 116, - 18, 19, 20, 21, 22, 23, 24, -1, -1, -1, - -1, 29, 30, 31, 32, 33, 34, 35, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 45, -1, -1, - 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, - -1, 59, 60, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 82, -1, -1, 85, 86, -1, - 88, 89, -1, 91, -1, 93, 94, 95, 96, 97, - 98, -1, -1, -1, 3, 4, 5, -1, 7, -1, - -1, -1, 11, 12, -1, -1, -1, 16, 116, 18, - 19, 20, 21, 22, 23, 24, -1, -1, -1, -1, - 29, 30, 31, 32, 33, 34, 35, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 45, -1, -1, 48, - 49, 50, 51, 52, 53, 54, 55, 56, 57, -1, - 59, 60, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 82, -1, -1, 85, 86, -1, 88, - 89, -1, -1, -1, 93, 94, 95, 96, 97, 98, - -1, -1, -1, 3, 4, 5, -1, 7, -1, -1, - -1, 11, 12, -1, -1, -1, 16, 116, 18, 19, - 20, 21, 22, 23, 24, -1, -1, -1, -1, 29, - 30, 31, 32, 33, 34, 35, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 45, -1, -1, 48, 49, - 50, 51, 52, 53, 54, 55, 56, 57, -1, 59, - 60, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 82, -1, -1, 85, 86, -1, 88, 89, - -1, -1, -1, 93, 94, 95, 96, 97, 98, -1, - -1, -1, 3, 4, 5, -1, 7, -1, -1, -1, - 11, 12, -1, -1, -1, 16, 116, 18, 19, 20, - 21, 22, 23, 24, -1, -1, -1, -1, 29, 30, - 31, 32, 33, 34, 35, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 45, -1, -1, 48, 49, 50, - 51, 52, 53, 54, 55, 56, 57, -1, 59, 60, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 82, -1, -1, 85, 86, -1, 88, 89, -1, - -1, -1, 93, 94, 95, 96, 97, 98, -1, -1, - -1, -1, -1, -1, 50, 51, -1, -1, 54, -1, - -1, -1, -1, -1, -1, 116, 62, 63, 64, 65, - 66, 67, -1, 69, 70, -1, -1, 73, -1, -1, - -1, 77, 78, 79, 80, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 91, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, - 50, 51, 118, -1, 54, -1, -1, -1, -1, -1, - -1, 127, 62, 63, 64, 65, 66, 67, -1, 69, - 70, -1, -1, 73, -1, -1, -1, 77, 78, 79, - 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 91, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 106, 107, 108, 109, - 110, 111, 112, 113, 114, 115, 50, 51, 118, -1, - 54, -1, -1, -1, -1, -1, -1, 127, 62, 63, - 64, 65, 66, 67, -1, 69, 70, -1, -1, 73, - -1, -1, -1, 77, 78, 79, 80, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 91, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 106, 107, 108, 109, 110, 111, 112, 113, - 114, 115, 50, 51, 118, -1, 54, -1, -1, -1, - -1, -1, -1, 127, 62, 63, 64, 65, 66, 67, - -1, 69, 70, -1, -1, 73, -1, -1, -1, 77, - 78, 79, 80, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 91, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 106, 107, - 108, 109, 110, 111, 112, 113, 114, 115, 50, 51, - 118, -1, 54, -1, -1, -1, -1, -1, -1, 127, - 62, 63, 64, 65, 66, 67, -1, 69, 70, -1, - -1, 73, -1, -1, -1, 77, 78, 79, 80, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 106, 107, 108, 109, 110, 111, - 112, 113, 114, 115, 50, 51, 118, -1, 54, -1, - -1, -1, -1, -1, -1, 127, 62, 63, 64, 65, - 66, 67, -1, 69, 70, -1, -1, 73, -1, -1, - -1, 77, 78, 79, 80, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 91, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, - 50, 51, 118, -1, 54, -1, -1, -1, -1, -1, - -1, 127, 62, 63, 64, 65, 66, 67, -1, 69, - 70, -1, -1, 73, -1, -1, -1, 77, 78, 79, - 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 91, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 106, 107, 108, 109, - 110, 111, 112, 113, 114, 115, 50, 51, 118, -1, - 54, -1, -1, -1, -1, -1, -1, 127, 62, 63, - 64, 65, 66, 67, -1, 69, 70, -1, -1, 73, - -1, -1, -1, 77, 78, 79, 80, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 91, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 106, 107, 108, 109, 110, 111, 112, 113, - 114, 115, 50, 51, 118, -1, 54, -1, -1, -1, - -1, -1, -1, 127, 62, 63, 64, 65, 66, 67, - -1, 69, 70, -1, -1, 73, -1, -1, -1, 77, - 78, 79, 80, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 91, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 106, 107, - 108, 109, 110, 111, 112, 113, 114, 115, 50, 51, - 118, -1, 54, -1, -1, -1, -1, -1, -1, 127, - 62, 63, 64, 65, 66, 67, -1, 69, 70, -1, - -1, 73, -1, -1, -1, 77, 78, 79, 80, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 106, 107, 108, 109, 110, 111, - 112, 113, 114, 115, 50, 51, 118, -1, 54, -1, - -1, -1, -1, -1, -1, 127, 62, 63, 64, 65, - 66, 67, -1, 69, 70, -1, -1, 73, -1, -1, - -1, 77, 78, 79, 80, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 91, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, - 50, 51, 118, -1, 54, -1, -1, -1, -1, -1, - -1, 127, 62, 63, 64, 65, 66, 67, -1, 69, - 70, -1, -1, 73, -1, -1, -1, 77, 78, 79, - 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 91, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 106, 107, 108, 109, - 110, 111, 112, 113, 114, 115, -1, -1, 118, -1, - -1, -1, -1, -1, -1, -1, -1, 127, 64, 65, - 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, - 76, -1, -1, 79, 80, -1, -1, -1, 84, 64, - 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, - 75, 76, -1, -1, 79, 80, -1, -1, 104, -1, - 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 104, - 126, 106, 107, 108, 109, 110, 111, 112, 113, 114, - 115, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 126, 64, 65, 66, 67, 68, 69, 70, 71, - 72, 73, 74, 75, 76, -1, -1, 79, 80, 64, - 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, - 75, 76, -1, -1, 79, 80, -1, -1, -1, -1, - -1, -1, 104, -1, 106, 107, 108, 109, 110, 111, - 112, 113, 114, 115, -1, -1, -1, -1, -1, -1, - -1, 106, 107, 108, 109, 110, 111, 112, 113, 114, - 115, 64, 65, 66, 67, 68, 69, 70, -1, -1, - 73, 74, -1, -1, -1, -1, 79, 80, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 106, 107, 108, 109, 110, 111, 112, - 113, 114, 115 -}; - -/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing - symbol of state STATE-NUM. */ -static const yytype_uint16 yystos[] = -{ - 0, 133, 134, 0, 1, 3, 4, 5, 6, 7, - 11, 12, 16, 18, 19, 20, 21, 22, 23, 24, - 29, 30, 31, 32, 33, 34, 35, 38, 44, 45, - 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, - 56, 57, 59, 60, 62, 63, 82, 85, 86, 88, - 89, 91, 93, 94, 95, 96, 97, 98, 116, 117, - 118, 136, 137, 138, 141, 143, 144, 148, 149, 151, - 152, 153, 154, 155, 165, 182, 199, 211, 212, 225, - 226, 227, 228, 229, 230, 231, 234, 242, 244, 245, - 246, 247, 248, 249, 268, 277, 138, 21, 22, 29, - 30, 31, 45, 50, 54, 79, 82, 85, 116, 156, - 157, 182, 199, 246, 249, 268, 157, 3, 4, 5, - 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, - 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, - 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, - 38, 44, 45, 46, 47, 48, 49, 50, 51, 54, - 62, 63, 64, 65, 66, 67, 69, 70, 73, 77, - 78, 79, 80, 91, 106, 107, 108, 109, 110, 111, - 112, 113, 114, 115, 118, 127, 128, 158, 163, 164, - 247, 263, 32, 33, 34, 35, 48, 49, 50, 54, - 158, 159, 160, 161, 242, 244, 183, 82, 141, 142, - 155, 199, 246, 248, 249, 142, 130, 131, 142, 272, - 275, 276, 186, 188, 82, 149, 155, 199, 204, 246, - 249, 91, 92, 117, 148, 165, 167, 171, 178, 180, - 266, 267, 171, 171, 128, 173, 174, 128, 169, 173, - 141, 52, 160, 130, 273, 140, 120, 165, 199, 165, - 54, 85, 136, 150, 151, 141, 91, 148, 168, 180, - 266, 277, 180, 265, 266, 277, 82, 154, 199, 246, - 249, 52, 53, 55, 158, 237, 243, 236, 237, 237, - 129, 232, 129, 235, 56, 57, 143, 165, 165, 272, - 276, 39, 40, 41, 42, 43, 36, 37, 28, 208, - 103, 126, 85, 91, 152, 103, 64, 65, 66, 67, - 68, 69, 70, 71, 72, 73, 74, 75, 76, 79, - 80, 104, 106, 107, 108, 109, 110, 111, 112, 113, - 114, 115, 81, 122, 124, 81, 124, 26, 120, 213, - 228, 83, 83, 169, 173, 213, 273, 141, 50, 54, - 156, 56, 57, 1, 107, 250, 275, 81, 122, 124, - 195, 264, 196, 81, 124, 271, 126, 135, 136, 54, - 13, 105, 200, 275, 103, 81, 122, 124, 83, 83, - 200, 272, 15, 17, 218, 131, 142, 142, 54, 81, - 122, 124, 25, 167, 167, 84, 126, 179, 277, 126, - 179, 125, 171, 86, 171, 175, 148, 171, 180, 211, - 277, 52, 59, 60, 139, 128, 166, 120, 136, 81, - 124, 83, 150, 125, 125, 184, 165, 273, 123, 126, - 130, 274, 126, 274, 126, 274, 121, 274, 54, 81, - 122, 124, 58, 99, 100, 101, 238, 101, 238, 101, - 61, 101, 101, 233, 238, 101, 58, 101, 64, 64, - 138, 142, 142, 142, 142, 138, 141, 141, 209, 91, - 143, 167, 180, 181, 150, 154, 126, 143, 165, 167, - 181, 165, 165, 165, 165, 165, 165, 165, 165, 165, - 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, - 165, 165, 165, 165, 165, 165, 165, 50, 51, 54, - 163, 269, 270, 168, 50, 51, 54, 163, 269, 50, - 54, 269, 269, 216, 214, 143, 165, 143, 165, 90, - 145, 193, 275, 251, 192, 50, 54, 156, 269, 168, - 269, 135, 141, 50, 52, 53, 54, 55, 91, 92, - 110, 113, 128, 252, 253, 254, 255, 256, 257, 258, - 259, 260, 261, 197, 162, 10, 8, 221, 277, 136, - 13, 165, 50, 54, 168, 50, 54, 136, 218, 136, - 91, 180, 219, 10, 27, 105, 201, 275, 201, 50, - 54, 168, 50, 54, 190, 126, 179, 167, 91, 167, - 178, 266, 91, 167, 267, 125, 91, 165, 167, 172, - 176, 178, 266, 273, 126, 81, 124, 273, 125, 160, - 185, 165, 136, 121, 165, 125, 273, 273, 91, 167, - 50, 54, 168, 50, 54, 240, 239, 129, 238, 129, - 165, 165, 72, 108, 207, 277, 167, 126, 125, 43, - 105, 83, 83, 169, 173, 123, 83, 83, 169, 170, - 173, 277, 170, 173, 170, 173, 207, 207, 146, 275, - 142, 135, 123, 10, 273, 103, 253, 135, 275, 126, - 262, 277, 126, 262, 50, 126, 262, 50, 158, 160, - 167, 181, 222, 277, 15, 203, 277, 14, 202, 203, - 83, 123, 83, 83, 203, 10, 10, 167, 126, 200, - 187, 189, 123, 142, 167, 126, 179, 167, 167, 126, - 177, 125, 126, 179, 125, 148, 211, 269, 269, 125, - 141, 121, 125, 165, 123, 136, 52, 53, 55, 241, - 249, 91, 92, 108, 152, 205, 206, 210, 91, 167, - 165, 165, 143, 165, 165, 145, 83, 143, 165, 143, - 165, 145, 217, 215, 207, 194, 275, 10, 125, 167, - 273, 10, 254, 257, 259, 261, 50, 256, 259, 198, - 84, 223, 277, 136, 9, 224, 277, 142, 10, 83, - 10, 91, 136, 136, 136, 201, 179, 91, 179, 179, - 91, 178, 180, 266, 125, 91, 273, 125, 273, 121, - 82, 126, 155, 199, 246, 249, 155, 126, 108, 136, - 167, 143, 165, 136, 136, 147, 135, 125, 126, 262, - 262, 262, 252, 155, 200, 136, 200, 167, 203, 218, - 220, 10, 10, 191, 165, 167, 126, 179, 126, 179, - 167, 125, 54, 92, 126, 81, 122, 124, 91, 92, - 152, 10, 10, 121, 136, 10, 259, 135, 136, 136, - 136, 179, 179, 91, 266, 91, 179, 155, 92, 50, - 54, 168, 50, 54, 126, 155, 155, 121, 262, 10, - 221, 202, 10, 167, 126, 179, 167, 155, 123, 92, - 126, 179, 91, 179, 155, 92, 167, 155, 179 -}; - -#define yyerrok (yyerrstatus = 0) -#define yyclearin (yychar = YYEMPTY) -#define YYEMPTY (-2) -#define YYEOF 0 - -#define YYACCEPT goto yyacceptlab -#define YYABORT goto yyabortlab -#define YYERROR goto yyerrorlab - - -/* Like YYERROR except do call yyerror. This remains here temporarily - to ease the transition to the new meaning of YYERROR, for GCC. - Once GCC version 2 has supplanted version 1, this can go. */ - -#define YYFAIL goto yyerrlab - -#define YYRECOVERING() (!!yyerrstatus) - -#define YYBACKUP(Token, Value) \ -do \ - if (yychar == YYEMPTY && yylen == 1) \ - { \ - yychar = (Token); \ - yylval = (Value); \ - yytoken = YYTRANSLATE (yychar); \ - YYPOPSTACK (1); \ - goto yybackup; \ - } \ - else \ - { \ - yyerror (YY_("syntax error: cannot back up")); \ - YYERROR; \ - } \ -while (YYID (0)) - - -#define YYTERROR 1 -#define YYERRCODE 256 - - -/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N]. - If N is 0, then set CURRENT to the empty location which ends - the previous symbol: RHS[0] (always defined). */ - -#define YYRHSLOC(Rhs, K) ((Rhs)[K]) -#ifndef YYLLOC_DEFAULT -# define YYLLOC_DEFAULT(Current, Rhs, N) \ - do \ - if (YYID (N)) \ - { \ - (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ - (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ - (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ - (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ - } \ - else \ - { \ - (Current).first_line = (Current).last_line = \ - YYRHSLOC (Rhs, 0).last_line; \ - (Current).first_column = (Current).last_column = \ - YYRHSLOC (Rhs, 0).last_column; \ - } \ - while (YYID (0)) -#endif - - -/* YY_LOCATION_PRINT -- Print the location on the stream. - This macro was not mandated originally: define only if we know - we won't break user code: when these are the locations we know. */ - -#ifndef YY_LOCATION_PRINT -# if YYLTYPE_IS_TRIVIAL -# define YY_LOCATION_PRINT(File, Loc) \ - fprintf (File, "%d.%d-%d.%d", \ - (Loc).first_line, (Loc).first_column, \ - (Loc).last_line, (Loc).last_column) -# else -# define YY_LOCATION_PRINT(File, Loc) ((void) 0) -# endif -#endif - - -/* YYLEX -- calling `yylex' with the right arguments. */ - -#ifdef YYLEX_PARAM -# define YYLEX yylex (YYLEX_PARAM) -#else -# define YYLEX yylex () -#endif - -/* Enable debugging if requested. */ -#if YYDEBUG - -# ifndef YYFPRINTF -# include /* INFRINGES ON USER NAME SPACE */ -# define YYFPRINTF fprintf -# endif - -# define YYDPRINTF(Args) \ -do { \ - if (yydebug) \ - YYFPRINTF Args; \ -} while (YYID (0)) - -# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ -do { \ - if (yydebug) \ - { \ - YYFPRINTF (stderr, "%s ", Title); \ - yy_symbol_print (stderr, \ - Type, Value); \ - YYFPRINTF (stderr, "\n"); \ - } \ -} while (YYID (0)) - - -/*--------------------------------. -| Print this symbol on YYOUTPUT. | -`--------------------------------*/ - -/*ARGSUSED*/ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -static void -yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) -#else -static void -yy_symbol_value_print (yyoutput, yytype, yyvaluep) - FILE *yyoutput; - int yytype; - YYSTYPE const * const yyvaluep; -#endif -{ - if (!yyvaluep) - return; -# ifdef YYPRINT - if (yytype < YYNTOKENS) - YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); -# else - YYUSE (yyoutput); -# endif - switch (yytype) - { - default: - break; - } -} - - -/*--------------------------------. -| Print this symbol on YYOUTPUT. | -`--------------------------------*/ - -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -static void -yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) -#else -static void -yy_symbol_print (yyoutput, yytype, yyvaluep) - FILE *yyoutput; - int yytype; - YYSTYPE const * const yyvaluep; -#endif -{ - if (yytype < YYNTOKENS) - YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); - else - YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); - - yy_symbol_value_print (yyoutput, yytype, yyvaluep); - YYFPRINTF (yyoutput, ")"); -} - -/*------------------------------------------------------------------. -| yy_stack_print -- Print the state stack from its BOTTOM up to its | -| TOP (included). | -`------------------------------------------------------------------*/ - -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -static void -yy_stack_print (yytype_int16 *bottom, yytype_int16 *top) -#else -static void -yy_stack_print (bottom, top) - yytype_int16 *bottom; - yytype_int16 *top; -#endif -{ - YYFPRINTF (stderr, "Stack now"); - for (; bottom <= top; ++bottom) - YYFPRINTF (stderr, " %d", *bottom); - YYFPRINTF (stderr, "\n"); -} - -# define YY_STACK_PRINT(Bottom, Top) \ -do { \ - if (yydebug) \ - yy_stack_print ((Bottom), (Top)); \ -} while (YYID (0)) - - -/*------------------------------------------------. -| Report that the YYRULE is going to be reduced. | -`------------------------------------------------*/ - -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -static void -yy_reduce_print (YYSTYPE *yyvsp, int yyrule) -#else -static void -yy_reduce_print (yyvsp, yyrule) - YYSTYPE *yyvsp; - int yyrule; -#endif -{ - int yynrhs = yyr2[yyrule]; - int yyi; - unsigned long int yylno = yyrline[yyrule]; - YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", - yyrule - 1, yylno); - /* The symbols being reduced. */ - for (yyi = 0; yyi < yynrhs; yyi++) - { - fprintf (stderr, " $%d = ", yyi + 1); - yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], - &(yyvsp[(yyi + 1) - (yynrhs)]) - ); - fprintf (stderr, "\n"); - } -} - -# define YY_REDUCE_PRINT(Rule) \ -do { \ - if (yydebug) \ - yy_reduce_print (yyvsp, Rule); \ -} while (YYID (0)) - -/* Nonzero means print parse trace. It is left uninitialized so that - multiple parsers can coexist. */ -int yydebug; -#else /* !YYDEBUG */ -# define YYDPRINTF(Args) -# define YY_SYMBOL_PRINT(Title, Type, Value, Location) -# define YY_STACK_PRINT(Bottom, Top) -# define YY_REDUCE_PRINT(Rule) -#endif /* !YYDEBUG */ - - -/* YYINITDEPTH -- initial size of the parser's stacks. */ -#ifndef YYINITDEPTH -# define YYINITDEPTH 200 -#endif - -/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only - if the built-in stack extension method is used). - - Do not make this value too large; the results are undefined if - YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) - evaluated with infinite-precision integer arithmetic. */ - -#ifndef YYMAXDEPTH -# define YYMAXDEPTH 10000 -#endif - - - -#if YYERROR_VERBOSE - -# ifndef yystrlen -# if defined __GLIBC__ && defined _STRING_H -# define yystrlen strlen -# else -/* Return the length of YYSTR. */ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -static YYSIZE_T -yystrlen (const char *yystr) -#else -static YYSIZE_T -yystrlen (yystr) - const char *yystr; -#endif -{ - YYSIZE_T yylen; - for (yylen = 0; yystr[yylen]; yylen++) - continue; - return yylen; -} -# endif -# endif - -# ifndef yystpcpy -# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE -# define yystpcpy stpcpy -# else -/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in - YYDEST. */ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -static char * -yystpcpy (char *yydest, const char *yysrc) -#else -static char * -yystpcpy (yydest, yysrc) - char *yydest; - const char *yysrc; -#endif -{ - char *yyd = yydest; - const char *yys = yysrc; - - while ((*yyd++ = *yys++) != '\0') - continue; - - return yyd - 1; -} -# endif -# endif - -# ifndef yytnamerr -/* Copy to YYRES the contents of YYSTR after stripping away unnecessary - quotes and backslashes, so that it's suitable for yyerror. The - heuristic is that double-quoting is unnecessary unless the string - contains an apostrophe, a comma, or backslash (other than - backslash-backslash). YYSTR is taken from yytname. If YYRES is - null, do not copy; instead, return the length of what the result - would have been. */ -static YYSIZE_T -yytnamerr (char *yyres, const char *yystr) -{ - if (*yystr == '"') - { - YYSIZE_T yyn = 0; - char const *yyp = yystr; - - for (;;) - switch (*++yyp) - { - case '\'': - case ',': - goto do_not_strip_quotes; - - case '\\': - if (*++yyp != '\\') - goto do_not_strip_quotes; - /* Fall through. */ - default: - if (yyres) - yyres[yyn] = *yyp; - yyn++; - break; - - case '"': - if (yyres) - yyres[yyn] = '\0'; - return yyn; - } - do_not_strip_quotes: ; - } - - if (! yyres) - return yystrlen (yystr); - - return yystpcpy (yyres, yystr) - yyres; -} -# endif - -/* Copy into YYRESULT an error message about the unexpected token - YYCHAR while in state YYSTATE. Return the number of bytes copied, - including the terminating null byte. If YYRESULT is null, do not - copy anything; just return the number of bytes that would be - copied. As a special case, return 0 if an ordinary "syntax error" - message will do. Return YYSIZE_MAXIMUM if overflow occurs during - size calculation. */ -static YYSIZE_T -yysyntax_error (char *yyresult, int yystate, int yychar) -{ - int yyn = yypact[yystate]; - - if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) - return 0; - else - { - int yytype = YYTRANSLATE (yychar); - YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); - YYSIZE_T yysize = yysize0; - YYSIZE_T yysize1; - int yysize_overflow = 0; - enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; - char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; - int yyx; - -# if 0 - /* This is so xgettext sees the translatable formats that are - constructed on the fly. */ - YY_("syntax error, unexpected %s"); - YY_("syntax error, unexpected %s, expecting %s"); - YY_("syntax error, unexpected %s, expecting %s or %s"); - YY_("syntax error, unexpected %s, expecting %s or %s or %s"); - YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); -# endif - char *yyfmt; - char const *yyf; - static char const yyunexpected[] = "syntax error, unexpected %s"; - static char const yyexpecting[] = ", expecting %s"; - static char const yyor[] = " or %s"; - char yyformat[sizeof yyunexpected - + sizeof yyexpecting - 1 - + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) - * (sizeof yyor - 1))]; - char const *yyprefix = yyexpecting; - - /* Start YYX at -YYN if negative to avoid negative indexes in - YYCHECK. */ - int yyxbegin = yyn < 0 ? -yyn : 0; - - /* Stay within bounds of both yycheck and yytname. */ - int yychecklim = YYLAST - yyn + 1; - int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; - int yycount = 1; - - yyarg[0] = yytname[yytype]; - yyfmt = yystpcpy (yyformat, yyunexpected); - - for (yyx = yyxbegin; yyx < yyxend; ++yyx) - if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) - { - if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) - { - yycount = 1; - yysize = yysize0; - yyformat[sizeof yyunexpected - 1] = '\0'; - break; - } - yyarg[yycount++] = yytname[yyx]; - yysize1 = yysize + yytnamerr (0, yytname[yyx]); - yysize_overflow |= (yysize1 < yysize); - yysize = yysize1; - yyfmt = yystpcpy (yyfmt, yyprefix); - yyprefix = yyor; - } - - yyf = YY_(yyformat); - yysize1 = yysize + yystrlen (yyf); - yysize_overflow |= (yysize1 < yysize); - yysize = yysize1; - - if (yysize_overflow) - return YYSIZE_MAXIMUM; - - if (yyresult) - { - /* Avoid sprintf, as that infringes on the user's name space. - Don't have undefined behavior even if the translation - produced a string with the wrong number of "%s"s. */ - char *yyp = yyresult; - int yyi = 0; - while ((*yyp = *yyf) != '\0') - { - if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) - { - yyp += yytnamerr (yyp, yyarg[yyi++]); - yyf += 2; - } - else - { - yyp++; - yyf++; - } - } - } - return yysize; - } -} -#endif /* YYERROR_VERBOSE */ - - -/*-----------------------------------------------. -| Release the memory associated to this symbol. | -`-----------------------------------------------*/ - -/*ARGSUSED*/ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -static void -yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep) -#else -static void -yydestruct (yymsg, yytype, yyvaluep) - const char *yymsg; - int yytype; - YYSTYPE *yyvaluep; -#endif -{ - YYUSE (yyvaluep); - - if (!yymsg) - yymsg = "Deleting"; - YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); - - switch (yytype) - { - - default: - break; - } -} - - -/* Prevent warnings from -Wmissing-prototypes. */ - -#ifdef YYPARSE_PARAM -#if defined __STDC__ || defined __cplusplus -int yyparse (void *YYPARSE_PARAM); -#else -int yyparse (); -#endif -#else /* ! YYPARSE_PARAM */ -#if defined __STDC__ || defined __cplusplus -int yyparse (void); -#else -int yyparse (); -#endif -#endif /* ! YYPARSE_PARAM */ - - - -/* The look-ahead symbol. */ -int yychar; - -/* The semantic value of the look-ahead symbol. */ -YYSTYPE yylval; - -/* Number of syntax errors so far. */ -int yynerrs; - - - -/*----------. -| yyparse. | -`----------*/ - -#ifdef YYPARSE_PARAM -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -int -yyparse (void *YYPARSE_PARAM) -#else -int -yyparse (YYPARSE_PARAM) - void *YYPARSE_PARAM; -#endif -#else /* ! YYPARSE_PARAM */ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -int -yyparse (void) -#else -int -yyparse () - -#endif -#endif -{ - - int yystate; - int yyn; - int yyresult; - /* Number of tokens to shift before error messages enabled. */ - int yyerrstatus; - /* Look-ahead token as an internal (translated) token number. */ - int yytoken = 0; -#if YYERROR_VERBOSE - /* Buffer for error messages, and its allocated size. */ - char yymsgbuf[128]; - char *yymsg = yymsgbuf; - YYSIZE_T yymsg_alloc = sizeof yymsgbuf; -#endif - - /* Three stacks and their tools: - `yyss': related to states, - `yyvs': related to semantic values, - `yyls': related to locations. - - Refer to the stacks thru separate pointers, to allow yyoverflow - to reallocate them elsewhere. */ - - /* The state stack. */ - yytype_int16 yyssa[YYINITDEPTH]; - yytype_int16 *yyss = yyssa; - yytype_int16 *yyssp; - - /* The semantic value stack. */ - YYSTYPE yyvsa[YYINITDEPTH]; - YYSTYPE *yyvs = yyvsa; - YYSTYPE *yyvsp; - - - -#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) - - YYSIZE_T yystacksize = YYINITDEPTH; - - /* The variables used to return semantic value and location from the - action routines. */ - YYSTYPE yyval; - - - /* The number of symbols on the RHS of the reduced rule. - Keep to zero when no symbol should be popped. */ - int yylen = 0; - - YYDPRINTF ((stderr, "Starting parse\n")); - - yystate = 0; - yyerrstatus = 0; - yynerrs = 0; - yychar = YYEMPTY; /* Cause a token to be read. */ - - /* Initialize stack pointers. - Waste one element of value and location stack - so that they stay on the same level as the state stack. - The wasted elements are never initialized. */ - - yyssp = yyss; - yyvsp = yyvs; - - goto yysetstate; - -/*------------------------------------------------------------. -| yynewstate -- Push a new state, which is found in yystate. | -`------------------------------------------------------------*/ - yynewstate: - /* In all cases, when you get here, the value and location stacks - have just been pushed. So pushing a state here evens the stacks. */ - yyssp++; - - yysetstate: - *yyssp = yystate; - - if (yyss + yystacksize - 1 <= yyssp) - { - /* Get the current used size of the three stacks, in elements. */ - YYSIZE_T yysize = yyssp - yyss + 1; - -#ifdef yyoverflow - { - /* Give user a chance to reallocate the stack. Use copies of - these so that the &'s don't force the real ones into - memory. */ - YYSTYPE *yyvs1 = yyvs; - yytype_int16 *yyss1 = yyss; - - - /* Each stack pointer address is followed by the size of the - data in use in that stack, in bytes. This used to be a - conditional around just the two extra args, but that might - be undefined if yyoverflow is a macro. */ - yyoverflow (YY_("memory exhausted"), - &yyss1, yysize * sizeof (*yyssp), - &yyvs1, yysize * sizeof (*yyvsp), - - &yystacksize); - - yyss = yyss1; - yyvs = yyvs1; - } -#else /* no yyoverflow */ -# ifndef YYSTACK_RELOCATE - goto yyexhaustedlab; -# else - /* Extend the stack our own way. */ - if (YYMAXDEPTH <= yystacksize) - goto yyexhaustedlab; - yystacksize *= 2; - if (YYMAXDEPTH < yystacksize) - yystacksize = YYMAXDEPTH; - - { - yytype_int16 *yyss1 = yyss; - union yyalloc *yyptr = - (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); - if (! yyptr) - goto yyexhaustedlab; - YYSTACK_RELOCATE (yyss); - YYSTACK_RELOCATE (yyvs); - -# undef YYSTACK_RELOCATE - if (yyss1 != yyssa) - YYSTACK_FREE (yyss1); - } -# endif -#endif /* no yyoverflow */ - - yyssp = yyss + yysize - 1; - yyvsp = yyvs + yysize - 1; - - - YYDPRINTF ((stderr, "Stack size increased to %lu\n", - (unsigned long int) yystacksize)); - - if (yyss + yystacksize - 1 <= yyssp) - YYABORT; - } - - YYDPRINTF ((stderr, "Entering state %d\n", yystate)); - - goto yybackup; - -/*-----------. -| yybackup. | -`-----------*/ -yybackup: - - /* Do appropriate processing given the current state. Read a - look-ahead token if we need one and don't already have one. */ - - /* First try to decide what to do without reference to look-ahead token. */ - yyn = yypact[yystate]; - if (yyn == YYPACT_NINF) - goto yydefault; - - /* Not known => get a look-ahead token if don't already have one. */ - - /* YYCHAR is either YYEMPTY or YYEOF or a valid look-ahead symbol. */ - if (yychar == YYEMPTY) - { - YYDPRINTF ((stderr, "Reading a token: ")); - yychar = YYLEX; - } - - if (yychar <= YYEOF) - { - yychar = yytoken = YYEOF; - YYDPRINTF ((stderr, "Now at end of input.\n")); - } - else - { - yytoken = YYTRANSLATE (yychar); - YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); - } - - /* If the proper action on seeing token YYTOKEN is to reduce or to - detect an error, take that action. */ - yyn += yytoken; - if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) - goto yydefault; - yyn = yytable[yyn]; - if (yyn <= 0) - { - if (yyn == 0 || yyn == YYTABLE_NINF) - goto yyerrlab; - yyn = -yyn; - goto yyreduce; - } - - if (yyn == YYFINAL) - YYACCEPT; - - /* Count tokens shifted since error; after three, turn off error - status. */ - if (yyerrstatus) - yyerrstatus--; - - /* Shift the look-ahead token. */ - YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); - - /* Discard the shifted token unless it is eof. */ - if (yychar != YYEOF) - yychar = YYEMPTY; - - yystate = yyn; - *++yyvsp = yylval; - - goto yynewstate; - - -/*-----------------------------------------------------------. -| yydefault -- do the default action for the current state. | -`-----------------------------------------------------------*/ -yydefault: - yyn = yydefact[yystate]; - if (yyn == 0) - goto yyerrlab; - goto yyreduce; - - -/*-----------------------------. -| yyreduce -- Do a reduction. | -`-----------------------------*/ -yyreduce: - /* yyn is the number of a rule to reduce with. */ - yylen = yyr2[yyn]; - - /* If YYLEN is nonzero, implement the default value of the action: - `$$ = $1'. - - Otherwise, the following line sets YYVAL to garbage. - This behavior is undocumented and Bison - users should not rely upon it. Assigning to YYVAL - unconditionally makes the parser a bit smaller, and it avoids a - GCC warning that YYVAL may be used uninitialized. */ - yyval = yyvsp[1-yylen]; - - - YY_REDUCE_PRINT (yyn); - switch (yyn) - { - case 2: -#line 349 "parse.y" - { - lex_state = EXPR_BEG; - top_local_init(); - if (ruby_class == rb_cObject) class_nest = 0; - else class_nest = 1; - } - break; - - case 3: -#line 356 "parse.y" - { - if ((yyvsp[(2) - (2)].node) && !compile_for_eval) { - /* last expression should not be void */ - if (nd_type((yyvsp[(2) - (2)].node)) != NODE_BLOCK) void_expr((yyvsp[(2) - (2)].node)); - else { - NODE *node = (yyvsp[(2) - (2)].node); - while (node->nd_next) { - node = node->nd_next; - } - void_expr(node->nd_head); - } - } - ruby_eval_tree = block_append(ruby_eval_tree, (yyvsp[(2) - (2)].node)); - top_local_setup(); - class_nest = 0; - } - break; - - case 4: -#line 378 "parse.y" - { - (yyval.node) = (yyvsp[(1) - (4)].node); - if ((yyvsp[(2) - (4)].node)) { - (yyval.node) = NEW_RESCUE((yyvsp[(1) - (4)].node), (yyvsp[(2) - (4)].node), (yyvsp[(3) - (4)].node)); - } - else if ((yyvsp[(3) - (4)].node)) { - rb_warn("else without rescue is useless"); - (yyval.node) = block_append((yyval.node), (yyvsp[(3) - (4)].node)); - } - if ((yyvsp[(4) - (4)].node)) { - (yyval.node) = NEW_ENSURE((yyval.node), (yyvsp[(4) - (4)].node)); - } - fixpos((yyval.node), (yyvsp[(1) - (4)].node)); - } - break; - - case 5: -#line 395 "parse.y" - { - void_stmts((yyvsp[(1) - (2)].node)); - (yyval.node) = (yyvsp[(1) - (2)].node); - } - break; - - case 7: -#line 403 "parse.y" - { - (yyval.node) = newline_node((yyvsp[(1) - (1)].node)); - } - break; - - case 8: -#line 407 "parse.y" - { - (yyval.node) = block_append((yyvsp[(1) - (3)].node), newline_node((yyvsp[(3) - (3)].node))); - } - break; - - case 9: -#line 411 "parse.y" - { - (yyval.node) = remove_begin((yyvsp[(2) - (2)].node)); - } - break; - - case 10: -#line 416 "parse.y" - {lex_state = EXPR_FNAME;} - break; - - case 11: -#line 417 "parse.y" - { - (yyval.node) = NEW_ALIAS((yyvsp[(2) - (4)].node), (yyvsp[(4) - (4)].node)); - } - break; - - case 12: -#line 421 "parse.y" - { - (yyval.node) = NEW_VALIAS((yyvsp[(2) - (3)].id), (yyvsp[(3) - (3)].id)); - } - break; - - case 13: -#line 425 "parse.y" - { - char buf[3]; - - sprintf(buf, "$%c", (char)(yyvsp[(3) - (3)].node)->nd_nth); - (yyval.node) = NEW_VALIAS((yyvsp[(2) - (3)].id), rb_intern(buf)); - } - break; - - case 14: -#line 432 "parse.y" - { - yyerror("can't make alias for the number variables"); - (yyval.node) = 0; - } - break; - - case 15: -#line 437 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (2)].node); - } - break; - - case 16: -#line 441 "parse.y" - { - (yyval.node) = NEW_IF(cond((yyvsp[(3) - (3)].node)), remove_begin((yyvsp[(1) - (3)].node)), 0); - fixpos((yyval.node), (yyvsp[(3) - (3)].node)); - if (cond_negative(&(yyval.node)->nd_cond)) { - (yyval.node)->nd_else = (yyval.node)->nd_body; - (yyval.node)->nd_body = 0; - } - } - break; - - case 17: -#line 450 "parse.y" - { - (yyval.node) = NEW_UNLESS(cond((yyvsp[(3) - (3)].node)), remove_begin((yyvsp[(1) - (3)].node)), 0); - fixpos((yyval.node), (yyvsp[(3) - (3)].node)); - if (cond_negative(&(yyval.node)->nd_cond)) { - (yyval.node)->nd_body = (yyval.node)->nd_else; - (yyval.node)->nd_else = 0; - } - } - break; - - case 18: -#line 459 "parse.y" - { - if ((yyvsp[(1) - (3)].node) && nd_type((yyvsp[(1) - (3)].node)) == NODE_BEGIN) { - (yyval.node) = NEW_WHILE(cond((yyvsp[(3) - (3)].node)), (yyvsp[(1) - (3)].node)->nd_body, 0); - } - else { - (yyval.node) = NEW_WHILE(cond((yyvsp[(3) - (3)].node)), (yyvsp[(1) - (3)].node), 1); - } - if (cond_negative(&(yyval.node)->nd_cond)) { - nd_set_type((yyval.node), NODE_UNTIL); - } - } - break; - - case 19: -#line 471 "parse.y" - { - if ((yyvsp[(1) - (3)].node) && nd_type((yyvsp[(1) - (3)].node)) == NODE_BEGIN) { - (yyval.node) = NEW_UNTIL(cond((yyvsp[(3) - (3)].node)), (yyvsp[(1) - (3)].node)->nd_body, 0); - } - else { - (yyval.node) = NEW_UNTIL(cond((yyvsp[(3) - (3)].node)), (yyvsp[(1) - (3)].node), 1); - } - if (cond_negative(&(yyval.node)->nd_cond)) { - nd_set_type((yyval.node), NODE_WHILE); - } - } - break; - - case 20: -#line 483 "parse.y" - { - NODE *resq = NEW_RESBODY(0, remove_begin((yyvsp[(3) - (3)].node)), 0); - (yyval.node) = NEW_RESCUE(remove_begin((yyvsp[(1) - (3)].node)), resq, 0); - } - break; - - case 21: -#line 488 "parse.y" - { - if (in_def || in_single) { - yyerror("BEGIN in method"); - } - local_push(0); - } - break; - - case 22: -#line 495 "parse.y" - { - ruby_eval_tree_begin = block_append(ruby_eval_tree_begin, - NEW_PREEXE((yyvsp[(4) - (5)].node))); - local_pop(); - (yyval.node) = 0; - } - break; - - case 23: -#line 502 "parse.y" - { - if (in_def || in_single) { - rb_warn("END in method; use at_exit"); - } - - (yyval.node) = NEW_ITER(0, NEW_POSTEXE(), (yyvsp[(3) - (4)].node)); - } - break; - - case 24: -#line 510 "parse.y" - { - (yyval.node) = node_assign((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 25: -#line 514 "parse.y" - { - value_expr((yyvsp[(3) - (3)].node)); - (yyvsp[(1) - (3)].node)->nd_value = ((yyvsp[(1) - (3)].node)->nd_head) ? NEW_TO_ARY((yyvsp[(3) - (3)].node)) : NEW_ARRAY((yyvsp[(3) - (3)].node)); - (yyval.node) = (yyvsp[(1) - (3)].node); - } - break; - - case 26: -#line 520 "parse.y" - { - value_expr((yyvsp[(3) - (3)].node)); - if ((yyvsp[(1) - (3)].node)) { - ID vid = (yyvsp[(1) - (3)].node)->nd_vid; - if ((yyvsp[(2) - (3)].id) == tOROP) { - (yyvsp[(1) - (3)].node)->nd_value = (yyvsp[(3) - (3)].node); - (yyval.node) = NEW_OP_ASGN_OR(gettable(vid), (yyvsp[(1) - (3)].node)); - if (is_asgn_or_id(vid)) { - (yyval.node)->nd_aid = vid; - } - } - else if ((yyvsp[(2) - (3)].id) == tANDOP) { - (yyvsp[(1) - (3)].node)->nd_value = (yyvsp[(3) - (3)].node); - (yyval.node) = NEW_OP_ASGN_AND(gettable(vid), (yyvsp[(1) - (3)].node)); - } - else { - (yyval.node) = (yyvsp[(1) - (3)].node); - (yyval.node)->nd_value = call_op(gettable(vid),(yyvsp[(2) - (3)].id),1,(yyvsp[(3) - (3)].node)); - } - } - else { - (yyval.node) = 0; - } - } - break; - - case 27: -#line 545 "parse.y" - { - NODE *args; - - value_expr((yyvsp[(6) - (6)].node)); - if (!(yyvsp[(3) - (6)].node)) (yyvsp[(3) - (6)].node) = NEW_ZARRAY(); - args = arg_concat((yyvsp[(6) - (6)].node), (yyvsp[(3) - (6)].node)); - if ((yyvsp[(5) - (6)].id) == tOROP) { - (yyvsp[(5) - (6)].id) = 0; - } - else if ((yyvsp[(5) - (6)].id) == tANDOP) { - (yyvsp[(5) - (6)].id) = 1; - } - (yyval.node) = NEW_OP_ASGN1((yyvsp[(1) - (6)].node), (yyvsp[(5) - (6)].id), args); - fixpos((yyval.node), (yyvsp[(1) - (6)].node)); - } - break; - - case 28: -#line 561 "parse.y" - { - value_expr((yyvsp[(5) - (5)].node)); - if ((yyvsp[(4) - (5)].id) == tOROP) { - (yyvsp[(4) - (5)].id) = 0; - } - else if ((yyvsp[(4) - (5)].id) == tANDOP) { - (yyvsp[(4) - (5)].id) = 1; - } - (yyval.node) = NEW_OP_ASGN2((yyvsp[(1) - (5)].node), (yyvsp[(3) - (5)].id), (yyvsp[(4) - (5)].id), (yyvsp[(5) - (5)].node)); - fixpos((yyval.node), (yyvsp[(1) - (5)].node)); - } - break; - - case 29: -#line 573 "parse.y" - { - value_expr((yyvsp[(5) - (5)].node)); - if ((yyvsp[(4) - (5)].id) == tOROP) { - (yyvsp[(4) - (5)].id) = 0; - } - else if ((yyvsp[(4) - (5)].id) == tANDOP) { - (yyvsp[(4) - (5)].id) = 1; - } - (yyval.node) = NEW_OP_ASGN2((yyvsp[(1) - (5)].node), (yyvsp[(3) - (5)].id), (yyvsp[(4) - (5)].id), (yyvsp[(5) - (5)].node)); - fixpos((yyval.node), (yyvsp[(1) - (5)].node)); - } - break; - - case 30: -#line 585 "parse.y" - { - value_expr((yyvsp[(5) - (5)].node)); - if ((yyvsp[(4) - (5)].id) == tOROP) { - (yyvsp[(4) - (5)].id) = 0; - } - else if ((yyvsp[(4) - (5)].id) == tANDOP) { - (yyvsp[(4) - (5)].id) = 1; - } - (yyval.node) = NEW_OP_ASGN2((yyvsp[(1) - (5)].node), (yyvsp[(3) - (5)].id), (yyvsp[(4) - (5)].id), (yyvsp[(5) - (5)].node)); - fixpos((yyval.node), (yyvsp[(1) - (5)].node)); - } - break; - - case 31: -#line 597 "parse.y" - { - rb_backref_error((yyvsp[(1) - (3)].node)); - (yyval.node) = 0; - } - break; - - case 32: -#line 602 "parse.y" - { - (yyval.node) = node_assign((yyvsp[(1) - (3)].node), NEW_SVALUE((yyvsp[(3) - (3)].node))); - } - break; - - case 33: -#line 606 "parse.y" - { - (yyvsp[(1) - (3)].node)->nd_value = ((yyvsp[(1) - (3)].node)->nd_head) ? NEW_TO_ARY((yyvsp[(3) - (3)].node)) : NEW_ARRAY((yyvsp[(3) - (3)].node)); - (yyval.node) = (yyvsp[(1) - (3)].node); - } - break; - - case 34: -#line 611 "parse.y" - { - (yyvsp[(1) - (3)].node)->nd_value = (yyvsp[(3) - (3)].node); - (yyval.node) = (yyvsp[(1) - (3)].node); - } - break; - - case 37: -#line 620 "parse.y" - { - (yyval.node) = logop(NODE_AND, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 38: -#line 624 "parse.y" - { - (yyval.node) = logop(NODE_OR, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 39: -#line 628 "parse.y" - { - (yyval.node) = NEW_NOT(cond((yyvsp[(2) - (2)].node))); - } - break; - - case 40: -#line 632 "parse.y" - { - (yyval.node) = NEW_NOT(cond((yyvsp[(2) - (2)].node))); - } - break; - - case 42: -#line 639 "parse.y" - { - value_expr((yyval.node)); - (yyval.node) = (yyvsp[(1) - (1)].node); - } - break; - - case 45: -#line 648 "parse.y" - { - (yyval.node) = NEW_RETURN(ret_args((yyvsp[(2) - (2)].node))); - } - break; - - case 46: -#line 652 "parse.y" - { - (yyval.node) = NEW_BREAK(ret_args((yyvsp[(2) - (2)].node))); - } - break; - - case 47: -#line 656 "parse.y" - { - (yyval.node) = NEW_NEXT(ret_args((yyvsp[(2) - (2)].node))); - } - break; - - case 49: -#line 663 "parse.y" - { - (yyval.node) = new_call((yyvsp[(1) - (4)].node), (yyvsp[(3) - (4)].id), (yyvsp[(4) - (4)].node)); - } - break; - - case 50: -#line 667 "parse.y" - { - (yyval.node) = new_call((yyvsp[(1) - (4)].node), (yyvsp[(3) - (4)].id), (yyvsp[(4) - (4)].node)); - } - break; - - case 51: -#line 673 "parse.y" - { - (yyval.vars) = dyna_push(); - (yyvsp[(1) - (1)].num) = ruby_sourceline; - } - break; - - case 52: -#line 677 "parse.y" - {(yyval.vars) = ruby_dyna_vars;} - break; - - case 53: -#line 680 "parse.y" - { - (yyval.node) = NEW_ITER((yyvsp[(3) - (6)].node), 0, dyna_init((yyvsp[(5) - (6)].node), (yyvsp[(4) - (6)].vars))); - nd_set_line((yyval.node), (yyvsp[(1) - (6)].num)); - dyna_pop((yyvsp[(2) - (6)].vars)); - } - break; - - case 54: -#line 688 "parse.y" - { - (yyval.node) = new_fcall((yyvsp[(1) - (2)].id), (yyvsp[(2) - (2)].node)); - fixpos((yyval.node), (yyvsp[(2) - (2)].node)); - } - break; - - case 55: -#line 693 "parse.y" - { - (yyval.node) = new_fcall((yyvsp[(1) - (3)].id), (yyvsp[(2) - (3)].node)); - if ((yyvsp[(3) - (3)].node)) { - if (nd_type((yyval.node)) == NODE_BLOCK_PASS) { - rb_compile_error("both block arg and actual block given"); - } - (yyvsp[(3) - (3)].node)->nd_iter = (yyval.node); - (yyval.node) = (yyvsp[(3) - (3)].node); - } - fixpos((yyval.node), (yyvsp[(2) - (3)].node)); - } - break; - - case 56: -#line 705 "parse.y" - { - (yyval.node) = new_call((yyvsp[(1) - (4)].node), (yyvsp[(3) - (4)].id), (yyvsp[(4) - (4)].node)); - fixpos((yyval.node), (yyvsp[(1) - (4)].node)); - } - break; - - case 57: -#line 710 "parse.y" - { - (yyval.node) = new_call((yyvsp[(1) - (5)].node), (yyvsp[(3) - (5)].id), (yyvsp[(4) - (5)].node)); - if ((yyvsp[(5) - (5)].node)) { - if (nd_type((yyval.node)) == NODE_BLOCK_PASS) { - rb_compile_error("both block arg and actual block given"); - } - (yyvsp[(5) - (5)].node)->nd_iter = (yyval.node); - (yyval.node) = (yyvsp[(5) - (5)].node); - } - fixpos((yyval.node), (yyvsp[(1) - (5)].node)); - } - break; - - case 58: -#line 722 "parse.y" - { - (yyval.node) = new_call((yyvsp[(1) - (4)].node), (yyvsp[(3) - (4)].id), (yyvsp[(4) - (4)].node)); - fixpos((yyval.node), (yyvsp[(1) - (4)].node)); - } - break; - - case 59: -#line 727 "parse.y" - { - (yyval.node) = new_call((yyvsp[(1) - (5)].node), (yyvsp[(3) - (5)].id), (yyvsp[(4) - (5)].node)); - if ((yyvsp[(5) - (5)].node)) { - if (nd_type((yyval.node)) == NODE_BLOCK_PASS) { - rb_compile_error("both block arg and actual block given"); - } - (yyvsp[(5) - (5)].node)->nd_iter = (yyval.node); - (yyval.node) = (yyvsp[(5) - (5)].node); - } - fixpos((yyval.node), (yyvsp[(1) - (5)].node)); - } - break; - - case 60: -#line 739 "parse.y" - { - (yyval.node) = new_super((yyvsp[(2) - (2)].node)); - fixpos((yyval.node), (yyvsp[(2) - (2)].node)); - } - break; - - case 61: -#line 744 "parse.y" - { - (yyval.node) = new_yield((yyvsp[(2) - (2)].node)); - fixpos((yyval.node), (yyvsp[(2) - (2)].node)); - } - break; - - case 63: -#line 752 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (3)].node); - } - break; - - case 65: -#line 759 "parse.y" - { - (yyval.node) = NEW_MASGN(NEW_LIST((yyvsp[(2) - (3)].node)), 0); - } - break; - - case 66: -#line 765 "parse.y" - { - (yyval.node) = NEW_MASGN((yyvsp[(1) - (1)].node), 0); - } - break; - - case 67: -#line 769 "parse.y" - { - (yyval.node) = NEW_MASGN(list_append((yyvsp[(1) - (2)].node),(yyvsp[(2) - (2)].node)), 0); - } - break; - - case 68: -#line 773 "parse.y" - { - (yyval.node) = NEW_MASGN((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 69: -#line 777 "parse.y" - { - (yyval.node) = NEW_MASGN((yyvsp[(1) - (2)].node), -1); - } - break; - - case 70: -#line 781 "parse.y" - { - (yyval.node) = NEW_MASGN(0, (yyvsp[(2) - (2)].node)); - } - break; - - case 71: -#line 785 "parse.y" - { - (yyval.node) = NEW_MASGN(0, -1); - } - break; - - case 73: -#line 792 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (3)].node); - } - break; - - case 74: -#line 798 "parse.y" - { - (yyval.node) = NEW_LIST((yyvsp[(1) - (2)].node)); - } - break; - - case 75: -#line 802 "parse.y" - { - (yyval.node) = list_append((yyvsp[(1) - (3)].node), (yyvsp[(2) - (3)].node)); - } - break; - - case 76: -#line 808 "parse.y" - { - (yyval.node) = assignable((yyvsp[(1) - (1)].id), 0); - } - break; - - case 77: -#line 812 "parse.y" - { - (yyval.node) = aryset((yyvsp[(1) - (4)].node), (yyvsp[(3) - (4)].node)); - } - break; - - case 78: -#line 816 "parse.y" - { - (yyval.node) = attrset((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].id)); - } - break; - - case 79: -#line 820 "parse.y" - { - (yyval.node) = attrset((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].id)); - } - break; - - case 80: -#line 824 "parse.y" - { - (yyval.node) = attrset((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].id)); - } - break; - - case 81: -#line 828 "parse.y" - { - if (in_def || in_single) - yyerror("dynamic constant assignment"); - (yyval.node) = NEW_CDECL(0, 0, NEW_COLON2((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].id))); - } - break; - - case 82: -#line 834 "parse.y" - { - if (in_def || in_single) - yyerror("dynamic constant assignment"); - (yyval.node) = NEW_CDECL(0, 0, NEW_COLON3((yyvsp[(2) - (2)].id))); - } - break; - - case 83: -#line 840 "parse.y" - { - rb_backref_error((yyvsp[(1) - (1)].node)); - (yyval.node) = 0; - } - break; - - case 84: -#line 847 "parse.y" - { - (yyval.node) = assignable((yyvsp[(1) - (1)].id), 0); - } - break; - - case 85: -#line 851 "parse.y" - { - (yyval.node) = aryset((yyvsp[(1) - (4)].node), (yyvsp[(3) - (4)].node)); - } - break; - - case 86: -#line 855 "parse.y" - { - (yyval.node) = attrset((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].id)); - } - break; - - case 87: -#line 859 "parse.y" - { - (yyval.node) = attrset((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].id)); - } - break; - - case 88: -#line 863 "parse.y" - { - (yyval.node) = attrset((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].id)); - } - break; - - case 89: -#line 867 "parse.y" - { - if (in_def || in_single) - yyerror("dynamic constant assignment"); - (yyval.node) = NEW_CDECL(0, 0, NEW_COLON2((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].id))); - } - break; - - case 90: -#line 873 "parse.y" - { - if (in_def || in_single) - yyerror("dynamic constant assignment"); - (yyval.node) = NEW_CDECL(0, 0, NEW_COLON3((yyvsp[(2) - (2)].id))); - } - break; - - case 91: -#line 879 "parse.y" - { - rb_backref_error((yyvsp[(1) - (1)].node)); - (yyval.node) = 0; - } - break; - - case 92: -#line 886 "parse.y" - { - yyerror("class/module name must be CONSTANT"); - } - break; - - case 94: -#line 893 "parse.y" - { - (yyval.node) = NEW_COLON3((yyvsp[(2) - (2)].id)); - } - break; - - case 95: -#line 897 "parse.y" - { - (yyval.node) = NEW_COLON2(0, (yyval.node)); - } - break; - - case 96: -#line 901 "parse.y" - { - (yyval.node) = NEW_COLON2((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].id)); - } - break; - - case 100: -#line 910 "parse.y" - { - lex_state = EXPR_END; - (yyval.id) = (yyvsp[(1) - (1)].id); - } - break; - - case 101: -#line 915 "parse.y" - { - lex_state = EXPR_END; - (yyval.id) = (yyvsp[(1) - (1)].id); - } - break; - - case 104: -#line 926 "parse.y" - { - (yyval.node) = NEW_LIT(ID2SYM((yyvsp[(1) - (1)].id))); - } - break; - - case 106: -#line 933 "parse.y" - { - (yyval.node) = NEW_UNDEF((yyvsp[(1) - (1)].node)); - } - break; - - case 107: -#line 936 "parse.y" - {lex_state = EXPR_FNAME;} - break; - - case 108: -#line 937 "parse.y" - { - (yyval.node) = block_append((yyvsp[(1) - (4)].node), NEW_UNDEF((yyvsp[(4) - (4)].node))); - } - break; - - case 109: -#line 942 "parse.y" - { (yyval.id) = '|'; } - break; - - case 110: -#line 943 "parse.y" - { (yyval.id) = '^'; } - break; - - case 111: -#line 944 "parse.y" - { (yyval.id) = '&'; } - break; - - case 112: -#line 945 "parse.y" - { (yyval.id) = tCMP; } - break; - - case 113: -#line 946 "parse.y" - { (yyval.id) = tEQ; } - break; - - case 114: -#line 947 "parse.y" - { (yyval.id) = tEQQ; } - break; - - case 115: -#line 948 "parse.y" - { (yyval.id) = tMATCH; } - break; - - case 116: -#line 949 "parse.y" - { (yyval.id) = '>'; } - break; - - case 117: -#line 950 "parse.y" - { (yyval.id) = tGEQ; } - break; - - case 118: -#line 951 "parse.y" - { (yyval.id) = '<'; } - break; - - case 119: -#line 952 "parse.y" - { (yyval.id) = tLEQ; } - break; - - case 120: -#line 953 "parse.y" - { (yyval.id) = tLSHFT; } - break; - - case 121: -#line 954 "parse.y" - { (yyval.id) = tRSHFT; } - break; - - case 122: -#line 955 "parse.y" - { (yyval.id) = '+'; } - break; - - case 123: -#line 956 "parse.y" - { (yyval.id) = '-'; } - break; - - case 124: -#line 957 "parse.y" - { (yyval.id) = '*'; } - break; - - case 125: -#line 958 "parse.y" - { (yyval.id) = '*'; } - break; - - case 126: -#line 959 "parse.y" - { (yyval.id) = '/'; } - break; - - case 127: -#line 960 "parse.y" - { (yyval.id) = '%'; } - break; - - case 128: -#line 961 "parse.y" - { (yyval.id) = tPOW; } - break; - - case 129: -#line 962 "parse.y" - { (yyval.id) = '~'; } - break; - - case 130: -#line 963 "parse.y" - { (yyval.id) = tUPLUS; } - break; - - case 131: -#line 964 "parse.y" - { (yyval.id) = tUMINUS; } - break; - - case 132: -#line 965 "parse.y" - { (yyval.id) = tAREF; } - break; - - case 133: -#line 966 "parse.y" - { (yyval.id) = tASET; } - break; - - case 134: -#line 967 "parse.y" - { (yyval.id) = '`'; } - break; - - case 175: -#line 980 "parse.y" - { - (yyval.node) = node_assign((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 176: -#line 984 "parse.y" - { - (yyval.node) = node_assign((yyvsp[(1) - (5)].node), NEW_RESCUE((yyvsp[(3) - (5)].node), NEW_RESBODY(0,(yyvsp[(5) - (5)].node),0), 0)); - } - break; - - case 177: -#line 988 "parse.y" - { - value_expr((yyvsp[(3) - (3)].node)); - if ((yyvsp[(1) - (3)].node)) { - ID vid = (yyvsp[(1) - (3)].node)->nd_vid; - if ((yyvsp[(2) - (3)].id) == tOROP) { - (yyvsp[(1) - (3)].node)->nd_value = (yyvsp[(3) - (3)].node); - (yyval.node) = NEW_OP_ASGN_OR(gettable(vid), (yyvsp[(1) - (3)].node)); - if (is_asgn_or_id(vid)) { - (yyval.node)->nd_aid = vid; - } - } - else if ((yyvsp[(2) - (3)].id) == tANDOP) { - (yyvsp[(1) - (3)].node)->nd_value = (yyvsp[(3) - (3)].node); - (yyval.node) = NEW_OP_ASGN_AND(gettable(vid), (yyvsp[(1) - (3)].node)); - } - else { - (yyval.node) = (yyvsp[(1) - (3)].node); - (yyval.node)->nd_value = call_op(gettable(vid),(yyvsp[(2) - (3)].id),1,(yyvsp[(3) - (3)].node)); - } - } - else { - (yyval.node) = 0; - } - } - break; - - case 178: -#line 1013 "parse.y" - { - NODE *args; - - value_expr((yyvsp[(6) - (6)].node)); - if (!(yyvsp[(3) - (6)].node)) (yyvsp[(3) - (6)].node) = NEW_ZARRAY(); - args = arg_concat((yyvsp[(6) - (6)].node), (yyvsp[(3) - (6)].node)); - if ((yyvsp[(5) - (6)].id) == tOROP) { - (yyvsp[(5) - (6)].id) = 0; - } - else if ((yyvsp[(5) - (6)].id) == tANDOP) { - (yyvsp[(5) - (6)].id) = 1; - } - (yyval.node) = NEW_OP_ASGN1((yyvsp[(1) - (6)].node), (yyvsp[(5) - (6)].id), args); - fixpos((yyval.node), (yyvsp[(1) - (6)].node)); - } - break; - - case 179: -#line 1029 "parse.y" - { - value_expr((yyvsp[(5) - (5)].node)); - if ((yyvsp[(4) - (5)].id) == tOROP) { - (yyvsp[(4) - (5)].id) = 0; - } - else if ((yyvsp[(4) - (5)].id) == tANDOP) { - (yyvsp[(4) - (5)].id) = 1; - } - (yyval.node) = NEW_OP_ASGN2((yyvsp[(1) - (5)].node), (yyvsp[(3) - (5)].id), (yyvsp[(4) - (5)].id), (yyvsp[(5) - (5)].node)); - fixpos((yyval.node), (yyvsp[(1) - (5)].node)); - } - break; - - case 180: -#line 1041 "parse.y" - { - value_expr((yyvsp[(5) - (5)].node)); - if ((yyvsp[(4) - (5)].id) == tOROP) { - (yyvsp[(4) - (5)].id) = 0; - } - else if ((yyvsp[(4) - (5)].id) == tANDOP) { - (yyvsp[(4) - (5)].id) = 1; - } - (yyval.node) = NEW_OP_ASGN2((yyvsp[(1) - (5)].node), (yyvsp[(3) - (5)].id), (yyvsp[(4) - (5)].id), (yyvsp[(5) - (5)].node)); - fixpos((yyval.node), (yyvsp[(1) - (5)].node)); - } - break; - - case 181: -#line 1053 "parse.y" - { - value_expr((yyvsp[(5) - (5)].node)); - if ((yyvsp[(4) - (5)].id) == tOROP) { - (yyvsp[(4) - (5)].id) = 0; - } - else if ((yyvsp[(4) - (5)].id) == tANDOP) { - (yyvsp[(4) - (5)].id) = 1; - } - (yyval.node) = NEW_OP_ASGN2((yyvsp[(1) - (5)].node), (yyvsp[(3) - (5)].id), (yyvsp[(4) - (5)].id), (yyvsp[(5) - (5)].node)); - fixpos((yyval.node), (yyvsp[(1) - (5)].node)); - } - break; - - case 182: -#line 1065 "parse.y" - { - yyerror("constant re-assignment"); - (yyval.node) = 0; - } - break; - - case 183: -#line 1070 "parse.y" - { - yyerror("constant re-assignment"); - (yyval.node) = 0; - } - break; - - case 184: -#line 1075 "parse.y" - { - rb_backref_error((yyvsp[(1) - (3)].node)); - (yyval.node) = 0; - } - break; - - case 185: -#line 1080 "parse.y" - { - value_expr((yyvsp[(1) - (3)].node)); - value_expr((yyvsp[(3) - (3)].node)); - if (nd_type((yyvsp[(1) - (3)].node)) == NODE_LIT && FIXNUM_P((yyvsp[(1) - (3)].node)->nd_lit) && - nd_type((yyvsp[(3) - (3)].node)) == NODE_LIT && FIXNUM_P((yyvsp[(3) - (3)].node)->nd_lit)) { - (yyvsp[(1) - (3)].node)->nd_lit = rb_range_new((yyvsp[(1) - (3)].node)->nd_lit, (yyvsp[(3) - (3)].node)->nd_lit, Qfalse); - (yyval.node) = (yyvsp[(1) - (3)].node); - } - else { - (yyval.node) = NEW_DOT2((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - } - break; - - case 186: -#line 1093 "parse.y" - { - value_expr((yyvsp[(1) - (3)].node)); - value_expr((yyvsp[(3) - (3)].node)); - if (nd_type((yyvsp[(1) - (3)].node)) == NODE_LIT && FIXNUM_P((yyvsp[(1) - (3)].node)->nd_lit) && - nd_type((yyvsp[(3) - (3)].node)) == NODE_LIT && FIXNUM_P((yyvsp[(3) - (3)].node)->nd_lit)) { - (yyvsp[(1) - (3)].node)->nd_lit = rb_range_new((yyvsp[(1) - (3)].node)->nd_lit, (yyvsp[(3) - (3)].node)->nd_lit, Qtrue); - (yyval.node) = (yyvsp[(1) - (3)].node); - } - else { - (yyval.node) = NEW_DOT3((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - } - break; - - case 187: -#line 1106 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), '+', 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 188: -#line 1110 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), '-', 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 189: -#line 1114 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), '*', 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 190: -#line 1118 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), '/', 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 191: -#line 1122 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), '%', 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 192: -#line 1126 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), tPOW, 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 193: -#line 1130 "parse.y" - { - (yyval.node) = call_op(call_op((yyvsp[(2) - (4)].node), tPOW, 1, (yyvsp[(4) - (4)].node)), tUMINUS, 0, 0); - } - break; - - case 194: -#line 1134 "parse.y" - { - (yyval.node) = call_op(call_op((yyvsp[(2) - (4)].node), tPOW, 1, (yyvsp[(4) - (4)].node)), tUMINUS, 0, 0); - } - break; - - case 195: -#line 1138 "parse.y" - { - if ((yyvsp[(2) - (2)].node) && nd_type((yyvsp[(2) - (2)].node)) == NODE_LIT) { - (yyval.node) = (yyvsp[(2) - (2)].node); - } - else { - (yyval.node) = call_op((yyvsp[(2) - (2)].node), tUPLUS, 0, 0); - } - } - break; - - case 196: -#line 1147 "parse.y" - { - (yyval.node) = call_op((yyvsp[(2) - (2)].node), tUMINUS, 0, 0); - } - break; - - case 197: -#line 1151 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), '|', 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 198: -#line 1155 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), '^', 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 199: -#line 1159 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), '&', 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 200: -#line 1163 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), tCMP, 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 201: -#line 1167 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), '>', 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 202: -#line 1171 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), tGEQ, 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 203: -#line 1175 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), '<', 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 204: -#line 1179 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), tLEQ, 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 205: -#line 1183 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), tEQ, 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 206: -#line 1187 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), tEQQ, 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 207: -#line 1191 "parse.y" - { - (yyval.node) = NEW_NOT(call_op((yyvsp[(1) - (3)].node), tEQ, 1, (yyvsp[(3) - (3)].node))); - } - break; - - case 208: -#line 1195 "parse.y" - { - (yyval.node) = match_gen((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 209: -#line 1199 "parse.y" - { - (yyval.node) = NEW_NOT(match_gen((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node))); - } - break; - - case 210: -#line 1203 "parse.y" - { - (yyval.node) = NEW_NOT(cond((yyvsp[(2) - (2)].node))); - } - break; - - case 211: -#line 1207 "parse.y" - { - (yyval.node) = call_op((yyvsp[(2) - (2)].node), '~', 0, 0); - } - break; - - case 212: -#line 1211 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), tLSHFT, 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 213: -#line 1215 "parse.y" - { - (yyval.node) = call_op((yyvsp[(1) - (3)].node), tRSHFT, 1, (yyvsp[(3) - (3)].node)); - } - break; - - case 214: -#line 1219 "parse.y" - { - (yyval.node) = logop(NODE_AND, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 215: -#line 1223 "parse.y" - { - (yyval.node) = logop(NODE_OR, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 216: -#line 1226 "parse.y" - {in_defined = 1;} - break; - - case 217: -#line 1227 "parse.y" - { - in_defined = 0; - (yyval.node) = NEW_DEFINED((yyvsp[(4) - (4)].node)); - } - break; - - case 218: -#line 1232 "parse.y" - { - (yyval.node) = NEW_IF(cond((yyvsp[(1) - (5)].node)), (yyvsp[(3) - (5)].node), (yyvsp[(5) - (5)].node)); - fixpos((yyval.node), (yyvsp[(1) - (5)].node)); - } - break; - - case 219: -#line 1237 "parse.y" - { - (yyval.node) = (yyvsp[(1) - (1)].node); - } - break; - - case 220: -#line 1243 "parse.y" - { - value_expr((yyvsp[(1) - (1)].node)); - (yyval.node) = (yyvsp[(1) - (1)].node); - } - break; - - case 222: -#line 1251 "parse.y" - { - (yyval.node) = NEW_LIST((yyvsp[(1) - (2)].node)); - } - break; - - case 223: -#line 1255 "parse.y" - { - (yyval.node) = (yyvsp[(1) - (2)].node); - } - break; - - case 224: -#line 1259 "parse.y" - { - value_expr((yyvsp[(4) - (5)].node)); - (yyval.node) = arg_concat((yyvsp[(1) - (5)].node), (yyvsp[(4) - (5)].node)); - } - break; - - case 225: -#line 1264 "parse.y" - { - (yyval.node) = NEW_LIST(NEW_HASH((yyvsp[(1) - (2)].node))); - } - break; - - case 226: -#line 1268 "parse.y" - { - value_expr((yyvsp[(2) - (3)].node)); - (yyval.node) = NEW_NEWLINE(NEW_SPLAT((yyvsp[(2) - (3)].node))); - } - break; - - case 227: -#line 1275 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (3)].node); - } - break; - - case 228: -#line 1279 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (4)].node); - } - break; - - case 229: -#line 1283 "parse.y" - { - (yyval.node) = NEW_LIST((yyvsp[(2) - (4)].node)); - } - break; - - case 230: -#line 1287 "parse.y" - { - (yyval.node) = list_append((yyvsp[(2) - (6)].node), (yyvsp[(4) - (6)].node)); - } - break; - - case 233: -#line 1297 "parse.y" - { - (yyval.node) = NEW_LIST((yyvsp[(1) - (1)].node)); - } - break; - - case 234: -#line 1301 "parse.y" - { - (yyval.node) = arg_blk_pass((yyvsp[(1) - (2)].node), (yyvsp[(2) - (2)].node)); - } - break; - - case 235: -#line 1305 "parse.y" - { - (yyval.node) = arg_concat((yyvsp[(1) - (5)].node), (yyvsp[(4) - (5)].node)); - (yyval.node) = arg_blk_pass((yyval.node), (yyvsp[(5) - (5)].node)); - } - break; - - case 236: -#line 1310 "parse.y" - { - (yyval.node) = NEW_LIST(NEW_HASH((yyvsp[(1) - (2)].node))); - (yyval.node) = arg_blk_pass((yyval.node), (yyvsp[(2) - (2)].node)); - } - break; - - case 237: -#line 1315 "parse.y" - { - (yyval.node) = arg_concat(NEW_LIST(NEW_HASH((yyvsp[(1) - (5)].node))), (yyvsp[(4) - (5)].node)); - (yyval.node) = arg_blk_pass((yyval.node), (yyvsp[(5) - (5)].node)); - } - break; - - case 238: -#line 1320 "parse.y" - { - (yyval.node) = list_append((yyvsp[(1) - (4)].node), NEW_HASH((yyvsp[(3) - (4)].node))); - (yyval.node) = arg_blk_pass((yyval.node), (yyvsp[(4) - (4)].node)); - } - break; - - case 239: -#line 1325 "parse.y" - { - value_expr((yyvsp[(6) - (7)].node)); - (yyval.node) = arg_concat(list_append((yyvsp[(1) - (7)].node), NEW_HASH((yyvsp[(3) - (7)].node))), (yyvsp[(6) - (7)].node)); - (yyval.node) = arg_blk_pass((yyval.node), (yyvsp[(7) - (7)].node)); - } - break; - - case 240: -#line 1331 "parse.y" - { - (yyval.node) = arg_blk_pass(NEW_SPLAT((yyvsp[(2) - (3)].node)), (yyvsp[(3) - (3)].node)); - } - break; - - case 242: -#line 1338 "parse.y" - { - (yyval.node) = arg_blk_pass(list_concat(NEW_LIST((yyvsp[(1) - (4)].node)),(yyvsp[(3) - (4)].node)), (yyvsp[(4) - (4)].node)); - } - break; - - case 243: -#line 1342 "parse.y" - { - (yyval.node) = arg_blk_pass((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 244: -#line 1346 "parse.y" - { - (yyval.node) = arg_concat(NEW_LIST((yyvsp[(1) - (5)].node)), (yyvsp[(4) - (5)].node)); - (yyval.node) = arg_blk_pass((yyval.node), (yyvsp[(5) - (5)].node)); - } - break; - - case 245: -#line 1351 "parse.y" - { - (yyval.node) = arg_concat(list_concat(NEW_LIST((yyvsp[(1) - (7)].node)),(yyvsp[(3) - (7)].node)), (yyvsp[(6) - (7)].node)); - (yyval.node) = arg_blk_pass((yyval.node), (yyvsp[(7) - (7)].node)); - } - break; - - case 246: -#line 1356 "parse.y" - { - (yyval.node) = NEW_LIST(NEW_HASH((yyvsp[(1) - (2)].node))); - (yyval.node) = arg_blk_pass((yyval.node), (yyvsp[(2) - (2)].node)); - } - break; - - case 247: -#line 1361 "parse.y" - { - (yyval.node) = arg_concat(NEW_LIST(NEW_HASH((yyvsp[(1) - (5)].node))), (yyvsp[(4) - (5)].node)); - (yyval.node) = arg_blk_pass((yyval.node), (yyvsp[(5) - (5)].node)); - } - break; - - case 248: -#line 1366 "parse.y" - { - (yyval.node) = list_append(NEW_LIST((yyvsp[(1) - (4)].node)), NEW_HASH((yyvsp[(3) - (4)].node))); - (yyval.node) = arg_blk_pass((yyval.node), (yyvsp[(4) - (4)].node)); - } - break; - - case 249: -#line 1371 "parse.y" - { - (yyval.node) = list_append(list_concat(NEW_LIST((yyvsp[(1) - (6)].node)),(yyvsp[(3) - (6)].node)), NEW_HASH((yyvsp[(5) - (6)].node))); - (yyval.node) = arg_blk_pass((yyval.node), (yyvsp[(6) - (6)].node)); - } - break; - - case 250: -#line 1376 "parse.y" - { - (yyval.node) = arg_concat(list_append(NEW_LIST((yyvsp[(1) - (7)].node)), NEW_HASH((yyvsp[(3) - (7)].node))), (yyvsp[(6) - (7)].node)); - (yyval.node) = arg_blk_pass((yyval.node), (yyvsp[(7) - (7)].node)); - } - break; - - case 251: -#line 1381 "parse.y" - { - (yyval.node) = arg_concat(list_append(list_concat(NEW_LIST((yyvsp[(1) - (9)].node)), (yyvsp[(3) - (9)].node)), NEW_HASH((yyvsp[(5) - (9)].node))), (yyvsp[(8) - (9)].node)); - (yyval.node) = arg_blk_pass((yyval.node), (yyvsp[(9) - (9)].node)); - } - break; - - case 252: -#line 1386 "parse.y" - { - (yyval.node) = arg_blk_pass(NEW_SPLAT((yyvsp[(2) - (3)].node)), (yyvsp[(3) - (3)].node)); - } - break; - - case 254: -#line 1392 "parse.y" - { - (yyval.num) = cmdarg_stack; - CMDARG_PUSH(1); - } - break; - - case 255: -#line 1397 "parse.y" - { - /* CMDARG_POP() */ - cmdarg_stack = (yyvsp[(1) - (2)].num); - (yyval.node) = (yyvsp[(2) - (2)].node); - } - break; - - case 257: -#line 1405 "parse.y" - {lex_state = EXPR_ENDARG;} - break; - - case 258: -#line 1406 "parse.y" - { - rb_warn("don't put space before argument parentheses"); - (yyval.node) = 0; - } - break; - - case 259: -#line 1410 "parse.y" - {lex_state = EXPR_ENDARG;} - break; - - case 260: -#line 1411 "parse.y" - { - rb_warn("don't put space before argument parentheses"); - (yyval.node) = (yyvsp[(2) - (4)].node); - } - break; - - case 261: -#line 1418 "parse.y" - { - (yyval.node) = NEW_BLOCK_PASS((yyvsp[(2) - (2)].node)); - } - break; - - case 262: -#line 1424 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (2)].node); - } - break; - - case 264: -#line 1431 "parse.y" - { - (yyval.node) = NEW_LIST((yyvsp[(1) - (1)].node)); - } - break; - - case 265: -#line 1435 "parse.y" - { - (yyval.node) = list_append((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 266: -#line 1441 "parse.y" - { - (yyval.node) = list_append((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 267: -#line 1445 "parse.y" - { - (yyval.node) = arg_concat((yyvsp[(1) - (4)].node), (yyvsp[(4) - (4)].node)); - } - break; - - case 268: -#line 1449 "parse.y" - { - (yyval.node) = NEW_SPLAT((yyvsp[(2) - (2)].node)); - } - break; - - case 277: -#line 1463 "parse.y" - { - (yyval.node) = NEW_FCALL((yyvsp[(1) - (1)].id), 0); - } - break; - - case 278: -#line 1467 "parse.y" - { - (yyvsp[(1) - (1)].num) = ruby_sourceline; - } - break; - - case 279: -#line 1472 "parse.y" - { - if ((yyvsp[(3) - (4)].node) == NULL) - (yyval.node) = NEW_NIL(); - else - (yyval.node) = NEW_BEGIN((yyvsp[(3) - (4)].node)); - nd_set_line((yyval.node), (yyvsp[(1) - (4)].num)); - } - break; - - case 280: -#line 1479 "parse.y" - {lex_state = EXPR_ENDARG;} - break; - - case 281: -#line 1480 "parse.y" - { - rb_warning("(...) interpreted as grouped expression"); - (yyval.node) = (yyvsp[(2) - (5)].node); - } - break; - - case 282: -#line 1485 "parse.y" - { - if (!(yyvsp[(2) - (3)].node)) (yyval.node) = NEW_NIL(); - else (yyval.node) = (yyvsp[(2) - (3)].node); - } - break; - - case 283: -#line 1490 "parse.y" - { - (yyval.node) = NEW_COLON2((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].id)); - } - break; - - case 284: -#line 1494 "parse.y" - { - (yyval.node) = NEW_COLON3((yyvsp[(2) - (2)].id)); - } - break; - - case 285: -#line 1498 "parse.y" - { - if ((yyvsp[(1) - (4)].node) && nd_type((yyvsp[(1) - (4)].node)) == NODE_SELF) - (yyval.node) = NEW_FCALL(tAREF, (yyvsp[(3) - (4)].node)); - else - (yyval.node) = NEW_CALL((yyvsp[(1) - (4)].node), tAREF, (yyvsp[(3) - (4)].node)); - fixpos((yyval.node), (yyvsp[(1) - (4)].node)); - } - break; - - case 286: -#line 1506 "parse.y" - { - if ((yyvsp[(2) - (3)].node) == 0) { - (yyval.node) = NEW_ZARRAY(); /* zero length array*/ - } - else { - (yyval.node) = (yyvsp[(2) - (3)].node); - } - } - break; - - case 287: -#line 1515 "parse.y" - { - (yyval.node) = NEW_HASH((yyvsp[(2) - (3)].node)); - } - break; - - case 288: -#line 1519 "parse.y" - { - (yyval.node) = NEW_RETURN(0); - } - break; - - case 289: -#line 1523 "parse.y" - { - (yyval.node) = new_yield((yyvsp[(3) - (4)].node)); - } - break; - - case 290: -#line 1527 "parse.y" - { - (yyval.node) = NEW_YIELD(0, Qfalse); - } - break; - - case 291: -#line 1531 "parse.y" - { - (yyval.node) = NEW_YIELD(0, Qfalse); - } - break; - - case 292: -#line 1534 "parse.y" - {in_defined = 1;} - break; - - case 293: -#line 1535 "parse.y" - { - in_defined = 0; - (yyval.node) = NEW_DEFINED((yyvsp[(5) - (6)].node)); - } - break; - - case 294: -#line 1540 "parse.y" - { - (yyvsp[(2) - (2)].node)->nd_iter = NEW_FCALL((yyvsp[(1) - (2)].id), 0); - (yyval.node) = (yyvsp[(2) - (2)].node); - fixpos((yyvsp[(2) - (2)].node)->nd_iter, (yyvsp[(2) - (2)].node)); - } - break; - - case 296: -#line 1547 "parse.y" - { - if ((yyvsp[(1) - (2)].node) && nd_type((yyvsp[(1) - (2)].node)) == NODE_BLOCK_PASS) { - rb_compile_error("both block arg and actual block given"); - } - (yyvsp[(2) - (2)].node)->nd_iter = (yyvsp[(1) - (2)].node); - (yyval.node) = (yyvsp[(2) - (2)].node); - fixpos((yyval.node), (yyvsp[(1) - (2)].node)); - } - break; - - case 297: -#line 1559 "parse.y" - { - (yyval.node) = NEW_IF(cond((yyvsp[(2) - (6)].node)), (yyvsp[(4) - (6)].node), (yyvsp[(5) - (6)].node)); - fixpos((yyval.node), (yyvsp[(2) - (6)].node)); - if (cond_negative(&(yyval.node)->nd_cond)) { - NODE *tmp = (yyval.node)->nd_body; - (yyval.node)->nd_body = (yyval.node)->nd_else; - (yyval.node)->nd_else = tmp; - } - } - break; - - case 298: -#line 1572 "parse.y" - { - (yyval.node) = NEW_UNLESS(cond((yyvsp[(2) - (6)].node)), (yyvsp[(4) - (6)].node), (yyvsp[(5) - (6)].node)); - fixpos((yyval.node), (yyvsp[(2) - (6)].node)); - if (cond_negative(&(yyval.node)->nd_cond)) { - NODE *tmp = (yyval.node)->nd_body; - (yyval.node)->nd_body = (yyval.node)->nd_else; - (yyval.node)->nd_else = tmp; - } - } - break; - - case 299: -#line 1581 "parse.y" - {COND_PUSH(1);} - break; - - case 300: -#line 1581 "parse.y" - {COND_POP();} - break; - - case 301: -#line 1584 "parse.y" - { - (yyval.node) = NEW_WHILE(cond((yyvsp[(3) - (7)].node)), (yyvsp[(6) - (7)].node), 1); - fixpos((yyval.node), (yyvsp[(3) - (7)].node)); - if (cond_negative(&(yyval.node)->nd_cond)) { - nd_set_type((yyval.node), NODE_UNTIL); - } - } - break; - - case 302: -#line 1591 "parse.y" - {COND_PUSH(1);} - break; - - case 303: -#line 1591 "parse.y" - {COND_POP();} - break; - - case 304: -#line 1594 "parse.y" - { - (yyval.node) = NEW_UNTIL(cond((yyvsp[(3) - (7)].node)), (yyvsp[(6) - (7)].node), 1); - fixpos((yyval.node), (yyvsp[(3) - (7)].node)); - if (cond_negative(&(yyval.node)->nd_cond)) { - nd_set_type((yyval.node), NODE_WHILE); - } - } - break; - - case 305: -#line 1604 "parse.y" - { - (yyval.node) = NEW_CASE((yyvsp[(2) - (5)].node), (yyvsp[(4) - (5)].node)); - fixpos((yyval.node), (yyvsp[(2) - (5)].node)); - } - break; - - case 306: -#line 1609 "parse.y" - { - (yyval.node) = (yyvsp[(3) - (4)].node); - } - break; - - case 307: -#line 1613 "parse.y" - { - (yyval.node) = (yyvsp[(4) - (5)].node); - } - break; - - case 308: -#line 1616 "parse.y" - {COND_PUSH(1);} - break; - - case 309: -#line 1616 "parse.y" - {COND_POP();} - break; - - case 310: -#line 1619 "parse.y" - { - (yyval.node) = NEW_FOR((yyvsp[(2) - (9)].node), (yyvsp[(5) - (9)].node), (yyvsp[(8) - (9)].node)); - fixpos((yyval.node), (yyvsp[(2) - (9)].node)); - } - break; - - case 311: -#line 1624 "parse.y" - { - if (in_def || in_single) - yyerror("class definition in method body"); - class_nest++; - local_push(0); - (yyval.num) = ruby_sourceline; - } - break; - - case 312: -#line 1633 "parse.y" - { - (yyval.node) = NEW_CLASS((yyvsp[(2) - (6)].node), (yyvsp[(5) - (6)].node), (yyvsp[(3) - (6)].node)); - nd_set_line((yyval.node), (yyvsp[(4) - (6)].num)); - local_pop(); - class_nest--; - } - break; - - case 313: -#line 1640 "parse.y" - { - (yyval.num) = in_def; - in_def = 0; - } - break; - - case 314: -#line 1645 "parse.y" - { - (yyval.num) = in_single; - in_single = 0; - class_nest++; - local_push(0); - } - break; - - case 315: -#line 1653 "parse.y" - { - (yyval.node) = NEW_SCLASS((yyvsp[(3) - (8)].node), (yyvsp[(7) - (8)].node)); - fixpos((yyval.node), (yyvsp[(3) - (8)].node)); - local_pop(); - class_nest--; - in_def = (yyvsp[(4) - (8)].num); - in_single = (yyvsp[(6) - (8)].num); - } - break; - - case 316: -#line 1662 "parse.y" - { - if (in_def || in_single) - yyerror("module definition in method body"); - class_nest++; - local_push(0); - (yyval.num) = ruby_sourceline; - } - break; - - case 317: -#line 1671 "parse.y" - { - (yyval.node) = NEW_MODULE((yyvsp[(2) - (5)].node), (yyvsp[(4) - (5)].node)); - nd_set_line((yyval.node), (yyvsp[(3) - (5)].num)); - local_pop(); - class_nest--; - } - break; - - case 318: -#line 1678 "parse.y" - { - (yyval.id) = cur_mid; - cur_mid = (yyvsp[(2) - (2)].id); - in_def++; - local_push(0); - } - break; - - case 319: -#line 1687 "parse.y" - { - if (!(yyvsp[(5) - (6)].node)) (yyvsp[(5) - (6)].node) = NEW_NIL(); - (yyval.node) = NEW_DEFN((yyvsp[(2) - (6)].id), (yyvsp[(4) - (6)].node), (yyvsp[(5) - (6)].node), NOEX_PRIVATE); - fixpos((yyval.node), (yyvsp[(4) - (6)].node)); - local_pop(); - in_def--; - cur_mid = (yyvsp[(3) - (6)].id); - } - break; - - case 320: -#line 1695 "parse.y" - {lex_state = EXPR_FNAME;} - break; - - case 321: -#line 1696 "parse.y" - { - in_single++; - local_push(0); - lex_state = EXPR_END; /* force for args */ - } - break; - - case 322: -#line 1704 "parse.y" - { - (yyval.node) = NEW_DEFS((yyvsp[(2) - (9)].node), (yyvsp[(5) - (9)].id), (yyvsp[(7) - (9)].node), (yyvsp[(8) - (9)].node)); - fixpos((yyval.node), (yyvsp[(2) - (9)].node)); - local_pop(); - in_single--; - } - break; - - case 323: -#line 1711 "parse.y" - { - (yyval.node) = NEW_BREAK(0); - } - break; - - case 324: -#line 1715 "parse.y" - { - (yyval.node) = NEW_NEXT(0); - } - break; - - case 325: -#line 1719 "parse.y" - { - (yyval.node) = NEW_REDO(); - } - break; - - case 326: -#line 1723 "parse.y" - { - (yyval.node) = NEW_RETRY(); - } - break; - - case 327: -#line 1729 "parse.y" - { - value_expr((yyvsp[(1) - (1)].node)); - (yyval.node) = (yyvsp[(1) - (1)].node); - } - break; - - case 336: -#line 1750 "parse.y" - { - (yyval.node) = NEW_IF(cond((yyvsp[(2) - (5)].node)), (yyvsp[(4) - (5)].node), (yyvsp[(5) - (5)].node)); - fixpos((yyval.node), (yyvsp[(2) - (5)].node)); - } - break; - - case 338: -#line 1758 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (2)].node); - } - break; - - case 341: -#line 1768 "parse.y" - { - (yyval.node) = NEW_LIST((yyvsp[(1) - (1)].node)); - } - break; - - case 342: -#line 1772 "parse.y" - { - (yyval.node) = list_append((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 343: -#line 1778 "parse.y" - { - if ((yyvsp[(1) - (1)].node)->nd_alen == 1) { - (yyval.node) = (yyvsp[(1) - (1)].node)->nd_head; - rb_gc_force_recycle((VALUE)(yyvsp[(1) - (1)].node)); - } - else { - (yyval.node) = NEW_MASGN((yyvsp[(1) - (1)].node), 0); - } - } - break; - - case 344: -#line 1788 "parse.y" - { - (yyval.node) = NEW_MASGN((yyvsp[(1) - (2)].node), 0); - } - break; - - case 345: -#line 1792 "parse.y" - { - (yyval.node) = NEW_BLOCK_VAR((yyvsp[(4) - (4)].node), NEW_MASGN((yyvsp[(1) - (4)].node), 0)); - } - break; - - case 346: -#line 1796 "parse.y" - { - (yyval.node) = NEW_BLOCK_VAR((yyvsp[(7) - (7)].node), NEW_MASGN((yyvsp[(1) - (7)].node), (yyvsp[(4) - (7)].node))); - } - break; - - case 347: -#line 1800 "parse.y" - { - (yyval.node) = NEW_BLOCK_VAR((yyvsp[(6) - (6)].node), NEW_MASGN((yyvsp[(1) - (6)].node), -1)); - } - break; - - case 348: -#line 1804 "parse.y" - { - (yyval.node) = NEW_MASGN((yyvsp[(1) - (4)].node), (yyvsp[(4) - (4)].node)); - } - break; - - case 349: -#line 1808 "parse.y" - { - (yyval.node) = NEW_MASGN((yyvsp[(1) - (3)].node), -1); - } - break; - - case 350: -#line 1812 "parse.y" - { - (yyval.node) = NEW_BLOCK_VAR((yyvsp[(5) - (5)].node), NEW_MASGN(0, (yyvsp[(2) - (5)].node))); - } - break; - - case 351: -#line 1816 "parse.y" - { - (yyval.node) = NEW_BLOCK_VAR((yyvsp[(4) - (4)].node), NEW_MASGN(0, -1)); - } - break; - - case 352: -#line 1820 "parse.y" - { - (yyval.node) = NEW_MASGN(0, (yyvsp[(2) - (2)].node)); - } - break; - - case 353: -#line 1824 "parse.y" - { - (yyval.node) = NEW_MASGN(0, -1); - } - break; - - case 354: -#line 1828 "parse.y" - { - (yyval.node) = NEW_BLOCK_VAR((yyvsp[(2) - (2)].node), (NODE*)1); - } - break; - - case 356: -#line 1835 "parse.y" - { - (yyval.node) = (NODE*)1; - command_start = Qtrue; - } - break; - - case 357: -#line 1840 "parse.y" - { - (yyval.node) = (NODE*)1; - command_start = Qtrue; - } - break; - - case 358: -#line 1845 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (3)].node); - command_start = Qtrue; - } - break; - - case 359: -#line 1852 "parse.y" - { - (yyval.vars) = dyna_push(); - (yyvsp[(1) - (1)].num) = ruby_sourceline; - } - break; - - case 360: -#line 1856 "parse.y" - {(yyval.vars) = ruby_dyna_vars;} - break; - - case 361: -#line 1859 "parse.y" - { - (yyval.node) = NEW_ITER((yyvsp[(3) - (6)].node), 0, dyna_init((yyvsp[(5) - (6)].node), (yyvsp[(4) - (6)].vars))); - nd_set_line((yyval.node), (yyvsp[(1) - (6)].num)); - dyna_pop((yyvsp[(2) - (6)].vars)); - } - break; - - case 362: -#line 1867 "parse.y" - { - if ((yyvsp[(1) - (2)].node) && nd_type((yyvsp[(1) - (2)].node)) == NODE_BLOCK_PASS) { - rb_compile_error("both block arg and actual block given"); - } - (yyvsp[(2) - (2)].node)->nd_iter = (yyvsp[(1) - (2)].node); - (yyval.node) = (yyvsp[(2) - (2)].node); - fixpos((yyval.node), (yyvsp[(1) - (2)].node)); - } - break; - - case 363: -#line 1876 "parse.y" - { - (yyval.node) = new_call((yyvsp[(1) - (4)].node), (yyvsp[(3) - (4)].id), (yyvsp[(4) - (4)].node)); - } - break; - - case 364: -#line 1880 "parse.y" - { - (yyval.node) = new_call((yyvsp[(1) - (4)].node), (yyvsp[(3) - (4)].id), (yyvsp[(4) - (4)].node)); - } - break; - - case 365: -#line 1886 "parse.y" - { - (yyval.node) = new_fcall((yyvsp[(1) - (2)].id), (yyvsp[(2) - (2)].node)); - fixpos((yyval.node), (yyvsp[(2) - (2)].node)); - } - break; - - case 366: -#line 1891 "parse.y" - { - (yyval.node) = new_call((yyvsp[(1) - (4)].node), (yyvsp[(3) - (4)].id), (yyvsp[(4) - (4)].node)); - fixpos((yyval.node), (yyvsp[(1) - (4)].node)); - } - break; - - case 367: -#line 1896 "parse.y" - { - (yyval.node) = new_call((yyvsp[(1) - (4)].node), (yyvsp[(3) - (4)].id), (yyvsp[(4) - (4)].node)); - fixpos((yyval.node), (yyvsp[(1) - (4)].node)); - } - break; - - case 368: -#line 1901 "parse.y" - { - (yyval.node) = new_call((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].id), 0); - } - break; - - case 369: -#line 1905 "parse.y" - { - (yyval.node) = new_super((yyvsp[(2) - (2)].node)); - } - break; - - case 370: -#line 1909 "parse.y" - { - (yyval.node) = NEW_ZSUPER(); - } - break; - - case 371: -#line 1915 "parse.y" - { - (yyval.vars) = dyna_push(); - (yyvsp[(1) - (1)].num) = ruby_sourceline; - } - break; - - case 372: -#line 1919 "parse.y" - {(yyval.vars) = ruby_dyna_vars;} - break; - - case 373: -#line 1921 "parse.y" - { - (yyval.node) = NEW_ITER((yyvsp[(3) - (6)].node), 0, dyna_init((yyvsp[(5) - (6)].node), (yyvsp[(4) - (6)].vars))); - nd_set_line((yyval.node), (yyvsp[(1) - (6)].num)); - dyna_pop((yyvsp[(2) - (6)].vars)); - } - break; - - case 374: -#line 1927 "parse.y" - { - (yyval.vars) = dyna_push(); - (yyvsp[(1) - (1)].num) = ruby_sourceline; - } - break; - - case 375: -#line 1931 "parse.y" - {(yyval.vars) = ruby_dyna_vars;} - break; - - case 376: -#line 1933 "parse.y" - { - (yyval.node) = NEW_ITER((yyvsp[(3) - (6)].node), 0, dyna_init((yyvsp[(5) - (6)].node), (yyvsp[(4) - (6)].vars))); - nd_set_line((yyval.node), (yyvsp[(1) - (6)].num)); - dyna_pop((yyvsp[(2) - (6)].vars)); - } - break; - - case 377: -#line 1943 "parse.y" - { - (yyval.node) = NEW_WHEN((yyvsp[(2) - (5)].node), (yyvsp[(4) - (5)].node), (yyvsp[(5) - (5)].node)); - } - break; - - case 379: -#line 1949 "parse.y" - { - (yyval.node) = list_append((yyvsp[(1) - (4)].node), NEW_WHEN((yyvsp[(4) - (4)].node), 0, 0)); - } - break; - - case 380: -#line 1953 "parse.y" - { - (yyval.node) = NEW_LIST(NEW_WHEN((yyvsp[(2) - (2)].node), 0, 0)); - } - break; - - case 383: -#line 1965 "parse.y" - { - if ((yyvsp[(3) - (6)].node)) { - (yyvsp[(3) - (6)].node) = node_assign((yyvsp[(3) - (6)].node), NEW_GVAR(rb_intern("$!"))); - (yyvsp[(5) - (6)].node) = block_append((yyvsp[(3) - (6)].node), (yyvsp[(5) - (6)].node)); - } - (yyval.node) = NEW_RESBODY((yyvsp[(2) - (6)].node), (yyvsp[(5) - (6)].node), (yyvsp[(6) - (6)].node)); - fixpos((yyval.node), (yyvsp[(2) - (6)].node)?(yyvsp[(2) - (6)].node):(yyvsp[(5) - (6)].node)); - } - break; - - case 385: -#line 1977 "parse.y" - { - (yyval.node) = NEW_LIST((yyvsp[(1) - (1)].node)); - } - break; - - case 388: -#line 1985 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (2)].node); - } - break; - - case 390: -#line 1992 "parse.y" - { - if ((yyvsp[(2) - (2)].node)) - (yyval.node) = (yyvsp[(2) - (2)].node); - else - /* place holder */ - (yyval.node) = NEW_NIL(); - } - break; - - case 393: -#line 2004 "parse.y" - { - (yyval.node) = NEW_LIT(ID2SYM((yyvsp[(1) - (1)].id))); - } - break; - - case 395: -#line 2011 "parse.y" - { - NODE *node = (yyvsp[(1) - (1)].node); - if (!node) { - node = NEW_STR(rb_str_new(0, 0)); - } - else { - node = evstr2dstr(node); - } - (yyval.node) = node; - } - break; - - case 397: -#line 2025 "parse.y" - { - (yyval.node) = literal_concat((yyvsp[(1) - (2)].node), (yyvsp[(2) - (2)].node)); - } - break; - - case 398: -#line 2031 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (3)].node); - } - break; - - case 399: -#line 2037 "parse.y" - { - NODE *node = (yyvsp[(2) - (3)].node); - if (!node) { - node = NEW_XSTR(rb_str_new(0, 0)); - } - else { - switch (nd_type(node)) { - case NODE_STR: - nd_set_type(node, NODE_XSTR); - break; - case NODE_DSTR: - nd_set_type(node, NODE_DXSTR); - break; - default: - node = NEW_NODE(NODE_DXSTR, rb_str_new(0, 0), 1, NEW_LIST(node)); - break; - } - } - (yyval.node) = node; - } - break; - - case 400: -#line 2060 "parse.y" - { - int options = (yyvsp[(3) - (3)].num); - NODE *node = (yyvsp[(2) - (3)].node); - if (!node) { - node = NEW_LIT(rb_reg_new("", 0, options & ~RE_OPTION_ONCE)); - } - else switch (nd_type(node)) { - case NODE_STR: - { - VALUE src = node->nd_lit; - nd_set_type(node, NODE_LIT); - node->nd_lit = rb_reg_new(RSTRING(src)->ptr, - RSTRING(src)->len, - options & ~RE_OPTION_ONCE); - } - break; - default: - node = NEW_NODE(NODE_DSTR, rb_str_new(0, 0), 1, NEW_LIST(node)); - case NODE_DSTR: - if (options & RE_OPTION_ONCE) { - nd_set_type(node, NODE_DREGX_ONCE); - } - else { - nd_set_type(node, NODE_DREGX); - } - node->nd_cflag = options & ~RE_OPTION_ONCE; - break; - } - (yyval.node) = node; - } - break; - - case 401: -#line 2093 "parse.y" - { - (yyval.node) = NEW_ZARRAY(); - } - break; - - case 402: -#line 2097 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (3)].node); - } - break; - - case 403: -#line 2103 "parse.y" - { - (yyval.node) = 0; - } - break; - - case 404: -#line 2107 "parse.y" - { - (yyval.node) = list_append((yyvsp[(1) - (3)].node), evstr2dstr((yyvsp[(2) - (3)].node))); - } - break; - - case 406: -#line 2114 "parse.y" - { - (yyval.node) = literal_concat((yyvsp[(1) - (2)].node), (yyvsp[(2) - (2)].node)); - } - break; - - case 407: -#line 2120 "parse.y" - { - (yyval.node) = NEW_ZARRAY(); - } - break; - - case 408: -#line 2124 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (3)].node); - } - break; - - case 409: -#line 2130 "parse.y" - { - (yyval.node) = 0; - } - break; - - case 410: -#line 2134 "parse.y" - { - (yyval.node) = list_append((yyvsp[(1) - (3)].node), (yyvsp[(2) - (3)].node)); - } - break; - - case 411: -#line 2140 "parse.y" - { - (yyval.node) = 0; - } - break; - - case 412: -#line 2144 "parse.y" - { - (yyval.node) = literal_concat((yyvsp[(1) - (2)].node), (yyvsp[(2) - (2)].node)); - } - break; - - case 413: -#line 2150 "parse.y" - { - (yyval.node) = 0; - } - break; - - case 414: -#line 2154 "parse.y" - { - (yyval.node) = literal_concat((yyvsp[(1) - (2)].node), (yyvsp[(2) - (2)].node)); - } - break; - - case 416: -#line 2161 "parse.y" - { - (yyval.node) = lex_strterm; - lex_strterm = 0; - lex_state = EXPR_BEG; - } - break; - - case 417: -#line 2167 "parse.y" - { - lex_strterm = (yyvsp[(2) - (3)].node); - (yyval.node) = NEW_EVSTR((yyvsp[(3) - (3)].node)); - } - break; - - case 418: -#line 2172 "parse.y" - { - (yyval.node) = lex_strterm; - lex_strterm = 0; - lex_state = EXPR_BEG; - COND_PUSH(0); - CMDARG_PUSH(0); - } - break; - - case 419: -#line 2180 "parse.y" - { - lex_strterm = (yyvsp[(2) - (4)].node); - COND_LEXPOP(); - CMDARG_LEXPOP(); - if (((yyval.node) = (yyvsp[(3) - (4)].node)) && nd_type((yyval.node)) == NODE_NEWLINE) { - (yyval.node) = (yyval.node)->nd_next; - rb_gc_force_recycle((VALUE)(yyvsp[(3) - (4)].node)); - } - (yyval.node) = new_evstr((yyval.node)); - } - break; - - case 420: -#line 2192 "parse.y" - {(yyval.node) = NEW_GVAR((yyvsp[(1) - (1)].id));} - break; - - case 421: -#line 2193 "parse.y" - {(yyval.node) = NEW_IVAR((yyvsp[(1) - (1)].id));} - break; - - case 422: -#line 2194 "parse.y" - {(yyval.node) = NEW_CVAR((yyvsp[(1) - (1)].id));} - break; - - case 424: -#line 2199 "parse.y" - { - lex_state = EXPR_END; - (yyval.id) = (yyvsp[(2) - (2)].id); - } - break; - - case 429: -#line 2212 "parse.y" - { - lex_state = EXPR_END; - if (!((yyval.node) = (yyvsp[(2) - (3)].node))) { - (yyval.node) = NEW_NIL(); - yyerror("empty symbol literal"); - } - else { - VALUE lit; - - switch (nd_type((yyval.node))) { - case NODE_DSTR: - nd_set_type((yyval.node), NODE_DSYM); - break; - case NODE_STR: - lit = (yyval.node)->nd_lit; - if (RSTRING(lit)->len == 0) { - yyerror("empty symbol literal"); - break; - } - if (strlen(RSTRING(lit)->ptr) == RSTRING(lit)->len) { - (yyval.node)->nd_lit = ID2SYM(rb_intern(RSTRING((yyval.node)->nd_lit)->ptr)); - nd_set_type((yyval.node), NODE_LIT); - break; - } - /* fall through */ - default: - (yyval.node) = NEW_NODE(NODE_DSYM, rb_str_new(0, 0), 1, NEW_LIST((yyval.node))); - break; - } - } - } - break; - - case 432: -#line 2248 "parse.y" - { - (yyval.node) = negate_lit((yyvsp[(2) - (2)].node)); - } - break; - - case 433: -#line 2252 "parse.y" - { - (yyval.node) = negate_lit((yyvsp[(2) - (2)].node)); - } - break; - - case 439: -#line 2262 "parse.y" - {(yyval.id) = kNIL;} - break; - - case 440: -#line 2263 "parse.y" - {(yyval.id) = kSELF;} - break; - - case 441: -#line 2264 "parse.y" - {(yyval.id) = kTRUE;} - break; - - case 442: -#line 2265 "parse.y" - {(yyval.id) = kFALSE;} - break; - - case 443: -#line 2266 "parse.y" - {(yyval.id) = k__FILE__;} - break; - - case 444: -#line 2267 "parse.y" - {(yyval.id) = k__LINE__;} - break; - - case 445: -#line 2271 "parse.y" - { - (yyval.node) = gettable((yyvsp[(1) - (1)].id)); - } - break; - - case 446: -#line 2277 "parse.y" - { - (yyval.node) = assignable((yyvsp[(1) - (1)].id), 0); - } - break; - - case 449: -#line 2287 "parse.y" - { - (yyval.node) = 0; - } - break; - - case 450: -#line 2291 "parse.y" - { - lex_state = EXPR_BEG; - } - break; - - case 451: -#line 2295 "parse.y" - { - (yyval.node) = (yyvsp[(3) - (4)].node); - } - break; - - case 452: -#line 2298 "parse.y" - {yyerrok; (yyval.node) = 0;} - break; - - case 453: -#line 2302 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (4)].node); - lex_state = EXPR_BEG; - command_start = Qtrue; - } - break; - - case 454: -#line 2308 "parse.y" - { - (yyval.node) = (yyvsp[(1) - (2)].node); - } - break; - - case 455: -#line 2314 "parse.y" - { - (yyval.node) = block_append(NEW_ARGS((yyvsp[(1) - (6)].num), (yyvsp[(3) - (6)].node), (yyvsp[(5) - (6)].node)), (yyvsp[(6) - (6)].node)); - } - break; - - case 456: -#line 2318 "parse.y" - { - (yyval.node) = block_append(NEW_ARGS((yyvsp[(1) - (4)].num), (yyvsp[(3) - (4)].node), 0), (yyvsp[(4) - (4)].node)); - } - break; - - case 457: -#line 2322 "parse.y" - { - (yyval.node) = block_append(NEW_ARGS((yyvsp[(1) - (4)].num), 0, (yyvsp[(3) - (4)].node)), (yyvsp[(4) - (4)].node)); - } - break; - - case 458: -#line 2326 "parse.y" - { - (yyval.node) = block_append(NEW_ARGS((yyvsp[(1) - (2)].num), 0, 0), (yyvsp[(2) - (2)].node)); - } - break; - - case 459: -#line 2330 "parse.y" - { - (yyval.node) = block_append(NEW_ARGS(0, (yyvsp[(1) - (4)].node), (yyvsp[(3) - (4)].node)), (yyvsp[(4) - (4)].node)); - } - break; - - case 460: -#line 2334 "parse.y" - { - (yyval.node) = block_append(NEW_ARGS(0, (yyvsp[(1) - (2)].node), 0), (yyvsp[(2) - (2)].node)); - } - break; - - case 461: -#line 2338 "parse.y" - { - (yyval.node) = block_append(NEW_ARGS(0, 0, (yyvsp[(1) - (2)].node)), (yyvsp[(2) - (2)].node)); - } - break; - - case 462: -#line 2342 "parse.y" - { - (yyval.node) = block_append(NEW_ARGS(0, 0, 0), (yyvsp[(1) - (1)].node)); - } - break; - - case 463: -#line 2346 "parse.y" - { - (yyval.node) = NEW_ARGS(0, 0, 0); - } - break; - - case 464: -#line 2352 "parse.y" - { - yyerror("formal argument cannot be a constant"); - } - break; - - case 465: -#line 2356 "parse.y" - { - yyerror("formal argument cannot be an instance variable"); - } - break; - - case 466: -#line 2360 "parse.y" - { - yyerror("formal argument cannot be a global variable"); - } - break; - - case 467: -#line 2364 "parse.y" - { - yyerror("formal argument cannot be a class variable"); - } - break; - - case 468: -#line 2368 "parse.y" - { - if (!is_local_id((yyvsp[(1) - (1)].id))) - yyerror("formal argument must be local variable"); - else if (local_id((yyvsp[(1) - (1)].id))) - yyerror("duplicate argument name"); - local_cnt((yyvsp[(1) - (1)].id)); - (yyval.num) = 1; - } - break; - - case 470: -#line 2380 "parse.y" - { - (yyval.num) += 1; - } - break; - - case 471: -#line 2386 "parse.y" - { - if (!is_local_id((yyvsp[(1) - (3)].id))) - yyerror("formal argument must be local variable"); - else if (local_id((yyvsp[(1) - (3)].id))) - yyerror("duplicate optional argument name"); - (yyval.node) = assignable((yyvsp[(1) - (3)].id), (yyvsp[(3) - (3)].node)); - } - break; - - case 472: -#line 2396 "parse.y" - { - (yyval.node) = NEW_BLOCK((yyvsp[(1) - (1)].node)); - (yyval.node)->nd_end = (yyval.node); - } - break; - - case 473: -#line 2401 "parse.y" - { - (yyval.node) = block_append((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 476: -#line 2411 "parse.y" - { - if (!is_local_id((yyvsp[(2) - (2)].id))) - yyerror("rest argument must be local variable"); - else if (local_id((yyvsp[(2) - (2)].id))) - yyerror("duplicate rest argument name"); - if (dyna_in_block()) { - rb_dvar_push((yyvsp[(2) - (2)].id), Qnil); - } - (yyval.node) = assignable((yyvsp[(2) - (2)].id), 0); - } - break; - - case 477: -#line 2422 "parse.y" - { - if (dyna_in_block()) { - (yyval.node) = NEW_DASGN_CURR(internal_id(), 0); - } - else { - (yyval.node) = NEW_NODE(NODE_LASGN,0,0,local_append(0)); - } - } - break; - - case 480: -#line 2437 "parse.y" - { - if (!is_local_id((yyvsp[(2) - (2)].id))) - yyerror("block argument must be local variable"); - else if (local_id((yyvsp[(2) - (2)].id))) - yyerror("duplicate block argument name"); - (yyval.node) = NEW_BLOCK_ARG((yyvsp[(2) - (2)].id)); - } - break; - - case 481: -#line 2447 "parse.y" - { - (yyval.node) = (yyvsp[(2) - (2)].node); - } - break; - - case 483: -#line 2454 "parse.y" - { - (yyval.node) = (yyvsp[(1) - (1)].node); - value_expr((yyval.node)); - } - break; - - case 484: -#line 2458 "parse.y" - {lex_state = EXPR_BEG;} - break; - - case 485: -#line 2459 "parse.y" - { - if ((yyvsp[(3) - (5)].node) == 0) { - yyerror("can't define singleton method for ()."); - } - else { - switch (nd_type((yyvsp[(3) - (5)].node))) { - case NODE_STR: - case NODE_DSTR: - case NODE_XSTR: - case NODE_DXSTR: - case NODE_DREGX: - case NODE_LIT: - case NODE_ARRAY: - case NODE_ZARRAY: - yyerror("can't define singleton method for literals"); - default: - value_expr((yyvsp[(3) - (5)].node)); - break; - } - } - (yyval.node) = (yyvsp[(3) - (5)].node); - } - break; - - case 487: -#line 2485 "parse.y" - { - (yyval.node) = (yyvsp[(1) - (2)].node); - } - break; - - case 488: -#line 2489 "parse.y" - { - if ((yyvsp[(1) - (2)].node)->nd_alen%2 != 0) { - yyerror("odd number list for Hash"); - } - (yyval.node) = (yyvsp[(1) - (2)].node); - } - break; - - case 490: -#line 2499 "parse.y" - { - (yyval.node) = list_concat((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node)); - } - break; - - case 491: -#line 2505 "parse.y" - { - (yyval.node) = list_append(NEW_LIST((yyvsp[(1) - (3)].node)), (yyvsp[(3) - (3)].node)); - } - break; - - case 511: -#line 2543 "parse.y" - {yyerrok;} - break; - - case 514: -#line 2548 "parse.y" - {yyerrok;} - break; - - case 515: -#line 2551 "parse.y" - {(yyval.node) = 0;} - break; - - -/* Line 1267 of yacc.c. */ -#line 7479 "parse.c" - default: break; - } - YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); - - YYPOPSTACK (yylen); - yylen = 0; - YY_STACK_PRINT (yyss, yyssp); - - *++yyvsp = yyval; - - - /* Now `shift' the result of the reduction. Determine what state - that goes to, based on the state we popped back to and the rule - number reduced by. */ - - yyn = yyr1[yyn]; - - yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; - if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) - yystate = yytable[yystate]; - else - yystate = yydefgoto[yyn - YYNTOKENS]; - - goto yynewstate; - - -/*------------------------------------. -| yyerrlab -- here on detecting error | -`------------------------------------*/ -yyerrlab: - /* If not already recovering from an error, report this error. */ - if (!yyerrstatus) - { - ++yynerrs; -#if ! YYERROR_VERBOSE - yyerror (YY_("syntax error")); -#else - { - YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); - if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) - { - YYSIZE_T yyalloc = 2 * yysize; - if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) - yyalloc = YYSTACK_ALLOC_MAXIMUM; - if (yymsg != yymsgbuf) - YYSTACK_FREE (yymsg); - yymsg = (char *) YYSTACK_ALLOC (yyalloc); - if (yymsg) - yymsg_alloc = yyalloc; - else - { - yymsg = yymsgbuf; - yymsg_alloc = sizeof yymsgbuf; - } - } - - if (0 < yysize && yysize <= yymsg_alloc) - { - (void) yysyntax_error (yymsg, yystate, yychar); - yyerror (yymsg); - } - else - { - yyerror (YY_("syntax error")); - if (yysize != 0) - goto yyexhaustedlab; - } - } -#endif - } - - - - if (yyerrstatus == 3) - { - /* If just tried and failed to reuse look-ahead token after an - error, discard it. */ - - if (yychar <= YYEOF) - { - /* Return failure if at end of input. */ - if (yychar == YYEOF) - YYABORT; - } - else - { - yydestruct ("Error: discarding", - yytoken, &yylval); - yychar = YYEMPTY; - } - } - - /* Else will try to reuse look-ahead token after shifting the error - token. */ - goto yyerrlab1; - - -/*---------------------------------------------------. -| yyerrorlab -- error raised explicitly by YYERROR. | -`---------------------------------------------------*/ -yyerrorlab: - - /* Pacify compilers like GCC when the user code never invokes - YYERROR and the label yyerrorlab therefore never appears in user - code. */ - if (/*CONSTCOND*/ 0) - goto yyerrorlab; - - /* Do not reclaim the symbols of the rule which action triggered - this YYERROR. */ - YYPOPSTACK (yylen); - yylen = 0; - YY_STACK_PRINT (yyss, yyssp); - yystate = *yyssp; - goto yyerrlab1; - - -/*-------------------------------------------------------------. -| yyerrlab1 -- common code for both syntax error and YYERROR. | -`-------------------------------------------------------------*/ -yyerrlab1: - yyerrstatus = 3; /* Each real token shifted decrements this. */ - - for (;;) - { - yyn = yypact[yystate]; - if (yyn != YYPACT_NINF) - { - yyn += YYTERROR; - if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) - { - yyn = yytable[yyn]; - if (0 < yyn) - break; - } - } - - /* Pop the current state because it cannot handle the error token. */ - if (yyssp == yyss) - YYABORT; - - - yydestruct ("Error: popping", - yystos[yystate], yyvsp); - YYPOPSTACK (1); - yystate = *yyssp; - YY_STACK_PRINT (yyss, yyssp); - } - - if (yyn == YYFINAL) - YYACCEPT; - - *++yyvsp = yylval; - - - /* Shift the error token. */ - YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); - - yystate = yyn; - goto yynewstate; - - -/*-------------------------------------. -| yyacceptlab -- YYACCEPT comes here. | -`-------------------------------------*/ -yyacceptlab: - yyresult = 0; - goto yyreturn; - -/*-----------------------------------. -| yyabortlab -- YYABORT comes here. | -`-----------------------------------*/ -yyabortlab: - yyresult = 1; - goto yyreturn; - -#ifndef yyoverflow -/*-------------------------------------------------. -| yyexhaustedlab -- memory exhaustion comes here. | -`-------------------------------------------------*/ -yyexhaustedlab: - yyerror (YY_("memory exhausted")); - yyresult = 2; - /* Fall through. */ -#endif - -yyreturn: - if (yychar != YYEOF && yychar != YYEMPTY) - yydestruct ("Cleanup: discarding lookahead", - yytoken, &yylval); - /* Do not reclaim the symbols of the rule which action triggered - this YYABORT or YYACCEPT. */ - YYPOPSTACK (yylen); - YY_STACK_PRINT (yyss, yyssp); - while (yyssp != yyss) - { - yydestruct ("Cleanup: popping", - yystos[*yyssp], yyvsp); - YYPOPSTACK (1); - } -#ifndef yyoverflow - if (yyss != yyssa) - YYSTACK_FREE (yyss); -#endif -#if YYERROR_VERBOSE - if (yymsg != yymsgbuf) - YYSTACK_FREE (yymsg); -#endif - /* Make sure YYID is used. */ - return YYID (yyresult); -} - - -#line 2553 "parse.y" - -#ifdef yystacksize -#undef YYMALLOC -#endif - -#include "regex.h" -#include "util.h" - -/* We remove any previous definition of `SIGN_EXTEND_CHAR', - since ours (we hope) works properly with all combinations of - machines, compilers, `char' and `unsigned char' argument types. - (Per Bothner suggested the basic approach.) */ -#undef SIGN_EXTEND_CHAR -#if __STDC__ -# define SIGN_EXTEND_CHAR(c) ((signed char)(c)) -#else /* not __STDC__ */ -/* As in Harbison and Steele. */ -# define SIGN_EXTEND_CHAR(c) ((((unsigned char)(c)) ^ 128) - 128) -#endif -#define is_identchar(c) (SIGN_EXTEND_CHAR(c)!=-1&&(ISALNUM(c) || (c) == '_' || ismbchar(c))) - -static char *tokenbuf = NULL; -static int tokidx, toksiz = 0; - -#define LEAVE_BS 1 - -static VALUE (*lex_gets)(); /* gets function */ -static VALUE lex_input; /* non-nil if File */ -static VALUE lex_lastline; /* gc protect */ -static char *lex_pbeg; -static char *lex_p; -static char *lex_pend; - -static int -yyerror(msg) - const char *msg; -{ - const int max_line_margin = 30; - const char *p, *pe; - char *buf; - int len, i; - - rb_compile_error("%s", msg); - p = lex_p; - while (lex_pbeg <= p) { - if (*p == '\n') break; - p--; - } - p++; - - pe = lex_p; - while (pe < lex_pend) { - if (*pe == '\n') break; - pe++; - } - - len = pe - p; - if (len > 4) { - char *p2; - const char *pre = "", *post = ""; - - if (len > max_line_margin * 2 + 10) { - int re_mbc_startpos _((const char *, int, int, int)); - if ((len = lex_p - p) > max_line_margin) { - p = p + re_mbc_startpos(p, len, len - max_line_margin, 0); - pre = "..."; - } - if ((len = pe - lex_p) > max_line_margin) { - pe = lex_p + re_mbc_startpos(lex_p, len, max_line_margin, 1); - post = "..."; - } - len = pe - p; - } - buf = ALLOCA_N(char, len+2); - MEMCPY(buf, p, char, len); - buf[len] = '\0'; - rb_compile_error_append("%s%s%s", pre, buf, post); - - i = lex_p - p; - p2 = buf; pe = buf + len; - - while (p2 < pe) { - if (*p2 != '\t') *p2 = ' '; - p2++; - } - buf[i] = '^'; - buf[i+1] = '\0'; - rb_compile_error_append("%s", buf); - } - - return 0; -} - -static int heredoc_end; - -int ruby_in_compile = 0; -int ruby__end__seen; - -static VALUE ruby_debug_lines; -#ifdef YYMALLOC -static NODE *parser_heap; -#endif - -static NODE* -yycompile(f, line) - char *f; - int line; -{ - int n; - NODE *node = 0; - struct RVarmap *vp, *vars = ruby_dyna_vars; - - ruby_in_compile = 1; - if (!compile_for_eval && rb_safe_level() == 0 && - rb_const_defined(rb_cObject, rb_intern("SCRIPT_LINES__"))) { - VALUE hash, fname; - - hash = rb_const_get(rb_cObject, rb_intern("SCRIPT_LINES__")); - if (TYPE(hash) == T_HASH) { - fname = rb_str_new2(f); - ruby_debug_lines = rb_ary_new(); - rb_hash_aset(hash, fname, ruby_debug_lines); - } - if (line > 1) { - VALUE str = rb_str_new(0,0); - while (line > 1) { - rb_ary_push(ruby_debug_lines, str); - line--; - } - } - } - - ruby__end__seen = 0; - ruby_eval_tree = 0; - ruby_eval_tree_begin = 0; - heredoc_end = 0; - lex_strterm = 0; - ruby_current_node = 0; - ruby_sourcefile = rb_source_filename(f); - n = yyparse(); - ruby_debug_lines = 0; - compile_for_eval = 0; - ruby_in_compile = 0; - cond_stack = 0; - cmdarg_stack = 0; - command_start = 1; - class_nest = 0; - in_single = 0; - in_def = 0; - cur_mid = 0; - - vp = ruby_dyna_vars; - ruby_dyna_vars = vars; - lex_strterm = 0; - while (vp && vp != vars) { - struct RVarmap *tmp = vp; - vp = vp->next; - rb_gc_force_recycle((VALUE)tmp); - } - if (n == 0) node = ruby_eval_tree; - if (ruby_nerrs) ruby_eval_tree_begin = 0; - return node; -} - -static int lex_gets_ptr; - -static VALUE -lex_get_str(s) - VALUE s; -{ - char *beg, *end, *pend; - - beg = RSTRING(s)->ptr; - if (lex_gets_ptr) { - if (RSTRING(s)->len == lex_gets_ptr) return Qnil; - beg += lex_gets_ptr; - } - pend = RSTRING(s)->ptr + RSTRING(s)->len; - end = beg; - while (end < pend) { - if (*end++ == '\n') break; - } - lex_gets_ptr = end - RSTRING(s)->ptr; - return rb_str_new(beg, end - beg); -} - -static VALUE -lex_getline() -{ - VALUE line = (*lex_gets)(lex_input); - if (ruby_debug_lines && !NIL_P(line)) { - rb_ary_push(ruby_debug_lines, line); - } - return line; -} - -NODE* -rb_compile_string(f, s, line) - const char *f; - VALUE s; - int line; -{ - lex_gets = lex_get_str; - lex_gets_ptr = 0; - lex_input = s; - lex_pbeg = lex_p = lex_pend = 0; - ruby_sourceline = line - 1; - compile_for_eval = ruby_in_eval; - - return yycompile(f, line); -} - -NODE* -rb_compile_cstr(f, s, len, line) - const char *f, *s; - int len, line; -{ - return rb_compile_string(f, rb_str_new(s, len), line); -} - -NODE* -rb_compile_file(f, file, start) - const char *f; - VALUE file; - int start; -{ - lex_gets = rb_io_gets; - lex_input = file; - lex_pbeg = lex_p = lex_pend = 0; - ruby_sourceline = start - 1; - - return yycompile(f, start); -} - -static inline int -nextc() -{ - int c; - - if (lex_p == lex_pend) { - if (lex_input) { - VALUE v = lex_getline(); - - if (NIL_P(v)) return -1; - if (heredoc_end > 0) { - ruby_sourceline = heredoc_end; - heredoc_end = 0; - } - ruby_sourceline++; - lex_pbeg = lex_p = RSTRING(v)->ptr; - lex_pend = lex_p + RSTRING(v)->len; - lex_lastline = v; - } - else { - lex_lastline = 0; - return -1; - } - } - c = (unsigned char)*lex_p++; - if (c == '\r' && lex_p < lex_pend && *lex_p == '\n') { - lex_p++; - c = '\n'; - } - - return c; -} - -static void -pushback(c) - int c; -{ - if (c == -1) return; - lex_p--; -} - -#define was_bol() (lex_p == lex_pbeg + 1) -#define peek(c) (lex_p != lex_pend && (c) == *lex_p) - -#define tokfix() (tokenbuf[tokidx]='\0') -#define tok() tokenbuf -#define toklen() tokidx -#define toklast() (tokidx>0?tokenbuf[tokidx-1]:0) - -static char* -newtok() -{ - tokidx = 0; - if (!tokenbuf) { - toksiz = 60; - tokenbuf = ALLOC_N(char, 60); - } - if (toksiz > 4096) { - toksiz = 60; - REALLOC_N(tokenbuf, char, 60); - } - return tokenbuf; -} - -static void -tokadd(c) - char c; -{ - tokenbuf[tokidx++] = c; - if (tokidx >= toksiz) { - toksiz *= 2; - REALLOC_N(tokenbuf, char, toksiz); - } -} - -static int -read_escape() -{ - int c; - - switch (c = nextc()) { - case '\\': /* Backslash */ - return c; - - case 'n': /* newline */ - return '\n'; - - case 't': /* horizontal tab */ - return '\t'; - - case 'r': /* carriage-return */ - return '\r'; - - case 'f': /* form-feed */ - return '\f'; - - case 'v': /* vertical tab */ - return '\13'; - - case 'a': /* alarm(bell) */ - return '\007'; - - case 'e': /* escape */ - return 033; - - case '0': case '1': case '2': case '3': /* octal constant */ - case '4': case '5': case '6': case '7': - { - int numlen; - - pushback(c); - c = scan_oct(lex_p, 3, &numlen); - lex_p += numlen; - } - return c; - - case 'x': /* hex constant */ - { - int numlen; - - c = scan_hex(lex_p, 2, &numlen); - if (numlen == 0) { - yyerror("Invalid escape character syntax"); - return 0; - } - lex_p += numlen; - } - return c; - - case 'b': /* backspace */ - return '\010'; - - case 's': /* space */ - return ' '; - - case 'M': - if ((c = nextc()) != '-') { - yyerror("Invalid escape character syntax"); - pushback(c); - return '\0'; - } - if ((c = nextc()) == '\\') { - return read_escape() | 0x80; - } - else if (c == -1) goto eof; - else { - return ((c & 0xff) | 0x80); - } - - case 'C': - if ((c = nextc()) != '-') { - yyerror("Invalid escape character syntax"); - pushback(c); - return '\0'; - } - case 'c': - if ((c = nextc())== '\\') { - c = read_escape(); - } - else if (c == '?') - return 0177; - else if (c == -1) goto eof; - return c & 0x9f; - - eof: - case -1: - yyerror("Invalid escape character syntax"); - return '\0'; - - default: - return c; - } -} - -static int -tokadd_escape() -{ - int c; - - switch (c = nextc()) { - case '\n': - return 0; /* just ignore */ - - case '0': case '1': case '2': case '3': /* octal constant */ - case '4': case '5': case '6': case '7': - { - int i; - - tokadd('\\'); - tokadd(c); - for (i=0; i<2; i++) { - c = nextc(); - if (c == -1) goto eof; - if (c < '0' || '7' < c) { - pushback(c); - break; - } - tokadd(c); - } - } - return 0; - - case 'x': /* hex constant */ - { - int numlen; - - tokadd('\\'); - tokadd(c); - scan_hex(lex_p, 2, &numlen); - if (numlen == 0) { - yyerror("Invalid escape character syntax"); - return -1; - } - while (numlen--) - tokadd(nextc()); - } - return 0; - - case 'M': - if ((c = nextc()) != '-') { - yyerror("Invalid escape character syntax"); - pushback(c); - return 0; - } - tokadd('\\'); tokadd('M'); tokadd('-'); - goto escaped; - - case 'C': - if ((c = nextc()) != '-') { - yyerror("Invalid escape character syntax"); - pushback(c); - return 0; - } - tokadd('\\'); tokadd('C'); tokadd('-'); - goto escaped; - - case 'c': - tokadd('\\'); tokadd('c'); - escaped: - if ((c = nextc()) == '\\') { - return tokadd_escape(); - } - else if (c == -1) goto eof; - tokadd(c); - return 0; - - eof: - case -1: - yyerror("Invalid escape character syntax"); - return -1; - - default: - tokadd('\\'); - tokadd(c); - } - return 0; -} - -static int -regx_options() -{ - char kcode = 0; - int options = 0; - int c; - - newtok(); - while (c = nextc(), ISALPHA(c)) { - switch (c) { - case 'i': - options |= RE_OPTION_IGNORECASE; - break; - case 'x': - options |= RE_OPTION_EXTENDED; - break; - case 'm': - options |= RE_OPTION_MULTILINE; - break; - case 'o': - options |= RE_OPTION_ONCE; - break; - case 'n': - kcode = 16; - break; - case 'e': - kcode = 32; - break; - case 's': - kcode = 48; - break; - case 'u': - kcode = 64; - break; - default: - tokadd(c); - break; - } - } - pushback(c); - if (toklen()) { - tokfix(); - rb_compile_error("unknown regexp option%s - %s", - toklen() > 1 ? "s" : "", tok()); - } - return options | kcode; -} - -#define STR_FUNC_ESCAPE 0x01 -#define STR_FUNC_EXPAND 0x02 -#define STR_FUNC_REGEXP 0x04 -#define STR_FUNC_QWORDS 0x08 -#define STR_FUNC_SYMBOL 0x10 -#define STR_FUNC_INDENT 0x20 - -enum string_type { - str_squote = (0), - str_dquote = (STR_FUNC_EXPAND), - str_xquote = (STR_FUNC_EXPAND), - str_regexp = (STR_FUNC_REGEXP|STR_FUNC_ESCAPE|STR_FUNC_EXPAND), - str_sword = (STR_FUNC_QWORDS), - str_dword = (STR_FUNC_QWORDS|STR_FUNC_EXPAND), - str_ssym = (STR_FUNC_SYMBOL), - str_dsym = (STR_FUNC_SYMBOL|STR_FUNC_EXPAND), -}; - -static void -dispose_string(str) - VALUE str; -{ - xfree(RSTRING(str)->ptr); - rb_gc_force_recycle(str); -} - -static int -tokadd_string(func, term, paren, nest) - int func, term, paren, *nest; -{ - int c; - - while ((c = nextc()) != -1) { - if (paren && c == paren) { - ++*nest; - } - else if (c == term) { - if (!nest || !*nest) { - pushback(c); - break; - } - --*nest; - } - else if ((func & STR_FUNC_EXPAND) && c == '#' && lex_p < lex_pend) { - int c2 = *lex_p; - if (c2 == '$' || c2 == '@' || c2 == '{') { - pushback(c); - break; - } - } - else if (c == '\\') { - c = nextc(); - switch (c) { - case '\n': - if (func & STR_FUNC_QWORDS) break; - if (func & STR_FUNC_EXPAND) continue; - tokadd('\\'); - break; - - case '\\': - if (func & STR_FUNC_ESCAPE) tokadd(c); - break; - - default: - if (func & STR_FUNC_REGEXP) { - pushback(c); - if (tokadd_escape() < 0) - return -1; - continue; - } - else if (func & STR_FUNC_EXPAND) { - pushback(c); - if (func & STR_FUNC_ESCAPE) tokadd('\\'); - c = read_escape(); - } - else if ((func & STR_FUNC_QWORDS) && ISSPACE(c)) { - /* ignore backslashed spaces in %w */ - } - else if (c != term && !(paren && c == paren)) { - tokadd('\\'); - } - } - } - else if (ismbchar(c)) { - int i, len = mbclen(c)-1; - - for (i = 0; i < len; i++) { - tokadd(c); - c = nextc(); - } - } - else if ((func & STR_FUNC_QWORDS) && ISSPACE(c)) { - pushback(c); - break; - } - if (!c && (func & STR_FUNC_SYMBOL)) { - func &= ~STR_FUNC_SYMBOL; - rb_compile_error("symbol cannot contain '\\0'"); - continue; - } - tokadd(c); - } - return c; -} - -#define NEW_STRTERM(func, term, paren) \ - rb_node_newnode(NODE_STRTERM, (func), (term) | ((paren) << (CHAR_BIT * 2)), 0) - -static int -parse_string(quote) - NODE *quote; -{ - int func = quote->nd_func; - int term = nd_term(quote); - int paren = nd_paren(quote); - int c, space = 0; - - if (func == -1) return tSTRING_END; - c = nextc(); - if ((func & STR_FUNC_QWORDS) && ISSPACE(c)) { - do {c = nextc();} while (ISSPACE(c)); - space = 1; - } - if (c == term && !quote->nd_nest) { - if (func & STR_FUNC_QWORDS) { - quote->nd_func = -1; - return ' '; - } - if (!(func & STR_FUNC_REGEXP)) return tSTRING_END; - yylval.num = regx_options(); - return tREGEXP_END; - } - if (space) { - pushback(c); - return ' '; - } - newtok(); - if ((func & STR_FUNC_EXPAND) && c == '#') { - switch (c = nextc()) { - case '$': - case '@': - pushback(c); - return tSTRING_DVAR; - case '{': - return tSTRING_DBEG; - } - tokadd('#'); - } - pushback(c); - if (tokadd_string(func, term, paren, "e->nd_nest) == -1) { - ruby_sourceline = nd_line(quote); - rb_compile_error("unterminated string meets end of file"); - return tSTRING_END; - } - - tokfix(); - yylval.node = NEW_STR(rb_str_new(tok(), toklen())); - return tSTRING_CONTENT; -} - -static int -heredoc_identifier() -{ - int c = nextc(), term, func = 0, len; - - if (c == '-') { - c = nextc(); - func = STR_FUNC_INDENT; - } - switch (c) { - case '\'': - func |= str_squote; goto quoted; - case '"': - func |= str_dquote; goto quoted; - case '`': - func |= str_xquote; - quoted: - newtok(); - tokadd(func); - term = c; - while ((c = nextc()) != -1 && c != term) { - len = mbclen(c); - do {tokadd(c);} while (--len > 0 && (c = nextc()) != -1); - } - if (c == -1) { - rb_compile_error("unterminated here document identifier"); - return 0; - } - break; - - default: - if (!is_identchar(c)) { - pushback(c); - if (func & STR_FUNC_INDENT) { - pushback('-'); - } - return 0; - } - newtok(); - term = '"'; - tokadd(func |= str_dquote); - do { - len = mbclen(c); - do {tokadd(c);} while (--len > 0 && (c = nextc()) != -1); - } while ((c = nextc()) != -1 && is_identchar(c)); - pushback(c); - break; - } - - tokfix(); - len = lex_p - lex_pbeg; - lex_p = lex_pend; - lex_strterm = rb_node_newnode(NODE_HEREDOC, - rb_str_new(tok(), toklen()), /* nd_lit */ - len, /* nd_nth */ - lex_lastline); /* nd_orig */ - return term == '`' ? tXSTRING_BEG : tSTRING_BEG; -} - -static void -heredoc_restore(here) - NODE *here; -{ - VALUE line = here->nd_orig; - lex_lastline = line; - lex_pbeg = RSTRING(line)->ptr; - lex_pend = lex_pbeg + RSTRING(line)->len; - lex_p = lex_pbeg + here->nd_nth; - heredoc_end = ruby_sourceline; - ruby_sourceline = nd_line(here); - dispose_string(here->nd_lit); - rb_gc_force_recycle((VALUE)here); -} - -static int -whole_match_p(eos, len, indent) - char *eos; - int len, indent; -{ - char *p = lex_pbeg; - int n; - - if (indent) { - while (*p && ISSPACE(*p)) p++; - } - n= lex_pend - (p + len); - if (n < 0 || (n > 0 && p[len] != '\n' && p[len] != '\r')) return Qfalse; - if (strncmp(eos, p, len) == 0) return Qtrue; - return Qfalse; -} - -static int -here_document(here) - NODE *here; -{ - int c, func, indent = 0; - char *eos, *p, *pend; - long len; - VALUE str = 0; - - eos = RSTRING(here->nd_lit)->ptr; - len = RSTRING(here->nd_lit)->len - 1; - indent = (func = *eos++) & STR_FUNC_INDENT; - - if ((c = nextc()) == -1) { - error: - rb_compile_error("can't find string \"%s\" anywhere before EOF", eos); - heredoc_restore(lex_strterm); - lex_strterm = 0; - return 0; - } - if (was_bol() && whole_match_p(eos, len, indent)) { - heredoc_restore(lex_strterm); - return tSTRING_END; - } - - if (!(func & STR_FUNC_EXPAND)) { - do { - p = RSTRING(lex_lastline)->ptr; - pend = lex_pend; - if (pend > p) { - switch (pend[-1]) { - case '\n': - if (--pend == p || pend[-1] != '\r') { - pend++; - break; - } - case '\r': - --pend; - } - } - if (str) - rb_str_cat(str, p, pend - p); - else - str = rb_str_new(p, pend - p); - if (pend < lex_pend) rb_str_cat(str, "\n", 1); - lex_p = lex_pend; - if (nextc() == -1) { - if (str) dispose_string(str); - goto error; - } - } while (!whole_match_p(eos, len, indent)); - } - else { - newtok(); - if (c == '#') { - switch (c = nextc()) { - case '$': - case '@': - pushback(c); - return tSTRING_DVAR; - case '{': - return tSTRING_DBEG; - } - tokadd('#'); - } - do { - pushback(c); - if ((c = tokadd_string(func, '\n', 0, NULL)) == -1) goto error; - if (c != '\n') { - yylval.node = NEW_STR(rb_str_new(tok(), toklen())); - return tSTRING_CONTENT; - } - tokadd(nextc()); - if ((c = nextc()) == -1) goto error; - } while (!whole_match_p(eos, len, indent)); - str = rb_str_new(tok(), toklen()); - } - heredoc_restore(lex_strterm); - lex_strterm = NEW_STRTERM(-1, 0, 0); - yylval.node = NEW_STR(str); - return tSTRING_CONTENT; -} - -#include "lex.c" - -static void -arg_ambiguous() -{ - rb_warning("ambiguous first argument; put parentheses or even spaces"); -} - -#define IS_ARG() (lex_state == EXPR_ARG || lex_state == EXPR_CMDARG) - -static int -yylex() -{ - register int c; - int space_seen = 0; - int cmd_state; - enum lex_state last_state; - - if (lex_strterm) { - int token; - if (nd_type(lex_strterm) == NODE_HEREDOC) { - token = here_document(lex_strterm); - if (token == tSTRING_END) { - lex_strterm = 0; - lex_state = EXPR_END; - } - } - else { - token = parse_string(lex_strterm); - if (token == tSTRING_END || token == tREGEXP_END) { - rb_gc_force_recycle((VALUE)lex_strterm); - lex_strterm = 0; - lex_state = EXPR_END; - } - } - return token; - } - cmd_state = command_start; - command_start = Qfalse; - retry: - switch (c = nextc()) { - case '\0': /* NUL */ - case '\004': /* ^D */ - case '\032': /* ^Z */ - case -1: /* end of script. */ - return 0; - - /* white spaces */ - case ' ': case '\t': case '\f': case '\r': - case '\13': /* '\v' */ - space_seen++; - goto retry; - - case '#': /* it's a comment */ - while ((c = nextc()) != '\n') { - if (c == -1) - return 0; - } - /* fall through */ - case '\n': - switch (lex_state) { - case EXPR_BEG: - case EXPR_FNAME: - case EXPR_DOT: - case EXPR_CLASS: - goto retry; - default: - break; - } - command_start = Qtrue; - lex_state = EXPR_BEG; - return '\n'; - - case '*': - if ((c = nextc()) == '*') { - if ((c = nextc()) == '=') { - yylval.id = tPOW; - lex_state = EXPR_BEG; - return tOP_ASGN; - } - pushback(c); - c = tPOW; - } - else { - if (c == '=') { - yylval.id = '*'; - lex_state = EXPR_BEG; - return tOP_ASGN; - } - pushback(c); - if (IS_ARG() && space_seen && !ISSPACE(c)){ - rb_warning("`*' interpreted as argument prefix"); - c = tSTAR; - } - else if (lex_state == EXPR_BEG || lex_state == EXPR_MID) { - c = tSTAR; - } - else { - c = '*'; - } - } - switch (lex_state) { - case EXPR_FNAME: case EXPR_DOT: - lex_state = EXPR_ARG; break; - default: - lex_state = EXPR_BEG; break; - } - return c; - - case '!': - lex_state = EXPR_BEG; - if ((c = nextc()) == '=') { - return tNEQ; - } - if (c == '~') { - return tNMATCH; - } - pushback(c); - return '!'; - - case '=': - if (was_bol()) { - /* skip embedded rd document */ - if (strncmp(lex_p, "begin", 5) == 0 && ISSPACE(lex_p[5])) { - for (;;) { - lex_p = lex_pend; - c = nextc(); - if (c == -1) { - rb_compile_error("embedded document meets end of file"); - return 0; - } - if (c != '=') continue; - if (strncmp(lex_p, "end", 3) == 0 && - (lex_p + 3 == lex_pend || ISSPACE(lex_p[3]))) { - break; - } - } - lex_p = lex_pend; - goto retry; - } - } - - switch (lex_state) { - case EXPR_FNAME: case EXPR_DOT: - lex_state = EXPR_ARG; break; - default: - lex_state = EXPR_BEG; break; - } - if ((c = nextc()) == '=') { - if ((c = nextc()) == '=') { - return tEQQ; - } - pushback(c); - return tEQ; - } - if (c == '~') { - return tMATCH; - } - else if (c == '>') { - return tASSOC; - } - pushback(c); - return '='; - - case '<': - c = nextc(); - if (c == '<' && - lex_state != EXPR_END && - lex_state != EXPR_DOT && - lex_state != EXPR_ENDARG && - lex_state != EXPR_CLASS && - (!IS_ARG() || space_seen)) { - int token = heredoc_identifier(); - if (token) return token; - } - switch (lex_state) { - case EXPR_FNAME: case EXPR_DOT: - lex_state = EXPR_ARG; break; - default: - lex_state = EXPR_BEG; break; - } - if (c == '=') { - if ((c = nextc()) == '>') { - return tCMP; - } - pushback(c); - return tLEQ; - } - if (c == '<') { - if ((c = nextc()) == '=') { - yylval.id = tLSHFT; - lex_state = EXPR_BEG; - return tOP_ASGN; - } - pushback(c); - return tLSHFT; - } - pushback(c); - return '<'; - - case '>': - switch (lex_state) { - case EXPR_FNAME: case EXPR_DOT: - lex_state = EXPR_ARG; break; - default: - lex_state = EXPR_BEG; break; - } - if ((c = nextc()) == '=') { - return tGEQ; - } - if (c == '>') { - if ((c = nextc()) == '=') { - yylval.id = tRSHFT; - lex_state = EXPR_BEG; - return tOP_ASGN; - } - pushback(c); - return tRSHFT; - } - pushback(c); - return '>'; - - case '"': - lex_strterm = NEW_STRTERM(str_dquote, '"', 0); - return tSTRING_BEG; - - case '`': - if (lex_state == EXPR_FNAME) { - lex_state = EXPR_END; - return c; - } - if (lex_state == EXPR_DOT) { - if (cmd_state) - lex_state = EXPR_CMDARG; - else - lex_state = EXPR_ARG; - return c; - } - lex_strterm = NEW_STRTERM(str_xquote, '`', 0); - return tXSTRING_BEG; - - case '\'': - lex_strterm = NEW_STRTERM(str_squote, '\'', 0); - return tSTRING_BEG; - - case '?': - if (lex_state == EXPR_END || lex_state == EXPR_ENDARG) { - lex_state = EXPR_BEG; - return '?'; - } - c = nextc(); - if (c == -1) { - rb_compile_error("incomplete character syntax"); - return 0; - } - if (ISSPACE(c)){ - if (!IS_ARG()){ - int c2 = 0; - switch (c) { - case ' ': - c2 = 's'; - break; - case '\n': - c2 = 'n'; - break; - case '\t': - c2 = 't'; - break; - case '\v': - c2 = 'v'; - break; - case '\r': - c2 = 'r'; - break; - case '\f': - c2 = 'f'; - break; - } - if (c2) { - rb_warn("invalid character syntax; use ?\\%c", c2); - } - } - ternary: - pushback(c); - lex_state = EXPR_BEG; - return '?'; - } - else if (ismbchar(c)) { - rb_warn("multibyte character literal not supported yet; use ?\\%.3o", c); - goto ternary; - } - else if ((ISALNUM(c) || c == '_') && lex_p < lex_pend && is_identchar(*lex_p)) { - goto ternary; - } - else if (c == '\\') { - c = read_escape(); - } - c &= 0xff; - lex_state = EXPR_END; - yylval.node = NEW_LIT(INT2FIX(c)); - return tINTEGER; - - case '&': - if ((c = nextc()) == '&') { - lex_state = EXPR_BEG; - if ((c = nextc()) == '=') { - yylval.id = tANDOP; - lex_state = EXPR_BEG; - return tOP_ASGN; - } - pushback(c); - return tANDOP; - } - else if (c == '=') { - yylval.id = '&'; - lex_state = EXPR_BEG; - return tOP_ASGN; - } - pushback(c); - if (IS_ARG() && space_seen && !ISSPACE(c)){ - rb_warning("`&' interpreted as argument prefix"); - c = tAMPER; - } - else if (lex_state == EXPR_BEG || lex_state == EXPR_MID) { - c = tAMPER; - } - else { - c = '&'; - } - switch (lex_state) { - case EXPR_FNAME: case EXPR_DOT: - lex_state = EXPR_ARG; break; - default: - lex_state = EXPR_BEG; - } - return c; - - case '|': - if ((c = nextc()) == '|') { - lex_state = EXPR_BEG; - if ((c = nextc()) == '=') { - yylval.id = tOROP; - lex_state = EXPR_BEG; - return tOP_ASGN; - } - pushback(c); - return tOROP; - } - if (c == '=') { - yylval.id = '|'; - lex_state = EXPR_BEG; - return tOP_ASGN; - } - if (lex_state == EXPR_FNAME || lex_state == EXPR_DOT) { - lex_state = EXPR_ARG; - } - else { - lex_state = EXPR_BEG; - } - pushback(c); - return '|'; - - case '+': - c = nextc(); - if (lex_state == EXPR_FNAME || lex_state == EXPR_DOT) { - lex_state = EXPR_ARG; - if (c == '@') { - return tUPLUS; - } - pushback(c); - return '+'; - } - if (c == '=') { - yylval.id = '+'; - lex_state = EXPR_BEG; - return tOP_ASGN; - } - if (lex_state == EXPR_BEG || lex_state == EXPR_MID || - (IS_ARG() && space_seen && !ISSPACE(c))) { - if (IS_ARG()) arg_ambiguous(); - lex_state = EXPR_BEG; - pushback(c); - if (ISDIGIT(c)) { - c = '+'; - goto start_num; - } - return tUPLUS; - } - lex_state = EXPR_BEG; - pushback(c); - return '+'; - - case '-': - c = nextc(); - if (lex_state == EXPR_FNAME || lex_state == EXPR_DOT) { - lex_state = EXPR_ARG; - if (c == '@') { - return tUMINUS; - } - pushback(c); - return '-'; - } - if (c == '=') { - yylval.id = '-'; - lex_state = EXPR_BEG; - return tOP_ASGN; - } - if (lex_state == EXPR_BEG || lex_state == EXPR_MID || - (IS_ARG() && space_seen && !ISSPACE(c))) { - if (IS_ARG()) arg_ambiguous(); - lex_state = EXPR_BEG; - pushback(c); - if (ISDIGIT(c)) { - return tUMINUS_NUM; - } - return tUMINUS; - } - lex_state = EXPR_BEG; - pushback(c); - return '-'; - - case '.': - lex_state = EXPR_BEG; - if ((c = nextc()) == '.') { - if ((c = nextc()) == '.') { - return tDOT3; - } - pushback(c); - return tDOT2; - } - pushback(c); - if (ISDIGIT(c)) { - yyerror("no . floating literal anymore; put 0 before dot"); - } - lex_state = EXPR_DOT; - return '.'; - - start_num: - case '0': case '1': case '2': case '3': case '4': - case '5': case '6': case '7': case '8': case '9': - { - int is_float, seen_point, seen_e, nondigit; - - is_float = seen_point = seen_e = nondigit = 0; - lex_state = EXPR_END; - newtok(); - if (c == '-' || c == '+') { - tokadd(c); - c = nextc(); - } - if (c == '0') { - int start = toklen(); - c = nextc(); - if (c == 'x' || c == 'X') { - /* hexadecimal */ - c = nextc(); - if (ISXDIGIT(c)) { - do { - if (c == '_') { - if (nondigit) break; - nondigit = c; - continue; - } - if (!ISXDIGIT(c)) break; - nondigit = 0; - tokadd(c); - } while ((c = nextc()) != -1); - } - pushback(c); - tokfix(); - if (toklen() == start) { - yyerror("numeric literal without digits"); - } - else if (nondigit) goto trailing_uc; - yylval.node = NEW_LIT(rb_cstr_to_inum(tok(), 16, Qfalse)); - return tINTEGER; - } - if (c == 'b' || c == 'B') { - /* binary */ - c = nextc(); - if (c == '0' || c == '1') { - do { - if (c == '_') { - if (nondigit) break; - nondigit = c; - continue; - } - if (c != '0' && c != '1') break; - nondigit = 0; - tokadd(c); - } while ((c = nextc()) != -1); - } - pushback(c); - tokfix(); - if (toklen() == start) { - yyerror("numeric literal without digits"); - } - else if (nondigit) goto trailing_uc; - yylval.node = NEW_LIT(rb_cstr_to_inum(tok(), 2, Qfalse)); - return tINTEGER; - } - if (c == 'd' || c == 'D') { - /* decimal */ - c = nextc(); - if (ISDIGIT(c)) { - do { - if (c == '_') { - if (nondigit) break; - nondigit = c; - continue; - } - if (!ISDIGIT(c)) break; - nondigit = 0; - tokadd(c); - } while ((c = nextc()) != -1); - } - pushback(c); - tokfix(); - if (toklen() == start) { - yyerror("numeric literal without digits"); - } - else if (nondigit) goto trailing_uc; - yylval.node = NEW_LIT(rb_cstr_to_inum(tok(), 10, Qfalse)); - return tINTEGER; - } - if (c == '_') { - /* 0_0 */ - goto octal_number; - } - if (c == 'o' || c == 'O') { - /* prefixed octal */ - c = nextc(); - if (c == '_') { - yyerror("numeric literal without digits"); - } - } - if (c >= '0' && c <= '7') { - /* octal */ - octal_number: - do { - if (c == '_') { - if (nondigit) break; - nondigit = c; - continue; - } - if (c < '0' || c > '7') break; - nondigit = 0; - tokadd(c); - } while ((c = nextc()) != -1); - if (toklen() > start) { - pushback(c); - tokfix(); - if (nondigit) goto trailing_uc; - yylval.node = NEW_LIT(rb_cstr_to_inum(tok(), 8, Qfalse)); - return tINTEGER; - } - if (nondigit) { - pushback(c); - goto trailing_uc; - } - } - if (c > '7' && c <= '9') { - yyerror("Illegal octal digit"); - } - else if (c == '.' || c == 'e' || c == 'E') { - tokadd('0'); - } - else { - pushback(c); - yylval.node = NEW_LIT(INT2FIX(0)); - return tINTEGER; - } - } - - for (;;) { - switch (c) { - case '0': case '1': case '2': case '3': case '4': - case '5': case '6': case '7': case '8': case '9': - nondigit = 0; - tokadd(c); - break; - - case '.': - if (nondigit) goto trailing_uc; - if (seen_point || seen_e) { - goto decode_num; - } - else { - int c0 = nextc(); - if (!ISDIGIT(c0)) { - pushback(c0); - goto decode_num; - } - c = c0; - } - tokadd('.'); - tokadd(c); - is_float++; - seen_point++; - nondigit = 0; - break; - - case 'e': - case 'E': - if (nondigit) { - pushback(c); - c = nondigit; - goto decode_num; - } - if (seen_e) { - goto decode_num; - } - tokadd(c); - seen_e++; - is_float++; - nondigit = c; - c = nextc(); - if (c != '-' && c != '+') continue; - tokadd(c); - nondigit = c; - break; - - case '_': /* `_' in number just ignored */ - if (nondigit) goto decode_num; - nondigit = c; - break; - - default: - goto decode_num; - } - c = nextc(); - } - - decode_num: - pushback(c); - tokfix(); - if (nondigit) { - char tmp[30]; - trailing_uc: - sprintf(tmp, "trailing `%c' in number", nondigit); - yyerror(tmp); - } - if (is_float) { - double d = strtod(tok(), 0); - if (errno == ERANGE) { - rb_warn("Float %s out of range", tok()); - errno = 0; - } - yylval.node = NEW_LIT(rb_float_new(d)); - return tFLOAT; - } - yylval.node = NEW_LIT(rb_cstr_to_inum(tok(), 10, Qfalse)); - return tINTEGER; - } - - case ']': - case '}': - case ')': - COND_LEXPOP(); - CMDARG_LEXPOP(); - lex_state = EXPR_END; - return c; - - case ':': - c = nextc(); - if (c == ':') { - if (lex_state == EXPR_BEG || lex_state == EXPR_MID || - lex_state == EXPR_CLASS || (IS_ARG() && space_seen)) { - lex_state = EXPR_BEG; - return tCOLON3; - } - lex_state = EXPR_DOT; - return tCOLON2; - } - if (lex_state == EXPR_END || lex_state == EXPR_ENDARG || ISSPACE(c)) { - pushback(c); - lex_state = EXPR_BEG; - return ':'; - } - switch (c) { - case '\'': - lex_strterm = NEW_STRTERM(str_ssym, c, 0); - break; - case '"': - lex_strterm = NEW_STRTERM(str_dsym, c, 0); - break; - default: - pushback(c); - break; - } - lex_state = EXPR_FNAME; - return tSYMBEG; - - case '/': - if (lex_state == EXPR_BEG || lex_state == EXPR_MID) { - lex_strterm = NEW_STRTERM(str_regexp, '/', 0); - return tREGEXP_BEG; - } - if ((c = nextc()) == '=') { - yylval.id = '/'; - lex_state = EXPR_BEG; - return tOP_ASGN; - } - pushback(c); - if (IS_ARG() && space_seen) { - if (!ISSPACE(c)) { - arg_ambiguous(); - lex_strterm = NEW_STRTERM(str_regexp, '/', 0); - return tREGEXP_BEG; - } - } - switch (lex_state) { - case EXPR_FNAME: case EXPR_DOT: - lex_state = EXPR_ARG; break; - default: - lex_state = EXPR_BEG; break; - } - return '/'; - - case '^': - if ((c = nextc()) == '=') { - yylval.id = '^'; - lex_state = EXPR_BEG; - return tOP_ASGN; - } - switch (lex_state) { - case EXPR_FNAME: case EXPR_DOT: - lex_state = EXPR_ARG; break; - default: - lex_state = EXPR_BEG; break; - } - pushback(c); - return '^'; - - case ';': - command_start = Qtrue; - case ',': - lex_state = EXPR_BEG; - return c; - - case '~': - if (lex_state == EXPR_FNAME || lex_state == EXPR_DOT) { - if ((c = nextc()) != '@') { - pushback(c); - } - } - switch (lex_state) { - case EXPR_FNAME: case EXPR_DOT: - lex_state = EXPR_ARG; break; - default: - lex_state = EXPR_BEG; break; - } - return '~'; - - case '(': - command_start = Qtrue; - if (lex_state == EXPR_BEG || lex_state == EXPR_MID) { - c = tLPAREN; - } - else if (space_seen) { - if (lex_state == EXPR_CMDARG) { - c = tLPAREN_ARG; - } - else if (lex_state == EXPR_ARG) { - rb_warn("don't put space before argument parentheses"); - c = '('; - } - } - COND_PUSH(0); - CMDARG_PUSH(0); - lex_state = EXPR_BEG; - return c; - - case '[': - if (lex_state == EXPR_FNAME || lex_state == EXPR_DOT) { - lex_state = EXPR_ARG; - if ((c = nextc()) == ']') { - if ((c = nextc()) == '=') { - return tASET; - } - pushback(c); - return tAREF; - } - pushback(c); - return '['; - } - else if (lex_state == EXPR_BEG || lex_state == EXPR_MID) { - c = tLBRACK; - } - else if (IS_ARG() && space_seen) { - c = tLBRACK; - } - lex_state = EXPR_BEG; - COND_PUSH(0); - CMDARG_PUSH(0); - return c; - - case '{': - if (IS_ARG() || lex_state == EXPR_END) - c = '{'; /* block (primary) */ - else if (lex_state == EXPR_ENDARG) - c = tLBRACE_ARG; /* block (expr) */ - else - c = tLBRACE; /* hash */ - COND_PUSH(0); - CMDARG_PUSH(0); - lex_state = EXPR_BEG; - if (c != tLBRACE) command_start = Qtrue; - return c; - - case '\\': - c = nextc(); - if (c == '\n') { - space_seen = 1; - goto retry; /* skip \\n */ - } - pushback(c); - return '\\'; - - case '%': - if (lex_state == EXPR_BEG || lex_state == EXPR_MID) { - int term; - int paren; - - c = nextc(); - quotation: - if (!ISALNUM(c)) { - term = c; - c = 'Q'; - } - else { - term = nextc(); - if (ISALNUM(term) || ismbchar(term)) { - yyerror("unknown type of %string"); - return 0; - } - } - if (c == -1 || term == -1) { - rb_compile_error("unterminated quoted string meets end of file"); - return 0; - } - paren = term; - if (term == '(') term = ')'; - else if (term == '[') term = ']'; - else if (term == '{') term = '}'; - else if (term == '<') term = '>'; - else paren = 0; - - switch (c) { - case 'Q': - lex_strterm = NEW_STRTERM(str_dquote, term, paren); - return tSTRING_BEG; - - case 'q': - lex_strterm = NEW_STRTERM(str_squote, term, paren); - return tSTRING_BEG; - - case 'W': - lex_strterm = NEW_STRTERM(str_dword, term, paren); - do {c = nextc();} while (ISSPACE(c)); - pushback(c); - return tWORDS_BEG; - - case 'w': - lex_strterm = NEW_STRTERM(str_sword, term, paren); - do {c = nextc();} while (ISSPACE(c)); - pushback(c); - return tQWORDS_BEG; - - case 'x': - lex_strterm = NEW_STRTERM(str_xquote, term, paren); - return tXSTRING_BEG; - - case 'r': - lex_strterm = NEW_STRTERM(str_regexp, term, paren); - return tREGEXP_BEG; - - case 's': - lex_strterm = NEW_STRTERM(str_ssym, term, paren); - lex_state = EXPR_FNAME; - return tSYMBEG; - - default: - yyerror("unknown type of %string"); - return 0; - } - } - if ((c = nextc()) == '=') { - yylval.id = '%'; - lex_state = EXPR_BEG; - return tOP_ASGN; - } - if (IS_ARG() && space_seen && !ISSPACE(c)) { - goto quotation; - } - switch (lex_state) { - case EXPR_FNAME: case EXPR_DOT: - lex_state = EXPR_ARG; break; - default: - lex_state = EXPR_BEG; break; - } - pushback(c); - return '%'; - - case '$': - last_state = lex_state; - lex_state = EXPR_END; - newtok(); - c = nextc(); - switch (c) { - case '_': /* $_: last read line string */ - c = nextc(); - if (is_identchar(c)) { - tokadd('$'); - tokadd('_'); - break; - } - pushback(c); - c = '_'; - /* fall through */ - case '~': /* $~: match-data */ - local_cnt(c); - /* fall through */ - case '*': /* $*: argv */ - case '$': /* $$: pid */ - case '?': /* $?: last status */ - case '!': /* $!: error string */ - case '@': /* $@: error position */ - case '/': /* $/: input record separator */ - case '\\': /* $\: output record separator */ - case ';': /* $;: field separator */ - case ',': /* $,: output field separator */ - case '.': /* $.: last read line number */ - case '=': /* $=: ignorecase */ - case ':': /* $:: load path */ - case '<': /* $<: reading filename */ - case '>': /* $>: default output handle */ - case '\"': /* $": already loaded files */ - tokadd('$'); - tokadd(c); - tokfix(); - yylval.id = rb_intern(tok()); - return tGVAR; - - case '-': - tokadd('$'); - tokadd(c); - c = nextc(); - if (is_identchar(c)) { - tokadd(c); - } - else { - pushback(c); - } - gvar: - tokfix(); - yylval.id = rb_intern(tok()); - /* xxx shouldn't check if valid option variable */ - return tGVAR; - - case '&': /* $&: last match */ - case '`': /* $`: string before last match */ - case '\'': /* $': string after last match */ - case '+': /* $+: string matches last paren. */ - if (last_state == EXPR_FNAME) { - tokadd('$'); - tokadd(c); - goto gvar; - } - yylval.node = NEW_BACK_REF(c); - return tBACK_REF; - - case '1': case '2': case '3': - case '4': case '5': case '6': - case '7': case '8': case '9': - tokadd('$'); - do { - tokadd(c); - c = nextc(); - } while (ISDIGIT(c)); - pushback(c); - if (last_state == EXPR_FNAME) goto gvar; - tokfix(); - yylval.node = NEW_NTH_REF(atoi(tok()+1)); - return tNTH_REF; - - default: - if (!is_identchar(c)) { - pushback(c); - return '$'; - } - case '0': - tokadd('$'); - } - break; - - case '@': - c = nextc(); - newtok(); - tokadd('@'); - if (c == '@') { - tokadd('@'); - c = nextc(); - } - if (ISDIGIT(c)) { - if (tokidx == 1) { - rb_compile_error("`@%c' is not allowed as an instance variable name", c); - } - else { - rb_compile_error("`@@%c' is not allowed as a class variable name", c); - } - return 0; - } - if (!is_identchar(c)) { - pushback(c); - return '@'; - } - break; - - case '_': - if (was_bol() && whole_match_p("__END__", 7, 0)) { - ruby__end__seen = 1; - lex_lastline = 0; - return -1; - } - newtok(); - break; - - default: - if (!is_identchar(c)) { - rb_compile_error("Invalid char `\\%03o' in expression", c); - goto retry; - } - - newtok(); - break; - } - - do { - tokadd(c); - if (ismbchar(c)) { - int i, len = mbclen(c)-1; - - for (i = 0; i < len; i++) { - c = nextc(); - tokadd(c); - } - } - c = nextc(); - } while (is_identchar(c)); - if ((c == '!' || c == '?') && is_identchar(tok()[0]) && !peek('=')) { - tokadd(c); - } - else { - pushback(c); - } - tokfix(); - - { - int result = 0; - - last_state = lex_state; - switch (tok()[0]) { - case '$': - lex_state = EXPR_END; - result = tGVAR; - break; - case '@': - lex_state = EXPR_END; - if (tok()[1] == '@') - result = tCVAR; - else - result = tIVAR; - break; - - default: - if (toklast() == '!' || toklast() == '?') { - result = tFID; - } - else { - if (lex_state == EXPR_FNAME) { - if ((c = nextc()) == '=' && !peek('~') && !peek('>') && - (!peek('=') || (lex_p + 1 < lex_pend && lex_p[1] == '>'))) { - result = tIDENTIFIER; - tokadd(c); - tokfix(); - } - else { - pushback(c); - } - } - if (result == 0 && ISUPPER(tok()[0])) { - result = tCONSTANT; - } - else { - result = tIDENTIFIER; - } - } - - if (lex_state != EXPR_DOT) { - const struct kwtable *kw; - - /* See if it is a reserved word. */ - kw = rb_reserved_word(tok(), toklen()); - if (kw) { - enum lex_state state = lex_state; - lex_state = kw->state; - if (state == EXPR_FNAME) { - yylval.id = rb_intern(kw->name); - return kw->id[0]; - } - if (kw->id[0] == kDO) { - command_start = Qtrue; - if (COND_P()) return kDO_COND; - if (CMDARG_P() && state != EXPR_CMDARG) - return kDO_BLOCK; - if (state == EXPR_ENDARG) - return kDO_BLOCK; - return kDO; - } - if (state == EXPR_BEG) - return kw->id[0]; - else { - if (kw->id[0] != kw->id[1]) - lex_state = EXPR_BEG; - return kw->id[1]; - } - } - } - - if (lex_state == EXPR_BEG || - lex_state == EXPR_MID || - lex_state == EXPR_DOT || - lex_state == EXPR_ARG || - lex_state == EXPR_CMDARG) { - if (cmd_state) { - lex_state = EXPR_CMDARG; - } - else { - lex_state = EXPR_ARG; - } - } - else { - lex_state = EXPR_END; - } - } - yylval.id = rb_intern(tok()); - if (is_local_id(yylval.id) && - last_state != EXPR_DOT && - ((dyna_in_block() && rb_dvar_defined(yylval.id)) || local_id(yylval.id))) { - lex_state = EXPR_END; - } - return result; - } -} - -NODE* -rb_node_newnode(type, a0, a1, a2) - enum node_type type; - VALUE a0, a1, a2; -{ - NODE *n = (NODE*)rb_newobj(); - - n->flags |= T_NODE; - nd_set_type(n, type); - nd_set_line(n, ruby_sourceline); - n->nd_file = ruby_sourcefile; - - n->u1.value = a0; - n->u2.value = a1; - n->u3.value = a2; - - return n; -} - -static enum node_type -nodetype(node) /* for debug */ - NODE *node; -{ - return (enum node_type)nd_type(node); -} - -static int -nodeline(node) - NODE *node; -{ - return nd_line(node); -} - -static NODE* -newline_node(node) - NODE *node; -{ - NODE *nl = 0; - if (node) { - int line; - if (nd_type(node) == NODE_NEWLINE) return node; - line = nd_line(node); - node = remove_begin(node); - nl = NEW_NEWLINE(node); - nd_set_line(nl, line); - nl->nd_nth = line; - } - return nl; -} - -static void -fixpos(node, orig) - NODE *node, *orig; -{ - if (!node) return; - if (!orig) return; - if (orig == (NODE*)1) return; - node->nd_file = orig->nd_file; - nd_set_line(node, nd_line(orig)); -} - -static void -parser_warning(node, mesg) - NODE *node; - const char *mesg; -{ - int line = ruby_sourceline; - ruby_sourceline = nd_line(node); - rb_warning("%s", mesg); - ruby_sourceline = line; -} - -static void -parser_warn(node, mesg) - NODE *node; - const char *mesg; -{ - int line = ruby_sourceline; - ruby_sourceline = nd_line(node); - rb_warn("%s", mesg); - ruby_sourceline = line; -} - -static NODE* -block_append(head, tail) - NODE *head, *tail; -{ - NODE *end, *h = head; - - if (tail == 0) return head; - - again: - if (h == 0) return tail; - switch (nd_type(h)) { - case NODE_NEWLINE: - h = h->nd_next; - goto again; - case NODE_LIT: - case NODE_STR: - parser_warning(h, "unused literal ignored"); - return tail; - default: - h = end = NEW_BLOCK(head); - end->nd_end = end; - fixpos(end, head); - head = end; - break; - case NODE_BLOCK: - end = h->nd_end; - break; - } - - if (RTEST(ruby_verbose)) { - NODE *nd = end->nd_head; - newline: - switch (nd_type(nd)) { - case NODE_RETURN: - case NODE_BREAK: - case NODE_NEXT: - case NODE_REDO: - case NODE_RETRY: - parser_warning(nd, "statement not reached"); - break; - - case NODE_NEWLINE: - nd = nd->nd_next; - goto newline; - - default: - break; - } - } - - if (nd_type(tail) != NODE_BLOCK) { - tail = NEW_BLOCK(tail); - tail->nd_end = tail; - } - end->nd_next = tail; - h->nd_end = tail->nd_end; - return head; -} - -/* append item to the list */ -static NODE* -list_append(list, item) - NODE *list, *item; -{ - NODE *last; - - if (list == 0) return NEW_LIST(item); - if (list->nd_next) { - last = list->nd_next->nd_end; - } - else { - last = list; - } - - list->nd_alen += 1; - last->nd_next = NEW_LIST(item); - list->nd_next->nd_end = last->nd_next; - return list; -} - -/* concat two lists */ -static NODE* -list_concat(head, tail) - NODE *head, *tail; -{ - NODE *last; - - if (head->nd_next) { - last = head->nd_next->nd_end; - } - else { - last = head; - } - - head->nd_alen += tail->nd_alen; - last->nd_next = tail; - if (tail->nd_next) { - head->nd_next->nd_end = tail->nd_next->nd_end; - } - else { - head->nd_next->nd_end = tail; - } - - return head; -} - -/* concat two string literals */ -static NODE * -literal_concat(head, tail) - NODE *head, *tail; -{ - enum node_type htype; - - if (!head) return tail; - if (!tail) return head; - - htype = nd_type(head); - if (htype == NODE_EVSTR) { - NODE *node = NEW_DSTR(rb_str_new(0, 0)); - head = list_append(node, head); - } - switch (nd_type(tail)) { - case NODE_STR: - if (htype == NODE_STR) { - rb_str_concat(head->nd_lit, tail->nd_lit); - rb_gc_force_recycle((VALUE)tail); - } - else { - list_append(head, tail); - } - break; - - case NODE_DSTR: - if (htype == NODE_STR) { - rb_str_concat(head->nd_lit, tail->nd_lit); - tail->nd_lit = head->nd_lit; - rb_gc_force_recycle((VALUE)head); - head = tail; - } - else { - nd_set_type(tail, NODE_ARRAY); - tail->nd_head = NEW_STR(tail->nd_lit); - list_concat(head, tail); - } - break; - - case NODE_EVSTR: - if (htype == NODE_STR) { - nd_set_type(head, NODE_DSTR); - head->nd_alen = 1; - } - list_append(head, tail); - break; - } - return head; -} - -static NODE * -evstr2dstr(node) - NODE *node; -{ - if (nd_type(node) == NODE_EVSTR) { - node = list_append(NEW_DSTR(rb_str_new(0, 0)), node); - } - return node; -} - -static NODE * -new_evstr(node) - NODE *node; -{ - NODE *head = node; - - again: - if (node) { - switch (nd_type(node)) { - case NODE_STR: case NODE_DSTR: case NODE_EVSTR: - return node; - case NODE_NEWLINE: - node = node->nd_next; - goto again; - } - } - return NEW_EVSTR(head); -} - -static NODE * -call_op(recv, id, narg, arg1) - NODE *recv; - ID id; - int narg; - NODE *arg1; -{ - value_expr(recv); - if (narg == 1) { - value_expr(arg1); - arg1 = NEW_LIST(arg1); - } - else { - arg1 = 0; - } - return NEW_CALL(recv, id, arg1); -} - -static NODE* -match_gen(node1, node2) - NODE *node1; - NODE *node2; -{ - local_cnt('~'); - - value_expr(node1); - value_expr(node2); - if (node1) { - switch (nd_type(node1)) { - case NODE_DREGX: - case NODE_DREGX_ONCE: - return NEW_MATCH2(node1, node2); - - case NODE_LIT: - if (TYPE(node1->nd_lit) == T_REGEXP) { - return NEW_MATCH2(node1, node2); - } - } - } - - if (node2) { - switch (nd_type(node2)) { - case NODE_DREGX: - case NODE_DREGX_ONCE: - return NEW_MATCH3(node2, node1); - - case NODE_LIT: - if (TYPE(node2->nd_lit) == T_REGEXP) { - return NEW_MATCH3(node2, node1); - } - } - } - - return NEW_CALL(node1, tMATCH, NEW_LIST(node2)); -} - -static NODE* -gettable(id) - ID id; -{ - if (id == kSELF) { - return NEW_SELF(); - } - else if (id == kNIL) { - return NEW_NIL(); - } - else if (id == kTRUE) { - return NEW_TRUE(); - } - else if (id == kFALSE) { - return NEW_FALSE(); - } - else if (id == k__FILE__) { - return NEW_STR(rb_str_new2(ruby_sourcefile)); - } - else if (id == k__LINE__) { - return NEW_LIT(INT2FIX(ruby_sourceline)); - } - else if (is_local_id(id)) { - if (dyna_in_block() && rb_dvar_defined(id)) return NEW_DVAR(id); - if (local_id(id)) return NEW_LVAR(id); - /* method call without arguments */ -#if 0 - /* Rite will warn this */ - rb_warn("ambiguous identifier; %s() or self.%s is better for method call", - rb_id2name(id), rb_id2name(id)); -#endif - return NEW_VCALL(id); - } - else if (is_global_id(id)) { - return NEW_GVAR(id); - } - else if (is_instance_id(id)) { - return NEW_IVAR(id); - } - else if (is_const_id(id)) { - return NEW_CONST(id); - } - else if (is_class_id(id)) { - return NEW_CVAR(id); - } - rb_compile_error("identifier %s is not valid", rb_id2name(id)); - return 0; -} - -static VALUE dyna_var_lookup _((ID id)); - -static NODE* -assignable(id, val) - ID id; - NODE *val; -{ - value_expr(val); - if (id == kSELF) { - yyerror("Can't change the value of self"); - } - else if (id == kNIL) { - yyerror("Can't assign to nil"); - } - else if (id == kTRUE) { - yyerror("Can't assign to true"); - } - else if (id == kFALSE) { - yyerror("Can't assign to false"); - } - else if (id == k__FILE__) { - yyerror("Can't assign to __FILE__"); - } - else if (id == k__LINE__) { - yyerror("Can't assign to __LINE__"); - } - else if (is_local_id(id)) { - if (rb_dvar_curr(id)) { - return NEW_DASGN_CURR(id, val); - } - else if (dyna_var_lookup(id)) { - return NEW_DASGN(id, val); - } - else if (local_id(id) || !dyna_in_block()) { - return NEW_LASGN(id, val); - } - else{ - rb_dvar_push(id, Qnil); - return NEW_DASGN_CURR(id, val); - } - } - else if (is_global_id(id)) { - return NEW_GASGN(id, val); - } - else if (is_instance_id(id)) { - return NEW_IASGN(id, val); - } - else if (is_const_id(id)) { - if (in_def || in_single) - yyerror("dynamic constant assignment"); - return NEW_CDECL(id, val, 0); - } - else if (is_class_id(id)) { - if (in_def || in_single) return NEW_CVASGN(id, val); - return NEW_CVDECL(id, val); - } - else { - rb_compile_error("identifier %s is not valid", rb_id2name(id)); - } - return 0; -} - -static NODE * -aryset(recv, idx) - NODE *recv, *idx; -{ - if (recv && nd_type(recv) == NODE_SELF) - recv = (NODE *)1; - else - value_expr(recv); - return NEW_ATTRASGN(recv, tASET, idx); -} - -ID -rb_id_attrset(id) - ID id; -{ - id &= ~ID_SCOPE_MASK; - id |= ID_ATTRSET; - return id; -} - -static NODE * -attrset(recv, id) - NODE *recv; - ID id; -{ - if (recv && nd_type(recv) == NODE_SELF) - recv = (NODE *)1; - else - value_expr(recv); - return NEW_ATTRASGN(recv, rb_id_attrset(id), 0); -} - -static void -rb_backref_error(node) - NODE *node; -{ - switch (nd_type(node)) { - case NODE_NTH_REF: - rb_compile_error("Can't set variable $%d", node->nd_nth); - break; - case NODE_BACK_REF: - rb_compile_error("Can't set variable $%c", (int)node->nd_nth); - break; - } -} - -static NODE * -arg_concat(node1, node2) - NODE *node1; - NODE *node2; -{ - if (!node2) return node1; - return NEW_ARGSCAT(node1, node2); -} - -static NODE * -arg_add(node1, node2) - NODE *node1; - NODE *node2; -{ - if (!node1) return NEW_LIST(node2); - if (nd_type(node1) == NODE_ARRAY) { - return list_append(node1, node2); - } - else { - return NEW_ARGSPUSH(node1, node2); - } -} - -static NODE* -node_assign(lhs, rhs) - NODE *lhs, *rhs; -{ - if (!lhs) return 0; - - value_expr(rhs); - switch (nd_type(lhs)) { - case NODE_GASGN: - case NODE_IASGN: - case NODE_LASGN: - case NODE_DASGN: - case NODE_DASGN_CURR: - case NODE_MASGN: - case NODE_CDECL: - case NODE_CVDECL: - case NODE_CVASGN: - lhs->nd_value = rhs; - break; - - case NODE_ATTRASGN: - case NODE_CALL: - lhs->nd_args = arg_add(lhs->nd_args, rhs); - break; - - default: - /* should not happen */ - break; - } - - return lhs; -} - -static int -value_expr0(node) - NODE *node; -{ - int cond = 0; - - while (node) { - switch (nd_type(node)) { - case NODE_DEFN: - case NODE_DEFS: - parser_warning(node, "void value expression"); - return Qfalse; - - case NODE_RETURN: - case NODE_BREAK: - case NODE_NEXT: - case NODE_REDO: - case NODE_RETRY: - if (!cond) yyerror("void value expression"); - /* or "control never reach"? */ - return Qfalse; - - case NODE_BLOCK: - while (node->nd_next) { - node = node->nd_next; - } - node = node->nd_head; - break; - - case NODE_BEGIN: - node = node->nd_body; - break; - - case NODE_IF: - if (!value_expr(node->nd_body)) return Qfalse; - node = node->nd_else; - break; - - case NODE_AND: - case NODE_OR: - cond = 1; - node = node->nd_2nd; - break; - - case NODE_NEWLINE: - node = node->nd_next; - break; - - default: - return Qtrue; - } - } - - return Qtrue; -} - -static void -void_expr0(node) - NODE *node; -{ - const char *useless = 0; - - if (!RTEST(ruby_verbose)) return; - - again: - if (!node) return; - switch (nd_type(node)) { - case NODE_NEWLINE: - node = node->nd_next; - goto again; - - case NODE_CALL: - switch (node->nd_mid) { - case '+': - case '-': - case '*': - case '/': - case '%': - case tPOW: - case tUPLUS: - case tUMINUS: - case '|': - case '^': - case '&': - case tCMP: - case '>': - case tGEQ: - case '<': - case tLEQ: - case tEQ: - case tNEQ: - useless = rb_id2name(node->nd_mid); - break; - } - break; - - case NODE_LVAR: - case NODE_DVAR: - case NODE_GVAR: - case NODE_IVAR: - case NODE_CVAR: - case NODE_NTH_REF: - case NODE_BACK_REF: - useless = "a variable"; - break; - case NODE_CONST: - case NODE_CREF: - useless = "a constant"; - break; - case NODE_LIT: - case NODE_STR: - case NODE_DSTR: - case NODE_DREGX: - case NODE_DREGX_ONCE: - useless = "a literal"; - break; - case NODE_COLON2: - case NODE_COLON3: - useless = "::"; - break; - case NODE_DOT2: - useless = ".."; - break; - case NODE_DOT3: - useless = "..."; - break; - case NODE_SELF: - useless = "self"; - break; - case NODE_NIL: - useless = "nil"; - break; - case NODE_TRUE: - useless = "true"; - break; - case NODE_FALSE: - useless = "false"; - break; - case NODE_DEFINED: - useless = "defined?"; - break; - } - - if (useless) { - int line = ruby_sourceline; - - ruby_sourceline = nd_line(node); - rb_warn("useless use of %s in void context", useless); - ruby_sourceline = line; - } -} - -static void -void_stmts(node) - NODE *node; -{ - if (!RTEST(ruby_verbose)) return; - if (!node) return; - if (nd_type(node) != NODE_BLOCK) return; - - for (;;) { - if (!node->nd_next) return; - void_expr0(node->nd_head); - node = node->nd_next; - } -} - -static NODE * -remove_begin(node) - NODE *node; -{ - NODE **n = &node; - while (*n) { - switch (nd_type(*n)) { - case NODE_NEWLINE: - n = &(*n)->nd_next; - continue; - case NODE_BEGIN: - *n = (*n)->nd_body; - default: - return node; - } - } - return node; -} - -static int -assign_in_cond(node) - NODE *node; -{ - switch (nd_type(node)) { - case NODE_MASGN: - yyerror("multiple assignment in conditional"); - return 1; - - case NODE_LASGN: - case NODE_DASGN: - case NODE_GASGN: - case NODE_IASGN: - break; - - case NODE_NEWLINE: - default: - return 0; - } - - switch (nd_type(node->nd_value)) { - case NODE_LIT: - case NODE_STR: - case NODE_NIL: - case NODE_TRUE: - case NODE_FALSE: - /* reports always */ - parser_warn(node->nd_value, "found = in conditional, should be =="); - return 1; - - case NODE_DSTR: - case NODE_XSTR: - case NODE_DXSTR: - case NODE_EVSTR: - case NODE_DREGX: - default: - break; - } -#if 0 - if (assign_in_cond(node->nd_value) == 0) { - parser_warning(node->nd_value, "assignment in condition"); - } -#endif - return 1; -} - -static int -e_option_supplied() -{ - if (strcmp(ruby_sourcefile, "-e") == 0) - return Qtrue; - return Qfalse; -} - -static void -warn_unless_e_option(node, str) - NODE *node; - const char *str; -{ - if (!e_option_supplied()) parser_warn(node, str); -} - -static void -warning_unless_e_option(node, str) - NODE *node; - const char *str; -{ - if (!e_option_supplied()) parser_warning(node, str); -} - -static NODE *cond0(); - -static NODE* -range_op(node) - NODE *node; -{ - enum node_type type; - - if (!e_option_supplied()) return node; - if (node == 0) return 0; - - value_expr(node); - node = cond0(node); - type = nd_type(node); - if (type == NODE_NEWLINE) { - node = node->nd_next; - type = nd_type(node); - } - if (type == NODE_LIT && FIXNUM_P(node->nd_lit)) { - warn_unless_e_option(node, "integer literal in conditional range"); - return call_op(node,tEQ,1,NEW_GVAR(rb_intern("$."))); - } - return node; -} - -static int -literal_node(node) - NODE *node; -{ - if (!node) return 1; /* same as NODE_NIL */ - switch (nd_type(node)) { - case NODE_LIT: - case NODE_STR: - case NODE_DSTR: - case NODE_EVSTR: - case NODE_DREGX: - case NODE_DREGX_ONCE: - case NODE_DSYM: - return 2; - case NODE_TRUE: - case NODE_FALSE: - case NODE_NIL: - return 1; - } - return 0; -} - -static NODE* -cond0(node) - NODE *node; -{ - if (node == 0) return 0; - assign_in_cond(node); - - switch (nd_type(node)) { - case NODE_DSTR: - case NODE_EVSTR: - case NODE_STR: - rb_warn("string literal in condition"); - break; - - case NODE_DREGX: - case NODE_DREGX_ONCE: - warning_unless_e_option(node, "regex literal in condition"); - local_cnt('_'); - local_cnt('~'); - return NEW_MATCH2(node, NEW_GVAR(rb_intern("$_"))); - - case NODE_AND: - case NODE_OR: - node->nd_1st = cond0(node->nd_1st); - node->nd_2nd = cond0(node->nd_2nd); - break; - - case NODE_DOT2: - case NODE_DOT3: - node->nd_beg = range_op(node->nd_beg); - node->nd_end = range_op(node->nd_end); - if (nd_type(node) == NODE_DOT2) nd_set_type(node,NODE_FLIP2); - else if (nd_type(node) == NODE_DOT3) nd_set_type(node, NODE_FLIP3); - node->nd_cnt = local_append(internal_id()); - if (!e_option_supplied()) { - int b = literal_node(node->nd_beg); - int e = literal_node(node->nd_end); - if ((b == 1 && e == 1) || (b + e >= 2 && RTEST(ruby_verbose))) { - parser_warn(node, "range literal in condition"); - } - } - break; - - case NODE_DSYM: - parser_warning(node, "literal in condition"); - break; - - case NODE_LIT: - if (TYPE(node->nd_lit) == T_REGEXP) { - warn_unless_e_option(node, "regex literal in condition"); - nd_set_type(node, NODE_MATCH); - local_cnt('_'); - local_cnt('~'); - } - else { - parser_warning(node, "literal in condition"); - } - default: - break; - } - return node; -} - -static NODE* -cond(node) - NODE *node; -{ - if (node == 0) return 0; - value_expr(node); - if (nd_type(node) == NODE_NEWLINE){ - node->nd_next = cond0(node->nd_next); - return node; - } - return cond0(node); -} - -static NODE* -logop(type, left, right) - enum node_type type; - NODE *left, *right; -{ - value_expr(left); - if (left && nd_type(left) == type) { - NODE *node = left, *second; - while ((second = node->nd_2nd) != 0 && nd_type(second) == type) { - node = second; - } - node->nd_2nd = NEW_NODE(type, second, right, 0); - return left; - } - return NEW_NODE(type, left, right, 0); -} - -static int -cond_negative(nodep) - NODE **nodep; -{ - NODE *c = *nodep; - - if (!c) return 0; - switch (nd_type(c)) { - case NODE_NOT: - *nodep = c->nd_body; - return 1; - case NODE_NEWLINE: - if (c->nd_next && nd_type(c->nd_next) == NODE_NOT) { - c->nd_next = c->nd_next->nd_body; - return 1; - } - } - return 0; -} - -static void -no_blockarg(node) - NODE *node; -{ - if (node && nd_type(node) == NODE_BLOCK_PASS) { - rb_compile_error("block argument should not be given"); - } -} - -static NODE * -ret_args(node) - NODE *node; -{ - if (node) { - no_blockarg(node); - if (nd_type(node) == NODE_ARRAY && node->nd_next == 0) { - node = node->nd_head; - } - if (node && nd_type(node) == NODE_SPLAT) { - node = NEW_SVALUE(node); - } - } - return node; -} - -static NODE * -new_yield(node) - NODE *node; -{ - long state = Qtrue; - - if (node) { - no_blockarg(node); - if (nd_type(node) == NODE_ARRAY && node->nd_next == 0) { - node = node->nd_head; - state = Qfalse; - } - if (node && nd_type(node) == NODE_SPLAT) { - state = Qtrue; - } - } - else { - state = Qfalse; - } - return NEW_YIELD(node, state); -} - -static NODE* -negate_lit(node) - NODE *node; -{ - switch (TYPE(node->nd_lit)) { - case T_FIXNUM: - node->nd_lit = LONG2FIX(-FIX2LONG(node->nd_lit)); - break; - case T_BIGNUM: - node->nd_lit = rb_funcall(node->nd_lit,tUMINUS,0,0); - break; - case T_FLOAT: - RFLOAT(node->nd_lit)->value = -RFLOAT(node->nd_lit)->value; - break; - default: - break; - } - return node; -} - -static NODE * -arg_blk_pass(node1, node2) - NODE *node1; - NODE *node2; -{ - if (node2) { - node2->nd_head = node1; - return node2; - } - return node1; -} - -static NODE* -arg_prepend(node1, node2) - NODE *node1, *node2; -{ - switch (nd_type(node2)) { - case NODE_ARRAY: - return list_concat(NEW_LIST(node1), node2); - - case NODE_SPLAT: - return arg_concat(node1, node2->nd_head); - - case NODE_BLOCK_PASS: - node2->nd_body = arg_prepend(node1, node2->nd_body); - return node2; - - default: - rb_bug("unknown nodetype(%d) for arg_prepend", nd_type(node2)); - } - return 0; /* not reached */ -} - -static NODE* -new_call(r,m,a) - NODE *r; - ID m; - NODE *a; -{ - if (a && nd_type(a) == NODE_BLOCK_PASS) { - a->nd_iter = NEW_CALL(r,m,a->nd_head); - return a; - } - return NEW_CALL(r,m,a); -} - -static NODE* -new_fcall(m,a) - ID m; - NODE *a; -{ - if (a && nd_type(a) == NODE_BLOCK_PASS) { - a->nd_iter = NEW_FCALL(m,a->nd_head); - return a; - } - return NEW_FCALL(m,a); -} - -static NODE* -new_super(a) - NODE *a; -{ - if (a && nd_type(a) == NODE_BLOCK_PASS) { - a->nd_iter = NEW_SUPER(a->nd_head); - return a; - } - return NEW_SUPER(a); -} - -static struct local_vars { - ID *tbl; - int nofree; - int cnt; - int dlev; - struct RVarmap* dyna_vars; - struct local_vars *prev; -} *lvtbl; - -static void -local_push(top) - int top; -{ - struct local_vars *local; - - local = ALLOC(struct local_vars); - local->prev = lvtbl; - local->nofree = 0; - local->cnt = 0; - local->tbl = 0; - local->dlev = 0; - local->dyna_vars = ruby_dyna_vars; - lvtbl = local; - if (!top) { - /* preserve reference for GC, but link should be cut. */ - rb_dvar_push(0, (VALUE)ruby_dyna_vars); - ruby_dyna_vars->next = 0; - } -} - -static void -local_pop() -{ - struct local_vars *local = lvtbl->prev; - - if (lvtbl->tbl) { - if (!lvtbl->nofree) xfree(lvtbl->tbl); - else lvtbl->tbl[0] = lvtbl->cnt; - } - ruby_dyna_vars = lvtbl->dyna_vars; - xfree(lvtbl); - lvtbl = local; -} - -static ID* -local_tbl() -{ - lvtbl->nofree = 1; - return lvtbl->tbl; -} - -static int -local_append(id) - ID id; -{ - if (lvtbl->tbl == 0) { - lvtbl->tbl = ALLOC_N(ID, 4); - lvtbl->tbl[0] = 0; - lvtbl->tbl[1] = '_'; - lvtbl->tbl[2] = '~'; - lvtbl->cnt = 2; - if (id == '_') return 0; - if (id == '~') return 1; - } - else { - REALLOC_N(lvtbl->tbl, ID, lvtbl->cnt+2); - } - - lvtbl->tbl[lvtbl->cnt+1] = id; - return lvtbl->cnt++; -} - -static int -local_cnt(id) - ID id; -{ - int cnt, max; - - if (id == 0) return lvtbl->cnt; - - for (cnt=1, max=lvtbl->cnt+1; cnttbl[cnt] == id) return cnt-1; - } - return local_append(id); -} - -static int -local_id(id) - ID id; -{ - int i, max; - - if (lvtbl == 0) return Qfalse; - for (i=3, max=lvtbl->cnt+1; itbl[i] == id) return Qtrue; - } - return Qfalse; -} - -static void -top_local_init() -{ - local_push(1); - lvtbl->cnt = ruby_scope->local_tbl?ruby_scope->local_tbl[0]:0; - if (lvtbl->cnt > 0) { - lvtbl->tbl = ALLOC_N(ID, lvtbl->cnt+3); - MEMCPY(lvtbl->tbl, ruby_scope->local_tbl, ID, lvtbl->cnt+1); - } - else { - lvtbl->tbl = 0; - } - if (ruby_dyna_vars) - lvtbl->dlev = 1; - else - lvtbl->dlev = 0; -} - -static void -top_local_setup() -{ - int len = lvtbl->cnt; - int i; - - if (len > 0) { - i = ruby_scope->local_tbl?ruby_scope->local_tbl[0]:0; - - if (i < len) { - if (i == 0 || (ruby_scope->flags & SCOPE_MALLOC) == 0) { - VALUE *vars = ALLOC_N(VALUE, len+1); - if (ruby_scope->local_vars) { - *vars++ = ruby_scope->local_vars[-1]; - MEMCPY(vars, ruby_scope->local_vars, VALUE, i); - rb_mem_clear(vars+i, len-i); - } - else { - *vars++ = 0; - rb_mem_clear(vars, len); - } - ruby_scope->local_vars = vars; - ruby_scope->flags |= SCOPE_MALLOC; - } - else { - VALUE *vars = ruby_scope->local_vars-1; - REALLOC_N(vars, VALUE, len+1); - ruby_scope->local_vars = vars+1; - rb_mem_clear(ruby_scope->local_vars+i, len-i); - } - if (ruby_scope->local_tbl && ruby_scope->local_vars[-1] == 0) { - if (!(ruby_scope->flags & SCOPE_CLONE)) - xfree(ruby_scope->local_tbl); - } - ruby_scope->local_vars[-1] = 0; /* no reference needed */ - ruby_scope->local_tbl = local_tbl(); - } - } - local_pop(); -} - -#define DVAR_USED FL_USER6 - -static VALUE -dyna_var_lookup(id) - ID id; -{ - struct RVarmap *vars = ruby_dyna_vars; - - while (vars) { - if (vars->id == id) { - FL_SET(vars, DVAR_USED); - return Qtrue; - } - vars = vars->next; - } - return Qfalse; -} - -static struct RVarmap* -dyna_push() -{ - struct RVarmap* vars = ruby_dyna_vars; - - rb_dvar_push(0, 0); - lvtbl->dlev++; - return vars; -} - -static void -dyna_pop(vars) - struct RVarmap* vars; -{ - lvtbl->dlev--; - ruby_dyna_vars = vars; -} - -static int -dyna_in_block() -{ - return (lvtbl->dlev > 0); -} - -static NODE * -dyna_init(node, pre) - NODE *node; - struct RVarmap *pre; -{ - struct RVarmap *post = ruby_dyna_vars; - NODE *var; - - if (!node || !post || pre == post) return node; - for (var = 0; post != pre && post->id; post = post->next) { - if (FL_TEST(post, DVAR_USED)) { - var = NEW_DASGN_CURR(post->id, var); - } - } - return block_append(var, node); -} - -int -ruby_parser_stack_on_heap() -{ -#if defined(YYMALLOC) - (void)rb_parser_realloc; - (void)rb_parser_calloc; - (void)nodetype; - (void)nodeline; - return Qfalse; -#else - return Qtrue; -#endif -} - -void -rb_gc_mark_parser() -{ -#if defined YYMALLOC - rb_gc_mark((VALUE)parser_heap); -#elif defined yystacksize - if (yyvsp) rb_gc_mark_locations((VALUE *)yyvs, (VALUE *)yyvsp); -#endif - - if (!ruby_in_compile) return; - - rb_gc_mark_maybe((VALUE)yylval.node); - rb_gc_mark(ruby_debug_lines); - rb_gc_mark(lex_lastline); - rb_gc_mark(lex_input); - rb_gc_mark((VALUE)lex_strterm); -} - -void -rb_parser_append_print() -{ - ruby_eval_tree = - block_append(ruby_eval_tree, - NEW_FCALL(rb_intern("print"), - NEW_ARRAY(NEW_GVAR(rb_intern("$_"))))); -} - -void -rb_parser_while_loop(chop, split) - int chop, split; -{ - if (split) { - ruby_eval_tree = - block_append(NEW_GASGN(rb_intern("$F"), - NEW_CALL(NEW_GVAR(rb_intern("$_")), - rb_intern("split"), 0)), - ruby_eval_tree); - } - if (chop) { - ruby_eval_tree = - block_append(NEW_CALL(NEW_GVAR(rb_intern("$_")), - rb_intern("chop!"), 0), ruby_eval_tree); - } - ruby_eval_tree = NEW_OPT_N(ruby_eval_tree); -} - -static struct { - ID token; - const char *name; -} op_tbl[] = { - {tDOT2, ".."}, - {tDOT3, "..."}, - {'+', "+"}, - {'-', "-"}, - {'+', "+(binary)"}, - {'-', "-(binary)"}, - {'*', "*"}, - {'/', "/"}, - {'%', "%"}, - {tPOW, "**"}, - {tUPLUS, "+@"}, - {tUMINUS, "-@"}, - {tUPLUS, "+(unary)"}, - {tUMINUS, "-(unary)"}, - {'|', "|"}, - {'^', "^"}, - {'&', "&"}, - {tCMP, "<=>"}, - {'>', ">"}, - {tGEQ, ">="}, - {'<', "<"}, - {tLEQ, "<="}, - {tEQ, "=="}, - {tEQQ, "==="}, - {tNEQ, "!="}, - {tMATCH, "=~"}, - {tNMATCH, "!~"}, - {'!', "!"}, - {'~', "~"}, - {'!', "!(unary)"}, - {'~', "~(unary)"}, - {'!', "!@"}, - {'~', "~@"}, - {tAREF, "[]"}, - {tASET, "[]="}, - {tLSHFT, "<<"}, - {tRSHFT, ">>"}, - {tCOLON2, "::"}, - {'`', "`"}, - {0, 0} -}; - -static st_table *sym_tbl; -static st_table *sym_rev_tbl; - -void -Init_sym() -{ - sym_tbl = st_init_strtable_with_size(200); - sym_rev_tbl = st_init_numtable_with_size(200); -} - -static ID last_id = tLAST_TOKEN; - -static ID -internal_id() -{ - return ID_INTERNAL | (++last_id << ID_SCOPE_SHIFT); -} - -static int -is_special_global_name(m) - const char *m; -{ - switch (*m) { - case '~': case '*': case '$': case '?': case '!': case '@': - case '/': case '\\': case ';': case ',': case '.': case '=': - case ':': case '<': case '>': case '\"': - case '&': case '`': case '\'': case '+': - case '0': - ++m; - break; - case '-': - ++m; - if (is_identchar(*m)) m += mbclen(*m); - break; - default: - if (!ISDIGIT(*m)) return 0; - do ++m; while (ISDIGIT(*m)); - } - return !*m; -} - -int -rb_symname_p(name) - const char *name; -{ - const char *m = name; - int localid = Qfalse; - - if (!m) return Qfalse; - switch (*m) { - case '\0': - return Qfalse; - - case '$': - if (is_special_global_name(++m)) return Qtrue; - goto id; - - case '@': - if (*++m == '@') ++m; - goto id; - - case '<': - switch (*++m) { - case '<': ++m; break; - case '=': if (*++m == '>') ++m; break; - default: break; - } - break; - - case '>': - switch (*++m) { - case '>': case '=': ++m; break; - } - break; - - case '=': - switch (*++m) { - case '~': ++m; break; - case '=': if (*++m == '=') ++m; break; - default: return Qfalse; - } - break; - - case '*': - if (*++m == '*') ++m; - break; - - case '+': case '-': - if (*++m == '@') ++m; - break; - - case '|': case '^': case '&': case '/': case '%': case '~': case '`': - ++m; - break; - - case '[': - if (*++m != ']') return Qfalse; - if (*++m == '=') ++m; - break; - - default: - localid = !ISUPPER(*m); - id: - if (*m != '_' && !ISALPHA(*m) && !ismbchar(*m)) return Qfalse; - while (is_identchar(*m)) m += mbclen(*m); - if (localid) { - switch (*m) { - case '!': case '?': case '=': ++m; - } - } - break; - } - return *m ? Qfalse : Qtrue; -} - -int -rb_sym_interned_p(str) - VALUE str; -{ - ID id; - - if (st_lookup(sym_tbl, (st_data_t)RSTRING(str)->ptr, (st_data_t *)&id)) - return Qtrue; - return Qfalse; -} - -ID -rb_intern(name) - const char *name; -{ - const char *m = name; - ID id; - int last; - - if (st_lookup(sym_tbl, (st_data_t)name, (st_data_t *)&id)) - return id; - - last = strlen(name)-1; - id = 0; - switch (*name) { - case '$': - id |= ID_GLOBAL; - if (is_special_global_name(++m)) goto new_id; - break; - case '@': - if (name[1] == '@') { - m++; - id |= ID_CLASS; - } - else { - id |= ID_INSTANCE; - } - m++; - break; - default: - if (name[0] != '_' && ISASCII(name[0]) && !ISALNUM(name[0])) { - /* operators */ - int i; - - for (i=0; op_tbl[i].token; i++) { - if (*op_tbl[i].name == *name && - strcmp(op_tbl[i].name, name) == 0) { - id = op_tbl[i].token; - goto id_regist; - } - } - } - - if (name[last] == '=') { - /* attribute assignment */ - char *buf = ALLOCA_N(char,last+1); - - strncpy(buf, name, last); - buf[last] = '\0'; - id = rb_intern(buf); - if (id > tLAST_TOKEN && !is_attrset_id(id)) { - id = rb_id_attrset(id); - goto id_regist; - } - id = ID_ATTRSET; - } - else if (ISUPPER(name[0])) { - id = ID_CONST; - } - else { - id = ID_LOCAL; - } - break; - } - if (!ISDIGIT(*m)) { - while (m <= name + last && is_identchar(*m)) { - m += mbclen(*m); - } - } - if (*m) id = ID_JUNK; - new_id: - id |= ++last_id << ID_SCOPE_SHIFT; - id_regist: - name = strdup(name); - st_add_direct(sym_tbl, (st_data_t)name, id); - st_add_direct(sym_rev_tbl, id, (st_data_t)name); - return id; -} - -const char * -rb_id2name(id) - ID id; -{ - const char *name; - st_data_t data; - - if (id < tLAST_TOKEN) { - int i; - - for (i=0; op_tbl[i].token; i++) { - if (op_tbl[i].token == id) - return op_tbl[i].name; - } - } - - if (st_lookup(sym_rev_tbl, id, &data)) - return (char *)data; - - if (is_attrset_id(id)) { - ID id2 = (id & ~ID_SCOPE_MASK) | ID_LOCAL; - - again: - name = rb_id2name(id2); - if (name) { - char *buf = ALLOCA_N(char, strlen(name)+2); - - strcpy(buf, name); - strcat(buf, "="); - rb_intern(buf); - return rb_id2name(id); - } - if (is_local_id(id2)) { - id2 = (id & ~ID_SCOPE_MASK) | ID_CONST; - goto again; - } - } - return 0; -} - -static int -symbols_i(key, value, ary) - char *key; - ID value; - VALUE ary; -{ - rb_ary_push(ary, ID2SYM(value)); - return ST_CONTINUE; -} - -/* - * call-seq: - * Symbol.all_symbols => array - * - * Returns an array of all the symbols currently in Ruby's symbol - * table. - * - * Symbol.all_symbols.size #=> 903 - * Symbol.all_symbols[1,20] #=> [:floor, :ARGV, :Binding, :symlink, - * :chown, :EOFError, :$;, :String, - * :LOCK_SH, :"setuid?", :$<, - * :default_proc, :compact, :extend, - * :Tms, :getwd, :$=, :ThreadGroup, - * :wait2, :$>] - */ - -VALUE -rb_sym_all_symbols() -{ - VALUE ary = rb_ary_new2(sym_tbl->num_entries); - - st_foreach(sym_tbl, symbols_i, ary); - return ary; -} - -int -rb_is_const_id(id) - ID id; -{ - if (is_const_id(id)) return Qtrue; - return Qfalse; -} - -int -rb_is_class_id(id) - ID id; -{ - if (is_class_id(id)) return Qtrue; - return Qfalse; -} - -int -rb_is_instance_id(id) - ID id; -{ - if (is_instance_id(id)) return Qtrue; - return Qfalse; -} - -int -rb_is_local_id(id) - ID id; -{ - if (is_local_id(id)) return Qtrue; - return Qfalse; -} - -int -rb_is_junk_id(id) - ID id; -{ - if (is_junk_id(id)) return Qtrue; - return Qfalse; -} - -static void -special_local_set(c, val) - char c; - VALUE val; -{ - int cnt; - - top_local_init(); - cnt = local_cnt(c); - top_local_setup(); - ruby_scope->local_vars[cnt] = val; -} - -VALUE -rb_backref_get() -{ - VALUE *var = rb_svar(1); - if (var) { - return *var; - } - return Qnil; -} - -void -rb_backref_set(val) - VALUE val; -{ - VALUE *var = rb_svar(1); - if (var) { - *var = val; - } - else { - special_local_set('~', val); - } -} - -VALUE -rb_lastline_get() -{ - VALUE *var = rb_svar(0); - if (var) { - return *var; - } - return Qnil; -} - -void -rb_lastline_set(val) - VALUE val; -{ - VALUE *var = rb_svar(0); - if (var) { - *var = val; - } - else { - special_local_set('_', val); - } -} - -#ifdef YYMALLOC -#define HEAPCNT(n, size) ((n) * (size) / sizeof(YYSTYPE)) -#define NEWHEAP() rb_node_newnode(NODE_ALLOCA, 0, (VALUE)parser_heap, 0) -#define ADD2HEAP(n, c, p) ((parser_heap = (n))->u1.node = (p), \ - (n)->u3.cnt = (c), (p)) - -static void * -rb_parser_malloc(size) - size_t size; -{ - size_t cnt = HEAPCNT(1, size); - NODE *n = NEWHEAP(); - void *ptr = xmalloc(size); - - return ADD2HEAP(n, cnt, ptr); -} - -static void * -rb_parser_calloc(nelem, size) - size_t nelem, size; -{ - size_t cnt = HEAPCNT(nelem, size); - NODE *n = NEWHEAP(); - void *ptr = xcalloc(nelem, size); - - return ADD2HEAP(n, cnt, ptr); -} - -static void * -rb_parser_realloc(ptr, size) - void *ptr; - size_t size; -{ - NODE *n; - size_t cnt = HEAPCNT(1, size); - - if (ptr && (n = parser_heap) != NULL) { - do { - if (n->u1.node == ptr) { - n->u1.node = ptr = xrealloc(ptr, size); - if (n->u3.cnt) n->u3.cnt = cnt; - return ptr; - } - } while ((n = n->u2.node) != NULL); - } - n = NEWHEAP(); - ptr = xrealloc(ptr, size); - return ADD2HEAP(n, cnt, ptr); -} - -static void -rb_parser_free(ptr) - void *ptr; -{ - NODE **prev = &parser_heap, *n; - - while ((n = *prev) != 0) { - if (n->u1.node == ptr) { - *prev = n->u2.node; - rb_gc_force_recycle((VALUE)n); - break; - } - prev = &n->u2.node; - } - xfree(ptr); -} -#endif - diff -Nru ruby1.8-1.8.7.22/process.c ruby1.8-1.8.7.72/process.c --- ruby1.8-1.8.7.22/process.c 2008-06-06 07:39:57.000000000 -0300 +++ ruby1.8-1.8.7.72/process.c 2008-06-29 06:34:43.000000000 -0300 @@ -2,8 +2,8 @@ process.c - - $Author: knu $ - $Date: 2008-06-06 19:39:57 +0900 (Fri, 06 Jun 2008) $ + $Author: shyouhei $ + $Date: 2008-06-29 18:34:43 +0900 (Sun, 29 Jun 2008) $ created at: Tue Aug 10 14:30:50 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -42,7 +42,7 @@ #ifdef HAVE_SYS_WAIT_H # include #endif -#ifdef HAVE_GETPRIORITY +#ifdef HAVE_SYS_RESOURCE_H # include #endif #include "st.h" diff -Nru ruby1.8-1.8.7.22/regex.c ruby1.8-1.8.7.72/regex.c --- ruby1.8-1.8.7.22/regex.c 2008-06-06 07:39:57.000000000 -0300 +++ ruby1.8-1.8.7.72/regex.c 2008-08-04 02:15:15.000000000 -0300 @@ -50,6 +50,9 @@ /* We need this for `regex.h', and perhaps for the Emacs include files. */ # include #endif +#ifdef HAVE_STDLIB_H +# include +#endif #if !defined(__STDC__) && !defined(_MSC_VER) # define volatile @@ -63,6 +66,10 @@ #ifdef RUBY_PLATFORM #include "defines.h" +#undef xmalloc +#undef xrealloc +#undef xcalloc +#undef xfree # define RUBY extern int rb_prohibit_interrupt; @@ -104,6 +111,11 @@ # include #endif +#define xmalloc malloc +#define xrealloc realloc +#define xcalloc calloc +#define xfree free + #ifdef C_ALLOCA #define FREE_VARIABLES() alloca(0) #else @@ -127,10 +139,12 @@ unsigned int xlen = stacke - stackb; \ if (stackb == stacka) { \ stackx = (type*)xmalloc(2 * xlen * sizeof(type)); \ + if (!stackx) goto memory_exhausted; \ memcpy(stackx, stackb, xlen * sizeof (type)); \ } \ else { \ stackx = (type*)xrealloc(stackb, 2 * xlen * sizeof(type)); \ + if (!stackx) goto memory_exhausted; \ } \ /* Rearrange the pointers. */ \ stackp = stackx + (stackp - stackb); \ @@ -2775,8 +2789,8 @@ The caller must supply the address of a (1 << BYTEWIDTH)-byte data area as bufp->fastmap. The other components of bufp describe the pattern to be used. */ -void -re_compile_fastmap(bufp) +static int +re_compile_fastmap0(bufp) struct re_pattern_buffer *bufp; { unsigned char *pattern = (unsigned char*)bufp->buffer; @@ -2944,7 +2958,7 @@ fastmap[j] = 1; } if (bufp->can_be_null) { - FREE_AND_RETURN_VOID(stackb); + FREE_AND_RETURN(stackb, 0); } /* Don't return; check the alternative paths so we can set can_be_null if appropriate. */ @@ -3110,7 +3124,16 @@ else break; } - FREE_AND_RETURN_VOID(stackb); + FREE_AND_RETURN(stackb, 0); + memory_exhausted: + FREE_AND_RETURN(stackb, -2); +} + +void +re_compile_fastmap(bufp) + struct re_pattern_buffer *bufp; +{ + (void)re_compile_fastmap0(bufp); } /* adjust startpos value to the position between characters. */ @@ -3144,7 +3167,8 @@ { /* Update the fastmap now if not correct already. */ if (!bufp->fastmap_accurate) { - re_compile_fastmap(bufp); + int ret = re_compile_fastmap0(bufp); + if (ret) return ret; } /* Adjust startpos for mbc string */ @@ -3190,7 +3214,8 @@ /* Update the fastmap now if not correct already. */ if (fastmap && !bufp->fastmap_accurate) { - re_compile_fastmap(bufp); + int ret = re_compile_fastmap0(bufp); + if (ret) return ret; } @@ -3580,7 +3605,7 @@ ``dummy''; if a failure happens and the failure point is a dummy, it gets discarded and the next next one is tried. */ - unsigned char **stacka; + unsigned char **const stacka = 0; unsigned char **stackb; unsigned char **stackp; unsigned char **stacke; @@ -3629,8 +3654,7 @@ } /* Initialize the stack. */ - stacka = RE_TALLOC(MAX_NUM_FAILURE_ITEMS * NFAILURES, unsigned char*); - stackb = stacka; + stackb = TMALLOC(MAX_NUM_FAILURE_ITEMS * NFAILURES, unsigned char*); stackp = stackb; stacke = &stackb[MAX_NUM_FAILURE_ITEMS * NFAILURES]; @@ -4400,6 +4424,8 @@ goto restore_best_regs; FREE_AND_RETURN(stackb,(-1)); /* Failure to match. */ + memory_exhausted: + FREE_AND_RETURN(stackb,(-2)); } @@ -4663,5 +4689,5 @@ mode : C c-file-style : "gnu" tab-width : 8 - End : + End */ diff -Nru ruby1.8-1.8.7.22/ruby.c ruby1.8-1.8.7.72/ruby.c --- ruby1.8-1.8.7.22/ruby.c 2008-06-06 07:39:57.000000000 -0300 +++ ruby1.8-1.8.7.72/ruby.c 2008-07-10 06:38:35.000000000 -0300 @@ -2,8 +2,8 @@ ruby.c - - $Author: knu $ - $Date: 2008-06-06 19:39:57 +0900 (Fri, 06 Jun 2008) $ + $Author: shyouhei $ + $Date: 2008-07-10 18:38:35 +0900 (Thu, 10 Jul 2008) $ created at: Tue Aug 10 12:47:31 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -1039,15 +1039,50 @@ #define set_arg0space() ((void)0) #endif +static int +get_arglen(int argc, char **argv) +{ + char *s = argv[0]; + int i; + + if (!argc) return 0; + s += strlen(s); + /* See if all the arguments are contiguous in memory */ + for (i = 1; i < argc; i++) { + if (argv[i] == s + 1) { + s++; + s += strlen(s); /* this one is ok too */ + } + else { + break; + } + } +#if defined(USE_ENVSPACE_FOR_ARG0) + if (environ && (s == environ[0])) { + s += strlen(s); + for (i = 1; environ[i]; i++) { + if (environ[i] == s + 1) { + s++; + s += strlen(s); /* this one is ok too */ + } + } + ruby_setenv("", NULL); /* duplicate environ vars */ + } +#endif + return s - argv[0]; +} + static void set_arg0(val, id) VALUE val; ID id; { + VALUE progname; char *s; long i; + int j; #if !defined(PSTAT_SETCMD) && !defined(HAVE_SETPROCTITLE) - static int len; + static int len = 0; #endif if (origargv == 0) rb_raise(rb_eRuntimeError, "$0 not initialized"); @@ -1068,33 +1103,13 @@ j.pst_command = s; pstat(PSTAT_SETCMD, j, i, 0, 0); } - rb_progname = rb_tainted_str_new(s, i); + progname = rb_tainted_str_new(s, i); #elif defined(HAVE_SETPROCTITLE) setproctitle("%.*s", (int)i, s); - rb_progname = rb_tainted_str_new(s, i); + progname = rb_tainted_str_new(s, i); #else if (len == 0) { - char *s = origargv[0]; - int i; - - s += strlen(s); - /* See if all the arguments are contiguous in memory */ - for (i = 1; i < origargc; i++) { - if (origargv[i] == s + 1) { - s++; - s += strlen(s); /* this one is ok too */ - } - else { - break; - } - } -#if defined(USE_ENVSPACE_FOR_ARG0) - if (s + 1 == envspace.begin) { - s = envspace.end; - ruby_setenv("", NULL); /* duplicate environ vars */ - } -#endif - len = s - origargv[0]; + len = get_arglen(origargc, origargv); } if (i >= len) { @@ -1104,10 +1119,13 @@ s = origargv[0] + i; *s = '\0'; if (++i < len) memset(s + 1, ' ', len - i); - for (i = 1; i < origargc; i++) - origargv[i] = s; - rb_progname = rb_tainted_str_new2(origargv[0]); + for (i = len-1, j = origargc-1; j > 0 && i >= 0; --i, --j) { + origargv[j] = origargv[0] + i; + *origargv[j] = '\0'; + } + progname = rb_tainted_str_new2(origargv[0]); #endif + rb_progname = rb_obj_freeze(progname); } void @@ -1115,7 +1133,7 @@ const char *name; { if (name) { - rb_progname = rb_tainted_str_new2(name); + rb_progname = rb_obj_freeze(rb_tainted_str_new2(name)); ruby_sourcefile = rb_source_filename(name); } } diff -Nru ruby1.8-1.8.7.22/ruby.h ruby1.8-1.8.7.72/ruby.h --- ruby1.8-1.8.7.22/ruby.h 2008-05-31 08:44:49.000000000 -0300 +++ ruby1.8-1.8.7.72/ruby.h 2008-07-10 01:54:53.000000000 -0300 @@ -2,7 +2,7 @@ ruby.h - - $Author: knu $ + $Author: shyouhei $ created at: Thu Jun 10 14:26:32 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -166,7 +166,7 @@ #define FIX2LONG(x) RSHIFT((long)x,1) #define FIX2ULONG(x) (((unsigned long)(x))>>1) #define FIXNUM_P(f) (((long)(f))&FIXNUM_FLAG) -#define POSFIXABLE(f) ((f) <= FIXNUM_MAX) +#define POSFIXABLE(f) ((f) < FIXNUM_MAX+1) #define NEGFIXABLE(f) ((f) >= FIXNUM_MIN) #define FIXABLE(f) (POSFIXABLE(f) && NEGFIXABLE(f)) diff -Nru ruby1.8-1.8.7.22/string.c ruby1.8-1.8.7.72/string.c --- ruby1.8-1.8.7.22/string.c 2008-06-20 06:28:35.000000000 -0300 +++ ruby1.8-1.8.7.72/string.c 2008-07-17 09:33:59.000000000 -0300 @@ -3,7 +3,7 @@ string.c - $Author: shyouhei $ - $Date: 2008-06-20 18:28:35 +0900 (Fri, 20 Jun 2008) $ + $Date: 2008-07-17 21:33:59 +0900 (Thu, 17 Jul 2008) $ created at: Mon Aug 9 17:12:58 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -462,7 +462,7 @@ rb_str_format_m(str, arg) VALUE str, arg; { - VALUE tmp = rb_check_array_type(arg); + volatile VALUE tmp = rb_check_array_type(arg); if (!NIL_P(tmp)) { return rb_str_format(RARRAY_LEN(tmp), RARRAY_PTR(tmp), str); @@ -708,9 +708,13 @@ const char *ptr; long len; { - long capa, total; + long capa, total, off = -1;; rb_str_modify(str); + if (ptr >= RSTRING(str)->ptr && ptr <= RSTRING(str)->ptr + RSTRING(str)->len) { + off = ptr - RSTRING(str)->ptr; + } + if (len == 0) return 0; if (FL_TEST(str, STR_ASSOC)) { FL_UNSET(str, STR_ASSOC); capa = RSTRING(str)->aux.capa = RSTRING(str)->len; @@ -732,6 +736,9 @@ } RESIZE_CAPA(str, capa); } + if (off != -1) { + ptr = RSTRING(str)->ptr + off; + } memcpy(RSTRING(str)->ptr + RSTRING(str)->len, ptr, len); RSTRING(str)->len = total; RSTRING(str)->ptr[total] = '\0'; /* sentinel */ diff -Nru ruby1.8-1.8.7.22/test/erb/test_erb.rb ruby1.8-1.8.7.72/test/erb/test_erb.rb --- ruby1.8-1.8.7.22/test/erb/test_erb.rb 2008-06-02 22:18:47.000000000 -0300 +++ ruby1.8-1.8.7.72/test/erb/test_erb.rb 2008-07-10 06:43:07.000000000 -0300 @@ -209,11 +209,13 @@ n.times do |i|%> %% %%><%%<%= i%><% end%> +%%% EOS ans = <<%0 % %%><%1 +%% EOS assert_equal(ans, ERB.new(src, nil, '%').result) end diff -Nru ruby1.8-1.8.7.22/test/ruby/test_float.rb ruby1.8-1.8.7.72/test/ruby/test_float.rb --- ruby1.8-1.8.7.22/test/ruby/test_float.rb 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/test/ruby/test_float.rb 2008-07-10 01:54:53.000000000 -0300 @@ -110,4 +110,38 @@ assert_equal(-3.5, (-11.5).remainder(4)) assert_equal(-3.5, (-11.5).remainder(-4)) end + + def test_to_i + assert_operator(4611686018427387905.0.to_i, :>, 0) + assert_operator(4611686018427387904.0.to_i, :>, 0) + assert_operator(4611686018427387903.8.to_i, :>, 0) + assert_operator(4611686018427387903.5.to_i, :>, 0) + assert_operator(4611686018427387903.2.to_i, :>, 0) + assert_operator(4611686018427387903.0.to_i, :>, 0) + assert_operator(4611686018427387902.0.to_i, :>, 0) + + assert_operator(1073741825.0.to_i, :>, 0) + assert_operator(1073741824.0.to_i, :>, 0) + assert_operator(1073741823.8.to_i, :>, 0) + assert_operator(1073741823.5.to_i, :>, 0) + assert_operator(1073741823.2.to_i, :>, 0) + assert_operator(1073741823.0.to_i, :>, 0) + assert_operator(1073741822.0.to_i, :>, 0) + + assert_operator((-1073741823.0).to_i, :<, 0) + assert_operator((-1073741824.0).to_i, :<, 0) + assert_operator((-1073741824.2).to_i, :<, 0) + assert_operator((-1073741824.5).to_i, :<, 0) + assert_operator((-1073741824.8).to_i, :<, 0) + assert_operator((-1073741825.0).to_i, :<, 0) + assert_operator((-1073741826.0).to_i, :<, 0) + + assert_operator((-4611686018427387903.0).to_i, :<, 0) + assert_operator((-4611686018427387904.0).to_i, :<, 0) + assert_operator((-4611686018427387904.2).to_i, :<, 0) + assert_operator((-4611686018427387904.5).to_i, :<, 0) + assert_operator((-4611686018427387904.8).to_i, :<, 0) + assert_operator((-4611686018427387905.0).to_i, :<, 0) + assert_operator((-4611686018427387906.0).to_i, :<, 0) + end end diff -Nru ruby1.8-1.8.7.22/test/ruby/test_time.rb ruby1.8-1.8.7.72/test/ruby/test_time.rb --- ruby1.8-1.8.7.22/test/ruby/test_time.rb 2007-02-12 20:01:19.000000000 -0300 +++ ruby1.8-1.8.7.72/test/ruby/test_time.rb 2008-06-29 08:09:30.000000000 -0300 @@ -71,4 +71,25 @@ assert_equal(Time.at(0x7fffffff), Time.at(-0x80000000) - (-0xffffffff)) end end + + def test_at + assert_equal(100000, Time.at(0.1).usec) + assert_equal(10000, Time.at(0.01).usec) + assert_equal(1000, Time.at(0.001).usec) + assert_equal(100, Time.at(0.0001).usec) + assert_equal(10, Time.at(0.00001).usec) + assert_equal(1, Time.at(0.000001).usec) + assert_equal(0, Time.at(1e-7).usec) + assert_equal(0, Time.at(4e-7).usec) + assert_equal(1, Time.at(6e-7).usec) + assert_equal(1, Time.at(14e-7).usec) + assert_equal(2, Time.at(16e-7).usec) + if negative_time_t? + assert_equal(0, Time.at(-1e-7).usec) + assert_equal(0, Time.at(-4e-7).usec) + assert_equal(999999, Time.at(-6e-7).usec) + assert_equal(999999, Time.at(-14e-7).usec) + assert_equal(999998, Time.at(-16e-7).usec) + end + end end diff -Nru ruby1.8-1.8.7.22/time.c ruby1.8-1.8.7.72/time.c --- ruby1.8-1.8.7.22/time.c 2008-06-06 07:39:57.000000000 -0300 +++ ruby1.8-1.8.7.72/time.c 2008-06-29 08:09:30.000000000 -0300 @@ -2,8 +2,8 @@ time.c - - $Author: knu $ - $Date: 2008-06-06 19:39:57 +0900 (Fri, 06 Jun 2008) $ + $Author: shyouhei $ + $Date: 2008-06-29 20:09:30 +0900 (Sun, 29 Jun 2008) $ created at: Tue Dec 28 14:31:59 JST 1993 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -192,6 +192,10 @@ double f, d; d = modf(RFLOAT(time)->value, &f); + if (d < 0) { + d += 1; + f -= 1; + } t.tv_sec = (time_t)f; if (f != t.tv_sec) { rb_raise(rb_eRangeError, "%f out of Time range", RFLOAT(time)->value); diff -Nru ruby1.8-1.8.7.22/util.c ruby1.8-1.8.7.72/util.c --- ruby1.8-1.8.7.22/util.c 2008-06-06 07:39:57.000000000 -0300 +++ ruby1.8-1.8.7.72/util.c 2008-06-29 05:10:06.000000000 -0300 @@ -2,8 +2,8 @@ util.c - - $Author: knu $ - $Date: 2008-06-06 19:39:57 +0900 (Fri, 06 Jun 2008) $ + $Author: shyouhei $ + $Date: 2008-06-29 17:10:06 +0900 (Sun, 29 Jun 2008) $ created at: Fri Mar 10 17:22:34 JST 1995 Copyright (C) 1993-2008 Yukihiro Matsumoto @@ -2171,6 +2171,8 @@ } #endif if (c == '.') { + if (!ISDIGIT(s[1])) + goto dig_done; c = *++s; if (!nd) { for (; c == '0'; c = *++s) diff -Nru ruby1.8-1.8.7.22/variable.c ruby1.8-1.8.7.72/variable.c --- ruby1.8-1.8.7.22/variable.c 2008-05-31 08:44:49.000000000 -0300 +++ ruby1.8-1.8.7.72/variable.c 2008-06-29 06:28:00.000000000 -0300 @@ -2,8 +2,8 @@ variable.c - - $Author: knu $ - $Date: 2008-05-31 20:44:49 +0900 (Sat, 31 May 2008) $ + $Author: shyouhei $ + $Date: 2008-06-29 18:28:00 +0900 (Sun, 29 Jun 2008) $ created at: Tue Apr 19 23:55:15 JST 1994 Copyright (C) 1993-2003 Yukihiro Matsumoto @@ -647,6 +647,7 @@ struct trace_var *trace; st_data_t data; + rb_secure(4); rb_scan_args(argc, argv, "11", &var, &cmd); id = rb_to_id(var); if (!st_lookup(rb_global_tbl, id, &data)) { diff -Nru ruby1.8-1.8.7.22/version.h ruby1.8-1.8.7.72/version.h --- ruby1.8-1.8.7.22/version.h 2008-06-20 06:28:35.000000000 -0300 +++ ruby1.8-1.8.7.72/version.h 2008-08-10 21:37:21.000000000 -0300 @@ -1,15 +1,15 @@ #define RUBY_VERSION "1.8.7" -#define RUBY_RELEASE_DATE "2008-06-20" +#define RUBY_RELEASE_DATE "2008-08-11" #define RUBY_VERSION_CODE 187 -#define RUBY_RELEASE_CODE 20080620 -#define RUBY_PATCHLEVEL 22 +#define RUBY_RELEASE_CODE 20080811 +#define RUBY_PATCHLEVEL 72 #define RUBY_VERSION_MAJOR 1 #define RUBY_VERSION_MINOR 8 #define RUBY_VERSION_TEENY 7 #define RUBY_RELEASE_YEAR 2008 -#define RUBY_RELEASE_MONTH 6 -#define RUBY_RELEASE_DAY 20 +#define RUBY_RELEASE_MONTH 8 +#define RUBY_RELEASE_DAY 11 #ifdef RUBY_EXTERN RUBY_EXTERN const char ruby_version[]; @@ -27,3 +27,5 @@ #define RUBY_RELEASE_STR "patchlevel" #define RUBY_RELEASE_NUM RUBY_PATCHLEVEL + +