oce & trilinos: force rpath on Sierra to avoid issues with load commands size (#2855)
* oce: force rpath on Sierra to avoid issues with load commands size * trilinos: use rpath on Sierra to avoid load commands limit
This commit is contained in:
parent
a8e1d78881
commit
c76088906e
@ -87,6 +87,10 @@ def install(self, spec, prefix):
|
|||||||
'-DOCE_OSX_USE_COCOA:BOOL=ON',
|
'-DOCE_OSX_USE_COCOA: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)
|
options.append('-DCMAKE_INSTALL_NAME_DIR:PATH=%s/lib' % prefix)
|
||||||
|
|
||||||
cmake('.', *options)
|
cmake('.', *options)
|
||||||
|
@ -25,6 +25,7 @@
|
|||||||
from spack import *
|
from spack import *
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
|
import platform
|
||||||
|
|
||||||
# Trilinos is complicated to build, as an inspiration a couple of links to
|
# Trilinos is complicated to build, as an inspiration a couple of links to
|
||||||
# other repositories which build it:
|
# other repositories which build it:
|
||||||
@ -171,10 +172,15 @@ def cmake_args(self):
|
|||||||
'-DLAPACK_LIBRARY_DIRS=%s' % ';'.join(lapack.directories),
|
'-DLAPACK_LIBRARY_DIRS=%s' % ';'.join(lapack.directories),
|
||||||
'-DTrilinos_ENABLE_EXPLICIT_INSTANTIATION:BOOL=ON',
|
'-DTrilinos_ENABLE_EXPLICIT_INSTANTIATION:BOOL=ON',
|
||||||
'-DTrilinos_ENABLE_CXX11:BOOL=ON',
|
'-DTrilinos_ENABLE_CXX11:BOOL=ON',
|
||||||
'-DTPL_ENABLE_Netcdf:BOOL=ON',
|
'-DTPL_ENABLE_Netcdf:BOOL=ON'
|
||||||
'-DCMAKE_INSTALL_NAME_DIR:PATH=%s/lib' % self.prefix
|
|
||||||
])
|
])
|
||||||
|
|
||||||
|
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
|
# Force Trilinos to use the MPI wrappers instead of raw compilers
|
||||||
# this is needed on Apple systems that require full resolution of
|
# this is needed on Apple systems that require full resolution of
|
||||||
# all symbols when linking shared libraries
|
# all symbols when linking shared libraries
|
||||||
|
Loading…
Reference in New Issue
Block a user