From edfe9ef32b7ff6655564d822e611ca1fd9db4783 Mon Sep 17 00:00:00 2001 From: arai Date: Sat, 6 Jul 2002 08:55:43 +0000 Subject: [PATCH] * configure.ac: AC_REPLACE_FUNCS(vsnprintf). * config.h.in: ditto. * src/lha.h: ditto. git-svn-id: svn+ssh://svn.sourceforge.jp/svnroot/lha/lha/trunk@287 6a8cc165-1e22-0410-a132-eb4e3f353aba --- config.h.in | 3 +++ configure.ac | 1 + src/lha.h | 6 ++++++ 3 files changed, 10 insertions(+) diff --git a/config.h.in b/config.h.in index d41ebae..e5ca81b 100644 --- a/config.h.in +++ b/config.h.in @@ -167,6 +167,9 @@ /* Define to 1 if you have the header file. */ #undef HAVE_VFORK_H +/* Define to 1 if you have the `vsnprintf' function. */ +#undef HAVE_VSNPRINTF + /* Define to 1 if `fork' works. */ #undef HAVE_WORKING_FORK diff --git a/configure.ac b/configure.ac index 952b907..6995428 100644 --- a/configure.ac +++ b/configure.ac @@ -59,6 +59,7 @@ AC_CHECK_FUNCS(strchr strdup memcpy memset memmove strcasecmp) AC_CHECK_FUNCS(mktime timelocal tzset ftime gettimeofday utime) AC_CHECK_FUNCS(mkdir rmdir ftruncate lchown mkstemp link) AC_CHECK_FUNCS(getpwuid getgrgid getpwnam getgrnam) +AC_REPLACE_FUNCS(vsnprintf) if test $ac_header_dirent = no; then AC_LIBOBJ(lhdir) diff --git a/src/lha.h b/src/lha.h index ff04a6c..05980c4 100644 --- a/src/lha.h +++ b/src/lha.h @@ -347,6 +347,12 @@ char *xstrrchr(const char *s, int c); char *xmemchr(const char *s, int c, size_t n); char *xmemrchr(const char *s, int c, size_t n); +/* from vsnprintf.c */ +#if !HAVE_VSNPRINTF +int vsnprintf(char *str, size_t n, const char *fmt, va_list ap); +int snprintf(char *str, size_t n, char const *fmt, ...); +#endif + /* Local Variables: */ /* mode:c */ /* tab-width:4 */ -- 2.11.0