File rhythmbox.spec of Package rhythmbox

#
# spec file for package rhythmbox
#
# Copyright (c) 2014 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/
#


%define with_webkit 1
# Enable for openSUSE > 1230 once the right version is in Factory.
%define with_daap 0
#define with_daap 0%{?suse_version} > 1330

Name:           rhythmbox
Version:        3.0.2
Release:        0
Summary:        GNOME Music Management Application
License:        GPL-2.0+
Group:          Productivity/Multimedia/Sound/Players
Url:            http://www.gnome.org/projects/rhythmbox/
Source:         http://download.gnome.org/sources/rhythmbox/3.0/%{name}-%{version}.tar.xz
# PATCH-FIX-UPSTREAM rhythmbox-3.0.1-libsecret018.patch fcrozat@suse.com bgo#725884 -- fix dependency with libsecret 0.18
Patch0:         rhythmbox-3.0.1-libsecret018.patch
BuildRequires:  gobject-introspection-devel
BuildRequires:  intltool
BuildRequires:  libdiscid-devel
BuildRequires:  lirc-devel
BuildRequires:  translation-update-upstream
BuildRequires:  update-desktop-files
BuildRequires:  vala
BuildRequires:  yelp-tools
BuildRequires:  pkgconfig(clutter-1.0) >= 1.8
BuildRequires:  pkgconfig(clutter-gst-2.0)
BuildRequires:  pkgconfig(clutter-gtk-1.0) >= 1.0
BuildRequires:  pkgconfig(clutter-x11-1.0) >= 1.8
BuildRequires:  pkgconfig(grilo-0.2) >= 0.2.0
BuildRequires:  pkgconfig(gstreamer-1.0) >= 0.11.92
BuildRequires:  pkgconfig(gstreamer-audio-1.0) >= 0.11.02
BuildRequires:  pkgconfig(gstreamer-base-1.0) >= 0.11.92
BuildRequires:  pkgconfig(gstreamer-pbutils-1.0) >= 0.11.92
BuildRequires:  pkgconfig(gstreamer-plugins-base-1.0) >= 0.11.92
BuildRequires:  pkgconfig(gtk+-3.0) >= 3.6.0
BuildRequires:  pkgconfig(gudev-1.0)
BuildRequires:  pkgconfig(ice)
BuildRequires:  pkgconfig(json-glib-1.0)
BuildRequires:  pkgconfig(libbrasero-media3)
%if 0%{with_daap}
# rhythmbox requires version 2.9.16, which only appeared after 12.3 release
BuildRequires:  pkgconfig(libdmapsharing-3.0) >= 2.9.19
%endif
BuildRequires:  pkgconfig(libgpod-1.0)
BuildRequires:  pkgconfig(libmtp)
BuildRequires:  pkgconfig(libnotify)
BuildRequires:  pkgconfig(libpeas-1.0) >= 0.7.3
BuildRequires:  pkgconfig(libpeas-gtk-1.0) >= 0.7.3
BuildRequires:  pkgconfig(libsecret-1) >= 0.18
BuildRequires:  pkgconfig(libsoup-2.4) >= 2.34.0
BuildRequires:  pkgconfig(libsoup-gnome-2.4)
BuildRequires:  pkgconfig(pygobject-3.0) >= 3.2.3
BuildRequires:  pkgconfig(sm)
BuildRequires:  pkgconfig(tdb)
BuildRequires:  pkgconfig(totem-plparser) >= 3.2.0
%if %{with_webkit}
BuildRequires:  pkgconfig(webkitgtk-3.0)
%endif
Requires:       gstreamer-plugins-base
Requires:       gstreamer-plugins-good
# For python plugins
Requires:       python3-gobject
Recommends:     %{name}-lang
Recommends:     media-player-info
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
%py_requires
%glib2_gsettings_schema_requires

%description
Music Management application with support for ripping audio-CD's,
playback of Ogg Vorbis and MP3 and burning of CD-ROMs.

%package devel
Summary:        GNOME Music Management Application -- Development Files
Group:          Development/Languages/C and C++
Requires:       %{name} = %{version}
Provides:       %{name}-doc = %{version}
Obsoletes:      %{name}-doc < %{version}

%description devel
Music Management application with support for ripping audio-CD's,
playback of Ogg Vorbis and MP3 and burning of CD-ROMs.

This package contains the development requirements to extend rhythmbox.

%lang_package
%prep
%setup -q
%patch0 -p1
translation-update-upstream

%build
export MOZILLA_PLUGINDIR=%{_libdir}/browser-plugins
%configure\
	--disable-static\
	--enable-lirc\
	--enable-python\
%if ! %{with_webkit}
        --without-webkit \
%endif
%if %{with_daap}
        --enable-daap \
%endif
        --enable-vala

%__make %{?_smp_mflags} V=1

%install
%makeinstall
%suse_update_desktop_file %name Player
%suse_update_desktop_file rhythmbox-device
%find_lang %{name} %{?no_lang_C}
find %{buildroot} -type f -name "*.la" -delete -print

%clean
rm -rf %{buildroot}

%post
/sbin/ldconfig
%if 0%{?suse_version} > 1130
%glib2_gsettings_schema_post
%desktop_database_post
%icon_theme_cache_post
%endif

%postun
/sbin/ldconfig
%if 0%{?suse_version} > 1130
%glib2_gsettings_schema_postun
%desktop_database_postun
%icon_theme_cache_postun
%endif

%files
%defattr(-,root,root)
%doc AUTHORS COPYING ChangeLog DOCUMENTERS INTERNALS MAINTAINERS MAINTAINERS.old NEWS README THANKS
%doc %{_datadir}/help/C/rhythmbox/
%{_bindir}/rhythmbox
%{_bindir}/rhythmbox-client
%{_datadir}/applications/rhythmbox.desktop
%{_datadir}/applications/rhythmbox-device.desktop
%{_datadir}/dbus-1/services/org.gnome.Rhythmbox3.service
%{_datadir}/glib-2.0/schemas/org.gnome.rhythmbox.gschema.xml
%{_datadir}/icons/hicolor/*/apps/rhythmbox*
%{_datadir}/icons/hicolor/*/status/rhythmbox-missing-artwork.*
%{_datadir}/rhythmbox/
%{_libdir}/girepository-1.0/MPID-3.0.typelib
%{_libdir}/girepository-1.0/RB-3.0.typelib
%{_libdir}/librhythmbox-core.so.*
%{_libdir}/browser-plugins/librhythmbox-itms-detection-plugin.*
%dir %{_libdir}/rhythmbox
%dir %{_libdir}/rhythmbox/plugins
%{_libdir}/rhythmbox/plugins/artsearch/
%{_libdir}/rhythmbox/plugins/audiocd/
%{_libdir}/rhythmbox/plugins/audioscrobbler/
%{_libdir}/rhythmbox/plugins/cd-recorder/
%if %{with_webkit}
%{_libdir}/rhythmbox/plugins/context/
%endif
%if %{with_daap}
%{_libdir}/rhythmbox/plugins/daap/
%endif
%{_libdir}/rhythmbox/plugins/dbus-media-server/
%{_libdir}/rhythmbox/plugins/fmradio/
%{_libdir}/rhythmbox/plugins/generic-player/
%{_libdir}/rhythmbox/plugins/grilo/
%{_libdir}/rhythmbox/plugins/im-status/
%{_libdir}/rhythmbox/plugins/ipod/
%{_libdir}/rhythmbox/plugins/iradio/
%{_libdir}/rhythmbox/plugins/lyrics/
%{_libdir}/rhythmbox/plugins/magnatune/
%{_libdir}/rhythmbox/plugins/mmkeys/
%{_libdir}/rhythmbox/plugins/mpris/
%{_libdir}/rhythmbox/plugins/mtpdevice/
%{_libdir}/rhythmbox/plugins/notification/
%{_libdir}/rhythmbox/plugins/power-manager/
%{_libdir}/rhythmbox/plugins/python-console/
%{_libdir}/rhythmbox/plugins/rb/
%{_libdir}/rhythmbox/plugins/rblirc/
%{_libdir}/rhythmbox/plugins/rbzeitgeist/
%{_libdir}/rhythmbox/plugins/replaygain/
%{_libdir}/rhythmbox/plugins/sendto/
# Currently missing due to clutter-gst 1.6 not being available anymore.
#%{_libdir}/rhythmbox/plugins/visualizer/
%{_libexecdir}/rhythmbox-metadata
%{_mandir}/man1/rhythmbox.*
%{_mandir}/man1/rhythmbox-client.*

%files devel
%defattr(-, root, root)
%{_datadir}/gir-1.0/*.gir
%doc %{_datadir}/gtk-doc/html/rhythmbox/
%{_includedir}/rhythmbox/
%{_libdir}/pkgconfig/rhythmbox.pc
%{_libdir}/librhythmbox-core.so
%{_libdir}/rhythmbox/sample-plugins/

%files lang -f %{name}.lang

%changelog
openSUSE Build Service is sponsored by