diff options
-rw-r--r-- | CMakeLists.txt | 10 | ||||
-rw-r--r-- | build_files/cmake/config/blender_lite.cmake | 1 | ||||
-rw-r--r-- | source/blender/CMakeLists.txt | 5 | ||||
-rw-r--r-- | source/creator/CMakeLists.txt | 20 |
4 files changed, 27 insertions, 9 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 16842f3134b..544e22f342b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -156,6 +156,16 @@ get_blender_version() option(WITH_BLENDER "Build blender (disable to build only the blender player)" ON) mark_as_advanced(WITH_BLENDER) +if(APPLE) + # Currently this causes a build error linking, disable. + set(WITH_BLENDER_THUMBNAILER OFF) +elseif(WIN32) + # Building the thumbnail extraction DLL could be made optional. + set(WITH_BLENDER_THUMBNAILER ON) +else() + option(WITH_BLENDER_THUMBNAILER "Build \"blender-thumbnailer\" thumbnail extraction utility" ON) +endif() + option(WITH_INTERNATIONAL "Enable I18N (International fonts and text)" ON) option(WITH_PYTHON "Enable Embedded Python API (only disable for development)" ON) diff --git a/build_files/cmake/config/blender_lite.cmake b/build_files/cmake/config/blender_lite.cmake index 0cd886e67d7..89bd46ecd7d 100644 --- a/build_files/cmake/config/blender_lite.cmake +++ b/build_files/cmake/config/blender_lite.cmake @@ -9,6 +9,7 @@ set(WITH_INSTALL_PORTABLE ON CACHE BOOL "" FORCE) set(WITH_ALEMBIC OFF CACHE BOOL "" FORCE) set(WITH_AUDASPACE OFF CACHE BOOL "" FORCE) +set(WITH_BLENDER_THUMBNAILER OFF CACHE BOOL "" FORCE) set(WITH_BOOST OFF CACHE BOOL "" FORCE) set(WITH_BUILDINFO OFF CACHE BOOL "" FORCE) set(WITH_BULLET OFF CACHE BOOL "" FORCE) diff --git a/source/blender/CMakeLists.txt b/source/blender/CMakeLists.txt index 0a494677d96..c6112344208 100644 --- a/source/blender/CMakeLists.txt +++ b/source/blender/CMakeLists.txt @@ -131,7 +131,10 @@ add_subdirectory(io) add_subdirectory(functions) add_subdirectory(makesdna) add_subdirectory(makesrna) -add_subdirectory(blendthumb) + +if(WITH_BLENDER_THUMBNAILER) + add_subdirectory(blendthumb) +endif() if(WITH_COMPOSITOR) add_subdirectory(compositor) diff --git a/source/creator/CMakeLists.txt b/source/creator/CMakeLists.txt index 45bfc3d6bdb..1d5d1491c7a 100644 --- a/source/creator/CMakeLists.txt +++ b/source/creator/CMakeLists.txt @@ -515,10 +515,12 @@ if(UNIX AND NOT APPLE) DESTINATION "." ) - install( - TARGETS blender-thumbnailer - DESTINATION "." - ) + if(WITH_BLENDER_THUMBNAILER) + install( + TARGETS blender-thumbnailer + DESTINATION "." + ) + endif() if(EXISTS ${LIBDIR}/mesa) install(DIRECTORY ${LIBDIR}/mesa/lib DESTINATION ".") @@ -558,10 +560,12 @@ if(UNIX AND NOT APPLE) FILES ${CMAKE_SOURCE_DIR}/release/freedesktop/icons/symbolic/apps/blender-symbolic.svg DESTINATION share/icons/hicolor/symbolic/apps ) - install( - TARGETS blender-thumbnailer - DESTINATION bin - ) + if(WITH_BLENDER_THUMBNAILER) + install( + TARGETS blender-thumbnailer + DESTINATION bin + ) + endif() set(BLENDER_TEXT_FILES_DESTINATION share/doc/blender) endif() |