#5 Define and use have_go_rpm_macros
Merged 4 years ago by ddd. Opened 4 years ago by fidencio.
rpms/ fidencio/kata-osbuilder wip/rework_macros  into  master

file modified
+7 -1
@@ -1,3 +1,9 @@ 

+ %if (0%{?fedora} && 0%{?fedora >= 31})

+     %define have_go_rpm_macros 1

+ %else

+     %define have_go_rpm_macros 0

+ %endif

+ 

  %global with_debug 0

  

  %if 0%{?with_debug}
@@ -57,7 +63,7 @@ 

  

  BuildRequires: gcc

  BuildRequires: git

- %if 0%{?fedora}

+ %if 0%{?have_go_rpm_macros}

  BuildRequires: go-rpm-macros

  %else

  BuildRequires: compiler(go-compiler)

In order to keep things more organised, let's define and use
have_go_rpm_macros instead of just checking for fedora.

By doing this we follow what's already done by libvirt.

Signed-off-by: Fabiano Fidêncio fidencio@redhat.com

Pull-Request has been merged by ddd

4 years ago