d100d80
%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
d100d80
%{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
d100d80
d100d80
Name:             picard
Alex Lancaster 65dc308
Version:          1.0
Alex Lancaster 65dc308
Release:          1%{?dist}
d100d80
Summary:          MusicBrainz-based audio tagger
d100d80
Group:            Applications/Multimedia
d100d80
01c08e3
Source0:          http://ftp.musicbrainz.org/pub/musicbrainz/picard/picard-%{version}.tar.gz
f19c321
Alex Lancaster 65dc308
# plugins, now distributed inside contrib/plugins directory,
Alex Lancaster 65dc308
# keep upstream URLs around in case we want to add upstream version
Alex Lancaster 65dc308
#Source1:	  http://users.musicbrainz.org/~luks/picard-plugins/discnumber.py
Alex Lancaster 65dc308
#Source2:          http://users.musicbrainz.org/~luks/picard-plugins/featartist.py
Alex Lancaster 65dc308
#Source3:          http://users.musicbrainz.org/~luks/picard-plugins/coverart.py
Alex Lancaster 65dc308
#Source4:          http://users.musicbrainz.org/~luks/picard-plugins/lastfm/__init__.py
Alex Lancaster 65dc308
#Source5:          http://users.musicbrainz.org/~luks/picard-plugins/lastfm/ui_options_lastfm.py
Alex Lancaster 65dc308
#Source6:          http://users.musicbrainz.org/~luks/picard-plugins/lastfm/options_lastfm.ui
Alex Lancaster 65dc308
#Source7:	  http://users.musicbrainz.org/~luks/picard-plugins/cuesheet.py
Alex Lancaster 65dc308
#Source8:	  http://users.musicbrainz.org/~luks/picard-plugins/open_in_gui.py
Alex Lancaster 65dc308
#Source9:	  http://users.musicbrainz.org/~luks/picard-plugins/swapprefix.py
Alex Lancaster 65dc308
#Source10:	  http://users.musicbrainz.org/~luks/picard-plugins/titlecase.py
Alex Lancaster 65dc308
#Source11:	  http://users.musicbrainz.org/~luks/picard-plugins/tracks2clipboard.py
Alex Lancaster 65dc308
#Source12:          http://users.musicbrainz.org/~luks/picard-plugins/replaygain/__init__.py
Alex Lancaster 65dc308
#Source13:          http://users.musicbrainz.org/~luks/picard-plugins/replaygain/ui_options_replaygain.py
Alex Lancaster 65dc308
#Source14:          http://users.musicbrainz.org/~luks/picard-plugins/replaygain/options_replaygain.ui
Alex Lancaster 65dc308
#Source15:	   http://users.musicbrainz.org/~luks/picard-plugins/featartistsintitles.py
Alex Lancaster 65dc308
#Source16:	   http://users.musicbrainz.org/~luks/picard-plugins/release_type.py
Alex Lancaster 65dc308
#Source17:	   http://users.musicbrainz.org/~luks/picard-plugins/no_release.py
Alex Lancaster 65dc308
#Source18:	   http://gitorious.org/musicbrainz/addrelease/blobs/raw/master/addrelease.py
Alex Lancaster 65dc308
Alex Lancaster 65dc308
# not yet included in contrib/ directory
Alex Lancaster b5e8859
Source19:	   http://github.com/voiceinsideyou/creaps-picard-plugins/raw/master/titlesort.py
Alex Lancaster b5e8859
Source20:	   http://github.com/voiceinsideyou/creaps-picard-plugins/raw/master/titleversion.py
a2ee5c6
Alex Lancaster b5e8859
# bonusdisc.py not yet ported
a2ee5c6
# search plugins are obsolete
a11194c
d100d80
License:          GPLv2+
d100d80
Url:              http://musicbrainz.org/doc/PicardTagger
d100d80
BuildRoot:        %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
d100d80
BuildRequires:    python-devel
d100d80
BuildRequires:    gettext
d100d80
BuildRequires:    desktop-file-utils
Alex Lancaster 65dc308
BuildRequires:    PyQt4 >= 4.6
d100d80
BuildRequires:    python-mutagen > 1.9
d100d80
BuildRequires:    libofa-devel
Alex Lancaster 65dc308
Requires:         PyQt4 >= 4.6
d100d80
Requires:         python-mutagen > 1.9
f19c321
Requires:         libdiscid
d100d80
d100d80
d100d80
%description
d100d80
Picard is an audio tagging application using data from the MusicBrainz
d100d80
database. The tagger is album or release oriented, rather than
d100d80
track-oriented.
d100d80
d100d80
%prep
01c08e3
%setup -q -n picard-%{version}
d100d80
d100d80
%build
d100d80
env %{__python} setup.py config
d100d80
env CFLAGS="$RPM_OPT_FLAGS" %{__python} setup.py build
d100d80
d100d80
%install
d100d80
rm -rf $RPM_BUILD_ROOT
d100d80
%{__python} setup.py install -O1 --skip-build --root=$RPM_BUILD_ROOT
56f4f25
d100d80
%find_lang %{name}
d100d80
desktop-file-install --vendor="fedora"                \
d100d80
  --delete-original --remove-category="Application"   \
d100d80
  --dir=$RPM_BUILD_ROOT/%{_datadir}/applications      \
d100d80
  $RPM_BUILD_ROOT/%{_datadir}/applications/*
d100d80
f19c321
# install plugins
f19c321
PLUGINDIR=$RPM_BUILD_ROOT%{python_sitearch}/picard/plugins/
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/discnumber.py ${PLUGINDIR}
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/featartist.py ${PLUGINDIR}
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/coverart.py ${PLUGINDIR}
f19c321
mkdir ${PLUGINDIR}/lastfm/
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/lastfm/__init__.py ${PLUGINDIR}/lastfm/
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/lastfm/ui_options_lastfm.py ${PLUGINDIR}/lastfm/
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/lastfm/options_lastfm.ui ${PLUGINDIR}/lastfm/
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/cuesheet.py ${PLUGINDIR}
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/open_in_gui.py ${PLUGINDIR}
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/swapprefix.py ${PLUGINDIR}
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/titlecase.py ${PLUGINDIR}
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/tracks2clipboard.py ${PLUGINDIR}
a2ee5c6
mkdir ${PLUGINDIR}/replaygain/
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/replaygain/__init__.py ${PLUGINDIR}/replaygain/
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/replaygain/ui_options_replaygain.py ${PLUGINDIR}/replaygain/
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/replaygain/options_replaygain.ui ${PLUGINDIR}/replaygain/
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/featartistsintitles.py ${PLUGINDIR}
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/release_type.py ${PLUGINDIR}
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/no_release.py ${PLUGINDIR}
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/addrelease.py ${PLUGINDIR}
Alex Lancaster 65dc308
mkdir ${PLUGINDIR}/lastfmplus/
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/lastfmplus/__init__.py ${PLUGINDIR}/lastfmplus/
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/lastfmplus/ui_options_lastfm.py ${PLUGINDIR}/lastfmplus/
Alex Lancaster 65dc308
install -pm 0644 contrib/plugins/classicdiscnumber.py ${PLUGINDIR}
Alex Lancaster 65dc308
Alex Lancaster b5e8859
install -pm 0644 %{SOURCE19} ${PLUGINDIR}
Alex Lancaster b5e8859
install -pm 0644 %{SOURCE20} ${PLUGINDIR}
01c08e3
a8ba14c
a8ba14c
echo %{fedora}
f19c321
d100d80
## disable tests for the moment
d100d80
%check
d100d80
%{?_with_check:%{__python} setup.py test || :}
d100d80
d100d80
%clean
d100d80
rm -rf $RPM_BUILD_ROOT
d100d80
d100d80
%files -f %{name}.lang
d100d80
%defattr(-,root,root,-)
d100d80
%doc AUTHORS.txt COPYING.txt NEWS.txt INSTALL.txt
d100d80
%{_bindir}/picard
d100d80
%{_datadir}/applications/fedora-picard.desktop
ee31c3d
%{_datadir}/icons/hicolor/*/apps/picard.png
304cc5c
%{python_sitearch}/*egg-info
d100d80
%dir %{python_sitearch}/picard
d100d80
%{python_sitearch}/picard/*
d100d80
d100d80
%changelog
Alex Lancaster 65dc308
* Mon Jun  4 2012  Alex Lancaster <alexlan[AT]fedoraproject org> - 1.0-1
Alex Lancaster 65dc308
- Update to latest upstream 1.0 (#827880)
Alex Lancaster 65dc308
- Use versions of plugins now distributed in contrib/plugins
Alex Lancaster 65dc308
- Update BR for PyQt >= 4.6 (#757398)
Alex Lancaster 65dc308
- Drop obsolete conditional in %%files (#757234)
Alex Lancaster 65dc308
6d57280
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.16-2
6d57280
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
6d57280
Alex Lancaster 65dc308
* Mon Nov 14 2011 Alex Lancaster <alexlan[AT]fedoraproject org> - 0.16-1
Alex Lancaster b5e8859
- Update to 0.16
Alex Lancaster b5e8859
- Update plugins, add titlesort, titleversion plugins.
Alex Lancaster b5e8859
01c08e3
* Sun Aug 21 2011 Alex Lancaster <alexlan[AT]fedoraproject org> - 0.15.1-1
01c08e3
- Update to 0.15.1
01c08e3
- Add more plugins
01c08e3
a2ee5c6
* Mon May 30 2011 Alex Lancaster <alexlan[AT]fedoraproject org> - 0.15-0.1.beta1
a2ee5c6
- Update to 0.15beta1 (#683055)
a2ee5c6
- Convert plugin files to files in git, easier to manage
a2ee5c6
- Only use plugins certified to be API compatible with 0.15 from
a2ee5c6
  http://users.musicbrainz.org/~luks/picard-plugins/
a2ee5c6
174a568
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.12.1-3
174a568
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
174a568
e17e442
* Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 0.12.1-2
e17e442
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
e17e442
9413506
* Tue Nov  3 2009 Alex Lancaster <alexlan[AT]fedoraproject org> - 0.12.1-1
9413506
- Update to upstream 0.12.1 (brown bag fix release)
9413506
ee31c3d
* Tue Oct 27 2009 Alex Lancaster <alexlan[AT]fedoraproject org> - 0.12-1
ee31c3d
- Update to 0.12 (#531224)
ee31c3d
- Icons now in icons/hicolor directory
ee31c3d
e9e9180
* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.11-4
e9e9180
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
e9e9180
1e8901b
* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.11-3
1e8901b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
1e8901b
253d324
* Tue Dec  9 2008 Alex Lancaster <alexlan[AT]fedoraproject org> - 0.11-2
253d324
- Fixed sources.
253d324
22cde54
* Tue Dec  9 2008 Alex Lancaster <alexlan[AT]fedoraproject org> - 0.11-1
22cde54
- Update to latest upstream (0.11)
22cde54
- Drop upstreamed patch
22cde54
- Remove sed-ing of .desktop file
22cde54
e5d23b2
* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.10-3
e5d23b2
- Rebuild for Python 2.6
e5d23b2
a8ba14c
* Tue Sep  2 2008 Alex Lancaster <alexlan[AT]fedoraproject org> - 0.10-2
a8ba14c
- Update plugin versions to 0.10 where possible.  
a8ba14c
- Temporarily disable the search plugins until they are ported to new API.
a8ba14c
a11194c
* Sun Aug 31 2008 Alex Lancaster <alexlan[AT]fedoraproject org> - 0.10-1
a11194c
- Update to latest upstream (0.10).
a11194c
- Add patch to work around broken setup.py.
a11194c
- Fixed some spec file errors: duplicate sources.
a11194c
55fa0fd
* Sat Feb  9 2008 Alex Lancaster <alexlan[AT]fedoraproject org> - 0.9.0-6
55fa0fd
- rebuilt for GCC 4.3 as requested by Fedora Release Engineering
55fa0fd
304cc5c
* Wed Dec 19 2007 Alex Lancaster <alexlan@fedoraproject.org> 0.9.0-5
304cc5c
- Add support for python eggs for F9+
304cc5c
524c533
* Wed Dec 19 2007 Alex Lancaster <alexlan@fedoraproject.org> 0.9.0-4
033ad35
- Update to proper release: 0.9.0
033ad35
- Drop plugins directory patch, applied upstream
033ad35
56f4f25
* Tue Dec 04 2007 Alex Lancaster <alexlan@fedoraproject.org> 0.9.0-0.6.beta1
56f4f25
- strip out png extension from .desktop file
56f4f25
f19c321
* Tue Dec 04 2007 Alex Lancaster <alexlan@fedoraproject.org> 0.9.0-0.5.beta1
f19c321
- Add plugins from http://musicbrainz.org/doc/PicardQt/Plugins
f19c321
- Patch to find proper plugins directory (filed upstream:
f19c321
  http://bugs.musicbrainz.org/ticket/3430)
f19c321
- Does not depend on python-musicbrainz2 any longer, uses libdiscid directly 
f19c321
f19c321
* Wed Nov 15 2007 Alex Lancaster <alexlan@fedoraproject.org> 0.9.0-0.4.beta1
d100d80
- Various minor spec file cleanups to make sure timestamps stay correct
d100d80
f19c321
* Wed Nov 14 2007 Alex Lancaster <alexlan@fedoraproject.org> 0.9.0-0.3.beta1
d100d80
- Create pixmaps directory
d100d80
f19c321
* Wed Nov 14 2007 Alex Lancaster <alexlan@fedoraproject.org> 0.9.0-0.2.beta1
d100d80
- Missing BR: python-devel
d100d80
- Use sitearch to make sure x86_64 builds work
d100d80
- Install icons share/pixmaps/, rather than share/icons/
d100d80
f19c321
* Wed Nov 14 2007 Alex Lancaster <alexlan@fedoraproject.org> 0.9.0-0.1.beta1
d100d80
- Initial packaging