summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
authorPramod S Kumbhar <pramod.r.s.kumbhar@gmail.com>2017-09-11 01:16:49 +0200
committerTodd Gamblin <tgamblin@llnl.gov>2017-09-10 13:16:49 -1000
commit3bb243e8e240d69e80d535e4c8cc818e96f61063 (patch)
treed6badaa50cc6daa6ed203cb594895dc3f50a550c /var
parentf5f51118b8469b1d37ad6c381394e8c497db3be3 (diff)
downloadspack-3bb243e8e240d69e80d535e4c8cc818e96f61063.tar.gz
spack-3bb243e8e240d69e80d535e4c8cc818e96f61063.tar.bz2
spack-3bb243e8e240d69e80d535e4c8cc818e96f61063.tar.xz
spack-3bb243e8e240d69e80d535e4c8cc818e96f61063.zip
Improve PDToolkit support for different compilers (#5322)
* Improve PDToolkit support for different compilers PDT dependency of TAU profiler doesn't use CC, CXX eb variables and needs command line arguments for compiler identification. If we don't pass compiler id then it uses gcc and result in link time errors while building TAU. This patch fixes it; tested with PGI and Intel compilers.
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/pdt/package.py15
1 files changed, 14 insertions, 1 deletions
diff --git a/var/spack/repos/builtin/packages/pdt/package.py b/var/spack/repos/builtin/packages/pdt/package.py
index 6895fd0578..7e4aec0af9 100644
--- a/var/spack/repos/builtin/packages/pdt/package.py
+++ b/var/spack/repos/builtin/packages/pdt/package.py
@@ -45,8 +45,21 @@ class Pdt(AutotoolsPackage):
version('3.19', '5c5e1e6607086aa13bf4b1b9befc5864')
version('3.18.1', 'e401534f5c476c3e77f05b7f73b6c4f2')
+ def patch(self):
+ if self.spec.satisfies('%clang'):
+ filter_file(r'PDT_GXX=g\+\+ ',
+ r'PDT_GXX=clang++ ', 'ductape/Makefile')
+
def configure(self, spec, prefix):
- configure('-prefix={0}'.format(prefix))
+ options = ['-prefix=%s' % prefix]
+ if self.compiler.name == 'xl':
+ options.append('-XLC')
+ elif self.compiler.name == 'intel':
+ options.append('-icpc')
+ elif self.compiler.name == 'pgi':
+ options.append('-pgCC')
+
+ configure(*options)
@run_after('install')
def link_arch_dirs(self):