diff --git a/var/spack/repos/builtin/packages/libgit2/package.py b/var/spack/repos/builtin/packages/libgit2/package.py index dcd5259a27..6fe9022179 100644 --- a/var/spack/repos/builtin/packages/libgit2/package.py +++ b/var/spack/repos/builtin/packages/libgit2/package.py @@ -57,6 +57,7 @@ class Libgit2(CMakePackage): # Build Dependencies depends_on('cmake@2.8:', type='build', when="@:0.28") depends_on('cmake@3.5:', type='build', when="@0.99:") + depends_on('pkgconfig', type='build') # Runtime Dependencies depends_on('libssh2', when='+ssh') diff --git a/var/spack/repos/builtin/packages/libssh2/package.py b/var/spack/repos/builtin/packages/libssh2/package.py index 3cada3de90..cb3bcab1c3 100644 --- a/var/spack/repos/builtin/packages/libssh2/package.py +++ b/var/spack/repos/builtin/packages/libssh2/package.py @@ -28,3 +28,9 @@ def cmake_args(self): spec = self.spec return [ '-DBUILD_SHARED_LIBS=%s' % ('YES' if '+shared' in spec else 'NO')] + + @run_after('install') + def darwin_fix(self): + # The shared library is not installed correctly on Darwin; fix this + if self.spec.satisfies('platform=darwin'): + fix_darwin_install_name(self.prefix.lib)