Blame m4/strtoumax.m4

Packit 33f14e
# strtoumax.m4 serial 12
Packit 33f14e
dnl Copyright (C) 2002-2004, 2006, 2009-2017 Free Software Foundation, Inc.
Packit 33f14e
dnl This file is free software; the Free Software Foundation
Packit 33f14e
dnl gives unlimited permission to copy and/or distribute it,
Packit 33f14e
dnl with or without modifications, as long as this notice is preserved.
Packit 33f14e
Packit 33f14e
AC_DEFUN([gl_FUNC_STRTOUMAX],
Packit 33f14e
[
Packit 33f14e
  AC_REQUIRE([gl_INTTYPES_H_DEFAULTS])
Packit 33f14e
Packit 33f14e
  dnl On OSF/1 5.1 with cc, this function is declared but not defined.
Packit 33f14e
  AC_CHECK_FUNCS_ONCE([strtoumax])
Packit 33f14e
  AC_CHECK_DECLS_ONCE([strtoumax])
Packit 33f14e
  if test "$ac_cv_have_decl_strtoumax" = yes; then
Packit 33f14e
    if test "$ac_cv_func_strtoumax" != yes; then
Packit 33f14e
      # HP-UX 11.11 has "#define strtoimax(...) ..." but no function.
Packit 33f14e
      REPLACE_STRTOUMAX=1
Packit 33f14e
    fi
Packit 33f14e
  else
Packit 33f14e
    HAVE_DECL_STRTOUMAX=0
Packit 33f14e
  fi
Packit 33f14e
])
Packit 33f14e
Packit 33f14e
# Prerequisites of lib/strtoumax.c.
Packit 33f14e
AC_DEFUN([gl_PREREQ_STRTOUMAX], [
Packit 33f14e
  AC_CHECK_DECLS([strtoull])
Packit 33f14e
  AC_REQUIRE([AC_TYPE_UNSIGNED_LONG_LONG_INT])
Packit 33f14e
])