3 %bcond_without doc # documentation build
4 %bcond_with publican # publican guides build (requires functional publican+wkhtmltopdf)
5 %bcond_without crash # crash extension
6 %bcond_without dyninst # dyninst support
7 %bcond_without java # Java runtime support
9 %ifnarch %{ix86} %{x8664} alpha arm ia64 ppc64 s390 s390x
12 %ifnarch %{ix86} %{x8664} ppc ppc64
13 %undefine with_dyninst
15 Summary: Instrumentation System
16 Summary(pl.UTF-8): System oprzyrządowania
22 Source0: http://sourceware.org/systemtap/ftp/releases/%{name}-%{version}.tar.gz
23 # Source0-md5: 2f3c183966c82ec9d70c1de286b545fc
24 Source1: %{name}.tmpfiles
25 Source2: stap-server.tmpfiles
26 Patch0: %{name}-configure.patch
27 Patch1: %{name}-build.patch
28 Patch2: %{name}-rpm5-support.patch
29 Patch4: format-security.patch
30 URL: http://sourceware.org/systemtap/
31 BuildRequires: autoconf >= 2.63
32 BuildRequires: automake
33 BuildRequires: avahi-devel
34 BuildRequires: boost-devel
35 %{?with_crash:BuildRequires: crash-devel}
36 BuildRequires: docbook-dtd412-xml
37 %{?with_dyninst:BuildRequires: dyninst-devel >= 8.0}
38 BuildRequires: elfutils-devel >= 0.148
39 BuildRequires: gettext-devel >= 0.19.4
40 BuildRequires: gettext-tools >= 0.19.4
41 BuildRequires: glib2-devel
44 BuildRequires: rpm-javaprov
46 %if %{with dyninst} || %{with java}
47 BuildRequires: libselinux-devel
49 BuildRequires: libstdc++-devel
50 BuildRequires: libvirt-devel >= 1.0.2
51 BuildRequires: libxml2-devel >= 2.0
52 BuildRequires: mysql-devel
53 BuildRequires: nss-devel >= 3
54 BuildRequires: pkgconfig
55 BuildRequires: rpm-devel
56 BuildRequires: rpm-pythonprov
57 BuildRequires: sqlite3-devel >= 3
60 BuildRequires: latex2html
61 %{?with_publican:BuildRequires: publican}
62 BuildRequires: texlive-dvips
63 BuildRequires: texlive-fonts-bitstream
64 BuildRequires: texlive-fonts-type1-bitstream
65 BuildRequires: texlive-latex
66 BuildRequires: texlive-latex-psnfss
67 BuildRequires: texlive-xetex
69 # let base mean client+local development package
70 Requires: %{name}-client = %{version}-%{release}
71 Requires: %{name}-devel = %{version}-%{release}
72 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
75 SystemTap is an instrumentation system for systems running Linux 2.6.
76 Developers can write instrumentation to collect data on the operation
77 of the system. The base systemtap package provides the components
78 needed to locally develop and execute systemtap script.
80 %description -l pl.UTF-8
81 SystemTap to system oprzyrządowania dla systemów opartych na Linuksie
82 2.6. Programiści mogą pisać narzędzia do zbierania danych dotyczących
83 operacji w systemie. Główny pakiet dostarcza komponenty niezbędne do
84 lokalnego tworzenia i wykonywania skryptów systemtap.
87 Summary: Programmable system-wide instrumentation system - runtime
88 Summary(pl.UTF-8): Programowalny systemowy system oprzyrządowania - środowisko uruchomieniowe
89 Group: Applications/System
92 SystemTap runtime contains the components needed to execute a
93 systemtap script that was already compiled into a module using a local
94 or remote systemtap-devel installation.
96 %description runtime -l pl.UTF-8
97 Środowisko uruchomieniowe SystemTap zawiera komponenty niezbędne do
98 uruchomienia skryptu systemtap, który został już wkompilowany do
99 modułu przy użyciu lokalnej lub zdalnej instalacji systemtap-devel.
101 %package runtime-java
102 Summary: SystemTap Java runtime support
103 Summary(pl.UTF-8): Obsługa Javy dla środowiska uruchomieniowego SystemTap
105 Requires: %{name}-runtime = %{version}-%{release}
106 Requires: byteman > 2.0
108 %description runtime-java
109 This package includes support files needed to run systemtap scripts
110 that probe Java processes running on the OpenJDK 1.6 and OpenJDK 1.7
111 runtimes using Byteman.
113 %description runtime-java -l pl.UTF-8
114 Ten pakiet zawiera pliki niezbędne do uruchamiania skryptów systemtap
115 sondujące procesy Javy działające w środowiskach OpenJDK 1.6 i OpenJDK
116 1.7 przy użyciu Bytemana.
119 Summary: Programmable system-wide instrumentation system - client
120 Summary(pl.UTF-8): Programowalny systemowy system oprzyrządowania - klient
121 Group: Applications/System
122 Requires: %{name}-runtime = %{version}-%{release}
125 Requires: libvirt >= 1.0.2
126 Requires: openssh-clients
132 This package provides the components needed to develop systemtap
133 scripts and compile them using a local systemtap-devel or a remote
134 systemtap-server installation, then run them using a local or remote
135 systemtap-runtime. It includes script samples and documentation, and a
136 copy of the tapset library for reference.
138 %description client -l pl.UTF-8
139 Ten pakiet dostarcza komponenty niezbędne do tworzenia skryptów
140 systemtap i kompilowania ich przy użyciu lokalnej instalacji
141 systemtap-devel lub zdalnej instalacji systemtap-server, a następnie
142 uruchamiania ich przy użyciu lokalnej lub zdalnej instalacji
143 systemtap-runtime. Zawiera przykłady skryptów oraz dokumentację, a
144 także kopię biblioteki tapset.
147 Summary: Programmable system-wide instrumentation system - development headers, tools
148 Summary(pl.UTF-8): Programowalny systemowy system oprzyrządowania - pliki nagłówkowe, narzędzia
149 Group: Development/Tools
150 Requires: %{name}-client = %{version}-%{release}
152 Requires: kernel-module-build
156 This package provides the components needed to compile a systemtap
157 script from source form into executable (.ko) forms. It may be
158 installed on a self-contained developer workstation (along with the
159 systemtap-client and systemtap-runtime packages), or on a dedicated
160 remote server (alongside the systemtap-server package). It includes a
161 copy of the standard tapset library and the runtime library C files.
163 %description devel -l pl.UTF-8
164 Ten pakiet dostarcza komponenty niezbędne do kompilowania skryptów
165 systemtap z postaci źródłowej do wykonywalnej (.ko). Może być
166 zainstalowany na samodzielnej stacji roboczej programisty (wraz z
167 pakietami systemtap-client i systemtap-runtime) lub dedykowanym
168 zdalnym serwerze (wraz z pakietem systemtap-server). Zawiera kopię
169 standardowej biblioteki tapset oraz pliki biblioteki uruchomieniowej
173 Summary: SystemTap Initscripts
174 Summary(pl.UTF-8): Skrypty startowe SystemTap
176 Requires(post,preun): /sbin/chkconfig
177 Requires: %{name} = %{version}-%{release}
180 %description initscript
181 SysVinit scripts to launch selected systemtap scripts at system
184 %description initscript -l pl.UTF-8
185 Skrypty SysVinit do uruchamiania wybranych skryptów systemtap w
186 trakcie startu systemu.
189 Summary: Instrumentation System Server
190 Summary(pl.UTF-8): Serwer systemu oprzyrządowania
191 Group: Applications/System
192 Requires(post,preun): /sbin/chkconfig
193 Requires: %{name}-devel = %{version}-%{release}
194 Requires: /bin/mktemp
199 This is the remote script compilation server component of systemtap.
200 It announces itself to nearby clients with avahi (if available), and
201 compiles systemtap scripts to kernel objects on their demand.
203 %description server -l pl.UTF-8
204 Ten pakiet zawiera komponent serwera do zdalnej kompilacji skryptów
205 systemtap. Rozgłasza się pobliskim klientom przy użyciu avahi (jeśli
206 jest dostępny) i na żądanie kompiluje skrypty systemtap do obiektów
210 Summary: Static probe support tools
211 Summary(pl.UTF-8): Narzędzia do obsługi sond statycznych
212 License: GPL v2+ and Public Domain
213 Group: Development/Libraries
215 %description sdt-devel
216 This package includes the <sys/sdt.h> header file used for static
217 instrumentation compiled into userspace programs and libraries, along
218 with the optional dtrace-compatibility preprocessor to process related
219 .d files into tracing-macro-laden .h headers.
221 %description sdt-devel -l pl.UTF-8
222 Ten pakiet zawiera plik nagłówkowy <sys/sdt.h> służący do
223 wkompilowywania statycznego oprzyrządowania do programów i bibliotek
224 przestrzeni użytkownika, wraz z opcjonalnym preprocesorem zgodności z
225 dtrace, który przetwarza pliki .d na pliki nagłówkowe .h z makrami
229 Summary: SystemTap guides and tutorials
230 Summary(pl.UTF-8): Przewodniki i dokumentacja wprowadzająca do SystemTap
234 SystemTap guides and tutorials.
236 %description doc -l pl.UTF-8
237 Przewodniki i dokumentacja wprowadzająca do SystemTap.
244 %if "%{_rpmversion}" >= "5.0"
255 --disable-silent-rules \
256 %{?with_crash:--enable-crash} \
257 --enable-docs%{!?with_doc:=no} \
259 --enable-publican%{!?with_publican:=no} \
262 --with-dyninst%{!?with_dyninst:=no} \
263 --with-java=%{?with_java:%{_jvmdir}/java}%{!?with_java:no}
267 rm -rf $RPM_BUILD_ROOT
268 install -d $RPM_BUILD_ROOT{/var/{cache,run}/%{name},%{systemdtmpfilesdir},%{systemdunitdir}} \
269 $RPM_BUILD_ROOT{%{_sysconfdir}/stap-server/conf.d,/etc/{sysconfig,logrotate.d,rc.d/init.d}} \
270 $RPM_BUILD_ROOT/var/log/stap-server
273 DESTDIR=$RPM_BUILD_ROOT
275 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/systemtap.conf
276 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/stap-server.conf
278 # not installed by make
279 install -p stap-prep $RPM_BUILD_ROOT%{_bindir}/stap-prep
281 install -p initscript/systemtap $RPM_BUILD_ROOT/etc/rc.d/init.d
282 cp -p initscript/config.systemtap $RPM_BUILD_ROOT%{_sysconfdir}/systemtap/config
284 install -p initscript/stap-server $RPM_BUILD_ROOT/etc/rc.d/init.d
285 cp -p initscript/config.stap-server $RPM_BUILD_ROOT/etc/sysconfig/stap-server
286 cp -p initscript/logrotate.stap-server $RPM_BUILD_ROOT/etc/logrotate.d/stap-server
287 cp -p stap-server.service $RPM_BUILD_ROOT%{systemdunitdir}
289 install -d $RPM_BUILD_ROOT%{_sysconfdir}/systemtap/{conf.d,script.d}
290 install -d $RPM_BUILD_ROOT/var/lib/stap-server/.systemtap
291 install -d $RPM_BUILD_ROOT/var/log/stap-server
294 install -d $RPM_BUILD_ROOT%{_examplesdir}
295 mv $RPM_BUILD_ROOT{%{_docdir}/%{name}/examples,%{_examplesdir}/%{name}-client-%{version}}
298 %{__mv} $RPM_BUILD_ROOT%{_docdir}/systemtap docs-installed
303 rm -rf $RPM_BUILD_ROOT
306 %defattr(644,root,root,755)
308 %files runtime -f %{name}.lang
309 %defattr(644,root,root,755)
310 %doc AUTHORS NEWS README*
311 %attr(755,root,root) %{_bindir}/stap-merge
312 %attr(755,root,root) %{_bindir}/stap-report
313 %{?with_dyninst:%attr(755,root,root) %{_bindir}/stapdyn}
314 %attr(755,root,root) %{_bindir}/stapsh
315 # XXX: %attr(4754,root,stapusr) staprun ?
316 %attr(755,root,root) %{_bindir}/staprun
317 %dir %{_libdir}/%{name}
318 %attr(755,root,root) %{_libdir}/%{name}/stap-authorize-cert
319 %attr(755,root,root) %{_libdir}/%{name}/stapio
320 %{?with_crash:%attr(755,root,root) %{_libdir}/%{name}/staplog.so}
321 %{_mandir}/man1/stap-merge.1*
322 %{_mandir}/man1/stap-report.1*
323 %{_mandir}/man1/stapref.1*
324 %{_mandir}/man3/stapex.3stap*
325 %{_mandir}/man3/stapfuncs.3stap*
326 %{_mandir}/man3/stapprobes.3stap*
327 %{_mandir}/man3/stapvars.3stap*
329 %{_mandir}/man3/function::*.3stap*
330 %{_mandir}/man3/macro::*.3stap*
331 %{_mandir}/man3/probe::*.3stap*
332 %{_mandir}/man3/tapset::*.3stap*
334 %{_mandir}/man7/error::*.7stap*
335 %{_mandir}/man7/stappaths.7*
336 %{_mandir}/man7/warning::debuginfo.7stap*
337 %{_mandir}/man7/warning::symbols.7stap*
338 %{?with_dyninst:%{_mandir}/man8/stapdyn.8*}
339 %{_mandir}/man8/staprun.8*
340 %{_mandir}/man8/stapsh.8*
341 %{_mandir}/man8/systemtap.8*
345 %defattr(644,root,root,755)
346 %attr(755,root,root) %{_libdir}/%{name}/stapbm
347 %attr(755,root,root) %{_libdir}/%{name}/libHelperSDT_*.so
348 %{_libdir}/%{name}/HelperSDT.jar
352 %defattr(644,root,root,755)
354 %doc docs-installed/{tapsets,langref.pdf,tutorial.pdf}
355 %{_examplesdir}/%{name}-client-%{version}
357 %attr(755,root,root) %{_bindir}/stap
358 %attr(755,root,root) %{_bindir}/stap-prep
359 %attr(755,root,root) %{_bindir}/stapvirt
360 %dir %{_datadir}/%{name}
361 %{_datadir}/%{name}/tapset
362 %{_mandir}/man1/stap.1*
363 %{_mandir}/man1/stap-prep.1*
364 %{_mandir}/man1/stapvirt.1*
367 %defattr(644,root,root,755)
368 %{_datadir}/%{name}/runtime
371 %defattr(644,root,root,755)
372 %attr(754,root,root) /etc/rc.d/init.d/systemtap
373 %dir %{_sysconfdir}/systemtap
374 %dir %{_sysconfdir}/systemtap/conf.d
375 %dir %{_sysconfdir}/systemtap/script.d
376 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/systemtap/config
377 %{systemdtmpfilesdir}/systemtap.conf
378 %dir /var/cache/%{name}
379 %dir /var/run/%{name}
382 %defattr(644,root,root,755)
383 %attr(755,root,root) %{_bindir}/stap-server
384 %attr(755,root,root) %{_libdir}/%{name}/stap-env
385 %attr(755,root,root) %{_libdir}/%{name}/stap-gen-cert
386 %attr(755,root,root) %{_libdir}/%{name}/stap-serverd
387 %attr(755,root,root) %{_libdir}/%{name}/stap-sign-module
388 %attr(755,root,root) %{_libdir}/%{name}/stap-start-server
389 %attr(755,root,root) %{_libdir}/%{name}/stap-stop-server
390 %dir %{_sysconfdir}/stap-server
391 %dir %{_sysconfdir}/stap-server/conf.d
392 %attr(754,root,root) /etc/rc.d/init.d/stap-server
393 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/stap-server
394 %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/stap-server
395 %{systemdunitdir}/stap-server.service
396 %{systemdtmpfilesdir}/stap-server.conf
397 # TODO: create user/group
398 #%attr(750,stap-server,stap-server) %dir /var/lib/stap-server
399 #%attr(700,stap-server,stap-server) %dir /var/lib/stap-server/.systemtap
400 #%attr(755,stap-server,stap-server) %dir /var/log/stap-server
401 #%attr(755,stap-server,stap-server) %dir /var/run/stap-server
402 %{_mandir}/man8/stap-server.8*
405 %defattr(644,root,root,755)
406 %attr(755,root,root) %{_bindir}/dtrace
407 %{_includedir}/sys/sdt.h
408 %{_includedir}/sys/sdt-config.h
409 %{_mandir}/man1/dtrace.1*
413 %defattr(644,root,root,755)
414 %doc doc/{langref,tutorial}.pdf doc/beginners/SystemTap_Beginners_Guide.pdf