summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2015-03-23 22:16:28 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2015-03-23 22:16:28 (GMT)
commit61b5fa8e2d69ce651ba4dd4757350be347c660a6 (patch)
tree68d90395fc95c994acc4f81f5618494a1c5475d3 /configure.ac
parentb424ce1b3f357b50cea356a00d61c46d67345926 (diff)
downloadhdf5-61b5fa8e2d69ce651ba4dd4757350be347c660a6.zip
hdf5-61b5fa8e2d69ce651ba4dd4757350be347c660a6.tar.gz
hdf5-61b5fa8e2d69ce651ba4dd4757350be347c660a6.tar.bz2
[svn-r26551] Description:
Remove the VSNPRINTF_WORKS macro, it's working around bugs in old SGI & HP compilers. Tested on: MacOSX/64 10.10.2 (amazon) w/serial & parallel (h5committest not required on this branch)
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac54
1 files changed, 1 insertions, 53 deletions
diff --git a/configure.ac b/configure.ac
index 1c6c6bb..4222c62 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1727,59 +1727,7 @@ AC_CHECK_FUNCS([gethostname getpwuid getrusage gettimeofday])
AC_CHECK_FUNCS([lstat rand_r random setsysinfo])
AC_CHECK_FUNCS([signal longjmp setjmp siglongjmp sigsetjmp sigprocmask])
AC_CHECK_FUNCS([snprintf srandom strdup symlink system])
-AC_CHECK_FUNCS([tmpfile asprintf vasprintf waitpid])
-
-## Check for vsnprintf() separately, so we can detect situations where it
-## doesn't return the correct size for formatted strings that are too large
-## for the buffer provided
-AC_CHECK_FUNCS([vsnprintf],
-
- ## Check if vsnprintf() returns correct size for strings that don't fit
- ## into the size allowed. If vsnprintf() works correctly on this platform,
- ## it should return a value of 42 for the test below
- ##
- ## Note that vsnprintf fails in two different ways:
- ## - In IRIX64, calls to vnsprintf() with a formatted string that
- ## is larger than the buffer size allowed incorrectly
- ## return the size of the buffer minus one.
- ## - In HP/UX, calls to vsnprintf() with a formatted string that
- ## is larger than the buffer size allowed incorrectly
- ## return (-1)
- AC_MSG_CHECKING([if vsnprintf returns correct value])
-
- AC_CACHE_VAL([hdf5_cv_vsnprintf_works],
- AC_TRY_RUN([
-#include <stdio.h>
-#include <stdlib.h>
-#include <stdarg.h>
-
-int test_vsnprintf(const char *fmt,...)
-{
- va_list ap;
- char *s = malloc(16);
- int ret;
-
- va_start(ap, fmt);
- ret=vsnprintf(s,16,"%s",ap);
- va_end(ap);
-
- return(ret!=42 ? 1 : 0);
-}
-
-int main(void)
-{
- exit(test_vsnprintf("%s","A string that is longer than 16 characters"));
-}
- ],[hdf5_cv_vsnprintf_works=yes],[hdf5_cv_vsnprintf_works=no],))
-
- if test ${hdf5_cv_vsnprintf_works} = "yes"; then
- AC_MSG_RESULT([yes])
- AC_DEFINE([VSNPRINTF_WORKS], [1],
- [Define if vsnprintf() returns the correct value for formatted strings that don't fit into size allowed])
- else
- AC_MSG_RESULT([no])
- fi
- ,)
+AC_CHECK_FUNCS([tmpfile asprintf vasprintf vsnprintf waitpid])
## ----------------------------------------------------------------------
## Check that a lone colon can be used as an argument