File udisks.spec of Package udisks

#
# spec file for package udisks (Version 1.0.2)
#
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#

# norootforbuild


Name:           udisks
Version:        1.0.2
Release:        1
License:        GPLv2+
Summary:        Disk Management Service
Url:            http://cgit.freedesktop.org/udisks/
Group:          System/Daemons
Source:         %{name}-%{version}.tar.bz2
# Need this one until bnc#504064 has been resolved -- mboman@suse.de
Source2:        umount.udisks
Obsoletes:      DeviceKit-disks <= 009
Provides:       DeviceKit-disks = 009
# avahi BuildRequires is solely for directory ownerships.
BuildRequires:  avahi
BuildRequires:  dbus-1-glib-devel
#BuildRequires:  device-mapper-devel
BuildRequires:  gtk-doc
BuildRequires:  intltool
BuildRequires:  libatasmart-devel
BuildRequires:  libgudev-1_0-devel
BuildRequires:  parted-devel
BuildRequires:  polkit-devel
BuildRequires:  sg3_utils-devel
#BuildRequires:  sqlite3-devel
# udev BuildRequires is solely for directory ownerships.
BuildRequires:  udev
#BuildRequires:  zlib-devel
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
udisks provides a daemon, D-Bus API and command line tools
for managing disks and storage devices.

%package devel
License:        GPLv2+
Summary:        Disk Management Service - Development Files
Group:          Development/Libraries/Other
Requires:       %{name} = %{version}
Requires:       glib2-devel
Provides:       DeviceKit-disks-devel = 009
Obsoletes:      DeviceKit-disks-devel <= 009

%description devel
udisks provides a daemon, D-Bus API and command line tools
for managing disks and storage devices.

%prep
%setup -q

%build
export V=1
%configure \
  --enable-gtk-doc \
  --disable-static \
  --libexecdir=%{_prefix}/lib/udisks
make %{?_smp_mflags}

%install
%makeinstall
find %{buildroot}%{_libdir} -name '*.la' -delete -print
# Not allowed to install into /sbin so move it to /usr/sbin (see bnc#504064)
mkdir -p %{buildroot}%{_sbindir}
mv %{buildroot}/sbin/umount.udisks %{buildroot}%{_sbindir}
cp %{S:2} %{buildroot}/sbin/
%find_lang %{name}

%clean
rm -rf %{buildroot}

%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

%files -f %{name}.lang
%defattr(-,root,root,-)
%doc AUTHORS COPYING NEWS README
/lib/udev/udisks-*
/lib/udev/rules.d/80-udisks.rules
%{_bindir}/udisks
%{_bindir}/udisks-tcp-bridge
%{_prefix}/lib/udisks
%{_libdir}/polkit-1/extensions/libudisks-action-*.so
%attr(0755,root,root) /sbin/umount.udisks
%{_sbindir}/umount.udisks
%{_datadir}/polkit-1/actions/*.policy
%{_datadir}/dbus-1/system-services/*.service
%{_sysconfdir}/dbus-1/system.d/*.conf
%attr(0644,root,root) %{_sysconfdir}/profile.d/udisks-bash-completion.sh
%{_sysconfdir}/avahi/services/udisks.service
%doc %{_mandir}/man?/*.*
%attr(0770,root,root) %dir %{_localstatedir}/lib/udisks

%files devel
%defattr(-,root,root,-)
%{_datadir}/pkgconfig/udisks.pc
%doc %{_datadir}/gtk-doc/html/udisks
%{_datadir}/dbus-1/interfaces/*.xml

%changelog
openSUSE Build Service is sponsored by