aboutsummaryrefslogtreecommitdiffstats
path: root/comms/rtl-sdr/Makefile
blob: dd980b81a60f2ce113d83b69b35a0c3c6aaea70a (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
# New ports collection makefile for:    rtl-sdr
# Date created:     23 August 2012
# Whom:         Ganael Laplanche <ganael.laplanche@martymac.org>
#
# $FreeBSD$
#

PORTNAME=   rtl-sdr
PORTVERSION=    20121104
CATEGORIES= comms hamradio
MASTER_SITES=   http://contribs.martymac.org/FreeBSD-ports/distfiles/ \
        LOCAL/martymac
EXTRACT_SUFX=   .tgz

MAINTAINER= martymac@FreeBSD.org
COMMENT=    Commandline tool that performs SDR with RTL2832-based USB sticks

LICENSE=    GPLv2

USE_PKGCONFIG=  yes
USE_AUTOTOOLS=  autoconf:env aclocal:env automake:env libtool
USE_GMAKE=  yes
GNU_CONFIGURE=  yes
CPPFLAGS+=  -I${LOCALBASE}/include
LDFLAGS+=   -L${LOCALBASE}/lib
USE_LDCONFIG=   yes

DOCSDIR=    ${PREFIX}/share/doc/librtlsdr

.include <bsd.port.pre.mk>

.if ${OSVERSION} < 800069
IGNORE= requires FreeBSD 8.0 or later
.endif

.if ${PORT_OPTIONS:MDOCS}
BUILD_DEPENDS+= doxygen:${PORTSDIR}/devel/doxygen
.else
EXTRA_PATCHES+= ${FILESDIR}/extra-patch-Makefile.am
.endif

post-patch:
    @${REINPLACE_CMD} 's|^pkgdocdir=.*|pkgdocdir=${DOCSDIR}|' \
        ${WRKSRC}/Makefile.am
    @${REINPLACE_CMD} 's|^pkgconfigdir =.*|pkgconfigdir = ${PREFIX}/libdata/pkgconfig|' \
        ${WRKSRC}/Makefile.am

pre-configure:
    @(cd ${WRKSRC} && ${AUTORECONF} -fi)

.include <bsd.port.post.mk>