apr-util: Fix spack install apr-util +crypto ^openssl~shared (#40301)
This commit is contained in:
parent
7a4b479724
commit
df01a11e07
1 changed files with 8 additions and 0 deletions
|
@ -32,6 +32,7 @@ class AprUtil(AutotoolsPackage):
|
|||
depends_on("postgresql", when="+pgsql")
|
||||
depends_on("sqlite", when="+sqlite")
|
||||
depends_on("unixodbc", when="+odbc")
|
||||
depends_on("pkg-config", type="build", when="+crypto ^openssl~shared")
|
||||
|
||||
@property
|
||||
def libs(self):
|
||||
|
@ -85,6 +86,13 @@ def configure_args(self):
|
|||
else:
|
||||
args.append("--without-odbc")
|
||||
|
||||
if spec.satisfies("+crypto ^openssl~shared"):
|
||||
# Need pkg-config to get zlib and -ldl flags
|
||||
# (see https://dev.apr.apache.narkive.com/pNnO9F1S/configure-bug-openssl)
|
||||
pkgconf = which("pkg-config")
|
||||
ssl_libs = pkgconf("--libs", "--static", "openssl", output=str)
|
||||
args.append(f"LIBS={ssl_libs}")
|
||||
|
||||
return args
|
||||
|
||||
def check(self):
|
||||
|
|
Loading…
Reference in a new issue