likwid: search library path for compilation with hwloc (#39659)
This commit is contained in:
parent
19f8e9147d
commit
9a0a4eceaf
@ -188,12 +188,18 @@ def install(self, spec, prefix):
|
|||||||
"HWLOC_INCLUDE_DIR = {0}".format(spec["hwloc"].prefix.include),
|
"HWLOC_INCLUDE_DIR = {0}".format(spec["hwloc"].prefix.include),
|
||||||
"config.mk",
|
"config.mk",
|
||||||
)
|
)
|
||||||
filter_file(
|
ll = spec["hwloc"].libs
|
||||||
"^#HWLOC_LIB_DIR.*",
|
if len(ll.directories) > 0 and len(ll.names) > 0:
|
||||||
"HWLOC_LIB_DIR = {0}".format(spec["hwloc"].prefix.lib),
|
filter_file(
|
||||||
"config.mk",
|
"^#HWLOC_LIB_DIR.*",
|
||||||
)
|
"HWLOC_LIB_DIR = {0}".format(ll.directories[0]),
|
||||||
filter_file("^#HWLOC_LIB_NAME.*", "HWLOC_LIB_NAME = hwloc", "config.mk")
|
"config.mk",
|
||||||
|
)
|
||||||
|
filter_file(
|
||||||
|
"^#HWLOC_LIB_NAME.*", "HWLOC_LIB_NAME = {0}".format(ll.names[0]), "config.mk"
|
||||||
|
)
|
||||||
|
else:
|
||||||
|
raise InstallError("Failed to find library path and/or name of hwloc dependency")
|
||||||
|
|
||||||
# https://github.com/RRZE-HPC/likwid/issues/287
|
# https://github.com/RRZE-HPC/likwid/issues/287
|
||||||
if self.spec.satisfies("@:5.0.2 %gcc@10:"):
|
if self.spec.satisfies("@:5.0.2 %gcc@10:"):
|
||||||
|
Loading…
Reference in New Issue
Block a user