+2011-09-01 Bruno Haible <bruno@clisp.org>
+
+ strtoimax: Avoid link error on OSF/1 with DTK cc.
+ * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Always test whether strtoimax is
+ defined as a function.
+ * modules/strtoimax (Depends-on, configure.ac): Test only whether
+ strtoimax is defined, not whether it is declared.
+
2011-09-01 Bruno Haible <bruno@clisp.org>
imaxdiv: Avoid link error on OSF/1 with DTK cc.
-# strtoimax.m4 serial 10
+# strtoimax.m4 serial 11
dnl Copyright (C) 2002-2004, 2006, 2009-2011 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
[
AC_REQUIRE([gl_INTTYPES_H_DEFAULTS])
+ dnl On OSF/1 5.1 with cc, this function is declared but not defined.
+ AC_CHECK_FUNCS_ONCE([strtoimax])
AC_CHECK_DECLS_ONCE([strtoimax])
if test "$ac_cv_have_decl_strtoimax" != yes; then
HAVE_DECL_STRTOIMAX=0
-
- AC_CHECK_FUNCS([strtoimax])
fi
])
Depends-on:
inttypes-incomplete
-verify [test "$ac_cv_have_decl_strtoimax" != yes && test $ac_cv_func_strtoimax = no]
-stdint [test "$ac_cv_have_decl_strtoimax" != yes && test $ac_cv_func_strtoimax = no]
-strtoll [test "$ac_cv_have_decl_strtoimax" != yes && test $ac_cv_func_strtoimax = no && test $ac_cv_type_long_long_int = yes]
+verify [test $ac_cv_func_strtoimax = no]
+stdint [test $ac_cv_func_strtoimax = no]
+strtoll [test $ac_cv_func_strtoimax = no && test $ac_cv_type_long_long_int = yes]
configure.ac:
gl_FUNC_STRTOIMAX
-if test "$ac_cv_have_decl_strtoimax" != yes && test $ac_cv_func_strtoimax = no; then
+if test $ac_cv_func_strtoimax = no; then
AC_LIBOBJ([strtoimax])
gl_PREREQ_STRTOIMAX
fi