# $Id: Portfile 37219 2008-05-30 15:52:10Z mmoll@macports.org $ PortSystem 1.0 name slepc version 2.3.3 categories math science maintainers mmoll description Scalable Library for Eigenvalue Problem Computations long_description SLEPc is a software library for the solution of large \ scale sparse eigenvalue problems on parallel computers. It is an \ extension of PETSc and can be used for either standard or generalized \ eigenproblems, with real or complex arithmetic. It can also be used for \ computing a partial SVD of a large, sparse, rectangular matrix. platforms darwin homepage http://www.grycap.upv.es/slepc master_sites http://www.grycap.upv.es/slepc/download/distrib distname ${name}-${version} # fixed up patch from official site: # (1) removed one patch that was rejected by patch, # (2) official path assumed "patch -p1", whereas MacPorts assumes "patch -p0". patchfiles patch-${distname}-7.diff checksums md5 5f9172c12f95ea0bebc73d45f4cdcaa0 \ sha1 17ffa8507ae81102178e5041e1f57c20cb9143c2 depends_lib-append port:petsc extract.suffix .tgz configure.env-append PETSC_DIR=${prefix}/lib/petsc PETSC_ARCH=darwin \ SLEPC_DIR=${worksrcpath} configure.cmd ${worksrcpath}/config/configure.py configure.args --prefix=${prefix}/lib/petsc build.env PETSC_DIR=${prefix}/lib/petsc PETSC_ARCH=darwin \ SLEPC_DIR=${worksrcpath} destroot.env PETSC_DIR=${prefix}/lib/petsc PETSC_ARCH=darwin \ SLEPC_DIR=${worksrcpath} destroot.destdir SLEPC_INSTALL_DIR=${destroot}${prefix}/lib/petsc variant arpack description {compile with ARPACK support} { pre-fetch { if {![file exists ${prefix}/lib/libparpack.a]} { return -code error "Please install the mpi variant of arpack first." } } # This is a rather fragile way to figure out where the fortran library can be # found that is needed to link against libparpack.a: if {[file exists ${prefix}/lib/gcc43]} { set fortrandir ${prefix}/lib/gcc43 } else { if {[file exists ${prefix}/lib/gcc42]} { set fortrandir ${prefix}/lib/gcc42 } else { if {[file exists ${prefix}/lib/g95]} { set fortrandir ${prefix}/lib/gcc95 } else { return -code error "Please install a fortran compiler by installing one of the following ports: gcc42, gcc43, or g95." } } } depends_lib-append port:arpack configure.args-append --with-arpack-dir=${fortrandir} \ --with-arpack-flags=-lparpack,-larpack,-lgfortran,-lmpi_f77 } post-activate { ui_msg "********************************************************" ui_msg "* Add the following lines to your .bash_profile if you *" ui_msg "* plan to use the PETSC/SLEPC makefile rules in *" ui_msg "* $prefix/lib/petsc/bmake: *" ui_msg "* *" ui_msg "* export PETSC_DIR=${prefix}/lib/petsc *" ui_msg "* export PETSC_ARCH=darwin *" ui_msg "* export SLEPC_DIR=${prefix}/lib/petsc *" ui_msg "* *" ui_msg "********************************************************" }