blob: 7484b2c25e3c52decccaaf05e3e819f7d71b0d44 (
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
|
PORTNAME= pwhois
PORTVERSION= 2.2.1.0
PORTREVISION= 1
CATEGORIES= net
MASTER_SITES= http://pwhois.org/get/ \
ZI
MAINTAINER= zi@FreeBSD.org
COMMENT= Whois-compatible framework for disclosing routing data
WWW= https://pwhois.org/
RUN_DEPENDS= p5-DBI>0:databases/p5-DBI \
p5-Time-Format>0:devel/p5-Time-Format \
p5-Log-Dispatch>0:devel/p5-Log-Dispatch \
p5-Net-DNS>0:dns/p5-Net-DNS \
p5-Net-Telnet>0:net/p5-Net-Telnet \
p5-Net-CIDR>0:net-mgmt/p5-Net-CIDR \
p5-RPSL-Parser>0:devel/p5-RPSL-Parser \
${DBD_MYSQL}
FETCH_ARGS= -p
USERS= ${PORTNAME}
GROUPS= ${PORTNAME}
USES= mysql shebangfix tar:tgz
SHEBANG_FILES= pwhois-updatedb
USE_RC_SUBR= ${PORTNAME}d
SUB_FILES= pkg-message 512.pwhois-updatedb
SUB_LIST= TOUCH="${TOUCH}" RM="${RM}" CHOWN="${CHOWN}" \
USER="${USERS}" GROUP="${GROUPS}" INSTALL="${INSTALL}"
post-patch:
@${REINPLACE_CMD} -e 's|/usr/local|${LOCALBASE}|g' \
-e 's|CC = gcc |CC = ${CC}|g' \
${WRKSRC}/Makefile
@${REINPLACE_CMD} -e 's|/etc/pwhois/|${ETCDIR}/|g' \
-e 's|/var/pwhois/|/var/db/pwhois/|g' \
-e 's|/var/log/|/var/log/pwhois/|g' \
-e 's|/var/db/log/|/var/log/pwhois/|g' \
${WRKSRC}/main.c ${WRKSRC}/pwhois-updatedb \
${WRKSRC}/pwhois_pwdump.c ${WRKSRC}/pwhoisd.conf
do-install:
@${MKDIR} ${STAGEDIR}${DATADIR} ${STAGEDIR}${ETCDIR} \
${STAGEDIR}${PREFIX}/etc/periodic/daily
${INSTALL_SCRIPT} ${WRKDIR}/512.pwhois-updatedb \
${STAGEDIR}${PREFIX}/etc/periodic/daily/
${INSTALL_PROGRAM} ${WRKSRC}/pwhoisd ${STAGEDIR}${PREFIX}/sbin/
${INSTALL_PROGRAM} ${WRKSRC}/pwhois-pwdump ${STAGEDIR}${PREFIX}/bin/
${INSTALL_SCRIPT} ${WRKSRC}/pwhois-updatedb ${STAGEDIR}${PREFIX}/sbin/
${INSTALL_DATA} ${WRKSRC}/pwhoisd.conf \
${STAGEDIR}${ETCDIR}/pwhoisd.conf.sample
${INSTALL_DATA} ${WRKSRC}/mysql/createdb.sql ${STAGEDIR}${DATADIR}/
@${MKDIR} ${STAGEDIR}/var/db/pwhois
@${MKDIR} ${STAGEDIR}/var/log/pwhois
.include <bsd.port.mk>
|