2009-04-30 17:39:08 +02:00
#
2011-01-17 19:06:05 +01:00
# spec file for package k3b
2009-04-30 17:39:08 +02:00
#
2014-07-18 06:39:47 +02:00
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
2009-04-30 17:39:08 +02:00
#
# 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/
#
2009-05-28 05:05:52 +02:00
%bcond_with ffmpeg
%bcond_with mad
%bcond_with lame
2009-04-30 17:39:08 +02:00
2011-02-21 23:54:56 +01:00
Name : k3b
2011-05-17 13:25:07 +02:00
Version : 2.0.2
2012-04-19 08:48:59 +02:00
Release : 0
2011-05-17 13:25:07 +02:00
Summary : CD/DVD/Blu-ray Burning Application for KDE
2011-12-06 18:21:01 +01:00
License : GPL-2.0+
2011-05-17 13:25:07 +02:00
Group : Productivity/Multimedia/CD/Record
2012-04-19 08:48:59 +02:00
Url : http://www.k3b.org/
2011-05-17 13:25:07 +02:00
Source0 : http://prdownloads.sourceforge.net/k3b/%{name} -%{version} .tar.bz2
# PATCH-FIX-OPENSUSE initial-preference.diff llunak@novell.com -- Make the default handler for .iso files instead of Ark
Patch0 : initial-preference.diff
# PATCH-FIX-OPENSUSE add_mimetypes_bnc661777.diff bnc#661777 ctrippe@gmx.net -- Add a few mimetypes to the desktop file for better integration in GNOME
Patch1 : add_mimetypes_bnc661777.diff
2011-09-01 15:27:43 +02:00
# PATCH-FIX-UPSTREAM k3b-short-trackinfo.patch bko #268307 idoenmez@suse.de -- Too short track info dataLen returned at least on HL-DT-ST BH10LS30
Patch2 : k3b-short-trackinfo.patch
2012-07-30 17:12:55 +02:00
# PATCH-FIX-UPSTREAM k3b-2.0.2-ffmpeg011.patch reddwarf@opensuse.org -- Make it compile with the latest ffmpeg.
Patch3 : k3b-2.0.2-ffmpeg011.patch
2012-12-19 20:50:05 +01:00
# PATCH-FIX-UPSTREAM k3b-increase-tolerance.patch kde#276002 hrvoje.senjan@gmail.com -- K3b::IsOverburnAllowed: Increase tolerance
Patch4 : k3b-increase-tolerance.patch
# PATCH-FIX-UPSTREAM k3b-fixed-crash-on-detecting-writing-speeds.patch kde#272427 hrvoje.senjan@gmail.com -- Fixed crash on detecting writing speeds
Patch5 : k3b-fixed-crash-on-detecting-writing-speeds.patch
# PATCH-FIX-UPSTREAM k3b-fixed-improper-track-number-in-CDDB-track-edit-window-title.patch kde#276681 hrvoje.senjan@gmail.com -- Fixed improper track number in CDDB track edit window title
Patch6 : k3b-fixed-improper-track-number-in-CDDB-track-edit-window-title.patch
# PATCH-FIX-UPSTREAM k3b-fixed-solid-predicates.patch kde#265819 hrvoje.senjan@gmail.com -- Starting ripping directly from device notifier is possible again
Patch7 : k3b-fixed-solid-predicates.patch
# PATCH-FIX-UPSTREAM k3b-dont-count-used-capacity-twice.patch kde#276002 hrvoje.senjan@gmail.com -- Don't count used capacity twice
Patch8 : k3b-dont-count-used-capacity-twice.patch
# PATCH-FIX-UPSTREAM k3b-prefer-growisofs-to-wodim-for-DVD-burning.patch hrvoje.senjan@gmail.com -- This patch makes K3b default to growisofs for all DVD or BluRay burning tasks if cdrecord is actually wodim.
Patch9 : k3b-prefer-growisofs-to-wodim-for-DVD-burning.patch
# PATCH-FIX-UPSTREAM k3b-set-error-status-when-CDDB-query-fails.patch hrvoje.senjan@gmail.com -- Set error status when CDDB query fails. Without it the error is buing not reported and as a result all entries in audio project are cleared up.
Patch10 : k3b-set-error-status-when-CDDB-query-fails.patch
2011-05-17 13:25:07 +02:00
BuildRoot : %{_tmppath} /%{name} -%{version} -build
# only needed to patch broken images in the upstream tarball
BuildRequires : ImageMagick
BuildRequires : fdupes
BuildRequires : flac-devel
%if %{with lame}
BuildRequires : libmp3lame-devel
%endif
BuildRequires : libdvdread-devel
2011-04-21 12:13:17 +02:00
%if %{with ffmpeg}
2011-02-21 23:54:56 +01:00
BuildRequires : libffmpeg-devel
2009-05-28 05:05:52 +02:00
%endif
2011-05-17 13:25:07 +02:00
BuildRequires : libkcddb4-devel
2011-02-21 23:54:44 +01:00
%if %{with mad}
2011-02-21 23:54:56 +01:00
BuildRequires : libmad-devel
2009-05-28 05:05:52 +02:00
%endif
2011-05-17 13:25:07 +02:00
BuildRequires : libmpcdec-devel
BuildRequires : libmusicbrainz-devel
BuildRequires : libsamplerate-devel
BuildRequires : libsndfile-devel
2012-07-30 17:12:55 +02:00
%if %suse_version > 1200
BuildRequires : pkgconfig(taglib)
%else
BuildRequires : taglib-devel
%endif
2011-05-17 13:25:07 +02:00
BuildRequires : libvorbis-devel
%if 0%{?suse_version}
BuildRequires : update-desktop-files
2009-04-30 17:39:08 +02:00
%endif
2011-05-17 13:25:07 +02:00
Requires : /usr/bin/cdrdao
Requires : /usr/bin/cdrecord
Requires : /usr/bin/mkisofs
Requires : /usr/bin/readcd
2014-07-18 06:39:47 +02:00
Requires : cdparanoia-devel
2011-05-17 13:25:07 +02:00
Requires : dvd+rw-tools
2011-02-21 23:54:44 +01:00
%kde4_runtime_requires
2011-05-17 13:25:07 +02:00
Requires(post) : shared-mime-info
Requires(postun) : shared-mime-info
2013-02-23 16:35:33 +01:00
Recommends: /usr/bin/normalize
Recommends: /usr/bin/sox
Recommends: /usr/bin/transcode
2011-05-17 13:25:07 +02:00
Recommends: vcdimager
2011-02-21 23:54:56 +01:00
Recommends: %{name} -lang = %{version}
2011-05-17 13:25:07 +02:00
Provides : kde4-k3b = 4.2.2.svn951754
Obsoletes : kde4-k3b < 4.2.2.svn951754
2009-04-30 17:39:08 +02:00
%description
2011-05-17 13:25:07 +02:00
Featuring a simple, yet powerful graphical interface, k3b provides various
options for burning a CD, DVD, or BD (Blu-ray disc). Various types of optical
projects are supported including (but not limited to) audio and data, video
projects for DVD and VCD, as well as multi-session and mixed-mode discs. k3b
also has the ability to erase re-writeable media and can perform more
complicated tasks such as audiovisual encoding and decoding.
2009-04-30 17:39:08 +02:00
%package devel
2011-05-17 13:25:07 +02:00
Summary : Development files for k3b
Group : Development/Libraries/C and C++
Requires : %{name} = %{version}
2009-04-30 17:39:08 +02:00
%description devel
2011-05-17 13:25:07 +02:00
This package contain files needed for development with k3b.
2009-04-30 17:39:08 +02:00
2009-08-11 17:40:19 +02:00
%lang_package
2009-04-30 17:39:08 +02:00
%prep
2011-05-17 13:25:07 +02:00
%setup -q
%patch0
2010-06-21 18:55:04 +02:00
%patch1
2011-08-23 15:30:55 +02:00
%patch2 -p1
2012-12-19 20:50:05 +01:00
%patch4 -p1
%patch5 -p1
%patch6 -p1
%patch7 -p1
%patch8 -p1
%patch9 -p1
%patch10 -p1
2011-09-01 15:27:43 +02:00
%if %{with ffmpeg}
%patch3 -p1
2011-08-23 15:30:55 +02:00
%endif
2011-05-17 13:25:07 +02:00
# patch image with wrong dimensions - fix rpmlint warning "wrong-icon-size"
pushd src/icons/actions
for f in hi16*.png; do
geom=$(identify -ping " $ f " |cut -f3 -d" " )
x=${geom%x*}
y=${geom#*x}
if [ " $ x " != " 1 6 " -o " $ y " != " 1 6 " ]; then
if [ " $ x " -gt " $ y " ]; then
nugeom=" $ { x } x $ { x } "
grav=south
elif [ " $ x " -lt " $ y " ]; then
nugeom=" $ { y } x $ { y } "
grav=center
else
nugeom=" "
fi
[ -n " $ n u g e o m " ] && mogrify -extent " $ n u g e o m " -background transparent -gravity " $ g r a v " " $ f "
mogrify -scale 16x16 -background transparent " $ f "
fi
done
popd
2009-04-30 17:39:08 +02:00
%build
2011-05-17 13:25:07 +02:00
export RPM_OPT_FLAGS=" %{optflags} - f n o - s t r i c t - a l i a s i n g "
%cmake_kde4 -d build -- -DK3B_ENABLE_HAL_SUPPORT=OFF
%make_jobs
2009-04-30 17:39:08 +02:00
%install
2011-05-17 13:25:07 +02:00
pushd build
%kde4_makeinstall
popd
%if 0%{?suse_version}
%suse_update_desktop_file -r k3b Qt KDE AudioVideo DiscBurning
%endif
# Remove unneeded locales
%if 0%{?suse_version} && 0%{?suse_version} < 1140
rm -rf %{buildroot} %{_datadir} /locale/ast/
rm -rf %{buildroot} %{_datadir} /locale/csb/
rm -rf %{buildroot} %{_datadir} /locale/hne/
rm -rf %{buildroot} %{_datadir} /locale/sr@ijekavian/
rm -rf %{buildroot} %{_datadir} /locale/sr@ijekavianlatin/
%endif
# Fix rpmlint warning "files-duplicate*"
%fdupes -s %{buildroot}
%find_lang k3b k3b.lang
%find_lang k3bsetup k3b.lang
%find_lang libk3b k3b.lang
%find_lang libk3bdevice k3b.lang
%find_lang kio_videodvd k3b.lang
%kde_post_install
2009-04-30 17:39:08 +02:00
2011-02-21 23:54:44 +01:00
%post
/sbin/ldconfig
/usr/bin/update-mime-database %{_datadir} /mime &> /dev/null || :
2009-04-30 17:39:08 +02:00
2011-02-21 23:54:44 +01:00
%postun
/sbin/ldconfig
/usr/bin/update-mime-database %{_datadir} /mime &> /dev/null || :
2009-04-30 17:39:08 +02:00
%clean
2011-05-17 13:25:07 +02:00
rm -rf %{buildroot}
2009-08-11 17:40:19 +02:00
2009-04-30 17:39:08 +02:00
%files
2011-05-17 13:25:07 +02:00
%defattr (-,root,root,-)
%doc COPYING* ChangeLog FAQ PERMISSIONS README
%{_kde4_bindir}/k3b
%{_kde4_bindir}/k3bsetup
%{_kde4_modulesdir}/k3b*.so
%{_kde4_modulesdir}/kcm_k3b*.so
%{_kde4_modulesdir}/kio_videodvd.so
%{_kde4_libexecdir}/k3bsetuphelper
%{_kde4_libdir}/libk3bdevice.so.*
%{_kde4_libdir}/libk3blib.so.*
%{_kde4_applicationsdir}/k3b.desktop
%doc %{_kde4_htmldir}/en/k3b/
%{_kde4_iconsdir}/hicolor/*/apps/k3b.*
%{_kde4_appsdir}/k3b/
%{_kde4_appsdir}/konqsidebartng/virtual_folders/services/videodvd.desktop
%dir %{_kde4_appsdir}/solid
%dir %{_kde4_appsdir}/solid/actions
%{_kde4_appsdir}/solid/actions/k3b_*.desktop
%{_kde4_servicesdir}/ServiceMenus/k3b_*.desktop
%{_kde4_servicesdir}/k3b*.desktop
%{_kde4_servicesdir}/kcm_k3b*.desktop
%{_kde4_servicesdir}/videodvd.protocol
%{_kde4_servicetypesdir}/k3bplugin.desktop
%{_datadir} /mime/packages/x-k3b.xml
%config %{_sysconfdir} /dbus-1/system.d/org.kde.kcontrol.k3bsetup.conf
%{_datadir} /dbus-1/system-services/org.kde.kcontrol.k3bsetup.service
%{_datadir} /polkit-1/actions/org.kde.kcontrol.k3bsetup.policy
2009-04-30 17:39:08 +02:00
%files devel
2011-05-17 13:25:07 +02:00
%defattr (-,root,root,-)
%{_includedir} /k3b*.h
%{_kde4_libdir}/libk3bdevice.so
%{_kde4_libdir}/libk3blib.so
%files lang -f k3b.lang
%defattr (-,root,root,-)
%exclude %{_kde4_htmldir}/en/k3b/
2009-04-30 17:39:08 +02:00
%changelog