-Summary: Text to Postscript filter.
-Summary(pl): Filtr text/plain do Postscriptu
+Summary: Text to Postscript filter
+Summary(ja): ¥Æ¥¥¹¥È¢ªPostScript ¥Õ¥£¥ë¥¿
+Summary(pl): Filtr text/plain do Postscriptu
+Summary(zh_CN): ´¿Îı¾µ½Postscriptת»»Æ÷
Name: a2ps
-Version: 4.10.4
-Release: 6
-Copyright: GPL
-Group: Utilities/Text
-Group(pl): Narzêdzia/Tekst
-Source: ftp://ftp.enst.fr/pub/unix/a2ps/%{name}-%{version}.tar.bz2
-Patch: a2ps-info.patch
-Prereq: /sbin/ldconfig
+Version: 4.13b
+Release: 23
+License: GPL
+Group: Applications/Text
+Source0: ftp://ftp.enst.fr/pub/unix/a2ps/%{name}-%{version}.tar.gz
+# Source0-md5: 0c8e0c31b08c14f7a7198ce967eb3281
+Source1: ftp://ftp.enst.fr/pub/unix/a2ps/i18n-fonts-0.1.tar.gz
+# Source1-md5: fee1456d0e6e94af4fc5b5a1bb9687b7
+Source2: ogonkify.1.pl
+Patch0: %{name}-info.patch
+Patch1: %{name}-security.patch
+Patch2: %{name}-etc.patch
+Patch3: %{name}-flex.patch
+Patch4: %{name}-conf.patch
+Patch5: %{name}-glibcpaper.patch
+Patch6: %{name}-autoenc.patch
+Patch7: %{name}-i18n.patch
+Patch8: %{name}-ogonkify-xfig-fix.patch
URL: http://www.inf.enst.fr/~demaille/a2ps/
-BuildRoot: /tmp/%{name}-%{version}-root
+BuildRequires: flex
+Prereq: /sbin/ldconfig
+Requires: psutils
+BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%define _sysconfdir /etc/a2ps
%description
a2ps is a text to PostScript filter with pretty-printing capabilities.
It includes support for a wide number of programming languages,
encodings (ISO Latins, Cyrillic etc.), medias, and spoken languages
-(for the interface).
-It has also the ability to delegate the processing of some files to
-other applications, letting you print DVI, PostScript etc. with the
-very same interface.
-
-%description -l pl
-A2ps jest programem pozwalajaj±cym na ³adne drukowanie plików tekstowych w
-PostScript. Posiada wsparcie dla wielu ró¿nych jêzyków programowania,
-zestawów znaków (ISO Latins, Cyrilica etc.), wielko¶ci papieru, i jêzyków
-komunikacji z u¿ytkownikiem. Potrafi tak¿e przekazaæ przetwarzanie plików
-do innych programów (tak, ¿e mo¿na wszystko drukowaæ (DVI, PostScript) przy
-u¿yciu tego samego polecenia. Zawiera program ,,ogonkify'' poprawiaj±cy
-b³êdnie zakodowany PostScript zawieraj±cy polskie znaki.
-
-%package devel
+(for the interface). It has also the ability to delegate the
+processing of some files to other applications, letting you print DVI,
+PostScript etc. with the very same interface.
+
+%description -l pl
+A2ps jest programem pozwalaj±cym na ³adne drukowanie plików
+tekstowych w PostScript. Posiada wsparcie dla wielu ró¿nych jêzyków
+programowania, zestawów znaków (ISO Latins, Cyrilica etc.), wielko¶ci
+papieru, i jêzyków komunikacji z u¿ytkownikiem. Potrafi tak¿e
+przekazaæ przetwarzanie plików do innych programów (tak, ¿e mo¿na
+wszystko drukowaæ (DVI, PostScript) przy u¿yciu tego samego polecenia.
+Zawiera program ,,ogonkify'' poprawiaj±cy b³êdnie zakodowany
+PostScript zawieraj±cy polskie znaki.
+
+%package devel
Summary: Header files and development documentation for a2ps
-Summary(pl): Pliki nag³ówkowe i dokunentacja do a2ps
-Group: Libraries
-Group(pl): Biblioteki
+Summary(pl): Pliki nag³ówkowe i dokumentacja do a2ps
+Group: Development/Libraries
Requires: %{name} = %{version}
%description devel
%description devel -l pl
Pliki nag³ówkowe i dokumentacja do a2ps.
-%package static
+%package static
Summary: a2ps static libraries
Summary(pl): Biblioteki statyczne do a2ps
-Group: Libraries
-Group(pl): Biblioteki
+Group: Development/Libraries
Requires: %{name}-devel = %{version}
%description static
Biblioteki statyczne do a2ps.
%prep
-%setup -q
-%patch -p1
+%setup -q -n %{name}-4.13 -a 1
+%patch0 -p1
+%patch1 -p1
+%patch2 -p1
+%patch3 -p1
+%patch4 -p1
+%patch5 -p1
+%patch6 -p1
+%patch7 -p1
+%patch8 -p0
%build
-autoheader
-autoconf
-CFLAGS=$RPM_OPT_FLAGS LDFLAGS=-s \
-./configure %{_target_platform} \
- --with-included-gettext \
- --prefix=/usr \
- --sysconfdir=/etc \
- --with-medium=A4 \
+%configure2_13 \
+ --with-gnu-gettext \
+ --with-medium=_glibc \
--with-encoding=latin1 \
- --enable-shared
-make
+ --enable-shared \
+ --enable-kanji
+%{__make}
%install
rm -rf $RPM_BUILD_ROOT
+install -d $RPM_BUILD_ROOT%{_datadir}/a2ps/{afm,fonts} \
+ $RPM_BUILD_ROOT%{_mandir}/pl/man1
-perl -pe 's/^lispdir = $/lispdir = {prefix}\/lib/g' contrib/emacs/Makefile >tmp
+perl -pe 's/^lispdir = $/lispdir = \$(prefix)\/lib\/emacs\/site-lisp/g' contrib/emacs/Makefile >tmp
-mv tmp contrib/emacs/Makefile
-make prefix=$RPM_BUILD_ROOT/usr sysconfdir=$RPM_BUILD_ROOT/etc install
+mv -f tmp contrib/emacs/Makefile
-#chmod 755 $RPM_BUILD_ROOT%{_libdir}/*.so.*
-gzip -9nf $RPM_BUILD_ROOT%{_infodir}/* \
- $RPM_BUILD_ROOT%{_mandir}/man1/* \
- AUTHORS ChangeLog NEWS README THANKS
+%{__make} install \
+ DESTDIR=$RPM_BUILD_ROOT
+
+install i18n-fonts-0.1/afm/*.afm %{buildroot}%{_datadir}/a2ps/afm
+install i18n-fonts-0.1/fonts/*.pfb %{buildroot}%{_datadir}/a2ps/fonts
+install %{SOURCE2} $RPM_BUILD_ROOT%{_mandir}/pl/man1
%find_lang %{name}
+%clean
+rm -rf $RPM_BUILD_ROOT
+
%post
-/sbin/install-info %{_infodir}/a2ps.info.gz /etc/info-dir
-/sbin/install-info %{_infodir}/ogonkify.info.gz /etc/info-dir
+[ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
/sbin/ldconfig
-%preun
-if [ $1 = 0 ]; then
- /sbin/install-info --delete %{_infodir}/a2ps.info.gz /etc/info-dir
- /sbin/install-info --delete %{_infodir}/ogonkify.info.gz /etc/info-dir
-fi
-
-%postun
+%postun
+[ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
/sbin/ldconfig
%files -f %{name}.lang
%defattr(644,root,root,755)
-%doc {AUTHORS,ChangeLog,NEWS,README,THANKS}.gz
-
-%config(noreplace) %verify(not size mtime md5) /etc/a2ps.cfg
-
+%doc AUTHORS ChangeLog NEWS README THANKS
+%dir %{_sysconfdir}
+%config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/a2ps.cfg
+%config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/a2ps-site.cfg
%attr(755,root,root) %{_bindir}/*
-%attr(755,root,root) %{_libdir}/*.so.*
+%attr(755,root,root) %{_libdir}/lib*.so.*.*
%{_mandir}/man1/*
+%lang(pl) %{_mandir}/pl/man1/*
%{_infodir}/a2ps*info*
%{_infodir}/ogonkify*info*
+%dir %{_datadir}/a2ps
%dir %{_datadir}/a2ps/afm
%{_datadir}/a2ps/afm/*.afm
%{_datadir}/a2ps/afm/*.map
%attr(755,root,root) %{_datadir}/a2ps/afm/*.sh
-%dir %{_datadir}/a2ps/encoding
-%{_datadir}/a2ps/encoding/*
-
-%dir %{_datadir}/a2ps/fonts
-%{_datadir}/a2ps/fonts/*
+%{_datadir}/a2ps/encoding
+%{_datadir}/a2ps/fonts
+%{_datadir}/a2ps/ppd
+%{_datadir}/a2ps/ps
+%{_datadir}/a2ps/sheets
-%dir %{_datadir}/a2ps/ogonkify
-%{_datadir}/a2ps/ogonkify/*.enc
-%{_datadir}/a2ps/ogonkify/*.ps
-
-%dir %{_datadir}/a2ps/ppd
-%{_datadir}/a2ps/ppd/*.ppd
-
-%dir %{_datadir}/a2ps/ps
-%{_datadir}/a2ps/ps/*
-
-%dir %{_datadir}/a2ps/sheets
-%{_datadir}/a2ps/sheets/*
+%dir %{_datadir}/ogonkify
+%{_datadir}/ogonkify/*.enc
+%{_datadir}/ogonkify/*.ps
+%{_datadir}/ogonkify/afm
+%{_datadir}/ogonkify/fonts
%files devel
%defattr(644,root,root,755)
-
+%{_libdir}/lib*.la
%attr(755,root,root) %{_libdir}/lib*.so
-
%{_includedir}/*
%files static
%defattr(644,root,root,755)
-
%{_libdir}/lib*.a
-
-%clean
-rm -rf $RPM_BUILD_ROOT
-
-%changelog
-* Sun Jan 31 1999 Wojtek ¦lusarczyk <wojtek@shadow.eu.org>
- [4.10.3-5d]
-- added missiong fonts.map ...
-- autoheader && autoconf before configure,
-- other 'extras' in %install section,
-- added %dir for %{_datadir}/a2ps/*,
-- added Group(pl),
-- minor changes in %files *.
-
-* Mon Dec 28 1998 Tomasz K³oczko <kloczek@rudy.mif.pg.gda.pl>
- [4.10.3-5]
-- added %post, %postun with {un}registering info pages (added
- a2ps-info.patch),
-- added compressed man pages.
-
-* Thu Oct 15 1998 Tomasz K³oczko <kloczek@rudy.mif.pg.gda.pl>
- [4.10.3-4]
-- simplification in files,
-- removed regexp info pages,
-- added stripping shared libraries,
-- changed default encoding to latin1,
-- added devel subpackage.
-
-* Mon Sep 07 1998 Ziemek Borowski <ziembor@faq-bot.ziembor.waw.pl>
- [4.10.3-3d]
-- based on Akim Demaille <demaille@inf.enst.fr> and
- Dave Whitinger <dave@whitinger.net> specs,
-- added lang tag,
-- added pl spec translation,
-- more detailed %files,
-- default medium == A4,
-- default encoding == latin2,
-- build against GNU libc-2.1.
-
-* Mon Aug 07 1998 Soos Peter <sp@osb.hu>
-- BuildRoot spec correction %dir %{_datadir}/a2ps