summaryrefslogtreecommitdiff
path: root/net/arla/Makefile
blob: 8c08241b7274eaf74ca6d304ae660763fcdc59e4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# $NetBSD: Makefile,v 1.49 2005/12/29 06:21:56 jlam Exp $

DISTNAME=		arla-0.41
#PKGREVISION=		1
CATEGORIES=		net security
MASTER_SITES=		ftp://ftp.stacken.kth.se/pub/arla/

MAINTAINER=		wennmach@NetBSD.org
HOMEPAGE=		http://www.stacken.kth.se/project/arla/
COMMENT=		Free AFS implementation from KTH

CONFLICTS+=		lwp-[0-9]*
CONFLICTS+=		rx-[0-9]*

OSVERSION_SPECIFIC=	yes
INFO_FILES=		arla.info send-pr.info

USE_LIBTOOL=		yes
GNU_CONFIGURE=		yes

DEINSTALL_EXTRA_TMPL+=	${.CURDIR}/DEINSTALL
INSTALL_EXTRA_TMPL+=	${.CURDIR}/INSTALL

.include "../../mk/bsd.prefs.mk"

.if !exists(/usr/src/sys/lib/libkern/libkern.h)
.  if exists(${BSDSRCDIR}/sys/lib/libkern/libkern.h)
CONFIGURE_ARGS+=	--with-sys=${BSDSRCDIR}/sys
.  else
PKG_FAIL_REASON+=	"${PKGNAME} requires kernel sources available under \$$BSDSRCDIR/sys (or //usr/src/sys)"
.  endif
.endif

CONFIGURE_ARGS+=	--sysconfdir=${PKG_SYSCONFDIR:Q}
CONFIGURE_ARGS+=	--with-arlacachedir=${ARLA_CACHE:Q}
CONFIGURE_ARGS+=	--enable-shared=no

# Enable one or more of the following kernel compile options as required:
# (these options must match the compile options of the kernel)
#CONFIGURE_ENV+=	KERNEL_CPPFLAGS="-DMULTIPROCESSOR -DDEBUG -DDIAGNOSTIC"

MESSAGE_SUBST+=		ARLA_CACHE=${ARLA_CACHE}
PLIST_SUBST+=		ARLA_CACHE=${ARLA_CACHE:Q}
FILES_SUBST+=		ARLA_CACHE=${ARLA_CACHE:Q}

EGDIR=		${PREFIX}/share/examples/arla

EGFILES=	CellServDB DynRootDB SuidCells ThisCell arla.conf

.for f in ${EGFILES}
CONF_FILES+=    ${EGDIR}/${f} ${PKG_SYSCONFDIR}/${f}
.endfor

RCD_SCRIPTS=	arlad
OWN_DIRS_PERMS=	${ARLA_CACHE} ${ROOT_USER} ${ROOT_GROUP} 0700

INSTALL_EXTRA_TMPL=	${.CURDIR}/INSTALL
DEINSTALL_EXTRA_TMPL=	${.CURDIR}/DEINSTALL

.include "../../mk/x11.buildlink3.mk"

post-install:
	${RM} -f ${EGDIR}/*.default
	${SED}	${FILES_SUBST_SED}					\
		< ${FILESDIR}/lkm.conf > ${WRKDIR}/lkm.conf
	${INSTALL_DATA} ${WRKDIR}/lkm.conf ${EGDIR}
	${INSTALL_DATA} ${FILESDIR}/fstab ${EGDIR}

.include "../../mk/bsd.pkg.mk"