summaryrefslogtreecommitdiff
path: root/binutils/configure.in
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2006-10-13 09:43:29 +0000
committerNick Clifton <nickc@redhat.com>2006-10-13 09:43:29 +0000
commitf9c026a85b129328be8ed9ce74f19fc0065454be (patch)
tree399caa063a9877ae0a03737895cb45214ca6a9d2 /binutils/configure.in
parentec6e49f44cf16f200634edd04c6e55ab0e2436b0 (diff)
downloadbinutils-gdb-f9c026a85b129328be8ed9ce74f19fc0065454be.tar.gz
PR binutils/2876
* configure.in: Check for the mkstemp and mkdtemp functions. * configure: Regenerate. * config.in (HAVE_MKDTEMP): New potential define. (MAKE_MKSTEMP): Likewise. * bucomm.c (make_tempname): Use mkstemp if it is available. * make_tempdir): New function: Create a temporary directory using mkdtemp, if it is available. * bucomm.h (make_tempdir): New prototype. * objcopy.c (copy_archive): Use make_tempdir if it is available. (strip_main): Produce an warning message if a temporary file could not be (copy_main): Likewise. * ar.c (write_archive): Likewise.
Diffstat (limited to 'binutils/configure.in')
-rw-r--r--binutils/configure.in6
1 files changed, 6 insertions, 0 deletions
diff --git a/binutils/configure.in b/binutils/configure.in
index c5bf6571fdb..7b63f4dccc9 100644
--- a/binutils/configure.in
+++ b/binutils/configure.in
@@ -84,6 +84,12 @@ AC_CHECK_HEADERS(string.h strings.h stdlib.h unistd.h fcntl.h sys/file.h)
AC_HEADER_SYS_WAIT
AC_FUNC_ALLOCA
AC_CHECK_FUNCS(sbrk utimes setmode getc_unlocked strcoll)
+AC_CHECK_FUNC([mkstemp],
+ AC_DEFINE([HAVE_MKSTEMP], 1,
+ [Define to 1 if you have the `mkstemp' function.]))
+AC_CHECK_FUNC([mkdtemp],
+ AC_DEFINE([HAVE_MKDTEMP], 1,
+ [Define to 1 if you have the `mkdtemp' function.]))
# Check whether fopen64 is available and whether _LARGEFILE64_SOURCE
# needs to be defined for it