Summary:	A multimedia management and playback application for GNOME
Summary(ja):	GNOME 向けのマルチメディア管理・再生アプリケーション
Name:		banshee
Version:	2.6.2
Release:	3%{?_dist_release}

License:	MIT/X11
Group:		Applications/Multimedia
URL:		http://banshee.fm/

Source0:	%{name}-%{version}.tar.xz

# Vine Patch
# ad-hoc patch to build with dbus-sharp 0.8.0
Patch100:       banshee-2.6.2-dbussharp2.patch

BuildRoot:	%{_tmppath}/%{name}-%{version}-root

BuildRequires:	mono-devel
BuildRequires:	mono-addins-devel
BuildRequires:	mono-zeroconf-devel
BuildRequires:	boo-devel
BuildRequires:	gdata-sharp-devel
BuildRequires:	taglib-sharp-devel
BuildRequires:	libgpod-sharp-devel
BuildRequires:	gudev-sharp-devel
BuildRequires:	gkeyfile-sharp-devel
BuildRequires:	gconf-sharp2
BuildRequires:	gio-sharp-devel
BuildRequires:	gtk-sharp-beans-devel
BuildRequires:	GConf2-devel
BuildRequires:	gstreamer-devel
BuildRequires:	gstreamer-plugins-base-devel
BuildRequires:	gtk2-devel
BuildRequires:	sqlite3-devel
BuildRequires:	dbus-sharp-devel >= 0.8.0
BuildRequires:	dbus-sharp-glib-devel >= 0.6.0
BuildRequires:	WebKit-gtk-devel
BuildRequires:	libmtp-devel
BuildRequires:	libudev-devel
BuildRequires:	brasero-devel
BuildRequires:	avahi-devel
BuildRequires:	gnome-doc-utils

Requires(post,postun):	desktop-file-utils
Requires(post,postun):	shared-mime-info

Requires:	libgpod-sharp
Requires:	gvfs-afc
Requires:	media-player-info

Vendor:		Project Vine
Distribution:	Vine Linux
Packager:	Takemikaduchi


%description
Banshee is a multimedia management and playback application for GNOME, with
support for OS X and Windows as well.

Play your music and videos. Stay entertained and up to date with podcasts
and video podcasts.  Sync your Android, iPod, and other devices. We think
you'll love the new Banshee!


%package	devel
Summary:        Development tools for banshee
Summary(ja):    banshee の開発環境
Group:          Development/Libraries
Requires:       %{name} = %{version}-%{release}
Requires:       pkgconfig

%description	devel
Header files and libraries for building a extension library for the
banshee.


%prep
%setup -q
%patch100 -p1 -b .dbussharp2

%build
# use mcs instead of gmcs
export MCS=%{_bindir}/mcs
export GMCS=%{_bindir}/mcs

#(if ! test -x configure; then NOCONFIGURE=1 ./autogen.sh; fi)
%configure \
	--disable-static 

%{__make} %{?_smp_mflags}


%install
%{__rm} -rf ${RPM_BUILD_ROOT}

make install DESTDIR=${RPM_BUILD_ROOT}

find $RPM_BUILD_ROOT -name '*.a' -exec rm -f {} \;
find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} \;

%find_lang %{name}


%clean
%{__rm} -rf ${RPM_BUILD_ROOT}


%post
touch --no-create %{_datadir}/icons/hicolor &> /dev/null || :
gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null || :
update-desktop-database %{_datadir}/applications &> /dev/null || :
update-mime-database %{_datadir}/mime &> /dev/null || :

%postun
if [ $1 -eq 0 ]; then
    touch --no-create %{_datadir}/icons/hicolor &> /dev/null || :
    gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null || :
fi
update-desktop-database %{_datadir}/applications &> /dev/null || :
update-mime-database %{_datadir}/mime &> /dev/null || :



%files -f %{name}.lang
%defattr(-,root,root,-)
%doc COPYING ChangeLog NEWS README
%{_bindir}/bamz
%{_bindir}/banshee
%{_bindir}/muinshee
%{_prefix}/lib/monodoc/sources/banshee-docs.*
%{_prefix}/lib/monodoc/sources/hyena-docs.*
%{_libdir}/%{name}
%{_datadir}/appdata/%{name}.appdata.xml
%{_datadir}/applications/banshee-audiocd.desktop
%{_datadir}/applications/banshee-media-player.desktop
%{_datadir}/applications/banshee.desktop
%{_datadir}/%{name}/audio-profiles/*.xml
%{_datadir}/%{name}/icons/hicolor/*/*/*
%{_datadir}/dbus-1/services/org.bansheeproject.Banshee.service
%{_datadir}/dbus-1/services/org.bansheeproject.CollectionIndexer.service
%{_datadir}/gnome/help/%{name}
%{_datadir}/icons/hicolor/*/apps/media-player-banshee.png
%{_datadir}/mime/packages/banshee-amz.xml
%{_datadir}/mime/packages/banshee-emx.xml

%files devel
%defattr(-,root,root,-)
%{_libdir}/pkgconfig/banshee-collection-indexer.pc
%{_libdir}/pkgconfig/banshee-core.pc
%{_libdir}/pkgconfig/banshee-hyena-data-sqlite.pc
%{_libdir}/pkgconfig/banshee-hyena-gui.pc
%{_libdir}/pkgconfig/banshee-hyena.pc
%{_libdir}/pkgconfig/banshee-lastfm-gui.pc
%{_libdir}/pkgconfig/banshee-lastfm.pc
%{_libdir}/pkgconfig/banshee-mono-media.pc
%{_libdir}/pkgconfig/banshee-musicbrainz.pc
%{_libdir}/pkgconfig/banshee-nowplaying.pc
%{_libdir}/pkgconfig/banshee-services.pc
%{_libdir}/pkgconfig/banshee-thickclient.pc
%{_libdir}/pkgconfig/banshee-webbrowser.pc


%changelog
* Wed Apr  1 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 2.6.2-3
- rebuilt with mono 3.12.1 and mono-addins 1.2

* Wed Nov 12 2014 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 2.6.2-2
- rebuilt with dbus-sharp 0.8.1 and dbus-shar-glib 0.6.0
- added Patch100

* Sun Mar 16 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.6.2-1
- new upstream release

* Sat Dec 28 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.6.1-2
- rebuild with VineSeed environment

* Sun Apr 21 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.6.1-1
- new upstream release

* Tue Oct 23 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.6.0-2
- change BuildRequires: mono-addins-devel instead of mono-addins

* Mon Oct 01 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.6.0-1
- new upstream release
- remove Patch0 (banshee-2.4.1-missing_cast.patch)

* Sun Jun 03 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.4.1-1
- initial build for Vine Linux

