2013-07-02 04:51:08 +00:00
|
|
|
From: Bastian Blank <waldi@debian.org>
|
|
|
|
Date: Mon, 26 Sep 2011 13:53:12 +0100
|
|
|
|
Subject: Create manpages and binaries including the version
|
|
|
|
Forwarded: no
|
|
|
|
|
|
|
|
[bwh: Fix version insertion in perf man page cross-references and perf
|
|
|
|
man page title. Install bash_completion script for perf with a
|
2014-01-21 05:53:15 +00:00
|
|
|
version-dependent name. And do the same for trace.]
|
2013-07-02 04:51:08 +00:00
|
|
|
|
2014-01-21 05:53:15 +00:00
|
|
|
--- a/tools/perf/Makefile.perf
|
|
|
|
+++ b/tools/perf/Makefile.perf
|
|
|
|
@@ -818,8 +818,8 @@ install-gtk:
|
|
|
|
install-bin: all install-gtk
|
|
|
|
$(call QUIET_INSTALL, binaries) \
|
|
|
|
$(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(bindir_SQ)'; \
|
|
|
|
- $(INSTALL) $(OUTPUT)perf '$(DESTDIR_SQ)$(bindir_SQ)'; \
|
|
|
|
- $(LN) '$(DESTDIR_SQ)$(bindir_SQ)/perf' '$(DESTDIR_SQ)$(bindir_SQ)/trace'
|
|
|
|
+ $(INSTALL) $(OUTPUT)perf '$(DESTDIR_SQ)$(bindir_SQ)/perf_$(VERSION)'; \
|
|
|
|
+ $(LN) '$(DESTDIR_SQ)$(bindir_SQ)/perf_$(VERSION)' '$(DESTDIR_SQ)$(bindir_SQ)/trace_$(VERSION)'
|
|
|
|
$(call QUIET_INSTALL, libexec) \
|
|
|
|
$(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(perfexec_instdir_SQ)'
|
|
|
|
$(call QUIET_INSTALL, perf-archive) \
|
|
|
|
@@ -842,7 +842,7 @@ ifndef NO_LIBPYTHON
|
2013-11-21 01:27:40 +00:00
|
|
|
endif
|
2014-01-21 05:53:15 +00:00
|
|
|
$(call QUIET_INSTALL, bash_completion-script) \
|
|
|
|
$(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(sysconfdir_SQ)/bash_completion.d'; \
|
|
|
|
- $(INSTALL) bash_completion '$(DESTDIR_SQ)$(sysconfdir_SQ)/bash_completion.d/perf'
|
|
|
|
+ $(INSTALL) bash_completion '$(DESTDIR_SQ)$(sysconfdir_SQ)/bash_completion.d/perf_$(VERSION)'
|
|
|
|
$(call QUIET_INSTALL, tests) \
|
|
|
|
$(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(perfexec_instdir_SQ)/tests'; \
|
|
|
|
$(INSTALL) tests/attr.py '$(DESTDIR_SQ)$(perfexec_instdir_SQ)/tests'; \
|
|
|
|
@@ -856,7 +856,7 @@ install-python_ext:
|
2011-09-26 12:53:12 +00:00
|
|
|
|
2013-02-24 05:15:41 +00:00
|
|
|
# 'make install-doc' should call 'make -C Documentation install'
|
|
|
|
$(INSTALL_DOC_TARGETS):
|
|
|
|
- $(QUIET_SUBDIR0)Documentation $(QUIET_SUBDIR1) $(@:-doc=)
|
|
|
|
+ $(QUIET_SUBDIR0)Documentation $(QUIET_SUBDIR1) $(@:-doc=) VERSION=$(VERSION)
|
|
|
|
|
|
|
|
### Cleaning rules
|
2011-09-26 12:53:12 +00:00
|
|
|
|
|
|
|
--- a/tools/perf/Documentation/Makefile
|
|
|
|
+++ b/tools/perf/Documentation/Makefile
|
2014-01-21 05:53:15 +00:00
|
|
|
@@ -183,14 +183,16 @@ ifdef missing_tools
|
2013-02-24 05:15:41 +00:00
|
|
|
$(error "You need to install $(missing_tools) for man pages")
|
|
|
|
endif
|
2011-09-26 12:53:12 +00:00
|
|
|
|
2013-02-24 05:15:41 +00:00
|
|
|
-do-install-man: man
|
|
|
|
+do-install-man: $(addprefix install-man-,$(_DOC_MAN1))
|
2011-09-26 12:53:12 +00:00
|
|
|
+
|
2012-06-09 18:54:23 +00:00
|
|
|
+install-man-perf.1: $(OUTPUT)perf.1
|
2011-09-26 12:53:12 +00:00
|
|
|
+ $(INSTALL) -d -m 755 $(DESTDIR)$(man1dir)
|
2012-06-09 19:18:46 +00:00
|
|
|
+ sed -e 's/"PERF"/"PERF_$(VERSION)"/' -e 's/fBperf-/fBperf_$(VERSION)-/g' $^ > $(DESTDIR)$(man1dir)/perf_$(VERSION).1
|
2011-09-26 12:53:12 +00:00
|
|
|
+
|
2012-06-09 18:54:23 +00:00
|
|
|
+install-man-perf%.1: $(OUTPUT)perf%.1
|
2014-01-21 05:53:15 +00:00
|
|
|
$(call QUIET_INSTALL, Documentation-man) \
|
|
|
|
$(INSTALL) -d -m 755 $(DESTDIR)$(man1dir); \
|
|
|
|
-# $(INSTALL) -d -m 755 $(DESTDIR)$(man5dir); \
|
|
|
|
-# $(INSTALL) -d -m 755 $(DESTDIR)$(man7dir); \
|
|
|
|
- $(INSTALL) -m 644 $(DOC_MAN1) $(DESTDIR)$(man1dir); \
|
|
|
|
-# $(INSTALL) -m 644 $(DOC_MAN5) $(DESTDIR)$(man5dir); \
|
|
|
|
-# $(INSTALL) -m 644 $(DOC_MAN7) $(DESTDIR)$(man7dir)
|
|
|
|
+ sed -e 's/"PERF\\-/"PERF_$(VERSION)\\-/' -e 's/fBperf-/fBperf_$(VERSION)-/g' $^ > $(DESTDIR)$(man1dir)/perf_$(VERSION)$*.1
|
2011-09-26 12:53:12 +00:00
|
|
|
|
2013-02-24 05:15:41 +00:00
|
|
|
install-man: check-man-tools man
|
|
|
|
|