File otawk.spec of Package otawk

#
# spec file for package otawk
#
# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
# Copyright (c) 2011 Guido Berhoerster.
#
# 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:           otawk
Summary:        One and True Implementation of AWK
Version:        20100523
Release:        1
License:        BSD
Group:          Productivity/Text/Utilities
Source:         http://www.cs.princeton.edu/~bwk/btl.mirror/awk.tar.gz
Url:            http://www.cs.princeton.edu/~bwk/btl.mirror/
BuildRequires:  bison
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
This is the version of awk described in "The AWK Programming Language",
by Al Aho, Brian Kernighan, and Peter Weinberger (Addison-Wesley, 1988,
ISBN 0-201-07981-X). It is commonly known as the "One True Awk".

%prep
%setup -q -c -n %{name}

%build
make CFLAGS="%{optflags}" %{?_smp_mflags}

%install
install -D -p -m 755 a.out %{buildroot}/bin/otawk
install -D -p -m 644 awk.1 %{buildroot}%{_mandir}/man1/otawk.1
gzip %{buildroot}%{_mandir}/man1/otawk.1
install -d -m 755 %{buildroot}/%{_bindir}
ln -sf ../../bin/otawk %{buildroot}%{_bindir}/otawk

%clean
rm -rf %{buildroot}

%files
%defattr(-,root,root,-)
%doc FIXES README
%doc %{_mandir}/man1/otawk.1.gz
%{_bindir}/otawk
/bin/otawk

%changelog
openSUSE Build Service is sponsored by