f8b77d0feb
(minor bugfixes), moves the include files to a ganglia subdirectory to unbreak XFree86-4-clients, and fixes a bug which caused gmond to dump core when started at boot. PR: 52736 Submitted by: brooks
92 lines
2.3 KiB
Makefile
92 lines
2.3 KiB
Makefile
# Ports collection makefile for: ganglia-monitor-core
|
|
# Date created: Wed Jan 23, 2003
|
|
# Whom: Brooks Davis <brooks@freebsd.org>
|
|
#
|
|
# $FreeBSD$
|
|
#
|
|
|
|
PORTNAME= ganglia-monitor-core
|
|
PORTVERSION= 2.5.3
|
|
CATEGORIES= sysutils net parallel
|
|
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
|
|
MASTER_SITE_SUBDIR= ganglia
|
|
.if defined (WITHOUT_GMETAD)
|
|
PKGNAMESUFFIX= -nogmetad
|
|
.endif
|
|
|
|
MAINTAINER= brooks@FreeBSD.org
|
|
COMMENT= "Ganglia cluster monitor, monitoring daemon"
|
|
|
|
.if !defined (WITHOUT_GMETAD)
|
|
LIB_DEPENDS= rrd.0:${PORTSDIR}/net/rrdtool
|
|
.endif
|
|
|
|
GNU_CONFIGURE= yes
|
|
CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \
|
|
LIBS="-L${LOCALBASE}/lib"
|
|
CONFIGURE_ARGS+= --includedir=${PREFIX}/include/ganglia
|
|
.if !defined (WITHOUT_GMETAD)
|
|
CONFIGURE_ARGS+= --with-gmetad
|
|
.endif
|
|
USE_LIBTOOL= yes
|
|
INSTALLS_SHLIB= yes
|
|
.if defined (WITHOUT_GMETAD)
|
|
PLIST_SUB+= GMETAD="@comment "
|
|
.else
|
|
PLIST_SUB+= GMETAD=
|
|
.endif
|
|
USE_REINPLACE= yes
|
|
|
|
MAN1= gmetric.1 gmond.1 gstat.1
|
|
.if !defined (WITHOUT_GMETAD)
|
|
MAN1+= gmetad.1
|
|
.endif
|
|
|
|
CONF_DIR= ${PREFIX}/etc
|
|
RC_DIR= ${PREFIX}/etc/rc.d
|
|
|
|
FIX_CONF_FILES= ${WRKSRC}/lib/ganglia/gmond_config.h \
|
|
${WRKSRC}/mans/gmetad.1 \
|
|
${WRKSRC}/mans/gmond.1 \
|
|
${WRKSRC}/gmetad/cmdline.c \
|
|
${WRKSRC}/gmetad/cmdline.h \
|
|
${WRKSRC}/gmond/cmdline.c \
|
|
${WRKSRC}/gmond/cmdline.h
|
|
FIX_DB_FILES= ${WRKSRC}/gmetad/gmetad.c \
|
|
${WRKSRC}/gmetad/gmetad.conf
|
|
|
|
post-patch:
|
|
${REINPLACE_CMD} -e "s|/etc/\(gm[a-z]*d.conf\)|${CONF_DIR}/\1|g" \
|
|
${FIX_CONF_FILES}
|
|
${REINPLACE_CMD} -e "s|/var/lib/ganglia|/var/db/ganglia|g" \
|
|
${FIX_DB_FILES}
|
|
|
|
# Post-install
|
|
#
|
|
|
|
post-install: install-man install-sample-files install-startup-files
|
|
${SH} pkg-install ${PKGNAME} POST-INSTALL
|
|
|
|
install-man:
|
|
${INSTALL_MAN} ${WRKSRC}/mans/gmetric.1 ${MANPREFIX}/man/man1
|
|
${INSTALL_MAN} ${WRKSRC}/mans/gmond.1 ${MANPREFIX}/man/man1
|
|
${INSTALL_MAN} ${WRKSRC}/mans/gstat.1 ${MANPREFIX}/man/man1
|
|
.if !defined (WITHOUT_GMETAD)
|
|
${INSTALL_MAN} ${WRKSRC}/mans/gmetad.1 ${MANPREFIX}/man/man1
|
|
.endif
|
|
|
|
install-sample-files:
|
|
${INSTALL_DATA} ${WRKSRC}/gmond/gmond.conf \
|
|
${CONF_DIR}/gmond.conf.sample
|
|
.if !defined (WITHOUT_GMETAD)
|
|
${INSTALL_DATA} ${WRKSRC}/gmetad/gmetad.conf \
|
|
${CONF_DIR}/gmetad.conf.sample
|
|
.endif
|
|
|
|
install-startup-files:
|
|
${INSTALL_SCRIPT} ${FILESDIR}/gmond.sh.sample ${RC_DIR}
|
|
.if !defined (WITHOUT_GMETAD)
|
|
${INSTALL_SCRIPT} ${FILESDIR}/gmetad.sh.sample ${RC_DIR}
|
|
.endif
|
|
|
|
.include <bsd.port.mk>
|