[前][次][番号順一覧][スレッド一覧]

ruby-changes:28609

From: kosaki <ko1@a...>
Date: Sun, 12 May 2013 17:41:23 +0900 (JST)
Subject: [ruby-changes:28609] kosaki:r40661 (trunk): * configure.in: removes AC_CHECK_FUNC(fseeko, fseeko64, ftello,

kosaki	2013-05-12 17:41:12 +0900 (Sun, 12 May 2013)

  New Revision: 40661

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=40661

  Log:
    * configure.in: removes AC_CHECK_FUNC(fseeko, fseeko64, ftello,
      ftello64). They are not used from anywhere.
    
    * win32/win32.c (fseeko): removes.
    * win32/win32.c (rb_w32_ftello): removes.
    * include/ruby/win32.h: removes declarations of rb_w32_ftello and
      rb_w32_fseeko.
    * win32/Makefile.sub: removes '#define HAVE_FTELLO 1'.

  Modified files:
    trunk/ChangeLog
    trunk/configure.in
    trunk/include/ruby/win32.h
    trunk/win32/Makefile.sub
    trunk/win32/win32.c

Index: include/ruby/win32.h
===================================================================
--- include/ruby/win32.h	(revision 40660)
+++ include/ruby/win32.h	(revision 40661)
@@ -385,8 +385,6 @@ scalb(double a, long b) https://github.com/ruby/ruby/blob/trunk/include/ruby/win32.h#L385
 
 extern int 	 rb_w32_ftruncate(int fd, off_t length);
 extern int 	 rb_w32_truncate(const char *path, off_t length);
-extern off_t	 rb_w32_ftello(FILE *stream);
-extern int 	 rb_w32_fseeko(FILE *stream, off_t offset, int whence);
 
 #undef HAVE_FTRUNCATE
 #define HAVE_FTRUNCATE 1
@@ -404,22 +402,6 @@ extern int 	 rb_w32_fseeko(FILE *stream, https://github.com/ruby/ruby/blob/trunk/include/ruby/win32.h#L402
 #define truncate rb_w32_truncate
 #endif
 
-#undef HAVE_FSEEKO
-#define HAVE_FSEEKO 1
-#if defined HAVE_FSEEKO64
-#define fseeko fseeko64
-#else
-#define fseeko rb_w32_fseeko
-#endif
-
-#undef HAVE_FTELLO
-#define HAVE_FTELLO 1
-#if defined HAVE_FTELLO64
-#define ftello ftello64
-#else
-#define ftello rb_w32_ftello
-#endif
-
 /*
  * stubs
  */
Index: configure.in
===================================================================
--- configure.in	(revision 40660)
+++ configure.in	(revision 40661)
@@ -1743,11 +1743,7 @@ AC_CHECK_FUNCS(fcntl) https://github.com/ruby/ruby/blob/trunk/configure.in#L1743
 AC_CHECK_FUNCS(fdatasync)
 AC_CHECK_FUNCS(fmod)
 AC_CHECK_FUNCS(fork)
-AC_CHECK_FUNCS(fseeko)
-AC_CHECK_FUNCS(fseeko64)
 AC_CHECK_FUNCS(fsync)
-AC_CHECK_FUNCS(ftello)
-AC_CHECK_FUNCS(ftello64)
 AC_CHECK_FUNCS(ftruncate)
 AC_CHECK_FUNCS(ftruncate64)
 AC_CHECK_FUNCS(getcwd)
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 40660)
+++ ChangeLog	(revision 40661)
@@ -1,3 +1,14 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Sun May 12 16:03:41 2013  KOSAKI Motohiro  <kosaki.motohiro@g...>
+
+	* configure.in: removes AC_CHECK_FUNC(fseeko, fseeko64, ftello,
+	  ftello64). They are not used from anywhere.
+
+	* win32/win32.c (fseeko): removes.
+	* win32/win32.c (rb_w32_ftello): removes.
+	* include/ruby/win32.h: removes declarations of rb_w32_ftello and
+	  rb_w32_fseeko.
+	* win32/Makefile.sub: removes '#define HAVE_FTELLO 1'.
+
 Sun May 12 15:51:47 2013  KOSAKI Motohiro  <kosaki.motohiro@g...>
 
 	* configure.in: remove AC_CHECK_FUNC(close). It is not used from
Index: win32/win32.c
===================================================================
--- win32/win32.c	(revision 40660)
+++ win32/win32.c	(revision 40661)
@@ -4889,38 +4889,6 @@ _lseeki64(int fd, off_t offset, int when https://github.com/ruby/ruby/blob/trunk/win32/win32.c#L4889
 #endif
 
 /* License: Ruby's */
-int
-fseeko(FILE *stream, off_t offset, int whence)
-{
-    off_t pos;
-    switch (whence) {
-      case SEEK_CUR:
-	if (fgetpos(stream, (fpos_t *)&pos))
-	    return -1;
-	pos += offset;
-	break;
-      case SEEK_END:
-	if ((pos = _filelengthi64(fileno(stream))) == (off_t)-1)
-	    return -1;
-	pos += offset;
-	break;
-      default:
-	pos = offset;
-	break;
-    }
-    return fsetpos(stream, (fpos_t *)&pos);
-}
-
-/* License: Ruby's */
-off_t
-rb_w32_ftello(FILE *stream)
-{
-    off_t pos;
-    if (fgetpos(stream, (fpos_t *)&pos)) return (off_t)-1;
-    return pos;
-}
-
-/* License: Ruby's */
 static long
 filetime_to_clock(FILETIME *ft)
 {
Index: win32/Makefile.sub
===================================================================
--- win32/Makefile.sub	(revision 40660)
+++ win32/Makefile.sub	(revision 40661)
@@ -656,7 +656,6 @@ $(CONFIG_H): $(MKFILES) $(srcdir)/win32/ https://github.com/ruby/ruby/blob/trunk/win32/Makefile.sub#L656
 #define HAVE_TRUNCATE 1
 #define HAVE_FTRUNCATE 1
 #define HAVE_FSEEKO 1
-#define HAVE_FTELLO 1
 #define HAVE_TIMES 1
 #define HAVE_FCNTL 1
 #define HAVE_LINK 1

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]