Upgrade to version 2.12.2.

- Simplify RUN_DEPENDS.
- Add support for DOCS and EXAMPLES.
- Use pkg-plist for the docs (remove PORTDOCS).
- Use PORTNAME in install code.
This commit is contained in:
Jimmy Olgeni 2015-05-09 13:46:09 +00:00
parent 093e7ca265
commit 6bdb4f4884
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=385891
3 changed files with 19 additions and 13 deletions

View File

@ -1,7 +1,7 @@
# $FreeBSD$
PORTNAME= mochiweb
PORTVERSION= 2.10.0
PORTVERSION= 2.12.2
DISTVERSIONPREFIX= v
CATEGORIES= www devel
@ -10,8 +10,8 @@ COMMENT= Erlang library for building lightweight HTTP servers
LICENSE= MIT
BUILD_DEPENDS= erlc:${PORTSDIR}/lang/erlang
RUN_DEPENDS= erl:${PORTSDIR}/lang/erlang
BUILD_DEPENDS= erl:${PORTSDIR}/lang/erlang
RUN_DEPENDS:= ${BUILD_DEPENDS}
CONFLICTS= mochiweb-basho-[0-9]*
@ -20,21 +20,25 @@ PLIST_SUB= VERSION="${PORTVERSION}"
USE_GITHUB= yes
GH_ACCOUNT= mochi
PORTDOCS= *
.include <bsd.port.options.mk>
do-install:
.if ${PORT_OPTIONS:MDOCS}
@${MKDIR} ${STAGEDIR}${DOCSDIR}
for FILE in CHANGES.md README; do \
${INSTALL_DATA} ${WRKSRC}/$${FILE} ${STAGEDIR}${DOCSDIR}; \
done
.endif
.if ${PORT_OPTIONS:MEXAMPLES}
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
cd ${WRKSRC}/examples && ${COPYTREE_SHARE} \* ${STAGEDIR}${EXAMPLESDIR}
@${MKDIR} ${STAGEDIR}${PREFIX}/lib/erlang/lib/mochiweb-${PORTVERSION}
@${MKDIR} ${STAGEDIR}${PREFIX}/lib/erlang/lib/mochiweb-${PORTVERSION}/ebin
@${MKDIR} ${STAGEDIR}${PREFIX}/lib/erlang/lib/mochiweb-${PORTVERSION}/include
@${MKDIR} ${STAGEDIR}${PREFIX}/lib/erlang/lib/mochiweb-${PORTVERSION}/src
${INSTALL_DATA} ${WRKSRC}/ebin/* ${STAGEDIR}${PREFIX}/lib/erlang/lib/mochiweb-${PORTVERSION}/ebin
${INSTALL_DATA} ${WRKSRC}/include/* ${STAGEDIR}${PREFIX}/lib/erlang/lib/mochiweb-${PORTVERSION}/include
${INSTALL_DATA} ${WRKSRC}/src/* ${STAGEDIR}${PREFIX}/lib/erlang/lib/mochiweb-${PORTVERSION}/src
.endif
@${MKDIR} ${STAGEDIR}${PREFIX}/lib/erlang/lib/${PORTNAME}-${PORTVERSION}
@${MKDIR} ${STAGEDIR}${PREFIX}/lib/erlang/lib/${PORTNAME}-${PORTVERSION}/ebin
@${MKDIR} ${STAGEDIR}${PREFIX}/lib/erlang/lib/${PORTNAME}-${PORTVERSION}/include
@${MKDIR} ${STAGEDIR}${PREFIX}/lib/erlang/lib/${PORTNAME}-${PORTVERSION}/src
${INSTALL_DATA} ${WRKSRC}/ebin/* ${STAGEDIR}${PREFIX}/lib/erlang/lib/${PORTNAME}-${PORTVERSION}/ebin
${INSTALL_DATA} ${WRKSRC}/include/* ${STAGEDIR}${PREFIX}/lib/erlang/lib/${PORTNAME}-${PORTVERSION}/include
${INSTALL_DATA} ${WRKSRC}/src/* ${STAGEDIR}${PREFIX}/lib/erlang/lib/${PORTNAME}-${PORTVERSION}/src
.include <bsd.port.mk>

View File

@ -1,2 +1,2 @@
SHA256 (mochi-mochiweb-v2.10.0_GH0.tar.gz) = e830a767a8e4b575d9da46ffc8bdfe1b5f4493353082280c4a1a692588499307
SIZE (mochi-mochiweb-v2.10.0_GH0.tar.gz) = 278224
SHA256 (mochi-mochiweb-v2.12.2_GH0.tar.gz) = 73369f5a2e0d5477632a3d1fa44c674f2dfc98908f86bfd6bd77b266bdb88684
SIZE (mochi-mochiweb-v2.12.2_GH0.tar.gz) = 284186

View File

@ -67,6 +67,8 @@ lib/erlang/lib/mochiweb-%%VERSION%%/src/mochiweb_socket_server.erl
lib/erlang/lib/mochiweb-%%VERSION%%/src/mochiweb_util.erl
lib/erlang/lib/mochiweb-%%VERSION%%/src/mochiweb_websocket.erl
lib/erlang/lib/mochiweb-%%VERSION%%/src/reloader.erl
%%PORTDOCS%%%%DOCSDIR%%/CHANGES.md
%%PORTDOCS%%%%DOCSDIR%%/README
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/hmac_api/README
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/hmac_api/hmac_api.hrl
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/hmac_api/hmac_api_client.erl