]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
spec: Update version check for maint Source URL
authorCole Robinson <crobinso@redhat.com>
Fri, 5 May 2017 00:08:55 +0000 (20:08 -0400)
committerCole Robinson <crobinso@redhat.com>
Wed, 10 May 2017 19:23:41 +0000 (15:23 -0400)
New maint release version numbers of just A.B.C format, not the old
A.B.C.D format. Adjust the check that dynamically changes the Source
URL for maint releases

Signed-off-by: Cole Robinson <crobinso@redhat.com>
Acked-by: Andrea Bolognani <abologna@redhat.com>
(cherry picked from commit 1d07a5bf3c03309642068d20698a1f55739dafa2)

libvirt.spec.in

index a389e88c578dde0d179662cd984f4fdba2894a57..0ece3c85d510a16d70ea606b7f0a6dae1048bd5d 100644 (file)
@@ -226,7 +226,7 @@ Group: Development/Libraries
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
 URL: http://libvirt.org/
 
-%if %(echo %{version} | grep -o \\. | wc -l) == 3
+%if %(echo %{version} | grep -q "\.0$"; echo $?) == 1
     %define mainturl stable_updates/
 %endif
 Source: http://libvirt.org/sources/%{?mainturl}libvirt-%{version}.tar.xz