From 8e4cdf5923d7ce62e109646d0b5f3372bb6552ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= Date: Tue, 30 Nov 2021 11:34:16 +0000 Subject: [PATCH] Use macros for all meson options and fix bash completion deps MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Daniel P. Berrangé --- virt-viewer.spec | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/virt-viewer.spec b/virt-viewer.spec index 709d08f..2b0d77f 100644 --- a/virt-viewer.spec +++ b/virt-viewer.spec @@ -10,7 +10,7 @@ Name: virt-viewer Version: 10.0 -Release: 5%{?dist} +Release: 6%{?dist} Summary: Virtual Machine Viewer License: GPLv2+ URL: https://gitlab.com/virt-viewer/virt-viewer @@ -19,6 +19,9 @@ Patch1: 0001-src-avoid-warnings-from-use-of-G_GNUC_FALLTHROUGH.patch Patch2: 0001-src-initialize-keymaps-variable.patch Requires: openssh-clients +# Our bash completion script uses virsh to list domains +Requires: libvirt-client + BuildRequires: gcc BuildRequires: meson BuildRequires: pkgconfig(glib-2.0) @@ -50,6 +53,9 @@ the display, and libvirt for looking up VNC/SPICE server details. %autosetup -p1 %build + +%define buildid_opt -Dbuild-id=%{release} + %if !%{with_govirt} %define ovirt_opt -Dovirt=disabled %endif @@ -58,7 +64,11 @@ the display, and libvirt for looking up VNC/SPICE server details. %define spice_opt -Dspice=disabled %endif -%meson -Dbuild-id=%{release} %{?ovirt_opt} %{?spice_opt} +%if 0%{?rhel} > 0 +%define osid_opt -Dos-id=rhel%{?rhel} +%endif + +%meson %{buildid_opt} %{?ovirt_opt} %{?spice_opt} %{?osid_opt} %meson_build %install @@ -79,6 +89,10 @@ the display, and libvirt for looking up VNC/SPICE server details. %{_datadir}/bash-completion/completions/virt-viewer %changelog +* Thu Nov 25 2021 Daniel P. Berrangé - 10.0-6 +- Add missing dep on libvirt-clients for bash completion +- Refactor setting build-id opt + * Tue Nov 16 2021 Tom Stellard - 10.0-5 - Backport fix for uninitialized variable