File media-downloader.spec of Package media-downloader
#
# Spec file for package media-downloader
#
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
Name: media-downloader
Version: 5.x.x
Release: 0
Summary: Qt GUI front end to multiple CLI based tools
License: GPL-2.0+
Group: Productivity/Multimedia/Video/Players
Source: %{name}-%{version}.tar.xz
URL: https://github.com/mhogomchungu/media-downloader
BuildRequires: cmake
%if 0%{?suse_version} <= 1600
BuildRequires: gcc13
BuildRequires: gcc13-c++
%else
BuildRequires: gcc
BuildRequires: gcc-c++
%endif
BuildRequires: pkgconfig(Qt6Core)
BuildRequires: pkgconfig(Qt6Gui)
BuildRequires: pkgconfig(Qt6Widgets)
BuildRequires: pkgconfig(Qt6Network)
Recommends: yt-dlp
%description
The tool %{name} is a Qt/C++ based GUI frontend to multiple CLI based tools that deal with downloading online media.
%lang_package
%prep
%autosetup -p1 -n %{name}-%{version}
%build
%if 0%{?suse_version} <= 1600
test -x "$(type -p gcc-13)" && export CC="$_"
test -x "$(type -p g++-13)" && export CXX="$_"
%endif
%cmake \
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
-DCMAKE_BUILD_TYPE=RELEASE \
-DBUILD_WITH_QT6=ON
%make_build
%install
cd build
%make_install
%files
%defattr(0755,root,root)
%{_bindir}/media-downloader
%defattr(0644,root,root)
%{_datadir}/applications/media-downloader.desktop
%{_datadir}/pixmaps/media-downloader.png
%{_datadir}/media-downloader
%{_datadir}/media-downloader/translations
%changelog