aboutsummaryrefslogtreecommitdiff
path: root/math
diff options
context:
space:
mode:
authorMaho Nakata <maho@FreeBSD.org>2007-01-06 22:25:34 +0000
committerMaho Nakata <maho@FreeBSD.org>2007-01-06 22:25:34 +0000
commitbe10777358a0d6c482e43d49b40fdbbcdccba0a2 (patch)
tree72863ebf648cfc74f3e92bc368ce0b41eb98b680 /math
parent6d395117efa4858db1a02ec0fd24ca54d09c05ab (diff)
downloadports-be10777358a0d6c482e43d49b40fdbbcdccba0a2.tar.gz
ports-be10777358a0d6c482e43d49b40fdbbcdccba0a2.zip
WITH_ATLAS knob is now added and dependency for ATLAS is now conditional.
Notes
Notes: svn path=/head/; revision=181648
Diffstat (limited to 'math')
-rw-r--r--math/lapack++/Makefile22
1 files changed, 15 insertions, 7 deletions
diff --git a/math/lapack++/Makefile b/math/lapack++/Makefile
index e675bbbebb6e..2af1566e15a9 100644
--- a/math/lapack++/Makefile
+++ b/math/lapack++/Makefile
@@ -22,19 +22,27 @@ EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX}
MAINTAINER= maho@FreeBSD.org
COMMENT= Linear Algebra PACKage in C++, a wrapper for LAPACK
-.if !defined(WITH_BLAS)
-LIB_DEPENDS= atlas:${PORTSDIR}/math/atlas
+.include <bsd.port.pre.mk>
+
+.if exists(${LOCALBASE}/lib/libatlas_r.so) && !defined(WITH_BLAS)
+WITH_ATLAS= yes
+.endif
+.if defined(WITH_ATLAS)
+LIB_DEPENDS+= atlas:${PORTSDIR}/math/atlas
+.else
+LIB_DEPENDS+= blas.1:${PORTSDIR}/math/blas
+LIB_DEPENDS+= lapack.3:${PORTSDIR}/math/lapack
.endif
GNU_CONFIGURE= yes
USE_GMAKE= yes
-.if defined(WITH_BLAS)
-BLAS_LIB= -L${LOCALBASE}/lib -lblas
-LAPACK_LIB= -L${LOCALBASE}/lib -llapack
-.else
+.if defined(WITH_ATLAS)
BLAS_LIB= -L${LOCALBASE}/lib -lf77blas -latlas
LAPACK_LIB= -L${LOCALBASE}/lib -lalapack -lcblas
+.else
+BLAS_LIB= -L${LOCALBASE}/lib -lblas
+LAPACK_LIB= -L${LOCALBASE}/lib -llapack
.endif
#BLAS_LIB= -L${LOCALBASE}/lib -lptf77blas -latlas_r ${PTHREAD_LIBS}
@@ -53,4 +61,4 @@ do-install:
${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/lapackppman1_1.ps.gz ${DOCSDIR}
.endif
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>