diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-01-03 04:23:52 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-01-03 04:23:52 +0400 |
commit | c2839bfe76139ed753e6b99118001bba5f2fa6ee (patch) | |
tree | b1edb08f125ccf8220e41d359ef80c38f6213f32 /source | |
parent | 1a7638fa94fbe9c6244d054d20efa3405153747f (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 'source')
-rw-r--r-- | source/blender/blenkernel/CMakeLists.txt | 2 | ||||
-rw-r--r-- | source/blender/bmesh/CMakeLists.txt | 4 | ||||
-rw-r--r-- | source/creator/CMakeLists.txt | 5 | ||||
-rw-r--r-- | source/gameengine/BlenderRoutines/CMakeLists.txt | 9 | ||||
-rw-r--r-- | source/gameengine/Converter/CMakeLists.txt | 2 | ||||
-rw-r--r-- | source/gameengine/Ketsji/CMakeLists.txt | 2 | ||||
-rw-r--r-- | source/gameengine/Physics/Bullet/CMakeLists.txt | 4 |
7 files changed, 21 insertions, 7 deletions
diff --git a/source/blender/blenkernel/CMakeLists.txt b/source/blender/blenkernel/CMakeLists.txt index 99008309498..aca06a1abcf 100644 --- a/source/blender/blenkernel/CMakeLists.txt +++ b/source/blender/blenkernel/CMakeLists.txt @@ -259,7 +259,7 @@ endif() if(WITH_BULLET) list(APPEND INC_SYS - ../../../extern/bullet2/src + ${BULLET_INCLUDE_DIRS} ) add_definitions(-DUSE_BULLET) endif() diff --git a/source/blender/bmesh/CMakeLists.txt b/source/blender/bmesh/CMakeLists.txt index 955b18c3db7..d11d74888ca 100644 --- a/source/blender/bmesh/CMakeLists.txt +++ b/source/blender/bmesh/CMakeLists.txt @@ -30,7 +30,6 @@ set(INC ../blenlib ../makesdna ../../../intern/guardedalloc - ../../../extern/bullet2/src ../../../extern/rangetree ../../../intern/opennl/extern ) @@ -127,6 +126,9 @@ endif() if(WITH_BULLET) add_definitions(-DWITH_BULLET) + list(APPEND INC_SYS + ${BULLET_INCLUDE_DIRS} + ) endif() if(WITH_INTERNATIONAL) diff --git a/source/creator/CMakeLists.txt b/source/creator/CMakeLists.txt index c53f27c7326..3fa646ac884 100644 --- a/source/creator/CMakeLists.txt +++ b/source/creator/CMakeLists.txt @@ -893,7 +893,6 @@ endif() ge_scenegraph ge_logic_network ge_logic_ngnetwork - extern_bullet ge_logic_loopbacknetwork bf_intern_moto extern_openjpeg @@ -972,6 +971,10 @@ endif() list(APPEND BLENDER_SORTED_LIBS bf_intern_locale) endif() + if(WITH_BULLET AND NOT WITH_BULLET_SYSTEM) + list_insert_after(BLENDER_SORTED_LIBS "ge_logic_ngnetwork" "extern_bullet") + endif() + foreach(SORTLIB ${BLENDER_SORTED_LIBS}) set(REMLIB ${SORTLIB}) foreach(SEARCHLIB ${BLENDER_LINK_LIBS}) diff --git a/source/gameengine/BlenderRoutines/CMakeLists.txt b/source/gameengine/BlenderRoutines/CMakeLists.txt index 9a47d223f76..d833534605b 100644 --- a/source/gameengine/BlenderRoutines/CMakeLists.txt +++ b/source/gameengine/BlenderRoutines/CMakeLists.txt @@ -30,7 +30,6 @@ set(INC ) set(INC_SYS - ../../../extern/bullet2/src ${PTHREADS_INCLUDE_DIRS} ${GLEW_INCLUDE_PATH} ${BOOST_INCLUDE_DIR} @@ -70,4 +69,12 @@ if(WITH_CODEC_FFMPEG) add_definitions(-DWITH_FFMPEG) endif() +if(WITH_BULLET) + list(APPEND INC_SYS + ${BULLET_INCLUDE_DIRS} + ) + add_definitions(-DUSE_BULLET) +endif() + + blender_add_lib(ge_blen_routines "${SRC}" "${INC}" "${INC_SYS}") diff --git a/source/gameengine/Converter/CMakeLists.txt b/source/gameengine/Converter/CMakeLists.txt index e01729e156f..8ac9e523d5d 100644 --- a/source/gameengine/Converter/CMakeLists.txt +++ b/source/gameengine/Converter/CMakeLists.txt @@ -112,7 +112,7 @@ set(SRC if(WITH_BULLET) list(APPEND INC_SYS - ../../../extern/bullet2/src + ${BULLET_INCLUDE_DIRS} ) add_definitions(-DUSE_BULLET) endif() diff --git a/source/gameengine/Ketsji/CMakeLists.txt b/source/gameengine/Ketsji/CMakeLists.txt index 524a38a4c26..e42c2a74a8e 100644 --- a/source/gameengine/Ketsji/CMakeLists.txt +++ b/source/gameengine/Ketsji/CMakeLists.txt @@ -252,7 +252,7 @@ if(WITH_BULLET) ../Physics/Bullet ) list(APPEND INC - ../../../extern/bullet2/src + ${BULLET_INCLUDE_DIRS} ) add_definitions(-DUSE_BULLET) endif() diff --git a/source/gameengine/Physics/Bullet/CMakeLists.txt b/source/gameengine/Physics/Bullet/CMakeLists.txt index 43b1bfe7468..afb166eee57 100644 --- a/source/gameengine/Physics/Bullet/CMakeLists.txt +++ b/source/gameengine/Physics/Bullet/CMakeLists.txt @@ -44,7 +44,6 @@ set(INC ) set(INC_SYS - ../../../../extern/bullet2/src ${GLEW_INCLUDE_PATH} ${PYTHON_INCLUDE_DIRS} ) @@ -60,6 +59,9 @@ set(SRC ) if(WITH_BULLET) + list(APPEND INC + ${BULLET_INCLUDE_DIRS} + ) add_definitions(-DUSE_BULLET) endif() |