Blame m4/stdint_h.m4

Packit fc043f
# stdint_h.m4 serial 5
Packit fc043f
dnl Copyright (C) 1997-2004 Free Software Foundation, Inc.
Packit fc043f
dnl This file is free software; the Free Software Foundation
Packit fc043f
dnl gives unlimited permission to copy and/or distribute it,
Packit fc043f
dnl with or without modifications, as long as this notice is preserved.
Packit fc043f
Packit fc043f
dnl From Paul Eggert.
Packit fc043f
Packit fc043f
# Define HAVE_STDINT_H_WITH_UINTMAX if <stdint.h> exists,
Packit fc043f
# doesn't clash with <sys/types.h>, and declares uintmax_t.
Packit fc043f
Packit fc043f
AC_DEFUN([gl_AC_HEADER_STDINT_H],
Packit fc043f
[
Packit fc043f
  AC_CACHE_CHECK([for stdint.h], gl_cv_header_stdint_h,
Packit fc043f
  [AC_TRY_COMPILE(
Packit fc043f
    [#include <sys/types.h>
Packit fc043f
#include <stdint.h>],
Packit fc043f
    [uintmax_t i = (uintmax_t) -1;],
Packit fc043f
    gl_cv_header_stdint_h=yes,
Packit fc043f
    gl_cv_header_stdint_h=no)])
Packit fc043f
  if test $gl_cv_header_stdint_h = yes; then
Packit fc043f
    AC_DEFINE_UNQUOTED(HAVE_STDINT_H_WITH_UINTMAX, 1,
Packit fc043f
      [Define if <stdint.h> exists, doesn't clash with <sys/types.h>,
Packit fc043f
       and declares uintmax_t. ])
Packit fc043f
  fi
Packit fc043f
])