git: 6a6d03c16fb0 - 2022Q3 - misc/opennn: Add test target; remove MPI option (defunct); Add USES=compiler:c++11-lang
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 20 Jul 2022 19:27:32 UTC
The branch 2022Q3 has been updated by yuri:
URL: https://cgit.FreeBSD.org/ports/commit/?id=6a6d03c16fb0b7a718075121b36e2b3e8bc29e94
commit 6a6d03c16fb0b7a718075121b36e2b3e8bc29e94
Author: Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2022-07-15 18:51:06 +0000
Commit: Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2022-07-20 19:25:19 +0000
misc/opennn: Add test target; remove MPI option (defunct); Add USES=compiler:c++11-lang
(cherry picked from commit 461a2801d4dde2197bb449f02909e69dfebf83c3)
---
misc/opennn/Makefile | 17 ++++++++++-------
1 file changed, 10 insertions(+), 7 deletions(-)
diff --git a/misc/opennn/Makefile b/misc/opennn/Makefile
index 81c10a2811a5..600ebd243910 100644
--- a/misc/opennn/Makefile
+++ b/misc/opennn/Makefile
@@ -1,5 +1,6 @@
PORTNAME= opennn
DISTVERSION= 5.0.5
+PORTREVISION= 1
CATEGORIES= misc # machine-learning
MASTER_SITES= https://github.com/Artelnics/opennn/archive/refs/tags/v${DISTVERSION}${EXTRACT_SUFX}?dummy=/
@@ -13,21 +14,23 @@ BROKEN_armv6= fatal error: 'omp.h' file not found
BROKEN_armv7= fatal error: 'omp.h' file not found
BROKEN_riscv64= fatal error: 'omp.h' file not found
-USES= cmake compiler dos2unix zip
-DOS2UNIX_FILES= opennn/CMakeLists.txt
+USES= cmake:testing compiler:c++11-lang dos2unix zip
USE_LDCONFIG= yes
-CMAKE_OFF= OpenNN_BUILD_EXAMPLES OpenNN_BUILD_TESTS
-LDFLAGS+= -lomp -pthread # https://github.com/Artelnics/opennn/issues/182
+DOS2UNIX_FILES= opennn/CMakeLists.txt
-OPTIONS_DEFINE= MPI
+CMAKE_OFF= OpenNN_BUILD_EXAMPLES OpenNN_BUILD_TESTS
+CMAKE_TESTING_ON= OpenNN_BUILD_TESTS # some tests fail, see https://github.com/Artelnics/opennn/issues/229
+CMAKE_TESTING_TARGET= tests
-MPI_CMAKE_BOOL= __OPENNN_MPI__
-MPI_BROKEN= deactivated: https://github.com/Artelnics/OpenNN/issues/86
+LDFLAGS+= -lomp -pthread # https://github.com/Artelnics/opennn/issues/182
do-install:
${MKDIR} ${STAGEDIR}${PREFIX}/include/${PORTNAME} && ${INSTALL_DATA} ${WRKSRC}/${PORTNAME}/*.h ${STAGEDIR}${PREFIX}/include/${PORTNAME}
${INSTALL_DATA} ${BUILD_WRKSRC}/${PORTNAME}/libopennn.so ${STAGEDIR}${PREFIX}/lib
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libopennn.so
+post-test:
+ @cd ${TEST_WRKSRC} && (${ECHO} suite | tests/tests)
+
.include <bsd.port.mk>