# New ports collection makefile for:	arla
# Date created:				2008-01-18
# Whom:					Alec Kloss <alec@setfilepointer.com>
#
# $FreeBSD$
#

PORTNAME=	arla
PORTVERSION=	20080301
CATEGORIES=	net
MASTER_SITES=	http://setfilepointer.com/pub/arla/ \
		ftp://ftp.stacken.kth.se/pub/arla/
PKGNAMESUFFIX=  -devel

MAINTAINER=	alec@setfilepointer.com
COMMENT=	AFS client implementation from http://www.stacken.kth.se/project/arla/

CONFLICTS=  arla-[0-9]*
LIB_DEPENDS=	krb5.23:${PORTSDIR}/security/heimdal \
		readline.5:${PORTSDIR}/devel/readline

USE_LDCONFIG=	yes

USE_BZIP2=	yes
HAS_CONFIGURE=	yes

.include <bsd.port.pre.mk>

.if ${OSVERSION} < 600000
IGNORE=Only supported on 6.x and later.
.endif

.if ! defined(ARLAPREFIX)
ARLAPREFIX=$(PREFIX)/arla
.endif

.if ! defined(FREEBSD_SYS)
FREEBSD_SYS=/sys
.endif

.if ! defined(HEIMDAL_HOME)
HEIMDAL_HOME=	${PREFIX}
.endif

.if ! defined(READLINE_HOME)
READLINE_HOME=	${PREFIX}
.endif

.if ! defined(ARLACACHEDIR)
ARLACACHEDIR=	/var/cache/arla
.endif

.if defined(WITHOUT_X11)
ARLA_WITHOUT_X_FLAG=	--without-x
.endif

CONFIGURE_ARGS=	--prefix=${ARLAPREFIX} \
			--sysconfdir=${PREFIX}/etc \
			--datarootdir=${PREFIX}/share \
			--infodir=${PREFIX}/${INFO_PATH} \
			--mandir=${MANPREFIX}/man \
			--with-arlacachedir=${ARLACACHEDIR} \
			--with-sys=${FREEBSD_SYS} \
			--with-krb5=${HEIMDAL_HOME} \
			--with-readline=${READLINE_HOME} \
			$(ARLA_WITHOUT_X_FLAG)

MAN1=	rxdebug.1 tokens.1 unlog.1 afstool.1 pts.1 udebug.1 arla-send-pr.1
MAN3=	log_log.3 log_vlog.3 log_open.3 log_close.3 log_unit_init.3 log_unit_free.3 log_set_mask.3 log_get_mask.3 log_mask2str.3 log_set_mask_str.3
MAN4=	nnpfs.4
MAN5=	AliasDB.5 CellServDB.5 DynRootDB.5 SuidCells.5 ThisCell.5 arla.conf.5
MAN8=	mount_nnpfs.8 umount_nnpfs.8 arlad.8 arla-cli.8 vos.8
INFO=	arla send-pr

.include <bsd.port.post.mk>
