adapted ClangTools.cmake

adapted ClangTools.cmake

--- cmake/ClangTools.cmake
+++ cmake/ClangTools.cmake
@@ -24,15 +24,30 @@
   add_custom_target(tidy
     COMMAND ${CLANG_TIDY_PROG} -p=${CMAKE_BINARY_DIR} ${SOURCES}
     WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/..
-    DEPENDS simple_viz_node
+    DEPENDS franka_hw_node
     COMMENT "Running clang-tidy"
     VERBATIM
   )
   add_custom_target(check-tidy
     COMMAND scripts/fail-on-output.sh ${CLANG_TIDY_PROG} -p=${CMAKE_BINARY_DIR} ${SOURCES}
     WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/..
-    DEPENDS simple_viz_node
+    DEPENDS franka_hw_node
     COMMENT "Running clang-tidy"
     VERBATIM
   )
+  add_custom_target(tidy
+    COMMAND ${CLANG_TIDY_PROG} -p=${CMAKE_BINARY_DIR} ${SOURCES}
+    WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/..
+    DEPENDS franka_joint_state_publisher
+    COMMENT "Running clang-tidy"
+    VERBATIM
+  )
+  add_custom_target(check-tidy
+    COMMAND scripts/fail-on-output.sh ${CLANG_TIDY_PROG} -p=${CMAKE_BINARY_DIR} ${SOURCES}
+    WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/..
+    DEPENDS franka_joint_state_publisher
+    COMMENT "Running clang-tidy"
+    VERBATIM
+  )
+
 endif()


Search for correct FMI Library name on Windows

--- cmake/FindFMILIB.cmake
+++ cmake/FindFMILIB.cmake
@@ -52,9 +52,12 @@
 # Find shared/import library and append its path prefix to the HINTS option.
 if (UNIX)
     set (CMAKE_FIND_LIBRARY_SUFFIXES ".so")
+    set (_FMILIB_shlibs "fmilib_shared" "fmilib2" "fmilib")
+else ()
+    set (_FMILIB_shlibs "fmilib_shared")
 endif ()
 find_library (FMILIB_SHARED_LIBRARY
-    NAMES "fmilib2" "fmilib"
+    NAMES ${_FMILIB_shlibs}
     ${_FMILIB_hints}
     PATHS ${FMILIB_DIR} $ENV{FMILIB_DIR}
     PATH_SUFFIXES "lib")


--- cmake/FindWebRTC.cmake
+++ cmake/FindWebRTC.cmake
@@ -166,8 +166,11 @@
     list(APPEND WEBRTC_INCLUDE_DIRS ${WEBRTC_INCLUDE_DIR} ${WEBRTC_INCLUDE_DIR}/third_party/boringssl/src/include)
   endif()

-  # include(${CMAKE_ROOT}/Modules/SelectLibraryConfigurations.cmake)
-  # select_library_configurations(WEBRTC)
+  # workaround for fixing error WEBRTC_LIBRARY-NOTFOUND
+  set(WEBRTC_LIBRARY_RELEASE ${WEBRTC_LIBRARIES_RELEASE})
+  set(WEBRTC_LIBRARY_DEBUG ${WEBRTC_LIBRARIES_DEBUG})
+  include(${CMAKE_ROOT}/Modules/SelectLibraryConfigurations.cmake)
+  select_library_configurations(WEBRTC)

   # message("WEBRTC_LIBRARIES_DEBUG: ${WEBRTC_LIBRARIES_DEBUG}")
   # message("WEBRTC_LIBRARIES_RELEASE: ${WEBRTC_LIBRARIES_RELEASE}")


cmake: fix zephyr_get_system_include_directories_for_lang() function

This commit fixes the zephyr_get_system_include_directories_for_lang()
function in the event that no system include directories are specified
for Zephyr interface.

This fixes an issue where the value returned by this function is
`-isystem` with no directory.

Signed-off-by: Torsten Rasmussen <a7c5b1d5a1f41fce6edfa3f7c2392ae0c59deafe@nordicsemi.no>

--- cmake/extensions.cmake
+++ cmake/extensions.cmake
@@ -217,7 +217,7 @@

   process_flags(${lang} flags output_list)
   string(REPLACE ";" "$<SEMICOLON>" genexp_output_list "${output_list}")
-  set(result_output_list "-isystem$<JOIN:${genexp_output_list}, -isystem>")
+  set(result_output_list "$<$<BOOL:${genexp_output_list}>:-isystem$<JOIN:${genexp_output_list}, -isystem>>")

   set(${i} ${result_output_list} PARENT_SCOPE)
 endfunction()


[axl_cmake] typo fix in import_lua.cmake

--- cmake/import_lua.cmake
+++ cmake/import_lua.cmake
@@ -30,7 +30,7 @@
 endif ()

 if (NOT LUA_LIB_DIR)
-	if (NOT_LUA_LIB_NAME)
+	if (NOT LUA_LIB_NAME)
 		axl_find_lib_dir_ex (
 			RESULT_LIB_DIR LUA_LIB_DIR
 			RESULT_LIB_NAME LUA_LIB_NAME


Also allow gcc 34

Also allow gcc 34

--- cmake/nvcc-check.cmake
+++ cmake/nvcc-check.cmake
@@ -1,91 +1,94 @@
-######################################################################
-# Based on a script by James Shackleford in Plastimatch.org
-# Modified by Simon Rit
-#
-# Currently, nvcc works with gcc-4.3 and gcc-4.4 for CUDA 4.x
-#
-# This script:
-#   * Checks the version of default gcc
-#   * If CUDA 4.x, we look for gcc-4.4 or gcc44
-#   * If not found or CUDA<4, we look for gcc-4.3 or gcc43 on the system
-#   * If found we tell nvcc to use it
-#   * If not found, fatal error
-######################################################################
-
-# This function searches for gcc version x.y (arguments 2 and 3 of the macro)
-# Return the result in argument 1, empty if not found
-FUNCTION(FIND_GCC GCC_PATH GCC_MAJOR GCC_MINOR)
-  # Search for gcc-x.y
-  FIND_PROGRAM(EXACT_GCC "gcc-${GCC_MAJOR}.${GCC_MINOR}")
-  IF(EXACT_GCC)
-    SET(GCC_PATH "${EXACT_GCC}" PARENT_SCOPE)
-  ELSE(EXACT_GCC)
-    # Search for gccxy
-    FIND_PROGRAM(EXACT_GCC2 "gcc${GCC_MAJOR}${GCC_MINOR}")
-    IF(EXACT_GCC2)
-      SET(GCC_PATH "${EXACT_GCC2}" PARENT_SCOPE)
-    ELSE(EXACT_GCC2)
-      # gcc-x.y not found, check default gcc
-      FIND_PROGRAM(DEFAULT_GCC gcc)
-      EXEC_PROGRAM(${DEFAULT_GCC} ARGS "-dumpversion" OUTPUT_VARIABLE GCCVER)
-
-      # Get major and minor revs
-      STRING(REGEX REPLACE "^([0-9]+)\\..*" "\\1" GCCVER_MAJOR "${GCCVER}")
-      STRING(REGEX REPLACE "^[0-9]+\\.([0-9]+).*" "\\1" GCCVER_MINOR "${GCCVER}")
-
-      # Check that adequate
-      IF("${GCCVER_MAJOR}" MATCHES "${GCC_MAJOR}" AND "${GCCVER_MINOR}" MATCHES "${GCC_MINOR}")
-        SET(GCC_PATH ${DEFAULT_GCC} PARENT_SCOPE)
-      ENDIF()
-    ENDIF(EXACT_GCC2)
-  ENDIF(EXACT_GCC)
-ENDFUNCTION(FIND_GCC)
-
-# Main code dealing with each version of cuda
-IF(CUDA_FOUND)
-  IF((CMAKE_SYSTEM_NAME MATCHES "Linux" AND CMAKE_COMPILER_IS_GNUCC) OR APPLE)
-    # Compatible gcc can be checked in host_config.h
-    SET(GCC_PATH "")
-    IF(${CUDA_VERSION} VERSION_GREATER "4.1.99")
-      FIND_GCC(GCC_PATH "4" "6")
-    ENDIF()
-    IF(NOT GCC_PATH AND ${CUDA_VERSION} VERSION_GREATER "4.0.99")
-      FIND_GCC(GCC_PATH "4" "5")
-    ENDIF()
-    IF(NOT GCC_PATH AND ${CUDA_VERSION} VERSION_GREATER "3.99")
-      FIND_GCC(GCC_PATH "4" "4")
-    ENDIF()
-    IF(NOT GCC_PATH)
-      FIND_GCC(GCC_PATH "4" "3")
-    ENDIF()
-    IF(NOT GCC_PATH)
-      FIND_GCC(GCC_PATH "4" "2")
-    ENDIF()
-
-    IF(GCC_PATH)
-      MESSAGE(STATUS "nvcc-check: Found adequate gcc (${GCC_PATH})... telling nvcc to use it!")
-      LIST(APPEND CUDA_NVCC_FLAGS --compiler-bindir ${GCC_PATH})
-    ELSE(GCC_PATH)
-      MESSAGE(FATAL_ERROR "nvcc-check: Please install adequate gcc for cuda.\nNote that gcc-4.x can be installed side-by-side with your current version of gcc.\n")
-    ENDIF(GCC_PATH)
-  ENDIF()
-
-
-  IF(CMAKE_SYSTEM_NAME MATCHES "Linux" OR CMAKE_SYSTEM_NAME MATCHES "APPLE")
-      # For CUDA 3.2: surface_functions.h does some non-compliant things...
-      #               so we tell g++ to ignore them when called via nvcc
-      #               by passing the -fpermissive flag through the nvcc
-      #               build trajectory.  Unfortunately, nvcc will also
-      #               blindly pass this flag to gcc, even though it is not
-      #               valid... resulting in TONS of warnings.  So, we go
-      #               version checking again, this time nvcc...
-      # Get the nvcc version number
-
-      # This issue seems to be only if cuda is installed in system so test CUDA_INCLUDE_DIRS
-      # (see http://nvidia.custhelp.com/app/answers/detail/a_id/2869/~/linux-based-cuda-v3.x-compiler-issue-affecting-cuda-surface-apis)
-      IF(CUDA_VERSION_MAJOR MATCHES "3" AND CUDA_VERSION_MINOR MATCHES "2" AND CUDA_INCLUDE_DIRS MATCHES "/usr/include")
-          SET (CUDA_NVCC_FLAGS ${CUDA_NVCC_FLAGS} --compiler-options='-fpermissive')
-          MESSAGE(STATUS "nvcc-check: CUDA 3.2 exception: CUDA_NVCC_FLAGS set to \"${CUDA_NVCC_FLAGS}\"")
-      ENDIF()
-  ENDIF()
-ENDIF(CUDA_FOUND)
+######################################################################
+# Based on a script by James Shackleford in Plastimatch.org
+# Modified by Simon Rit
+#
+# Currently, nvcc works with gcc-4.3 and gcc-4.4 for CUDA 4.x
+#
+# This script:
+#   * Checks the version of default gcc
+#   * If CUDA 4.x, we look for gcc-4.4 or gcc44
+#   * If not found or CUDA<4, we look for gcc-4.3 or gcc43 on the system
+#   * If found we tell nvcc to use it
+#   * If not found, fatal error
+######################################################################
+
+# This function searches for gcc version x.y (arguments 2 and 3 of the macro)
+# Return the result in argument 1, empty if not found
+FUNCTION(FIND_GCC GCC_PATH GCC_MAJOR GCC_MINOR)
+  # Search for gcc-x.y
+  FIND_PROGRAM(EXACT_GCC "gcc-${GCC_MAJOR}.${GCC_MINOR}")
+  IF(EXACT_GCC)
+    SET(GCC_PATH "${EXACT_GCC}" PARENT_SCOPE)
+  ELSE(EXACT_GCC)
+    # Search for gccxy
+    FIND_PROGRAM(EXACT_GCC2 "gcc${GCC_MAJOR}${GCC_MINOR}")
+    IF(EXACT_GCC2)
+      SET(GCC_PATH "${EXACT_GCC2}" PARENT_SCOPE)
+    ELSE(EXACT_GCC2)
+      # gcc-x.y not found, check default gcc
+      FIND_PROGRAM(DEFAULT_GCC gcc)
+      EXEC_PROGRAM(${DEFAULT_GCC} ARGS "-dumpversion" OUTPUT_VARIABLE GCCVER)
+
+      # Get major and minor revs
+      STRING(REGEX REPLACE "^([0-9]+)\\..*" "\\1" GCCVER_MAJOR "${GCCVER}")
+      STRING(REGEX REPLACE "^[0-9]+\\.([0-9]+).*" "\\1" GCCVER_MINOR "${GCCVER}")
+
+      # Check that adequate
+      IF("${GCCVER_MAJOR}" MATCHES "${GCC_MAJOR}" AND "${GCCVER_MINOR}" MATCHES "${GCC_MINOR}")
+        SET(GCC_PATH ${DEFAULT_GCC} PARENT_SCOPE)
+      ENDIF()
+    ENDIF(EXACT_GCC2)
+  ENDIF(EXACT_GCC)
+ENDFUNCTION(FIND_GCC)
+
+# Main code dealing with each version of cuda
+IF(CUDA_FOUND)
+  IF((CMAKE_SYSTEM_NAME MATCHES "Linux" AND CMAKE_COMPILER_IS_GNUCC) OR APPLE)
+    # Compatible gcc can be checked in host_config.h
+    SET(GCC_PATH "")
+    IF(${CUDA_VERSION} VERSION_GREATER "4.1.99")
+      FIND_GCC(GCC_PATH "4" "6")
+    ENDIF()
+    IF(NOT GCC_PATH AND ${CUDA_VERSION} VERSION_GREATER "4.0.99")
+      FIND_GCC(GCC_PATH "4" "5")
+    ENDIF()
+    IF(NOT GCC_PATH AND ${CUDA_VERSION} VERSION_GREATER "3.99")
+      FIND_GCC(GCC_PATH "4" "4")
+    ENDIF()
+    IF(NOT GCC_PATH)
+      FIND_GCC(GCC_PATH "4" "3")
+    ENDIF()
+    IF(NOT GCC_PATH)
+      FIND_GCC(GCC_PATH "4" "2")
+    ENDIF()
+    IF(NOT GCC_PATH)
+      FIND_GCC(GCC_PATH "3" "4")
+    ENDIF()
+
+    IF(GCC_PATH)
+      MESSAGE(STATUS "nvcc-check: Found adequate gcc (${GCC_PATH})... telling nvcc to use it!")
+      LIST(APPEND CUDA_NVCC_FLAGS --compiler-bindir ${GCC_PATH})
+    ELSE(GCC_PATH)
+      MESSAGE(FATAL_ERROR "nvcc-check: Please install adequate gcc for cuda.\nNote that gcc-4.x can be installed side-by-side with your current version of gcc.\n")
+    ENDIF(GCC_PATH)
+  ENDIF()
+
+
+  IF(CMAKE_SYSTEM_NAME MATCHES "Linux" OR CMAKE_SYSTEM_NAME MATCHES "APPLE")
+      # For CUDA 3.2: surface_functions.h does some non-compliant things...
+      #               so we tell g++ to ignore them when called via nvcc
+      #               by passing the -fpermissive flag through the nvcc
+      #               build trajectory.  Unfortunately, nvcc will also
+      #               blindly pass this flag to gcc, even though it is not
+      #               valid... resulting in TONS of warnings.  So, we go
+      #               version checking again, this time nvcc...
+      # Get the nvcc version number
+
+      # This issue seems to be only if cuda is installed in system so test CUDA_INCLUDE_DIRS
+      # (see http://nvidia.custhelp.com/app/answers/detail/a_id/2869/~/linux-based-cuda-v3.x-compiler-issue-affecting-cuda-surface-apis)
+      IF(CUDA_VERSION_MAJOR MATCHES "3" AND CUDA_VERSION_MINOR MATCHES "2" AND CUDA_INCLUDE_DIRS MATCHES "/usr/include")
+          SET (CUDA_NVCC_FLAGS ${CUDA_NVCC_FLAGS} --compiler-options='-fpermissive')
+          MESSAGE(STATUS "nvcc-check: CUDA 3.2 exception: CUDA_NVCC_FLAGS set to \"${CUDA_NVCC_FLAGS}\"")
+      ENDIF()
+  ENDIF()
+ENDIF(CUDA_FOUND)


Squashed 'cmake/' changes from d206036..e4fe921

e4fe921 improved cpp tools
d34f916 include CMakeParseArguments

git-subtree-dir: cmake
git-subtree-split: e4fe921297d8644d2bfee611adcb57daf24e53a9

--- helpers.cmake
+++ helpers.cmake
@@ -14,6 +14,7 @@
 #  along with this program.  If not, see <http://www.gnu.org/licenses/>.

 set(HELPER_MODULES_PATH ${CMAKE_CURRENT_LIST_DIR})
+include(CMakeParseArguments)

 function(set_advanced_cpp_warnings TARGET)
@@ -201,12 +202,12 @@
     ARGUMENTS -quiet SOURCEFILE -- -std=c++11 INCLUDES DEFINITIONS)
   if(TARGET ${TARGET}_clang_tidy)
     set(CPP_TARGETS ${CPP_TARGETS} ${TARGET}_clang_tidy)
-  endif()
-
-  add_on_source(${TARGET}
-    NAME ${TARGET}_clang_tidy_fix
-    COMMAND clang-tidy
-    ARGUMENTS -quiet -fix -format-style=file SOURCEFILE -- -std=c++11 INCLUDES DEFINITIONS)
+
+    add_on_source(${TARGET}
+      NAME ${TARGET}_clang_tidy_fix
+      COMMAND clang-tidy
+      ARGUMENTS -quiet -fix -format-style=file SOURCEFILE -- -std=c++11 INCLUDES DEFINITIONS)
+  endif()

   add_on_source(${TARGET}
     NAME ${TARGET}_cppcheck
@@ -219,17 +220,26 @@
   add_on_source(${TARGET}
     NAME ${TARGET}_cppclean
     COMMAND cppclean
-    ARGUMENTS INCLUDES ALL_SOURCEFILES)
-  if(TARGET ${TARGET}_cppclean)
-    set(CPP_TARGETS ${CPP_TARGETS} ${TARGET}_cppclean)
-  endif()
-
-  add_on_source(${TARGET}
-    NAME ${TARGET}_iwyu
-    COMMAND iwyu
-    ARGUMENTS -std=c++11 -I/usr/include/clang/3.8/include INCLUDES DEFINITIONS SOURCEFILE)
-  if(TARGET ${TARGET}_iwyu)
-    set(CPP_TARGETS ${CPP_TARGETS} ${TARGET}_iwyu)
+    ARGUMENTS INCLUDES SOURCEFILE)
+  #if(TARGET ${TARGET}_cppclean)
+  #  set(CPP_TARGETS ${CPP_TARGETS} ${TARGET}_cppclean)
+  #endif()
+
+  add_on_source(${TARGET}
+    NAME ${TARGET}_vera
+    COMMAND vera++
+    ARGUMENTS --warning --no-duplicate --show-rule ALL_SOURCEFILES)
+  if(TARGET ${TARGET}_vera)
+    set(CPP_TARGETS ${CPP_TARGETS} ${TARGET}_vera)
+  endif()
+
+  get_target_property(INCLUDE_DIRECTORIES ${TARGET} INCLUDE_DIRECTORIES)
+  add_on_source(${TARGET}
+    NAME ${TARGET}_flint
+    COMMAND flint++
+    ARGUMENTS -v -r ALL_SOURCEFILES ${INCLUDE_DIRECTORIES})
+  if(TARGET ${TARGET}_flint)
+    set(CPP_TARGETS ${CPP_TARGETS} ${TARGET}_flint)
   endif()

   if(CPP_TARGETS)
@@ -260,19 +270,6 @@
     find_program(HAVE_GIT git)
     mark_as_advanced(HAVE_GIT)
     if(HAVE_GIT)
-
-      #add_custom_target(${TARGET}_version ALL
-      #  DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/git_version/version.h)
-
-      #add_custom_command(
-      #  OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/git_version/version.h
-      #  COMMAND ${CMAKE_COMMAND}
-      #  -DARGS_BINARY_DIR=${CMAKE_CURRENT_BINARY_DIR}
-      #  -DARGS_DIFF_VAR=${ARGS_DIFF_VAR}
-      #  -DARGS_DPREFIX=${ARGS_DPREFIX}
-      #  -DARGS_SOURCE_DIR=${CMAKE_CURRENT_SOURCE_DIR}
-      #  -DARGS_WITH_DIFF=${ARGS_WITH_DIFF}
-      #  -P ${HELPER_MODULES_PATH}/git_version.cmake)

       add_custom_target(${TARGET}_version ALL
         COMMAND ${CMAKE_COMMAND}


fix pour le BUILDNAME.

fix pour le BUILDNAME.

--- DartConfig.cmake
+++ DartConfig.cmake
@@ -2,7 +2,7 @@
 # the specified NIGHLY_START_TIME. Time is specified in 24 hour format.
 SET (NIGHTLY_START_TIME "21:00:00 EDT")

-SET (BUILD_NAME "${CMAKE_SYSTEM}-${CMAKE_CXX_COMPILER}-${CMAKE_BUILD_TYPE}")
+SET (BUILDNAME "${BUILDNAME}_${CMAKE_BUILD_TYPE}")

 # Dart server to submit results (used by client)


BUG: Calling wrong macro

BUG: Calling wrong macro

The call to CHECK_CXX_SOURCE_COMPILES should CHECK_CXX_COMPILER_FLAG.

Change-Id: Ifddf4fe03e41b307f4f28cea785a956f49fcb350

--- CMake/ITKSetStandardCompilerFlags.cmake
+++ CMake/ITKSetStandardCompilerFlags.cmake
@@ -26,7 +26,7 @@
   set(local_c_flags "")
   set(flag_list "${ARGN}")
   foreach(flag IN LISTS flag_list)
-    CHECK_C_SOURCE_COMPILES(${flag} C_HAS_WARNING${flag})
+    CHECK_C_COMPILER_FLAG(${flag} C_HAS_WARNING${flag})
     if(${C_HAS_WARNING${flag}})
       set(local_c_flags "${local_c_flags} ${flag}")
     endif()
@@ -39,7 +39,7 @@
   set(local_cxx_flags "")
   set(flag_list "${ARGN}")
   foreach(flag IN LISTS flag_list)
-    CHECK_CXX_SOURCE_COMPILES(${flag} CXX_HAS_WARNING${flag})
+    CHECK_CXX_COMPILER_FLAG(${flag} CXX_HAS_WARNING${flag})
     if(${CXX_HAS_WARNING${flag}})
       set(local_cxx_flags "${local_cxx_flags} ${flag}")
     endif()


COMP: Work around test file too big with x64_64-w64-mingw32.

This addresses:

  /tmp/cc8u6U4H.s: Assembler messages:
  /tmp/cc8u6U4H.s: Fatal error: can't write
  Modules/Filtering/ImageFilterBase/test/CMakeFiles/ITKImageFilterBaseTestDriver.dir/itkCastImageFilterTest.cxx.obj:
  File too big

Do not try the work-around with MinGW.

Change-Id: I299c51f7b127d4f9a1485a6a0a4b65014b84dc79

--- CMake/ITKSetStandardCompilerFlags.cmake
+++ CMake/ITKSetStandardCompilerFlags.cmake
@@ -275,7 +275,7 @@
   # Set the compiler-specific flag for disabling optimization.
   if(MSVC)
     set(ITK_CXX_DISABLE_OPTIMIZATION_FLAG "/Od")
-  elseif("${CMAKE_CXX_COMPILER_ID}" MATCHES "^(GNU|Intel)$")
+  elseif("${CMAKE_CXX_COMPILER_ID}" MATCHES "^(GNU|Intel)$" AND NOT MINGW)
     set(ITK_CXX_DISABLE_OPTIMIZATION_FLAG "-O0")
   endif()
   if(DEFINED ITK_CXX_DISABLE_OPTIMIZATION_FLAG)


comment LLVM libc++ / libstdc++ GNU

comment LLVM libc++ / libstdc++ GNU

--- CMake/Mathematica/FindMathematica.cmake
+++ CMake/Mathematica/FindMathematica.cmake
@@ -1035,8 +1035,10 @@
 			if ("${Mathematica_MathLink_VERSION_MINOR}" GREATER 18)
 				# Apple MathLink API revision >= 19 has dependency on C++ standard library
 				if (Mathematica_USE_LIBCXX_LIBRARIES)
+					# LLVM libc++
 					list (APPEND ${_outLibraries} c++ )
 				else()
+					# GNU libstdc++
 					list (APPEND ${_outLibraries} stdc++ )
 				endif()
 			endif()
@@ -1048,7 +1050,7 @@
 	elseif (UNIX)
 		if (DEFINED Mathematica_MathLink_VERSION_MINOR)
 			if ("${Mathematica_MathLink_VERSION_MINOR}" GREATER 18)
-				# UNIX MathLink API revision >= 19 has dependency on libstc++
+				# UNIX MathLink API revision >= 19 has dependency on GNU libstdc++
 				list (APPEND ${_outLibraries} stdc++ )
 			endif()
 		endif()
@@ -1105,7 +1107,7 @@
 		if (CMAKE_SYSTEM_NAME STREQUAL "Linux")
 			if (DEFINED Mathematica_WSTP_VERSION_MINOR)
 				if ("${Mathematica_WSTP_VERSION_MINOR}" GREATER 18)
-					# UNIX WSTP API revision >= 19 has dependency on libstc++
+					# UNIX WSTP API revision >= 19 has dependency on GNU libstdc++
 					list (APPEND ${_outLibraries} stdc++ )
 				endif()
 			endif()
@@ -1385,7 +1387,7 @@
 		endif()
 	endif()
 	option (Mathematica_USE_LIBCXX_LIBRARIES
-		"prefer Mathematica libraries linked with libc++ to those linked with libstdc++?"
+		"prefer Mathematica libraries linked with LLVM libc++ to those linked with GNU libstdc++?"
 		${Mathematica_USE_LIBCXX_LIBRARIES_INIT})
 	if (NOT DEFINED Mathematica_DEBUG_INIT)
 		if (DEFINED Mathematica_DEBUG)


Boost 1.47 required for cmake check

Boost 1.47 required for cmake check

--- ConfigureChecks.cmake
+++ ConfigureChecks.cmake
@@ -52,8 +52,8 @@
 # set BOOST_ROOT to select a boost installation

 # This is required to enable the new version
-SET(Boost_ADDITIONAL_VERSIONS 1.40 1.40.0 1.39 1.39.0 1.38 1.38.0 1.37 1.37.0)
-FIND_PACKAGE(Boost 1.36)
+SET(Boost_ADDITIONAL_VERSIONS 1.47 1.47.0)
+FIND_PACKAGE(Boost 1.47)

 ##################################################
 # Threads


Bump to version 1.2

Bump to version 1.2

--- conf/LiboroVersion.cmake
+++ conf/LiboroVersion.cmake
@@ -3,5 +3,5 @@
 # Please do not add extra numerals in this file or change its formatting.

 SET(CPACK_PACKAGE_VERSION_MAJOR "1")
-SET(CPACK_PACKAGE_VERSION_MINOR "1")
+SET(CPACK_PACKAGE_VERSION_MINOR "2")
 SET(CPACK_PACKAGE_VERSION_PATCH "0")


No comment.

No comment.

--- frontends/CsoundAC/cmake_install.cmake
+++ frontends/CsoundAC/cmake_install.cmake
@@ -45,8 +45,8 @@
     ENDIF()
   ENDFOREACH()
   FILE(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/lib" TYPE SHARED_LIBRARY FILES
-    "/home/mkg/csound/libCsoundAC.so.6.0"
-    "/home/mkg/csound/libCsoundAC.so"
+    "/home/mkg/csound-csound6-git/libCsoundAC.so.6.0"
+    "/home/mkg/csound-csound6-git/libCsoundAC.so"
     )
   FOREACH(file
       "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/libCsoundAC.so.6.0"
@@ -70,7 +70,7 @@
          FILE "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/_CsoundAC.so"
          RPATH "")
   ENDIF()
-  FILE(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/lib" TYPE MODULE FILES "/home/mkg/csound/_CsoundAC.so")
+  FILE(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/lib" TYPE MODULE FILES "/home/mkg/csound-csound6-git/_CsoundAC.so")
   IF(EXISTS "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/_CsoundAC.so" AND
      NOT IS_SYMLINK "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/_CsoundAC.so")
     FILE(RPATH_REMOVE
@@ -82,7 +82,7 @@
 ENDIF(NOT CMAKE_INSTALL_COMPONENT OR "${CMAKE_INSTALL_COMPONENT}" STREQUAL "Unspecified")

 IF(NOT CMAKE_INSTALL_COMPONENT OR "${CMAKE_INSTALL_COMPONENT}" STREQUAL "Unspecified")
-  FILE(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/lib" TYPE FILE FILES "/home/mkg/csound/CsoundAC.py")
+  FILE(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/lib" TYPE FILE FILES "/home/mkg/csound-csound6-git/CsoundAC.py")
 ENDIF(NOT CMAKE_INSTALL_COMPONENT OR "${CMAKE_INSTALL_COMPONENT}" STREQUAL "Unspecified")

 IF(NOT CMAKE_INSTALL_COMPONENT OR "${CMAKE_INSTALL_COMPONENT}" STREQUAL "Unspecified")
@@ -92,7 +92,7 @@
          FILE "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/luaCsoundAC.so"
          RPATH "")
   ENDIF()
-  FILE(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/lib" TYPE MODULE FILES "/home/mkg/csound/luaCsoundAC.so")
+  FILE(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/lib" TYPE MODULE FILES "/home/mkg/csound-csound6-git/luaCsoundAC.so")
   IF(EXISTS "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/luaCsoundAC.so" AND
      NOT IS_SYMLINK "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/luaCsoundAC.so")
     FILE(RPATH_REMOVE


cmake: fix linker flags

cmake: fix linker flags

--- cmake/OpenCVCompilerDefenses.cmake
+++ cmake/OpenCVCompilerDefenses.cmake
@@ -74,9 +74,9 @@
   set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fPIE -pie")
 endif()

-set( CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${LINKER_DEFENSES_FLAGS_COMMON}" )
-set( CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} ${LINKER_DEFENSES_FLAGS_COMMON}" )
-set( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${LINKER_DEFENSES_FLAGS_COMMON}" )
+set( CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${OPENCV_LINKER_DEFENSES_FLAGS_COMMON}" )
+set( CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} ${OPENCV_LINKER_DEFENSES_FLAGS_COMMON}" )
+set( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${OPENCV_LINKER_DEFENSES_FLAGS_COMMON}" )

 if(CMAKE_COMPILER_IS_GNUCXX)
   foreach(flags


Remove DOS line endings from LLDBStandalone.cmake

git-svn-id: 4c4cc70b1ef44ba2b7963015e681894188cea27e@241361 91177308-0d34-0410-b5e6-96231b3b80d8

--- cmake/modules/LLDBStandalone.cmake
+++ cmake/modules/LLDBStandalone.cmake
@@ -1,87 +1,87 @@
-# If we are not building as a part of LLVM, build LLDB as an
-# standalone project, using LLVM as an external library:
-if (CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
-  project(lldb)
-  cmake_minimum_required(VERSION 2.8)
-
-  option(LLVM_INSTALL_TOOLCHAIN_ONLY "Only include toolchain files in the 'install' target." OFF)
-
-  set(LLDB_PATH_TO_LLVM_SOURCE "" CACHE PATH
-    "Path to LLVM source code. Not necessary if using an installed LLVM.")
-  set(LLDB_PATH_TO_LLVM_BUILD "" CACHE PATH
-    "Path to the directory where LLVM was built or installed.")
-
-  set(LLDB_PATH_TO_CLANG_SOURCE "" CACHE PATH
-    "Path to Clang source code. Not necessary if using an installed Clang.")
-  set(LLDB_PATH_TO_CLANG_BUILD "" CACHE PATH
-    "Path to the directory where Clang was built or installed.")
-
-  if (LLDB_PATH_TO_LLVM_SOURCE)
-    if (NOT EXISTS "${LLDB_PATH_TO_LLVM_SOURCE}/cmake/config-ix.cmake")
-      message(FATAL_ERROR "Please set LLDB_PATH_TO_LLVM_SOURCE to the root "
-              "directory of LLVM source code.")
-    else()
-      get_filename_component(LLVM_MAIN_SRC_DIR ${LLDB_PATH_TO_LLVM_SOURCE}
-                             ABSOLUTE)
-      list(APPEND CMAKE_MODULE_PATH "${LLVM_MAIN_SRC_DIR}/cmake/modules")
-    endif()
-  endif()
-
-  if (LLDB_PATH_TO_CLANG_SOURCE)
-      get_filename_component(CLANG_MAIN_SRC_DIR ${LLDB_PATH_TO_CLANG_SOURCE}
-                             ABSOLUTE)
-  endif()
-
-  list(APPEND CMAKE_MODULE_PATH "${LLDB_PATH_TO_LLVM_BUILD}/share/llvm/cmake")
-
-  get_filename_component(PATH_TO_LLVM_BUILD ${LLDB_PATH_TO_LLVM_BUILD}
-                         ABSOLUTE)
-
-  get_filename_component(PATH_TO_CLANG_BUILD ${LLDB_PATH_TO_CLANG_BUILD}
-                         ABSOLUTE)
-
-  # These variables are used by add_llvm_library.
-  set(LLVM_RUNTIME_OUTPUT_INTDIR ${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/bin)
-  set(LLVM_LIBRARY_OUTPUT_INTDIR ${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/lib${LLVM_LIBDIR_SUFFIX})
-
-  include(AddLLVM)
-  include(HandleLLVMOptions)
-
-  # Verify that we can find a Python 2 interpreter.  Python 3 is unsupported.
-  if (PYTHON_EXECUTABLE STREQUAL "")
-    set(Python_ADDITIONAL_VERSIONS 2.7 2.6 2.5)
-    include(FindPythonInterp)
-    if( NOT PYTHONINTERP_FOUND )
-      message(FATAL_ERROR
-              "Unable to find Python interpreter, required for builds and testing.
-               Please install Python or specify the PYTHON_EXECUTABLE CMake variable.")
-    endif()
-  else()
-    message("-- Found PythonInterp: ${PYTHON_EXECUTABLE}")
-  endif()
-  # Import CMake library targets from LLVM and Clang.
-  include("${LLDB_PATH_TO_LLVM_BUILD}/share/llvm/cmake/LLVMConfig.cmake")
-  include("${LLDB_PATH_TO_CLANG_BUILD}/share/clang/cmake/ClangConfig.cmake")
-
-  set(PACKAGE_VERSION "${LLVM_PACKAGE_VERSION}")
-
-  set(LLVM_MAIN_INCLUDE_DIR "${LLVM_MAIN_SRC_DIR}/include")
-  set(LLVM_BINARY_DIR ${CMAKE_BINARY_DIR})
-
-  set(CLANG_MAIN_INCLUDE_DIR "${CLANG_MAIN_SRC_DIR}/include")
-
-  set(CMAKE_INCLUDE_CURRENT_DIR ON)
-  include_directories("${PATH_TO_LLVM_BUILD}/include"
-                      "${LLVM_MAIN_INCLUDE_DIR}"
-                      "${PATH_TO_CLANG_BUILD}/include"
-                      "${CLANG_MAIN_INCLUDE_DIR}"
-                      "${CMAKE_CURRENT_SOURCE_DIR}/source")
-  link_directories("${PATH_TO_LLVM_BUILD}/lib${LLVM_LIBDIR_SUFFIX}"
-                   "${PATH_TO_CLANG_BUILD}/lib${LLVM_LIBDIR_SUFFIX}")
-
-  set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
-  set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib${LLVM_LIBDIR_SUFFIX})
-  set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib${LLVM_LIBDIR_SUFFIX})
-
-  set(LLDB_BUILT_STANDALONE 1)
-endif()
+# If we are not building as a part of LLVM, build LLDB as an
+# standalone project, using LLVM as an external library:
+if (CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
+  project(lldb)
+  cmake_minimum_required(VERSION 2.8)
+
+  option(LLVM_INSTALL_TOOLCHAIN_ONLY "Only include toolchain files in the 'install' target." OFF)
+
+  set(LLDB_PATH_TO_LLVM_SOURCE "" CACHE PATH
+    "Path to LLVM source code. Not necessary if using an installed LLVM.")
+  set(LLDB_PATH_TO_LLVM_BUILD "" CACHE PATH
+    "Path to the directory where LLVM was built or installed.")
+
+  set(LLDB_PATH_TO_CLANG_SOURCE "" CACHE PATH
+    "Path to Clang source code. Not necessary if using an installed Clang.")
+  set(LLDB_PATH_TO_CLANG_BUILD "" CACHE PATH
+    "Path to the directory where Clang was built or installed.")
+
+  if (LLDB_PATH_TO_LLVM_SOURCE)
+    if (NOT EXISTS "${LLDB_PATH_TO_LLVM_SOURCE}/cmake/config-ix.cmake")
+      message(FATAL_ERROR "Please set LLDB_PATH_TO_LLVM_SOURCE to the root "
+              "directory of LLVM source code.")
+    else()
+      get_filename_component(LLVM_MAIN_SRC_DIR ${LLDB_PATH_TO_LLVM_SOURCE}
+                             ABSOLUTE)
+      list(APPEND CMAKE_MODULE_PATH "${LLVM_MAIN_SRC_DIR}/cmake/modules")
+    endif()
+  endif()
+
+  if (LLDB_PATH_TO_CLANG_SOURCE)
+      get_filename_component(CLANG_MAIN_SRC_DIR ${LLDB_PATH_TO_CLANG_SOURCE}
+                             ABSOLUTE)
+  endif()
+
+  list(APPEND CMAKE_MODULE_PATH "${LLDB_PATH_TO_LLVM_BUILD}/share/llvm/cmake")
+
+  get_filename_component(PATH_TO_LLVM_BUILD ${LLDB_PATH_TO_LLVM_BUILD}
+                         ABSOLUTE)
+
+  get_filename_component(PATH_TO_CLANG_BUILD ${LLDB_PATH_TO_CLANG_BUILD}
+                         ABSOLUTE)
+
+  # These variables are used by add_llvm_library.
+  set(LLVM_RUNTIME_OUTPUT_INTDIR ${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/bin)
+  set(LLVM_LIBRARY_OUTPUT_INTDIR ${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/lib${LLVM_LIBDIR_SUFFIX})
+
+  include(AddLLVM)
+  include(HandleLLVMOptions)
+
+  # Verify that we can find a Python 2 interpreter.  Python 3 is unsupported.
+  if (PYTHON_EXECUTABLE STREQUAL "")
+    set(Python_ADDITIONAL_VERSIONS 2.7 2.6 2.5)
+    include(FindPythonInterp)
+    if( NOT PYTHONINTERP_FOUND )
+      message(FATAL_ERROR
+              "Unable to find Python interpreter, required for builds and testing.
+               Please install Python or specify the PYTHON_EXECUTABLE CMake variable.")
+    endif()
+  else()
+    message("-- Found PythonInterp: ${PYTHON_EXECUTABLE}")
+  endif()
+  # Import CMake library targets from LLVM and Clang.
+  include("${LLDB_PATH_TO_LLVM_BUILD}/share/llvm/cmake/LLVMConfig.cmake")
+  include("${LLDB_PATH_TO_CLANG_BUILD}/share/clang/cmake/ClangConfig.cmake")
+
+  set(PACKAGE_VERSION "${LLVM_PACKAGE_VERSION}")
+
+  set(LLVM_MAIN_INCLUDE_DIR "${LLVM_MAIN_SRC_DIR}/include")
+  set(LLVM_BINARY_DIR ${CMAKE_BINARY_DIR})
+
+  set(CLANG_MAIN_INCLUDE_DIR "${CLANG_MAIN_SRC_DIR}/include")
+
+  set(CMAKE_INCLUDE_CURRENT_DIR ON)
+  include_directories("${PATH_TO_LLVM_BUILD}/include"
+                      "${LLVM_MAIN_INCLUDE_DIR}"
+                      "${PATH_TO_CLANG_BUILD}/include"
+                      "${CLANG_MAIN_INCLUDE_DIR}"
+                      "${CMAKE_CURRENT_SOURCE_DIR}/source")
+  link_directories("${PATH_TO_LLVM_BUILD}/lib${LLVM_LIBDIR_SUFFIX}"
+                   "${PATH_TO_CLANG_BUILD}/lib${LLVM_LIBDIR_SUFFIX}")
+
+  set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
+  set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib${LLVM_LIBDIR_SUFFIX})
+  set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib${LLVM_LIBDIR_SUFFIX})
+
+  set(LLDB_BUILT_STANDALONE 1)
+endif()


refs #6566 Revert xz third_party patches.  Will do this on git to reduce effects on nightly tests.
svn merge -c -55449 https://svn.tokutek.com/tokudb/toku/tokudb
svn merge -c -55401 https://svn.tokutek.com/tokudb/toku/tokudb
svn merge -c -55400 https://svn.tokutek.com/tokudb/toku/tokudb

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

--- cmake_modules/TokuThirdParty.cmake
+++ cmake_modules/TokuThirdParty.cmake
@@ -46,39 +46,39 @@
   list(APPEND xz_configure_opts --enable-debug)
 endif ()

-set(XZ_SOURCE_DIR "${TokuDB_SOURCE_DIR}/third_party/xz-4.999.9beta" CACHE FILEPATH "Where to find sources for xz (lzma).")
+set(XZ_SOURCE_DIR "${TOKU_SVNROOT}/xz-4.999.9beta" CACHE FILEPATH "Where to find sources for xz (lzma).")
 if (NOT EXISTS "${XZ_SOURCE_DIR}/configure")
-    message(FATAL_ERROR "Can't find the xz sources.  Please check them out to ${XZ_SOURCE_DIR} or modify TokuDB_SOURCE_DIR (${TokuDB_SOURCE_DIR}) or XZ_SOURCE_DIR.")
+  message(FATAL_ERROR "Can't find the xz sources.  Please check them out to ${XZ_SOURCE_DIR} or modify TOKU_SVNROOT (${TOKU_SVNROOT}) or XZ_SOURCE_DIR.")
 endif ()

-FILE(GLOB XZ_ALL_FILES ${XZ_SOURCE_DIR}/*)
 if (CMAKE_GENERATOR STREQUAL Ninja)
   ## ninja doesn't understand "$(MAKE)"
-  set(SUBMAKE_COMMAND make)
+  ExternalProject_Add(build_lzma
+    PREFIX xz
+    SOURCE_DIR "${XZ_SOURCE_DIR}"
+    CONFIGURE_COMMAND
+        "${XZ_SOURCE_DIR}/configure" ${xz_configure_opts}
+        "--prefix=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/xz"
+    BUILD_COMMAND
+        make -C src/liblzma
+    INSTALL_COMMAND
+        make -C src/liblzma install
+    )
 else ()
   ## use "$(MAKE)" for submakes so they can use the jobserver, doesn't
   ## seem to break Xcode...
-  set(SUBMAKE_COMMAND $(MAKE))
-endif ()
-
-ExternalProject_Add(build_lzma
+  ExternalProject_Add(build_lzma
     PREFIX xz
-    DOWNLOAD_COMMAND
-        cp -au "${XZ_ALL_FILES}" "<SOURCE_DIR>/"
+    SOURCE_DIR "${XZ_SOURCE_DIR}"
     CONFIGURE_COMMAND
-        "<SOURCE_DIR>/configure" ${xz_configure_opts}
+        "${XZ_SOURCE_DIR}/configure" ${xz_configure_opts}
         "--prefix=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/xz"
     BUILD_COMMAND
-        ${SUBMAKE_COMMAND} -C src/liblzma
+        $(MAKE) -C src/liblzma
     INSTALL_COMMAND
-        ${SUBMAKE_COMMAND} -C src/liblzma install
-)
-FILE(GLOB_RECURSE XZ_ALL_FILES_RECURSIVE ${XZ_SOURCE_DIR}/*)
-ExternalProject_Add_Step(build_lzma reclone_src # Names of project and custom step
-    COMMENT "(re)cloning xz source..."     # Text printed when step executes
-    DEPENDERS download configure   # Steps that depend on this step
-    DEPENDS   ${XZ_ALL_FILES_RECURSIVE}   # Files on which this step depends
-)
+        $(MAKE) -C src/liblzma install
+    )
+endif ()

 set_source_files_properties(
   "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/xz/include/lzma.h"


CMake: greentea: Remove dependency on global MBED_PATH

The mbed_greentea_add_test macro required a greentea test to set an
MBED_PATH variable to the path of the mbed-os root directory, which it
attempts to add as a 'subdirectory' of the test project. We can instead
use CMake's built in CMAKE_CURRENT_LIST_DIR variable to deduce the path
to mbed-os relative to the current list file directory, removing the
need for greentea tests to set MBED_PATH.

--- tools/cmake/mbed_greentea.cmake
+++ tools/cmake/mbed_greentea.cmake
@@ -1,9 +1,9 @@
 # Copyright (c) 2020-2021 ARM Limited. All rights reserved.
 # SPDX-License-Identifier: Apache-2.0
-
 set(MBED_CONFIG_PATH ${CMAKE_CURRENT_BINARY_DIR} CACHE INTERNAL "")

 include(${CMAKE_CURRENT_LIST_DIR}/app.cmake)
+set(MBED_ROOT ${CMAKE_CURRENT_LIST_DIR}/../.. CACHE INTERNAL "")

 # CMake Macro for generalizing CMake configuration across the greentea test suite with configurable parameters
 # Macro args:
@@ -34,8 +34,7 @@
         "${multipleValueArgs}"
         ${ARGN}
     )
-
-    add_subdirectory(${MBED_PATH} build)
+    add_subdirectory(${MBED_ROOT} build)

     add_executable(${MBED_GREENTEA_TEST_NAME})


ENH: Update elastix to revision 5219

ENH: Update elastix to revision 5219

Revision 5211 wouldn’t compile on OS X. Updating to 5219 fixed the issue.

--- SuperBuild/External_Elastix.cmake
+++ SuperBuild/External_Elastix.cmake
@@ -2,7 +2,7 @@

 file( WRITE "${CMAKE_CURRENT_BINARY_DIR}/${proj}-build/CMakeCacheInit.txt" "${ep_common_cache}" )
 set( ELASTIX_REPOSITORY https://svn.bigr.nl/elastix/trunkpublic/ )
-set( ELASTIX_REVISION 5211 )
+set( ELASTIX_REVISION 5219 )

 ExternalProject_Add( ${proj}
   SVN_REPOSITORY ${ELASTIX_REPOSITORY}


_ALL_EXTS

_ALL_EXTS

git-svn-id: de9bbed4c30e0eb58fe8e7d66f5c80b71699a07c@1006 bf01a9d7-0df3-0310-8ad4-b1c94d9ae2d5

--- Numerics/cmake/LibraryProjectSetup.cmake
+++ Numerics/cmake/LibraryProjectSetup.cmake
@@ -31,6 +31,8 @@
   endforeach(_EXT ${${PROJECT_NAME}_SOURCE_FILE_EXTENSIONS})
   list(APPEND _ALL_EXTS *.h)
   list(APPEND _ALL_EXTS *.hpp)
+else(NOT ${PROJECT_NAME}_SOURCE_FILE_EXTENSIONS)
+  set(_ALL_EXTS ${${PROJECT_NAME}_SOURCE_FILE_EXTENSIONS})
 endif(NOT ${PROJECT_NAME}_SOURCE_FILE_EXTENSIONS)

 foreach(_DIR ${_ALL_DIRS})


upgrade expected superlu_dist version

upgrade expected superlu_dist version

--- cmake/FindPetsc.cmake
+++ cmake/FindPetsc.cmake
@@ -38,7 +38,7 @@
   mumps_common
   pord
   scalapack
-  superlu_dist_3.3
+  superlu_dist_4.1
   flapack
   fblas
   ssl


[cmake] added macro axl_replace_configuration_for_install

in install commands, configuration must be referred to as $<CONFIGURATION>

--- cmake/axl_utils.cmake
+++ cmake/axl_utils.cmake
@@ -1376,4 +1376,19 @@
 		)
 endmacro()

+macro(
+axl_replace_configuration_for_install
+	_DST_LIST
+	# ...
+	)
+
+	set(_SRC_LIST ${ARGN})
+	set(${_DST_LIST})
+
+	foreach(_SRC ${_SRC_LIST})
+		string(REPLACE "$(Configuration)" "$<CONFIGURATION>" _DST ${_SRC})
+		list(APPEND ${_DST_LIST} ${_DST})
+	endforeach()
+endmacro()
+
 #...............................................................................


Look for libsodium in ${sodium_DIR} on all platforms

--- cmake/Modules/FindSodium.cmake
+++ cmake/Modules/FindSodium.cmake
@@ -42,6 +42,8 @@
     set(sodium_USE_STATIC_LIBS_LAST ${sodium_USE_STATIC_LIBS} CACHE INTERNAL "internal change tracking variable")
 endif()

+set(sodium_DIR "$ENV{sodium_DIR}" CACHE FILEPATH "sodium install directory")
+mark_as_advanced(sodium_DIR)

 ########################################################################
 # UNIX
@@ -62,18 +64,16 @@
         HINTS ${${XPREFIX}_INCLUDE_DIRS}
     )
     find_library(sodium_LIBRARY_DEBUG NAMES ${${XPREFIX}_LIBRARIES} sodium
-        HINTS ${${XPREFIX}_LIBRARY_DIRS}
+        HINTS ${${XPREFIX}_LIBRARY_DIRS} ${sodium_DIR}
     )
     find_library(sodium_LIBRARY_RELEASE NAMES ${${XPREFIX}_LIBRARIES} sodium
-        HINTS ${${XPREFIX}_LIBRARY_DIRS}
+        HINTS ${${XPREFIX}_LIBRARY_DIRS} ${sodium_DIR}
     )

 ########################################################################
 # Windows
 elseif (WIN32)
-    set(sodium_DIR "$ENV{sodium_DIR}" CACHE FILEPATH "sodium install directory")
-    mark_as_advanced(sodium_DIR)

     find_path(sodium_INCLUDE_DIR sodium.h
         HINTS ${sodium_DIR}


Fix python install bug (site.getsitepackages failed on Vincent system)

--- cmake/PythonInstallSetup.cmake
+++ cmake/PythonInstallSetup.cmake
@@ -73,11 +73,18 @@
     set(PY_INSTALL_DIR ${CMAKE_INSTALL_PREFIX})
   else()
     # Default case : siconos_python_install=standard
-    set(PYTHON_COMMAND_GET_INSTALL_DIR
-      "import site; print(site.getsitepackages()[0])")
+    #set(PYTHON_COMMAND_GET_INSTALL_DIR
+    #  "import site; print(site.getsitepackages()[0])")
+    # --> this does not work properly: the order in resulting
+    # list depends on the OS, the python version ...
     # Set the SICONOS_PYTHON_INSTALL_DIR to the proper path
+    configure_file(fake_setup.py tmp/setup.py)
+    configure_file(fake/__init__.py tmp/fake/__init__.py)
+    configure_file(find_python_install.py tmp/find_python_install.py)
     execute_process(
-      COMMAND ${PYTHON_EXECUTABLE} -c "${PYTHON_COMMAND_GET_INSTALL_DIR}"
+      COMMAND cd ${CMAKE_CURRENT_BINARY_DIR}/tmp/
+      COMMAND ${PYTHON_EXECUTABLE} find_python_install.py
+      WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/tmp/
       OUTPUT_VARIABLE PY_INSTALL_DIR)
   endif()
   string(STRIP ${PY_INSTALL_DIR} PY_INSTALL_DIR)


cmake: search LIBSSH_INCLUDE, LIBSSH_LIBRARY paths for libssh files

The README file mentions that the path to the libssh library can
be specified by defining the LIBSSH_INCLUDE and LIBSSH_LIBRARY variables
but CMAKE wasn't searching in those paths for libssh.

Add those variables to the directory search list for libssh include and
lib files.

--- cmake/modules/FindLibSSH.cmake
+++ cmake/modules/FindLibSSH.cmake
@@ -28,6 +28,7 @@
         NAMES
           libssh/libssh.h
         PATHS
+          ${LIBSSH_INCLUDE}
           /usr/include
           /usr/local/include
           /opt/local/include
@@ -41,6 +42,7 @@
           ssh
           libssh
         PATHS
+          ${LIBSSH_LIBRARY}
           /usr/lib
           /usr/local/lib
           /opt/local/lib


[Windows] fix search of libSiconos* lib ...

--- Numerics/cmake/FindSiconosGeneric.cmake
+++ Numerics/cmake/FindSiconosGeneric.cmake
@@ -11,6 +11,17 @@
 INCLUDE(FindPackageHandleStandardArgs)

 MACRO(FIND_SICONOS_COMPONENT _project _header_file)
+
+  # We should try to use Windows-GNU to some extend ... --xhub
+  IF(CMAKE_SYSTEM_NAME MATCHES Windows)
+    if (NOT MINGW)
+      SET(CMAKE_FIND_LIBRARY_PREFIXES "lib" "" ${CMAKE_FIND_LIBRARY_PREFIXES})
+      SET(CMAKE_FIND_LIBRARY_SUFFIXES ${CMAKE_FIND_LIBRARY_SUFFIXES} ".dll.a" ".a")
+    endif()
+    SET(EXE_EXT ".exe")
+  ELSE()
+    SET(EXE_EXT)
+  ENDIF()

   IF(Siconos${_project}_LIBRARY_DIRECTORY)
     MESSAGE(STATUS "Looking for ${_project} library in ${Siconos${_project}_LIBRARY_DIRECTORY}")


Use custom targets to expand CMAKE_CFG_INTDIR in tests.

--- CMake/mitkTestProjectTemplate.cmake
+++ CMake/mitkTestProjectTemplate.cmake
@@ -19,19 +19,31 @@
       -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE}
       -DAwesomeProject_BUILD_ALL_PLUGINS:BOOL=ON
   )
+
+  add_custom_target(MITK-ProjectTemplateBuildTest
+                    ${CMAKE_COMMAND} --build ${MITK-ProjectTemplate_BINARY_DIR} --config ${CMAKE_CFG_INTDIR})

   add_test(mitkProjectTemplateBuildTest
-           ${CMAKE_COMMAND} --build ${MITK-ProjectTemplate_BINARY_DIR} --config ${CMAKE_CFG_INTDIR})
+           ${CMAKE_COMMAND} --build ${MITK_BINARY_DIR} --target MITK-ProjectTemplateBuildTest)
   set_tests_properties(mitkProjectTemplateBuildTest PROPERTIES
                        LABELS MITK)

-  if(CMAKE_CFG_INTDIR STREQUAL "." OR CMAKE_CFG_INTDIR STREQUAL "Release")
+
+  add_custom_target(MITK-ProjectTemplatePackageTest
+                    ${CMAKE_COMMAND} --build ${MITK-ProjectTemplate_BINARY_DIR}/AwesomeProject-build --target package --config ${CMAKE_CFG_INTDIR})
+
+  if(WIN32)
     # Only test packaging if build type is "Release" on Windows
+    add_test(NAME mitkProjectTemplatePackageTest CONFIGURATIONS Release
+             COMMAND ${CMAKE_COMMAND} --build ${MITK_BINARY_DIR} --target MITK-ProjectTemplatePackageTest)
+  else()
     add_test(mitkProjectTemplatePackageTest
-             ${CMAKE_COMMAND} --build ${MITK-ProjectTemplate_BINARY_DIR}/AwesomeProject-build --target package --config ${CMAKE_CFG_INTDIR})
-    set_tests_properties(mitkProjectTemplatePackageTest PROPERTIES
-                         DEPENDS mitkProjectTemplateBuildTest
-                         LABELS MITK)
+             ${CMAKE_COMMAND} --build ${MITK_BINARY_DIR} --target MITK-ProjectTemplatePackageTest)
   endif()
+
+  set_tests_properties(mitkProjectTemplatePackageTest PROPERTIES
+                       DEPENDS mitkProjectTemplateBuildTest
+                       LABELS MITK)
+

 endif()


BUG: fix external project prefix dir for patchelf

--- SuperBuild/CMake/External_pkgtools.cmake
+++ SuperBuild/CMake/External_pkgtools.cmake
@@ -28,7 +28,7 @@
   )

 ExternalProject_Add(PATCHELF
-  PREFIX "${PATCHELF_SB_PREFIX_DIR}"
+  PREFIX "${PKGTOOLS_SB_PREFIX_DIR}"
   URL "http://nixos.org/releases/patchelf/patchelf-0.9/patchelf-0.9.tar.bz2"
   URL_MD5 d02687629c7e1698a486a93a0d607947
   DOWNLOAD_DIR   ${DOWNLOAD_LOCATION}


PKG: install qt.conf as file

PKG: install qt.conf as file

--- SuperBuild/Packaging/PackageHelper.cmake
+++ SuperBuild/Packaging/PackageHelper.cmake
@@ -173,7 +173,7 @@
   # We need qt.conf on windows and linux. macx is still to be tested.
   # So just not add this without testing
   if(NOT APPLE)
-    install(PROGRAMS
+    install(FILES
       ${PACKAGE_SUPPORT_FILES_DIR}/qt.conf
       DESTINATION ${PKG_STAGE_DIR}/bin
       )


DOC: add comment about boost version in superbuild

--- Superbuild/CMake/External_boost.cmake
+++ Superbuild/CMake/External_boost.cmake
@@ -1,4 +1,10 @@
 set(proj BOOST)
+
+# Use boost 1.54. There was previously incompatibilities between boost and Qt which leads
+# to compilation errors for OTB.  We could increase boost version to last stable
+# release in future version of superbuild as we've patchedOTB code to
+# support both libraries. See the related changeset in OTB trunk:
+# http://hg.orfeo-toolbox.org/OTB/r# ev/8da67e36c78d

 if(NOT __EXTERNAL_${proj}__)
 set(__EXTERNAL_${proj}__ 1)


Fix installing .pdb files on Windows.

Fix installing .pdb files on Windows.

--HG--
branch : v1-7
extra : convert_revision : svn%3A8631bf8a-c64b-0410-883c-f3eb003322f7/branches/v1-7%401744

--- CMake/Utils/OgreConfigTargets.cmake
+++ CMake/Utils/OgreConfigTargets.cmake
@@ -191,25 +191,7 @@
 endfunction(ogre_config_lib)

 function(ogre_config_component LIBNAME)
-  ogre_config_common(${LIBNAME})
-  ogre_install_target(${LIBNAME} "" TRUE)
-
-  if (MINGW)
-	# remove lib prefix from DLL outputs
-	set_target_properties(${LIBNAME} PROPERTIES PREFIX "")
-  endif ()
-
-  if (OGRE_INSTALL_PDB)
-    # install debug pdb files
-    install(FILES ${OGRE_BINARY_DIR}/lib${OGRE_DEBUG_PATH}/${LIBNAME}_d.pdb
-	  DESTINATION bin${OGRE_DEBUG_PATH}
-	  CONFIGURATIONS Debug
-	)
-	install(FILES ${OGRE_BINARY_DIR}/lib${OGRE_RELWDBG_PATH}/${LIBNAME}.pdb
-	  DESTINATION bin${OGRE_RELWDBG_PATH}
-	  CONFIGURATIONS RelWithDebInfo
-	)
-  endif ()
+  ogre_config_lib(${LIBNAME} FALSE)
 endfunction(ogre_config_component)

@@ -296,7 +278,7 @@

 function(ogre_config_sample_exe SAMPLENAME)
   ogre_config_sample_common(${SAMPLENAME})
-  if (OGRE_INSTALL_PDB)
+  if (OGRE_INSTALL_PDB AND OGRE_INSTALL_SAMPLES)
 	  # install debug pdb files - no _d on exe
 	  install(FILES ${OGRE_BINARY_DIR}/bin${OGRE_DEBUG_PATH}/${SAMPLENAME}.pdb
 		  DESTINATION bin${OGRE_DEBUG_PATH}
@@ -311,7 +293,7 @@

 function(ogre_config_sample_lib SAMPLENAME)
   ogre_config_sample_common(${SAMPLENAME})
-  if (OGRE_INSTALL_PDB)
+  if (OGRE_INSTALL_PDB AND OGRE_INSTALL_SAMPLES)
 	  # install debug pdb files - with a _d on lib
 	  install(FILES ${OGRE_BINARY_DIR}/bin${OGRE_DEBUG_PATH}/${SAMPLENAME}_d.pdb
 		  DESTINATION bin${OGRE_DEBUG_PATH}


Don't apply visibility settings to statically built samples.  Fixes linking problems with Xcode 4 and iOS.

--- CMake/Utils/OgreConfigTargets.cmake
+++ CMake/Utils/OgreConfigTargets.cmake
@@ -293,14 +293,17 @@
       endif()
     endif(NOT OGRE_BUILD_PLATFORM_APPLE_IOS)
   endif (APPLE)
-  if (CMAKE_COMPILER_IS_GNUCXX)
-    # add GCC visibility flags to shared library build
-    set_target_properties(${SAMPLENAME} PROPERTIES COMPILE_FLAGS "${OGRE_GCC_VISIBILITY_FLAGS}")
-    set_target_properties(${SAMPLENAME} PROPERTIES XCODE_ATTRIBUTE_GCC_SYMBOLS_PRIVATE_EXTERN "${XCODE_ATTRIBUTE_GCC_SYMBOLS_PRIVATE_EXTERN}")
-    set_target_properties(${SAMPLENAME} PROPERTIES XCODE_ATTRIBUTE_GCC_INLINES_ARE_PRIVATE_EXTERN "${XCODE_ATTRIBUTE_GCC_INLINES_ARE_PRIVATE_EXTERN}")
-    # disable "lib" prefix on Unix
-    set_target_properties(${SAMPLENAME} PROPERTIES PREFIX "")
-  endif (CMAKE_COMPILER_IS_GNUCXX)
+  if (NOT OGRE_STATIC)
+    if (CMAKE_COMPILER_IS_GNUCXX)
+      # add GCC visibility flags to shared library build
+      set_target_properties(${SAMPLENAME} PROPERTIES COMPILE_FLAGS "${OGRE_GCC_VISIBILITY_FLAGS}")
+      set_target_properties(${SAMPLENAME} PROPERTIES XCODE_ATTRIBUTE_GCC_SYMBOLS_PRIVATE_EXTERN "${XCODE_ATTRIBUTE_GCC_SYMBOLS_PRIVATE_EXTERN}")
+      set_target_properties(${SAMPLENAME} PROPERTIES XCODE_ATTRIBUTE_GCC_INLINES_ARE_PRIVATE_EXTERN "${XCODE_ATTRIBUTE_GCC_INLINES_ARE_PRIVATE_EXTERN}")
+      # disable "lib" prefix on Unix
+      set_target_properties(${SAMPLENAME} PROPERTIES PREFIX "")
+    endif (CMAKE_COMPILER_IS_GNUCXX)
+  endif()
+
   if (OGRE_INSTALL_SAMPLES)
 	ogre_install_target(${SAMPLENAME} ${OGRE_SAMPLE_PATH} FALSE)
   endif()


CMake export broke install directory structures; disabled for the moment.

--HG--
branch : v1-7

--- CMake/Utils/OgreConfigTargets.cmake
+++ CMake/Utils/OgreConfigTargets.cmake
@@ -48,33 +48,35 @@
 function(ogre_install_target TARGETNAME SUFFIX EXPORT)

 	if(EXPORT)
-	  install(TARGETS ${TARGETNAME}
-		EXPORT Ogre-exports
+	  install(TARGETS ${TARGETNAME} #EXPORT Ogre-exports
 		BUNDLE DESTINATION "bin${OGRE_RELEASE_PATH}" CONFIGURATIONS Release None ""
 		RUNTIME DESTINATION "bin${OGRE_RELEASE_PATH}" CONFIGURATIONS Release None ""
 		LIBRARY DESTINATION "lib${OGRE_LIB_RELEASE_PATH}${SUFFIX}" CONFIGURATIONS Release None ""
 		ARCHIVE DESTINATION "lib${OGRE_LIB_RELEASE_PATH}${SUFFIX}" CONFIGURATIONS Release None ""
 		FRAMEWORK DESTINATION "bin${OGRE_RELEASE_PATH}" CONFIGURATIONS Release None ""
-
+      )
+	  install(TARGETS ${TARGETNAME} #EXPORT Ogre-exports
 		BUNDLE DESTINATION "bin${OGRE_RELWDBG_PATH}" CONFIGURATIONS RelWithDebInfo
 		RUNTIME DESTINATION "bin${OGRE_RELWDBG_PATH}" CONFIGURATIONS RelWithDebInfo
 		LIBRARY DESTINATION "lib${OGRE_LIB_RELWDBG_PATH}${SUFFIX}" CONFIGURATIONS RelWithDebInfo
 		ARCHIVE DESTINATION "lib${OGRE_LIB_RELWDBG_PATH}${SUFFIX}" CONFIGURATIONS RelWithDebInfo
 		FRAMEWORK DESTINATION "bin${OGRE_RELWDBG_PATH}" CONFIGURATIONS RelWithDebInfo
-
+      )
+	  install(TARGETS ${TARGETNAME} #EXPORT Ogre-exports
 		BUNDLE DESTINATION "bin${OGRE_MINSIZE_PATH}" CONFIGURATIONS MinSizeRel
 		RUNTIME DESTINATION "bin${OGRE_MINSIZE_PATH}" CONFIGURATIONS MinSizeRel
 		LIBRARY DESTINATION "lib${OGRE_LIB_MINSIZE_PATH}${SUFFIX}" CONFIGURATIONS MinSizeRel
 		ARCHIVE DESTINATION "lib${OGRE_LIB_MINSIZE_PATH}${SUFFIX}" CONFIGURATIONS MinSizeRel
 		FRAMEWORK DESTINATION "bin${OGRE_MINSIZE_PATH}" CONFIGURATIONS MinSizeRel
-
+      )
+	  install(TARGETS ${TARGETNAME} #EXPORT Ogre-exports
 		BUNDLE DESTINATION "bin${OGRE_DEBUG_PATH}" CONFIGURATIONS Debug
 		RUNTIME DESTINATION "bin${OGRE_DEBUG_PATH}" CONFIGURATIONS Debug
 		LIBRARY DESTINATION "lib${OGRE_LIB_DEBUG_PATH}${SUFFIX}" CONFIGURATIONS Debug
 		ARCHIVE DESTINATION "lib${OGRE_LIB_DEBUG_PATH}${SUFFIX}" CONFIGURATIONS Debug
 		FRAMEWORK DESTINATION "bin${OGRE_DEBUG_PATH}" CONFIGURATIONS Debug
 	  )
-	  install(EXPORT Ogre-exports DESTINATION lib)
+	  #install(EXPORT Ogre-exports DESTINATION lib)
 	else()
 	  install(TARGETS ${TARGETNAME}
 		BUNDLE DESTINATION "bin${OGRE_RELEASE_PATH}" CONFIGURATIONS Release None ""
@@ -82,19 +84,22 @@
 		LIBRARY DESTINATION "lib${OGRE_LIB_RELEASE_PATH}${SUFFIX}" CONFIGURATIONS Release None ""
 		ARCHIVE DESTINATION "lib${OGRE_LIB_RELEASE_PATH}${SUFFIX}" CONFIGURATIONS Release None ""
 		FRAMEWORK DESTINATION "bin${OGRE_RELEASE_PATH}" CONFIGURATIONS Release None ""
-
+      )
+	  install(TARGETS ${TARGETNAME}
 		BUNDLE DESTINATION "bin${OGRE_RELWDBG_PATH}" CONFIGURATIONS RelWithDebInfo
 		RUNTIME DESTINATION "bin${OGRE_RELWDBG_PATH}" CONFIGURATIONS RelWithDebInfo
 		LIBRARY DESTINATION "lib${OGRE_LIB_RELWDBG_PATH}${SUFFIX}" CONFIGURATIONS RelWithDebInfo
 		ARCHIVE DESTINATION "lib${OGRE_LIB_RELWDBG_PATH}${SUFFIX}" CONFIGURATIONS RelWithDebInfo
 		FRAMEWORK DESTINATION "bin${OGRE_RELWDBG_PATH}" CONFIGURATIONS RelWithDebInfo
-
+      )
+	  install(TARGETS ${TARGETNAME}
 		BUNDLE DESTINATION "bin${OGRE_MINSIZE_PATH}" CONFIGURATIONS MinSizeRel
 		RUNTIME DESTINATION "bin${OGRE_MINSIZE_PATH}" CONFIGURATIONS MinSizeRel
 		LIBRARY DESTINATION "lib${OGRE_LIB_MINSIZE_PATH}${SUFFIX}" CONFIGURATIONS MinSizeRel
 		ARCHIVE DESTINATION "lib${OGRE_LIB_MINSIZE_PATH}${SUFFIX}" CONFIGURATIONS MinSizeRel
 		FRAMEWORK DESTINATION "bin${OGRE_MINSIZE_PATH}" CONFIGURATIONS MinSizeRel
-
+      )
+	  install(TARGETS ${TARGETNAME}
 		BUNDLE DESTINATION "bin${OGRE_DEBUG_PATH}" CONFIGURATIONS Debug
 		RUNTIME DESTINATION "bin${OGRE_DEBUG_PATH}" CONFIGURATIONS Debug
 		LIBRARY DESTINATION "lib${OGRE_LIB_DEBUG_PATH}${SUFFIX}" CONFIGURATIONS Debug


Auto-clean updated external projects by default

--- SuperBuild.cmake
+++ SuperBuild.cmake
@@ -98,8 +98,7 @@
 include(mitkFunctionInstallExternalCMakeProject)
 include(mitkFunctionCleanExternalProject)

-option(MITK_AUTOCLEAN_EXTERNAL_PROJECTS "Experimental: Clean external project builds if updated" OFF)
-mark_as_advanced(MITK_AUTOCLEAN_EXTERNAL_PROJECTS)
+option(MITK_AUTOCLEAN_EXTERNAL_PROJECTS "Experimental: Clean external project builds if updated" ON)

 set(ep_prefix "${CMAKE_BINARY_DIR}/ep")
 set_property(DIRECTORY PROPERTY EP_PREFIX ${ep_prefix})


switch cmake for CMake for case sensitive OS's

--- SuperBuild.cmake
+++ SuperBuild.cmake
@@ -132,7 +132,7 @@
 # If the user doesn't want git checkout to be performed,
 # these will be set to blank strings. Else, they'll be set to
 # ${${proj}_URL} and ${${proj}_TAG}, respectively.
-include(${CMAKE_SOURCE_DIR}/cmake/SetGitTagAndRepo.cmake)
+include(${CMAKE_SOURCE_DIR}/CMake/SetGitTagAndRepo.cmake)

 if (UNIX AND NOT APPLE)
   option(USE_SYSTEM_Boost "Build using an external version of Boost" OFF)


Set STATUS mode for CMake message() function calls (#13)

--- cmake/ucm.cmake
+++ cmake/ucm.cmake
@@ -244,11 +244,11 @@
 # Prints all compiler flags for all configurations
 macro(ucm_print_flags)
     ucm_gather_flags(1 flags_configs)
-    message("")
+    message(STATUS "")
     foreach(flags ${flags_configs})
-        message("${flags}: ${${flags}}")
-    endforeach()
-    message("")
+        message(STATUS "${flags}: ${${flags}}")
+    endforeach()
+    message(STATUS "")
 endmacro()

 # ucm_set_xcode_attrib


Some serious updates to GObjectIntrospection.cmake to handle the cmake install prefix stuff

--- cmake/Modules/GObjectIntrospection.cmake
+++ cmake/Modules/GObjectIntrospection.cmake
@@ -34,14 +34,22 @@
 _pkg_config_variable(g_ir_scanner GIR_SCANNER)
 _pkg_config_variable(g_ir_compiler GIR_COMPILER)

+# CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT is only set when the variable is
+# actually set, so we need to create another variable to track that.
+if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
+	set(_INSTALL_PREFIX ${CMAKE_INSTALL_PREFIX} CACHE INTERNAL
+	    "holds the default install path if cmake set it")
+	mark_as_advanced(_INSTALL_PREFIX)
+endif(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
+
 # check if cmake_install_prefix was specified, if so build our paths using that
-if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
+if(_INSTALL_PREFIX)
 	_pkg_config_variable(girdir GIR_GIRDIR)
 	_pkg_config_variable(typelibdir GIR_TYPELIBDIR)
-else(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
+else(_INSTALL_PREFIX)
 	set(GIR_GIRDIR "${CMAKE_INSTALL_PREFIX}/share/gir-1.0")
 	set(GIR_TYPELIBDIR "${CMAKE_INSTALL_PREFIX}/lib/girepository-1.0")
-endif(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
+endif(_INSTALL_PREFIX)

 ###############################################################################
 # The main function


update IPPICV package

update IPPICV package

--- 3rdparty/ippicv/downloader.cmake
+++ 3rdparty/ippicv/downloader.cmake
@@ -8,21 +8,21 @@
 function(_icv_downloader)
   # Define actual ICV versions
   if(APPLE)
-    set(OPENCV_ICV_PACKAGE_NAME "ippicv_macosx_20140429.tgz")
-    set(OPENCV_ICV_PACKAGE_HASH "f2195a60829899983acd4a45794e1717")
+    set(OPENCV_ICV_PACKAGE_NAME "ippicv_macosx_20141027.tgz")
+    set(OPENCV_ICV_PACKAGE_HASH "9662fe0694a67e59491a0dcc82fa26e0")
     set(OPENCV_ICV_PLATFORM "macosx")
     set(OPENCV_ICV_PACKAGE_SUBDIR "/ippicv_osx")
   elseif(UNIX)
     if(ANDROID AND (NOT ANDROID_ABI STREQUAL x86))
       return()
     endif()
-    set(OPENCV_ICV_PACKAGE_NAME "ippicv_linux_20140513.tgz")
-    set(OPENCV_ICV_PACKAGE_HASH "d80cb24f3a565113a9d6dc56344142f6")
+    set(OPENCV_ICV_PACKAGE_NAME "ippicv_linux_20141027.tgz")
+    set(OPENCV_ICV_PACKAGE_HASH "8b449a536a2157bcad08a2b9f266828b")
     set(OPENCV_ICV_PLATFORM "linux")
     set(OPENCV_ICV_PACKAGE_SUBDIR "/ippicv_lnx")
   elseif(WIN32 AND NOT ARM)
-    set(OPENCV_ICV_PACKAGE_NAME "ippicv_windows_20140429.zip")
-    set(OPENCV_ICV_PACKAGE_HASH "b5028a92224ec1fbc554010c52eb3ec8")
+    set(OPENCV_ICV_PACKAGE_NAME "ippicv_windows_20141027.zip")
+    set(OPENCV_ICV_PACKAGE_HASH "b59f865d1ba16e8c84124e19d78eec57")
     set(OPENCV_ICV_PLATFORM "windows")
     set(OPENCV_ICV_PACKAGE_SUBDIR "/ippicv_win")
   else()
@@ -45,7 +45,7 @@
     endif()
   endif()
   unset(OPENCV_ICV_PACKAGE_DOWNLOADED CACHE)
-
+
   set(OPENCV_ICV_PACKAGE_ARCHIVE "${CMAKE_CURRENT_LIST_DIR}/downloads/${OPENCV_ICV_PLATFORM}-${OPENCV_ICV_PACKAGE_HASH}/${OPENCV_ICV_PACKAGE_NAME}")
   get_filename_component(OPENCV_ICV_PACKAGE_ARCHIVE_DIR "${OPENCV_ICV_PACKAGE_ARCHIVE}" PATH)
   if(EXISTS "${OPENCV_ICV_PACKAGE_ARCHIVE}")
@@ -56,7 +56,7 @@
       file(REMOVE_RECURSE "${OPENCV_ICV_PACKAGE_ARCHIVE_DIR}")
     endif()
   endif()
-
+
   if(NOT EXISTS "${OPENCV_ICV_PACKAGE_ARCHIVE}")
     if(NOT DEFINED OPENCV_ICV_URL)
       if(DEFINED ENV{OPENCV_ICV_URL})
@@ -65,7 +65,7 @@
         set(OPENCV_ICV_URL "http://sourceforge.net/projects/opencvlibrary/files/3rdparty/ippicv")
       endif()
     endif()
-
+
     file(MAKE_DIRECTORY ${OPENCV_ICV_PACKAGE_ARCHIVE_DIR})
     message(STATUS "ICV: Downloading ${OPENCV_ICV_PACKAGE_NAME}...")
     file(DOWNLOAD "${OPENCV_ICV_URL}/${OPENCV_ICV_PACKAGE_NAME}" "${OPENCV_ICV_PACKAGE_ARCHIVE}"
@@ -82,12 +82,12 @@
       endif()
     endif()
   endif()
-
+
   ocv_assert(EXISTS "${OPENCV_ICV_PACKAGE_ARCHIVE}")
   ocv_assert(NOT EXISTS "${OPENCV_ICV_UNPACK_PATH}")
   file(MAKE_DIRECTORY ${OPENCV_ICV_UNPACK_PATH})
   ocv_assert(EXISTS "${OPENCV_ICV_UNPACK_PATH}")
-
+
   message(STATUS "ICV: Unpacking ${OPENCV_ICV_PACKAGE_NAME} to ${OPENCV_ICV_UNPACK_PATH}...")
   execute_process(COMMAND ${CMAKE_COMMAND} -E tar xz "${OPENCV_ICV_PACKAGE_ARCHIVE}"
                   WORKING_DIRECTORY "${OPENCV_ICV_UNPACK_PATH}"
@@ -100,7 +100,7 @@
   ocv_assert(EXISTS "${OPENCV_ICV_PATH}")

   set(OPENCV_ICV_PACKAGE_DOWNLOADED "${OPENCV_ICV_PACKAGE_HASH}" CACHE INTERNAL "ICV package hash")
-
+
   message(STATUS "ICV: Package successfully downloaded")
   set(OPENCV_ICV_PATH "${OPENCV_ICV_PATH}" PARENT_SCOPE)
 endfunction()


Adapting CMakeLists to fit tetralith

Adapting CMakeLists to fit tetralith

Former-commit-id: 2e9e7804404a8644f6b5b9adc5c6e5d13c105f12

--- cmake-modules/Fetch_Arpack-ng.cmake
+++ cmake-modules/Fetch_Arpack-ng.cmake
@@ -5,6 +5,7 @@
 find_library(ARPACK_LIBRARIES
         NAMES libarpack${CUSTOM_SUFFIX}
         PATHS /usr/lib/x86_64-linux-gnu/
+        NO_DEFAULT_PATH
         )

 if (NOT ARPACK_LIBRARIES)
@@ -14,16 +15,18 @@
     find_library(ARPACK_LIBRARIES
             NAMES arpack
             PATHS "$ENV{ARPACK_DIR}/lib"
+            NO_DEFAULT_PATH
             )
     find_path(ARPACK_INCLUDE_DIRS
             NAMES arpack
             PATHS "$ENV{ARPACK_DIR}/include"
+            NO_DEFAULT_PATH
             )
 endif()

-if(ARPACK_LIBRARIES)
+if(ARPACK_LIBRARIES AND ARPACK_INCLUDE_DIRS)
     message(STATUS "ARPACK found in system:   ${ARPACK_LIBRARIES}")
     add_library(arpack INTERFACE)
     set_target_properties(arpack


Update OptimizeForArchitecture.cmake

Update OptimizeForArchitecture.cmake

--- cmake/OptimizeForArchitecture.cmake
+++ cmake/OptimizeForArchitecture.cmake
@@ -1874,7 +1874,7 @@
    if("${CMAKE_SYSTEM_PROCESSOR}" MATCHES "i686.*|i386.*|x86.*|amd64.*|x86_64.*|AMD64.*")
       set(TARGET_ARCHITECTURE "auto" CACHE STRING "CPU architecture to optimize for. Using an incorrect setting here can result in crashes of the resulting binary because of invalid instructions used. Setting the value to \"auto\" will try to optimize for the architecture where cmake is called. Setting the value to \"native\" bypasses all checks and uses \"-march=native\" or the compiler equivalent flag. Other supported values are: \"none\", \"generic\", \"core\", \"merom\" (65nm Core2), \"penryn\" (45nm Core2), \"nehalem\", \"westmere\", \"sandybridge\", \"ivybridge\", \"haswell\", \"broadwell\", \"skylake\", \"skylake-xeon\", \"kabylake\", \"cannonlake\", \"cascadelake\", \"cooperlake\", \"icelake\", \"icelake-xeon\", \"tigerlake\", \"alderlake\", \"sapphirerapids\", \"bonnell\", \"silvermont\", \"goldmont\", \"goldmont-plus\", \"tremont\", \"knl\" (Knights Landing), \"knm\" (Knights Mill), \"atom\", \"k8\", \"k8-sse3\", \"barcelona\", \"istanbul\", \"magny-cours\", \"bulldozer\", \"interlagos\", \"piledriver\", \"steamroller\", \"excavator\", \"amd14h\", \"amd16h\", \"zen\", \"zen2\", \"zen3\"." )
    elseif("${CMAKE_SYSTEM_PROCESSOR}" MATCHES "^(arm.*|ARM.*|aarch64.*|AARCH64.*)")
-      set(TARGET_ARCHITECTURE "auto" CACHE STRING "CPU architecture to optimize for. Using an incorrect setting here can result in crashes of the resulting binary because of invalid instructions used. Setting the value to \"auto\" will try to optimize for the architecture where cmake is called. Other supported values are: \"none\", \"generic\", \"a64fx\", \"arm1020e\", \"arm1020t\", \"arm1022e\", \"arm1026ej-s\", \"arm10e\", \"arm10tdmi\", \"arm1136j-s\", \"arm1136jf-s\", \"arm1156t2-s\", \"arm1156t2f-s\", \"arm1176jz-s\", \"arm1176jzf-s\", \"arm710t\", \"arm720t\", \"arm740t\", \"arm7tdmi-s\", \"arm7tdmi\", \"arm810\", \"arm8\", \"arm920\", \"arm920t\", \"arm922t\", \"arm926ej-s\", \"arm940t\", \"arm946e-s\", \"arm966e-s\", \"arm968e-s\", \"arm9\", \"arm9e\", \"arm9tdmi\", \"brahma-b15\", \"brahma-b53\", \"carmel\", \"cortex-a12\", \"cortex-a15.cortex-a7\", \"cortex-a15\", \"cortex-a17.cortex-a7\", \"cortex-a17\", \"cortex-a32\", \"cortex-a34\", \"cortex-a35\", \"cortex-a53\", \"cortex-a55\", \"cortex-a57.cortext-a53\", \"cortex-a57\", \"cortex-a5\", \"cortex-a72.cortext-a53\", \"cortex-a72\", \"cortex-a73.cortext-a35\", \"cortex-a73.cortext-a53\", \"cortex-a73\", \"cortex-a75.cortext-a55\", \"cortex-a75\", \"cortex-a76.cortext-a55\", \"cortex-a76\", \"cortex-a76ae\", \"cortex-a77\", \"cortex-a7\", \"cortex-a8\", \"cortex-a9\", \"cortex-m0\", \"cortex-m0plus\", \"cortex-m1\", \"cortex-m23\", \"cortex-m33\", \"cortex-m35p\", \"cortex-m3\", \"cortex-m4\", \"cortex-m55\", \"cortex-m7\", \"cortex-r4\", \"cortex-r4f\", \"cortex-r52\", \"cortex-r5\", \"cortex-r7\", \"cortex-r8\", \"denver2\", \"denver\", \"exynos-m1\", \"fa526\", \"fa606te\", \"fa626\", \"fa626te\", \"fa726te\", \"falkor\", \"fmp626\", \"generic-armv7-a\", \"i80200\", \"i80321-400-b0\", \"i80321-400\", \"i80321-600-b0\", \"i80321-600\", \"ipx1200\", \"ipx425-266\", \"ipx425-400\", \"ipx425-533\", \"iwmmxt2\", \"iwmmxt\", \"krait\", \"kryo2\", \"kryo\", \"marvell-f\", \"marvell-pj4\", \"mpcore\", \"neoverse-e1\", \"neoverse-n1\", \"pxa210a\", \"pxa210b\", \"pxa210c\", \"pxa250a\", \"pxa250b\", \"pxa250c\", \"pxa27x\", \"pxa30x\", \"pxa31x\", \"pxa32x\", \"pxa930\", \"sa1110\", \"saphira\", \"scorpion\", \"strongarm1100\", \"strongarm110\", \"strongarm\", \"thunderx2\", \"thunderx2t99\", \"thunderx\", \"thunderxt81\", \"thunderxt83\", \"thunderxt88\", \"tsv110\", \"xgene1\", \"xscale\".")
+      set(TARGET_ARCHITECTURE "auto" CACHE STRING "CPU architecture to optimize for. Using an incorrect setting here can result in crashes of the resulting binary because of invalid instructions used. Setting the value to \"auto\" will try to optimize for the architecture where cmake is called. Setting the value to \"native\" bypasses all checks and uses \"-march=native\" or the compiler equivalent flag. Other supported values are: \"none\", \"generic\", \"a64fx\", \"arm1020e\", \"arm1020t\", \"arm1022e\", \"arm1026ej-s\", \"arm10e\", \"arm10tdmi\", \"arm1136j-s\", \"arm1136jf-s\", \"arm1156t2-s\", \"arm1156t2f-s\", \"arm1176jz-s\", \"arm1176jzf-s\", \"arm710t\", \"arm720t\", \"arm740t\", \"arm7tdmi-s\", \"arm7tdmi\", \"arm810\", \"arm8\", \"arm920\", \"arm920t\", \"arm922t\", \"arm926ej-s\", \"arm940t\", \"arm946e-s\", \"arm966e-s\", \"arm968e-s\", \"arm9\", \"arm9e\", \"arm9tdmi\", \"brahma-b15\", \"brahma-b53\", \"carmel\", \"cortex-a12\", \"cortex-a15.cortex-a7\", \"cortex-a15\", \"cortex-a17.cortex-a7\", \"cortex-a17\", \"cortex-a32\", \"cortex-a34\", \"cortex-a35\", \"cortex-a53\", \"cortex-a55\", \"cortex-a57.cortext-a53\", \"cortex-a57\", \"cortex-a5\", \"cortex-a72.cortext-a53\", \"cortex-a72\", \"cortex-a73.cortext-a35\", \"cortex-a73.cortext-a53\", \"cortex-a73\", \"cortex-a75.cortext-a55\", \"cortex-a75\", \"cortex-a76.cortext-a55\", \"cortex-a76\", \"cortex-a76ae\", \"cortex-a77\", \"cortex-a7\", \"cortex-a8\", \"cortex-a9\", \"cortex-m0\", \"cortex-m0plus\", \"cortex-m1\", \"cortex-m23\", \"cortex-m33\", \"cortex-m35p\", \"cortex-m3\", \"cortex-m4\", \"cortex-m55\", \"cortex-m7\", \"cortex-r4\", \"cortex-r4f\", \"cortex-r52\", \"cortex-r5\", \"cortex-r7\", \"cortex-r8\", \"denver2\", \"denver\", \"exynos-m1\", \"fa526\", \"fa606te\", \"fa626\", \"fa626te\", \"fa726te\", \"falkor\", \"fmp626\", \"generic-armv7-a\", \"i80200\", \"i80321-400-b0\", \"i80321-400\", \"i80321-600-b0\", \"i80321-600\", \"ipx1200\", \"ipx425-266\", \"ipx425-400\", \"ipx425-533\", \"iwmmxt2\", \"iwmmxt\", \"krait\", \"kryo2\", \"kryo\", \"marvell-f\", \"marvell-pj4\", \"mpcore\", \"neoverse-e1\", \"neoverse-n1\", \"pxa210a\", \"pxa210b\", \"pxa210c\", \"pxa250a\", \"pxa250b\", \"pxa250c\", \"pxa27x\", \"pxa30x\", \"pxa31x\", \"pxa32x\", \"pxa930\", \"sa1110\", \"saphira\", \"scorpion\", \"strongarm1100\", \"strongarm110\", \"strongarm\", \"thunderx2\", \"thunderx2t99\", \"thunderx\", \"thunderxt81\", \"thunderxt83\", \"thunderxt88\", \"tsv110\", \"xgene1\", \"xscale\".")
    elseif("${CMAKE_SYSTEM_PROCESSOR}" MATCHES "^(powerpc|ppc)64.*")
       set(TARGET_ARCHITECTURE "auto" CACHE STRING "CPU architecture to optimize for. Using an incorrect setting here can result in crashes of the resulting binary because of invalid instructions used. Setting the value to \"auto\" will try to optimize for the architecture where cmake is called. Other supported values are: \"none\", \"generic\", \"power8\", \"power9\", \"power10\".")
    else()


Intel family 6 model 23 can have SSE4.1, but that is not guaranteed. :(

Now, for penryn, the OptimizeForArchitecture macro additionally takes a look at the CPU flags,
looking whether the SSE4.1 cpuid flag is set.

--- cmake/OptimizeForArchitecture.cmake
+++ cmake/OptimizeForArchitecture.cmake
@@ -34,16 +34,21 @@
          string(REGEX REPLACE ".*vendor_id[ \t]*:[ \t]+([a-zA-Z0-9_-]+).*" "\\1" _vendor_id "${_cpuinfo}")
          string(REGEX REPLACE ".*cpu family[ \t]*:[ \t]+([a-zA-Z0-9_-]+).*" "\\1" _cpu_family "${_cpuinfo}")
          string(REGEX REPLACE ".*model[ \t]*:[ \t]+([a-zA-Z0-9_-]+).*" "\\1" _cpu_model "${_cpuinfo}")
+         string(REGEX REPLACE ".*flags[ \t]*:[ \t]+([a-zA-Z0-9_-]+).*" "\\1" _cpu_flags "${_cpuinfo}")
       elseif(CMAKE_SYSTEM_NAME STREQUAL "Darwin")
          exec_program("/usr/sbin/sysctl -n machdep.cpu.vendor" OUTPUT_VARIABLE _vendor_id)
          exec_program("/usr/sbin/sysctl -n machdep.cpu.model"  OUTPUT_VARIABLE _cpu_model)
          exec_program("/usr/sbin/sysctl -n machdep.cpu.family" OUTPUT_VARIABLE _cpu_family)
+         exec_program("/usr/sbin/sysctl -n machdep.cpu.features" OUTPUT_VARIABLE _cpu_flags)
+         string(TOLOWER "${_cpu_flags}" _cpu_flags)
+         string(REPLACE "." "_" _cpu_flags "${_cpu_flags}")
       elseif(CMAKE_SYSTEM_NAME STREQUAL "Windows")
          get_filename_component(_vendor_id "[HKEY_LOCAL_MACHINE\\Hardware\\Description\\System\\CentralProcessor\\0;VendorIdentifier]" NAME CACHE)
          get_filename_component(_cpu_id "[HKEY_LOCAL_MACHINE\\Hardware\\Description\\System\\CentralProcessor\\0;Identifier]" NAME CACHE)
          mark_as_advanced(_vendor_id _cpu_id)
          string(REGEX REPLACE ".* Family ([0-9]+) .*" "\\1" _cpu_family "${_cpu_id}")
          string(REGEX REPLACE ".* Model ([0-9]+) .*" "\\1" _cpu_model "${_cpu_id}")
+         message(AUTHOR_WARNING "If you know how to query the processor capabilities wrt. SSE on Windows, let me know!")
       endif(CMAKE_SYSTEM_NAME STREQUAL "Linux")
       if(_vendor_id STREQUAL "GenuineIntel")
          if(_cpu_family EQUAL 6)
@@ -111,7 +116,14 @@
    elseif(TARGET_ARCHITECTURE STREQUAL "penryn")
       list(APPEND _march_flag_list "penryn")
       list(APPEND _march_flag_list "core2")
-      list(APPEND _available_vector_units_list "sse" "sse2" "sse3" "ssse3" "sse4.1")
+      list(APPEND _available_vector_units_list "sse" "sse2" "sse3" "ssse3")
+      message(STATUS "Sadly the Penryn architecture exists in variants with SSE4.1 and without SSE4.1.")
+      if(_cpu_flags MATCHES "sse4_1")
+         message(STATUS "SSE4.1: enabled (auto-detected from this computer's CPU flags)")
+         list(APPEND _available_vector_units_list "sse4.1")
+      else()
+         message(STATUS "SSE4.1: disabled (auto-detected from this computer's CPU flags)")
+      endif()
    elseif(TARGET_ARCHITECTURE STREQUAL "nehalem")
       list(APPEND _march_flag_list "nehalem")
       list(APPEND _march_flag_list "core2")


Remove duplicate compile option for nuttx

libtuv-DCO-1.0-Signed-off-by: SaeHie Park saehie.park@samsung.com

--- cmake/option/option_arm-nuttx.cmake
+++ cmake/option/option_arm-nuttx.cmake
@@ -45,7 +45,6 @@
           "-march=armv7e-m"
           "-mfpu=fpv4-sp-d16"
           "-mfloat-abi=hard"
-          "-mfloat-abi=hard"
           )
   else()
     message(STATUS "WARNING: TARGET_BOARD=`${TARGET_BOARD}` is unknown to make")


do not include global dylib location when exporting

--- cmake_modules/install_package.cmake
+++ cmake_modules/install_package.cmake
@@ -174,12 +174,12 @@
   elseif( EXPORT_${PROJECT_NAME} )

         # add "installed" library to list of required libraries to link against
-        if( PACKAGE_LIB_NAME )
-            cmake_policy( SET CMP0026 OLD )
-            get_target_property( _target_library ${PACKAGE_LIB_NAME} LOCATION )
-            get_filename_component( _lib ${_target_library} NAME )
-            list( APPEND PACKAGE_LINK_LIBS ${CMAKE_CURRENT_BINARY_DIR}/${_lib} )
-        endif()
+        #if( PACKAGE_LIB_NAME )
+        #    cmake_policy( SET CMP0026 OLD )
+        #    get_target_property( _target_library ${PACKAGE_LIB_NAME} LOCATION )
+        #    get_filename_component( _lib ${_target_library} NAME )
+        #    list( APPEND PACKAGE_LINK_LIBS ${CMAKE_CURRENT_BINARY_DIR}/${_lib} )
+        #endif()

         if( PACKAGE_INSTALL_HEADER_DIRS )


WRG: update diapOTB tag

WRG: update diapOTB tag

--- Modules/Remote/diapotb.remote.cmake
+++ Modules/Remote/diapotb.remote.cmake
@@ -22,5 +22,5 @@
 otb_fetch_module(DiapOTBModule
   "OTB module for SAR processing in Diapason."
   GIT_REPOSITORY https://gitlab.orfeo-toolbox.org/remote_modules/diapotb.git
-  GIT_TAG 04628a9c183883b461114ff5b099943197431f5a
+  GIT_TAG 1b46a3ca14a009779b277a9c43f4a59913462d1a
 )


STYLE: Remove trailing whitespace.

STYLE: Remove trailing whitespace.

--- CMake/CheckFor64BitStreams.cmake
+++ CMake/CheckFor64BitStreams.cmake
@@ -9,7 +9,7 @@
   IF("${VARIABLE}" MATCHES "^${VARIABLE}$")
     SET(MACRO_CHECK_FOR_64BIT_STREAMS_FLAGS ${CMAKE_REQUIRED_FLAGS})
     IF(CMAKE_NO_ANSI_STREAM_HEADERS)
-      SET(MACRO_CHECK_FOR_64BIT_STREAMS_FLAGS
+      SET(MACRO_CHECK_FOR_64BIT_STREAMS_FLAGS
         "${MACRO_CHECK_FOR_64BIT_STREAMS_FLAGS} -DNO_ANSI")
     ENDIF(CMAKE_NO_ANSI_STREAM_HEADERS)
     IF(SIZEOF_LONG_LONG)


Mark all install cmake variables as advanced

Variables that fit the pattern `FG_INSTALL_*` are marked
as advanced

--- CMakeModules/FGInstallDirs.cmake
+++ CMakeModules/FGInstallDirs.cmake
@@ -17,11 +17,6 @@
 # Header files
 if(NOT DEFINED FG_INSTALL_INC_DIR)
     set(FG_INSTALL_INC_DIR "include" CACHE PATH "Installation path for headers")
-endif()
-
-# Data files
-if(NOT DEFINED FG_INSTALL_DATA_DIR)
-    set(FG_INSTALL_DATA_DIR "data" CACHE PATH "Installation path for data files")
 endif()

 # Documentation
@@ -59,3 +54,12 @@
                           "${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_PREFIX}"
                            ABSOLUTE)
 endif()
+
+mark_as_advanced(
+    FG_INSTALL_CMAKE_DIR
+    FG_INSTALL_MAN_DIR
+    FG_INSTALL_EXAMPLE_DIR
+    FG_INSTALL_DOC_DIR
+    FG_INSTALL_INC_DIR
+    FG_INSTALL_LIB_DIR
+    FG_INSTALL_BIN_DIR)


ENH: OTB can use MuParser superbuild

ENH: OTB can use MuParser superbuild

--- CMake/External_OTB.cmake
+++ CMake/External_OTB.cmake
@@ -4,8 +4,50 @@

 set(OTB_SB_BUILD_DIR ${CMAKE_BINARY_DIR}/${proj}/build)

+set(${proj}_DEPENDENCIES)
+
+if(USE_SYSTEM_GDAL)
+  set(OTB_SB_GDAL_CONFIG)
+else()
+  set(OTB_SB_GDAL_CONFIG
+    -DGDAL_INCLUDE_DIR:PATH=${CMAKE_INSTALL_PREFIX}/include
+    -DGDAL_LIBRARY:PATH=${CMAKE_INSTALL_PREFIX}/lib/libgdal.so
+    -DGDAL_CONFIG:PATH=${CMAKE_INSTALL_PREFIX}/bin/gdal-config
+    )
+  list(APPEND ${proj}_DEPENDENCIES GDAL)
+endif()
+
+if(USE_SYSTEM_OSSIM)
+  set(OTB_SB_OSSIM_CONFIG)
+else()
+  set(OTB_SB_OSSIM_CONFIG
+    -DOSSIM_INCLUDE_DIR:PATH=${CMAKE_INSTALL_PREFIX}/include
+    -DOSSIM_LIBRARY:PATH=${CMAKE_INSTALL_PREFIX}/lib/libossim.so
+    )
+  list(APPEND ${proj}_DEPENDENCIES OSSIM)
+endif()
+
+if(USE_SYSTEM_ITK)
+  set(OTB_SB_ITK_CONFIG)
+else()
+  set(OTB_SB_ITK_CONFIG
+    -DITK_DIR:PATH=${CMAKE_INSTALL_PREFIX}/lib/cmake/ITK-4.6
+    )
+  list(APPEND ${proj}_DEPENDENCIES ITK)
+endif()
+
+if(USE_SYSTEM_MUPARSER)
+  set(OTB_SB_MUPARSER_CONFIG)
+else()
+  set(OTB_SB_MUPARSER_CONFIG
+    -DMUPARSER_INCLUDE_DIR:PATH=${CMAKE_INSTALL_PREFIX}/include
+    -DMUPARSER_LIBRARY:PATH=${CMAKE_INSTALL_PREFIX}/lib/libmuparser.so
+    )
+  list(APPEND ${proj}_DEPENDENCIES MUPARSER)
+endif()
+
 ExternalProject_Add(${proj}
-    DEPENDS ITK OSSIM GDAL
+    DEPENDS ${${proj}_DEPENDENCIES}
     PREFIX ${proj}
     HG_REPOSITORY "http://hg.orfeo-toolbox.org/OTB"
     HG_TAG tip
@@ -15,16 +57,16 @@
       -DCMAKE_INSTALL_PREFIX:STRING=${CMAKE_INSTALL_PREFIX}
       -DCMAKE_BUILD_TYPE:STRING=Release
       -DBUILD_SHARED_LIBS:BOOL=ON
-      -DBUILD_TESTING:BOOL=OFF
-      -DBUILD_EXAMPLES:BOOL=OFF
+      -DBUILD_TESTING:BOOL=ON
+      -DBUILD_EXAMPLES:BOOL=ON
       -DBUILD_APPLICATIONS:BOOL=ON
-      -DOTB_WRAP_QT:BOOL=ON
-      -DITK_DIR:PATH=${CMAKE_INSTALL_PREFIX}/lib/cmake/ITK-4.6
+      -DOTB_WRAP_QT:BOOL=OFF
       -DCMAKE_PREFIX_PATH:STRING=${CMAKE_INSTALL_PREFIX}
       -DOTB_USE_EXTERNAL_OSSIM:BOOL=ON
-      -DGDAL_INCLUDE_DIR:PATH=${CMAKE_INSTALL_PREFIX}/include
-      -DGDAL_LIBRARY:PATH=${CMAKE_INSTALL_PREFIX}/lib/libgdal.so
-      -DGDAL_CONFIG:PATH=${CMAKE_INSTALL_PREFIX}/bin/gdal-config
+      ${OTB_SB_ITK_CONFIG}
+      ${OTB_SB_OSSIM_CONFIG}
+      ${OTB_SB_GDAL_CONFIG}
+      ${OTB_SB_MUPARSER_CONFIG}
     CMAKE_COMMAND
       LD_LIBRARY_PATH=${CMAKE_INSTALL_PREFIX}/lib
       ${CMAKE_COMMAND}


BUG: parse correctly OTB-Data revision number

--- CMake/SourceStatus.cmake
+++ CMake/SourceStatus.cmake
@@ -17,29 +17,22 @@
   string(REGEX REPLACE "\n" ";" OTB_WC_STATUS "${OTB_WC_STATUS}")
   set(OTB_WC_STATUS ${OTB_WC_STATUS} CACHE STRING "Repository status" FORCE)
   mark_as_advanced(OTB_WC_STATUS)
-
-  if(OTB_DATA_ROOT)
-    Mercurial_WC_IDENTIFY(${OTB_DATA_ROOT} OTB_DATA)
-    set(OTB_DATA_WC_REVISION ${OTB_DATA_WC_REVISION} CACHE STRING "Repository version" FORCE)
-    mark_as_advanced(OTB_DATA_WC_REVISION)
-  endif()
-
 endif()
 endif()

 if(EXISTS "${PROJECT_SOURCE_DIR}/.git")
   find_package(Git)
   if(GIT_FOUND)
-    execute_process(COMMAND ${GIT_EXECUTABLE} log -1 --pretty=oneline
+    execute_process(COMMAND ${GIT_EXECUTABLE} log -1 --pretty=format:%H
       WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
-      OUTPUT_VARIABLE OTB_WC_VERSION
+      OUTPUT_VARIABLE OTB_WC_REVISION
       OUTPUT_STRIP_TRAILING_WHITESPACE ERROR_QUIET)
     execute_process(COMMAND ${GIT_EXECUTABLE} status -s
       WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
       OUTPUT_VARIABLE OTB_WC_STATUS
       OUTPUT_STRIP_TRAILING_WHITESPACE ERROR_QUIET)
     message(STATUS "Repository status :")
-    message(STATUS "  Repository revision is ${OTB_WC_VERSION}")
+    message(STATUS "  Repository revision is ${OTB_WC_REVISION}")
     if(OTB_WC_STATUS)
       message(STATUS "  Local file modifications:")
       string(REPLACE "\n" "\n--     " OTB_WC_STATUS_PRETTYPRINT "    ${OTB_WC_STATUS}")
@@ -49,3 +42,30 @@
     endif()
   endif()
 endif()
+
+if(OTB_DATA_ROOT)
+  if(EXISTS "${OTB_DATA_ROOT}/.hg")
+    if(NOT Mercurial_FOUND)
+      find_package(Mercurial)
+    endif()
+    if(Mercurial_FOUND)
+      Mercurial_WC_IDENTIFY(${OTB_DATA_ROOT} OTB_DATA)
+      set(OTB_DATA_WC_REVISION ${OTB_DATA_WC_REVISION} CACHE STRING "Repository version" FORCE)
+      mark_as_advanced(OTB_DATA_WC_REVISION)
+    endif()
+  endif()
+
+  if(EXISTS "${OTB_DATA_ROOT}/.git")
+    if(NOT GIT_FOUND)
+      find_package(Git)
+    endif()
+    if(GIT_FOUND)
+      execute_process(COMMAND ${GIT_EXECUTABLE} log -1 --pretty=format:%H
+        WORKING_DIRECTORY ${OTB_DATA_ROOT}
+        OUTPUT_VARIABLE OTB_DATA_WC_REVISION
+        OUTPUT_STRIP_TRAILING_WHITESPACE ERROR_QUIET)
+      set(OTB_DATA_WC_REVISION ${OTB_DATA_WC_REVISION} CACHE STRING "Repository version" FORCE)
+      mark_as_advanced(OTB_DATA_WC_REVISION)
+    endif()
+  endif()
+endif()


COMP: Fix MINCTransformIO factory registration.

Addresses:

  Undefined symbols:
  "itk::MINCTransformIOFactoryRegister__Private()", referenced from:
      itk::(anonymous namespace)::TransformIOFactoryRegisterRegisterListin TransformReadWrite.cxx.o
  ld: symbol(s) not found

Change-Id: I415bffdbabdc65878044e8ec0903bd579c5f9a56

--- CMake/UseITK.cmake
+++ CMake/UseITK.cmake
@@ -92,12 +92,10 @@
   set(LIST_OF_FACTORIES_REGISTRATION "")
   set(LIST_OF_FACTORY_NAMES "")

-  foreach (TransformFormat  Matlab Txt HDF5)
+  foreach (TransformFormat  Matlab Txt HDF5 MINC)
     ADD_FACTORY_REGISTRATION("LIST_OF_FACTORIES_REGISTRATION" "LIST_OF_FACTORY_NAMES"
       ITKIOTransform${TransformFormat} ${TransformFormat}TransformIO)
   endforeach()
-  ADD_FACTORY_REGISTRATION("LIST_OF_FACTORIES_REGISTRATION" "LIST_OF_FACTORY_NAMES"
-    ITKIOMINC MINCTransformIO)
   ADD_FACTORY_REGISTRATION("LIST_OF_FACTORIES_REGISTRATION" "LIST_OF_FACTORY_NAMES"
     ITKIOTransformInsightLegacy TxtTransformIO)


another fix to code coverage

another fix to code coverage

--- CodeCoverage.cmake
+++ CodeCoverage.cmake
@@ -134,7 +134,7 @@
     # Capturing lcov counters and generating report
     COMMAND ${LCOV_PATH} --directory . --capture --output-file ${_outputname}.info
     COMMAND ${LCOV_PATH} --remove ${_outputname}.info 'tests/*' '/usr/*' --output-file ${_outputname}.info.cleaned
-    FILE RENAME ${_outputname}.info.cleaned ${_outputname}.info
+    COMMAND ${CMAKE_COMMAND} -E rename ${_outputname}.info.cleaned ${_outputname}.info
   )

 	# Setup target


CMake: Add check for matching C++11 support

--- cmake/configure/configure_2_trilinos.cmake
+++ cmake/configure/configure_2_trilinos.cmake
@@ -122,7 +122,8 @@
     # unsigned int.
     #
     IF(TRILINOS_WITH_NO_32BIT_INDICES AND NOT DEAL_II_WITH_64BIT_INDICES)
-      MESSAGE(STATUS "deal.II was configured to use 32bit global indices but "
+      MESSAGE(STATUS "Could not find a sufficient Trilinos installation: "
+        "deal.II was configured to use 32bit global indices but "
         "Trilinos was not."
         )
       SET(TRILINOS_ADDITIONAL_ERROR_STRING
@@ -141,7 +142,8 @@
     # unsigned long long int.
     #
     IF(TRILINOS_WITH_NO_64BIT_INDICES AND DEAL_II_WITH_64BIT_INDICES)
-      MESSAGE(STATUS "deal.II was configured to use 64bit global indices but "
+      MESSAGE(STATUS "Could not find a sufficient Trilinos installation: "
+        "deal.II was configured to use 64bit global indices but "
         "Trilinos was not."
         )
       SET(TRILINOS_ADDITIONAL_ERROR_STRING
@@ -180,6 +182,26 @@
       ENDIF()
     ENDIF()

+    #
+    # Newer Trilinos versions (12.0.1 or newer) require a matching C++11
+    # support. I.e., if Trilinos is configured with C++11 support, deal.II
+    # also has to be configured with C++11 support:
+    #
+    IF(TRILINOS_WITH_MANDATORY_CXX11 AND NOT DEAL_II_WITH_CXX11)
+      MESSAGE(STATUS "Could not find a sufficient Trilinos installation: "
+        "Trilinos was compiled with C++11 support, but C++11 support is "
+        "disabled (DEAL_II_WITH_CXX11=off)."
+        )
+      SET(TRILINOS_ADDITIONAL_ERROR_STRING
+        ${TRILINOS_ADDITIONAL_ERROR_STRING}
+        "The Trilinos installation (found at \"${TRILINOS_DIR}\")\n"
+        "requires C++11 support, but C++11 support is disabled:\n"
+        "  DEAL_II_WITH_CXX11 = ${DEAL_II_WITH_CXX11}\n"
+        )
+      SET(${var} FALSE)
+
+    ENDIF()
+
     CHECK_MPI_INTERFACE(TRILINOS ${var})
   ENDIF()
 ENDMACRO()


Add path to qmake executable to meInria-superprojectCONFIG.cmake

--- cmake/externals/projects_modules/Qt4.cmake
+++ cmake/externals/projects_modules/Qt4.cmake
@@ -142,6 +142,18 @@

 endif()

+
+## #############################################################################
+## Provide path of qmake executable for Asclepios and visages plugins
+## #############################################################################
+
+
+  file(APPEND ${${PROJECT_NAME}_CONFIG_FILE}
+    "set(QT_QMAKE_EXECUTABLE ${QT_QMAKE_EXECUTABLE})
+    find_package(Qt REQUIRED)\n\n"
+    )
+
+
 #TODO it si mark as advanced because not really tested yet.
 mark_as_advanced(USE_SYSTEM_${ep_name})
 endfunction()


build: include more directories

build: include more directories

llvm/Support/Compiler.h recently grew a dependency on llvm-config.h.  This
pointed out that we were not including the path to the generated header
directory in the build output.  Ensure that we have the corresponding -I.

--- cmake/modules/SwiftSharedCMakeConfig.cmake
+++ cmake/modules/SwiftSharedCMakeConfig.cmake
@@ -252,6 +252,9 @@
                       "${CLANG_MAIN_INCLUDE_DIR}"
                       "${CMARK_MAIN_INCLUDE_DIR}"
                       "${CMARK_BUILD_INCLUDE_DIR}")
+  foreach (INCLUDE_DIR ${LLVM_INCLUDE_DIRS})
+    include_directories(${INCLUDE_DIR})
+  endforeach ()

   link_directories(
       "${LLVM_LIBRARY_DIR}"


fix behavior of ament_include_directories_order on non-Windows (#157)

--- ament_cmake_include_directories/cmake/ament_include_directories_order.cmake
+++ ament_cmake_include_directories/cmake/ament_include_directories_order.cmake
@@ -23,7 +23,11 @@
 # @public
 #
 macro(ament_include_directories_order var)
-  _ament_include_directories_order(${var} "$ENV{AMENT_PREFIX_PATH}" ${ARGN})
+  set(_ament_prefix_path_list "$ENV{AMENT_PREFIX_PATH}")
+  if(NOT WIN32)
+    string(REPLACE ":" ";" _ament_prefix_path_list "${_ament_prefix_path_list}")
+  endif()
+  _ament_include_directories_order(${var} "${_ament_prefix_path_list}" ${ARGN})
 endmacro()


Fix ucol_setMaxVariable detection for Gentoo Linux (#5309)

The issue was the symbol is exported by the ICU lib. Including headers
was not enough. The linker requires the libraries to succeed.

With this fix, CoreCLR successfully builds on Gentoo Linux 100%.
Tested with LXC gentoo container on Ubuntu machine.

Steps to configure and build:
https://gist.github.com/jasonwilliams200OK/1a2e2c0e904ffa95faf6333fcd88d9b8

Fix #5160

--- src/corefx/System.Globalization.Native/configure.cmake
+++ src/corefx/System.Globalization.Native/configure.cmake
@@ -8,11 +8,18 @@
     int main() { UDateFormatSymbolType e = UDAT_STANDALONE_SHORTER_WEEKDAYS; }
 " HAVE_UDAT_STANDALONE_SHORTER_WEEKDAYS)

+if(NOT CLR_CMAKE_PLATFORM_DARWIN)
+    set(CMAKE_REQUIRED_LIBRARIES ${ICUUC} ${ICUI18N})
+else()
+    set(CMAKE_REQUIRED_LIBRARIES ${ICUCORE})
+endif()
+
 check_symbol_exists(
     ucol_setMaxVariable
     "unicode/ucol.h"
     HAVE_SET_MAX_VARIABLE)

+unset(CMAKE_REQUIRED_LIBRARIES)
 unset(CMAKE_REQUIRED_INCLUDES)

 configure_file(


Fix another CMake location

Fix another CMake location

--- EqStringifyShaders.cmake
+++ EqStringifyShaders.cmake
@@ -10,7 +10,7 @@
     add_custom_command(OUTPUT ${OUTPUT_FILES}
       COMMAND ${CMAKE_COMMAND} -DEQ_STRINGIFY_SHADERS_PROCESSING_MODE=ON
         -DINPUT="${INPUT}" -DOUTPUT="${OUTPUT}"
-        -P ${CMAKE_SOURCE_DIR}/CMake/EqStringifyShaders.cmake
+        -P ${CMAKE_CURRENT_LIST_DIR}/EqStringifyShaders.cmake
       DEPENDS ${INPUT}
       )
     list(APPEND ${SOURCES} ${OUTPUT_FILES})


CI: avoid multiple ctest_submit

CI: avoid multiple ctest_submit

--- CI/main_ci.cmake
+++ CI/main_ci.cmake
@@ -77,6 +77,7 @@
     )

 if ( NOT _configure_rv EQUAL 0 )
+  # stop processing here
   ctest_submit()
   message( FATAL_ERROR "An error occurs during ctest_configure.")
 endif()
@@ -87,7 +88,6 @@
             )

 if ( NOT _build_rv EQUAL 0 )
-  ctest_submit()
   message( SEND_ERROR "An error occurs during ctest_build.")
 endif()

@@ -97,7 +97,6 @@
            )

 if ( NOT _test_rv EQUAL 0 )
-  ctest_submit()
   message( SEND_ERROR "An error occurs during ctest_test.")
 endif()


closes #5784 don't run valgrind on tdb-recover because it's statically linked and we can't change --soname-synonyms for just one child

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

--- DartConfig.cmake
+++ DartConfig.cmake
@@ -4,7 +4,7 @@
     # that is hard to parse out, so we'll just let it run alone
     set(MEMORYCHECK_COMMAND "${TokuDB_SOURCE_DIR}/scripts/tokuvalgrind")
   endif ()
-  set(MEMORYCHECK_COMMAND_OPTIONS "--gen-suppressions=no --soname-synonyms=somalloc=*tokuportability* --quiet --num-callers=20 --leak-check=full --show-reachable=yes --trace-children=yes --trace-children-skip=sh,*/sh,basename,*/basename,dirname,*/dirname,rm,*/rm,cp,*/cp,mv,*/mv,cat,*/cat,diff,*/diff,grep,*/grep,date,*/date,test,*/tokudb_dump* --trace-children-skip-by-arg=--only_create,--test,--no-shutdown,novalgrind" CACHE INTERNAL "options for valgrind")
+  set(MEMORYCHECK_COMMAND_OPTIONS "--gen-suppressions=no --soname-synonyms=somalloc=*tokuportability* --quiet --num-callers=20 --leak-check=full --show-reachable=yes --trace-children=yes --trace-children-skip=sh,*/sh,basename,*/basename,dirname,*/dirname,rm,*/rm,cp,*/cp,mv,*/mv,cat,*/cat,diff,*/diff,grep,*/grep,date,*/date,test,*/tokudb_dump,*/tdb-recover --trace-children-skip-by-arg=--only_create,--test,--no-shutdown,novalgrind" CACHE INTERNAL "options for valgrind")
   set(MEMORYCHECK_SUPPRESSIONS_FILE "${CMAKE_CURRENT_BINARY_DIR}/valgrind.suppressions" CACHE INTERNAL "suppressions file for valgrind")
   set(UPDATE_COMMAND "svn")
 endif()


ENH: Add support for http submit

ENH: Add support for http submit

--- DartConfig.cmake
+++ DartConfig.cmake
@@ -3,10 +3,15 @@
 SET (NIGHTLY_START_TIME "0:30:00 EDT")

 # Dart server to submit results (used by client)
-SET (DROP_SITE "public.kitware.com")
-SET (DROP_LOCATION "/incoming")
-SET (DROP_SITE_USER "ftpuser")
-SET (DROP_SITE_PASSWORD "public")
+IF(DROP_METHOD MATCHES http)
+  SET (DROP_SITE "public.kitware.com")
+  SET (DROP_LOCATION "/cgi-bin/HTTPUploadDartFile.cgi")
+ELSE(DROP_METHOD MATCHES http)
+  SET (DROP_SITE "public.kitware.com")
+  SET (DROP_LOCATION "/incoming")
+  SET (DROP_SITE_USER "ftpuser")
+  SET (DROP_SITE_PASSWORD "public")
+ENDIF(DROP_METHOD MATCHES http)
 SET (TRIGGER_SITE
        "http://${DROP_SITE}/cgi-bin/Submit-Xdmf-TestingResults.pl")


ENH: Changed default of BUILD_DOXYGIN to off.

--- DartConfig.cmake
+++ DartConfig.cmake
@@ -19,7 +19,7 @@
 SET (CVS_WEB_URL "http://${DROP_SITE}/cgi-bin/cvsweb.cgi/Insight/")
 SET (CVS_WEB_CVSROOT "Insight")

-OPTION(BUILD_DOXYGEN "Build source documentation using doxygen" "On")
+OPTION(BUILD_DOXYGEN "Build source documentation using doxygen" "Off")
 SET (DOXYGEN_CONFIG "${PROJECT_BINARY_DIR}/doxygen.config" )
 SET (USE_DOXYGEN "On")
 SET (DOXYGEN_URL "http://${DROP_SITE}/Insight/Doxygen/html/" )


Add link with fmt if existing spdlog is found and fmt exists

--- cmake/Modules/FindSpdlog_EP.cmake
+++ cmake/Modules/FindSpdlog_EP.cmake
@@ -67,6 +67,10 @@

 if (SPDLOG_FOUND AND NOT TARGET Spdlog::Spdlog)
   add_library(Spdlog::Spdlog INTERFACE IMPORTED)
+  find_package(fmt)
+  if (${fmt_FOUND})
+    target_link_libraries(Spdlog::Spdlog INTERFACE fmt::fmt)
+  endif()
   set_target_properties(Spdlog::Spdlog PROPERTIES
     INTERFACE_INCLUDE_DIRECTORIES "${SPDLOG_INCLUDE_DIR}"
   )


only add avr-reset if an executable has also been added

--- cmake/avr-arduino-toolchain.cmake
+++ cmake/avr-arduino-toolchain.cmake
@@ -61,11 +61,6 @@
 add_definitions(-DF_CPU=${F_CPU})
 add_definitions(-DBAUD=${BAUD})

-# add a reset command using avrdude
-if (NOT TARGET avr-reset)
-    add_custom_target(avr-reset COMMAND ${AVRDUDE} -c${PROGRAMMER} -p${MCU})
-endif ()
-
 # we need a little function to add multiple targets
 function(add_executable_avr NAME)
     add_executable(${NAME} ${ARGN})
@@ -81,6 +76,11 @@
             COMMAND ${AVRSIZE} --mcu=${MCU} -C --format=avr "${NAME}.elf"
             DEPENDS ${NAME})
     add_custom_target(${NAME}-strip ALL DEPENDS ${NAME}.hex)
+
+    # add a reset command using avrdude (only if it does not yet exist)
+    if (NOT TARGET avr-reset)
+        add_custom_target(avr-reset COMMAND ${AVRDUDE} -c${PROGRAMMER} -p${MCU})
+    endif ()

     if (PROGRAMMER STREQUAL "usbasp")
         set(AVRDUDE_ARGS -c${PROGRAMMER} -p${MCU} -Pusb)


Copy the modulemap early and spell it out in the compiler flags.

CMake is doing various checks during its configure time. For example, trying to
compile code to check the system config. The modulemap needs to be copied if
it ends up explicitly in the compiler flags.

--- cmake/modules/CheckCompiler.cmake
+++ cmake/modules/CheckCompiler.cmake
@@ -120,10 +120,12 @@
                              CXX_SUPPORTS_MODULES)
   set(CMAKE_REQUIRED_FLAGS ${OLD_CMAKE_REQUIRED_FLAGS})
   if (CXX_SUPPORTS_MODULES)
+    file(COPY ${CMAKE_SOURCE_DIR}/build/unix/module.modulemap DESTINATION ${ROOT_INCLUDE_DIR})
+
     #append_if(CXX_SUPPORTS_MODULES "-fmodules" CMAKE_C_FLAGS)
     #append_if(CXX_SUPPORTS_MODULES "-fmodules -fcxx-modules" CMAKE_CXX_FLAGS)
-    set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fmodules")
-    set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fmodules -fcxx-modules")
+    set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fmodules -fmodule-map-file=${CMAKE_BINARY_DIR}/include/module.modulemap -fmodules-cache-path=${CMAKE_BINARY_DIR}/include/pcms/")
+    set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fmodules -fcxx-modules -fmodule-map-file=${CMAKE_BINARY_DIR}/include/module.modulemap -fmodules-cache-path=${CMAKE_BINARY_DIR}/include/pcms/")
   else()
     message(FATAL_ERROR "cxxmodules is not supported by this compiler")
   endif()


Suffix messages JARs with _message

Suffix messages JARs with _message

--- rosidl_generator_java/cmake/rosidl_generator_java_generate_interfaces.cmake
+++ rosidl_generator_java/cmake/rosidl_generator_java_generate_interfaces.cmake
@@ -281,18 +281,18 @@
   endforeach()
 endforeach()

-add_jar("${PROJECT_NAME}_jar"
+add_jar("${PROJECT_NAME}_messages_jar"
   "${_generated_msg_java_files}"
   "${_generated_srv_java_files}"
   OUTPUT_NAME
-  "${PROJECT_NAME}"
+  "${PROJECT_NAME}_messages"
   INCLUDE_JARS
   "${_jar_deps}"
 )

-add_dependencies("${PROJECT_NAME}_jar" "${rosidl_generate_interfaces_TARGET}${_target_suffix}")
-
-get_property(_jar_file TARGET "${PROJECT_NAME}_jar" PROPERTY "JAR_FILE")
+add_dependencies("${PROJECT_NAME}_messages_jar" "${rosidl_generate_interfaces_TARGET}${_target_suffix}")
+
+get_property(_jar_file TARGET "${PROJECT_NAME}_messages_jar" PROPERTY "JAR_FILE")

 if(NOT rosidl_generate_interfaces_SKIP_INSTALL)
   set(_install_jar_dir "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}")
@@ -301,7 +301,7 @@
     get_filename_component(_msg_package_dir "${_msg_file}" DIRECTORY)
     get_filename_component(_msg_package_dir "${_msg_package_dir}" DIRECTORY)

-    install_jar("${PROJECT_NAME}_jar" "share/${PROJECT_NAME}/java")
-    ament_export_jars("share/${PROJECT_NAME}/java/${PROJECT_NAME}.jar")
-  endif()
-endif()
+    install_jar("${PROJECT_NAME}_messages_jar" "share/${PROJECT_NAME}/java")
+    ament_export_jars("share/${PROJECT_NAME}/java/${PROJECT_NAME}_messages.jar")
+  endif()
+endif()


SVN_SILENT made messages (.desktop file)

--- gstreamer/gstreamer.desktop.cmake
+++ gstreamer/gstreamer.desktop.cmake
@@ -11,6 +11,7 @@

 Name=GStreamer
 Name[bg]=GStreamer
+Name[bs]=Gstreamer
 Name[ca]=GStreamer
 Name[ca@valencia]=GStreamer
 Name[cs]=GStreamer
@@ -65,6 +66,7 @@

 Comment=Phonon GStreamer backend
 Comment[bg]=Phonon GStreamer
+Comment[bs]=Gstreamer kao pozadina Phonona
 Comment[ca]=Dorsal GStreamer del Phonon
 Comment[ca@valencia]=Dorsal GStreamer del Phonon
 Comment[cs]=Podpůrná vrstva GStreamer pro Phonon


Hunter 0.2.3

Hunter 0.2.3

--- HunterGate.cmake
+++ HunterGate.cmake
@@ -14,8 +14,8 @@

 cmake_minimum_required(VERSION 2.8.10)

-set(HUNTER_MINIMUM_VERSION "0.2.2")
-set(HUNTER_MINIMUM_VERSION_HASH 2d538ede36c2cf24c526a5d4c452209faa89d536)
+set(HUNTER_MINIMUM_VERSION "0.2.3")
+set(HUNTER_MINIMUM_VERSION_HASH 4b8f3dff884f02b8ade014cf61ba46b494802fc4)

 # Set HUNTER_ROOT cmake variable to suitable value.
 # Info about variable can be found in HUNTER_ROOT_INFO.


Update hunter gate

Update hunter gate

--- HunterGate.cmake
+++ HunterGate.cmake
@@ -14,8 +14,8 @@

 cmake_minimum_required(VERSION 2.8.10)

-set(HUNTER_MINIMUM_VERSION "0.2.10")
-set(HUNTER_MINIMUM_VERSION_HASH 725c05b78b62ee476430d3c3ec355e6cdc597b54)
+set(HUNTER_MINIMUM_VERSION "0.3.3")
+set(HUNTER_MINIMUM_VERSION_HASH 2c94192b1fedca076888ed83261ffd51c735219b)

 # Set HUNTER_ROOT cmake variable to suitable value.
 # Info about variable can be found in HUNTER_ROOT_INFO.


Enable hptt library.

Enable hptt library.


Drop CMAKE_SYSROOT from taglib-config

Drop CMAKE_SYSROOT from taglib-config

Commit d4c938cbc766ffb400c09efb9e696fce2537d81e is about fixing taglib-config for proper cross-compilation. The fix is right in principle, but wrong about adding `CMAKE_SYSROOT`. The correct prefix path should be set outside of the config file as some embedded Linux distros like OpenWrt or OpenEmbedded install with a different DESTDIR, and dependent packages see a different sysroot.

--- taglib-config.cmake
+++ taglib-config.cmake
@@ -14,8 +14,8 @@
 	exit 1;
 }

-prefix=@CMAKE_SYSROOT@@CMAKE_INSTALL_PREFIX@
-exec_prefix=@CMAKE_SYSROOT@@CMAKE_INSTALL_PREFIX@
+prefix=@CMAKE_INSTALL_PREFIX@
+exec_prefix=@CMAKE_INSTALL_PREFIX@
 libdir=${exec_prefix}/lib
 includedir=${prefix}/include


Cmake/SetVersion: do not unnecessarily pur variables in cache

Setting a cache variable and then setting a non-cache variable with the same
name does not modify the cache variable.

There is no advantage here in using cache variables, to let's use regular
variables.

Signed-off-by: David Wagner <60228a510f9a76940848fa2d29321fc4edfc2119@intel.com>

--- SetVersion.cmake
+++ SetVersion.cmake
@@ -27,12 +27,12 @@
 # SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

 # Fallback values:
-set(PF_VERSION_MAJOR 0 CACHE INTERNAL "Parameter Framework's version major number")
-set(PF_VERSION_MINOR 0 CACHE INTERNAL "Parameter Framework's version minor number")
-set(PF_VERSION_PATCH 0 CACHE INTERNAL "Parameter Framework's version patch number")
-set(PF_VERSION_TWEAK 0 CACHE INTERNAL "Parameter Framework's version tweak (or build) number")
-set(PF_VERSION_SHA1 "g0000000000" CACHE INTERNAL "Parameter Framework's sources git SHA1")
-set(PF_VERSION_DIRTY "" CACHE INTERNAL "Parameter Framework's sources dirty marker")
+set(PF_VERSION_MAJOR 0)
+set(PF_VERSION_MINOR 0)
+set(PF_VERSION_PATCH 0)
+set(PF_VERSION_TWEAK 0)
+set(PF_VERSION_SHA1 "g0000000000")
+set(PF_VERSION_DIRTY "")

 # Find and set the Parameter Framework's version
 # First, let's see if the user forced a version (i.e. "vX.Y.Z-N")
@@ -69,7 +69,7 @@
 endif()

 # If we are precisely on a tag, make a nicer version string
-set(NICE_PF_VERSION "${PF_VERSION}" CACHE INTERNAL "")
+set(NICE_PF_VERSION "${PF_VERSION}")
 if((PF_VERSION_TWEAK EQUAL 0) AND (NOT PF_VERSION_DIRTY))
     set(NICE_PF_VERSION "v${PF_VERSION_MAJOR}.${PF_VERSION_MINOR}.${PF_VERSION_PATCH}")
 endif()


COMP: Propagation of the slicer build directory path to the inner build

--- SuperBuild.cmake
+++ SuperBuild.cmake
@@ -174,6 +174,7 @@
   VTK_DIR:PATH
   VTK_VERSION_MAJOR:STRING
   SlicerExecutionModel_DIR:PATH
+  Slicer_DIR:PATH
   )

 _expand_external_project_vars()


COMP: Enable parallel build in superbuild subprojects.

The CMAKE_GENERATOR value needs to be set for external projects.

--- SuperBuild.cmake
+++ SuperBuild.cmake
@@ -11,6 +11,8 @@
 endif()

 set( TubeTK_DEPENDS "" )
+
+set(gen "${CMAKE_GENERATOR}")

 ##
 ## Check if sytem ITK or superbuild ITK


COMP: SuperBuild.cmake - Clean code

COMP: SuperBuild.cmake - Clean code

Move variable WITH_COVERAGE, DOCUMENTATION_TARGET_IN_ALL and CTEST_USE_LAUNCHERS
into "ctk_cmake_boolean_args" list.

--- SuperBuild.cmake
+++ SuperBuild.cmake
@@ -166,6 +166,9 @@
 SET(ctk_cmake_boolean_args
   BUILD_TESTING
   CTK_USE_KWSTYLE
+  WITH_COVERAGE
+  DOCUMENTATION_TARGET_IN_ALL
+  CTEST_USE_LAUNCHERS
   ${ctk_libs_bool_vars}
   ${ctk_plugins_bool_vars}
   ${ctk_applications_bool_vars}
@@ -193,10 +196,7 @@
   CMAKE_ARGS
     ${ctk_superbuild_boolean_args}
     -DCTK_SUPERBUILD:BOOL=OFF
-    -DWITH_COVERAGE:BOOL=${WITH_COVERAGE}
-    -DDOCUMENTATION_TARGET_IN_ALL:BOOL=${DOCUMENTATION_TARGET_IN_ALL}
     -DDOCUMENTATION_ARCHIVES_OUTPUT_DIRECTORY:PATH=${DOCUMENTATION_ARCHIVES_OUTPUT_DIRECTORY}
-    -DCTEST_USE_LAUNCHERS:BOOL=${CTEST_USE_LAUNCHERS}
     -DCTK_SUPERBUILD_BINARY_DIR:PATH=${CTK_BINARY_DIR}
     -DCTK_CMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CTK_CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
     -DCTK_CMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CTK_CMAKE_LIBRARY_OUTPUT_DIRECTORY}


build_tools:cmake:riscv: make toolchain path user-settable (#5165)

Change RISCV_TOOLCHAIN_ROOT to be a user-settable variable. User can set
it in cmake configuration if the toolchain is not installed from
build_tools/riscv/riscv_bootstrap.sh.

--- build_tools/cmake/riscv.toolchain.cmake
+++ build_tools/cmake/riscv.toolchain.cmake
@@ -27,7 +27,7 @@

 set(RISCV_TOOL_PATH "$ENV{HOME}/riscv" CACHE PATH "RISC-V tool path")

-set(RISCV_TOOLCHAIN_ROOT "${RISCV_TOOL_PATH}/toolchain/clang/${RISCV_HOST_TAG}/RISCV")
+set(RISCV_TOOLCHAIN_ROOT "${RISCV_TOOL_PATH}/toolchain/clang/${RISCV_HOST_TAG}/RISCV" CACHE PATH "RISC-V compiler path")
 set(CMAKE_FIND_ROOT_PATH ${RISCV_TOOLCHAIN_ROOT})
 list(APPEND CMAKE_PREFIX_PATH "${RISCV_TOOLCHAIN_ROOT}")


ENH: Update elastix

ENH: Update elastix

--- SuperBuild/ExternalElastix.cmake
+++ SuperBuild/ExternalElastix.cmake
@@ -20,7 +20,7 @@
 set( proj Elastix )

 set( ELASTIX_GIT_REPOSITORY https://github.com/SuperElastix/elastix )
-set( ELASTIX_GIT_TAG 3809d045d2e0a28d1b57b1e1b59a5f3f6ae3d0da )
+set( ELASTIX_GIT_TAG 0ce6c24a2b74c0132f1a53848321f1c7a92162ea )

 UPDATE_SELX_SUPERBUILD_COMMAND(${proj})


--- plugins/sipe/ktpaccountskcm_plugin_sipe.desktop.cmake
+++ plugins/sipe/ktpaccountskcm_plugin_sipe.desktop.cmake
@@ -2,9 +2,11 @@
 Encoding=UTF-8
 Comment=Custom account configuration user interface for accounts using the sipe connection manager.
 Comment[cs]=Vlastní uživatelské rozhraní nastavení účtů pro účty používající správce spojení sipe.
+Comment[da]=Brugerflade til brugertilpasset kontokonfiguration til konti der bruger forbindelseshåndteringen sipe.
 Comment[de]=Eigene Benutzeroberfläche zum Einrichten von Zugängen, die die Sipe-Verbindungsverwaltung verwenden.
 Comment[fi]=Sipe-yhteyshallintaa käyttävien tilien mukautettu hallintakäyttöliittymä.
 Comment[ia]=Interfacie de usator pro configuration de conto personalisate pro contos usante le gerente de connexion Sipe.
+Comment[it]=Interfaccia utente personalizzata di configurazione account per account che usano il gestore di connessioni Sipe.
 Comment[nl]=Gebruikersinterface voor aangepaste accountconfiguratie voor accounts die de Sipe verbindingenbeheerder gebruiken.
 Comment[pt]=Interface de utilizador de configuração de contas personalizadas com o gestor de ligações Sipe.
 Comment[pt_BR]=Interface de configuração de contas personalizadas usando o gerenciador de conexões Sipe.
@@ -20,9 +22,11 @@
 Icon=blockdevice
 Name=Sipe Account Configuration User Interface
 Name[cs]=Uživatelské rozhraní nastavení účtu Sipe
+Name[da]=Brugerflade til konfiguration af sipe-konto
 Name[de]=Benutzeroberfläche zur Einrichtung von Sipe-Zugängen
 Name[fi]=Sipe-tilinmäärityksen käyttöliittymä
 Name[ia]=Interfacie de usator de configuration de conto de Sipe
+Name[it]=Interfaccia utente di configurazione account Sipe
 Name[nl]=Gebruikersinterface voor Sipe accountconfiguratie
 Name[pt]=Interface de Configuração de Contas do Sipe
 Name[pt_BR]=Interface de configuração de contas do Sipe