linux-trace-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Tzvetomir Stoyanov (VMware)" <tz.stoyanov@gmail.com>
To: rostedt@goodmis.org
Cc: sudipm.mukherjee@gmail.com, linux-trace-devel@vger.kernel.org
Subject: [PATCH] libtracefs: Fix Documentation Makefile
Date: Mon,  4 Jan 2021 11:09:41 +0200	[thread overview]
Message-ID: <20210104090941.424254-1-tz.stoyanov@gmail.com> (raw)

The libtracefs documentation install failes due to missing functions
used in the Makefile. It was coppied from libtraceevent/Documentation,
but not all of the required functions exist in the tracefs build
scripts.

Reported-by: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
Signed-off-by: Tzvetomir Stoyanov (VMware) <tz.stoyanov@gmail.com>
---
 Documentation/Makefile | 39 +++++++++++++++------------------------
 1 file changed, 15 insertions(+), 24 deletions(-)

diff --git a/Documentation/Makefile b/Documentation/Makefile
index e9212df..72b6939 100644
--- a/Documentation/Makefile
+++ b/Documentation/Makefile
@@ -45,19 +45,16 @@ ASCIIDOC_EXTRA += -a mansource="libtracefs" -a manmanual="libtracefs Manual"
 ASCIIDOC_HTML = xhtml5
 endif
 
-XMLTO=xmlto
-
-_tmp_tool_path := $(call get-executable,$(ASCIIDOC))
-ifeq ($(_tmp_tool_path),)
-	missing_tools = $(ASCIIDOC)
+ASCIIDOC_INSTALLED := $(shell command -v $(ASCIIDOC) 2> /dev/null)
+ifndef ASCIIDOC_INSTALLED
+	missing_tools += $(ASCIIDOC)
 endif
 
-ifndef USE_ASCIIDOCTOR
-_tmp_tool_path := $(call get-executable,$(XMLTO))
-ifeq ($(_tmp_tool_path),)
+XMLTO=xmlto
+XMLTO_INSTALLED := $(shell command -v $(XMLTO) 2> /dev/null)
+ifndef XMLTO_INSTALLED
 	missing_tools += $(XMLTO)
 endif
-endif
 
 #
 # For asciidoc ...
@@ -132,7 +129,7 @@ ifneq ($(V),1)
 endif
 endif
 
-all: html man
+all: check-man-tools html man
 
 man: man3
 man3: $(DOC_MAN3)
@@ -141,7 +138,7 @@ html: $(MAN_HTML)
 
 $(MAN_HTML) $(DOC_MAN3): asciidoc.conf
 
-install: install-man install-html
+install: check-man-tools install-man install-html
 
 check-man-tools:
 ifdef missing_tools
@@ -149,28 +146,22 @@ ifdef missing_tools
 endif
 
 do-install-man: man
-	$(call QUIET_INSTALL, Documentation-man) \
-		$(INSTALL) -d -m 755 $(DESTDIR)$(man3dir); \
-		$(INSTALL) -m 644 $(OUTPUT)*.3 $(DESTDIR)$(man3dir);
+	$(Q)$(call do_install,$(OUTPUT)*.3,$(DESTDIR)$(man3dir),644);
 
-install-man: check-man-tools man do-install-man
+install-man: man do-install-man
 
 do-install-html: html
-	$(call QUIET_INSTALL, Documentation-html) \
-		$(INSTALL) -d -m 755 $(DESTDIR)$(htmldir); \
-		$(INSTALL) -m 644 $(OUTPUT)*.html $(DESTDIR)$(htmldir);
+	$(Q)$(call do_install,$(OUTPUT)*.html,$(DESTDIR)$(htmldir),644);
 
-install-html: check-man-tools html do-install-html
+install-html: html do-install-html
 
 uninstall: uninstall-man uninstall-html
 
 uninstall-man:
-	$(call QUIET_UNINST, Documentation-man) \
-		$(Q)$(RM) $(addprefix $(DESTDIR)$(man3dir)/,$(DOC_MAN3))
+	$(Q)$(RM) $(addprefix $(DESTDIR)$(man3dir)/,$(DOC_MAN3))
 
 uninstall-html:
-	$(call QUIET_UNINST, Documentation-html) \
-		$(Q)$(RM) $(addprefix $(DESTDIR)$(htmldir)/,$(MAN_HTML))
+	$(Q)$(RM) $(addprefix $(DESTDIR)$(htmldir)/,$(MAN_HTML))
 
 ifdef missing_tools
   DO_INSTALL_MAN = $(warning Please install $(missing_tools) to have the man pages installed)
@@ -184,7 +175,7 @@ CLEAN_FILES =					\
 	$(DOC_MAN3) *.3
 
 clean:
-	$(call QUIET_CLEAN, Documentation) $(RM) $(CLEAN_FILES)
+	$(Q) $(RM) $(CLEAN_FILES)
 
 ifdef USE_ASCIIDOCTOR
 $(OUTPUT)%.3 : $(OUTPUT)%.txt
-- 
2.29.2


                 reply	other threads:[~2021-01-04  9:10 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210104090941.424254-1-tz.stoyanov@gmail.com \
    --to=tz.stoyanov@gmail.com \
    --cc=linux-trace-devel@vger.kernel.org \
    --cc=rostedt@goodmis.org \
    --cc=sudipm.mukherjee@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).