summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenis Davydov <davydden@gmail.com>2016-07-09 08:12:34 +0200
committerDenis Davydov <davydden@gmail.com>2016-07-09 08:12:34 +0200
commite482994a1505bf7b8e506872c8ac205fce68b217 (patch)
treeb1f1f6733c9090447e94da54020ada57157086c1
parentc096bb332a7710a0618049f0e2df1800771bd3f9 (diff)
downloadspack-e482994a1505bf7b8e506872c8ac205fce68b217.tar.gz
spack-e482994a1505bf7b8e506872c8ac205fce68b217.tar.bz2
spack-e482994a1505bf7b8e506872c8ac205fce68b217.tar.xz
spack-e482994a1505bf7b8e506872c8ac205fce68b217.zip
petsc: add -lm when building example
-rw-r--r--var/spack/repos/builtin/packages/petsc/package.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/var/spack/repos/builtin/packages/petsc/package.py b/var/spack/repos/builtin/packages/petsc/package.py
index 90afdbdb90..11f5c36c22 100644
--- a/var/spack/repos/builtin/packages/petsc/package.py
+++ b/var/spack/repos/builtin/packages/petsc/package.py
@@ -154,7 +154,7 @@ class Petsc(Package):
env['PETSC_DIR'] = self.prefix
cc = Executable(spec['mpi'].mpicc)
cc('ex50.c', '-I%s' % prefix.include, '-L%s' % prefix.lib,
- '-lpetsc', '-o', 'ex50')
+ '-lpetsc', '-lm', '-o', 'ex50')
run = Executable(join_path(spec['mpi'].prefix.bin, 'mpirun'))
run('ex50', '-da_grid_x', '4', '-da_grid_y', '4')
if 'superlu-dist' in spec: