File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed
Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -58,7 +58,15 @@ if(OPENVDB_TOOL_USE_NANO)
5858 endif ()
5959 #target_include_directories(vdb_tool_common INTERFACE ${PROJECT_SOURCE_DIR}/../nanovdb/)
6060 if (NOT OPENVDB_BUILD_NANOVDB)
61- message (FATAL_ERROR "Please pass -DUSE_NANOVDB=ON as a cmake argument." )
61+ find_package (OpenVDB COMPONENTS nanovdb)
62+ if (NOT OpenVDB_nanovdb_FOUND OR NOT OpenVDB_FOUND)
63+ message (FATAL_ERROR
64+ " Couldn't find NanoVDB\n "
65+ " Either set OPENVDB_CMAKE_PATH to <OpenVDB install path>/lib/cmake/OpenVDB"
66+ " or please pass -DUSE_NANOVDB=ON as a cmake argument." )
67+ endif ()
68+ set (NANOVDB_LIB OpenVDB::nanovdb)
69+ target_include_directories (vdb_tool_common INTERFACE ${OPENVDB_nanovdb_INCLUDE_DIR} )
6270 else ()
6371 set (NANOVDB_LIB nanovdb)
6472 endif ()
You can’t perform that action at this time.
0 commit comments