diff options
author | Tom Payerle <payerle@umd.edu> | 2024-02-27 04:45:29 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-02-27 10:45:29 +0100 |
commit | 3290e2c18981115f4e2b7e7a240aab1ffc922fa7 (patch) | |
tree | 56fedb08812c223ff5f9b9251b3ee9a575f07016 | |
parent | 2a9fc3452a07c6e9cb37e4e1442729ca02b613d1 (diff) | |
download | spack-3290e2c18981115f4e2b7e7a240aab1ffc922fa7.tar.gz spack-3290e2c18981115f4e2b7e7a240aab1ffc922fa7.tar.bz2 spack-3290e2c18981115f4e2b7e7a240aab1ffc922fa7.tar.xz spack-3290e2c18981115f4e2b7e7a240aab1ffc922fa7.zip |
openexr: Add custom libs property (#42274)
Libraries for openexr are named libOpenEXR*.so, etc., so the default libs
handler in spec does not find them.
Add a custom libs property to address this.
Partial fix for #42273
Co-authored-by: payerle <payerle@users.noreply.github.com>
-rw-r--r-- | var/spack/repos/builtin/packages/openexr/package.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/openexr/package.py b/var/spack/repos/builtin/packages/openexr/package.py index 90e291c912..768f95e1c0 100644 --- a/var/spack/repos/builtin/packages/openexr/package.py +++ b/var/spack/repos/builtin/packages/openexr/package.py @@ -85,6 +85,17 @@ class Openexr(CMakePackage, AutotoolsPackage): with when("build_system=cmake"): depends_on("cmake@3.12:", type="build") + @property + def libs(self): + # Override because libs have different case than Spack package name + name = "libOpenEXR*" + # We expect libraries to be in either lib64 or lib directory + for root in (self.prefix.lib64, self.prefix.lib): + liblist = find_libraries(name, root=root, shared=True, recursive=False) + if liblist: + break + return liblist + class CMakeBuilder(CMakeBuilder): def cmake_args(self): |