File far2l.spec of Package far2l
#
# spec file for package far2l
#
# 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 https://bugs.opensuse.org/
#
Name: far2l
Version: @SERVICE@
Release: 0
Summary: Linux port of FAR v2
License: GPL-2.0-or-later AND BSD-3-Clause
Group: Productivity/File utilities
URL: https://github.com/elfmz/far2l
Source: %{name}-%{version}.tar.xz
BuildRequires: cmake >= 3.0.2
BuildRequires: fdupes
BuildRequires: gawk
%if 0%{?suse_version} >= 1699
BuildRequires: gcc-c++ >= 10.2.1
%else
BuildRequires: gcc10-c++
%endif
BuildRequires: hicolor-icon-theme
#uildRequires: libunrar-devel
BuildRequires: m4
BuildRequires: ninja
BuildRequires: pkgconfig
BuildRequires: pkgconfig(fmt)
BuildRequires: pkgconfig(glib-2.0)
BuildRequires: pkgconfig(icu-uc)
BuildRequires: pkgconfig(libarchive)
BuildRequires: pkgconfig(libnfs)
BuildRequires: pkgconfig(libpcre)
BuildRequires: pkgconfig(libssh)
BuildRequires: pkgconfig(libssl)
BuildRequires: pkgconfig(libxml-2.0)
BuildRequires: pkgconfig(neon)
BuildRequires: pkgconfig(python3)
BuildRequires: pkgconfig(smbclient)
BuildRequires: pkgconfig(spdlog)
BuildRequires: pkgconfig(uchardet)
BuildRequires: pkgconfig(xerces-c)
BuildRequires: pkgconfig(zlib)
BuildRequires: python3-virtualenv
BuildRequires: update-desktop-files
BuildRequires: wxGTK3-devel
#uildRequires: wxQt-3_2-devel
Requires: gvfs
Requires: libnotify-tools
Requires: xdg-utils
Requires: xterm-bin
%description
Linux port of FAR Manager v2 (http://farmanager.com) BETA VERSION.
Currently interesting only for enthusiasts!!!
%package bash-completion
Summary: Bash completion for %{name}
Group: System/Shells
Requires: bash-completion
Supplements: (%{name} and bash)
BuildArch: noarch
%description bash-completion
Bash command line completion support for %{name}.
%prep
%autosetup
sed -i "s/\(Exec=\).*/\1%{name}/" %{name}/DE/%{name}.desktop
%build
%define __builder ninja
%cmake \
-DBUILD_SHARED_LIBS:BOOL=OFF \
%if 0%{?suse_version} >= 1699
-DCMAKE_CXX_COMPILER=%{_bindir}/g++
%else
-DCMAKE_CXX_COMPILER=%{_bindir}/g++-10
%endif
%ninja_build
%install
%ninja_install -C build
rm -fv %{buildroot}%{_datadir}/icons/*.??g
rm -rfv %{buildroot}%{_datadir}/icons/hicolor/1024x1024
%suse_update_desktop_file -r %{name} System FileManager
%fdupes -s %{buildroot}%{_datadir}/icons/hicolor/
%files
%doc README.md
%{_bindir}/%{name}
%{_bindir}/%{name}edit
%{_datadir}/%{name}/
%{_datadir}/applications/%{name}.desktop
%{_datadir}/applications/%{name}edit.desktop
%{_datadir}/icons/hicolor/*/apps/%{name}.??g
%{_datadir}/icons/hicolor/*/apps/%{name}edit.??g
%{_mandir}/man?/%{name}.?%{?ext_man}
%{_mandir}/*/man?/%{name}.?%{?ext_man}
#%%{_libexecdir}/%%{name}/
%{_prefix}/lib/%{name}
%license LICENSE.txt
%files bash-completion
%dir %{_datadir}/bash-completion/
%dir %{_datadir}/bash-completion/completions
%{_datadir}/bash-completion/completions/%{name}
%changelog