1 diff -ruN coreutils-8.27.orig/gnulib-tests/gnulib.mk coreutils-8.27/gnulib-tests/gnulib.mk
2 --- coreutils-8.27.orig/gnulib-tests/gnulib.mk 2017-03-09 04:52:57.000000000 +0100
3 +++ coreutils-8.27/gnulib-tests/gnulib.mk 2017-06-10 20:43:44.600627260 +0200
6 ## begin gnulib module chown-tests
9 -check_PROGRAMS += test-chown
10 -test_chown_LDADD = $(LDADD) $(NANOSLEEP_LIB)
12 +#check_PROGRAMS += test-chown
13 +#test_chown_LDADD = $(LDADD) $(NANOSLEEP_LIB)
14 EXTRA_DIST += nap.h test-chown.h test-chown.c signature.h macros.h
16 ## end gnulib module chown-tests
19 ## begin gnulib module fchownat-tests
21 -TESTS += test-fchownat
22 -check_PROGRAMS += test-fchownat
23 -test_fchownat_LDADD = $(LDADD) $(NANOSLEEP_LIB) @LIBINTL@
24 +#TESTS += test-fchownat
25 +#check_PROGRAMS += test-fchownat
26 +#test_fchownat_LDADD = $(LDADD) $(NANOSLEEP_LIB) @LIBINTL@
27 EXTRA_DIST += nap.h test-chown.h test-lchown.h test-fchownat.c signature.h macros.h
29 ## end gnulib module fchownat-tests
32 ## begin gnulib module fdutimensat-tests
34 -TESTS += test-fdutimensat
35 -check_PROGRAMS += test-fdutimensat
36 -test_fdutimensat_LDADD = $(LDADD) $(CLOCK_TIME_LIB) \
37 - $(NANOSLEEP_LIB) @LIBINTL@
38 +#TESTS += test-fdutimensat
39 +#check_PROGRAMS += test-fdutimensat
40 +#test_fdutimensat_LDADD = $(LDADD) $(CLOCK_TIME_LIB) \
41 +# $(NANOSLEEP_LIB) @LIBINTL@
42 EXTRA_DIST += nap.h test-futimens.h test-lutimens.h test-utimens.h test-utimens-common.h test-fdutimensat.c macros.h
44 ## end gnulib module fdutimensat-tests
47 ## begin gnulib module futimens-tests
49 -TESTS += test-futimens
50 -check_PROGRAMS += test-futimens
51 -test_futimens_LDADD = $(LDADD) $(CLOCK_TIME_LIB) $(NANOSLEEP_LIB) @LIBINTL@
52 +#TESTS += test-futimens
53 +#check_PROGRAMS += test-futimens
54 +#test_futimens_LDADD = $(LDADD) $(CLOCK_TIME_LIB) $(NANOSLEEP_LIB) @LIBINTL@
55 EXTRA_DIST += nap.h test-futimens.h test-utimens-common.h test-futimens.c signature.h macros.h
57 ## end gnulib module futimens-tests
60 ## begin gnulib module lchown-tests
63 -check_PROGRAMS += test-lchown
64 -test_lchown_LDADD = $(LDADD) $(NANOSLEEP_LIB)
65 +#TESTS += test-lchown
66 +#check_PROGRAMS += test-lchown
67 +#test_lchown_LDADD = $(LDADD) $(NANOSLEEP_LIB)
68 EXTRA_DIST += nap.h test-lchown.h test-lchown.c signature.h macros.h
70 ## end gnulib module lchown-tests
73 ## begin gnulib module utimens-tests
75 -TESTS += test-utimens
76 -check_PROGRAMS += test-utimens
77 -test_utimens_LDADD = $(LDADD) $(CLOCK_TIME_LIB) $(NANOSLEEP_LIB) @LIBINTL@
78 +#TESTS += test-utimens
79 +#check_PROGRAMS += test-utimens
80 +#test_utimens_LDADD = $(LDADD) $(CLOCK_TIME_LIB) $(NANOSLEEP_LIB) @LIBINTL@
81 EXTRA_DIST += nap.h test-futimens.h test-lutimens.h test-utimens.h test-utimens-common.h test-utimens.c macros.h
83 ## end gnulib module utimens-tests
84 diff -ruN coreutils-8.27.orig/gnulib-tests/test-stat-time.c coreutils-8.27/gnulib-tests/test-stat-time.c
85 --- coreutils-8.27.orig/gnulib-tests/test-stat-time.c 2017-01-01 23:35:38.000000000 +0100
86 +++ coreutils-8.27/gnulib-tests/test-stat-time.c 2017-06-10 20:43:44.599627263 +0200
87 @@ -167,7 +167,7 @@ test_mtime (const struct stat *statinfo,
91 -#if defined _WIN32 && !defined __CYGWIN__
93 /* Skip the ctime tests on native Windows platforms, because their
94 st_ctime is either the same as st_mtime (plus or minus an offset)
95 or set to the file _creation_ time, and is not influenced by rename
96 diff -ruN coreutils-8.27.orig/gnulib-tests/test-utimens-common.h coreutils-8.27/gnulib-tests/test-utimens-common.h
97 --- coreutils-8.27.orig/gnulib-tests/test-utimens-common.h 2017-01-01 23:35:38.000000000 +0100
98 +++ coreutils-8.27/gnulib-tests/test-utimens-common.h 2017-06-10 20:43:44.598627265 +0200
99 @@ -49,7 +49,7 @@ enum {
103 -# if defined _WIN32 && !defined __CYGWIN__
105 /* Skip ctime tests on native Windows, since it is either a copy of
106 mtime or birth time (depending on the file system), rather than a
107 properly tracked change time. See
108 diff -ruN coreutils-8.27.orig/tests/local.mk coreutils-8.27/tests/local.mk
109 --- coreutils-8.27.orig/tests/local.mk 2017-03-01 05:25:37.000000000 +0100
110 +++ coreutils-8.27/tests/local.mk 2017-06-10 20:43:44.601627257 +0200
113 tests/cp/link-heap.sh \
115 - tests/misc/tty-eof.pl \
116 tests/tail-2/inotify-hash-abuse.sh \
117 tests/tail-2/inotify-hash-abuse2.sh \
118 tests/tail-2/F-vs-missing.sh \
120 tests/misc/sort-unique-segv.sh \
121 tests/misc/sort-version.sh \
122 tests/misc/sort-NaN-infloop.sh \
123 - tests/misc/sort-u-FMR.sh \
124 tests/split/filter.sh \
125 tests/split/suffix-auto-length.sh \
126 tests/split/suffix-length.sh \
128 tests/df/unreadable.sh \
129 tests/df/total-unprocessed.sh \
130 tests/df/no-mtab-status.sh \
131 - tests/df/skip-duplicates.sh \
132 tests/df/skip-rootfs.sh \
135 diff -ruN coreutils-8.27.orig/tests/misc/nohup.sh coreutils-8.27/tests/misc/nohup.sh
136 --- coreutils-8.27.orig/tests/misc/nohup.sh 2017-01-01 23:34:24.000000000 +0100
137 +++ coreutils-8.27/tests/misc/nohup.sh 2017-06-10 20:44:45.353459732 +0200
140 # Bug present through coreutils 8.0: failure to print advisory message
141 # to stderr must be fatal. Requires stdout to be terminal.
142 -if test -w /dev/full && test -c /dev/full; then
144 - # POSIX shells immediately exit the subshell on exec error.
145 - # So check we can write to /dev/tty before the exec, which
146 - # isn't possible if we've no controlling tty for example.
147 - test -c /dev/tty && >/dev/tty || exit 0
150 - test -t 1 || exit 0
151 - returns_ 125 nohup echo hi 2> /dev/full || fail=1
152 - test -f nohup.out || fail=1
153 - compare /dev/null nohup.out || fail=1
158 +#if test -w /dev/full && test -c /dev/full; then
160 +# # POSIX shells immediately exit the subshell on exec error.
161 +# # So check we can write to /dev/tty before the exec, which
162 +# # isn't possible if we've no controlling tty for example.
163 +# test -c /dev/tty && >/dev/tty || exit 0
166 +# test -t 1 || exit 0
167 +# returns_ 125 nohup echo hi 2> /dev/full || fail=1
168 +# test -f nohup.out || fail=1
169 +# compare /dev/null nohup.out || fail=1
175 nohup no-such-command 2> err
177 diff -ruN coreutils-8.27.orig/tests/misc/printenv.sh coreutils-8.27/tests/misc/printenv.sh
178 --- coreutils-8.27.orig/tests/misc/printenv.sh 2017-01-01 23:34:24.000000000 +0100
179 +++ coreutils-8.27/tests/misc/printenv.sh 2017-06-10 20:43:44.597627268 +0200
181 # env's output the same way as that of printenv and works around a bug
182 # on aarch64 at least where libc's execvp reverses the order of the
184 -env -- env | grep -Ev '^(_|LD_PRELOAD)=' > exp || framework_failure_
185 -env -- printenv | grep -Ev '^(_|LD_PRELOAD)=' > out || fail=1
186 +env -- env | grep -Ev '^(_|LD_PRELOAD|RANDOM=)=' > exp || framework_failure_
187 +env -- printenv | grep -Ev '^(_|LD_PRELOAD|RANDOM=)=' > out || fail=1
188 compare exp out || fail=1
190 # POSIX is clear that environ may, but need not be, sorted.
191 diff -ruN coreutils-8.27.orig/tests/misc/realpath.sh coreutils-8.27/tests/misc/realpath.sh
192 --- coreutils-8.27.orig/tests/misc/realpath.sh 2017-01-01 23:34:24.000000000 +0100
193 +++ coreutils-8.27/tests/misc/realpath.sh 2017-06-10 20:43:44.597627268 +0200
195 ln -s /// three || framework_failure_
198 -realpath -Pqz . >/dev/null || fail=1
199 +$initial_cwd_/src/realpath -Pqz . >/dev/null || fail=1
200 # Operand is required
201 -returns_ 1 realpath >/dev/null || fail=1
202 -returns_ 1 realpath --relative-base . --relative-to . || fail=1
203 -returns_ 1 realpath --relative-base . || fail=1
204 +returns_ 1 $initial_cwd_/src/realpath >/dev/null || fail=1
205 +returns_ 1 $initial_cwd_/src/realpath --relative-base . --relative-to . || fail=1
206 +returns_ 1 $initial_cwd_/src/realpath --relative-base . || fail=1
208 # -e --relative-* require directories
209 -returns_ 1 realpath -e --relative-to=dir1/f --relative-base=. . || fail=1
210 -realpath -e --relative-to=dir1/ --relative-base=. . || fail=1
211 +returns_ 1 $initial_cwd_/src/realpath -e --relative-to=dir1/f --relative-base=. . || fail=1
212 +$initial_cwd_/src/realpath -e --relative-to=dir1/ --relative-base=. . || fail=1
214 # Note NUL params are unconditionally rejected by canonicalize_filename_mode
215 -returns_ 1 realpath -m '' || fail=1
216 -returns_ 1 realpath --relative-base= --relative-to=. . || fail=1
217 +returns_ 1 $initial_cwd_/src/realpath -m '' || fail=1
218 +returns_ 1 $initial_cwd_/src/realpath --relative-base= --relative-to=. . || fail=1
222 -test "$(realpath ldir2/..)" = "$this/dir1" || fail=1
223 -test "$(realpath -L ldir2/..)" = "$this" || fail=1
224 -test "$(realpath -s ldir2)" = "$this/ldir2" || fail=1
225 +this=$($initial_cwd_/src/realpath .)
226 +test "$($initial_cwd_/src/realpath ldir2/..)" = "$this/dir1" || fail=1
227 +test "$($initial_cwd_/src/realpath -L ldir2/..)" = "$this" || fail=1
228 +test "$($initial_cwd_/src/realpath -s ldir2)" = "$this/ldir2" || fail=1
230 # relative string handling
231 -test $(realpath -m --relative-to=prefix prefixed/1) = '../prefixed/1' || fail=1
232 -test $(realpath -m --relative-to=prefixed prefix/1) = '../prefix/1' || fail=1
233 -test $(realpath -m --relative-to=prefixed prefixed/1) = '1' || fail=1
234 +test $($initial_cwd_/src/realpath -m --relative-to=prefix prefixed/1) = '../prefixed/1' || fail=1
235 +test $($initial_cwd_/src/realpath -m --relative-to=prefixed prefix/1) = '../prefix/1' || fail=1
236 +test $($initial_cwd_/src/realpath -m --relative-to=prefixed prefixed/1) = '1' || fail=1
238 # Ensure no redundant trailing '/' present, as was the case in v8.15
239 -test $(realpath -sm --relative-to=/usr /) = '..' || fail=1
240 +test $($initial_cwd_/src/realpath -sm --relative-to=/usr /) = '..' || fail=1
241 # Ensure no redundant leading '../' present, as was the case in v8.15
242 -test $(realpath -sm --relative-to=/ /usr) = 'usr' || fail=1
243 +test $($initial_cwd_/src/realpath -sm --relative-to=/ /usr) = 'usr' || fail=1
245 # Ensure --relative-base works
246 -out=$(realpath -sm --relative-base=/usr --relative-to=/usr /tmp /usr) || fail=1
247 +out=$($initial_cwd_/src/realpath -sm --relative-base=/usr --relative-to=/usr /tmp /usr) || fail=1
248 test "$out" = "/tmp$nl." || fail=1
249 -out=$(realpath -sm --relative-base=/ --relative-to=/ / /usr) || fail=1
250 +out=$($initial_cwd_/src/realpath -sm --relative-base=/ --relative-to=/ / /usr) || fail=1
251 test "$out" = ".${nl}usr" || fail=1
252 # --relative-to defaults to the value of --relative-base
253 -out=$(realpath -sm --relative-base=/usr /tmp /usr) || fail=1
254 +out=$($initial_cwd_/src/realpath -sm --relative-base=/usr /tmp /usr) || fail=1
255 test "$out" = "/tmp$nl." || fail=1
256 -out=$(realpath -sm --relative-base=/ / /usr) || fail=1
257 +out=$($initial_cwd_/src/realpath -sm --relative-base=/ / /usr) || fail=1
258 test "$out" = ".${nl}usr" || fail=1
259 # For now, --relative-base must be a prefix of --relative-to, or all output
260 # will be absolute (compare to MacOS 'relpath -d dir start end').
261 -out=$(realpath -sm --relative-base=/usr/local --relative-to=/usr \
262 +out=$($initial_cwd_/src/realpath -sm --relative-base=/usr/local --relative-to=/usr \
263 /usr /usr/local) || fail=1
264 test "$out" = "/usr${nl}/usr/local" || fail=1
266 # Ensure // is handled correctly.
267 -test "$(realpath / // ///)" = "/$nl$double_slash$nl/" || fail=1
268 -test "$(realpath one two three)" = "/$nl$double_slash$nl/" || fail=1
269 -out=$(realpath -sm --relative-to=/ / // /dev //dev) || fail=1
270 +test "$($initial_cwd_/src/realpath / // ///)" = "/$nl$double_slash$nl/" || fail=1
271 +test "$($initial_cwd_/src/realpath one two three)" = "/$nl$double_slash$nl/" || fail=1
272 +out=$($initial_cwd_/src/realpath -sm --relative-to=/ / // /dev //dev) || fail=1
273 if test $double_slash = //; then
274 test "$out" = ".$nl//${nl}dev$nl//dev" || fail=1
276 test "$out" = ".$nl.${nl}dev${nl}dev" || fail=1
278 -out=$(realpath -sm --relative-to=// / // /dev //dev) || fail=1
279 +out=$($initial_cwd_/src/realpath -sm --relative-to=// / // /dev //dev) || fail=1
280 if test $double_slash = //; then
281 test "$out" = "/$nl.$nl/dev${nl}dev" || fail=1
283 test "$out" = ".$nl.${nl}dev${nl}dev" || fail=1
285 -out=$(realpath --relative-base=/ --relative-to=// / //) || fail=1
286 +out=$($initial_cwd_/src/realpath --relative-base=/ --relative-to=// / //) || fail=1
287 if test $double_slash = //; then
288 test "$out" = "/$nl//" || fail=1