aboutsummaryrefslogtreecommitdiff
path: root/math/carve/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'math/carve/Makefile')
-rw-r--r--math/carve/Makefile24
1 files changed, 15 insertions, 9 deletions
diff --git a/math/carve/Makefile b/math/carve/Makefile
index 494cae6c097e..adf0e29f797d 100644
--- a/math/carve/Makefile
+++ b/math/carve/Makefile
@@ -11,20 +11,22 @@ EXTRACT_SUFX= .tgz
MAINTAINER= gahr@FreeBSD.org
COMMENT= A fast, robust constructive solid geometry library
+LICENSE= GPLv2
+
LIB_DEPENDS= libboost_filesystem.so:${PORTSDIR}/devel/boost-libs
-OPTIONS_DEFINE= GUI
+OPTIONS_DEFINE= DOCS GUI
-USES= cmake:outsource
+USES= cmake:outsource compiler:c++11-lib
USE_GL= glut
USE_LDCONFIG= yes
-LICENSE= GPLv2
+PORTDOCS= *
CFLAGS+= -I${LOCALBASE}/include
+CXXFLAGS+= -std=c++11
LDFLAGS+= -L${LOCALBASE}/lib
-NO_STAGE= yes
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MGUI}
@@ -37,11 +39,15 @@ PLIST_SUB+= GUI="@comment "
CMAKE_ARGS+= -DCARVE_WITH_GUI:BOOL=false
.endif
+post-patch:
+ ${FIND} ${WRKSRC} -name "*.cpp" -o -name "*.h" -o -name "*.hpp" | ${XARGS} \
+ ${REINPLACE_CMD} -e 's|::tr1||g'
+ ${REINPLACE_CMD} -e '/gtest/s|^|#|; /tests/s|^|#|' ${WRKSRC}/CMakeLists.txt
+ ${REINPLACE_CMD} -e 's|__is_heap|is_heap|' ${WRKSRC}/lib/triangulator.cpp
+
post-install:
- ${LN} -sf libcarve.so.${PORTVERSION} ${PREFIX}/lib/libcarve.so.${PORTVERSION:R:R}
-.if !defined(NOPORTDOCS)
- ${MKDIR} ${DOCSDIR}
- ${INSTALL_DATA} ${WRKSRC}/doc/carve.pdf ${DOCSDIR}
-.endif
+ ${LN} -sf libcarve.so.${PORTVERSION} ${STAGEDIR}${PREFIX}/lib/libcarve.so.${PORTVERSION:R:R}
+ @${MKDIR} ${STAGEDIR}${DOCSDIR}
+ ${INSTALL_DATA} ${WRKSRC}/doc/carve.pdf ${STAGEDIR}${DOCSDIR}
.include <bsd.port.mk>