bug-automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#32156: automake handling of texinfo files


From: Paul Hardy
Subject: bug#32156: automake handling of texinfo files
Date: Sat, 14 Jul 2018 08:11:49 -0700

Greetings,

Here are three issues surrounding automake handling of Texinfo
files that I have noticed.  This is in automake versions 1.15 and
1.16.1.


FIRST ISSUE:

If for example a doc/Makefile.am file contains a line of the form

     html_TEXINFOS = myprog.texi

then "autoreconf -i" gives the following complaint from automake:

     doc/Makefile.am:6: error: HTML generation not yet supported

Yet automake does support HTML generation of Texinfo files now.
This appears to be an automake bug.


SECOND ISSUE:

Would it be possible to allow a Makefile.am entry of the form

     txt_TEXINFOS = myprog.texi

Then a Makefile could generate a plain text version of a Texinfo
document with something like

     $(MAKEINFO) --plaintext $< -o $@


THIRD ISSUE:

I would like to make a request that there be a standard way to
leave .pdf and .html files (and .txt files, if their support is added)
that were generated from Texinfo sources to remain undeleted
by "make clean".

automake will build a .info file from Texinfo sources, and will leave
it in place with a "make clean" or "make distclean".  The reasoning
given in the Automake manual is that a user should have the .info file
available without having to install packages to build it.

It would be nice to have that capability also apply to .pdf and .html
files produced from Texinfo sources.  I was able to force that in a
way that does not comply with the API, which is why I am writing this
email in response to the section in Chapter 25 of the manual titled
"What is not in the API".  Here is how I did it:

     # Override removal of mypkg.html and mypkg.pdf
     # that happens in clean-aminfo target
     clean: clean-generic mostlyclean-am
          -test -z "mypkg.dvi mypkg.ps" \
          rm -rf mypkg.dvi mypkg.ps

So I redefine the "clean" target, because using a "clean-local"
definition would not override the "clean" target.

I could also have made a non-API-standard modification of the
clean-aminfo target instead.  Either way ventures outside the API.

I can think of two possible ways to generate clean-aminfo differently:

     1) If someone lists <mypkg>.html and/or <mypkg>.pdf in EXTRA_DIST
or some similar variable, then do not have the clean-aminfo target
remove them; or

     2) Allow the user to define a variable such as "AM_TEXINFO_CLEAN"
that would override the default Automake assumption of removing *.pdf,
*.html, *.dvi, and *.ps [this might be easier to implement].

Alternatively, add the target "clean-aminfo" to the API.

I know that the GNU convention is only to preserve a .info file, not
.html or .pdf.  But HTML and PDF files are removed even if a package
is declared as "foreign".

I tried this workaround using automake 1.15 and automake 1.16.1.

What are your thoughts on this?

Thank you,


Paul Hardy





reply via email to

[Prev in Thread] Current Thread [Next in Thread]