lang/erlang-java: add APP_VERSION check.

Check that the specified APP_VERSION matches the value in vsn.mk,
as there is no other way to know if the Makefile is correct when
updating the port.
This commit is contained in:
Jimmy Olgeni 2019-05-28 21:38:10 +00:00
parent 48e1b56118
commit 3eb67b2b7d
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=502921

View file

@ -26,7 +26,6 @@ MAKE_JOBS_UNSAFE=yes
PLIST_SUB= APP_VERSION=${APP_VERSION}
# always check the app version in otp_versions.table
APP_VERSION= 1.9.1
APP_DIR= ${PREFIX}/lib/erlang/lib/jinterface-${APP_VERSION}
@ -42,6 +41,9 @@ do-build:
${RM} -r ${WRKSRC}/lib/jinterface/priv/com
do-install:
@if [ ! $$(${CAT} ${WRKSRC}/lib/jinterface/vsn.mk | ${CUT} -w -f3) = ${APP_VERSION} ]; then \
${ECHO_MSG} "===> APP_VERSION (${APP_VERSION}) in Makefile does not match value in lib/jinterface/vsn.mk"; exit 1; \
fi
@${MKDIR} ${STAGEDIR}${APP_DIR}
@${MKDIR} ${STAGEDIR}${APP_DIR}/priv
cd ${WRKSRC}/lib/jinterface && ${COPYTREE_SHARE} ebin ${STAGEDIR}${APP_DIR}