depot/third_party/nixpkgs/pkgs/applications/misc/blender/draco.patch
Default email f34ce41345 Project import generated by Copybara.
GitOrigin-RevId: b73c2221a46c13557b1b3be9c2070cc42cf01eb3
2024-07-27 08:49:29 +02:00

26 lines
1.2 KiB
Diff

--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -898,11 +898,6 @@ set_and_warn_dependency(WITH_PYTHON WITH_CYCLES OFF)
set_and_warn_dependency(WITH_PYTHON WITH_DRACO OFF)
set_and_warn_dependency(WITH_PYTHON WITH_MOD_FLUID OFF)
-if(WITH_DRACO AND NOT WITH_PYTHON_INSTALL)
- message(STATUS "WITH_DRACO requires WITH_PYTHON_INSTALL to be ON, disabling WITH_DRACO for now")
- set(WITH_DRACO OFF)
-endif()
-
# enable boost for cycles, audaspace or i18n
# otherwise if the user disabled
--- a/scripts/addons_core/io_scene_gltf2/io/com/gltf2_io_draco_compression_extension.py
+++ b/scripts/addons_core/io_scene_gltf2/io/com/gltf2_io_draco_compression_extension.py
@@ -17,7 +17,7 @@ def dll_path() -> Path:
"""
lib_name = 'extern_draco'
- blender_root = Path(bpy.app.binary_path).parent
+ blender_root = Path(bpy.app.binary_path).parent.parent
- python_lib = Path('{v[0]}.{v[1]}/python/lib'.format(v=bpy.app.version))
+ python_lib = Path('share/blender/{v[0]}.{v[1]}/python-ext/lib'.format(v=bpy.app.version))
python_version = 'python{v[0]}.{v[1]}'.format(v=sys.version_info)
path = os.environ.get('BLENDER_EXTERN_DRACO_LIBRARY_PATH')