[l2h] Makefile for segmented documentation
alessandro basili
alessandro.basili at cern.ch
Thu Nov 3 17:57:55 CET 2011
Hi,
I'm actually intrigued by the possibility to have a Makefile that runs
over the .tex and produces both the dvi/ps/pdf output as well as the html.
I have followed the example Makefile coming with the package but I'm
having problems extending the idea to a more complex structure of files
and cross-references and my make is either running in a somewhat
infinite loop or simply I never get to the point where "Nothing to be
done for 'all'".
Except for the latex part (which targets .dvi, .aux and .ps) the l2h
part is understood in the following way:
$(TOP)/$(TOP).html target depends on changes on .tex, .aux and any the
.html of each section. Every section depends on the related .tex and on
the internals.pl which contains the references/labels from other sections.
Whenever the .html is targeted, a .stamp is targeted instead, which will
actually run l2h over the .tex and then touch a .stamp file. The .stamp
target has the same dependencies that .html has (why?).
The last and maybe most mysterious part is the internals target, which
is running l2h over the related .tex (which will produce a new
internals.pl only if something changed from previous run).
So if we have 10 sections with various references, we should always have
internals target for each of them and include the dependencies only in
.stamp and .html targets, but to me this approach is not working.
I also found that the Makefile of the main l2h documentation is quite
messy and I failed to make it (didn't try with a bigger hammer though),
so if anyone out there found an elegant solution with Makefiles I'd
really appreciate it.
Cheers,
Al
More information about the latex2html
mailing list