File barcode.spec of Package barcode

#
# spec file for package barcode
#
# Copyright (c) 2013 SUSE LINUX Products 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:           barcode
%if %suse_version <= 1220
BuildRequires:  texlive
%else
BuildRequires:  makeinfo
BuildRequires:  texinfo
BuildRequires:  texlive-dvips
BuildRequires:  texlive-tex
BuildRequires:  texlive-texinfo
%endif
BuildRequires:  xz
Requires(pre):  %install_info_prereq
Version:        0.99
Release:        0
Summary:        Text-Mode Barcode Creation Utility
License:        GPL-3.0+
Group:          Productivity/Graphics/Other
Url:            http://www.gnu.org/software/barcode/barcode.html
Source:         ftp://ftp.gnu.org/pub/gnu/%{name}/%{name}-%{version}.tar.xz
Patch2:         %{name}-0.99-info.patch
# PATCH-FIX-UPSTREAM fix mem leak (bnc#537525)
Patch5:         %{name}-0.98-leak-fix.patch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
GNU Barcode is meant to meet most barcode creation needs with a
conventional printer. It can create printouts for the conventional
product tagging standards: UPC-A, UPC-E, EAN-13, EAN-8, ISBN, as well
as a few other formats. Output is generated in either PostScript or
Encapsulated PostScript format.

%prep
%setup
%patch2
%patch5

%build
%configure
make

%install
make DESTDIR=%{buildroot} install

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

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

%files
%defattr(-, root, root)
%doc COPYING README TODO
%{_bindir}/barcode
%{_bindir}/sample
%{_infodir}/%{name}.info.gz

%changelog
openSUSE Build Service is sponsored by