]> git.pld-linux.org Git - packages/dbus.git/blob - dbus.spec
- rel 3
[packages/dbus.git] / dbus.spec
1 #
2 # TODO:
3 #       - fix .la files so we don't need to explicitly R: libcap-devel in devel package
4 #
5 %define         expat_version   1:1.95.5
6 #
7 Summary:        D-BUS message bus
8 Summary(pl.UTF-8):      Magistrala przesyłania komunikatów D-BUS
9 Name:           dbus
10 Version:        1.1.2
11 Release:        3
12 License:        AFL v2.1 or GPL v2
13 Group:          Libraries
14 Source0:        http://dbus.freedesktop.org/releases/dbus/%{name}-%{version}.tar.gz
15 # Source0-md5:  e33d96a4c4605536127835a70b14d5b9
16 Source1:        messagebus.init
17 Source2:        %{name}-daemon-1-profile.d-sh
18 Source3:        %{name}-sysconfig
19 Source4:        %{name}-xinitrc.sh
20 Patch0:         %{name}-nolibs.patch
21 Patch1:         %{name}-config.patch
22 Patch2:         %{name}-no_fatal_checks.patch
23 Patch3:         %{name}-geteuid.patch
24 URL:            http://www.freedesktop.org/Software/dbus
25 BuildRequires:  audit-libs-devel
26 BuildRequires:  autoconf >= 2.52
27 BuildRequires:  automake
28 BuildRequires:  doxygen
29 BuildRequires:  expat-devel >= %{expat_version}
30 BuildRequires:  libcap-devel
31 BuildRequires:  libselinux-devel
32 BuildRequires:  libtool
33 BuildRequires:  pkgconfig
34 BuildRequires:  rpmbuild(macros) >= 1.268
35 BuildRequires:  sed >= 4.0
36 BuildRequires:  xmlto
37 BuildRequires:  xorg-lib-libX11-devel
38 Requires(post,postun):  /sbin/ldconfig
39 Requires(post,preun):   /sbin/chkconfig
40 Requires(postun):       /usr/sbin/groupdel
41 Requires(postun):       /usr/sbin/userdel
42 Requires(pre):  /bin/id
43 Requires(pre):  /usr/bin/getgid
44 Requires(pre):  /usr/sbin/groupadd
45 Requires(pre):  /usr/sbin/useradd
46 Requires:       %{name}-libs = %{version}-%{release}
47 Requires:       rc-scripts
48 Provides:       group(messagebus)
49 Provides:       user(messagebus)
50 Conflicts:      pam < 0.99.7.1
51 Obsoletes:      dbus-X11
52 Obsoletes:      dbus-glib-tools
53 # not available for dbus 0.9x yet(?)
54 #Obsoletes:     dbus-gtk dbus-gcj dbus-gcj-devel dbus-gcj-static
55 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
56
57 %description
58 D-BUS is a system for sending messages between applications. It is
59 used both for the systemwide message bus service, and as a
60 per-user-login-session messaging facility.
61
62 %description -l pl.UTF-8
63 D-BUS to system przesyłania komunikatów pomiędzy aplikacjami. Jest
64 używany zarówno jako ogólnosystemowa usługa magistrali komunikatów jak
65 i możliwość przesyłania komunikatów w ramach jednej sesji użytkownika.
66
67 %package libs
68 Summary:        D-BUS libraries
69 Summary(pl.UTF-8):      Biblioteki D-BUS
70 Group:          Libraries
71
72 %description libs
73 D-BUS libraries.
74
75 %description libs -l pl.UTF-8
76 Biblioteki D-BUS.
77
78 %package devel
79 Summary:        Header files for D-BUS
80 Summary(pl.UTF-8):      Pliki nagłówkowe D-BUS
81 Group:          Development/Libraries
82 Requires:       %{name}-libs = %{version}-%{release}
83 Requires:       audit-libs-devel
84 Requires:       libcap-devel
85
86 %description devel
87 Header files for D-BUS.
88
89 %description devel -l pl.UTF-8
90 Pliki nagłówkowe D-BUS.
91
92 %package static
93 Summary:        Static D-BUS libraries
94 Summary(pl.UTF-8):      Statyczne biblioteki D-BUS
95 Group:          Development/Libraries
96 Requires:       %{name}-devel = %{version}-%{release}
97
98 %description static
99 Static D-BUS libraries.
100
101 %description static -l pl.UTF-8
102 Statyczne biblioteki D-BUS.
103
104 %prep
105 %setup -q
106 %patch0 -p1
107 %patch1 -p1
108 %patch2 -p1
109 %patch3 -p1
110
111 %build
112 %{__libtoolize}
113 %{__aclocal}
114 %{__autoconf}
115 %{__autoheader}
116 %{__automake}
117 %configure \
118         %{?debug:--enable-verbose-mode} \
119         --disable-asserts \
120         --disable-tests \
121         --enable-abstract-sockets \
122         --enable-selinux \
123         --with-console-auth-dir=%{_localstatedir}/run/console/ \
124         --with-session-socket-dir=/tmp \
125         --with-system-pid-file=%{_localstatedir}/run/dbus.pid \
126         --with-xml=expat
127 %{__make}
128
129 %install
130 rm -rf $RPM_BUILD_ROOT
131 install -d $RPM_BUILD_ROOT/etc/profile.d
132 install -d $RPM_BUILD_ROOT/etc/rc.d/init.d
133 install -d $RPM_BUILD_ROOT/etc/sysconfig
134 install -d $RPM_BUILD_ROOT/etc/X11/xinit/xinitrc.d
135 install -d $RPM_BUILD_ROOT%{_datadir}/dbus-1/services
136 install -d $RPM_BUILD_ROOT%{_localstatedir}/run/dbus
137
138 %{__make} install \
139         DESTDIR=$RPM_BUILD_ROOT
140
141 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/messagebus
142 install %{SOURCE2} $RPM_BUILD_ROOT/etc/profile.d/dbus-daemon-1.sh
143 install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/messagebus
144 install %{SOURCE4} $RPM_BUILD_ROOT/etc/X11/xinit/xinitrc.d
145
146 %clean
147 rm -rf $RPM_BUILD_ROOT
148
149 %pre
150 %groupadd -g 122 messagebus
151 %useradd -u 122 -d /usr/share/empty -s /bin/false -c "System message bus" -g 122 messagebus
152
153 %post
154 /sbin/chkconfig --add messagebus
155 %service messagebus restart "D-Bus daemon"
156
157 %preun
158 if [ "$1" = "0" ];then
159         %service messagebus stop
160         /sbin/chkconfig --del messagebus
161 fi
162
163 %postun
164 if [ "$1" = "0" ]; then
165         %userremove messagebus
166         %groupremove messagebus
167 fi
168
169 %post   libs -p /sbin/ldconfig
170 %postun libs -p /sbin/ldconfig
171
172 %triggerpostun -- %{name} < 0.92
173 %banner %{name} << EOF
174 WARNING!!!
175 configuration file /etc/sysconfig/dbus has been moved to /etc/sysconfig/messagebus!
176 EOF
177
178 if [ -f /etc/sysconfig/dbus ]; then
179         mv -f /etc/sysconfig/messagebus{,.rpmnew}
180         mv -f /etc/sysconfig/{dbus,messagebus}
181 elif [ -f /etc/sysconfig/dbus.rpmsave ]; then
182         mv -f /etc/sysconfig/messagebus{,.rpmnew}
183         mv -f /etc/sysconfig/{dbus.rpmsave,messagebus}
184 fi
185
186 %files
187 %defattr(644,root,root,755)
188 %attr(755,root,root) %{_bindir}/dbus-cleanup-sockets
189 %attr(755,root,root) %{_bindir}/dbus-daemon
190 %attr(755,root,root) %{_bindir}/dbus-uuidgen
191 # R: libX11
192 %attr(755,root,root) %{_bindir}/dbus-launch
193 %attr(755,root,root) %{_bindir}/dbus-monitor
194 %attr(755,root,root) %{_bindir}/dbus-send
195 %dir %{_sysconfdir}/dbus-1
196 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/dbus-1/*.conf
197 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/messagebus
198 %attr(754,root,root) /etc/rc.d/init.d/*
199 %attr(755,root,root) /etc/profile.d/dbus-daemon-1.sh
200 %attr(755,root,root) /etc/X11/xinit/xinitrc.d/*.sh
201
202 %dir %{_sysconfdir}/dbus-1/system.d
203 %dir %{_sysconfdir}/dbus-1/session.d
204 %dir %{_datadir}/dbus-1
205 %dir %{_datadir}/dbus-1/services
206 %dir %{_datadir}/dbus-1/system-services
207 %dir %{_localstatedir}/run/dbus
208 %dir /var/lib/dbus
209 %{_mandir}/man1/dbus-cleanup-sockets.1*
210 %{_mandir}/man1/dbus-daemon.1*
211 %{_mandir}/man1/dbus-uuidgen.1*
212 %{_mandir}/man1/dbus-launch.1*
213 %{_mandir}/man1/dbus-monitor.1*
214 %{_mandir}/man1/dbus-send.1*
215
216 %files libs
217 %defattr(644,root,root,755)
218 %doc AUTHORS COPYING ChangeLog NEWS README doc/TODO
219 %attr(755,root,root) %{_libdir}/libdbus-1.so.*.*.*
220 %dir %{_libdir}/dbus-*
221
222 %files devel
223 %defattr(644,root,root,755)
224 %doc doc/*.{html,txt}
225 %attr(755,root,root) %{_libdir}/libdbus-1.so
226 %{_libdir}/libdbus-1.la
227 %{_libdir}/dbus-*/include
228 %{_pkgconfigdir}/dbus-1.pc
229 %{_includedir}/dbus*
230
231 %files static
232 %defattr(644,root,root,755)
233 %{_libdir}/libdbus-1.a
This page took 0.102951 seconds and 3 git commands to generate.