annotate m4/imaxdiv.m4 @ 40057:b06060465f09

maint: Run 'make update-copyright'
author Paul Eggert <eggert@cs.ucla.edu>
date Tue, 01 Jan 2019 00:25:11 +0100
parents a1cf139454dc
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
19663
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
1 # imaxdiv.m4 serial 5
40057
b06060465f09 maint: Run 'make update-copyright'
Paul Eggert <eggert@cs.ucla.edu>
parents: 19663
diff changeset
2 dnl Copyright (C) 2006, 2009-2019 Free Software Foundation, Inc.
7206
4e6b2be7a129 New module 'imaxdiv'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
3 dnl This file is free software; the Free Software Foundation
4e6b2be7a129 New module 'imaxdiv'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
4 dnl gives unlimited permission to copy and/or distribute it,
4e6b2be7a129 New module 'imaxdiv'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
5 dnl with or without modifications, as long as this notice is preserved.
4e6b2be7a129 New module 'imaxdiv'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
6
4e6b2be7a129 New module 'imaxdiv'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
7 AC_DEFUN([gl_FUNC_IMAXDIV],
4e6b2be7a129 New module 'imaxdiv'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
8 [
14606
9b89f648856f inttypes: Move some configure check to module 'imaxdiv'.
Paul Eggert <eggert@cs.ucla.edu>
parents: 14079
diff changeset
9 AC_REQUIRE([gl_INTTYPES_H_DEFAULTS])
15555
caabcfbb39a5 imaxdiv: Avoid link error on OSF/1 with DTK cc.
Bruno Haible <bruno@clisp.org>
parents: 14986
diff changeset
10
caabcfbb39a5 imaxdiv: Avoid link error on OSF/1 with DTK cc.
Bruno Haible <bruno@clisp.org>
parents: 14986
diff changeset
11 dnl On OSF/1 5.1 with cc, this function is declared but not defined.
caabcfbb39a5 imaxdiv: Avoid link error on OSF/1 with DTK cc.
Bruno Haible <bruno@clisp.org>
parents: 14986
diff changeset
12 AC_CHECK_FUNCS_ONCE([imaxdiv])
14606
9b89f648856f inttypes: Move some configure check to module 'imaxdiv'.
Paul Eggert <eggert@cs.ucla.edu>
parents: 14079
diff changeset
13 AC_CHECK_DECLS_ONCE([imaxdiv])
7206
4e6b2be7a129 New module 'imaxdiv'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
14 if test "$ac_cv_have_decl_imaxdiv" != yes; then
14606
9b89f648856f inttypes: Move some configure check to module 'imaxdiv'.
Paul Eggert <eggert@cs.ucla.edu>
parents: 14079
diff changeset
15 HAVE_DECL_IMAXDIV=0
7206
4e6b2be7a129 New module 'imaxdiv'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
16 fi
19663
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
17
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
18 AC_CACHE_CHECK([whether <inttypes.h> defines imaxdiv_t],
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
19 [gl_cv_type_imaxdiv_t],
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
20 [dnl Assume that if imaxdiv is declared, imaxdiv_t is defined.
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
21 if test $ac_cv_have_decl_imaxdiv = yes; then
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
22 gl_cv_type_imaxdiv_t=yes
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
23 else
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
24 AC_COMPILE_IFELSE(
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
25 [AC_LANG_PROGRAM(
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
26 [[#include <inttypes.h>
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
27 imaxdiv_t x;
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
28 ]])
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
29 ],
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
30 [gl_cv_type_imaxdiv_t=yes],
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
31 [gl_cv_type_imaxdiv_t=no])
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
32 fi
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
33 ])
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
34 if test $gl_cv_type_imaxdiv_t = no; then
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
35 HAVE_IMAXDIV_T=0
a1cf139454dc imaxdiv: Fix compilation error on Android.
Bruno Haible <bruno@clisp.org>
parents: 19484
diff changeset
36 fi
7206
4e6b2be7a129 New module 'imaxdiv'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
37 ])
4e6b2be7a129 New module 'imaxdiv'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
38
4e6b2be7a129 New module 'imaxdiv'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
39 # Prerequisites of lib/imaxdiv.c.
4e6b2be7a129 New module 'imaxdiv'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
40 AC_DEFUN([gl_PREREQ_IMAXDIV], [:])