diff --git a/latex2html.spec b/latex2html.spec index 265d822..59632c9 100644 --- a/latex2html.spec +++ b/latex2html.spec @@ -3,7 +3,7 @@ Summary: Converts LaTeX documents to HTML Name: latex2html Version: 2008 -Release: 3%{?dist} +Release: 4%{?dist} License: GPLv2+ Group: Applications/Publishing URL: http://www.latex2html.org/ @@ -19,7 +19,7 @@ Patch3: latex2html-2K.1beta-DB.patch Patch4: latex2html-2002-2-1-SHLIB.patch Patch5: latex2html-2002-2-1-gsfont.patch Patch6: latex2html-2002.2.1-grayimg.patch -Requires: tex(latex), tex(dvips) +Requires: tex(latex), tex(dvips), netpbm-progs BuildRequires: perl >= 5.003, ghostscript >= 4.03, netpbm >= 9.21, tex(latex) BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch @@ -55,6 +55,8 @@ pushd %{name}-%{version} for i in Dos Mac OS2 Win32; do rm -f L2hos/${i}.pm done +rm -rf cweb2html +rm -f readme.hthtml popd %if %{enable_japanese} @@ -75,22 +77,22 @@ pushd %{name}-%{version} cp %{SOURCE1} cfgcache.pm tar fxz %{SOURCE2} -./configure --program-prefix=%{?_program_prefix} \ - --prefix=%{_prefix} \ - --exec-prefix=%{_exec_prefix} \ - --bindir=%{_bindir} \ - --sbindir=%{_sbindir} \ - --sysconfdir=%{_sysconfdir} \ - --datadir=%{_datadir} \ - --includedir=%{_includedir} \ - --libdir=%{_datadir}/latex2html \ - --libexecdir=%{_libexecdir} \ - --localstatedir=%{_localstatedir} \ - --sharedstatedir=%{_sharedstatedir} \ - --mandir=%{_mandir} \ - --infodir=%{_infodir} \ - --shlibdir=%{_datadir}/latex2html \ - --with-texpath=%{_datadir}/texmf/tex/latex/html +./configure --program-prefix=%{?_program_prefix} \ + --prefix=%{_prefix} \ + --exec-prefix=%{_exec_prefix} \ + --bindir=%{_bindir} \ + --sbindir=%{_sbindir} \ + --sysconfdir=%{_sysconfdir} \ + --datadir=%{_datadir} \ + --includedir=%{_includedir} \ + --libdir=%{_datadir}/latex2html \ + --libexecdir=%{_libexecdir} \ + --localstatedir=%{_localstatedir} \ + --sharedstatedir=%{_sharedstatedir} \ + --mandir=%{_mandir} \ + --infodir=%{_infodir} \ + --shlibdir=%{_datadir}/latex2html \ + --with-texpath=%{_datadir}/texmf/tex/latex/html perl -pi -e"s,/usr/(share/)?lib,%{_datadir}," cfgcache.pm make @@ -102,56 +104,58 @@ sed s/latex2html/jlatex2html/g < %{SOURCE1} > cfgcache.pm perl -pi -e"s,/usr/bin/dvips,/usr/bin/pdvips," cfgcache.pm perl -pi -e"s,/usr/bin/latex,/usr/bin/platex," cfgcache.pm -./configure --program-prefix=%{?_program_prefix} \ - --prefix=%{_prefix} \ - --exec-prefix=%{_exec_prefix} \ - --bindir=%{_bindir} \ - --sbindir=%{_sbindir} \ - --sysconfdir=%{_sysconfdir} \ - --datadir=%{_datadir} \ - --includedir=%{_includedir} \ - --libdir=%{_datadir}/jlatex2html \ - --libexecdir=%{_libexecdir} \ - --localstatedir=%{_localstatedir} \ - --sharedstatedir=%{_sharedstatedir} \ - --mandir=%{_mandir} \ - --infodir=%{_infodir} \ - --shlibdir=%{_datadir}/jlatex2html \ - --with-texpath=%{_datadir}/texmf/tex/latex/html +./configure --program-prefix=%{?_program_prefix} \ + --prefix=%{_prefix} \ + --exec-prefix=%{_exec_prefix} \ + --bindir=%{_bindir} \ + --sbindir=%{_sbindir} \ + --sysconfdir=%{_sysconfdir} \ + --datadir=%{_datadir} \ + --includedir=%{_includedir} \ + --libdir=%{_datadir}/jlatex2html \ + --libexecdir=%{_libexecdir} \ + --localstatedir=%{_localstatedir} \ + --sharedstatedir=%{_sharedstatedir} \ + --mandir=%{_mandir} \ + --infodir=%{_infodir} \ + --shlibdir=%{_datadir}/jlatex2html \ + --with-texpath=%{_datadir}/texmf/tex/latex/html perl -pi -e"s,/usr/(share/)?lib,%{_datadir},; - s,%{_datadir}/latex2html,%{_datadir}/jlatex2html," cfgcache.pm + s,%{_datadir}/latex2html,%{_datadir}/jlatex2html," cfgcache.pm make -perl -pi -e"s,${RPM_BUILD_ROOT},," l2hconf.pm perl -pi -e"s,\\\${dd}pstoimg,\\\${dd}jpstoimg, ; - s,\\\${dd}texexpand,\\\${dd}jtexexpand," l2hconf.pm + s,\\\${dd}texexpand,\\\${dd}jtexexpand," l2hconf.pm for i in latex2html pstoimg texexpand ; do - mv ${i} j${i} + mv ${i} j${i} done popd %endif %install -rm -rf $RPM_BUILD_ROOT +rm -rf %{buildroot} pushd %{name}-%{version} -perl -pi -e"s,%{_prefix},${RPM_BUILD_ROOT}%{_prefix}," cfgcache.pm +perl -pi -e"s,%{_prefix},%{buildroot}%{_prefix}," cfgcache.pm perl -pi -e"s,/.*\\\${dd}texexpand,%{_bindir}/texexpand,; - s,/.*\\\${dd}pstoimg,%{_bindir}/pstoimg,; - s,/.*\\\${dd}*icons,\\\${LATEX2HTMLDIR}/icons,; - s,/.*\\\${dd}rgb.txt,\\\${LATEX2HTMLDIR}/styles/rgb.txt,; - s,/.*\\\${dd}styles\\\${dd}crayola.txt,\\\${LATEX2HTMLDIR}/styles/crayola.txt," latex2html -perl -pi -e"s,$RPM_BUILD_ROOT,," l2hconf.pm + s,/.*\\\${dd}pstoimg,%{_bindir}/pstoimg,; + s,/.*\\\${dd}*icons,\\\${LATEX2HTMLDIR}/icons,; + s,/.*\\\${dd}rgb.txt,\\\${LATEX2HTMLDIR}/styles/rgb.txt,; + s,/.*\\\${dd}styles\\\${dd}crayola.txt,\\\${LATEX2HTMLDIR}/styles/crayola.txt," latex2html +perl -pi -e"s,%{buildroot},," l2hconf.pm make install rm -f %{buildroot}%{_datadir}/latex2html/versions/table.pl.orig -perl -pi -e"s,$RPM_BUILD_ROOT,," %{buildroot}%{_datadir}/latex2html/cfgcache.pm -perl -pi -e"s,$RPM_BUILD_ROOT,," %{buildroot}%{_bindir}/pstoimg -perl -pi -e"s,$RPM_BUILD_ROOT,," %{buildroot}%{_bindir}/texexpand -perl -pi -e"s,$RPM_BUILD_ROOT,," cfgcache.pm +rm -rf %{buildroot}%{_datadir}/latex2html/docs/ +rm -rf %{buildroot}%{_datadir}/latex2html/example/ +perl -pi -e"s,%{buildroot},," %{buildroot}%{_datadir}/latex2html/cfgcache.pm +perl -pi -e"s,%{buildroot},," %{buildroot}%{_bindir}/pstoimg +perl -pi -e"s,%{buildroot},," %{buildroot}%{_bindir}/texexpand +perl -pi -e"s,%{buildroot},," cfgcache.pm perl -pi -e"s,$cfg{'GS_LIB'} = q'';,$cfg{'GS_LIB'} = q'%{_datadir}/ghostscript/`ghostscript --version`';," cfgcache.pm install -m0644 *.pm %{buildroot}%{_datadir}/latex2html +chmod +x %{buildroot}%{_datadir}/latex2html/makeseg/makeseg %{buildroot}%{_datadir}/latex2html/makemap # install man pages mkdir -p %{buildroot}%{_mandir}/man1 @@ -160,35 +164,38 @@ popd %if %{enable_japanese} pushd %{name}-%{version}JA -perl -pi -e"s,%{_prefix},${RPM_BUILD_ROOT}%{_prefix}," cfgcache.pm +perl -pi -e"s,%{_prefix},%{buildroot}%{_prefix}," cfgcache.pm perl -pi -e"s,latex2html pstoimg texexpand,jlatex2html jpstoimg jtexexpand," config/install.pl perl -pi -e"s,/.*\\\${dd}texexpand,%{_bindir}/jtexexpand,; - s,/.*\\\${dd}pstoimg,%{_bindir}/jpstoimg,; - s,/.*\\\${dd}icons,\\\${LATEX2HTMLDIR}/icons,; - s,/.*\\\${dd}styles\\\${dd}rgb.txt,\\\${LATEX2HTMLDIR}/styles/rgb.txt,; - s,/.*\\\${dd}styles\\\${dd}crayola.txt,\\\${LATEX2HTMLDIR}/styles/crayola.txt," jlatex2html -perl -pi -e"s,$RPM_BUILD_ROOT,," l2hconf.pm + s,/.*\\\${dd}pstoimg,%{_bindir}/jpstoimg,; + s,/.*\\\${dd}icons,\\\${LATEX2HTMLDIR}/icons,; + s,/.*\\\${dd}styles\\\${dd}rgb.txt,\\\${LATEX2HTMLDIR}/styles/rgb.txt,; + s,/.*\\\${dd}styles\\\${dd}crayola.txt,\\\${LATEX2HTMLDIR}/styles/crayola.txt," jlatex2html +perl -pi -e"s,%{buildroot},," l2hconf.pm make install rm -f %{buildroot}%{_datadir}/jlatex2html/versions/table.pl.orig -perl -pi -e"s,$RPM_BUILD_ROOT,," %{buildroot}%{_datadir}/jlatex2html/cfgcache.pm -perl -pi -e"s,$RPM_BUILD_ROOT,," %{buildroot}%{_bindir}/jpstoimg -perl -pi -e"s,$RPM_BUILD_ROOT,," %{buildroot}%{_bindir}/jtexexpand -perl -pi -e"s,$RPM_BUILD_ROOT,," cfgcache.pm +rm -rf %{buildroot}%{_datadir}/jlatex2html/docs/ +rm -rf %{buildroot}%{_datadir}/jlatex2html/example/ +perl -pi -e"s,%{buildroot},," %{buildroot}%{_datadir}/jlatex2html/cfgcache.pm +perl -pi -e"s,%{buildroot},," %{buildroot}%{_bindir}/jpstoimg +perl -pi -e"s,%{buildroot},," %{buildroot}%{_bindir}/jtexexpand +perl -pi -e"s,%{buildroot},," cfgcache.pm perl -pi -e"s,$cfg{'GS_LIB'} = q'';,$cfg{'GS_LIB'} = q'%{_datadir}/ghostscript/`ghostscript --version`';," cfgcache.pm install -m0644 *.pm %{buildroot}%{_datadir}/jlatex2html +chmod +x %{buildroot}%{_datadir}/jlatex2html/makeseg/makeseg %{buildroot}%{_datadir}/jlatex2html/makemap popd %endif for f in cweb2html/cweb2html makeseg/makeseg makemap ; do - perl -pi -e "s,/usr/local/bin/perl,/usr/bin/perl," $RPM_BUILD_ROOT%{_datadir}/latex2html/$f + perl -pi -e "s,/usr/local/bin/perl,/usr/bin/perl," %{buildroot}%{_datadir}/latex2html/$f %if %{enable_japanese} - perl -pi -e "s,/usr/local/bin/perl,/usr/bin/perl," $RPM_BUILD_ROOT%{_datadir}/jlatex2html/$f + perl -pi -e "s,/usr/local/bin/perl,/usr/bin/perl," %{buildroot}%{_datadir}/jlatex2html/$f %endif done %clean -rm -rf $RPM_BUILD_ROOT +rm -rf %{buildroot} %post [ -x %{_bindir}/texconfig-sys ] && %{_bindir}/texconfig-sys rehash 2> /dev/null || : @@ -198,6 +205,7 @@ rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root,-) +%doc latex2html-2008/{LICENSE,LICENSE.orig,README,FAQ,BUGS,docs,example} %{_bindir}/latex2html %{_bindir}/pstoimg %{_bindir}/texexpand @@ -219,6 +227,15 @@ rm -rf $RPM_BUILD_ROOT %{_mandir}/man1/pstoimg.* %changelog +* Fri Dec 11 2009 Jindrich Novy 2008-4 +- require netpbm-progs +- review fixes (#225980): + - include documentation + - set executable bit for makeseg and makemap scripts + - white-space spec correction + - move docs and example directory to %%doc + - nuke duplicated stuff + * Fri Jul 24 2009 Fedora Release Engineering - 2008-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild