[FFmpeg-devel] [PATCH] doc: enable compilation of monolithic tools doc with --enable-monolithic-tools-doc
Stefano Sabatini
stefasab at gmail.com
Thu Apr 4 11:25:32 CEST 2013
On date Thursday 2013-04-04 09:55:50 +0200, Clément Bœsch encoded:
> On Thu, Apr 04, 2013 at 12:20:35AM +0200, Stefano Sabatini wrote:
> [...]
> > From 4ae2477a05efcd19f4ec88c1753d552a876b2edf Mon Sep 17 00:00:00 2001
> > From: Stefano Sabatini <stefasab at gmail.com>
> > Date: Tue, 19 Mar 2013 20:54:26 +0100
> > Subject: [PATCH] doc: enable compilation of -all tool pages
> >
> > In particular, add documentation configuration system, through the
> > doc/config.texi file.
> >
> > Fix trac issue #2374.
> > ---
> > configure | 13 +++++++++++--
> > doc/Makefile | 21 +++++++++++++++++----
> > doc/all-components.texi | 30 ++++++++++++++++++++++++++++++
> > doc/ffmpeg.texi | 9 +++++++--
> > doc/ffplay.texi | 9 +++++++--
> > doc/ffprobe.texi | 9 +++++++--
> > doc/ffserver.texi | 9 +++++++--
> > 7 files changed, 86 insertions(+), 14 deletions(-)
> > create mode 100644 doc/all-components.texi
> >
> > diff --git a/configure b/configure
> > index 4b46007..a6ab58e 100755
> > --- a/configure
> > +++ b/configure
> > @@ -658,6 +658,12 @@ print_config(){
> > } else if (file ~ /\\.mak\$/) {
> > n = -v ? \"\" : \"!\";
> > printf(\"%s%s=yes\\n\", n, c) >>file;
> > + } else if (file ~ /\\.texi\$/) {
> > + pre = -v ? \"\" : \"@c \";
> > + yesno = \$2;
> > + c2 = tolower(c);
> > + gsub(/_/, \"-\", c2);
> > + printf(\"%s at set %s %s\\n\", pre, c2, yesno) >>file;
> > }
> > }
> > }"
> > @@ -4406,13 +4412,13 @@ fi
> >
> > echo "License: $license"
> >
> > -echo "Creating config.mak and config.h..."
> > +echo "Creating config.mak, config.h, and doc/config.texi..."
> >
>
> doc/config.texi looks .gitignore compliant.
>
> [...]
> > @@ -61,11 +60,22 @@ doc/%.html: doc/%.texi $(SRC_PATH)/doc/t2h.init $(GENTEXI)
> > $(Q)$(TEXIDEP)
> > $(M)texi2html -I doc -monolithic --init-file $(SRC_PATH)/doc/t2h.init --output $@ $<
> >
> > +doc/%-all.html: TAG = HTML
> > +doc/%-all.html: doc/%.texi $(SRC_PATH)/doc/t2h.init $(GENTEXI)
> > + $(Q)$(TEXIDEP)
> > + $(M)texi2html -I doc -monolithic --D=config-all --init-file $(SRC_PATH)/doc/t2h.init --output $@ $<
> > + $(RM) config-all.texi
> > +
>
> > doc/%.pod: TAG = POD
> > doc/%.pod: doc/%.texi $(SRC_PATH)/doc/texi2pod.pl $(GENTEXI)
> > $(Q)$(TEXIDEP)
> > $(M)perl $(SRC_PATH)/doc/texi2pod.pl -Idoc $< $@
> >
> > +doc/%-all.pod: TAG = POD
> > +doc/%-all.pod: doc/%.texi $(SRC_PATH)/doc/texi2pod.pl $(GENTEXI)
> > + $(Q)$(TEXIDEP)
> > + $(M)perl $(SRC_PATH)/doc/texi2pod.pl -Dconfig-all=yes -Idoc $< $@
> > +
>
> I wonder if you can't factorize this. Maybe something like (untested):
>
> doc/%-all.pod: EXTRA_OPTS = -Dconfig-all=yes
> doc/%.pod: TAG = POD
> doc/%.pod: doc/%.texi $(SRC_PATH)/doc/texi2pod.pl $(GENTEXI)
> $(Q)$(TEXIDEP)
> $(M)perl $(SRC_PATH)/doc/texi2pod.pl $(EXTRA_OPTS) -Idoc $< $@
>
> Note: I don't consider this blocking if the above doesn't work.
Doesn't seem to work, suggestions for better code are welcome but I
don't think this should block the patch.
> > doc/%.1 doc/%.3: TAG = MAN
> > doc/%.1: doc/%.pod $(GENTEXI)
> > $(M)pod2man --section=1 --center=" " --release=" " $< > $@
> > @@ -94,6 +104,9 @@ uninstall-man:
> >
> > clean:: docclean
> >
> > +distclean:: docclean
> > + $(RM) doc/config.texi
> > +
> > docclean:
> > $(RM) $(TXTPAGES) doc/*.html doc/*.pod doc/*.1 doc/*.3 $(CLEANSUFFIXES:%=doc/%) doc/avoptions_*.texi
> > $(RM) -r doc/doxy/html
> [...]
> > diff --git a/doc/ffprobe.texi b/doc/ffprobe.texi
> > index 6e30b2f..a4e19bd 100644
> > --- a/doc/ffprobe.texi
> > +++ b/doc/ffprobe.texi
> > @@ -487,10 +487,15 @@ DV, GXF and AVI timecodes are available in format metadata
> > @end itemize
> > @c man end TIMECODE
> >
> > + at include config.texi
> > + at ifset monolithic-tools-doc
> > + at include all-components.texi
> > + at end ifset
> > +
> > @chapter See Also
> >
> > @ifhtml
> > - at url{ffplay.html,ffmpeg}, @url{ffprobe.html,ffprobe}, @url{ffserver.html,ffserver},
> > + at url{ffprobe-all.html,ffprobe-all} @url{ffplay.html,ffmpeg}, @url{ffprobe.html,ffprobe}, @url{ffserver.html,ffserver},
>
> Note: @url{ffplay.html,ffmpeg} looks wrong.
>
> [...]
>
> Rest LGTM
Updated with a few more fixes.
--
FFmpeg = Funny Fiendish Magical Programmable Ermetic Game
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0007-doc-enable-compilation-of-all-tool-pages.patch
Type: text/x-diff
Size: 10049 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20130404/81c638a3/attachment.bin>
More information about the ffmpeg-devel
mailing list