LBANN OS X (#7105)

* Added a package for the MDAnalysis toolkit.

* Added some flags to fix the build RPATHs and OpenMP for LBANN on OS X.

* Fixed Hydrogen branch of Elemental to find OpenMP on OS X.
This commit is contained in:
Brian Van Essen
2018-01-31 10:38:53 -07:00
committed by becker33
parent 60cc0b0b90
commit 06758fe5cb
3 changed files with 34 additions and 1 deletions

View File

@@ -23,6 +23,7 @@
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
##############################################################################
import os
import sys
from spack import *
from spack.spec import UnsupportedCompilerError
@@ -211,6 +212,15 @@ def cmake_args(self):
'-DHydrogen_GENERAL_LAPACK_FALLBACK=ON',
]
# Add support for OS X to find OpenMP
if (self.spec.satisfies('%clang')):
if (sys.platform == 'darwin'):
clang = self.compiler.cc
clang_bin = os.path.dirname(clang)
clang_root = os.path.dirname(clang_bin)
args.extend([
'-DOpenMP_DIR={0}'.format(clang_root)])
if 'blas=openblas' in spec:
args.extend([
'-DHydrogen_USE_OpenBLAS:BOOL=%s' % ('blas=openblas' in spec),