forked from Lainports/freebsd-ports
It has been common practice to have one or more URLs at the end of the ports' pkg-descr files, one per line and prefixed with "WWW:". These URLs should point at a project website or other relevant resources. Access to these URLs required processing of the pkg-descr files, and they have often become stale over time. If more than one such URL was present in a pkg-descr file, only the first one was tarnsfered into the port INDEX, but for many ports only the last line did contain the port specific URL to further information. There have been several proposals to make a project URL available as a macro in the ports' Makefiles, over time. This commit implements such a proposal and moves one of the WWW: entries of each pkg-descr file into the respective port's Makefile. A heuristic attempts to identify the most relevant URL in case there is more than one WWW: entry in some pkg-descr file. URLs that are not moved into the Makefile are prefixed with "See also:" instead of "WWW:" in the pkg-descr files in order to preserve them. There are 1256 ports that had no WWW: entries in pkg-descr files. These ports will not be touched in this commit. The portlint port has been adjusted to expect a WWW entry in each port Makefile, and to flag any remaining "WWW:" lines in pkg-descr files as deprecated. Approved by: portmgr (tcberner)
101 lines
3.3 KiB
Makefile
101 lines
3.3 KiB
Makefile
PORTNAME= logcheck
|
|
DISTVERSION= 1.3.24
|
|
CATEGORIES= security
|
|
MASTER_SITES= DEBIAN_POOL
|
|
DISTNAME= ${PORTNAME}_${PORTVERSION}
|
|
|
|
MAINTAINER= yasu@FreeBSD.org
|
|
COMMENT= Auditing tool for system logs on Unix boxes
|
|
WWW= https://salsa.debian.org/debian/logcheck
|
|
|
|
LICENSE= GPLv2+
|
|
LICENSE_FILE= ${WRKSRC}/LICENSE
|
|
|
|
BUILD_DEPENDS= docbook-to-man>0:textproc/docbook-to-man
|
|
RUN_DEPENDS= bash:shells/bash \
|
|
lockfile-create:sysutils/lockfile-progs \
|
|
mime-construct:mail/mime-construct
|
|
|
|
# Enable Perl dependency for logtail script
|
|
USES= perl5 shebangfix tar:xz
|
|
SHEBANG_FILES= src/detectrotate/*.dtr src/logcheck src/logtail src/logtail2
|
|
BINMODE= 755
|
|
SUB_FILES= pkg-deinstall pkg-install pkg-message
|
|
SUB_LIST+= CRON=${PORT_OPTIONS:MCRON} \
|
|
DBDIR=${DBDIR} \
|
|
LOGCHECK_GROUP=${LOGCHECK_GROUP} \
|
|
LOGCHECK_USER=${LOGCHECK_USER}
|
|
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}
|
|
USERS= ${LOGCHECK_USER}
|
|
GROUPS= ${LOGCHECK_GROUP}
|
|
PLIST_SUB+= CHGRP=${CHGRP} \
|
|
CHMOD=${CHMOD} \
|
|
DBDIR=${DBDIR} \
|
|
FIND=${FIND} \
|
|
LOGCHECK_GROUP=${LOGCHECK_GROUP} \
|
|
LOGCHECK_USER=${LOGCHECK_USER} \
|
|
RUNDIR=${RUNDIR}
|
|
PORTDOCS= ${DOCS:T}
|
|
|
|
OPTIONS_DEFINE= CRON DOCS EXAMPLES
|
|
OPTIONS_DEFAULT= CRON
|
|
CRON_DESC= Install cron script automatically
|
|
|
|
# None. portlint compliance
|
|
BASEDIR?=
|
|
CONFIG_DIRS= cracking.d ignore.d.paranoid ignore.d.server \
|
|
ignore.d.workstation violations.d violations.ignore.d
|
|
DBDIR= ${BASEDIR}/var/db/${PORTNAME}
|
|
DOCS= AUTHORS CHANGES CREDITS TODO docs/README*
|
|
LOGCHECK_GROUP= ${LOGCHECK_USER}
|
|
LOGCHECK_USER= logcheck
|
|
MAN1_FILES= logcheck-test.1
|
|
MAN8_FILES= logcheck.8 logtail.8 logtail2.8
|
|
REINPLACE_FILES= debian/logcheck.cron.d docs/logcheck.sgml \
|
|
docs/logtail2.8 docs/README.logcheck \
|
|
docs/README.logcheck-database docs/README.logtail \
|
|
etc/logcheck.conf src/logcheck src/logtail2
|
|
RUNDIR= ${BASEDIR}/var/run/${PORTNAME}
|
|
|
|
.include <bsd.port.pre.mk>
|
|
|
|
do-build:
|
|
.for file in ${REINPLACE_FILES}
|
|
${REINPLACE_CMD} ${_SUB_LIST_TEMP} ${WRKSRC}/${file}
|
|
.endfor
|
|
docbook-to-man ${WRKSRC}/docs/logcheck.sgml > ${WRKSRC}/docs/logcheck.8
|
|
${FIND} ${WRKSRC} -type f \( -name \*.orig -o -name \*.bak \) -delete
|
|
|
|
do-install:
|
|
@${MKDIR} ${STAGEDIR}${DATADIR}/detectrotate \
|
|
${STAGEDIR}${DBDIR} \
|
|
${STAGEDIR}${DOCSDIR} \
|
|
${STAGEDIR}${ETCDIR} \
|
|
${STAGEDIR}${EXAMPLESDIR} \
|
|
${STAGEDIR}${RUNDIR}
|
|
${INSTALL_SCRIPT} ${WRKSRC}/src/logcheck-test ${STAGEDIR}${PREFIX}/bin
|
|
${INSTALL_SCRIPT} ${WRKSRC}/src/logcheck ${STAGEDIR}${PREFIX}/sbin
|
|
${INSTALL_SCRIPT} ${WRKSRC}/src/logtail ${STAGEDIR}${PREFIX}/sbin
|
|
${INSTALL_SCRIPT} ${WRKSRC}/src/logtail2 ${STAGEDIR}${PREFIX}/sbin
|
|
${INSTALL_DATA} ${WRKSRC}/etc/logcheck.conf \
|
|
${STAGEDIR}${ETCDIR}/logcheck.conf.sample
|
|
${INSTALL_DATA} ${WRKSRC}/etc/logcheck.logfiles \
|
|
${STAGEDIR}${ETCDIR}/logcheck.logfiles.sample
|
|
.for i in ${CONFIG_DIRS}
|
|
@${MKDIR} ${STAGEDIR}${ETCDIR}/${i}
|
|
${INSTALL_DATA} ${WRKSRC}/rulefiles/linux/${i}/* \
|
|
${STAGEDIR}${ETCDIR}/${i}
|
|
.endfor
|
|
${INSTALL_DATA} ${WRKSRC}/src/detectrotate/*.dtr \
|
|
${STAGEDIR}${DATADIR}/detectrotate
|
|
${INSTALL_DATA} ${WRKSRC}/debian/logcheck.cron.d \
|
|
${STAGEDIR}${EXAMPLESDIR}/crontab.in
|
|
.for i in ${MAN1_FILES}
|
|
${INSTALL_MAN} ${WRKSRC}/docs/$i ${STAGEDIR}${MAN1PREFIX}/man/man1
|
|
.endfor
|
|
.for i in ${MAN8_FILES}
|
|
${INSTALL_MAN} ${WRKSRC}/docs/$i ${STAGEDIR}${MAN8PREFIX}/man/man8
|
|
.endfor
|
|
cd ${WRKSRC} && ${INSTALL_DATA} ${DOCS} ${STAGEDIR}${DOCSDIR}
|
|
|
|
.include <bsd.port.post.mk>
|