diff options
59 files changed, 1198 insertions, 186 deletions
diff --git a/CMakeCPack.cmake b/CMakeCPack.cmake index b27cd69..66ec900 100644 --- a/CMakeCPack.cmake +++ b/CMakeCPack.cmake @@ -65,16 +65,9 @@ if(EXISTS "${CMAKE_ROOT}/Modules/CPack.cmake") endif() endif() - # default component for IFW - if(CMAKE_INSTALL_DEFAULT_COMPONENT_NAME) - set(_CPACK_IFW_COMPONENT_NAME ${CMAKE_INSTALL_DEFAULT_COMPONENT_NAME}) - else() - set(_CPACK_IFW_COMPONENT_NAME Unspecified) - endif() - string(TOUPPER ${_CPACK_IFW_COMPONENT_NAME} _CPACK_IFW_COMPONENT_UNAME) - if(${CMAKE_SYSTEM_NAME} MATCHES Windows) - set(_CPACK_IFW_PACKAGE_ICON "set(CPACK_IFW_PACKAGE_ICON \"${CMake_SOURCE_DIR}/Source/QtDialog/CMakeSetup.ico\")") + set(_CPACK_IFW_PACKAGE_ICON + "set(CPACK_IFW_PACKAGE_ICON \"${CMake_SOURCE_DIR}/Source/QtDialog/CMakeSetup.ico\")") if(BUILD_QtDialog) set(_CPACK_IFW_SHORTCUT_OPTIONAL "${_CPACK_IFW_SHORTCUT_OPTIONAL}component.addOperation(\"CreateShortcut\", \"@TargetDir@/bin/cmake-gui.exe\", \"@StartMenuDir@/CMake (cmake-gui).lnk\");\n") endif() @@ -87,7 +80,7 @@ if(EXISTS "${CMAKE_ROOT}/Modules/CPack.cmake") install(FILES "${CMake_SOURCE_DIR}/Source/QtIFW/cmake.org.html" DESTINATION "." ) - set(_CPACK_IFW_COMPONENT_SCRIPT "set(CPACK_IFW_COMPONENT_${_CPACK_IFW_COMPONENT_UNAME}_SCRIPT \"${CMake_BINARY_DIR}/installscript.qs\")") + set(_CPACK_IFW_PACKAGE_SCRIPT "set(CPACK_IFW_COMPONENT_GROUP_CMAKE_SCRIPT \"${CMake_BINARY_DIR}/installscript.qs\")") endif() if(${CMAKE_SYSTEM_NAME} MATCHES Linux) diff --git a/CMakeCPackOptions.cmake.in b/CMakeCPackOptions.cmake.in index 5127220..57ed4ca 100644 --- a/CMakeCPackOptions.cmake.in +++ b/CMakeCPackOptions.cmake.in @@ -32,22 +32,25 @@ endif() include("@QT_DIALOG_CPACK_OPTIONS_FILE@" OPTIONAL) if(CPACK_GENERATOR MATCHES "IFW") - # Version with QtIFW limitations - set(CPACK_PACKAGE_VERSION "@_CPACK_IFW_PACKAGE_VERSION@") # Installer configuration set(CPACK_IFW_PACKAGE_TITLE "CMake Build Tool") set(CPACK_IFW_PRODUCT_URL "http://www.cmake.org") @_CPACK_IFW_PACKAGE_ICON@ - set(CPACK_IFW_PACKAGE_WINDOW_ICON "@CMake_SOURCE_DIR@/Source/QtDialog/CMakeSetup128.png") - # Enable install default component - set(CPACK_COMPONENTS_ALL "@_CPACK_IFW_COMPONENT_NAME@") - # Component configuration - set(CPACK_COMPONENT_@_CPACK_IFW_COMPONENT_UNAME@_DISPLAY_NAME "@CPACK_PACKAGE_NAME@") - set(CPACK_COMPONENT_@_CPACK_IFW_COMPONENT_UNAME@_DESCRIPTION "@CPACK_PACKAGE_DESCRIPTION_SUMMARY@") - # IFW component onfiguration - set(CPACK_IFW_COMPONENT_@_CPACK_IFW_COMPONENT_UNAME@_NAME "@CPACK_PACKAGE_NAME@") - set(CPACK_IFW_COMPONENT_@_CPACK_IFW_COMPONENT_UNAME@_LICENSES "@CPACK_PACKAGE_NAME@ Copyright" "@CPACK_RESOURCE_FILE_LICENSE@") - @_CPACK_IFW_COMPONENT_SCRIPT@ + set(CPACK_IFW_PACKAGE_WINDOW_ICON + "@CMake_SOURCE_DIR@/Source/QtDialog/CMakeSetup128.png") + # Package configuration group + set(CPACK_IFW_PACKAGE_GROUP CMake) + # Group configuration + set(CPACK_COMPONENT_GROUP_CMAKE_DISPLAY_NAME + "@CPACK_PACKAGE_NAME@") + set(CPACK_COMPONENT_GROUP_CMAKE_DESCRIPTION + "@CPACK_PACKAGE_DESCRIPTION_SUMMARY@") + # IFW group configuration + set(CPACK_IFW_COMPONENT_GROUP_CMAKE_VERSION + "@_CPACK_IFW_PACKAGE_VERSION@") + set(CPACK_IFW_COMPONENT_GROUP_CMAKE_LICENSES + "@CPACK_PACKAGE_NAME@ Copyright" "@CPACK_RESOURCE_FILE_LICENSE@") + @_CPACK_IFW_PACKAGE_SCRIPT@ endif() if(CPACK_GENERATOR MATCHES "CygwinSource") diff --git a/Help/manual/cmake-modules.7.rst b/Help/manual/cmake-modules.7.rst index 91fffe9..61e4bb4 100644 --- a/Help/manual/cmake-modules.7.rst +++ b/Help/manual/cmake-modules.7.rst @@ -23,6 +23,7 @@ All Modules /module/CheckCXXSourceRuns /module/CheckCXXSymbolExists /module/CheckFortranFunctionExists + /module/CheckFortranSourceCompiles /module/CheckFunctionExists /module/CheckIncludeFileCXX /module/CheckIncludeFile @@ -114,6 +115,7 @@ All Modules /module/FindHg /module/FindHSPELL /module/FindHTMLHelp + /module/FindIce /module/FindIcotool /module/FindImageMagick /module/FindITK @@ -206,6 +208,7 @@ All Modules /module/FindWish /module/FindwxWidgets /module/FindwxWindows + /module/FindXerces /module/FindX11 /module/FindXMLRPC /module/FindZLIB diff --git a/Help/manual/cmake-properties.7.rst b/Help/manual/cmake-properties.7.rst index 9faf99a..5b0673a 100644 --- a/Help/manual/cmake-properties.7.rst +++ b/Help/manual/cmake-properties.7.rst @@ -287,6 +287,8 @@ Properties on Source Files /prop_sf/OBJECT_DEPENDS /prop_sf/OBJECT_OUTPUTS /prop_sf/SYMBOLIC + /prop_sf/VS_DEPLOYMENT_CONTENT + /prop_sf/VS_SHADER_TYPE /prop_sf/WRAP_EXCLUDE /prop_sf/XCODE_EXPLICIT_FILE_TYPE /prop_sf/XCODE_LAST_KNOWN_FILE_TYPE diff --git a/Help/manual/cmake-variables.7.rst b/Help/manual/cmake-variables.7.rst index e622784..2124f7d 100644 --- a/Help/manual/cmake-variables.7.rst +++ b/Help/manual/cmake-variables.7.rst @@ -362,6 +362,7 @@ Variables for CTest /variable/CTEST_TRIGGER_SITE /variable/CTEST_UPDATE_COMMAND /variable/CTEST_UPDATE_OPTIONS + /variable/CTEST_UPDATE_VERSION_ONLY /variable/CTEST_USE_LAUNCHERS Variables for CPack diff --git a/Help/manual/ctest.1.rst b/Help/manual/ctest.1.rst index a57a8f0..52e4beb 100644 --- a/Help/manual/ctest.1.rst +++ b/Help/manual/ctest.1.rst @@ -668,6 +668,15 @@ Configuration settings to specify the version control tool include: * :module:`CTest` module variable: ``UPDATE_TYPE`` if set, else ``CTEST_UPDATE_TYPE`` +``UpdateVersionOnly`` + Specify that you want the version control update command to only + discover the current version that is checked out, and not to update + to a different version. + + * `CTest Script`_ variable: :variable:`CTEST_UPDATE_VERSION_ONLY` + + + Additional configuration settings include: ``NightlyStartTime`` diff --git a/Help/module/CheckFortranSourceCompiles.rst b/Help/module/CheckFortranSourceCompiles.rst new file mode 100644 index 0000000..b749a2a --- /dev/null +++ b/Help/module/CheckFortranSourceCompiles.rst @@ -0,0 +1 @@ +.. cmake-module:: ../../Modules/CheckFortranSourceCompiles.cmake diff --git a/Help/module/FindIce.rst b/Help/module/FindIce.rst new file mode 100644 index 0000000..3af9405 --- /dev/null +++ b/Help/module/FindIce.rst @@ -0,0 +1 @@ +.. cmake-module:: ../../Modules/FindIce.cmake diff --git a/Help/module/FindXerces.rst b/Help/module/FindXerces.rst new file mode 100644 index 0000000..166d8dd --- /dev/null +++ b/Help/module/FindXerces.rst @@ -0,0 +1 @@ +.. cmake-module:: ../../Modules/FindXerces.cmake diff --git a/Help/policy/CMP0022.rst b/Help/policy/CMP0022.rst index 16a5bc3..22c7c4f 100644 --- a/Help/policy/CMP0022.rst +++ b/Help/policy/CMP0022.rst @@ -22,7 +22,7 @@ downstream users of CMake versions older than 2.8.12. The target_link_libraries command will no longer populate the properties matching LINK_INTERFACE_LIBRARIES(_<CONFIG>)? if this policy is NEW. -Warning-free future-compatible code which works with CMake 2.8.9 onwards +Warning-free future-compatible code which works with CMake 2.8.7 onwards can be written by using the ``LINK_PRIVATE`` and ``LINK_PUBLIC`` keywords of :command:`target_link_libraries`. diff --git a/Help/prop_sf/VS_DEPLOYMENT_CONTENT.rst b/Help/prop_sf/VS_DEPLOYMENT_CONTENT.rst new file mode 100644 index 0000000..9fb3ba3 --- /dev/null +++ b/Help/prop_sf/VS_DEPLOYMENT_CONTENT.rst @@ -0,0 +1,11 @@ +VS_DEPLOYMENT_CONTENT +--------------------- + +Mark a source file as content for deployment with a Windows Phone or +Windows Store application when built with a Visual Studio generator. +The value must evaluate to either ``1`` or ``0`` and may use +:manual:`generator expressions <cmake-generator-expressions(7)>` +to make the choice based on the build configuration. +The ``.vcxproj`` file entry for the source file will be +marked either ``DeploymentContent`` or ``ExcludedFromBuild`` +for values ``1`` and ``0``, respectively. diff --git a/Help/prop_sf/VS_SHADER_TYPE.rst b/Help/prop_sf/VS_SHADER_TYPE.rst new file mode 100644 index 0000000..6880256 --- /dev/null +++ b/Help/prop_sf/VS_SHADER_TYPE.rst @@ -0,0 +1,4 @@ +VS_SHADER_TYPE +-------------- + +Set the VS shader type of a ``.hlsl`` source file. diff --git a/Help/release/dev/FindOpenMP-add-Fortran-support.rst b/Help/release/dev/FindOpenMP-add-Fortran-support.rst new file mode 100644 index 0000000..0205718 --- /dev/null +++ b/Help/release/dev/FindOpenMP-add-Fortran-support.rst @@ -0,0 +1,4 @@ +FindOpenMP-add-Fortran-support +------------------------------ + +* The :module:`FindOpenMP` module learned to support Fortran. diff --git a/Help/release/dev/add-CheckFortranSourceCompiles.rst b/Help/release/dev/add-CheckFortranSourceCompiles.rst new file mode 100644 index 0000000..b78c747 --- /dev/null +++ b/Help/release/dev/add-CheckFortranSourceCompiles.rst @@ -0,0 +1,5 @@ +add-CheckFortranSourceCompiles +------------------------------ + +* The :module:`CheckFortranSourceCompiles` module was added to + provide a ``CHECK_Fortran_SOURCE_COMPILES`` macro. diff --git a/Help/release/dev/vs-special-source-file-properties.rst b/Help/release/dev/vs-special-source-file-properties.rst new file mode 100644 index 0000000..166c4b3 --- /dev/null +++ b/Help/release/dev/vs-special-source-file-properties.rst @@ -0,0 +1,11 @@ +vs-special-source-file-properties +--------------------------------- + +* A :prop_sf:`VS_DEPLOYMENT_CONTENT` source file property was added + to tell the Visual Studio generators to mark content for deployment + in Windows Phone and Windows Store projects. + +* The Visual Studio generators learned to treat ``.hlsl`` source + files as High Level Shading Language sources (using ``FXCompile`` + in ``.vcxproj`` files). A :prop_sf:`VS_SHADER_TYPE` source file + property was added to specify the Shader Type. diff --git a/Help/variable/CTEST_UPDATE_VERSION_ONLY.rst b/Help/variable/CTEST_UPDATE_VERSION_ONLY.rst new file mode 100644 index 0000000..e646e6e --- /dev/null +++ b/Help/variable/CTEST_UPDATE_VERSION_ONLY.rst @@ -0,0 +1,5 @@ +CTEST_UPDATE_VERSION_ONLY +------------------------- + +Specify the CTest ``UpdateVersionOnly`` setting +in a :manual:`ctest(1)` dashboard client script. diff --git a/Modules/CMakeCheckCompilerFlagCommonPatterns.cmake b/Modules/CMakeCheckCompilerFlagCommonPatterns.cmake index aa7d96a..19b2bbc 100644 --- a/Modules/CMakeCheckCompilerFlagCommonPatterns.cmake +++ b/Modules/CMakeCheckCompilerFlagCommonPatterns.cmake @@ -28,6 +28,7 @@ macro (CHECK_COMPILER_FLAG_COMMON_PATTERNS _VAR) FAIL_REGEX "option.*not supported" # Intel FAIL_REGEX "invalid argument .*option" # Intel FAIL_REGEX "ignoring option .*argument required" # Intel + FAIL_REGEX "ignoring option .*argument is of wrong type" # Intel FAIL_REGEX "[Uu]nknown option" # HP FAIL_REGEX "[Ww]arning: [Oo]ption" # SunPro FAIL_REGEX "command option .* is not recognized" # XL diff --git a/Modules/CPackIFW.cmake b/Modules/CPackIFW.cmake index 29a0047..8463b5d 100644 --- a/Modules/CPackIFW.cmake +++ b/Modules/CPackIFW.cmake @@ -74,6 +74,15 @@ # # You can use predefined variables. # +# .. variable:: CPACK_IFW_PACKAGE_GROUP +# +# The group, which will be used to configure the root package +# +# .. variable:: CPACK_IFW_PACKAGE_NAME +# +# The root package name, which will be used if configuration group is not +# specified +# # Components # """""""""" # @@ -122,11 +131,10 @@ # # :: # -# cpack_ifw_configure_component(<compname> -# [COMMON] +# cpack_ifw_configure_component(<compname> [COMMON] +# [NAME <name>] # [VERSION <version>] # [SCRIPT <script>] -# [NAME <name>] # [PRIORITY <priority>] # [DEPENDS <com_id> ...] # [LICENSES <display_name> <file_path> ...]) @@ -163,6 +171,7 @@ # cpack_ifw_configure_component_group(<grpname> # [VERSION <version>] # [NAME <name>] +# [SCRIPT <script>] # [PRIORITY <priority>] # [LICENSES <display_name> <file_path> ...]) # @@ -174,6 +183,9 @@ # ``NAME`` is used to create domain-like identification for this component group. # By default used origin component group name. # +# ``SCRIPT`` is relative or absolute path to operations script +# for this component group. +# # ``PRIORITY`` is priority of the component group in the tree. # # ``LICENSES`` pair of <display_name> and <file_path> of license text for this @@ -329,6 +341,20 @@ if(NOT __CMAKE_PARSE_ARGUMENTS_INCLUDED) include(CMakeParseArguments) endif() +# Resolve full filename for script file +macro(_cpack_ifw_resolve_script _variable) + set(_ifw_script_macro ${_variable}) + set(_ifw_script_file ${${_ifw_script_macro}}) + if(DEFINED ${_ifw_script_macro}) + get_filename_component(${_ifw_script_macro} ${_ifw_script_file} ABSOLUTE) + set(_ifw_script_file ${${_ifw_script_macro}}) + if(NOT EXISTS ${_ifw_script_file}) + message(WARNING "CPack IFW: script file \"${_ifw_script_file}\" is not exists") + set(${_ifw_script_macro}) + endif() + endif() +endmacro() + # Resolve full path to lisense file macro(_cpack_ifw_resolve_lisenses _variable) if(${_variable}) @@ -357,18 +383,7 @@ macro(cpack_ifw_configure_component compname) set(_IFW_MULTI_ARGS DEPENDS LICENSES) cmake_parse_arguments(CPACK_IFW_COMPONENT_${_CPACK_IFWCOMP_UNAME} "${_IFW_OPT}" "${_IFW_ARGS}" "${_IFW_MULTI_ARGS}" ${ARGN}) - # Resolve full filename for script file - set(_IFW_SCRIPT_MACRO CPACK_IFW_COMPONENT_${_CPACK_IFWCOMP_UNAME}_SCRIPT) - set(_IFW_SCRIPT_FILE ${${_IFW_SCRIPT_MACRO}}) - if(DEFINED ${_IFW_SCRIPT_MACRO}) - get_filename_component(${_IFW_SCRIPT_MACRO} ${_IFW_SCRIPT_FILE} ABSOLUTE) - set(_IFW_SCRIPT_FILE ${${_IFW_SCRIPT_MACRO}}) - if(NOT EXISTS ${_IFW_SCRIPT_FILE}) - message(WARNING "CPack IFW: script file \"${_IFW_SCRIPT_FILE}\" for component \"${compname}\" is not exists" ) - set(${_IFW_SCRIPT_MACRO}) - endif() - endif() - + _cpack_ifw_resolve_script(CPACK_IFW_COMPONENT_${_CPACK_IFWCOMP_UNAME}_SCRIPT) _cpack_ifw_resolve_lisenses(CPACK_IFW_COMPONENT_${_CPACK_IFWCOMP_UNAME}_LICENSES) set(_CPACK_IFWCOMP_STR "\n# Configuration for IFW component \"${compname}\"\n") @@ -403,10 +418,11 @@ macro(cpack_ifw_configure_component_group grpname) string(TOUPPER ${grpname} _CPACK_IFWGRP_UNAME) set(_IFW_OPT) - set(_IFW_ARGS VERSION NAME PRIORITY) + set(_IFW_ARGS NAME VERSION SCRIPT PRIORITY) set(_IFW_MULTI_ARGS LICENSES) cmake_parse_arguments(CPACK_IFW_COMPONENT_GROUP_${_CPACK_IFWGRP_UNAME} "${_IFW_OPT}" "${_IFW_ARGS}" "${_IFW_MULTI_ARGS}" ${ARGN}) + _cpack_ifw_resolve_script(CPACK_IFW_COMPONENT_GROUP_${_CPACK_IFWGRP_UNAME}_SCRIPT) _cpack_ifw_resolve_lisenses(CPACK_IFW_COMPONENT_GROUP_${_CPACK_IFWGRP_UNAME}_LICENSES) set(_CPACK_IFWGRP_STR "\n# Configuration for IFW component group \"${grpname}\"\n") diff --git a/Modules/CheckFortranSourceCompiles.cmake b/Modules/CheckFortranSourceCompiles.cmake new file mode 100644 index 0000000..63e4539 --- /dev/null +++ b/Modules/CheckFortranSourceCompiles.cmake @@ -0,0 +1,110 @@ +#.rst: +# CheckFortranSourceCompiles +# -------------------------- +# +# Check if given Fortran source compiles and links into an executable:: +# +# CHECK_Fortran_SOURCE_COMPILES(<code> <var> [FAIL_REGEX <fail-regex>]) +# +# The arguments are: +# +# ``<code>`` +# Source code to try to compile. It must define a PROGRAM entry point. +# ``<var>`` +# Variable to store whether the source code compiled. +# ``<fail-regex>`` +# Fail if test output matches this regex. +# +# The following variables may be set before calling this macro to modify +# the way the check is run:: +# +# CMAKE_REQUIRED_FLAGS = string of compile command line flags +# CMAKE_REQUIRED_DEFINITIONS = list of macros to define (-DFOO=bar) +# CMAKE_REQUIRED_INCLUDES = list of include directories +# CMAKE_REQUIRED_LIBRARIES = list of libraries to link +# CMAKE_REQUIRED_QUIET = execute quietly without messages + +#============================================================================= +# Copyright 2005-2009 Kitware, Inc. +# +# Distributed under the OSI-approved BSD License (the "License"); +# see accompanying file Copyright.txt for details. +# +# This software is distributed WITHOUT ANY WARRANTY; without even the +# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +# See the License for more information. +#============================================================================= +# (To distribute this file outside of CMake, substitute the full +# License text for the above reference.) + + + +macro(CHECK_Fortran_SOURCE_COMPILES SOURCE VAR) + if(NOT DEFINED "${VAR}") + set(_FAIL_REGEX) + set(_key) + foreach(arg ${ARGN}) + if("${arg}" MATCHES "^(FAIL_REGEX)$") + set(_key "${arg}") + elseif(_key) + list(APPEND _${_key} "${arg}") + else() + message(FATAL_ERROR "Unknown argument:\n ${arg}\n") + endif() + endforeach() + set(MACRO_CHECK_FUNCTION_DEFINITIONS + "-D${VAR} ${CMAKE_REQUIRED_FLAGS}") + if(CMAKE_REQUIRED_LIBRARIES) + set(CHECK_Fortran_SOURCE_COMPILES_ADD_LIBRARIES + LINK_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES}) + else() + set(CHECK_Fortran_SOURCE_COMPILES_ADD_LIBRARIES) + endif() + if(CMAKE_REQUIRED_INCLUDES) + set(CHECK_Fortran_SOURCE_COMPILES_ADD_INCLUDES + "-DINCLUDE_DIRECTORIES:STRING=${CMAKE_REQUIRED_INCLUDES}") + else() + set(CHECK_Fortran_SOURCE_COMPILES_ADD_INCLUDES) + endif() + file(WRITE "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/src.F" + "${SOURCE}\n") + + if(NOT CMAKE_REQUIRED_QUIET) + message(STATUS "Performing Test ${VAR}") + endif() + try_compile(${VAR} + ${CMAKE_BINARY_DIR} + ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/src.F + COMPILE_DEFINITIONS ${CMAKE_REQUIRED_DEFINITIONS} + ${CHECK_Fortran_SOURCE_COMPILES_ADD_LIBRARIES} + CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${MACRO_CHECK_FUNCTION_DEFINITIONS} + "${CHECK_Fortran_SOURCE_COMPILES_ADD_INCLUDES}" + OUTPUT_VARIABLE OUTPUT) + + foreach(_regex ${_FAIL_REGEX}) + if("${OUTPUT}" MATCHES "${_regex}") + set(${VAR} 0) + endif() + endforeach() + + if(${VAR}) + set(${VAR} 1 CACHE INTERNAL "Test ${VAR}") + if(NOT CMAKE_REQUIRED_QUIET) + message(STATUS "Performing Test ${VAR} - Success") + endif() + file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log + "Performing Fortran SOURCE FILE Test ${VAR} succeded with the following output:\n" + "${OUTPUT}\n" + "Source file was:\n${SOURCE}\n") + else() + if(NOT CMAKE_REQUIRED_QUIET) + message(STATUS "Performing Test ${VAR} - Failed") + endif() + set(${VAR} "" CACHE INTERNAL "Test ${VAR}") + file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log + "Performing Fortran SOURCE FILE Test ${VAR} failed with the following output:\n" + "${OUTPUT}\n" + "Source file was:\n${SOURCE}\n") + endif() + endif() +endmacro() diff --git a/Modules/CheckFunctionExists.cmake b/Modules/CheckFunctionExists.cmake index 01a652b..4c4334f 100644 --- a/Modules/CheckFunctionExists.cmake +++ b/Modules/CheckFunctionExists.cmake @@ -38,7 +38,7 @@ macro(CHECK_FUNCTION_EXISTS FUNCTION VARIABLE) - if(NOT DEFINED "${VARIABLE}") + if(NOT DEFINED "${VARIABLE}" OR "x${${VARIABLE}}" STREQUAL "x${VARIABLE}") set(MACRO_CHECK_FUNCTION_DEFINITIONS "-DCHECK_FUNCTION_EXISTS=${FUNCTION} ${CMAKE_REQUIRED_FLAGS}") if(NOT CMAKE_REQUIRED_QUIET) diff --git a/Modules/CheckIncludeFileCXX.cmake b/Modules/CheckIncludeFileCXX.cmake index 718e667..eff982c 100644 --- a/Modules/CheckIncludeFileCXX.cmake +++ b/Modules/CheckIncludeFileCXX.cmake @@ -44,7 +44,7 @@ # License text for the above reference.) macro(CHECK_INCLUDE_FILE_CXX INCLUDE VARIABLE) - if(NOT DEFINED "${VARIABLE}") + if(NOT DEFINED "${VARIABLE}" OR "x${${VARIABLE}}" STREQUAL "x${VARIABLE}") if(CMAKE_REQUIRED_INCLUDES) set(CHECK_INCLUDE_FILE_CXX_INCLUDE_DIRS "-DINCLUDE_DIRECTORIES=${CMAKE_REQUIRED_INCLUDES}") else() diff --git a/Modules/CheckSymbolExists.cmake b/Modules/CheckSymbolExists.cmake index 6f50c88..c31f6b6 100644 --- a/Modules/CheckSymbolExists.cmake +++ b/Modules/CheckSymbolExists.cmake @@ -50,7 +50,7 @@ macro(CHECK_SYMBOL_EXISTS SYMBOL FILES VARIABLE) endmacro() macro(_CHECK_SYMBOL_EXISTS SOURCEFILE SYMBOL FILES VARIABLE) - if(NOT DEFINED "${VARIABLE}") + if(NOT DEFINED "${VARIABLE}" OR "x${${VARIABLE}}" STREQUAL "x${VARIABLE}") set(CMAKE_CONFIGURABLE_FILE_CONTENT "/* */\n") set(MACRO_CHECK_SYMBOL_EXISTS_FLAGS ${CMAKE_REQUIRED_FLAGS}) if(CMAKE_REQUIRED_LIBRARIES) diff --git a/Modules/DartConfiguration.tcl.in b/Modules/DartConfiguration.tcl.in index 0420882..86049d0 100644 --- a/Modules/DartConfiguration.tcl.in +++ b/Modules/DartConfiguration.tcl.in @@ -37,6 +37,9 @@ ConfigureCommand: "@CMAKE_COMMAND@" "@PROJECT_SOURCE_DIR@" MakeCommand: @MAKECOMMAND@ DefaultCTestConfigurationType: @DEFAULT_CTEST_CONFIGURATION_TYPE@ +# version control +UpdateVersionOnly: @CTEST_UPDATE_VERSION_ONLY@ + # CVS options # Default is "-d -P -A" CVSCommand: @CVSCOMMAND@ diff --git a/Modules/ExternalProject.cmake b/Modules/ExternalProject.cmake index dbce9f4..218066c 100644 --- a/Modules/ExternalProject.cmake +++ b/Modules/ExternalProject.cmake @@ -26,7 +26,7 @@ # [CVS_MODULE mod] # Module to checkout from CVS repo # [CVS_TAG tag] # Tag to checkout from CVS repo # [SVN_REPOSITORY url] # URL of Subversion repo -# [SVN_REVISION rev] # Revision to checkout from Subversion repo +# [SVN_REVISION -r<rev>] # Revision to checkout from Subversion repo # [SVN_USERNAME john ] # Username for Subversion checkout and update # [SVN_PASSWORD doe ] # Password for Subversion checkout and update # [SVN_TRUST_CERT 1 ] # Trust the Subversion server site certificate diff --git a/Modules/FindIce.cmake b/Modules/FindIce.cmake new file mode 100644 index 0000000..c437a40 --- /dev/null +++ b/Modules/FindIce.cmake @@ -0,0 +1,396 @@ +#.rst: +# FindIce +# ------- +# +# Find the ZeroC Internet Communication Engine (ICE) programs, +# libraries and datafiles. +# +# This module supports multiple components. +# Components can include any of: ``Freeze``, ``Glacier2``, ``Ice``, +# ``IceBox``, ``IceDB``, ``IceGrid``, ``IcePatch``, ``IceSSL``, +# ``IceStorm``, ``IceUtil``, ``IceXML``, or ``Slice``. +# +# This module reports information about the Ice installation in +# several variables. General variables:: +# +# Ice_VERSION - Ice release version +# Ice_FOUND - true if the main programs and libraries were found +# Ice_LIBRARIES - component libraries to be linked +# Ice_INCLUDE_DIRS - the directories containing the Ice headers +# Ice_SLICE_DIRS - the directories containing the Ice slice interface +# definitions +# +# Ice programs are reported in:: +# +# Ice_SLICE2CPP_EXECUTABLE - path to slice2cpp executable +# Ice_SLICE2CS_EXECUTABLE - path to slice2cs executable +# Ice_SLICE2FREEZEJ_EXECUTABLE - path to slice2freezej executable +# Ice_SLICE2FREEZE_EXECUTABLE - path to slice2freeze executable +# Ice_SLICE2HTML_EXECUTABLE - path to slice2html executable +# Ice_SLICE2JAVA_EXECUTABLE - path to slice2java executable +# Ice_SLICE2PHP_EXECUTABLE - path to slice2php executable +# Ice_SLICE2PY_EXECUTABLE - path to slice2py executable +# Ice_SLICE2RB_EXECUTABLE - path to slice2rb executable +# +# Ice component libraries are reported in:: +# +# Ice_<C>_FOUND - ON if component was found +# Ice_<C>_LIBRARIES - libraries for component +# +# Note that ``<C>`` is the uppercased name of the component. +# +# This module reads hints about search results from:: +# +# Ice_HOME - the root of the Ice installation +# +# The environment variable :envvar:`ICE_HOME` may also be used; the +# Ice_HOME variable takes precedence. +# +# The following cache variables may also be set:: +# +# Ice_<P>_EXECUTABLE - the path to executable <P> +# Ice_INCLUDE_DIR - the directory containing the Ice headers +# Ice_SLICE_DIR - the directory containing the Ice slice interface +# definitions +# Ice_<C>_LIBRARY - the library for component <C> +# +# .. note:: +# +# In most cases none of the above variables will require setting, +# unless multiple Ice versions are available and a specific version +# is required. On Windows, the most recent version of Ice will be +# found through the registry. On Unix, the programs, headers and +# libraries will usually be in standard locations, but Ice_SLICE_DIRS +# might not be automatically detected (commonly known locations are +# searched). All the other variables are defaulted using Ice_HOME, +# if set. It's possible to set Ice_HOME and selectively specify +# alternative locations for the other components; this might be +# required for e.g. newer versions of Visual Studio if the +# heuristics are not sufficient to identify the correct programs and +# libraries for the specific Visual Studio version. +# +# Other variables one may set to control this module are:: +# +# Ice_DEBUG - Set to ON to enable debug output from FindIce. + +# Written by Roger Leigh <rleigh@codelibre.net> + +#============================================================================= +# Copyright 2014 University of Dundee +# +# Distributed under the OSI-approved BSD License (the "License"); +# see accompanying file Copyright.txt for details. +# +# This software is distributed WITHOUT ANY WARRANTY; without even the +# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +# See the License for more information. +#============================================================================= +# (To distribute this file outside of CMake, substitute the full +# License text for the above reference.) + +# The Ice checks are contained in a function due to the large number +# of temporary variables needed. +function(_Ice_FIND) + # Released versions of Ice, including generic short forms + set(ice_versions + 3 + 3.5 + 3.5.1 + 3.5.0 + 3.4 + 3.4.2 + 3.4.1 + 3.4.0 + 3.3 + 3.3.1 + 3.3.0) + + # Set up search paths, taking compiler into account. Search Ice_HOME, + # with ICE_HOME in the environment as a fallback if unset. + if(Ice_HOME) + list(APPEND ice_roots "${Ice_HOME}") + else() + if(NOT "$ENV{ICE_HOME}" STREQUAL "") + file(TO_CMAKE_PATH "$ENV{ICE_HOME}" NATIVE_PATH) + list(APPEND ice_roots "${NATIVE_PATH}") + set(Ice_HOME "${NATIVE_PATH}" + CACHE PATH "Location of the Ice installation" FORCE) + endif() + endif() + + if(CMAKE_SIZEOF_VOID_P EQUAL 8) + # 64-bit path suffix + set(_x64 "/x64") + # 64-bit library directory + set(_lib64 "lib64") + endif() + + if(MSVC_VERSION) + # VS 8.0 + if(NOT MSVC_VERSION VERSION_LESS 1400 AND MSVC_VERSION VERSION_LESS 1500) + set(vcver "vc80") + set(vcyear "2005") + # VS 9.0 + elseif(NOT MSVC_VERSION VERSION_LESS 1500 AND MSVC_VERSION VERSION_LESS 1600) + set(vcver "vc90") + set(vcyear "2008") + # VS 10.0 + elseif(NOT MSVC_VERSION VERSION_LESS 1600 AND MSVC_VERSION VERSION_LESS 1700) + set(vcver "vc100") + # VS 11.0 + elseif(NOT MSVC_VERSION VERSION_LESS 1700 AND MSVC_VERSION VERSION_LESS 1800) + set(vcver "vc110") + # VS 12.0 + elseif(NOT MSVC_VERSION VERSION_LESS 1800 AND MSVC_VERSION VERSION_LESS 1900) + set(vcver "vc120") + # VS 14.0 + elseif(NOT MSVC_VERSION VERSION_LESS 1900 AND MSVC_VERSION VERSION_LESS 2000) + set(vcver "vc140") + endif() + endif() + + # For compatibility with ZeroC Windows builds. + if(vcver) + # Earlier Ice (3.3) builds don't use vcnnn subdirectories, but are harmless to check. + list(APPEND ice_binary_suffixes "bin/${vcver}${_x64}" "bin/${vcver}") + list(APPEND ice_library_suffixes "lib/${vcver}${_x64}" "lib/${vcver}") + endif() + # Generic 64-bit and 32-bit directories + list(APPEND ice_binary_suffixes "bin${_x64}" "bin") + list(APPEND ice_library_suffixes "${_lib64}" "lib${_x64}" "lib") + list(APPEND ice_include_suffixes "include") + list(APPEND ice_slice_suffixes "slice") + + # On Windows, look in the registry for install locations. Different + # versions of Ice install support different compiler versions. + if(vcver) + foreach(ice_version ${ice_versions}) + # Ice 3.3 releases use a Visual Studio year suffix and value is + # enclosed in double quotes, though only the leading quote is + # returned by get_filename_component. + unset(ice_location) + if(vcyear) + get_filename_component(ice_location + "[HKEY_LOCAL_MACHINE\\SOFTWARE\\ZeroC\\Ice ${ice_version} for Visual Studio ${vcyear};InstallDir]" + PATH) + if(ice_location AND NOT ("${ice_location}" STREQUAL "/registry" OR "${ice_location}" STREQUAL "/")) + string(REGEX REPLACE "^\"(.*)\"?$" "\\1" ice_location "${ice_location}") + get_filename_component(ice_location "${ice_location}" ABSOLUTE) + else() + unset(ice_location) + endif() + endif() + # Ice 3.4+ releases don't use a suffix + if(NOT ice_location OR "${ice_location}" STREQUAL "/registry") + get_filename_component(ice_location + "[HKEY_LOCAL_MACHINE\\SOFTWARE\\ZeroC\\Ice ${ice_version};InstallDir]" + ABSOLUTE) + endif() + + if(ice_location AND NOT "${ice_location}" STREQUAL "/registry") + list(APPEND ice_roots "${ice_location}") + endif() + endforeach() + else() + foreach(ice_version ${ice_versions}) + # Prefer 64-bit variants if present (and using a 64-bit compiler) + list(APPEND ice_roots "/opt/Ice-${ice_version}") + endforeach() + endif() + + set(ice_programs + slice2cpp + slice2cs + slice2freezej + slice2freeze + slice2html + slice2java + slice2php + slice2py + slice2rb) + + # Find all Ice programs + foreach(program ${ice_programs}) + string(TOUPPER "${program}" program_upcase) + set(cache_var "Ice_${program_upcase}_EXECUTABLE") + set(program_var "Ice_${program_upcase}_EXECUTABLE") + find_program("${cache_var}" "${program}" + HINTS ${ice_roots} + PATH_SUFFIXES ${ice_binary_suffixes} + DOC "Ice ${program} executable") + mark_as_advanced(cache_var) + set("${program_var}" "${${cache_var}}" PARENT_SCOPE) + endforeach() + + # Get version. + if(Ice_SLICE2CPP_EXECUTABLE) + # Execute in C locale for safety + set(_Ice_SAVED_LC_ALL "$ENV{LC_ALL}") + set(ENV{LC_ALL} C) + + execute_process(COMMAND ${Ice_SLICE2CPP_EXECUTABLE} --version + ERROR_VARIABLE Ice_VERSION_SLICE2CPP_FULL + ERROR_STRIP_TRAILING_WHITESPACE) + + # restore the previous LC_ALL + set(ENV{LC_ALL} ${_Ice_SAVED_LC_ALL}) + + # Make short version + string(REGEX REPLACE "^(.*)\\.[^.]*$" "\\1" Ice_VERSION_SLICE2CPP_SHORT "${Ice_VERSION_SLICE2CPP_FULL}") + set(Ice_VERSION "${Ice_VERSION_SLICE2CPP_FULL}" PARENT_SCOPE) + endif() + + message(STATUS "Ice version: ${Ice_VERSION_SLICE2CPP_FULL}") + + # The following searches prefer the version found; note reverse + # order due to prepending. + if(NOT MSVC) + list(INSERT ice_roots 0 "/opt/Ice-${Ice_VERSION_SLICE2CPP_SHORT}") + list(INSERT ice_roots 0 "/opt/Ice-${Ice_VERSION_SLICE2CPP_FULL}") + endif() + + # Find include directory + find_path(Ice_INCLUDE_DIR + NAMES "Ice/Ice.h" + HINTS ${ice_roots} + PATH_SUFFIXES ${ice_include_suffixes} + DOC "Ice include directory") + set(Ice_INCLUDE_DIR "${Ice_INCLUDE_DIR}" PARENT_SCOPE) + + # In common use on Linux, MacOS X (homebrew) and FreeBSD; prefer + # version-specific dir + list(APPEND ice_slice_paths + /usr/local/share /usr/share) + list(APPEND ice_slice_suffixes + "Ice-${Ice_VERSION_SLICE2CPP_FULL}/slice" + "Ice-${Ice_VERSION_SLICE2CPP_SHORT}/slice" + Ice) + + # Find slice directory + find_path(Ice_SLICE_DIR + NAMES "Ice/Connection.ice" + HINTS ${ice_roots} + ${ice_slice_paths} + PATH_SUFFIXES ${ice_slice_suffixes} + NO_DEFAULT_PATH + DOC "Ice slice directory") + set(Ice_SLICE_DIR "${Ice_SLICE_DIR}" PARENT_SCOPE) + + # Find all Ice libraries + set(Ice_REQUIRED_LIBS_FOUND ON) + foreach(component ${Ice_FIND_COMPONENTS}) + string(TOUPPER "${component}" component_upcase) + set(component_cache "Ice_${component_upcase}_LIBRARY") + set(component_found "${component_upcase}_FOUND") + find_library("${component_cache}" "${component}" + HINTS ${ice_roots} + PATH_SUFFIXES ${ice_library_suffixes} + DOC "Ice ${component} library") + mark_as_advanced("${component_cache}") + if("${component_cache}") + set("${component_found}" ON) + list(APPEND Ice_LIBRARY "${${component_cache}}") + endif() + mark_as_advanced("${component_found}") + set("${component_cache}" "${${component_cache}}" PARENT_SCOPE) + set("${component_found}" "${${component_found}}" PARENT_SCOPE) + if("${component_found}") + if ("Ice_FIND_REQUIRED_${component}") + list(APPEND Ice_LIBS_FOUND "${component} (required)") + else() + list(APPEND Ice_LIBS_FOUND "${component} (optional)") + endif() + else() + if ("Ice_FIND_REQUIRED_${component}") + set(Ice_REQUIRED_LIBS_FOUND OFF) + list(APPEND Ice_LIBS_NOTFOUND "${component} (required)") + else() + list(APPEND Ice_LIBS_NOTFOUND "${component} (optional)") + endif() + endif() + endforeach() + set(_Ice_REQUIRED_LIBS_FOUND "${Ice_REQUIRED_LIBS_FOUND}" PARENT_SCOPE) + set(Ice_LIBRARY "${Ice_LIBRARY}" PARENT_SCOPE) + + if(Ice_LIBS_FOUND) + message(STATUS "Found the following Ice libraries:") + foreach(found ${Ice_LIBS_FOUND}) + message(STATUS " ${found}") + endforeach() + endif() + if(Ice_LIBS_NOTFOUND) + message(STATUS "The following Ice libraries were not found:") + foreach(notfound ${Ice_LIBS_NOTFOUND}) + message(STATUS " ${notfound}") + endforeach() + endif() + + if(Ice_DEBUG) + message(STATUS "--------FindIce.cmake search debug--------") + message(STATUS "ICE binary path search order: ${ice_roots}") + message(STATUS "ICE include path search order: ${ice_roots}") + message(STATUS "ICE slice path search order: ${ice_roots} ${ice_slice_paths}") + message(STATUS "ICE library path search order: ${ice_roots}") + message(STATUS "----------------") + endif() +endfunction() + +_Ice_FIND() + +include(FindPackageHandleStandardArgs) +FIND_PACKAGE_HANDLE_STANDARD_ARGS(Ice + FOUND_VAR Ice_FOUND + REQUIRED_VARS Ice_SLICE2CPP_EXECUTABLE + Ice_INCLUDE_DIR + Ice_SLICE_DIR + Ice_LIBRARY + _Ice_REQUIRED_LIBS_FOUND + VERSION_VAR Ice_VERSION + FAIL_MESSAGE "Failed to find all Ice components") + +unset(_Ice_REQUIRED_LIBS_FOUND) + +if(Ice_FOUND) + set(Ice_INCLUDE_DIRS "${Ice_INCLUDE_DIR}") + set(Ice_SLICE_DIRS "${Ice_SLICE_DIR}") + set(Ice_LIBRARIES "${Ice_LIBRARY}") + foreach(_Ice_component ${Ice_FIND_COMPONENTS}) + string(TOUPPER "${_Ice_component}" _Ice_component_upcase) + set(_Ice_component_cache "Ice_${_Ice_component_upcase}_LIBRARY") + set(_Ice_component_lib "Ice_${_Ice_component_upcase}_LIBRARIES") + set(_Ice_component_found "${_Ice_component_upcase}_FOUND") + if("${_Ice_component_found}") + set("${_Ice_component_lib}" "${${_Ice_component_cache}}") + endif() + unset(_Ice_component_upcase) + unset(_Ice_component_cache) + unset(_Ice_component_lib) + unset(_Ice_component_found) + endforeach() +endif() + +if(Ice_DEBUG) + message(STATUS "--------FindIce.cmake results debug--------") + message(STATUS "Ice_VERSION number: ${Ice_VERSION}") + message(STATUS "Ice_HOME directory: ${Ice_HOME}") + message(STATUS "Ice_INCLUDE_DIR directory: ${Ice_INCLUDE_DIR}") + message(STATUS "Ice_SLICE_DIR directory: ${Ice_SLICE_DIR}") + message(STATUS "Ice_LIBRARIES: ${Ice_LIBRARIES}") + message(STATUS "slice2cpp executable: ${Ice_SLICE2CPP_EXECUTABLE}") + message(STATUS "slice2cs executable: ${Ice_SLICE2CS_EXECUTABLE}") + message(STATUS "slice2freezej executable: ${Ice_SLICE2FREEZEJ_EXECUTABLE}") + message(STATUS "slice2freeze executable: ${Ice_SLICE2FREEZE_EXECUTABLE}") + message(STATUS "slice2html executable: ${Ice_SLICE2HTML_EXECUTABLE}") + message(STATUS "slice2java executable: ${Ice_SLICE2JAVA_EXECUTABLE}") + message(STATUS "slice2php executable: ${Ice_SLICE2PHP_EXECUTABLE}") + message(STATUS "slice2py executable: ${Ice_SLICE2PY_EXECUTABLE}") + message(STATUS "slice2rb executable: ${Ice_SLICE2RB_EXECUTABLE}") + foreach(component ${Ice_FIND_COMPONENTS}) + string(TOUPPER "${component}" component_upcase) + set(component_lib "Ice_${component_upcase}_LIBRARIES") + set(component_found "${component_upcase}_FOUND") + message(STATUS "${component} library found: ${${component_found}}") + message(STATUS "${component} library: ${${component_lib}}") + endforeach() + message(STATUS "----------------") +endif() diff --git a/Modules/FindMPI.cmake b/Modules/FindMPI.cmake index 6e15f3b..3be5e3c 100644 --- a/Modules/FindMPI.cmake +++ b/Modules/FindMPI.cmake @@ -522,6 +522,7 @@ endfunction() # Most mpi distros have some form of mpiexec which gives us something we can reliably look for. find_program(MPIEXEC NAMES ${_MPI_EXEC_NAMES} + HINTS ${MPI_HOME} $ENV{MPI_HOME} PATHS ${_MPI_PREFIX_PATH} PATH_SUFFIXES bin DOC "Executable for running MPI programs.") @@ -584,7 +585,9 @@ foreach (lang C CXX Fortran) find_program(MPI_${lang}_COMPILER NAMES ${_MPI_${lang}_COMPILER_NAMES} - PATHS "${MPI_HOME}/bin" "$ENV{MPI_HOME}/bin" ${_MPI_PREFIX_PATH}) + HINTS ${_MPI_BASE_DIR}/bin + PATHS ${_MPI_PREFIX_PATH} + ) interrogate_mpi_compiler(${lang} ${try_libs}) mark_as_advanced(MPI_${lang}_COMPILER) diff --git a/Modules/FindOpenMP.cmake b/Modules/FindOpenMP.cmake index 935a0ca..801b4f8 100644 --- a/Modules/FindOpenMP.cmake +++ b/Modules/FindOpenMP.cmake @@ -16,6 +16,7 @@ # # OpenMP_C_FLAGS - flags to add to the C compiler for OpenMP support # OpenMP_CXX_FLAGS - flags to add to the CXX compiler for OpenMP support +# OpenMP_Fortran_FLAGS - flags to add to the Fortran compiler for OpenMP support # OPENMP_FOUND - true if openmp is detected # # @@ -27,6 +28,7 @@ # Copyright 2009 Kitware, Inc. # Copyright 2008-2009 André Rigland Brodtkorb <Andre.Brodtkorb@ifi.uio.no> # Copyright 2012 Rolf Eike Beer <eike@sf-mail.de> +# Copyright 2014 Nicolas Bock <nicolasbock@gmail.com> # # Distributed under the OSI-approved BSD License (the "License"); # see accompanying file Copyright.txt for details. @@ -106,6 +108,17 @@ int main() { } ") +# same in Fortran +set(OpenMP_Fortran_TEST_SOURCE + " +program test +use omp_lib +integer :: n +n = omp_get_num_threads() +end program test + " + ) + # check c compiler if(CMAKE_C_COMPILER_LOADED) # if these are set then do not try to find them again, @@ -176,6 +189,40 @@ if(CMAKE_CXX_COMPILER_LOADED) unset(OpenMP_CXX_TEST_SOURCE) endif() +# check Fortran compiler +if(CMAKE_Fortran_COMPILER_LOADED) + # if these are set then do not try to find them again, + # by avoiding any try_compiles for the flags + if(OpenMP_Fortran_FLAGS) + unset(OpenMP_Fortran_FLAG_CANDIDATES) + else() + _OPENMP_FLAG_CANDIDATES("Fortran") + include(${CMAKE_CURRENT_LIST_DIR}/CheckFortranSourceCompiles.cmake) + endif() + + foreach(FLAG IN LISTS OpenMP_Fortran_FLAG_CANDIDATES) + set(SAFE_CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS}") + set(CMAKE_REQUIRED_FLAGS "${FLAG}") + unset(OpenMP_FLAG_DETECTED CACHE) + if(NOT CMAKE_REQUIRED_QUIET) + message(STATUS "Try OpenMP Fortran flag = [${FLAG}]") + endif() + check_fortran_source_compiles("${OpenMP_Fortran_TEST_SOURCE}" OpenMP_FLAG_DETECTED) + set(CMAKE_REQUIRED_FLAGS "${SAFE_CMAKE_REQUIRED_FLAGS}") + if(OpenMP_FLAG_DETECTED) + set(OpenMP_Fortran_FLAGS_INTERNAL "${FLAG}") + break() + endif() + endforeach() + + set(OpenMP_Fortran_FLAGS "${OpenMP_Fortran_FLAGS_INTERNAL}" + CACHE STRING "Fortran compiler flags for OpenMP parallization") + + list(APPEND _OPENMP_REQUIRED_VARS OpenMP_Fortran_FLAGS) + unset(OpenMP_Fortran_FLAG_CANDIDATES) + unset(OpenMP_Fortran_TEST_SOURCE) +endif() + set(CMAKE_REQUIRED_QUIET ${CMAKE_REQUIRED_QUIET_SAVE}) if(_OPENMP_REQUIRED_VARS) diff --git a/Modules/FindXerces.cmake b/Modules/FindXerces.cmake new file mode 100644 index 0000000..325bb6d --- /dev/null +++ b/Modules/FindXerces.cmake @@ -0,0 +1,85 @@ +#.rst: +# FindXerces +# ---------- +# +# Find the Apache Xerces-C++ validating XML parser headers and libraries. +# +# This module reports information about the Xerces installation in +# several variables. General variables:: +# +# Xerces_FOUND - true if the Xerces headers and libraries were found +# Xerces_VERSION - Xerces release version +# Xerces_INCLUDE_DIRS - the directory containing the Xerces headers +# Xerces_LIBRARIES - Xerces libraries to be linked +# +# The following cache variables may also be set:: +# +# Xerces_INCLUDE_DIR - the directory containing the Xerces headers +# Xerces_LIBRARY - the Xerces library + +# Written by Roger Leigh <rleigh@codelibre.net> + +#============================================================================= +# Copyright 2014 University of Dundee +# +# Distributed under the OSI-approved BSD License (the "License"); +# see accompanying file Copyright.txt for details. +# +# This software is distributed WITHOUT ANY WARRANTY; without even the +# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +# See the License for more information. +#============================================================================= +# (To distribute this file outside of CMake, substitute the full +# License text for the above reference.) + +function(_Xerces_GET_VERSION version_hdr) + file(STRINGS ${version_hdr} _contents REGEX "^[ \t]*#define XERCES_VERSION_.*") + if(_contents) + string(REGEX REPLACE ".*#define XERCES_VERSION_MAJOR[ \t]+([0-9]+).*" "\\1" Xerces_MAJOR "${_contents}") + string(REGEX REPLACE ".*#define XERCES_VERSION_MINOR[ \t]+([0-9]+).*" "\\1" Xerces_MINOR "${_contents}") + string(REGEX REPLACE ".*#define XERCES_VERSION_REVISION[ \t]+([0-9]+).*" "\\1" Xerces_PATCH "${_contents}") + + if(NOT Xerces_MAJOR MATCHES "^[0-9]+$") + message(FATAL_ERROR "Version parsing failed for XERCES_VERSION_MAJOR!") + endif() + if(NOT Xerces_MINOR MATCHES "^[0-9]+$") + message(FATAL_ERROR "Version parsing failed for XERCES_VERSION_MINOR!") + endif() + if(NOT Xerces_PATCH MATCHES "^[0-9]+$") + message(FATAL_ERROR "Version parsing failed for XERCES_VERSION_REVISION!") + endif() + + set(Xerces_VERSION "${Xerces_MAJOR}.${Xerces_MINOR}.${Xerces_PATCH}" PARENT_SCOPE) + else() + message(FATAL_ERROR "Include file ${version_hdr} does not exist or does not contain expected version information") + endif() +endfunction() + +# Find include directory +find_path(Xerces_INCLUDE_DIR + NAMES "xercesc/util/PlatformUtils.hpp" + DOC "Xerces-C++ include directory") +mark_as_advanced(Xerces_INCLUDE_DIR) + +# Find all Xerces libraries +find_library(Xerces_LIBRARY "xerces-c" + DOC "Xerces-C++ libraries") +mark_as_advanced(Xerces_LIBRARY) + +if(Xerces_INCLUDE_DIR) + _Xerces_GET_VERSION("${Xerces_INCLUDE_DIR}/xercesc/util/XercesVersion.hpp") +endif() + +include(FindPackageHandleStandardArgs) +FIND_PACKAGE_HANDLE_STANDARD_ARGS(Xerces + FOUND_VAR Xerces_FOUND + REQUIRED_VARS Xerces_LIBRARY + Xerces_INCLUDE_DIR + Xerces_VERSION + VERSION_VAR Xerces_VERSION + FAIL_MESSAGE "Failed to find Xerces") + +if(Xerces_FOUND) + set(Xerces_INCLUDE_DIRS "${Xerces_INCLUDE_DIR}") + set(Xerces_LIBRARIES "${Xerces_LIBRARY}") +endif() diff --git a/Source/CMakeVersion.cmake b/Source/CMakeVersion.cmake index b9c3034..077005a 100644 --- a/Source/CMakeVersion.cmake +++ b/Source/CMakeVersion.cmake @@ -1,5 +1,5 @@ # CMake version number components. set(CMake_VERSION_MAJOR 3) set(CMake_VERSION_MINOR 0) -set(CMake_VERSION_PATCH 20140813) +set(CMake_VERSION_PATCH 20140822) #set(CMake_VERSION_RC 1) diff --git a/Source/CPack/IFW/cmCPackIFWGenerator.cxx b/Source/CPack/IFW/cmCPackIFWGenerator.cxx index e7c97c6..732938b 100644 --- a/Source/CPack/IFW/cmCPackIFWGenerator.cxx +++ b/Source/CPack/IFW/cmCPackIFWGenerator.cxx @@ -33,8 +33,6 @@ //---------------------------------------------------------------------------- cmCPackIFWGenerator::cmCPackIFWGenerator() { - // Change the default behavior - componentPackageMethod = ONE_PACKAGE_PER_COMPONENT; } //---------------------------------------------------------------------------- @@ -374,9 +372,6 @@ cmCPackComponentGroup* cmCPackIFWGenerator::GetComponentGroup(const std::string &projectName, const std::string &groupName) { - ComponentGoupsMap::iterator git = ComponentGroups.find(groupName); - if ( git != ComponentGroups.end() ) return &(git->second); - cmCPackComponentGroup* group = cmCPackGenerator::GetComponentGroup(projectName, groupName); if(!group) return group; @@ -388,7 +383,7 @@ cmCPackIFWGenerator::GetComponentGroup(const std::string &projectName, cmCPackIFWPackage *package = &Packages[name]; package->Name = name; package->Generator = this; - if(package->ConfigureFromComponentGroup(group)) + if(package->ConfigureFromGroup(group)) { package->Installer = &Installer; Installer.Packages.insert( @@ -436,17 +431,29 @@ bool cmCPackIFWGenerator::IsOnePackage() const } //---------------------------------------------------------------------------- -std::string cmCPackIFWGenerator::GetRootPackageName() const +std::string cmCPackIFWGenerator::GetRootPackageName() { + // Default value std::string name = "root"; - if(const char* optIFW_ROOT_PACKAGE_NAME = - this->GetOption("CPACK_IFW_ROOT_PACKAGE_NAME")) + if (const char* optIFW_PACKAGE_GROUP = + this->GetOption("CPACK_IFW_PACKAGE_GROUP")) + { + // Configure from root group + cmCPackIFWPackage package; + package.Generator = this; + package.ConfigureFromGroup(optIFW_PACKAGE_GROUP); + name = package.Name; + } + else if (const char* optIFW_PACKAGE_NAME = + this->GetOption("CPACK_IFW_PACKAGE_NAME")) { - name = optIFW_ROOT_PACKAGE_NAME; + // Configure from root package name + name = optIFW_PACKAGE_NAME; } else if (const char* optPACKAGE_NAME = this->GetOption("CPACK_PACKAGE_NAME")) { + // Configure from package name name = optPACKAGE_NAME; } return name; diff --git a/Source/CPack/IFW/cmCPackIFWGenerator.h b/Source/CPack/IFW/cmCPackIFWGenerator.h index e871f7c..7211e04 100644 --- a/Source/CPack/IFW/cmCPackIFWGenerator.h +++ b/Source/CPack/IFW/cmCPackIFWGenerator.h @@ -97,7 +97,7 @@ protected: // Methods bool IsOnePackage() const; - std::string GetRootPackageName() const; + std::string GetRootPackageName(); std::string GetGroupPackageName(cmCPackComponentGroup *group) const; std::string GetComponentPackageName(cmCPackComponent *component) const; diff --git a/Source/CPack/IFW/cmCPackIFWInstaller.cxx b/Source/CPack/IFW/cmCPackIFWInstaller.cxx index 78b2ffb..fcb07e6 100644 --- a/Source/CPack/IFW/cmCPackIFWInstaller.cxx +++ b/Source/CPack/IFW/cmCPackIFWInstaller.cxx @@ -48,9 +48,15 @@ const char *cmCPackIFWInstaller::GetOption(const std::string &op) const void cmCPackIFWInstaller::ConfigureFromOptions() { // Name; - if (const char* option = GetOption("CPACK_PACKAGE_NAME")) + if (const char* optIFW_PACKAGE_NAME = + this->GetOption("CPACK_IFW_PACKAGE_NAME")) { - Name = option; + Name = optIFW_PACKAGE_NAME; + } + else if (const char* optPACKAGE_NAME = + this->GetOption("CPACK_PACKAGE_NAME")) + { + Name = optPACKAGE_NAME; } else { @@ -274,7 +280,16 @@ void cmCPackIFWInstaller::GeneratePackageFiles() cmCPackIFWPackage package; package.Generator = Generator; package.Installer = this; - package.ConfigureFromOptions(); + // Check package group + if (const char* option = GetOption("CPACK_IFW_PACKAGE_GROUP")) + { + package.ConfigureFromGroup(option); + package.ForcedInstallation = "true"; + } + else + { + package.ConfigureFromOptions(); + } package.GeneratePackageFile(); return; } diff --git a/Source/CPack/IFW/cmCPackIFWInstaller.h b/Source/CPack/IFW/cmCPackIFWInstaller.h index 02cd07b..1630a94 100644 --- a/Source/CPack/IFW/cmCPackIFWInstaller.h +++ b/Source/CPack/IFW/cmCPackIFWInstaller.h @@ -13,7 +13,7 @@ #ifndef cmCPackIFWInstaller_h #define cmCPackIFWInstaller_h -#include "cmStandardIncludes.h" +#include <cmStandardIncludes.h> class cmCPackIFWPackage; class cmCPackIFWGenerator; diff --git a/Source/CPack/IFW/cmCPackIFWPackage.cxx b/Source/CPack/IFW/cmCPackIFWPackage.cxx index 5e7a7c7..3c45639 100644 --- a/Source/CPack/IFW/cmCPackIFWPackage.cxx +++ b/Source/CPack/IFW/cmCPackIFWPackage.cxx @@ -121,7 +121,14 @@ cmCPackIFWPackage::cmCPackIFWPackage() : //---------------------------------------------------------------------------- const char *cmCPackIFWPackage::GetOption(const std::string &op) const { - return Generator ? Generator->GetOption(op) : 0; + const char *option = Generator ? Generator->GetOption(op) : 0; + return option && *option ? option : 0; +} + +//---------------------------------------------------------------------------- +bool cmCPackIFWPackage::IsOn(const std::string &op) const +{ + return Generator ? Generator->IsOn(op) : false; } //---------------------------------------------------------------------------- @@ -232,7 +239,6 @@ int cmCPackIFWPackage::ConfigureFromComponent(cmCPackComponent *component) // Script if (const char* option = GetOption(prefix + "SCRIPT")) { - // TODO: add check file exist Script = option; } @@ -306,7 +312,7 @@ int cmCPackIFWPackage::ConfigureFromComponent(cmCPackComponent *component) //---------------------------------------------------------------------------- int -cmCPackIFWPackage::ConfigureFromComponentGroup(cmCPackComponentGroup *group) +cmCPackIFWPackage::ConfigureFromGroup(cmCPackComponentGroup *group) { if(!group) return 0; @@ -335,6 +341,12 @@ cmCPackIFWPackage::ConfigureFromComponentGroup(cmCPackComponentGroup *group) Version = "1.0.0"; } + // Script + if (const char* option = GetOption(prefix + "SCRIPT")) + { + Script = option; + } + // Licenses if (const char* option = this->GetOption(prefix + "LICENSES")) { @@ -359,6 +371,48 @@ cmCPackIFWPackage::ConfigureFromComponentGroup(cmCPackComponentGroup *group) } //---------------------------------------------------------------------------- +int cmCPackIFWPackage::ConfigureFromGroup(const std::string &groupName) +{ + // Group configuration + + cmCPackComponentGroup group; + std::string prefix = "CPACK_COMPONENT_GROUP_" + + cmsys::SystemTools::UpperCase(groupName) + + "_"; + + if (const char *option = GetOption(prefix + "DISPLAY_NAME")) + { + group.DisplayName = option; + } + else + { + group.DisplayName = group.Name; + } + + if (const char* option = GetOption(prefix + "DESCRIPTION")) + { + group.Description = option; + } + group.IsBold = IsOn(prefix + "BOLD_TITLE"); + group.IsExpandedByDefault = IsOn(prefix + "EXPANDED"); + + // Package configuration + + group.Name = groupName; + + if(Generator) + { + Name = Generator->GetGroupPackageName(&group); + } + else + { + Name = group.Name; + } + + return ConfigureFromGroup(&group); +} + +//---------------------------------------------------------------------------- void cmCPackIFWPackage::GeneratePackageFile() { // Lazy directory initialization diff --git a/Source/CPack/IFW/cmCPackIFWPackage.h b/Source/CPack/IFW/cmCPackIFWPackage.h index 868c15d..9fc9bd0 100644 --- a/Source/CPack/IFW/cmCPackIFWPackage.h +++ b/Source/CPack/IFW/cmCPackIFWPackage.h @@ -13,7 +13,7 @@ #ifndef cmCPackIFWPackage_h #define cmCPackIFWPackage_h -#include "cmStandardIncludes.h" +#include <cmStandardIncludes.h> class cmCPackComponent; class cmCPackComponentGroup; @@ -105,6 +105,7 @@ public: // Configuration public: // Internal implementation const char* GetOption(const std::string& op) const; + bool IsOn(const std::string& op) const; std::string GetComponentName(cmCPackComponent *component); @@ -112,7 +113,8 @@ public: // Internal implementation int ConfigureFromOptions(); int ConfigureFromComponent(cmCPackComponent *component); - int ConfigureFromComponentGroup(cmCPackComponentGroup *group); + int ConfigureFromGroup(cmCPackComponentGroup *group); + int ConfigureFromGroup(const std::string &groupName); void GeneratePackageFile(); diff --git a/Source/CTest/cmCTestSubmitHandler.cxx b/Source/CTest/cmCTestSubmitHandler.cxx index 109905c..06fcb75 100644 --- a/Source/CTest/cmCTestSubmitHandler.cxx +++ b/Source/CTest/cmCTestSubmitHandler.cxx @@ -1479,8 +1479,10 @@ int cmCTestSubmitHandler::ProcessHandler() //---------------------------------------------------------------------------- std::string cmCTestSubmitHandler::GetSubmitResultsPrefix() { + std::string buildname = cmCTest::SafeBuildIdField( + this->CTest->GetCTestConfiguration("BuildName")); std::string name = this->CTest->GetCTestConfiguration("Site") + - "___" + this->CTest->GetCTestConfiguration("BuildName") + + "___" + buildname + "___" + this->CTest->GetCurrentTag() + "-" + this->CTest->GetTestModelString() + "___XML___"; return name; diff --git a/Source/CTest/cmCTestUpdateCommand.cxx b/Source/CTest/cmCTestUpdateCommand.cxx index 5408a8a..f87466d 100644 --- a/Source/CTest/cmCTestUpdateCommand.cxx +++ b/Source/CTest/cmCTestUpdateCommand.cxx @@ -56,6 +56,8 @@ cmCTestGenericHandler* cmCTestUpdateCommand::InitializeHandler() this->CTest->SetCTestConfigurationFromCMakeVariable(this->Makefile, "GITUpdateCustom", "CTEST_GIT_UPDATE_CUSTOM"); this->CTest->SetCTestConfigurationFromCMakeVariable(this->Makefile, + "UpdateVersionOnly", "CTEST_UPDATE_VERSION_ONLY"); + this->CTest->SetCTestConfigurationFromCMakeVariable(this->Makefile, "HGCommand", "CTEST_HG_COMMAND"); this->CTest->SetCTestConfigurationFromCMakeVariable(this->Makefile, "HGUpdateOptions", "CTEST_HG_UPDATE_OPTIONS"); diff --git a/Source/CTest/cmCTestUpdateHandler.cxx b/Source/CTest/cmCTestUpdateHandler.cxx index fda61ea..68f5fe1 100644 --- a/Source/CTest/cmCTestUpdateHandler.cxx +++ b/Source/CTest/cmCTestUpdateHandler.cxx @@ -258,12 +258,13 @@ int cmCTestUpdateHandler::ProcessHandler() double elapsed_time_start = cmSystemTools::GetTime(); bool updated = vc->Update(); - + std::string buildname = cmCTest::SafeBuildIdField( + this->CTest->GetCTestConfiguration("BuildName")); os << "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" << "<Update mode=\"Client\" Generator=\"ctest-" << cmVersion::GetCMakeVersion() << "\">\n" << "\t<Site>" << this->CTest->GetCTestConfiguration("Site") << "</Site>\n" - << "\t<BuildName>" << this->CTest->GetCTestConfiguration("BuildName") + << "\t<BuildName>" << buildname << "</BuildName>\n" << "\t<BuildStamp>" << this->CTest->GetCurrentTag() << "-" << this->CTest->GetTestModelString() << "</BuildStamp>" << std::endl; diff --git a/Source/CTest/cmCTestUploadHandler.cxx b/Source/CTest/cmCTestUploadHandler.cxx index 4c3f81b..e33c387 100644 --- a/Source/CTest/cmCTestUploadHandler.cxx +++ b/Source/CTest/cmCTestUploadHandler.cxx @@ -44,14 +44,15 @@ int cmCTestUploadHandler::ProcessHandler() "Cannot open Upload.xml file" << std::endl); return -1; } - + std::string buildname = cmCTest::SafeBuildIdField( + this->CTest->GetCTestConfiguration("BuildName")); cmCTest::SetOfStrings::const_iterator it; ofs << "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" << "<?xml-stylesheet type=\"text/xsl\" " "href=\"Dart/Source/Server/XSL/Build.xsl " "<file:///Dart/Source/Server/XSL/Build.xsl> \"?>\n" << "<Site BuildName=\"" - << this->CTest->GetCTestConfiguration("BuildName") + << buildname << "\" BuildStamp=\"" << this->CTest->GetCurrentTag() << "-" << this->CTest->GetTestModelString() << "\" Name=\"" diff --git a/Source/CTest/cmCTestVC.cxx b/Source/CTest/cmCTestVC.cxx index f89fa2b..15f796f 100644 --- a/Source/CTest/cmCTestVC.cxx +++ b/Source/CTest/cmCTestVC.cxx @@ -166,10 +166,17 @@ void cmCTestVC::CleanupImpl() //---------------------------------------------------------------------------- bool cmCTestVC::Update() { - this->NoteOldRevision(); - this->Log << "--- Begin Update ---\n"; - bool result = this->UpdateImpl(); - this->Log << "--- End Update ---\n"; + bool result = true; + // if update version only is on then do not actually update, + // just note the current version and finish + if(!cmSystemTools::IsOn( + this->CTest->GetCTestConfiguration("UpdateVersionOnly").c_str())) + { + this->NoteOldRevision(); + this->Log << "--- Begin Update ---\n"; + result = this->UpdateImpl(); + this->Log << "--- End Update ---\n"; + } this->NoteNewRevision(); return result; } diff --git a/Source/CTest/cmParseMumpsCoverage.cxx b/Source/CTest/cmParseMumpsCoverage.cxx index 6236211..225e704 100644 --- a/Source/CTest/cmParseMumpsCoverage.cxx +++ b/Source/CTest/cmParseMumpsCoverage.cxx @@ -96,11 +96,13 @@ void cmParseMumpsCoverage::InitializeMumpsFile(std::string& file) } if(found) { - // (2) If the first character found above is whitespace then continue the - // search for the first following non-whitespace character. + // (2) If the first character found above is whitespace or a period + // then continue the search for the first following non-whitespace + // character. if(line[i] == ' ' || line[i] == '\t') { - while(i < line.size() && (line[i] == ' ' || line[i] == '\t')) + while(i < line.size() && (line[i] == ' ' || line[i] == '\t' + || line[i] == '.')) { i++; } diff --git a/Source/QtDialog/CMakeSetupDialog.cxx b/Source/QtDialog/CMakeSetupDialog.cxx index 8a37797..0574681 100644 --- a/Source/QtDialog/CMakeSetupDialog.cxx +++ b/Source/QtDialog/CMakeSetupDialog.cxx @@ -756,6 +756,9 @@ bool CMakeSetupDialog::setupFirstConfigure() QString systemName = dialog.getSystemName(); m->insertProperty(QCMakeProperty::STRING, "CMAKE_SYSTEM_NAME", tr("CMake System Name"), systemName, false); + QString systemVersion = dialog.getSystemVersion(); + m->insertProperty(QCMakeProperty::STRING, "CMAKE_SYSTEM_VERSION", + tr("CMake System Version"), systemVersion, false); QString cxxCompiler = dialog.getCXXCompiler(); m->insertProperty(QCMakeProperty::FILEPATH, "CMAKE_CXX_COMPILER", tr("CXX compiler."), cxxCompiler, false); diff --git a/Source/cmCTest.cxx b/Source/cmCTest.cxx index b28f3b5..a7905a4 100644 --- a/Source/cmCTest.cxx +++ b/Source/cmCTest.cxx @@ -488,9 +488,11 @@ int cmCTest::Initialize(const char* binary_dir, cmCTestStartCommand* command) { cmCTestLog(this, DEBUG, "Here: " << __LINE__ << std::endl); cmCTestLog(this, OUTPUT, - " Site: " << this->GetCTestConfiguration("Site") << std::endl - << " Build name: " << this->GetCTestConfiguration("BuildName") - << std::endl); + " Site: " << this->GetCTestConfiguration("Site") << std::endl + << " Build name: " + << cmCTest::SafeBuildIdField( + this->GetCTestConfiguration("BuildName")) + << std::endl); cmCTestLog(this, DEBUG, "Produce XML is on" << std::endl); if ( this->TestModel == cmCTest::NIGHTLY && this->GetCTestConfiguration("NightlyStartTime").empty() ) @@ -1441,7 +1443,7 @@ std::string cmCTest::SafeBuildIdField(const std::string& value) // Disallow non-filename and non-space whitespace characters. // If they occur, replace them with "" // - const char *disallowed = "\\/:*?\"<>|\n\r\t\f\v"; + const char *disallowed = "\\:*?\"<>|\n\r\t\f\v"; if (safevalue.find_first_of(disallowed) != value.npos) { @@ -1582,12 +1584,14 @@ void cmCTest::EndXML(std::ostream& ostr) int cmCTest::GenerateCTestNotesOutput(std::ostream& os, const cmCTest::VectorOfStrings& files) { + std::string buildname = cmCTest::SafeBuildIdField( + this->GetCTestConfiguration("BuildName")); cmCTest::VectorOfStrings::const_iterator it; os << "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" << "<?xml-stylesheet type=\"text/xsl\" " "href=\"Dart/Source/Server/XSL/Build.xsl " "<file:///Dart/Source/Server/XSL/Build.xsl> \"?>\n" - << "<Site BuildName=\"" << this->GetCTestConfiguration("BuildName") + << "<Site BuildName=\"" << buildname << "\" BuildStamp=\"" << this->CurrentTag << "-" << this->GetTestModelString() << "\" Name=\"" << this->GetCTestConfiguration("Site") << "\" Generator=\"ctest" diff --git a/Source/cmListFileLexer.c b/Source/cmListFileLexer.c index bfa388e..af4fc3d 100644 --- a/Source/cmListFileLexer.c +++ b/Source/cmListFileLexer.c @@ -369,8 +369,8 @@ static void yy_fatal_error (yyconst char msg[] ,yyscan_t yyscanner ); *yy_cp = '\0'; \ yyg->yy_c_buf_p = yy_cp; -#define YY_NUM_RULES 23 -#define YY_END_OF_BUFFER 24 +#define YY_NUM_RULES 24 +#define YY_END_OF_BUFFER 25 /* This struct is not used in this scanner, but its presence is necessary. */ struct yy_trans_info @@ -381,10 +381,10 @@ struct yy_trans_info static yyconst flex_int16_t yy_accept[77] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, - 24, 13, 21, 1, 15, 3, 13, 5, 6, 7, - 22, 22, 16, 18, 19, 20, 10, 11, 8, 12, - 9, 4, 13, 0, 13, 0, 21, 0, 0, 7, - 13, 0, 13, 0, 2, 0, 13, 16, 0, 17, + 25, 13, 22, 1, 16, 3, 13, 5, 6, 7, + 15, 23, 17, 19, 20, 21, 10, 11, 8, 12, + 9, 4, 13, 0, 13, 0, 22, 0, 0, 7, + 13, 0, 13, 0, 2, 0, 13, 17, 0, 18, 10, 8, 4, 0, 14, 0, 0, 0, 0, 14, 0, 0, 14, 0, 0, 0, 2, 14, 0, 0, 0, 0, 0, 0, 0, 0 @@ -523,10 +523,10 @@ static yyconst flex_int16_t yy_chk[253] = } ; /* Table of booleans, true if rule could match eol. */ -static yyconst flex_int32_t yy_rule_can_match_eol[24] = +static yyconst flex_int32_t yy_rule_can_match_eol[25] = { 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, - 0, 0, 0, 0, }; +1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, + 0, 0, 0, 0, 0, }; /* The intent behind this definition is that it'll catch * any uses of REJECT which flex missed. @@ -615,7 +615,7 @@ static void cmListFileLexerDestroy(cmListFileLexer* lexer); -#line 621 "cmListFileLexer.c" +#line 628 "cmListFileLexer.c" #define INITIAL 0 #define STRING 1 @@ -850,7 +850,7 @@ YY_DECL #line 91 "cmListFileLexer.in.l" -#line 858 "cmListFileLexer.c" +#line 865 "cmListFileLexer.c" if ( !yyg->yy_init ) { @@ -1111,75 +1111,84 @@ case 15: YY_RULE_SETUP #line 215 "cmListFileLexer.in.l" { + lexer->token.type = cmListFileLexer_Token_ArgumentUnquoted; + cmListFileLexerSetToken(lexer, yytext, yyleng); + lexer->column += yyleng; + return 1; +} +case 16: +YY_RULE_SETUP +#line 222 "cmListFileLexer.in.l" +{ lexer->token.type = cmListFileLexer_Token_ArgumentQuoted; cmListFileLexerSetToken(lexer, "", 0); lexer->column += yyleng; BEGIN(STRING); } YY_BREAK -case 16: +case 17: YY_RULE_SETUP -#line 222 "cmListFileLexer.in.l" +#line 229 "cmListFileLexer.in.l" { cmListFileLexerAppend(lexer, yytext, yyleng); lexer->column += yyleng; } YY_BREAK -case 17: -/* rule 17 can match eol */ +case 18: +/* rule 18 can match eol */ YY_RULE_SETUP -#line 227 "cmListFileLexer.in.l" +#line 234 "cmListFileLexer.in.l" { /* Continuation: text is not part of string */ ++lexer->line; lexer->column = 1; } YY_BREAK -case 18: -/* rule 18 can match eol */ +case 19: +/* rule 19 can match eol */ YY_RULE_SETUP -#line 233 "cmListFileLexer.in.l" +#line 240 "cmListFileLexer.in.l" { cmListFileLexerAppend(lexer, yytext, yyleng); ++lexer->line; lexer->column = 1; } YY_BREAK -case 19: +case 20: YY_RULE_SETUP -#line 239 "cmListFileLexer.in.l" +#line 246 "cmListFileLexer.in.l" { lexer->column += yyleng; BEGIN(INITIAL); return 1; } -case 20: +case 21: YY_RULE_SETUP -#line 245 "cmListFileLexer.in.l" +#line 252 "cmListFileLexer.in.l" { cmListFileLexerAppend(lexer, yytext, yyleng); lexer->column += yyleng; } YY_BREAK case YY_STATE_EOF(STRING): -#line 250 "cmListFileLexer.in.l" +#line 257 "cmListFileLexer.in.l" { lexer->token.type = cmListFileLexer_Token_BadString; BEGIN(INITIAL); return 1; } -case 21: +case 22: YY_RULE_SETUP -#line 256 "cmListFileLexer.in.l" +#line 263 "cmListFileLexer.in.l" { lexer->token.type = cmListFileLexer_Token_Space; cmListFileLexerSetToken(lexer, yytext, yyleng); lexer->column += yyleng; return 1; } -case 22: +case 23: YY_RULE_SETUP -#line 263 "cmListFileLexer.in.l" +#line 270 "cmListFileLexer.in.l" { lexer->token.type = cmListFileLexer_Token_BadCharacter; cmListFileLexerSetToken(lexer, yytext, yyleng); @@ -1188,18 +1197,18 @@ YY_RULE_SETUP } case YY_STATE_EOF(INITIAL): case YY_STATE_EOF(COMMENT): -#line 270 "cmListFileLexer.in.l" +#line 277 "cmListFileLexer.in.l" { lexer->token.type = cmListFileLexer_Token_None; cmListFileLexerSetToken(lexer, 0, 0); return 0; } -case 23: +case 24: YY_RULE_SETUP -#line 276 "cmListFileLexer.in.l" +#line 283 "cmListFileLexer.in.l" ECHO; YY_BREAK -#line 1220 "cmListFileLexer.c" +#line 1238 "cmListFileLexer.c" case YY_END_OF_BUFFER: { @@ -2320,7 +2329,7 @@ void cmListFileLexer_yyfree (void * ptr , yyscan_t yyscanner) #define YYTABLES_NAME "yytables" -#line 276 "cmListFileLexer.in.l" +#line 282 "cmListFileLexer.in.l" diff --git a/Source/cmListFileLexer.in.l b/Source/cmListFileLexer.in.l index ed4bf6b..a520c72 100644 --- a/Source/cmListFileLexer.in.l +++ b/Source/cmListFileLexer.in.l @@ -212,6 +212,13 @@ LEGACY {MAKEVAR}|{UNQUOTED}|\"({MAKEVAR}|{UNQUOTED}|[ \t[=])*\" return 1; } +\[ { + lexer->token.type = cmListFileLexer_Token_ArgumentUnquoted; + cmListFileLexerSetToken(lexer, yytext, yyleng); + lexer->column += yyleng; + return 1; +} + \" { lexer->token.type = cmListFileLexer_Token_ArgumentQuoted; cmListFileLexerSetToken(lexer, "", 0); diff --git a/Source/cmMakefileTargetGenerator.cxx b/Source/cmMakefileTargetGenerator.cxx index 758c8e4..7849d12 100644 --- a/Source/cmMakefileTargetGenerator.cxx +++ b/Source/cmMakefileTargetGenerator.cxx @@ -361,9 +361,13 @@ void cmMakefileTargetGenerator::WriteTargetLanguageFlags() for(std::set<std::string>::const_iterator l = languages.begin(); l != languages.end(); ++l) { - *this->FlagFileStream << *l << "_FLAGS = " << this->GetFlags(*l) << "\n\n"; - *this->FlagFileStream << *l << "_DEFINES = " << this->GetDefines(*l) << - "\n\n"; + std::string flags = this->GetFlags(*l); + std::string defines = this->GetDefines(*l); + // Escape comment characters so they do not terminate assignment. + cmSystemTools::ReplaceString(flags, "#", "\\#"); + cmSystemTools::ReplaceString(defines, "#", "\\#"); + *this->FlagFileStream << *l << "_FLAGS = " << flags << "\n\n"; + *this->FlagFileStream << *l << "_DEFINES = " << defines << "\n\n"; } } diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx index b9295e4..09a9252 100644 --- a/Source/cmVisualStudio10TargetGenerator.cxx +++ b/Source/cmVisualStudio10TargetGenerator.cxx @@ -1044,12 +1044,24 @@ void cmVisualStudio10TargetGenerator::WriteHeaderSource(cmSourceFile const* sf) void cmVisualStudio10TargetGenerator::WriteExtraSource(cmSourceFile const* sf) { + bool toolHasSettings = false; std::string tool = "None"; + std::string shaderType; std::string const& ext = sf->GetExtension(); if(ext == "appxmanifest") { tool = "AppxManifest"; } + else if(ext == "hlsl") + { + tool = "FXCompile"; + // Figure out the type of shader compiler to use. + if(const char* st = sf->GetProperty("VS_SHADER_TYPE")) + { + shaderType = st; + toolHasSettings = true; + } + } else if(ext == "jpg" || ext == "png") { @@ -1059,7 +1071,64 @@ void cmVisualStudio10TargetGenerator::WriteExtraSource(cmSourceFile const* sf) { tool = "XML"; } - this->WriteSource(tool, sf); + + std::string deployContent; + if(this->GlobalGenerator->TargetsWindowsPhone() || + this->GlobalGenerator->TargetsWindowsStore()) + { + const char* content = sf->GetProperty("VS_DEPLOYMENT_CONTENT"); + if(content && *content) + { + toolHasSettings = true; + deployContent = content; + } + } + + if(toolHasSettings) + { + this->WriteSource(tool, sf, ">\n"); + + if(!deployContent.empty()) + { + std::vector<std::string> const* configs = + this->GlobalGenerator->GetConfigurations(); + cmGeneratorExpression ge; + cmsys::auto_ptr<cmCompiledGeneratorExpression> cge = + ge.Parse(deployContent); + for(size_t i = 0; i != configs->size(); ++i) + { + if(0 == strcmp(cge->Evaluate(this->Makefile, (*configs)[i]), "1")) + { + this->WriteString("<DeploymentContent Condition=\"" + "'$(Configuration)|$(Platform)'=='", 3); + (*this->BuildFileStream) << (*configs)[i] << "|" + << this->Platform << "'\">true"; + this->WriteString("</DeploymentContent>\n", 0); + } + else + { + this->WriteString("<ExcludedFromBuild Condition=\"" + "'$(Configuration)|$(Platform)'=='", 3); + (*this->BuildFileStream) << (*configs)[i] << "|" + << this->Platform << "'\">true"; + this->WriteString("</ExcludedFromBuild>\n", 0); + } + } + } + if(!shaderType.empty()) + { + this->WriteString("<ShaderType>", 3); + (*this->BuildFileStream) << cmVS10EscapeXML(shaderType) + << "</ShaderType>\n"; + } + + this->WriteString("</", 2); + (*this->BuildFileStream) << tool << ">\n"; + } + else + { + this->WriteSource(tool, sf); + } } void cmVisualStudio10TargetGenerator::WriteSource( diff --git a/Templates/TestDriver.cxx.in b/Templates/TestDriver.cxx.in index 0e0a872..ffa6999 100644 --- a/Templates/TestDriver.cxx.in +++ b/Templates/TestDriver.cxx.in @@ -3,6 +3,10 @@ #include <string.h> #include <stdlib.h> +#if defined(_MSC_VER) +# pragma warning(disable:4996) /* deprecation */ +#endif + @CMAKE_TESTDRIVER_EXTRA_INCLUDES@ diff --git a/Tests/CMakeLists.txt b/Tests/CMakeLists.txt index 7aa31cc..f51a934 100644 --- a/Tests/CMakeLists.txt +++ b/Tests/CMakeLists.txt @@ -2168,7 +2168,7 @@ ${CMake_BINARY_DIR}/bin/cmake -DDIR=dev -P ${CMake_SOURCE_DIR}/Utilities/Release $<TARGET_FILE:ctest> -T Coverage --debug) set_tests_properties(CTestGTMCoverage PROPERTIES PASS_REGULAR_EXPRESSION - "Process file.*ZZCOVTST.m.*Total LOC:.*23.*Percentage Coverage: 82.61*" + "Process file.*ZZCOVTST.m.*Total LOC:.*30.*Percentage Coverage: 80.00*" ENVIRONMENT COVFILE=) configure_file( @@ -2186,7 +2186,7 @@ ${CMake_BINARY_DIR}/bin/cmake -DDIR=dev -P ${CMake_SOURCE_DIR}/Utilities/Release $<TARGET_FILE:ctest> -T Coverage --debug) set_tests_properties(CTestCacheCoverage PROPERTIES PASS_REGULAR_EXPRESSION - "Process file.*ZZCOVTST.m.*Total LOC:.*22.*Percentage Coverage: 86.36.*" + "Process file.*ZZCOVTST.m.*Total LOC:.*29.*Percentage Coverage: 86.21.*" ENVIRONMENT COVFILE=) # Adding a test case for Python Coverage diff --git a/Tests/CTestUpdateCommon.cmake b/Tests/CTestUpdateCommon.cmake index 857c6f5..97153f0 100644 --- a/Tests/CTestUpdateCommon.cmake +++ b/Tests/CTestUpdateCommon.cmake @@ -219,6 +219,36 @@ function(run_dashboard_command_line bin_dir) endfunction() #----------------------------------------------------------------------------- +# Function to find the Update.xml file and make sure +# it only has the Revision in it and no updates +function(check_no_update bin_dir) + set(PATTERN ${TOP}/${bin_dir}/Testing/*/Update.xml) + file(GLOB UPDATE_XML_FILE RELATIVE ${TOP} ${PATTERN}) + string(REGEX REPLACE "//Update.xml$" "/Update.xml" + UPDATE_XML_FILE "${UPDATE_XML_FILE}") + message(" found ${UPDATE_XML_FILE}") + set(rev_regex "Revision|PriorRevision") + file(STRINGS ${TOP}/${UPDATE_XML_FILE} UPDATE_XML_REVISIONS + REGEX "^\t<(${rev_regex})>[^<\n]+</(${rev_regex})>$" + ) + set(found_revisons FALSE) + foreach(r IN LISTS UPDATE_XML_REVISIONS) + if("${r}" MATCHES "PriorRevision") + message(FATAL_ERROR "Found PriorRevision in no update test") + endif() + if("${r}" MATCHES "<Revision>") + set(found_revisons TRUE) + endif() + endforeach() + if(found_revisons) + message(" found <Revision> in no update test") + else() + message(FATAL_ERROR " missing <Revision> in no update test") + endif() +endfunction() + + +#----------------------------------------------------------------------------- # Function to run the dashboard through a script function(run_dashboard_script bin_dir) run_child( @@ -228,13 +258,17 @@ function(run_dashboard_script bin_dir) # Verify the updates reported by CTest. list(APPEND UPDATE_MAYBE Updated{subdir} Updated{CTestConfig.cmake}) - check_updates(${bin_dir} - Updated{foo.txt} - Updated{bar.txt} - Updated{zot.txt} - Updated{subdir/foo.txt} - Updated{subdir/bar.txt} - ) + if(NO_UPDATE) + check_no_update(${bin_dir}) + else() + check_updates(${bin_dir} + Updated{foo.txt} + Updated{bar.txt} + Updated{zot.txt} + Updated{subdir/foo.txt} + Updated{subdir/bar.txt} + ) + endif() endfunction() #----------------------------------------------------------------------------- diff --git a/Tests/CTestUpdateGIT.cmake.in b/Tests/CTestUpdateGIT.cmake.in index f6939de..41b732b 100644 --- a/Tests/CTestUpdateGIT.cmake.in +++ b/Tests/CTestUpdateGIT.cmake.in @@ -317,3 +317,20 @@ set(CTEST_GIT_UPDATE_CUSTOM \${CTEST_GIT_COMMAND} pull origin master) # Run the dashboard script with CTest. run_dashboard_script(dash-binary-custom) + + +rewind_source(dash-source) + +#----------------------------------------------------------------------------- +# Test no update with a dashboard script. +message("Running CTest Dashboard Script (No update)...") + +create_dashboard_script(dash-binary-no-update + "# git command configuration +set(CTEST_GIT_COMMAND \"${GIT}\") +set(CTEST_UPDATE_VERSION_ONLY TRUE) +") + +# Run the dashboard script with CTest. +set(NO_UPDATE 1) +run_dashboard_script(dash-binary-no-update) diff --git a/Tests/CompileOptions/CMakeLists.txt b/Tests/CompileOptions/CMakeLists.txt index 9b6c9c2..05a5f82 100644 --- a/Tests/CompileOptions/CMakeLists.txt +++ b/Tests/CompileOptions/CMakeLists.txt @@ -22,6 +22,12 @@ set_property(TARGET CompileOptions PROPERTY COMPILE_OPTIONS ${cxx_tests} ) +if(CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang|Borland") + set_property(TARGET CompileOptions APPEND PROPERTY COMPILE_OPTIONS + "-DTEST_OCTOTHORPE=\"#\"" + ) +endif() + target_link_libraries(CompileOptions testlib) if(CMAKE_CXX_COMPILER_ID MATCHES "GNU") diff --git a/Tests/CompileOptions/main.cpp b/Tests/CompileOptions/main.cpp index 42f4cca..f3c1355 100644 --- a/Tests/CompileOptions/main.cpp +++ b/Tests/CompileOptions/main.cpp @@ -17,6 +17,9 @@ int main() { return (strcmp(NEEDS_ESCAPE, "E$CAPE") == 0 +#ifdef TEST_OCTOTHORPE + && strcmp(TEST_OCTOTHORPE, "#") == 0 +#endif && strcmp(EXPECTED_C_COMPILER_VERSION, TEST_C_COMPILER_VERSION) == 0 && strcmp(EXPECTED_CXX_COMPILER_VERSION, TEST_CXX_COMPILER_VERSION) == 0 && TEST_C_COMPILER_VERSION_EQUALITY == 1 diff --git a/Tests/FortranOnly/CMakeLists.txt b/Tests/FortranOnly/CMakeLists.txt index d57a8b2..a3f83c9 100644 --- a/Tests/FortranOnly/CMakeLists.txt +++ b/Tests/FortranOnly/CMakeLists.txt @@ -43,3 +43,25 @@ add_custom_target(checksayhello ALL COMMAND ${CMAKE_COMMAND} -P ${FortranOnly_SOURCE_DIR}/checksayhello.cmake ) add_dependencies(checksayhello sayhello) + +# Exclude this test on IBM XL for now because the check strangely +# fails with 'ld: 0706-029 Use a number with the -H flag'. +if(NOT CMAKE_Fortran_COMPILER_ID STREQUAL XL) + set(err_log ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log) + file(REMOVE "${err_log}") + include(CheckFortranSourceCompiles) + unset(HAVE_PRINT CACHE) + CHECK_Fortran_SOURCE_COMPILES([[ + PROGRAM TEST_HAVE_PRINT + PRINT *, 'Hello' + END +]] HAVE_PRINT) + if(NOT HAVE_PRINT) + if(EXISTS "${err_log}") + file(READ "${err_log}" err) + endif() + string(REPLACE "\n" "\n " err " ${err}") + message(SEND_ERROR "CHECK_Fortran_SOURCE_COMPILES for HAVE_PRINT failed:\n" + "${err}") + endif() +endif() diff --git a/Tests/MumpsCoverage/VistA-FOIA/Packages/Uncategorized/ZZCOVTST.m b/Tests/MumpsCoverage/VistA-FOIA/Packages/Uncategorized/ZZCOVTST.m index 9a08edf..ee70682 100644 --- a/Tests/MumpsCoverage/VistA-FOIA/Packages/Uncategorized/ZZCOVTST.m +++ b/Tests/MumpsCoverage/VistA-FOIA/Packages/Uncategorized/ZZCOVTST.m @@ -10,6 +10,7 @@ EN ; This entry point shouldn't be found without fixing I '$$T5 W "RETURNED FROM t5",! Q ; This line not executable + D T6^ZZCOVTST ; T1 ; This line should always be found N D @@ -33,4 +34,10 @@ T4 N D S D=5 W "Shouldn't be executed" T5(EQ) ;this entry point is called with a $$ notation W "THIS IS THE $$ NOTATION!",! Q 0 +T6 ; An entry point to show comments inside of "DO" blocks + D + . W "This is executable code",! + . ;This is a comment inside the do block, not executable + . S ZZBLAH="blah" + W "Ending T6",! ; diff --git a/Tests/MumpsCoverage/ZZCOVTST.cmcov b/Tests/MumpsCoverage/ZZCOVTST.cmcov index 798e5b2..7a5df61 100644 --- a/Tests/MumpsCoverage/ZZCOVTST.cmcov +++ b/Tests/MumpsCoverage/ZZCOVTST.cmcov @@ -1,5 +1,5 @@ Routine,Line,RtnLine,Code
-ZZCOVTST,1,0,"ZZCOVTST;OSEHRA/JPS -- Test routine for Coverage Parsing;4/28/2014"
+ZZCOVTST,1,1,"ZZCOVTST;OSEHRA/JPS -- Test routine for Coverage Parsing;4/28/2014"
,2,0," ; (tab) This is series of comments"
,3,0," ; (tab) it should all be not executable"
,4,0," ; (spaces) one of these sets might be a problem"
@@ -8,31 +8,38 @@ ZZCOVTST,1,0,"ZZCOVTST;OSEHRA/JPS -- Test routine for Coverage Parsing;4/28/2014 ,7,1," N D"
,8,1," S D=1 ;An executable line"
,9,1," D T1^ZZCOVTST"
-,10,1,"I '$$T5 W ""RETURNED FROM t5"",!"
-,11,1," Q"
-,12,0," ; This line not executable"
-,13,0," ;"
-,14,0,"T1 ; This line should always be found"
-,15,1," N D"
-,16,1," S D=2"
-,17,1," W !,D,!,""This is the second entry point"",!"
-,18,1," D T2^ZZCOVTST(D)"
-,19,1," Q"
-,20,0," ;"
-,21,0,"T2(EQ) ; This is debatable"
-,22,1," N D"
-,23,1," S D=3"
-,24,1," W !,D,!,EQ,""This is the third entry point"",!"
-,25,1," D T3^ZZCOVTST"
-,26,1," Q"
-,27,0," ;"
-,28,1,"T3 N D S D=4 W D,!,""Fourth Entry point"",! Q"
-,29,0," ;"
-,30,0,"T4 N D S D=5 W ""Shouldn't be executed"""
-,31,0," W ""Lots to not do"""
-,32,0," Q"
-,33,1,"T5()"
-,34,1," W ""THIS IS ONE WITH $$ NOTATION"",1"
-,35,1," Q 0"
-,36,0," ;"
-Totals for ZZCOVTST,,19,
+,10,1," I '$$T5 W ""RETURNED FROM t5"",!"
+,11,1," D T6^ZZCOVTST"
+,12,1," Q"
+,13,0," ; This line not executable"
+,14,0," ;"
+,15,0,"T1 ; This line should always be found"
+,16,1," N D"
+,17,1," S D=2"
+,18,1," W !,D,!,""This is the second entry point"",!"
+,19,1," D T2^ZZCOVTST(D)"
+,20,1," Q"
+,21,0," ;"
+,22,0,"T2(EQ) ; This is debatable and only called with ENT^ROU notation"
+,23,1," N D"
+,24,1," S D=3"
+,25,1," W !,D,!,EQ,""This is the third entry point"",!"
+,26,1," D T3^ZZCOVTST"
+,27,1," Q"
+,28,0," ;"
+,29,1,"T3 N D S D=4 W D,!,""Fourth Entry point"",! Q"
+,30,0," ;"
+,31,0,"T4 N D S D=5 W ""Shouldn't be executed"""
+,32,0," W ""Lots to not do"""
+,33,0," Q"
+,34,1,"T5(EQ) ;this entry point is called with a $$ notation"
+,35,1," W ""THIS IS THE $$ NOTATION!"",!"
+,36,1," Q 0"
+,37,0,"T6 ; An entry point to show comments inside of ""DO"" blocks"
+,38,1," D"
+,39,1," . W ""This is executable code"",!"
+,40,0," . ; This is a comment inside the do block, not executable"
+,41,1," . S ZZBLAH=""blah"""
+,42,1," W ""Ending T6"",!"
+,43,0," ;"
+Totals for ZZCOVTST,,25,
\ No newline at end of file diff --git a/Tests/MumpsCoverage/ZZCOVTST.mcov b/Tests/MumpsCoverage/ZZCOVTST.mcov index f73d354..b2608d9 100644 --- a/Tests/MumpsCoverage/ZZCOVTST.mcov +++ b/Tests/MumpsCoverage/ZZCOVTST.mcov @@ -1,30 +1,38 @@ %GO Global Output Utility -GT.M 30-APR-2014 14:24:46 ZWR -^ZZCOVERAGE("*CHILDREN")="0:0:0" -^ZZCOVERAGE("*RUN")="24000:88000:112000" -^ZZCOVERAGE("ZZCOVTST","EN")="1:4000:8000:12000:6464583" -^ZZCOVERAGE("ZZCOVTST","EN",1)="1:0:0:0:20" -^ZZCOVERAGE("ZZCOVTST","EN",2)="1:0:0:0:14" -^ZZCOVERAGE("ZZCOVTST","EN",3)="1:0:0:0:26" -^ZZCOVERAGE("ZZCOVTST","EN",4)="1:0:0:0:228" -^ZZCOVERAGE("ZZCOVTST","T1")="1:0:0:0:92" -^ZZCOVERAGE("ZZCOVTST","T1",1)="1:0:0:0:13" -^ZZCOVERAGE("ZZCOVTST","T1",2)="1:0:0:0:12" -^ZZCOVERAGE("ZZCOVTST","T1",3)="1:0:0:0:14" -^ZZCOVERAGE("ZZCOVTST","T1",4)="1:0:0:0:29" -^ZZCOVERAGE("ZZCOVTST","T1",5)="1:0:0:0:12" -^ZZCOVERAGE("ZZCOVTST","T2")="1:0:0:0:102" -^ZZCOVERAGE("ZZCOVTST","T2",0)="1:0:0:0:14" -^ZZCOVERAGE("ZZCOVTST","T2",1)="1:0:0:0:12" -^ZZCOVERAGE("ZZCOVTST","T2",2)="1:0:0:0:12" -^ZZCOVERAGE("ZZCOVTST","T2",3)="1:0:0:0:14" -^ZZCOVERAGE("ZZCOVTST","T2",4)="1:0:0:0:25" -^ZZCOVERAGE("ZZCOVTST","T2",5)="1:0:0:0:12" -^ZZCOVERAGE("ZZCOVTST","T3")="1:0:0:0:28" -^ZZCOVERAGE("ZZCOVTST","T3",0)="1:0:0:0:17" -^ZZCOVERAGE("ZZCOVTST","T5")="1:0:0:0:388" -^ZZCOVERAGE("ZZCOVTST","T5",0)="1:0:0:0:114" -^ZZCOVERAGE("ZZCOVTST","T5",1)="1:0:0:0:28" -^ZZCOVERAGE("ZZCOVTST","T5",2)="1:0:0:0:14" +GT.M 15-AUG-2014 10:14:32 ZWR +^ZZCOVERAGE("*CHILDREN")="212000:68000:280000" +^ZZCOVERAGE("*RUN")="56000:136000:192000" +^ZZCOVERAGE("ZZCOVTST","EN")="1:4000:4000:8000:8627798" +^ZZCOVERAGE("ZZCOVTST","EN",1)="1:0:0:0:27" +^ZZCOVERAGE("ZZCOVTST","EN",2)="1:0:0:0:23" +^ZZCOVERAGE("ZZCOVTST","EN",3)="1:0:0:0:70" +^ZZCOVERAGE("ZZCOVTST","EN",4)="1:0:0:0:74" +^ZZCOVERAGE("ZZCOVTST","EN",5)="1:0:0:0:66" +^ZZCOVERAGE("ZZCOVTST","EN",6)="1:0:0:0:40" +^ZZCOVERAGE("ZZCOVTST","T1")="1:0:0:0:208" +^ZZCOVERAGE("ZZCOVTST","T1",1)="1:0:0:0:23" +^ZZCOVERAGE("ZZCOVTST","T1",2)="1:0:0:0:24" +^ZZCOVERAGE("ZZCOVTST","T1",3)="1:0:0:0:26" +^ZZCOVERAGE("ZZCOVTST","T1",4)="1:0:0:0:73" +^ZZCOVERAGE("ZZCOVTST","T1",5)="1:0:0:0:40" +^ZZCOVERAGE("ZZCOVTST","T2")="1:0:0:0:1783" +^ZZCOVERAGE("ZZCOVTST","T2",0)="1:0:0:0:25" +^ZZCOVERAGE("ZZCOVTST","T2",1)="1:0:0:0:524" +^ZZCOVERAGE("ZZCOVTST","T2",2)="1:0:0:0:40" +^ZZCOVERAGE("ZZCOVTST","T2",3)="1:0:0:0:95" +^ZZCOVERAGE("ZZCOVTST","T2",4)="1:0:0:0:607" +^ZZCOVERAGE("ZZCOVTST","T2",5)="1:0:0:0:470" +^ZZCOVERAGE("ZZCOVTST","T3")="1:0:0:0:254" +^ZZCOVERAGE("ZZCOVTST","T3",0)="1:0:0:0:76" +^ZZCOVERAGE("ZZCOVTST","T5")="1:0:0:0:153" +^ZZCOVERAGE("ZZCOVTST","T5",0)="1:0:0:0:40" +^ZZCOVERAGE("ZZCOVTST","T5",1)="1:0:0:0:41" +^ZZCOVERAGE("ZZCOVTST","T5",2)="1:0:0:0:41" +^ZZCOVERAGE("ZZCOVTST","T6")="1:0:0:0:227" +^ZZCOVERAGE("ZZCOVTST","T6",1)="1:0:0:0:41" +^ZZCOVERAGE("ZZCOVTST","T6",2)="1:0:0:0:42" +^ZZCOVERAGE("ZZCOVTST","T6",4)="1:0:0:0:41" +^ZZCOVERAGE("ZZCOVTST","T6",5)="1:0:0:0:34" +^ZZCOVERAGE("ZZCOVTST","T6",6)="1:0:0:0:38" diff --git a/Tests/RunCMake/Syntax/Unquoted1-stderr.txt b/Tests/RunCMake/Syntax/Unquoted1-stderr.txt index ff8194a..85a7a9d 100644 --- a/Tests/RunCMake/Syntax/Unquoted1-stderr.txt +++ b/Tests/RunCMake/Syntax/Unquoted1-stderr.txt @@ -1 +1 @@ -^\[\]\[=\]\[\$\$\(MV\)-DSTR=" \[="\[;\]$ +^\[\]\[=\]\[\$\$\(MV\)-DSTR=" \[="\[;\]\]\[$ diff --git a/Tests/RunCMake/Syntax/Unquoted1.cmake b/Tests/RunCMake/Syntax/Unquoted1.cmake index 0344fbd..515161f 100644 --- a/Tests/RunCMake/Syntax/Unquoted1.cmake +++ b/Tests/RunCMake/Syntax/Unquoted1.cmake @@ -1 +1 @@ -message([] [=] [$ $(MV) -DSTR=" [=" [;]) +message([] [=] [$ $(MV) -DSTR=" [=" [;] ] [) |