]>
Commit | Line | Data |
---|---|---|
3eaa205f | 1 | # TODO |
3db19835 ER |
2 | # - use policykit to gain root |
3 | # - use %caps when rpm supports it: %attr(750,root,wireshark) %caps(cap_net_raw,cap_net_admin=eip) %{_sbindir}/dumpcap | |
3eaa205f ER |
4 | # - think of loosing dependency loop: |
5 | # Executing rpm --upgrade -vh --root /... | |
6 | # error: LOOP: | |
7 | # error: removing libwiretap-1.2.4-1.i686 "Requires(auto): libwsutil.so.0" from tsort relations. | |
8 | # error: libwiretap-1.2.4-1.i686 Requires(auto): libwsutil.so.0 | |
9 | # error: removing wireshark-common-1.2.4-1.i686 "Requires: libwiretap = 1.2.4-1" from tsort relations. | |
10 | # error: wireshark-common-1.2.4-1.i686 Requires: libwiretap = 1.2.4-1 | |
11 | # error: LOOP: | |
12 | # error: removing libwiretap-1.2.3-1.i686 "Requires: libwiretap = 1.2.3-1" from tsort relations. | |
13 | # error: libwiretap-1.2.3-1.i686 Requires: libwiretap = 1.2.3-1 | |
14 | # error: removing wireshark-common-1.2.3-1.i686 "Requires(auto): libwsutil.so.0" from tsort relations. | |
15 | # error: wireshark-common-1.2.3-1.i686 Requires(auto): libwsutil.so.0 | |
06ce418f | 16 | # |
681bd53b | 17 | # Conditional build: |
e705ff13 | 18 | %bcond_without kerberos5 # build without Kerberos V support |
0f807600 | 19 | %bcond_without snmp # build without snmp support |
0846fcb3 | 20 | |
c06ca841 | 21 | Summary: Network traffic and protocol analyzer |
301eb42a ER |
22 | Summary(es.UTF-8): Analizador de tráfico de red |
23 | Summary(pl.UTF-8): Analizator ruchu i protokołów sieciowych | |
24 | Summary(pt_BR.UTF-8): Analisador de tráfego de rede | |
25 | Summary(ru.UTF-8): Анализатор сетевого траффика | |
26 | Summary(uk.UTF-8): Аналізатор мережевого трафіку | |
3564cfa5 | 27 | Name: wireshark |
e2778136 | 28 | Version: 1.8.6 |
b316fa1c | 29 | Release: 1 |
c06ca841 | 30 | License: GPL |
6d55af47 TP |
31 | Group: Networking/Utilities |
32 | Source0: http://www.wireshark.org/download/src/%{name}-%{version}.tar.bz2 | |
e2778136 | 33 | # Source0-md5: 317361e701936c72f7f18f857059b944 |
c54254da AM |
34 | Patch0: %{name}-Werror.patch |
35 | Patch1: %{name}-gcc43.patch | |
36 | Patch2: %{name}-ac.patch | |
37 | Patch3: %{name}-desktop.patch | |
ba8d5592 | 38 | URL: http://www.wireshark.org/ |
ba8d5592 | 39 | BuildRequires: autoconf >= 2.52 |
54cc2149 | 40 | BuildRequires: automake |
00a07a36 | 41 | BuildRequires: bison |
1b8a1786 | 42 | BuildRequires: elfutils-devel |
ad2318ff | 43 | BuildRequires: flex |
ba8d5592 | 44 | BuildRequires: gnutls-devel >= 1.0.0 |
4bf910d1 | 45 | BuildRequires: gtk+2-devel >= 1:2.0.0 |
c1939565 | 46 | %{?with_kerberos5:BuildRequires: heimdal-devel} |
558b2cad | 47 | BuildRequires: libcap-devel |
f1a1443d | 48 | BuildRequires: libgcrypt-devel >= 1.1.42 |
2dee0cf7 | 49 | BuildRequires: libpcap-devel >= 2:1.0.0-4 |
38791bb5 | 50 | BuildRequires: libsmi-devel |
742fd0dc | 51 | BuildRequires: libtool |
9f20d4ae | 52 | BuildRequires: libxslt-progs |
4d8bc1a9 | 53 | BuildRequires: lua51-devel |
49540dfb | 54 | %{?with_snmp:BuildRequires: net-snmp-devel} |
4d8bc1a9 | 55 | BuildRequires: pcre-devel |
00a07a36 | 56 | BuildRequires: perl-tools-pod |
264f64a4 | 57 | BuildRequires: pkgconfig |
4d8bc1a9 | 58 | BuildRequires: portaudio-devel |
d88a1752 | 59 | BuildRequires: sed >= 4.0 |
c06ca841 | 60 | BuildRequires: zlib-devel |
d1cb25db | 61 | Requires: %{name}-common = %{version}-%{release} |
ad2318ff | 62 | Requires: libpcap >= 0.4 |
2fc873c0 | 63 | Provides: ethereal |
3585cc66 | 64 | Provides: ethereal-gnome |
2fc873c0 | 65 | Obsoletes: ethereal |
3585cc66 | 66 | Obsoletes: ethereal-gnome |
d1cb25db | 67 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
c06ca841 | 68 | |
c06ca841 | 69 | %description |
3564cfa5 | 70 | Wireshark is the name for powerful graphical network sniffer, traffic |
3993f161 | 71 | and protocol analyzer based on GTK+ and libpcap libraries. It lets you |
72 | capture and interactively browse the contents of network frames with | |
3564cfa5 | 73 | vast knowledge of more than 100 network protocols. Wireshark has |
3993f161 | 74 | severeal useful features, including a rich display filter language, |
75 | the ability to view the ASCII contents of a TCP connection and plug-in | |
76 | capabilities. | |
c06ca841 | 77 | |
bd5a719c JR |
78 | %description -l es.UTF-8 |
79 | Analizador de tráfico de red. | |
bd307bb2 | 80 | |
bd5a719c JR |
81 | %description -l pl.UTF-8 |
82 | Wireshark jest potężnym, graficznym snifferem, analizatorem ruchu oraz | |
83 | protokołów sieciowych opartym na bibliotekach GTK+ oraz libpcap. | |
84 | Umożliwia on przechwytywanie oraz interaktywną analizę zawartości | |
85 | ramek oraz ponad stu protokołów sieciowych. Wireshark posiada wiele | |
86 | użytecznych cech, takich jak rozbudowany język filtrów wyświetlania, | |
87 | możliwość oglądania przebiegu sesji TCP oraz możliwość dołączania | |
3993f161 | 88 | wtyczek (plug-ins). |
c06ca841 | 89 | |
bd5a719c JR |
90 | %description -l pt_BR.UTF-8 |
91 | O Wireshark é um analisador de protocolo de rede baseado no GTK+. | |
bd307bb2 | 92 | |
bd5a719c JR |
93 | %description -l ru.UTF-8 |
94 | Wireshark - это анализатор сетевого траффика для Unix-подобных ОС. Он | |
95 | базируется на GTK+ и libpcap. | |
8cadd9c5 | 96 | |
bd5a719c JR |
97 | %description -l uk.UTF-8 |
98 | Wireshark - це аналізатор мережевого трафіку для Unix-подібних ОС. Він | |
99 | базується на GTK+ та libpcap. | |
8cadd9c5 | 100 | |
8556fd8d | 101 | %package common |
102 | Summary: Network traffic and protocol analyzer - common files | |
301eb42a | 103 | Summary(pl.UTF-8): Analizator ruchu i protokołów sieciowych - wspólne pliki |
8556fd8d | 104 | Group: Networking |
3d4f4fbf | 105 | Requires: libwiretap = %{version}-%{release} |
f32e8035 | 106 | Provides: %{name}-tools |
2fc873c0 | 107 | Provides: ethereal-common |
3db19835 | 108 | Provides: group(wireshark) |
9cdb13ff | 109 | Obsoletes: ethereal-common |
f32e8035 | 110 | Obsoletes: wireshark-tools |
3db19835 ER |
111 | Requires(post,postun): /sbin/ldconfig |
112 | Requires(post,postun): /sbin/setcap | |
8556fd8d | 113 | |
114 | %description common | |
3564cfa5 | 115 | Wireshark is the name for powerful graphical network sniffer, traffic |
8556fd8d | 116 | and protocol analyzer based on GTK+ and libpcap libraries. It lets you |
117 | capture and interactively browse the contents of network frames with | |
3564cfa5 | 118 | vast knowledge of more than 100 network protocols. Wireshark has |
8556fd8d | 119 | severeal useful features, including a rich display filter language, |
120 | the ability to view the ASCII contents of a TCP connection and plug-in | |
121 | capabilities. | |
122 | ||
a8a05b82 JB |
123 | This package provides set of tools for manipulating capture files. It |
124 | contains: | |
9b0cad4e AG |
125 | - capinfo - prints informatio about binary capture files, |
126 | - dftest - shows display filter byte-code, | |
ad479611 | 127 | - dumpcap - dumps network traffic to a file, |
9b0cad4e | 128 | - editcap - edit and/or translate the format of capture files, |
9b0cad4e | 129 | - mergecap - merges two capture files into one, |
ad479611 AG |
130 | - randpkt - generates libpcap trace file full of random packets, |
131 | - rawshark - dumps and analyzes raw libpcap data, | |
9b0cad4e AG |
132 | - text2cap - generate a capture file from an ASCII hexdump of packets. |
133 | ||
bd5a719c JR |
134 | %description common -l es.UTF-8 |
135 | Analizador de tráfico de red. | |
8556fd8d | 136 | |
bd5a719c JR |
137 | %description common -l pl.UTF-8 |
138 | Wireshark jest potężnym, graficznym snifferem, analizatorem ruchu oraz | |
139 | protokołów sieciowych opartym na bibliotekach GTK+ oraz libpcap. | |
140 | Umożliwia on przechwytywanie oraz interaktywną analizę zawartości | |
141 | ramek oraz ponad stu protokołów sieciowych. Wireshark posiada wiele | |
142 | użytecznych cech, takich jak rozbudowany język filtrów wyświetlania, | |
143 | możliwość oglądania przebiegu sesji TCP oraz możliwość dołączania | |
8556fd8d | 144 | wtyczek (plug-ins). |
145 | ||
a8a05b82 JB |
146 | Pakiet ten dostarcza także zestaw narzędzi do obróbki plików z |
147 | przechwyconymi pakietami, obejmujący: | |
148 | - capinfo - do wyświetlania informacji o binarnych plikach zrzutu, | |
149 | - dftest - do pokazywania bajtkodu filtrów wyświetlania, | |
ad479611 | 150 | - dumpcap - do zrzucania ruchu sieciowego do pliku, |
9b0cad4e | 151 | - editcap - do edycji plików i tłumaczenia ich na inne formaty, |
9b0cad4e | 152 | - mergecap - do łączenia dwóch plików w jeden, |
ad479611 AG |
153 | - randpkt - do generowania plikow cap z losowymi danymi, |
154 | - rawshark - do obróbki plików cap, | |
9b0cad4e AG |
155 | - text2cap - do generowania pliku cap z szesnastkowego zrzutu ASCII |
156 | pakietów. | |
157 | ||
bd5a719c JR |
158 | %description common -l pt_BR.UTF-8 |
159 | O Wireshark é um analisador de protocolo de rede baseado no GTK+. | |
8556fd8d | 160 | |
bd5a719c JR |
161 | %description common -l ru.UTF-8 |
162 | Wireshark - это анализатор сетевого траффика для Unix-подобных ОС. Он | |
163 | базируется на GTK+ и libpcap. | |
9a51ce65 | 164 | |
bd5a719c JR |
165 | %description common -l uk.UTF-8 |
166 | Wireshark - це аналізатор мережевого трафіку для Unix-подібних ОС. Він | |
167 | базується на GTK+ та libpcap. | |
13dcc98b | 168 | |
3564cfa5 | 169 | %package -n twireshark |
87fe533f | 170 | Summary: Text-mode network traffic and protocol analyzer |
301eb42a ER |
171 | Summary(pl.UTF-8): Tekstowy analizator ruchu i protokołów sieciowych |
172 | Summary(pt_BR.UTF-8): Analisador modo texto de tráfego de rede (sniffer) | |
9a51ce65 | 173 | Group: Networking |
d1cb25db | 174 | Requires: %{name}-common = %{version}-%{release} |
9a51ce65 | 175 | Requires: libpcap >= 0.4 |
2fc873c0 | 176 | Provides: tethereal |
9cdb13ff | 177 | Obsoletes: tethereal |
9a51ce65 | 178 | |
3564cfa5 AM |
179 | %description -n twireshark |
180 | Twireshark is a network protocol analyzer. It lets you capture packet | |
9a51ce65 | 181 | data from a live network, or read packets from a previously saved |
182 | capture file, either printing a decoded form of those packets to the | |
3564cfa5 | 183 | standard output or writing the packets to a file. Twireshark's native |
9a51ce65 | 184 | capture file format is libpcap format, which is also the format used |
185 | by tcpdump and various other tools. | |
186 | ||
bd5a719c JR |
187 | %description -n twireshark -l pl.UTF-8 |
188 | Twireshark jest analizatorem protokołów sieciowych. Pozwala na | |
189 | przechwytywanie pakietów z sieci lub wczytywanie danych z pliku. | |
190 | Zdekodowany wynik (a twireshark zna ponad 100 rozmaitych protokołów | |
191 | sieciowych!) jest wyświetlony na ekranie. Natywnym formatem plików | |
192 | tetherala jest format libpcap, tak więc jest on kompatybilny z | |
193 | tcpdumpem i innymi podobnymi narzędziami. | |
9a51ce65 | 194 | |
bd5a719c JR |
195 | %description -n twireshark -l pt_BR.UTF-8 |
196 | Esta é uma versão para modo texto do analisador de tráfego de rede | |
3564cfa5 | 197 | Wireshark. |
9a51ce65 | 198 | |
3d4f4fbf | 199 | %package -n libwiretap |
2da354f1 | 200 | Summary: Packet capture and analysis library |
301eb42a | 201 | Summary(pl.UTF-8): Biblioteka do przechwytywania i analizy pakietów |
3d4f4fbf JB |
202 | Group: Libraries |
203 | ||
204 | %description -n libwiretap | |
205 | Wiretap is a library that is being developed as a future replacement | |
206 | for libpcap, the current standard Unix library for packet capturing. | |
207 | ||
bd5a719c JR |
208 | %description -n libwiretap -l pl.UTF-8 |
209 | Biblioteka Wiretap rozwijana jest jako przyszły następca biblioteki | |
210 | libpcap, obecnie standardu przechwytywania pakietów w systemach Unix. | |
3d4f4fbf | 211 | |
2bb0e3ef | 212 | %package -n libwiretap-devel |
3d4f4fbf | 213 | Summary: Header files for libwiretap packet capture library |
301eb42a | 214 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libwiretap do przechwytywania pakietów |
2bb0e3ef | 215 | Group: Development/Libraries |
3d4f4fbf | 216 | Requires: gtk+2-devel >= 2.0.0 |
d88a1752 | 217 | Requires: libwiretap = %{version}-%{release} |
2bb0e3ef AM |
218 | |
219 | %description -n libwiretap-devel | |
3d4f4fbf | 220 | Header files for libwiretap packet capture library. |
2bb0e3ef | 221 | |
bd5a719c JR |
222 | %description -n libwiretap-devel -l pl.UTF-8 |
223 | Pliki nagłówkowe biblioteki libwiretap służącej do przechwytywania | |
224 | pakietów. | |
2bb0e3ef | 225 | |
c06ca841 | 226 | %prep |
3db19835 | 227 | %setup -q |
63effabc | 228 | %patch0 -p1 |
69922c19 | 229 | %patch1 -p1 |
5fe62224 | 230 | %patch2 -p1 |
b03933b3 | 231 | %patch3 -p1 |
d88a1752 ER |
232 | sed -i -e 's/lua5\.1/lua51/g' acinclude.m4 |
233 | find -name Makefile.am | xargs sed -i -e 's/-Werror//g' | |
6682782e | 234 | |
c06ca841 | 235 | %build |
bd307bb2 | 236 | %{__libtoolize} |
82ef181d | 237 | %{__aclocal} -I aclocal-fallback |
bd307bb2 | 238 | %{__autoconf} |
239 | %{__automake} | |
bd307bb2 | 240 | %configure \ |
9556b0ee | 241 | --enable-randpkt \ |
7d460fd4 | 242 | --enable-dftest \ |
b316fa1c | 243 | --enable-packet-editor \ |
e705ff13 | 244 | %if %{with kerberos5} |
61c15373 SP |
245 | --with-krb5 \ |
246 | --with-ssl \ | |
247 | %endif | |
c526690f | 248 | %{!?with_snmp:--without-net-snmp --without-ucdsnmp} \ |
c54254da | 249 | --with-lua=/usr |
6682782e | 250 | |
47b29440 | 251 | %{__make} |
c06ca841 | 252 | |
253 | %install | |
254 | rm -rf $RPM_BUILD_ROOT | |
2bb0e3ef | 255 | install -d $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir},%{_includedir}/wiretap} |
c06ca841 | 256 | |
c335c139 PG |
257 | %{__make} install \ |
258 | DESTDIR=$RPM_BUILD_ROOT | |
c06ca841 | 259 | |
3db19835 ER |
260 | cp -p image/hi48-app-wireshark.png $RPM_BUILD_ROOT%{_pixmapsdir}/%{name}.png |
261 | cp -p wireshark.desktop $RPM_BUILD_ROOT%{_desktopdir} | |
c06ca841 | 262 | |
d88a1752 | 263 | cp -a wiretap/*.h $RPM_BUILD_ROOT%{_includedir}/wiretap |
2bb0e3ef | 264 | |
a53f49c9 | 265 | # plugins *.la are useless - *.so are loaded through gmodule |
3564cfa5 | 266 | rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/plugins/%{version}*/*.la |
a53f49c9 | 267 | |
3d4f4fbf | 268 | # no headers installed for this library |
3564cfa5 | 269 | rm -f $RPM_BUILD_ROOT%{_libdir}/libwireshark.{so,la} |
3d4f4fbf | 270 | |
c06ca841 | 271 | %clean |
272 | rm -rf $RPM_BUILD_ROOT | |
273 | ||
3db19835 ER |
274 | %pre common |
275 | %groupadd -P %{name}-common -g 104 wireshark | |
276 | ||
277 | %post common | |
278 | /sbin/ldconfig | |
279 | /sbin/setcap 'CAP_NET_RAW+eip CAP_NET_ADMIN+eip' %{_bindir}/dumpcap | |
280 | exit 0 | |
281 | ||
282 | %postun common | |
283 | /sbin/ldconfig | |
284 | if [ "$1" = "0" ]; then | |
285 | %groupremove wireshark | |
286 | fi | |
3d4f4fbf JB |
287 | |
288 | %post -n libwiretap -p /sbin/ldconfig | |
289 | %postun -n libwiretap -p /sbin/ldconfig | |
290 | ||
681bd53b JB |
291 | %files |
292 | %defattr(644,root,root,755) | |
3564cfa5 | 293 | %attr(755,root,root) %{_bindir}/wireshark |
681bd53b JB |
294 | %dir %{_libdir}/%{name} |
295 | %dir %{_libdir}/%{name}/plugins | |
3564cfa5 AM |
296 | %dir %{_libdir}/%{name}/plugins/%{version}* |
297 | %attr(755,root,root) %{_libdir}/%{name}/plugins/%{version}*/*.so | |
681bd53b | 298 | %{_datadir}/%{name} |
7bc1a31f | 299 | %{_desktopdir}/%{name}.desktop |
d88a1752 | 300 | %{_pixmapsdir}/*.png |
3564cfa5 | 301 | %{_mandir}/man1/wireshark.1* |
681bd53b | 302 | |
8556fd8d | 303 | %files common |
69177e7d | 304 | %defattr(644,root,root,755) |
b03933b3 | 305 | %doc AUTHORS* ChangeLog NEWS README{,.[lv]*} doc/{randpkt.txt,README.*} |
61c15373 | 306 | %attr(755,root,root) %{_bindir}/capinfos |
7d460fd4 | 307 | %attr(755,root,root) %{_bindir}/dftest |
3db19835 | 308 | %attr(750,root,wireshark) %{_bindir}/dumpcap |
9a51ce65 | 309 | %attr(755,root,root) %{_bindir}/editcap |
7d460fd4 | 310 | %attr(755,root,root) %{_bindir}/mergecap |
7d460fd4 | 311 | %attr(755,root,root) %{_bindir}/randpkt |
38791bb5 JB |
312 | %attr(755,root,root) %{_bindir}/rawshark |
313 | %attr(755,root,root) %{_bindir}/text2pcap | |
9b0cad4e | 314 | %attr(755,root,root) %{_libdir}/libwireshark.so.*.*.* |
b316fa1c | 315 | %attr(755,root,root) %ghost %{_libdir}/libwireshark.so.2 |
b03933b3 | 316 | %attr(755,root,root) %{_libdir}/libwsutil.so.*.*.* |
b316fa1c | 317 | %attr(755,root,root) %ghost %{_libdir}/libwsutil.so.2 |
38791bb5 | 318 | %{_mandir}/man1/capinfos.1* |
b314d27d | 319 | %{_mandir}/man1/dftest.1* |
38791bb5 JB |
320 | %{_mandir}/man1/dumpcap.1* |
321 | %{_mandir}/man1/editcap.1* | |
38791bb5 JB |
322 | %{_mandir}/man1/mergecap.1* |
323 | %{_mandir}/man1/rawshark.1* | |
b314d27d | 324 | %{_mandir}/man1/randpkt.1* |
38791bb5 | 325 | %{_mandir}/man1/text2pcap.1* |
9b0cad4e | 326 | %{_mandir}/man4/wireshark-filter.4* |
9a51ce65 | 327 | |
3564cfa5 | 328 | %files -n twireshark |
5077cd31 | 329 | %defattr(644,root,root,755) |
3564cfa5 | 330 | %attr(755,root,root) %{_bindir}/tshark |
b314d27d | 331 | %{_mandir}/man1/tshark*.1* |
2bb0e3ef | 332 | |
3d4f4fbf | 333 | %files -n libwiretap |
2bb0e3ef | 334 | %defattr(644,root,root,755) |
b89a59b8 | 335 | %doc wiretap/{README*,AUTHORS} |
3d4f4fbf | 336 | %attr(755,root,root) %{_libdir}/libwiretap.so.*.*.* |
b316fa1c | 337 | %attr(755,root,root) %ghost %{_libdir}/libwiretap.so.2 |
3d4f4fbf JB |
338 | |
339 | %files -n libwiretap-devel | |
340 | %defattr(644,root,root,755) | |
341 | %attr(755,root,root) %{_libdir}/libwiretap.so | |
d88a1752 | 342 | %attr(755,root,root) %{_libdir}/libwsutil.so |
3d4f4fbf | 343 | %{_libdir}/libwiretap.la |
5a2627c1 | 344 | %{_libdir}/libwsutil.la |
2bb0e3ef | 345 | %{_includedir}/wiretap |