]> git.pld-linux.org Git - packages/systemtap.git/blame - systemtap.spec
- compile C++ in C++11 mode (required by dyninst)
[packages/systemtap.git] / systemtap.spec
CommitLineData
87230ea0 1#
8bec3f09
JB
2# Conditional build:
3%bcond_without doc # documentation build
97c167ee 4%bcond_with publican # publican guides build [as of 3.0 not rebuilt automatically, PDFs are included]
1651fd5a 5%bcond_without crash # crash extension
c15371b4 6%bcond_without dyninst # dyninst support
8bec3f09 7%bcond_without java # Java runtime support
7a86387a 8
1651fd5a
JB
9%ifnarch %{ix86} %{x8664} alpha arm ia64 ppc64 s390 s390x
10%undefine with_crash
11%endif
923afaa0 12%ifnarch %{ix86} %{x8664} x32 ppc ppc64 aarch64
c15371b4
JB
13%undefine with_dyninst
14%endif
aa39e90e 15Summary: Instrumentation System
7ad1ccd0 16Summary(pl.UTF-8): System oprzyrządowania
aa39e90e 17Name: systemtap
97c167ee 18Version: 3.0
8e86ead7 19Release: 2
839ed024 20License: GPL v2+
aa39e90e 21Group: Base
e7f20467 22Source0: http://sourceware.org/systemtap/ftp/releases/%{name}-%{version}.tar.gz
97c167ee 23# Source0-md5: 0edc087e748769496ee244acf3b80168
7a86387a 24Source1: %{name}.tmpfiles
8bec3f09 25Source2: stap-server.tmpfiles
459a2a3b 26Patch0: %{name}-configure.patch
099db71a 27Patch1: %{name}-build.patch
6fbeb569 28Patch2: %{name}-rpm5-support.patch
97c167ee 29Patch3: %{name}-no-werror.patch
1a30c954 30Patch4: format-security.patch
ff9bc29b 31URL: http://sourceware.org/systemtap/
8bec3f09 32BuildRequires: autoconf >= 2.63
60a0430a 33BuildRequires: automake
099db71a 34BuildRequires: avahi-devel
8bec3f09 35BuildRequires: boost-devel
1651fd5a 36%{?with_crash:BuildRequires: crash-devel}
8bec3f09 37BuildRequires: docbook-dtd412-xml
c15371b4 38%{?with_dyninst:BuildRequires: dyninst-devel >= 8.0}
8bec3f09 39BuildRequires: elfutils-devel >= 0.148
e75a4152
JB
40BuildRequires: gettext-devel >= 0.19.4
41BuildRequires: gettext-tools >= 0.19.4
aa39e90e 42BuildRequires: glib2-devel
97c167ee
JB
43BuildRequires: json-c-devel
44%{?with_java:BuildRequires: jdk}
c15371b4
JB
45%if %{with dyninst} || %{with java}
46BuildRequires: libselinux-devel
47%endif
8e86ead7 48BuildRequires: libstdc++-devel >= 6:4.7
e7f20467
JB
49BuildRequires: libvirt-devel >= 1.0.2
50BuildRequires: libxml2-devel >= 2.0
aa39e90e 51BuildRequires: mysql-devel
97c167ee 52BuildRequires: ncurses-devel
8bec3f09 53BuildRequires: nss-devel >= 3
7af1a693 54BuildRequires: pkgconfig
97c167ee 55BuildRequires: readline-devel
bc044f75 56BuildRequires: rpm-devel
97c167ee 57%{?with_java:BuildRequires: rpm-javaprov}
fa83958d 58BuildRequires: rpm-pythonprov
8bec3f09
JB
59BuildRequires: sqlite3-devel >= 3
60BuildRequires: xmlto
61%if %{with doc}
62BuildRequires: latex2html
63%{?with_publican:BuildRequires: publican}
64BuildRequires: texlive-dvips
65BuildRequires: texlive-fonts-bitstream
66BuildRequires: texlive-fonts-type1-bitstream
099db71a 67BuildRequires: texlive-latex
7af1a693
ER
68BuildRequires: texlive-latex-psnfss
69BuildRequires: texlive-xetex
8bec3f09
JB
70%endif
71# let base mean client+local development package
72Requires: %{name}-client = %{version}-%{release}
73Requires: %{name}-devel = %{version}-%{release}
aa39e90e
AM
74BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
75
76%description
77SystemTap is an instrumentation system for systems running Linux 2.6.
78Developers can write instrumentation to collect data on the operation
8bec3f09
JB
79of the system. The base systemtap package provides the components
80needed to locally develop and execute systemtap script.
aa39e90e 81
3bf8b266
JR
82%description -l pl.UTF-8
83SystemTap to system oprzyrządowania dla systemów opartych na Linuksie
842.6. Programiści mogą pisać narzędzia do zbierania danych dotyczących
8bec3f09
JB
85operacji w systemie. Główny pakiet dostarcza komponenty niezbędne do
86lokalnego tworzenia i wykonywania skryptów systemtap.
099db71a
AM
87
88%package runtime
89Summary: Programmable system-wide instrumentation system - runtime
8bec3f09
JB
90Summary(pl.UTF-8): Programowalny systemowy system oprzyrządowania - środowisko uruchomieniowe
91Group: Applications/System
099db71a
AM
92
93%description runtime
94SystemTap runtime contains the components needed to execute a
95systemtap script that was already compiled into a module using a local
96or remote systemtap-devel installation.
97
8bec3f09
JB
98%description runtime -l pl.UTF-8
99Środowisko uruchomieniowe SystemTap zawiera komponenty niezbędne do
100uruchomienia skryptu systemtap, który został już wkompilowany do
101modułu przy użyciu lokalnej lub zdalnej instalacji systemtap-devel.
102
103%package runtime-java
104Summary: SystemTap Java runtime support
105Summary(pl.UTF-8): Obsługa Javy dla środowiska uruchomieniowego SystemTap
106Group: Libraries
107Requires: %{name}-runtime = %{version}-%{release}
8bec3f09
JB
108Requires: byteman > 2.0
109
110%description runtime-java
111This package includes support files needed to run systemtap scripts
112that probe Java processes running on the OpenJDK 1.6 and OpenJDK 1.7
113runtimes using Byteman.
114
115%description runtime-java -l pl.UTF-8
116Ten pakiet zawiera pliki niezbędne do uruchamiania skryptów systemtap
117sondujące procesy Javy działające w środowiskach OpenJDK 1.6 i OpenJDK
1181.7 przy użyciu Bytemana.
119
099db71a
AM
120%package client
121Summary: Programmable system-wide instrumentation system - client
8bec3f09
JB
122Summary(pl.UTF-8): Programowalny systemowy system oprzyrządowania - klient
123Group: Applications/System
124Requires: %{name}-runtime = %{version}-%{release}
099db71a
AM
125Requires: coreutils
126Requires: grep
e7f20467 127Requires: libvirt >= 1.0.2
099db71a
AM
128Requires: openssh-clients
129Requires: sed
099db71a
AM
130Requires: unzip
131Requires: zip
132
133%description client
8bec3f09
JB
134This package provides the components needed to develop systemtap
135scripts and compile them using a local systemtap-devel or a remote
136systemtap-server installation, then run them using a local or remote
137systemtap-runtime. It includes script samples and documentation, and a
138copy of the tapset library for reference.
099db71a 139
8bec3f09
JB
140%description client -l pl.UTF-8
141Ten pakiet dostarcza komponenty niezbędne do tworzenia skryptów
142systemtap i kompilowania ich przy użyciu lokalnej instalacji
143systemtap-devel lub zdalnej instalacji systemtap-server, a następnie
144uruchamiania ich przy użyciu lokalnej lub zdalnej instalacji
145systemtap-runtime. Zawiera przykłady skryptów oraz dokumentację, a
146także kopię biblioteki tapset.
147
148%package devel
149Summary: Programmable system-wide instrumentation system - development headers, tools
150Summary(pl.UTF-8): Programowalny systemowy system oprzyrządowania - pliki nagłówkowe, narzędzia
151Group: Development/Tools
152Requires: %{name}-client = %{version}-%{release}
153Requires: gcc
154Requires: kernel-module-build
155Requires: make
156
157%description devel
158This package provides the components needed to compile a systemtap
159script from source form into executable (.ko) forms. It may be
160installed on a self-contained developer workstation (along with the
161systemtap-client and systemtap-runtime packages), or on a dedicated
162remote server (alongside the systemtap-server package). It includes a
163copy of the standard tapset library and the runtime library C files.
164
165%description devel -l pl.UTF-8
166Ten pakiet dostarcza komponenty niezbędne do kompilowania skryptów
167systemtap z postaci źródłowej do wykonywalnej (.ko). Może być
168zainstalowany na samodzielnej stacji roboczej programisty (wraz z
169pakietami systemtap-client i systemtap-runtime) lub dedykowanym
170zdalnym serwerze (wraz z pakietem systemtap-server). Zawiera kopię
171standardowej biblioteki tapset oraz pliki biblioteki uruchomieniowej
172C.
099db71a
AM
173
174%package initscript
8bec3f09
JB
175Summary: SystemTap Initscripts
176Summary(pl.UTF-8): Skrypty startowe SystemTap
099db71a 177Group: Base
8bec3f09
JB
178Requires(post,preun): /sbin/chkconfig
179Requires: %{name} = %{version}-%{release}
180Requires: rc-scripts
099db71a
AM
181
182%description initscript
8bec3f09 183SysVinit scripts to launch selected systemtap scripts at system
099db71a
AM
184startup.
185
8bec3f09
JB
186%description initscript -l pl.UTF-8
187Skrypty SysVinit do uruchamiania wybranych skryptów systemtap w
188trakcie startu systemu.
189
190%package server
191Summary: Instrumentation System Server
192Summary(pl.UTF-8): Serwer systemu oprzyrządowania
193Group: Applications/System
194Requires(post,preun): /sbin/chkconfig
195Requires: %{name}-devel = %{version}-%{release}
196Requires: /bin/mktemp
197Requires: unzip
198Requires: zip
199
200%description server
201This is the remote script compilation server component of systemtap.
202It announces itself to nearby clients with avahi (if available), and
203compiles systemtap scripts to kernel objects on their demand.
204
205%description server -l pl.UTF-8
206Ten pakiet zawiera komponent serwera do zdalnej kompilacji skryptów
207systemtap. Rozgłasza się pobliskim klientom przy użyciu avahi (jeśli
208jest dostępny) i na żądanie kompiluje skrypty systemtap do obiektów
209jądra.
210
099db71a
AM
211%package sdt-devel
212Summary: Static probe support tools
8bec3f09
JB
213Summary(pl.UTF-8): Narzędzia do obsługi sond statycznych
214License: GPL v2+ and Public Domain
099db71a 215Group: Development/Libraries
099db71a
AM
216
217%description sdt-devel
218This package includes the <sys/sdt.h> header file used for static
219instrumentation compiled into userspace programs and libraries, along
220with the optional dtrace-compatibility preprocessor to process related
221.d files into tracing-macro-laden .h headers.
222
8bec3f09
JB
223%description sdt-devel -l pl.UTF-8
224Ten pakiet zawiera plik nagłówkowy <sys/sdt.h> służący do
225wkompilowywania statycznego oprzyrządowania do programów i bibliotek
226przestrzeni użytkownika, wraz z opcjonalnym preprocesorem zgodności z
227dtrace, który przetwarza pliki .d na pliki nagłówkowe .h z makrami
228śledzącymi.
229
a575733c
JB
230%package doc
231Summary: SystemTap guides and tutorials
232Summary(pl.UTF-8): Przewodniki i dokumentacja wprowadzająca do SystemTap
233Group: Documentation
234
235%description doc
236SystemTap guides and tutorials.
237
238%description doc -l pl.UTF-8
239Przewodniki i dokumentacja wprowadzająca do SystemTap.
240
aa39e90e 241%prep
459a2a3b 242%setup -q
243%patch0 -p1
099db71a 244%patch1 -p1
97c167ee 245%patch3 -p1
1a30c954 246%patch4 -p1
8bec3f09 247%if "%{_rpmversion}" >= "5.0"
6fbeb569 248%patch2 -p1
8bec3f09 249%endif
26f73914 250
aa39e90e 251%build
e7f20467 252%{__gettextize}
459a2a3b 253%{__aclocal}
254%{__autoconf}
255%{__autoheader}
256%{__automake}
8e86ead7
JB
257# dyninst requires C++11 mode
258CXXFLAGS="%{rpmcxxflags} -std=c++11"
459a2a3b 259%configure \
099db71a 260 --disable-silent-rules \
1651fd5a 261 %{?with_crash:--enable-crash} \
8bec3f09 262 --enable-docs%{!?with_doc:=no} \
099db71a 263 --enable-pie \
8bec3f09 264 --enable-server \
099db71a 265 --enable-sqlite \
c15371b4 266 --with-dyninst%{!?with_dyninst:=no} \
8bec3f09 267 --with-java=%{?with_java:%{_jvmdir}/java}%{!?with_java:no}
aa39e90e
AM
268%{__make}
269
270%install
271rm -rf $RPM_BUILD_ROOT
8bec3f09
JB
272install -d $RPM_BUILD_ROOT{/var/{cache,run}/%{name},%{systemdtmpfilesdir},%{systemdunitdir}} \
273 $RPM_BUILD_ROOT{%{_sysconfdir}/stap-server/conf.d,/etc/{sysconfig,logrotate.d,rc.d/init.d}} \
bc044f75 274 $RPM_BUILD_ROOT/var/log/stap-server
aa39e90e 275
43d6c0ff 276%{__make} install \
aa39e90e
AM
277 DESTDIR=$RPM_BUILD_ROOT
278
8bec3f09
JB
279cp -p %{SOURCE1} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/systemtap.conf
280cp -p %{SOURCE2} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/stap-server.conf
281
282# not installed by make
7a86387a 283install -p stap-prep $RPM_BUILD_ROOT%{_bindir}/stap-prep
aa39e90e 284
7a86387a
ER
285install -p initscript/systemtap $RPM_BUILD_ROOT/etc/rc.d/init.d
286cp -p initscript/config.systemtap $RPM_BUILD_ROOT%{_sysconfdir}/systemtap/config
bc044f75 287
7a86387a
ER
288install -p initscript/stap-server $RPM_BUILD_ROOT/etc/rc.d/init.d
289cp -p initscript/config.stap-server $RPM_BUILD_ROOT/etc/sysconfig/stap-server
290cp -p initscript/logrotate.stap-server $RPM_BUILD_ROOT/etc/logrotate.d/stap-server
291cp -p stap-server.service $RPM_BUILD_ROOT%{systemdunitdir}
8bec3f09
JB
292
293install -d $RPM_BUILD_ROOT%{_sysconfdir}/systemtap/{conf.d,script.d}
294install -d $RPM_BUILD_ROOT/var/lib/stap-server/.systemtap
295install -d $RPM_BUILD_ROOT/var/log/stap-server
296
7a86387a 297%if %{with doc}
fa83958d 298install -d $RPM_BUILD_ROOT%{_examplesdir}
97c167ee 299%{__mv} $RPM_BUILD_ROOT{%{_docdir}/%{name}/examples,%{_examplesdir}/%{name}-client-%{version}}
7a86387a
ER
300%endif
301
8bec3f09 302%{__mv} $RPM_BUILD_ROOT%{_docdir}/systemtap docs-installed
bc044f75 303
099db71a
AM
304%find_lang %{name}
305
a3bbe4b0 306%clean
307rm -rf $RPM_BUILD_ROOT
308
aa39e90e
AM
309%files
310%defattr(644,root,root,755)
8bec3f09
JB
311
312%files runtime -f %{name}.lang
313%defattr(644,root,root,755)
314%doc AUTHORS NEWS README*
839ed024 315%attr(755,root,root) %{_bindir}/stap-merge
316%attr(755,root,root) %{_bindir}/stap-report
c15371b4 317%{?with_dyninst:%attr(755,root,root) %{_bindir}/stapdyn}
839f235b 318%attr(755,root,root) %{_bindir}/stapsh
8bec3f09
JB
319# XXX: %attr(4754,root,stapusr) staprun ?
320%attr(755,root,root) %{_bindir}/staprun
73e96872 321%dir %{_libdir}/%{name}
8bec3f09
JB
322%attr(755,root,root) %{_libdir}/%{name}/stap-authorize-cert
323%attr(755,root,root) %{_libdir}/%{name}/stapio
1651fd5a 324%{?with_crash:%attr(755,root,root) %{_libdir}/%{name}/staplog.so}
839f235b 325%{_mandir}/man1/stap-merge.1*
311fc893 326%{_mandir}/man1/stap-report.1*
e75a4152 327%{_mandir}/man1/stapref.1*
8bec3f09
JB
328%{_mandir}/man3/stapex.3stap*
329%{_mandir}/man3/stapfuncs.3stap*
330%{_mandir}/man3/stapprobes.3stap*
331%{_mandir}/man3/stapvars.3stap*
52ae841a
JB
332%if %{with doc}
333%{_mandir}/man3/function::*.3stap*
e75a4152 334%{_mandir}/man3/macro::*.3stap*
52ae841a
JB
335%{_mandir}/man3/probe::*.3stap*
336%{_mandir}/man3/tapset::*.3stap*
337%endif
8bec3f09 338%{_mandir}/man7/error::*.7stap*
bc044f75 339%{_mandir}/man7/stappaths.7*
8bec3f09 340%{_mandir}/man7/warning::debuginfo.7stap*
eae4d4c2 341%{_mandir}/man7/warning::symbols.7stap*
311fc893 342%{?with_dyninst:%{_mandir}/man8/stapdyn.8*}
839f235b 343%{_mandir}/man8/staprun.8*
311fc893 344%{_mandir}/man8/stapsh.8*
e7f20467 345%{_mandir}/man8/systemtap.8*
97c167ee
JB
346%lang(cs) %{_mandir}/cs/man1/stap-merge.1*
347%lang(cs) %{_mandir}/cs/man1/stap-report.1*
348%lang(cs) %{_mandir}/cs/man1/stapref.1*
349%lang(cs) %{_mandir}/cs/man3/stapex.3stap*
350%lang(cs) %{_mandir}/cs/man3/stapfuncs.3stap*
351%lang(cs) %{_mandir}/cs/man3/stapprobes.3stap*
352%lang(cs) %{_mandir}/cs/man3/stapvars.3stap*
353%lang(cs) %{_mandir}/cs/man7/error::*.7stap*
354%lang(cs) %{_mandir}/cs/man7/stappaths.7*
355%lang(cs) %{_mandir}/cs/man7/warning::debuginfo.7stap*
356%lang(cs) %{_mandir}/cs/man7/warning::symbols.7stap*
357%lang(cs) %{_mandir}/cs/man8/stapsh.8*
358%lang(cs) %{_mandir}/cs/man8/systemtap.8*
099db71a 359
8bec3f09
JB
360%if %{with java}
361%files runtime-java
362%defattr(644,root,root,755)
363%attr(755,root,root) %{_libdir}/%{name}/stapbm
364%attr(755,root,root) %{_libdir}/%{name}/libHelperSDT_*.so
365%{_libdir}/%{name}/HelperSDT.jar
366%endif
367
368%files client
369%defattr(644,root,root,755)
8bec3f09
JB
370%attr(755,root,root) %{_bindir}/stap
371%attr(755,root,root) %{_bindir}/stap-prep
3d813eaf 372%attr(755,root,root) %{_bindir}/stapvirt
8bec3f09
JB
373%dir %{_datadir}/%{name}
374%{_datadir}/%{name}/tapset
375%{_mandir}/man1/stap.1*
376%{_mandir}/man1/stap-prep.1*
3d813eaf 377%{_mandir}/man1/stapvirt.1*
97c167ee
JB
378%lang(cs) %{_mandir}/cs/man1/stap.1*
379%lang(cs) %{_mandir}/cs/man1/stap-prep.1*
380%lang(cs) %{_mandir}/cs/man1/stapvirt.1*
381%if %{with doc}
382%{_examplesdir}/%{name}-client-%{version}
383%endif
8bec3f09
JB
384
385%files devel
386%defattr(644,root,root,755)
387%{_datadir}/%{name}/runtime
388
389%files initscript
390%defattr(644,root,root,755)
8bec3f09
JB
391%attr(754,root,root) /etc/rc.d/init.d/systemtap
392%dir %{_sysconfdir}/systemtap
393%dir %{_sysconfdir}/systemtap/conf.d
394%dir %{_sysconfdir}/systemtap/script.d
395%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/systemtap/config
396%{systemdtmpfilesdir}/systemtap.conf
397%dir /var/cache/%{name}
398%dir /var/run/%{name}
399
400%files server
401%defattr(644,root,root,755)
402%attr(755,root,root) %{_bindir}/stap-server
403%attr(755,root,root) %{_libdir}/%{name}/stap-env
404%attr(755,root,root) %{_libdir}/%{name}/stap-gen-cert
405%attr(755,root,root) %{_libdir}/%{name}/stap-serverd
406%attr(755,root,root) %{_libdir}/%{name}/stap-sign-module
407%attr(755,root,root) %{_libdir}/%{name}/stap-start-server
408%attr(755,root,root) %{_libdir}/%{name}/stap-stop-server
409%dir %{_sysconfdir}/stap-server
410%dir %{_sysconfdir}/stap-server/conf.d
411%attr(754,root,root) /etc/rc.d/init.d/stap-server
412%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/stap-server
413%config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/stap-server
414%{systemdunitdir}/stap-server.service
415%{systemdtmpfilesdir}/stap-server.conf
416# TODO: create user/group
417#%attr(750,stap-server,stap-server) %dir /var/lib/stap-server
418#%attr(700,stap-server,stap-server) %dir /var/lib/stap-server/.systemtap
419#%attr(755,stap-server,stap-server) %dir /var/log/stap-server
420#%attr(755,stap-server,stap-server) %dir /var/run/stap-server
421%{_mandir}/man8/stap-server.8*
97c167ee 422%lang(cs) %{_mandir}/cs/man8/stap-server.8*
8bec3f09
JB
423
424%files sdt-devel
099db71a
AM
425%defattr(644,root,root,755)
426%attr(755,root,root) %{_bindir}/dtrace
427%{_includedir}/sys/sdt.h
428%{_includedir}/sys/sdt-config.h
429%{_mandir}/man1/dtrace.1*
97c167ee 430%lang(cs) %{_mandir}/cs/man1/dtrace.1*
a575733c 431
97c167ee 432%if %{with doc}
a575733c
JB
433%files doc
434%defattr(644,root,root,755)
97c167ee 435%doc doc/{langref,tutorial}.pdf doc/beginners/SystemTap_Beginners_Guide.pdf docs-installed/tapsets.pdf
a575733c 436%endif
This page took 0.231652 seconds and 4 git commands to generate.