apr-util: Fix spack install apr-util +crypto ^openssl~shared (#40301)
This commit is contained in:
		| @@ -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): | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Alex Richert
					Alex Richert