silo: variant python needs python (#48257)
* silo: variant python needs python * Dependency to Python did not resolve the "Python.h" header not being found Added the -I path to Python header to the compiler. Having silo depend on python was not sufficient to get the path to python. Maybe there is a smarter way to do that, but this one works. * Update var/spack/repos/builtin/packages/silo/package.py Co-authored-by: Wouter Deconinck <wdconinc@gmail.com> * Update var/spack/repos/builtin/packages/silo/package.py Co-authored-by: Wouter Deconinck <wdconinc@gmail.com> * Update var/spack/repos/builtin/packages/silo/package.py Co-authored-by: Wouter Deconinck <wdconinc@gmail.com> --------- Co-authored-by: Wouter Deconinck <wdconinc@gmail.com>
This commit is contained in:
parent
d1d61820f4
commit
88d5393570
@ -65,6 +65,7 @@ class Silo(AutotoolsPackage):
|
||||
variant("hzip", default=True, description="Enable hzip support")
|
||||
variant("fpzip", default=True, description="Enable fpzip support")
|
||||
|
||||
depends_on("python", type=("build", "link"), when="+python")
|
||||
depends_on("perl", type="build")
|
||||
depends_on("m4", type="build", when="+shared")
|
||||
depends_on("autoconf", type="build", when="+shared")
|
||||
@ -129,6 +130,8 @@ def flag_handler(self, name, flags):
|
||||
if spec.satisfies("%oneapi"):
|
||||
flags.append("-Wno-error=int")
|
||||
flags.append("-Wno-error=int-conversion")
|
||||
if spec.satisfies("+python"):
|
||||
flags.append(f"-I {spec['python'].headers.directories[0]}")
|
||||
if "+hdf5" in spec:
|
||||
# @:4.10 can use up to the 1.10 API
|
||||
if "@:4.10" in spec:
|
||||
|
Loading…
Reference in New Issue
Block a user