1 |
%define with_consolekit 1 |
2 |
%define xdm_libdir %{_datadir}/X11/xdm |
3 |
Name: xdm |
4 |
Version: 1.1.11 |
5 |
Release: %mkrel 2 |
6 |
Summary: X Display Manager with support for XDMCP |
7 |
Group: System/X11 |
8 |
URL: http://xorg.freedesktop.org |
9 |
Source: http://xorg.freedesktop.org/releases/individual/app/%{name}-%{version}.tar.bz2 |
10 |
Source1: xdm.pamd |
11 |
#Patch0: xdm-1.1.10-link.patch |
12 |
License: MIT |
13 |
|
14 |
BuildRequires: libx11-devel >= 1.0.0 |
15 |
BuildRequires: libxau-devel >= 1.0.0 |
16 |
BuildRequires: libxdmcp-devel >= 1.0.0 |
17 |
BuildRequires: libxmu-devel >= 1.0.0 |
18 |
BuildRequires: libxt-devel >= 1.0.0 |
19 |
BuildRequires: libxaw-devel >= 1.0.1 |
20 |
BuildRequires: x11-util-macros >= 1.0.1 |
21 |
BuildRequires: libpam-devel |
22 |
%if %{with_consolekit} |
23 |
BuildRequires: consolekit-devel |
24 |
BuildRequires: libdbus-devel |
25 |
BuildRequires: x11-util-macros >= 1.3.0 |
26 |
%endif |
27 |
Requires: xinitrc > 2.4.19-9 |
28 |
Requires: xrdb |
29 |
Requires: sessreg |
30 |
Conflicts: xorg-x11 < 7.0 |
31 |
|
32 |
Patch4: 0004-Support-kdm-extended-syntax-to-reserve-a-server-for.patch |
33 |
#Patch5: 0005-Initialize-the-greeter-only-after-checking-if-the-th.patch |
34 |
Patch6: 0006-Add-console-kit-support-to-xdm.patch |
35 |
Patch7: 0007-Add-files-required-by-consolekit-support.patch |
36 |
|
37 |
%description |
38 |
Xdm manages a collection of X displays, which may be on the local host or |
39 |
remote servers. The design of xdm was guided by the needs of X terminals as |
40 |
well as The Open Group standard XDMCP, the X Display Manager Control Protocol. |
41 |
Xdm provides services similar to those provided by init, getty and login on |
42 |
character terminals: prompting for login name and password, authenticating the |
43 |
user, and running a session. |
44 |
|
45 |
%prep |
46 |
%setup -q -n %{name}-%{version} |
47 |
%apply_patches |
48 |
|
49 |
%build |
50 |
# patch 6 requires autoreconf |
51 |
autoreconf -v --install |
52 |
%configure2_5x \ |
53 |
--x-includes=%{_includedir}\ |
54 |
--x-libraries=%{_libdir} \ |
55 |
%if %{with_consolekit} |
56 |
--with-consolekit \ |
57 |
%endif |
58 |
--with-xdmlibdir=%{xdm_libdir} \ |
59 |
--enable-xdmshell \ |
60 |
--with-pam \ |
61 |
--with-systemdsystemunitdir=%_unitdir |
62 |
|
63 |
%make |
64 |
|
65 |
%install |
66 |
%makeinstall_std |
67 |
|
68 |
LC_ALL=C |
69 |
LANG=C |
70 |
export LC_ALL LANG |
71 |
|
72 |
# remove files that are in xinitrc |
73 |
rm -rf %{buildroot}%{xdm_libdir}/{[A-Z]*,xdm-config} |
74 |
|
75 |
# remove unused devel files |
76 |
rm -rf %{buildroot}%{xdm_libdir}/*.{a,la} |
77 |
|
78 |
# install PAM file |
79 |
mkdir -p %{buildroot}%{_sysconfdir}/pam.d |
80 |
install -m 644 %{_sourcedir}/xdm.pamd $RPM_BUILD_ROOT/etc/pam.d/xdm |
81 |
|
82 |
install -d %{buildroot}/var/lib/xdm |
83 |
ln -sf /var/lib/xdm %{buildroot}%{xdm_libdir}/authdir |
84 |
|
85 |
# logrotate |
86 |
mkdir -p %{buildroot}%{_sysconfdir}/logrotate.d |
87 |
cat << EOF > %{buildroot}%{_sysconfdir}/logrotate.d/xdm |
88 |
/var/log/xdm-error.log { |
89 |
notifempty |
90 |
missingok |
91 |
nocompress |
92 |
} |
93 |
EOF |
94 |
|
95 |
%pre |
96 |
if [ -d %{xdm_libdir}/authdir ]; then |
97 |
# this is now a symlink |
98 |
rm -rf %{xdm_libdir}/authdir |
99 |
fi |
100 |
|
101 |
%files |
102 |
%config(noreplace) %{_sysconfdir}/pam.d/xdm |
103 |
%config(noreplace) %{_sysconfdir}/logrotate.d/xdm |
104 |
%dir /var/lib/xdm |
105 |
%{_bindir}/xdm |
106 |
%{_bindir}/xdmshell |
107 |
%{_mandir}/man1/xdm*.* |
108 |
%{xdm_libdir}/* |
109 |
%{_datadir}/X11/app-defaults/Chooser |
110 |
%_unitdir/xdm.service |