aboutsummaryrefslogtreecommitdiffstats
path: root/net-mgmt/kismet/Makefile
blob: 67ff184d1f59d6909e7144c67c9c0d35cb22ee61 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
# New ports collection makefile for:    kismet
# Date created:         3 May 2004
# Whom:                 Thomas Spreng <spreng@socket.ch>
#
# $FreeBSD$
#

PORTNAME=   kismet
PORTVERSION=    200508.r1
PORTREVISION=   1
CATEGORIES= net-mgmt
MASTER_SITES=   http://www.kismetwireless.net/code/
DISTNAME=   kismet-2005-08-R1

MAINTAINER= eol1@yahoo.com
COMMENT=    802.11 layer2 wireless network detector, sniffer, and IDS

GNU_CONFIGURE=  yes
USE_GMAKE=  yes
USE_REINPLACE=  yes
CONFIGURE_ENV=  CPPFLAGS="-I${LOCALBASE}/include ${PTHREAD_CFLAGS}" \
        LIBS="-L${LOCALBASE}/lib ${PTHREAD_LIBS}"
CONFIGURE_ARGS+=    --enable-syspcap

OPTIONS=    CURSES "libcurses interface" on \
        PANEL "libpanels interface" on \
        SETUID "Install kismet with setuid" on \
        GPSMAP "Build gpsmap utility" on

.include <bsd.port.pre.mk>

.if defined(WITHOUT_CURSES)
CONFIGURE_ARGS+=--disable-curses
.endif

.if defined(WITHOUT_PANEL)
CONFIGURE_ARGS+=--disable-panel
.endif

.if defined(WITHOUT_SETUID)
CONFIGURE_ARGS+=--disable-setuid
.endif

.if defined(WITHOUT_GPSMAP)
CONFIGURE_ARGS+=--disable-gpsmap
PLIST_SUB+= GPS="@comment "
.else
PLIST_SUB+= GPS=""
LIB_DEPENDS+=   gmp.6:${PORTSDIR}/math/libgmp4 \
        expat.6:${PORTSDIR}/textproc/expat2 \
        Magick++.9:${PORTSDIR}/graphics/ImageMagick
BUILD_DEPENDS+= wget:${PORTSDIR}/ftp/wget
RUN_DEPENDS+=   wget:${PORTSDIR}/ftp/wget
.endif

MAN1=       kismet.1 kismet_drone.1 gpsmap.1
MAN5=       kismet.conf.5 kismet_drone.conf.5 kismet_ui.conf.5

.if ${OSVERSION} < 502000
CONFIGURE_ARGS+=    --disable-pcap
.endif

post-extract:
    @${REINPLACE_CMD} -e 's|-lpthread|${PTHREAD_LIBS}|g' \
        ${WRKSRC}/configure

post-install:
    ${INSTALL_DATA} ${WRKSRC}/conf/kismet.conf ${PREFIX}/etc/kismet.conf.sample
    ${INSTALL_DATA} ${WRKSRC}/conf/kismet_drone.conf ${PREFIX}/etc/kismet_drone.conf.sample
    ${INSTALL_DATA} ${WRKSRC}/conf/kismet_ui.conf ${PREFIX}/etc/kismet_ui.conf.sample

.include <bsd.port.post.mk>