2002-03-24 10:32:45 -05:00
|
|
|
# New ports collection makefile for: audit
|
|
|
|
# Date created: 24 March 2002
|
|
|
|
# Whom: anders
|
|
|
|
#
|
|
|
|
# $FreeBSD$
|
|
|
|
#
|
|
|
|
|
|
|
|
PORTNAME= audit
|
|
|
|
PORTVERSION= 1.0
|
2004-02-04 00:10:27 -05:00
|
|
|
PORTREVISION= 2
|
2002-03-24 10:32:45 -05:00
|
|
|
CATEGORIES= security
|
2003-11-09 05:06:00 -05:00
|
|
|
MASTER_SITES= http://www.corest.com/download/audit/ \
|
2002-03-24 10:32:45 -05:00
|
|
|
ftp://ftp.nuug.no/pub/anders/distfiles/
|
|
|
|
DISTNAME= ${PORTNAME}-v${PORTVERSION}beta-src
|
|
|
|
|
|
|
|
MAINTAINER= anders@FreeBSD.org
|
2003-03-07 01:14:21 -05:00
|
|
|
COMMENT= Tools for remote and centralized audit data collection
|
2002-03-24 10:32:45 -05:00
|
|
|
|
|
|
|
.if defined(WITH_MYSQL)
|
|
|
|
LIB_DEPENDS+= mysqlclient.10:${PORTSDIR}/databases/mysql323-client
|
|
|
|
.endif
|
|
|
|
.if defined(WITH_PGSQL)
|
2003-01-04 10:53:39 -05:00
|
|
|
POSTGRESQL_PORT?= databases/postgresql7
|
|
|
|
LIB_DEPENDS+= pq.3:${PORTSDIR}/${POSTGRESQL_PORT}
|
2002-03-24 10:32:45 -05:00
|
|
|
.endif
|
|
|
|
|
|
|
|
WRKSRC= ${WRKDIR}/${PORTNAME}-v${PORTVERSION}beta
|
|
|
|
|
2002-06-30 16:26:07 -04:00
|
|
|
USE_GMAKE= yes
|
2002-11-03 20:30:04 -05:00
|
|
|
USE_REINPLACE= yes
|
2002-06-30 16:26:07 -04:00
|
|
|
|
2002-03-24 10:32:45 -05:00
|
|
|
GNU_CONFIGURE= yes
|
|
|
|
CONFIGURE_ARGS+= --with-audit-libdir=${PREFIX}/lib/alat
|
|
|
|
.if defined(WITH_MYSQL)
|
|
|
|
CONFIGURE_ARGS+= --with-mysql \
|
|
|
|
--with-mysql-libdir=${LOCALBASE}/lib/mysql \
|
|
|
|
--with-mysql-incdir=${LOCALBASE}/include
|
|
|
|
PLIST_SUB+= MYSQL=''
|
|
|
|
.else
|
|
|
|
PLIST_SUB+= MYSQL='@comment '
|
|
|
|
.endif
|
|
|
|
.if defined(WITH_PGSQL)
|
|
|
|
CONFIGURE_ARGS+= --with-pgsql \
|
|
|
|
--with-pgsql-libdir=${LOCALBASE}/lib \
|
|
|
|
--with-pgsql-incdir=${LOCALBASE}/include
|
|
|
|
PLIST_SUB+= PGSQL=''
|
|
|
|
.else
|
|
|
|
PLIST_SUB+= PGSQL='@comment '
|
|
|
|
.endif
|
|
|
|
INSTALLS_SHLIB= yes
|
|
|
|
LDCONFIG_DIRS= %%PREFIX%%/lib/alat
|
|
|
|
MANCOMPRESSED= yes
|
|
|
|
MAN1= audit.1
|
|
|
|
MAN8= auditd.8
|
|
|
|
|
|
|
|
DOCS= COPYING README TODO
|
|
|
|
FIXPREFIX_CONF= src/include/audconf.h src/auditd/auditd.8
|
|
|
|
LIBVERSION= 1
|
|
|
|
|
2004-03-05 07:20:58 -05:00
|
|
|
.include <bsd.port.pre.mk>
|
|
|
|
|
|
|
|
.if ${ARCH} == "amd64"
|
|
|
|
BROKEN= "Does not compile on amd64"
|
|
|
|
.endif
|
|
|
|
|
2002-03-24 10:32:45 -05:00
|
|
|
post-patch:
|
2002-11-03 20:30:04 -05:00
|
|
|
${REINPLACE_CMD} -e "s@Linux@FreeBSD@g" ${WRKSRC}/configure
|
|
|
|
(${FIND} ${WRKSRC}/src/modules -name Makefile.in -exec \
|
|
|
|
${REINPLACE_CMD} -e \
|
2002-11-24 04:03:29 -05:00
|
|
|
"s!^LIB=\(.*\).{VERSION}!LIB=\1${LIBVERSION}!" {} \;)
|
2002-11-03 20:30:04 -05:00
|
|
|
${REINPLACE_CMD} -e "s@AUDIT_VERSION@\"${LIBVERSION}\"@g" \
|
2002-03-24 10:32:45 -05:00
|
|
|
${WRKSRC}/src/lib/modules.c
|
|
|
|
.for f in ${FIXPREFIX_CONF}
|
2002-11-03 20:30:04 -05:00
|
|
|
${REINPLACE_CMD} -e "s@/etc/auditd.conf@${PREFIX}/etc/auditd.conf@g" \
|
2002-03-24 10:32:45 -05:00
|
|
|
${WRKSRC}/${f}
|
|
|
|
.endfor
|
|
|
|
|
|
|
|
post-install:
|
|
|
|
${INSTALL_DATA} ${WRKSRC}/auditd.conf ${PREFIX}/etc/auditd.conf.sample
|
|
|
|
.if !defined(NOPORTDOCS)
|
2002-10-06 20:06:12 -04:00
|
|
|
${INSTALL} -d -o root -g wheel -m 0755 ${DOCSDIR}
|
2002-03-24 10:32:45 -05:00
|
|
|
.for f in ${DOCS}
|
|
|
|
${INSTALL_DATA} ${WRKSRC}/${f} ${DOCSDIR}
|
|
|
|
.endfor
|
|
|
|
.endif
|
|
|
|
|
2004-03-05 07:20:58 -05:00
|
|
|
.include <bsd.port.post.mk>
|