From fd9dd8d04517c7a592b7b1e229750b16c215c1cb Mon Sep 17 00:00:00 2001 From: Germano Massullo Date: Sun, 16 Apr 2023 18:38:29 +0200 Subject: [PATCH] improved Linux distribution version macros --- keepassxc.spec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/keepassxc.spec b/keepassxc.spec index 6b9d524..7c7c39b 100644 --- a/keepassxc.spec +++ b/keepassxc.spec @@ -38,7 +38,7 @@ Source2: https://keepassxc.org/keepassxc_master_signing_key.asc # disabling the patch fixes the problem, therefore it has been disabled on # Fedora >= 38 -%if (0%{?el} || 0%{?fedora} < 38) +%if (%{defined rhel} || (%{defined fedora} && 0%{?fedora} < 38)) Patch0: xcb.patch %endif Patch1: appdata.patch @@ -46,7 +46,7 @@ Patch1: appdata.patch BuildRequires: botan2-devel BuildRequires: cmake >= 3.1 BuildRequires: desktop-file-utils -%if 0%{?el8} +%if %{defined rhel} BuildRequires: gcc-toolset-12-gcc-c++ BuildRequires: gcc-toolset-12-annobin-plugin-gcc %else @@ -140,7 +140,7 @@ sed -i '/type="contribute"/d' ./share/linux/org.keepassxc.KeePassXC.appdata.xml %endif %build -%if 0%{?el8} +%if %{defined rhel} . /opt/rh/gcc-toolset-12/enable %endif # -DWITH_XC_DOCS=OFF is needed on EL due missing rubygem-asciidoctor