Compare commits
3 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ef6ca71d97 | ||
|
|
e5192b99a6 | ||
|
|
c8043a8cdf |
4 changed files with 93 additions and 9 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -4,3 +4,4 @@
|
||||||
/trace-cmd-2.6.tar.gz
|
/trace-cmd-2.6.tar.gz
|
||||||
/trace-cmd-2.6.1.tar.gz
|
/trace-cmd-2.6.1.tar.gz
|
||||||
/trace-cmd-v2.6.2.tar.gz
|
/trace-cmd-v2.6.2.tar.gz
|
||||||
|
/trace-cmd-v2.7.tar.gz
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,45 @@
|
||||||
|
From 2abc926978474c4588ad43fd49c54f6a7fa3abaf Mon Sep 17 00:00:00 2001
|
||||||
|
From: "Vladislav Valtchev (VMware)" <vladislav.valtchev@gmail.com>
|
||||||
|
Date: Tue, 6 Feb 2018 10:48:59 +0200
|
||||||
|
Subject: [PATCH 01/25] trace-cmd: Fix the logic behind SWIG_DEFINED in the
|
||||||
|
Makefile
|
||||||
|
|
||||||
|
At least on Ubuntu, the $(shell ...) command used in the master Makefile to test
|
||||||
|
for the existence of the 'swig' command does not work in the negative case.
|
||||||
|
That causes the build to report ugly errors in case 'swig' is not installed on
|
||||||
|
the system.
|
||||||
|
This one-line patch, fixes the problem by using the POSIX 'comamnd -v {CMD}'
|
||||||
|
in $(shell ...) to detect the presence of the swig and restores this way the
|
||||||
|
fake report_noswig target.
|
||||||
|
|
||||||
|
Signed-off-by: Vladislav Valtchev (VMware) <vladislav.valtchev@gmail.com>
|
||||||
|
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
|
||||||
|
---
|
||||||
|
Makefile | 4 ++--
|
||||||
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/Makefile b/Makefile
|
||||||
|
index 6217037..85433b8 100644
|
||||||
|
--- a/Makefile
|
||||||
|
+++ b/Makefile
|
||||||
|
@@ -92,7 +92,7 @@ ifndef VERBOSE
|
||||||
|
VERBOSE = 0
|
||||||
|
endif
|
||||||
|
|
||||||
|
-SWIG_DEFINED := $(shell if swig -help &> /dev/null; then echo 1; else echo 0; fi)
|
||||||
|
+SWIG_DEFINED := $(shell if command -v swig; then echo 1; else echo 0; fi)
|
||||||
|
ifeq ($(SWIG_DEFINED), 0)
|
||||||
|
BUILD_PYTHON := report_noswig
|
||||||
|
NO_PYTHON = 1
|
||||||
|
@@ -105,7 +105,7 @@ PYTHON_GUI := ctracecmd.so ctracecmdgui.so
|
||||||
|
PYTHON_VERS ?= python
|
||||||
|
|
||||||
|
# Can build python?
|
||||||
|
-ifeq ($(shell sh -c "pkg-config --cflags $(PYTHON_VERS) > /dev/null 2>&1 && which swig && echo y"), y)
|
||||||
|
+ifeq ($(shell sh -c "pkg-config --cflags $(PYTHON_VERS) > /dev/null 2>&1 && echo y"), y)
|
||||||
|
PYTHON_PLUGINS := plugin_python.so
|
||||||
|
BUILD_PYTHON := $(PYTHON) $(PYTHON_PLUGINS)
|
||||||
|
PYTHON_SO_INSTALL := ctracecmd.install
|
||||||
|
--
|
||||||
|
2.14.3
|
||||||
|
|
||||||
2
sources
2
sources
|
|
@ -1 +1 @@
|
||||||
SHA512 (trace-cmd-v2.6.2.tar.gz) = 9e2f5ff570fb551a7effc5842701c05fad95c1fdfac1ec18d1715c5960f8685f5936e3af50bc13653abeb2dbcdedf47abf17bf4820a3c5c41fd0882bc07fc61a
|
SHA512 (trace-cmd-v2.7.tar.gz) = e507eb6609f1fd3dddec541e9f69c466f4f3f66c28f0a7f4292615e3984cebaaf42725f3d82b8c625e5c60977d1f9b5e96cce7664b951eb5f99b955cc440efe4
|
||||||
|
|
|
||||||
|
|
@ -3,21 +3,20 @@
|
||||||
#%%global git_commit 57371aaa2f469d0ba15fd85276deca7bfdd7ce36
|
#%%global git_commit 57371aaa2f469d0ba15fd85276deca7bfdd7ce36
|
||||||
|
|
||||||
Name: trace-cmd
|
Name: trace-cmd
|
||||||
Version: 2.6.2
|
Version: 2.7
|
||||||
Release: 2%{?dist}
|
Release: 2%{?dist}
|
||||||
License: GPLv2 and LGPLv2
|
License: GPLv2 and LGPLv2
|
||||||
Summary: A user interface to Ftrace
|
Summary: A user interface to Ftrace
|
||||||
|
|
||||||
Group: Development/Tools
|
|
||||||
URL: http://git.kernel.org/?p=linux/kernel/git/rostedt/trace-cmd.git;a=summary
|
URL: http://git.kernel.org/?p=linux/kernel/git/rostedt/trace-cmd.git;a=summary
|
||||||
# If upstream does not provide tarballs.
|
# If upstream does not provide tarballs, to generate:
|
||||||
# To generate:
|
|
||||||
# git clone git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git
|
# git clone git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git
|
||||||
# cd trace-cmd
|
# cd trace-cmd
|
||||||
# git archive --prefix=trace-cmd-%%{version}/ -o trace-cmd-v%%{version}.tar.gz %%{git_commit}
|
# git archive --prefix=trace-cmd-%%{version}/ -o trace-cmd-v%%{version}.tar.gz %%{git_commit}
|
||||||
Source0: https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git/snapshot/%{name}-v%{version}.tar.gz
|
Source0: https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git/snapshot/%{name}-v%{version}.tar.gz
|
||||||
Source1: kernelshark.desktop
|
Source1: kernelshark.desktop
|
||||||
Patch1: 0001-trace-cmd-Figure-out-the-arch-and-install-library-to.patch
|
Patch1: 0001-trace-cmd-Figure-out-the-arch-and-install-library-to.patch
|
||||||
|
Patch2: 0002-trace-cmd-Fix-the-logic-behind-SWIG_DEFINED-in-the-M.patch
|
||||||
BuildRequires: xmlto
|
BuildRequires: xmlto
|
||||||
BuildRequires: asciidoc
|
BuildRequires: asciidoc
|
||||||
BuildRequires: mlocate
|
BuildRequires: mlocate
|
||||||
|
|
@ -34,25 +33,35 @@ tracers and will record into a data file.
|
||||||
|
|
||||||
%package -n kernelshark
|
%package -n kernelshark
|
||||||
Summary: GUI analysis for Ftrace data captured by trace-cmd
|
Summary: GUI analysis for Ftrace data captured by trace-cmd
|
||||||
Group: Development/Tools
|
|
||||||
Requires: trace-cmd%{_isa} = %{version}-%{release}
|
Requires: trace-cmd%{_isa} = %{version}-%{release}
|
||||||
|
|
||||||
%description -n kernelshark
|
%description -n kernelshark
|
||||||
Kernelshark is the GUI frontend for analyzing data produced by
|
Kernelshark is the GUI frontend for analyzing data produced by
|
||||||
'trace-cmd extract'
|
'trace-cmd extract'
|
||||||
|
|
||||||
|
%package python2
|
||||||
|
Summary: Python plugin support for trace-cmd
|
||||||
|
Requires: trace-cmd%{_isa} = %{version}-%{release}
|
||||||
|
BuildRequires: swig
|
||||||
|
BuildRequires: python2-devel
|
||||||
|
|
||||||
|
%description python2
|
||||||
|
Python plugin support for trace-cmd
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n %{name}-v%{version}
|
%setup -q -n %{name}-v%{version}
|
||||||
%patch1 -p1
|
%patch1 -p1
|
||||||
|
%patch2 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
# MANPAGE_DOCBOOK_XSL define is hack to avoid using locate
|
# MANPAGE_DOCBOOK_XSL define is hack to avoid using locate
|
||||||
MANPAGE_DOCBOOK_XSL=`rpm -ql docbook-style-xsl | grep manpages/docbook.xsl`
|
MANPAGE_DOCBOOK_XSL=`rpm -ql docbook-style-xsl | grep manpages/docbook.xsl`
|
||||||
make V=1 CFLAGS="%{optflags} -D_GNU_SOURCE" MANPAGE_DOCBOOK_XSL=$MANPAGE_DOCBOOK_XSL prefix=%{_prefix} all doc gui
|
make V=1 CFLAGS="%{optflags} -D_GNU_SOURCE" LDFLAGS="%{build_ldflags}" \
|
||||||
|
MANPAGE_DOCBOOK_XSL=$MANPAGE_DOCBOOK_XSL prefix=%{_prefix} all doc gui python-plugin
|
||||||
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
make V=1 DESTDIR=%{buildroot}/ prefix=%{_prefix} install install_doc install_gui
|
make V=1 DESTDIR=%{buildroot}/ prefix=%{_prefix} install install_doc install_gui install_python
|
||||||
find %{buildroot}%{_mandir} -type f | xargs chmod u-x,g-x,o-x
|
find %{buildroot}%{_mandir} -type f | xargs chmod u-x,g-x,o-x
|
||||||
find %{buildroot}%{_datadir} -type f | xargs chmod u-x,g-x,o-x
|
find %{buildroot}%{_datadir} -type f | xargs chmod u-x,g-x,o-x
|
||||||
find %{buildroot}%{_libdir} -type f -iname "*.so" | xargs chmod 0755
|
find %{buildroot}%{_libdir} -type f -iname "*.so" | xargs chmod 0755
|
||||||
|
|
@ -63,7 +72,20 @@ desktop-file-validate %{buildroot}/%{_datadir}/applications/kernelshark.desktop
|
||||||
%files
|
%files
|
||||||
%doc COPYING COPYING.LIB README
|
%doc COPYING COPYING.LIB README
|
||||||
%{_bindir}/trace-cmd
|
%{_bindir}/trace-cmd
|
||||||
%{_libdir}/%{name}
|
%dir %{_libdir}/%{name}
|
||||||
|
%dir %{_libdir}/%{name}/plugins
|
||||||
|
%{_libdir}/%{name}/plugins/plugin_blk.so
|
||||||
|
%{_libdir}/%{name}/plugins/plugin_cfg80211.so
|
||||||
|
%{_libdir}/%{name}/plugins/plugin_function.so
|
||||||
|
%{_libdir}/%{name}/plugins/plugin_hrtimer.so
|
||||||
|
%{_libdir}/%{name}/plugins/plugin_jbd2.so
|
||||||
|
%{_libdir}/%{name}/plugins/plugin_kmem.so
|
||||||
|
%{_libdir}/%{name}/plugins/plugin_kvm.so
|
||||||
|
%{_libdir}/%{name}/plugins/plugin_mac80211.so
|
||||||
|
%{_libdir}/%{name}/plugins/plugin_sched_switch.so
|
||||||
|
%{_libdir}/%{name}/plugins/plugin_scsi.so
|
||||||
|
%{_libdir}/%{name}/plugins/plugin_tlb.so
|
||||||
|
%{_libdir}/%{name}/plugins/plugin_xen.so
|
||||||
%{_mandir}/man1/*
|
%{_mandir}/man1/*
|
||||||
%{_mandir}/man5/*
|
%{_mandir}/man5/*
|
||||||
|
|
||||||
|
|
@ -75,8 +97,24 @@ desktop-file-validate %{buildroot}/%{_datadir}/applications/kernelshark.desktop
|
||||||
%{_datadir}/applications/kernelshark.desktop
|
%{_datadir}/applications/kernelshark.desktop
|
||||||
%{_sysconfdir}/bash_completion.d/trace-cmd.bash
|
%{_sysconfdir}/bash_completion.d/trace-cmd.bash
|
||||||
|
|
||||||
|
%files python2
|
||||||
|
%doc Documentation/README.PythonPlugin
|
||||||
|
%{_libdir}/%{name}/plugins/plugin_python.so
|
||||||
|
%{_libdir}/%{name}/python/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Mar 02 2018 Zamir SUN <sztsian@gmail.com> - 2.7-2
|
||||||
|
- Add python plugins
|
||||||
|
|
||||||
|
* Fri Mar 02 2018 Zamir SUN <sztsian@gmail.com> - 2.7-1
|
||||||
|
- Update to 2.7
|
||||||
|
- Remove Groups tag
|
||||||
|
|
||||||
|
* Fri Feb 23 2018 Florian Weimer <fweimer@redhat.com> - 2.6.2-3
|
||||||
|
- Use LDFLAGS from redhat-rpm-config
|
||||||
|
|
||||||
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.6.2-2
|
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.6.2-2
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue