Permalink
Browse files

math/tvmet: fix build with clang

- Fix build with clang
- Add LICENSE (LGPL21)
- USES gmake
- Allow staging

PR:		ports/184240
Submitted by:	KATO Tsuguru <tkato432 yahoo.com>
  • Loading branch information...
1 parent fc9080e commit c6856549f0ac6160b1e7a2cd3491d67486263626 @william-gr william-gr committed Nov 30, 2013
Showing with 17 additions and 14 deletions.
  1. +16 −13 math/tvmet/Makefile
  2. +1 −1 math/tvmet/pkg-plist
View
@@ -9,40 +9,43 @@ MASTER_SITES= SF/${PORTNAME}/Tar.Gz_Bz2%20Archive/${PORTVERSION}
MAINTAINER= ports@FreeBSD.org
COMMENT= Tiny Vector and Matrix template library
+LICENSE= LGPL21 # (or later)
+
+OPTIONS_DEFINE= CPPUNIT DEBUG DOCS EXAMPLES
+
USE_BZIP2= yes
-USE_GMAKE= yes
+USES= gmake
USE_AUTOTOOLS= libtool
-MAKE_ARGS= CXX="${CXX}" CXXFLAGS="${CXXFLAGS}"
+CONFIGURE_ARGS= --with-cxx=${CXX}
-MAN1= tvmet-config.1
+.include <bsd.port.options.mk>
-.if defined(WITH_CPPUNIT)
-LIB_DEPENDS+= cppunit-1.10.2:${PORTSDIR}/devel/cppunit
+.if ${PORT_OPTIONS:MCPPUNIT}
+LIB_DEPENDS+= libcppunit-1.12.so:${PORTSDIR}/devel/cppunit
CONFIGURE_ARGS+= --with-cppunit-prefix=${LOCALBASE}
.else
CONFIGURE_ENV+= ac_cv_path_CPPUNIT_CONFIG=no
.endif
-.if defined(WITH_DEBUG)
+.if ${PORT_OPTIONS:MDEBUG}
CXXFLAGS+= -DTVMET_DEBUG
.else
CXXFLAGS+= -DTVMET_OPTIMIZE
.endif
-NO_STAGE= yes
post-patch:
@${REINPLACE_CMD} -e 's|= -O |= |g' ${WRKSRC}/doc/Makefile.in
post-install:
-.if !defined(NOPORTDOCS)
- @${MKDIR} ${DOCSDIR}
+ @${MKDIR} ${STAGEDIR}${DOCSDIR}
.for ext in dox cc css h png
- ${INSTALL_DATA} ${WRKSRC}/doc/*.${ext} ${DOCSDIR}
+ (cd ${WRKSRC}/doc && ${INSTALL_DATA} *.${ext} \
+ ${STAGEDIR}${DOCSDIR})
.endfor
- @${MKDIR} ${EXAMPLESDIR}
+ @${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
.for ext in cc
- ${INSTALL_DATA} ${WRKSRC}/examples/*.${ext} ${EXAMPLESDIR}
+ (cd ${WRKSRC}/examples && ${INSTALL_DATA} *.${ext} \
+ ${STAGEDIR}${EXAMPLESDIR})
.endfor
-.endif
.include <bsd.port.mk>
View
@@ -1,5 +1,5 @@
-@comment $FreeBSD$
bin/tvmet-config
+man/man1/tvmet-config.1.gz
include/tvmet/AliasProxy.h
include/tvmet/BinaryFunctionals.h
include/tvmet/CommaInitializer.h

0 comments on commit c685654

Please sign in to comment.