|
|
|
@ -1,19 +1,19 @@
|
|
|
|
|
%{!?with_sqlite: %global with_sqlite 0%{?fedora} >= 17 || 0%{?rhel} >= 7}
|
|
|
|
|
# prefer prebuilt docs
|
|
|
|
|
%{!?with_docs: %global with_docs 0}
|
|
|
|
|
%{!?with_docs: %global with_docs 1}
|
|
|
|
|
%{!?with_htmldocs: %global with_htmldocs 0}
|
|
|
|
|
%{!?with_monitor: %global with_monitor 1}
|
|
|
|
|
# crash is not available
|
|
|
|
|
%ifarch ppc ppc64 %{sparc} %{mips}
|
|
|
|
|
%ifarch ppc ppc64 %{sparc} aarch64 ppc64le %{mips}
|
|
|
|
|
%{!?with_crash: %global with_crash 0}
|
|
|
|
|
%else
|
|
|
|
|
%{!?with_crash: %global with_crash 1}
|
|
|
|
|
%endif
|
|
|
|
|
%{!?with_rpm: %global with_rpm 1}
|
|
|
|
|
%{!?with_bundled_elfutils: %global with_bundled_elfutils 0}
|
|
|
|
|
%{!?elfutils_version: %global elfutils_version 0.142}
|
|
|
|
|
%{!?pie_supported: %global pie_supported 1}
|
|
|
|
|
%{!?with_boost: %global with_boost 0}
|
|
|
|
|
%ifarch %{ix86} x86_64 ppc ppc64 ppc64le aarch64
|
|
|
|
|
%ifarch %{ix86} x86_64 ppc ppc64
|
|
|
|
|
%{!?with_dyninst: %global with_dyninst 0%{?fedora} >= 18 || 0%{?rhel} >= 7}
|
|
|
|
|
%else
|
|
|
|
|
%{!?with_dyninst: %global with_dyninst 0}
|
|
|
|
@ -33,18 +33,14 @@
|
|
|
|
|
%{!?with_openssl: %global with_openssl 0}
|
|
|
|
|
%endif
|
|
|
|
|
%{!?with_pyparsing: %global with_pyparsing 0%{?fedora} >= 18 || 0%{?rhel} >= 7}
|
|
|
|
|
%{!?with_python3: %global with_python3 0%{?fedora} >= 23 || 0%{?rhel} > 7}
|
|
|
|
|
%{!?with_python2_probes: %global with_python2_probes (0%{?fedora} <= 28 && 0%{?rhel} <= 7)}
|
|
|
|
|
%{!?with_python3_probes: %global with_python3_probes (0%{?fedora} >= 23 || 0%{?rhel} > 7)}
|
|
|
|
|
%{!?with_python3: %global with_python3 0%{?fedora} >= 23}
|
|
|
|
|
%{!?with_python2_probes: %global with_python2_probes 1}
|
|
|
|
|
%{!?with_python3_probes: %global with_python3_probes 0%{?fedora} >= 23}
|
|
|
|
|
%{!?with_httpd: %global with_httpd 0}
|
|
|
|
|
%{!?with_specific_python: %global with_specific_python 0%{?fedora} >= 31}
|
|
|
|
|
|
|
|
|
|
# Virt is supported on these arches, even on el7, but it's not in core EL7
|
|
|
|
|
%if 0%{?rhel} <= 7
|
|
|
|
|
%ifarch ppc64le aarch64
|
|
|
|
|
%global with_virthost 0
|
|
|
|
|
%endif
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if 0%{?fedora} >= 18 || 0%{?rhel} >= 6
|
|
|
|
|
%define initdir %{_initddir}
|
|
|
|
@ -70,26 +66,18 @@
|
|
|
|
|
%define dracutstap %{_prefix}/share/dracut/modules.d/99stap
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if 0%{?rhel} == 6 || 0%{?rhel} == 7
|
|
|
|
|
%if 0%{?rhel} >= 6
|
|
|
|
|
%define dracutbindir /sbin
|
|
|
|
|
%else
|
|
|
|
|
%define dracutbindir %{_bindir}
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if 0%{?rhel} == 6
|
|
|
|
|
%{!?_rpmmacrodir: %define _rpmmacrodir /etc/rpm/}
|
|
|
|
|
%else
|
|
|
|
|
%{!?_rpmmacrodir: %define _rpmmacrodir %{_rpmconfigdir}/macros.d}
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
# To avoid testsuite/*/*.stp has shebang which doesn't start with '/'
|
|
|
|
|
%define __brp_mangle_shebangs_exclude_from .stp$
|
|
|
|
|
|
|
|
|
|
Name: systemtap
|
|
|
|
|
Version: 4.3
|
|
|
|
|
Release: 0.20200212git91ffb97ad335%{?dist}
|
|
|
|
|
Version: 3.2
|
|
|
|
|
Release: 2%{?dist}
|
|
|
|
|
# for version, see also configure.ac
|
|
|
|
|
|
|
|
|
|
Patch10: rhbz1504009.patch
|
|
|
|
|
|
|
|
|
|
# Packaging abstract:
|
|
|
|
|
#
|
|
|
|
@ -119,18 +107,19 @@ Release: 0.20200212git91ffb97ad335%{?dist}
|
|
|
|
|
# intermediary stap-server for --use-server: systemtap-server (-devel unused)
|
|
|
|
|
|
|
|
|
|
Summary: Programmable system-wide instrumentation system
|
|
|
|
|
Group: Development/System
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
Source: %{name}-%{version}-0.20200211git91ffb97ad335.tar.gz
|
|
|
|
|
Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz
|
|
|
|
|
|
|
|
|
|
# Build*
|
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
|
|
|
BuildRequires: gcc-c++
|
|
|
|
|
BuildRequires: cpio
|
|
|
|
|
BuildRequires: gettext-devel
|
|
|
|
|
BuildRequires: pkgconfig(nss)
|
|
|
|
|
BuildRequires: pkgconfig(avahi-client)
|
|
|
|
|
%if %{with_dyninst}
|
|
|
|
|
BuildRequires: dyninst-devel >= 10.0
|
|
|
|
|
BuildRequires: dyninst-devel >= 8.0
|
|
|
|
|
BuildRequires: pkgconfig(libselinux)
|
|
|
|
|
%endif
|
|
|
|
|
%if %{with_sqlite}
|
|
|
|
@ -153,7 +142,14 @@ BuildRequires: crash-devel zlib-devel
|
|
|
|
|
%if %{with_rpm}
|
|
|
|
|
BuildRequires: rpm-devel
|
|
|
|
|
%endif
|
|
|
|
|
%if %{with_bundled_elfutils}
|
|
|
|
|
Source1: elfutils-%{elfutils_version}.tar.gz
|
|
|
|
|
Patch1: elfutils-portability.patch
|
|
|
|
|
BuildRequires: m4
|
|
|
|
|
%global setup_elfutils -a1
|
|
|
|
|
%else
|
|
|
|
|
BuildRequires: elfutils-devel >= %{elfutils_version}
|
|
|
|
|
%endif
|
|
|
|
|
%if %{with_docs}
|
|
|
|
|
BuildRequires: /usr/bin/latex /usr/bin/dvips /usr/bin/ps2pdf
|
|
|
|
|
%if 0%{?fedora} >= 18 || 0%{?rhel} >= 7
|
|
|
|
@ -185,20 +181,13 @@ BuildRequires: readline-devel
|
|
|
|
|
BuildRequires: pkgconfig(ncurses)
|
|
|
|
|
%endif
|
|
|
|
|
%if %{with_python2_probes}
|
|
|
|
|
BuildRequires: python2-devel
|
|
|
|
|
%if 0%{?fedora} >= 1
|
|
|
|
|
BuildRequires: python2-setuptools
|
|
|
|
|
%else
|
|
|
|
|
BuildRequires: python-devel
|
|
|
|
|
BuildRequires: python-setuptools
|
|
|
|
|
%endif
|
|
|
|
|
%endif
|
|
|
|
|
%if %{with_python3_probes}
|
|
|
|
|
BuildRequires: python3-devel
|
|
|
|
|
BuildRequires: python3-setuptools
|
|
|
|
|
%endif
|
|
|
|
|
%if %{with_specific_python}
|
|
|
|
|
BuildRequires: /usr/bin/pathfix.py
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with_httpd}
|
|
|
|
|
BuildRequires: libmicrohttpd-devel
|
|
|
|
@ -219,26 +208,26 @@ the components needed to locally develop and execute systemtap scripts.
|
|
|
|
|
|
|
|
|
|
%package server
|
|
|
|
|
Summary: Instrumentation System Server
|
|
|
|
|
Group: Development/System
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
Requires: systemtap-devel = %{version}-%{release}
|
|
|
|
|
Conflicts: systemtap-devel < %{version}-%{release}
|
|
|
|
|
Conflicts: systemtap-runtime < %{version}-%{release}
|
|
|
|
|
Conflicts: systemtap-client < %{version}-%{release}
|
|
|
|
|
Requires: nss coreutils
|
|
|
|
|
# On RHEL[45], /bin/mktemp comes from the 'mktemp' package. On newer
|
|
|
|
|
# distributions, /bin/mktemp comes from the 'coreutils' package. To
|
|
|
|
|
# avoid a specific RHEL[45] Requires, we'll do a file-based require.
|
|
|
|
|
Requires: nss /bin/mktemp
|
|
|
|
|
Requires: zip unzip
|
|
|
|
|
Requires(pre): shadow-utils
|
|
|
|
|
Requires(post): chkconfig
|
|
|
|
|
Requires(preun): chkconfig
|
|
|
|
|
Requires(preun): initscripts
|
|
|
|
|
Requires(postun): initscripts
|
|
|
|
|
BuildRequires: nss-devel avahi-devel
|
|
|
|
|
%if %{with_openssl}
|
|
|
|
|
Requires: openssl
|
|
|
|
|
%endif
|
|
|
|
|
%if %{with_systemd}
|
|
|
|
|
Requires: systemd
|
|
|
|
|
%else
|
|
|
|
|
Requires(post): chkconfig
|
|
|
|
|
Requires(preun): chkconfig
|
|
|
|
|
Requires(preun): initscripts
|
|
|
|
|
Requires(postun): initscripts
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%description server
|
|
|
|
@ -249,20 +238,15 @@ compiles systemtap scripts to kernel objects on their demand.
|
|
|
|
|
|
|
|
|
|
%package devel
|
|
|
|
|
Summary: Programmable system-wide instrumentation system - development headers, tools
|
|
|
|
|
Group: Development/System
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
|
|
|
|
|
%if 0%{?rhel} >= 8 || 0%{?fedora} >= 20
|
|
|
|
|
Recommends: (kernel-debug-devel if kernel-debug)
|
|
|
|
|
Recommends: (kernel-devel if kernel)
|
|
|
|
|
%else
|
|
|
|
|
# The virtual provide 'kernel-devel-uname-r' tries to get the right
|
|
|
|
|
# kernel variant (kernel-PAE, kernel-debug, etc.) devel package
|
|
|
|
|
# installed.
|
|
|
|
|
Requires: kernel-devel-uname-r
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%{?fedora:Suggests: kernel-devel}
|
|
|
|
|
Requires: gcc make
|
|
|
|
|
Conflicts: systemtap-client < %{version}-%{release}
|
|
|
|
|
Conflicts: systemtap-server < %{version}-%{release}
|
|
|
|
|
Conflicts: systemtap-runtime < %{version}-%{release}
|
|
|
|
|
# Suggest: kernel-debuginfo
|
|
|
|
|
|
|
|
|
|
%description devel
|
|
|
|
@ -276,12 +260,10 @@ a copy of the standard tapset library and the runtime library C files.
|
|
|
|
|
|
|
|
|
|
%package runtime
|
|
|
|
|
Summary: Programmable system-wide instrumentation system - runtime
|
|
|
|
|
Group: Development/System
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
Requires(pre): shadow-utils
|
|
|
|
|
Conflicts: systemtap-devel < %{version}-%{release}
|
|
|
|
|
Conflicts: systemtap-server < %{version}-%{release}
|
|
|
|
|
Conflicts: systemtap-client < %{version}-%{release}
|
|
|
|
|
|
|
|
|
|
%description runtime
|
|
|
|
|
SystemTap runtime contains the components needed to execute
|
|
|
|
@ -291,15 +273,13 @@ using a local or remote systemtap-devel installation.
|
|
|
|
|
|
|
|
|
|
%package client
|
|
|
|
|
Summary: Programmable system-wide instrumentation system - client
|
|
|
|
|
Group: Development/System
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
Requires: zip unzip
|
|
|
|
|
Requires: systemtap-runtime = %{version}-%{release}
|
|
|
|
|
Requires: coreutils grep sed unzip zip
|
|
|
|
|
Requires: openssh-clients
|
|
|
|
|
Conflicts: systemtap-devel < %{version}-%{release}
|
|
|
|
|
Conflicts: systemtap-server < %{version}-%{release}
|
|
|
|
|
Conflicts: systemtap-runtime < %{version}-%{release}
|
|
|
|
|
%if %{with_mokutil}
|
|
|
|
|
Requires: mokutil
|
|
|
|
|
%endif
|
|
|
|
@ -314,17 +294,14 @@ documentation, and a copy of the tapset library for reference.
|
|
|
|
|
|
|
|
|
|
%package initscript
|
|
|
|
|
Summary: Systemtap Initscripts
|
|
|
|
|
Group: Development/System
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
Requires: systemtap = %{version}-%{release}
|
|
|
|
|
%if %{with_systemd}
|
|
|
|
|
Requires: systemd
|
|
|
|
|
%else
|
|
|
|
|
Requires(post): chkconfig
|
|
|
|
|
Requires(preun): chkconfig
|
|
|
|
|
Requires(preun): initscripts
|
|
|
|
|
Requires(postun): initscripts
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%description initscript
|
|
|
|
|
This package includes a SysVinit script to launch selected systemtap
|
|
|
|
@ -334,17 +311,14 @@ boot-time probing if supported.
|
|
|
|
|
|
|
|
|
|
%package sdt-devel
|
|
|
|
|
Summary: Static probe support tools
|
|
|
|
|
Group: Development/System
|
|
|
|
|
License: GPLv2+ and Public Domain
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
%if %{with_pyparsing}
|
|
|
|
|
%if %{with_python3}
|
|
|
|
|
Requires: python3-pyparsing
|
|
|
|
|
%else
|
|
|
|
|
%if 0%{?rhel} >= 7
|
|
|
|
|
Requires: pyparsing
|
|
|
|
|
%else
|
|
|
|
|
Requires: python2-pyparsing
|
|
|
|
|
%endif
|
|
|
|
|
%endif
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
@ -357,6 +331,7 @@ with the optional dtrace-compatibility preprocessor to process related
|
|
|
|
|
|
|
|
|
|
%package testsuite
|
|
|
|
|
Summary: Instrumentation System Testsuite
|
|
|
|
|
Group: Development/System
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
Requires: systemtap = %{version}-%{release}
|
|
|
|
@ -414,21 +389,23 @@ systemtap on the current system.
|
|
|
|
|
%if %{with_java}
|
|
|
|
|
%package runtime-java
|
|
|
|
|
Summary: Systemtap Java Runtime Support
|
|
|
|
|
Group: Development/System
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
Requires: systemtap-runtime = %{version}-%{release}
|
|
|
|
|
Requires: byteman > 2.0
|
|
|
|
|
Requires: iproute
|
|
|
|
|
Requires: java-devel
|
|
|
|
|
Requires: net-tools
|
|
|
|
|
|
|
|
|
|
%description runtime-java
|
|
|
|
|
This package includes support files needed to run systemtap scripts
|
|
|
|
|
that probe Java processes running on the OpenJDK runtimes using Byteman.
|
|
|
|
|
that probe Java processes running on the OpenJDK 1.6 and OpenJDK 1.7
|
|
|
|
|
runtimes using Byteman.
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with_python2_probes}
|
|
|
|
|
%package runtime-python2
|
|
|
|
|
Summary: Systemtap Python 2 Runtime Support
|
|
|
|
|
Group: Development/System
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
Requires: systemtap-runtime = %{version}-%{release}
|
|
|
|
@ -441,36 +418,20 @@ that probe python 2 processes.
|
|
|
|
|
%if %{with_python3_probes}
|
|
|
|
|
%package runtime-python3
|
|
|
|
|
Summary: Systemtap Python 3 Runtime Support
|
|
|
|
|
Group: Development/System
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
Requires: systemtap-runtime = %{version}-%{release}
|
|
|
|
|
|
|
|
|
|
%if ! (%{with_python2_probes})
|
|
|
|
|
# Provide an clean upgrade path when the python2 package is removed
|
|
|
|
|
Obsoletes: %{name}-runtime-python2 < %{version}-%{release}
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%description runtime-python3
|
|
|
|
|
This package includes support files needed to run systemtap scripts
|
|
|
|
|
that probe python 3 processes.
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with_python3}
|
|
|
|
|
%package exporter
|
|
|
|
|
Summary: Systemtap-prometheus interoperation mechanism
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
Requires: systemtap-runtime = %{version}-%{release}
|
|
|
|
|
|
|
|
|
|
%description exporter
|
|
|
|
|
This package includes files for a systemd service that manages
|
|
|
|
|
systemtap sessions and relays prometheus metrics from the sessions
|
|
|
|
|
to remote requesters on demand.
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with_virthost}
|
|
|
|
|
%package runtime-virthost
|
|
|
|
|
Summary: Systemtap Cross-VM Instrumentation - host
|
|
|
|
|
Group: Development/System
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
Requires: libvirt >= 1.0.2
|
|
|
|
@ -485,6 +446,7 @@ connection.
|
|
|
|
|
%if %{with_virtguest}
|
|
|
|
|
%package runtime-virtguest
|
|
|
|
|
Summary: Systemtap Cross-VM Instrumentation - guest
|
|
|
|
|
Group: Development/System
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: http://sourceware.org/systemtap/
|
|
|
|
|
Requires: systemtap-runtime = %{version}-%{release}
|
|
|
|
@ -506,10 +468,37 @@ systemtap-runtime-virthost machine to execute systemtap scripts.
|
|
|
|
|
# ------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%setup -q
|
|
|
|
|
%setup -q %{?setup_elfutils}
|
|
|
|
|
|
|
|
|
|
%if %{with_bundled_elfutils}
|
|
|
|
|
cd elfutils-%{elfutils_version}
|
|
|
|
|
%patch1 -p1
|
|
|
|
|
sleep 1
|
|
|
|
|
find . \( -name Makefile.in -o -name aclocal.m4 \) -print | xargs touch
|
|
|
|
|
sleep 1
|
|
|
|
|
find . \( -name configure -o -name config.h.in \) -print | xargs touch
|
|
|
|
|
cd ..
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%patch10 -p1
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
|
|
|
|
|
%if %{with_bundled_elfutils}
|
|
|
|
|
# Build our own copy of elfutils.
|
|
|
|
|
%global elfutils_config --with-elfutils=elfutils-%{elfutils_version}
|
|
|
|
|
|
|
|
|
|
# We have to prevent the standard dependency generation from identifying
|
|
|
|
|
# our private elfutils libraries in our provides and requires.
|
|
|
|
|
%global _use_internal_dependency_generator 0
|
|
|
|
|
%global filter_eulibs() /bin/sh -c "%{1} | sed '/libelf/d;/libdw/d;/libebl/d'"
|
|
|
|
|
%global __find_provides %{filter_eulibs /usr/lib/rpm/find-provides}
|
|
|
|
|
%global __find_requires %{filter_eulibs /usr/lib/rpm/find-requires}
|
|
|
|
|
|
|
|
|
|
# This will be needed for running stap when not installed, for the test suite.
|
|
|
|
|
%global elfutils_mflags LD_LIBRARY_PATH=`pwd`/lib-elfutils
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
# Enable/disable the dyninst pure-userspace backend
|
|
|
|
|
%if %{with_dyninst}
|
|
|
|
|
%global dyninst_config --with-dyninst
|
|
|
|
@ -545,7 +534,7 @@ systemtap-runtime-virthost machine to execute systemtap scripts.
|
|
|
|
|
%global docs_config --enable-docs --disable-htmldocs
|
|
|
|
|
%endif
|
|
|
|
|
%else
|
|
|
|
|
%global docs_config --enable-docs=prebuilt
|
|
|
|
|
%global docs_config --disable-docs
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
# Enable pie as configure defaults to disabling it
|
|
|
|
@ -596,20 +585,18 @@ systemtap-runtime-virthost machine to execute systemtap scripts.
|
|
|
|
|
%global httpd_config --disable-httpd
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with_bpf}
|
|
|
|
|
%global bpf_config --with-bpf
|
|
|
|
|
%else
|
|
|
|
|
%global bpf_config --without-bpf
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
# We don't ship compileworthy python code, just oddball samples
|
|
|
|
|
%global py_auto_byte_compile 0
|
|
|
|
|
|
|
|
|
|
%configure %{dyninst_config} %{sqlite_config} %{crash_config} %{docs_config} %{pie_config} %{rpm_config} %{java_config} %{virt_config} %{dracut_config} %{python3_config} %{python2_probes_config} %{python3_probes_config} %{httpd_config} %{bpf_config} --disable-silent-rules --with-extra-version="rpm %{version}-%{release}"
|
|
|
|
|
%configure %{?elfutils_config} %{dyninst_config} %{sqlite_config} %{crash_config} %{docs_config} %{pie_config} %{rpm_config} %{java_config} %{virt_config} %{dracut_config} %{python3_config} %{python2_probes_config} %{python3_probes_config} %{httpd_config} --disable-silent-rules --with-extra-version="rpm %{version}-%{release}"
|
|
|
|
|
make %{?_smp_mflags}
|
|
|
|
|
|
|
|
|
|
%if %{with_emacsvim}
|
|
|
|
|
%{_emacs_bytecompile} emacs/systemtap-mode.el
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
rm -rf ${RPM_BUILD_ROOT}
|
|
|
|
|
make DESTDIR=$RPM_BUILD_ROOT install
|
|
|
|
|
%find_lang %{name}
|
|
|
|
|
for dir in $(ls -1d $RPM_BUILD_ROOT%{_mandir}/{??,??_??}) ; do
|
|
|
|
@ -638,21 +625,19 @@ install -c -m 755 stap-prep $RPM_BUILD_ROOT%{_bindir}/stap-prep
|
|
|
|
|
# Copy over the testsuite
|
|
|
|
|
cp -rp testsuite $RPM_BUILD_ROOT%{_datadir}/systemtap
|
|
|
|
|
|
|
|
|
|
%if %{with_docs}
|
|
|
|
|
# We want the manuals in the special doc dir, not the generic doc install dir.
|
|
|
|
|
# We build it in place and then move it away so it doesn't get installed
|
|
|
|
|
# twice. rpm can specify itself where the (versioned) docs go with the
|
|
|
|
|
# %doc directive.
|
|
|
|
|
mkdir docs.installed
|
|
|
|
|
mv $RPM_BUILD_ROOT%{_datadir}/doc/systemtap/*.pdf docs.installed/
|
|
|
|
|
%if %{with_docs}
|
|
|
|
|
%if %{with_htmldocs}
|
|
|
|
|
mv $RPM_BUILD_ROOT%{_datadir}/doc/systemtap/tapsets docs.installed/
|
|
|
|
|
mv $RPM_BUILD_ROOT%{_datadir}/doc/systemtap/SystemTap_Beginners_Guide docs.installed/
|
|
|
|
|
%endif
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
install -D -m 644 macros.systemtap $RPM_BUILD_ROOT%{_rpmmacrodir}/macros.systemtap
|
|
|
|
|
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/stap-server
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/lib/stap-server
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/lib/stap-server/.systemtap
|
|
|
|
@ -662,27 +647,12 @@ mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/cache/systemtap
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/run/systemtap
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d
|
|
|
|
|
install -m 644 initscript/logrotate.stap-server $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/stap-server
|
|
|
|
|
|
|
|
|
|
# If using systemd systemtap.service file, retain the old init script in %{_libexecdir} as a helper.
|
|
|
|
|
%if %{with_systemd}
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_unitdir}
|
|
|
|
|
touch $RPM_BUILD_ROOT%{_unitdir}/systemtap.service
|
|
|
|
|
install -m 644 initscript/systemtap.service $RPM_BUILD_ROOT%{_unitdir}/systemtap.service
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_sbindir}
|
|
|
|
|
install -m 755 initscript/systemtap $RPM_BUILD_ROOT%{_sbindir}/systemtap-service
|
|
|
|
|
%else
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{initdir}
|
|
|
|
|
install -m 755 initscript/systemtap $RPM_BUILD_ROOT%{initdir}
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_sbindir}
|
|
|
|
|
ln -sf %{initdir}/systemtap $RPM_BUILD_ROOT%{_sbindir}/systemtap-service
|
|
|
|
|
# TODO CHECK CORRECTNESS: symlink %{_sbindir}/systemtap-service to %{initdir}/systemtap
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/systemtap
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/systemtap/conf.d
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/systemtap/script.d
|
|
|
|
|
install -m 644 initscript/config.systemtap $RPM_BUILD_ROOT%{_sysconfdir}/systemtap/config
|
|
|
|
|
|
|
|
|
|
%if %{with_systemd}
|
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_unitdir}
|
|
|
|
|
touch $RPM_BUILD_ROOT%{_unitdir}/stap-server.service
|
|
|
|
@ -735,32 +705,21 @@ done
|
|
|
|
|
touch $RPM_BUILD_ROOT%{dracutstap}/params.conf
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with_specific_python}
|
|
|
|
|
# Some files got ambiguous python shebangs, we fix them after everything else is done
|
|
|
|
|
pathfix.py -pni "%{__python3} %{py3_shbang_opts}" %{buildroot}%{python3_sitearch} %{buildroot}%{_bindir}/*
|
|
|
|
|
%endif
|
|
|
|
|
%clean
|
|
|
|
|
rm -rf ${RPM_BUILD_ROOT}
|
|
|
|
|
|
|
|
|
|
%pre runtime
|
|
|
|
|
getent group stapusr >/dev/null || groupadd -f -g 156 -r stapusr
|
|
|
|
|
getent group stapsys >/dev/null || groupadd -f -g 157 -r stapsys
|
|
|
|
|
getent group stapdev >/dev/null || groupadd -f -g 158 -r stapdev
|
|
|
|
|
getent group stapusr >/dev/null || groupadd -g 156 -r stapusr 2>/dev/null || groupadd -r stapusr
|
|
|
|
|
getent group stapsys >/dev/null || groupadd -g 157 -r stapsys 2>/dev/null || groupadd -r stapsys
|
|
|
|
|
getent group stapdev >/dev/null || groupadd -g 158 -r stapdev 2>/dev/null || groupadd -r stapdev
|
|
|
|
|
exit 0
|
|
|
|
|
|
|
|
|
|
%pre server
|
|
|
|
|
getent group stap-server >/dev/null || groupadd -f -g 155 -r stap-server
|
|
|
|
|
getent group stap-server >/dev/null || groupadd -g 155 -r stap-server 2>/dev/null || groupadd -r stap-server
|
|
|
|
|
getent passwd stap-server >/dev/null || \
|
|
|
|
|
useradd -c "Systemtap Compile Server" -u 155 -g stap-server -d %{_localstatedir}/lib/stap-server -r -s /sbin/nologin stap-server 2>/dev/null || \
|
|
|
|
|
useradd -c "Systemtap Compile Server" -g stap-server -d %{_localstatedir}/lib/stap-server -r -s /sbin/nologin stap-server
|
|
|
|
|
|
|
|
|
|
%pre testsuite
|
|
|
|
|
getent passwd stapusr >/dev/null || \
|
|
|
|
|
useradd -c "Systemtap 'stapusr' User" -g stapusr -r -s /sbin/nologin stapusr
|
|
|
|
|
getent passwd stapsys >/dev/null || \
|
|
|
|
|
useradd -c "Systemtap 'stapsys' User" -g stapsys -G stapusr -r -s /sbin/nologin stapsys
|
|
|
|
|
getent passwd stapdev >/dev/null || \
|
|
|
|
|
useradd -c "Systemtap 'stapdev' User" -g stapdev -G stapusr -r -s /sbin/nologin stapdev
|
|
|
|
|
exit 0
|
|
|
|
|
|
|
|
|
|
%post server
|
|
|
|
|
|
|
|
|
|
# We have some duplication between the %files listings for the
|
|
|
|
@ -915,24 +874,6 @@ if [ "$1" -ge "1" ]; then
|
|
|
|
|
fi
|
|
|
|
|
exit 0
|
|
|
|
|
|
|
|
|
|
%if %{with_python3}
|
|
|
|
|
%if %{with_systemd}
|
|
|
|
|
%preun exporter
|
|
|
|
|
if [ $1 = 0 ] ; then
|
|
|
|
|
/bin/systemctl stop stap-exporter.service >/dev/null 2>&1 || :
|
|
|
|
|
/bin/systemctl disable stap-exporter.service >/dev/null 2>&1 || :
|
|
|
|
|
fi
|
|
|
|
|
exit 0
|
|
|
|
|
|
|
|
|
|
%postun exporter
|
|
|
|
|
# Restart service if this is an upgrade rather than an uninstall
|
|
|
|
|
if [ "$1" -ge "1" ]; then
|
|
|
|
|
/bin/systemctl condrestart stap-exporter >/dev/null 2>&1 || :
|
|
|
|
|
fi
|
|
|
|
|
exit 0
|
|
|
|
|
%endif
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%post
|
|
|
|
|
# Remove any previously-built uprobes.ko materials
|
|
|
|
|
(make -C %{_datadir}/systemtap/runtime/uprobes clean) >/dev/null 2>&1 || true
|
|
|
|
@ -997,10 +938,11 @@ done
|
|
|
|
|
|
|
|
|
|
# ------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
%files
|
|
|
|
|
%files -f systemtap.lang
|
|
|
|
|
# The master "systemtap" rpm doesn't include any files.
|
|
|
|
|
|
|
|
|
|
%files server -f systemtap.lang
|
|
|
|
|
%defattr(-,root,root)
|
|
|
|
|
%{_bindir}/stap-server
|
|
|
|
|
%dir %{_libexecdir}/systemtap
|
|
|
|
|
%{_libexecdir}/systemtap/stap-serverd
|
|
|
|
@ -1054,6 +996,10 @@ done
|
|
|
|
|
%dir %{_libexecdir}/systemtap
|
|
|
|
|
%{_libexecdir}/systemtap/libHelperSDT_*.so
|
|
|
|
|
%endif
|
|
|
|
|
%if %{with_bundled_elfutils}
|
|
|
|
|
%dir %{_libdir}/systemtap
|
|
|
|
|
%{_libdir}/systemtap/lib*.so*
|
|
|
|
|
%endif
|
|
|
|
|
%if %{with_emacsvim}
|
|
|
|
|
%{_emacs_sitelispdir}/*.el*
|
|
|
|
|
%{_emacs_sitestartdir}/systemtap-init.el
|
|
|
|
@ -1069,6 +1015,7 @@ done
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files runtime -f systemtap.lang
|
|
|
|
|
%defattr(-,root,root)
|
|
|
|
|
%attr(4110,root,stapusr) %{_bindir}/staprun
|
|
|
|
|
%{_bindir}/stapsh
|
|
|
|
|
%{_bindir}/stap-merge
|
|
|
|
@ -1104,12 +1051,13 @@ done
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files client -f systemtap.lang
|
|
|
|
|
%defattr(-,root,root)
|
|
|
|
|
%doc README README.unprivileged AUTHORS NEWS
|
|
|
|
|
%{_datadir}/systemtap/examples
|
|
|
|
|
%{!?_licensedir:%global license %%doc}
|
|
|
|
|
%license COPYING
|
|
|
|
|
%doc docs.installed/*.pdf
|
|
|
|
|
%if %{with_docs}
|
|
|
|
|
%doc docs.installed/*.pdf
|
|
|
|
|
%if %{with_htmldocs}
|
|
|
|
|
%doc docs.installed/tapsets/*.html
|
|
|
|
|
%doc docs.installed/SystemTap_Beginners_Guide
|
|
|
|
@ -1133,20 +1081,15 @@ done
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files initscript
|
|
|
|
|
%if %{with_systemd}
|
|
|
|
|
%{_unitdir}/systemtap.service
|
|
|
|
|
%{_sbindir}/systemtap-service
|
|
|
|
|
%else
|
|
|
|
|
%defattr(-,root,root)
|
|
|
|
|
%{initdir}/systemtap
|
|
|
|
|
%{_sbindir}/systemtap-service
|
|
|
|
|
%endif
|
|
|
|
|
%dir %{_sysconfdir}/systemtap
|
|
|
|
|
%dir %{_sysconfdir}/systemtap/conf.d
|
|
|
|
|
%dir %{_sysconfdir}/systemtap/script.d
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/systemtap/config
|
|
|
|
|
%dir %{_localstatedir}/cache/systemtap
|
|
|
|
|
%ghost %{_localstatedir}/run/systemtap
|
|
|
|
|
%{_mandir}/man8/systemtap-service.8*
|
|
|
|
|
%{_mandir}/man8/systemtap.8*
|
|
|
|
|
%if %{with_dracut}
|
|
|
|
|
%dir %{dracutstap}
|
|
|
|
|
%{dracutstap}/*
|
|
|
|
@ -1154,17 +1097,18 @@ done
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files sdt-devel
|
|
|
|
|
%defattr(-,root,root)
|
|
|
|
|
%{_bindir}/dtrace
|
|
|
|
|
%{_includedir}/sys/sdt.h
|
|
|
|
|
%{_includedir}/sys/sdt-config.h
|
|
|
|
|
%{_mandir}/man1/dtrace.1*
|
|
|
|
|
%{_rpmmacrodir}/macros.systemtap
|
|
|
|
|
%doc README AUTHORS NEWS
|
|
|
|
|
%{!?_licensedir:%global license %%doc}
|
|
|
|
|
%license COPYING
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files testsuite
|
|
|
|
|
%defattr(-,root,root)
|
|
|
|
|
%dir %{_datadir}/systemtap
|
|
|
|
|
%{_datadir}/systemtap/testsuite
|
|
|
|
|
|
|
|
|
@ -1208,15 +1152,6 @@ done
|
|
|
|
|
%endif
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with_python3}
|
|
|
|
|
%files exporter
|
|
|
|
|
%{_sysconfdir}/stap-exporter
|
|
|
|
|
%{_sysconfdir}/sysconfig/stap-exporter
|
|
|
|
|
%{_unitdir}/stap-exporter.service
|
|
|
|
|
%{_mandir}/man8/stap-exporter.8*
|
|
|
|
|
%{_sbindir}/stap-exporter
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
# ------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
# Future new-release entries should be of the form
|
|
|
|
@ -1226,35 +1161,8 @@ done
|
|
|
|
|
|
|
|
|
|
# PRERELEASE
|
|
|
|
|
%changelog
|
|
|
|
|
* Tue Apr 21 2020 Björn Esser <besser82@fedoraproject.org> - 4.3-0.20200212git91ffb97ad335
|
|
|
|
|
- Rebuild (json-c)
|
|
|
|
|
|
|
|
|
|
* Tue Feb 11 2020 Frank Ch. Eigler <fche@redhat.com> - 4.3-0.20200211git91ffb97ad335
|
|
|
|
|
- Automated weekly rawhide release
|
|
|
|
|
- Applied spec changes from upstream git
|
|
|
|
|
|
|
|
|
|
* Mon Feb 03 2020 Frank Ch. Eigler <fche@redhat.com> - 4.3-0.20200203git6c0b74f5910a
|
|
|
|
|
- Automated weekly rawhide release
|
|
|
|
|
- Applied spec changes from upstream git
|
|
|
|
|
|
|
|
|
|
* Fri Jan 31 2020 Fedora Release Engineering <releng@fedoraproject.org> - 4.3-0.20200113gitb1e6a6645bba
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Sun Jan 12 2020 Frank Ch. Eigler <fche@redhat.com> - 4.3-0.20200112gitb1e6a6645bba
|
|
|
|
|
- Automated weekly rawhide release
|
|
|
|
|
- Applied spec changes from upstream git
|
|
|
|
|
|
|
|
|
|
* Mon Nov 18 2019 Sagar Patel <sapatel@redhat.com> - 4.2-1
|
|
|
|
|
- Upstream release.
|
|
|
|
|
|
|
|
|
|
* Tue May 07 2019 Serguei Makarov <smakarov@redhat.com> - 4.1-1
|
|
|
|
|
- Upstream release.
|
|
|
|
|
|
|
|
|
|
* Sat Oct 13 2018 Frank Ch. Eigler <fche@redhat.com> - 4.0-1
|
|
|
|
|
- Upstream release.
|
|
|
|
|
|
|
|
|
|
* Thu Jun 07 2018 Frank Ch. Eigler <fche@redhat.com> - 3.3-1
|
|
|
|
|
- Upstream release.
|
|
|
|
|
* Fri Oct 20 2017 Frank Ch. Eigler <fche@redhat.com> - 3.2-2
|
|
|
|
|
- rhbz1504009 (dtrace -G -o /dev/null)
|
|
|
|
|
|
|
|
|
|
* Wed Oct 18 2017 Frank Ch. Eigler <fche@redhat.com> - 3.2-1
|
|
|
|
|
- Upstream release.
|
|
|
|
@ -1278,7 +1186,7 @@ done
|
|
|
|
|
- Upstream release.
|
|
|
|
|
|
|
|
|
|
* Mon Jul 07 2014 Josh Stone <jistone@redhat.com>
|
|
|
|
|
- Flip with_dyninst to an %%ifarch whitelist.
|
|
|
|
|
- Flip with_dyninst to an %ifarch whitelist.
|
|
|
|
|
|
|
|
|
|
* Wed Apr 30 2014 Jonathan Lebon <jlebon@redhat.com> - 2.5-1
|
|
|
|
|
- Upstream release.
|
|
|
|
|