Summary: PostScript Utilities
Summary(ja): PostScriptユーティリティ
Name: psutils
Version: 1.17
Release: 22%{?_dist_release}
License: distributable
Group: Applications/Publishing

Source: ftp.dcs.ed.ac.uk:/pub/ajcd/psutils-p17.tar.gz
Patch0: psutils-p17-Makefile.patch
Patch1: psutils-p17-misc.patch
Patch2: psutils-p17-paper.patch
Patch3: psutils-p17-strip.patch

BuildRoot: %{_tmppath}/%{name}-%{version}-root
BuildRequires: perl

%description
This package contains some utilities for manipulating PostScript documents.
Page selection and rearrangement are supported, including arrangement into
signatures for booklet printing, and page merging for n-up printing.

%description -l ja
このパッケージは PostScript 文章を加工するためのユーティリティをいくつか含んでいます。
ページの選択や再配置が対応しており、小冊子印刷用に署名を調整したり、n 面付印刷のためにページを取り込むする機能が含まれます。


%prep
%setup -q -n psutils
%patch0 -p1 -b .makefile
%patch1 -p1 -b .misc
%patch2 -p1 -b .paper
%patch3 -p1 -b .strip

%build
%__make -f Makefile.unix PERL=%__perl \
	    BINDIR=$RPM_BUILD_ROOT%{_bindir} \
	 SCRIPTDIR=$RPM_BUILD_ROOT%{_bindir} \
	INCLUDEDIR=$RPM_BUILD_ROOT%{_datadir}/psutils \
	    MANDIR=$RPM_BUILD_ROOT%{_mandir}/man1


%install
%__rm -rf $RPM_BUILD_ROOT

%__mkdir_p $RPM_BUILD_ROOT%{_datadir}
%__mkdir_p $RPM_BUILD_ROOT%{_mandir}
%__make -f Makefile.unix install \
	    BINDIR=$RPM_BUILD_ROOT%{_bindir} \
	 SCRIPTDIR=$RPM_BUILD_ROOT%{_bindir} \
	INCLUDEDIR=$RPM_BUILD_ROOT%{_datadir}/psutils \
	    MANDIR=$RPM_BUILD_ROOT%{_mandir}/man1

cd $RPM_BUILD_ROOT%{_bindir}
strip epsffit psbook psnup psresize psselect pstops


%clean
%__rm -rf $RPM_BUILD_ROOT


%files
%defattr(-,root,root)
%doc LICENSE README
%dir %{_datadir}/psutils
     %{_datadir}/psutils/*
%{_mandir}/man1/*
%{_bindir}/*


%changelog
* Sat Feb 28 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 1.17-22
- rebuilt on current VineSeed

* Sat Apr 16 2011 Munehiro Yamamoto <munepi@vinelinux.org> 1.17-21
- rebuilt
  - improved the Japanese translation of %%description

* Fri Oct 10 2008 Shu KONNO <owa@bg.wakwak.com> 1.17-20vl5
- applied new versioning policy, spec in utf-8

* Sun Jul 02 2006 Shu KONNO <owa@bg.wakwak.com> 1.17-19vl2
- s/Copylight/License/

* Mon May  5 2003 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.17-19vl1
- rebuild with new toolchains
- based on Rawhide 1.17-9
- add BuildPreReq: /usr/bin/perl

* Thu Jun 14 2001 <sagami@vinelinux.org>
- p17-3: added defattr

* Mon Jun 11 2001 MATSUBAYASHI 'Shaolin' Kohji <shaolin@vinelinux.org>
- p17-2
- /usr/man -> %%{_mandir}

* Thu Feb  1 2000 Yasuyuki Furukawa <furukawa@vinelinux.org>
- rebuild for Vine

* Mon Oct 13 1997 Atsushi Yamagata <yamagata@jwu.ac.jp>
- 1st release


