aboutsummaryrefslogtreecommitdiffstats
path: root/math
diff options
context:
space:
mode:
authormaho <maho@FreeBSD.org>2007-01-13 08:34:33 +0800
committermaho <maho@FreeBSD.org>2007-01-13 08:34:33 +0800
commit2be469e6548c537f43d2d27cb34ac005553b16cf (patch)
treeb6e10164f3a6cd3c7aebbd53daba7de8fd80dbfa /math
parent68869e0f511d299054faac77209ccda001bc5b73 (diff)
downloadfreebsd-ports-gnome-2be469e6548c537f43d2d27cb34ac005553b16cf.tar.gz
freebsd-ports-gnome-2be469e6548c537f43d2d27cb34ac005553b16cf.tar.zst
freebsd-ports-gnome-2be469e6548c537f43d2d27cb34ac005553b16cf.zip
* Migrate to gfortran.
* Bump port revision. * Use gfortran compiled atlas/blas/lapack.
Diffstat (limited to 'math')
-rw-r--r--math/umfpack/Makefile30
-rw-r--r--math/umfpack/files/patch-Make+Make.freebsd2
2 files changed, 21 insertions, 11 deletions
diff --git a/math/umfpack/Makefile b/math/umfpack/Makefile
index d8a36eb017e5..47d0f393174b 100644
--- a/math/umfpack/Makefile
+++ b/math/umfpack/Makefile
@@ -7,6 +7,7 @@
PORTNAME= umfpack
PORTVERSION= 4.4
+PORTREVISION= 1
CATEGORIES= math
MASTER_SITES= http://www.cise.ufl.edu/research/sparse/umfpack/v${PORTVERSION}/
DISTNAME= UMFPACKv${PORTVERSION}
@@ -14,32 +15,41 @@ DISTNAME= UMFPACKv${PORTVERSION}
MAINTAINER= ports@FreeBSD.org
COMMENT= Unsymmetric-pattern MultiFrontal Package
-.ifdef WITH_ATLAS
-LIB_DEPENDS= atlas.1:${PORTSDIR}/math/atlas
+.if exists(${LOCALBASE}/lib/libatlas_r.so) && !defined(WITH_BLAS)
+WITH_ATLAS= yes
+.endif
+.if defined(WITH_ATLAS)
+LIB_DEPENDS+= atlas.2:${PORTSDIR}/math/atlas
+BLAS= -lf77blas -latlas
.else
-LIB_DEPENDS= blas.1:${PORTSDIR}/math/blas
+LIB_DEPENDS+= blas.2:${PORTSDIR}/math/blas
+BLAS= -lblas
.endif
+WANT_FORTRAN= yes #dummy but future use
+BUILD_DEPENDS+= gfortran42:${PORTSDIR}/lang/gcc42
+FC= gfortran42
+F77= gfortran42
+FORTRANLIBS= -lgfortranbegin -lgfortran
+GCCLIBDIR= -L`${CAT} ${WRKSRC}/LIBDIR` -L`${CAT} ${WRKSRC}/LIBDIR`/../../..
+
CONFLICTS= elmer-umfpack-4*
WRKSRC= ${WRKDIR}/${DISTNAME}/UMFPACK
ALL_TARGET= lib
-.ifdef WITH_ATLAS
-BLAS_LIBS= -lf77blas -latlas
-.else
-BLAS_LIBS?= -lblas
-.endif
-
post-extract:
${CP} ${WRKDIR}/${DISTNAME}/AMD/Make/Make.linux \
${WRKDIR}/${DISTNAME}/AMD/Make/Make.freebsd
pre-build:
+ @${DIRNAME} `${FC} -print-libgcc-file-name` > ${WRKSRC}/LIBDIR
@${REINPLACE_CMD} -e 's+%%CC%%+${CC}+g ; \
s+%%CFLAGS%%+${CFLAGS}+ ; \
s+%%LOCALBASE%%+${LOCALBASE}+ ; \
- s+%%BLAS_LIBS%%+${BLAS_LIBS}+ ;' \
+ s+%%GCCLIBDIR%%+${GCCLIBDIR}+ ; \
+ s+%%FORTRANLIBS%%+${FORTRANLIBS}+ ; \
+ s+%%BLAS%%+${BLAS}+ ;' \
${WRKDIR}/${DISTNAME}/AMD/Make/Make.freebsd
do-install:
diff --git a/math/umfpack/files/patch-Make+Make.freebsd b/math/umfpack/files/patch-Make+Make.freebsd
index c516d0404138..dd10e0f4c426 100644
--- a/math/umfpack/files/patch-Make+Make.freebsd
+++ b/math/umfpack/files/patch-Make+Make.freebsd
@@ -24,7 +24,7 @@
-# CONFIG =
-# LIB = -lf77blas -latlas -lfrtbegin -lg2c -lm
+CONFIG = -DGETRUSAGE
-+LIB = -L%%LOCALBASE%%/lib %%BLAS_LIBS%% -lg2c -lm
++LIB = -L%%LOCALBASE%%/lib %%BLAS%% %%GCCLIBDIR%% %%FORTRANLIBS%% -lm
# 4: with Fortran interface to the BLAS, and Goto's BLAS
- CONFIG =