Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit fc16bf6

Browse files
committed
Merge branch 'master' into libpq_compression
2 parents 7d616ce + 481018f commit fc16bf6

File tree

812 files changed

+51682
-16687
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

812 files changed

+51682
-16687
lines changed

config/ac_func_accept_argtypes.m4

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,8 @@ AC_DEFUN([AC_FUNC_ACCEPT_ARGTYPES],
4343
[AC_CACHE_VAL(ac_cv_func_accept_arg1,dnl
4444
[AC_CACHE_VAL(ac_cv_func_accept_arg2,dnl
4545
[AC_CACHE_VAL(ac_cv_func_accept_arg3,dnl
46-
[for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL' 'SOCKET WSAAPI'; do
47-
for ac_cv_func_accept_arg1 in 'int' 'unsigned int' 'SOCKET'; do
46+
[for ac_cv_func_accept_return in 'int' 'SOCKET WSAAPI' 'unsigned int PASCAL'; do
47+
for ac_cv_func_accept_arg1 in 'int' 'SOCKET' 'unsigned int'; do
4848
for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
4949
for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
5050
AC_COMPILE_IFELSE([AC_LANG_SOURCE(

config/c-compiler.m4

Lines changed: 27 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -273,60 +273,6 @@ AC_DEFINE(HAVE__BUILTIN_TYPES_COMPATIBLE_P, 1,
273273
fi])# PGAC_C_TYPES_COMPATIBLE
274274

275275

276-
# PGAC_C_BUILTIN_BSWAP16
277-
# -------------------------
278-
# Check if the C compiler understands __builtin_bswap16(),
279-
# and define HAVE__BUILTIN_BSWAP16 if so.
280-
AC_DEFUN([PGAC_C_BUILTIN_BSWAP16],
281-
[AC_CACHE_CHECK(for __builtin_bswap16, pgac_cv__builtin_bswap16,
282-
[AC_COMPILE_IFELSE([AC_LANG_SOURCE(
283-
[static unsigned long int x = __builtin_bswap16(0xaabb);]
284-
)],
285-
[pgac_cv__builtin_bswap16=yes],
286-
[pgac_cv__builtin_bswap16=no])])
287-
if test x"$pgac_cv__builtin_bswap16" = xyes ; then
288-
AC_DEFINE(HAVE__BUILTIN_BSWAP16, 1,
289-
[Define to 1 if your compiler understands __builtin_bswap16.])
290-
fi])# PGAC_C_BUILTIN_BSWAP16
291-
292-
293-
294-
# PGAC_C_BUILTIN_BSWAP32
295-
# -------------------------
296-
# Check if the C compiler understands __builtin_bswap32(),
297-
# and define HAVE__BUILTIN_BSWAP32 if so.
298-
AC_DEFUN([PGAC_C_BUILTIN_BSWAP32],
299-
[AC_CACHE_CHECK(for __builtin_bswap32, pgac_cv__builtin_bswap32,
300-
[AC_COMPILE_IFELSE([AC_LANG_SOURCE(
301-
[static unsigned long int x = __builtin_bswap32(0xaabbccdd);]
302-
)],
303-
[pgac_cv__builtin_bswap32=yes],
304-
[pgac_cv__builtin_bswap32=no])])
305-
if test x"$pgac_cv__builtin_bswap32" = xyes ; then
306-
AC_DEFINE(HAVE__BUILTIN_BSWAP32, 1,
307-
[Define to 1 if your compiler understands __builtin_bswap32.])
308-
fi])# PGAC_C_BUILTIN_BSWAP32
309-
310-
311-
312-
# PGAC_C_BUILTIN_BSWAP64
313-
# -------------------------
314-
# Check if the C compiler understands __builtin_bswap64(),
315-
# and define HAVE__BUILTIN_BSWAP64 if so.
316-
AC_DEFUN([PGAC_C_BUILTIN_BSWAP64],
317-
[AC_CACHE_CHECK(for __builtin_bswap64, pgac_cv__builtin_bswap64,
318-
[AC_COMPILE_IFELSE([AC_LANG_SOURCE(
319-
[static unsigned long int x = __builtin_bswap64(0xaabbccddeeff0011);]
320-
)],
321-
[pgac_cv__builtin_bswap64=yes],
322-
[pgac_cv__builtin_bswap64=no])])
323-
if test x"$pgac_cv__builtin_bswap64" = xyes ; then
324-
AC_DEFINE(HAVE__BUILTIN_BSWAP64, 1,
325-
[Define to 1 if your compiler understands __builtin_bswap64.])
326-
fi])# PGAC_C_BUILTIN_BSWAP64
327-
328-
329-
330276
# PGAC_C_BUILTIN_CONSTANT_P
331277
# -------------------------
332278
# Check if the C compiler understands __builtin_constant_p(),
@@ -423,6 +369,33 @@ fi])# PGAC_C_COMPUTED_GOTO
423369

424370

425371

372+
# PGAC_CHECK_BUILTIN_FUNC
373+
# -----------------------
374+
# This is similar to AC_CHECK_FUNCS(), except that it will work for compiler
375+
# builtin functions, as that usually fails to.
376+
# The first argument is the function name, eg [__builtin_clzl], and the
377+
# second is its argument list, eg [unsigned long x]. The current coding
378+
# works only for a single argument named x; we might generalize that later.
379+
# It's assumed that the function's result type is coercible to int.
380+
# On success, we define "HAVEfuncname" (there's usually more than enough
381+
# underscores already, so we don't add another one).
382+
AC_DEFUN([PGAC_CHECK_BUILTIN_FUNC],
383+
[AC_CACHE_CHECK(for $1, pgac_cv$1,
384+
[AC_LINK_IFELSE([AC_LANG_PROGRAM([
385+
int
386+
call$1($2)
387+
{
388+
return $1(x);
389+
}], [])],
390+
[pgac_cv$1=yes],
391+
[pgac_cv$1=no])])
392+
if test x"${pgac_cv$1}" = xyes ; then
393+
AC_DEFINE_UNQUOTED(AS_TR_CPP([HAVE$1]), 1,
394+
[Define to 1 if your compiler understands $1.])
395+
fi])# PGAC_CHECK_BUILTIN_FUNC
396+
397+
398+
426399
# PGAC_PROG_VARCC_VARFLAGS_OPT
427400
# -----------------------
428401
# Given a compiler, variable name and a string, check if the compiler

0 commit comments

Comments
 (0)