Репозиторий Sisyphus
Последнее обновление: 21 октября 2019 | Пакетов: 17508 | Посещений: 15303949
en ru br
Репозитории ALT
5.1: 1.2.16-alt2
4.1: 1.2.12-alt1.M41.1
4.0: 1.0.3-alt1.M40.2
3.0: 0.36.2-alt1

Другие репозитории

Группа :: Система/Серверы
Пакет: dbus

 Главная   Изменения   Спек   Патчи   Sources   Загрузить   Gear   Bugs and FR  Repocop 

%define dbus_user      messagebus
%define dbus_group     messagebus

%define system_socket_dir /run/dbus
%define session_socket_dir %system_socket_dir/users
%define system_socket %system_socket_dir/system_bus_socket
%define systemdsystemunitdir /lib/systemd/system
%define systemdsessionunitdir %_prefix/lib/systemd/user

Name: dbus
Version: 1.12.12
Release: alt1

Summary: D-BUS is a simple IPC framework based on messages.
License: AFL/GPL
Group: System/Servers
Url: http://www.freedesktop.org/Software/dbus

Packager: Valery Inozemtsev <shrek at altlinux.ru>

PreReq: shadow-utils
Requires: lib%name = %version-%release

BuildRequires: autoconf-archive doxygen gcc-c++ libexpat-devel libSM-devel libX11-devel xmlto libselinux-devel libaudit-devel libcap-ng-devel
BuildRequires: libsystemd-daemon-devel libsystemd-login-devel libsystemd-journal-devel

Source: %name-%version.tar
Patch: %name-%version.patch

D-BUS is a system for low-latency, low-overhead, easy to use interprocess
communication (IPC). In more detail:

 o D-BUS is low-latency because it is designed to avoid round trips and
   allow asynchronous operation, much like the X protocol.

 o D-BUS is low-overhead because it uses a binary protocol, and does not
   have to convert to and from a text format such as XML. Because D-BUS is
   intended for potentially high-resolution same-machine IPC, not primarily
   for Internet IPC, this is an interesting optimization.

 o D-BUS is easy to use because it works in terms of messages rather than
   byte streams, and automatically handles a lot of the hard IPC issues.
   Also, the D-BUS library is designed to be wrapped in a way that lets
   developers use their framework's existing object/type system, rather
   than learning a new one specifically for IPC.

This package contains D-BUS daemon and system utilities.

%package tools
Summary: D-BUS user helper tools
Group: Monitoring
Requires: %name = %version-%release
Provides: dbus-userhelpers = %version-%release
Obsoletes: dbus-userhelpers

%description tools
This package includes user tools for launching D-BUS service on session startup

%package tools-gui
Summary:  D-BUS user helper tools
Group: Monitoring
Requires: %name = %version-%release

%description tools-gui
This package includes user tools for launching D-BUS service on session startup

%package -n lib%name
Summary: D-BUS shared libraries
Group: System/Libraries

%description -n lib%name
This package contains D-BUS shared libraries

%package -n lib%name-devel
Summary: D-BUS development files
Group: Development/C
Requires: lib%name = %version-%release
%description -n lib%name-devel
This package contains D-BUS development files (headers and libraries links)

%add_findreq_skiplist %_x11sysconfdir/xinit.d/*

%setup -q
%patch -p1

mkdir -p m4

%configure \
--disable-tests \
--disable-asserts \
--enable-xml-docs \
--enable-doxygen-docs \
--enable-inotify \
--enable-libaudit \
--enable-selinux \
--enable-systemd \
--enable-user-session \
--bindir=/bin \
--libexecdir=/lib/dbus-1 \
--with-system-pid-file=/run/messagebus.pid \
--with-system-socket=%system_socket \
--with-session-socket-dir=%session_socket_dir \
--with-systemdsystemunitdir=%systemdsystemunitdir \
--localstatedir=%_var \


doxygen Doxyfile

%make DESTDIR=%buildroot install

mkdir -p %buildroot/{%_lib,%_bindir}
for f in %buildroot%_libdir/lib*.so; do
t=$(readlink "$f")
ln -sf ../../%_lib/"$t" "$f"
mv %buildroot%_libdir/lib*.so.* %buildroot/%_lib/
ln -sf ../../bin/dbus-launch %buildroot%_bindir/dbus-launch
ln -sf ../../bin/dbus-send %buildroot%_bindir/dbus-send
ln -sf dbus.service %buildroot/lib/systemd/system/messagebus.service

install -pD -m0755 bus/messagebus.in %buildroot%_initdir/messagebus

cp -a doc/api/html api

mkdir -p %buildroot%_sysconfdir/dbus-1/system.d
mkdir -p %buildroot%_sysconfdir/dbus-1/session.d
mkdir -p %buildroot%_datadir/dbus-1/interfaces
mkdir -p %buildroot%system_socket_dir
mkdir -p %buildroot%session_socket_dir
mkdir -p %buildroot%_localstatedir/dbus
touch %buildroot%_localstatedir/dbus/machine-id
touch %buildroot%_sysconfdir/machine-id

mkdir -p %buildroot/lib/tmpfiles.d
cat << __EOF__ > %buildroot/lib/tmpfiles.d/%name.conf
d /run/dbus 0755 root root -
d /run/dbus/users 1777 root root -

%_sbindir/groupadd -r -f %dbus_group 2> /dev/null ||:
%_sbindir/useradd -r -n -g %dbus_group -d %system_socket_dir -s /dev/null -c "D-Bus System User" %dbus_user 2> /dev/null ||:

if [ $1 -eq 1 ] ; then
   /sbin/chkconfig --add messagebus
   /sbin/chkconfig messagebus resetpriorities

/bin/dbus-uuidgen --ensure

#%triggerin -- %name < %version

#service messagebus restart
#/bin/dbus-uuidgen --ensure

%preun_service messagebus

%dir %_sysconfdir/dbus-1
%config(noreplace) %_sysconfdir/dbus-1/*.conf
%dir %_sysconfdir/dbus-1/system.d
%dir %_sysconfdir/dbus-1/session.d
%ghost %_sysconfdir/machine-id
%dir /lib/dbus-1
%attr(4510,root,messagebus) /lib/dbus-1/dbus-daemon-launch-helper
%dir %_datadir/dbus-1
%dir %_datadir/dbus-1/system.d
%dir %_datadir/dbus-1/session.d
%dir %_datadir/dbus-1/services
%dir %_datadir/dbus-1/system-services
#attr(0755,root,root) #dir #system_socket_dir
#attr(1777,root,root) #dir #session_socket_dir
%dir %_localstatedir/dbus
%ghost %_localstatedir/dbus/machine-id

%files tools

%files tools-gui

%files -n lib%name

%files -n lib%name-devel
%dir %_datadir/dbus-1
%dir %_datadir/dbus-1/interfaces


Полный changelog можно просмотреть здесь

дизайн и разработка: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
текущий майнтейнер: Michael Shigorin