math/triangle: Install the header; build and install the shared library

Reason: other packages expect headers/library.

Other port changes:
* Order the USExx section
* Simplify the test target
* Change WWW to https
This commit is contained in:
Yuri Victorovich 2018-08-05 00:44:37 +00:00
parent 9570014a75
commit 3b645af29d
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=476383
2 changed files with 16 additions and 10 deletions

View file

@ -3,7 +3,7 @@
PORTNAME= triangle
PORTVERSION= 1.6
PORTREVISION= 2
PORTREVISION= 3
CATEGORIES= math
MASTER_SITES= NL/voronoi
DISTNAME= ${PORTNAME}
@ -14,19 +14,25 @@ COMMENT= Two-Dimensional Quality Mesh Generator and Delaunay Triangulator
NO_CDROM= No commercial use without prior arrangement with the author
NO_WRKSUBDIR= yes
USES= zip
USE_XORG= x11
NO_WRKSUBDIR= yes
MAKEFILE= makefile
USE_XORG= x11
USE_LDCONFIG= yes
PLIST_FILES= bin/triangle bin/showme
PLIST_FILES= bin/${PORTNAME} bin/showme \
include/${PORTNAME}.h \
lib/lib${PORTNAME}.so
post-build:
@cd ${WRKSRC} && ${CC} ${CFLAGS} ${LDFLAGS} -shared -fPIC -o lib${PORTNAME}.so ${PORTNAME}.c
do-install:
${INSTALL_PROGRAM} ${PLIST_FILES:S|^bin|${WRKSRC}|} ${STAGEDIR}${PREFIX}/bin
${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${WRKSRC}/showme ${STAGEDIR}${PREFIX}/bin
${INSTALL_DATA} ${WRKSRC}/${PORTNAME}.h ${STAGEDIR}${PREFIX}/include
${INSTALL_DATA} ${WRKSRC}/lib${PORTNAME}.so ${STAGEDIR}${PREFIX}/lib
.if defined(MAINTAINER_MODE)
test: build
(cd ${INSTALL_WRKSRC} && ./triangle -p A.poly && ./showme A.1.poly)
.endif
do-test: build
@cd ${INSTALL_WRKSRC} && ./${PORTNAME} -p A.poly && ./showme A.1.poly
.include <bsd.port.mk>

View file

@ -8,4 +8,4 @@ especially those generated by Triangle, my two-dimensional quality mesh
generator and Delaunay triangulator.
Show Me can also write PostScript images to files.
WWW: http://www.cs.cmu.edu/~quake/triangle.html
WWW: https://www.cs.cmu.edu/~quake/triangle.html