1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-26 09:46:09 +00:00

Support stage

Add docs and examples options
Use pkg-plist
This commit is contained in:
Baptiste Daroussin 2014-01-27 23:45:36 +00:00
parent 9cb8ca204e
commit 09911bfe3a
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=341482
2 changed files with 31 additions and 41 deletions

View File

@ -3,26 +3,24 @@
PORTNAME= cvsgraph
PORTVERSION= 1.7.0
PORTREVISION= 5
PORTREVISION= 6
CATEGORIES= devel graphics
MASTER_SITES= http://www.akhphd.au.dk/~bertho/cvsgraph/release/
MAINTAINER= ports@FreeBSD.org
COMMENT= Graph the life story of a file under CVS or RCS
LIB_DEPENDS= gd:${PORTSDIR}/graphics/gd
OPTIONS_DEFINE= DOCS EXAMPLES
LIB_DEPENDS= libgd.so:${PORTSDIR}/graphics/gd
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}
MAN1= cvsgraph.1
MAN5= cvsgraph.conf.5
DOCDIR= share/doc/${PORTNAME}
DOCS= ChangeLog README
EXAMPLES= cvsgraphwrapper.php mkimage.php
MORE_EXAMPLES= README.Automatic_documentation checkoutlist commit_action.sh \
commitinfo cvswrappers tag_action.sh taginfo
PLIST= ${WRKDIR}/pkg-plist
SUB_FILES= pkg-message
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --with-gd-inc=${LOCALBASE}/include \
@ -30,50 +28,24 @@ CONFIGURE_ARGS= --with-gd-inc=${LOCALBASE}/include \
LDFLAGS="-L${PREFIX}/lib"
REINPLACE_ARGS= -i ""
NO_STAGE= yes
pre-patch:
@${REINPLACE_CMD} -e "s:/home/bertho/tmp/cvstest:/home/ncvs:g" ${WRKSRC}/cvsgraph.conf
pre-install:
${ECHO_CMD} bin/cvsgraph > ${PLIST}
${ECHO_CMD} etc/cvsgraph.conf.sample >> ${PLIST}
.if !defined(NOPORTDOCS)
.for i in ${DOCS}
${ECHO_CMD} ${DOCDIR}/${i} >> ${PLIST}
.endfor
.for i in ${MORE_EXAMPLES}
${ECHO_CMD} share/examples/${PORTNAME}/automatic_documentation/${i} >> ${PLIST}
.endfor
.for i in ${EXAMPLES}
${ECHO_CMD} share/examples/${PORTNAME}/${i} >> ${PLIST}
.endfor
${ECHO_CMD} @dirrm share/examples/${PORTNAME}/automatic_documentation >> ${PLIST}
${ECHO_CMD} @dirrm share/examples/${PORTNAME} >> ${PLIST}
${ECHO_CMD} @dirrm ${DOCDIR} >> ${PLIST}
.endif
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin
${INSTALL_DATA} ${WRKSRC}/cvsgraph.conf ${PREFIX}/etc/cvsgraph.conf.sample
${INSTALL_MAN} ${WRKSRC}/cvsgraph.1 ${PREFIX}/man/man1
${INSTALL_MAN} ${WRKSRC}/cvsgraph.conf.5 ${PREFIX}/man/man5
.if !defined(NOPORTDOCS)
${MKDIR} ${PREFIX}/${DOCDIR}
${MKDIR} ${PREFIX}/share/examples/${PORTNAME}
${MKDIR} ${PREFIX}/share/examples/${PORTNAME}/automatic_documentation
${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin
${INSTALL_DATA} ${WRKSRC}/cvsgraph.conf ${STAGEDIR}${PREFIX}/etc/cvsgraph.conf.sample
${INSTALL_MAN} ${WRKSRC}/cvsgraph.1 ${STAGEDIR}${MAN1PREFIX}/man/man1
${INSTALL_MAN} ${WRKSRC}/cvsgraph.conf.5 ${STAGEDIR}${MAN5PREFIX}/man/man5
@${MKDIR} ${STAGEDIR}${DOCSDIR}
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}/automatic_documentation
.for i in ${DOCS}
${INSTALL_DATA} ${WRKSRC}/${i} ${PREFIX}/${DOCDIR}
${INSTALL_DATA} ${WRKSRC}/${i} ${STAGEDIR}${DOCSDIR}
.endfor
.for i in ${EXAMPLES}
${INSTALL_DATA} ${WRKSRC}/contrib/${i} ${PREFIX}/share/examples/${PORTNAME}
${INSTALL_DATA} ${WRKSRC}/contrib/${i} ${STAGEDIR}${EXAMPLESDIR}
.endfor
.for i in ${MORE_EXAMPLES}
${INSTALL_DATA} ${WRKSRC}/contrib/automatic_documentation/${i} ${PREFIX}/share/examples/${PORTNAME}/automatic_documentation
${INSTALL_DATA} ${WRKSRC}/contrib/automatic_documentation/${i} ${STAGEDIR}${EXAMPLESDIR}/automatic_documentation
.endfor
.endif
post-install:
@${ECHO_CMD} " "
@${CAT} ${PKGMESSAGE}
.include <bsd.port.mk>

18
devel/cvsgraph/pkg-plist Normal file
View File

@ -0,0 +1,18 @@
bin/cvsgraph
etc/cvsgraph.conf.sample
man/man1/cvsgraph.1.gz
man/man5/cvsgraph.conf.5.gz
%%PORTDOCS%%%%DOCSDIR%%/ChangeLog
%%PORTDOCS%%%%DOCSDIR%%/README
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/automatic_documentation/README.Automatic_documentation
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/automatic_documentation/checkoutlist
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/automatic_documentation/commit_action.sh
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/automatic_documentation/commitinfo
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/automatic_documentation/cvswrappers
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/automatic_documentation/tag_action.sh
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/automatic_documentation/taginfo
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/cvsgraphwrapper.php
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/mkimage.php
%%PORTEXAMPLES%%@dirrmtry %%EXAMPLESDIR%%/automatic_documentation
%%PORTEXAMPLES%%@dirrmtry %%EXAMPLESDIR%%
%%PORTDOCS%%@dirrmtry %%DOCSDIR%%