diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-06-13 09:51:02 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-06-13 09:51:02 +0000 |
commit | 1b47fa1097c709be518a5071a7ec0e5271d45a00 (patch) | |
tree | 62f7220ccb1211efc9e1bc9b69c28448173c03bf | |
parent | 1c940e6cdd3e59430d57a42a9d5989bc5ad85270 (diff) |
2000-06-13
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_4@751 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | config.guess | 4 | ||||
-rw-r--r-- | config.sub | 2 | ||||
-rw-r--r-- | configure | 477 | ||||
-rw-r--r-- | configure.in | 16 | ||||
-rw-r--r-- | ext/extmk.rb.in | 2 | ||||
-rw-r--r-- | ext/tk/lib/tk.rb | 207 | ||||
-rw-r--r-- | ext/tk/lib/tkcanvas.rb | 107 | ||||
-rw-r--r-- | ext/tk/lib/tkentry.rb | 8 | ||||
-rw-r--r-- | ext/tk/lib/tkfont.rb | 14 | ||||
-rw-r--r-- | io.c | 10 | ||||
-rw-r--r-- | lib/jcode.rb | 16 | ||||
-rw-r--r-- | lib/pstore.rb | 4 | ||||
-rw-r--r-- | misc/ruby-mode.el | 125 | ||||
-rw-r--r-- | re.c | 22 | ||||
-rw-r--r-- | rubytest.rb | 6 | ||||
-rw-r--r-- | time.c | 57 | ||||
-rw-r--r-- | version.h | 4 |
18 files changed, 729 insertions, 356 deletions
@@ -1,3 +1,7 @@ +Fri Jun 9 15:11:35 2000 Yukihiro Matsumoto <matz@netlab.co.jp> + + * time.c (make_time_t): supports daylight saving time. + Fri Jun 9 01:05:55 2000 WATANABE Hirofumi <eban@os.rim.or.jp> * regex.h: export re_mbctab properly on cygwin. diff --git a/config.guess b/config.guess index 20ad33d44f..53ebbce1a9 100644 --- a/config.guess +++ b/config.guess @@ -969,10 +969,6 @@ EOF *:Rhapsody:*:*) echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} exit 0 ;; - *:"Mac OS":*:*) - echo `uname -p`-apple-macos${UNAME_RELEASE} - exit 0 ;; - esac #echo '(No uname command or uname output not recognized.)' 1>&2 diff --git a/config.sub b/config.sub index 1c351e17c2..3c591de61b 100644 --- a/config.sub +++ b/config.sub @@ -910,7 +910,7 @@ case $os in | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ | -mingw32* | -linux* | -uxpv* | -beos* | -mpeix* | -udk* \ - | -interix* | -uwin* | -rhapsody* | -openstep* | -macos | -oskit*) + | -interix* | -uwin* | -rhapsody* | -openstep* | -oskit*) # Remember, each alternative MUST END IN *, to match a version number. ;; -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ @@ -633,12 +633,6 @@ echo "configure:628: checking target architecture" >&5 TARGET_ARCHS="ppc i386" fi ;; - macos*) - echo -n "MacOS X : " - if test "$TARGET_ARCHS" = "" ; then - TARGET_ARCHS="ppc i386" - fi - ;; nextstep*|openstep*) echo -n "NeXTSTEP/OPENSTEP: " if test "$TARGET_ARCHS" = "" ; then @@ -686,7 +680,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:690: checking for $ac_word" >&5 +echo "configure:684: 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 @@ -716,7 +710,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:720: checking for $ac_word" >&5 +echo "configure:714: 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 @@ -767,7 +761,7 @@ fi # Extract the first word of "cl", so it can be a program name with args. set dummy cl; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:771: checking for $ac_word" >&5 +echo "configure:765: 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 @@ -799,7 +793,7 @@ fi fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 -echo "configure:803: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 +echo "configure:797: 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. @@ -810,12 +804,12 @@ cross_compiling=$ac_cv_prog_cc_cross cat > conftest.$ac_ext << EOF -#line 814 "configure" +#line 808 "configure" #include "confdefs.h" main(){return(0);} EOF -if { (eval echo configure:819: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:813: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; 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 @@ -841,12 +835,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:845: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 +echo "configure:839: 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:850: checking whether we are using GNU C" >&5 +echo "configure:844: 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 @@ -855,7 +849,7 @@ else yes; #endif EOF -if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:859: \"$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:853: \"$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 @@ -874,7 +868,7 @@ ac_test_CFLAGS="${CFLAGS+set}" ac_save_CFLAGS="$CFLAGS" CFLAGS= echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 -echo "configure:878: checking whether ${CC-cc} accepts -g" >&5 +echo "configure:872: 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 @@ -906,7 +900,7 @@ else fi echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 -echo "configure:910: checking how to run the C preprocessor" >&5 +echo "configure:904: checking how to run the C preprocessor" >&5 # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= @@ -921,13 +915,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 925 "configure" +#line 919 "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:931: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:925: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -938,13 +932,13 @@ else rm -rf conftest* CPP="${CC-cc} -E -traditional-cpp" cat > conftest.$ac_ext <<EOF -#line 942 "configure" +#line 936 "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:948: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:942: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -955,13 +949,13 @@ else rm -rf conftest* CPP="${CC-cc} -nologo -E" cat > conftest.$ac_ext <<EOF -#line 959 "configure" +#line 953 "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:965: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:959: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -987,13 +981,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:991: checking whether ${CC-cc} needs -traditional" >&5 +echo "configure:985: 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 997 "configure" +#line 991 "configure" #include "confdefs.h" #include <sgtty.h> Autoconf TIOCGETP @@ -1011,7 +1005,7 @@ rm -f conftest* if test $ac_cv_prog_gcc_traditional = no; then cat > conftest.$ac_ext <<EOF -#line 1015 "configure" +#line 1009 "configure" #include "confdefs.h" #include <termio.h> Autoconf TCGETA @@ -1037,7 +1031,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:1041: checking for $ac_word" >&5 +echo "configure:1035: 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 @@ -1070,7 +1064,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:1074: checking for $ac_word" >&5 +echo "configure:1068: 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 @@ -1103,7 +1097,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:1107: checking for $ac_word" >&5 +echo "configure:1101: 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 @@ -1135,7 +1129,7 @@ test -n "$AR" || AR="ar" echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6 -echo "configure:1139: checking whether ln -s works" >&5 +echo "configure:1133: checking whether ln -s works" >&5 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1156,7 +1150,7 @@ else fi echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 -echo "configure:1160: checking whether ${MAKE-make} sets \${MAKE}" >&5 +echo "configure:1154: 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 @@ -1186,17 +1180,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:1190: checking for minix/config.h" >&5 +echo "configure:1184: 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 1195 "configure" +#line 1189 "configure" #include "confdefs.h" #include <minix/config.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1200: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1194: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -1235,12 +1229,12 @@ fi echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6 -echo "configure:1239: checking for Cygwin environment" >&5 +echo "configure:1233: checking for Cygwin environment" >&5 if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1244 "configure" +#line 1238 "configure" #include "confdefs.h" int main() { @@ -1251,7 +1245,7 @@ int main() { return __CYGWIN__; ; return 0; } EOF -if { (eval echo configure:1255: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1249: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_cygwin=yes else @@ -1268,19 +1262,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6 CYGWIN= test "$ac_cv_cygwin" = yes && CYGWIN=yes echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6 -echo "configure:1272: checking for mingw32 environment" >&5 +echo "configure:1266: checking for mingw32 environment" >&5 if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1277 "configure" +#line 1271 "configure" #include "confdefs.h" int main() { return __MINGW32__; ; return 0; } EOF -if { (eval echo configure:1284: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1278: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_mingw32=yes else @@ -1299,7 +1293,7 @@ test "$ac_cv_mingw32" = yes && MINGW32=yes echo $ac_n "checking for executable suffix""... $ac_c" 1>&6 -echo "configure:1303: checking for executable suffix" >&5 +echo "configure:1297: checking for executable suffix" >&5 if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1309,7 +1303,7 @@ else rm -f conftest* echo 'int main () { return 0; }' > conftest.$ac_ext ac_cv_exeext= - if { (eval echo configure:1313: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then + if { (eval echo configure:1307: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then for file in conftest.*; do case $file in *.c | *.o | *.obj) ;; @@ -1330,13 +1324,13 @@ echo "$ac_t""${ac_cv_exeext}" 1>&6 ac_exeext=$EXEEXT echo $ac_n "checking for object suffix""... $ac_c" 1>&6 -echo "configure:1334: checking for object suffix" >&5 +echo "configure:1328: checking for object suffix" >&5 if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else rm -f conftest* echo 'int i = 1;' > conftest.$ac_ext -if { (eval echo configure:1340: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1334: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then for ac_file in conftest.*; do case $ac_file in *.c) ;; @@ -1355,7 +1349,7 @@ ac_objext=$ac_cv_objext echo $ac_n "checking size of int""... $ac_c" 1>&6 -echo "configure:1359: checking size of int" >&5 +echo "configure:1353: 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 @@ -1363,7 +1357,7 @@ else ac_cv_sizeof_int=4 else cat > conftest.$ac_ext <<EOF -#line 1367 "configure" +#line 1361 "configure" #include "confdefs.h" #include <stdio.h> main() @@ -1374,7 +1368,7 @@ main() exit(0); } EOF -if { (eval echo configure:1378: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:1372: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_sizeof_int=`cat conftestval` else @@ -1394,7 +1388,7 @@ EOF echo $ac_n "checking size of short""... $ac_c" 1>&6 -echo "configure:1398: checking size of short" >&5 +echo "configure:1392: checking size of short" >&5 if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1402,7 +1396,7 @@ else ac_cv_sizeof_short=2 else cat > conftest.$ac_ext <<EOF -#line 1406 "configure" +#line 1400 "configure" #include "confdefs.h" #include <stdio.h> main() @@ -1413,7 +1407,7 @@ main() exit(0); } EOF -if { (eval echo configure:1417: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:1411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_sizeof_short=`cat conftestval` else @@ -1433,7 +1427,7 @@ EOF echo $ac_n "checking size of long""... $ac_c" 1>&6 -echo "configure:1437: checking size of long" >&5 +echo "configure:1431: 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 @@ -1441,7 +1435,7 @@ else ac_cv_sizeof_long=4 else cat > conftest.$ac_ext <<EOF -#line 1445 "configure" +#line 1439 "configure" #include "confdefs.h" #include <stdio.h> main() @@ -1452,7 +1446,7 @@ main() exit(0); } EOF -if { (eval echo configure:1456: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:1450: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_sizeof_long=`cat conftestval` else @@ -1472,7 +1466,7 @@ EOF echo $ac_n "checking size of void*""... $ac_c" 1>&6 -echo "configure:1476: checking size of void*" >&5 +echo "configure:1470: 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 @@ -1480,7 +1474,7 @@ else ac_cv_sizeof_voidp=4 else cat > conftest.$ac_ext <<EOF -#line 1484 "configure" +#line 1478 "configure" #include "confdefs.h" #include <stdio.h> main() @@ -1491,7 +1485,7 @@ main() exit(0); } EOF -if { (eval echo configure:1495: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:1489: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_sizeof_voidp=`cat conftestval` else @@ -1511,7 +1505,7 @@ EOF echo $ac_n "checking size of float""... $ac_c" 1>&6 -echo "configure:1515: checking size of float" >&5 +echo "configure:1509: checking size of float" >&5 if eval "test \"`echo '$''{'ac_cv_sizeof_float'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1519,7 +1513,7 @@ else ac_cv_sizeof_float=4 else cat > conftest.$ac_ext <<EOF -#line 1523 "configure" +#line 1517 "configure" #include "confdefs.h" #include <stdio.h> main() @@ -1530,7 +1524,7 @@ main() exit(0); } EOF -if { (eval echo configure:1534: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:1528: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_sizeof_float=`cat conftestval` else @@ -1550,7 +1544,7 @@ EOF echo $ac_n "checking size of double""... $ac_c" 1>&6 -echo "configure:1554: checking size of double" >&5 +echo "configure:1548: checking size of double" >&5 if eval "test \"`echo '$''{'ac_cv_sizeof_double'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1558,7 +1552,7 @@ else ac_cv_sizeof_double=8 else cat > conftest.$ac_ext <<EOF -#line 1562 "configure" +#line 1556 "configure" #include "confdefs.h" #include <stdio.h> main() @@ -1569,7 +1563,7 @@ main() exit(0); } EOF -if { (eval echo configure:1573: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:1567: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_sizeof_double=`cat conftestval` else @@ -1590,19 +1584,19 @@ EOF echo $ac_n "checking for prototypes""... $ac_c" 1>&6 -echo "configure:1594: checking for prototypes" >&5 +echo "configure:1588: 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 1599 "configure" +#line 1593 "configure" #include "confdefs.h" int foo(int x) { return 0; } int main() { return foo(10); ; return 0; } EOF -if { (eval echo configure:1606: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1600: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_have_prototypes=yes else @@ -1623,19 +1617,19 @@ EOF fi echo $ac_n "checking token paste string""... $ac_c" 1>&6 -echo "configure:1627: checking token paste string" >&5 +echo "configure:1621: checking token paste string" >&5 if eval "test \"`echo '$''{'rb_cv_tokenpaste'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1632 "configure" +#line 1626 "configure" #include "confdefs.h" #define paste(a,b) a##b int main() { int xy = 1; return paste(x,y); ; return 0; } EOF -if { (eval echo configure:1639: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1633: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_tokenpaste=ansi else @@ -1661,12 +1655,12 @@ EOF fi echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6 -echo "configure:1665: checking for variable length prototypes and stdarg.h" >&5 +echo "configure:1659: 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 1670 "configure" +#line 1664 "configure" #include "confdefs.h" #include <stdarg.h> @@ -1683,7 +1677,7 @@ int main() { return foo(10, "", 3.14); ; return 0; } EOF -if { (eval echo configure:1687: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1681: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_stdarg=yes else @@ -1704,19 +1698,19 @@ EOF fi echo $ac_n "checking for gcc attribute noreturn""... $ac_c" 1>&6 -echo "configure:1708: checking for gcc attribute noreturn" >&5 +echo "configure:1702: 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 1713 "configure" +#line 1707 "configure" #include "confdefs.h" void exit(int x) __attribute__ ((noreturn)); int main() { ; return 0; } EOF -if { (eval echo configure:1720: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1714: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_have_attr_noreturn=yes else @@ -1740,7 +1734,6 @@ case "$host_os" in nextstep*) ;; openstep*) ;; rhapsody*) ;; -macos*) ;; human*) ac_cv_func_getpgrp_void=yes;; beos*) ;; cygwin*) ;; @@ -1750,7 +1743,7 @@ os2_emx*) LIBS="-lm $LIBS" *) LIBS="-lm $LIBS";; esac echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6 -echo "configure:1754: checking for crypt in -lcrypt" >&5 +echo "configure:1747: 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 @@ -1758,7 +1751,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lcrypt $LIBS" cat > conftest.$ac_ext <<EOF -#line 1762 "configure" +#line 1755 "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 @@ -1769,7 +1762,7 @@ int main() { crypt() ; return 0; } EOF -if { (eval echo configure:1773: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1766: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -1797,7 +1790,7 @@ else fi echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 -echo "configure:1801: checking for dlopen in -ldl" >&5 +echo "configure:1794: 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 @@ -1805,7 +1798,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ldl $LIBS" cat > conftest.$ac_ext <<EOF -#line 1809 "configure" +#line 1802 "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 @@ -1816,7 +1809,7 @@ int main() { dlopen() ; return 0; } EOF -if { (eval echo configure:1820: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1813: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -1844,7 +1837,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:1848: checking for shl_load in -ldld" >&5 +echo "configure:1841: 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 @@ -1852,7 +1845,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ldld $LIBS" cat > conftest.$ac_ext <<EOF -#line 1856 "configure" +#line 1849 "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 @@ -1863,7 +1856,7 @@ int main() { shl_load() ; return 0; } EOF -if { (eval echo configure:1867: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1860: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -1891,7 +1884,7 @@ else fi # Dynamic linking for HP-UX echo $ac_n "checking for setlocale in -lxpg4""... $ac_c" 1>&6 -echo "configure:1895: checking for setlocale in -lxpg4" >&5 +echo "configure:1888: 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 @@ -1899,7 +1892,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lxpg4 $LIBS" cat > conftest.$ac_ext <<EOF -#line 1903 "configure" +#line 1896 "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 @@ -1910,7 +1903,7 @@ int main() { setlocale() ; return 0; } EOF -if { (eval echo configure:1914: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1907: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -1943,12 +1936,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:1947: checking for $ac_hdr that defines DIR" >&5 +echo "configure:1940: 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 1952 "configure" +#line 1945 "configure" #include "confdefs.h" #include <sys/types.h> #include <$ac_hdr> @@ -1956,7 +1949,7 @@ int main() { DIR *dirp = 0; ; return 0; } EOF -if { (eval echo configure:1960: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1953: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* eval "ac_cv_header_dirent_$ac_safe=yes" else @@ -1981,7 +1974,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:1985: checking for opendir in -ldir" >&5 +echo "configure:1978: 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 @@ -1989,7 +1982,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ldir $LIBS" cat > conftest.$ac_ext <<EOF -#line 1993 "configure" +#line 1986 "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 @@ -2000,7 +1993,7 @@ int main() { opendir() ; return 0; } EOF -if { (eval echo configure:2004: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1997: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -2022,7 +2015,7 @@ fi else echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6 -echo "configure:2026: checking for opendir in -lx" >&5 +echo "configure:2019: 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 @@ -2030,7 +2023,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lx $LIBS" cat > conftest.$ac_ext <<EOF -#line 2034 "configure" +#line 2027 "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 @@ -2041,7 +2034,7 @@ int main() { opendir() ; return 0; } EOF -if { (eval echo configure:2045: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2038: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -2064,12 +2057,12 @@ fi fi echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 -echo "configure:2068: checking for ANSI C header files" >&5 +echo "configure:2061: 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 2073 "configure" +#line 2066 "configure" #include "confdefs.h" #include <stdlib.h> #include <stdarg.h> @@ -2077,7 +2070,7 @@ else #include <float.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2081: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:2074: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -2094,7 +2087,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 2098 "configure" +#line 2091 "configure" #include "confdefs.h" #include <string.h> EOF @@ -2112,7 +2105,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 2116 "configure" +#line 2109 "configure" #include "confdefs.h" #include <stdlib.h> EOF @@ -2133,7 +2126,7 @@ if test "$cross_compiling" = yes; then : else cat > conftest.$ac_ext <<EOF -#line 2137 "configure" +#line 2130 "configure" #include "confdefs.h" #include <ctype.h> #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') @@ -2144,7 +2137,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); exit (0); } EOF -if { (eval echo configure:2148: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2141: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then : else @@ -2168,12 +2161,12 @@ EOF fi echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6 -echo "configure:2172: checking for sys/wait.h that is POSIX.1 compatible" >&5 +echo "configure:2165: checking for sys/wait.h that is POSIX.1 compatible" >&5 if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2177 "configure" +#line 2170 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/wait.h> @@ -2189,7 +2182,7 @@ wait (&s); s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; ; return 0; } EOF -if { (eval echo configure:2193: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2186: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_header_sys_wait_h=yes else @@ -2215,17 +2208,17 @@ for ac_hdr in stdlib.h string.h unistd.h limits.h sys/file.h sys/ioctl.h\ do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:2219: checking for $ac_hdr" >&5 +echo "configure:2212: 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 2224 "configure" +#line 2217 "configure" #include "confdefs.h" #include <$ac_hdr> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2229: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:2222: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -2253,12 +2246,12 @@ done echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6 -echo "configure:2257: checking for uid_t in sys/types.h" >&5 +echo "configure:2250: 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 2262 "configure" +#line 2255 "configure" #include "confdefs.h" #include <sys/types.h> EOF @@ -2287,12 +2280,12 @@ EOF fi echo $ac_n "checking for size_t""... $ac_c" 1>&6 -echo "configure:2291: checking for size_t" >&5 +echo "configure:2284: 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 2296 "configure" +#line 2289 "configure" #include "confdefs.h" #include <sys/types.h> #if STDC_HEADERS @@ -2320,12 +2313,12 @@ EOF fi echo $ac_n "checking for st_blksize in struct stat""... $ac_c" 1>&6 -echo "configure:2324: checking for st_blksize in struct stat" >&5 +echo "configure:2317: 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 2329 "configure" +#line 2322 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/stat.h> @@ -2333,7 +2326,7 @@ int main() { struct stat s; s.st_blksize; ; return 0; } EOF -if { (eval echo configure:2337: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2330: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_st_blksize=yes else @@ -2355,12 +2348,12 @@ fi save_LIBOJBS="$LIBOBJS" echo $ac_n "checking for st_blocks in struct stat""... $ac_c" 1>&6 -echo "configure:2359: checking for st_blocks in struct stat" >&5 +echo "configure:2352: 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 2364 "configure" +#line 2357 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/stat.h> @@ -2368,7 +2361,7 @@ int main() { struct stat s; s.st_blocks; ; return 0; } EOF -if { (eval echo configure:2372: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2365: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_st_blocks=yes else @@ -2392,12 +2385,12 @@ fi LIBOBJS="$save_LIBOBJS" echo $ac_n "checking for st_rdev in struct stat""... $ac_c" 1>&6 -echo "configure:2396: checking for st_rdev in struct stat" >&5 +echo "configure:2389: 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 2401 "configure" +#line 2394 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/stat.h> @@ -2405,7 +2398,7 @@ int main() { struct stat s; s.st_rdev; ; return 0; } EOF -if { (eval echo configure:2409: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2402: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_st_rdev=yes else @@ -2427,7 +2420,7 @@ fi echo $ac_n "checking type of array argument to getgroups""... $ac_c" 1>&6 -echo "configure:2431: checking type of array argument to getgroups" >&5 +echo "configure:2424: 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 @@ -2435,7 +2428,7 @@ else ac_cv_type_getgroups=cross else cat > conftest.$ac_ext <<EOF -#line 2439 "configure" +#line 2432 "configure" #include "confdefs.h" /* Thanks to Mike Rendell for this test. */ @@ -2460,7 +2453,7 @@ main() } EOF -if { (eval echo configure:2464: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2457: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_type_getgroups=gid_t else @@ -2474,7 +2467,7 @@ fi if test $ac_cv_type_getgroups = cross; then cat > conftest.$ac_ext <<EOF -#line 2478 "configure" +#line 2471 "configure" #include "confdefs.h" #include <unistd.h> EOF @@ -2498,12 +2491,12 @@ EOF echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 -echo "configure:2502: checking return type of signal handlers" >&5 +echo "configure:2495: 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 2507 "configure" +#line 2500 "configure" #include "confdefs.h" #include <sys/types.h> #include <signal.h> @@ -2520,7 +2513,7 @@ int main() { int i; ; return 0; } EOF -if { (eval echo configure:2524: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2517: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_type_signal=void else @@ -2541,19 +2534,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:2545: checking for working alloca.h" >&5 +echo "configure:2538: 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 2550 "configure" +#line 2543 "configure" #include "confdefs.h" #include <alloca.h> int main() { void *p = alloca(2 * sizeof(int)); ; return 0; } EOF -if { (eval echo configure:2557: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2550: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_cv_header_alloca_h=yes else @@ -2574,12 +2567,12 @@ EOF fi echo $ac_n "checking for alloca""... $ac_c" 1>&6 -echo "configure:2578: checking for alloca" >&5 +echo "configure:2571: 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 2583 "configure" +#line 2576 "configure" #include "confdefs.h" #ifdef __GNUC__ @@ -2607,7 +2600,7 @@ int main() { char *p = (char *) alloca(1); ; return 0; } EOF -if { (eval echo configure:2611: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2604: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_cv_func_alloca_works=yes else @@ -2639,12 +2632,12 @@ EOF echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 -echo "configure:2643: checking whether alloca needs Cray hooks" >&5 +echo "configure:2636: 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 2648 "configure" +#line 2641 "configure" #include "confdefs.h" #if defined(CRAY) && ! defined(CRAY2) webecray @@ -2669,12 +2662,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:2673: checking for $ac_func" >&5 +echo "configure:2666: 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 2678 "configure" +#line 2671 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -2697,7 +2690,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:2701: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2694: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -2724,7 +2717,7 @@ done fi echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 -echo "configure:2728: checking stack direction for C alloca" >&5 +echo "configure:2721: 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 @@ -2732,7 +2725,7 @@ else ac_cv_c_stack_direction=0 else cat > conftest.$ac_ext <<EOF -#line 2736 "configure" +#line 2729 "configure" #include "confdefs.h" find_stack_direction () { @@ -2751,7 +2744,7 @@ main () exit (find_stack_direction() < 0); } EOF -if { (eval echo configure:2755: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2748: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_c_stack_direction=1 else @@ -2773,12 +2766,12 @@ EOF fi echo $ac_n "checking for pid_t""... $ac_c" 1>&6 -echo "configure:2777: checking for pid_t" >&5 +echo "configure:2770: 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 2782 "configure" +#line 2775 "configure" #include "confdefs.h" #include <sys/types.h> #if STDC_HEADERS @@ -2807,17 +2800,17 @@ fi ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for vfork.h""... $ac_c" 1>&6 -echo "configure:2811: checking for vfork.h" >&5 +echo "configure:2804: 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 2816 "configure" +#line 2809 "configure" #include "confdefs.h" #include <vfork.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2821: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:2814: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -2842,18 +2835,18 @@ else fi echo $ac_n "checking for working vfork""... $ac_c" 1>&6 -echo "configure:2846: checking for working vfork" >&5 +echo "configure:2839: 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:2852: checking for vfork" >&5 +echo "configure:2845: 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 2857 "configure" +#line 2850 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char vfork(); below. */ @@ -2876,7 +2869,7 @@ vfork(); ; return 0; } EOF -if { (eval echo configure:2880: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2873: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_vfork=yes" else @@ -2898,7 +2891,7 @@ fi ac_cv_func_vfork_works=$ac_cv_func_vfork else cat > conftest.$ac_ext <<EOF -#line 2902 "configure" +#line 2895 "configure" #include "confdefs.h" /* Thanks to Paul Eggert for this test. */ #include <stdio.h> @@ -2993,7 +2986,7 @@ main() { } } EOF -if { (eval echo configure:2997: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2990: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_func_vfork_works=yes else @@ -3016,7 +3009,7 @@ EOF fi echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6 -echo "configure:3020: checking for 8-bit clean memcmp" >&5 +echo "configure:3013: 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 @@ -3024,7 +3017,7 @@ else ac_cv_func_memcmp_clean=no else cat > conftest.$ac_ext <<EOF -#line 3028 "configure" +#line 3021 "configure" #include "confdefs.h" main() @@ -3034,7 +3027,7 @@ main() } EOF -if { (eval echo configure:3038: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3031: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_func_memcmp_clean=yes else @@ -3056,12 +3049,12 @@ for ac_func in dup2 memmove mkdir strcasecmp strncasecmp strerror strftime\ isinf isnan finite do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:3060: checking for $ac_func" >&5 +echo "configure:3053: 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 3065 "configure" +#line 3058 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -3084,7 +3077,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:3088: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3081: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -3117,12 +3110,12 @@ for ac_func in fmod killpg drand48 random wait4 waitpid syscall getcwd\ dlopen sigprocmask sigaction _setjmp setsid do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:3121: checking for $ac_func" >&5 +echo "configure:3114: 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 3126 "configure" +#line 3119 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -3145,7 +3138,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:3149: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3142: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -3170,12 +3163,12 @@ fi done echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 -echo "configure:3174: checking whether struct tm is in sys/time.h or time.h" >&5 +echo "configure:3167: 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 3179 "configure" +#line 3172 "configure" #include "confdefs.h" #include <sys/types.h> #include <time.h> @@ -3183,7 +3176,7 @@ int main() { struct tm *tp; tp->tm_sec; ; return 0; } EOF -if { (eval echo configure:3187: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3180: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_tm=time.h else @@ -3204,12 +3197,12 @@ EOF fi echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 -echo "configure:3208: checking for tm_zone in struct tm" >&5 +echo "configure:3201: 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 3213 "configure" +#line 3206 "configure" #include "confdefs.h" #include <sys/types.h> #include <$ac_cv_struct_tm> @@ -3217,7 +3210,7 @@ int main() { struct tm tm; tm.tm_zone; ; return 0; } EOF -if { (eval echo configure:3221: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3214: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_tm_zone=yes else @@ -3237,12 +3230,12 @@ EOF else echo $ac_n "checking for tzname""... $ac_c" 1>&6 -echo "configure:3241: checking for tzname" >&5 +echo "configure:3234: 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 3246 "configure" +#line 3239 "configure" #include "confdefs.h" #include <time.h> #ifndef tzname /* For SGI. */ @@ -3252,7 +3245,7 @@ int main() { atoi(*tzname); ; return 0; } EOF -if { (eval echo configure:3256: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3249: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_cv_var_tzname=yes else @@ -3275,14 +3268,14 @@ fi if test "$ac_cv_func_strftime" = no; then cat > conftest.$ac_ext <<EOF -#line 3279 "configure" +#line 3272 "configure" #include "confdefs.h" int main() { extern int daylight; int i = daylight; ; return 0; } EOF -if { (eval echo configure:3286: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3279: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* cat >> confdefs.h <<\EOF #define HAVE_DAYLIGHT 1 @@ -3302,7 +3295,7 @@ EOF else echo $ac_n "checking for BSD signal semantics""... $ac_c" 1>&6 -echo "configure:3306: checking for BSD signal semantics" >&5 +echo "configure:3299: 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 @@ -3310,7 +3303,7 @@ else rb_cv_bsd_signal=no else cat > conftest.$ac_ext <<EOF -#line 3314 "configure" +#line 3307 "configure" #include "confdefs.h" #include <stdio.h> @@ -3332,7 +3325,7 @@ main() } EOF -if { (eval echo configure:3336: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3329: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then rb_cv_bsd_signal=yes else @@ -3356,7 +3349,7 @@ EOF fi echo $ac_n "checking whether getpgrp takes no argument""... $ac_c" 1>&6 -echo "configure:3360: checking whether getpgrp takes no argument" >&5 +echo "configure:3353: checking whether getpgrp takes no argument" >&5 if eval "test \"`echo '$''{'ac_cv_func_getpgrp_void'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -3364,7 +3357,7 @@ else { echo "configure: error: cannot check getpgrp if cross compiling" 1>&2; exit 1; } else cat > conftest.$ac_ext <<EOF -#line 3368 "configure" +#line 3361 "configure" #include "confdefs.h" /* @@ -3419,7 +3412,7 @@ main() } EOF -if { (eval echo configure:3423: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3416: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_func_getpgrp_void=yes else @@ -3443,7 +3436,7 @@ EOF fi echo $ac_n "checking whether setpgrp takes no argument""... $ac_c" 1>&6 -echo "configure:3447: checking whether setpgrp takes no argument" >&5 +echo "configure:3440: checking whether setpgrp takes no argument" >&5 if eval "test \"`echo '$''{'ac_cv_func_setpgrp_void'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -3451,7 +3444,7 @@ else { echo "configure: error: cannot check setpgrp if cross compiling" 1>&2; exit 1; } else cat > conftest.$ac_ext <<EOF -#line 3455 "configure" +#line 3448 "configure" #include "confdefs.h" #ifdef HAVE_UNISTD_H @@ -3471,7 +3464,7 @@ main() } EOF -if { (eval echo configure:3475: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3468: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_func_setpgrp_void=no else @@ -3496,7 +3489,7 @@ fi echo $ac_n "checking for working strtod""... $ac_c" 1>&6 -echo "configure:3500: checking for working strtod" >&5 +echo "configure:3493: checking for working strtod" >&5 if eval "test \"`echo '$''{'rb_cv_func_strtod'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -3504,7 +3497,7 @@ else rb_cv_func_strtod=no else cat > conftest.$ac_ext <<EOF -#line 3508 "configure" +#line 3501 "configure" #include "confdefs.h" double strtod (); @@ -3534,7 +3527,7 @@ main() } EOF -if { (eval echo configure:3538: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3531: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then rb_cv_func_strtod=yes else @@ -3552,14 +3545,14 @@ echo "$ac_t""$rb_cv_func_strtod" 1>&6 test $rb_cv_func_strtod = no && LIBOBJS="$LIBOBJS strtod.o" echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 -echo "configure:3556: checking whether byte ordering is bigendian" >&5 +echo "configure:3549: 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 3563 "configure" +#line 3556 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/param.h> @@ -3570,11 +3563,11 @@ int main() { #endif ; return 0; } EOF -if { (eval echo configure:3574: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3567: \"$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 3578 "configure" +#line 3571 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/param.h> @@ -3585,7 +3578,7 @@ int main() { #endif ; return 0; } EOF -if { (eval echo configure:3589: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3582: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_bigendian=yes else @@ -3605,7 +3598,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 3609 "configure" +#line 3602 "configure" #include "confdefs.h" main () { /* Are we little or big endian? From Harbison&Steele. */ @@ -3618,7 +3611,7 @@ main () { exit (u.c[sizeof (long) - 1] == 1); } EOF -if { (eval echo configure:3622: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3615: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_c_bigendian=no else @@ -3642,12 +3635,12 @@ EOF fi echo $ac_n "checking for working const""... $ac_c" 1>&6 -echo "configure:3646: checking for working const" >&5 +echo "configure:3639: checking for working const" >&5 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 3651 "configure" +#line 3644 "configure" #include "confdefs.h" int main() { @@ -3696,7 +3689,7 @@ ccp = (char const *const *) p; ; return 0; } EOF -if { (eval echo configure:3700: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3693: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_const=yes else @@ -3717,14 +3710,14 @@ EOF fi echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6 -echo "configure:3721: checking whether char is unsigned" >&5 +echo "configure:3714: 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 3728 "configure" +#line 3721 "configure" #include "confdefs.h" #ifdef __CHAR_UNSIGNED__ yes @@ -3746,7 +3739,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 3750 "configure" +#line 3743 "configure" #include "confdefs.h" /* volatile prevents gcc2 from optimizing the test away on sparcs. */ #if !defined(__STDC__) || __STDC__ != 1 @@ -3756,7 +3749,7 @@ main() { volatile char c = 255; exit(c < 0); } EOF -if { (eval echo configure:3760: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3753: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_c_char_unsigned=yes else @@ -3781,7 +3774,7 @@ fi echo $ac_n "checking whether right shift preserve sign bit""... $ac_c" 1>&6 -echo "configure:3785: checking whether right shift preserve sign bit" >&5 +echo "configure:3778: 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 @@ -3789,7 +3782,7 @@ else rb_cv_rshift_sign=yes else cat > conftest.$ac_ext <<EOF -#line 3793 "configure" +#line 3786 "configure" #include "confdefs.h" int @@ -3801,7 +3794,7 @@ main() } EOF -if { (eval echo configure:3805: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:3798: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then rb_cv_rshift_sign=yes else @@ -3829,19 +3822,19 @@ EOF fi echo $ac_n "checking count field in FILE structures""... $ac_c" 1>&6 -echo "configure:3833: checking count field in FILE structures" >&5 +echo "configure:3826: 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 3838 "configure" +#line 3831 "configure" #include "confdefs.h" #include <stdio.h> int main() { FILE *f = stdin; f->_cnt = 0; ; return 0; } EOF -if { (eval echo configure:3845: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3838: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_fcnt="_cnt" else @@ -3851,14 +3844,14 @@ fi rm -f conftest* if test "$rb_cv_fcnt" = ""; then cat > conftest.$ac_ext <<EOF -#line 3855 "configure" +#line 3848 "configure" #include "confdefs.h" #include <stdio.h> int main() { FILE *f = stdin; f->__cnt = 0; ; return 0; } EOF -if { (eval echo configure:3862: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3855: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_fcnt="__cnt" else @@ -3869,14 +3862,14 @@ rm -f conftest* fi if test "$rb_cv_fcnt" = ""; then cat > conftest.$ac_ext <<EOF -#line 3873 "configure" +#line 3866 "configure" #include "confdefs.h" #include <stdio.h> int main() { FILE *f = stdin; f->_r = 0; ; return 0; } EOF -if { (eval echo configure:3880: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3873: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_fcnt="_r" else @@ -3887,14 +3880,14 @@ rm -f conftest* fi if test "$rb_cv_fcnt" = ""; then cat > conftest.$ac_ext <<EOF -#line 3891 "configure" +#line 3884 "configure" #include "confdefs.h" #include <stdio.h> int main() { FILE *f = stdin; f->readCount = 0; ; return 0; } EOF -if { (eval echo configure:3898: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3891: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_fcnt="readCount" else @@ -3905,14 +3898,14 @@ rm -f conftest* fi if test "$rb_cv_fcnt" = ""; then cat > conftest.$ac_ext <<EOF -#line 3909 "configure" +#line 3902 "configure" #include "confdefs.h" #include <stdio.h> int main() { FILE *f = stdin; f->_rcount = 0; ; return 0; } EOF -if { (eval echo configure:3916: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3909: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_fcnt="_rcount" else @@ -3980,7 +3973,7 @@ fi echo $ac_n "checking whether ELF binaries are produced""... $ac_c" 1>&6 -echo "configure:3984: checking whether ELF binaries are produced" >&5 +echo "configure:3977: checking whether ELF binaries are produced" >&5 if eval "test \"`echo '$''{'rb_cv_binary_elf'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -3988,7 +3981,7 @@ else rb_cv_binary_elf=yes else cat > conftest.$ac_ext <<EOF -#line 3992 "configure" +#line 3985 "configure" #include "confdefs.h" /* Test for whether ELF binaries are produced */ @@ -4008,7 +4001,7 @@ main() { } EOF -if { (eval echo configure:4012: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:4005: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then rb_cv_binary_elf=yes else @@ -4056,13 +4049,12 @@ 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:4060: checking whether OS depend dynamic link works" >&5 +echo "configure:4053: checking whether OS depend dynamic link works" >&5 if test "$GCC" = yes; then case "$host_os" in nextstep*) ;; openstep*) ;; rhapsody*) ;; - macos*) ;; human*) ;; bsdi*) ;; cygwin*) ;; @@ -4142,10 +4134,6 @@ echo "configure:4060: checking whether OS depend dynamic link works" >&5 LDFLAGS="" DLDFLAGS="$ARCH_FLAG" rb_cv_dlopen=yes ;; - macos*) LDSHARED='cc -dynamic -bundle -undefined suppress' - LDFLAGS="" - DLDFLAGS="$ARCH_FLAG" - rb_cv_dlopen=yes ;; aix*) LDSHARED='/usr/ccs/bin/ld' XLDFLAGS='-Wl,-bE:ruby.imp' DLDFLAGS='-eInit_$(TARGET) -bI:$(topdir)/ruby.imp -bM:SRE -T512 -H512 -lc' @@ -4181,12 +4169,12 @@ if test "$ac_cv_header_a_out_h" = yes; then if test "$with_dln_a_out" = yes || test "$rb_cv_dlopen" = unknown; then cat confdefs.h > config.h echo $ac_n "checking whether matz's dln works""... $ac_c" 1>&6 -echo "configure:4185: checking whether matz's dln works" >&5 +echo "configure:4173: checking whether matz's dln works" >&5 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 4190 "configure" +#line 4178 "configure" #include "confdefs.h" #define USE_DLN_A_OUT @@ -4196,7 +4184,7 @@ int main() { ; return 0; } EOF -if { (eval echo configure:4200: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4188: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* rb_cv_dln_a_out=yes else @@ -4253,11 +4241,6 @@ EOF #define DLEXT ".bundle" EOF ;; - macos*) DLEXT=bundle - cat >> confdefs.h <<\EOF -#define DLEXT ".bundle" -EOF -;; cygwin*) DLEXT=dll cat >> confdefs.h <<\EOF #define DLEXT ".dll" @@ -4291,8 +4274,6 @@ case "$host_os" in STRIP='strip -A -n';; rhapsody*) STRIP='strip -A -n';; - macos*) - STRIP='strip -A -n';; esac EXTSTATIC= @@ -4310,7 +4291,7 @@ fi case "$host_os" in human*) echo $ac_n "checking for _harderr in -lsignal""... $ac_c" 1>&6 -echo "configure:4314: checking for _harderr in -lsignal" >&5 +echo "configure:4295: 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 @@ -4318,7 +4299,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lsignal $LIBS" cat > conftest.$ac_ext <<EOF -#line 4322 "configure" +#line 4303 "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 @@ -4329,7 +4310,7 @@ int main() { _harderr() ; return 0; } EOF -if { (eval echo configure:4333: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4314: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4357,7 +4338,7 @@ else fi echo $ac_n "checking for hmemset in -lhmem""... $ac_c" 1>&6 -echo "configure:4361: checking for hmemset in -lhmem" >&5 +echo "configure:4342: 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 @@ -4365,7 +4346,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lhmem $LIBS" cat > conftest.$ac_ext <<EOF -#line 4369 "configure" +#line 4350 "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 @@ -4376,7 +4357,7 @@ int main() { hmemset() ; return 0; } EOF -if { (eval echo configure:4380: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4361: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4406,12 +4387,12 @@ fi for ac_func in select gettimeofday do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:4410: checking for $ac_func" >&5 +echo "configure:4391: 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 4415 "configure" +#line 4396 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -4434,7 +4415,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:4438: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4419: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -4459,7 +4440,7 @@ fi done echo $ac_n "checking whether PD libc _dtos18 fail to convert big number""... $ac_c" 1>&6 -echo "configure:4463: checking whether PD libc _dtos18 fail to convert big number" >&5 +echo "configure:4444: 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 @@ -4467,7 +4448,7 @@ else rb_cv_missing__dtos18=no else cat > conftest.$ac_ext <<EOF -#line 4471 "configure" +#line 4452 "configure" #include "confdefs.h" #include <stdio.h> @@ -4479,7 +4460,7 @@ main () } EOF -if { (eval echo configure:4483: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:4464: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then rb_cv_missing__dtos18=yes else @@ -4501,7 +4482,7 @@ EOF fi echo $ac_n "checking whether PD libc fconvert fail to round""... $ac_c" 1>&6 -echo "configure:4505: checking whether PD libc fconvert fail to round" >&5 +echo "configure:4486: 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 @@ -4509,7 +4490,7 @@ else rb_cv_missing_fconvert=no else cat > conftest.$ac_ext <<EOF -#line 4513 "configure" +#line 4494 "configure" #include "confdefs.h" #include <stdio.h> @@ -4522,7 +4503,7 @@ main () } EOF -if { (eval echo configure:4526: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:4507: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then rb_cv_missing_fconvert=yes else diff --git a/configure.in b/configure.in index e4dde170fd..7bf19d42b3 100644 --- a/configure.in +++ b/configure.in @@ -43,12 +43,6 @@ AC_ARG_ENABLE(fat-binary, TARGET_ARCHS="ppc i386" fi ;; - macos*) - echo -n "MacOS X : " - if test "$TARGET_ARCHS" = "" ; then - TARGET_ARCHS="ppc i386" - fi - ;; nextstep*|openstep*) echo -n "NeXTSTEP/OPENSTEP: " if test "$TARGET_ARCHS" = "" ; then @@ -146,7 +140,6 @@ case "$host_os" in nextstep*) ;; openstep*) ;; rhapsody*) ;; -macos*) ;; human*) ac_cv_func_getpgrp_void=yes;; beos*) ;; cygwin*) ;; @@ -401,7 +394,6 @@ if test "$with_dln_a_out" != yes; then nextstep*) ;; openstep*) ;; rhapsody*) ;; - macos*) ;; human*) ;; bsdi*) ;; cygwin*) ;; @@ -481,10 +473,6 @@ if test "$with_dln_a_out" != yes; then LDFLAGS="" DLDFLAGS="$ARCH_FLAG" rb_cv_dlopen=yes ;; - macos*) LDSHARED='cc -dynamic -bundle -undefined suppress' - LDFLAGS="" - DLDFLAGS="$ARCH_FLAG" - rb_cv_dlopen=yes ;; aix*) LDSHARED='/usr/ccs/bin/ld' XLDFLAGS='-Wl,-bE:ruby.imp' DLDFLAGS='-eInit_$(TARGET) -bI:$(topdir)/ruby.imp -bM:SRE -T512 -H512 -lc' @@ -553,8 +541,6 @@ else AC_DEFINE(DLEXT, ".bundle");; rhapsody*) DLEXT=bundle AC_DEFINE(DLEXT, ".bundle");; - macos*) DLEXT=bundle - AC_DEFINE(DLEXT, ".bundle");; cygwin*) DLEXT=dll AC_DEFINE(DLEXT, ".dll");; os2_emx*) DLEXT=dll @@ -580,8 +566,6 @@ case "$host_os" in STRIP='strip -A -n';; rhapsody*) STRIP='strip -A -n';; - macos*) - STRIP='strip -A -n';; esac EXTSTATIC= diff --git a/ext/extmk.rb.in b/ext/extmk.rb.in index 91d3304fd1..deb29ecae8 100644 --- a/ext/extmk.rb.in +++ b/ext/extmk.rb.in @@ -503,7 +503,7 @@ def extmake(target) $objs = nil $local_flags = "" case RUBY_PLATFORM - when /cygwin|beos|openstep|nextstep|rhapsody|macos|i386-os2_emx/ + when /cygwin|beos|openstep|nextstep|rhapsody|i386-os2_emx/ $libs = "" when /mswin32/ $LIBEXT = "lib" diff --git a/ext/tk/lib/tk.rb b/ext/tk/lib/tk.rb index 6dd832b942..a028797f74 100644 --- a/ext/tk/lib/tk.rb +++ b/ext/tk/lib/tk.rb @@ -457,6 +457,21 @@ module TkCore _get_eval_string(TkUtil.eval_cmd(Tk_CMDTBL[arg.shift], *arg)) end + def scaling(scale=nil) + if scale + tk_call('tk', 'scaling', scale) + else + Float(number(tk_call('tk', 'scaling'))) + end + end + def scaling_displayof(win, scale=nil) + if scale + tk_call('tk', 'scaling', '-displayof', win, scale) + else + Float(number(tk_call('tk', '-displayof', win, 'scaling'))) + end + end + def appname(name=None) tk_call('tk', 'appname', name) end @@ -526,7 +541,7 @@ module TkCore def tk_call(*args) print args.join(" "), "\n" if $DEBUG - args.filter {|x|_get_eval_string(x)} + args.filter{|x|_get_eval_string(x)} args.compact! args.flatten! begin @@ -772,6 +787,24 @@ class TkBindTag end end +class TkBindTagAll<TkBindTag + BindTagALL = [] + def TkBindTagAll.new(*args) + if BindTagALL[0] + BindTagALL[0].bind(*args) if args != [] + else + new = super() + BindTagALL[0] = new + end + BindTagALL[0] + end + + def initialize(*args) + @id = 'all' + BindTagALL[0].bind(*args) if args != [] + end +end + class TkVariable include Tk extend TkCore @@ -1151,6 +1184,31 @@ module TkKinput end end +module TkXIM + include Tk + extend Tk + + def TkXIM.useinputmethods(window=nil,value=nil) + if window + if value + tk_call 'tk', 'useinputmethods', '-displayof', window.path, value + else + tk_call 'tk', 'useinputmethods', '-displayof', window.path + end + else + if value + tk_call 'tk', 'useinputmethods', value + else + tk_call 'tk', 'useinputmethods' + end + end + end + + def useinputmethods(value=nil) + TkXIM.useinputmethods(self,value) + end +end + module TkWinfo include Tk extend Tk @@ -1807,7 +1865,7 @@ class TkWindow<TkObject self end - def unpack(keys = nil) + def unpack tk_call 'pack', 'forget', epath self end @@ -1817,7 +1875,7 @@ class TkWindow<TkObject self end - def ungrid(keys = nil) + def ungrid tk_call 'grid', 'forget', epath self end @@ -1827,8 +1885,8 @@ class TkWindow<TkObject self end - def unplace(keys = nil) - tk_call 'place', 'forget', epath, *hash_kv(keys) + def unplace + tk_call 'place', 'forget', epath self end alias place_forget unplace @@ -1894,11 +1952,11 @@ class TkWindow<TkObject end def lower(below=None) - tk_call 'lower', path, below + tk_call 'lower', epath, below self end def raise(above=None) - tk_call 'raise', path, above + tk_call 'raise', epath, above self end @@ -1912,7 +1970,7 @@ class TkWindow<TkObject end def destroy - tk_call 'destroy', path + tk_call 'destroy', epath if @cmdtbl for id in @cmdtbl uninstall_cmd id @@ -1927,7 +1985,7 @@ class TkWindow<TkObject alias wait wait_visibility def wait_destroy - tk_call 'tkwait', 'window', path + tk_call 'tkwait', 'window', epath end def bindtags(taglist=nil) @@ -2259,6 +2317,41 @@ class TkListbox<TkTextWin def selection_set(first, last=None) tk_send 'selection', 'set', first, last end + + def itemcget(index, key) + tk_tcl2ruby tk_send 'itemcget', index, "-#{key}" + end + def itemconfigure(index, key, val=None) + if key.kind_of? Hash + if (key['font'] || key['kanjifont'] || + key['latinfont'] || key['asciifont']) + tagfont_configure(index, key.dup) + else + tk_send 'itemconfigure', index, *hash_kv(key) + end + + else + if (key == 'font' || key == 'kanjifont' || + key == 'latinfont' || key == 'asciifont' ) + tagfont_configure({key=>val}) + else + tk_call 'itemconfigure', index, "-#{key}", val + end + end + end + + def itemconfiginfo(index, key=nil) + if key + conf = tk_split_list(tk_send('itemconfigure',index,"-#{key}")) + conf[0] = conf[0][1..-1] + conf + else + tk_split_list(tk_send('itemconfigure', index)).collect{|conf| + conf[0] = conf[0][1..-1] + conf + } + end + end end module TkTreatMenuEntryFont @@ -2397,6 +2490,9 @@ class TkMenu<TkWindow def delete(index, last=None) tk_send 'delete', index, last end + def popup(x, y, index=nil) + tk_call 'tk_popup', path, x, y, index + end def post(x, y) tk_send 'post', x, y end @@ -2451,6 +2547,34 @@ class TkMenu<TkWindow end end +module TkSystemMenu + def initialize(parent, keys=nil) + fail unless parent.kind_of? TkMenu + @path = format("%s.%s", parent.path, self.type::SYSMENU_NAME) + TkComm::Tk_WINDOWS[@path] = self + create_self + configure(keys) if keys + end +end + +class TkSysMenu_Help<TkMenu + # for all platform + include TkSystemMenu + SYSMENU_NAME = 'help' +end + +class TkSysMenu_System<TkMenu + # for Windows + include TkSystemMenu + SYSMENU_NAME = 'system' +end + +class TkSysMenu_Apple<TkMenu + # for Machintosh + include TkSystemMenu + SYSMENU_NAME = 'apple' +end + class TkMenubutton<TkLabel WidgetClassNames['Menubutton'] = self def TkMenubutton.to_eval @@ -2461,6 +2585,71 @@ class TkMenubutton<TkLabel end end +class TkOptionMenubutton<TkMenubutton + class OptionMenu<TkMenu + def initialize(parent) + @path = parent.path + '.menu' + TkComm::Tk_WINDOWS[@path] = self + end + end + + def initialize(parent=nil, var=TkVariable.new, firstval=nil, *vals) + fail unless var.kind_of? TkVariable + @variable = var + firstval = @variable.value unless firstval + @variable.value = firstval + install_win(if parent then parent.path end) + @menu = OptionMenu.new(self) + tk_call 'tk_optionMenu', @path, @variable.id, firstval, *vals + end + + def value + @variable.value + end + + def activate(index) + @menu.activate(index) + end + def add(value) + @menu.add('radiobutton', 'variable'=>@variable, + 'label'=>value, 'value'=>value) + end + def index(index) + @menu.index(index) + end + def invoke(index) + @menu.invoke(index) + end + def insert(index, value) + @menu.add(index, 'radiobutton', 'variable'=>@variable, + 'label'=>value, 'value'=>value) + end + def delete(index, last=None) + @menu.delete(index, last) + end + def yposition(index) + @menu.yposition(index) + end + def menucget(index, key) + @menu.cget(index, key) + end + def menuconfigure(index, key, val=None) + @menu.configure(index, key, val) + end + def menuconfiginfo(index, key=nil) + @menu.configinfo(index, key) + end + def entrycget(index, key) + @menu.entrycget(index, key) + end + def entryconfigure(index, key, val=None) + @menu.entryconfigure(index, key, val) + end + def entryconfiginfo(index, key=nil) + @menu.entryconfiginfo(index, key) + end +end + module TkComposite include Tk extend Tk diff --git a/ext/tk/lib/tkcanvas.rb b/ext/tk/lib/tkcanvas.rb index 80c36f6ed8..7f44bdb993 100644 --- a/ext/tk/lib/tkcanvas.rb +++ b/ext/tk/lib/tkcanvas.rb @@ -217,7 +217,7 @@ class TkCanvas<TkWindow def find(mode, *args) list(tk_send 'find', mode, *args).filter{|id| - TkcItem.id2obj(id) + TkcItem.id2obj(self, id) } end def find_above(target) @@ -250,14 +250,14 @@ class TkCanvas<TkWindow if ret == "" nil else - TkcItem.id2obj(ret) + TkcItem.id2obj(self, ret) end end end def gettags(tagOrId) list(tk_send('gettags', tagid(tagOrId))).collect{|tag| - TkcTag.id2obj(tag) + TkcTag.id2obj(self, tag) } end @@ -478,6 +478,41 @@ module TkcTagAccess def itemtype @c.itemtype @id end + + # Followings operators supports logical expressions of canvas tags + # (for Tk8.3+). + # If tag1.path is 't1' and tag2.path is 't2', then + # ltag = tag1 & tag2; ltag.path => "(t1)&&(t2)" + # ltag = tag1 | tag2; ltag.path => "(t1)||(t2)" + # ltag = tag1 ^ tag2; ltag.path => "(t1)^(t2)" + # ltag = - tag1; ltag.path => "!(t1)" + def & (tag) + if tag.kind_of? TkObject + TkcTagString.new(@c, '(' + @id + ')&&(' + tag.path + ')') + else + TkcTagString.new(@c, '(' + @id + ')&&(' + tag.to_s + ')') + end + end + + def | (tag) + if tag.kind_of? TkObject + TkcTagString.new(@c, '(' + @id + ')||(' + tag.path + ')') + else + TkcTagString.new(@c, '(' + @id + ')||(' + tag.to_s + ')') + end + end + + def ^ (tag) + if tag.kind_of? TkObject + TkcTagString.new(@c, '(' + @id + ')^(' + tag.path + ')') + else + TkcTagString.new(@c, '(' + @id + ')^(' + tag.to_s + ')') + end + end + + def -@ + TkcTagString.new(@c, '!(' + @id + ')') + end end class TkcTag<TkObject @@ -485,8 +520,10 @@ class TkcTag<TkObject CTagID_TBL = {} - def TkcTag.id2obj(id) - CTagID_TBL[id]? CTagID_TBL[id]: id + def TkcTag.id2obj(canvas, id) + cpath = canvas.path + return id unless CTagID_TBL[cpath] + CTagID_TBL[cpath][id]? CTagID_TBL[cpath][id]: id end Tk_CanvasTag_ID = ['ctag0000'] @@ -495,8 +532,10 @@ class TkcTag<TkObject fail format("%s need to be TkCanvas", parent.inspect) end @c = parent + @cpath = parent.path @path = @id = Tk_CanvasTag_ID[0] - CTagID_TBL[@id] = self + CTagID_TBL[@cpath] = {} unless CTagID_TBL[@cpath] + CTagID_TBL[@cpath][@id] = self Tk_CanvasTag_ID[0] = Tk_CanvasTag_ID[0].succ if mode tk_call @c.path, "addtag", @id, mode, *args @@ -508,7 +547,7 @@ class TkcTag<TkObject def delete @c.delete @id - CTagID_TBL[@id] = nil + CTagID_TBL[@path][@id] = nil if CTagID_TBL[@path] end alias remove delete alias destroy delete @@ -534,7 +573,7 @@ class TkcTag<TkObject alias closest set_to_closest def set_to_enclosed(x1, y1, x2, y2) - @c.addtag_enclosest(@id, x1, y1, x2, y2) + @c.addtag_enclosed(@id, x1, y1, x2, y2) end alias enclosed set_to_enclosed @@ -549,14 +588,40 @@ class TkcTag<TkObject alias withtag set_to_withtag end +class TkcTagString<TkcTag + def self.new(parent, name, *args) + if CTagID_TBL[parent.path] && CTagID_TBL[parent.path][name] + return CTagID_TBL[parent.path][name] + else + super(parent, name, *args) + end + end + + def initialize(parent, name, mode=nil, *args) + if not parent.kind_of?(TkCanvas) + fail format("%s need to be TkCanvas", parent.inspect) + end + @c = parent + @cpath = parent.path + @path = @id = name + CTagID_TBL[@cpath] = {} unless CTagID_TBL[@cpath] + CTagID_TBL[@cpath][@id] = self + if mode + tk_call @c.path, "addtag", @id, mode, *args + end + end +end + class TkcTagAll<TkcTag def initialize(parent) if not parent.kind_of?(TkCanvas) fail format("%s need to be TkCanvas", parent.inspect) end @c = parent + @cpath = parent.path @path = @id = 'all' - CTagID_TBL[@id] = self + CTagID_TBL[@cpath] = {} unless CTagID_TBL[@cpath] + CTagID_TBL[@cpath][@id] = self end end @@ -566,8 +631,10 @@ class TkcTagCurrent<TkcTag fail format("%s need to be TkCanvas", parent.inspect) end @c = parent + @cpath = parent.path @path = @id = 'current' - CTagID_TBL[@id] = self + CTagID_TBL[@cpath] = {} unless CTagID_TBL[@cpath] + CTagID_TBL[@cpath][@id] = self end end @@ -578,8 +645,10 @@ class TkcGroup<TkcTag fail format("%s need to be TkCanvas", parent.inspect) end @c = parent + @cpath = parent.path @path = @id = Tk_cGroup_ID[0] - CTagID_TBL[@id] = self + CTagID_TBL[@cpath] = {} unless CTagID_TBL[@cpath] + CTagID_TBL[@cpath][@id] = self Tk_cGroup_ID[0] = Tk_cGroup_ID[0].succ add(*args) if args != [] end @@ -597,7 +666,6 @@ class TkcGroup<TkcTag end end - class TkcItem<TkObject include TkcTagAccess @@ -608,8 +676,10 @@ class TkcItem<TkObject CItemTypeToClass[type] end - def TkcItem.id2obj(id) - CItemID_TBL[id]? CItemID_TBL[id]: id + def TkcItem.id2obj(canvas, id) + cpath = canvas.path + return id unless CItemID_TBL[cpath] + CItemID_TBL[cpath][id]? CItemID_TBL[cpath][id]: id end def initialize(parent, *args) @@ -622,7 +692,8 @@ class TkcItem<TkObject keys = args.pop end @id = create_self(*args).to_i ;# 'canvas item id' is integer number - CItemID_TBL[@id] = self + CItemID_TBL[@path] = {} unless CItemID_TBL[@path] + CItemID_TBL[@path][@id] = self if keys # tk_call @path, 'itemconfigure', @id, *hash_kv(keys) configure(keys) if keys @@ -636,7 +707,7 @@ class TkcItem<TkObject def delete @c.delete @id - CItemID_TBL[@id] = nil + CItemID_TBL[@path][@id] = nil if CItemID_TBL[@path] end alias remove delete alias destroy delete @@ -768,6 +839,10 @@ class TkPhotoImage<TkImage tk_send 'copy', source, *args end + def data(keys=nil) + tk_send 'data', *hash_kv(keys) + end + def get(x, y) tk_send 'get', x, y end diff --git a/ext/tk/lib/tkentry.rb b/ext/tk/lib/tkentry.rb index f35d2eef00..5207d9b895 100644 --- a/ext/tk/lib/tkentry.rb +++ b/ext/tk/lib/tkentry.rb @@ -59,6 +59,14 @@ class TkEntry<TkLabel tk_send 'selection', 'to', index end + def validate + if tk_send('validate') == '0' + false + else + true + end + end + def value tk_send 'get' end diff --git a/ext/tk/lib/tkfont.rb b/ext/tk/lib/tkfont.rb index 2683260d69..363839d3d3 100644 --- a/ext/tk/lib/tkfont.rb +++ b/ext/tk/lib/tkfont.rb @@ -49,7 +49,7 @@ class TkFont def TkFont.create_copy(font) keys = {} - font.configure.each{|key,value| keys[key] = value } + font.configinfo.each{|key,value| keys[key] = value } new_font = TkFont.new(font.latin_font, font.kanji_font, keys) end @@ -123,17 +123,13 @@ class TkFont ################################### private ################################### - def initialize(ltn=nil, knj=nil, keys=nil) + def initialize(ltn=DEFAULT_LATIN_FONT_NAME, knj=DEFAULT_KANJI_FONT_NAME, + keys=nil) @id = format("@font%.4d", Tk_FontID[0]) Tk_FontID[0] += 1 Tk_FontNameTBL[@id] = self - - ltn = DEFAULT_LATIN_FONT_NAME unless ltn create_latinfont(ltn) - - knj = DEFAULT_KANJI_FONT_NAME unless knj create_kanjifont(knj) - create_compoundfont(keys) end @@ -714,7 +710,7 @@ class TkFont if winobj.kind_of? TkText ret.push([winobj, winobj.tagid2obj(tag)]) elsif winobj.kind_of? TkCanvas - if (tagobj = TkcTag.id2obj(tag)).kind_of? TkcTag + if (tagobj = TkcTag.id2obj(winobj, tag)).kind_of? TkcTag ret.push([winobj, tagobj]) elsif (tagobj = TkcItem.id2obj(tag)).kind_of? TkcItem ret.push([winobj, tagobj]) @@ -822,7 +818,7 @@ class TkFont if JAPANIZED_TK configinfo_core(@latinfont, slot) else - configure(slot, value) + configinfo(slot) end end @@ -582,7 +582,10 @@ rb_io_gets_internal(argc, argv, io) c = getc(f); TRAP_END; if (c == EOF) { - if (ferror(f) && errno == EINTR) continue; + if (ferror(f)) { + ig (errno == EINTR) continue; + rb_sys_fail(fptr->path); + } break; } if ((*bp++ = c) == newline) break; @@ -669,7 +672,10 @@ rb_io_gets(io) c = getc(f); TRAP_END; if (c == EOF) { - if (ferror(f) && errno == EINTR) continue; + if (ferror(f)) { + ig (errno == EINTR) continue; + rb_sys_fail(fptr->path); + } break; } if ((*bp++ = c) == '\n') break; diff --git a/lib/jcode.rb b/lib/jcode.rb index 92b9284471..608c97206e 100644 --- a/lib/jcode.rb +++ b/lib/jcode.rb @@ -84,10 +84,6 @@ class String h end - def bsquote(str) - str.gsub(/\\/, '\\\\\\\\') - end - HashCache = {} TrPatternCache = {} DeletePatternCache = {} @@ -98,7 +94,7 @@ class String def tr!(from, to) return self.delete!(from) if to.length == 0 - pattern = TrPatternCache[from] ||= /[#{bsquote(from)}]/ + pattern = TrPatternCache[from] ||= /[#{Regexp::quote(from)}]/ if from[0] == ?^ last = /.$/.match(to)[0] self.gsub!(pattern, last) @@ -113,7 +109,7 @@ class String end def delete!(del) - self.gsub!(DeletePatternCache[del] ||= /[#{bsquote(del)}]+/, '') + self.gsub!(DeletePatternCache[del] ||= /[#{Regexp::quote(del)}]+/, '') end def delete(del) @@ -123,7 +119,7 @@ class String def squeeze!(del=nil) pattern = if del - SqueezePatternCache[del] ||= /([#{bsquote(del)}])\1+/ + SqueezePatternCache[del] ||= /([#{Regexp::quote(del)}])\1+/ else /(.|\n)\1+/ end @@ -137,7 +133,7 @@ class String def tr_s!(from, to) return self.delete!(from) if to.length == 0 - pattern = SqueezePatternCache[from] ||= /([#{bsquote(from)}])\1+"/ + pattern = SqueezePatternCache[from] ||= /([#{Regexp::quote(from)}])\1+"/ if from[0] == ?^ last = /.$/.match(to)[0] self.gsub!(pattern, last) @@ -163,5 +159,9 @@ class String self.delete("^#{str}").jlength end + def each_char(&block) + scan(/.|\n/, &block) + end end + $VERBOSE = $vsave diff --git a/lib/pstore.rb b/lib/pstore.rb index 97b3794326..eb65aabc8d 100644 --- a/lib/pstore.rb +++ b/lib/pstore.rb @@ -88,14 +88,14 @@ class PStore file = File::open(@filename, "r+") orig = true else + @table = {} file = File::open(@filename, "w+") + Marshal::dump(@table, file) end file.flock(File::LOCK_EX) if orig File::copy @filename, backup @table = Marshal::load(file) - else - @table = {} end begin catch(:pstore_abort_transaction) do diff --git a/misc/ruby-mode.el b/misc/ruby-mode.el index 75efbf012b..763c076d8a 100644 --- a/misc/ruby-mode.el +++ b/misc/ruby-mode.el @@ -17,6 +17,10 @@ "class\\|module\\|def\\|if\\|unless\\|case\\|while\\|until\\|for\\|begin\\|do" ) +(defconst ruby-non-block-do-re + "\\(while\\|until\\|for\\|rescue\\)\\>" + ) + (defconst ruby-indent-beg-re "\\(\\s *\\(class\\|module\\|def\\)\\)\\|if\\|unless\\|case\\|while\\|until\\|for\\|begin" ) @@ -114,6 +118,31 @@ (defvar ruby-indent-level 2 "*Indentation of ruby statements.") +(eval-when-compile (require 'cl)) +(defun ruby-imenu-create-index () + (let ((index-alist '()) + class-name class-begin method-name method-begin decl) + (goto-char (point-min)) + (while (re-search-forward "^\\s *\\(class\\|def\\)\\s *\\([^(\n ]+\\)" nil t) + (setq decl (buffer-substring (match-beginning 1) (match-end 1))) + (cond + ((string= "class" decl) + (setq class-begin (match-beginning 2)) + (setq class-name (buffer-substring class-begin (match-end 2))) + (push (cons class-name (match-beginning 0)) index-alist) + (ruby-mark-defun) + (save-restriction + (narrow-to-region (region-beginning) (region-end)) + (while (re-search-forward "^\\s *def\\s *\\([^(\n ]+\\)" nil t) + (setq method-begin (match-beginning 1)) + (setq method-name (buffer-substring method-begin (match-end 1))) + (push (cons (concat class-name "#" method-name) (match-beginning 0)) index-alist)))) + ((string= "def" decl) + (setq method-begin (match-beginning 2)) + (setq method-name (buffer-substring method-begin (match-end 2))) + (push (cons method-name (match-beginning 0)) index-alist)))) + index-alist)) + (defun ruby-mode-variables () (set-syntax-table ruby-mode-syntax-table) (setq local-abbrev-table ruby-mode-abbrev-table) @@ -153,6 +182,9 @@ The variable ruby-indent-level controls the amount of indentation. (setq major-mode 'ruby-mode) (ruby-mode-variables) + (make-local-variable 'imenu-create-index-function) + (setq imenu-create-index-function 'ruby-imenu-create-index) + (run-hooks 'ruby-mode-hook)) (defun ruby-current-indentation () @@ -172,8 +204,7 @@ The variable ruby-indent-level controls the amount of indentation. (defun ruby-indent-to (x) (if x (let (shift top beg) - (and (< x 0) - (error "invalid nest")) + (and (< x 0) (error "invalid nest")) (setq shift (current-column)) (beginning-of-line) (setq beg (point)) @@ -191,7 +222,7 @@ The variable ruby-indent-level controls the amount of indentation. (indent-to x) (move-to-column (+ x shift)))))) -(defun ruby-expr-beg (&optional modifier) +(defun ruby-expr-beg (&optional option) (save-excursion (if (looking-at "\\?") (progn @@ -203,10 +234,11 @@ The variable ruby-indent-level controls the amount of indentation. (or (bolp) (looking-at ruby-operator-re) (looking-at "[\\[({]") - (and (not modifier) (looking-at "[!?]")) + (and (not (eq option 'modifier)) + (looking-at "[!?]")) (and (looking-at ruby-symbol-re) - (forward-word -1) - (if (and (not modifier) (bolp)) + (skip-chars-backward ruby-symbol-chars) + (if (and (not (eq option 'modifier)) (bolp)) t (if (or (looking-at ruby-block-beg-re) (looking-at ruby-block-op-re) @@ -214,7 +246,8 @@ The variable ruby-indent-level controls the amount of indentation. (progn (goto-char (match-end 0)) (looking-at "\\>")) - (looking-at "[a-zA-Z][a-zA-z0-9_]* +/[^ \t]")))))))) + (and (not (eq option 'expr-arg)) + (looking-at "[a-zA-Z][a-zA-z0-9_]* +/[^ \t]"))))))))) (defun ruby-parse-region (start end) (let ((indent-point end) @@ -250,7 +283,7 @@ The variable ruby-indent-level controls the amount of indentation. ((looking-at "/") (cond ((and (not (eobp)) (ruby-expr-beg)) - (if (re-search-forward "[^\\]/" indent-point t) + (if (re-search-forward "[^\\]\\(\\\\\\\\\\)*/" indent-point t) nil (setq in-string (point)) (goto-char indent-point))) @@ -258,18 +291,24 @@ The variable ruby-indent-level controls the amount of indentation. (goto-char pnt)))) ((looking-at "%") (cond - ((and (not (eobp)) (ruby-expr-beg) + ((and (not (eobp)) (ruby-expr-beg 'expr-arg) (not (looking-at "%=")) (looking-at "%[Qqrxw]?\\(.\\)")) + (goto-char (match-beginning 1)) (setq w (buffer-substring (match-beginning 1) (match-end 1))) (cond - ((string= w "[") (setq w "]")) + ((string= w "[") (setq w "\\]")) ((string= w "{") (setq w "}")) ((string= w "(") (setq w ")")) - ((string= w "<") (setq w ">"))) - (goto-char (match-end 0)) - (if (search-forward w indent-point t) + ((string= w "<") (setq w ">")) + ((member w '("*" "." "+" "?" "^" "$")) + (setq w (concat "\\" w)))) + (if (re-search-forward + (if (string= w "\\") + "\\\\[^\\]*\\\\" + (concat "[^\\]\\(\\\\\\\\\\)*" w)) + indent-point t) nil (setq in-string (point)) (goto-char indent-point))) @@ -313,7 +352,9 @@ The variable ruby-indent-level controls the amount of indentation. (if (or (and (not (bolp)) (progn (forward-char -1) - (eq ?_ (char-after (point))))) + (setq w (char-after (point))) + (or (eq ?_ w) + (eq ?. w)))) (progn (goto-char pnt) (setq w (char-after (point))) @@ -335,10 +376,45 @@ The variable ruby-indent-level controls the amount of indentation. (goto-char (match-end 0))) ((looking-at ruby-block-beg-re) (and + (or (not (looking-at "do\\>[^_]")) + (save-excursion + (back-to-indentation) + (not (looking-at ruby-non-block-do-re)))) + (or (bolp) + (progn + (forward-char -1) + (setq w (char-after (point))) + (not (or (eq ?_ w) + (eq ?. w))))) + (goto-char pnt) + (setq w (char-after (point))) + (not (eq ?_ w)) + (not (eq ?! w)) + (not (eq ?? w)) + (skip-chars-forward " \t") + (if (not (eolp)) + (progn + (goto-char (match-beginning 0)) + (if (looking-at ruby-modifier-re) + (ruby-expr-beg 'modifier) + t)) + t) + (goto-char pnt) + (setq nest (cons (cons nil pnt) nest)) + (setq depth (1+ depth))) + (goto-char pnt)) + ((looking-at ruby-block-beg-re) + (and + (or (not (looking-at "do\\>[^_]")) + (save-excursion + (back-to-indentation) + (not (looking-at ruby-non-block-do-re)))) (or (bolp) (progn (forward-char -1) - (not (eq ?_ (char-after (point)))))) + (setq w (char-after (point))) + (not (or (eq ?_ w) + (eq ?. w))))) (goto-char pnt) (setq w (char-after (point))) (not (eq ?_ w)) @@ -349,7 +425,7 @@ The variable ruby-indent-level controls the amount of indentation. (progn (goto-char (match-beginning 0)) (if (looking-at ruby-modifier-re) - (ruby-expr-beg t) + (ruby-expr-beg 'modifier) t)) t) (goto-char pnt) @@ -423,7 +499,7 @@ The variable ruby-indent-level controls the amount of indentation. (goto-char (cdr (nth 1 state))) (forward-word -1) ; skip back a keyword (cond - ((looking-at "do") ; iter block is a special case + ((looking-at "do\\>[^_]") ; iter block is a special case (cond ((nth 3 state) (goto-char (nth 3 state)) @@ -621,12 +697,12 @@ An end of a defun is found by moving forward from the beginning of one." (setq font-lock-keywords ruby-font-lock-keywords))) (defun ruby-font-lock-docs (limit) - (if (re-search-forward "^=begin\\s *$" limit t) + (if (re-search-forward "^=begin\\(\\s \\|$\\)" limit t) (let (beg) (beginning-of-line) (setq beg (point)) (forward-line 1) - (if (re-search-forward "^=end\\s *$" limit t) + (if (re-search-forward "^=end\\(\\s \\|$\\)" limit t) (progn (set-match-data (list beg (point))) t))))) @@ -671,12 +747,13 @@ An end of a defun is found by moving forward from the beginning of one." "until" "when" "while" + "yield" ) "\\|") - "\\)\\>[^_]") + "\\)\\>\\([^_]\\|$\\)") 2) ;; variables - '("\\(^\\|[^_:.@$]\\|\\.\\.\\)\\b\\(nil\\|self\\|true\\|false\\)\\b[^_]" + '("\\(^\\|[^_:.@$]\\|\\.\\.\\)\\b\\(nil\\|self\\|true\\|false\\)\\b\\([^_]\\|$\\)" 2 font-lock-variable-name-face) ;; variables '("[$@].\\(\\w\\|_\\)*" @@ -688,7 +765,7 @@ An end of a defun is found by moving forward from the beginning of one." '("\\(^\\|[^_]\\)\\b\\([A-Z]+\\(\\w\\|_\\)*\\)" 2 font-lock-type-face) ;; functions - '("^\\s *def\\s *\\([^( ]+\\)" + '("^\\s *def\\s +\\([^( ]+\\)" 1 font-lock-function-name-face) ;; symbols '("\\(^\\|[^:]\\)\\(:\\(\\w\\|_\\)+\\??\\)\\b" @@ -707,8 +784,8 @@ An end of a defun is found by moving forward from the beginning of one." ("^\\s *\\(require\\|load\\).*$" nil include) ("^\\s *\\(include\\|alias\\|undef\\).*$" nil decl) ("^\\s *\\<\\(class\\|def\\|module\\)\\>" "[)\n;]" defun) - ("[^_]\\<\\(begin\\|case\\|else\\|elsif\\|end\\|ensure\\|for\\|if\\|unless\\|rescue\\|then\\|when\\|while\\|until\\|do\\)\\>[^_]" 1 defun) - ("[^_]\\<\\(and\\|break\\|next\\|raise\\|fail\\|in\\|not\\|or\\|redo\\|retry\\|return\\|super\\|yield\\|catch\\|throw\\|self\\|nil\\)\\>[^_]" 1 keyword) + ("[^_]\\<\\(begin\\|case\\|else\\|elsif\\|end\\|ensure\\|for\\|if\\|unless\\|rescue\\|then\\|when\\|while\\|until\\|do\\|yield\\)\\>\\([^_]\\|$\\)" 1 defun) + ("[^_]\\<\\(and\\|break\\|next\\|raise\\|fail\\|in\\|not\\|or\\|redo\\|retry\\|return\\|super\\|yield\\|catch\\|throw\\|self\\|nil\\)\\>\\([^_]\\|$\\)" 1 keyword) ("\\$\\(.\\|\\sw+\\)" nil type) ("[$@].[a-zA-Z_0-9]*" nil struct) ("^__END__" nil label)))) @@ -477,14 +477,20 @@ rb_reg_prepare_re(reg) { int need_recompile = 0; - /* case-flag not set for the object */ - if (!FL_TEST(reg, REG_IGNORECASE)) { - int state = FL_TEST(reg, REG_CASESTATE); + int state; - if ((ruby_ignorecase || state) && !(ruby_ignorecase && state)) { - RBASIC(reg)->flags ^= REG_CASESTATE; - need_recompile = 1; - } + rb_reg_check(re); + state = FL_TEST(re, REG_CASESTATE); + /* ignorecase status */ + if (ruby_ignorecase && !state) { + FL_SET(re, REG_CASESTATE); + RREGEXP(re)->ptr->options |= RE_OPTION_IGNORECASE; + need_recompile = 1; + } + if (!ruby_ignorecase && state) { + FL_UNSET(re, REG_CASESTATE); + RREGEXP(re)->ptr->options &= ~RE_OPTION_IGNORECASE; + need_recompile = 1; } if (!FL_TEST(reg, KCODE_FIXED) && @@ -558,7 +564,7 @@ rb_reg_search(reg, str, pos, reverse) if (result == -2) { rb_reg_raise(RREGEXP(reg)->str, RREGEXP(reg)->len, - "Stack overfow in regexp matcher", reg); + "Stack overflow in regexp matcher", reg); } if (result < 0) { matchcache = match; diff --git a/rubytest.rb b/rubytest.rb index 20032e303e..b1006c420c 100644 --- a/rubytest.rb +++ b/rubytest.rb @@ -3,6 +3,12 @@ require 'rbconfig' include Config +unless File.exist? "./#{CONFIG['ruby_install_name']}" + print "./#{CONFIG['ruby_install_name']} is not found.\n" + print "Try `make' first, then `make test', please.\n" + exit 0 +end + if File.exist? CONFIG['LIBRUBY_SO'] case RUBY_PLATFORM when /-hpux/ @@ -195,6 +195,7 @@ time_arg(argc, argv, tm) VALUE v[6]; int i; + MEMZERO(tm, struct tm, 1); if (argc == 10) { v[0] = argv[5]; v[1] = argv[4]; @@ -202,6 +203,7 @@ time_arg(argc, argv, tm) v[3] = argv[2]; v[4] = argv[1]; v[5] = argv[0]; + tm->tm_isdst = RTEST(argv[9]) ? 1 : 0; } else { rb_scan_args(argc, argv, "15", &v[0],&v[1],&v[2],&v[3],&v[4],&v[5]); @@ -258,9 +260,9 @@ static VALUE time_localtime _((VALUE)); static VALUE time_get_tm _((VALUE, int)); static time_t -make_time_t(tptr, fn) +make_time_t(tptr, utc_or_local) struct tm *tptr; - struct tm *(*fn)(); + int utc_or_local; { struct timeval tv; time_t oguess, guess; @@ -272,21 +274,21 @@ make_time_t(tptr, fn) } guess = tv.tv_sec; - tm = (*fn)(&guess); + tm = gmtime(&guess); if (!tm) goto error; t = tptr->tm_year; if (t < 69) goto out_of_range; while (diff = t - tm->tm_year) { oguess = guess; - guess += diff * 364 * 24 * 3600; + guess += diff * 363 * 24 * 3600; if (diff > 0 && guess <= oguess) goto out_of_range; - tm = (*fn)(&guess); + tm = gmtime(&guess); if (!tm) goto error; } t = tptr->tm_mon; while (diff = t - tm->tm_mon) { guess += diff * 27 * 24 * 3600; - tm = (*fn)(&guess); + tm = gmtime(&guess); if (!tm) goto error; if (tptr->tm_year != tm->tm_year) goto out_of_range; } @@ -296,6 +298,49 @@ make_time_t(tptr, fn) guess += (tptr->tm_sec - tm->tm_sec); if (guess < 0) goto out_of_range; + if (!utc_or_local) { /* localtime zone adjust */ +#if defined(HAVE_DAYLIGHT) + extern int daylight; + extern long timezone; + + localtime(&guess); + guess += timezone + daylight; +#else + struct tm gt, lt; + long tzsec; + + t = 0; + gt = *gmtime(&guess); + lt = *localtime(&guess); + tzsec = (gt.tm_min-lt.tm_min)*60 + (gt.tm_hour-lt.tm_hour)*3600; + + if(lt.tm_year > gt.tm_year) { + tzsec -= 24*3600; + } + else if(gt.tm_year > lt.tm_year) { + tzsec += 24*3600; + } + else { + tzsec += (gt.tm_yday - lt.tm_yday)*24*3600; + } + + if (lt.tm_isdst) tzsec += 3600; + + guess += tzsec; + if (guess < 0) { + goto out_of_range; + } + tm = localtime(&guess); + if (!tm) goto error; + if (tm->tm_hour != tptr->tm_hour) { + guess -= 3600; + } +#endif + if (guess < 0) { + goto out_of_range; + } + } + return guess; out_of_range: @@ -1,4 +1,4 @@ #define RUBY_VERSION "1.4.4" -#define RUBY_RELEASE_DATE "2000-06-05" +#define RUBY_RELEASE_DATE "2000-06-13" #define RUBY_VERSION_CODE 144 -#define RUBY_RELEASE_CODE 20000605 +#define RUBY_RELEASE_CODE 20000613 |