File eh-man2html.spec of Package eh-man2html
#
# spec file for package vn-man2html
#
# Copyright (c) 2012 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: eh-man2html
Version: 3.0.1
Release: 0
Summary: Earl Hood's man2html implementation
License: GPL-2.0+
Group: System/Base
URL: http://dcssrv1.oit.uci.edu/indiv/ehood/man2html.html
#CVS-Clone: -d:pserver:anonymous@cvs.savannah.nongnu.org:/sources/man2html co man2html
#CVS-Web: http://cvs.savannah.gnu.org/viewvc/man2html/?root=man2html
Source: man2html%version.tar.gz
BuildRoot: %_tmppath/%name-%version-build
BuildArch: noarch
%if 0%{?suse_version}
BuildRequires: update-alternatives
Requires(pre): update-alternatives
Requires(postun): update-alternatives
%endif
Provides: man2html = eh-%version-%release
%description
A Perl-based Unix manpage to HTML converter.
%prep
%setup -qn man2html%version
%build
perl -i -pe 's{^#!.*}{#!/usr/bin/perl}g' man2html;
%install
b="%buildroot";
mkdir -p "$b/%_bindir";
install -pm0755 man2html "$b/%_bindir/eh-man2html";
ln -s eh-man2html "$b/%_bindir/man2html";
%if 0%{?suse_version}
%post
%_sbindir/update-alternatives --install \
%_bindir/man2html man2html %_bindir/eh-man2html 15;
%endif
%if 0%{?suse_version}
%preun
if [ "$1" = 0 ]; then
%_sbindir/update-alternatives --remove man2html %_bindir/eh-man2html;
fi;
%endif
%files
%defattr(-,root,root)
%if 0%{?suse_version}
%ghost %_bindir/man2html
%_bindir/eh-man2html
%else
%_bindir/man2html
%_bindir/eh-man2html
%endif
%changelog