openvdb: update to v10.0.0 (#33835)
This commit is contained in:
parent
9e1fef8813
commit
9a2fbf373c
@ -14,16 +14,20 @@ class Openvdb(CMakePackage):
|
|||||||
"""OpenVDB - a sparse volume data format."""
|
"""OpenVDB - a sparse volume data format."""
|
||||||
|
|
||||||
homepage = "https://github.com/AcademySoftwareFoundation/openvdb"
|
homepage = "https://github.com/AcademySoftwareFoundation/openvdb"
|
||||||
url = "https://github.com/AcademySoftwareFoundation/openvdb/archive/v8.0.1.tar.gz"
|
url = "https://github.com/AcademySoftwareFoundation/openvdb/archive/v10.0.0.tar.gz"
|
||||||
git = "https://github.com/AcademySoftwareFoundation/openvdb.git"
|
git = "https://github.com/AcademySoftwareFoundation/openvdb.git"
|
||||||
|
|
||||||
# Github account name for Drew.Whitehouse@gmail.com
|
# Github account name for drew@lagrangian.xyz
|
||||||
maintainers = ["eloop"]
|
maintainers = ["eloop"]
|
||||||
|
|
||||||
version("develop", branch="develop")
|
version("develop", branch="develop")
|
||||||
|
version("10.0.0", "6d4f6b5ccd0f9d35a4886d9a51a98c97fa314f75bf9737c5121e91b706e2db70")
|
||||||
|
version("9.1.0", "914ee417b4607c75c95b53bc73a0599de4157c7d6a32e849e80f24e40fb64181")
|
||||||
|
version("8.2.0", "d2e77a0720db79e9c44830423bdb013c24a1cf50994dd61d570b6e0c3e0be699")
|
||||||
version("8.0.1", "a6845da7c604d2c72e4141c898930ac8a2375521e535f696c2cd92bebbe43c4f")
|
version("8.0.1", "a6845da7c604d2c72e4141c898930ac8a2375521e535f696c2cd92bebbe43c4f")
|
||||||
version("7.1.0", "0c3588c1ca6e647610738654ec2c6aaf41a203fd797f609fbeab1c9f7c3dc116")
|
version("7.1.0", "0c3588c1ca6e647610738654ec2c6aaf41a203fd797f609fbeab1c9f7c3dc116")
|
||||||
|
|
||||||
|
# these variants were for 8.0.1 and probably could be updated...
|
||||||
variant("shared", default=True, description="Build as a shared library.")
|
variant("shared", default=True, description="Build as a shared library.")
|
||||||
variant("python", default=False, description="Build the pyopenvdb python extension.")
|
variant("python", default=False, description="Build the pyopenvdb python extension.")
|
||||||
variant("vdb_print", default=False, description="Build the vdb_print tool.")
|
variant("vdb_print", default=False, description="Build the vdb_print tool.")
|
||||||
@ -31,19 +35,18 @@ class Openvdb(CMakePackage):
|
|||||||
variant("vdb_render", default=False, description="Build the vdb_render tool.")
|
variant("vdb_render", default=False, description="Build the vdb_render tool.")
|
||||||
variant("ax", default=False, description="Build the AX extension (untested).")
|
variant("ax", default=False, description="Build the AX extension (untested).")
|
||||||
|
|
||||||
depends_on("ilmbase")
|
depends_on("ilmbase", when="@8:9")
|
||||||
depends_on("openexr")
|
depends_on("ilmbase@2.3:3.1", when="@10:")
|
||||||
depends_on("intel-tbb")
|
depends_on("openexr", when="@8:9")
|
||||||
|
depends_on("openexr@2.3:3.1", when="@10:")
|
||||||
# Openvdb officially suggests an old version of blosc but it doesn't seem to be
|
depends_on("intel-tbb@:2020.1", when="@:8.1")
|
||||||
# strictly neccessary and requires manual approval from spack.
|
depends_on("intel-tbb@2021", when="@8.2:")
|
||||||
depends_on("c-blosc") # depends_on('c-blosc@1.5:')
|
depends_on("zlib")
|
||||||
|
depends_on("c-blosc@1.17.0") # depends_on('c-blosc@1.5:')
|
||||||
extends("python", when="+python")
|
|
||||||
depends_on("py-numpy", when="+python")
|
depends_on("py-numpy", when="+python")
|
||||||
|
|
||||||
depends_on("boost+iostreams+system+python+numpy", when="+python")
|
depends_on("boost+iostreams+system+python+numpy", when="+python")
|
||||||
depends_on("boost+iostreams+system", when="~python")
|
depends_on("boost+iostreams+system", when="~python")
|
||||||
|
extends("python", when="+python")
|
||||||
|
|
||||||
# AX requires quite a few things, and hasn't been properly released
|
# AX requires quite a few things, and hasn't been properly released
|
||||||
# yet. I've only managed to build llvm@8.0.1 under centos8. It
|
# yet. I've only managed to build llvm@8.0.1 under centos8. It
|
||||||
@ -51,7 +54,6 @@ class Openvdb(CMakePackage):
|
|||||||
depends_on("llvm@8.0.1", when="+ax")
|
depends_on("llvm@8.0.1", when="+ax")
|
||||||
depends_on("bison", when="+ax")
|
depends_on("bison", when="+ax")
|
||||||
depends_on("flex", when="+ax")
|
depends_on("flex", when="+ax")
|
||||||
|
|
||||||
depends_on("git", type="build", when="@develop")
|
depends_on("git", type="build", when="@develop")
|
||||||
|
|
||||||
def cmake_args(self):
|
def cmake_args(self):
|
||||||
@ -68,16 +70,14 @@ def cmake_args(self):
|
|||||||
]
|
]
|
||||||
return args
|
return args
|
||||||
|
|
||||||
# The python extension is being put in the wrong directory
|
# Before v8.2.0 the python extension is being installed in the
|
||||||
# by OpenVDB's cmake, instead it needs to be in
|
# wrong directory by OpenVDB's cmake, instead it needs to be in
|
||||||
# python_platlib. For RHEL systems we seem to get the
|
# python_platlib. And for RHEL systems we find the dso in
|
||||||
# dso in lib64/ instead of lib/
|
# lib64/ instead of lib/.
|
||||||
@run_after("install")
|
@run_after("install")
|
||||||
def post_install(self):
|
def post_install(self):
|
||||||
|
|
||||||
spec = self.spec
|
spec = self.spec
|
||||||
|
if "+python" in spec and spec.satisfies("@:8.0.1"):
|
||||||
if "+python" in spec:
|
|
||||||
if sys.platform == "darwin":
|
if sys.platform == "darwin":
|
||||||
pyso = "pyopenvdb.dylib"
|
pyso = "pyopenvdb.dylib"
|
||||||
else:
|
else:
|
||||||
@ -87,4 +87,5 @@ def post_install(self):
|
|||||||
src = prefix.lib.join(pyver).join(pyso)
|
src = prefix.lib.join(pyver).join(pyso)
|
||||||
if not os.path.isfile(src):
|
if not os.path.isfile(src):
|
||||||
src = prefix.lib64.join(pyver).join(pyso)
|
src = prefix.lib64.join(pyver).join(pyso)
|
||||||
|
assert os.path.isfile(src)
|
||||||
os.rename(src, os.path.join(python_platlib, pyso))
|
os.rename(src, os.path.join(python_platlib, pyso))
|
||||||
|
Loading…
Reference in New Issue
Block a user