File k3b.spec of Package k3b

# spec file for package k3b
# Copyright (c) 2020 SUSE LLC
# 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

%bcond_without lang
%bcond_without ffmpeg
%bcond_without lame
%bcond_without mad
Name:           k3b
Version:        20.04.2
Release:        0
Summary:        CD/DVD/Blu-ray Burning Application for KDE
License:        GPL-2.0-or-later
Group:          Productivity/Multimedia/CD/Record
Patch1:         Don-t-suggest-to-install-libburn.patch
Patch2:         0001-Revert-Enable-the-k3b-helper-by-default.patch
Patch3:         fix-taglib-include-dirs.patch
BuildRequires:  extra-cmake-modules
BuildRequires:  fdupes
BuildRequires:  flac-devel
BuildRequires:  libdvdread-devel
BuildRequires:  libmpcdec-devel
BuildRequires:  libmusicbrainz-devel
BuildRequires:  libsamplerate-devel
BuildRequires:  libsndfile-devel
BuildRequires:  libvorbis-devel
BuildRequires:  pkgconfig
BuildRequires:  update-desktop-files
BuildRequires:  cmake(KF5Archive) >= 5.21.0
BuildRequires:  cmake(KF5Cddb)
BuildRequires:  cmake(KF5Config) >= 5.21.0
BuildRequires:  cmake(KF5CoreAddons) >= 5.21.0
BuildRequires:  cmake(KF5DocTools) >= 5.21.0
BuildRequires:  cmake(KF5FileMetaData) >= 5.21.0
BuildRequires:  cmake(KF5I18n) >= 5.21.0
BuildRequires:  cmake(KF5IconThemes) >= 5.21.0
BuildRequires:  cmake(KF5JobWidgets) >= 5.21.0
BuildRequires:  cmake(KF5KCMUtils) >= 5.21.0
BuildRequires:  cmake(KF5KIO) >= 5.21.0
BuildRequires:  cmake(KF5NewStuff) >= 5.21.0
BuildRequires:  cmake(KF5Notifications) >= 5.21.0
BuildRequires:  cmake(KF5NotifyConfig) >= 5.21.0
BuildRequires:  cmake(KF5Service) >= 5.21.0
BuildRequires:  cmake(KF5Solid) >= 5.21.0
BuildRequires:  cmake(KF5WidgetsAddons) >= 5.21.0
BuildRequires:  cmake(KF5XmlGui) >= 5.21.0
BuildRequires:  cmake(Qt5Core) >= 5.5.0
BuildRequires:  cmake(Qt5DBus) >= 5.5.0
BuildRequires:  cmake(Qt5Gui) >= 5.5.0
BuildRequires:  cmake(Qt5Test) >= 5.5.0
BuildRequires:  pkgconfig(taglib)
Requires:       %{_bindir}/cdrdao
Requires:       %{_bindir}/cdrecord
Requires:       %{_bindir}/mkisofs
Requires:       %{_bindir}/readcd
Requires:       dvd+rw-tools
Requires(post): hicolor-icon-theme
Requires(post): shared-mime-info
Requires(postun): hicolor-icon-theme
Requires(postun): shared-mime-info
Recommends:     %{_bindir}/normalize
Recommends:     %{_bindir}/sox
Recommends:     %{_bindir}/transcode
Recommends:     %{name}-lang
Recommends:     vcdimager
Provides:       kde4-k3b = 4.2.2.svn951754
Obsoletes:      k3b-codecs
Obsoletes:      kde4-k3b < 4.2.2.svn951754
%if %{with lang}
Source2:        applications.keyring
%if %{with ffmpeg}
BuildRequires:  pkgconfig(libavcodec)
BuildRequires:  pkgconfig(libavformat)
%if %{with lame}
BuildRequires:  libmp3lame-devel
Requires:       lame
%if %{with mad}
BuildRequires:  pkgconfig(mad)

Featuring a graphical interface, k3b provides various
options for burning a CD, DVD, or BD (Blu-ray disc). Various types of
projects are supported, including audio and data, video
projects for DVD and VCD, as well as multi-session and mixed-mode discs. k3b
has the ability to erase re-writeable media, and can perform more
complicated tasks such as audiovisual encoding and decoding.

%package devel
Summary:        Development files for k3b
Group:          Development/Libraries/C and C++
Requires:       %{name} = %{version}

%description devel
This package contain files needed for development with k3b.


%setup -q
%autopatch -p1

CXXFLAGS="%{optflags} -fno-strict-aliasing"
%cmake_kf5 -d build -- -DBUILD_TESTING=ON -DKF5_INCLUDE_INSTALL_DIR=%{_kf5_includedir}

%kf5_makeinstall -C build
%if %{with lang}
  %find_lang %{name} --with-man --all-name

%suse_update_desktop_file -r org.kde.k3b Qt KDE AudioVideo DiscBurning

%fdupes -s %{buildroot}



%license COPYING*
%doc ChangeLog FAQ.txt PERMISSIONS.txt README.txt
%dir %{_kf5_servicesdir}/ServiceMenus
%dir %{_kf5_sharedir}/konqsidebartng
%dir %{_kf5_sharedir}/konqsidebartng/virtual_folders
%dir %{_kf5_sharedir}/konqsidebartng/virtual_folders/services
%dir %{_kf5_sharedir}/solid
%dir %{_kf5_sharedir}/solid/actions
%doc %lang(en) %{_kf5_htmldir}/en/k3b/
%dir %{_kf5_plugindir}/kf5/
%dir %{_kf5_plugindir}/kf5/kio/

%files devel
%license COPYING*

%if %{with lang}
%files lang -f %{name}.lang
%license COPYING*

openSUSE Build Service is sponsored by