File amarok.spec of Package amarok
#
# spec file for package amarok (Version 2.1.1)
#
# Copyright (c) 2009 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
%bcond_with mp4
Name: amarok
BuildRequires: cups-devel libkcddb4-devel mysql ruby-devel sqlite-devel taglib-devel
BuildRequires: kdebase4-workspace-devel libkcompactdisc4-devel tse3-devel update-desktop-files
BuildRequires: gstreamer010-devel libmtp-devel libnjb-devel libvisual-devel xine-devel
BuildRequires: flac-devel gtk2-devel libQtWebKit-devel libdvdread-devel libkde4-devel
BuildRequires: dbus-1-glib-devel libogg-devel libsamplerate-devel libsndfile-devel
BuildRequires: gdk-pixbuf-devel libcurl-devel libsoprano-devel loudmouth-devel
BuildRequires: libmysqlclient-devel libqca2-devel
BuildRequires: qt4-qtscript taglib-extras-devel
BuildRequires: libgpod-devel >= 0.7.0
%if %suse_version > 1110
BuildRequires: libmysqld-devel
%endif
%if %{with mp4}
BuildRequires: libmp4v2-devel
%endif
# Required for the fdupes macro
BuildRequires: fdupes
Url: http://amarok.kde.org
License: GPL v2 or later
Group: Productivity/Multimedia/Sound/Players
Summary: Media Player for KDE
Version: 2.1.1
Release: 6
Source0: %name-%version.tar.bz2
Patch3: link-mysql-embedded.diff
Patch4: errmsg-mysql-embedded.diff
Patch5: spaces_in_filenames.diff
Patch6: errmsg-mysql51-embedded.diff
# PATCH-FIX-UPSTREAM amarok-2.1.1-lyricwiki.patch kde#202366 -- Makes LyricWiki work again. Took from upstream GIT.
Patch99: amarok-2.1.1-lyricwiki.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Provides: kde4-amarok = 2.0.90
Obsoletes: kde4-amarok <= 2.0.90
Requires: qt4-qtscript
Requires: %{name}-lang = %{version}
%description
Amarok is a media player for all kinds of media. This includes MP3, Ogg
Vorbis, audio CDs, podcasts and streams. Play lists can be stored in
.m3u or .pls files.
Authors:
--------
Christian Muehlhaeuser <chris@chris.de>
Mark Kretschmann <markey@web.de>
Max Howell <max.howell@methylblue.com>
Stanislav Karchebny <berk@inbox.ru>
%lang_package
%prep
%setup -q -n %name-%version
%patch3
%if %suse_version > 1110
%patch6
%else
%patch4
%endif
%patch5
%patch99
%build
%ifarch ppc ppc64
export RPM_OPT_FLAGS="$RPM_OPT_FLAGS -mminimal-toc"
%endif
%cmake_kde4 -d build
%make_jobs
%install
cd build
%makeinstall
cd ..
install -m 0644 /usr/share/mysql/english/errmsg.sys $RPM_BUILD_ROOT/usr/share/kde4/apps/amarok/errmsg.sys
%suse_update_desktop_file -r amarok AudioVideo Player
%find_lang amarok
%find_lang amarokcollectionscanner_qt amarok.lang
%kde_post_install
# create hardlinks for duplicate file using fdupes macro
%fdupes %{buildroot}
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%clean
%{__rm} -rf %{buildroot}
%files lang -f amarok.lang
%files
%defattr(-,root,root)
%_bindir/amarok
%_bindir/amarokcollectionscanner
%_bindir/amarok_afttagger
%_bindir/amarokmp3tunesharmonydaemon
%_kde4_modules/amarok_*
%_kde4_modules/kcm_amarok_service_*
%_kde4_modules/libamarok_*
%_libdir/libamarok_service_liblastfm.so
%_libdir/libamaroklib.so
%_libdir/libamaroklib.so.*
%_libdir/libamarokpud.so
%_libdir/libamarokpud.so.*
%_libdir/libmediadevicelib.so
%_libdir/libmediadevicelib.so.*
%_libdir/strigi/strigita_audible.so
%_libdir/strigi/strigita_mp4.so
%{_datadir}/applications/kde4/amarok.desktop
%{_datadir}/dbus-1/interfaces/org.freedesktop.MediaPlayer.player.xml
%{_datadir}/dbus-1/interfaces/org.freedesktop.MediaPlayer.root.xml
%{_datadir}/dbus-1/interfaces/org.freedesktop.MediaPlayer.tracklist.xml
%{_datadir}/icons/hicolor/*/apps/amarok.*
%_kde_share_dir/apps/amarok
%_kde_share_dir/apps/desktoptheme/Amarok-Mockup
%_kde_share_dir/apps/desktoptheme/amarok-default.desktop
%_kde_share_dir/apps/desktoptheme/default/widgets/amarok-*
%_kde_share_dir/config.kcfg/amarokconfig.kcfg
%_kde_config_dir/amarok.knsrc
%_kde_share_dir/servicetypes/amarok_*
%_kde_share_dir/services/amarok-*
%_kde_share_dir/services/amarok_*
%_kde_share_dir/services/amaroklastfm.protocol
%_kde_share_dir/services/amarok.protocol
%_kde_share_dir/services/ServiceMenus/amarok_append.desktop
%_kde_config_dir/amarok_homerc
%changelog