Date: Tue, 14 Jul 2015 10:44:51 +0000 (UTC) From: Jimmy Olgeni <olgeni@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r391976 - head/Mk/Uses Message-ID: <201507141044.t6EAipBc015406@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: olgeni Date: Tue Jul 14 10:44:50 2015 New Revision: 391976 URL: https://svnweb.freebsd.org/changeset/ports/391976 Log: Improvements in erlang.mk: - Replace %%PORTVERSION%% in all source files - Fix vsn tag in app files, whatever its format Modified: head/Mk/Uses/erlang.mk Modified: head/Mk/Uses/erlang.mk ============================================================================== --- head/Mk/Uses/erlang.mk Tue Jul 14 09:14:41 2015 (r391975) +++ head/Mk/Uses/erlang.mk Tue Jul 14 10:44:50 2015 (r391976) @@ -79,17 +79,19 @@ do-install: do-install-erlang post-patch-erlang: @${FIND} ${WRKSRC} -name .gitignore -delete -# Attempt to remove all traces of {vsn, git}; replace with actual PORTVERSION +# Attempt to remove all traces of {vsn, ....}; replace with actual PORTVERSION @if [ -f ${WRKSRC}/src/${ERL_APP_NAME}.app.src ]; then \ - ${REINPLACE_CMD} -i '' -e 's/{ *vsn, *git *}/{vsn, "${PORTVERSION}"}/' \ + ${REINPLACE_CMD} -i '' -e 's/{ *vsn,.*}/{vsn, "${PORTVERSION}"}/' \ ${WRKSRC}/src/${ERL_APP_NAME}.app.src; \ fi @if [ -f ${WRKSRC}/ebin/${ERL_APP_NAME}.app ]; then \ - ${REINPLACE_CMD} -i '' -e 's/{ *vsn, *git *}/{vsn, "${PORTVERSION}"}/' \ + ${REINPLACE_CMD} -i '' -e 's/{ *vsn,.*}/{vsn, "${PORTVERSION}"}/' \ ${WRKSRC}/ebin/${ERL_APP_NAME}.app; \ fi @${GREP} -l "%%LOCALBASE%%" $$(${FIND} ${WRKSRC}) \ | ${XARGS} ${REINPLACE_CMD} -i '' -e "s@%%LOCALBASE%%@${LOCALBASE}@" + @${GREP} -l "%%PORTVERSION%%" $$(${FIND} ${WRKSRC}) \ + | ${XARGS} ${REINPLACE_CMD} -i '' -e "s@%%PORTVERSION%%@${PORTVERSION}@" # Always try to build with the system version of rebar and rebar3 @if [ -f ${WRKSRC}/rebar.config ]; then \ ${REINPLACE_CMD} -i '' -e "s@./rebar3@${REBAR3_CMD}@; s@./rebar@${REBAR_CMD}@" \
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201507141044.t6EAipBc015406>