@@ -64,29 +64,42 @@ project(OpenVDB LANGUAGES CXX VERSION ${OpenVDB_VERSION})
6464include (CMakeDependentOption)
6565include (GNUInstallDirs)
6666
67- # todo epydoc and pdflatex
67+ # Components
6868option (OPENVDB_BUILD_CORE "Enable the core OpenVDB library. Both static and shared versions are enabled by default" ON )
6969option (OPENVDB_BUILD_BINARIES "Enable the vdb binaries. Only vdb_print is enabled by default" ON )
7070option (OPENVDB_BUILD_PYTHON_MODULE "Build the pyopenvdb Python module" OFF )
7171option (OPENVDB_BUILD_UNITTESTS "Build the OpenVDB unit tests" OFF )
7272option (OPENVDB_BUILD_DOCS "Build the OpenVDB documentation" OFF )
7373option (OPENVDB_BUILD_HOUDINI_PLUGIN "Build the Houdini plugin" OFF )
7474option (OPENVDB_BUILD_HOUDINI_ABITESTS "Build the Houdini ABI tests" OFF )
75-
75+ option (OPENVDB_BUILD_MAYA_PLUGIN "Build the Maya plugin" OFF )
7676option (OPENVDB_BUILD_AX "Build the OpenVDB AX library. Turns ON if USE_AX is ON." ${USE_AX} )
7777option (OPENVDB_BUILD_AX_UNITTESTS "Build the OpenVDB AX unit tests" OFF )
78-
7978option (OPENVDB_BUILD_NANOVDB "Build the NanoVDB library. Turns ON if USE_NANOVDB is ON." ${USE_NANOVDB} )
8079
81- option (OPENVDB_BUILD_MAYA_PLUGIN "Build the Maya plugin" OFF )
82- option (OPENVDB_USE_DELAYED_LOADING "Build the core OpenVDB library with delayed-loading." ON )
80+ # Global options
8381option (OPENVDB_ENABLE_RPATH "Build with RPATH information" ON )
82+ option (OPENVDB_ENABLE_ASSERTS "Build with asserts in OpenVDB code enabled" OFF )
83+ option (OPENVDB_USE_DELAYED_LOADING "Build the core OpenVDB library with delayed-loading." ON )
8484option (OPENVDB_CXX_STRICT "Enable or disable pre-defined compiler warnings" OFF )
85-
8685cmake_dependent_option(OPENVDB_INSTALL_CMAKE_MODULES
8786 "Install the provided OpenVDB CMake modules when building the core library"
8887 ON "OPENVDB_BUILD_CORE" OFF )
88+ option (USE_CCACHE "Build using Ccache if found on the path" ON )
89+ # Disable this on Windows due to linker OOM issues:
90+ # LNK1248: image size (XXX) exceeds maximum allowable size (FFFFFFFF)
91+ # https://github.com/AcademySoftwareFoundation/openvdb/issues/1718
92+ # https://github.com/AcademySoftwareFoundation/openvdb/issues/1624
93+ cmake_dependent_option(USE_EXPLICIT_INSTANTIATION "Use explicit instantiation for all supported classes
94+ and methods against a pre-defined list of OpenVDB trees. This makes the core library larger and slower
95+ to compile, but speeds up the compilation of all dependent code by bypassing the expensive template
96+ instantation." ON "NOT WIN32" OFF )
97+ option (OPENVDB_FUTURE_DEPRECATION "Generate messages for upcoming deprecation" ON )
98+ option (OPENVDB_ENABLE_UNINSTALL "Adds a CMake uninstall target." ON )
99+ option (USE_COLORED_OUTPUT "Always produce ANSI-colored output (GNU/Clang only)." OFF )
89100
101+ # Component dependency options
102+ cmake_dependent_option(USE_PKGCONFIG "Use pkg-config to search for dependent libraries." ON "NOT WIN32" OFF )
90103option (USE_HOUDINI [=[
91104Build the library against a Houdini installation. Turns on automatically if OPENVDB_BUILD_HOUDINI_PLUGIN is enabled.
92105When enabled, you do not need to provide dependency locations for TBB, Blosc, Imath and OpenEXR. Boost must be
@@ -121,7 +134,6 @@ option(USE_NANOVDB "Use NanoVDB while building openvdb components." ${OPENVDB_BU
121134
122135cmake_dependent_option(OPENVDB_DISABLE_BOOST_IMPLICIT_LINKING
123136 "Disable the implicit linking of Boost libraries on Windows" ON "WIN32" OFF )
124- option (USE_CCACHE "Build using Ccache if found on the path" ON )
125137option (USE_STATIC_DEPENDENCIES [=[
126138Only search for and use static libraries. If OFF the shared versions of requried libraries are prioritised, falling
127139back to static libraries. Forcing individual static dependencies can be enabled by setting XXX_USE_STATIC_LIBS
@@ -136,20 +148,6 @@ its default system search routine if it cannot find a dependency with the provid
136148paths provided through the Xxx_ROOT, supported XXX_INCLUDEDIR/XXX_LIBRARYDIR variables or the SYSTEM_LIBRARY_PATHS
137149list will be searched.]=] OFF )
138150
139- option (OPENVDB_FUTURE_DEPRECATION "Generate messages for upcoming deprecation" ON )
140- option (OPENVDB_ENABLE_UNINSTALL "Adds a CMake uninstall target." ON )
141- option (USE_COLORED_OUTPUT "Always produce ANSI-colored output (GNU/Clang only)." OFF )
142- cmake_dependent_option(USE_PKGCONFIG "Use pkg-config to search for dependent libraries." ON "NOT WIN32" OFF )
143-
144- # Disable this on Windows due to linker OOM issues:
145- # LNK1248: image size (XXX) exceeds maximum allowable size (FFFFFFFF)
146- # https://github.com/AcademySoftwareFoundation/openvdb/issues/1718
147- # https://github.com/AcademySoftwareFoundation/openvdb/issues/1624
148- cmake_dependent_option(USE_EXPLICIT_INSTANTIATION "Use explicit instantiation for all supported classes
149- and methods against a pre-defined list of OpenVDB trees. This makes the core library larger and slower
150- to compile, but speeds up the compilation of all dependent code by bypassing the expensive template
151- instantation." ON "NOT WIN32" OFF )
152-
153151set (SYSTEM_LIBRARY_PATHS "" CACHE STRING [=[
154152A global list of library paths to additionally use into when searching for dependencies.]=])
155153set (MSVC_MP_THREAD_COUNT "" CACHE STRING [=[
0 commit comments