From dc7fd7bfe98e268f96fbc66d6ece4bf6a5bc057c Mon Sep 17 00:00:00 2001 From: Tzvetomir Stoyanov Date: Fri, 10 May 2019 15:56:08 -0400 Subject: tools lib traceevent: Introduce man pages Initial support for libtraceevent man pages - Documentation directory, templates, configurations, Makefiles. The first man page is also part of the patch - summary of the library and all its APIs. Building of the documentation is integrated into the libtraceevent build process, new targets are added to its Makefile: make help make doc make doc-clean make doc-install make doc-uninstall Signed-off-by: Tzvetomir Stoyanov Cc: Andrew Morton Cc: Jiri Olsa Cc: Namhyung Kim Cc: linux-trace-devel@vger.kernel.org Link: http://lore.kernel.org/linux-trace-devel/20190503091119.23399-2-tstoyanov@vmware.com Link: http://lkml.kernel.org/r/20190510200106.104812629@goodmis.org [ Replaced tracefs tracing/events to tracefs events in DESCRIPTION section ] Signed-off-by: Steven Rostedt (VMware) Signed-off-by: Arnaldo Carvalho de Melo --- tools/lib/traceevent/Documentation/asciidoc.conf | 91 ++++++++++++++++++++++++ 1 file changed, 91 insertions(+) create mode 100644 tools/lib/traceevent/Documentation/asciidoc.conf (limited to 'tools/lib/traceevent/Documentation/asciidoc.conf') diff --git a/tools/lib/traceevent/Documentation/asciidoc.conf b/tools/lib/traceevent/Documentation/asciidoc.conf new file mode 100644 index 000000000000..1b03c63fb73a --- /dev/null +++ b/tools/lib/traceevent/Documentation/asciidoc.conf @@ -0,0 +1,91 @@ +## linktep: macro +# +# Usage: linktep:command[manpage-section] +# +# Note, {0} is the manpage section, while {target} is the command. +# +# Show TEP link as: (
); if section is defined, else just show +# the command. + +[macros] +(?su)[\\]?(?Plinktep):(?P\S*?)\[(?P.*?)\]= + +[attributes] +asterisk=* +plus=+ +caret=^ +startsb=[ +endsb=] +tilde=~ + +ifdef::backend-docbook[] +[linktep-inlinemacro] +{0%{target}} +{0#} +{0#{target}{0}} +{0#} +endif::backend-docbook[] + +ifdef::backend-docbook[] +ifndef::tep-asciidoc-no-roff[] +# "unbreak" docbook-xsl v1.68 for manpages. v1.69 works with or without this. +# v1.72 breaks with this because it replaces dots not in roff requests. +[listingblock] +{title} + +ifdef::doctype-manpage[] + .ft C +endif::doctype-manpage[] +| +ifdef::doctype-manpage[] + .ft +endif::doctype-manpage[] + +{title#} +endif::tep-asciidoc-no-roff[] + +ifdef::tep-asciidoc-no-roff[] +ifdef::doctype-manpage[] +# The following two small workarounds insert a simple paragraph after screen +[listingblock] +{title} + +| + +{title#} + +[verseblock] +{title} +{title%} +{title#} +| + +{title#} +{title%} +endif::doctype-manpage[] +endif::tep-asciidoc-no-roff[] +endif::backend-docbook[] + +ifdef::doctype-manpage[] +ifdef::backend-docbook[] +[header] +template::[header-declarations] + + +{mantitle} +{manvolnum} +trace-cmd +{libtraceevent_version} +trace-cmd Manual + + + {manname} + {manpurpose} + +endif::backend-docbook[] +endif::doctype-manpage[] + +ifdef::backend-xhtml11[] +[linktep-inlinemacro] +{target}{0?({0})} +endif::backend-xhtml11[] -- cgit v1.2.3-59-g8ed1b From f7dff58a8b5a35a65379cdc76fe11c168f9ef198 Mon Sep 17 00:00:00 2001 From: Tzvetomir Stoyanov Date: Fri, 10 May 2019 15:56:09 -0400 Subject: tools lib traceevent: Add support for man pages with multiple names Added support for man pages with multiple names, used to combine the description of several APIs into one page. Signed-off-by: Tzvetomir Stoyanov Cc: Andrew Morton Cc: Jiri Olsa Cc: Namhyung Kim Cc: linux-trace-devel@vger.kernel.org Link: http://lore.kernel.org/linux-trace-devel/20190503091119.23399-3-tstoyanov@vmware.com Link: http://lkml.kernel.org/r/20190510200106.263630606@goodmis.org Signed-off-by: Steven Rostedt (VMware) Signed-off-by: Arnaldo Carvalho de Melo --- tools/lib/traceevent/Documentation/asciidoc.conf | 35 ++++++++++++++++++++++-- 1 file changed, 32 insertions(+), 3 deletions(-) (limited to 'tools/lib/traceevent/Documentation/asciidoc.conf') diff --git a/tools/lib/traceevent/Documentation/asciidoc.conf b/tools/lib/traceevent/Documentation/asciidoc.conf index 1b03c63fb73a..07595717f06e 100644 --- a/tools/lib/traceevent/Documentation/asciidoc.conf +++ b/tools/lib/traceevent/Documentation/asciidoc.conf @@ -74,12 +74,41 @@ template::[header-declarations] {mantitle} {manvolnum} -trace-cmd +libtraceevent {libtraceevent_version} -trace-cmd Manual +libtraceevent Manual - {manname} + {manname1} + {manname2} + {manname3} + {manname4} + {manname5} + {manname6} + {manname7} + {manname8} + {manname9} + {manname10} + {manname11} + {manname12} + {manname13} + {manname14} + {manname15} + {manname16} + {manname17} + {manname18} + {manname19} + {manname20} + {manname21} + {manname22} + {manname23} + {manname24} + {manname25} + {manname26} + {manname27} + {manname28} + {manname29} + {manname30} {manpurpose} endif::backend-docbook[] -- cgit v1.2.3-59-g8ed1b