# New ports collection makefile for:   cactid
# Date created:        Feb 26 2005
# Whom:                clement@FreeBSD.org
#
# $FreeBSD: ports/net/cactid/Makefile,v 1.13 2007/02/28 01:19:03 kuriyama Exp $
#

PORTNAME=	cactid
PORTVERSION=	0.8.6.i
PORTREVISION=	1
CATEGORIES=	net
MASTER_SITES=	http://www.cacti.net/downloads/cactid/
DISTNAME=	cacti-${PORTNAME}-0.8.6i

MAINTAINER=	clement@FreeBSD.org
COMMENT=	A multithreaded poller for Cacti written in C

LIB_DEPENDS=	netsnmp.10:${PORTSDIR}/net-mgmt/net-snmp

GNU_CONFIGURE=	YES
CONFIGURE_ARGS+=--with-mysql=${LOCALBASE} --with-snmp=${LOCALBASE}
USE_MYSQL=	YES
USE_OPENSSL=	YES

post-patch:
	@${REINPLACE_CMD} 's,%%PREFIX%%,${PREFIX},' \
		${WRKSRC}/cactid.h

do-install:
	@${INSTALL_PROGRAM} ${WRKSRC}/cactid ${PREFIX}/bin
	@${MKDIR} ${EXAMPLESDIR}
	@${INSTALL_DATA} ${WRKSRC}/cactid.conf ${EXAMPLESDIR}
	@[ -e ${PREFIX}/etc/cactid.conf ] || \
		${INSTALL_DATA} ${EXAMPLESDIR}/cactid.conf ${PREFIX}/etc/
.include <bsd.port.mk>


syntax highlighted by Code2HTML, v. 0.9.1