summaryrefslogtreecommitdiff
path: root/m4/jm-macros.m4
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2001-03-02 03:14:31 +0000
committerJim Meyering <jim@meyering.net>2001-03-02 03:14:31 +0000
commit68de994bf16d4fc2271e7a19c25241a368798fd8 (patch)
treefa92c10eea199ba0bb00b0683ef086aadaa95278 /m4/jm-macros.m4
parentb11665966d16f8424a42a6dc50872d7fa3b69d76 (diff)
downloadcoreutils-68de994bf16d4fc2271e7a19c25241a368798fd8.tar.xz
(jm_MACROS): Use mkstemp replacement if the system
lacks mkstemp. Compile our own tempname.c if we compile our own mkstemp.c, as mkstemp relies on tempname.
Diffstat (limited to 'm4/jm-macros.m4')
-rw-r--r--m4/jm-macros.m47
1 files changed, 6 insertions, 1 deletions
diff --git a/m4/jm-macros.m4 b/m4/jm-macros.m4
index 208a8723d..8ce920c23 100644
--- a/m4/jm-macros.m4
+++ b/m4/jm-macros.m4
@@ -1,4 +1,4 @@
-#serial 33 -*- autoconf -*-
+#serial 34 -*- autoconf -*-
dnl Misc type-related macros for fileutils, sh-utils, textutils.
@@ -83,6 +83,11 @@ AC_DEFUN(jm_MACROS,
AC_REPLACE_FUNCS(memchr memcpy memmove memrchr memset)
AC_CHECK_FUNCS(getpagesize)
+ AC_REPLACE_FUNCS(mkstemp)
+ if test $ac_cv_func_mkstemp != yes; then
+ AC_LIBOBJ(tempname)
+ fi
+
# By default, argmatch should fail calling usage (1).
AC_DEFINE(ARGMATCH_DIE, [usage (1)],
[Define to the function xargmatch calls on failures.])