1 | --- configure.orig 2021-10-30 10:57:55.000000000 +0200 |
---|
2 | +++ configure 2021-10-30 10:59:23.000000000 +0200 |
---|
3 | @@ -36346,9 +36346,9 @@ |
---|
4 | printf %s "(cached) " >&6 |
---|
5 | else $as_nop |
---|
6 | # Remove any remnants of a previous test. |
---|
7 | - rm -rf confdir-14B--- |
---|
8 | + rm -rf confdir--14B--- |
---|
9 | # Arrange for deletion of the temporary directory this test creates. |
---|
10 | - ac_clean_files="$ac_clean_files confdir-14B---" |
---|
11 | + ac_clean_files="$ac_clean_files confdir--14B---" |
---|
12 | if test "$cross_compiling" = yes |
---|
13 | then : |
---|
14 | case "$host_os" in |
---|
15 | @@ -36361,6 +36361,7 @@ |
---|
16 | /* end confdefs.h. */ |
---|
17 | |
---|
18 | #include <errno.h> |
---|
19 | +#include <stdio.h> |
---|
20 | #include <stdlib.h> |
---|
21 | #if HAVE_UNISTD_H |
---|
22 | # include <unistd.h> |
---|
23 | @@ -36434,9 +36435,10 @@ |
---|
24 | initial_cwd_len = strlen (cwd); |
---|
25 | free (cwd); |
---|
26 | |
---|
27 | + FILE *f = fopen ("/var/tmp/sub-dirs-records", "a+"); |
---|
28 | if (1) |
---|
29 | { |
---|
30 | - static char const dir_name[] = "confdir-14B---"; |
---|
31 | + static char const dir_name[] = "confdir--14B---"; |
---|
32 | size_t desired_depth = ((TARGET_LEN - 1 - initial_cwd_len) |
---|
33 | / sizeof dir_name); |
---|
34 | size_t d; |
---|
35 | @@ -36449,7 +36451,12 @@ |
---|
36 | fail = 3; /* Unable to construct deep hierarchy. */ |
---|
37 | break; |
---|
38 | } |
---|
39 | +/* else |
---|
40 | + { |
---|
41 | + fprintf (f, "%s on level %lu successfully built.\n", getcwd (NULL, 0), d); |
---|
42 | + }*/ |
---|
43 | } |
---|
44 | + fprintf (f, "Directory tree built! We're in %s, path name length is %lu\n", cwd = getcwd (NULL, 0), strlen(cwd)); |
---|
45 | |
---|
46 | /* If libc has the bug in question, this invocation of getcwd |
---|
47 | results in a failed assertion. */ |
---|
48 | @@ -36461,6 +36468,7 @@ |
---|
49 | |
---|
50 | /* Call rmdir first, in case the above chdir failed. */ |
---|
51 | rmdir (dir_name); |
---|
52 | + fprintf (f, "Deleting the latest sub-dir, initial_cwd_len is %lu, TARGET_LEN is %lu, dir_name has string length %lu, desired_depth is %lu.\n", initial_cwd_len, TARGET_LEN, (sizeof dir_name), desired_depth); |
---|
53 | while (0 < d--) |
---|
54 | { |
---|
55 | if (chdir ("..") < 0) |
---|
56 | @@ -36468,10 +36476,17 @@ |
---|
57 | fail = 5; |
---|
58 | break; |
---|
59 | } |
---|
60 | - rmdir (dir_name); |
---|
61 | + else |
---|
62 | + { |
---|
63 | +/* rmdir(dir_name);*/ |
---|
64 | + system("/bin/rm -rf confdir--14B---"); |
---|
65 | + perror("/bin/rm"); |
---|
66 | + system("/bin/ls -li >> ls-li-output"); |
---|
67 | + fprintf (f, "Just removed 'confdir--14B---' in %s on level %lu\n", getcwd (NULL, 0), d); |
---|
68 | + } |
---|
69 | } |
---|
70 | } |
---|
71 | - |
---|
72 | + fclose (f); |
---|
73 | return fail; |
---|
74 | } |
---|
75 | |
---|
76 | @@ -36488,6 +36503,7 @@ |
---|
77 | fi |
---|
78 | |
---|
79 | fi |
---|
80 | +mv -v conftest rm-confdir |
---|
81 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
---|
82 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
---|
83 | fi |
---|