# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
PortGroup linear_algebra 1.0
maintainers {dstrubbe @dstrubbe}
description GW/Bethe-Salpeter equation
long_description BerkeleyGW is a set of computer codes that calculate the quasiparticle properties \
and the optical responses of a large variety of materials from bulk periodic crystals \
to nanostructures such as slabs, wires and molecules, using many-body perturbation theory \
(the GW approximation and Bethe-Salpeter equation).
homepage http://www.berkeleygw.org
checksums rmd160 26933a24c10ba03457c667bc5f2d3ca21df2a436 \
sha256 1305dc8587af666fe437bc2561a9106b2b0bcdbe91980b8f1ae7bbd491ce1e25
master_sites https://berkeley.box.com/shared/static
distfiles 829s6ha4popx1g4cslpklzh5znf2v6la.gz
#old name: BGW-${version}.tar.gz; master_sites ${homepage}/releases
# needed for case-sensitive filesystems
worksrcdir BerkeleyGW-${version}
if {![variant_isset fftw2]} {
compilers.enforce_some_fortran fftw-3
# May fail with +mpich +gcc5. Use +mpich +gfortran instead.
# In file included from /opt/local/include/mpich-gcc5/mpi.h:2231:0,
# /opt/local/include/mpich-gcc5/mpicxx.h:22:4: error: #error 'Please use the same version of GCC and g++ for compiling MPICH and user MPI programs'
# # error 'Please use the same version of GCC and g++ for compiling MPICH and user MPI programs'
# WHAT DO WE DO WHEN meaning of 'gfortran' is updated? No record... Maybe rename to gfortran5 etc. ?
# test hangs in Epsilon with OpenMPI, for unknown reason.
compilers.choose fc cc cxx cpp
# can we re-enable OpenMPI?
mpi.setup require_fortran -openmpi -openmpi_devel -gfortran -clang
# FIXME: +gfortran just needs smarter setting of cpp to the one from gcc;
#clang and llvm only useful with +g95 currently (which is useless)
if {[variant_isset g95]} {
depends_build-append port:llvm-gcc42
# FIXME: this unnecessarily enforces scalapack also had same C compiler as we are using.
if {[mpi_variant_isset]} {
depends_lib-append port:scalapack
if {![mpi_variant_isset]} {
ui_error "+scalapack requires an MPI variant. Choose +mpich, +mpich_devel, +openmpi, or +openmpi_devel."
return -code error "+scalapack requires an MPI variant."