@@ -159,15 +159,16 @@ BuildRequires: dos2unix
159159BuildRequires: fdupes
160160%endif
161161
162- %if ( 0%{? rhel_version } >= 800 || ! 0%{?rhel_version } ) && ( 0%{? rhel } >= 8 || ! 0%{?rhel } )
162+ %if ( ! 0%{?rhel_version } ) && ( ! 0%{?rhel } )
163163# Not sure why claimed absent in RHEL7 (even with Fedora/EPEL repo layer added)
164164%define NUTPKG_WITH_AVAHI 1
165165BuildRequires: avahi-devel
166166%else
167167%define NUTPKG_WITH_AVAHI 0
168168%endif
169169
170- %if ( 0%{?rhel_version }>= 800 || ! 0%{?rhel_version } ) && ( 0%{?rhel }>= 8 || ! 0%{?rhel } ) && ( 0%{?sle_version }>= 150000 || ! 0%{?sle_version } ) && ( 0%{?suse_version }>= 1300 || ! 0%{?suse_version } )
170+ %if ( ! 0%{?rhel_version } ) && ( ! 0%{?rhel } ) && ( 0%{?sle_version }>= 150000 || ! 0%{?sle_version } ) && ( 0%{?suse_version }>= 1300 || ! 0%{?suse_version } )
171+ # Not sure why claimed absent in RHEL (even with Fedora/EPEL repo layer added)
171172%define NUTPKG_WITH_FREEIPMI 1
172173BuildRequires: (libfreeipmi-devel or freeipmi-devel)
173174%else
@@ -231,7 +232,8 @@ BuildRequires: (httpd-devel or apache2-devel)
231232
232233BuildRequires: (dbus-1-glib-devel or dbus-glib-devel)
233234
234- %if ( 0%{?rhel_version }>= 800 || ! 0%{?rhel_version } ) && ( 0%{?rhel }>= 8 || ! 0%{?rhel } )
235+ %if ( (0%{?rhel_version }> 0 && 0%{?rhel_version }< 800) || ! 0%{?rhel_version } ) && ( (0%{?rhel }> 0 && 0%{?rhel }< 8) || ! 0%{?rhel } )
236+ # Strange that this is not present in RHEL8 (even with Fedora EPEL repos attached)
235237BuildRequires: (libcppunit-devel or cppunit-devel)
236238%endif
237239
@@ -265,17 +267,19 @@ BuildRequires: powerman-devel
265267%define NUTPKG_WITH_POWERMAN 0
266268%endif
267269
268- %if ( 0%{?suse_version }> 0 || ! %{?suse_version } ) && (0%{?centos_version }>= 800) || ! 0%{?centos_version } ) && ( ! 0%{?rhel_version } ) && ( ! 0%{?rhel } )
270+ %if ( 0%{?suse_version }> 0 || ! 0 %{?suse_version } ) && (0%{?centos_version }>= 800 || ! 0%{?centos_version } ) && ( ! 0%{?rhel_version } ) && ( ! 0%{?rhel } )
269271# Strange that this is not present in RHEL (even with Fedora EPEL repos attached)
270272# But it also complains about epel-rpm-macros when this is added though.
271273BuildRequires: systemd-rpm-macros
272274%endif
273275
276+ %if ( 0%{?rhel_version }>= 800 || ! 0%{?rhel_version } ) && ( 0%{?rhel }>= 8 || ! 0%{?rhel } )
274277# Only needed for PDF generation, we do not package that now
275278#BuildRequires: dblatex
276279
277280BuildRequires: (libxslt-tools or libxslt)
278281BuildRequires: asciidoc
282+ %endif
279283
280284%if 0%{?opensuse_version }
281285# Package provides driver for USB HID UPSes, but people can live with hal addon:
0 commit comments