subdirectory. That would make the subsequent AC_TRY_RUN macro fail,
for lack of the ./confdefs.h file. Instead, use the temporary
directory name as a prefix on the template string.
Include <unistd.h> for the declaration of close.
-#serial 7
+#serial 8
# On some hosts (e.g., HP-UX 10.20, SunOS 4.1.4, Solaris 2.5.1), mkstemp has a
# silly limit that it can create no more than 26 files from a given template.
gl_cv_func_mkstemp_limitations,
[
mkdir conftest.mkstemp
- ( cd conftest.mkstemp
- AC_TRY_RUN([
+ AC_TRY_RUN([
# include <stdlib.h>
+# include <unistd.h>
int main ()
{
int i;
for (i = 0; i < 70; i++)
{
- char template[] = "coXXXXXX.tmp";
+ char template[] = "conftest.mkstemp/coXXXXXX.tmp";
int fd = mkstemp (template);
if (fd == -1)
exit (1);
gl_cv_func_mkstemp_limitations=yes,
gl_cv_func_mkstemp_limitations=yes
)
- )
rm -rf conftest.mkstemp
]
)