aboutsummaryrefslogtreecommitdiff
path: root/sysutils/zfsnap2/Makefile
diff options
context:
space:
mode:
authorMartin Matuska <mm@FreeBSD.org>2016-06-30 09:00:05 +0000
committerMartin Matuska <mm@FreeBSD.org>2016-06-30 09:00:05 +0000
commit2bbc785c4a80e70f6f35e6c8e67fc5214e0ec9cd (patch)
tree9d7a2221b910c0a092cde884a511ced6ea8b9161 /sysutils/zfsnap2/Makefile
parent59a6688fc82da808025e38be7811ec1155e74435 (diff)
downloadports-2bbc785c4a80e70f6f35e6c8e67fc5214e0ec9cd.tar.gz
ports-2bbc785c4a80e70f6f35e6c8e67fc5214e0ec9cd.zip
Notes
Diffstat (limited to 'sysutils/zfsnap2/Makefile')
-rw-r--r--sysutils/zfsnap2/Makefile51
1 files changed, 51 insertions, 0 deletions
diff --git a/sysutils/zfsnap2/Makefile b/sysutils/zfsnap2/Makefile
new file mode 100644
index 000000000000..4ec13882ab9c
--- /dev/null
+++ b/sysutils/zfsnap2/Makefile
@@ -0,0 +1,51 @@
+# Created by: Martin Matuska <mm@FreeBSD.org>
+# $FreeBSD$
+
+PORTNAME= zfsnap
+DISTVERSIONPREFIX= v
+DISTVERSION= 2.0.0-beta2
+CATEGORIES= sysutils
+PKGNAMESUFFIX= 2
+
+MAINTAINER= mm@FreeBSD.org
+COMMENT= Portable performant script to make rolling ZFS snapshots easy
+
+LICENSE= BSD3CLAUSE
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+NO_BUILD= yes
+USE_GITHUB= yes
+GH_TAGNAME= af91bd21c848751176ccce0ae314e3c0feb75cc5
+
+OPTIONS_DEFINE= BASH ZSH
+OPTIONS_DEFAULT= BASH ZSH
+OPTIONS_SUB= yes
+
+PORTDOCS= AUTHORS NEWS PORTABILITY README.md
+
+post-patch:
+ @${REINPLACE_CMD} -e "s,# ZFSNAP_LIB_DIR=.*,ZFSNAP_LIB_DIR=${PREFIX}/share/zfsnap,g" ${WRKSRC}/sbin/zfsnap.sh
+
+do-install:
+ ${INSTALL_SCRIPT} ${WRKSRC}/sbin/zfsnap.sh ${STAGEDIR}${PREFIX}/sbin/zfsnap
+ cd ${WRKSRC}/share && ${COPYTREE_SHARE} . ${STAGEDIR}${PREFIX}/share
+ ${INSTALL_MAN} ${WRKSRC}/man/man8/zfsnap.8 ${STAGEDIR}${MAN8PREFIX}/man/man8/zfsnap.8
+ ${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
+ cd ${WRKSRC} && ${COPYTREE_SHARE} completion ${STAGEDIR}${EXAMPLESDIR}
+ cd ${WRKSRC} && ${COPYTREE_SHARE} periodic ${STAGEDIR}${EXAMPLESDIR}
+ ${MKDIR} ${STAGEDIR}${DOCSDIR}
+.for file in ${PORTDOCS}
+ ${INSTALL_DATA} ${WRKSRC}/${file} ${STAGEDIR}${DOCSDIR}/${file}
+.endfor
+
+post-install-BASH-on:
+ ${MKDIR} ${STAGEDIR}${PREFIX}/etc/bash_completion.d
+ ${INSTALL_DATA} ${WRKSRC}/completion/zfsnap-completion.bash \
+ ${STAGEDIR}${PREFIX}/etc/bash_completion.d/zfsnap.sh
+
+post-install-ZSH-on:
+ ${MKDIR} ${STAGEDIR}${PREFIX}/share/zsh/site-functions
+ ${INSTALL_DATA} ${WRKSRC}/completion/zfsnap-completion.bash \
+ ${STAGEDIR}${PREFIX}/share/zsh/site-functions/_zfsnap
+
+.include <bsd.port.mk>