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:
authorAntony Riakiotakis <kalast@gmail.com>2015-05-04 18:34:32 +0300
committerAntony Riakiotakis <kalast@gmail.com>2015-05-04 18:34:32 +0300
commitdc7d07753f537a89068dd770a7b264f8cbbb6d47 (patch)
tree5580a1dde4a2a878543442b9039840fe2b0d8c1e /CMakeLists.txt
parent920aa5e7d2da91805acb8e2c2963fd908f873eeb (diff)
parent1227e5c3d1ee20e9af57984a261b1d51d48c0263 (diff)
Merge branch 'master' into gooseberry
Conflicts: source/blender/editors/space_sequencer/sequencer_draw.c
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt13
1 files changed, 13 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index ff7c10f785c..3416a3f5756 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1185,6 +1185,19 @@ if(UNIX AND NOT APPLE)
# though some c11 features can still be used.
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu89")
endif()
+
+ # use ld.gold linker if available, could make optional
+ execute_process(
+ COMMAND ${CMAKE_C_COMPILER} -fuse-ld=gold -Wl,--version
+ ERROR_QUIET OUTPUT_VARIABLE LD_VERSION)
+ if ("${LD_VERSION}" MATCHES "GNU gold")
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fuse-ld=gold")
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fuse-ld=gold")
+ else ()
+ message(INFO "GNU gold linker isn't available, using the default system linker.")
+ endif ()
+ unset(LD_VERSION)
+
# CLang is the same as GCC for now.
elseif(CMAKE_C_COMPILER_ID MATCHES "Clang")
set(PLATFORM_CFLAGS "-pipe -fPIC -funsigned-char -fno-strict-aliasing")