blob: 0f819cd8451138a5d0622302d621c1e4784741b9 (
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
|
# Whom: Andy Clark <andrewclarkii@gmail.com>
# $FreeBSD$
PORTNAME= nuttcp
PORTVERSION= 6.1.2
CATEGORIES= benchmarks net
MASTER_SITES= ftp://ftp.lcp.nrl.navy.mil/pub/${PORTNAME}/ \
ftp://ftp.lcp.nrl.navy.mil/pub/${PORTNAME}/beta/:beta
DISTFILES= ${DISTNAME}${EXTRACT_SUFX} \
${NUTTSCPDISTFILE}:beta
EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX}
MAINTAINER= andrewclarkii@gmail.com
COMMENT= TCP/UDP network testing tool
USE_BZIP2= yes
MAKEFILE= /dev/null
ALL_TARGET= ${PORTNAME}
MAN8= ${PORTNAME}.8
NUTTSCPVERSION= 1.7
NUTTSCPDISTFILE=nuttscp-${NUTTSCPVERSION}
OPTIONS_DEFINE= NUTTSCP
OPTIONS_DEFAULT= NUTTSCP
NUTTSCP_DESC= Install script for copying files over nuttcp
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MNUTTSCP}
USES+= perl5
PLIST_SUB+= NUTTSCP=""
.else
PLIST_SUB+= NUTTSCP="@comment "
.endif
.include <bsd.port.pre.mk>
post-extract: .SILENT
${CP} ${DISTDIR}/${DIST_SUBDIR}/${NUTTSCPDISTFILE} ${WRKDIR}/nuttscp
post-patch: .SILENT
${FIND} ${WRKSRC}/ -type f -exec \
${REINPLACE_CMD} 's|/usr/local|${PREFIX}|g' {} +
${REINPLACE_CMD} 's|/usr/bin/perl|${PERL}|g' ${WRKDIR}/nuttscp
do-install:
. if ${PORT_OPTIONS:MNUTTSCP}
${INSTALL_SCRIPT} ${WRKDIR}/nuttscp ${PREFIX}/bin/
( cd ${PREFIX}/bin; ${LN} -sf nuttscp nuttrcp )
. endif
${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin/
${INSTALL_MAN} ${WRKSRC}/${PORTNAME}.8 ${MAN8PREFIX}/man/man8/
${MKDIR} ${DATADIR}/
. for file in LICENSE README examples.txt
${INSTALL_DATA} ${WRKSRC}/${file} ${DATADIR}/
. endfor
${MKDIR} ${PREFIX}/etc/xinetd.d/
. for file in ${PORTNAME} ${PORTNAME}4 ${PORTNAME}6
${INSTALL_DATA} ${WRKSRC}/xinetd.d/${file} \
${PREFIX}/etc/xinetd.d/
. endfor
.include <bsd.port.post.mk>
|