]>
Commit | Line | Data |
---|---|---|
1074f79d | 1 | # Release number for rpm build. Stays at 1 for new PACKAGE_VERSION increases. |
d8c3d602 | 2 | %define release 2 |
1074f79d | 3 | # Version number of oldest elfutils release that works with systemtap. |
4cbe5562 | 4 | %define elfutils_version 0.127 |
1074f79d RM |
5 | |
6 | # Set bundled_elfutils to 0 on systems that have %{elfutils_version} or newer. | |
7 | %if 0%{?fedora} | |
8 | %define bundled_elfutils 1 | |
d8c3d602 | 9 | %define sqlite 0 |
1074f79d RM |
10 | %if "%fedora" >= "6" |
11 | %define bundled_elfutils 0 | |
d8c3d602 | 12 | %define sqlite 1 |
1074f79d RM |
13 | %endif |
14 | %endif | |
15 | ||
16 | %if 0%{?rhel} | |
9e9c67be | 17 | %define bundled_elfutils 1 |
d8c3d602 | 18 | %define sqlite 0 |
1074f79d RM |
19 | %if "%rhel" >= "5" |
20 | %define bundled_elfutils 0 | |
d8c3d602 | 21 | %define sqlite 1 |
1074f79d RM |
22 | %endif |
23 | %endif | |
24 | ||
b3b92e29 | 25 | %if 0%{!?bundled_elfutils:1} |
1074f79d RM |
26 | # Yo! DO NOT TOUCH THE FOLLOWING LINE. |
27 | # You can use rpmbuild --define "bundled_elfutils 0" for a build of your own. | |
28 | %define bundled_elfutils 1 | |
29 | %endif | |
7d838f63 | 30 | |
d8c3d602 WC |
31 | %if 0%{!?sqlite:1} |
32 | # Yo! DO NOT TOUCH THE FOLLOWING LINE. | |
33 | # You can use rpmbuild --define "sqlite 1" for a build of your own. | |
34 | %define sqlite 0 | |
35 | %endif | |
36 | ||
a2c9eba7 | 37 | Name: systemtap |
7d838f63 | 38 | Version: @VERSION@ |
1074f79d | 39 | Release: %{release}%{?dist} |
7d838f63 | 40 | Summary: Instrumentation System |
7d838f63 | 41 | Group: Development/System |
6a1cd8a7 | 42 | License: GPLv2+ |
a2c9eba7 RM |
43 | URL: http://sourceware.org/systemtap/ |
44 | Source: ftp://sourceware.org/pub/%{name}/%{name}-%{version}.tar.gz | |
45 | ||
37b99e78 | 46 | BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) |
a2c9eba7 RM |
47 | |
48 | Requires: kernel >= 2.6.9-11 | |
78db65bd | 49 | BuildRequires: glib2-devel >= 2.0.0 |
b20febf3 FCE |
50 | # make check |
51 | BuildRequires: dejagnu | |
d8c3d602 | 52 | %if %{sqlite} |
c3a3c0c9 | 53 | BuildRequires: sqlite-devel |
d8c3d602 WC |
54 | Requires: sqlite |
55 | %endif | |
78db65bd | 56 | Requires: glib2 >= 2.0.0 |
4698b0a8 FCE |
57 | # Requires: kernel-devel |
58 | # or is that kernel-smp-devel? kernel-hugemem-devel? | |
aab2b35f | 59 | Requires: gcc make |
9ae6172f | 60 | # Suggest: kernel-debuginfo |
a63a95dc | 61 | Requires: systemtap-runtime = %{version}-%{release} |
e7122323 | 62 | Requires: sudo |
7d838f63 MH |
63 | |
64 | %if %{bundled_elfutils} | |
65 | Source1: elfutils-%{elfutils_version}.tar.gz | |
66 | Patch1: elfutils-portability.patch | |
67 | %define setup_elfutils -a1 | |
a2c9eba7 RM |
68 | %else |
69 | BuildRequires: elfutils-devel >= %{elfutils_version} | |
7d838f63 MH |
70 | %endif |
71 | ||
7d838f63 | 72 | %description |
a2c9eba7 RM |
73 | SystemTap is an instrumentation system for systems running Linux 2.6. |
74 | Developers can write instrumentation to collect data on the operation | |
75 | of the system. | |
7d838f63 | 76 | |
a63a95dc DS |
77 | %package runtime |
78 | Summary: Instrumentation System Runtime | |
79 | Group: Development/System | |
6a1cd8a7 | 80 | License: GPLv2+ |
a63a95dc DS |
81 | URL: http://sourceware.org/systemtap/ |
82 | Requires: kernel >= 2.6.9-11 | |
83 | ||
84 | %description runtime | |
85 | SystemTap runtime is the runtime component of an instrumentation | |
86 | system for systems running Linux 2.6. Developers can write | |
87 | instrumentation to collect data on the operation of the system. | |
88 | ||
7d838f63 | 89 | %prep |
a2c9eba7 RM |
90 | %setup -q %{?setup_elfutils} |
91 | ||
7d838f63 MH |
92 | %if %{bundled_elfutils} |
93 | cd elfutils-%{elfutils_version} | |
94 | %patch1 -p1 | |
a2c9eba7 RM |
95 | sleep 1 |
96 | find . \( -name Makefile.in -o -name aclocal.m4 \) -print | xargs touch | |
97 | sleep 1 | |
98 | find . \( -name configure -o -name config.h.in \) -print | xargs touch | |
7d838f63 MH |
99 | cd .. |
100 | %endif | |
101 | ||
102 | %build | |
a2c9eba7 | 103 | |
7d838f63 MH |
104 | %if %{bundled_elfutils} |
105 | # Build our own copy of elfutils. | |
4d9087fc | 106 | %define elfutils_config --with-elfutils=elfutils-%{elfutils_version} |
a2c9eba7 RM |
107 | |
108 | # We have to prevent the standard dependency generation from identifying | |
109 | # our private elfutils libraries in our provides and requires. | |
110 | %define _use_internal_dependency_generator 0 | |
111 | %define filter_eulibs() /bin/sh -c "%{1} | sed '/libelf/d;/libdw/d;/libebl/d'" | |
112 | %define __find_provides %{filter_eulibs /usr/lib/rpm/find-provides} | |
113 | %define __find_requires %{filter_eulibs /usr/lib/rpm/find-requires} | |
4dbd685d RM |
114 | |
115 | # This will be needed for running stap when not installed, for the test suite. | |
116 | %define elfutils_mflags LD_LIBRARY_PATH=`pwd`/lib-elfutils | |
7d838f63 MH |
117 | %endif |
118 | ||
d8c3d602 WC |
119 | %if %{sqlite} |
120 | # Include the coverage testing support | |
121 | %define sqlite_config --enable-sqlitedb | |
122 | %endif | |
123 | ||
124 | %configure %{?elfutils_config} %{?sqlite_config} | |
a2c9eba7 | 125 | make %{?_smp_mflags} |
2a4b42eb DS |
126 | |
127 | # Fix paths in the example scripts | |
128 | find examples -type f -name '*.stp' -print0 | xargs -0 sed -i -r -e '1s@^#!.+stap@#!%{_bindir}/stap@' | |
7d838f63 | 129 | |
c63a6b9d DS |
130 | # To avoid perl dependency, make perl sample script non-executable |
131 | chmod -x examples/samples/kmalloc-top | |
132 | ||
7d838f63 MH |
133 | %install |
134 | rm -rf ${RPM_BUILD_ROOT} | |
37b99e78 | 135 | make DESTDIR=$RPM_BUILD_ROOT install |
7d838f63 | 136 | |
4dbd685d RM |
137 | %check |
138 | make check %{?elfutils_mflags} || : | |
7d838f63 MH |
139 | |
140 | %clean | |
141 | rm -rf ${RPM_BUILD_ROOT} | |
142 | ||
143 | %files | |
144 | %defattr(-,root,root) | |
a2c9eba7 | 145 | |
94cfa802 | 146 | %doc README AUTHORS NEWS COPYING examples |
a2c9eba7 RM |
147 | |
148 | %{_bindir}/stap | |
78db65bd | 149 | %{_bindir}/lket-b2a |
4dbd685d | 150 | %{_mandir}/man1/* |
ba4a90fd | 151 | %{_mandir}/man5/* |
a2c9eba7 RM |
152 | |
153 | %dir %{_datadir}/systemtap | |
154 | %{_datadir}/systemtap/runtime | |
4dbd685d | 155 | %{_datadir}/systemtap/tapset |
a2c9eba7 | 156 | |
7d838f63 MH |
157 | %if %{bundled_elfutils} |
158 | %dir %{_libdir}/%{name} | |
c1edaa30 | 159 | %{_libdir}/%{name}/*.so* |
7d838f63 | 160 | %endif |
a2c9eba7 | 161 | |
a63a95dc DS |
162 | %files runtime |
163 | %defattr(-,root,root) | |
164 | %{_bindir}/staprun | |
906cf40a | 165 | %{_libexecdir}/systemtap |
be168105 DS |
166 | %{_mandir}/man8/* |
167 | ||
168 | %doc README AUTHORS NEWS COPYING | |
7d838f63 MH |
169 | |
170 | %changelog | |
d8c3d602 WC |
171 | * Wed Jul 11 2007 Will Cohen <wcohen@redhat.com> - 0.5.14-2 |
172 | - Fix Requires and BuildRequires for sqlite. | |
173 | ||
c1edaa30 FCE |
174 | * Tue Jul 2 2007 Frank Ch. Eigler <fche@redhat.com> - 0.5.14-1 |
175 | - Many robustness improvements: 1117, 1134, 1305, 1307, 1570, 1806, | |
176 | 2033, 2116, 2224, 2339, 2341, 2406, 2426, 2438, 2583, 3037, | |
177 | 3261, 3282, 3331, 3428 3519, 3545, 3625, 3648, 3880, 3888, 3911, | |
178 | 3952, 3965, 4066, 4071, 4075, 4078, 4081, 4096, 4119, 4122, 4127, | |
179 | 4146, 4171, 4179, 4183, 4221, 4224, 4254, 4281, 4319, 4323, 4326, | |
180 | 4329, 4332, 4337, 4415, 4432, 4444, 4445, 4458, 4467, 4470, 4471, | |
181 | 4518, 4567, 4570, 4579, 4589, 4609, 4664 | |
182 | ||
aa384dcd FCE |
183 | * Mon Mar 26 2007 Frank Ch. Eigler <fche@redhat.com> - 0.5.13-1 |
184 | - An emergency / preliminary refresh, mainly for compatibility | |
185 | with 2.6.21-pre kernels. | |
2a4b42eb | 186 | |
31982bd2 FCE |
187 | * Mon Jan 1 2007 Frank Ch. Eigler <fche@redhat.com> - 0.5.12-1 |
188 | - Many changes, see NEWS file. | |
189 | ||
a63a95dc DS |
190 | * Tue Sep 26 2006 David Smith <dsmith@redhat.com> - 0.5.10-1 |
191 | - Added 'systemtap-runtime' subpackage. | |
192 | ||
d65d6b27 RM |
193 | * Wed Jul 19 2006 Roland McGrath <roland@redhat.com> - 0.5.9-1 |
194 | - PRs 2669, 2913 | |
195 | ||
c1d6a343 RM |
196 | * Fri Jun 16 2006 Roland McGrath <roland@redhat.com> - 0.5.8-1 |
197 | - PRs 2627, 2520, 2228, 2645 | |
198 | ||
f6291560 | 199 | * Fri May 5 2006 Frank Ch. Eigler <fche@redhat.com> - 0.5.7-1 |
6f231a27 FCE |
200 | - PRs 2511 2453 2307 1813 1944 2497 2538 2476 2568 1341 2058 2220 2437 |
201 | 1326 2014 2599 2427 2438 2465 1930 2149 2610 2293 2634 2506 2433 | |
202 | ||
611010bf RM |
203 | * Tue Apr 4 2006 Roland McGrath <roland@redhat.com> - 0.5.5-1 |
204 | - Many changes, affected PRs include: 2068, 2293, 1989, 2334, | |
205 | 1304, 2390, 2425, 953. | |
206 | ||
be9923ac FCE |
207 | * Wed Feb 1 2006 Frank Ch. Eigler <fche@redhat.com> - 0.5.4-1 |
208 | - PRs 1916, 2205, 2142, 2060, 1379 | |
209 | ||
db6a8a10 RM |
210 | * Mon Jan 16 2006 Roland McGrath <roland@redhat.com> - 0.5.3-1 |
211 | - Many changes, affected PRs include: 2056, 1144, 1379, 2057, | |
212 | 2060, 1972, 2140, 2148 | |
213 | ||
dcf0c541 RM |
214 | * Mon Dec 19 2005 Roland McGrath <roland@redhat.com> - 0.5.2-1 |
215 | - Fixed build with gcc 4.1, various tapset changes. | |
216 | ||
4d9087fc RM |
217 | * Wed Dec 7 2005 Roland McGrath <roland@redhat.com> - 0.5.1-1 |
218 | - elfutils update, build changes | |
219 | ||
e94c050c | 220 | * Fri Dec 02 2005 Frank Ch. Eigler <fche@redhat.com> - 0.5-1 |
7d9e8974 FCE |
221 | - Many fixes and improvements: 1425, 1536, 1505, 1380, 1329, 1828, 1271, |
222 | 1339, 1340, 1345, 1837, 1917, 1903, 1336, 1868, 1594, 1564, 1276, 1295 | |
223 | ||
ae65ed5c RM |
224 | * Mon Oct 31 2005 Roland McGrath <roland@redhat.com> - 0.4.2-1 |
225 | - Many fixes and improvements: PRs 1344, 1260, 1330, 1295, 1311, 1368, | |
226 | 1182, 1131, 1332, 1366, 1456, 1271, 1338, 1482, 1477, 1194. | |
227 | ||
66bb48fd RM |
228 | * Wed Sep 14 2005 Roland McGrath <roland@redhat.com> - 0.4.1-1 |
229 | - Many fixes and improvements since 0.2.2; relevant PRs include: | |
230 | 1122, 1134, 1155, 1172, 1174, 1175, 1180, 1186, 1187, 1191, 1193, 1195, | |
231 | 1197, 1205, 1206, 1209, 1213, 1244, 1257, 1258, 1260, 1265, 1268, 1270, | |
232 | 1289, 1292, 1306, 1335, 1257 | |
233 | ||
323904e0 FCE |
234 | * Wed Sep 7 2005 Frank Ch. Eigler <fche@redhat.com> |
235 | - Bump version. | |
236 | ||
03f23d0f | 237 | * Wed Aug 16 2005 Frank Ch. Eigler <fche@redhat.com> |
83ff1cf9 FCE |
238 | - Bump version. |
239 | ||
2205d115 MH |
240 | * Wed Aug 3 2005 Martin Hunt <hunt@redhat.com> - 0.2.2-1 |
241 | - Add directory /var/cache/systemtap | |
242 | - Add stp_check to /usr/libexec/systemtap | |
243 | ||
351e76d3 RM |
244 | * Wed Aug 3 2005 Roland McGrath <roland@redhat.com> - 0.2.1-1 |
245 | - New version 0.2.1, various fixes. | |
246 | ||
4dbd685d RM |
247 | * Fri Jul 29 2005 Roland McGrath <roland@redhat.com> - 0.2-1 |
248 | - New version 0.2, requires elfutils 0.111 | |
249 | ||
a2c9eba7 RM |
250 | * Mon Jul 25 2005 Roland McGrath <roland@redhat.com> |
251 | - Clean up spec file, build bundled elfutils. | |
252 | ||
7d838f63 MH |
253 | * Thu Jul 21 2005 Martin Hunt <hunt@redhat.com> |
254 | - Set Version to use version from autoconf. | |
255 | - Fix up some of the path names. | |
a2c9eba7 RM |
256 | - Add Requires and BuildRequires. |
257 | ||
258 | * Wed Jul 19 2005 Will Cohen <wcohen@redhat.com> | |
7d838f63 | 259 | - Initial creation of RPM. |