summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
authorSergey Kosukhin <skosukhin@gmail.com>2018-03-06 18:25:00 +0100
committerMassimiliano Culpo <massimiliano.culpo@gmail.com>2018-03-06 18:25:00 +0100
commit8d6738a3e66c2c02de68c2a2496a62b2d91228ac (patch)
treed5c750f8a74135a5913ce39ccc40cd93b145235e /var
parent02bed55007361b11b7f732a8d0744532e9067513 (diff)
downloadspack-8d6738a3e66c2c02de68c2a2496a62b2d91228ac.tar.gz
spack-8d6738a3e66c2c02de68c2a2496a62b2d91228ac.tar.bz2
spack-8d6738a3e66c2c02de68c2a2496a62b2d91228ac.tar.xz
spack-8d6738a3e66c2c02de68c2a2496a62b2d91228ac.zip
Setup dependent environment for pkgconf. (#7102)
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/pkgconf/package.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/pkgconf/package.py b/var/spack/repos/builtin/packages/pkgconf/package.py
index 5ed5bf4c7e..d0cf6eb899 100644
--- a/var/spack/repos/builtin/packages/pkgconf/package.py
+++ b/var/spack/repos/builtin/packages/pkgconf/package.py
@@ -40,6 +40,19 @@ class Pkgconf(AutotoolsPackage):
provides('pkgconfig')
+ def setup_dependent_environment(self, spack_env, run_env, dependent_spec):
+ """spack built pkg-config on cray's requires adding /usr/local/
+ and /usr/lib64/ to PKG_CONFIG_PATH in order to access cray '.pc'
+ files.
+ Adds the ACLOCAL path for autotools."""
+ spack_env.append_path('ACLOCAL_PATH',
+ join_path(self.prefix.share, 'aclocal'))
+ if 'platform=cray' in self.spec:
+ spack_env.append_path('PKG_CONFIG_PATH',
+ '/usr/lib64/pkgconfig')
+ spack_env.append_path('PKG_CONFIG_PATH',
+ '/usr/local/lib64/pkgconfig')
+
@run_after('install')
def link_pkg_config(self):
symlink('pkgconf', '{0}/pkg-config'.format(self.prefix.bin))