git: 1b12104e16a9 - main - math/sympol: Fix paths in installed headers; Add test target

Yuri Victorovich yuri at FreeBSD.org
Sat May 22 18:34:31 UTC 2021


The branch main has been updated by yuri:

URL: https://cgit.FreeBSD.org/ports/commit/?id=1b12104e16a9da5afeab276a526726c5b1ac2044

commit 1b12104e16a9da5afeab276a526726c5b1ac2044
Author:     Yuri Victorovich <yuri at FreeBSD.org>
AuthorDate: 2021-05-22 18:30:55 +0000
Commit:     Yuri Victorovich <yuri at FreeBSD.org>
CommitDate: 2021-05-22 18:34:29 +0000

    math/sympol: Fix paths in installed headers; Add test target
    
    Project installs headers that include its own headers as if they
    are installed into a subdirectory when they are really installed
    without a subdirectory.
    
    Reported by:    Philipp-Joachim Ost <philipp at philippost.de> (via e-mail)
---
 math/sympol/Makefile | 13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/math/sympol/Makefile b/math/sympol/Makefile
index bce16d7296c6..37a30fd167d4 100644
--- a/math/sympol/Makefile
+++ b/math/sympol/Makefile
@@ -1,6 +1,7 @@
 PORTNAME=	sympol
 DISTVERSIONPREFIX=	v
 DISTVERSION=	0.1.9
+PORTREVISION=	1
 CATEGORIES=	math
 
 MAINTAINER=	yuri at FreeBSD.org
@@ -14,14 +15,24 @@ LIB_DEPENDS=	libboost_program_options.so:devel/boost-libs \
 		libcddgmp.so:math/cddlib \
 		libgmp.so:math/gmp
 
-USES=		cmake compiler:c++11-lang eigen:3 localbase:ldflags
+USES=		cmake:testing compiler:c++11-lang eigen:3 localbase:ldflags perl5 shebangfix
+USE_PERL5=	test
 USE_LDCONFIG=	yes
 
 USE_GITHUB=	yes
 GH_ACCOUNT=	tremlin
 GH_PROJECT=	SymPol
 
+SHEBANG_GLOB=	*.pl
+
+CMAKE_TESTING_ON=	BUILD_TESTS # test 'perltest' fails with 'output format mismatch', see https://github.com/tremlin/SymPol/issues/1
+
 post-install:
 	@${RM} ${STAGEDIR}${PREFIX}/lib/libcddgmp.so
+	# remove subdirectory of logger.h, see https://github.com/tremlin/SymPol/issues/2
+	@${REINPLACE_CMD} -i '' -e 's|#include "yal/|#include "|' ${STAGEDIR}${PREFIX}/include/sympol/*.h
+
+pre-test: # correct the build directory path
+	@${REINPLACE_CMD} -e "s|'\\.\\./build/release'|'${BUILD_WRKSRC}'|" ${WRKSRC}/contrib/test-sympol.pl
 
 .include <bsd.port.mk>


More information about the dev-commits-ports-all mailing list