2 %bcond_with tests # build without tests (tests fail mostly)
3 %bcond_without qt4 # build without Qt4
4 %bcond_without qt5 # build without Qt5
6 Summary: A lightweight display manager
7 Summary(hu.UTF-8): Egy könnyűsúlyú bejelentkezéskezelő
9 # Odd versions are development, use only Even versions here (1.x = x odd/even)
12 # library/bindings are LGPLv2 or LGPLv3, the rest GPLv3+
13 License: (LGPLv2 or LGPLv3) and GPLv3+
14 Group: X11/Applications
15 Source0: https://github.com/CanonicalLtd/lightdm/releases/download/%{version}/%{name}-%{version}.tar.xz
16 # Source0-md5: 3e33b2bd15d769bbcc2e73ac94a1e1ea
18 Source2: %{name}-autologin.pamd
19 Source3: %{name}-greeter.pamd
21 Source5: %{name}-tmpfiles.conf
23 Patch1: %{name}-nodaemon_option.patch
24 URL: http://www.freedesktop.org/wiki/Software/LightDM
25 BuildRequires: autoconf
26 BuildRequires: automake >= 1:1.11
27 BuildRequires: docbook-dtd412-xml
28 BuildRequires: gettext-tools
29 BuildRequires: glib2-devel >= 1:2.30
30 BuildRequires: gnome-common
31 BuildRequires: gnome-doc-utils
32 BuildRequires: gobject-introspection-devel >= 0.9.5
33 BuildRequires: gtk-doc
34 BuildRequires: intltool >= 0.35.0
35 BuildRequires: libgcrypt-devel
36 BuildRequires: libtool
37 BuildRequires: libxcb-devel
38 BuildRequires: libxklavier-devel
39 BuildRequires: pam-devel
40 BuildRequires: perl-XML-Parser
41 BuildRequires: perl-base
42 BuildRequires: pkgconfig
43 BuildRequires: rpmbuild(macros) >= 1.690
44 BuildRequires: tar >= 1:1.22
46 BuildRequires: xorg-lib-libX11-devel
47 BuildRequires: xorg-lib-libXdmcp-devel
49 BuildRequires: yelp-tools
51 BuildRequires: QtCore-devel
52 BuildRequires: QtDBus-devel
53 BuildRequires: QtGui-devel
54 BuildRequires: qt4-build
57 BuildRequires: Qt5Core-devel
58 BuildRequires: Qt5DBus-devel
59 BuildRequires: Qt5Gui-devel
60 BuildRequires: qt5-build
64 Requires: lightdm-greeter
65 Requires: xinitrc-ng >= 1.1-2
69 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
71 %define bashdir %{_sysconfdir}/bash_completion.d
74 An X display manager that:
75 - Has a lightweight codebase
76 - Is standards compliant (PAM, ConsoleKit, etc)
77 - Has a well defined interface between the server and user interface
78 - Fully themeable (easiest with the webkit interface)
79 - Cross-desktop (greeters can be written in any toolkit)
81 %description -l hu.UTF-8
82 Egy X bejelentkezéskezelő, amely:
83 - pehelysúlyú kóddal rendelkezik
84 - követi a standardokat (PAM, ConsoleKit, stb.)
85 - jól-definiált felület a szerver és a felhasználói felület között
86 - teljesen témázható (a legkönnyebb a webkit felülettel)
87 - desktop-független (üdvözlők bármilyen eszközkészlettel írhatók)
90 Summary: LightDM GObject client library
92 Obsoletes: lightdm-libs < 1.7.0-0.6
94 %description libs-gobject
95 This package contains a GObject based library for LightDM clients to
96 use to interface with LightDM.
98 %package libs-gobject-devel
99 Summary: Development files for %{name}-gobject
100 Group: Development/Libraries
102 Requires: %{name}-libs-gobject = %{version}-%{release}
104 %description libs-gobject-devel
105 This package contains development files for a GObject based library
106 for LightDM clients to use to interface with LightDM.
109 Summary: LightDM Qt4 client library
111 Obsoletes: lightdm-libs-qt
112 Conflicts: lightdm-libs < 1.7.0-0.6
114 %description libs-qt4
115 This package contains a Qt4 based library for LightDM clients to use
116 to interface with LightDM.
118 %package libs-qt4-devel
119 Summary: Development files for %{name}-qt4
120 Group: Development/Libraries
121 Requires: %{name}-libs-qt4 = %{version}-%{release}
122 Obsoletes: lightdm-libs-qt-devel
124 %description libs-qt4-devel
125 This package contains development files for a Qt4 based library for
126 LightDM clients to use to interface with LightDM.
129 Summary: LightDM Qt5 client library
132 %description libs-qt5
133 This package contains a Qt5 based library for LightDM clients to use
134 to interface with LightDM.
136 %package libs-qt5-devel
137 Summary: Development files for %{name}-qt5
138 Group: Development/Libraries
139 Requires: %{name}-libs-qt5 = %{version}-%{release}
141 %description libs-qt5-devel
142 This package contains development files for a Qt5 based library for
143 LightDM clients to use to interface with LightDM.
146 Summary: lightdm API documentation
148 %if "%{_rpmversion}" >= "5"
153 lightdm API documentation.
156 Summary: Init script for Lightdm
157 Summary(pl.UTF-8): Skrypt init dla Lightdm-a
158 Group: X11/Applications
159 Requires(post,preun): /sbin/chkconfig
160 Requires(post,postun): systemd-units >= 38
161 Requires: %{name} = %{version}-%{release}
162 Requires: rc-scripts >= 0.4.3.0
163 Requires: systemd-units >= 38
164 Obsoletes: lightdm-upstart < 1.7.12-6
167 Init script for Lightdm.
169 %description init -l pl.UTF-8
170 Skrypt init dla Lightdm-a.
172 %package -n bash-completion-lightdm
173 Summary: Bash completion for LightDM
174 Summary(pl.UTF-8): Bashowe uzupełnianie parametrów dla LightDM
175 Group: Applications/Shells
176 Requires: %{name} = %{version}-%{release}
177 Requires: bash-completion
178 %if "%{_rpmversion}" >= "5"
182 %description -n bash-completion-lightdm
183 Bash completion for LightDM.
185 %description -n bash-completion-lightdm -l pl.UTF-8
186 Bashowe uzupełnianie parametrów dla LightDM.
201 --disable-silent-rules \
204 --enable-liblightdm-gobject \
205 %{?with_qt4:--enable-liblightdm-qt} \
206 %{?with_qt5:--enable-liblightdm-qt5} \
207 --with-html-dir=%{_gtkdocdir} \
209 --with-greeter-session=lightdm-gtk-greeter \
210 --with-greeter-user=xdm
212 %{?with_tests:%{__make} check}
215 rm -rf $RPM_BUILD_ROOT
217 INSTALL='install -p' \
218 DESTDIR=$RPM_BUILD_ROOT
220 install -d $RPM_BUILD_ROOT/etc/{pam.d,security,rc.d/init.d,dbus-1/system.d} \
221 $RPM_BUILD_ROOT%{bashdir} \
222 $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/%{name}.conf.d \
223 $RPM_BUILD_ROOT/home/services/xdm \
224 $RPM_BUILD_ROOT%{_datadir}/xgreeters \
225 $RPM_BUILD_ROOT%{_datadir}/%{name}/{remote-sessions,%{name}.conf.d} \
226 $RPM_BUILD_ROOT%{systemdunitdir} \
227 $RPM_BUILD_ROOT/var/lib/%{name}-data \
228 $RPM_BUILD_ROOT/var/{log,cache}/%{name}
230 install -d $RPM_BUILD_ROOT{/var/run/lightdm,%{systemdtmpfilesdir}}
231 cp -p %{SOURCE5} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/lightdm.conf
234 install -p %{SOURCE4} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
235 ln -s /dev/null $RPM_BUILD_ROOT%{systemdunitdir}/%{name}.service
237 cp -p %{SOURCE1} $RPM_BUILD_ROOT/etc/pam.d/%{name}
238 cp -p %{SOURCE2} $RPM_BUILD_ROOT/etc/pam.d/lightdm-autologin
239 cp -p %{SOURCE3} $RPM_BUILD_ROOT/etc/pam.d/lightdm-greeter
240 touch $RPM_BUILD_ROOT/etc/security/blacklist.%{name}
242 # We don't ship AppAmor
243 rm -rv $RPM_BUILD_ROOT/etc/apparmor.d
245 %{__rm} -r $RPM_BUILD_ROOT%{_localedir}/{lb,wae}
247 %{__rm} -r $RPM_BUILD_ROOT%{_datadir}/bash-completion
248 cp -p data/bash-completion/{dm-tool,lightdm} $RPM_BUILD_ROOT%{bashdir}
250 %find_lang %{name} --with-gnome
253 rm -rf $RPM_BUILD_ROOT
256 %groupadd -g 55 -r -f xdm
257 %useradd -u 55 -r -d /home/services/xdm -s /bin/false -c "X Display Manager" -g xdm xdm
260 if [ "$1" = "0" ]; then
265 %post libs-gobject -p /sbin/ldconfig
266 %postun libs-gobject -p /sbin/ldconfig
268 %post libs-qt4 -p /sbin/ldconfig
269 %postun libs-qt4 -p /sbin/ldconfig
271 %post libs-qt5 -p /sbin/ldconfig
272 %postun libs-qt5 -p /sbin/ldconfig
275 /sbin/chkconfig --add %{name}
276 %service -n %{name} restart
280 if [ "$1" = "0" ]; then
281 /sbin/chkconfig --del %{name}
282 %service %{name} stop
288 %files -f %{name}.lang
289 %defattr(644,root,root,755)
291 %dir %{_sysconfdir}/%{name}
292 %dir %{_sysconfdir}/%{name}/%{name}.conf.d
293 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/%{name}.conf
294 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/keys.conf
295 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/users.conf
296 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/%{name}
297 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/lightdm-autologin
298 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/lightdm-greeter
299 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/security/blacklist.%{name}
300 /etc/dbus-1/system.d/org.freedesktop.DisplayManager.conf
301 %attr(755,root,root) %{_bindir}/dm-tool
302 %attr(755,root,root) %{_sbindir}/lightdm
303 %attr(755,root,root) %{_libexecdir}/lightdm-guest-session
304 %{_libdir}/girepository-1.0/LightDM-1.typelib
305 %{systemdtmpfilesdir}/lightdm.conf
306 %{_datadir}/accountsservice/interfaces/org.freedesktop.DisplayManager.AccountsService.xml
307 %{_datadir}/dbus-1/interfaces/org.freedesktop.DisplayManager.AccountsService.xml
308 %{_datadir}/polkit-1/actions/org.freedesktop.DisplayManager.AccountsService.policy
309 %dir %{_datadir}/xgreeters
310 %dir %{_datadir}/%{name}
311 %dir %{_datadir}/%{name}/remote-sessions
312 %dir %{_datadir}/%{name}/%{name}.conf.d
313 %{_mandir}/man1/dm-tool.1*
314 %{_mandir}/man1/%{name}.1*
315 %dir %attr(710,root,root) /var/cache/%{name}
316 %dir %attr(710,root,root) /var/log/%{name}
317 %dir %attr(770,root,root) /var/run/%{name}
318 %dir %attr(700,root,root) /var/lib/%{name}-data
319 %dir %attr(750,xdm,xdm) /home/services/xdm
322 %defattr(644,root,root,755)
323 %attr(755,root,root) %{_libdir}/liblightdm-gobject-1.so.*.*.*
324 %attr(755,root,root) %ghost %{_libdir}/liblightdm-gobject-1.so.0
328 %defattr(644,root,root,755)
329 %attr(755,root,root) %{_libdir}/liblightdm-qt-3.so.*.*.*
330 %attr(755,root,root) %ghost %{_libdir}/liblightdm-qt-3.so.0
332 %files libs-qt4-devel
333 %defattr(644,root,root,755)
334 %{_libdir}/liblightdm-qt-3.la
335 %attr(755,root,root) %{_libdir}/liblightdm-qt-3.so
336 %{_includedir}/lightdm-qt-3
337 %{_pkgconfigdir}/liblightdm-qt-3.pc
342 %defattr(644,root,root,755)
343 %attr(755,root,root) %{_libdir}/liblightdm-qt5-3.so.*.*.*
344 %attr(755,root,root) %ghost %{_libdir}/liblightdm-qt5-3.so.0
346 %files libs-qt5-devel
347 %defattr(644,root,root,755)
348 %{_libdir}/liblightdm-qt5-3.la
349 %attr(755,root,root) %{_libdir}/liblightdm-qt5-3.so
350 %{_includedir}/lightdm-qt5-3
351 %{_pkgconfigdir}/liblightdm-qt5-3.pc
354 %files libs-gobject-devel
355 %defattr(644,root,root,755)
356 %{_datadir}/gir-1.0/LightDM-1.gir
357 %{_includedir}/lightdm-gobject-1
358 %{_pkgconfigdir}/liblightdm-gobject-1.pc
359 %{_libdir}/liblightdm-gobject-1.la
360 %attr(755,root,root) %{_libdir}/liblightdm-gobject-1.so
362 %{_datadir}/vala/vapi/liblightdm-gobject-1.vapi
363 %{_datadir}/vala/vapi/liblightdm-gobject-1.deps
366 %defattr(644,root,root,755)
367 %{_gtkdocdir}/lightdm-gobject-1
370 %defattr(644,root,root,755)
371 %attr(754,root,root) /etc/rc.d/init.d/%{name}
372 %{systemdunitdir}/%{name}.service
374 %files -n bash-completion-lightdm
375 %defattr(644,root,root,755)