mirror of
https://git.FreeBSD.org/ports.git
synced 2024-12-03 01:23:49 +00:00
* Migrate to gfortran.
* Bump port revision. * Use gfortran compiled atlas/blas/lapack. * Changes are minimal. Approved by: portmgr(kris)
This commit is contained in:
parent
92275f2f27
commit
095eeae99d
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=182496
@ -7,6 +7,7 @@
|
||||
|
||||
PORTNAME= scilab
|
||||
PORTVERSION= 4.1
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= math cad parallel
|
||||
MASTER_SITES= http://www.scilab.org/download/${PORTVERSION}/
|
||||
EXTRACT_SUFX= -src.tar.gz
|
||||
@ -22,6 +23,7 @@ RUN_DEPENDS+= wish8.4:${PORTSDIR}/x11-toolkits/tk84
|
||||
GNU_CONFIGURE= yes
|
||||
USE_GETTEXT= yes
|
||||
WANT_GNOME= yes
|
||||
USE_AUTOTOOLS= autoconf:259
|
||||
|
||||
CONFIGURE_ARGS= --with-tk \
|
||||
--with-tk-library=${LOCALBASE}/lib \
|
||||
@ -34,12 +36,11 @@ CONFIGURE_ARGS= --with-tk \
|
||||
--without-java \
|
||||
--without-ocaml
|
||||
|
||||
CONFIGURE_ENV= X11BASE=${X11BASE} F77=${F77} FFLAGS="${FFLAGS}"
|
||||
CONFIGURE_ENV+= X11BASE=${X11BASE} F77=${F77} FFLAGS="${FFLAGS}"
|
||||
|
||||
PLIST_SUB= PORTVERSION="${PORTVERSION}" DOCSDIR="share/doc/scilab"
|
||||
|
||||
OPTIONS= ATLAS "Use Atlas" off \
|
||||
GTK2 "Use Gtk+2 interface" off \
|
||||
OPTIONS= GTK2 "Use Gtk+2 interface" off \
|
||||
PVM "Use PVM" off
|
||||
|
||||
.include <bsd.port.pre.mk>
|
||||
@ -67,13 +68,16 @@ LIB_DEPENDS+= readline.5:${PORTSDIR}/devel/readline
|
||||
PLIST_SUB+= GTK2="@comment " NOGTK2=""
|
||||
.endif
|
||||
|
||||
.if exists(${LOCALBASE}/lib/libatlas_r.so) && !defined(WITH_BLAS)
|
||||
WITH_ATLAS= yes
|
||||
.endif
|
||||
.if defined(WITH_ATLAS)
|
||||
CONFIGURE_ARGS+= --with-atlas-library=${LOCALBASE}/lib
|
||||
LIB_DEPENDS+= f77blas.1:${PORTSDIR}/math/atlas
|
||||
LIB_DEPENDS+= atlas.2:${PORTSDIR}/math/atlas
|
||||
BLAS_LIBS= -lalapack -lcblas -lf77blas -latlas
|
||||
.else
|
||||
LIB_DEPENDS+= lapack.3:${PORTSDIR}/math/lapack
|
||||
LIB_DEPENDS+= blas.1:${PORTSDIR}/math/blas
|
||||
LIB_DEPENDS+= lapack.4:${PORTSDIR}/math/lapack
|
||||
LIB_DEPENDS+= blas.2:${PORTSDIR}/math/blas
|
||||
BLAS_LIBS?= -llapack -lblas
|
||||
.endif
|
||||
MAKE_ENV+= BLAS_LIBS="-L${LOCALBASE}/lib ${BLAS_LIBS}"
|
||||
@ -83,6 +87,12 @@ MAKE_ENV+= BLAS_LIBS="-L${LOCALBASE}/lib ${BLAS_LIBS}"
|
||||
USE_GCC= 3.2
|
||||
.endif
|
||||
|
||||
WANT_FORTRAN=yes #dummy but future use
|
||||
BUILD_DEPENDS+= gfortran42:${PORTSDIR}/lang/gcc42
|
||||
F77= gfortran42
|
||||
FC= gfortran42
|
||||
CONFIGURE_ARGS+= --with-gfortran
|
||||
|
||||
.if ${ARCH} == "alpha" && ${OSVERSION} >= 502102 || ${ARCH} == "ia64" || \
|
||||
${ARCH} == "sparc64" || ${ARCH} == "amd64" && ${OSVERSION} >= 700000
|
||||
BROKEN= does not compile on alpha 5.x, ia64, sparc64 or amd64 -CURRENT
|
||||
|
55
math/scilab/files/patch-configure.in
Normal file
55
math/scilab/files/patch-configure.in
Normal file
@ -0,0 +1,55 @@
|
||||
--- configure.in.orig Sat Nov 4 00:06:57 2006
|
||||
+++ configure.in Tue Jan 16 17:37:44 2007
|
||||
@@ -119,7 +119,7 @@
|
||||
fi
|
||||
AC_CHECK_PROG(WITH_G77,g77,yes,no)
|
||||
if test "$WITH_G77" = no; then
|
||||
- AC_CHECK_PROG(WITH_GFORTRAN,gfortran,yes,no)
|
||||
+ AC_CHECK_PROGS(WITH_GFORTRAN,[gfortran gfortran41 gfortran42 gfortran43],no)
|
||||
if test "$WITH_GFORTRAN" = no; then
|
||||
AC_MSG_ERROR([Unable to configure: g77 or gfortran compiler not found])
|
||||
fi
|
||||
@@ -151,7 +151,7 @@
|
||||
fi
|
||||
elif test "$with_gfortran" = yes; then
|
||||
# GNU g95 (gfortran) required
|
||||
- AC_CHECK_PROG(WITH_GFORTRAN,gfortran,yes,no)
|
||||
+ AC_CHECK_PROGS(WITH_GFORTRAN,[gfortran gfortran41 gfortran42 gfortran43],no)
|
||||
if test "$WITH_GFORTRAN" = no; then
|
||||
AC_MSG_ERROR([Unable to configure: gfortran compiler not found])
|
||||
fi
|
||||
@@ -1297,14 +1297,29 @@
|
||||
FC_PICFLAGS='-fPIC'
|
||||
LD=ld
|
||||
LD_LDFLAGS=-lm
|
||||
-
|
||||
+ if test "$WITH_G77" = yes; then
|
||||
+ FC_PICFLAGS=-fPIC
|
||||
+ if test "$enable_debug" = yes; then
|
||||
+ FC_OPTIONS="-g"
|
||||
+ FC_OPTIONS_O0=""
|
||||
+ else
|
||||
+ FC_OPTIONS="-O"
|
||||
+ FC_OPTIONS_O0=""
|
||||
+ fi
|
||||
+ elif test "$WITH_GFORTRAN" != no;then
|
||||
+ if test "$enable_debug" = yes; then
|
||||
+ FC_OPTIONS="-g"
|
||||
+ FC_OPTIONS_O0=""
|
||||
+ else
|
||||
+ FC_OPTIONS="-O"
|
||||
+ FC_OPTIONS_O0=""
|
||||
+ fi
|
||||
+ FC_PICFLAGS=-fPIC
|
||||
+ AC_DEFINE(G95_FORTRAN)
|
||||
+ fi
|
||||
if test "$enable_debug" = yes; then
|
||||
CC_OPTIONS='-g -Dfreebsd'
|
||||
FC_OPTIONS=-g
|
||||
- fi
|
||||
- if test "$WITH_G77" = yes; then
|
||||
- # On FreeBSD the gnu fortran compiler is named f77
|
||||
- FC=f77
|
||||
fi
|
||||
DLDLIB='${SCIDIR}/libs/libdld.a'
|
||||
DLD_SUBDIR=dld
|
Loading…
Reference in New Issue
Block a user