File kid3-qt.spec of Package kid3-qt
#
# spec file for package kid3-qt
#
# Copyright (c) 2013 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 rname kid3
Name: kid3-qt
Version: 2.3
Release: 0
Summary: Efficient ID3 Tag Editor - Non Kde version
License: GPL-2.0+
Group: Productivity/Multimedia/Sound/Utilities
Url: http://kid3.sourceforge.net
Source0: http://downloads.sourceforge.net/%{rname}/%{rname}-%{version}.tar.gz
#Source1: COPYING
Patch0: kid3-qt-gcc47.patch
# PATCH-FIX-UPSTREAM kid3-2.3-gstreamer1.0.diff -- enables gstreamer 1.0 support
Patch1: kid3-2.3-gstreamer1.0.diff
BuildRequires: cmake
#BuildRequires: crimson
BuildRequires: docbook-xsl-stylesheets
BuildRequires: flac-devel
#BuildRequires: fop
BuildRequires: hicolor-icon-theme
BuildRequires: id3lib-devel
BuildRequires: jpackage-utils
BuildRequires: libQtWebKit-devel
BuildRequires: libchromaprint-devel
BuildRequires: libmusicbrainz3-devel
BuildRequires: libqt4-devel
BuildRequires: libtunepimp-devel
BuildRequires: libvorbis-devel
BuildRequires: perl
BuildRequires: pkg-config
BuildRequires: perl(File::Spec)
#BuildRequires: susedoc
BuildRequires: taglib-devel
BuildRequires: update-desktop-files
BuildRequires: xerces-j2
# Kid3-qt builds with the latest gstreamer in multimedia:libs for all distributions, unlike kid3.
%if 0%{?suse_version} > 1230
BuildRequires: pkgconfig(gstreamer-1.0)
%else
BuildRequires: pkgconfig(gstreamer-0.10)
%endif
BuildRequires: pkgconfig(libexslt)
BuildRequires: pkgconfig(phonon)
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Requires(pre): desktop-file-utils
Requires: libtag1 >= 1.8
Provides: kid3 = %{version}
Obsoletes: kid3 < %{version}
%description
This is the non kde qt version.
With Kid3 you can:
* Edit ID3v1.1 tags
* Edit all ID3v2.3 and ID3v2.4 frames
* Convert between ID3v1.1, ID3v2.3 and ID3v2.4 tags
* Edit tags in MP3, Ogg/Vorbis, FLAC, MPC, MP4/AAC, MP2, Speex,
TrueAudio, WavPack, WMA, WAV and AIFF files
* Edit tags of multiple files, e.g. the artist, album, year and
genre of all files of an album typically have the same values and can
be set together.
* Generate tags from filenames
* Generate filenames from tags
* Rename and create directories from tags
* Generate playlist files
* Automatically convert upper and lower case and replace strings
* Import from gnudb.org, TrackType.org, MusicBrainz, Discogs, Amazon
and other sources of album data
* Export tags as CSV, HTML, playlists, Kover XML and in other formats
%lang_package
%prep
%setup -q -n %{rname}-%{version}
%patch0 -p1
%if 0%{?suse_version} > 1230
%patch1 -p1
%endif
%build
%if 0%{?suse_version} < 1310
mkdir Build && cd Build
cmake ../ -DCMAKE_INSTALL_PREFIX:PATH=%{_prefix} \
-DCMAKE_C_FLAGS:STRING="%{optflags} -ggdb" \
-DCMAKE_CXX_FLAGS:STRING="%{optflags} -ggdb" \
%else
%cmake \
%endif
-DWITH_MP4V2=OFF \
-DWITH_KDE:BOOL=off \
-DBUILD_SHARED_LIBS=OFF \
-DDOCBOOK_XSL_DIR:PATH=%{_datadir}/xml/docbook/stylesheet/nwalsh/1.75.2/ \
-DWITH_DOCDIR:STRING=share/doc/packages/kid3-qt \
-DWITH_TRANSLATIONSDIR:STRING=share/locale
make %{?_smp_mflags}
%install
%if 0%{?suse_version} < 1310
pushd Build
export INSTALL_ROOT=%{buildroot}
%make_install
popd
%else
%cmake_install
%endif
%suse_update_desktop_file -r "%{name}" AudioVideo AudioVideoEditing
install -Dpm 0644 deb/kid3.1 %{buildroot}%{_mandir}/man1/kid3-qt.1
cp -pr AUTHORS ChangeLog COPYING LICENSE NEWS README %{buildroot}%{_docdir}/%{name}/
%find_lang %{name} %{name}.lang --without-kde --with-qt --all-name --without-mo
%post
update-desktop-database -q > /dev/null
%postun
update-desktop-database -q > /dev/null
%files
%defattr(644,root,root,755)
%doc %{_docdir}/%{name}
%defattr(755,root,root,755)
%{_bindir}/%{name}
%defattr(644,root,root,755)
%{_datadir}/applications/%{name}.desktop
%{_datadir}/icons/hicolor/16x16/apps/%{name}.png
%{_datadir}/icons/hicolor/32x32/apps/%{name}.png
%{_datadir}/icons/hicolor/48x48/apps/%{name}.png
%{_datadir}/icons/hicolor/scalable/apps/kid3-qt.svg
%{_mandir}/man1/kid3-qt.1.gz
%files lang -f %{name}.lang
%defattr(-,root,root,-)
%changelog