diff options
Diffstat (limited to 'var/spack/repos/builtin/packages/trilinos/package.py')
-rw-r--r-- | var/spack/repos/builtin/packages/trilinos/package.py | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/var/spack/repos/builtin/packages/trilinos/package.py b/var/spack/repos/builtin/packages/trilinos/package.py index aed722814b..5f8c2debb0 100644 --- a/var/spack/repos/builtin/packages/trilinos/package.py +++ b/var/spack/repos/builtin/packages/trilinos/package.py @@ -25,6 +25,7 @@ from spack import * import os import sys +import platform # Trilinos is complicated to build, as an inspiration a couple of links to # other repositories which build it: @@ -171,10 +172,15 @@ class Trilinos(CMakePackage): '-DLAPACK_LIBRARY_DIRS=%s' % ';'.join(lapack.directories), '-DTrilinos_ENABLE_EXPLICIT_INSTANTIATION:BOOL=ON', '-DTrilinos_ENABLE_CXX11:BOOL=ON', - '-DTPL_ENABLE_Netcdf:BOOL=ON', - '-DCMAKE_INSTALL_NAME_DIR:PATH=%s/lib' % self.prefix + '-DTPL_ENABLE_Netcdf:BOOL=ON' ]) + if '.'.join(platform.mac_ver()[0].split('.')[:2]) == '10.12': + # use @rpath on Sierra due to limit of dynamic loader + options.append('-DCMAKE_MACOSX_RPATH=ON') + else: + options.append('-DCMAKE_INSTALL_NAME_DIR:PATH=%s/lib' % prefix) + # Force Trilinos to use the MPI wrappers instead of raw compilers # this is needed on Apple systems that require full resolution of # all symbols when linking shared libraries |