Add missing stringzeug entry in cmake-config.cmake.

--- libzeug-config.cmake
+++ libzeug-config.cmake
@@ -162,6 +162,7 @@
 find(reflection  reflectionzeug/reflectionzeug_api.h   ${LIB_PATHS})
 find(script      scriptzeug/scriptzeug_api.h           ${LIB_PATHS})
 find(signal      signalzeug/signalzeug_api.h           ${LIB_PATHS})
+find(string      stringzeug/stringzeug_api.h           ${LIB_PATHS})
 find(threading   threadingzeug/threadingzeug_api.h     ${LIB_PATHS})
 find(widget      widgetzeug/widgetzeug_api.h           ${LIB_PATHS})


Add basic documentation for C++ Standard options

--- Modules/CetCompilerSettings.cmake
+++ Modules/CetCompilerSettings.cmake
@@ -77,8 +77,17 @@
 # ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 #
 # The following CMake variables are set by default when including this module
-# for general control of the C++ Standard:
-#
+# to enforce availability and uniformity of the requested C++ Standard:
+#
+#.rst:
+# - :cmake:variable:`CMAKE_CXX_STANDARD_REQUIRED <cmake:variable:CMAKE_CXX_STANDARD_REQUIRED>`: ON
+#
+#   - Prevent decay to an earlier standard if the compiler in use does
+#     not support the requested standard.
+#
+set(CMAKE_CXX_STANDARD_REQUIRED ON)
+
+#.rst:
 # - :cmake:variable:`CMAKE_CXX_EXTENSIONS <cmake:variable:CMAKE_CXX_EXTENSIONS>`: OFF
 #
 #   - Prevent use of vendor specific language extensions. For example, when using the
@@ -87,94 +96,39 @@
 set(CMAKE_CXX_EXTENSIONS OFF)

 #.rst:
-# - :cmake:variable:`CMAKE_CXX_STANDARD_REQUIRED <cmake:variable:CMAKE_CXX_STANDARD_REQUIRED>`: ON
-#
-#   - Prevent decay to an earlier standard if the compiler in use does
-#     not support the requested standard.
-#
-set(CMAKE_CXX_STANDARD_REQUIRED ON)
-
-#.rst:
-# To configure and select the C++ Standard used to compile the project,
-# the ``CMAKE_CXX_STANDARD`` variable is used... A project may specify
-# a minimum standard it requires for compilation, and users may select
-# from this or higher known standards to perform the actual build.
-
-#.rst:
-# .. todo::
-#
-#   Review usage of ``CMAKE_CXX_STANDARD`` vs compile features, as well
-#   as standard specification fo C/Fortran.
-#   In CMake, we have two builtin ways to specify the required standard,
-#   meaning that CMake will set the compile flags like ``-std=c++11`` for
-#   us automatically.
-#
-#   * Set the :cmake:variable:`CMAKE_CXX_STANDARD <cmake:variable:CMAKE_CXX_STANDARD>`
-#     and :cmake:variable:`CMAKE_CXX_STANDARD_REQUIRED <cmake:variable:CMAKE_CXX_STANDARD_REQUIRED>`
-#     variables to the required standard, e.g. ``11``, and ``ON`` to enforce that
-#     the compiler in use supports the standard. These variables provide the
-#     defaults for the :cmake:prop_tgt:`CXX_STANDARD <cmake:prop_tgt:CXX_STANDARD>`
-#     and :cmake:prop_tgt:`CXX_STANDARD_REQUIRED <cmake:prop_tgt:CXX_STANDARD_REQUIRED>` target
-#     properties, which may also be set on a per-target basis. Note that this
-#     method does *not* guarantee that the compiler supports *all* features of
-#     the specified standard.
-#   * Use the :cmake:command:`target_compile_features <cmake:command:target_compile_features>`
-#     command on a target, passing a list of specific features required (see
-#     :cmake:prop_gbl:`CMAKE_CXX_KNOWN_FEATURES <cmake:prop_gbl:CMAKE_CXX_KNOWN_FEATURES>`).
-#     This guarantees that the compiler supports the required language feature, provided
-#     that the compiler, version and standard are known to CMake.
-#
-#   In both cases, CMake automatically adds any needed flags needed to compile
-#   against the requested standard to the compile commands. The main difference is
-#   that ``target_compile_features`` is a `usage requirement` so the features are
-#   propagated to exported targets. Clients of those targets pick up the compile
-#   features, and so can be compiled against the same standard (mostly) automatically.
-#
-#   An advantage of using the plain project-scope variables is that we can easily add
-#   support for new standards quickly by setting the variables
-#   ``CMAKE_CXX<EPOCH>_STANDARD_COMPILE_OPTION`` and ``CMAKE_CXX<EPOCH>_EXTENSION_COMPILE_OPTION``
-#   variables based on the compiler ID and Version. For example ``-std=c++1z`` and ``-std=gnu++1z``
-#   if using GCC 5(?) and above.
-#   Means we cannot support compile features, because names for those need to be defined,
-#   ultimately, by upstream CMake based on the final features defined by ISO.
-#   Can define our own names of course, but at the potential cost of compatibility with
-#   mainline CMake and we'd also require clients of any package to depend on and use
-#   cetbuildtools2 (unless we exported the module setting the features into the package).
-#   `Generally` the names map to Clang ``__has_feature`` names and the similar _`SD-6` names.
-#
-#   We can also, given an epoch, get the list of features supported by the current
-#   compiler, so can also use this list later on if needed. Feature based configuration
-#   is probably most useful when a new standard is being gradually rolled out.
-#
-#   Side note: In UPS/cetbuildtools, standard is selected based on `UPS Qualifiers`_,
-#   and specifially the primary qualifier. This is mostly a specification of compiler
-#   vendor, version and C++ Standard. If we provide a UPS compatibility layer, then
-#   need to use this info, but it can be as a basic check/translation that things
-#   match up (see ``report_product_info`` program etc, though these still rely on
-#   setup_for_development writing files to buildir).
-#
-# .. _`UPS Qualifiers`: https://cdcvs.fnal.gov/redmine/projects/cet-is-public/wiki/AboutQualifiers
-# .. _`SD-6`: https://isocpp.org/std/standing-documents/sd-6-sg10-feature-test-recommendations
-#
-# TODO: Look at functionizing the below - at present, have to do
-#
-#  set(CET_COMPILER_CXX_STANDARD_MINIMUM 14)
-#  include(CetCompilerSettings)
-#
-# Review whether it's better to do
-#
-#  include(CetCompilerSettings)
-#  cet_compiler_cxx_standard_minimum(14)
-#
-# NB: trick here is that variable has sensible default (NULL),
-# but how to do a default function call? Could just set CXX_STANDARD
-# to sensible default in CetCompilerSettings, then if the function is
-# overidden, provides configuration?
+# To configure the specific C++ standard against which the project will be built,
+# the following variables and options are available:
+#
+# .. cmake:variable:: CET_COMPILER_CXX_STANDARD_MINIMUM
+#
+#   Internal variable that should be set by the project before inclusion
+#   of this module to specify the minimum C++ Standard (11, 14, 17, 2a) required
+#   by the project's source code. For example
+#
+#   .. code-block:: cmake
+#
+#     set(CET_COMPILER_CXX_STANDARD_MINIMUM 14)
+#     include(CetCompilerSettings)
+#
+#   .. todo::
+#
+#     Review this pattern of use, and whether the minimum can be set after inclusion,
+#     e.g. via a function to configure the ``enum_option`` used to select the standard.
+#
+#     In UPS/cetbuildtools, standard is selected based on `UPS Qualifiers`_,
+#     and specifially the primary qualifier. This is mostly a specification of compiler
+#     vendor, version and C++ Standard. If we provide a UPS compatibility layer, then
+#     need to use this info, but it can be as a basic check/translation that things
+#     match up (see ``report_product_info`` program etc, though these still rely on
+#     setup_for_development writing files to buildir).
+#
+#     .. _`UPS Qualifiers`: https://cdcvs.fnal.gov/redmine/projects/cet-is-public/wiki/AboutQualifiers
+#     .. _`SD-6`: https://isocpp.org/std/standing-documents/sd-6-sg10-feature-test-recommendations

 # Projects may need to define the minimum standard, so VALUES needs to
-# take that into account, and set DEFAULT to the first entry.
-# Because upcoming versions may be alphanumeric, this list should be ordered
+# filter out earlier epochs. Because upcoming versions may be alphanumeric, this list should be
+# manually ordered until the official numeric epoch is known
 set(CET_SUPPORTED_CXX_STANDARDS 11 14 17 2a)
 set(CET_PROJECT_CXX_STANDARDS)

@@ -183,7 +137,7 @@
   list(FIND CET_SUPPORTED_CXX_STANDARDS "${CET_COMPILER_CXX_STANDARD_MINIMUM}" _cxx_min_index)
   if(_cxx_min_index LESS 0)
     message(FATAL_ERROR
-"project has requested a minimum C++ Standard of `${CET_COMPILER_CXX_STANDARD_MINIMUM}`,
+      "Project `${PROJECT_NAME}` has requested a minimum C++ Standard of `${CET_COMPILER_CXX_STANDARD_MINIMUM}`,
 but this is not in the list of known standards:\n"
 "${CET_SUPPORTED_CXX_STANDARDS}"
     )
@@ -200,6 +154,22 @@
   set(CET_PROJECT_CXX_STANDARDS ${CET_SUPPORTED_CXX_STANDARDS})
 endif()

+#.rst:
+# .. cmake:variable:: CET_COMPILER_CXX_STANDARD
+#
+#   Option to select the actual C++ Standard to compile the project against.
+#   The default is ``11``, or the value of ``CET_COMPILER_CXX_STANDARD_MINIMUM``
+#   if the project has set that. The set of possible valid values are ``11``, ``14``
+#   ``17`` and ``2a``.
+#
+#   If the configured Compiler/CMake version does not know how to set up this
+#   version of the standard, a ``FATAL_ERROR`` will be emitted.
+#
+#   .. todo::
+#
+#     Document how to add support for a new compiler/version not known to
+#     CMake via the compile features/options functionality.
+#
 enum_option(CET_COMPILER_CXX_STANDARD
   VALUES ${CET_PROJECT_CXX_STANDARDS}
   TYPE STRING
@@ -214,9 +184,10 @@
   message(FATAL_ERROR
 "C++ Standard `${CET_COMPILER_CXX_STANDARD}` requested, but detected compiler
 ${CMAKE_CXX_COMPILER_ID} v${CMAKE_CXX_COMPILER_VERSION}\n"
-"is not known to support it. If this is an error, you can add support by setting "
-"the variables CMAKE_CXX${CET_COMPILER_CXX_STANDARD}_STANDARD_COMPILE_OPTION to the "
-"flag required to be passed to the compiler to activate this standard. This setting "
+"is not known to support it, at least by this CMake version (v${CMAKE_VERSION})."
+"If this is an error, you can add support by setting the variables "
+"CMAKE_CXX${CET_COMPILER_CXX_STANDARD}_STANDARD_COMPILE_OPTION to the flag(s) "
+"required to be passed to the compiler to activate this standard. This setting "
 "must be done before inclusion of CetCompilerSettings"
   )
 endif()
@@ -238,7 +209,8 @@
 #   The warnings checked for by the compiler are defined in CET by four
 #   levels, with the following flags prepended to ``CMAKE_C_FLAGS`` and ``CMAKE_CXX_FLAGS``.
 #   At present, diagnostic selection is only enabled for C and C++ languages
-#   and when using the GNU, Clang or Intel compilers.
+#   and when using the GNU, Clang or Intel compilers. The following values
+#   may be selected:
 #
 #   * ``CAVALIER``
 #


[Config] Updated the CMake support file for the renaming of AirSched into AirTSP.

--- config/project_config_embeddable.cmake
+++ config/project_config_embeddable.cmake
@@ -2,7 +2,7 @@
 ## CMake Macros for an embeddable project
 ##
 ## Author: Denis Arnaud
-## Date: July 2011
+## Date: June 2013
 #######################################################################

@@ -382,9 +382,9 @@
       get_travelccm (${_arg_version})
     endif (${_arg_lower} STREQUAL "travelccm")

-    if (${_arg_lower} STREQUAL "airsched")
-      get_airsched (${_arg_version})
-    endif (${_arg_lower} STREQUAL "airsched")
+    if (${_arg_lower} STREQUAL "airtsp")
+      get_airtsp (${_arg_version})
+    endif (${_arg_lower} STREQUAL "airtsp")

     if (${_arg_lower} STREQUAL "airrac")
       get_airrac (${_arg_version})
@@ -1032,37 +1032,37 @@

 endmacro (get_travelccm)

-# ~~~~~~~~~~ AirSched ~~~~~~~~~
-macro (get_airsched)
+# ~~~~~~~~~~ AirTSP ~~~~~~~~~
+macro (get_airtsp)
   unset (_required_version)
   if (${ARGC} GREATER 0)
     set (_required_version ${ARGV0})
-    message (STATUS "Requires AirSched-${_required_version}")
+    message (STATUS "Requires AirTSP-${_required_version}")
   else (${ARGC} GREATER 0)
-    message (STATUS "Requires AirSched without specifying any version")
+    message (STATUS "Requires AirTSP without specifying any version")
   endif (${ARGC} GREATER 0)

-  find_package (AirSched ${_required_version} REQUIRED
-	HINTS ${WITH_AIRSCHED_PREFIX})
-  if (AirSched_FOUND)
+  find_package (AirTSP ${_required_version} REQUIRED
+	HINTS ${WITH_AIRTSP_PREFIX})
+  if (AirTSP_FOUND)
     #
-    message (STATUS "Found AirSched version: ${AIRSCHED_VERSION}")
+    message (STATUS "Found AirTSP version: ${AIRTSP_VERSION}")

     # Update the list of include directories for the project
-    include_directories (${AIRSCHED_INCLUDE_DIRS})
+    include_directories (${AIRTSP_INCLUDE_DIRS})

     # Update the list of dependencies for the project
-    set (PROJ_DEP_LIBS_FOR_LIB ${PROJ_DEP_LIBS_FOR_LIB} ${AIRSCHED_LIBRARIES})
-
-  else (AirSched_FOUND)
-    set (ERROR_MSG "The AirSched library cannot be found. If it is installed")
+    set (PROJ_DEP_LIBS_FOR_LIB ${PROJ_DEP_LIBS_FOR_LIB} ${AIRTSP_LIBRARIES})
+
+  else (AirTSP_FOUND)
+    set (ERROR_MSG "The AirTSP library cannot be found. If it is installed")
     set (ERROR_MSG "${ERROR_MSG} in a in a non standard directory, just invoke")
-    set (ERROR_MSG "${ERROR_MSG} 'cmake' specifying the -DWITH_AIRSCHED_PREFIX=")
-    set (ERROR_MSG "${ERROR_MSG}<AirSched install path> variable.")
+    set (ERROR_MSG "${ERROR_MSG} 'cmake' specifying the -DWITH_AIRTSP_PREFIX=")
+    set (ERROR_MSG "${ERROR_MSG}<AirTSP install path> variable.")
     message (FATAL_ERROR "${ERROR_MSG}")
-  endif (AirSched_FOUND)
-
-endmacro (get_airsched)
+  endif (AirTSP_FOUND)
+
+endmacro (get_airtsp)

 # ~~~~~~~~~~ AirRAC ~~~~~~~~~
 macro (get_airrac)
@@ -2608,19 +2608,19 @@
   endif (TravelCCM_FOUND)
 endmacro (display_travelccm)

-# AirSched
-macro (display_airsched)
-  if (AirSched_FOUND)
+# AirTSP
+macro (display_airtsp)
+  if (AirTSP_FOUND)
     message (STATUS)
-    message (STATUS "* AirSched:")
-    message (STATUS "  - AIRSCHED_VERSION .............. : ${AIRSCHED_VERSION}")
-    message (STATUS "  - AIRSCHED_BINARY_DIRS .......... : ${AIRSCHED_BINARY_DIRS}")
-    message (STATUS "  - AIRSCHED_EXECUTABLES .......... : ${AIRSCHED_EXECUTABLES}")
-    message (STATUS "  - AIRSCHED_LIBRARY_DIRS ......... : ${AIRSCHED_LIBRARY_DIRS}")
-    message (STATUS "  - AIRSCHED_LIBRARIES ............ : ${AIRSCHED_LIBRARIES}")
-    message (STATUS "  - AIRSCHED_INCLUDE_DIRS ......... : ${AIRSCHED_INCLUDE_DIRS}")
-  endif (AirSched_FOUND)
-endmacro (display_airsched)
+    message (STATUS "* AirTSP:")
+    message (STATUS "  - AIRTSP_VERSION .............. : ${AIRTSP_VERSION}")
+    message (STATUS "  - AIRTSP_BINARY_DIRS .......... : ${AIRTSP_BINARY_DIRS}")
+    message (STATUS "  - AIRTSP_EXECUTABLES .......... : ${AIRTSP_EXECUTABLES}")
+    message (STATUS "  - AIRTSP_LIBRARY_DIRS ......... : ${AIRTSP_LIBRARY_DIRS}")
+    message (STATUS "  - AIRTSP_LIBRARIES ............ : ${AIRTSP_LIBRARIES}")
+    message (STATUS "  - AIRTSP_INCLUDE_DIRS ......... : ${AIRTSP_INCLUDE_DIRS}")
+  endif (AirTSP_FOUND)
+endmacro (display_airtsp)

 # AirRAC
 macro (display_airrac)
@@ -2858,7 +2858,7 @@
   display_sevmgr ()
   display_trademgen ()
   display_travelccm ()
-  display_airsched ()
+  display_airtsp ()
   display_airrac ()
   display_rmol ()
   display_airinv ()


uppercase P in path name

uppercase P in path name

--- contrib/cmake/build_from_scratch.cmake
+++ contrib/cmake/build_from_scratch.cmake
@@ -57,7 +57,7 @@

 execute_checked_command(
     COMMAND ${_cmake}
-        -S ${_script_cwd}/build3rdparty
+        -S ${_script_cwd}/build3rdParty
         -B ${_3rdparty_sdk_dir}
         -DCMAKE_BUILD_TYPE=Release
 )


Another blind fix to build with leap motion support on windows

--- indra/cmake/Copy3rdPartyLibs.cmake
+++ indra/cmake/Copy3rdPartyLibs.cmake
@@ -75,8 +75,13 @@
     endif (FMODEX)

     if (LEAPMOTION)
-      set(debug_files ${debug_files} Leapd.dll)
-      set(release_files ${release_files} Leap.dll)
+      if( NOT ND_BUILD64BIT_ARCH )
+        set(debug_files ${debug_files} x86/Leapd.dll)
+        set(release_files ${release_files} x86/Leap.dll)
+      else( NOT ND_BUILD64BIT_ARCH )
+        set(debug_files ${debug_files} x64/Leapd.dll)
+        set(release_files ${release_files} x64/Leap.dll)
+      endif( NOT ND_BUILD64BIT_ARCH )
     endif (LEAPMOTION)

 # <FS:ND> Copy pdb files for symbol generation too


BUG: added condition to adding dependecy to doxygen

--- Code/BasicFilters/SourceCodeGenerator.cmake
+++ Code/BasicFilters/SourceCodeGenerator.cmake
@@ -55,7 +55,9 @@

 # Make target for generated code
 add_custom_target(FilterSourceCode ALL DEPENDS ${SimpleITKBasicFiltersSource})
-add_dependencies(Documentation FilterSourceCode)
+if (BUILD_DOXYGEN)
+  add_dependencies(Documentation FilterSourceCode)
+endif (BUILD_DOXYGEN)

 # clear the include files
 file ( WRITE ${CMAKE_CURRENT_BINARY_DIR}/SimpleITKBasicFiltersGeneratedHeaders.h "" )


Fixed OgreInstallDependencies.cmake to copy the GLES DLL only if the GLES render system is selected.

--- Dependencies/OgreInstallDependencies.cmake
+++ Dependencies/OgreInstallDependencies.cmake
@@ -65,21 +65,45 @@
     ${OGRE_DEP_BIN_DIR}/release/libgles_cm.dll
 	  DESTINATION bin/minsizerel CONFIGURATIONS MinSizeRel
   )
+
+  # install GLES dlls
+  if (OGRE_BUILD_RENDERSYSTEM_GLES)
+	  install(FILES
+		${OGRE_DEP_BIN_DIR}/debug/libgles_cm.dll
+		  DESTINATION bin/debug CONFIGURATIONS Debug
+	  )
+	  install(FILES
+		${OGRE_DEP_BIN_DIR}/release/libgles_cm.dll
+		  DESTINATION bin/release CONFIGURATIONS Release None ""
+	  )
+	  install(FILES
+		${OGRE_DEP_BIN_DIR}/release/libgles_cm.dll
+		  DESTINATION bin/relwithdebinfo CONFIGURATIONS RelWithDebInfo
+	  )
+	  install(FILES
+		${OGRE_DEP_BIN_DIR}/release/libgles_cm.dll
+		  DESTINATION bin/minsizerel CONFIGURATIONS MinSizeRel
+	  )
+  endif ()
 endif ()

 # copy the required DLLs to the build directory (configure_file is the only copy-like op I found in CMake)
 configure_file(${OGRE_DEP_BIN_DIR}/debug/cg.dll ${OGRE_BINARY_DIR}/bin/debug/cg.dll COPYONLY)
 configure_file(${OGRE_DEP_BIN_DIR}/debug/OIS_d.dll ${OGRE_BINARY_DIR}/bin/debug/OIS_d.dll COPYONLY)
-configure_file(${OGRE_DEP_BIN_DIR}/debug/libgles_cm.dll ${OGRE_BINARY_DIR}/bin/debug/libgles_cm.dll COPYONLY)

 configure_file(${OGRE_DEP_BIN_DIR}/release/cg.dll ${OGRE_BINARY_DIR}/bin/release/cg.dll COPYONLY)
 configure_file(${OGRE_DEP_BIN_DIR}/release/OIS.dll ${OGRE_BINARY_DIR}/bin/release/OIS.dll COPYONLY)
-configure_file(${OGRE_DEP_BIN_DIR}/release/libgles_cm.dll ${OGRE_BINARY_DIR}/bin/release/libgles_cm.dll COPYONLY)

 configure_file(${OGRE_DEP_BIN_DIR}/release/cg.dll ${OGRE_BINARY_DIR}/bin/relwithdebinfo/cg.dll COPYONLY)
 configure_file(${OGRE_DEP_BIN_DIR}/release/OIS.dll ${OGRE_BINARY_DIR}/bin/relwithdebinfo/OIS.dll COPYONLY)
-configure_file(${OGRE_DEP_BIN_DIR}/release/libgles_cm.dll ${OGRE_BINARY_DIR}/bin/relwithdebinfo/libgles_cm.dll COPYONLY)

 configure_file(${OGRE_DEP_BIN_DIR}/release/cg.dll ${OGRE_BINARY_DIR}/bin/minsizerel/cg.dll COPYONLY)
 configure_file(${OGRE_DEP_BIN_DIR}/release/OIS.dll ${OGRE_BINARY_DIR}/bin/minsizerel/OIS.dll COPYONLY)
-configure_file(${OGRE_DEP_BIN_DIR}/release/libgles_cm.dll ${OGRE_BINARY_DIR}/bin/minsizerel/libgles_cm.dll COPYONLY)
+
+if (OGRE_BUILD_RENDERSYSTEM_GLES)
+	configure_file(${OGRE_DEP_BIN_DIR}/debug/libgles_cm.dll ${OGRE_BINARY_DIR}/bin/debug/libgles_cm.dll COPYONLY)
+	configure_file(${OGRE_DEP_BIN_DIR}/release/libgles_cm.dll ${OGRE_BINARY_DIR}/bin/release/libgles_cm.dll COPYONLY)
+	configure_file(${OGRE_DEP_BIN_DIR}/release/libgles_cm.dll ${OGRE_BINARY_DIR}/bin/relwithdebinfo/libgles_cm.dll COPYONLY)
+	configure_file(${OGRE_DEP_BIN_DIR}/release/libgles_cm.dll ${OGRE_BINARY_DIR}/bin/minsizerel/libgles_cm.dll COPYONLY)
+endif ()
+


Fix: Wrong argument in `conan_cmake_autodetect` (#354)

* Fix: Wrong argument in `conan_cmake_autodetect`

* Trigger CI

Co-authored-by: czoido <2accafae6a9d696f958aa2dba27077cd7a20a336@gmail.com>

--- conan.cmake
+++ conan.cmake
@@ -428,7 +428,7 @@
     set(${result} ${detected_setings} PARENT_SCOPE)
 endfunction()

-function(conan_cmake_autodetect detected_settings ${ARGV})
+function(conan_cmake_autodetect detected_settings)
     _conan_detect_build_type(${ARGV})
     _conan_check_system_name()
     _conan_check_language()


Coverage generation is buggy on xcode 7.3+.

--- run_ctest.cmake
+++ run_ctest.cmake
@@ -169,7 +169,10 @@
     endif()
 elseif(CC_NAME STREQUAL "xcode")
     find_program(CTEST_COVERAGE_COMMAND NAMES llvm-cov PATHS /Library/Developer/CommandLineTools/usr/bin/)
-    if(CC_VERSION VERSION_GREATER 6.3 OR CC_VERSION VERSION_EQUAL 6.3)
+    if(CC_VERSION VERSION_GREATER 7.3 OR CC_VERSION VERSION_EQUAL 7.3)
+        set(CTEST_COVERAGE_COMMAND "")
+        set(CTEST_COVERAGE_EXTRA_FLAGS "")
+    elseif(CC_VERSION VERSION_GREATER 6.3 OR CC_VERSION VERSION_EQUAL 6.3)
         set(CTEST_COVERAGE_EXTRA_FLAGS "${CTEST_COVERAGE_EXTRA_FLAGS} gcov")
     endif()
 elseif(CC_NAME STREQUAL "icc")


cmake: Re-order cmake script inclusions

cmake: Re-order cmake script inclusions

The script `cmake/env.cmake` enables languages and in the case of Arm
compiler, `CMAKE_SYSTEM_PROCESSOR` is expected to be set before a
language is enabled. `CMAKE_SYSTEM_PROCESSOR` is set in
`cmake/core.cmake`. Therefore, `cmake/core.cmake` is included before
`cmake/env.cmake`.

Similarly, `cmake/profile.cmake` sets compiler options, hence it is
included before enabling languages in `cmake/env.cmake`.

Signed-off-by: Devaraj Ranganna <53e2fcb007e5c6e2caf46b91114119a655266f64@arm.com>

--- cmake/app.cmake
+++ cmake/app.cmake
@@ -2,10 +2,10 @@

 include(.mbedbuild/mbed_config.cmake)
 include(${MBED_ROOT}/cmake/toolchain.cmake)
+include(${MBED_ROOT}/cmake/core.cmake)
+include(${MBED_ROOT}/cmake/profile.cmake)
 include(${MBED_ROOT}/cmake/env.cmake)
 include(${MBED_ROOT}/cmake/util.cmake)
-include(${MBED_ROOT}/cmake/core.cmake)
-include(${MBED_ROOT}/cmake/profile.cmake)

 # if the environment does not specify build type, set to Debug
 if(NOT CMAKE_BUILD_TYPE)


Display the lua variables when found #25

--- cmake/lua.cmake
+++ cmake/lua.cmake
@@ -12,5 +12,7 @@
   endif()
 endif()
 message(STATUS "Found Lua")
+message(STATUS "  Lua include ${LUA_INCLUDE_DIR}")
+message(STATUS "  Lua lib ${LUA_LIBRARIES}")

 include_directories(${LUA_INCLUDE_DIR})


Added zlib dependency to protobuf

Added zlib dependency to protobuf

--- ThirdPartyLibraries.cmake
+++ ThirdPartyLibraries.cmake
@@ -439,6 +439,7 @@
 add_library_dependencies(curl-asio third_party.boost_system third_party.libcurl)
 add_library_dependencies(readline ncurses)
 add_library_dependencies(shark third_party.boost_serialization)
+add_library_dependencies(protobuf third_party.zlib)

 # Aliases.
 add_library_dependencies(boost_asio third_party.boost_system)
@@ -2257,6 +2258,7 @@
           ${CONFIGURE_LIB_TYPE}
   BUILD_IN_SOURCE 1)
   add_dependencies(${PROTOBUF_TARGET} ${PROTOC_TARGET})
+  add_dependencies(${PROTOBUF_TARGET} ${ZLIB_TARGET})
 if (PYTHON_SUPPORTED)
   add_external_project_step(${PROTOBUF_TARGET} build_python_runtime
     COMMAND /usr/bin/env python setup.py build


修正下载问题

修正下载问题

--- 3rd_party/3rd_party.libhiredis.cmake
+++ 3rd_party/3rd_party.libhiredis.cmake
@@ -17,7 +17,7 @@
     message(STATUS "hiredis not found try to build it.")
     if (NOT EXISTS "${3RD_PARTY_REDIS_BASE_DIR}/hiredis-${HIREDIS_VERSION}.tar.gz")
         message(STATUS "download from https://github.com/redis/hiredis/archive/v${HIREDIS_VERSION}.tar.gz to ${3RD_PARTY_REDIS_BASE_DIR}/hiredis-${HIREDIS_VERSION}.tar.gz")
-        file(DOWNLOAD "https://github.com/redis/hiredis/archive/v${HIREDIS_VERSION}.tar.gz" "${3RD_PARTY_REDIS_BASE_DIR}/hiredis-${HIREDIS_VERSION}.tar.gz" SHOW_PROGRESS)
+        FindConfigurePackageDownloadFile("https://github.com/redis/hiredis/archive/v${HIREDIS_VERSION}.tar.gz" "${3RD_PARTY_REDIS_BASE_DIR}/hiredis-${HIREDIS_VERSION}.tar.gz" SHOW_PROGRESS)
     else()
         message(STATUS "use cache package ${3RD_PARTY_REDIS_BASE_DIR}/hiredis-${HIREDIS_VERSION}.tar.gz")
     endif()


BUG: Remove extra debug statement in CMake/ctkDashboardDriverScript.cmake

--- CMake/ctkDashboardDriverScript.cmake
+++ CMake/ctkDashboardDriverScript.cmake
@@ -56,7 +56,7 @@
   message(FATAL_ERROR "Unknown script mode: '${SCRIPT_MODE}'. Script mode should be either 'experimental', 'continuous' or 'nightly'")
 endif()

-message("script_mode:${SCRIPT_MODE}")
+#message("script_mode:${SCRIPT_MODE}")
 #message("model:${model}")
 #message("empty_binary_directory:${empty_binary_directory}")
 #message("force_build:${force_build}")


Allow to use 64bit version of Cg on Windows

--- cmake/FindCg.cmake
+++ cmake/FindCg.cmake
@@ -38,9 +38,14 @@
     )
 ELSE (APPLE)
   IF (WIN32)
+		IF (CMAKE_SIZEOF_VOID_P EQUALS 8)
+			SET(CG_BIN_SEARCH_PATH "$ENV{PROGRAMFILES}/NVIDIA\ Corporation/Cg/bin.x64")
+		ELSE
+			SET(CG_BIN_SEARCH_PATH "$ENV{PROGRAMFILES}/NVIDIA\ Corporation/Cg/bin")
+		ENDIF
     FIND_PROGRAM( CG_COMPILER cgc
       $ENV{CG_BIN_PATH}
-      $ENV{PROGRAMFILES}/NVIDIA\ Corporation/Cg/bin
+			${CG_BIN_SEARCH_PATH}
       $ENV{PROGRAMFILES}/Cg
       ${PROJECT_SOURCE_DIR}/../Cg
       DOC "The Cg Compiler"
@@ -61,11 +66,16 @@
       ${CG_COMPILER_DIR}
       DOC "The directory where Cg/cg.h resides"
       )
+		IF (CMAKE_SIZEOF_VOID_P EQUALS 8)
+			SET(CG_LIB_SEARCH_PATH "$ENV{PROGRAMFILES}/NVIDIA\ Corporation/Cg/lib.x64")
+		ELSE
+			SET(CG_LIB_SEARCH_PATH "$ENV{PROGRAMFILES}/NVIDIA\ Corporation/Cg/lib")
+		ENDIF
     FIND_LIBRARY( CG_LIBRARY
       NAMES Cg
       PATHS
       $ENV{CG_LIB_PATH}
-      $ENV{PROGRAMFILES}/NVIDIA\ Corporation/Cg/lib
+			${CG_LIB_SEARCH_PATH}
       $ENV{PROGRAMFILES}/Cg
       ${PROJECT_SOURCE_DIR}/../Cg
       ${CG_COMPILER_SUPER_DIR}/lib
@@ -75,7 +85,7 @@
     FIND_LIBRARY( CG_GL_LIBRARY
       NAMES CgGL
       PATHS
-      $ENV{PROGRAMFILES}/NVIDIA\ Corporation/Cg/lib
+			${CG_LIB_SEARCH_PATH}
       $ENV{PROGRAMFILES}/Cg
       ${PROJECT_SOURCE_DIR}/../Cg
       ${CG_COMPILER_SUPER_DIR}/lib


Clang-Tidy: make things work with LLVM 9.0.0.

Note that this required disabling some checks. Indeed, the plan here is to get our codebase to build as-is. However, whenever we review our codebase, we should reenable those checks and rework our codebase accordingly.

--- cmake/common.cmake
+++ cmake/common.cmake
@@ -132,6 +132,7 @@
     set(_CLANG_TIDY_CHECKS
       -*
       bugprone-*
+      -bugprone-branch-clone
       ${_NO_BUGPRONE_EXCEPTION_ESCAPE}
       cert-*
       -cert-err58-cpp
@@ -144,6 +145,8 @@
       -cppcoreguidelines-special-member-functions
       fuchsia-*
       -fuchsia-default-arguments
+      -fuchsia-default-arguments-calls
+      -fuchsia-default-arguments-declarations
       -fuchsia-multiple-inheritance
       -fuchsia-statically-constructed-objects
       google-*
@@ -159,9 +162,11 @@
       modernize-*
       -modernize-pass-by-value
       -modernize-raw-string-literal
+      -modernize-use-trailing-return-type
       performance-*
       -performance-inefficient-string-concatenation
       readability-*
+      -readability-convert-member-functions-to-static
       -readability-magic-numbers
     )
     string(REPLACE ";" ","


Fix typo in FindOpenMVG.cmake

Fix typo in FindOpenMVG.cmake

--- src/cmakeFindModules/FindOpenMVG.cmake
+++ src/cmakeFindModules/FindOpenMVG.cmake
@@ -24,7 +24,7 @@
 )

 IF(OPENMVG_INCLUDE_DIR)
-  MESSAGE(STATUS "OpenMVG headers found in ${OPENMVG_INCLUDE_DIRS}")
+  MESSAGE(STATUS "OpenMVG headers found in ${OPENMVG_INCLUDE_DIR}")
 ELSE()
   MESSAGE(STATUS "NOT FOUND")
 ENDIF (OPENMVG_INCLUDE_DIR)


[cmake] yet another macro switch default warning fix

--- config.h.cmake
+++ config.h.cmake
@@ -122,6 +122,10 @@
 # define HAVE_ALBERTA 0
 #endif

+#ifndef HAVE_GRAPE
+# define HAVE_GRAPE 0
+#endif
+
 /*** End: Silence implicitly False evaluation of undefined macro warnings ****/

 /* end dune-stuff */


Search for dynamically linked superlu

Search for dynamically linked superlu

--- toonz/cmake/FindSuperLU.cmake
+++ toonz/cmake/FindSuperLU.cmake
@@ -15,6 +15,7 @@
     NAMES
         libsuperlu.a
         libsuperlu_4.1.a
+        libsuperlu.so
     HINTS
         ${THIRDPARTY_LIBS_HINTS}
     PATH_SUFFIXES


Media : Fixed cmake reference to ffmpeg devpack version for Unices.

--- src/cmake/devpack-standard-imports.cmake
+++ src/cmake/devpack-standard-imports.cmake
@@ -10,7 +10,7 @@
 		if (WIN32)
 			DEVPACK_IMPORT("ffmpeg" "git09cd228" "1" "windows" "i386" "all" "all" "all")
 		else()
-			DEVPACK_IMPORT("ffmpeg" "1.1.1" "1" "all" "all" "${DEVPACK_COMPILER}" "all")
+			DEVPACK_IMPORT("ffmpeg" "22725" "3" "all" "all" "${DEVPACK_COMPILER}" "all")
 		endif()
 	endif()
 	list(APPEND YUNI_STATIC_AUDIO "${YUNI_EXT_FFMPEG_LIB}")


While I need the 2011/05.24-r31 coredumper external to compile on rhel6, it turns out it doesn't compile on rhel 3 x86_64. And the 0.2 version rhel 3 was compiling doesn't compile on rhel 6. So I need both. #1998

--- build/cmake/CondorConfigure.cmake
+++ build/cmake/CondorConfigure.cmake
@@ -476,7 +476,14 @@
 add_subdirectory(${CONDOR_EXTERNAL_DIR}/bundles/drmaa/1.6)

 if (NOT WINDOWS)
-	add_subdirectory(${CONDOR_EXTERNAL_DIR}/bundles/coredumper/2011.05.24-r31)
+
+	if (${SYSTEM_NAME} MATCHES "rhel3" AND ${SYS_ARCH} MATCHES "X86_64")
+		# The new version of 2011.05.24-r31 doesn't compile on rhel3/x86_64
+		add_subdirectory(${CONDOR_EXTERNAL_DIR}/bundles/coredumper/0.2)
+	else ()
+		add_subdirectory(${CONDOR_EXTERNAL_DIR}/bundles/coredumper/2011.05.24-r31)
+	endif()
+
 	add_subdirectory(${CONDOR_EXTERNAL_DIR}/bundles/unicoregahp/1.2.0)
 	add_subdirectory(${CONDOR_EXTERNAL_DIR}/bundles/expat/2.0.1)
 	add_subdirectory(${CONDOR_EXTERNAL_DIR}/bundles/libxml2/2.7.3)


Find Python 2 correctly on the Macs.

Find Python 2 correctly on the Macs.

--- build/cmake/CondorConfigure.cmake
+++ build/cmake/CondorConfigure.cmake
@@ -99,15 +99,13 @@
         # We need to do this the hard way for both python2 and python3 support in the same build
         # This will be easier in cmake 3

-        if(DARWIN)
-            # This is a glorious hack, but it's the right thing to do
-            # for our machines.  [FIXME: TimT, should we pass this in as
-            # a command-line argument to CMake in BaTLab?]
-        	set(PYTHON_EXECUTABLE /usr/bin/python)
+        if(${OS_NAME} STREQUAL "DARWIN")
+            find_program(PYTHON_EXECUTABLE python)
         else()
             find_program(PYTHON_EXECUTABLE python2)
         endif()

+message(STATUS "PYTHON_EXECUTABLE = ${PYTHON_EXECUTABLE}")
         if (PYTHON_EXECUTABLE)
             set(PYTHONINTERP_FOUND TRUE)
             set(PYTHON_QUERY_PART_01 "from distutils import sysconfig;")


It turns out Clang does support -fstack-protector.

It doesn't support the misspelled -fnostack-protector (now excised).

--- build/cmake/CondorConfigure.cmake
+++ build/cmake/CondorConfigure.cmake
@@ -772,15 +772,12 @@

 	# gcc on our AIX machines recognizes -fstack-protector, but lacks
 	# the requisite library.
-	# Clang on Mac OS X doesn't support -fstack-protector, but the
-	# check below claims it does. This is probably because the compiler
-	# just prints a warning, rather than failing.
-	if (NOT AIX AND NOT "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
+	if (NOT AIX)
 		check_cxx_compiler_flag(-fstack-protector cxx_fstack_protector)
 		if (cxx_fstack_protector)
 			set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fstack-protector")
 		endif(cxx_fstack_protector)
-	endif()
+	endif(NOT AIX)

 	# Clang on Mac OS X doesn't support -rdynamic, but the
 	# check below claims it does. This is probably because the compiler


Some minor cleaning up.

Some minor cleaning up.

--- cmake/common.cmake
+++ cmake/common.cmake
@@ -32,8 +32,6 @@
             SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -O0")
         ENDIF()
     ELSE()
-        SET(CMAKE_BUILD_TYPE "Release")
-
         MESSAGE("Building a release version...")

         SET(DEBUG_MODE OFF)


Use generic kernels  for ishama,shasum,shdot,shrot

--- cmake/kernel.cmake
+++ cmake/kernel.cmake
@@ -117,16 +117,16 @@
   set(SHAMAXKERNEL ../arm/amax.c)
   set(SHMAXKERNEL ../arm/max.c)
   set(SHMINKERNEL ../arm/min.c)
-  set(ISHAMAXKERNEL iamax.S)
+  set(ISHAMAXKERNEL ../arm/iamax.c)
   set(ISHAMINKERNEL ../arm/iamin.c)
   set(ISHMAXKERNEL ../arm/imax.c)
   set(ISHMINKERNEL ../arm/imin.c)
-  set(SHASUMKERNEL asum.S)
+  set(SHASUMKERNEL ../arm/asum.c)
   set(SHAXPYKERNEL ../arm/axpy.c)
   set(SHAXPBYKERNEL ../arm/axpby.c)
   set(SHCOPYKERNEL ../arm/copy.c)
-  set(SHDOTKERNEL dot.S)
-  set(SHROTKERNEL rot.S)
+  set(SHDOTKERNEL ../arm/dot.c)
+  set(SHROTKERNEL ../arm/rot.c)
   set(SHSCALKERNEL scal.S)
   set(SHNRM2KERNEL nrm2.S)
   set(SHSUMKERNEL sum.S)


- Rearrange some OSX/iOS libraries

- Rearrange some OSX/iOS libraries

--- cmake/Find/FindStandardLibs.cmake
+++ cmake/Find/FindStandardLibs.cmake
@@ -51,14 +51,22 @@
         "-framework CoreAudio"
         "-framework CoreFoundation"
         "-framework CoreGraphics"
-        "-framework CoreMotion"
         "-framework Foundation"
-        "-framework GameController"
         "-framework OpenAL"
-        "-framework OpenGLES"
         "-framework QuartzCore"
-        "-framework UIKit"
         )
+    if(IOS)
+        list ( APPEND CORE_EXTRA_LIBRARIES
+            "-framework CoreMotion"
+            "-framework GameController"
+            "-framework OpenGLES"
+            "-framework UIKit"
+            )
+    else()
+        list ( APPEND CORE_EXTRA_LIBRARIES
+            "-framework OpenGL"
+            )
+    endif()
 endif()

 if(ANDROID)


cmake: Default LIBDIR to lib${LIB_SUFFIX}.

--- cmake/GNUInstallDirsWrapper.cmake
+++ cmake/GNUInstallDirsWrapper.cmake
@@ -6,7 +6,7 @@
 	endif()

 	if(NOT DEFINED CMAKE_INSTALL_LIBDIR)
-		set(CMAKE_INSTALL_LIBDIR "lib" CACHE PATH "object code libraries (lib)")
+		set(CMAKE_INSTALL_LIBDIR "lib${LIB_SUFFIX}" CACHE PATH "object code libraries (lib)")
 	endif()

 	mark_as_advanced(CMAKE_INSTALL_BINDIR CMAKE_INSTALL_LIBDIR)


spelling: commands

spelling: commands

Signed-off-by: Josh Soref <dc510c92cc1794ea84000fde88becdce67bf7624@users.noreply.github.com>

--- cmake/modules/CatchAddTests.cmake
+++ cmake/modules/CatchAddTests.cmake
@@ -45,7 +45,7 @@
 # Parse output
 foreach(line ${output})
   set(test ${line})
-  # use escape commas to handle properly test cases with commans inside the name
+  # use escape commas to handle properly test cases with commands inside the name
   string(REPLACE "," "\\," test_name ${test})
   # ...and add to script
   add_command(add_test "${prefix}${test}${suffix}" ${TEST_EXECUTOR} "${TEST_EXECUTABLE}" "${test_name}" ${extra_args})


OpenVino: fix allocation failure on Window for RelWithDebInfo build (#5713)

* ng_supported_ops

* Remove ng_supported_ops

* Revert "Remove ng_supported_ops"

This reverts commit 3c27385b2d88c6e8cf7ac4e8c290a367ad5d0bd8.

* Revert "ng_supported_ops"

This reverts commit 650721ae2913b79739521d58838298e031abdac1.

* cmake changes to ensure that the debug build on windows link to debug builds of openvino
and do not result in bad allocation error

Co-authored-by: sfatimar <f5986f0de9d2b1f55c434cc95efc2e1df8f90cab@intel/com>

--- cmake/onnxruntime_providers.cmake
+++ cmake/onnxruntime_providers.cmake
@@ -578,11 +578,16 @@

     # Library paths
     list(APPEND OPENVINO_LIB_DIR_LIST $ENV{INTEL_OPENVINO_DIR}/deployment_tools/inference_engine/external/tbb/lib)
+    list(APPEND OPENVINO_LIB_DIR_LIST $ENV{INTEL_OPENVINO_DIR}/deployment_tools/inference_engine/external/tbb/bin)
     list(APPEND OPENVINO_LIB_DIR_LIST $ENV{INTEL_OPENVINO_DIR}/deployment_tools/inference_engine/external/mkltiny_lnx/lib)

     # Lib names
     if (WIN32)
-      list(APPEND OPENVINO_LIB_LIST inference_engine.lib inference_engine_legacy.lib tbb.lib ${PYTHON_LIBRARIES})
+      if (CMAKE_BUILD_TYPE STREQUAL "Debug")
+        list(APPEND OPENVINO_LIB_LIST inference_engined.lib inference_engine_legacyd.lib tbb.lib ${PYTHON_LIBRARIES})
+      else()
+        list(APPEND OPENVINO_LIB_LIST inference_engine.lib inference_engine_legacy.lib tbb.lib ${PYTHON_LIBRARIES})
+      endif()
     else()
       list(APPEND OPENVINO_LIB_LIST -linference_engine -linference_engine_legacy -ltbb ${PYTHON_LIBRARIES})
     endif()
@@ -592,16 +597,29 @@
       list(APPEND OPENVINO_INCLUDE_DIR_LIST $ENV{INTEL_OPENVINO_DIR}/deployment_tools/ngraph/include)
       list(APPEND OPENVINO_INCLUDE_DIR_LIST $ENV{INTEL_OPENVINO_DIR}/deployment_tools/ngraph/include/ngraph/frontend)
       list(APPEND OPENVINO_LIB_DIR_LIST $ENV{INTEL_OPENVINO_DIR}/deployment_tools/ngraph/lib)
-      if (WIN32)
-        list(APPEND OPENVINO_LIB_LIST ngraph.lib)
+      if (OPENVINO_VERSION VERSION_EQUAL "2020.4")
+        if (WIN32)
+          list(APPEND OPENVINO_LIB_LIST ngraph.lib onnx_importer.lib)
+        else()
+          list(APPEND OPENVINO_LIB_LIST -lngraph -lonnx_importer)
+        endif()
+      endif()
+      if (OPENVINO_VERSION VERSION_GREATER "2020.4")
+        if (WIN32)
+          if (CMAKE_BUILD_TYPE STREQUAL "Debug")
+            list(APPEND OPENVINO_LIB_LIST ngraphd.lib onnx_importerd.lib)
+          else()
+            list(APPEND OPENVINO_LIB_LIST ngraph.lib onnx_importer.lib)
+          endif()
+        else()
+          list(APPEND OPENVINO_LIB_LIST -lngraph -lonnx_importer)
+        endif()
+      endif()
       else()
-        list(APPEND OPENVINO_LIB_LIST -lngraph)
-      endif()
-      if (OPENVINO_VERSION VERSION_GREATER_EQUAL "2020.4")
         if (WIN32)
-          list(APPEND OPENVINO_LIB_LIST onnx_importer.lib)
+          list(APPEND OPENVINO_LIB_LIST ngraph.lib)
         else()
-          list(APPEND OPENVINO_LIB_LIST -lonnx_importer)
+          list(APPEND OPENVINO_LIB_LIST -lngraph)
         endif()
       endif()
     else ()
@@ -610,14 +628,16 @@
     endif()

     if(WIN32)
-      list(APPEND OPENVINO_LIB_DIR_LIST $ENV{INTEL_OPENVINO_DIR}/deployment_tools/inference_engine/lib/intel64/Release)
+      if (CMAKE_BUILD_TYPE STREQUAL "Debug")
+        list(APPEND OPENVINO_LIB_DIR_LIST $ENV{INTEL_OPENVINO_DIR}/deployment_tools/inference_engine/lib/intel64/Debug)
+      else()
+        list(APPEND OPENVINO_LIB_DIR_LIST $ENV{INTEL_OPENVINO_DIR}/deployment_tools/inference_engine/lib/intel64/Release)
+      endif()
     elseif(CMAKE_LIBRARY_ARCHITECTURE STREQUAL "aarch64-linux-gnu")
       list(APPEND OPENVINO_LIB_DIR_LIST $ENV{INTEL_OPENVINO_DIR}/deployment_tools/inference_engine/lib/aarch64)
     else()
       list(APPEND OPENVINO_LIB_DIR_LIST $ENV{INTEL_OPENVINO_DIR}/deployment_tools/inference_engine/lib/intel64)
     endif()
-
-  endif()

   source_group(TREE ${ONNXRUNTIME_ROOT}/core FILES ${onnxruntime_providers_openvino_cc_srcs})
   add_library(onnxruntime_providers_openvino ${onnxruntime_providers_openvino_cc_srcs})


Update script_octomap.cmake

Update script_octomap.cmake

--- cmakemodules/script_octomap.cmake
+++ cmakemodules/script_octomap.cmake
@@ -51,7 +51,6 @@
 			${CMD_CMAKE_POSTFIX}
 		  BUILD_COMMAND
 			${CMAKE_COMMAND} --build ${MRPT_BINARY_DIR}/EP_octomap-prefix/src/EP_octomap-build --config $<CONFIG> --target octomap-static
-			COMMAND tree ${MRPT_BINARY_DIR}/3rdparty/octomap/
 			COMMAND ${CMAKE_COMMAND} -E copy ${MRPT_BINARY_DIR}/3rdparty/octomap/lib/${LIB_PREFIX}octomap$<$<CONFIG:Debug>:${CMAKE_DEBUG_POSTFIX}>.${LIB_EXT} ${MRPT_BINARY_DIR}/lib/
 			COMMAND ${CMAKE_COMMAND} -E copy ${MRPT_BINARY_DIR}/3rdparty/octomap/lib/${LIB_PREFIX}octomath$<$<CONFIG:Debug>:${CMAKE_DEBUG_POSTFIX}>.${LIB_EXT} ${MRPT_BINARY_DIR}/lib/
 		  INSTALL_COMMAND   ""


#5006 use find_package(Valgrind) for linux refs[t:5006]

git-svn-id: b5c078ec0b4d3a50497e9dd3081db18a5b4f16e5@44260 c7de825b-a66e-492c-adef-691d508d4ae1

--- cmake_modules/TokuFeatureDetection.cmake
+++ cmake_modules/TokuFeatureDetection.cmake
@@ -7,7 +7,7 @@
   find_package(BDB REQUIRED)
 endif()

-find_package(VALGRIND REQUIRED)
+find_package(Valgrind REQUIRED)

 include(CheckIncludeFiles)


client: don't backup old cmake files when munging

adar@adar-ThinkPad-T540p:/tmp/bundle/usr/local/share/kuduClient/cmake$ ls -l
total 24
-rw-r--r-- 1 adar adar 1210 Aug 27 16:29 kuduClientConfig.cmake
-rw-r--r-- 1 adar adar 1210 Mar 10 10:29 kuduClientConfig.cmakee
-rw-r--r-- 1 adar adar 2997 Aug 27 16:29 kuduClientTargets.cmake
-rw-r--r-- 1 adar adar 3024 Jul 14 13:17 kuduClientTargets.cmakee
-rw-r--r-- 1 adar adar  828 Aug 27 16:29 kuduClientTargets-debug.cmake
-rw-r--r-- 1 adar adar  873 Aug 27 13:48 kuduClientTargets-debug.cmakee

I fought with cmake, sed, and single quotes for all of five minutes before
giving up and dropping the -e altogether.

Change-Id: I18d0dc59e91897b58f81014597d29e9e58a13aa1
Reviewed-on: http://gerrit.sjc.cloudera.com:8080/7669
Tested-by: Adar Dembo <866ca730bfc7f544e3ebce604ceeba4879f23df0@cloudera.com>
Reviewed-by: Todd Lipcon <2c763d726a8c2f6afda9be7e0e56a2caa6bb5e6b@cloudera.com>

--- src/kudu/client/MungeExportedInstallTargets.cmake
+++ src/kudu/client/MungeExportedInstallTargets.cmake
@@ -11,5 +11,5 @@
 file(GLOB CMAKE_FILES "${CMAKE_FILES_DIR}/*.cmake")
 foreach(CMAKE_FILE ${CMAKE_FILES})
   message(STATUS "Munging kudu client targets in ${CMAKE_FILE}")
-  execute_process(COMMAND sed -ie s/kudu_client_exported/kudu_client/g ${CMAKE_FILE})
+  execute_process(COMMAND sed -i s/kudu_client_exported/kudu_client/g ${CMAKE_FILE})
 endforeach()


BUG: Mantis-1124: fix the use of Update_command and reorder the patch commands properly

--- SuperBuild/CMake/External_gdal.cmake
+++ SuperBuild/CMake/External_gdal.cmake
@@ -51,10 +51,10 @@
       INSTALL_DIR ${SB_INSTALL_PREFIX}
       DOWNLOAD_DIR ${DOWNLOAD_LOCATION}
       DEPENDS ${${proj}_DEPENDENCIES}
-      UPDATE_COMMAND  ${CMAKE_COMMAND} -E copy_directory ${GDAL_SB_SRC} ${GDAL_SB_BUILD_DIR}
       PATCH_COMMAND ${CMAKE_COMMAND} -E touch ${GDAL_SB_SRC}/config.rpath
         COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/patches/GDAL/GNUmakefile ${GDAL_SB_SRC}/swig/python/GNUmakefile
         COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_SOURCE_DIR}/patches/${proj}/S2_patch ${GDAL_SB_SRC}
+        COMMAND ${CMAKE_COMMAND} -E copy_directory ${GDAL_SB_SRC} ${GDAL_SB_BUILD_DIR}
       CONFIGURE_COMMAND
         # use 'env' because CTest launcher doesn't perform shell interpretation
         ${SB_ENV_CONFIGURE_CMD}
@@ -89,9 +89,9 @@
        INSTALL_DIR ${SB_INSTALL_PREFIX}
       DOWNLOAD_DIR ${DOWNLOAD_LOCATION}
        DEPENDS ${${proj}_DEPENDENCIES}
-       PATCH_COMMAND ${CMAKE_COMMAND} -E copy_directory  ${GDAL_SB_SRC} ${GDAL_SB_BUILD_DIR}
-        COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/patches/GDAL/GNUmakefile ${GDAL_SB_SRC}/swig/python/GNUmakefile
+       PATCH_COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/patches/GDAL/GNUmakefile ${GDAL_SB_SRC}/swig/python/GNUmakefile
         COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_SOURCE_DIR}/patches/${proj}/S2_patch ${GDAL_SB_SRC}
+        COMMAND ${CMAKE_COMMAND} -E copy_directory  ${GDAL_SB_SRC} ${GDAL_SB_BUILD_DIR}
        CONFIGURE_COMMAND  ${CMAKE_COMMAND} -E copy  ${CMAKE_SOURCE_DIR}/patches/${proj}/ogrsqlitevirtualogr.cpp
       ${GDAL_SB_BUILD_DIR}/ogr/ogrsf_frmts/sqlite/ogrsqlitevirtualogr.cpp
        BUILD_COMMAND nmake /f ${GDAL_SB_BUILD_DIR}/makefile.vc MSVC_VER=${MSVC_VERSION} EXT_NMAKE_OPT=${CMAKE_BINARY_DIR}/nmake_gdal_extra.opt


Updating virtualenv version to 15.0.1

Updating virtualenv version to 15.0.1

Change-Id: Ia3d6b9997421fcf196708ba7a11a968311ab6d49

--- SuperBuild/External_virtualenv.cmake
+++ SuperBuild/External_virtualenv.cmake
@@ -7,8 +7,8 @@

 set(proj virtualenv)

-set(${proj}_TARGET_VERSION 14.0.6)
-set(${proj}_DOWNLOAD_SOURCE_HASH "a035037925c82990a7659ecf8764bcdb")
+set(${proj}_TARGET_VERSION 15.0.1)
+set(${proj}_DOWNLOAD_SOURCE_HASH "28d76a0d9cbd5dc42046dd14e76a6ecc")

 # based on the standard EP_PREFIX locations, but since we don't build
 # or install, then standars install directory is also the source


mpich seems to require the path to the exe

--- test/cmake/macros.cmake
+++ test/cmake/macros.cmake
@@ -19,7 +19,7 @@
     FOREACH(PROCS ${NUMBER_OF_PROCESSES_TO_EXECUTE})
         ADD_TEST(
             NAME ${TEST_NAME}_${PROCS}_procs
-            COMMAND ${MPIEXEC} ${MPIEXEC_NUMPROC_FLAG} ${PROCS} ${TEST_NAME}.exe
+            COMMAND ${MPIEXEC} ${MPIEXEC_NUMPROC_FLAG} ${PROCS} ./${TEST_NAME}.exe
             )
     ENDFOREACH()
 ENDFUNCTION()


Fix warnings when building with VS11.

Fix warnings when building with VS11.

git-svn-id: 0ff597fd157e6f4fc38580e8d64ab130330d2411@152523 91177308-0d34-0410-b5e6-96231b3b80d8

--- include/llvm/Support/DataTypes.h.cmake
+++ include/llvm/Support/DataTypes.h.cmake
@@ -94,6 +94,9 @@
 #else /* _MSC_VER */
 /* Visual C++ doesn't provide standard integer headers, but it does provide
    built-in data types. */
+#ifdef HAVE_STDINT_H
+#include <stdint.h>
+#endif
 #include <stdlib.h>
 #include <stddef.h>
 #include <sys/types.h>


Fix missing quotes in CMake for SWIFT_STDLIB_DISABLE_INSTANTIATION_CACHES

--- stdlib/cmake/modules/SwiftSource.cmake
+++ stdlib/cmake/modules/SwiftSource.cmake
@@ -527,7 +527,7 @@
   endif()

   if(SWIFT_STDLIB_DISABLE_INSTANTIATION_CACHES)
-    list(APPEND swift_flags "-Xfrontend -disable-preallocated-instantiation-caches")
+    list(APPEND swift_flags "-Xfrontend" "-disable-preallocated-instantiation-caches")
   endif()

   list(APPEND swift_flags ${SWIFT_STDLIB_EXTRA_SWIFT_COMPILE_FLAGS})


conserve spaces: if the FLAGS variable is empty replace instead of append

--- cmake/AddCompilerFlag.cmake
+++ cmake/AddCompilerFlag.cmake
@@ -136,10 +136,18 @@
    endif()

    if(check_c_compiler_flag_${_flag_esc} AND DEFINED _c_flags)
-      set(${_c_flags} "${${_c_flags}} ${_flag}")
+      if(${_c_flags})
+         set(${_c_flags} "${${_c_flags}} ${_flag}")
+      else()
+         set(${_c_flags} "${_flag}")
+      endif()
    endif()
    if(check_cxx_compiler_flag_${_flag_esc} AND DEFINED _cxx_flags)
-      set(${_cxx_flags} "${${_cxx_flags}} ${_flag}")
+      if(${_cxx_flags})
+         set(${_cxx_flags} "${${_cxx_flags}} ${_flag}")
+      else()
+         set(${_cxx_flags} "${_flag}")
+      endif()
    endif()

    if(MIC_NATIVE_FOUND)


Update version string

Update version string

--- cmake/DawnDefinitions.cmake
+++ cmake/DawnDefinitions.cmake
@@ -48,5 +48,5 @@
 string(TOLOWER ${CMAKE_CXX_COMPILER_ID} compiler)
 set(compiler "${compiler}-${CMAKE_CXX_COMPILER_VERSION}")
 set(DAWN_FULL_VERSION_STR
-    "${DAWN_VERSION_STRING}-${SDAWN_GIT_HASH}-${architecture}-${platform}-${compiler}"
+    "${DAWN_VERSION_STR}-${SDAWN_GIT_HASH}-${architecture}-${platform}-${compiler}"
     CACHE STRING "Full version string of Dawn" FORCE)


Improvements in package build.

Improvements in package build.

--- cmake/OpenCVPackaging.cmake
+++ cmake/OpenCVPackaging.cmake
@@ -2,16 +2,21 @@
 set(CPACK_set_DESTDIR "on")

 if(NOT OPENCV_CUSTOM_PACKAGE_INFO)
-  set(CPACK_PACKAGE_DESCRIPTION "Open Computer Vision Library")
-  set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "OpenCV")
+  set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Open Computer Vision Library")
+  set(CPACK_PACKAGE_DESCRIPTION
+"OpenCV (Open Source Computer Vision Library) is an open source computer vision
+and machine learning software library. OpenCV was built to provide a common
+infrastructure for computer vision applications and to accelerate the use of
+machine perception in the commercial products. Being a BSD-licensed product,
+OpenCV makes it easy for businesses to utilize and modify the code.")
   set(CPACK_PACKAGE_VENDOR "OpenCV Foundation")
   set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/LICENSE")
   set(CPACK_PACKAGE_CONTACT "admin@opencv.org")
+  set(CPACK_PACKAGE_VERSION_MAJOR "${OPENCV_VERSION_MAJOR}")
+  set(CPACK_PACKAGE_VERSION_MINOR "${OPENCV_VERSION_MINOR}")
+  set(CPACK_PACKAGE_VERSION_PATCH "${OPENCV_VERSION_PATCH}")
+  set(CPACK_PACKAGE_VERSION "${OPENCV_VCSVERSION}")
 endif(NOT OPENCV_CUSTOM_PACKAGE_INFO)
-
-set(CPACK_PACKAGE_VERSION_MAJOR "${OPENCV_VERSION_MAJOR}")
-set(CPACK_PACKAGE_VERSION_MINOR "${OPENCV_VERSION_MINOR}")
-set(CPACK_PACKAGE_VERSION_PATCH "${OPENCV_VERSION_PATCH}")

 #arch
 if(X86)
@@ -19,7 +24,7 @@
   set(CPACK_RPM_PACKAGE_ARCHITECTURE "i686")
 elseif(X86_64)
   set(CPACK_DEBIAN_ARCHITECTURE "amd64")
-  set(CPACK_RPM_PACKAGE_ARCHITECTURE "amd64")
+  set(CPACK_RPM_PACKAGE_ARCHITECTURE "x86_64")
 elseif(ARM)
   set(CPACK_DEBIAN_ARCHITECTURE "armhf")
   set(CPACK_RPM_PACKAGE_ARCHITECTURE "armhf")
@@ -41,11 +46,16 @@

 #rpm options
 set(CPACK_RPM_COMPONENT_INSTALL TRUE)
-set(CPACK_RPM_PACKAGE_LICENSE ${CPACK_RESOURCE_FILE_LICENSE})
+set(CPACK_RPM_PACKAGE_SUMMARY ${CPACK_PACKAGE_DESCRIPTION_SUMMARY})
+set(CPACK_RPM_PACKAGE_DESCRIPTION ${CPACK_PACKAGE_DESCRIPTION})
+set(CPACK_RPM_PACKAGE_URL "http://opencv.org")
+set(CPACK_RPM_PACKAGE_LICENSE "BSD")

 #deb options
 set(CPACK_DEB_COMPONENT_INSTALL TRUE)
-set(CPACK_DEBIAN_PACKAGE_PRIORITY "extra")
+set(CPACK_DEBIAN_PACKAGE_PRIORITY "optional")
+set(CPACK_DEBIAN_PACKAGE_SECTION "libs")
+set(CPACK_DEBIAN_PACKAGE_HOMEPAGE "http://opencv.org")

 #depencencies
 set(CPACK_DEBIAN_PACKAGE_SHLIBDEPS TRUE)
@@ -54,6 +64,13 @@
 set(CPACK_COMPONENT_docs_DEPENDS libs)
 set(CPACK_COMPONENT_java_DEPENDS libs)
 set(CPACK_COMPONENT_python_DEPENDS libs)
+
+if(HAVE_CUDA)
+  string(REPLACE "." "-" cuda_version_suffix ${CUDA_VERSION})
+  set(CPACK_DEB_libs_PACKAGE_DEPENDS "cuda-core-libs-${cuda_version_suffix}, cuda-extra-libs-${cuda_version_suffix}")
+  set(CPACK_COMPONENT_dev_DEPENDS libs)
+  set(CPACK_DEB_dev_PACKAGE_DEPENDS "cuda-headers-${cuda_version_suffix}")
+endif()

 if(NOT OPENCV_CUSTOM_PACKAGE_INFO)
   set(CPACK_COMPONENT_libs_DISPLAY_NAME "lib${CMAKE_PROJECT_NAME}")


[cmake] update comment on option WITH_MECHANISMS

--- cmake/default_options.cmake
+++ cmake/default_options.cmake
@@ -32,7 +32,7 @@
 option(WITH_UMFPACK "Compilation with the UMFPACK solver. Default = OFF" OFF)
 option(WITH_FCLIB "link with fclib when this mode is enable. Default = OFF" OFF)
 option(WITH_FREECAD "Use FreeCAD. Default = OFF" OFF)
-option(WITH_MECHANISMS "Generation of bindings for Saladyn Mechanisms toolbox. Default = OFF" OFF)
+option(WITH_MECHANISMS "Generation of bindings for Mechanisms toolbox (required OCE). Default = OFF" OFF)
 option(WITH_XML "Enable xml files i/o. Default = ON" ON)
 option(WITH_DOCKER "Build inside a docker container. Default = OFF" OFF)
 option(FORCE_SKIP_RPATH "Do not build shared libraries with rpath. Useful only for packaging. Default = OFF" OFF)


[CMake] add_llvm_loadable_module: Fixup r200762, I mis-eliminated wrong line. :(

git-svn-id: 0ff597fd157e6f4fc38580e8d64ab130330d2411@200763 91177308-0d34-0410-b5e6-96231b3b80d8

--- cmake/modules/AddLLVM.cmake
+++ cmake/modules/AddLLVM.cmake
@@ -217,6 +217,7 @@
     # Add empty "phony" target
     add_custom_target(${name})
   else()
+    llvm_process_sources( ALL_FILES ${ARGN} )
     add_library(${name} MODULE ${ALL_FILES})
     set_output_directory(${name} ${LLVM_RUNTIME_OUTPUT_INTDIR} ${LLVM_LIBRARY_OUTPUT_INTDIR})
     set_target_properties( ${name} PROPERTIES PREFIX "" )


Install runtime dlls in the INSTALL_DIR/bin directory. NFC

One of the earlier patches updated the cmake rule to install the
runtime dlls in INSTALL_DIR/lib which is not correct. This patch
updates the rule to install CMake's RUNTIME in bin directory
Differential Revision: http://reviews.llvm.org/D15505

git-svn-id: 0ff597fd157e6f4fc38580e8d64ab130330d2411@255781 91177308-0d34-0410-b5e6-96231b3b80d8

--- cmake/modules/AddLLVM.cmake
+++ cmake/modules/AddLLVM.cmake
@@ -541,9 +541,11 @@
     set_target_properties( ${name} PROPERTIES EXCLUDE_FROM_ALL ON)
   elseif(NOT _is_gtest)
     if (NOT LLVM_INSTALL_TOOLCHAIN_ONLY OR ${name} STREQUAL "LTO")
+      set(install_dir lib${LLVM_LIBDIR_SUFFIX})
       if(ARG_SHARED OR BUILD_SHARED_LIBS)
-        if(WIN32 OR CYGWIN)
+        if(WIN32 OR CYGWIN OR MINGW)
           set(install_type RUNTIME)
+          set(install_dir bin)
         else()
           set(install_type LIBRARY)
         endif()
@@ -553,7 +555,7 @@

       install(TARGETS ${name}
             EXPORT LLVMExports
-            ${install_type} DESTINATION lib${LLVM_LIBDIR_SUFFIX}
+            ${install_type} DESTINATION ${install_dir}
             COMPONENT ${name})

       if (NOT CMAKE_CONFIGURATION_TYPES)


Build Git in source

Build Git in source

This is so that it can find Makefile.

--- cmake/modules/FindGit.cmake
+++ cmake/modules/FindGit.cmake
@@ -11,6 +11,7 @@
 			URL https://www.kernel.org/pub/software/scm/git/git-2.10.0.tar.gz
 			URL_HASH SHA512=EA6312A5F3EC3DBC48E02F65798A4EA8B5CAB60CC0D9DA6EF4A32A575324C12617F76604E4AD5DA9835F0F6769F405526133E831B327262B67A070EEFCDEDDEA
 			CONFIGURE_COMMAND "" #No CMakeLists here.
+			BUILD_IN_SOURCE 1
 		)
 		set(GIT_EXECUTABLE ${CMAKE_CURRENT_BINARY_DIR}/Git-prefix/src/Git-build/git)
 		set(git_version "git version 2.10.0")


COMP: Bump KWStyle to 2018-02-22 master

COMP: Bump KWStyle to 2018-02-22 master

Includes a boost update for Newer X-code compilers.

Co-authored-by: Sean McBride <sean@rogue-research.com>

Change-Id: I57be62057bd2890534d46bc8dc04ac6e90ae519e

--- Utilities/KWStyle/BuildKWStyle.cmake
+++ Utilities/KWStyle/BuildKWStyle.cmake
@@ -23,7 +23,7 @@
 if(NOT TARGET KWStyle)
 ExternalProject_add(KWStyle
   GIT_REPOSITORY "${git_protocol}://github.com/Kitware/KWStyle.git"
-  GIT_TAG 8148e5ac45dc9783e6bb55b06c7398db63936ec4
+  GIT_TAG f732214adae862e89a8cfe114553bc53211b46d4
   UPDATE_COMMAND ""
   DOWNLOAD_DIR ${KWStyle_SOURCE_DIR}
   SOURCE_DIR ${KWStyle_SOURCE_DIR}


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 01)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   03)
+SET(KWSYS_DATE_STAMP_DAY   04)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 03)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   03)
+SET(KWSYS_DATE_STAMP_DAY   04)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 08)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   25)
+SET(KWSYS_DATE_STAMP_DAY   26)


STYLE: Nightly Date Stamp

STYLE: Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -7,4 +7,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 02)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   22)
+SET(KWSYS_DATE_STAMP_DAY   23)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 10)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   04)
+SET(KWSYS_DATE_STAMP_DAY   05)


STYLE: Nightly Date Stamp

STYLE: Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -7,4 +7,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 06)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   13)
+SET(KWSYS_DATE_STAMP_DAY   14)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 10)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   07)
+SET(KWSYS_DATE_STAMP_DAY   08)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -7,4 +7,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 08)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   11)
+SET(KWSYS_DATE_STAMP_DAY   12)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 01)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   21)
+SET(KWSYS_DATE_STAMP_DAY   22)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 05)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   03)
+SET(KWSYS_DATE_STAMP_DAY   04)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -7,4 +7,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 09)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   20)
+SET(KWSYS_DATE_STAMP_DAY   21)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 05)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   19)
+SET(KWSYS_DATE_STAMP_DAY   20)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 07)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   07)
+SET(KWSYS_DATE_STAMP_DAY   08)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 03)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   11)
+SET(KWSYS_DATE_STAMP_DAY   12)


emscripten: added cmake option for new Duplicate Function Elimination (default: off)

--- cmake-toolchains/emscripten.toolchain.cmake
+++ cmake-toolchains/emscripten.toolchain.cmake
@@ -38,6 +38,7 @@

 # tweakable options
 option(FIPS_EMSCRIPTEN_USE_FS "emscripten: enable FS module" OFF)
+option(FIPS_EMSCRIPTEN_USE_DFE "emscripten: enable Duplicate Function Elimination" OFF)
 set(FIPS_EMSCRIPTEN_TOTAL_MEMORY 134217728 CACHE STRING "emscripten: total heap size in bytes")
 set(FIPS_EMSCRIPTEN_LTO_LEVEL 1 CACHE STRING "emscripten: Link-time-optimization level (0..3)")
 set(FIPS_EMSCRIPTEN_OUTLINING_LIMIT 20000 CACHE STRING "emscripten: outlining limit")
@@ -65,6 +66,13 @@
     set(EMSCRIPTEN_NO_FILESYSTEM 0)
 else()
     set(EMSCRIPTEN_NO_FILESYSTEM 1)
+endif()
+if (FIPS_EMSCRIPTEN_USE_DFE)
+    set(EMSCRIPTEN_DFE 1)
+    set(EMSCRIPTEN_DFE_DUMP 1)
+else()
+    set(EMSCRIPTEN_DFE 0)
+    set(EMSCRIPTEN_DFE_DUMP 0)
 endif()

 # disable closure for now, as long as ANGLE_instanced_array support is not fully supported in emscripten
@@ -106,6 +114,7 @@
 message("EMSCRIPTEN_ASSERTIONS: ${EMSCRIPTEN_ASSERTIONS}")
 message("EMSCRIPTEN_DISABLE_EXCEPTION_CATCHING: ${EMSCRIPTEN_DISABLE_EXCEPTION_CATCHING}")
 message("EMSCRIPTEN_NO_FILESYSTEM: ${EMSCRIPTEN_NO_FILESYSTEM}")
+message("EMSCRIPTEN_DFE: ${EMSCRIPTEN_DFE}")
 message("EMSCRIPTEN_TRACING: ${EMSCRIPTEN_TRACING}")

 set(CMAKE_SYSTEM_NAME Linux)
@@ -199,7 +208,7 @@
 set(CMAKE_C_FLAGS_PROFILING "${EMSCRIPTEN_OPT} --profiling")

 # linker flags
-set(CMAKE_EXE_LINKER_FLAGS "${EMSCRIPTEN_CONFIG_OPTION} ${EMSCRIPTEN_CACHE_OPTION} ${EMSCRIPTEN_TRACING_OPTION} --memory-init-file ${EMSCRIPTEN_MEMORY_INIT_FLAG} -s MEM_INIT_METHOD=${FIPS_EMSCRIPTEN_MEM_INIT_METHOD} -s ERROR_ON_UNDEFINED_SYMBOLS=1 -s TOTAL_MEMORY=${FIPS_EMSCRIPTEN_TOTAL_MEMORY} -s DISABLE_EXCEPTION_CATCHING=${EMSCRIPTEN_DISABLE_EXCEPTION_CATCHING} -s NO_FILESYSTEM=${EMSCRIPTEN_NO_FILESYSTEM}")
+set(CMAKE_EXE_LINKER_FLAGS "${EMSCRIPTEN_CONFIG_OPTION} ${EMSCRIPTEN_CACHE_OPTION} ${EMSCRIPTEN_TRACING_OPTION} --memory-init-file ${EMSCRIPTEN_MEMORY_INIT_FLAG} -s MEM_INIT_METHOD=${FIPS_EMSCRIPTEN_MEM_INIT_METHOD} -s ERROR_ON_UNDEFINED_SYMBOLS=1 -s TOTAL_MEMORY=${FIPS_EMSCRIPTEN_TOTAL_MEMORY} -s DISABLE_EXCEPTION_CATCHING=${EMSCRIPTEN_DISABLE_EXCEPTION_CATCHING} -s NO_FILESYSTEM=${EMSCRIPTEN_NO_FILESYSTEM} -s ELIMINATE_DUPLICATE_FUNCTIONS=${EMSCRIPTEN_DFE} -s ELIMINATE_DUPLICATE_FUNCTIONS_DUMP_EQUIVALENT_FUNCTIONS=${EMSCRIPTEN_DFE_DUMP}")
 set(CMAKE_EXE_LINKER_FLAGS_RELEASE "${EMSCRIPTEN_OPT} --llvm-lto ${FIPS_EMSCRIPTEN_LTO_LEVEL} -s VERBOSE=${EMSCRIPTEN_BUILD_VERBOSE} -s ASM_JS=1 -s ASSERTIONS=${EMSCRIPTEN_ASSERTIONS} -s OUTLINING_LIMIT=${FIPS_EMSCRIPTEN_OUTLINING_LIMIT} --closure ${EMSCRIPTEN_USE_CLOSURE}")
 set(CMAKE_EXE_LINKER_FLAGS_DEBUG "${EMSCRIPTEN_OPT} -g -s ASM_JS=1 -s VERBOSE=${EMSCRIPTEN_BUILD_VERBOSE}")
 set(CMAKE_EXE_LINKER_FLAGS_PROFILING "--profiling ${EMSCRIPTEN_OPT} --llvm-lto ${FIPS_EMSCRIPTEN_LTO_LEVEL} -s VERBOSE=${EMSCRIPTEN_BUILD_VERBOSE} -s ASM_JS=1 -s ASSERTIONS=${EMSCRIPTEN_ASSERTIONS} -s OUTLINING_LIMIT=${FIPS_EMSCRIPTEN_OUTLINING_LIMIT}")
@@ -208,7 +217,7 @@
 set(CMAKE_STATIC_LINKER_FLAGS "${EMSCRIPTEN_CONFIG_OPTION}")

 # dynamic lib linker flags
-set(CMAKE_SHARED_LINKER_FLAGS "-shared ${EMSCRIPTEN_CONFIG_OPTIONS} ${EMSCRIPTEN_CACHE_OPTION} ${EMSCRIPTEN_TRACING_OPTION} --memory-init-file 0 -s ERROR_ON_UNDEFINED_SYMBOLS=1 -s TOTAL_MEMORY=${FIPS_EMSCRIPTEN_TOTAL_MEMORY_WORKER} -s BUILD_AS_WORKER=1 -s EXPORTED_FUNCTIONS=[\\\"_dowork\\\"] -s DISABLE_EXCEPTION_CATCHING=${EMSCRIPTEN_DISABLE_EXCEPTION_CATCHING} -s NO_FILESYSTEM=${EMSCRIPTEN_NO_FILESYSTEM}")
+set(CMAKE_SHARED_LINKER_FLAGS "-shared ${EMSCRIPTEN_CONFIG_OPTIONS} ${EMSCRIPTEN_CACHE_OPTION} ${EMSCRIPTEN_TRACING_OPTION} --memory-init-file 0 -s ERROR_ON_UNDEFINED_SYMBOLS=1 -s TOTAL_MEMORY=${FIPS_EMSCRIPTEN_TOTAL_MEMORY_WORKER} -s BUILD_AS_WORKER=1 -s EXPORTED_FUNCTIONS=[\\\"_dowork\\\"] -s DISABLE_EXCEPTION_CATCHING=${EMSCRIPTEN_DISABLE_EXCEPTION_CATCHING} -s NO_FILESYSTEM=${EMSCRIPTEN_NO_FILESYSTEM} -s ELIMINATE_DUPLICATE_FUNCTIONS=${EMSCRIPTEN_DFE} -s ELIMINATE_DUPLICATE_FUNCTIONS_DUMP_EQUIVALENT_FUNCTIONS=${EMSCRIPTEN_DFE_DUMP}")
 set(CMAKE_SHARED_LINKER_FLAGS_RELEASE "${EMSCRIPTEN_OPT} --llvm-lto ${FIPS_EMSCRIPTEN_LTO_LEVEL} -s VERBOSE=${EMSCRIPTEN_BUILD_VERBOSE} -s ASM_JS=1 -s ASSERTIONS=${EMSCRIPTEN_ASSERTIONS} -s OUTLINING_LIMIT=${FIPS_EMSCRIPTEN_OUTLINING_LIMIT} --closure ${EMSCRIPTEN_USE_CLOSURE}")
 set(CMAKE_SHARED_LINKER_FLAGS_DEBUG "${EMSCRIPTEN_OPT} -g -s ASM_JS=1 -s VERBOSE=${EMSCRIPTEN_BUILD_VERBOSE} --closure 0")
 set(CMAKE_SHARED_LINKER_FLAGS_PROFILING "--profiling ${EMSCRIPTEN_OPT} --llvm-lto ${FIPS_EMSCRIPTEN_LTO_LEVEL} -s VERBOSE=${EMSCRIPTEN_BUILD_VERBOSE} -s ASM_JS=1 -s ASSERTIONS=${EMSCRIPTEN_ASSERTIONS} -s OUTLINING_LIMIT=${FIPS_EMSCRIPTEN_OUTLINING_LIMIT}")


Fix cmake fortran support so it will also work with cmake 2.4.

svn path=/trunk/; revision=8912

--- cmake/modules/CMakeFortranInformation.cmake
+++ cmake/modules/CMakeFortranInformation.cmake
@@ -150,8 +150,13 @@

 # compile a Fortran file into an object file
 IF(NOT CMAKE_Fortran_COMPILE_OBJECT)
-  SET(CMAKE_Fortran_COMPILE_OBJECT
-    "<CMAKE_Fortran_COMPILER> -o <OBJECT> <DEFINES> <FLAGS> -c <SOURCE>")
+  IF(${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} GREATER 2.4)
+    SET(CMAKE_Fortran_COMPILE_OBJECT
+      "<CMAKE_Fortran_COMPILER> -o <OBJECT> <DEFINES> <FLAGS> -c <SOURCE>")
+  ELSE(${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} GREATER 2.4)
+    SET(CMAKE_Fortran_COMPILE_OBJECT
+      "<CMAKE_Fortran_COMPILER> -o <OBJECT> <FLAGS> -c <SOURCE>")
+  ENDIF(${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} GREATER 2.4)
 ENDIF(NOT CMAKE_Fortran_COMPILE_OBJECT)

 # link a fortran program


Update builtin version of VecCore to 0.5.0

--- cmake/modules/SearchInstalledSoftware.cmake
+++ cmake/modules/SearchInstalledSoftware.cmake
@@ -1355,7 +1355,7 @@
 endif()

 if(veccore AND NOT VecCore_FOUND)
-  set(VecCore_VERSION "0.4.2")
+  set(VecCore_VERSION "0.5.0")
   set(VecCore_PROJECT "VecCore-${VecCore_VERSION}")
   set(VecCore_SRC_URI "${lcgpackages}/${VecCore_PROJECT}.tar.gz")
   set(VecCore_DESTDIR "${CMAKE_BINARY_DIR}/externals")
@@ -1363,7 +1363,7 @@

   ExternalProject_Add(VECCORE
     URL     ${VecCore_SRC_URI}
-    URL_HASH SHA256=79f418e466c211d0a5ff1d9127a82d84bceefe5321878cd37e77f50bc91f4cc2
+    URL_HASH SHA256=5b52205c1213574fa43d6362b60b0e16239035cf64106f8841d7beb7e32bdd03
     BUILD_IN_SOURCE 0
     LOG_DOWNLOAD 1 LOG_CONFIGURE 1 LOG_BUILD 1 LOG_INSTALL 1
     CMAKE_ARGS -G ${CMAKE_GENERATOR}


Update to latest AddSAMPPlugin.cmake from cmake-modules

--- cmake/AddSAMPPlugin.cmake
+++ cmake/AddSAMPPlugin.cmake
@@ -3,7 +3,7 @@

   set_target_properties(${name} PROPERTIES PREFIX "")

-  if(CMAKE_COMPILER_IS_GNUCC OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
+  if(CMAKE_COMPILER_IS_GNUCC OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
     set_property(TARGET ${name} APPEND_STRING PROPERTY COMPILE_FLAGS " -m32")
     set_property(TARGET ${name} APPEND_STRING PROPERTY LINK_FLAGS    " -m32")
   endif()
@@ -13,7 +13,7 @@
                  COMPILE_FLAGS " -Wno-attributes")
   endif()

-  if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
+  if(CMAKE_CXX_COMPILER_ID MATCHES "Clang")
     set_property(TARGET ${name} APPEND_STRING PROPERTY
                  COMPILE_FLAGS " -Wno-ignored-attributes")
   endif()
@@ -23,7 +23,7 @@
                  LINK_FLAGS " -Wl,--enable-stdcall-fixup")
   endif()

-  if(UNIX AND NOT WIN32)
+  if(UNIX AND NOT WIN32 AND NOT APPLE)
     set_property(TARGET ${name} APPEND PROPERTY COMPILE_DEFINITIONS "LINUX")
   endif()
 endfunction()


Update Depdendencies.cmake

Update Depdendencies.cmake

Downgraded Qt to 5.15.2 for windows

--- cmake/Depdendencies.cmake
+++ cmake/Depdendencies.cmake
@@ -47,8 +47,8 @@
         # Let FAST build Qt 5
         if(WIN32)
             fast_download_dependency(qt5
-                    5.15.5
-                    0e253ac91463f3d722f100402c24b8ec2363bb28954636068d0b5bd30e0476a0
+                    5.15.2
+		    3d025e412d4af7d4fe669677ac71614909eb44aac8eca6b8fb29459abf621dff
                     Qt5Core.lib Qt5Gui.lib Qt5Widgets.lib Qt5OpenGL.lib Qt5Multimedia.lib Qt5MultimediaWidgets.lib Qt5Network.lib Qt5PrintSupport.lib Qt5SerialPort.lib
             )
             fast_download_dependency(openssl


Replace new grpc package

Replace new grpc package

--- cmake/external/grpc.cmake
+++ cmake/external/grpc.cmake
@@ -45,7 +45,7 @@
     #    checkout and clean other dirs under third_party
     # 4. remove .git, and package the directory.
     URL "http://paddlepaddledeps.bj.bcebos.com/grpc-v1.10.x-paddle.tar.gz"
-    URL_MD5  "6c472b60703aad03ce697c502a70c01f"
+    URL_MD5  "eb06e8a63e679c5ec14ac9debade7ba1"
     PREFIX          ${GRPC_SOURCES_DIR}
     UPDATE_COMMAND  ""
     CONFIGURE_COMMAND ""


remove unused nccl.cmake

remove unused nccl.cmake

--- cmake/external/nccl.cmake
+++ cmake/external/nccl.cmake
@@ -1,67 +0,0 @@
-# Copyright (c) 2016 PaddlePaddle Authors. All Rights Reserved.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-if(NOT WITH_GPU)
-  return()
-endif()
-
-include(ExternalProject)
-
-set(NCCL_SOURCE_DIR ${THIRD_PARTY_PATH}/nccl)
-
-include_directories(${NCCL_SOURCE_DIR}/src/extern_nccl/src)
-
-if(WITH_DSO)
-  # If we use DSO, we do not build nccl, just download the dependencies
-  set(NCCL_BUILD_COMMAND "")
-  set(NCCL_INSTALL_COMMAND "")
-  set(NCCL_INSTALL_DIR "")
-else()
-  # otherwise, we build nccl and link it.
-  set(NCCL_INSTALL_DIR ${THIRD_PARTY_PATH}/install/nccl)
-  # Note: cuda 8.0 is needed to make nccl
-  # When cuda is not installed on the system directory, need to set CUDA_HOME to your cuda root
-  set(NCCL_BUILD_COMMAND "make -j 8")
-  set(NCCL_INSTALL_COMMAND  "make install PREFIX=${NCCL_INSTALL_DIR}")
-endif()
-
-ExternalProject_Add(
-    extern_nccl
-    ${EXTERNAL_PROJECT_LOG_ARGS}
-    GIT_REPOSITORY  "https://github.com/NVIDIA/nccl.git"
-    GIT_TAG         "v1.3.4-1"
-    PREFIX          "${NCCL_SOURCE_DIR}"
-    UPDATE_COMMAND  ""
-    CONFIGURE_COMMAND ""
-    BUILD_COMMAND     "${NCCL_BUILD_COMMAND}"
-    INSTALL_COMMAND   "${NCCL_INSTALL_COMMAND}"
-    INSTALL_DIR       "${NCCL_INSTALL_DIR}"
-    TEST_COMMAND      ""
-)
-
-if(WITH_DSO)
-  if(${CMAKE_VERSION} VERSION_LESS "3.3.0")
-    set(dummyfile ${CMAKE_CURRENT_BINARY_DIR}/lib_nccl_dummy.c)
-    file(WRITE ${dummyfile} "const char * dummy_nccl = \"${dummyfile}\";")
-    add_library(nccl STATIC ${dummyfile})
-  else()
-    add_library(nccl INTERFACE)
-  endif()
-else()
-  add_library(nccl STATIC IMPORTED GLOBAL)
-  set_property(TARGET nccl PROPERTY IMPORTED_LOCATION
-               ${NCCL_INSTALL_DIR}/lib/libnccl_static.a)
-endif()
-
-add_dependencies(nccl extern_nccl)


build: add fPIC flag to tinyobjloader

build: add fPIC flag to tinyobjloader

--- cmake/tinyobjloader.cmake
+++ cmake/tinyobjloader.cmake
@@ -18,4 +18,5 @@

 reaper_configure_external_target(${TINYOBJLOADER_BIN} "TinyObjLoader")

+set_target_properties(${TINYOBJLOADER_BIN} PROPERTIES POSITION_INDEPENDENT_CODE ON)
 set_target_properties(${TINYOBJLOADER_BIN} PROPERTIES FOLDER External)


cmake: Use find_program() to locate the toolchain

Instead of hard-coding the path use find_program(), since that allows
CMake to sort out platform-specific details such as .exe extensions on
Windows.

Signed-off-by: Carles Cufi <853081dc8dca4fe6a7e3c984752718b5db36e060@nordicsemi.no>

--- cmake/toolchain-gcc.cmake
+++ cmake/toolchain-gcc.cmake
@@ -1,15 +1,15 @@
 # Configures CMake for using GCC, this script is re-used by several
 # GCC-based toolchains

-set(CMAKE_C_COMPILER   ${CROSS_COMPILE}gcc     CACHE INTERNAL " " FORCE)
-set(CMAKE_OBJCOPY      ${CROSS_COMPILE}objcopy CACHE INTERNAL " " FORCE)
-set(CMAKE_OBJDUMP      ${CROSS_COMPILE}objdump CACHE INTERNAL " " FORCE)
-#set(CMAKE_LINKER      ${CROSS_COMPILE}ld      CACHE INTERNAL " " FORCE) # Not in use yet
-set(CMAKE_AR           ${CROSS_COMPILE}ar      CACHE INTERNAL " " FORCE)
-set(CMAKE_RANLILB      ${CROSS_COMPILE}ranlib  CACHE INTERNAL " " FORCE)
-set(CMAKE_READELF      ${CROSS_COMPILE}readelf CACHE INTERNAL " " FORCE)
-set(CMAKE_GDB          ${CROSS_COMPILE}gdb     CACHE INTERNAL " " FORCE)
-set(CMAKE_NM           ${CROSS_COMPILE}nm      CACHE INTERNAL " " FORCE)
+find_program(CMAKE_C_COMPILER ${CROSS_COMPILE}gcc     PATH ${TOOLCHAIN_HOME} NO_DEFAULT_PATH)
+find_program(CMAKE_OBJCOPY    ${CROSS_COMPILE}objcopy PATH ${TOOLCHAIN_HOME} NO_DEFAULT_PATH)
+find_program(CMAKE_OBJDUMP    ${CROSS_COMPILE}objdump PATH ${TOOLCHAIN_HOME} NO_DEFAULT_PATH)
+#find_program(CMAKE_LINKER     ${CROSS_COMPILE}ld      PATH ${TOOLCHAIN_HOME} NO_DEFAULT_PATH)
+find_program(CMAKE_AR         ${CROSS_COMPILE}ar      PATH ${TOOLCHAIN_HOME} NO_DEFAULT_PATH)
+find_program(CMAKE_RANLIB     ${CROSS_COMPILE}ranlib  PATH ${TOOLCHAIN_HOME} NO_DEFAULT_PATH)
+find_program(CMAKE_READELF    ${CROSS_COMPILE}readelf PATH ${TOOLCHAIN_HOME} NO_DEFAULT_PATH)
+find_program(CMAKE_GDB        ${CROSS_COMPILE}gdb     PATH ${TOOLCHAIN_HOME} NO_DEFAULT_PATH)
+find_program(CMAKE_NM         ${CROSS_COMPILE}nm      PATH ${TOOLCHAIN_HOME} NO_DEFAULT_PATH)

 assert_exists(CMAKE_READELF)


iOS: add -Wno-expansion-to-defined for latest Xcode versions

--- cmake-toolchains/ios.toolchain.cmake
+++ cmake-toolchains/ios.toolchain.cmake
@@ -63,11 +63,11 @@
 endif()

 # compiler flags
-set(CMAKE_CXX_FLAGS "-fstrict-aliasing -Wno-multichar -Wall -Wextra -Wno-unused-parameter -Wno-unknown-pragmas -Wno-ignored-qualifiers -Wno-long-long -Wno-overloaded-virtual -Wno-unused-volatile-lvalue -Wno-deprecated-writable-strings")
+set(CMAKE_CXX_FLAGS "-fstrict-aliasing -Wno-multichar -Wall -Wextra -Wno-expansion-to-defined -Wno-unused-parameter -Wno-unknown-pragmas -Wno-ignored-qualifiers -Wno-long-long -Wno-overloaded-virtual -Wno-unused-volatile-lvalue -Wno-deprecated-writable-strings")
 set(CMAKE_CXX_FLAGS_RELEASE "-O3 -DNDEBUG")
 set(CMAKE_CXX_FLAGS_DEBUG "-O0 -D_DEBUG_ -D_DEBUG -DFIPS_DEBUG=1 -g")

-set(CMAKE_C_FLAGS "-fstrict-aliasing -Wno-multichar -Wall -Wextra -Wno-unused-parameter -Wno-unknown-pragmas -Wno-ignored-qualifiers -Wno-long-long -Wno-overloaded-virtual -Wno-unused-volatile-lvalue  -Wno-deprecated-writable-strings")
+set(CMAKE_C_FLAGS "-fstrict-aliasing -Wno-multichar -Wall -Wextra -Wno-expansion-to-defined -Wno-unused-parameter -Wno-unknown-pragmas -Wno-ignored-qualifiers -Wno-long-long -Wno-overloaded-virtual -Wno-unused-volatile-lvalue  -Wno-deprecated-writable-strings")
 set(CMAKE_C_FLAGS_RELEASE "-O3 -DNDEBUG")
 set(CMAKE_C_FLAGS_DEBUG "-O0 -D_DEBUG_ -D_DEBUG -DFIPS_DEBUG=1 -g")


comp: bump version number

comp: bump version number

--- CMake/version.cmake
+++ CMake/version.cmake
@@ -1,3 +1,3 @@
 set (VV_VERSION_MAJOR 1)
 set (VV_VERSION_MINOR 1)
-set (VV_VERSION_PATCH 4)
+set (VV_VERSION_PATCH 5)


ARROW-856: Also read compiler info from stdout

As I cannot reproduce the problem, this may not the be the correct solution. Still due to the output of `gcc -v` in the ticket, it is very likely that some systems print the info on stdout. Also the additional message should improve debugging.

Author: Uwe L. Korn <uwelk@xhochy.com>

Closes #650 from xhochy/ARROW-856 and squashes the following commits:

d87c7bd [Uwe L. Korn] ARROW-856: Also read compiler info from stdout

--- cpp/cmake_modules/CompilerInfo.cmake
+++ cpp/cmake_modules/CompilerInfo.cmake
@@ -21,7 +21,11 @@
   set(COMPILER_GET_VERSION_SWITCH "-v")
 endif()

+message(INFO "Compiler command: ${CMAKE_CXX_COMPILER}")
+# Some gcc seem to output their version on stdout, most do it on stderr, simply
+# merge both pipes into a single variable
 execute_process(COMMAND "${CMAKE_CXX_COMPILER}" ${COMPILER_GET_VERSION_SWITCH}
+                OUTPUT_VARIABLE COMPILER_VERSION_FULL
                 ERROR_VARIABLE COMPILER_VERSION_FULL)
 message(INFO "Compiler version: ${COMPILER_VERSION_FULL}")
 message(INFO "Compiler id: ${CMAKE_CXX_COMPILER_ID}")


fix TAR_URL for FindConfigurePackage

fix TAR_URL for FindConfigurePackage

--- project/cmake/modules/FindConfigurePackage.cmake
+++ project/cmake/modules/FindConfigurePackage.cmake
@@ -131,7 +131,7 @@
                     FindConfigurePackageDownloadFile("${FindConfigurePackage_TAR_URL}" "${FindConfigurePackage_WORKING_DIRECTORY}/${DOWNLOAD_FILENAME}")
                 endif()

-                execute_process(COMMAND ${CMAKE_COMMAND} -E tar xvf ${DOWNLOAD_NATIVE_FILENAME}
+                execute_process(COMMAND ${CMAKE_COMMAND} -E tar xvf "${FindConfigurePackage_WORKING_DIRECTORY}/${DOWNLOAD_FILENAME}"
                     WORKING_DIRECTORY ${FindConfigurePackage_WORKING_DIRECTORY}
                 )


better variable name

better variable name

--- tensorflow/contrib/cmake/tf_core_framework.cmake
+++ tensorflow/contrib/cmake/tf_core_framework.cmake
@@ -211,10 +211,6 @@
   file(GLOB tf_core_platform_srcs_exclude
       "${tensorflow_source_dir}/tensorflow/core/platform/default/device_tracer.cc")
   list(REMOVE_ITEM tf_core_platform_srcs ${tf_core_platform_srcs_exclude})
-  # file(GLOB tf_core_platform_gpu_srcs
-  #   "${tensorflow_source_dir}/tensorflow/core/platform/default/gpu/*.h"
-  #   "${tensorflow_source_dir}/tensorflow/core/platform/default/gpu/*.cc")
-  # list(APPEND tf_core_platform_srcs ${tf_core_platform_gpu_srcs})
 endif()

 file(GLOB tf_core_platform_exclude_srcs


BUG: Use https to download freetype

BUG: Use https to download freetype

--- SuperBuild/CMake/External_freetype.cmake
+++ SuperBuild/CMake/External_freetype.cmake
@@ -30,7 +30,7 @@

 ExternalProject_Add(FREETYPE
   PREFIX FREETYPE
-  URL "http://download.savannah.gnu.org/releases/freetype/freetype-2.6.tar.gz"
+  URL "https://download.savannah.gnu.org/releases/freetype/freetype-2.6.tar.gz"
   URL_MD5 1d733ea6c1b7b3df38169fbdbec47d2b
   BINARY_DIR ${FREETYPE_SB_BUILD_DIR}
   INSTALL_DIR ${SB_INSTALL_PREFIX}


COMP: Update remote module: TotalVariation

`git shortlog --no-merges fbab38..e47fb5`

```
Hans Johnson (3):
      STYLE: Remove CMake-language block-end command arguments
      ENH: Add .gitattributes to allow running ITK clang-formatting scripts
      DOC: Update copyright assignment to NumFOCUS

Jean-Christophe Fillion-Robin (1):
      COMP: Ensure proxTV dependencies are found when building against ITK build tree

Pablo Hernandez-Cerdan (5):
      BUG: Use ITKInternalEigen3_DIR to find Eigen
      Revert "COMP: Ensure proxTV dependencies are found when building against ITK build tree"
      COMP: CMake: Install proxTV in ITK standard folders
      DOC: Remove TODOs in Readme
      DOC: Update readme, remove duplicated license
```

--- Modules/Remote/TotalVariation.remote.cmake
+++ Modules/Remote/TotalVariation.remote.cmake
@@ -7,5 +7,5 @@
 https://github.com/albarji/proxTV
 "
   GIT_REPOSITORY ${git_protocol}://github.com/InsightSoftwareConsortium/ITKTotalVariation.git
-  GIT_TAG fbab387c7c93bb58036d3e3d46bc34e7801a19dd
+  GIT_TAG e47fb5b1e2eef32cddb131d8ba47b78dbde9fbbd
 )


Delete SpinWaveGenie.cmake

Delete SpinWaveGenie.cmake

using appveyor.cmake instead. [ci skip]

--- SpinWaveGenie.cmake
+++ SpinWaveGenie.cmake
@@ -1,6 +0,0 @@
-set(BUILD_DIR C:/Users/Steve/Desktop/LibrariesThirdPartyVC120 CACHE PATH "")
-set(Boost_INCLUDE_DIR ${BUILD_DIR}/include CACHE PATH "")
-set(Boost_LIBRARY_DIR ${BUILD_DIR}/lib CACHE PATH "")
-set(EIGEN3_INCLUDE_DIR ${BUILD_DIR}/include CACHE PATH "")
-set(USE_THREADS OFF)
-#set(TBB_INSTALL_DIR ${}BUILD_DIR} CACHE PATH "")


Updated FindMatlab to recognize the newest MATLAB release.

--- tools/FindMatlab.cmake
+++ tools/FindMatlab.cmake
@@ -249,6 +249,7 @@
 endif()

 set(MATLAB_VERSIONS_MAPPING
+    "R2022a=9.12"
     "R2021b=9.11"
     "R2021a=9.10"
     "R2020b=9.9"


Remove Helpers.h headers from framework headers

--- toolchains/iOS.framework.cmake
+++ toolchains/iOS.framework.cmake
@@ -47,7 +47,6 @@

 set(FRAMEWORK_HEADERS
     ${PROJECT_SOURCE_DIR}/ios/framework/TangramMap.h
-    ${PROJECT_SOURCE_DIR}/ios/src/Helpers.h
     ${PROJECT_SOURCE_DIR}/ios/src/TGGeoPolyline.h
     ${PROJECT_SOURCE_DIR}/ios/src/TGGeoPolygon.h
     ${PROJECT_SOURCE_DIR}/ios/src/TGGeoPoint.h
@@ -55,6 +54,7 @@

 set(HEADERS
     ${PROJECT_SOURCE_DIR}/ios/src/platform_ios.h
+    ${PROJECT_SOURCE_DIR}/ios/src/Helpers.h
     ${FRAMEWORK_HEADERS})

 add_bundle_resources(RESOURCES "${PROJECT_SOURCE_DIR}/scenes/fonts" "./fonts")


CI: replace warning by send_error if tests are failing

--- CI/main_superbuild.cmake
+++ CI/main_superbuild.cmake
@@ -208,7 +208,7 @@
   "${OTB_SOURCE_DIR}/log/test_cmake_error_log.txt" "${_test_error}")

 if ( NOT _test_rv EQUAL 0 )
-  message( WARNING "Some tests have failed.")
+  message( SEND_ERROR "Some tests have failed.")
 endif()

 ctest_submit()


Fix CMake problem that could cause errors and configuration to stop if boost was not found.

--HG--
branch : v1-9

--- CMake/Dependencies.cmake
+++ CMake/Dependencies.cmake
@@ -170,7 +170,9 @@
     find_package(Boost COMPONENTS ${OGRE_BOOST_COMPONENTS} QUIET)
 endif()

-list(REMOVE_DUPLICATES Boost_LIBRARIES)
+if(Boost_FOUND)
+  list(REMOVE_DUPLICATES Boost_LIBRARIES)
+endif()

 # Optional Boost libs (Boost_${COMPONENT}_FOUND
 macro_log_feature(Boost_FOUND "boost" "Boost (general)" "http://boost.org" FALSE "" "")


Set BUILD_CMOCK as CACHE variable

Set BUILD_CMOCK as CACHE variable

This addresses a CMP0077 warning.

--- CMake/sitkUseGTest.cmake
+++ CMake/sitkUseGTest.cmake
@@ -31,8 +31,8 @@
   set(CMAKE_CXX_VISIBILITY_PRESET)
   set(CMAKE_VISIBILITY_INLINES_HIDDEN)

-  set(BUILD_GTEST                 ON )
-  set(BUILD_GMOCK                 OFF)
+  set(BUILD_GTEST ON CACHE INTERNAL "" FORCE )
+  set(BUILD_GMOCK OFF CACHE INTERNAL "" FORCE )

   # google test does not properly use pthreads on mingw


modules: updated FindSDL2.cmake from Magnum repository.

--- modules/FindSDL2.cmake
+++ modules/FindSDL2.cmake
@@ -35,11 +35,12 @@
 # In Emscripten SDL is linked automatically, thus no need to find the library.
 # Also the includes are in SDL subdirectory, not SDL2.
 if(CORRADE_TARGET_EMSCRIPTEN)
-    set(PATH_SUFFIXES SDL)
+    set(_SDL2_PATH_SUFFIXES SDL)
 else()
-    find_library(SDL2_LIBRARY SDL2)
+    find_library(SDL2_LIBRARY SDL2
+        PATH_SUFFIXES lib/x86 lib/x64)
     set(SDL2_LIBRARY_NEEDED SDL2_LIBRARY)
-    set(PATH_SUFFIXES SDL2)
+    set(_SDL2_PATH_SUFFIXES SDL2)
 endif()

 # Include dir
@@ -52,11 +53,9 @@
     # this issue), but rather SDL2.framework/Headers/SDL.h, CMake might find
     # SDL.framework/Headers/SDL.h if SDL1 is installed, which is wrong.
     NAMES SDL_scancode.h
-    PATH_SUFFIXES ${PATH_SUFFIXES}
-)
+    PATH_SUFFIXES ${_SDL2_PATH_SUFFIXES})

 include(FindPackageHandleStandardArgs)
 find_package_handle_standard_args("SDL2" DEFAULT_MSG
     ${SDL2_LIBRARY_NEEDED}
-    SDL2_INCLUDE_DIR
-)
+    SDL2_INCLUDE_DIR)


Bugfix: CMake: Remove leftover code. We are able to find muparser externally :-]

git-svn-id: 31d9d2f6432a47c86a3640814024c107794ea77c@32598 0785d39b-7218-0410-832d-ea1e28bc413d

--- deal.II/cmake/configure/configure_muparser.cmake
+++ deal.II/cmake/configure/configure_muparser.cmake
@@ -18,24 +18,8 @@
 # Configuration for the MUPARSER library:
 #

-MACRO(FEATURE_MUPARSER_FIND_EXTERNAL var)
-  MESSAGE(STATUS
-    "No module available for finding functionparser externally."
-    )
-ENDMACRO()
-
-
 MACRO(FEATURE_MUPARSER_CONFIGURE_BUNDLED)
   SET(MUPARSER_BUNDLED_INCLUDE_DIRS ${MUPARSER_FOLDER}/include)
 ENDMACRO()

-
-MACRO(FEATURE_MUPARSER_ERROR_MESSAGE)
-  MESSAGE(FATAL_ERROR "\n"
-    "No module available for finding functionparser externally.\n"
-    "Disable DEAL_II_WITH_MUPARSER, or enable DEAL_II_ALLOW_BUNDLED.\n\n"
-    )
-ENDMACRO()
-
-
 CONFIGURE_FEATURE(MUPARSER)


update cmake/FindGLIB.cmake

update cmake/FindGLIB.cmake


Yet another default UFID fix. (#96)

Yet another default UFID fix. (#96)

--- cmake/bde_ufid.cmake
+++ cmake/bde_ufid.cmake
@@ -608,20 +608,16 @@
     if(NOT UFID)
         if(CMAKE_BUILD_TYPE)
             if(CMAKE_BUILD_TYPE STREQUAL "Release")
-                message(STATUS  "Setting 'Release' to UFID to 'opt_exc_mt'.")
                 set(defUFID "opt_exc_mt")
             endif()
             if(CMAKE_BUILD_TYPE STREQUAL "RelWithDebInfo")
-                message(STATUS  "Setting 'RelWithDebInfo' to UFID to 'opt_dbg_exc_mt'.")
                 set(defUFID "opt_dbg_exc_mt")
             endif()
             if(CMAKE_BUILD_TYPE STREQUAL "Debug")
-                message(STATUS  "Setting 'Debug' to UFID to 'dbg_exc_mt'.")
                 set(defUFID "dbg_exc_mt")
             endif()
         else()
             message(WARNING "Nor CMAKE_BUILD_TYPE nor UFID is defined.")
-            message(STATUS  "Setting default UFID to 'opt_exc_mt'.")
             set(defUFID "opt_exc_mt")
         endif()
         if(BUILD_BITNESS)
@@ -629,6 +625,7 @@
                 STRING(APPEND defUFID "_64")
             endif()
         endif()
+        message(STATUS "Setting UFID to ${defUFID}.")
         set(UFID ${defUFID} CACHE STRING "UFID for the project")
     endif()


Fixed build

Fixed build

--- src/cmake/core.cmake
+++ src/cmake/core.cmake
@@ -17,6 +17,11 @@
     core/basetypes/MCObjectMac.mm
     core/basetypes/MCDataMac.mm
     core/rfc822/MCMessageParserMac.mm
+  )
+
+  set(core_includes_apple
+    "${CMAKE_CURRENT_SOURCE_DIR}/core/basetypes/icu-ucsdet"
+    "${CMAKE_CURRENT_SOURCE_DIR}/core/basetypes/icu-ucsdet/include"
   )
 ENDIF()

@@ -168,10 +173,7 @@
   "${CMAKE_CURRENT_SOURCE_DIR}/core"
   "${CMAKE_CURRENT_SOURCE_DIR}/core/abstract"
   "${CMAKE_CURRENT_SOURCE_DIR}/core/basetypes"
-IF(APPLE)
-  "${CMAKE_CURRENT_SOURCE_DIR}/core/basetypes/icu-ucsdet"
-  "${CMAKE_CURRENT_SOURCE_DIR}/core/basetypes/icu-ucsdet/include"
-ENDIF()
+  ${core_includes_apple}
   "${CMAKE_CURRENT_SOURCE_DIR}/core/imap"
   "${CMAKE_CURRENT_SOURCE_DIR}/core/pop"
   "${CMAKE_CURRENT_SOURCE_DIR}/core/nntp"


COMP: on some systems, MITK_Poco_Config.cmake was not found. Adapting CMAKE_MODULE_PATH.

--- CMake/MITK_Poco_Config.cmake
+++ CMake/MITK_Poco_Config.cmake
@@ -1,5 +1,4 @@
-SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${PROJECT_SOURCE_DIR}/BlueBerry/CMake)
-SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${PROJECT_SOURCE_DIR}/mitk/BlueBerry/CMake)
+SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${MITK_SOURCE_DIR}/BlueBerry/CMake)
 FIND_PACKAGE(Poco)
 LIST(APPEND ALL_INCLUDE_DIRECTORIES ${Poco_INCLUDE_DIRS})
 LIST(APPEND ALL_LIBRARIES optimized PocoFoundation


fix: FindTBB for "Visual Studio 15 2017" generator

--- CMake/Modules/FindTBB.cmake
+++ CMake/Modules/FindTBB.cmake
@@ -230,6 +230,9 @@

 if (WIN32 AND MSVC AND CMAKE_GENERATOR MATCHES "Visual Studio ([0-9]+)")
   set(_TBB_MSVS_VERSION ${CMAKE_MATCH_1})
+  if (_TBB_MSVS_VERSION EQUAL 15)
+    set(_TBB_MSVS_VERSION 14)
+  endif ()
   if (CMAKE_CL_64)
     list(APPEND _TBB_LIB_PATH_SUFFIXES lib/intel64/vc${_TBB_MSVS_VERSION})
     list(APPEND _TBB_LIB_PATH_SUFFIXES intel64/vc${_TBB_MSVS_VERSION}/lib)


Cmake: Bugfixes

Cmake: Bugfixes

git-svn-id: 31d9d2f6432a47c86a3640814024c107794ea77c@28883 0785d39b-7218-0410-832d-ea1e28bc413d

--- deal.II/cmake/setup_deal_ii.cmake
+++ deal.II/cmake/setup_deal_ii.cmake
@@ -83,7 +83,8 @@

 SET(DEAL_II_PROJECT_CONFIG_NAME "${DEAL_II_PACKAGE_NAME}")

-SET_IF_EMPTY(DEAL_II_BASE_NAME "deal_II")
+STRING(REPLACE "." "_" _base_name "${DEAL_II_PACKAGE_NAME}")
+SET_IF_EMPTY(DEAL_II_BASE_NAME "${_base_name}")
 SET_IF_EMPTY(DEAL_II_DEBUG_SUFFIX ".g")
 SET_IF_EMPTY(DEAL_II_RELEASE_SUFFIX "")

@@ -107,7 +108,7 @@
   #
   SET_IF_EMPTY(DEAL_II_CMAKE_MACROS_RELDIR "share/${DEAL_II_PACKAGE_NAME}/cmake/Macros")
   SET_IF_EMPTY(DEAL_II_DOCUMENTATION_RELDIR "share/doc/${DEAL_II_PACKAGE_NAME}/html")
-  SET_IF_EMPTY(DEAL_II_EXAMPLES_RELDIR "share/${DEAL_II_PACKAGE_NAME}/examples")
+  SET_IF_EMPTY(DEAL_II_EXAMPLES_RELDIR "share/doc/${DEAL_II_PACKAGE_NAME}/examples")
   SET_IF_EMPTY(DEAL_II_EXECUTABLE_RELDIR "bin")
   SET_IF_EMPTY(DEAL_II_INCLUDE_RELDIR "include")
   SET_IF_EMPTY(DEAL_II_LIBRARY_RELDIR "lib${LIB_SUFFIX}")


Increase the ament_cmake_copyright default timeout. (#355)

Add one minute so that Windows Debug won't fail as often.

Signed-off-by: Chris Lalancette <281cd07d7578d97c83271fbbf2faddb83ab3791c@openrobotics.org>

--- ament_cmake_copyright/cmake/ament_copyright.cmake
+++ ament_cmake_copyright/cmake/ament_copyright.cmake
@@ -32,7 +32,7 @@
     set(ARG_TESTNAME "copyright")
   endif()
   if(NOT ARG_TIMEOUT)
-    set(ARG_TIMEOUT 120)
+    set(ARG_TIMEOUT 200)
   endif()

   find_program(ament_copyright_BIN NAMES "ament_copyright")


PERF: Allow overwriting ABI/Optimization & Warning flags

Provide a mechanism for changing the default warning
and ABI/OPTIMIZATION flags.

The default ABI/Optimization flag settings are
set to:
    -mtune=native # Tune the code for the computer used compile
                  # ITK, but allow running on generic cpu
                  # archetectures
    -march=corei7 # Use ABI settings to support corei7
                  # (circa 2008 ABI feature sets)

The defaults can easily be overriden from the cmake comand line with:
  -DITK_C_OPTIMIZATION_FLAGS:STRING="-march=native"
  -DITK_CXX_OPTIMIZATION_FLAGS:STRING="-march=native"
  -DITK_C_WARNING_FLAGS:STRING="-Wall -Werror"
  -DITK_CXX_WARNING_FLAGS:STRING="-Wall -Werror"

--- CMake/ITKSetStandardCompilerFlags.cmake
+++ CMake/ITKSetStandardCompilerFlags.cmake
@@ -26,7 +26,7 @@
   check_pie_supported()
 endif()

-function(check_c_compiler_warning_flags c_flag_var)
+function(check_c_compiler_flags c_flag_var)
   set(local_c_flags "")
   set(flag_list "${ARGN}")
   foreach(flag IN LISTS flag_list)
@@ -40,7 +40,7 @@
 endfunction()

-function(check_cxx_compiler_warning_flags cxx_flag_var)
+function(check_cxx_compiler_flags cxx_flag_var)
   set(local_cxx_flags "")
   set(flag_list "${ARGN}")
   foreach(flag IN LISTS flag_list)
@@ -130,11 +130,56 @@
     ## Clang compiler likes to warn about this feature that is technically only in
     ## c++0x, but works on many compilers, and if it fails, then alternate methods are used

-  check_c_compiler_warning_flags(CMAKE_C_WARNING_FLAGS ${c_flags} ${c_and_cxx_flags})
-  check_cxx_compiler_warning_flags(CMAKE_CXX_WARNING_FLAGS ${c_and_cxx_flags} ${cxx_flags})
+  check_c_compiler_flags(CMAKE_C_WARNING_FLAGS ${c_flags} ${c_and_cxx_flags})
+  check_cxx_compiler_flags(CMAKE_CXX_WARNING_FLAGS ${c_and_cxx_flags} ${cxx_flags})

   set(${c_warning_flags_var} "${CMAKE_C_WARNING_FLAGS}" PARENT_SCOPE)
   set(${cxx_warning_flags_var} "${CMAKE_CXX_WARNING_FLAGS}" PARENT_SCOPE)
+endfunction()
+
+
+function(check_compiler_optimization_flags c_optimization_flags_var cxx_optimization_flags_var)
+  set(${c_optimization_flags_var} "" PARENT_SCOPE)
+  set(${cxx_optimization_flags_var} "" PARENT_SCOPE)
+
+  if(MSVC)
+      set(InstructionSetOptimizationFlags
+         # https://docs.microsoft.com/en-us/cpp/build/reference/arch-x64?view=vs-2015
+         /arch:SSE /arch:SSE2 /arch:/AVX ) # /arch:/AVX2 AVX2 circa 2013
+  else()
+    if (${CMAKE_C_COMPILER} MATCHES "icc.*$")
+      set(USING_INTEL_ICC_COMPILER TRUE)
+    endif()
+    if (${CMAKE_CXX_COMPILER} MATCHES "icpc.*$")
+      set(USING_INTEL_ICC_COMPILER TRUE)
+    endif()
+    if(USING_INTEL_ICC_COMPILER)
+      set(InstructionSetOptimizationFlags "" )
+    else()
+      set(InstructionSetOptimizationFlags "")
+    endif ()
+
+    # Check this list on C compiler only
+    set(c_flags "")
+
+    # Check this list on C++ compiler only
+    set(cxx_flags "")
+
+    # Check this list on both C and C++ compilers
+    set(InstructionSetOptimizationFlags
+       # https://gcc.gnu.org/onlinedocs/gcc-4.8.0/gcc/i386-and-x86_002d64-Options.html
+       # NOTE the corei7 release date was 2008
+       -mtune=native # Tune the code for the computer used compile ITK, but allow running on generic cpu archetectures
+       -march=corei7 # Use ABI settings to support corei7 (circa 2008 ABI feature sets, core-avx circa 2013)
+       )
+  endif()
+  set(c_and_cxx_flags ${InstructionSetOptimizationFlags})
+
+  check_c_compiler_flags(    CMAKE_C_WARNING_FLAGS ${c_and_cxx_flags} ${c_flags})
+  check_cxx_compiler_flags(CMAKE_CXX_WARNING_FLAGS ${c_and_cxx_flags} ${cxx_flags})
+
+  set(${c_optimization_flags_var} "${CMAKE_C_WARNING_FLAGS}" PARENT_SCOPE)
+  set(${cxx_optimization_flags_var} "${CMAKE_CXX_WARNING_FLAGS}" PARENT_SCOPE)
 endfunction()

@@ -304,16 +349,60 @@
   endif()
 endmacro()#End the platform check function

+if(NOT ITK_C_WARNING_FLAGS OR NOT ITK_CXX_WARNING_FLAGS ) # Only check once if not explicitly set on command line
+  #-----------------------------------------------------------------------------
+  #Check the set of warning flags the compiler supports
+  check_compiler_warning_flags(C_WARNING_FLAGS CXX_WARNING_FLAGS)
+endif()
+
+if(NOT ITK_C_WARNING_FLAGS) #Not set on cmake command line option -DITK_C_WARNING_FLAGS:STRING=""
+  set(ITK_C_WARNING_FLAGS ${C_WARNING_FLAGS})
+endif()
+set(ITK_C_WARNING_FLAGS ${ITK_C_WARNING_FLAGS} CACHE STRING "ITK C compiler warning flags. Modify to suit your needs.")
+
+if(NOT ITK_CXX_WARNING_FLAGS) #Not set on cmake command line option -DITK_CXX_WARNING_FLAGS:STRING=""
+  set(ITK_CXX_WARNING_FLAGS ${CXX_WARNING_FLAGS})
+endif()
+set(ITK_CXX_WARNING_FLAGS ${ITK_CXX_WARNING_FLAGS} CACHE STRING "ITK CXX compiler warning flags. Modify to suit your needs.")
+
+mark_as_advanced(ITK_CXX_WARNING_FLAGS)
+mark_as_advanced(ITK_C_WARNING_FLAGS)
+unset(C_WARNING_FLAGS)
+unset(CXX_WARNING_FLAGS)
+
+
+if(NOT ITK_C_OPTIMIZATION_FLAGS OR NOT ITK_CXX_OPTIMIZATION_FLAGS ) # Only check once if not explicitly set on command line
+  #-----------------------------------------------------------------------------
+  #Check the set of warning flags the compiler supports
+  check_compiler_optimization_flags(C_OPTIMIZATION_FLAGS CXX_OPTIMIZATION_FLAGS)
+endif()
+if(NOT ITK_C_OPTIMIZATION_FLAGS) #Not set on cmake command line option -DITK_C_OPTIMIZATION_FLAGS:STRING=""
+  set(ITK_C_OPTIMIZATION_FLAGS ${C_OPTIMIZATION_FLAGS} CACHE STRING "ITK C Compiler ABI/Optimization flags, Use '-march=native' to maximize performance, but break portabilitly.")
+else()
+  set(ITK_C_OPTIMIZATION_FLAGS ${ITK_C_OPTIMIZATION_FLAGS} CACHE STRING "ITK C Compiler ABI/Optimization flags, Use '-march=native' to maximize performance, but break portabilitly.")
+endif()
+if(NOT ITK_CXX_OPTIMIZATION_FLAGS) #Not set on cmake command line option -DITK_CXX_OPTIMIZATION_FLAGS:STRING=""
+  set(ITK_CXX_OPTIMIZATION_FLAGS ${CXX_OPTIMIZATION_FLAGS} CACHE STRING "ITK CXX Compiler ABI/Optimization flags, Use '-march=native' to maximize performance, but break portabilitly.")
+else()
+  set(ITK_CXX_OPTIMIZATION_FLAGS ${ITK_CXX_OPTIMIZATION_FLAGS} CACHE STRING "ITK CXX Compiler ABI/Optimization flags, Use '-march=native' to maximize performance, but break portabilitly.")
+endif()
+mark_as_advanced(ITK_CXX_OPTIMIZATION_FLAGS)
+mark_as_advanced(ITK_C_OPTIMIZATION_FLAGS)
+unset(C_OPTIMIZATION_FLAGS)
+unset(CXX_OPTIMIZATION_FLAGS)
+
 #-----------------------------------------------------------------------------
-#Check the set of warning flags the compiler supports
-check_compiler_warning_flags(C_WARNING_FLAGS CXX_WARNING_FLAGS)
+#Check the set of platform flags the compiler supports
+check_compiler_platform_flags()

 # Append ITK warnings to the CMake flags.
 # We do not set them in ITK_REQUIRED FLAGS because all project which
 # use ITK don't require these flags .
-set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${C_WARNING_FLAGS}")
-set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CXX_WARNING_FLAGS}")
-
-#-----------------------------------------------------------------------------
-#Check the set of platform flags the compiler supports
-check_compiler_platform_flags()
+
+string(REPLACE " " ";" CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${ITK_C_OPTIMIZATION_FLAGS} ${ITK_C_WARNING_FLAGS}")
+list(REMOVE_DUPLICATES CMAKE_C_FLAGS)
+string(REPLACE ";" " " CMAKE_C_FLAGS "${CMAKE_C_FLAGS}")
+
+string(REPLACE " " ";" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${ITK_CXX_OPTIMIZATION_FLAGS} ${ITK_CXX_WARNING_FLAGS}")
+list(REMOVE_DUPLICATES CMAKE_CXX_FLAGS)
+string(REPLACE ";" " " CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")


Fix python code in cmake quoting issue reported by Hans Johnson

http://slicer-devel.65872.n3.nabble.com/CTK-CMake-warning-tt4030604.html

--- CMake/ctkMacroCompilePythonScript.cmake
+++ CMake/ctkMacroCompilePythonScript.cmake
@@ -223,7 +223,7 @@
                 print err.msg
                 success = 0
             except IOError, e:
-                print "Sorry", e
+                print 'Sorry', e
                 success = 0
             else:
                 if ok == 0:


ENH: Update ExternalProjectDependency system based on commontk/Artichoke@0cc99d3

List of changes:

$ git shortlog 9c98004..0cc99d3 --no-merges
Jean-Christophe Fillion-Robin (4):
      Add test checking that variable ending with "-NOTFOUND" are passed
      test: Remove unused debug statement, initalize variable
      ExternalProjectDependency: Support ALL_PROJECTS variable ending with NOTFOUND
      Add MarkAsSuperBuild-EP_ARGS_VAR test

--- CMake/ctkMacroCheckExternalProjectDependency.cmake
+++ CMake/ctkMacroCheckExternalProjectDependency.cmake
@@ -458,7 +458,8 @@
     get_property(${proj}_EP_PROPERTY_${property} GLOBAL PROPERTY ${proj}_EP_PROPERTY_${property})
     get_property(${_ALL_PROJECT_IDENTIFIER}_EP_PROPERTY_${property} GLOBAL PROPERTY ${_ALL_PROJECT_IDENTIFIER}_EP_PROPERTY_${property})
     set(_all ${${proj}_EP_PROPERTY_${property}} ${${_ALL_PROJECT_IDENTIFIER}_EP_PROPERTY_${property}})
-    if(_all)
+    list(LENGTH _all _num_properties)
+    if(_num_properties GREATER 0)
       list(APPEND _ep_arguments ${property} ${_all})
     endif()
   endforeach()


FIX (#1201): Qmitk.dll installation

FIX (#1201): Qmitk.dll installation

--- CMake/CoreHelpers.cmake
+++ CMake/CoreHelpers.cmake
@@ -47,7 +47,7 @@
   ADD_LIBRARY(Qmitk${LIBPOSTFIX} ${ARGV0} ${CPP_FILES} ${Q${KITNAME}_GENERATED_CPP})
   TARGET_LINK_LIBRARIES(Qmitk${LIBPOSTFIX} ${QT_LIBRARIES} ${${KITNAME}_CORE_LIBRARIES})
   IF(ARGV0 STREQUAL "SHARED")
-      INSTALL(TARGETS ${FUNC_NAME}
+      INSTALL(TARGETS Qmitk${LIBPOSTFIX}
           RUNTIME DESTINATION bin
           LIBRARY DESTINATION lib
           ARCHIVE DESTINATION lib/static


FindPystring: Also find a static pystring lib (#1449)

Signed-off-by: Leander Schulten <29a09892a606f544fce73d6c9c37a7e541407d2b@rwth-aachen.de>

Co-authored-by: Patrick Hodoul <7057c3cd2372738fdbcbbd3cdc93319520f6bd11@autodesk.com>

--- share/cmake/modules/Findpystring.cmake
+++ share/cmake/modules/Findpystring.cmake
@@ -10,10 +10,6 @@
 #
 # Targets defined by this module:
 #   pystring::pystring - IMPORTED target, if found
-#
-# By default, the dynamic libraries of pystring will be found. To find the
-# static ones instead, you must set the pystring_STATIC_LIBRARY variable to
-# TRUE before calling find_package(pystring ...).
 #
 # If pystring is not installed in a standard path, you can use the
 # pystring_ROOT variable to tell CMake where to find it. If it is not found
@@ -41,16 +37,10 @@
             pystring/include
     )

-    # Attempt to find static library first if this is set
-    if(pystring_STATIC_LIBRARY)
-        set(_pystring_STATIC
-            "${CMAKE_STATIC_LIBRARY_PREFIX}pystring${CMAKE_STATIC_LIBRARY_SUFFIX}")
-    endif()
-
     # Find library
     find_library(pystring_LIBRARY
         NAMES
-            ${_pystring_STATIC} pystring
+            pystring libpystring
         HINTS
             ${_pystring_SEARCH_DIRS}
         PATH_SUFFIXES


Added description to the msi AAF component

--- Installer/CPackConfig.cmake
+++ Installer/CPackConfig.cmake
@@ -101,3 +101,8 @@
     DISPLAY_NAME "Final Cut Pro XML"
     DESCRIPTION "Final Cut Pro XML Interchange Format"
 )
+
+cpack_add_component(Aaf
+    DISPLAY_NAME "AAF"
+    DESCRIPTION "Advanced Authoring Format"
+)


Remove unused

Remove unused

--- scripts/sleep.cmake
+++ scripts/sleep.cmake
@@ -1,10 +0,0 @@
-# Cross-platform sleep
-# http://public.kitware.com/Bug/print_bug_page.php?bug_id=14484
-
-if(NOT DEFINED seconds)
-  set(seconds 1)
-endif()
-
-set(CTEST_RUN_CURRENT_SCRIPT 0)
-
-ctest_sleep(${seconds})