ruby-changes:21810
From: kosaki <ko1@a...>
Date: Sun, 27 Nov 2011 13:55:36 +0900 (JST)
Subject: [ruby-changes:21810] kosaki:r33859 (trunk): * configure.in: revert r33832 and r33833. [Bug #5674]
kosaki 2011-11-27 13:55:27 +0900 (Sun, 27 Nov 2011) New Revision: 33859 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=33859 Log: * configure.in: revert r33832 and r33833. [ruby-core:41313] [Bug #5674] Modified files: trunk/ChangeLog trunk/configure.in Index: configure.in =================================================================== --- configure.in (revision 33858) +++ configure.in (revision 33859) @@ -1638,6 +1638,64 @@ AC_DEFINE(RSHIFT(x,y), (((x)<0) ? ~((~(x))>>(int)(y)) : (x)>>(int)(y))) fi +# win32.c still use this. Don't remove it. +test "$rb_cv_fcnt" = "not found" && rb_cv_fcnt="not found (OK if using GNU libc)" +AC_CACHE_CHECK([read count field in FILE structures], rb_cv_fcnt, +[rb_cv_fcnt="not found (OK if using GNU libc)" +for fcnt in dnl + _cnt dnl + __cnt dnl + _r dnl + readCount dnl + _rcount dnl for emx0.9c +; do + AC_TRY_COMPILE([#include <stdio.h> +], + [FILE *f = stdin; f->$fcnt = 0;], + [rb_cv_fcnt="$fcnt"; break]) +done]) +AS_CASE("$rb_cv_fcnt", + ["not found"*], [rb_cv_fcnt="not found"], + [AC_DEFINE_UNQUOTED(FILE_COUNT, $rb_cv_fcnt)]) + +# win32.c still use this. Don't remove it. +AC_CACHE_CHECK([read buffer ptr field in FILE structures], rb_cv_frptr, +[for frptr in dnl + _IO_read_ptr dnl + _ptr dnl + __ptr dnl + bufpos dnl + _p dnl + __bufpos dnl +; do + AC_TRY_COMPILE([#include <stdio.h> +], + [FILE *f = stdin; char buf[256]; f->$frptr = buf;], + rb_cv_frptr="$frptr"; break, + rb_cv_frptr="not found") +done]) +if test "$rb_cv_frptr" != "not found"; then + AC_DEFINE_UNQUOTED(FILE_READPTR, $rb_cv_frptr) + + if test "$rb_cv_fcnt" = "not found"; then + AC_CACHE_CHECK([read buffer end field in FILE structures], rb_cv_frend, + [for frend in dnl + _IO_read_end dnl + bufread dnl + __bufread dnl + ; do + AC_TRY_COMPILE([#include <stdio.h> + ], + [FILE *f = stdin; char buf[256]; f->$frend = buf;], + rb_cv_frend="$frend"; break, + rb_cv_frend="not found") + done]) + if test "$rb_cv_frend" != "not found"; then + AC_DEFINE_UNQUOTED(FILE_READEND, $rb_cv_frend) + fi + fi +fi + RUBY_CHECK_SIZEOF([struct stat.st_ino], [long "long long"], [], [@%:@include <sys/stat.h>]) AC_CACHE_CHECK([whether struct dirent.d_name is too small], rb_cv_sizeof_struct_dirent_too_small, Index: ChangeLog =================================================================== --- ChangeLog (revision 33858) +++ ChangeLog (revision 33859) @@ -105,16 +105,6 @@ and/or -Wold-style-definition warnings if specified. Patch by Nikolai Weibull. Thank you! [Bug #5459] [ruby-core:40200] -Fri Nov 25 07:56:49 2011 KOSAKI Motohiro <kosaki.motohiro@g...> - - * configure.in: remove [read buffer ptr field in FILE structures] check. - ruby 1.9 or later doesn't use stdio at all. - -Fri Nov 25 07:52:46 2011 KOSAKI Motohiro <kosaki.motohiro@g...> - - * configure.in: remove [read count field in FILE] check. - ruby 1.9 or later doesn't use stdio at all. - Fri Nov 25 07:46:09 2011 KOSAKI Motohiro <kosaki.motohiro@g...> * configure.in: add -Wall always. -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/