[l2h] Indic-TeX/HTML

Ross Moore ross at ics.mq.edu.au
Wed Dec 7 01:09:27 CET 2005


Hello Bob,

On 07/12/2005, at 9:06 AM, Bob Hueckstedt wrote:

> I have successfully installed LaTeX2HTML on a PC running XP and  
> running TeX via MikTeX. I was even able to get the manual to come  
> out correct in html.

I don't have easy access to this setup, so cannot easily test this.
However, I'll try to help you do tests that may help diagnose
exactly what is going wrong.

> Whether I run latex2html on the dn or the tex file, I get the same  
> response. Here is the relevant portion of the log:
>
> <quote>
> Writing image.pre file . . .
> The syntax of the command is incorrect.

After this error, the next one is not surprising ...
>
> This is TeX, Version 3.141592 (MikTeX 2.4)
> ! I can't find file `.\images.tex'.
> (*) ./images.tex

   ... since  ./images.tex  will not have been created yet.
Presumably the command whose syntax is supposedly bad is
(one step along the path) involved in creating  images.tex .

>
> Please type another input file name:
> <\quote>
>
> I ran latex2html with the -debug option. That gave me two places in  
> latex2html.bat that seem challenged. They are line 3773:
> $preprocessor_cmds .= $this_cmd."\n";
>
> and lines 3799-3803 (particularly line 3801):
> sub make_latex_images{
>     &close_dbm_database if $DJGPP;
>     local($dd) = $dd; $dd = '/' if ($dd eq "\\");
>     local($latex_call) = "$LATEX .$dd${PREFIX}images.tex";
>     print "$latex_call\n" if (($DEBUG)||($VERBOSITY > 1));
>     L2hos->syswait($latex_call);
>     &open_dbm_database if $DJGPP;
> }
>
> Not knowing perl, I'm good and stuck. Any help out of this would be  
> most appreciated.

The place that you want to examine is here:


sub preprocess_images {
     do {
         print "\nWriting image.pre file ...\n";
         open(ENV,">.$dd${PREFIX}images.pre")
             || die "\nCannot write '${PREFIX}images.pre': $!\n";
         print ENV &make_latex($latex_body);
         print ENV "\n";
         close ENV;
         &copy_file($FILE, "bbl");
         &copy_file($FILE, "aux");
         local($num_cmds, $cnt, $this, @cmds);
         @cmds = (split ('\n', $preprocessor_cmds));
         $this_cmd = $num_cmds = 1+$#cmds;
         $cnt = $num_cmds; $preprocessor_cmds = '';
         while (@cmds) {
             $this_cmd = shift @cmds; last unless ($this_cmd);
             $this_cmd =~ s/.pre /.tex$cnt / if(($cnt)&&($cnt <  
$num_cmds));
             $cnt--; $this_cmd .= $cnt if ($cnt);
             $preprocessor_cmds .= $this_cmd."\n";
             L2hos->syswait($this_cmd);
         }
         # save pre-processor commands in a file:  preproc
         open(CMDS,">.$dd${PREFIX}preproc")
             || die "\nCannot write '${PREFIX}preproc': $!\n";
         print CMDS $preprocessor_cmds ;
         close CMDS;

     } if ((%latex_body) && ($latex_body =~ /newpage/));
}

This is at ~ line 3729 .
The line number may change a bit with version and installation.

You can see the first  print  message.
The operating system calls come at the  syswait  command,
within a loop --- in case there is more than one step involved.

All the commands should have been written into a file,
named   preproc .

Can you find that file for your job ?
It should be in the subdirectory where the pages are being built.

Try executing the lines in there, one at a time.
What happens ?
It should either:
    (i)  work just fine;
OR
    (ii) give that message about a syntax error.


If (i) then we need to find an explanation for it not working
within the LaTeX2HTML job, even though it works manually.

If (ii) then either:
   (a) there is some syntax used by XP that isn't the same as for DOS;
or
   (b) latex2html  didn't install correctly under XP, at least for you.


Note that the version of LaTeX2HTML that you are using was written
before XP was available as an operating system.
So it is quite possible that you are testing portions of it that
have not been run before in this setting. That's unlikely, but
nevertheless possible, as LaTeX2HTML was developed primarily to
be a Unix tool. That it works at all under Windows is due to other
developers, who may not have tested all the possible aspects.


>
> The only thing that happened during the installation, when I ran  
> config, was that the netpbm I fetched had no pnmflip (it being now  
> a perl file), no ppmquant (same -- a perl file) and no anytopnm  
> (also a perl file). But I doubt any of this is relevant. But what  
> do I know?

It's not relevant yet, but may become so when we get past the pre- 
processor
problem.

Even so, those Perl files should still be executables.
What messages, from the installation procedure, led you
to mention them here ?


Hope this helps,

	Ross Moore

>
> Bob Hueckstedt
> Professor of Sanskrit
> Univerity of Virginia
>
> _______________________________________________
> latex2html mailing list
> latex2html at tug.org
> http://tug.org/mailman/listinfo/latex2html

------------------------------------------------------------------------
Ross Moore                                         ross at maths.mq.edu.au
Mathematics Department                             office: E7A-419
Macquarie University                               tel: +61 +2 9850 8955
Sydney, Australia  2109                            fax: +61 +2 9850 8114
------------------------------------------------------------------------




More information about the latex2html mailing list