mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
configure.in: disable posix_fadvise
* configure.in (posix_fadvise): disable use of posix_fadvise itself on 32-bit AIX. [ruby-core:62968] [Bug #9914] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46384 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
34b6d25640
commit
8a2dc6f1dd
3 changed files with 18 additions and 5 deletions
|
@ -1,3 +1,8 @@
|
|||
Mon Jun 9 00:04:25 2014 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* configure.in (posix_fadvise): disable use of posix_fadvise
|
||||
itself on 32-bit AIX. [ruby-core:62968] [Bug #9914]
|
||||
|
||||
Sun Jun 8 23:28:00 2014 <kanemoto@ruby-lang.org>
|
||||
|
||||
* io.c (rb_io_advise): AIX currently does not support a 32-bit call to
|
||||
|
|
13
configure.in
13
configure.in
|
@ -1200,7 +1200,18 @@ mv confdefs.h largefile.h
|
|||
mv confdefs1.h confdefs.h
|
||||
cat largefile.h >> confdefs.h
|
||||
|
||||
AS_CASE(["$target_os"],[mingw*], [ac_cv_type_off_t=yes;ac_cv_sizeof_off_t=8])
|
||||
AS_CASE(["$target_os"],
|
||||
[mingw*], [ac_cv_type_off_t=yes;ac_cv_sizeof_off_t=8],
|
||||
[aix*], [
|
||||
AS_CASE(["$target_cpu:$ac_cv_sys_large_files"],
|
||||
[ppc64:*|powerpc64:*], [],
|
||||
[*:no|*:unknown], []
|
||||
[
|
||||
# AIX currently does not support a 32-bit call to posix_fadvise()
|
||||
# if _LARGE_FILES is defined.
|
||||
ac_cv_posix_fadvise=no
|
||||
])
|
||||
])
|
||||
|
||||
AC_C_BIGENDIAN
|
||||
AC_C_CONST
|
||||
|
|
5
io.c
5
io.c
|
@ -8591,10 +8591,7 @@ rb_io_advise(int argc, VALUE *argv, VALUE io)
|
|||
off = NIL_P(offset) ? 0 : NUM2OFFT(offset);
|
||||
l = NIL_P(len) ? 0 : NUM2OFFT(len);
|
||||
|
||||
/* AIX currently does not support a 32-bit call to posix_fadvise()
|
||||
* if _LARGE_FILES is defined.
|
||||
*/
|
||||
#if defined(HAVE_POSIX_FADVISE) && !(defined(_AIX) && defined(_LARGE_FILES) && !defined(_ARCH_PPC64))
|
||||
#ifdef HAVE_POSIX_FADVISE
|
||||
return do_io_advise(fptr, advice, off, l);
|
||||
#else
|
||||
((void)off, (void)l); /* Ignore all hint */
|
||||
|
|
Loading…
Add table
Reference in a new issue