File xcfa.spec of Package xcfa

#
# spec file for package xcfa
#
# Copyright (c) 2018 Packman Team <packman@links2linux.de>
#
# 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.links2linux.org/
#


Name:           xcfa
Version:        5.0.2
Release:        0
Summary:        A lightweight multimedia converter and audio CD ripper
License:        GPL-3.0
Group:          Productivity/Multimedia/Sound/Players
URL:            http://www.xcfa.tuxfamily.org/static2/xcfa
Source0:        http://download.tuxfamily.org/xcfaudio/xcfa_download/src/%{name}-%{version}.tar.gz
Patch0:         xcfa.patch
Patch1:         manpage.patch
Patch2:         xcfa-no-buildtime.patch
Patch3:         deskop_file_valid.patch
BuildRequires:  alsa-devel
BuildRequires:  fdupes
BuildRequires:  gcc-c++
BuildRequires:  glib2-devel
BuildRequires:  gtk3-devel
BuildRequires:  libcurl-devel
BuildRequires:  libtag-devel
BuildRequires:  pkgconfig
BuildRequires:  vte-devel
Requires(post): desktop-file-utils
Requires(post): update-desktop-files
Recommends:     cdparanoia
Recommends:     faac
Recommends:     faad2
Recommends:     flac
Recommends:     lame
Recommends:     lsdvd
Recommends:     mp3gain
Recommends:     mplayer
Recommends:     normalize
Recommends:     vorbis-tools
Recommends:     vorbisgain
Recommends:     wavpack
Suggests:       %{name}-lang

%description
XFCA (X Convert File Audio) is a tool to create audio files out of a DVD, convert audio files into another, and rip audio CDs.

%lang_package

%prep
%setup -q
%patch -P 0 -p1
gunzip man/xcfa.gz
%patch -P 1 -p1
gzip man/xcfa
%patch -P 2 -p1
%patch -P 3 -p1
mv man/xcfa_cli.1.gz man/xcfa_cli.gz
sed -i 's/xcfa_cli\.1\.gz/xcfa_cli\.gz/g' man/Makefile.in

%build
export LDADD="-lm"
CFLAGS='%{optflags} -Wno-deprecated-declarations'
%configure
%make_build

%install
%make_install
%find_lang %{name} %{?no_lang_C} --all-name
%fdupes %{buildroot}

%post
update-desktop-database > /dev/null
echo "The standard language of '%{name}' is french."
echo "So please install '%{name}-lang' for language support (includes english)"

%postun
update-desktop-database > /dev/null

%files
%license COPYING
%dir %{_datadir}/pixmaps/xcfa
%dir %{_datadir}/xcfa
%dir %{_datadir}/xcfa/glade
%{_bindir}/xcfa
%{_bindir}/xcfa_cli
%{_datadir}/applications/xcfa.desktop
%{_mandir}/man1/xcfa.1%{ext_man}
%{_mandir}/man1/xcfa_cli.1%{ext_man}
%{_datadir}/pixmaps/xcfa-cd.png
%{_datadir}/pixmaps/xcfa.png
%{_datadir}/pixmaps/xcfa.xpm
%{_datadir}/pixmaps/xcfa/2ch.png
%{_datadir}/pixmaps/xcfa/about.png
%{_datadir}/pixmaps/xcfa/coche.png
%{_datadir}/pixmaps/xcfa/coche_exist.png
%{_datadir}/pixmaps/xcfa/dbfs-no.png
%{_datadir}/pixmaps/xcfa/gplv3.png
%{_datadir}/pixmaps/xcfa/no_play.png
%{_datadir}/pixmaps/xcfa/norm_fix.png
%{_datadir}/pixmaps/xcfa/norm_mix.png
%{_datadir}/pixmaps/xcfa/norm_peak.png
%{_datadir}/pixmaps/xcfa/norm_rpg_wait.png
%{_datadir}/pixmaps/xcfa/normalize2.png
%{_datadir}/pixmaps/xcfa/not_install.png
%{_datadir}/pixmaps/xcfa/prg-ok.png
%{_datadir}/pixmaps/xcfa/rpg_album.png
%{_datadir}/pixmaps/xcfa/rpg_effacer.png
%{_datadir}/pixmaps/xcfa/rpg_piste.png
%{_datadir}/pixmaps/xcfa/selected.png
%{_datadir}/pixmaps/xcfa/selected_exist.png
%{_datadir}/pixmaps/xcfa/selected_expert.png
%{_datadir}/pixmaps/xcfa/selected_expert_exist.png
%{_datadir}/pixmaps/xcfa/sol.png
%{_datadir}/pixmaps/xcfa/trash.png
%{_datadir}/xcfa/glade/xcfa.glade
%{_datadir}/xcfa/glade/xcfa_win_about.glade
%{_datadir}/xcfa/glade/xcfa_win_info.glade
%{_datadir}/xcfa/glade/xcfa_win_reader.glade
%{_datadir}/xcfa/glade/xcfa_win_scan.glade
%{_datadir}/xcfa/glade/xcfa_win_treeview.glade

%files lang -f %{name}.lang

%changelog