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: a33c6f2ac5d6b77d8d02246685ee5105
24 Source1: systemtap.tmpfiles
25 Source2: stap-server.tmpfiles
26 Patch0: %{name}-configure.patch
27 Patch1: %{name}-build.patch
28 Patch2: %{name}-rpm5-support.patch
29 URL: http://sourceware.org/systemtap/
30 BuildRequires: autoconf >= 2.63
31 BuildRequires: automake
32 BuildRequires: avahi-devel
33 BuildRequires: boost-devel
34 %{?with_crash:BuildRequires: crash-devel}
35 BuildRequires: docbook-dtd412-xml
36 %{?with_dyninst:BuildRequires: dyninst-devel >= 8.0}
37 BuildRequires: elfutils-devel >= 0.148
38 BuildRequires: gettext-devel >= 0.18.2
39 BuildRequires: glib2-devel
40 %{?with_java:BuildRequires: jdk}
41 %if %{with dyninst} || %{with java}
42 BuildRequires: libselinux-devel
44 BuildRequires: libstdc++-devel
45 BuildRequires: libvirt-devel >= 1.0.2
46 BuildRequires: libxml2-devel >= 2.0
47 BuildRequires: mysql-devel
48 BuildRequires: nss-devel >= 3
49 BuildRequires: rpm-devel
50 BuildRequires: sqlite3-devel >= 3
53 BuildRequires: latex2html
54 %{?with_publican:BuildRequires: publican}
55 BuildRequires: texlive-dvips
56 BuildRequires: texlive-fonts-bitstream
57 BuildRequires: texlive-fonts-type1-bitstream
58 BuildRequires: texlive-latex
60 # let base mean client+local development package
61 Requires: %{name}-client = %{version}-%{release}
62 Requires: %{name}-devel = %{version}-%{release}
63 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
66 SystemTap is an instrumentation system for systems running Linux 2.6.
67 Developers can write instrumentation to collect data on the operation
68 of the system. The base systemtap package provides the components
69 needed to locally develop and execute systemtap script.
71 %description -l pl.UTF-8
72 SystemTap to system oprzyrządowania dla systemów opartych na Linuksie
73 2.6. Programiści mogą pisać narzędzia do zbierania danych dotyczących
74 operacji w systemie. Główny pakiet dostarcza komponenty niezbędne do
75 lokalnego tworzenia i wykonywania skryptów systemtap.
78 Summary: Programmable system-wide instrumentation system - runtime
79 Summary(pl.UTF-8): Programowalny systemowy system oprzyrządowania - środowisko uruchomieniowe
80 Group: Applications/System
83 SystemTap runtime contains the components needed to execute a
84 systemtap script that was already compiled into a module using a local
85 or remote systemtap-devel installation.
87 %description runtime -l pl.UTF-8
88 Środowisko uruchomieniowe SystemTap zawiera komponenty niezbędne do
89 uruchomienia skryptu systemtap, który został już wkompilowany do
90 modułu przy użyciu lokalnej lub zdalnej instalacji systemtap-devel.
93 Summary: SystemTap Java runtime support
94 Summary(pl.UTF-8): Obsługa Javy dla środowiska uruchomieniowego SystemTap
96 Requires: %{name}-runtime = %{version}-%{release}
97 Requires: byteman > 2.0
99 %description runtime-java
100 This package includes support files needed to run systemtap scripts
101 that probe Java processes running on the OpenJDK 1.6 and OpenJDK 1.7
102 runtimes using Byteman.
104 %description runtime-java -l pl.UTF-8
105 Ten pakiet zawiera pliki niezbędne do uruchamiania skryptów systemtap
106 sondujące procesy Javy działające w środowiskach OpenJDK 1.6 i OpenJDK
107 1.7 przy użyciu Bytemana.
110 Summary: Programmable system-wide instrumentation system - client
111 Summary(pl.UTF-8): Programowalny systemowy system oprzyrządowania - klient
112 Group: Applications/System
113 Requires: %{name}-runtime = %{version}-%{release}
116 Requires: libvirt >= 1.0.2
117 Requires: openssh-clients
123 This package provides the components needed to develop systemtap
124 scripts and compile them using a local systemtap-devel or a remote
125 systemtap-server installation, then run them using a local or remote
126 systemtap-runtime. It includes script samples and documentation, and a
127 copy of the tapset library for reference.
129 %description client -l pl.UTF-8
130 Ten pakiet dostarcza komponenty niezbędne do tworzenia skryptów
131 systemtap i kompilowania ich przy użyciu lokalnej instalacji
132 systemtap-devel lub zdalnej instalacji systemtap-server, a następnie
133 uruchamiania ich przy użyciu lokalnej lub zdalnej instalacji
134 systemtap-runtime. Zawiera przykłady skryptów oraz dokumentację, a
135 także kopię biblioteki tapset.
138 Summary: Programmable system-wide instrumentation system - development headers, tools
139 Summary(pl.UTF-8): Programowalny systemowy system oprzyrządowania - pliki nagłówkowe, narzędzia
140 Group: Development/Tools
141 Requires: %{name}-client = %{version}-%{release}
143 Requires: kernel-module-build
147 This package provides the components needed to compile a systemtap
148 script from source form into executable (.ko) forms. It may be
149 installed on a self-contained developer workstation (along with the
150 systemtap-client and systemtap-runtime packages), or on a dedicated
151 remote server (alongside the systemtap-server package). It includes a
152 copy of the standard tapset library and the runtime library C files.
154 %description devel -l pl.UTF-8
155 Ten pakiet dostarcza komponenty niezbędne do kompilowania skryptów
156 systemtap z postaci źródłowej do wykonywalnej (.ko). Może być
157 zainstalowany na samodzielnej stacji roboczej programisty (wraz z
158 pakietami systemtap-client i systemtap-runtime) lub dedykowanym
159 zdalnym serwerze (wraz z pakietem systemtap-server). Zawiera kopię
160 standardowej biblioteki tapset oraz pliki biblioteki uruchomieniowej
164 Summary: SystemTap Initscripts
165 Summary(pl.UTF-8): Skrypty startowe SystemTap
167 Requires(post,preun): /sbin/chkconfig
168 Requires: %{name} = %{version}-%{release}
171 %description initscript
172 SysVinit scripts to launch selected systemtap scripts at system
175 %description initscript -l pl.UTF-8
176 Skrypty SysVinit do uruchamiania wybranych skryptów systemtap w
177 trakcie startu systemu.
180 Summary: Instrumentation System Server
181 Summary(pl.UTF-8): Serwer systemu oprzyrządowania
182 Group: Applications/System
183 Requires(post,preun): /sbin/chkconfig
184 Requires: %{name}-devel = %{version}-%{release}
185 Requires: /bin/mktemp
190 This is the remote script compilation server component of systemtap.
191 It announces itself to nearby clients with avahi (if available), and
192 compiles systemtap scripts to kernel objects on their demand.
194 %description server -l pl.UTF-8
195 Ten pakiet zawiera komponent serwera do zdalnej kompilacji skryptów
196 systemtap. Rozgłasza się pobliskim klientom przy użyciu avahi (jeśli
197 jest dostępny) i na żądanie kompiluje skrypty systemtap do obiektów
201 Summary: Static probe support tools
202 Summary(pl.UTF-8): Narzędzia do obsługi sond statycznych
203 License: GPL v2+ and Public Domain
204 Group: Development/Libraries
206 %description sdt-devel
207 This package includes the <sys/sdt.h> header file used for static
208 instrumentation compiled into userspace programs and libraries, along
209 with the optional dtrace-compatibility preprocessor to process related
210 .d files into tracing-macro-laden .h headers.
212 %description sdt-devel -l pl.UTF-8
213 Ten pakiet zawiera plik nagłówkowy <sys/sdt.h> służący do
214 wkompilowywania statycznego oprzyrządowania do programów i bibliotek
215 przestrzeni użytkownika, wraz z opcjonalnym preprocesorem zgodności z
216 dtrace, który przetwarza pliki .d na pliki nagłówkowe .h z makrami
223 %if "%{_rpmversion}" >= "5.0"
234 --disable-silent-rules \
235 %{?with_crash:--enable-crash} \
236 --enable-docs%{!?with_doc:=no} \
238 --enable-publican%{!?with_publican:=no} \
241 --with-dyninst%{!?with_dyninst:=no} \
242 --with-java=%{?with_java:%{_jvmdir}/java}%{!?with_java:no}
246 rm -rf $RPM_BUILD_ROOT
247 install -d $RPM_BUILD_ROOT{/var/{cache,run}/%{name},%{systemdtmpfilesdir},%{systemdunitdir}} \
248 $RPM_BUILD_ROOT{%{_sysconfdir}/stap-server/conf.d,/etc/{sysconfig,logrotate.d,rc.d/init.d}} \
249 $RPM_BUILD_ROOT/var/log/stap-server
252 DESTDIR=$RPM_BUILD_ROOT
254 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/systemtap.conf
255 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/stap-server.conf
257 # not installed by make
258 install stap-prep $RPM_BUILD_ROOT%{_bindir}/stap-prep
260 install initscript/systemtap $RPM_BUILD_ROOT/etc/rc.d/init.d
261 install initscript/config.systemtap $RPM_BUILD_ROOT%{_sysconfdir}/systemtap/config
263 install initscript/stap-server $RPM_BUILD_ROOT/etc/rc.d/init.d
264 install initscript/config.stap-server $RPM_BUILD_ROOT/etc/sysconfig/stap-server
265 install initscript/logrotate.stap-server $RPM_BUILD_ROOT/etc/logrotate.d/stap-server
266 install stap-server.service $RPM_BUILD_ROOT%{systemdunitdir}
268 install -d $RPM_BUILD_ROOT%{_sysconfdir}/systemtap/{conf.d,script.d}
269 install -d $RPM_BUILD_ROOT/var/lib/stap-server/.systemtap
270 install -d $RPM_BUILD_ROOT/var/log/stap-server
272 %{__mv} $RPM_BUILD_ROOT%{_docdir}/systemtap docs-installed
277 rm -rf $RPM_BUILD_ROOT
280 %defattr(644,root,root,755)
282 %files runtime -f %{name}.lang
283 %defattr(644,root,root,755)
284 %doc AUTHORS NEWS README*
285 %attr(755,root,root) %{_bindir}/stap-merge
286 %attr(755,root,root) %{_bindir}/stap-report
287 %{?with_dyninst:%attr(755,root,root) %{_bindir}/stapdyn}
288 %attr(755,root,root) %{_bindir}/stapsh
289 # XXX: %attr(4754,root,stapusr) staprun ?
290 %attr(755,root,root) %{_bindir}/staprun
291 %dir %{_libdir}/%{name}
292 %attr(755,root,root) %{_libdir}/%{name}/stap-authorize-cert
293 %attr(755,root,root) %{_libdir}/%{name}/stapio
294 %{?with_crash:%attr(755,root,root) %{_libdir}/%{name}/staplog.so}
295 %{_mandir}/man1/stap-merge.1*
296 %{_mandir}/man1/stap-report.1*
297 %{_mandir}/man3/function::*.3stap*
298 %{_mandir}/man3/probe::*.3stap*
299 %{_mandir}/man3/stapex.3stap*
300 %{_mandir}/man3/stapfuncs.3stap*
301 %{_mandir}/man3/stapprobes.3stap*
302 %{_mandir}/man3/stapvars.3stap*
303 %{_mandir}/man3/tapset::*.3stap*
304 %{_mandir}/man7/error::*.7stap*
305 %{_mandir}/man7/stappaths.7*
306 %{_mandir}/man7/warning::debuginfo.7stap*
307 %{?with_dyninst:%{_mandir}/man8/stapdyn.8*}
308 %{_mandir}/man8/staprun.8*
309 %{_mandir}/man8/stapsh.8*
310 %{_mandir}/man8/systemtap.8*
314 %defattr(644,root,root,755)
315 %attr(755,root,root) %{_libdir}/%{name}/stapbm
316 %attr(755,root,root) %{_libdir}/%{name}/libHelperSDT_*.so
317 %{_libdir}/%{name}/HelperSDT.jar
321 %defattr(644,root,root,755)
322 %doc docs-installed/examples %{?with_docs:docs-installed/{tapsets,langref.pdf,tutorial.pdf}}
323 %attr(755,root,root) %{_bindir}/stap
324 %attr(755,root,root) %{_bindir}/stap-prep
325 %attr(755,root,root) %{_bindir}/stapvirt
326 %dir %{_datadir}/%{name}
327 %{_datadir}/%{name}/tapset
328 %{_mandir}/man1/stap.1*
329 %{_mandir}/man1/stap-prep.1*
330 %{_mandir}/man1/stapvirt.1*
333 %defattr(644,root,root,755)
334 %{_datadir}/%{name}/runtime
337 %defattr(644,root,root,755)
338 %attr(754,root,root) /etc/rc.d/init.d/systemtap
339 %dir %{_sysconfdir}/systemtap
340 %dir %{_sysconfdir}/systemtap/conf.d
341 %dir %{_sysconfdir}/systemtap/script.d
342 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/systemtap/config
343 %{systemdtmpfilesdir}/systemtap.conf
344 %dir /var/cache/%{name}
345 %dir /var/run/%{name}
348 %defattr(644,root,root,755)
349 %attr(755,root,root) %{_bindir}/stap-server
350 %attr(755,root,root) %{_libdir}/%{name}/stap-env
351 %attr(755,root,root) %{_libdir}/%{name}/stap-gen-cert
352 %attr(755,root,root) %{_libdir}/%{name}/stap-serverd
353 %attr(755,root,root) %{_libdir}/%{name}/stap-sign-module
354 %attr(755,root,root) %{_libdir}/%{name}/stap-start-server
355 %attr(755,root,root) %{_libdir}/%{name}/stap-stop-server
356 %dir %{_sysconfdir}/stap-server
357 %dir %{_sysconfdir}/stap-server/conf.d
358 %attr(754,root,root) /etc/rc.d/init.d/stap-server
359 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/stap-server
360 %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/stap-server
361 %{systemdunitdir}/stap-server.service
362 %{systemdtmpfilesdir}/stap-server.conf
363 # TODO: create user/group
364 #%attr(750,stap-server,stap-server) %dir /var/lib/stap-server
365 #%attr(700,stap-server,stap-server) %dir /var/lib/stap-server/.systemtap
366 #%attr(755,stap-server,stap-server) %dir /var/log/stap-server
367 #%attr(755,stap-server,stap-server) %dir /var/run/stap-server
368 %{_mandir}/man8/stap-server.8*
371 %defattr(644,root,root,755)
372 %attr(755,root,root) %{_bindir}/dtrace
373 %{_includedir}/sys/sdt.h
374 %{_includedir}/sys/sdt-config.h
375 %{_mandir}/man1/dtrace.1*