File datamash.spec of Package datamash

#
# spec file for package datamash
#
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
#
# 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/
#


Name:           datamash
Version:        1.3
Release:        0
Summary:        Statistical, numerical and textual operations in the command line
License:        GPL-3.0-or-later
Group:          Productivity/Scientific/Math
Url:            https://www.gnu.org/software/datamash/
Source:         https://ftp.gnu.org/gnu/datamash/%{name}-%{version}.tar.gz
Source2:        https://ftp.gnu.org/gnu/datamash/%{name}-%{version}.tar.gz.sig
Source3:        https://savannah.gnu.org/project/memberlist-gpgkeys.php?group=datamash&download=1#/%{name}.keyring
# PTACH-FIX-UPSTREAM upstream-disable-broken-test.patch guillaume@opensuse.org -- Disable broken test (fix AArch64)
Patch0:         upstream-disable-broken-test.patch
# PATCH-FIX-UPSTREAM upstream-fix-test.patch guillaume@opensuse.org -- Rework a test (fix armv7l and PPC64)
Patch1:         upstream-fix-test.patch
BuildRequires:  pkgconfig
BuildRequires:  pkgconfig(openssl)
Requires(post): %{install_info_prereq}
Requires(preun): %{install_info_prereq}

%description
GNU datamash is a command-line program which performs basic numeric,
textual and statistical operations on input textual data files.

%prep
%setup -q
%patch0 -p1
%patch1 -p1

%build
%configure \
	--docdir=%{_docdir}/%{name} \
	--with-openssl=yes \
	--with-packager="%{vendor}" \
	--with-packager-version="%{distribution} %{version}-%{release}" \
	--with-packager-bug-reports="%{packager}" \
	--with-bash-completion-dir=no
make %{?_smp_mflags}

%install
%make_install
%find_lang %{name}

%check
make %{?_smp_mflags} check

%post
%install_info --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz

%preun
%install_info_delete --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz

%files -f %{name}.lang
%license COPYING
%doc ChangeLog README AUTHORS THANKS TODO
%{_bindir}/%{name}
%{_mandir}/man1/*.1%{ext_man}
%{_infodir}/%{name}.info%{ext_info}
%{_datadir}/%{name}

%changelog
openSUSE Build Service is sponsored by