Ross Burton (pkg-config patch)
Roland Stigge (bug fix: allow fail inside setup)
Torok Edwin (strsignal and build fixes)
- Roland Illig (portability fixes for varargs calls)
+ Roland Illig (varargs and strsignal portability fixes)
Anybody who has contributed code to Check or Check's build system is
considered an author. Send patches to this file to
AC_FUNC_STRFTIME
AC_FUNC_VPRINTF
AC_CHECK_FUNCS([alarm gettimeofday localtime_r memmove memset putenv setenv strdup strerror strrchr strstr])
+AC_REPLACE_FUNCS([strsignal])
# Output files
AC_CONFIG_HEADERS([config.h])
#endif
#undef malloc
#undef realloc
+#undef strsignal
#include <sys/types.h>
void *malloc (size_t n);
void *realloc (void *p, size_t n);
+char *strsignal(int sig);
void *rpl_malloc (size_t n);
void *rpl_realloc (void *p, size_t n);
+static const char *rpl_strsignal(int sig);
/* Allocate an N-byte block of memory from the heap. If N is zero,
allocate a 1-byte block. */
return realloc (p, n);
}
+/* We simply don't have strsignal on some platforms. This function
+ should get used if AC_REPLACE_FUNCS([strsignal]) cannot find
+ something acceptable. Note that Gnulib has a much much much more
+ advanced version of strsignal, but we don't really care.
+*/
+static const char *
+rpl_strsignal (int sig)
+{
+ static char signame[40];
+
+ sprintf(signame, "SIG #%d", sig);
+ return signame;
+}
+
Suite *suite_create (const char *name)
{
Suite *s;