Windows MSVC allow building with openvdb / tbb
authorMartijn Berger <martijn.berger@gmail.com>
Wed, 10 Feb 2016 12:59:04 +0000 (13:59 +0100)
committerMartijn Berger <martijn.berger@gmail.com>
Wed, 10 Feb 2016 12:59:04 +0000 (13:59 +0100)
CMakeLists.txt

index d2d87270fd0d4e556f1773d126f5dc763fdc0f6f..4e623d587bc2a332789aefdfc736fc164d3bf7bf 100644 (file)
@@ -1423,7 +1423,7 @@ elseif(WIN32)
                                message(WARNING "Using HARDCODED OpenEXR locations")
                                set(OPENEXR ${LIBDIR}/openexr)
                                set(OPENEXR_INCLUDE_DIR ${OPENEXR}/include)
-                               set(OPENEXR_INCLUDE_DIRS ${OPENEXR}/include/OpenEXR)
+                               set(OPENEXR_INCLUDE_DIRS ${OPENEXR_INCLUDE_DIR} ${OPENEXR}/include/OpenEXR)
                                set(OPENEXR_LIBPATH ${OPENEXR}/lib)
                                set(OPENEXR_LIBRARIES
                                        ${OPENEXR_LIBPATH}/Iex-2_2.lib
@@ -1476,6 +1476,9 @@ elseif(WIN32)
                        if(WITH_INTERNATIONAL)
                                list(APPEND boost_extra_libs locale)
                        endif()
+                       if(WITH_OPENVDB)
+                               list(APPEND boost_extra_libs iostreams)
+                       endif()
                        set(Boost_USE_STATIC_RUNTIME ON) # prefix lib
                        set(Boost_USE_MULTITHREADED ON) # suffix -mt
                        set(Boost_USE_STATIC_LIBS ON) # suffix -s
@@ -1566,11 +1569,12 @@ elseif(WIN32)
                endif()
 
                if(WITH_OPENVDB)
+                       set(TBB_LIBRARIES ${LIBDIR}/tbb/lib/tbb.lib)
+                       set(TBB_INCLUDE_DIR ${LIBDIR}/tbb/include)
                        set(OPENVDB ${LIBDIR}/openvdb)
-                       set(OPENVDB_INCLUDE_DIRS ${OPENVDB}/include)
+                       set(OPENVDB_INCLUDE_DIRS ${OPENVDB}/include ${TBB_INCLUDE_DIR})
                        set(OPENVDB_LIBRARIES openvdb ${TBB_LIBRARIES})
                        set(OPENVDB_LIBPATH ${LIBDIR}/openvdb/lib)
-                       set(OPENVDB_DEFINITIONS)
                endif()
 
                if(WITH_MOD_CLOTH_ELTOPO)