More upstream patches to track test failure.
Also enable LTO since it should be behaving better now.
This commit is contained in:
parent
5598d785aa
commit
0727ae206e
@ -1,7 +1,7 @@
|
|||||||
From 5dc844e5b481b32915d38a9e5dd32bef3e698957 Mon Sep 17 00:00:00 2001
|
From 5dc844e5b481b32915d38a9e5dd32bef3e698957 Mon Sep 17 00:00:00 2001
|
||||||
From: "Richard W.M. Jones" <rjones@redhat.com>
|
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||||||
Date: Fri, 31 Jul 2020 08:51:37 +0100
|
Date: Fri, 31 Jul 2020 08:51:37 +0100
|
||||||
Subject: [PATCH] tests/test-nozero.sh: Add set -x.
|
Subject: [PATCH 1/2] tests/test-nozero.sh: Add set -x.
|
||||||
|
|
||||||
Used to track down a failure in this test which only happens in Koji.
|
Used to track down a failure in this test which only happens in Koji.
|
||||||
---
|
---
|
||||||
|
@ -0,0 +1,53 @@
|
|||||||
|
From 89a36b1fab8302ddc370695d386a28a03a74eae7 Mon Sep 17 00:00:00 2001
|
||||||
|
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||||||
|
Date: Sat, 1 Aug 2020 08:46:53 +0100
|
||||||
|
Subject: [PATCH 2/2] tests/test-nozero.sh: Create test file as single extent,
|
||||||
|
add debugging.
|
||||||
|
|
||||||
|
Previously the test file was created by repeatedly appending, ie:
|
||||||
|
|
||||||
|
$ rm file; for f in {0..1023}; do printf '%1024s' . >> file; done ; stat -c "%b %B" file
|
||||||
|
3968 512
|
||||||
|
|
||||||
|
This seems to create files which have more than one extent. I have
|
||||||
|
changed it to the simpler form:
|
||||||
|
|
||||||
|
$ rm file; for f in {0..1023}; do printf '%1024s' .; done > file; stat -c "%b %B" file
|
||||||
|
2048 512
|
||||||
|
|
||||||
|
Also this commit adds debugging.
|
||||||
|
---
|
||||||
|
tests/test-nozero.sh | 12 ++++++++++--
|
||||||
|
1 file changed, 10 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/tests/test-nozero.sh b/tests/test-nozero.sh
|
||||||
|
index 9a815814..f1bb8a38 100755
|
||||||
|
--- a/tests/test-nozero.sh
|
||||||
|
+++ b/tests/test-nozero.sh
|
||||||
|
@@ -71,13 +71,21 @@ cleanup ()
|
||||||
|
}
|
||||||
|
cleanup_fn cleanup
|
||||||
|
|
||||||
|
-# Prep images, and check that zero with trim results in a sparse image.
|
||||||
|
-for f in {0..1023}; do printf '%1024s' . >> nozero1.img; done
|
||||||
|
+# Prep images.
|
||||||
|
+for f in {0..1023}; do printf '%1024s' . ; done > nozero1.img
|
||||||
|
cp nozero1.img nozero2.img
|
||||||
|
cp nozero1.img nozero3.img
|
||||||
|
cp nozero1.img nozero4.img
|
||||||
|
cp nozero1.img nozero5.img
|
||||||
|
cp nozero1.img nozero6.img
|
||||||
|
+
|
||||||
|
+# Debug number of blocks and block size in the images.
|
||||||
|
+for f in {1..6}; do
|
||||||
|
+ stat -c "%n: %b allocated blocks of size %B bytes, total size %s" \
|
||||||
|
+ nozero$f.img
|
||||||
|
+done
|
||||||
|
+
|
||||||
|
+# Check that zero with trim results in a sparse image.
|
||||||
|
requires nbdkit -U - --filter=log file logfile=nozero1.log nozero1.img \
|
||||||
|
--run 'nbdsh -u "$uri" -c "h.zero (1024*1024, 0)"'
|
||||||
|
if test "$(stat -c %b nozero1.img)" = "$(stat -c %b nozero2.img)"; then
|
||||||
|
--
|
||||||
|
2.28.0.rc2
|
||||||
|
|
12
nbdkit.spec
12
nbdkit.spec
@ -45,7 +45,7 @@ ExclusiveArch: x86_64
|
|||||||
|
|
||||||
Name: nbdkit
|
Name: nbdkit
|
||||||
Version: 1.21.20
|
Version: 1.21.20
|
||||||
Release: 4%{?dist}
|
Release: 5%{?dist}
|
||||||
Summary: NBD server
|
Summary: NBD server
|
||||||
|
|
||||||
License: BSD
|
License: BSD
|
||||||
@ -60,6 +60,7 @@ Source2: libguestfs.keyring
|
|||||||
|
|
||||||
# Upsream patch to try to track down test failure.
|
# Upsream patch to try to track down test failure.
|
||||||
Patch1: 0001-tests-test-nozero.sh-Add-set-x.patch
|
Patch1: 0001-tests-test-nozero.sh-Add-set-x.patch
|
||||||
|
Patch2: 0002-tests-test-nozero.sh-Create-test-file-as-single-exte.patch
|
||||||
|
|
||||||
%if 0%{patches_touch_autotools}
|
%if 0%{patches_touch_autotools}
|
||||||
BuildRequires: autoconf, automake, libtool
|
BuildRequires: autoconf, automake, libtool
|
||||||
@ -667,10 +668,6 @@ autoreconf -i
|
|||||||
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
# Disable LTO, it's unreliable. See for example:
|
|
||||||
# https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/thread/ULGH5JYL7MHKDKTINJLOEN2QG6LOHWH7/
|
|
||||||
%define _lto_cflags %{nil}
|
|
||||||
|
|
||||||
# Golang bindings are not enabled in the Fedora build since they don't
|
# Golang bindings are not enabled in the Fedora build since they don't
|
||||||
# need to be. Most people would use them by copying the upstream
|
# need to be. Most people would use them by copying the upstream
|
||||||
# package into their vendor/ directory.
|
# package into their vendor/ directory.
|
||||||
@ -1075,9 +1072,8 @@ export LIBGUESTFS_TRACE=1
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* Fri Jul 31 2020 Richard W.M. Jones <rjones@redhat.com> - 1.21.20-4
|
* Sat Aug 1 2020 Richard W.M. Jones <rjones@redhat.com> - 1.21.20-5
|
||||||
- Add upstream patch to try to track down test failure in Koji.
|
- Add upstream patches to try to track down test failure in Koji.
|
||||||
- Disable LTO.
|
|
||||||
|
|
||||||
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.21.20-2
|
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.21.20-2
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||||
|
Loading…
Reference in New Issue
Block a user