Skip to content

Commit c6ab4b3

Browse files
authored
Autotools: Refactor ext/standard cache variables (#14799)
- Cache variable renamed from ac_cv_flush_io to php_cv_have_flush_io - CS synced
1 parent cf914f4 commit c6ab4b3

File tree

1 file changed

+10
-12
lines changed

1 file changed

+10
-12
lines changed

ext/standard/config.m4

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
dnl
22
dnl Check if flush should be called explicitly after buffered io
33
dnl
4-
AC_CACHE_CHECK([whether flush should be called explicitly after a buffered io], ac_cv_flush_io,[
5-
AC_RUN_IFELSE([AC_LANG_SOURCE([[
4+
AC_CACHE_CHECK([whether flush should be called explicitly after a buffered io],
5+
[php_cv_have_flush_io],
6+
[AC_RUN_IFELSE([AC_LANG_SOURCE([[
67
#include <stdio.h>
78
#include <stdlib.h>
89
#ifdef HAVE_UNISTD_H
@@ -40,16 +41,13 @@ int main(int argc, char **argv)
4041
4142
exit(result);
4243
}
43-
]])],[
44-
ac_cv_flush_io=no
45-
],[
46-
ac_cv_flush_io=yes
47-
],[
48-
ac_cv_flush_io=no
49-
])])
50-
if test "$ac_cv_flush_io" = "yes"; then
51-
AC_DEFINE(HAVE_FLUSHIO, 1, [Define if flush should be called explicitly after a buffered io.])
52-
fi
44+
]])],
45+
[php_cv_have_flush_io=no],
46+
[php_cv_have_flush_io=yes],
47+
[php_cv_have_flush_io=no])])
48+
AS_VAR_IF([php_cv_have_flush_io], [yes],
49+
[AC_DEFINE([HAVE_FLUSHIO], [1],
50+
[Define to 1 if flush should be called explicitly after a buffered io.])])
5351

5452
PHP_ARG_WITH([external-libcrypt],
5553
[for external libcrypt or libxcrypt],

0 commit comments

Comments
 (0)