summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeoffrey Oxberry <goxberry@gmail.com>2017-06-13 17:59:25 -0700
committerTodd Gamblin <tgamblin@llnl.gov>2017-06-13 17:59:25 -0700
commit56f7c85c939231c289c1b497607058f8bb57245f (patch)
tree075d57d7233615a5b404b545768b4262f97d4e05
parentb80252451782ed2606ee340f1de233a84d634685 (diff)
downloadspack-56f7c85c939231c289c1b497607058f8bb57245f.tar.gz
spack-56f7c85c939231c289c1b497607058f8bb57245f.tar.bz2
spack-56f7c85c939231c289c1b497607058f8bb57245f.tar.xz
spack-56f7c85c939231c289c1b497607058f8bb57245f.zip
metis: bugfix: make shared library build portable (#4489)
Fixes #4488. When compiling metis as a shared library, the package used the syntax `-rpath=`, followed by a path. This syntax is non-portable, so replace it using Spack's compiler rpath argument property.
-rw-r--r--var/spack/repos/builtin/packages/metis/package.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/var/spack/repos/builtin/packages/metis/package.py b/var/spack/repos/builtin/packages/metis/package.py
index 6424509592..3b904dd015 100644
--- a/var/spack/repos/builtin/packages/metis/package.py
+++ b/var/spack/repos/builtin/packages/metis/package.py
@@ -135,7 +135,8 @@ class Metis(Package):
# Set up and run tests on installation
ccompile('-I%s' % prefix.include, '-L%s' % prefix.lib,
- '-Wl,-rpath=%s' % (prefix.lib if '+shared' in spec else ''),
+ self.compiler.cc_rpath_arg +
+ '%s' % (prefix.lib if '+shared' in spec else ''),
join_path('Programs', 'io.o'), join_path('Test', 'mtest.c'),
'-o', '%s/mtest' % prefix.bin, '-lmetis', '-lm')