Cleanup spec file conditionals

This commit is contained in:
Merlin Mathesius 2018-01-09 14:25:05 -06:00
parent 37911ff92b
commit 374db1b0a4
1 changed files with 20 additions and 5 deletions

View File

@ -35,10 +35,22 @@ Epoch: 1
# Eclipse is arch-specific, but multilib agnostic
%global _eclipsedir %{_prefix}/lib/eclipse
%if 0%{?fedora} || 0%{?rhel} > 7
%global use_webkit2 1
%else
%global use_webkit2 0
%endif
%if 0%{?fedora} >= 27 || 0%{?rhel} > 7
%global use_wayland 1
%else
%global use_wayland 0
%endif
Summary: An open, extensible IDE
Name: eclipse
Version: 4.7.2
Release: 1%{?dist}
Release: 2%{?dist}
License: EPL
URL: http://www.eclipse.org/
@ -161,7 +173,7 @@ BuildRequires: pkgconfig(xtst)
BuildRequires: pkgconfig(libsecret-1)
BuildRequires: pkgconfig(gtk+-2.0)
BuildRequires: pkgconfig(gtk+-3.0)
%if 0%{?rhel}
%if ! %{use_webkit2}
# RHEL does not have webkit2
BuildRequires: pkgconfig(webkitgtk-3.0)
%else
@ -238,7 +250,7 @@ Summary: SWT Library for GTK+
Requires: java-headless >= 1:1.7.0
Requires: javapackages-tools
Requires: eclipse-filesystem
%if 0%{?rhel}
%if ! %{use_webkit2}
# RHEL does not have webkit2
Requires: gtk3
Requires: webkitgtk3
@ -401,7 +413,7 @@ tar --strip-components=1 -xf %{SOURCE1}
%patch20
%patch21
%patch22
%if ! 0%{?rhel}
%if %{use_webkit2}
# RHEL does not have webkit2
%patch23
%endif
@ -409,7 +421,7 @@ tar --strip-components=1 -xf %{SOURCE1}
%patch25
%patch26
%patch27
%if 0%{?rhel} || 0%{?fedora} < 27
%if ! %{use_wayland}
# Enable wayland by default on F27+
%patch28
%endif
@ -1101,6 +1113,9 @@ fi
%{_eclipsedir}/plugins/org.eclipse.osgi.util_*
%changelog
* Tue Jan 09 2018 Merlin Mathesius <mmathesi@redhat.com> - 1:4.7.2-2
- Cleanup spec file conditionals
* Wed Nov 29 2017 Mat Booth <mat.booth@redhat.com> - 1:4.7.2-1
- Update to last RC/final release of Oxygen.2
- Fix x11 crash when running on wayland