From 3e6ccdf06d8fc52e7c2a1e789c188c555a6897cc Mon Sep 17 00:00:00 2001 From: Lokesh Mandvekar Date: Wed, 13 Sep 2023 14:04:48 -0400 Subject: [PATCH] rpm: correctly obsolete older rpm builds The prior change in #268 didn't completely obsolete older builds of gvisor-tap-vsock, causing installation conflicts with the official Fedora builds. This commit should correctly obsolete fedora packages. Ref: https://cirrus-ci.com/task/5730166412935168 Note: To avoid nvr complexity, this commit only fixes the conflicts for official Fedora builds. Any issues with the podman-next copr can be fixed on a case-by-case basis unless an overwhelming amount of people complain. Signed-off-by: Lokesh Mandvekar --- rpm/gvisor-tap-vsock.spec | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/rpm/gvisor-tap-vsock.spec b/rpm/gvisor-tap-vsock.spec index 74932daf3..6273d4642 100644 --- a/rpm/gvisor-tap-vsock.spec +++ b/rpm/gvisor-tap-vsock.spec @@ -70,6 +70,10 @@ dynamic port forwarding. %package gvforwarder Summary: %{desc_gvforwarder} Provides: gvforwarder = %{epoch}:%{version}-%{release} +%if !%{defined copr_username} +Obsoletes: %{name} < 6:0.7.0-6 +Recommends: %{name} = %{epoch}:%{version}-%{release} +%endif %description gvforwarder %{desc_gvforwarder}