]>
Commit | Line | Data |
---|---|---|
8afa832f ER |
1 | # Conditional build: |
2 | %bcond_with tests # build without tests (tests fail mostly) | |
f4c63304 ER |
3 | %bcond_without qt4 # build without Qt4 |
4 | %bcond_without qt5 # build without Qt5 | |
8afa832f | 5 | |
c5b54d7b ZU |
6 | Summary: A lightweight display manager |
7 | Summary(hu.UTF-8): Egy könnyűsúlyú bejelentkezéskezelő | |
8 | Name: lightdm | |
33777998 | 9 | # Odd versions are development, use only Even versions here (1.x = x odd/even) |
81f68717 | 10 | Version: 1.12.2 |
d70bdf62 | 11 | Release: 1 |
eff0aaee ER |
12 | # library/bindings are LGPLv2 or LGPLv3, the rest GPLv3+ |
13 | License: (LGPLv2 or LGPLv3) and GPLv3+ | |
c5b54d7b | 14 | Group: X11/Applications |
886ff782 | 15 | Source0: https://launchpad.net/lightdm/1.12/%{version}/+download/%{name}-%{version}.tar.xz |
81f68717 | 16 | # Source0-md5: 573e2cf8acf96df3ed7c4968749a80ad |
6330239a | 17 | Source1: %{name}.pamd |
9affbe56 ER |
18 | Source2: %{name}-autologin.pamd |
19 | Source3: %{name}-greeter.pamd | |
aeb930bc | 20 | Source4: %{name}.init |
8afa832f | 21 | Source5: %{name}-tmpfiles.conf |
4f2b8153 ER |
22 | Patch0: config.patch |
23 | Patch1: upstart-path.patch | |
aeb930bc | 24 | Patch2: %{name}-nodaemon_option.patch |
3d3d7bd6 | 25 | Patch3: %{name}-qt5.patch |
65a202a6 | 26 | URL: http://www.freedesktop.org/wiki/Software/LightDM |
a0bff196 | 27 | BuildRequires: autoconf |
3d3d7bd6 | 28 | BuildRequires: automake >= 1:1.11 |
a0bff196 | 29 | BuildRequires: docbook-dtd412-xml |
c5b54d7b | 30 | BuildRequires: gettext-devel |
0e15dcbc | 31 | BuildRequires: glib2-devel >= 1:2.30 |
a0bff196 | 32 | BuildRequires: gnome-common |
c5b54d7b | 33 | BuildRequires: gnome-doc-utils |
3d3d7bd6 | 34 | BuildRequires: gobject-introspection-devel >= 0.9.5 |
a0bff196 | 35 | BuildRequires: gtk-doc |
3d3d7bd6 | 36 | BuildRequires: intltool >= 0.35.0 |
f320953a | 37 | BuildRequires: libgcrypt-devel |
a0bff196 | 38 | BuildRequires: libtool |
3d3d7bd6 | 39 | BuildRequires: libxcb-devel |
768f7b75 ZU |
40 | BuildRequires: libxklavier-devel |
41 | BuildRequires: pam-devel | |
c5b54d7b ZU |
42 | BuildRequires: perl-XML-Parser |
43 | BuildRequires: perl-base | |
a0bff196 | 44 | BuildRequires: pkgconfig |
7b654e98 | 45 | BuildRequires: rpmbuild(macros) >= 1.690 |
e8d8d6ad | 46 | BuildRequires: tar >= 1:1.22 |
6330239a | 47 | BuildRequires: vala |
3d3d7bd6 JP |
48 | BuildRequires: xorg-lib-libX11-devel |
49 | BuildRequires: xorg-lib-libXdmcp-devel | |
e8d8d6ad ER |
50 | BuildRequires: xz |
51 | BuildRequires: yelp-tools | |
f4c63304 ER |
52 | %if %{with qt4} |
53 | BuildRequires: QtCore-devel | |
54 | BuildRequires: QtDBus-devel | |
55 | BuildRequires: QtGui-devel | |
56 | BuildRequires: qt4-build | |
57 | %endif | |
58 | %if %{with qt5} | |
59 | BuildRequires: Qt5Core-devel | |
60 | BuildRequires: Qt5DBus-devel | |
61 | BuildRequires: Qt5Gui-devel | |
62 | BuildRequires: qt5-build | |
63 | %endif | |
26ddca36 | 64 | Requires: /usr/bin/X |
e8d8d6ad | 65 | Requires: dbus-x11 |
d1bb4d34 | 66 | Requires: lightdm-greeter |
9e848167 | 67 | Requires: xinitrc-ng >= 1.1-2 |
e476a337 | 68 | Provides: XDM |
d1bb4d34 JP |
69 | Provides: group(xdm) |
70 | Provides: user(xdm) | |
c5b54d7b ZU |
71 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
72 | ||
73 | %description | |
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) | |
80 | ||
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) | |
88 | ||
8b528774 ER |
89 | %package libs-gobject |
90 | Summary: LightDM GObject client library | |
9bc4da5d | 91 | Group: Libraries |
8b528774 | 92 | Obsoletes: lightdm-libs < 1.7.0-0.6 |
9bc4da5d | 93 | |
8b528774 ER |
94 | %description libs-gobject |
95 | This package contains a GObject based library for LightDM clients to | |
96 | use to interface with LightDM. | |
9bc4da5d | 97 | |
8b528774 ER |
98 | %package libs-gobject-devel |
99 | Summary: Development files for %{name}-gobject | |
c5b54d7b | 100 | Group: Development/Libraries |
8b528774 ER |
101 | Group: Libraries |
102 | Requires: %{name}-libs-gobject = %{version}-%{release} | |
103 | ||
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. | |
107 | ||
3d3d7bd6 JP |
108 | %package libs-qt4 |
109 | Summary: LightDM Qt4 client library | |
8b528774 | 110 | Group: Libraries |
3d3d7bd6 | 111 | Obsoletes: lightdm-libs-qt |
8b528774 | 112 | Conflicts: lightdm-libs < 1.7.0-0.6 |
c5b54d7b | 113 | |
3d3d7bd6 JP |
114 | %description libs-qt4 |
115 | This package contains a Qt4 based library for LightDM clients to use | |
116 | to interface with LightDM. | |
c5b54d7b | 117 | |
3d3d7bd6 JP |
118 | %package libs-qt4-devel |
119 | Summary: Development files for %{name}-qt4 | |
c5b54d7b | 120 | Group: Development/Libraries |
3d3d7bd6 JP |
121 | Requires: %{name}-libs-qt4 = %{version}-%{release} |
122 | Obsoletes: lightdm-libs-qt-devel | |
c5b54d7b | 123 | |
3d3d7bd6 JP |
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. | |
127 | ||
128 | %package libs-qt5 | |
129 | Summary: LightDM Qt5 client library | |
130 | Group: Libraries | |
131 | ||
132 | %description libs-qt5 | |
133 | This package contains a Qt5 based library for LightDM clients to use | |
134 | to interface with LightDM. | |
135 | ||
136 | %package libs-qt5-devel | |
137 | Summary: Development files for %{name}-qt5 | |
138 | Group: Development/Libraries | |
139 | Requires: %{name}-libs-qt5 = %{version}-%{release} | |
140 | ||
141 | %description libs-qt5-devel | |
142 | This package contains development files for a Qt5 based library for | |
8b528774 | 143 | LightDM clients to use to interface with LightDM. |
c5b54d7b | 144 | |
c5b54d7b ZU |
145 | %package apidocs |
146 | Summary: lightdm API documentation | |
147 | Group: Documentation | |
77a840c7 ER |
148 | %if "%{_rpmversion}" >= "5" |
149 | BuildArch: noarch | |
150 | %endif | |
c5b54d7b ZU |
151 | |
152 | %description apidocs | |
153 | lightdm API documentation. | |
154 | ||
aeb930bc ER |
155 | %package init |
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 | |
165 | Conflicts: upstart < 0.6 | |
008e6bad | 166 | |
aeb930bc ER |
167 | %description init |
168 | Init script for Lightdm. | |
008e6bad | 169 | |
aeb930bc ER |
170 | %description init -l pl.UTF-8 |
171 | Skrypt init dla Lightdm-a. | |
008e6bad | 172 | |
c5b54d7b ZU |
173 | %prep |
174 | %setup -q | |
4f2b8153 ER |
175 | %patch0 -p1 |
176 | %patch1 -p1 | |
f320953a | 177 | %patch2 -p1 |
3d3d7bd6 | 178 | %patch3 -p0 |
c5b54d7b ZU |
179 | |
180 | %build | |
768f7b75 | 181 | %{__libtoolize} |
a84ee4bd | 182 | %{__gtkdocize} |
768f7b75 ZU |
183 | %{__aclocal} |
184 | %{__autoconf} | |
185 | %{__autoheader} | |
186 | %{__automake} | |
187 | %configure \ | |
d1bb4d34 | 188 | --disable-silent-rules \ |
8b528774 | 189 | --disable-static \ |
8afa832f | 190 | %{__enable tests} \ |
3d3d7bd6 | 191 | --enable-liblightdm-gobject \ |
f4c63304 ER |
192 | %{?with_qt4:--enable-liblightdm-qt} \ |
193 | %{?with_qt5:--enable-liblightdm-qt5} \ | |
48783655 | 194 | --with-html-dir=%{_gtkdocdir} \ |
6330239a | 195 | --enable-gtk-doc \ |
862615aa | 196 | --with-greeter-session=lightdm-gtk-greeter \ |
d1bb4d34 | 197 | --with-greeter-user=xdm |
c5b54d7b | 198 | %{__make} |
8afa832f | 199 | %{?with_tests:%{__make} check} |
c5b54d7b ZU |
200 | |
201 | %install | |
202 | rm -rf $RPM_BUILD_ROOT | |
c5b54d7b | 203 | %{__make} install \ |
8afa832f | 204 | INSTALL='install -p' \ |
c5b54d7b ZU |
205 | DESTDIR=$RPM_BUILD_ROOT |
206 | ||
aeb930bc | 207 | install -d $RPM_BUILD_ROOT/etc/{pam.d,security,init,rc.d/init.d,dbus-1/system.d} \ |
8afa832f | 208 | $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/%{name}.conf.d \ |
d1bb4d34 | 209 | $RPM_BUILD_ROOT/home/services/xdm \ |
96fe17ec | 210 | $RPM_BUILD_ROOT%{_datadir}/xgreeters \ |
8afa832f | 211 | $RPM_BUILD_ROOT%{_datadir}/%{name}/{remote-sessions,%{name}.conf.d} \ |
aeb930bc | 212 | $RPM_BUILD_ROOT%{systemdunitdir} \ |
1281c6a0 | 213 | $RPM_BUILD_ROOT/var/lib/%{name}-data \ |
8afa832f ER |
214 | $RPM_BUILD_ROOT/var/{log,cache}/%{name} |
215 | ||
216 | install -d $RPM_BUILD_ROOT{/var/run/lightdm,%{systemdtmpfilesdir}} | |
217 | cp -p %{SOURCE5} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/lightdm.conf | |
96fe17ec | 218 | |
aeb930bc ER |
219 | # initscripts |
220 | cp -p data/init/%{name}.conf $RPM_BUILD_ROOT/etc/init | |
8afa832f ER |
221 | install -p %{SOURCE4} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name} |
222 | ln -s /dev/null $RPM_BUILD_ROOT%{systemdunitdir}/%{name}.service | |
aeb930bc | 223 | |
8afa832f | 224 | cp -p %{SOURCE1} $RPM_BUILD_ROOT/etc/pam.d/%{name} |
9affbe56 ER |
225 | cp -p %{SOURCE2} $RPM_BUILD_ROOT/etc/pam.d/lightdm-autologin |
226 | cp -p %{SOURCE3} $RPM_BUILD_ROOT/etc/pam.d/lightdm-greeter | |
8afa832f | 227 | touch $RPM_BUILD_ROOT/etc/security/blacklist.%{name} |
d1bb4d34 | 228 | |
e8d8d6ad | 229 | # We don't ship AppAmor |
aeb930bc | 230 | rm -rv $RPM_BUILD_ROOT/etc/apparmor.d |
e8d8d6ad | 231 | |
d1bb4d34 JP |
232 | %{__rm} -r $RPM_BUILD_ROOT%{_localedir}/{lb,wae} |
233 | ||
a84ee4bd | 234 | %find_lang %{name} --with-gnome |
6330239a | 235 | |
c5b54d7b ZU |
236 | %clean |
237 | rm -rf $RPM_BUILD_ROOT | |
238 | ||
d1bb4d34 JP |
239 | %pre |
240 | %groupadd -g 55 -r -f xdm | |
241 | %useradd -u 55 -r -d /home/services/xdm -s /bin/false -c "X Display Manager" -g xdm xdm | |
242 | ||
1862114d ER |
243 | %postun |
244 | if [ "$1" = "0" ]; then | |
245 | %userremove xdm | |
246 | %groupremove xdm | |
247 | fi | |
248 | ||
8b528774 ER |
249 | %post libs-gobject -p /sbin/ldconfig |
250 | %postun libs-gobject -p /sbin/ldconfig | |
251 | ||
3d3d7bd6 JP |
252 | %post libs-qt4 -p /sbin/ldconfig |
253 | %postun libs-qt4 -p /sbin/ldconfig | |
254 | ||
255 | %post libs-qt5 -p /sbin/ldconfig | |
256 | %postun libs-qt5 -p /sbin/ldconfig | |
6330239a | 257 | |
aeb930bc ER |
258 | %post init |
259 | /sbin/chkconfig --add %{name} | |
260 | %service -n %{name} restart | |
261 | %upstart_post %{name} | |
262 | %systemd_reload | |
263 | ||
264 | %preun | |
265 | if [ "$1" = "0" ]; then | |
266 | /sbin/chkconfig --del %{name} | |
267 | %service %{name} stop | |
268 | fi | |
008e6bad | 269 | |
aeb930bc ER |
270 | %postun init |
271 | %systemd_reload | |
272 | %upstart_postun %{name} | |
008e6bad | 273 | |
d1bb4d34 | 274 | %files -f %{name}.lang |
c5b54d7b | 275 | %defattr(644,root,root,755) |
eff0aaee | 276 | %doc NEWS |
933e01e3 | 277 | %dir %{_sysconfdir}/%{name} |
8afa832f | 278 | %dir %{_sysconfdir}/%{name}/%{name}.conf.d |
933e01e3 ER |
279 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/%{name}.conf |
280 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/keys.conf | |
281 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/users.conf | |
8afa832f | 282 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/%{name} |
15907466 BZ |
283 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/lightdm-autologin |
284 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/lightdm-greeter | |
8afa832f | 285 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/security/blacklist.%{name} |
933e01e3 ER |
286 | /etc/dbus-1/system.d/org.freedesktop.DisplayManager.conf |
287 | %attr(755,root,root) %{_bindir}/dm-tool | |
d1bb4d34 | 288 | %attr(755,root,root) %{_sbindir}/lightdm |
8afa832f | 289 | %attr(755,root,root) %{_libdir}/lightdm-guest-session |
d1bb4d34 | 290 | %{_libdir}/girepository-1.0/LightDM-1.typelib |
8afa832f | 291 | %{systemdtmpfilesdir}/lightdm.conf |
d1bb4d34 | 292 | %dir %{_datadir}/xgreeters |
8028cf24 ER |
293 | %dir %{_datadir}/%{name} |
294 | %dir %{_datadir}/%{name}/remote-sessions | |
8afa832f ER |
295 | %dir %{_datadir}/%{name}/%{name}.conf.d |
296 | %{_mandir}/man1/dm-tool.1* | |
297 | %{_mandir}/man1/%{name}.1* | |
298 | %dir %attr(710,root,root) /var/cache/%{name} | |
299 | %dir %attr(710,root,root) /var/log/%{name} | |
300 | %dir %attr(770,root,root) /var/run/%{name} | |
1281c6a0 | 301 | %dir %attr(700,root,root) /var/lib/%{name}-data |
d27af43d | 302 | %dir %attr(750,xdm,xdm) /home/services/xdm |
d1bb4d34 | 303 | |
8b528774 | 304 | %files libs-gobject |
9bc4da5d ER |
305 | %defattr(644,root,root,755) |
306 | %attr(755,root,root) %{_libdir}/liblightdm-gobject-1.so.*.*.* | |
307 | %attr(755,root,root) %ghost %{_libdir}/liblightdm-gobject-1.so.0 | |
9bc4da5d | 308 | |
f4c63304 | 309 | %if %{with qt4} |
3d3d7bd6 | 310 | %files libs-qt4 |
c5b54d7b | 311 | %defattr(644,root,root,755) |
8b528774 ER |
312 | %attr(755,root,root) %{_libdir}/liblightdm-qt-3.so.*.*.* |
313 | %attr(755,root,root) %ghost %{_libdir}/liblightdm-qt-3.so.0 | |
c5b54d7b | 314 | |
f4c63304 ER |
315 | %files libs-qt4-devel |
316 | %defattr(644,root,root,755) | |
317 | %{_libdir}/liblightdm-qt-3.la | |
318 | %attr(755,root,root) %{_libdir}/liblightdm-qt-3.so | |
319 | %{_includedir}/lightdm-qt-3 | |
320 | %{_pkgconfigdir}/liblightdm-qt-3.pc | |
321 | %endif | |
322 | ||
323 | %if %{with qt5} | |
3d3d7bd6 JP |
324 | %files libs-qt5 |
325 | %defattr(644,root,root,755) | |
326 | %attr(755,root,root) %{_libdir}/liblightdm-qt5-3.so.*.*.* | |
327 | %attr(755,root,root) %ghost %{_libdir}/liblightdm-qt5-3.so.0 | |
328 | ||
f4c63304 ER |
329 | %files libs-qt5-devel |
330 | %defattr(644,root,root,755) | |
331 | %{_libdir}/liblightdm-qt5-3.la | |
332 | %attr(755,root,root) %{_libdir}/liblightdm-qt5-3.so | |
333 | %{_includedir}/lightdm-qt5-3 | |
334 | %{_pkgconfigdir}/liblightdm-qt5-3.pc | |
335 | %endif | |
336 | ||
8b528774 | 337 | %files libs-gobject-devel |
c5b54d7b | 338 | %defattr(644,root,root,755) |
eccfdb7d | 339 | %{_datadir}/gir-1.0/LightDM-1.gir |
d1bb4d34 | 340 | %{_includedir}/lightdm-gobject-1 |
d1bb4d34 | 341 | %{_pkgconfigdir}/liblightdm-gobject-1.pc |
eccfdb7d ER |
342 | %{_libdir}/liblightdm-gobject-1.la |
343 | %attr(755,root,root) %{_libdir}/liblightdm-gobject-1.so | |
344 | # -vala | |
d1bb4d34 | 345 | %{_datadir}/vala/vapi/liblightdm-gobject-1.vapi |
8b528774 | 346 | |
c5b54d7b ZU |
347 | %files apidocs |
348 | %defattr(644,root,root,755) | |
48783655 | 349 | %{_gtkdocdir}/lightdm-gobject-1 |
008e6bad | 350 | |
aeb930bc | 351 | %files init |
008e6bad | 352 | %defattr(644,root,root,755) |
aeb930bc | 353 | %attr(754,root,root) /etc/rc.d/init.d/%{name} |
0139fe42 | 354 | %config(noreplace) %verify(not md5 mtime size) /etc/init/%{name}.conf |
8afa832f | 355 | %{systemdunitdir}/%{name}.service |