blender/build_files/build_environment/patches/usd.diff
2026-09-10 17:04:08 +02:00

43 lines
1.3 KiB
Diff

diff --git a/cmake/macros/Private.cmake b/cmake/macros/Private.cmake
index e2dccb075..fc71099ce 100644
--- a/cmake/macros/Private.cmake
+++ b/cmake/macros/Private.cmake
@@ -968,7 +968,7 @@ function(_pxr_python_module NAME)
return()
endif()
- if (WIN32 AND PXR_USE_DEBUG_PYTHON)
+ if (WIN32 AND PXR_USE_DEBUG_PYTHON AND NOT "${CMAKE_DEBUG_POSTFIX}" STREQUAL "_d")
# On Windows when compiling with debug python the library must be named with _d.
set(LIBRARY_NAME "_${NAME}_d")
else()
diff --git a/pxr/imaging/hioOpenVDB/CMakeLists.txt b/pxr/imaging/hioOpenVDB/CMakeLists.txt
index c94b63c5a..b3bcae4eb 100644
--- a/pxr/imaging/hioOpenVDB/CMakeLists.txt
+++ b/pxr/imaging/hioOpenVDB/CMakeLists.txt
@@ -20,6 +20,12 @@ else()
LIST(APPEND __VDB_IMATH_LIBS ${OPENEXR_Half_LIBRARY})
endif()
+if (WIN32)
+ # OpenVDB uses constants from <cmath> that aren't available on
+ # Windows unless this is defined.
+ add_definitions(-D_USE_MATH_DEFINES)
+endif()
+
pxr_library(hioOpenVDB
LIBRARIES
ar
diff --git a/pxr/usdImaging/CMakeLists.txt b/pxr/usdImaging/CMakeLists.txt
index 53c026689..e99a5ac17 100644
--- a/pxr/usdImaging/CMakeLists.txt
+++ b/pxr/usdImaging/CMakeLists.txt
@@ -7,7 +7,7 @@ set(DIRS
usdVolImaging
usdAppUtils
usdviewq
- bin
+# bin
plugin
)