Fixup fromcvs/togit conversion
[minix-pkgsrc.git] / pkgtools / tinderbox-dragonfly / Makefile
blob7fc8b69e29a97a93a7d12b560ae6dab1a66aa3c0
1 # $NetBSD: Makefile,v 1.10 2013/03/02 20:33:32 wiz Exp $
4 DISTNAME= tinderbox-dragonfly-${TBOX_VERSION}
5 PKGREVISION= 6
6 CATEGORIES= pkgtools
7 MASTER_SITES= http://tinderbox.marcuscom.com/
8 DISTFILES= tinderbox-${TBOX_VERSION}.tar.gz
10 MAINTAINER= draco@marino.st
11 HOMEPAGE= http://tinderbox.marcuscom.com/
12 COMMENT= Tinderbox package building system (pkgsrc)
13 LICENSE= modified-bsd
15 DEPENDS+= p5-Compress-Bzip2>=2:../../archivers/p5-Compress-Bzip2
16 DEPENDS+= csup>=20100101:../../net/csup
17 DEPENDS+= scmgit>1.6:../../devel/scmgit
19 TBOX_VERSION= 3.4.1
20 ONLY_FOR_PLATFORM= DragonFly-*-*
22 USE_TOOLS+= perl perl:run
23 NO_CONFIGURE= yes
24 NO_BUILD= yes
25 RCD_SCRIPTS= tinderd
26 WRKSRC= ${WRKDIR}/tinderbox-${TBOX_VERSION}
27 TRASH= ${WRKDIR}/trash
28 MAN_FILES_cmd= ${SED} -ne "s,^man/man1/,,p" PLIST
29 MAN_FILES= ${MAN_FILES_cmd:sh}
31 INSTALLATION_DIRS+= tinderbox/scripts
32 INSTALLATION_DIRS+= ${PKGMANDIR}/man1
34 SUBST_CLASSES+= paths
35 SUBST_FILES.paths+= contrib/bulk/add_all_packages.sh
36 SUBST_FILES.paths+= contrib/bulk/bulk_hook_1.sh
37 SUBST_FILES.paths+= contrib/bulk/bulkbuild.sh
38 SUBST_SED.paths+= -e 's,@TINROOT@,${PREFIX}/tinderbox,g'
39 SUBST_STAGE.paths= post-patch
41 .include "options.mk"
43 post-extract:
44 ${MKDIR} ${TRASH}
45 .if empty(PKG_OPTIONS:Mwebui)
46 mv ${WRKSRC}/webui ${TRASH}
47 .endif
48 mv ${WRKSRC}/etc/rc.d ${TRASH}
49 ${MKDIR} ${WRKSRC}/contrib/bulk
50 for dossier in add_all_packages bulk_hook_1 bulkbuild; do \
51 ${CP} ${FILESDIR}/$${dossier}.sh.in \
52 ${WRKSRC}/contrib/bulk/$${dossier}.sh; \
53 done
54 chmod 755 ${WRKSRC}/contrib/bulk/*
56 post-patch:
57 .if !empty(PKG_OPTIONS:Manybody)
58 perl -i -pe 's/^if \[ `id -u` != 0 \]; then/if false; then/' \
59 ${WRKSRC}/tc
60 .endif
61 cd ${WRKSRC} && ${FIND} -E . -regex '.*(orig|bak)' -exec ${RM} {} \;
63 do-install:
64 for manual in ${MAN_FILES}; do \
65 ${INSTALL_MAN} ${WRKSRC}/man/man1/$${manual} ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1; \
66 done
67 mv ${WRKSRC}/man ${TRASH}
68 cd ${WRKSRC}; for dossier in .version *; do \
69 ${TEST} ! -f "$$dossier" || \
70 ${CP} "$$dossier" ${DESTDIR}${PREFIX}/tinderbox/scripts; \
71 ${TEST} ! -d "$$dossier" || \
72 ${CP} -R "$$dossier" ${DESTDIR}${PREFIX}/tinderbox/scripts; \
73 done
75 .include "../../mk/bsd.pkg.mk"