]> git.pld-linux.org Git - packages/kismet.git/blob - kismet.spec
- Up to the latest version 2011-03-R2.
[packages/kismet.git] / kismet.spec
1 # TODO
2 #  - Anybody knows, why it will not build, when kernel-headers are installed?
3 #
4 %define         tarver  %(echo %{version} | tr _ -)
5 Summary:        Wireless network sniffer
6 Summary(pl.UTF-8):      Sniffer sieci bezprzewodowych
7 Name:           kismet
8 Version:        2011_03_R2
9 Release:        0.1
10 License:        GPL
11 Group:          Networking/Utilities
12 Source0:        http://www.kismetwireless.net/code/%{name}-%{tarver}.tar.gz
13 # Source0-md5:  8bf077e8111e6dc8c12cadefdf40aadd
14 Patch0:         config.patch
15 URL:            http://www.kismetwireless.net/
16 BuildRequires:  autoconf
17 BuildRequires:  automake
18 BuildRequires:  bluez-libs-devel
19 BuildRequires:  gmp-devel
20 BuildRequires:  libcap-devel
21 BuildRequires:  libnl-devel
22 BuildRequires:  libpcap-devel >= 2:0.9.4-1
23 BuildRequires:  libstdc++-devel
24 BuildRequires:  ncurses-ext-devel
25 BuildRequires:  openssl-devel
26 BuildRequires:  pcre-devel
27 BuildRequires:  pkgconfig
28 BuildRequires:  sed >= 4.0
29 Suggests:       %{name}-server
30 # it uses internal structures - so strict deps
31 %requires_eq    libpcap
32 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33
34 %define         plugins plugin-autowep plugin-btscan plugin-ptw plugin-spectools
35
36 %description
37 Kismet is a 802.11b wireless network sniffer. It is capable of
38 sniffing using almost any wireless card supported in Linux, including
39 Prism2 based cards supported by the Wlan-NG project (Linksys, Dlink,
40 Rangelan, etc), cards which support standard packet capture via
41 libpcap (Cisco), and limited support for cards without RF Monitor
42 support.
43
44 %description -l pl.UTF-8
45 Kismet to sniffer bezprzewodowych sieci 802.11b. Jest zdolny do
46 sniffowania używając prawie dowolnych bezprzewodowych kart sieciowych
47 w Linuksie włączając w to karty Prism2 wspierane przez projekt Wlan-NG
48 (Linksys, Dlink, Rangelan, etc), kart które umożliwiają
49 przechwytywanie pakietów poprzez libpcap (Cisco), oraz ograniczone
50 wsparcie dla kart bez obsługi Monitora RF.
51
52 %package server
53 Summary:        Server for Kismet
54 Group:          Networking/Daemons
55 Requires(postun):       /usr/sbin/groupdel
56 Requires(pre):  /usr/sbin/groupadd
57 Provides:       group(kismet)
58
59 %description server
60 This package contains kismet_server which you can access with kismet
61 protocol compatible clients.
62
63 %prep
64 %setup -q -n %{name}-%{tarver}
65 %patch0 -p1
66
67 # make lib64 aware, include exec bits on install
68 %{__sed} -i -e 's!\$(prefix)/lib/!%_libdir/!g' plugin-*/Makefile
69 %{__sed} -i -e '/install/ s!-m644!-m755!' plugin-*/Makefile
70
71 # make %doc friendly
72 for a in plugin-*/README; do
73         mv $a README.${a%/README}
74 done
75
76 %build
77 cp -f /usr/share/automake/config.* .
78 %{__aclocal}
79 %{__autoconf}
80 %configure
81
82 %{__make} \
83         CLIENTLIBS="-ldl -lncurses -lpanel -ltinfo"  # hack to add -ltinfo
84
85 for plugin in %plugins; do
86         %{__make} -C $plugin \
87                 KIS_SRC_DIR=$PWD
88 done
89
90 %install
91 rm -rf $RPM_BUILD_ROOT
92 install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_bindir},%{_datadir},/var/log/%{name}}
93 for dir in . %plugins; do
94         %{__make} -C $dir install \
95                 DESTDIR="$RPM_BUILD_ROOT" \
96                 KIS_SRC_DIR=$PWD \
97                 INSTUSR=%(id -un) \
98                 INSTGRP=%(id -gn) \
99                 MANGRP=%(id -gn)
100 done
101
102 # do what binsuidinstall would do
103 install -p kismet_capture $RPM_BUILD_ROOT%{_bindir}
104
105 %clean
106 rm -rf $RPM_BUILD_ROOT
107
108 %pre server
109 %groupadd -P %{name}-server -g 180 kismet
110
111 %preun server
112 if [ "$1" = "0" ]; then
113         %groupremove kismet
114 fi
115
116 %files
117 %defattr(644,root,root,755)
118 %doc docs/* CHANGELOG README README.plugin-*
119 %attr(755,root,root) %{_bindir}/kismet
120 %attr(755,root,root) %{_bindir}/kismet_client
121 %{_datadir}/%{name}
122 %{_mandir}/man1/kismet.1*
123 %{_mandir}/man1/kismet_drone.1*
124 %dir %{_libdir}/kismet_client
125 %attr(755,root,root) %{_libdir}/kismet_client/btscan_ui.so
126 %attr(755,root,root) %{_libdir}/kismet_client/spectools_ui.so
127
128 %files server
129 %defattr(644,root,root,755)
130 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/kismet.conf
131 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/kismet_drone.conf
132 %attr(4750,root,kismet) %{_bindir}/kismet_capture
133 %attr(755,root,root) %{_bindir}/kismet_drone
134 %attr(755,root,root) %{_bindir}/kismet_server
135 %{_mandir}/man5/kismet.conf.5*
136 %{_mandir}/man5/kismet_drone.conf.5*
137 %dir %{_libdir}/kismet
138 %attr(755,root,root) %{_libdir}/kismet/aircrack-kismet.so
139 %attr(755,root,root) %{_libdir}/kismet/autowep-kismet.so
140 %attr(755,root,root) %{_libdir}/kismet/btscan.so
141 %attr(755,root,root) %{_libdir}/kismet/spectool_net.so
142 %dir %attr(770,root,kismet) /var/log/%{name}
This page took 0.061044 seconds and 3 git commands to generate.