Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2013-01-03 04:23:52 +0400
committerCampbell Barton <ideasman42@gmail.com>2013-01-03 04:23:52 +0400
commitc2839bfe76139ed753e6b99118001bba5f2fa6ee (patch)
treeb1edb08f125ccf8220e41d359ef80c38f6213f32 /CMakeLists.txt
parent1a7638fa94fbe9c6244d054d20efa3405153747f (diff)
add option WITH_SYSTEM_BULLET to link against the bullet installation found on the system.
Note: this doesn't work yet for everything with latest stable bullet (2.81), need to look into why and likely apply some patches upstream. However I managed to link blender by disabling some features, likely it can be made to work without too much trouble.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt18
1 files changed, 17 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index a87c3e2d96d..fd5a3769b2a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -129,6 +129,8 @@ option(WITH_IK_ITASC "Enable ITASC IK solver (only disable for development
option(WITH_IK_SOLVER "Enable Legacy IK solver (only disable for development)" ON)
option(WITH_FFTW3 "Enable FFTW3 support (Used for smoke and audio effects)" ON)
option(WITH_BULLET "Enable Bullet (Physics Engine)" ON)
+option(WITH_SYSTEM_BULLET "Use the systems bullet library (currently unsupported due to missing features in upstream!)" )
+mark_as_advanced(WITH_SYSTEM_BULLET)
option(WITH_GAMEENGINE "Enable Game Engine" ON)
option(WITH_PLAYER "Build Player" OFF)
option(WITH_OPENCOLORIO "Enable OpenColorIO color management" ON)
@@ -1842,12 +1844,26 @@ else()
set(GLEW_INCLUDE_PATH "${CMAKE_SOURCE_DIR}/extern/glew/include")
endif()
+
+#-----------------------------------------------------------------------------
+# Configure Bullet
+
+if(WITH_BULLET AND WITH_SYSTEM_BULLET)
+ find_package(Bullet)
+ if(NOT BULLET_FOUND)
+ set(WITH_BULLET OFF)
+ endif()
+else()
+ set(BULLET_INCLUDE_DIRS "${CMAKE_SOURCE_DIR}/extern/bullet2/src")
+ # set(BULLET_LIBRARIES "")
+endif()
+
#-----------------------------------------------------------------------------
# Configure Python.
if(WITH_PYTHON_MODULE)
add_definitions(-DPy_ENABLE_SHARED)
-endif()
+endif().
#-----------------------------------------------------------------------------
# Extra compile flags