From c7a5c48cbad0062c55bf9fa6df2926646b2c3091 Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Fri, 21 Apr 2017 10:58:01 +0200 Subject: CMake: Add option to link against system-wide Gflags library It is disabled by default, so should not affect existing configurations. Main benefits of this goes as: - Linux distros can use that to avoid libraries duplication and link blender package against gflags package from the system. - It it easier to test whether Blender works with updated version of Gflags prior to re-bundling the library. --- source/blenderplayer/CMakeLists.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'source/blenderplayer') diff --git a/source/blenderplayer/CMakeLists.txt b/source/blenderplayer/CMakeLists.txt index 58bebc66a3e..e0afd84db82 100644 --- a/source/blenderplayer/CMakeLists.txt +++ b/source/blenderplayer/CMakeLists.txt @@ -177,10 +177,13 @@ endif() extern_wcwidth bf_intern_libmv extern_glog - extern_gflags extern_sdlew ) + if(NOT WITH_SYSTEM_GFLAGS) + list(APPEND BLENDER_SORTED_LIBS extern_gflags) + endif() + if(WITH_MOD_CLOTH_ELTOPO) list(APPEND BLENDER_SORTED_LIBS extern_eltopo) endif() -- cgit v1.2.3