NO-JIRA: Fix broken CMake initialisation of BUILD_WITH_CXX git-svn-id: https://svn.apache.org/repos/asf/qpid/proton/trunk@1628523 13f79535-47bb-0310-9956-ffa450edef68
Project: http://git-wip-us.apache.org/repos/asf/qpid-proton/repo Commit: http://git-wip-us.apache.org/repos/asf/qpid-proton/commit/8cc810a8 Tree: http://git-wip-us.apache.org/repos/asf/qpid-proton/tree/8cc810a8 Diff: http://git-wip-us.apache.org/repos/asf/qpid-proton/diff/8cc810a8 Branch: refs/heads/examples Commit: 8cc810a8c2382cc0b6ce9e75170eaf3f7a77d619 Parents: 5d32449 Author: Andrew Stitcher <[email protected]> Authored: Tue Sep 30 19:46:27 2014 +0000 Committer: Andrew Stitcher <[email protected]> Committed: Tue Sep 30 19:46:27 2014 +0000 ---------------------------------------------------------------------- CMakeLists.txt | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/8cc810a8/CMakeLists.txt ---------------------------------------------------------------------- diff --git a/CMakeLists.txt b/CMakeLists.txt index d7b081f..7d1fba7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -26,11 +26,12 @@ if (CMAKE_BUILD_TYPE MATCHES "Deb") endif (CMAKE_BUILD_TYPE MATCHES "Deb") message(STATUS "Build type is \"${CMAKE_BUILD_TYPE}\"${has_debug_symbols}") -option(BUILD_WITH_CXX "Compile Proton using C++" OFF) -if ("${CMAKE_GENERATOR}" MATCHES "^Visual Studio") + +if (MSVC) # No C99 capability, use C++ - set(BUILD_WITH_CXX ON) -endif ("${CMAKE_GENERATOR}" MATCHES "^Visual Studio") + set(DEFAULT_BUILD_WITH_CXX ON) +endif (MSVC) +option(BUILD_WITH_CXX "Compile Proton using C++" ${DEFAULT_BUILD_WITH_CXX}) if (BUILD_WITH_CXX) project (Proton C CXX) --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
