File pgfconsole.spec of Package pgfconsole
#
# spec file for package pgfconsole
#
# Copyright (c) 2019 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 https://bugs.opensuse.org/
#
%define so_ver 7
%define lib_name libpgf
%define lib_ver 7.21.7
Name: pgfconsole
Version: 7.21.7
Release: lp156.10.1
Summary: Console utility for Progressive Graphics File conversion
License: GPL-2.0-only
Requires: libpgf%{so_ver} >= %{lib_ver}
Group: Productivity/Graphics/Other
URL: http://www.libpgf.org/
Source0: https://sourceforge.net/projects/libpgf/files/libpgf/%{version}/pgf-console.zip
Patch0: pgfconsole.patch
BuildRequires: libpgf%{so_ver}
BuildRequires: libpgf-devel
BuildRequires: doxygen
BuildRequires: gcc-c++
BuildRequires: graphviz
BuildRequires: libtool
BuildRequires: pkgconfig
BuildRequires: unzip
BuildRequires: freeimage-devel
BuildRequires: libfreeimage3
BuildRequires: libfreeimageplus3
BuildRequires: dos2unix
%description
pgfconsole is a console utility for encoding and decoding of Progressive Graphics
Files using the libpgf library.
%package doc
Summary: Doc and Man Files for pgfconsole
%description doc
This package provides documentation files for pgfconsole
%prep
%setup -q -n pgf
%patch -P 0 -p1
# Remove build time references so build-compare can do its work
echo "HTML_TIMESTAMP = NO" >> doc/Doxyfile.in
cd ./src
%build
dos2unix autogen.sh ChangeLog configure.ac COPYING FAQ INSTALL Makefile.am pgf.spec README.txt
mv README.txt README
sh autogen.sh
%configure --disable-static
make %{?_smp_mflags}
%install
%make_install
mkdir -p "%buildroot/%_docdir/pgfconsole"
mv "%buildroot/usr/share/doc/pgf-6.15.29/" "%buildroot/%_docdir/pgfconsole"
# Remove unused file
rm "%buildroot/usr/bin/pkgconfig/pgf.pc"
%__ln_s /usr/bin/pgf %{buildroot}/usr/bin/pgfconsole
%files
%license COPYING
%attr(755,root,root) %{_bindir}/pgf
%{_bindir}/pgfconsole
%files doc
%doc README
%doc %_mandir/man3/*
%_docdir/pgfconsole