summaryrefslogtreecommitdiff
path: root/sysutils/radmind/Makefile
blob: 2aebe9c5d8f487b18081e7e7eb37382c98981bf9 (plain) (blame)
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
# Created by: Paul Dlug <paul@aps.org>
# $FreeBSD$

PORTNAME=	radmind
PORTVERSION=	1.14.1
PORTREVISION=	2012032001
CATEGORIES=	sysutils
MASTER_SITES=	SF
MASTER_SITE_SUBDIR=${PORTNAME}/${PORTNAME}/${PORTNAME}-${PORTVERSION}

MAINTAINER=	mikeg@bsd-box.net
COMMENT=	Utility for administering filesystem changes

USE_OPENSSL=	yes
USE_RC_SUBR=	radmind
MAKE_JOBS_UNSAFE=	yes

GNU_CONFIGURE=	yes
CONFIGURE_ARGS=	--with-radminddir=${RADMIND_BASE_DIR}

RADMINUSER=	radmind
USERS=		${RADMINUSER}
GROUPS=		${RADMINUSER}
RADMIND_BASE_DIR?=	/var/radmind

SUB_LIST=	RADMIND_BASE_DIR=${RADMIND_BASE_DIR} RADMINUSER=${RADMINUSER}
PLIST_SUB=	RADMIND_BASE_DIR=${RADMIND_BASE_DIR} RADMINUSER=${RADMINUSER}
SUB_FILES+=	pkg-install pkg-message

MAN1=		fsdiff.1 ktcheck.1 lapply.1 lcksum.1 lcreate.1 lfdiff.1 \
		lmerge.1 lsort.1 twhich.1 rash.1 repo.1
MAN5=		applefile.5
MAN8=		radmind.8
DOCS=		COPYRIGHT README SPEC

OPTIONS_DEFINE=	IGNORE_TIMESTAMPS DOCS
IGNORE_TIMESTAMPS_DESC=	Add '-t' option to fsdiff

.include <bsd.port.options.mk>

.if ${PORT_OPTIONS:MIGNORE_TIMESTAMPS}
EXTRA_PATCHES+=	${FILESDIR}/optpatch-ignore_timestamps
.endif

post-install:
# Ugly hack to remove generated man pages
	${RM} -rf ${WRKSRC}/tmp

.if ${PORT_OPTIONS:MDOCS}
	${MKDIR} ${DOCSDIR}
	cd ${WRKSRC} && ${INSTALL_DATA} ${DOCS} ${DOCSDIR}
.endif
	${CP} ${FILESDIR}/config.sample ${RADMIND_BASE_DIR}/config.sample
	@if [ ! -f ${RADMIND_BASE_DIR}/config ]; then \
		${CP} -p ${RADMIND_BASE_DIR}/config.sample ${RADMIND_BASE_DIR}/config ; \
	fi
	@${CHOWN} -R ${RADMINUSER}:${RADMINUSER} ${RADMIND_BASE_DIR}
	@${CAT} ${PKGMESSAGE}

.include <bsd.port.mk>