2013-07-10 19:01:32 +02:00
|
|
|
# Created by: NAKATA, Maho <maho@FreeBSD.org>
|
2003-10-04 06:21:13 +02:00
|
|
|
# $FreeBSD$
|
|
|
|
|
|
|
|
PORTNAME= sdpa
|
2009-08-03 17:03:56 +02:00
|
|
|
PORTVERSION= 7.3.1
|
2009-09-13 02:08:01 +02:00
|
|
|
PORTREVISION= 1
|
2003-10-04 06:21:13 +02:00
|
|
|
CATEGORIES= math
|
2007-04-18 02:32:25 +02:00
|
|
|
MASTER_SITES= http://sdpa.indsys.chuo-u.ac.jp/sdpa/files/
|
2009-08-03 17:03:56 +02:00
|
|
|
DISTNAME= ${PORTNAME}.${PORTVERSION}.src-${SRCDATE}
|
2004-05-06 21:49:54 +02:00
|
|
|
DIST_SUBDIR= sdpa
|
2003-10-04 06:21:13 +02:00
|
|
|
|
|
|
|
MAINTAINER= maho@FreeBSD.org
|
2013-07-26 08:38:59 +02:00
|
|
|
COMMENT= Very efficient SDP (semidefinite programming) solver
|
2003-10-04 06:21:13 +02:00
|
|
|
|
2013-07-10 19:01:32 +02:00
|
|
|
USES= gmake
|
|
|
|
|
2008-02-18 02:40:11 +01:00
|
|
|
.include <bsd.port.pre.mk>
|
2003-10-04 06:21:13 +02:00
|
|
|
|
2009-08-03 17:03:56 +02:00
|
|
|
SRCDATE= 20090729
|
|
|
|
MANUALFILE= sdpa7-manual.pdf
|
2007-07-14 03:25:39 +02:00
|
|
|
USE_FORTRAN= yes
|
2008-02-18 02:40:11 +01:00
|
|
|
GNU_CONFIGURE= yes
|
2009-08-03 17:03:56 +02:00
|
|
|
WRKSRC= ${WRKDIR}/${PORTNAME}.${PORTVERSION}.src
|
2007-01-16 05:37:14 +01:00
|
|
|
|
2010-02-16 07:04:31 +01:00
|
|
|
.if exists(${LOCALBASE}/lib/libgoto2.so)
|
2011-11-22 12:14:10 +01:00
|
|
|
WITH_BLAS?= gotoblas
|
|
|
|
.elif exists(${LOCALBASE}/lib/libatlas.so)
|
|
|
|
WITH_BLAS?= atlas
|
|
|
|
.else
|
|
|
|
WITH_BLAS?= reference
|
2008-02-18 02:40:11 +01:00
|
|
|
.endif
|
2007-01-16 05:37:14 +01:00
|
|
|
|
2011-11-22 12:14:10 +01:00
|
|
|
. if ${WITH_BLAS} == reference
|
2008-02-18 02:40:11 +01:00
|
|
|
LIB_DEPENDS+= blas.2:${PORTSDIR}/math/blas
|
|
|
|
LIB_DEPENDS+= lapack.4:${PORTSDIR}/math/lapack
|
2007-01-11 09:05:45 +01:00
|
|
|
BLAS= -lblas
|
|
|
|
LAPACK= -llapack
|
2011-11-22 12:14:10 +01:00
|
|
|
.elif ${WITH_BLAS} == gotoblas
|
2010-02-16 07:04:31 +01:00
|
|
|
LIB_DEPENDS+= goto2:${PORTSDIR}/math/gotoblas
|
2008-02-18 02:40:11 +01:00
|
|
|
LIB_DEPENDS+= lapack.4:${PORTSDIR}/math/lapack
|
2010-02-16 07:04:31 +01:00
|
|
|
BLAS= -lgoto2p
|
|
|
|
LAPACK=
|
2011-11-22 12:14:10 +01:00
|
|
|
.elif ${WITH_BLAS} == atlas
|
2008-02-18 02:40:11 +01:00
|
|
|
LIB_DEPENDS+= atlas:${PORTSDIR}/math/atlas
|
2011-11-22 12:14:10 +01:00
|
|
|
BLAS= -lptf77blas
|
|
|
|
LAPACK= -lalapack -lptcblas
|
2004-08-18 13:12:34 +02:00
|
|
|
.endif
|
2007-01-11 09:05:45 +01:00
|
|
|
|
2008-12-15 05:06:31 +01:00
|
|
|
CONFIGURE_ARGS+=--with-blas="-L${LOCALBASE}/lib ${BLAS}" --with-lapack="-L${LOCALBASE}/lib ${LAPACK}"
|
2003-10-04 06:21:13 +02:00
|
|
|
|
2008-03-05 02:10:39 +01:00
|
|
|
PLIST_SUB+= MANUALFILE=${MANUALFILE}
|
|
|
|
|
2013-07-26 08:38:59 +02:00
|
|
|
post-patch:
|
|
|
|
# Register missing target dependency to unbreak parallel builds
|
|
|
|
@${REINPLACE_CMD} -e 's,^sdpa_DEPENDENCIES =,& $$(lib_LIBRARIES),' \
|
|
|
|
${WRKSRC}/Makefile.in
|
|
|
|
|
2003-10-04 06:21:13 +02:00
|
|
|
do-install:
|
|
|
|
${INSTALL_PROGRAM} ${WRKSRC}/sdpa ${PREFIX}/bin
|
|
|
|
@${MKDIR} ${DATADIR}
|
|
|
|
${INSTALL_DATA} ${WRKSRC}/param.sdpa ${DATADIR}
|
|
|
|
.if !defined(NOPORTDOCS)
|
|
|
|
@${MKDIR} ${DOCSDIR}
|
2009-08-03 17:03:56 +02:00
|
|
|
${INSTALL_DATA} ${WRKSRC}/doc/${MANUALFILE} ${DOCSDIR}
|
2003-10-04 06:21:13 +02:00
|
|
|
.endif
|
|
|
|
|
2005-07-04 06:12:12 +02:00
|
|
|
.include <bsd.port.post.mk>
|