freebsd-ports/net/nagios/Makefile
Dmitry Sivachenko 49e0e21a44 Add WITH_GD2 knob to use gd2 rather than gd1.
PR:		51287
Submitted by:	"Leonid A. Lyamanov" <leonas@demos.su>
Reviewed by:	maintainer
2003-04-23 10:40:02 +00:00

64 lines
1.8 KiB
Makefile

# New ports collection makefile for: nagios
# Date created: 19 May 2002
# Whom: Blaz Zupan <blaz@si.FreeBSD.org>
#
# $FreeBSD$
#
PORTNAME= nagios
PORTVERSION= 1.0
PORTREVISION= 1
CATEGORIES= net
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR=nagios
MAINTAINER= blaz@si.FreeBSD.org
COMMENT= Extremely powerful network monitoring system
.if defined(WITH_GD2)
LIB_DEPENDS= gd.4:${PORTSDIR}/graphics/gd2
.else
LIB_DEPENDS= gd.2:${PORTSDIR}/graphics/gd
.endif
LIB_DEPENDS+= gnugetopt.1:${PORTSDIR}/devel/libgnugetopt
RUN_DEPENDS= ${LOCALBASE}/libexec/nagios/check_nagios:${PORTSDIR}/net/nagios-plugins
GNU_CONFIGURE= yes
CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \
CFLAGS="${CFLAGS} -I${LOCALBASE}/include" \
LIBS="-L${LOCALBASE}/lib -lgd -lgnugetopt"
CONFIGURE_ARGS= --with-command-user=nagios \
--with-command-grp=www \
--with-nagios-user=nagios \
--with-nagios-grp=nagios \
--with-template-objects \
--with-template-extinfo \
--with-init-dir=${PREFIX}/etc/rc.d \
--sbindir=${PREFIX}/share/nagios/cgi-bin \
--libexecdir=${PREFIX}/libexec/nagios \
--datadir=${PREFIX}/share/nagios \
--sysconfdir=${PREFIX}/etc/nagios \
--localstatedir=/var/spool/nagios \
--prefix=${PREFIX}
.if defined(WITH_MYSQL)
LIB_DEPENDS+= mysqlclient.10:${PORTSDIR}/databases/mysql323-client
CONFIGURE_ARGS+=--with-mysql-lib=${LOCALBASE}/lib/mysql \
--with-mysql-inc=${LOCALBASE}/include/mysql \
--with-mysql-xdata
.endif
.if defined(WITH_POSTGRES)
LIB_DEPENDS+= pq.3:${PORTSDIR}/databases/postgresql7
CONFIGURE_ARGS+=--with-pgsql-lib=${LOCALBASE}/pgsql \
--with-pgsql-inc=${LOCALBASE}/pgsql \
--with-pgsql-xdata
.endif
INSTALL_TARGET= all install config install-config install-daemoninit install-commandmode
pre-install:
@PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
.include <bsd.port.mk>