[supermin/f21] Upstream patch for RHBZ#1155586.

Richard W.M. Jones rjones at fedoraproject.org
Wed Nov 26 22:11:34 UTC 2014


commit 5699133b089aad7e76a42d9b61fcefdb361d5eb7
Author: Richard W.M. Jones <rjones at redhat.com>
Date:   Wed Nov 26 22:07:45 2014 +0000

    Upstream patch for RHBZ#1155586.

 ...move-trailing-slash-from-readlink-filenam.patch |   31 ++++++++++++++++++++
 supermin.spec                                      |   10 ++++++-
 2 files changed, 40 insertions(+), 1 deletions(-)
---
diff --git a/0001-supermin-Remove-trailing-slash-from-readlink-filenam.patch b/0001-supermin-Remove-trailing-slash-from-readlink-filenam.patch
new file mode 100644
index 0000000..a224f05
--- /dev/null
+++ b/0001-supermin-Remove-trailing-slash-from-readlink-filenam.patch
@@ -0,0 +1,31 @@
+From d7bb984889257f5b87963dcca6456fc6e4cc804e Mon Sep 17 00:00:00 2001
+From: "Richard W.M. Jones" <rjones at redhat.com>
+Date: Sat, 25 Oct 2014 22:51:20 +0100
+Subject: [PATCH] supermin: Remove trailing slash from readlink filenames
+ (RHBZ#1155586).
+
+---
+ src/build.ml | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/src/build.ml b/src/build.ml
+index 500ce33..b9b44ac 100644
+--- a/src/build.ml
++++ b/src/build.ml
+@@ -402,6 +402,13 @@ and munge files =
+           realpath (parent // target)
+         else
+           target in
++      (* Remove trailing slash from filenames (RHBZ#1155586). *)
++      let target =
++        let len = String.length target in
++        if len >= 2 && target.[len-1] = '/' then
++          String.sub target 0 (len-1)
++        else
++          target in
+       if not (dir_seen target) then (
+         let target =
+           {ft_path = target; ft_source_path = target; ft_config = false} in
+-- 
+2.1.0
+
diff --git a/supermin.spec b/supermin.spec
index 1fb4965..1dfab4e 100644
--- a/supermin.spec
+++ b/supermin.spec
@@ -1,7 +1,7 @@
 Summary:       Tool for creating supermin appliances
 Name:          supermin
 Version:       5.1.10
-Release:       1%{?dist}
+Release:       2%{?dist}
 License:       GPLv2+
 
 %if 0%{?rhel} >= 7
@@ -11,6 +11,9 @@ ExclusiveArch: x86_64
 URL:           http://people.redhat.com/~rjones/supermin/
 Source0:       http://libguestfs.org/download/supermin/%{name}-%{version}.tar.gz
 
+# Upstream patch for RHBZ#1155586
+Patch1:        0001-supermin-Remove-trailing-slash-from-readlink-filenam.patch
+
 BuildRequires: /usr/bin/pod2man
 BuildRequires: rpm
 BuildRequires: yum-utils
@@ -52,6 +55,8 @@ second when you need to boot one of them.
 %prep
 %setup -q
 
+%patch1 -p1
+
 
 %build
 %configure --disable-network-tests
@@ -84,6 +89,9 @@ make check || {
 
 
 %changelog
+* Wed Nov 26 2014 Richard W.M. Jones <rjones at redhat.com> - 5.1.10-2
+- Upstream patch for RHBZ#1155586.
+
 * Thu Sep  4 2014 Richard W.M. Jones <rjones at redhat.com> - 5.1.10-1
 - New upstream version 5.1.10.
 - Remove patch which is now included upstream.


More information about the scm-commits mailing list