summaryrefslogtreecommitdiff
path: root/sysutils/dirvish/Makefile
blob: 06cdc3330c08eeba80c1b69ffa4fb1454a3ccec3 (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
# $NetBSD: Makefile,v 1.5 2009/06/09 17:34:50 abs Exp $
#

DISTNAME=	dirvish-1.2.1
CATEGORIES=	sysutils
MASTER_SITES=	http://www.dirvish.org/
EXTRACT_SUFX=	.tgz

MAINTAINER=	pkgsrc-users@NetBSD.org
HOMEPAGE=	http://www.dirvish.org/
COMMENT=	Fast, disk based, rotating network backup system

DEPENDS+=	rsync>=2.6.0:../../net/rsync
DEPENDS+=	p5-Getopt-Long>=2.35:../../devel/p5-Getopt-Long
DEPENDS+=	p5-Time-modules>=2003.0:../../time/p5-Time-modules
DEPENDS+=	p5-Time-Period>=1.0:../../time/p5-Time-Period

PKG_SYSCONFSUBDIR=	dirvish
PKG_DESTDIR_SUPPORT=	user-destdir

EXECUTABLES=	dirvish dirvish-runall dirvish-expire dirvish-locate
MAN5=		dirvish.conf.5
MAN8=		dirvish.8 dirvish-runall.8 dirvish-expire.8 \
		dirvish-locate.8
DOCS=		COPYING FAQ.html INSTALL RELEASE.html TODO.html

INSTALLATION_DIRS=	${PKGMANDIR}/man5 ${PKGMANDIR}/man8 sbin \
			share/doc/dirvish

do-build:
	cd ${WRKSRC}; \
	for f in ${EXECUTABLES}; do \
        	${ECHO} "#!${PERL5}" > $$f; \
        	${ECHO} "\$$CONFDIR = \"${PKG_SYSCONFDIR}\";" >> $$f; \
        	${CAT} $$f.pl >>$$f; \
	        ${CAT} loadconfig.pl >>$$f; \
	done

do-install:
	for f in ${EXECUTABLES}; do \
		${INSTALL_SCRIPT} ${WRKSRC}/$$f ${DESTDIR}${PREFIX}/sbin; \
	done
	for f in ${MAN5}; do \
		${INSTALL_MAN} ${WRKSRC}/$$f \
			${DESTDIR}${PREFIX}/${PKGMANDIR}/man5; \
	done
	for f in ${MAN8}; do \
		${INSTALL_MAN} ${WRKSRC}/$$f \
			${DESTDIR}${PREFIX}/${PKGMANDIR}/man8; \
	done
	for f in ${DOCS}; do \
		${INSTALL_DATA} ${WRKSRC}/$$f \
			${DESTDIR}${PREFIX}/share/doc/dirvish; \
	done

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