Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 7 Jun 2018 08:34:27 +0000 (UTC)
From:      Dmitry Marakasov <amdmi3@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r471902 - head/french/med
Message-ID:  <201806070834.w578YRNJ086351@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: amdmi3
Date: Thu Jun  7 08:34:27 2018
New Revision: 471902
URL: https://svnweb.freebsd.org/changeset/ports/471902

Log:
  - Switch to new test framework
  - Switch to options helpers
  
  Approved by:	portmgr blanket

Modified:
  head/french/med/Makefile

Modified: head/french/med/Makefile
==============================================================================
--- head/french/med/Makefile	Thu Jun  7 06:26:39 2018	(r471901)
+++ head/french/med/Makefile	Thu Jun  7 08:34:27 2018	(r471902)
@@ -26,6 +26,9 @@ CONFIGURE_ARGS=	--disable-python --with-hdf5=${LOCALBA
 CONFIGURE_ENV=	WISH=${WISH} H5DUMP=h5dump-18
 GNU_CONFIGURE=	yes
 USE_LDCONFIG=	yes
+TEST_WRKSRC=	${WRKSRC}/tests
+TEST_TARGET=	check  # XXX: 1 of 16 tests fail
+TEST_ENV=	${MAKE_ENV} HDF5_DISABLE_VERSION_CHECK=1
 
 LIBVER=		1.8.0
 PLIST_SUB+=	VE=${LIBVER}
@@ -35,38 +38,32 @@ PATCH_TK_SCRIPTS=	tools/mdump/xmdump2.in tools/mdump/x
 DOC2FIX=	. dox gif html html.dox jpg png
 TST2FIX=	c f
 
-.include <bsd.port.options.mk>
-
-pre-configure:
-	${REINPLACE_CMD} -e 's|<malloc\.h>|<stdlib.h>|' \
+post-patch:
+	@${REINPLACE_CMD} -e 's|<malloc\.h>|<stdlib.h>|' \
 		${WRKSRC}/include/2.3.6/med_outils.h \
 		${WRKSRC}/include/med_outils.h
-.if ! ${PORT_OPTIONS:MDOCS}
-	${REINPLACE_CMD} -e '/SUBDIRS/ s|doc||' ${WRKSRC}/Makefile.in
-.endif
-.if ! ${PORT_OPTIONS:MEXAMPLES}
-	${REINPLACE_CMD} -e '/SUBDIRS/ s|tests||' ${WRKSRC}/Makefile.in
-.endif
 .for dd in ${DOC2FIX}
-	${REINPLACE_CMD} -e 's|docdir = $$(datadir)/doc|docdir = @docdir@|'	\
+	@${REINPLACE_CMD} -e 's|docdir = $$(datadir)/doc|docdir = @docdir@|'	\
 		${WRKSRC}/doc/${dd}/Makefile.in
 .endfor
 .for dd in ${TST2FIX}
-	${FIND} ${WRKSRC}/tests -name Makefile.in | ${XARGS}	\
+	@${FIND} ${WRKSRC}/tests -name Makefile.in | ${XARGS}	\
 	${REINPLACE_CMD} -e 's|test${dd}dir = $$(bindir)/test|test${dd}dir = ${EXAMPLESDIR}/test|' \
 			-e 's|unittestsdir = $$(bindir)/unit|unittestsdir = ${EXAMPLESDIR}/unit|' \
 			-e 's|usescasesdir = $$(bindir)/uses|usescasesdir = ${EXAMPLESDIR}/uses|'
 .endfor
 	# ATM MED is only compatible with hdf5-18
-	${REINPLACE_CMD} -e 's|-lhdf5|-lhdf5-18|'  ${WRKSRC}/${CONFIGURE_SCRIPT}
+	@${REINPLACE_CMD} -e 's|-lhdf5|-lhdf5-18|'  ${WRKSRC}/${CONFIGURE_SCRIPT}
 
+post-patch-DOCS-off:
+	@${REINPLACE_CMD} -e '/SUBDIRS/ s|doc||' ${WRKSRC}/Makefile.in
+
+post-patch-EXAMPLES-off:
+	@${REINPLACE_CMD} -e '/SUBDIRS/ s|tests||' ${WRKSRC}/Makefile.in
+
 post-install:
 	(cd ${STAGEDIR}${PREFIX}/bin && ${LN} -sf mdump3 mdump	\
 		&& ${LN} -sf xmdump3 xmdump)
-
-regression-test:
-	(cd ${BUILD_WRKSRC}/tests && ${SETENV} ${MAKE_ENV} HDF5_DISABLE_VERSION_CHECK=1	\
-		${MAKE_CMD} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} check)
 
 .include "${.CURDIR}/../../french/aster/bsd.aster.mk"
 .include <bsd.port.mk>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201806070834.w578YRNJ086351>