[Cmake-commits] CMake branch, next, updated. v2.8.8-3006-g6de3ce0

Stephen Kelly steveire at gmail.com
Tue Jun 5 13:47:20 EDT 2012


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".

The branch, next has been updated
       via  6de3ce053ebba24c0390be79aae01dbbc835a56d (commit)
       via  ce35b578ab12b248a955f5aff1410e9daf152054 (commit)
      from  2ec9474a245b35c4f4f8b1e30becc08b35725b1b (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=6de3ce053ebba24c0390be79aae01dbbc835a56d
commit 6de3ce053ebba24c0390be79aae01dbbc835a56d
Merge: 2ec9474 ce35b57
Author:     Stephen Kelly <steveire at gmail.com>
AuthorDate: Tue Jun 5 13:47:19 2012 -0400
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Tue Jun 5 13:47:19 2012 -0400

    Merge topic 'position-independent-targets' into next
    
    ce35b57 Don't set the PIE compile option variable on old GCC.


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=ce35b578ab12b248a955f5aff1410e9daf152054
commit ce35b578ab12b248a955f5aff1410e9daf152054
Author:     Stephen Kelly <steveire at gmail.com>
AuthorDate: Tue Jun 5 19:45:19 2012 +0200
Commit:     Stephen Kelly <steveire at gmail.com>
CommitDate: Tue Jun 5 19:45:19 2012 +0200

    Don't set the PIE compile option variable on old GCC.
    
    According to
    
    http://www.linuxfromscratch.org/~manuel/hlfs-book/
    glibc-2.4/chapter02/pie.html
    
    it has been available since version 3.4.

diff --git a/Modules/Compiler/GNU.cmake b/Modules/Compiler/GNU.cmake
index bbc07e7..2829e8b 100644
--- a/Modules/Compiler/GNU.cmake
+++ b/Modules/Compiler/GNU.cmake
@@ -22,7 +22,9 @@ macro(__compiler_gnu lang)
   # Feature flags.
   set(CMAKE_${lang}_VERBOSE_FLAG "-v")
   set(CMAKE_${lang}_COMPILE_OPTIONS_PIC "-fPIC")
-  set(CMAKE_${lang}_COMPILE_OPTIONS_PIE "-fPIE")
+  if(NOT CMAKE_C_COMPILER_VERSION VERSION_LESS 3.4)
+    set(CMAKE_${lang}_COMPILE_OPTIONS_PIE "-fPIE")
+  endif()
   set(CMAKE_SHARED_LIBRARY_${lang}_FLAGS "-fPIC")
   set(CMAKE_SHARED_LIBRARY_CREATE_${lang}_FLAGS "-shared")
 

-----------------------------------------------------------------------

Summary of changes:
 Modules/Compiler/GNU.cmake |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list