From 82e60504039515b1b4510619410c87154b91031d Mon Sep 17 00:00:00 2001 From: Leigh Scott Date: Oct 20 2019 14:27:16 +0000 Subject: Make it build for epel-8, preparation as qt4 support has been removed from the next lightdm upstream release --- diff --git a/lightdm.spec b/lightdm.spec index 0835ee5..c6273ad 100644 --- a/lightdm.spec +++ b/lightdm.spec @@ -1,6 +1,10 @@ # FIXME: most tests currently fail %bcond_with tests +%if 0%{?fedora} || 0%{?rhel} < 8 +%global _with_qt4 1 +%endif + %global glib2_version %(pkg-config --modversion glib-2.0 2>/dev/null || echo "2.44") %global giturl https://github.com/CanonicalLtd/lightdm @@ -9,10 +13,18 @@ Summary: A cross-desktop Display Manager Version: 1.30.0 Release: 2%{?dist} +%if 0%{?rhel} >= 8 +# Exclude failing arch +#DEBUG util.py:593: No matching package to install: 'gnome-common' +#DEBUG util.py:593: No matching package to install: 'itstool' +#DEBUG util.py:593: Not all dependencies satisfied +ExclusiveArch: x86_64 ppc64le +%endif + # library/bindings are LGPLv2 or LGPLv3, the rest GPLv3+ License: (LGPLv2 or LGPLv3) and GPLv3+ URL: https://www.freedesktop.org/wiki/Software/LightDM/ -Source0: %{giturl}/archive/%{version}.tar.gz#/lightdm-%{version}.tar.gz +Source0: %{giturl}/archive/%{version}/lightdm-%{version}.tar.gz Source10: lightdm.pam Source11: lightdm-autologin.pam @@ -50,7 +62,7 @@ BuildRequires: pkgconfig(gmodule-export-2.0) BuildRequires: pkgconfig(gobject-2.0) BuildRequires: pkgconfig(gobject-introspection-1.0) >= 0.9.5 BuildRequires: pkgconfig(libxklavier) -BuildRequires: pkgconfig(QtCore) pkgconfig(QtDBus) pkgconfig(QtGui) pkgconfig(QtNetwork) +%{?_with_qt4:BuildRequires: pkgconfig(QtCore) pkgconfig(QtDBus) pkgconfig(QtGui) pkgconfig(QtNetwork)} BuildRequires: pkgconfig(Qt5Core) pkgconfig(Qt5DBus) pkgconfig(Qt5Gui) BuildRequires: pkgconfig(x11) BuildRequires: pkgconfig(xcb) @@ -99,6 +111,7 @@ Requires: %{name}-gobject%{?_isa} = %{version}-%{release} %description gobject-devel %{summary}. +%if 0%{?_with_qt4} %package qt Summary: LightDM Qt4 client library Requires: %{name}%{?_isa} = %{version}-%{release} @@ -112,6 +125,7 @@ Summary: Development files for %{name}-qt Requires: %{name}-qt%{?_isa} = %{version}-%{release} %description qt-devel %{summary}. +%endif %package qt5 Summary: LightDM Qt5 client library @@ -144,7 +158,7 @@ NOCONFIGURE=1 ./autogen.sh --disable-static \ --enable-gtk-doc \ --enable-libaudit \ - --enable-liblightdm-qt \ + %{?_with_qt4:--enable-liblightdm-qt} \ --enable-liblightdm-qt5 \ --enable-introspection \ %if %{with tests} @@ -277,6 +291,7 @@ fi %{_datadir}/gir-1.0/LightDM-1.gir %{_datadir}/vala/vapi/liblightdm-gobject-1.* +%if 0%{?_with_qt4} %ldconfig_scriptlets qt %files qt @@ -287,6 +302,7 @@ fi %{_includedir}/lightdm-qt-3/ %{_libdir}/liblightdm-qt-3.so %{_libdir}/pkgconfig/liblightdm-qt-3.pc +%endif %ldconfig_scriptlets qt5