[Cmake-commits] CMake branch, next, updated. v3.0.0-3711-g4827bdf

Stephen Kelly steveire at gmail.com
Fri Jun 13 05:16:17 EDT 2014


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  4827bdf8f07bac2a3dda0280f8ef5c516a8902fa (commit)
       via  631f0c6edda3e3546910e02a18650d17888dc0ab (commit)
       via  52cc7306f9f74133c225f01b416a476ce11686f6 (commit)
       via  6699d2b084f80d439e47884423d592da50e17628 (commit)
       via  f8c6b43b56fb9594ad3b5d8505db809cfaf40eaf (commit)
      from  4276648a2e50e4e3b977c875108dcdfe7252f496 (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=4827bdf8f07bac2a3dda0280f8ef5c516a8902fa
commit 4827bdf8f07bac2a3dda0280f8ef5c516a8902fa
Merge: 4276648 631f0c6
Author:     Stephen Kelly <steveire at gmail.com>
AuthorDate: Fri Jun 13 05:16:16 2014 -0400
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Fri Jun 13 05:16:16 2014 -0400

    Merge topic 'features-cleanups' into next
    
    631f0c6e WCDH: Fix compiler id test for compatibility macros.
    52cc7306 Project: Detect other compilers before detecting Clang.
    6699d2b0 WCDH: Remove noise from generated defines.
    f8c6b43b Features: Escape the COMPILE_OPTIONS for dialects.


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=631f0c6edda3e3546910e02a18650d17888dc0ab
commit 631f0c6edda3e3546910e02a18650d17888dc0ab
Author:     Stephen Kelly <steveire at gmail.com>
AuthorDate: Fri Jun 13 11:08:34 2014 +0200
Commit:     Stephen Kelly <steveire at gmail.com>
CommitDate: Fri Jun 13 11:09:19 2014 +0200

    WCDH: Fix compiler id test for compatibility macros.
    
    Enable the alignment features for Clang.

diff --git a/Modules/WriteCompilerDetectionHeader.cmake b/Modules/WriteCompilerDetectionHeader.cmake
index fb0dda1..593176c 100644
--- a/Modules/WriteCompilerDetectionHeader.cmake
+++ b/Modules/WriteCompilerDetectionHeader.cmake
@@ -428,7 +428,7 @@ function(write_compiler_detection_header
         set(file_content "${file_content}
 #  if ${def_name}
 #    define ${def_value} alignas(X)
-#  elif ${prefix_arg}_COMPILER_IS_GNU
+#  elif ${prefix_arg}_COMPILER_IS_GNU || ${prefix_arg}_COMPILER_IS_Clang
 #    define ${def_value} __attribute__ ((__aligned__(X)))
 #  else
 #    define ${def_value}
@@ -440,7 +440,7 @@ function(write_compiler_detection_header
         set(file_content "${file_content}
 #  if ${def_name}
 #    define ${def_value} alignof(X)
-#  elif ${prefix_arg}_COMPILER_IS_GNU
+#  elif ${prefix_arg}_COMPILER_IS_GNU || ${prefix_arg}_COMPILER_IS_Clang
 #    define ${def_value} __alignof__(X)
 #  endif
 \n")
@@ -495,10 +495,10 @@ function(write_compiler_detection_header
 #    if ${def_name}
 #      define ${def_value} [[deprecated]]
 #      define ${def_value}_MSG(MSG) [[deprecated(MSG)]]
-#    elif defined(__GNUC__) || defined(__clang__)
+#    elif ${prefix_arg}_COMPILER_IS_GNU || ${prefix_arg}_COMPILER_IS_Clang
 #      define ${def_value} __attribute__((__deprecated__))
 #      define ${def_value}_MSG(MSG) __attribute__((__deprecated__(MSG)))
-#    elif defined(_MSC_VER)
+#    elif ${prefix_arg}_COMPILER_IS_MSVC
 #      define ${def_value} __declspec(deprecated)
 #      define ${def_value}_MSG(MSG) __declspec(deprecated(MSG))
 #    else

http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=52cc7306f9f74133c225f01b416a476ce11686f6
commit 52cc7306f9f74133c225f01b416a476ce11686f6
Author:     Stephen Kelly <steveire at gmail.com>
AuthorDate: Fri Jun 13 10:50:07 2014 +0200
Commit:     Stephen Kelly <steveire at gmail.com>
CommitDate: Fri Jun 13 10:56:24 2014 +0200

    Project: Detect other compilers before detecting Clang.
    
    Commit v2.8.10.1~5^2 (Fix PathScale compiler id for Clang-based
    upstream, 2012-11-05) re-ordered the detection logic for PathScale.
    
    Other compiler vendors are also producing Clang-based frontends, so
    detect "actual" Clang as one of the last compilers to allow for others
    doing the same.
    
        http://llvm.org/devmtg/2014-04/PDFs/Posters/ClangIntel.pdf
        http://docwiki.embarcadero.com/RADStudio/XE5/en/Clang-based_C%2B%2B_Compilers

diff --git a/Modules/CMakeCompilerIdDetection.cmake b/Modules/CMakeCompilerIdDetection.cmake
index 7f82a9d..e247885 100644
--- a/Modules/CMakeCompilerIdDetection.cmake
+++ b/Modules/CMakeCompilerIdDetection.cmake
@@ -61,8 +61,6 @@ function(compiler_id_detection outvar lang)
     list(APPEND ordered_compilers
       Intel
       PathScale
-      AppleClang
-      Clang
       Embarcadero
       Borland
       Watcom
@@ -84,6 +82,8 @@ function(compiler_id_detection outvar lang)
     endif()
     list(APPEND ordered_compilers
       SCO
+      AppleClang
+      Clang
       GNU
       MSVC
       ADSP

http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=6699d2b084f80d439e47884423d592da50e17628
commit 6699d2b084f80d439e47884423d592da50e17628
Author:     Stephen Kelly <steveire at gmail.com>
AuthorDate: Fri Jun 13 10:46:27 2014 +0200
Commit:     Stephen Kelly <steveire at gmail.com>
CommitDate: Fri Jun 13 10:46:27 2014 +0200

    WCDH: Remove noise from generated defines.
    
    The DECL part is redundant, and the language part is not needed. The
    source language and context already determines the language, so there
    is no need to repeat it in the define name.

diff --git a/Help/manual/cmake-compile-features.7.rst b/Help/manual/cmake-compile-features.7.rst
index d4bbecc..8a2fe30 100644
--- a/Help/manual/cmake-compile-features.7.rst
+++ b/Help/manual/cmake-compile-features.7.rst
@@ -166,11 +166,11 @@ symbol, and compiler support determines what it is expanded to:
     virtual void Execute() = 0;
   };
 
-  struct Concrete Foo_CXX_FINAL {
-    void Execute() Foo_CXX_OVERRIDE;
+  struct Concrete Foo_FINAL {
+    void Execute() Foo_OVERRIDE;
   };
 
-In this case, ``Foo_CXX_FINAL`` will expand to ``final`` if the
+In this case, ``Foo_FINAL`` will expand to ``final`` if the
 compiler supports the keyword, or to empty otherwise.
 
 In this use-case, the CMake code will wish to enable a particular language
@@ -189,13 +189,13 @@ set to influence all following targets:
       cxx_final cxx_override
   )
 
-  # Includes foo_compiler_detection.h and uses the Foo_DECL_CXX_FINAL symbol
+  # Includes foo_compiler_detection.h and uses the Foo_FINAL symbol
   # which will expand to 'final' if the compiler supports the requested
   # CXX_STANDARD.
   add_library(foo foo.cpp)
   set_property(TARGET foo PROPERTY CXX_STANDARD 11)
 
-  # Includes foo_compiler_detection.h and uses the Foo_DECL_CXX_FINAL symbol
+  # Includes foo_compiler_detection.h and uses the Foo_FINAL symbol
   # which will expand to 'final' if the compiler supports the feature,
   # even though CXX_STANDARD is not set explicitly.  The requirement of
   # cxx_constexpr causes CMake to set CXX_STANDARD internally, which
diff --git a/Modules/WriteCompilerDetectionHeader.cmake b/Modules/WriteCompilerDetectionHeader.cmake
index d7992fe..fb0dda1 100644
--- a/Modules/WriteCompilerDetectionHeader.cmake
+++ b/Modules/WriteCompilerDetectionHeader.cmake
@@ -99,14 +99,14 @@
 #
 # .. code-block:: c++
 #
-#    class MyClass ClimbingStats_DECL_CXX_FINAL
+#    class MyClass ClimbingStats_FINAL
 #    {
-#        ClimbingStats_DECL_CXX_CONSTEXPR int someInterface() { return 42; }
+#        ClimbingStats_CONSTEXPR int someInterface() { return 42; }
 #    };
 #
-# The ``ClimbingStats_DECL_CXX_FINAL`` macro will expand to ``final`` if the
+# The ``ClimbingStats_FINAL`` macro will expand to ``final`` if the
 # compiler (and its flags) support the ``cxx_final`` feature, and the
-# ``ClimbingStats_DECL_CXX_CONSTEXPR`` macro will expand to ``constexpr``
+# ``ClimbingStats_CONSTEXPR`` macro will expand to ``constexpr``
 # if ``cxx_constexpr`` is supported.
 #
 # The following features generate corresponding symbol defines:
@@ -386,7 +386,7 @@ function(write_compiler_detection_header
 \n")
       endif()
       if (feature STREQUAL cxx_constexpr)
-        set(def_value "${prefix_arg}_DECL_${feature_upper}")
+        set(def_value "${prefix_arg}_CONSTEXPR")
         set(file_content "${file_content}
 #  if ${def_name}
 #    define ${def_value} constexpr
@@ -396,7 +396,7 @@ function(write_compiler_detection_header
 \n")
       endif()
       if (feature STREQUAL cxx_final)
-        set(def_value "${prefix_arg}_DECL_${feature_upper}")
+        set(def_value "${prefix_arg}_FINAL")
         set(file_content "${file_content}
 #  if ${def_name}
 #    define ${def_value} final
@@ -406,7 +406,7 @@ function(write_compiler_detection_header
 \n")
       endif()
       if (feature STREQUAL cxx_override)
-        set(def_value "${prefix_arg}_DECL_${feature_upper}")
+        set(def_value "${prefix_arg}_OVERRIDE")
         set(file_content "${file_content}
 #  if ${def_name}
 #    define ${def_value} override

http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=f8c6b43b56fb9594ad3b5d8505db809cfaf40eaf
commit f8c6b43b56fb9594ad3b5d8505db809cfaf40eaf
Author:     Stephen Kelly <steveire at gmail.com>
AuthorDate: Fri Jun 13 10:30:57 2014 +0200
Commit:     Stephen Kelly <steveire at gmail.com>
CommitDate: Fri Jun 13 10:42:57 2014 +0200

    Features: Escape the COMPILE_OPTIONS for dialects.
    
    Allow for future handling as a list, not a string which may contain
    whitespace.

diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx
index c8c8c79..30ba220 100644
--- a/Source/cmLocalGenerator.cxx
+++ b/Source/cmLocalGenerator.cxx
@@ -2229,7 +2229,7 @@ AddCompilerRequirementFlag(std::string &flags, cmTarget* target,
            "does not know the compile flags to use to enable it.";
       this->GetMakefile()->IssueMessage(cmake::FATAL_ERROR, e.str());
       }
-    this->AppendFlags(flags, opt);
+    this->AppendFlagEscape(flags, opt);
     return;
     }
 
@@ -2275,7 +2275,7 @@ AddCompilerRequirementFlag(std::string &flags, cmTarget* target,
 
     if (const char *opt = target->GetMakefile()->GetDefinition(option_flag))
       {
-      this->AppendFlags(flags, opt);
+      this->AppendFlagEscape(flags, opt);
       return;
       }
     }

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

Summary of changes:
 Help/manual/cmake-compile-features.7.rst   |   10 +++++-----
 Modules/CMakeCompilerIdDetection.cmake     |    4 ++--
 Modules/WriteCompilerDetectionHeader.cmake |   22 +++++++++++-----------
 Source/cmLocalGenerator.cxx                |    4 ++--
 4 files changed, 20 insertions(+), 20 deletions(-)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list