diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 1999-01-11 07:55:27 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 1999-01-11 07:55:27 +0000 |
commit | a9c4c9041bd8ee877e062f93496a03d3c767d6e4 (patch) | |
tree | be7e553d1463426a284ad8c0588e9e717cfcf7b5 | |
parent | fb1369446bbe1f53f4144ba12f76b89f1a542835 (diff) |
1.2.1 stable
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/v1_1r@362 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | ChangeLog | 19 | ||||
-rw-r--r-- | Makefile.in | 4 | ||||
-rw-r--r-- | array.c | 2 | ||||
-rw-r--r-- | bignum.c | 1 | ||||
-rw-r--r-- | config.guess | 104 | ||||
-rw-r--r-- | config.sub | 51 | ||||
-rw-r--r-- | configure | 433 | ||||
-rw-r--r-- | configure.in | 9 | ||||
-rw-r--r-- | eval.c | 22 | ||||
-rw-r--r-- | ext/tcltklib/extconf.rb | 6 | ||||
-rw-r--r-- | ext/tcltklib/lib/tcltk.rb | 287 | ||||
-rw-r--r-- | gc.c | 26 | ||||
-rw-r--r-- | missing/nt.c | 4 | ||||
-rw-r--r-- | regex.c | 82 | ||||
-rw-r--r-- | st.c | 3 | ||||
-rw-r--r-- | util.c | 2 | ||||
-rw-r--r-- | version.h | 4 |
17 files changed, 585 insertions, 474 deletions
@@ -1,3 +1,22 @@ +Mon Jan 11 16:52:31 1999 Yukihiro Matsumoto <matz@netlab.co.jp> + + * version 1.2.1 (stable) released. + +Wed Jan 6 02:42:08 1999 Yukihiro Matsumoto <matz@netlab.co.jp> + + * bignum.c (Init_Bignum): forgot to define Bignum#===. + + * gc.c (gc_sweep): if add_heap() is called during GC, objects on + allocated heap page(s) are not marked, should not be recycled. + + * gc.c (gc_sweep): should refer latest freelist. + +Mon Dec 28 18:54:17 1998 Yukihiro Matsumoto <matz@netlab.co.jp> + + * gc.c (obj_free): better C_ALLOCA support. + + * eval.c (rb_eval): should not dump core with "#{}". + Fri Dec 25 13:07:46 1998 Yukihiro Matsumoto <matz@netlab.co.jp> * version 1.2 (stable) released. diff --git a/Makefile.in b/Makefile.in index f94889be15..35e947b725 100644 --- a/Makefile.in +++ b/Makefile.in @@ -74,9 +74,9 @@ OBJS = array.o \ all: miniruby$(binsuffix) rbconfig.rb @./miniruby$(binsuffix) -Xext extmk.rb @EXTSTATIC@ -miniruby$(binsuffix): $(OBJS) $(MAINOBJ) dmyext.o +miniruby$(binsuffix): libruby.a $(MAINOBJ) dmyext.o @rm -f $@ - $(PURIFY) $(CC) $(LDFLAGS) $(MAINOBJ) $(OBJS) dmyext.o $(LIBS) -o $@ + $(PURIFY) $(CC) $(LDFLAGS) $(MAINOBJ) dmyext.o libruby.a $(LIBS) -o $@ ruby$(binsuffix): $(LIBRUBY) $(MAINOBJ) $(EXTOBJS) @rm -f $@ @@ -795,7 +795,7 @@ ary_sort_bang(ary) if (RARRAY(ary)->len == 0) return ary; ary_modify(ary); - qsort(RARRAY(ary)->ptr, RARRAY(ary)->len, sizeof(VALUE), + rb_qsort(RARRAY(ary)->ptr, RARRAY(ary)->len, sizeof(VALUE), iterator_p()?sort_1:sort_2); return ary; } @@ -1295,6 +1295,7 @@ Init_Bignum() rb_define_method(cBignum, "<=>", big_cmp, 1); rb_define_method(cBignum, "==", big_eq, 1); + rb_define_method(cBignum, "===", big_eq, 1); rb_define_method(cBignum, "eql?", big_eq, 1); rb_define_method(cBignum, "hash", big_hash, 0); rb_define_method(cBignum, "to_i", big_to_i, 0); diff --git a/config.guess b/config.guess index d1eb24fcc1..0fdc826ba0 100644 --- a/config.guess +++ b/config.guess @@ -1,6 +1,6 @@ #! /bin/sh # Attempt to guess a canonical system name. -# Copyright (C) 1992, 93, 94, 95, 96, 1997 Free Software Foundation, Inc. +# Copyright (C) 1992, 93, 94, 95, 96, 97, 1998 Free Software Foundation, Inc. # # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -123,6 +123,9 @@ EOF amiga:OpenBSD:*:*) echo m68k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; + *:[Aa]miga[Oo][Ss]:*:*) + echo ${UNAME_MACHINE}-unknown-amigaos + exit 0 ;; arc64:OpenBSD:*:*) echo mips64el-unknown-openbsd${UNAME_RELEASE} exit 0 ;; @@ -150,7 +153,7 @@ EOF SR2?01:HI-UX/MPP:*:*) echo hppa1.1-hitachi-hiuxmpp exit 0;; - Pyramid*:OSx*:*:*|MIS*:OSx*:*:*) + Pyramid*:OSx*:*:*|MIS*:OSx*:*:*|MIS*:SMP_DC-OSx*:*:*) # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. if test "`(/bin/universe) 2>/dev/null`" = att ; then echo pyramid-pyramid-sysv3 @@ -161,6 +164,9 @@ EOF NILE:*:*:dcosx) echo pyramid-pyramid-svr4 exit 0 ;; + sun4H:SunOS:5.*:*) + echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit 0 ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; @@ -227,6 +233,9 @@ EOF powerpc:machten:*:*) echo powerpc-apple-machten${UNAME_RELEASE} exit 0 ;; + macppc:NetBSD:*:*) + echo powerpc-apple-netbsd${UNAME_RELEASE} + exit 0 ;; RISC*:Mach:*:*) echo mips-dec-mach_bsd4.3 exit 0 ;; @@ -332,7 +341,8 @@ EOF fi exit 0 ;; *:AIX:*:4) - if /usr/sbin/lsattr -EHl proc0 | grep POWER >/dev/null 2>&1; then + IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | head -1 | awk '{ print $1 }'` + if /usr/sbin/lsattr -EHl ${IBM_CPU_ID} | grep POWER >/dev/null 2>&1; then IBM_ARCH=rs6000 else IBM_ARCH=powerpc @@ -365,12 +375,44 @@ EOF hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) echo m68k-hp-bsd4.4 exit 0 ;; - 9000/[3478]??:HP-UX:*:*) + 9000/[34678]??:HP-UX:*:*) case "${UNAME_MACHINE}" in 9000/31? ) HP_ARCH=m68000 ;; 9000/[34]?? ) HP_ARCH=m68k ;; - 9000/7?? | 9000/8?[1679] ) HP_ARCH=hppa1.1 ;; - 9000/8?? ) HP_ARCH=hppa1.0 ;; + 9000/6?? | 9000/7?? | 9000/80[24] | 9000/8?[13679] | 9000/892 ) + sed 's/^ //' << EOF >dummy.c + #include <stdlib.h> + #include <unistd.h> + + int main () + { + #if defined(_SC_KERNEL_BITS) + long bits = sysconf(_SC_KERNEL_BITS); + #endif + long cpu = sysconf (_SC_CPU_VERSION); + + switch (cpu) + { + case CPU_PA_RISC1_0: puts ("hppa1.0"); break; + case CPU_PA_RISC1_1: puts ("hppa1.1"); break; + case CPU_PA_RISC2_0: + #if defined(_SC_KERNEL_BITS) + switch (bits) + { + case 64: puts ("hppa2.0w"); break; + case 32: puts ("hppa2.0n"); break; + default: puts ("hppa2.0"); break; + } break; + #else /* !defined(_SC_KERNEL_BITS) */ + puts ("hppa2.0"); break; + #endif + default: puts ("hppa1.0"); break; + } + exit (0); + } +EOF + (${CC-cc} dummy.c -o dummy 2>/dev/null ) && HP_ARCH=`./dummy` + rm -f dummy.c dummy esac HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` echo ${HP_ARCH}-hp-hpux${HPUX_REV} @@ -476,9 +518,15 @@ EOF hp300:OpenBSD:*:*) echo m68k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; - i?86:BSD/386:*:* | *:BSD/OS:*:*) + sparc*:BSD/OS:*:*) + echo sparc-unknown-bsdi${UNAME_RELEASE} + exit 0 ;; + i?86:BSD/386:*:* | i?86:BSD/OS:*:*) echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} exit 0 ;; + *:BSD/OS:*:*) + echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} + exit 0 ;; *:FreeBSD:*:*) echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit 0 ;; @@ -492,13 +540,13 @@ EOF echo i386-pc-bow exit 0 ;; i*:CYGWIN*:*) - echo i386-pc-cygwin32 + echo ${UNAME_MACHINE}-pc-cygwin exit 0 ;; i*:MINGW*:*) - echo i386-pc-mingw32 + echo ${UNAME_MACHINE}-pc-mingw32 exit 0 ;; p*:CYGWIN*:*) - echo powerpcle-unknown-cygwin32 + echo powerpcle-unknown-cygwin exit 0 ;; prep*:SunOS:5.*:*) echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` @@ -507,6 +555,12 @@ EOF echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` exit 0 ;; *:Linux:*:*) + # uname on the ARM produces all sorts of strangeness, and we need to + # filter it out. + case "$UNAME_MACHINE" in + arm* | sa110*) UNAME_MACHINE="arm" ;; + esac + # The BFD linker knows what the default object file format is, so # first see if it will tell us. ld_help_string=`ld --help 2>&1` @@ -567,11 +621,11 @@ EOF objdump --private-headers dummy | \ grep ld.so.1 > /dev/null if test "$?" = 0 ; then - LIBC="-libc1" + LIBC="libc1" fi fi rm -f dummy.s dummy - echo ${UNAME_MACHINE}-unknown-linux${LIBC} ; exit 0 + echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} ; exit 0 elif test "${UNAME_MACHINE}" = "mips" ; then cat >dummy.c <<EOF main(argc, argv) @@ -635,6 +689,13 @@ EOF echo ${UNAME_MACHINE}-pc-sysv32 fi exit 0 ;; + i?86:UnixWare:*:*) + if /bin/uname -X 2>/dev/null >/dev/null ; then + (/bin/uname -X|egrep '^Machine.*Pentium' >/dev/null) \ + && UNAME_MACHINE=i586 + fi + echo ${UNAME_MACHINE}-unixware-${UNAME_RELEASE}-${UNAME_VERSION} + exit 0 ;; pc:*:*:*) # uname -m prints for DJGPP always 'pc', but it prints nothing about # the processor, so we play safe by assuming i386. @@ -715,15 +776,12 @@ EOF mc68*:A/UX:*:*) echo m68k-apple-aux${UNAME_RELEASE} exit 0 ;; - X680[02346]0:Human68k:*:*) - echo m68k-sharp-human - exit 0 ;; news*:NEWS-OS:*:6*) echo mips-sony-newsos6 - exit 0 ;; - R3000:*System_V*:*:* | R4000:UNIX_SYSV:*:*) + exit 0 ;; + R3000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R4000:UNIX_SV:*:*) if [ -d /usr/nec ]; then - echo mips-nec-sysv${UNAME_RELEASE} + echo mips-nec-sysv`echo ${UNAME_RELEASE} | sed -n 's/\([.0-9]*\).*/\1/p'` else echo mips-unknown-sysv${UNAME_RELEASE} fi @@ -731,13 +789,13 @@ EOF DS/90*:*:*:V20*) echo sparc-fujitsu-uxpds exit 0 ;; - BeBox:BeOS:*:*) - echo powerpc-be-beos + BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. + echo powerpc-be-beos exit 0 ;; - BeMac:BeOS:*:*) - echo powerpc-apple-beos + BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. + echo powerpc-apple-beos exit 0 ;; - BePC:BeOS:*:*) + BePC:BeOS:*:*) # BeOS running on Intel PC compatible. echo i586-pc-beos exit 0 ;; diff --git a/config.sub b/config.sub index 9775812226..858aba7aa5 100644 --- a/config.sub +++ b/config.sub @@ -1,6 +1,6 @@ #! /bin/sh # Configuration validation subroutine script, version 1.1. -# Copyright (C) 1991, 92, 93, 94, 95, 96, 1997 Free Software Foundation, Inc. +# Copyright (C) 1991, 92-97, 1998 Free Software Foundation, Inc. # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software # can handle that machine. It does not imply ALL GNU software can. @@ -150,8 +150,8 @@ case $basic_machine in # Recognize the basic CPU types without company name. # Some are omitted here because they have special meanings below. tahoe | i860 | m32r | m68k | m68000 | m88k | ns32k | arc | arm \ - | arme[lb] | pyramid | mn10200 | mn10300 \ - | tron | a29k | 580 | i960 | h8300 | hppa | hppa1.0 | hppa1.1 \ + | arme[lb] | pyramid | mn10200 | mn10300 | tron | a29k \ + | 580 | i960 | h8300 | hppa | hppa1.0 | hppa1.1 | hppa2.0 \ | alpha | alphaev5 | alphaev56 | we32k | ns16k | clipper \ | i370 | sh | powerpc | powerpcle | 1750a | dsp16xx | pdp11 \ | mips64 | mipsel | mips64el | mips64orion | mips64orionel \ @@ -162,7 +162,7 @@ case $basic_machine in # We use `pc' rather than `unknown' # because (1) that's what they normally are, and # (2) the word "unknown" tends to confuse beginning users. - i[3456]86) + i[34567]86) basic_machine=$basic_machine-pc ;; i[3456]86-TOWNS*) @@ -174,11 +174,11 @@ case $basic_machine in exit 1 ;; # Recognize the basic CPU types with company name. - vax-* | tahoe-* | i[3456]86-* | i860-* | m32r-* | m68k-* | m68000-* \ + vax-* | tahoe-* | i[34567]86-* | i860-* | m32r-* | m68k-* | m68000-* \ | m88k-* | sparc-* | ns32k-* | fx80-* | arc-* | arm-* | c[123]* \ | mips-* | pyramid-* | tron-* | a29k-* | romp-* | rs6000-* \ | power-* | none-* | 580-* | cray2-* | h8300-* | i960-* \ - | xmp-* | ymp-* | hppa-* | hppa1.0-* | hppa1.1-* \ + | xmp-* | ymp-* | hppa-* | hppa1.0-* | hppa1.1-* | hppa2.0-* \ | alpha-* | alphaev5-* | alphaev56-* | we32k-* | cydra-* \ | ns16k-* | pn-* | np1-* | xps100-* | clipper-* | orion-* \ | sparclite-* | pdp11-* | sh-* | powerpc-* | powerpcle-* \ @@ -353,19 +353,19 @@ case $basic_machine in os=-mvs ;; # I'm not sure what "Sysv32" means. Should this be sysv3.2? - i[3456]86v32) + i[34567]86v32) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv32 ;; - i[3456]86v4*) + i[34567]86v4*) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv4 ;; - i[3456]86v) + i[34567]86v) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv ;; - i[3456]86sol2) + i[34567]86sol2) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-solaris2 ;; @@ -472,25 +472,23 @@ case $basic_machine in pc532 | pc532-*) basic_machine=ns32k-pc532 ;; - pentium | p5) - basic_machine=i586-intel + pentium | p5 | k5 | nexen) + basic_machine=i586-pc ;; - pentiumpro | p6) - basic_machine=i686-intel + pentiumpro | p6 | k6 | 6x86) + basic_machine=i686-pc ;; - pentium-* | p5-*) + pentiumii | pentium2) + basic_machine=i786-pc + ;; + pentium-* | p5-* | k5-* | nexen-*) basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` ;; - pentiumpro-* | p6-*) + pentiumpro-* | p6-* | k6-* | 6x86-*) basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` ;; - k5) - # We don't have specific support for AMD's K5 yet, so just call it a Pentium - basic_machine=i586-amd - ;; - nexen) - # We don't have specific support for Nexgen yet, so just call it a Pentium - basic_machine=i586-nexgen + pentiumii-* | pentium2-*) + basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pn) basic_machine=pn-gould @@ -722,8 +720,8 @@ case $os in | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ - | -cygwin32* | -pe* | -psos* | -moss* | -proelf* \ - | -linux* | -bow* | -rhapsody* | -openstep* ) + | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ + | -mingw32* | -linux* | -uxpv* | -beos*) # Remember, each alternative MUST END IN *, to match a version number. ;; -sunos5*) @@ -841,6 +839,9 @@ case $basic_machine in sparc-* | *-sun) os=-sunos4.1.1 ;; + *-be) + os=-beos + ;; *-ibm) os=-aix ;; @@ -562,7 +562,7 @@ fi if test $rb_thread = yes; then cat >> confdefs.h <<\EOF -#define THREAD 1 +#define USE_THREAD 1 EOF fi @@ -621,26 +621,38 @@ if test "${enable_fat_binary+set}" = set; then fat_binary=$enableval fi - if test "$fat_binary" = yes ; then + if test "$fat_binary" = yes ; then echo $ac_n "checking target architecture ""... $ac_c" 1>&6 echo "configure:628: checking target architecture " >&5 - if test "$host_os" = "rhapsody" ; then - echo -n "Rhapsody: " - if test "$TARGET_ARCHS" = "" ; then - TARGET_ARCHS="ppc i486" + case "$host_os" in + rhapsody*) + echo -n "MacOS X Server: " + if test "$TARGET_ARCHS" = "" ; then + TARGET_ARCHS="ppc i386" fi - else + ;; + nextstep*|openstep*) echo -n "NeXTSTEP/OPENSTEP: " - if test "$TARGET_ARCHS" = "" ; then - if test `/usr/bin/arch` = "m68k" ; then - TARGET_ARCHS="m68k i486" - else - TARGET_ARCHS="m68k `/usr/bin/arch`" - fi + + if test "$host_os" = "rhapsody" ; then + echo -n "Rhapsody: " + if test "$TARGET_ARCHS" = "" ; then + TARGET_ARCHS="ppc i486" + fi + else + echo -n "NeXTSTEP/OPENSTEP: " + if test "$TARGET_ARCHS" = "" ; then + if test `/usr/bin/arch` = "m68k" ; then + TARGET_ARCHS="m68k i486" + else # Black and Native one + TARGET_ARCHS="m68k `/usr/bin/arch`" + fi + fi fi - fi + ;; + esac # /usr/lib/arch_tool -archify_list $TARGET_ARCHS for archs in $TARGET_ARCHS do @@ -677,7 +689,7 @@ test "$program_transform_name" = "" && program_transform_name="s,x,x," # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:681: checking for $ac_word" >&5 +echo "configure:693: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -706,7 +718,7 @@ 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 $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:710: checking for $ac_word" >&5 +echo "configure:722: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -754,7 +766,7 @@ fi fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 -echo "configure:758: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 +echo "configure:770: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 ac_ext=c # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. @@ -764,11 +776,11 @@ ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS cross_compiling=$ac_cv_prog_cc_cross cat > conftest.$ac_ext <<EOF -#line 768 "configure" +#line 780 "configure" #include "confdefs.h" main(){return(0);} EOF -if { (eval echo configure:772: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:784: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then ac_cv_prog_cc_works=yes # If we can't run a trivial program, we are probably using a cross compiler. if (./conftest; exit) 2>/dev/null; then @@ -788,12 +800,12 @@ if test $ac_cv_prog_cc_works = no; then { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 -echo "configure:792: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 +echo "configure:804: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 cross_compiling=$ac_cv_prog_cc_cross echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 -echo "configure:797: checking whether we are using GNU C" >&5 +echo "configure:809: checking whether we are using GNU C" >&5 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -802,7 +814,7 @@ else yes; #endif EOF -if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:806: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then +if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:818: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then ac_cv_prog_gcc=yes else ac_cv_prog_gcc=no @@ -817,7 +829,7 @@ if test $ac_cv_prog_gcc = yes; then ac_save_CFLAGS="$CFLAGS" CFLAGS= echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 -echo "configure:821: checking whether ${CC-cc} accepts -g" >&5 +echo "configure:833: checking whether ${CC-cc} accepts -g" >&5 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -845,7 +857,7 @@ else fi echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 -echo "configure:849: checking how to run the C preprocessor" >&5 +echo "configure:861: checking how to run the C preprocessor" >&5 # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= @@ -860,13 +872,13 @@ else # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. cat > conftest.$ac_ext <<EOF -#line 864 "configure" +#line 876 "configure" #include "confdefs.h" #include <assert.h> Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:870: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:882: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then : @@ -877,13 +889,13 @@ else rm -rf conftest* CPP="${CC-cc} -E -traditional-cpp" cat > conftest.$ac_ext <<EOF -#line 881 "configure" +#line 893 "configure" #include "confdefs.h" #include <assert.h> Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:887: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:899: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then : @@ -907,13 +919,13 @@ echo "$ac_t""$CPP" 1>&6 if test $ac_cv_prog_gcc = yes; then echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6 -echo "configure:911: checking whether ${CC-cc} needs -traditional" >&5 +echo "configure:923: checking whether ${CC-cc} needs -traditional" >&5 if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else ac_pattern="Autoconf.*'x'" cat > conftest.$ac_ext <<EOF -#line 917 "configure" +#line 929 "configure" #include "confdefs.h" #include <sgtty.h> Autoconf TIOCGETP @@ -931,7 +943,7 @@ rm -f conftest* if test $ac_cv_prog_gcc_traditional = no; then cat > conftest.$ac_ext <<EOF -#line 935 "configure" +#line 947 "configure" #include "confdefs.h" #include <termio.h> Autoconf TCGETA @@ -957,7 +969,7 @@ 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 $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:961: checking for $ac_word" >&5 +echo "configure:973: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -989,7 +1001,7 @@ test -n "$YACC" || YACC="yacc" # Extract the first word of "ranlib", so it can be a program name with args. set dummy ranlib; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:993: checking for $ac_word" >&5 +echo "configure:1005: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1021,7 +1033,7 @@ 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 $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1025: checking for $ac_word" >&5 +echo "configure:1037: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1061,7 +1073,7 @@ test -n "$AR" || AR="ar" # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # ./install, which can be erroneously created by make from ./install.sh. echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 -echo "configure:1065: checking for a BSD compatible install" >&5 +echo "configure:1077: checking for a BSD compatible install" >&5 if test -z "$INSTALL"; then if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1111,7 +1123,7 @@ test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 -echo "configure:1115: checking whether ${MAKE-make} sets \${MAKE}" >&5 +echo "configure:1127: checking whether ${MAKE-make} sets \${MAKE}" >&5 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1141,17 +1153,17 @@ fi # checks for UNIX variants that set C preprocessor variables ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6 -echo "configure:1145: checking for minix/config.h" >&5 +echo "configure:1157: checking for minix/config.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1150 "configure" +#line 1162 "configure" #include "confdefs.h" #include <minix/config.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1155: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1167: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* @@ -1190,7 +1202,7 @@ fi echo $ac_n "checking size of int""... $ac_c" 1>&6 -echo "configure:1194: checking size of int" >&5 +echo "configure:1206: checking size of int" >&5 if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1198,7 +1210,7 @@ else { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } else cat > conftest.$ac_ext <<EOF -#line 1202 "configure" +#line 1214 "configure" #include "confdefs.h" #include <stdio.h> main() @@ -1209,7 +1221,7 @@ main() exit(0); } EOF -if { (eval echo configure:1213: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:1225: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then ac_cv_sizeof_int=`cat conftestval` else @@ -1229,7 +1241,7 @@ EOF echo $ac_n "checking size of long""... $ac_c" 1>&6 -echo "configure:1233: checking size of long" >&5 +echo "configure:1245: checking size of long" >&5 if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1237,7 +1249,7 @@ else { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } else cat > conftest.$ac_ext <<EOF -#line 1241 "configure" +#line 1253 "configure" #include "confdefs.h" #include <stdio.h> main() @@ -1248,7 +1260,7 @@ main() exit(0); } EOF -if { (eval echo configure:1252: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:1264: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then ac_cv_sizeof_long=`cat conftestval` else @@ -1268,7 +1280,7 @@ EOF echo $ac_n "checking size of void*""... $ac_c" 1>&6 -echo "configure:1272: checking size of void*" >&5 +echo "configure:1284: checking size of void*" >&5 if eval "test \"`echo '$''{'ac_cv_sizeof_voidp'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1276,7 +1288,7 @@ else { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } else cat > conftest.$ac_ext <<EOF -#line 1280 "configure" +#line 1292 "configure" #include "confdefs.h" #include <stdio.h> main() @@ -1287,7 +1299,7 @@ main() exit(0); } EOF -if { (eval echo configure:1291: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:1303: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then ac_cv_sizeof_voidp=`cat conftestval` else @@ -1308,19 +1320,19 @@ EOF echo $ac_n "checking for prototypes""... $ac_c" 1>&6 -echo "configure:1312: checking for prototypes" >&5 +echo "configure:1324: checking for prototypes" >&5 if eval "test \"`echo '$''{'rb_cv_have_prototypes'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1317 "configure" +#line 1329 "configure" #include "confdefs.h" int foo(int x) { return 0; } int main() { return foo(10); ; return 0; } EOF -if { (eval echo configure:1324: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1336: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_have_prototypes=yes else @@ -1341,12 +1353,12 @@ EOF fi echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6 -echo "configure:1345: checking for variable length prototypes and stdarg.h" >&5 +echo "configure:1357: checking for variable length prototypes and stdarg.h" >&5 if eval "test \"`echo '$''{'rb_cv_stdarg'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1350 "configure" +#line 1362 "configure" #include "confdefs.h" #include <stdarg.h> @@ -1363,7 +1375,7 @@ int main() { return foo(10, "", 3.14); ; return 0; } EOF -if { (eval echo configure:1367: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1379: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_stdarg=yes else @@ -1384,19 +1396,19 @@ EOF fi echo $ac_n "checking for gcc attribute noreturn""... $ac_c" 1>&6 -echo "configure:1388: checking for gcc attribute noreturn" >&5 +echo "configure:1400: checking for gcc attribute noreturn" >&5 if eval "test \"`echo '$''{'rb_cv_have_attr_noreturn'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1393 "configure" +#line 1405 "configure" #include "confdefs.h" void exit(int x) __attribute__ ((noreturn)); int main() { ; return 0; } EOF -if { (eval echo configure:1400: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1412: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_have_attr_noreturn=yes else @@ -1425,7 +1437,7 @@ beos*) ;; *) LIBS="-lm $LIBS";; esac echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6 -echo "configure:1429: checking for crypt in -lcrypt" >&5 +echo "configure:1441: checking for crypt in -lcrypt" >&5 ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1433,7 +1445,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lcrypt $LIBS" cat > conftest.$ac_ext <<EOF -#line 1437 "configure" +#line 1449 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -1444,7 +1456,7 @@ int main() { crypt() ; return 0; } EOF -if { (eval echo configure:1448: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:1460: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -1472,7 +1484,7 @@ else fi echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 -echo "configure:1476: checking for dlopen in -ldl" >&5 +echo "configure:1488: checking for dlopen in -ldl" >&5 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1480,7 +1492,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ldl $LIBS" cat > conftest.$ac_ext <<EOF -#line 1484 "configure" +#line 1496 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -1491,7 +1503,7 @@ int main() { dlopen() ; return 0; } EOF -if { (eval echo configure:1495: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:1507: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -1519,7 +1531,7 @@ else fi # Dynamic linking for SunOS/Solaris and SYSV echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 -echo "configure:1523: checking for shl_load in -ldld" >&5 +echo "configure:1535: checking for shl_load in -ldld" >&5 ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1527,7 +1539,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ldld $LIBS" cat > conftest.$ac_ext <<EOF -#line 1531 "configure" +#line 1543 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -1538,7 +1550,7 @@ int main() { shl_load() ; return 0; } EOF -if { (eval echo configure:1542: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:1554: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -1566,7 +1578,7 @@ else fi # Dynamic linking for HP-UX echo $ac_n "checking for setlocale in -lxpg4""... $ac_c" 1>&6 -echo "configure:1570: checking for setlocale in -lxpg4" >&5 +echo "configure:1582: checking for setlocale in -lxpg4" >&5 ac_lib_var=`echo xpg4'_'setlocale | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1574,7 +1586,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lxpg4 $LIBS" cat > conftest.$ac_ext <<EOF -#line 1578 "configure" +#line 1590 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -1585,7 +1597,7 @@ int main() { setlocale() ; return 0; } EOF -if { (eval echo configure:1589: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:1601: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -1618,12 +1630,12 @@ for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6 -echo "configure:1622: checking for $ac_hdr that defines DIR" >&5 +echo "configure:1634: checking for $ac_hdr that defines DIR" >&5 if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1627 "configure" +#line 1639 "configure" #include "confdefs.h" #include <sys/types.h> #include <$ac_hdr> @@ -1631,7 +1643,7 @@ int main() { DIR *dirp = 0; ; return 0; } EOF -if { (eval echo configure:1635: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1647: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* eval "ac_cv_header_dirent_$ac_safe=yes" else @@ -1656,7 +1668,7 @@ done # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. if test $ac_header_dirent = dirent.h; then echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6 -echo "configure:1660: checking for opendir in -ldir" >&5 +echo "configure:1672: checking for opendir in -ldir" >&5 ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1664,7 +1676,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ldir $LIBS" cat > conftest.$ac_ext <<EOF -#line 1668 "configure" +#line 1680 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -1675,7 +1687,7 @@ int main() { opendir() ; return 0; } EOF -if { (eval echo configure:1679: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:1691: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -1697,7 +1709,7 @@ fi else echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6 -echo "configure:1701: checking for opendir in -lx" >&5 +echo "configure:1713: checking for opendir in -lx" >&5 ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1705,7 +1717,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lx $LIBS" cat > conftest.$ac_ext <<EOF -#line 1709 "configure" +#line 1721 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -1716,7 +1728,7 @@ int main() { opendir() ; return 0; } EOF -if { (eval echo configure:1720: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:1732: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -1739,12 +1751,12 @@ fi fi echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 -echo "configure:1743: checking for ANSI C header files" >&5 +echo "configure:1755: checking for ANSI C header files" >&5 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1748 "configure" +#line 1760 "configure" #include "confdefs.h" #include <stdlib.h> #include <stdarg.h> @@ -1752,7 +1764,7 @@ else #include <float.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1756: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1768: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* @@ -1769,7 +1781,7 @@ rm -f conftest* if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat > conftest.$ac_ext <<EOF -#line 1773 "configure" +#line 1785 "configure" #include "confdefs.h" #include <string.h> EOF @@ -1787,7 +1799,7 @@ 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 <<EOF -#line 1791 "configure" +#line 1803 "configure" #include "confdefs.h" #include <stdlib.h> EOF @@ -1808,7 +1820,7 @@ if test "$cross_compiling" = yes; then : else cat > conftest.$ac_ext <<EOF -#line 1812 "configure" +#line 1824 "configure" #include "confdefs.h" #include <ctype.h> #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') @@ -1819,7 +1831,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); exit (0); } EOF -if { (eval echo configure:1823: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:1835: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then : else @@ -1848,17 +1860,17 @@ for ac_hdr in stdlib.h unistd.h limits.h sys/file.h sys/ioctl.h pwd.h \ do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:1852: checking for $ac_hdr" >&5 +echo "configure:1864: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1857 "configure" +#line 1869 "configure" #include "confdefs.h" #include <$ac_hdr> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1862: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1874: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* @@ -1886,12 +1898,12 @@ done echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6 -echo "configure:1890: checking for uid_t in sys/types.h" >&5 +echo "configure:1902: checking for uid_t in sys/types.h" >&5 if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1895 "configure" +#line 1907 "configure" #include "confdefs.h" #include <sys/types.h> EOF @@ -1920,12 +1932,12 @@ EOF fi echo $ac_n "checking for size_t""... $ac_c" 1>&6 -echo "configure:1924: checking for size_t" >&5 +echo "configure:1936: checking for size_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1929 "configure" +#line 1941 "configure" #include "confdefs.h" #include <sys/types.h> #if STDC_HEADERS @@ -1953,12 +1965,12 @@ EOF fi echo $ac_n "checking for st_blksize in struct stat""... $ac_c" 1>&6 -echo "configure:1957: checking for st_blksize in struct stat" >&5 +echo "configure:1969: checking for st_blksize in struct stat" >&5 if eval "test \"`echo '$''{'ac_cv_struct_st_blksize'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1962 "configure" +#line 1974 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/stat.h> @@ -1966,7 +1978,7 @@ int main() { struct stat s; s.st_blksize; ; return 0; } EOF -if { (eval echo configure:1970: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1982: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_st_blksize=yes else @@ -1988,12 +2000,12 @@ fi save_LIBOJBS="$LIBOBJS" echo $ac_n "checking for st_blocks in struct stat""... $ac_c" 1>&6 -echo "configure:1992: checking for st_blocks in struct stat" >&5 +echo "configure:2004: checking for st_blocks in struct stat" >&5 if eval "test \"`echo '$''{'ac_cv_struct_st_blocks'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1997 "configure" +#line 2009 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/stat.h> @@ -2001,7 +2013,7 @@ int main() { struct stat s; s.st_blocks; ; return 0; } EOF -if { (eval echo configure:2005: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2017: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_st_blocks=yes else @@ -2025,12 +2037,12 @@ fi LIBOBJS="$save_LIBOBJS" echo $ac_n "checking for st_rdev in struct stat""... $ac_c" 1>&6 -echo "configure:2029: checking for st_rdev in struct stat" >&5 +echo "configure:2041: checking for st_rdev in struct stat" >&5 if eval "test \"`echo '$''{'ac_cv_struct_st_rdev'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2034 "configure" +#line 2046 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/stat.h> @@ -2038,7 +2050,7 @@ int main() { struct stat s; s.st_rdev; ; return 0; } EOF -if { (eval echo configure:2042: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2054: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_st_rdev=yes else @@ -2060,7 +2072,7 @@ fi echo $ac_n "checking type of array argument to getgroups""... $ac_c" 1>&6 -echo "configure:2064: checking type of array argument to getgroups" >&5 +echo "configure:2076: checking type of array argument to getgroups" >&5 if eval "test \"`echo '$''{'ac_cv_type_getgroups'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2068,7 +2080,7 @@ else ac_cv_type_getgroups=cross else cat > conftest.$ac_ext <<EOF -#line 2072 "configure" +#line 2084 "configure" #include "confdefs.h" /* Thanks to Mike Rendell for this test. */ @@ -2093,7 +2105,7 @@ main() } EOF -if { (eval echo configure:2097: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2109: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then ac_cv_type_getgroups=gid_t else @@ -2107,7 +2119,7 @@ fi if test $ac_cv_type_getgroups = cross; then cat > conftest.$ac_ext <<EOF -#line 2111 "configure" +#line 2123 "configure" #include "confdefs.h" #include <unistd.h> EOF @@ -2131,12 +2143,12 @@ EOF echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 -echo "configure:2135: checking return type of signal handlers" >&5 +echo "configure:2147: checking return type of signal handlers" >&5 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2140 "configure" +#line 2152 "configure" #include "confdefs.h" #include <sys/types.h> #include <signal.h> @@ -2153,7 +2165,7 @@ int main() { int i; ; return 0; } EOF -if { (eval echo configure:2157: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2169: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_type_signal=void else @@ -2174,19 +2186,19 @@ EOF # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works # for constant arguments. Useless! echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 -echo "configure:2178: checking for working alloca.h" >&5 +echo "configure:2190: checking for working alloca.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2183 "configure" +#line 2195 "configure" #include "confdefs.h" #include <alloca.h> int main() { char *p = alloca(2 * sizeof(int)); ; return 0; } EOF -if { (eval echo configure:2190: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:2202: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* ac_cv_header_alloca_h=yes else @@ -2207,12 +2219,12 @@ EOF fi echo $ac_n "checking for alloca""... $ac_c" 1>&6 -echo "configure:2211: checking for alloca" >&5 +echo "configure:2223: checking for alloca" >&5 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2216 "configure" +#line 2228 "configure" #include "confdefs.h" #ifdef __GNUC__ @@ -2235,7 +2247,7 @@ int main() { char *p = (char *) alloca(1); ; return 0; } EOF -if { (eval echo configure:2239: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:2251: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* ac_cv_func_alloca_works=yes else @@ -2267,12 +2279,12 @@ EOF echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 -echo "configure:2271: checking whether alloca needs Cray hooks" >&5 +echo "configure:2283: checking whether alloca needs Cray hooks" >&5 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2276 "configure" +#line 2288 "configure" #include "confdefs.h" #if defined(CRAY) && ! defined(CRAY2) webecray @@ -2297,12 +2309,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6 if test $ac_cv_os_cray = yes; then for ac_func in _getb67 GETB67 getb67; do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:2301: checking for $ac_func" >&5 +echo "configure:2313: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2306 "configure" +#line 2318 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -2325,7 +2337,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:2329: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:2341: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -2352,7 +2364,7 @@ done fi echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 -echo "configure:2356: checking stack direction for C alloca" >&5 +echo "configure:2368: checking stack direction for C alloca" >&5 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2360,7 +2372,7 @@ else ac_cv_c_stack_direction=0 else cat > conftest.$ac_ext <<EOF -#line 2364 "configure" +#line 2376 "configure" #include "confdefs.h" find_stack_direction () { @@ -2379,7 +2391,7 @@ main () exit (find_stack_direction() < 0); } EOF -if { (eval echo configure:2383: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2395: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then ac_cv_c_stack_direction=1 else @@ -2401,12 +2413,12 @@ EOF fi echo $ac_n "checking for pid_t""... $ac_c" 1>&6 -echo "configure:2405: checking for pid_t" >&5 +echo "configure:2417: checking for pid_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2410 "configure" +#line 2422 "configure" #include "confdefs.h" #include <sys/types.h> #if STDC_HEADERS @@ -2435,17 +2447,17 @@ fi ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for vfork.h""... $ac_c" 1>&6 -echo "configure:2439: checking for vfork.h" >&5 +echo "configure:2451: checking for vfork.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2444 "configure" +#line 2456 "configure" #include "confdefs.h" #include <vfork.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2449: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:2461: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* @@ -2470,18 +2482,18 @@ else fi echo $ac_n "checking for working vfork""... $ac_c" 1>&6 -echo "configure:2474: checking for working vfork" >&5 +echo "configure:2486: checking for working vfork" >&5 if eval "test \"`echo '$''{'ac_cv_func_vfork_works'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else if test "$cross_compiling" = yes; then echo $ac_n "checking for vfork""... $ac_c" 1>&6 -echo "configure:2480: checking for vfork" >&5 +echo "configure:2492: checking for vfork" >&5 if eval "test \"`echo '$''{'ac_cv_func_vfork'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2485 "configure" +#line 2497 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char vfork(); below. */ @@ -2504,7 +2516,7 @@ vfork(); ; return 0; } EOF -if { (eval echo configure:2508: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:2520: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_vfork=yes" else @@ -2525,7 +2537,7 @@ fi else cat > conftest.$ac_ext <<EOF -#line 2529 "configure" +#line 2541 "configure" #include "confdefs.h" /* Thanks to Paul Eggert for this test. */ #include <stdio.h> @@ -2620,7 +2632,7 @@ main() { } } EOF -if { (eval echo configure:2624: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2636: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then ac_cv_func_vfork_works=yes else @@ -2643,7 +2655,7 @@ EOF fi echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6 -echo "configure:2647: checking for 8-bit clean memcmp" >&5 +echo "configure:2659: checking for 8-bit clean memcmp" >&5 if eval "test \"`echo '$''{'ac_cv_func_memcmp_clean'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2651,7 +2663,7 @@ else ac_cv_func_memcmp_clean=no else cat > conftest.$ac_ext <<EOF -#line 2655 "configure" +#line 2667 "configure" #include "confdefs.h" main() @@ -2661,7 +2673,7 @@ main() } EOF -if { (eval echo configure:2665: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2677: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then ac_cv_func_memcmp_clean=yes else @@ -2678,16 +2690,16 @@ fi echo "$ac_t""$ac_cv_func_memcmp_clean" 1>&6 test $ac_cv_func_memcmp_clean = no && LIBOBJS="$LIBOBJS memcmp.o" -for ac_func in dup2 setenv memmove mkdir strcasecmp strerror strftime\ +for ac_func in dup2 memmove mkdir strcasecmp strerror strftime\ strchr strstr strtoul strdup crypt flock vsnprintf do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:2686: checking for $ac_func" >&5 +echo "configure:2698: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2691 "configure" +#line 2703 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -2710,7 +2722,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:2714: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:2726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -2739,16 +2751,16 @@ done for ac_func in fmod killpg drand48 random wait4 waitpid syscall getcwd\ truncate chsize times utimes fcntl lockf setitimer\ setruid seteuid setreuid setrgid setegid setregid\ - setpgrp2 getpgid getgroups getpriority\ + setpgrp2 getpgid setpgid getgroups getpriority\ dlopen sigprocmask sigaction _setjmp setpgrp setsid do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:2747: checking for $ac_func" >&5 +echo "configure:2759: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2752 "configure" +#line 2764 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -2771,7 +2783,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:2775: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:2787: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -2797,12 +2809,12 @@ done if test "$ac_cv_func_strftime" = no; then echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 -echo "configure:2801: checking whether struct tm is in sys/time.h or time.h" >&5 +echo "configure:2813: checking whether struct tm is in sys/time.h or time.h" >&5 if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2806 "configure" +#line 2818 "configure" #include "confdefs.h" #include <sys/types.h> #include <time.h> @@ -2810,7 +2822,7 @@ int main() { struct tm *tp; tp->tm_sec; ; return 0; } EOF -if { (eval echo configure:2814: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2826: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_tm=time.h else @@ -2831,12 +2843,12 @@ EOF fi echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 -echo "configure:2835: checking for tm_zone in struct tm" >&5 +echo "configure:2847: checking for tm_zone in struct tm" >&5 if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2840 "configure" +#line 2852 "configure" #include "confdefs.h" #include <sys/types.h> #include <$ac_cv_struct_tm> @@ -2844,7 +2856,7 @@ int main() { struct tm tm; tm.tm_zone; ; return 0; } EOF -if { (eval echo configure:2848: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2860: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_tm_zone=yes else @@ -2864,12 +2876,12 @@ EOF else echo $ac_n "checking for tzname""... $ac_c" 1>&6 -echo "configure:2868: checking for tzname" >&5 +echo "configure:2880: checking for tzname" >&5 if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2873 "configure" +#line 2885 "configure" #include "confdefs.h" #include <time.h> #ifndef tzname /* For SGI. */ @@ -2879,7 +2891,7 @@ int main() { atoi(*tzname); ; return 0; } EOF -if { (eval echo configure:2883: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:2895: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* ac_cv_var_tzname=yes else @@ -2901,14 +2913,14 @@ EOF fi cat > conftest.$ac_ext <<EOF -#line 2905 "configure" +#line 2917 "configure" #include "confdefs.h" int main() { extern int daylight; int i = daylight; ; return 0; } EOF -if { (eval echo configure:2912: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:2924: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* cat >> confdefs.h <<\EOF #define HAVE_DAYLIGHT 1 @@ -2928,7 +2940,7 @@ EOF else echo $ac_n "checking for BSD signal semantics""... $ac_c" 1>&6 -echo "configure:2932: checking for BSD signal semantics" >&5 +echo "configure:2944: checking for BSD signal semantics" >&5 if eval "test \"`echo '$''{'rb_cv_bsd_signal'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2936,7 +2948,7 @@ else { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } else cat > conftest.$ac_ext <<EOF -#line 2940 "configure" +#line 2952 "configure" #include "confdefs.h" #include <stdio.h> @@ -2958,7 +2970,7 @@ main() } EOF -if { (eval echo configure:2962: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2974: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then rb_cv_bsd_signal=yes else @@ -2992,19 +3004,19 @@ EOF else echo $ac_n "checking whether getpgrp() has arg""... $ac_c" 1>&6 -echo "configure:2996: checking whether getpgrp() has arg" >&5 +echo "configure:3008: checking whether getpgrp() has arg" >&5 if eval "test \"`echo '$''{'rb_cv_bsdgetpgrp'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 3001 "configure" +#line 3013 "configure" #include "confdefs.h" #include <unistd.h> int main() { getpgrp(0); ; return 0; } EOF -if { (eval echo configure:3008: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3020: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_bsdgetpgrp=yes else @@ -3025,19 +3037,19 @@ EOF fi echo $ac_n "checking whether setpgrp() has args""... $ac_c" 1>&6 -echo "configure:3029: checking whether setpgrp() has args" >&5 +echo "configure:3041: checking whether setpgrp() has args" >&5 if eval "test \"`echo '$''{'rb_cv_bsdsetpgrp'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 3034 "configure" +#line 3046 "configure" #include "confdefs.h" #include <unistd.h> int main() { setpgrp(1, 1); ; return 0; } EOF -if { (eval echo configure:3041: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3053: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_bsdsetpgrp=yes else @@ -3059,14 +3071,14 @@ EOF fi echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 -echo "configure:3063: checking whether byte ordering is bigendian" >&5 +echo "configure:3075: checking whether byte ordering is bigendian" >&5 if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else ac_cv_c_bigendian=unknown # See if sys/param.h defines the BYTE_ORDER macro. cat > conftest.$ac_ext <<EOF -#line 3070 "configure" +#line 3082 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/param.h> @@ -3077,11 +3089,11 @@ int main() { #endif ; return 0; } EOF -if { (eval echo configure:3081: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3093: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* # It does; now see whether it defined to BIG_ENDIAN or not. cat > conftest.$ac_ext <<EOF -#line 3085 "configure" +#line 3097 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/param.h> @@ -3092,7 +3104,7 @@ int main() { #endif ; return 0; } EOF -if { (eval echo configure:3096: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3108: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_bigendian=yes else @@ -3112,7 +3124,7 @@ if test "$cross_compiling" = yes; then { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } else cat > conftest.$ac_ext <<EOF -#line 3116 "configure" +#line 3128 "configure" #include "confdefs.h" main () { /* Are we little or big endian? From Harbison&Steele. */ @@ -3125,7 +3137,7 @@ main () { exit (u.c[sizeof (long) - 1] == 1); } EOF -if { (eval echo configure:3129: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3141: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then ac_cv_c_bigendian=no else @@ -3149,14 +3161,14 @@ EOF fi echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6 -echo "configure:3153: checking whether char is unsigned" >&5 +echo "configure:3165: checking whether char is unsigned" >&5 if eval "test \"`echo '$''{'ac_cv_c_char_unsigned'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else if test "$GCC" = yes; then # GCC predefines this symbol on systems where it applies. cat > conftest.$ac_ext <<EOF -#line 3160 "configure" +#line 3172 "configure" #include "confdefs.h" #ifdef __CHAR_UNSIGNED__ yes @@ -3178,7 +3190,7 @@ if test "$cross_compiling" = yes; then { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } else cat > conftest.$ac_ext <<EOF -#line 3182 "configure" +#line 3194 "configure" #include "confdefs.h" /* volatile prevents gcc2 from optimizing the test away on sparcs. */ #if !defined(__STDC__) || __STDC__ != 1 @@ -3188,7 +3200,7 @@ main() { volatile char c = 255; exit(c < 0); } EOF -if { (eval echo configure:3192: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3204: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then ac_cv_c_char_unsigned=yes else @@ -3213,7 +3225,7 @@ fi echo $ac_n "checking whether right shift preserve sign bit""... $ac_c" 1>&6 -echo "configure:3217: checking whether right shift preserve sign bit" >&5 +echo "configure:3229: checking whether right shift preserve sign bit" >&5 if eval "test \"`echo '$''{'rb_cv_rshift_sign'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -3221,7 +3233,7 @@ else { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } else cat > conftest.$ac_ext <<EOF -#line 3225 "configure" +#line 3237 "configure" #include "confdefs.h" int @@ -3233,7 +3245,7 @@ main() } EOF -if { (eval echo configure:3237: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3249: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then rb_cv_rshift_sign=yes else @@ -3261,19 +3273,19 @@ EOF fi echo $ac_n "checking count field in FILE structures""... $ac_c" 1>&6 -echo "configure:3265: checking count field in FILE structures" >&5 +echo "configure:3277: checking count field in FILE structures" >&5 if eval "test \"`echo '$''{'rb_cv_fcnt'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 3270 "configure" +#line 3282 "configure" #include "confdefs.h" #include <stdio.h> int main() { FILE *f = stdin; f->_cnt = 0; ; return 0; } EOF -if { (eval echo configure:3277: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3289: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_fcnt="_cnt" else @@ -3283,14 +3295,14 @@ fi rm -f conftest* if test "$rb_cv_fcnt" = ""; then cat > conftest.$ac_ext <<EOF -#line 3287 "configure" +#line 3299 "configure" #include "confdefs.h" #include <stdio.h> int main() { FILE *f = stdin; f->__cnt = 0; ; return 0; } EOF -if { (eval echo configure:3294: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3306: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_fcnt="__cnt" else @@ -3301,14 +3313,14 @@ rm -f conftest* fi if test "$rb_cv_fcnt" = ""; then cat > conftest.$ac_ext <<EOF -#line 3305 "configure" +#line 3317 "configure" #include "confdefs.h" #include <stdio.h> int main() { FILE *f = stdin; f->_r = 0; ; return 0; } EOF -if { (eval echo configure:3312: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3324: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_fcnt="_r" else @@ -3319,14 +3331,14 @@ rm -f conftest* fi if test "$rb_cv_fcnt" = ""; then cat > conftest.$ac_ext <<EOF -#line 3323 "configure" +#line 3335 "configure" #include "confdefs.h" #include <stdio.h> int main() { FILE *f = stdin; f->readCount = 0; ; return 0; } EOF -if { (eval echo configure:3330: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3342: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_fcnt="readCount" else @@ -3365,7 +3377,7 @@ fi case "$host_os" in linux*) echo $ac_n "checking whether ELF binaries are produced""... $ac_c" 1>&6 -echo "configure:3369: checking whether ELF binaries are produced" >&5 +echo "configure:3381: checking whether ELF binaries are produced" >&5 if eval "test \"`echo '$''{'rb_cv_linux_elf'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -3373,7 +3385,7 @@ else : else cat > conftest.$ac_ext <<EOF -#line 3377 "configure" +#line 3389 "configure" #include "confdefs.h" /* Test for whether ELF binaries are produced */ @@ -3393,7 +3405,7 @@ main() { } EOF -if { (eval echo configure:3397: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3409: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then rb_cv_linux_elf=yes else @@ -3423,7 +3435,7 @@ STATIC= if test "$with_dln_a_out" != yes; then rb_cv_dlopen=unknown echo $ac_n "checking whether OS depend dynamic link works""... $ac_c" 1>&6 -echo "configure:3427: checking whether OS depend dynamic link works" >&5 +echo "configure:3439: checking whether OS depend dynamic link works" >&5 if test "$GCC" = yes; then case "$host_os" in nextstep*) ;; @@ -3467,7 +3479,8 @@ echo "configure:3427: checking whether OS depend dynamic link works" >&5 rb_cv_dlopen=yes ;; netbsd*) LDSHARED="ld -Bshareable" rb_cv_dlopen=yes ;; - openbsd*) LDSHARED="ld -Bshareable" + openbsd*) LDSHARED="ld -Bforcearchive -Bshareable" + CCDLFLAGS=-fPIC rb_cv_dlopen=yes ;; nextstep*) LDSHARED='cc -r' LDFLAGS="-u libsys_s" @@ -3506,13 +3519,13 @@ 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 echo $ac_n "checking whether matz's dln works""... $ac_c" 1>&6 -echo "configure:3510: checking whether matz's dln works" >&5 +echo "configure:3523: checking whether matz's dln works" >&5 cat confdefs.h > config.h if eval "test \"`echo '$''{'rb_cv_dln_a_out'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 3516 "configure" +#line 3529 "configure" #include "confdefs.h" #define USE_DLN_A_OUT @@ -3522,7 +3535,7 @@ int main() { ; return 0; } EOF -if { (eval echo configure:3526: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3539: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_dln_a_out=yes else @@ -3624,7 +3637,7 @@ fi case "$host_os" in human*) echo $ac_n "checking for _harderr in -lsignal""... $ac_c" 1>&6 -echo "configure:3628: checking for _harderr in -lsignal" >&5 +echo "configure:3641: checking for _harderr in -lsignal" >&5 ac_lib_var=`echo signal'_'_harderr | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -3632,7 +3645,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lsignal $LIBS" cat > conftest.$ac_ext <<EOF -#line 3636 "configure" +#line 3649 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -3643,7 +3656,7 @@ int main() { _harderr() ; return 0; } EOF -if { (eval echo configure:3647: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:3660: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -3671,7 +3684,7 @@ else fi echo $ac_n "checking for hmemset in -lhmem""... $ac_c" 1>&6 -echo "configure:3675: checking for hmemset in -lhmem" >&5 +echo "configure:3688: checking for hmemset in -lhmem" >&5 ac_lib_var=`echo hmem'_'hmemset | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -3679,7 +3692,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lhmem $LIBS" cat > conftest.$ac_ext <<EOF -#line 3683 "configure" +#line 3696 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -3690,7 +3703,7 @@ int main() { hmemset() ; return 0; } EOF -if { (eval echo configure:3694: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:3707: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -3720,12 +3733,12 @@ fi for ac_func in select do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:3724: checking for $ac_func" >&5 +echo "configure:3737: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 3729 "configure" +#line 3742 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -3748,7 +3761,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:3752: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:3765: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -3773,7 +3786,7 @@ fi done echo $ac_n "checking whether PD libc _dtos18 fail to convert big number""... $ac_c" 1>&6 -echo "configure:3777: checking whether PD libc _dtos18 fail to convert big number" >&5 +echo "configure:3790: checking whether PD libc _dtos18 fail to convert big number" >&5 if eval "test \"`echo '$''{'rb_cv_missing__dtos18'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -3781,7 +3794,7 @@ else { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } else cat > conftest.$ac_ext <<EOF -#line 3785 "configure" +#line 3798 "configure" #include "confdefs.h" #include <stdio.h> @@ -3793,7 +3806,7 @@ main () } EOF -if { (eval echo configure:3797: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3810: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then rb_cv_missing__dtos18=yes else @@ -3815,7 +3828,7 @@ EOF fi echo $ac_n "checking whether PD libc fconvert fail to round""... $ac_c" 1>&6 -echo "configure:3819: checking whether PD libc fconvert fail to round" >&5 +echo "configure:3832: checking whether PD libc fconvert fail to round" >&5 if eval "test \"`echo '$''{'rb_cv_missing_fconvert'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -3823,7 +3836,7 @@ else { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } else cat > conftest.$ac_ext <<EOF -#line 3827 "configure" +#line 3840 "configure" #include "confdefs.h" #include <stdio.h> @@ -3836,7 +3849,7 @@ main () } EOF -if { (eval echo configure:3840: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3853: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null then rb_cv_missing_fconvert=yes else diff --git a/configure.in b/configure.in index 9ef13c52a3..c6c1d9596e 100644 --- a/configure.in +++ b/configure.in @@ -24,7 +24,7 @@ AC_ARG_ENABLE(thread, [--disable-thread never use user-level thread], [ rb_thread=$enableval ]) if test $rb_thread = yes; then - AC_DEFINE(THREAD) + AC_DEFINE(USE_THREAD) fi AC_CANONICAL_HOST @@ -170,12 +170,12 @@ AC_TYPE_SIGNAL AC_FUNC_ALLOCA AC_FUNC_VFORK AC_FUNC_MEMCMP -AC_REPLACE_FUNCS(dup2 setenv memmove mkdir strcasecmp strerror strftime\ +AC_REPLACE_FUNCS(dup2 memmove mkdir strcasecmp strerror strftime\ strchr strstr strtoul strdup crypt flock vsnprintf) AC_CHECK_FUNCS(fmod killpg drand48 random wait4 waitpid syscall getcwd\ truncate chsize times utimes fcntl lockf setitimer\ setruid seteuid setreuid setrgid setegid setregid\ - setpgrp2 getpgid getgroups getpriority\ + setpgrp2 getpgid setpgid getgroups getpriority\ dlopen sigprocmask sigaction _setjmp setpgrp setsid) if test "$ac_cv_func_strftime" = no; then AC_STRUCT_TIMEZONE @@ -382,7 +382,8 @@ if test "$with_dln_a_out" != yes; then rb_cv_dlopen=yes ;; netbsd*) LDSHARED="ld -Bshareable" rb_cv_dlopen=yes ;; - openbsd*) LDSHARED="ld -Bshareable" + openbsd*) LDSHARED="ld -Bforcearchive -Bshareable" + CCDLFLAGS=-fPIC rb_cv_dlopen=yes ;; nextstep*) LDSHARED='cc -r' LDFLAGS="-u libsys_s" @@ -1262,7 +1262,7 @@ mod_alias_method(mod, newname, oldname) # define TMP_PROTECT NODE * volatile __protect_tmp=0 # define TMP_ALLOC(n) \ (__protect_tmp = node_newnode(NODE_ALLOCA, \ - ALLOCA_N(VALUE,n),__protect_tmp,n),\ + ALLOC_N(VALUE,n),__protect_tmp,n),\ (void*)__protect_tmp->nd_head) #else # define TMP_PROTECT typedef int foobazzz @@ -2316,11 +2316,12 @@ rb_eval(self, node) str = str_new3(node->nd_lit); while (list) { - if (nd_type(list->nd_head) == NODE_STR) { - str2 = list->nd_head->nd_lit; - } - else { - if (nd_type(list->nd_head) == NODE_EVSTR) { + if (list->nd_head) { + switch (nd_type(list->nd_head)) { + case NODE_STR: + str2 = list->nd_head->nd_lit; + break; + case NODE_EVSTR: rb_in_eval++; list->nd_head = compile(list->nd_head->nd_lit,0); eval_tree = 0; @@ -2328,11 +2329,12 @@ rb_eval(self, node) if (nerrs > 0) { compile_error("string expansion"); } + /* fall through */ + default: + str2 = rb_eval(self, list->nd_head); + str2 = obj_as_string(str2); + break; } - str2 = rb_eval(self, list->nd_head); - str2 = obj_as_string(str2); - } - if (str2) { str_cat(str, RSTRING(str2)->ptr, RSTRING(str2)->len); if (str_tainted(str2)) str_taint(str); } diff --git a/ext/tcltklib/extconf.rb b/ext/tcltklib/extconf.rb index 14c8e45ae5..6f6d256604 100644 --- a/ext/tcltklib/extconf.rb +++ b/ext/tcltklib/extconf.rb @@ -13,7 +13,7 @@ def search_header(include, *path) begin for i in path.sort!.reverse! dir = Dir[i] - for path in dir + for path in dir.sort!.reverse! next unless File.directory? path Dir.chdir path files = Dir[include] @@ -52,11 +52,11 @@ $libraries = [] def search_lib(file, func, *path) for i in path.reverse! dir = Dir[i] - for path in dir + for path in dir.sort!.reverse! $LDFLAGS = $libraries.collect{|p| "-L" + p}.join(" ") + " -L" + path files = Dir[path+"/"+file] if files.size > 0 - for lib in files + for lib in files.sort!.reverse! lib = File::basename(lib) lib.sub!(/^lib/, '') lib.sub!(/\.(a|so)$/, '') diff --git a/ext/tcltklib/lib/tcltk.rb b/ext/tcltklib/lib/tcltk.rb index 81d01f930d..54a00e8f3c 100644 --- a/ext/tcltklib/lib/tcltk.rb +++ b/ext/tcltklib/lib/tcltk.rb @@ -1,48 +1,44 @@ # tof -#### tcltk ライブラリ +#### tcltk library, more direct manipulation of tcl/tk #### Sep. 5, 1997 Y. Shigehiro require "tcltklib" ################ -# module TclTk: tcl/tk のライブラリ全体で必要になるものを集めたもの -# (主に, 名前空間の点から module にする使う.) +# module TclTk: collection of tcl/tk utilities (supplies namespace.) module TclTk - # 単にここに書けば最初に 1 度実行されるのか?? - - # 生成した一意な名前を保持しておく連想配列を初期化する. + # initialize Hash to hold unique symbols and such @namecnt = {} - # コールバックを保持しておく連想配列を初期化する. + # initialize Hash to hold callbacks @callback = {} end -# TclTk.mainloop(): TclTkLib.mainloop() を呼ぶ. +# TclTk.mainloop(): call TclTkLib.mainloop() def TclTk.mainloop() print("mainloop: start\n") if $DEBUG TclTkLib.mainloop() print("mainloop: end\n") if $DEBUG end -# TclTk.deletecallbackkey(ca): コールバックを TclTk module から取り除く. -# tcl/tk インタプリタにおいてコールバックが取り消されるわけではない. -# これをしないと, 最後に TclTkInterpreter が GC できない. -# (GC したくなければ, 別に, これをしなくても良い.) -# ca: コールバック(TclTkCallback) +# TclTk.deletecallbackkey(ca): remove callback from TclTk module +# this does not remove callbacks from tcl/tk interpreter +# without calling this method, TclTkInterpreter will not be GCed +# ca: callback(TclTkCallback) def TclTk.deletecallbackkey(ca) print("deletecallbackkey: ", ca.to_s(), "\n") if $DEBUG @callback.delete(ca.to_s) end -# TclTk.dcb(ca, wid, W): 配列に入っている複数のコールバックに対して -# TclTk.deletecallbackkey() を呼ぶ. -# トップレベルの <Destroy> イベントのコールバックとして呼ぶためのもの. -# ca: コールバック(TclTkCallback) の Array -# wid: トップレベルのウィジェット(TclTkWidget) -# w: コールバックに %W で与えられる, ウインドウに関するパラメータ(String) +# TclTk.dcb(ca, wid, W): call TclTk.deletecallbackkey() for each callbacks +# in an array. +# this is for callback for top-level <Destroy> +# ca: array of callbacks(TclTkCallback) +# wid: top-level widget(TclTkWidget) +# w: information about window given by %W(String) def TclTk.dcb(ca, wid, w) if wid.to_s() == w ca.each{|i| @@ -51,33 +47,33 @@ def TclTk.dcb(ca, wid, w) end end -# TclTk._addcallback(ca): コールバックを登録する. -# ca: コールバック(TclTkCallback) +# TclTk._addcallback(ca): register callback +# ca: callback(TclTkCallback) def TclTk._addcallback(ca) print("_addcallback: ", ca.to_s(), "\n") if $DEBUG @callback[ca.to_s()] = ca end -# TclTk._callcallback(key, arg): 登録したコールバックを呼び出す. -# key: コールバックを選択するキー (TclTkCallback が to_s() で返す値) -# arg: tcl/tk インタプリタからのパラメータ +# TclTk._callcallback(key, arg): invoke registered callback +# key: key to select callback (to_s value of the TclTkCallback) +# arg: parameter from tcl/tk interpreter def TclTk._callcallback(key, arg) print("_callcallback: ", @callback[key].inspect, "\n") if $DEBUG @callback[key]._call(arg) - # コールバックからの返り値はどうせ捨てられる. - # String を返さないと, rb_eval_string() がエラーになる. + # throw out callback value + # should return String to satisfy rb_eval_string() return "" end -# TclTk._newname(prefix): 一意な名前(String)を生成して返す. -# prefix: 名前の接頭語 +# TclTk._newname(prefix): generate unique name(String) +# prefix: prefix of the unique name def TclTk._newname(prefix) - # 生成した名前のカウンタは @namecnt に入っているので, 調べる. + # generated name counter is stored in @namecnt if !@namecnt.key?(prefix) - # 初めて使う接頭語なので初期化する. + # first appearing prefix, initialize @namecnt[prefix] = 1 else - # 使ったことのある接頭語なので, 次の名前にする. + # already appeared prefix, generate next name @namecnt[prefix] += 1 end return "#{prefix}#{@namecnt[prefix]}" @@ -85,51 +81,48 @@ end ################ -# class TclTkInterpreter: tcl/tk のインタプリタ +# class TclTkInterpreter: tcl/tk interpreter class TclTkInterpreter - # initialize(): 初期化. + # initialize(): def initialize() - # インタプリタを生成する. + # generate interpreter object @ip = TclTkIp.new() - # インタプリタに ruby_fmt コマンドを追加する. - # ruby_fmt コマンドとは, 後ろの引数を format コマンドで処理して - # ruby コマンドに渡すものである. - # (なお, ruby コマンドは, 引数を 1 つしかとれない.) + # add ruby_fmt command to tcl interpreter + # ruby_fmt command format arguments by `format' and call `ruby' command + # (notice ruby command receives only one argument) if $DEBUG @ip._eval("proc ruby_fmt {fmt args} { puts \"ruby_fmt: $fmt $args\" ; ruby [format $fmt $args] }") else @ip._eval("proc ruby_fmt {fmt args} { ruby [format $fmt $args] }") end - # @ip._get_eval_string(*args): tcl/tk インタプリタで評価する - # 文字列(String)を生成して返す. - # *args: tcl/tk で評価するスクリプト(に対応するオブジェクト列) + # @ip._get_eval_string(*args): generate string to evaluate in tcl interpreter + # *args: script which is going to be evaluated under tcl/tk def @ip._get_eval_string(*args) argstr = "" args.each{|arg| argstr += " " if argstr != "" - # もし to_eval() メソッドが + # call to_eval if it is defined if (arg.respond_to?(:to_eval)) - # 定義されていればそれを呼ぶ. argstr += arg.to_eval() else - # 定義されていなければ to_s() を呼ぶ. + # call to_s unless defined argstr += arg.to_s() end } return argstr end - # @ip._eval_args(*args): tcl/tk インタプリタで評価し, - # その結果(String)を返す. - # *args: tcl/tk で評価するスクリプト(に対応するオブジェクト列) + # @ip._eval_args(*args): evaluate string under tcl/tk interpreter + # returns result string. + # *args: script which is going to be evaluated under tcl/tk def @ip._eval_args(*args) - # インタプリタで評価する文字列を求める. + # calculate the string to eval in the interpreter argstr = _get_eval_string(*args) - # インタプリタで評価する. + # evaluate under the interpreter print("_eval: \"", argstr, "\"") if $DEBUG res = _eval(argstr) if $DEBUG @@ -137,219 +130,205 @@ class TclTkInterpreter elsif _return_value() != 0 print(res, "\n") end - fail(%Q/can't eval "#{argstr}"/) if _return_value() != 0 + fail(%Q/can't eval "#{argstr}"/) if _return_value() != 0 #' return res end - # tcl/tk のコマンドに対応するオブジェクトを生成し, 連想配列に入れておく. + # generate tcl/tk command object and register in the hash @commands = {} - # tcl/tk インタプリタに登録されているすべてのコマンドに対して, + # for all commands registered in tcl/tk interpreter: @ip._eval("info command").split(/ /).each{|comname| if comname =~ /^[.]/ - # コマンドがウィジェット(のパス名)の場合は - # TclTkWidget のインスタンスを作って連想配列に入れる. + # if command is a widget (path), generate TclTkWidget, + # and register it in the hash @commands[comname] = TclTkWidget.new(@ip, comname) else - # そうでない場合は - # TclTkCommand のインスタンスを作って連想配列に入れる. + # otherwise, generate TclTkCommand @commands[comname] = TclTkCommand.new(@ip, comname) end } end - # commands(): tcl/tk のコマンドに対応するオブジェクトを Hash に - # 入れたものを返す. + # commands(): returns hash of the tcl/tk commands def commands() return @commands end - # rootwidget(): ルートウィジェット(TclTkWidget)を返す. + # rootwidget(): returns root widget(TclTkWidget) def rootwidget() return @commands["."] end - # _tcltkip(): @ip(TclTkIp) を返す. + # _tcltkip(): returns @ip(TclTkIp) def _tcltkip() return @ip end - # method_missing(id, *args): 未定義のメソッドは tcl/tk のコマンドとみなして - # 実行し, その結果(String)を返す. - # id: メソッドのシンボル - # *args: コマンドの引数 + # method_missing(id, *args): execute undefined method as tcl/tk command + # id: method symbol + # *args: method arguments def method_missing(id, *args) - # もし, メソッドの tcl/tk コマンドが + # if command named by id registered, then execute it if @commands.key?(id.id2name) - # あれば, 実行して結果を返す. return @commands[id.id2name].e(*args) else - # 無ければもともとの処理. + # otherwise, exception super end end end -# class TclTkObject: tcl/tk のオブジェクト -# (基底クラスとして使う. -# tcltk ライブラリを使う人が TclTkObject.new() することはないはず.) +# class TclTkObject: base class of the tcl/tk objects class TclTkObject - # initialize(ip, exp): 初期化. - # ip: インタプリタ(TclTkIp) - # exp: tcl/tk での表現形 + # initialize(ip, exp): + # ip: interpreter(TclTkIp) + # exp: tcl/tk representation def initialize(ip, exp) fail("type is not TclTkIp") if !ip.kind_of?(TclTkIp) @ip = ip @exp = exp end - # to_s(): tcl/tk での表現形(String)を返す. + # to_s(): returns tcl/tk representation def to_s() return @exp end end -# class TclTkCommand: tcl/tk のコマンド -# (tcltk ライブラリを使う人が TclTkCommand.new() することはないはず. -# TclTkInterpreter:initialize() から new() される.) +# class TclTkCommand: tcl/tk commands +# you should not call TclTkCommand.new() +# commands are created by TclTkInterpreter:initialize() class TclTkCommand < TclTkObject - # e(*args): コマンドを実行し, その結果(String)を返す. - # (e は exec または eval の e.) - # *args: コマンドの引数 + # e(*args): execute command. returns String (e is for exec or eval) + # *args: command arguments def e(*args) return @ip._eval_args(to_s(), *args) end end -# class TclTkLibCommand: tcl/tk のコマンド -# (ライブラリにより実現されるコマンドで, tcl/tk インタプリタに最初から -# 存在しないものは, インタプリタの commands() では生成できない. -# そのようなものに対し, コマンドの名前から TclTkCommand オブジェクトを -# 生成する. +# class TclTkLibCommand: tcl/tk commands in the library class TclTkLibCommand < TclTkCommand - # initialize(ip, name): 初期化 - # ip: インタプリタ(TclTkInterpreter) - # name: コマンド名 (String) + # initialize(ip, name): + # ip: interpreter(TclTkInterpreter) + # name: command name (String) def initialize(ip, name) super(ip._tcltkip, name) end end -# class TclTkVariable: tcl/tk の変数 +# class TclTkVariable: tcl/tk variable class TclTkVariable < TclTkObject - # initialize(interp, dat): 初期化. - # interp: インタプリタ(TclTkInterpreter) - # dat: 設定する値(String) - # nil なら, 設定しない. + # initialize(interp, dat): + # interp: interpreter(TclTkInterpreter) + # dat: the value to set(String) + # if nil, not initialize variable def initialize(interp, dat) - # tcl/tk での表現形(変数名)を自動生成する. + # auto-generate tcl/tk representation (variable name) exp = TclTk._newname("v_") - # TclTkObject を初期化する. + # initialize TclTkObject super(interp._tcltkip(), exp) - # set コマンドを使うのでとっておく. + # safe this for `set' command @set = interp.commands()["set"] - # 値を設定する. + # set value set(dat) if dat end - # tcl/tk の set を使えば, 値の設定/参照はできるが, - # それだけではなんなので, 一応, メソッドをかぶせたものも用意しておく. + # although you can set/refer variable by using set in tcl/tk, + # we provide the method for accessing variables - # set(data): tcl/tk の変数に set を用いて値を設定する. - # data: 設定する値 + # set(data): set tcl/tk variable using `set' + # data: new value def set(data) @set.e(to_s(), data.to_s()) end - # get(): tcl/tk の変数の値(String)を set を用いて読みだし返す. + # get(): read tcl/tk variable(String) using `set' def get() return @set.e(to_s()) end end -# class TclTkWidget: tcl/tk のウィジェット +# class TclTkWidget: tcl/tk widget class TclTkWidget < TclTkCommand - # initialize(*args): 初期化. - # *args: パラメータ + # initialize(*args): + # *args: parameters def initialize(*args) if args[0].kind_of?(TclTkIp) - # 最初の引数が TclTkIp の場合: + # in case the 1st argument is TclTkIp: - # 既に tcl/tk に定義されているウィジェットに TclTkWidget の構造を - # かぶせる. (TclTkInterpreter:initialize() から使われる.) + # Wrap tcl/tk widget by TclTkWidget + # (used in TclTkInterpreter#initialize()) - # パラメータ数が 2 でなければエラー. + # need two arguments fail("illegal # of parameter") if args.size != 2 - # ip: インタプリタ(TclTkIp) - # exp: tcl/tk での表現形 + # ip: interpreter(TclTkIp) + # exp: tcl/tk representation ip, exp = args - # TclTkObject を初期化する. + # initialize TclTkObject super(ip, exp) elsif args[0].kind_of?(TclTkInterpreter) - # 最初の引数が TclTkInterpreter の場合: + # in case 1st parameter is TclTkInterpreter: - # 親ウィジェットから新たなウィジェトを生成する. + # generate new widget from parent widget - # interp: インタプリタ(TclTkInterpreter) - # parent: 親ウィジェット - # command: ウィジェットを生成するコマンド(label 等) - # *args: command に渡す引数 + # interp: interpreter(TclTkInterpreter) + # parent: parent widget + # command: widget generating tk command(label 等) + # *args: argument to the command interp, parent, command, *args = args - # ウィジェットの名前を作る. + # generate widget name exp = parent.to_s() exp += "." if exp !~ /[.]$/ exp += TclTk._newname("w_") - # TclTkObject を初期化する. + # initialize TclTkObject super(interp._tcltkip(), exp) - # ウィジェットを生成する. + # generate widget res = @ip._eval_args(command, exp, *args) # fail("can't create Widget") if res != exp - # tk_optionMenu では, ボタン名を exp で指定すると - # res にメニュー名を返すので res != exp となる. + # for tk_optionMenu, it is legal res != exp else fail("first parameter is not TclTkInterpreter") end end end -# class TclTkCallback: tcl/tk のコールバック +# class TclTkCallback: tcl/tk callbacks class TclTkCallback < TclTkObject - # initialize(interp, pr, arg): 初期化. - # interp: インタプリタ(TclTkInterpreter) - # pr: コールバック手続き(Proc) - # arg: pr のイテレータ変数に渡す文字列 - # tcl/tk の bind コマンドではパラメータを受け取るために % 置換を - # 用いるが, pr の内部で % を書いてもうまくいかない. - # arg に文字列を書いておくと, その置換結果を, pr で - # イテレータ変数を通して受け取ることができる. - # scrollbar コマンドの -command オプションのように - # 何も指定しなくてもパラメータが付くコマンドに対しては, - # arg を指定してはならない. + # initialize(interp, pr, arg): + # interp: interpreter(TclTkInterpreter) + # pr: callback procedure(Proc) + # arg: string to pass as block parameters of pr + # bind command of tcl/tk uses % replacement for parameters + # pr can receive replaced data using block parameter + # its format is specified by arg string + # You should not specify arg for the command like + # scrollbar with -command option, which receives parameters + # without specifying any replacement def initialize(interp, pr, arg = nil) - # tcl/tk での表現形(変数名)を自動生成する. + # auto-generate tcl/tk representation (variable name) exp = TclTk._newname("c_") - # TclTkObject を初期化する. + # initialize TclTkObject super(interp._tcltkip(), exp) - # パラメータをとっておく. + # save parameters @pr = pr @arg = arg - # モジュールに登録しておく. + # register in the module TclTk._addcallback(self) end - # to_eval(): @ip._eval_args で評価するときの表現形(String)を返す. + # to_eval(): retuens string representation for @ip._eval_args def to_eval() if @arg - # %s は ruby_fmt より前に bind により置換されてしまうので - # %%s としてある. したがって, これは bind 専用. + # bind replaces %s before calling ruby_fmt, so %%s is used s = %Q/{ruby_fmt {TclTk._callcallback("#{to_s()}", "%%s")} #{@arg}}/ else s = %Q/{ruby_fmt {TclTk._callcallback("#{to_s()}", "%s")}}/ @@ -358,28 +337,28 @@ class TclTkCallback < TclTkObject return s end - # _call(arg): コールバックを呼び出す. - # arg: コールバックに渡されるパラメータ + # _call(arg): invoke callback + # arg: callback parameter def _call(arg) @pr.call(arg) end end -# class TclTkImage: tcl/tk のイメージ +# class TclTkImage: tcl/tk images class TclTkImage < TclTkCommand - # initialize(interp, t, *args): 初期化. - # イメージの生成は TclTkImage.new() で行うが, - # 破壊は image delete で行う. (いまいちだけど仕方が無い.) - # interp: インタプリタ(TclTkInterpreter) - # t: イメージのタイプ (photo, bitmap, etc.) - # *args: コマンドの引数 + # initialize(interp, t, *args): + # generating image is done by TclTkImage.new() + # destrying is done by image delete (inconsistent, sigh) + # interp: interpreter(TclTkInterpreter) + # t: image type (photo, bitmap, etc.) + # *args: command argument def initialize(interp, t, *args) - # tcl/tk での表現形(変数名)を自動生成する. + # auto-generate tcl/tk representation exp = TclTk._newname("i_") - # TclTkObject を初期化する. + # initialize TclTkObject super(interp._tcltkip(), exp) - # イメージを生成する. + # generate image res = @ip._eval_args("image create", t, exp, *args) fail("can't create Image") if res != exp end @@ -592,10 +592,10 @@ gc_sweep() { RVALUE *p, *pend; int freed = 0; - int i; + int i, used = heaps_used; if (rb_in_compile) { - for (i = 0; i < heaps_used; i++) { + for (i = 0; i < used; i++) { p = heaps[i]; pend = p + HEAP_SLOTS; while (p < pend) { if (!(p->as.basic.flags&FL_MARK) && BUILTIN_TYPE(p) == T_NODE) @@ -606,19 +606,17 @@ gc_sweep() } freelist = 0; - for (i = 0; i < heaps_used; i++) { - RVALUE *nfreelist; + for (i = 0; i < used; i++) { int n = 0; - nfreelist = freelist; p = heaps[i]; pend = p + HEAP_SLOTS; while (p < pend) { if (!(p->as.basic.flags & FL_MARK)) { if (p->as.basic.flags) obj_free((VALUE)p); p->as.free.flag = 0; - p->as.free.next = nfreelist; - nfreelist = p; + p->as.free.next = freelist; + freelist = p; n++; } else @@ -626,7 +624,6 @@ gc_sweep() p++; } freed += n; - freelist = nfreelist; } alloc_objects = 0; if (freed < FREE_MIN) { @@ -725,8 +722,17 @@ obj_free(obj) if (RANY(obj)->as.bignum.digits) free(RANY(obj)->as.bignum.digits); break; case T_NODE: - if (nd_type(obj) == NODE_SCOPE && RANY(obj)->as.node.u1.tbl) { - free(RANY(obj)->as.node.u1.tbl); + switch (nd_type(obj)) { + case NODE_SCOPE: + if (RANY(obj)->as.node.u1.tbl) { + free(RANY(obj)->as.node.u1.tbl); + } + break; +#ifdef C_ALLOCA + case NODE_ALLOCA: + free(RANY(obj)->as.node.u1.value); + break; +#endif } return; /* no need to free iv_tbl */ diff --git a/missing/nt.c b/missing/nt.c index 029dd31d16..41d84a5da7 100644 --- a/missing/nt.c +++ b/missing/nt.c @@ -279,13 +279,15 @@ static char *szInternalCmds[] = { "type", "ver", "vol", + NULL }; int isInternalCmd(char *cmd) { - int i, fRet; + int i, fRet=0; char **vec; + NtMakeCmdVector(cmd, &vec, FALSE); for( i = 0; szInternalCmds[i] ; i++){ if(!strcmp(szInternalCmds[i], vec[0])){ fRet = 1; @@ -144,9 +144,8 @@ static int group_match_null_string_p (); /* This must be nonzero for the wordchar and notwordchar pattern commands in re_match. */ -#ifndef Sword -#define Sword 1 -#endif +#define Sword 1 +#define Sword2 2 #define SYNTAX(c) re_syntax_table[c] @@ -171,23 +170,14 @@ init_syntax_once() memset(re_syntax_table, 0, sizeof re_syntax_table); - for (c = 'a'; c <= 'z'; c++) - re_syntax_table[c] = Sword; - - for (c = 'A'; c <= 'Z'; c++) - re_syntax_table[c] = Sword; - - for (c = '0'; c <= '9'; c++) - re_syntax_table[c] = Sword; - + for (c=0; c<0x7f; c++) + if (isalnum(c)) + re_syntax_table[c] = Sword; re_syntax_table['_'] = Sword; - /* Add specific syntax for ISO Latin-1. */ - for (c = 0300; c <= 0377; c++) - re_syntax_table[c] = Sword; - re_syntax_table[0327] = 0; - re_syntax_table[0367] = 0; - + for (c=0x80; c<=0xff; c++) + if (isalnum(c)) + re_syntax_table[c] = Sword2; done = 1; } @@ -1274,16 +1264,20 @@ re_compile_pattern(pattern, size, bufp) PATFETCH(c); switch (c) { case 'w': - for (c = 0; c < (1 << BYTEWIDTH); c++) - if (SYNTAX(c) == Sword) - SET_LIST_BIT(c); + for (c = 0; c < (1 << BYTEWIDTH); c++) { + if (SYNTAX(c) == Sword || + (!current_mbctype && SYNTAX(c) == Sword2)) + SET_LIST_BIT(c); + } last = -1; continue; case 'W': - for (c = 0; c < (1 << BYTEWIDTH); c++) - if (SYNTAX(c) != Sword) - SET_LIST_BIT(c); + for (c = 0; c < (1 << BYTEWIDTH); c++) { + if (SYNTAX(c) != Sword && + (current_mbctype || SYNTAX(c) != Sword2)) + SET_LIST_BIT(c); + } if (current_mbctype) { set_list_bits(0x8000, 0xffff, (unsigned char*)b); } @@ -2559,17 +2553,46 @@ re_compile_fastmap(bufp) break; case wordchar: - for (j = 0; j < (1 << BYTEWIDTH); j++) + for (j = 0; j < 0x80; j++) { if (SYNTAX(j) == Sword) fastmap[j] = 1; + } + switch (current_mbctype) { + case MBCTYPE_ASCII: + for (j = 0x80; j < (1 << BYTEWIDTH); j++) { + if (SYNTAX(j) == Sword2) + fastmap[j] = 1; + } + break; + case MBCTYPE_EUC: + case MBCTYPE_SJIS: + for (j = 0x80; j < (1 << BYTEWIDTH); j++) { + if (mbctab[j]) + fastmap[j] = 1; + } + break; + } break; case notwordchar: for (j = 0; j < 0x80; j++) if (SYNTAX(j) != Sword) fastmap[j] = 1; - for (j = 0x80; j < (1 << BYTEWIDTH); j++) - fastmap[j] = 1; + switch (current_mbctype) { + case MBCTYPE_ASCII: + for (j = 0x80; j < (1 << BYTEWIDTH); j++) { + if (SYNTAX(j) != Sword2) + fastmap[j] = 1; + } + break; + case MBCTYPE_EUC: + case MBCTYPE_SJIS: + for (j = 0x80; j < (1 << BYTEWIDTH); j++) { + if (!mbctab[j]) + fastmap[j] = 1; + } + break; + } break; case charset: @@ -3050,7 +3073,10 @@ typedef union 2) if we're before the beginning of string2, we have to look at the last character in string1; we assume there is a string1, so use this in conjunction with AT_STRINGS_BEG. */ -#define IS_A_LETTER(d) (SYNTAX(*(d)) == Sword) +#define IS_A_LETTER(d) (SYNTAX(*(d)) == Sword || \ + (current_mbctype ? \ + mbctab[*(d)] == 1 : \ + SYNTAX(*(d)) == Sword2)) static void init_regs(regs, num_regs) @@ -41,7 +41,10 @@ void *xcalloc(); void *xrealloc(); static void rehash(); +#ifndef max #define max(a,b) ((a) > (b) ? (a) : (b)) +#endif + #define alloc(type) (type*)xmalloc((unsigned)sizeof(type)) #define Calloc(n,s) (char*)xcalloc((n),(s)) @@ -648,7 +648,7 @@ typedef struct { char *LL, *RR; } stack_node; /* Stack structure for L,l,R,r */ ((*cmp)(b,c)<0 ? b : ((*cmp)(a,c)<0 ? c : a)) : \ ((*cmp)(b,c)>0 ? b : ((*cmp)(a,c)<0 ? a : c)) ) -void qsort (base, nel, size, cmp) void* base; size_t nel; size_t size; int (*cmp)(); +void rb_qsort (base, nel, size, cmp) void* base; size_t nel; size_t size; int (*cmp)(); { register char *l, *r, *m; /* l,r:left,right group m:median point */ register int t, eq_l, eq_r; /* eq_l: all items in left group are equal to S */ @@ -1,2 +1,2 @@ -#define RUBY_VERSION "1.2" -#define VERSION_DATE "98/12/25" +#define RUBY_VERSION "1.2.1" +#define VERSION_DATE "99/01/11" |