import trace-cmd-2.9.2-9.el9

This commit is contained in:
CentOS Sources 2022-09-27 10:26:11 -04:00 committed by Stepan Oksanichenko
parent 8c0f087185
commit cc32d104d6
4 changed files with 43 additions and 2 deletions

View File

@ -0,0 +1 @@
SUBSYSTEM=="module", ACTION=="add", PROGRAM="/usr/bin/systemctl is-active trace-cmd.service", PROGRAM="/usr/bin/systemctl reload trace-cmd.service"

4
SOURCES/trace-cmd.conf Normal file
View File

@ -0,0 +1,4 @@
# ftrace based flightrecorder configuration file.
# trace-cmd options
OPTS="-b 2048 -i -e block -e irq -e mce -e module -e power -e sched -e signal -e timer -e workqueue -e kvm -e net"

15
SOURCES/trace-cmd.service Normal file
View File

@ -0,0 +1,15 @@
[Unit]
Description=trace-cmd Flightrecorder
DefaultDependencies=no
Before=sysinit.target
[Service]
Type=oneshot
RemainAfterExit=yes
EnvironmentFile=/etc/sysconfig/trace-cmd.conf
ExecStart=/usr/bin/trace-cmd start $OPTS
ExecStop=/usr/bin/trace-cmd reset
ExecReload=/usr/bin/trace-cmd start $OPTS
[Install]
WantedBy=multi-user.target

View File

@ -6,7 +6,7 @@
Name: trace-cmd
Version: %{srcversion}
Release: 8%{?dist}
Release: 9%{?dist}
License: GPLv2 and LGPLv2
Summary: A user interface to Ftrace
Requires: libtracecmd
@ -19,6 +19,9 @@ URL: http://git.kernel.org/?p=linux/kernel/git/rostedt/trace-cmd.git;a=summary
# cd trace-cmd
# git archive --prefix=trace-cmd-%%{version}/ -o trace-cmd-v%%{version}.tar.gz %%{git_commit}
Source0: https://git.kernel.org/pub/scm/utils/trace-cmd/trace-cmd.git/snapshot/trace-cmd-v%{srcversion}.tar.gz
Source1: trace-cmd.conf
Source2: trace-cmd.service
Source3: 98-trace-cmd.rules
Patch0: trace-cmd-Fix-broken-profile-command.patch
Patch1: trace-cmd-utils.mk-don-t-ignore-LDFLAGS-when-linking-the-share.patch
@ -38,6 +41,7 @@ BuildRequires: json-c-devel
BuildRequires: libtraceevent-devel
BuildRequires: libtracefs-devel
BuildRequires: chrpath
BuildRequires: systemd-rpm-macros
%description
trace-cmd is a user interface to Ftrace. Instead of needing to use the
@ -70,6 +74,9 @@ Development files of the libtracecmd library
%prep
%autosetup -p1 -n %{name}-v%{srcversion}
cp %{SOURCE1} .
cp %{SOURCE2} .
cp %{SOURCE3} .
%build
%set_build_flags
@ -92,7 +99,15 @@ make V=1 libdir=%{_libdir} prefix=%{_prefix} DESTDIR=%{buildroot}/ \
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}%{_libdir} -type f -iname "*.so" | xargs chmod 0755
mkdir -p %{buildroot}/%{_sysconfdir}
mkdir -p -m755 %{buildroot}/%{_sysconfdir}/sysconfig/
mkdir -p -m755 %{buildroot}/%{_unitdir}/
mkdir -p -m755 %{buildroot}/%{_udevrulesdir}/
install -p -m 644 trace-cmd.conf %{buildroot}/%{_sysconfdir}/sysconfig/
install -p -m 644 trace-cmd.service %{buildroot}/%{_unitdir}/
install -p -m 644 98-trace-cmd.rules %{buildroot}/%{_udevrulesdir}/
%preun
%systemd_preun %{name}.service
%files
%doc COPYING COPYING.LIB README
@ -100,6 +115,9 @@ mkdir -p %{buildroot}/%{_sysconfdir}
%{_mandir}/man1/%{name}*
%{_mandir}/man5/%{name}*
%{_sysconfdir}/bash_completion.d/trace-cmd.bash
%{_sysconfdir}/sysconfig/trace-cmd.conf
%{_unitdir}/trace-cmd.service
%{_udevrulesdir}/98-trace-cmd.rules
%files python3
%doc Documentation/README.PythonPlugin
@ -119,6 +137,9 @@ mkdir -p %{buildroot}/%{_sysconfdir}
%{_includedir}/trace-cmd
%changelog
* Thu Mar 31 2022 Jerome Marchand <jmarchan@redhat.com> - 2.9.2-9
- Add flight recorder service
* Fri Nov 12 2021 Jerome Marchand <jmarchan@redhat.com> - 2.9.2-8
- Fix remaining gating runpath failure