convert cmake file to LF

convert cmake file to LF

--- cmake/Finddokan.cmake
+++ cmake/Finddokan.cmake
@@ -1,40 +1,40 @@
-    #set(DOKAN_ROOT_PATHS "$ENV{PROGRAMFILES}/Dokan")
-
-    #MESSAGE( STATUS "DOKAN_ROOT_PATH: " ${DOKAN_ROOT_PATHS} )
-
-    set(DOKAN_FOUND TRUE)
-
-    set(DOKAN_ROOT_PATHS    "/cygdrive/c/Program Files/Dokan/Dokan Library-1.0.3"
-            "/c/Program Files/Dokan/Dokan Library-1.0.3"
-            "c:/Program Files/Dokan/Dokan Library-1.0.3")
-
-    find_path(DOKAN_INCLUDE_DIR
-            NAMES
-            dokan/dokan.h
-            PATHS
-            ${DOKAN_ROOT_PATHS}
-            PATH_SUFFIXES
-            include
-            )
-
-
-    if(NOT DOKAN_INCLUDE_DIRS)
-        set(DOKAN_FOUND FALSE)
-    endif(NOT DOKAN_INCLUDE_DIRS)
-
-    SET(CMAKE_FIND_LIBRARY_PREFIXES "")
-    SET(CMAKE_FIND_LIBRARY_SUFFIXES ".lib" ".dll")
-
-    find_library(DOKAN_LIB_DIR
-            NAMES
-            dokan1
-            PATHS
-            ${DOKAN_ROOT_PATHS}
-            )
-
-    if(NOT DOKAN_LIB_DIRS)
-        set(DOKAN_FOUND FALSE)
-    endif(NOT DOKAN_LIB_DIRS)
-
-    MESSAGE( STATUS "DOKAN_INCLUDE_DIR: " ${DOKAN_INCLUDE_DIR} )
+    #set(DOKAN_ROOT_PATHS "$ENV{PROGRAMFILES}/Dokan")
+
+    #MESSAGE( STATUS "DOKAN_ROOT_PATH: " ${DOKAN_ROOT_PATHS} )
+
+    set(DOKAN_FOUND TRUE)
+
+    set(DOKAN_ROOT_PATHS    "/cygdrive/c/Program Files/Dokan/Dokan Library-1.0.3"
+            "/c/Program Files/Dokan/Dokan Library-1.0.3"
+            "c:/Program Files/Dokan/Dokan Library-1.0.3")
+
+    find_path(DOKAN_INCLUDE_DIR
+            NAMES
+            dokan/dokan.h
+            PATHS
+            ${DOKAN_ROOT_PATHS}
+            PATH_SUFFIXES
+            include
+            )
+
+
+    if(NOT DOKAN_INCLUDE_DIRS)
+        set(DOKAN_FOUND FALSE)
+    endif(NOT DOKAN_INCLUDE_DIRS)
+
+    SET(CMAKE_FIND_LIBRARY_PREFIXES "")
+    SET(CMAKE_FIND_LIBRARY_SUFFIXES ".lib" ".dll")
+
+    find_library(DOKAN_LIB_DIR
+            NAMES
+            dokan1
+            PATHS
+            ${DOKAN_ROOT_PATHS}
+            )
+
+    if(NOT DOKAN_LIB_DIRS)
+        set(DOKAN_FOUND FALSE)
+    endif(NOT DOKAN_LIB_DIRS)
+
+    MESSAGE( STATUS "DOKAN_INCLUDE_DIR: " ${DOKAN_INCLUDE_DIR} )
     MESSAGE( STATUS "DOKAN_LIB_DIR: " ${DOKAN_LIB_DIR} )


Solve the problem of std=c++11 flag is not passed to the NVCC.

--- cmake/TbagFlags.cmake
+++ cmake/TbagFlags.cmake
@@ -52,26 +52,29 @@

 #/// Assign Position Independent Code.
 macro (tbag_flags__set_position_independent_code)
-    if (CMAKE_VERSION VERSION_LESS "3.0.2")
-        set (CMAKE_C_FLAGS   "${CMAKE_C_FLAGS}   -fPIC")
-        set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC")
-    endif ()
+    #if (CMAKE_VERSION VERSION_LESS "3.0.2")
+    set (CMAKE_C_FLAGS   "${CMAKE_C_FLAGS}   -fPIC")
+    set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC")
+    #endif ()
+
+    # Don't use this variables:
     set (CMAKE_POSITION_INDEPENDENT_CODE ON) # -fPIC
 endmacro ()

 #/// Assign C++11 standard.
 macro (tbag_flags__set_cpp_standard_11)
-    if (CMAKE_VERSION VERSION_LESS "3.1")
-        #if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU" AND NOT CUDA_FOUND)
-        #    set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++11")
-        #else ()
-        #    set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
-        #endif ()
-        set (CMAKE_CXX_FLAGS "-std=c++11 ${CMAKE_CXX_FLAGS}")
-    endif ()
+    #if (CMAKE_VERSION VERSION_LESS "3.1")
+    ##if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU" AND NOT CUDA_FOUND)
+    ##    set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++11")
+    ##else ()
+    ##    set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
+    ##endif ()
+    set (CMAKE_CXX_FLAGS "-std=c++11 ${CMAKE_CXX_FLAGS}")
+    #endif ()

-    set (CMAKE_CXX_STANDARD     11) # C++ standard 11
-    set (CMAKE_CXX_EXTENSIONS  OFF) # Don't change the -std=gnu++11 to -std=c++11
+    # Don't use this variables:
+    #set (CMAKE_CXX_STANDARD     11) # C++ standard 11
+    #set (CMAKE_CXX_EXTENSIONS  OFF) # Don't change the -std=gnu++11 to -std=c++11
 endmacro ()

 #/// Assign default debug definition.


prepend file

prepend file

--- cmake/UseCyclus.cmake
+++ cmake/UseCyclus.cmake
@@ -346,7 +346,7 @@
     message(STATUS "Compiling ${_srcname} fast from assembly ${_asmname}")
     set(_filename "${_asmname}")
   endif()
-  set(CYCLUS_CORE_SRC ${CYCLUS_CORE_SRC} "${_filename}")
+  set(CYCLUS_CORE_SRC "${_filename}" ${CYCLUS_CORE_SRC})

   # set some compile flags for the selected file
   if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")


fix compilation (clang doesn't have -Wmisleading-indentation)

--- cmake/configure.cmake
+++ cmake/configure.cmake
@@ -10,7 +10,9 @@
         set(CMAKE_CXX_FLAGS                     "-std=c++14 -pedantic -march=native -mtune=native -ffunction-sections")
         set(CMAKE_CXX_FLAGS                     "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wconversion")
         set(CMAKE_CXX_FLAGS                     "${CMAKE_CXX_FLAGS} -Woverloaded-virtual")
+if(CMAKE_CXX_COMPILER_ID MATCHES GNU)
         set(CMAKE_CXX_FLAGS                     "${CMAKE_CXX_FLAGS} -Wmisleading-indentation")
+endif()
         set(CMAKE_CXX_FLAGS                     "${CMAKE_CXX_FLAGS} -Wreorder")
         set(CMAKE_CXX_FLAGS                     "${CMAKE_CXX_FLAGS} -Wnon-virtual-dtor")
         set(CMAKE_CXX_FLAGS                     "${CMAKE_CXX_FLAGS} -Wcast-align")


CMake: Change Python version required to be at least 3.5 (#6081)

Removed the restriction for the Python version to be >= 3.6 but < 3.8.
Now it has to be >=3.5, lower versions are EOL.

Removed the search for Python2 too since nothing uses it anymore.

Fixes osquery/osquery#6079

--- cmake/utilities.cmake
+++ cmake/utilities.cmake
@@ -100,17 +100,7 @@
 endfunction()

 function(findPythonExecutablePath)
-  find_package(Python2 COMPONENTS Interpreter REQUIRED)
-  set(EX_TOOL_PYTHON2_EXECUTABLE_PATH "${Python2_EXECUTABLE}" PARENT_SCOPE)
-
-  find_package(Python3 3.7 EXACT COMPONENTS Interpreter)
-
-  if(NOT Python3_FOUND)
-    find_package(Python3 3.6 EXACT COMPONENTS Interpreter)
-    if(NOT Python3_FOUND)
-      message(FATAL_ERROR "Could not find a suitable Python 3 version. Please install a version >= 3.6 but < 3.8")
-    endif()
-  endif()
+  find_package(Python3 3.5 COMPONENTS Interpreter REQUIRED)

   set(EX_TOOL_PYTHON3_EXECUTABLE_PATH "${Python3_EXECUTABLE}" PARENT_SCOPE)
 endfunction()


Added rosbuild_include(), #2350, and deprecated the old way of automatically including cmake code.

--- core/rosbuild/public.cmake
+++ core/rosbuild/public.cmake
@@ -114,7 +114,14 @@
   else(_rospack_failed)
     separate_arguments(_rospack_invoke_result)
     set(_rospack_${_varname} ${_rospack_invoke_result})
-    set(${_prefix}_${_varname} "${_rospack_invoke_result}" CACHE INTERNAL "")
+    # We don't cache results that contain newlines, because
+    # they make CMake's cache unhappy. This check should only affect calls
+    # to `rospack plugins`, which we don't need to cache.
+    if(_rospack_invoke_result MATCHES ".*\n.*")
+      set(${_prefix}_${_varname} "${_rospack_invoke_result}")
+    else(_rospack_invoke_result MATCHES ".*\n.*")
+      set(${_prefix}_${_varname} "${_rospack_invoke_result}" CACHE INTERNAL "")
+    endif(_rospack_invoke_result MATCHES ".*\n.*")
   endif(_rospack_failed)
 endmacro(rosbuild_invoke_rospack)

@@ -361,7 +368,8 @@
   endforeach(_l)

   # Also collect cmake fragments exported by packages that depend on
-  # rosbuild.
+  # rosbuild.  This behavior is deprecated, in favor of using
+  # rosbuild_include() to explicitly include cmake code from other packages.
   rosbuild_invoke_rospack(rosbuild _rosbuild EXPORTS plugins --attrib=cmake --top=${_project})
   list(LENGTH _rosbuild_EXPORTS _rosbuild_EXPORTS_length)

@@ -383,6 +391,7 @@

   foreach(_f ${_rosbuild_EXPORTS_stripped})
     list(APPEND _cmake_fragments ${_f})
+    message("\n[rosbuild] WARNING: the file ${_f} is being included automatically.  This behavior is deprecated.  The package containing that file should instead export the directory containing the file, and you should use rosbuild_include() to include the file explicitly.\n")
   endforeach(_f)

   # Now include them all
@@ -1130,3 +1139,27 @@
   endif()
 endmacro(rosbuild_check_for_sse)

+macro(rosbuild_include pkg module)
+  # Find exported cmake directories
+  rosbuild_invoke_rospack(rosbuild _rosbuild EXPORTS plugins --attrib=cmake_directory --top=${_project})
+  string(REGEX REPLACE "\n" ";" _rosbuild_EXPORTS_stripped "${_rosbuild_EXPORTS}")
+  list(LENGTH _rosbuild_EXPORTS_stripped _rosbuild_EXPORTS_stripped_length)
+  set(_idx 0)
+  set(_found False)
+  while(_idx LESS ${_rosbuild_EXPORTS_stripped_length} AND NOT _found)
+    list(GET _rosbuild_EXPORTS_stripped ${_idx} _pkg)
+    math(EXPR _idx "${_idx} + 1")
+    list(GET _rosbuild_EXPORTS_stripped ${_idx} _dir)
+    if("${_pkg}" STREQUAL "${pkg}")
+      message("[rosbuild] Including ${_dir}/${module}.cmake")
+      include(${_dir}/${module}.cmake)
+      # Poor man's break
+      set(_found True)
+    endif("${_pkg}" STREQUAL "${pkg}")
+    math(EXPR _idx "${_idx} + 1")
+  endwhile(_idx LESS ${_rosbuild_EXPORTS_stripped_length} AND NOT _found)
+  if(NOT _found)
+    message(FATAL_ERROR "[rosbuild] Failed to include ${module} from ${pkg}")
+  endif(NOT _found)
+endmacro(rosbuild_include)
+


try to use -Wno-unused-local-typedefs only with GCC 4.8

--- cmake/VcMacros.cmake
+++ cmake/VcMacros.cmake
@@ -202,7 +202,11 @@
             # GCC gives bogus "array subscript is above array bounds" warnings in math.cpp
             AddCompilerFlag("-Wno-array-bounds")
          endif()
-         AddCompilerFlag("-Wno-unused-local-typedefs")
+         if(Vc_GCC_VERSION VERSION_GREATER "4.7.99")
+            # GCC 4.8 warns about stuff we don't care about
+            # Some older GCC versions have problems to note that they don't support the flag
+            AddCompilerFlag("-Wno-unused-local-typedefs")
+         endif()
       endif()
       vc_add_compiler_flag(Vc_DEFINITIONS "-Wabi")
       vc_add_compiler_flag(Vc_DEFINITIONS "-fabi-version=0") # ABI version 4 is required to make __m128 and __m256 appear as different types. 0 should give us the latest version.


only report a failed test if there is some certain output

--- cmake/checkgdb.cmake
+++ cmake/checkgdb.cmake
@@ -1,11 +1,13 @@
-execute_process(COMMAND ${EXECUTABLE} ${FILE} ${ARGS} RESULT_VARIABLE RESULT)
-string(TOUPPER "${RESULT}" RESULT)
-if (RESULT MATCHES ".*THE FOLLOWING TESTS FAILED.*")
+execute_process(COMMAND ${EXECUTABLE} ${FILE} ${ARGS} RESULT_VARIABLE RESULT OUTPUT_VARIABLE OUTPUT)
+string(TOUPPER "${OUTPUT}" OUTPUT)
+if (RESULT)
 	#if (GDB_COMMAND AND GDB_SCRIPT)
 	#	execute_process(COMMAND ${GDB_COMMAND}
 	#		--command=${GDB_SCRIPT}
 	#		--args ${EXECUTABLE} ${FILE} ${ARGS}
 	#			RESULT_VARIABLE GDB_RESULT)
 	#endif()
-	MESSAGE( FATAL_ERROR "FAIL:  ${ARGS}" )
-endif()
+	if ("${OUTPUT}" MATCHES ".*THE FOLLOWING TESTS FAILED.*")
+		MESSAGE( FATAL_ERROR "FAIL:  ${ARGS}, EXITCODE:  ${RESULT}" )
+	endif ("${OUTPUT}" MATCHES ".*THE FOLLOWING TESTS FAILED.*")
+endif (RESULT)


small update

small update

git-svn-id: 6b1c4fe79111c0bc0cce83313250759594f8984b@5988 e128ff1e-fa79-4151-a8cb-522299a2c450

--- cmake/gsConfig.cmake
+++ cmake/gsConfig.cmake
@@ -172,6 +172,11 @@
    set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unknown-pragmas")
 endif()

+if (CMAKE_COMPILER_IS_GNUCXX AND NOT POLICY CMP0063)
+  set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fvisibility=hidden")
+  set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility=hidden -fvisibility-inlines-hidden")
+endif()
+
 if (CMAKE_CXX_COMPILER_ID MATCHES "Intel" AND NOT GISMO_WITH_OPENMP)
    if ( CMAKE_SYSTEM_NAME MATCHES "Linux" )
      set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -diag-disable 3180") #comma for more warns


build: macos: openssl: Search homebrewed OpenSSL installed directory

Signed-off-by: Hiroshi Hatake <a476a6e5b5893650242fbf0b2961500a9bd9032e@calyptia.com>

--- cmake/homebrew.cmake
+++ cmake/homebrew.cmake
@@ -20,3 +20,15 @@
   message(STATUS "Using flex keg installed by Homebrew at ${HOMEBREW_FLEX_PREFIX}")
   set(FLEX_EXECUTABLE "${HOMEBREW_FLEX_PREFIX}/bin/flex")
 endif()
+
+# Also, searching homebrewed OpenSSL automatically.
+execute_process(
+  COMMAND brew --prefix openssl
+  RESULT_VARIABLE HOMEBREW_OPENSSL
+  OUTPUT_VARIABLE HOMEBREW_OPENSSL_PREFIX
+  OUTPUT_STRIP_TRAILING_WHITESPACE
+  )
+if (HOMEBREW_OPENSSL EQUAL 0 AND EXISTS "${HOMEBREW_OPENSSL_PREFIX}")
+  message(STATUS "Using openssl keg installed by Homebrew at ${HOMEBREW_OPENSSL_PREFIX}")
+  set(OPENSSL_ROOT_DIR "${HOMEBREW_OPENSSL_PREFIX}")
+endif()


Move to the latest ParaView tag

Move to the latest ParaView tag

This is slated to be the 5.3.0 release tag if no more issues are found.

--- versions.cmake
+++ versions.cmake
@@ -92,7 +92,7 @@
   set(_paraview_revision "master")
 else()
   # Test the revision with OpenGL2 rendering before updating, update often!
-  set(_paraview_revision "bef675740bde7a29af66110d1dc6843fafdc51d7")
+  set(_paraview_revision "21353a09b9172b4204e9412716e978fdd30da7d2")
 endif()
 add_revision(paraview
   GIT_REPOSITORY "https://gitlab.kitware.com/paraview/paraview.git"


Remove MSN_WEBCAM because it is not used

--- config-kopete.h.cmake
+++ config-kopete.h.cmake
@@ -4,9 +4,6 @@

 /* Define if you have xmms libraries and header files. */
 #cmakedefine HAVE_XMMS 1
-
-/* Define if MSN webcam support can be enabled */
-#define MSN_WEBCAM 1

 /* Define to compile with GSM SMS support */
 /* #undef INCLUDE_SMSGSM */


[Build] Suppressed wrong end-of-lines.

[Build] Suppressed wrong end-of-lines.

--- config/project_config_embeddable.cmake
+++ config/project_config_embeddable.cmake
@@ -1280,9 +1280,7 @@

   # Convenient message to the user/developer
   if (NOT CMAKE_INSTALL_RPATH_USE_LINK_PATH)
-    install (CODE "message (\"On Unix-based platforms, run "
-	  "export LD_LIBRARY_PATH=${INSTALL_LIB_DIR}:\$LD_LIBRARY_PATH "
-	  "once per session\")")
+    install (CODE "message (\"On Unix-based platforms, run export LD_LIBRARY_PATH=${INSTALL_LIB_DIR}:\$LD_LIBRARY_PATH once per session\")")
   endif (NOT CMAKE_INSTALL_RPATH_USE_LINK_PATH)

 endmacro (module_library_add_standard)


Ensure a module's root directory is in the include path.

--- CPM.cmake
+++ CPM.cmake
@@ -458,6 +458,7 @@
   # the parent scope).
   add_definitions(${CPM_DEFINITIONS})
   include_directories(${CPM_INCLUDE_DIRS})
+  include_directories(${CMAKE_CURRENT_SOURCE_DIR})

 endmacro()


HarfBuzz: build without glib

HarfBuzz: build without glib

--- packages/harfbuzz.cmake
+++ packages/harfbuzz.cmake
@@ -7,6 +7,8 @@
         --prefix=${MINGW_INSTALL_PREFIX}
         --disable-shared
         --with-icu=no
+        --with-glib=no
+        --with-gobject=no
         --disable-gtk-doc-html
     BUILD_COMMAND ${MAKE}
     INSTALL_COMMAND ${MAKE} install


see if gcov and clang versions match (#150)

* see if gcov and clang versions match

* maybe we should be using lcov... since we apt-get it

* whitespace

* what version is llvm-cov?

* use llvm-cov

* llvm-cov gcov

* remove cov version checks

--- core/cmake/CoverallsGenerateGcov.cmake
+++ core/cmake/CoverallsGenerateGcov.cmake
@@ -33,8 +33,8 @@
 #
 # Example for running as standalone CMake script from the command line:
 # (Note it is important the -P is at the end...)
-# $ cmake -DCOV_PATH=$(pwd)
-#         -DCOVERAGE_SRCS="catcierge_rfid.c;catcierge_timer.c"
+# $ cmake -DCOV_PATH=$(pwd)
+#         -DCOVERAGE_SRCS="catcierge_rfid.c;catcierge_timer.c"
 #         -P ../cmake/CoverallsGcovUpload.cmake
 #
 CMAKE_MINIMUM_REQUIRED(VERSION 2.8)
@@ -65,7 +65,8 @@
 # CMake list format.
 string(REGEX REPLACE "\\*" ";" COVERAGE_SRCS ${COVERAGE_SRCS})

-find_program(GCOV_EXECUTABLE gcov)
+find_program(GCOV_EXECUTABLE llvm-cov)
+message("Found ${GCOV_EXECUTABLE}")

 if (NOT GCOV_EXECUTABLE)
 	message(FATAL_ERROR "gcov not found! Aborting...")
@@ -121,9 +122,9 @@
 #
 macro(get_source_path_from_gcov_filename _SRC_FILENAME _GCOV_FILENAME)

-	# /path/to/project/root/build/#path#to#project#root#subdir#the_file.c.gcov
-	# ->
-	# #path#to#project#root#subdir#the_file.c.gcov
+	# /path/to/project/root/build/#path#to#project#root#subdir#the_file.c.gcov
+	# ->
+	# #path#to#project#root#subdir#the_file.c.gcov
 	get_filename_component(_GCOV_FILENAME_WEXT ${_GCOV_FILENAME} NAME)

 	# #path#to#project#root#subdir#the_file.c.gcov -> /path/to/project/root/subdir/the_file.c
@@ -161,7 +162,7 @@
 	# If -p is not specified then the file is named only "the_file.c.gcov"
 	#
 	execute_process(
-		COMMAND ${GCOV_EXECUTABLE} -p -o ${GCDA_DIR} ${GCDA}
+		COMMAND ${GCOV_EXECUTABLE} gcov -p -o ${GCDA_DIR} ${GCDA}
 		WORKING_DIRECTORY ${COV_PATH}
 	)
 endforeach()
@@ -191,9 +192,9 @@
 # ALL_GCOV_FILES =
 #				/path/to/project/root/build/#path#to#project#root#subdir#the_file.c.gcov
 #				/path/to/project/root/build/#path#to#project#root#subdir#other_file.c.gcov
-#
+#
 # Result should be:
-# GCOV_FILES =
+# GCOV_FILES =
 #				/path/to/project/root/build/#path#to#project#root#subdir#the_file.c.gcov
 #
 set(GCOV_FILES "")
@@ -206,9 +207,9 @@
 foreach (GCOV_FILE ${ALL_GCOV_FILES})

 	#
-	# /path/to/project/root/build/#path#to#project#root#subdir#the_file.c.gcov
-	# ->
-	# /path/to/project/root/subdir/the_file.c
+	# /path/to/project/root/build/#path#to#project#root#subdir#the_file.c.gcov
+	# ->
+	# /path/to/project/root/subdir/the_file.c
 	get_source_path_from_gcov_filename(GCOV_SRC_PATH ${GCOV_FILE})

 	# Is this in the list of source files?
@@ -306,8 +307,8 @@
 		# Example of what we're parsing:
 		# Hitcount  |Line | Source
 		# "        8:   26:        if (!allowed || (strlen(allowed) == 0))"
-		string(REGEX REPLACE
-			"^([^:]*):([^:]*):(.*)$"
+		string(REGEX REPLACE
+			"^([^:]*):([^:]*):(.*)$"
 			"\\1;\\2;\\3"
 			RES
 			"${GCOV_LINE}")
@@ -344,7 +345,7 @@

 			# Lines with 0 line numbers are metadata and can be ignored.
 			if (NOT ${LINE} EQUAL 0)
-
+
 				if (DO_SKIP)
 					set(GCOV_FILE_COVERAGE "${GCOV_FILE_COVERAGE}null, ")
 				else()
@@ -424,7 +425,6 @@

 file(WRITE "${COVERALLS_OUTPUT_FILE}" "${JSON}")
 message("###########################################################################")
-message("Generated coveralls JSON containing coverage data:")
+message("Generated coveralls JSON containing coverage data:")
 message("${COVERALLS_OUTPUT_FILE}")
 message("###########################################################################")
-


Trying different cmake variables

Trying different cmake variables

--- appveyor.cmake
+++ appveyor.cmake
@@ -1,2 +1,5 @@
 set(BUILD_DIR C:/projects/morebin CACHE PATH "")
-set(Boost_DIR C:/Libraries/boost_1_60_0 "")
+set(Boost_DIR C:/Libraries/boost_1_60_0 CACHE_PATH "")
+set(Boost_ROOT "${BOOST_DIR}" CACHE_PATH "")
+#set(Boost_INCLUDE_DIR "${Boost_DIR}/include" CACHE PATH "")
+#set(Boost_LIBRARY_DIR "${Boost_DIR}/lib" CACHE PATH "")


Add hunter_download_cache_{meta,raw}_file calls

--- cmake/modules/hunter_load_from_cache.cmake
+++ cmake/modules/hunter_load_from_cache.cmake
@@ -5,6 +5,8 @@
 include(hunter_cache_run)
 include(hunter_create_cache_meta_directory)
 include(hunter_create_dependency_entry)
+include(hunter_download_cache_meta_file)
+include(hunter_download_cache_raw_file)
 include(hunter_internal_error)
 include(hunter_status_debug)
 include(hunter_test_string_not_empty)
@@ -74,6 +76,10 @@
   set(basic_deps_done "${cache_meta_dir}/basic-deps.DONE")
   set(basic_deps_info "${cache_meta_dir}/basic-deps.info")

+  hunter_download_cache_meta_file(
+      LOCAL "${basic_deps_info}" DONE "${basic_deps_done}"
+  )
+
   if(NOT EXISTS "${basic_deps_done}")
     hunter_status_debug(
         "Cache miss (no basic dependencies info found: ${basic_deps_done})"
@@ -137,6 +143,10 @@

   set(cache_sha1_file "${cache_meta_dir}/cache.sha1")
   set(cache_done_file "${cache_meta_dir}/CACHE.DONE")
+
+  hunter_download_cache_meta_file(
+      LOCAL "${cache_sha1_file}" DONE "${cache_done_file}"
+  )

   if(NOT EXISTS "${cache_done_file}")
     hunter_status_debug(
@@ -179,6 +189,9 @@
   # Unpack cache archive
   file(READ "${cache_sha1_file}" cache_sha1)
   set(archive_file "${cache_directory}/raw/${cache_sha1}.tar.bz2")
+
+  hunter_download_cache_raw_file(LOCAL "${archive_file}" SHA1 "${cache_sha1}")
+
   if(NOT EXISTS "${archive_file}")
     hunter_internal_error("archive file not found: ${archive_file}")
   endif()


Build only the hiredis static library.

Build only the hiredis static library.

--- config/Hiredis.cmake
+++ config/Hiredis.cmake
@@ -12,7 +12,7 @@
     TMP_DIR ${EXTERNALS_DIR}/hiredis/tmp
     UPDATE_COMMAND "" # don't update, i.e., always use the same version
     CONFIGURE_COMMAND "" # skip configure
-    BUILD_COMMAND make
+    BUILD_COMMAND make static
     INSTALL_COMMAND "" # skip install
   )


package.json.cmake: create node version specific package.json

Signed-off-by: Brendan Le Foll <3e0e8c4069934e8b47d99704927a85c66c0ceb33@intel.com>

--- src/javascript/package.json.cmake
+++ src/javascript/package.json.cmake
@@ -5,7 +5,7 @@
   "homepage": "http://github.com/intel-iot-devkit/mraa",
   "main" : "./mraa.node",
   "engines": {
-    "node": ">= 0.10.x"
+    "node": ">= @NODE_VERSION_MAJOR@.@NODE_VERSION_MINOR@.x"
   },
   "bugs": {
     "url" : "http://github.com/intel-iot-devkit/mraa/issues"


small fix

small fix

--- client/client-multi/client-c/toolchains/cc32xx.cmake
+++ client/client-multi/client-c/toolchains/cc32xx.cmake
@@ -30,7 +30,7 @@
   set(CC32XX_SDK "${KAA_TOOLCHAIN_PATH}/cc3200-sdk")
 endif()

-CMAKE_FORCE_C_COMPILER(${KAA_ARM_TOOLCHAIN}/bin/arm-none-eabi-gcc${WIN_EXE} GNU)
+CMAKE_FORCE_C_COMPILER(${KAA_ARM_TOOLCHAIN}/bin/arm-none-eabi-gcc${EXECUTABLE_SUFFIX} GNU)

 set(CMAKE_C_FLAGS "-mthumb -mcpu=cortex-m4 -ffunction-sections -fdata-sections -MD -std=c99 -g -O0 -static"  CACHE STRING "" FORCE)
 set(CMAKE_A_FLAGS "-mthumb -mcpu=cortex-m4 -MD -static"  CACHE STRING "" FORCE)


BUG: Temporarily removed ctest_update() from SuperBuild, still hoping to fix "ERROR: script returned exit code 255"

--- SuperBuild/CTest.cmake
+++ SuperBuild/CTest.cmake
@@ -48,8 +48,7 @@
 set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} \"${CTEST_SOURCE_DIRECTORY}\"")

 ctest_start("Nightly")
-# Added ctest_update() to ensure that the commit SHA will be passed to CDash, and GitHub.
-ctest_update()
+# TODO Add ctest_update() to ensure that the commit SHA will be passed to CDash, and GitHub.
 ctest_configure()
 ctest_build()
 ctest_submit( PARTS Configure Build )


gen.cmake: handle generated dependencies

Signed-off-by: Karol Gugala <38af71640571ee4b5093d4f69ffca1ac454f2948@antmicro.com>

--- make/gen.cmake
+++ make/gen.cmake
@@ -300,6 +300,7 @@

   foreach(PREFIX ${N_TEMPLATE_PREFIXES})
     foreach(SRC ${N_TEMPLATE_SRCS})
+      set(REAL_INCLUDE_FILES "")
       string(
         REPLACE
           "ntemplate."
@@ -314,6 +315,28 @@
           SRC_WITH_PREFIX
           ${SRC_NO_NTEMPLATE}
       )
+      get_file_target(SRC_TARGET_NAME ${SRC})
+      get_target_property(SRC_INCLUDE_FILES ${SRC_TARGET_NAME} INCLUDE_FILES)
+      foreach(INC ${SRC_INCLUDE_FILES})
+        get_filename_component(INC_FILE ${INC} NAME)
+        get_filename_component(INC_DIR ${INC} DIRECTORY)
+        # template all the include files
+        string(
+          REPLACE
+            "ntemplate."
+            ""
+            INC_NO_NTEMPLATE
+            ${INC_FILE}
+        )
+        string(
+          REPLACE
+            "N"
+            ${PREFIX}
+            INC_WITH_PREFIX
+            ${INC_NO_NTEMPLATE}
+        )
+        list(APPEND REAL_INCLUDE_FILES ${INC_DIR}/${INC_WITH_PREFIX})
+      endforeach()
       get_file_location(SRC_LOCATION ${SRC})
       set(DEPS "")
       append_file_dependency(DEPS ${SRC})
@@ -329,7 +352,9 @@
         WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
       )

-      add_file_target(FILE ${SRC_WITH_PREFIX} GENERATED DEPENDS ${SRC})
+      add_file_target(FILE ${SRC_WITH_PREFIX} GENERATED)
+      get_file_target(SRC_TARGET_NAME ${SRC_WITH_PREFIX})
+      set_target_properties(${SRC_TARGET_NAME} PROPERTIES INCLUDE_FILES "${REAL_INCLUDE_FILES}")

       list(APPEND OUTPUTS ${SRC_WITH_PREFIX})


ZLIB bugfix.

ZLIB bugfix.

--- VAD_ZLIB.cmake
+++ VAD_ZLIB.cmake
@@ -103,7 +103,7 @@
         message(STATUS "zlib patch version: ${ZLIB_VERSION_PATCH}")
     endif()
     if(_ZLIB_VERSION_LIST_LENGTH GREATER 3)
-        list(GET _ZLIB_VERSION_LIST 2 ZLIB_VERSION_TWEAK)
+        list(GET _ZLIB_VERSION_LIST 3 ZLIB_VERSION_TWEAK)
         set(ZLIB_VERSION_TWEAK ${ZLIB_VERSION_TWEAK} CACHE INTERNAL "")
         message(STATUS "zlib tweak version: ${ZLIB_VERSION_TWEAK}")
     endif()


build system: quote values in __component_write_properties

--- tools/cmake/component.cmake
+++ tools/cmake/component.cmake
@@ -126,7 +126,7 @@
         foreach(property ${component_properties})
             __component_get_property(val ${component_target} ${property})
             set(component_properties_text
-                "${component_properties_text}\nset(__component_${component_target}_${property} ${val})")
+                "${component_properties_text}\nset(__component_${component_target}_${property} \"${val}\")")
         endforeach()
         file(WRITE ${output_file} "${component_properties_text}")
     endforeach()


Bug#42733: Type-punning warnings when compiling MySQL -- strict aliasing violations.

Due to the extent of aliasing violations in the MySQL source
code, at this time it is safer to disable strict aliasing related
optimizations in release builds.

As of this patch, only GCC enables strict aliasing by default.
Hence, use the -fno-strict-aliasing option to disable the
aliasing rules.

cmake/build_configurations/mysql_release.cmake:
  Add -fno-strict-aliasing to release builds.

--- cmake/build_configurations/mysql_release.cmake
+++ cmake/build_configurations/mysql_release.cmake
@@ -131,16 +131,16 @@

   # Default GCC flags
   IF(CMAKE_COMPILER_IS_GNUCC)
-    SET(COMMON_C_FLAGS               "-g -static-libgcc -fno-omit-frame-pointer")
+    SET(COMMON_C_FLAGS               "-g -static-libgcc -fno-omit-frame-pointer -fno-strict-aliasing")
     SET(CMAKE_C_FLAGS_DEBUG          "-O ${COMMON_C_FLAGS}")
     SET(CMAKE_C_FLAGS_RELWITHDEBINFO "-O3 ${COMMON_C_FLAGS}")
   ENDIF()
   IF(CMAKE_COMPILER_IS_GNUCXX)
-    SET(COMMON_CXX_FLAGS               "-g -static-libgcc -fno-omit-frame-pointer")
+    SET(COMMON_CXX_FLAGS               "-g -static-libgcc -fno-omit-frame-pointer -fno-strict-aliasing")
     SET(CMAKE_CXX_FLAGS_DEBUG          "-O ${COMMON_CXX_FLAGS}")
     SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O3 ${COMMON_CXX_FLAGS}")
   ENDIF()
-
+
   # HPUX flags
   IF(CMAKE_SYSTEM_NAME MATCHES "HP-UX")
     IF(CMAKE_C_COMPILER_ID MATCHES "HP")
@@ -156,7 +156,7 @@
     ENDIF()
     SET(WITH_SSL no)
   ENDIF()
-
+
   # Linux flags
   IF(CMAKE_SYSTEM_NAME MATCHES "Linux")
     IF(CMAKE_C_COMPILER_ID MATCHES "Intel")
@@ -173,18 +173,18 @@
       SET(WITH_SSL no)
     ENDIF()
   ENDIF()
-
+
   # OSX flags
   IF(APPLE)
-    SET(COMMON_C_FLAGS                 "-g -fno-common")
+    SET(COMMON_C_FLAGS                 "-g -fno-common -fno-strict-aliasing")
     # XXX: why are we using -felide-constructors on OSX?
-    SET(COMMON_CXX_FLAGS               "-g -fno-common -felide-constructors")
+    SET(COMMON_CXX_FLAGS               "-g -fno-common -felide-constructors -fno-strict-aliasing")
     SET(CMAKE_C_FLAGS_DEBUG            "-O ${COMMON_C_FLAGS}")
     SET(CMAKE_CXX_FLAGS_DEBUG          "-O ${COMMON_CXX_FLAGS}")
     SET(CMAKE_C_FLAGS_RELWITHDEBINFO   "-Os ${COMMON_C_FLAGS}")
     SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-Os ${COMMON_CXX_FLAGS}")
   ENDIF()
-
+
   # Solaris flags
   IF(CMAKE_SYSTEM_NAME MATCHES "SunOS")
     IF(CMAKE_SYSTEM_VERSION VERSION_GREATER "5.9")
@@ -219,7 +219,7 @@
       ENDIF()
     ENDIF()
   ENDIF()
-
+
   IF(CMAKE_C_FLAGS_DEBUG)
     SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG}"
       CACHE STRING "Debug C compile flags")


* Fixed error in configuration test for QLayouts

svn path=/trunk/KDE/kdebindings/smoke/; revision=642110

--- qt/qtguess.pl.cmake
+++ qt/qtguess.pl.cmake
@@ -315,7 +315,7 @@
 						    void setGeometry( const QRect & ) { };
                             QLayoutItem* itemAt(int) const {return (QLayoutItem*) NULL;}
                             QLayoutItem* takeAt(int) {return (QLayoutItem*) NULL;}
-                            int QFoo::count() const {return 0;}
+                            int count() const {return 0;}

  						};
  					"],


ENH: dependency to Superimpose application

--- Modules/Applications/AppFusion/otb-module.cmake
+++ Modules/Applications/AppFusion/otb-module.cmake
@@ -10,6 +10,7 @@
     OTBInterpolation

   TEST_DEPENDS
+    OTBAppProjection
     OTBTestKernel
     OTBCommandLine


COMP: Update LesionSizingToolkit for external build and style test failures.

The protocol also needs to be http because https is not yet supported.

Change-Id: Idff3ddc72c55920ade7847f1978f0c90b5ce5945

--- Modules/Remote/LesionSizingToolkit.remote.cmake
+++ Modules/Remote/LesionSizingToolkit.remote.cmake
@@ -1,5 +1,5 @@
 itk_fetch_module(LesionSizingToolkit
   "Framework for determining the sizes of lesions in medical images."
-  GIT_REPOSITORY ${git_protocol}://public.kitware.com/LesionSizingToolkit.git
-  GIT_TAG fd9cfcef3bb4f7678bc50ecbe6ad51c6998cc3db
+  GIT_REPOSITORY http://public.kitware.com/LesionSizingToolkit.git
+  GIT_TAG 100ec226866cca13a6ed0f5c2d3520f45750424d
   )


ffmpeg: update 4.1 (OpenCV 4.x branch)

ffmpeg: update 4.1 (OpenCV 4.x branch)

ffmpeg 4.0.2 -> 4.1

--- 3rdparty/ffmpeg/ffmpeg.cmake
+++ 3rdparty/ffmpeg/ffmpeg.cmake
@@ -1,9 +1,9 @@
-# Binaries branch name: ffmpeg/master_20180918
-# Binaries were created for OpenCV: e628fd7bce2b5d64c36b5bdc55a37c0ae78bc907
-ocv_update(FFMPEG_BINARIES_COMMIT "c88df798e9dc3d63840f913714563a730245464a")
-ocv_update(FFMPEG_FILE_HASH_BIN32 "48c95ce37d5aa6b15b3ad116e331ebc1")
-ocv_update(FFMPEG_FILE_HASH_BIN64 "d33eca57ae1cfd6287b975b98125f7a3")
-ocv_update(FFMPEG_FILE_HASH_CMAKE "5fd49e1b84e9f402ca155e27c92d2ce9")
+# Binaries branch name: ffmpeg/master_20181106
+# Binaries were created for OpenCV: 2c6f1ab57d4250ee46e32d1b51c056431965b470
+ocv_update(FFMPEG_BINARIES_COMMIT "759a23e24ab787a0979f8a93103dcc3105ec10c1")
+ocv_update(FFMPEG_FILE_HASH_BIN32 "849286ccc527c99e5a218b67f13c6e8c")
+ocv_update(FFMPEG_FILE_HASH_BIN64 "96444a4645753aaafa296479665c9185")
+ocv_update(FFMPEG_FILE_HASH_CMAKE "f710891525a04586d565d0e700e62a9c")

 function(download_win_ffmpeg script_var)
   set(${script_var} "" PARENT_SCOPE)


Look for lua5.1

Look for lua5.1

--- extras/buildsystem/cmake/include/FindLua.cmake
+++ extras/buildsystem/cmake/include/FindLua.cmake
@@ -13,6 +13,9 @@
     set(Lua_FOUND FALSE CACHE INTERNAL "")

     pkg_check_modules(Lua lua>=5.1 lua5.1)
+    if (NOT Lua_FOUND)
+        pkg_check_modules(Lua lua5.1)
+    endif (NOT Lua_FOUND)

     if (NOT Lua_FOUND)
         find_library( Lua_LIBRARY NAMES lua5.1 lua51 lua)


Handle Visual Studio 2022

Handle Visual Studio 2022

--- CMake/mitkFunctionGetMSVCVersion.cmake
+++ CMake/mitkFunctionGetMSVCVersion.cmake
@@ -8,6 +8,11 @@
     set(VISUAL_STUDIO_VERSION_MINOR ${version_minor} PARENT_SCOPE)
   elseif(MSVC_VERSION GREATER_EQUAL 1920 AND MSVC_VERSION LESS 1930)
     set(VISUAL_STUDIO_PRODUCT_NAME "Visual Studio 2019" PARENT_SCOPE)
+    set(VISUAL_STUDIO_VERSION_MAJOR 14 PARENT_SCOPE)
+    string(SUBSTRING ${MSVC_VERSION} 2 -1 version_minor)
+    set(VISUAL_STUDIO_VERSION_MINOR ${version_minor} PARENT_SCOPE)
+  elseif(MSVC_VERSION GREATER_EQUAL 1930 AND MSVC_VERSION LESS 1940)
+    set(VISUAL_STUDIO_PRODUCT_NAME "Visual Studio 2022" PARENT_SCOPE)
     set(VISUAL_STUDIO_VERSION_MAJOR 14 PARENT_SCOPE)
     string(SUBSTRING ${MSVC_VERSION} 2 -1 version_minor)
     set(VISUAL_STUDIO_VERSION_MINOR ${version_minor} PARENT_SCOPE)


[changed] docs

[changed] docs

--- cmake/BOTG_INCLUDE.cmake
+++ cmake/BOTG_INCLUDE.cmake
@@ -1,3 +1,14 @@
+##
+##
+##cmake/BOTG_INCLUDE.cmake
+##------------------------------------------------------------------------------
+##This file is the key file to include from a project's central
+##CMakeLists.txt to perform the BootsOnTheGround magic. It even
+##bootstraps in a copy of the BootsOnTheGround repo if not found.
+##
+##.. code-block:: cmake
+##
+
 #This function is special and needs to be here so it can be part of a
 #Bootstrapping operation.
 MACRO( BOTG_DownloadExternalProjects external_projects )


Update CodeCoverage.cmake

Update CodeCoverage.cmake

--- cmake/CodeCoverage.cmake
+++ cmake/CodeCoverage.cmake
@@ -1,4 +1,4 @@
-IF(DEFINED ENV{VAR})
+IF(DEFINED ENV{GCOV_PATH})
     SET(GCOV_PATH $ENV{GCOV_PATH})
 ELSE()
     FIND_PROGRAM(GCOV_PATH gcov)


Remove superfluous testing files (as changeset 5c4d6666125a but more complete)

--- cmake/EigenTesting.cmake
+++ cmake/EigenTesting.cmake
@@ -68,11 +68,7 @@
     endif()
   endif()

-  if(EIGEN_BIN_BASH_EXISTS)
-    add_test(${testname_with_suffix} "${Eigen_SOURCE_DIR}/test/runtest.sh" "${testname_with_suffix}")
-  else()
-    add_test(${testname_with_suffix} "${targetname}")
-  endif()
+  add_test(${testname_with_suffix} "${targetname}")

   # Specify target and test labels accoirding to EIGEN_CURRENT_SUBPROJECT
   get_property(current_subproject GLOBAL PROPERTY EIGEN_CURRENT_SUBPROJECT)


Bug 914: fix compiler detection on windows
(grafted from d0828c602f7a055cbe51459e936741b5ff8e414c)

--HG--
extra : source : d0828c602f7a055cbe51459e936741b5ff8e414c

--- cmake/EigenTesting.cmake
+++ cmake/EigenTesting.cmake
@@ -359,22 +359,29 @@
       endif()
     else()
     # on all other system we rely on ${CMAKE_CXX_COMPILER}
-    # supporting a "--version" flag
+    # supporting a "--version" or "/version" flag
+
+    if(WIN32 AND NOT CYGWIN)
+      set(EIGEN_CXX_FLAG_VERSION "/version")
+    else()
+      set(EIGEN_CXX_FLAG_VERSION "--version")
+    endif()

     # check whether the head command exists
     find_program(HEAD_EXE head NO_CMAKE_ENVIRONMENT_PATH NO_CMAKE_PATH NO_CMAKE_SYSTEM_PATH)
     if(HEAD_EXE)
-      execute_process(COMMAND ${CMAKE_CXX_COMPILER} --version
+      execute_process(COMMAND ${CMAKE_CXX_COMPILER} ${EIGEN_CXX_FLAG_VERSION}
                       COMMAND head -n 1
                       OUTPUT_VARIABLE eigen_cxx_compiler_version_string OUTPUT_STRIP_TRAILING_WHITESPACE)
     else()
-      execute_process(COMMAND ${CMAKE_CXX_COMPILER} --version
+      execute_process(COMMAND ${CMAKE_CXX_COMPILER}  ${EIGEN_CXX_FLAG_VERSION}
                       OUTPUT_VARIABLE eigen_cxx_compiler_version_string OUTPUT_STRIP_TRAILING_WHITESPACE)
       string(REGEX REPLACE "[\n\r].*"  ""  eigen_cxx_compiler_version_string  ${eigen_cxx_compiler_version_string})
     endif()

     ei_get_compilerver_from_cxx_version_string("${eigen_cxx_compiler_version_string}" CNAME CVER)
     set(${VAR} "${CNAME}-${CVER}")
+
   endif()
 endmacro(ei_get_compilerver)


improve compiler and architecture detection

--- cmake/EigenTesting.cmake
+++ cmake/EigenTesting.cmake
@@ -298,23 +298,31 @@

     if( my_service_pack )
       set(${VAR} ${my_service_pack})
-	else()
-	  set(${VAR} "na")
-    endif()
-  else()
-    # on all other system we rely on ${CMAKE_CXX_COMPILER}
-	# supporting a "--version" flag
-	exec_program(${CMAKE_CXX_COMPILER}
-	  ARGS --version
-	  OUTPUT_VARIABLE eigen_cxx_compiler_version
-	)
-	# here I try to extract the version string
-	# - TODO: this can most likely be improved and fixed
-    string(REGEX REPLACE ".* ([0-9])\\.([0-9])\\.([0-9]).*" "\\1.\\2.\\3"
-      eigen_cxx_compiler_version ${eigen_cxx_compiler_version})
-	# again, here is room for improvement
-	# what if the compiler is not "g++" !?
-    set(${VAR} "g++${eigen_cxx_compiler_version}")
+    else()
+      set(${VAR} "na")
+    endif()
+  else()
+    # on all other system we rely on ${CMAKE_CXX_COMPILER}
+    # supporting a "--version" flag
+    exec_program( ${CMAKE_CXX_COMPILER}
+                  ARGS --version
+                  OUTPUT_VARIABLE eigen_cxx_compiler_version_raw
+                )
+    # first extract the compiler name which is the first word
+    string( REGEX REPLACE ".*(llvm\\-g\\+\\+|g\\+\\+|icpc|clang).*" "\\1"
+            eigen_cxx_compiler_name ${eigen_cxx_compiler_version_raw})
+
+    if(eigen_cxx_compiler_name MATCHES ".*g\\+\\+.*")
+      string( REGEX REPLACE ".* ([0-9])\\.([0-9])\\.([0-9]).*" "\\1.\\2.\\3"
+              eigen_cxx_compiler_version ${eigen_cxx_compiler_version_raw})
+    elseif(eigen_cxx_compiler_name MATCHES "icpc|clang")
+      string( REGEX REPLACE ".* ([0-9]*)\\.([0-9]*) .*" "\\1.\\2"
+              eigen_cxx_compiler_version ${eigen_cxx_compiler_version_raw})
+    else()
+      set(eigen_cxx_compiler_version "_")
+    endif()
+
+    set(${VAR} "${eigen_cxx_compiler_name}-${eigen_cxx_compiler_version}")
   endif()
 endmacro(ei_get_compilerver)

@@ -378,7 +386,17 @@
 endmacro(ei_set_build_string)

 macro(ei_is_64bit_env VAR)
-  if(CMAKE_CL_64)
+
+  file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/is64.cpp"
+      "int main() { return (sizeof(int*) == 8 ? 1 : 0); }
+      ")
+  try_run(run_res compile_res
+         ${CMAKE_CURRENT_BINARY_DIR} "${CMAKE_CURRENT_BINARY_DIR}/is64.cpp"
+          RUN_OUTPUT_VARIABLE run_output)
+
+  if(compile_res AND run_res)
+    set(${VAR} ${run_res})
+  elseif(CMAKE_CL_64)
     set(${VAR} 1)
   elseif("$ENV{Platform}" STREQUAL "X64") # nmake 64 bit
     set(${VAR} 1)


fixed link issues with treejuce static library on linux

--- cmake/FindTREEJUCE.cmake
+++ cmake/FindTREEJUCE.cmake
@@ -42,6 +42,13 @@
 #
 # find library
 #
+
+if(WIN32)
+    set(treejuce_dep_libs version winmm Shlwapi Dbghelp)
+elseif(UNIX)
+    set(treejuce_dep_libs pthread dl)
+endif()
+
 if(TREEJUCE_SEARCH_STATIC)
     set(treejuce_lib_name "treejuce_s")
     set(CMAKE_FIND_LIBRARY_SUFFIXES ${CMAKE_STATIC_LIBRARY_SUFFIX})
@@ -49,18 +56,29 @@
     set(treejuce_lib_name "treejuce")
 endif()

-find_library(TREEJUCE_LIBRARIES ${treejuce_lib_name}
-    HINTS
-        ${TREEJUCE_SEARCH_PREFIX_LIB}
-        ${TREEJUCE_SEARCH_PREFIX}/${CMAKE_INSTALL_LIBDIR}
-        ${TREEJUCE_SEARCH_PREFIX}/lib
-)
+if(NOT TREEJUCE_LIBRARIES)
+    message("find treejuce libraries")
+    find_library(treejuce_main_lib ${treejuce_lib_name}
+        HINTS
+            ${TREEJUCE_SEARCH_PREFIX_LIB}
+            ${TREEJUCE_SEARCH_PREFIX}/${CMAKE_INSTALL_LIBDIR}
+            ${TREEJUCE_SEARCH_PREFIX}/lib
+    )
+    set_property(CACHE treejuce_main_lib
+        PROPERTY
+            ADVANCED 1
+    )
+    message(${treejuce_main_lib})
+    set(TREEJUCE_LIBRARIES ${treejuce_dep_libs} ${treejuce_main_lib} CACHE STRING "" FORCE)
+    message("for user: ${TREEJUCE_LIBRARIES}")
+endif()

 #
 # finalize
 #
 FIND_PACKAGE_HANDLE_STANDARD_ARGS(TREEJUCE
     REQUIRED_VARS
+        treejuce_main_lib
         TREEJUCE_BIN_BUILDER
         TREEJUCE_INCLUDE_DIR
         TREEJUCE_LIBRARIES


[cmake] hack to make CI look better

[cmake] hack to make CI look better

--- cmake/SiconosSetup.cmake
+++ cmake/SiconosSetup.cmake
@@ -82,12 +82,13 @@
 if(WITH_PYTHON_WRAPPER)
   find_package(PythonFull REQUIRED)
   include(FindPythonModule)
-endif()

-# --- xml schema. Used in tests. ---
-if(WITH_XML)
-  set(SICONOS_XML_SCHEMA "${CMAKE_SOURCE_DIR}/config/xmlschema/SiconosModelSchema-V3.7.xsd")
-  find_python_module(lxml REQUIRED)
+  # --- xml schema. Used in tests. ---
+  if(WITH_XML)
+    set(SICONOS_XML_SCHEMA "${CMAKE_SOURCE_DIR}/config/xmlschema/SiconosModelSchema-V3.7.xsd")
+    find_python_module(lxml REQUIRED)
+  endif()
+
 endif()


fix variable typo

fix variable typo

--- cmake/build_embree.cmake
+++ cmake/build_embree.cmake
@@ -38,7 +38,7 @@
 set(RTCORE_IGNORE_INVALID_RAYS     OFF CACHE INTERNAL "" FORCE)
 set(RTCORE_RAY_PACKETS             ON  CACHE INTERNAL "" FORCE)

-if (OSPRAY_USE_TBB)
+if (USE_TBB)
   set(RTCORE_TASKING_SYSTEM TBB CACHE INTERNAL "" FORCE)
 else ()
   set(RTCORE_TASKING_SYSTEM Internal CACHE INTERNAL "" FORCE)


added all tools to GCC as well - just to keep it symetric with CLANG

--- src/cmake/toolchains/gcc.cmake
+++ src/cmake/toolchains/gcc.cmake
@@ -2,3 +2,9 @@

 set(CMAKE_C_COMPILER   gcc)
 set(CMAKE_CXX_COMPILER g++)
+
+set(CMAKE_AR      "ar"      CACHE FILEPATH "ar")
+set(CMAKE_LINKER  "ld"      CACHE FILEPATH "ld")
+set(CMAKE_NM      "nm"      CACHE FILEPATH "nm")
+set(CMAKE_OBJDUMP "objdump" CACHE FILEPATH "objdump")
+set(CMAKE_RANLIB  "ranlib"  CACHE FILEPATH "ranlib")


disabled unit tests running in build

disabled unit tests running in build

--- tools/cmake/ANHLibrary.cmake
+++ tools/cmake/ANHLibrary.cmake
@@ -191,12 +191,12 @@
     	        ${CMAKE_CURRENT_BINARY_DIR}/${name}_tests.vcxproj.user @ONLY)
         ENDIF()

-        add_custom_command(
-            TARGET ${name}_test
-            POST_BUILD
-            COMMAND $<TARGET_FILE:${name}_test>
-            WORKING_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${configuration}
-        )
+        # add_custom_command(
+            # TARGET ${name}_test
+            # POST_BUILD
+            # COMMAND $<TARGET_FILE:${name}_test>
+            # WORKING_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${configuration}
+        # )

         add_test(
             NAME all_${name}_tests


Installed version of samples.cfg should reference samples plugins in ./

--HG--
branch : v1-7

--- CMake/InstallResources.cmake
+++ CMake/InstallResources.cmake
@@ -17,16 +17,16 @@
   set(OGRE_MEDIA_DIR_DBG "../../${OGRE_MEDIA_PATH}")
   set(OGRE_PLUGIN_DIR_REL ".")
   set(OGRE_PLUGIN_DIR_DBG ".")
-  set(OGRE_SAMPLES_DIR_REL "Samples")
-  set(OGRE_SAMPLES_DIR_DBG "Samples")
+  set(OGRE_SAMPLES_DIR_REL ".")
+  set(OGRE_SAMPLES_DIR_DBG ".")
 elseif (UNIX)
   set(OGRE_MEDIA_PATH "share/OGRE/media")
   set(OGRE_MEDIA_DIR_REL "../${OGRE_MEDIA_PATH}")
   set(OGRE_MEDIA_DIR_DBG "../../${OGRE_MEDIA_PATH}")
   set(OGRE_PLUGIN_DIR_REL "../lib/OGRE")
   set(OGRE_PLUGIN_DIR_DBG "../../lib/OGRE")
-  set(OGRE_SAMPLES_DIR_REL "../lib/OGRE/Samples")
-  set(OGRE_SAMPLES_DIR_DBG "../lib/OGRE/Samples")
+  set(OGRE_SAMPLES_DIR_REL "../lib/OGRE")
+  set(OGRE_SAMPLES_DIR_DBG "../lib/OGRE")
 endif ()

 # configure plugins.cfg


Small fix for 64-bit linux systems that don't install in lib64.

--- CMake/itkExternal_FFTW.cmake
+++ CMake/itkExternal_FFTW.cmake
@@ -102,10 +102,9 @@
     if(APPLE)
       set(FFTW_LIBDIR ${ITK_BINARY_DIR}/fftw/lib)
     else()
+      set(FFTW_LIBDIR ${ITK_BINARY_DIR}/fftw/lib)
       if(CMAKE_SIZEOF_VOID_P MATCHES 8)
-        set(FFTW_LIBDIR ${ITK_BINARY_DIR}/fftw/lib64)
-      else()
-        set(FFTW_LIBDIR ${ITK_BINARY_DIR}/fftw/lib)
+        list(APPEND FFTW_LIBDIR ${ITK_BINARY_DIR}/fftw/lib64)
       endif()
     endif()
     link_directories(${FFTW_LIBDIR})


Add mirror of SimpleITK External Data repository

This mirror is utilized for CMake External Data

--- CMake/sitkExternalData.cmake
+++ CMake/sitkExternalData.cmake
@@ -32,6 +32,10 @@
 mark_as_advanced(ExternalData_URL_TEMPLATES)
 if(NOT SimpleITK_FORBID_DOWNLOADS)
   list(APPEND ExternalData_URL_TEMPLATES
+
+    # Data mirrored from SimpleITKExternalData repository
+    "https://erie.nlm.nih.gov/SimpleITKExternalData/%(algo)/%(hash)"
+
     # Data published by MIDAS
     "https://placid.nlm.nih.gov/api/rest?method=midas.bitstream.download&checksum=%(hash)&algorithm=%(algo)"


Add library directories if needed when using an ITK module

--- CMake/sitkTargetUseITK.cmake
+++ CMake/sitkTargetUseITK.cmake
@@ -16,6 +16,10 @@

   itk_module_config(_itk ${itk_modules})

+  if(_itk_LIBRARY_DIRS)
+    link_libraries(${_itk_LIBRARY_DIRS})
+  endif()
+
   if(_itk_LIBRARIES)
     target_link_libraries( ${target_name}
       ${interface_keyword}


added shlwapi and version libs

added shlwapi and version libs

--- FindwxWidgets.cmake
+++ FindwxWidgets.cmake
@@ -446,7 +446,7 @@
       list(APPEND wxWidgets_LIBRARIES opengl32 glu32)
     endif()

-    list(APPEND wxWidgets_LIBRARIES winmm comctl32 rpcrt4 wsock32)
+    list(APPEND wxWidgets_LIBRARIES winmm comctl32 rpcrt4 wsock32 shlwapi version)
   endmacro()

   #-------------------------------------------------------------------


add default AMD targets

add default AMD targets


build:iree: Fix the duplicated cmake cache include

Add the cache include check following the example in Android NDK
android.toolchain.cmake
https://android-review.googlesource.com/c/platform/ndk/+/353248

Also remove the upfront "-lstdc++ -lm" flags since the math library is
included later and the system doesn't require stdc++ to be built.

Change-Id: I6cef50e7c9d30f848a58382134aa36be5fecc9d6
GitOrigin-RevId: 99146dfbbe93d1322192ddcd1c3ff0a5a77a7993

--- riscv_iree.cmake
+++ riscv_iree.cmake
@@ -6,7 +6,18 @@

 cmake_minimum_required (VERSION 3.13)

+# CMake invokes the toolchain file twice during the first build, but only once
+# during subsequent rebuilds. This was causing the various flags to be added
+# twice on the first build, and on a rebuild ninja would see only one set of the
+# flags and rebuild the world.
+# https://github.com/android-ndk/ndk/issues/323
+if(RISCV_TOOLCHAIN_INCLUDED)
+  return()
+endif(RISCV_TOOLCHAIN_INCLUDED)
+set(RISCV_TOOLCHAIN_INCLUDED true)
+
 set(CMAKE_SYSTEM_PROCESSOR riscv)
+set(CMAKE_CROSSCOMPILING ON CACHE BOOL "")

 if(CMAKE_HOST_SYSTEM_NAME STREQUAL Linux)
   set(RISCV_HOST_TAG linux)
@@ -40,7 +51,6 @@
   set(RISCV_LINKER_FLAGS "${RISCV_LINKER_FLAGS} -lstdc++ -lpthread -lm -ldl")
 elseif(RISCV_CPU STREQUAL "rv32-baremetal")
   set(CMAKE_SYSTEM_NAME Generic)
-  set(CMAKE_CROSSCOMPILING ON CACHE BOOL "")
   set(CMAKE_C_STANDARD 11)
   set(CMAKE_C_EXTENSIONS OFF)     # Force the usage of _ISOC11_SOURCE
   set(IREE_BUILD_BINDINGS_TFLITE OFF CACHE BOOL "" FORCE)
@@ -50,7 +60,6 @@
   set(CMAKE_SYSTEM_LIBRARY_PATH "${RISCV_TOOLCHAIN_ROOT}/riscv32-unknown-elf/lib")
   set(IREE_ENABLE_THREADING OFF CACHE BOOL "" FORCE)
   list(APPEND RISCV_COMPILER_FLAGS "-g3 -menable-experimental-extensions -march=rv32imfv0p10 -mabi=ilp32 -DIREE_PLATFORM_GENERIC=1 -DIREE_SYNCHRONIZATION_DISABLE_UNSAFE=1 -DIREE_FILE_IO_ENABLE=0 -DIREE_TIME_NOW_FN=\"\{ return 0; \}\"")
-  set(RISCV_LINKER_FLAGS "-lstdc++ -lm")
 endif()

 set(CMAKE_C_FLAGS             "${RISCV_COMPILER_FLAGS} ${CMAKE_C_FLAGS}")


Exclude Python test files from CMake PIP package. (#10302)

* Exclude *_test.py files from the CMake-built PIP package.

* Add stray _test.py file to the PIP package.

* Nit. Convert tabs to spaces in tf_python.cmake

--- tensorflow/contrib/cmake/tf_python.cmake
+++ tensorflow/contrib/cmake/tf_python.cmake
@@ -174,8 +174,15 @@
     if(NOT ${ADD_PYTHON_MODULE_DONTCOPY})
         foreach(script ${module_python_srcs})
             get_filename_component(REL_DIR ${script} DIRECTORY)
-            add_custom_command(TARGET tf_python_copy_scripts_to_destination PRE_BUILD
-              COMMAND ${CMAKE_COMMAND} -E copy ${tensorflow_source_dir}/${script} ${CMAKE_CURRENT_BINARY_DIR}/tf_python/${script})
+            # NOTE(mrry): This rule may exclude modules that should be part of
+            # the distributed PIP package
+            # (e.g. tensorflow/contrib/testing/python/framework/util_test.py),
+            # so we currently add explicit commands to include those files
+            # later on in this script.
+            if (NOT "${script}" MATCHES "_test\.py$")
+	        add_custom_command(TARGET tf_python_copy_scripts_to_destination PRE_BUILD
+                  COMMAND ${CMAKE_COMMAND} -E copy ${tensorflow_source_dir}/${script} ${CMAKE_CURRENT_BINARY_DIR}/tf_python/${script})
+            endif()
         endforeach()
     endif()
 endfunction()
@@ -863,9 +870,17 @@
     tf_python_touchup_modules
     tf_python_ops
     tf_extension_ops)
+
+# Fix-up Python files that were not included by the add_python_module() macros.
 add_custom_command(TARGET tf_python_build_pip_package POST_BUILD
   COMMAND ${CMAKE_COMMAND} -E copy ${tensorflow_source_dir}/tensorflow/tools/pip_package/setup.py
                                    ${CMAKE_CURRENT_BINARY_DIR}/tf_python/)
+# This file is unfortunately excluded by the regex that excludes *_test.py
+# files, but it is imported into tf.contrib, so we add it explicitly.
+add_custom_command(TARGET tf_python_copy_scripts_to_destination PRE_BUILD
+  COMMAND ${CMAKE_COMMAND} -E copy ${tensorflow_source_dir}/tensorflow/contrib/testing/python/framework/util_test.py
+                                   ${CMAKE_CURRENT_BINARY_DIR}/tf_python/tensorflow/contrib/testing/python/framework/)
+
 if(WIN32)
   add_custom_command(TARGET tf_python_build_pip_package POST_BUILD
     COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_BINARY_DIR}/$(Configuration)/pywrap_tensorflow_internal.dll


fixing include directory of depends to be able to transmit to parent project.

--- WkDepends.cmake
+++ WkDepends.cmake
@@ -161,7 +161,7 @@

 			#dependencies headers ( need to be included after project's own headers )
 			#Note : we use the include dir from source, not from the copy in binary dir.
-			file( TO_CMAKE_PATH ${dir_name}/${${subprj_name}_INCLUDE_DIR} subprj_include_path)
+			file( TO_CMAKE_PATH ${CMAKE_CURRENT_BINARY_DIR}/${dir_name}/${${subprj_name}_INCLUDE_DIR} subprj_include_path)
 			file( TO_CMAKE_PATH ${CMAKE_CURRENT_BINARY_DIR}/${dir_name}/CMakeFiles subprj_include_wk_path)

 			#To match a binary dependency variable names :


cosmetics

cosmetics

--- modules/git_info/git_info.cmake
+++ modules/git_info/git_info.cmake
@@ -10,14 +10,13 @@
 #   fetch: https://github.com/scisoft/autocmake/raw/master/modules/git_info/git_info_sub.cmake
 #          https://github.com/scisoft/autocmake/raw/master/modules/git_info/git_info.h.in

+# CMAKE_CURRENT_LIST_DIR is undefined in CMake 2.8.2
+# see https://public.kitware.com/Bug/print_bug_page.php?bug_id=11675
+# workaround: create CMAKE_CURRENT_LIST_DIR if it doesn't exist
+if(NOT DEFINED CMAKE_CURRENT_LIST_DIR)
+    get_filename_component(CMAKE_CURRENT_LIST_DIR ${CMAKE_CURRENT_LIST_FILE} PATH)
+endif()

-# note: cmake 2.8.2 has undefined variable CMAKE_CURRENT_LIST_DIR,
-# see https://public.kitware.com/Bug/print_bug_page.php?bug_id=11675
-# workaround from Google : create CMAKE_CURRENT_LIST_DIR if it doesn't exist
-if(NOT DEFINED CMAKE_CURRENT_LIST_DIR)
-    message(STATUS "The CMAKE_CURRENT_LIST_DIR variable defined in workaround")
-    get_filename_component(CMAKE_CURRENT_LIST_DIR ${CMAKE_CURRENT_LIST_FILE} PATH)
-endif(NOT DEFINED CMAKE_CURRENT_LIST_DIR)
 add_custom_command(
     OUTPUT ${PROJECT_BINARY_DIR}/git_info.h
     COMMAND ${CMAKE_COMMAND} -D_target_dir=${PROJECT_BINARY_DIR} -P git_info_sub.cmake


Fix Hexagon toolchain detection for default installer

--- cmake/toolchains/Toolchain-hexagon-7.2.10.cmake
+++ cmake/toolchains/Toolchain-hexagon-7.2.10.cmake
@@ -35,7 +35,7 @@
 include(common/px4_base)

 if(NOT HEXAGON_TOOLS_ROOT)
-	set(HEXAGON_TOOLS_ROOT /opt/HEXAGON_Tools/7.2.10/Tools)
+	set(HEXAGON_TOOLS_ROOT $ENV{HOME}/Qualcomm/HEXAGON_Tools/7.2.10/Tools)
 endif()

 macro (list2string out in)


- Copy library for RelWithDebInfo and MinSizeRel configurations.

--- source/cmake/tbb.cmake
+++ source/cmake/tbb.cmake
@@ -30,17 +30,17 @@

     add_custom_command(TARGET ${_target} POST_BUILD
         COMMAND ${CMAKE_COMMAND} -E copy_if_different
-        ${_tbb_bin_dir}/$<$<CONFIG:Debug>:"${_tbb_debug}">$<$<CONFIG:Release>:"${_tbb_release}">
+        ${_tbb_bin_dir}/$<$<CONFIG:Debug>:"${_tbb_debug}">$<$<CONFIG:Release>:"${_tbb_release}">$<$<CONFIG:RelWithDebInfo>:"${_tbb_release}">$<$<CONFIG:MinSizeRel>:"${_tbb_release}">
         "${PROJECT_BINARY_DIR}/$<CONFIGURATION>")

     add_custom_command(TARGET ${_target} POST_BUILD
         COMMAND ${CMAKE_COMMAND} -E copy_if_different
-        ${_tbb_bin_dir}/$<$<CONFIG:Debug>:"${_tbb_malloc_debug}">$<$<CONFIG:Release>:"${_tbb_malloc_release}">
+        ${_tbb_bin_dir}/$<$<CONFIG:Debug>:"${_tbb_malloc_debug}">$<$<CONFIG:Release>:"${_tbb_malloc_release}">$<$<CONFIG:RelWithDebInfo>:"${_tbb_malloc_release}">$<$<CONFIG:MinSizeRel>:"${_tbb_malloc_release}">
         "${PROJECT_BINARY_DIR}/$<CONFIGURATION>")

     add_custom_command(TARGET ${_target} POST_BUILD
         COMMAND ${CMAKE_COMMAND} -E copy_if_different
-        ${_tbb_bin_dir}/$<$<CONFIG:Debug>:"${_tbb_malloc_proxy_debug}">$<$<CONFIG:Release>:"${_tbb_malloc_proxy_release}">
+        ${_tbb_bin_dir}/$<$<CONFIG:Debug>:"${_tbb_malloc_proxy_debug}">$<$<CONFIG:Release>:"${_tbb_malloc_proxy_release}">$<$<CONFIG:RelWithDebInfo>:"${_tbb_malloc_proxy_release}">$<$<CONFIG:MinSizeRel>:"${_tbb_malloc_proxy_release}">
         "${PROJECT_BINARY_DIR}/$<CONFIGURATION>")

 endfunction()


Updated FW - fixes depth calculator issues on devices without calibration

--- cmake/Depthai/DepthaiDeviceSideConfig.cmake
+++ cmake/Depthai/DepthaiDeviceSideConfig.cmake
@@ -2,7 +2,7 @@
 set(DEPTHAI_DEVICE_SIDE_MATURITY "snapshot")

 # "full commit hash of device side binary"
-set(DEPTHAI_DEVICE_SIDE_COMMIT "1a02d5d1e684380dce117d0cb0c5fe83dc7bc8b2")
+set(DEPTHAI_DEVICE_SIDE_COMMIT "0149933b6f845f30b6d68defd59ca6f52bdaa78c")

 # "version if applicable"
 set(DEPTHAI_DEVICE_SIDE_VERSION "")


updated device side config

updated device side config

--- cmake/Depthai/DepthaiDeviceSideConfig.cmake
+++ cmake/Depthai/DepthaiDeviceSideConfig.cmake
@@ -2,7 +2,7 @@
 set(DEPTHAI_DEVICE_SIDE_MATURITY "snapshot")

 # "full commit hash of device side binary"
-set(DEPTHAI_DEVICE_SIDE_COMMIT "838304e38c1602b4b26faf3d97dd9cbb5540b1df")
+set(DEPTHAI_DEVICE_SIDE_COMMIT "78391482def7152f329a88ac19bdcf4d37d66bf6")

 # "version if applicable"
-set(DEPTHAI_DEVICE_SIDE_VERSION "")
+set(DEPTHAI_DEVICE_SIDE_VERSION "")


Update FW with error reporting for DetectionNetwork

--- cmake/Depthai/DepthaiDeviceSideConfig.cmake
+++ cmake/Depthai/DepthaiDeviceSideConfig.cmake
@@ -2,7 +2,7 @@
 set(DEPTHAI_DEVICE_SIDE_MATURITY "snapshot")

 # "full commit hash of device side binary"
-set(DEPTHAI_DEVICE_SIDE_COMMIT "73f5dfe7a318e713481dd00d134c2c597112afff")
+set(DEPTHAI_DEVICE_SIDE_COMMIT "bfb509700962dc4d8d78de9be30a49efa98e25f8")

 # "version if applicable"
 set(DEPTHAI_DEVICE_SIDE_VERSION "")


Update FW

Update FW

--- cmake/Depthai/DepthaiDeviceSideConfig.cmake
+++ cmake/Depthai/DepthaiDeviceSideConfig.cmake
@@ -2,7 +2,7 @@
 set(DEPTHAI_DEVICE_SIDE_MATURITY "snapshot")

 # "full commit hash of device side binary"
-set(DEPTHAI_DEVICE_SIDE_COMMIT "04bc17b1e79eaeaf9e0a03e8fa462e5377d0f2a6")
+set(DEPTHAI_DEVICE_SIDE_COMMIT "9628a4701a703d4654d2e965bbfcb74b6cee4915")

 # "version if applicable"
 set(DEPTHAI_DEVICE_SIDE_VERSION "")


aerofc cmake: add baro driver again

aerofc cmake: add baro driver again

--- cmake/configs/nuttx_aerofc-v1_default.cmake
+++ cmake/configs/nuttx_aerofc-v1_default.cmake
@@ -13,6 +13,7 @@
 	drivers/distance_sensor
 	drivers/gps
 	drivers/led
+	drivers/barometer/ms5611
 	drivers/magnetometer/hmc5883
 	drivers/magnetometer/ist8310
 	drivers/mpu9250


make: Add missing ekf2 module to PX4-v1 build

--- cmake/configs/nuttx_px4fmu-v1_default.cmake
+++ cmake/configs/nuttx_px4fmu-v1_default.cmake
@@ -73,6 +73,7 @@
 	modules/attitude_estimator_q
 	modules/ekf_att_pos_estimator
 	modules/position_estimator_inav
+	modules/ekf2

 	#
 	# Vehicle Control


[cmake] Fix setting cuda off when is not found

When cuda is not found, if teh cmake cuda flag was on it was not switched off, causing an error
when building RooFit on a platform without cuda.

--- cmake/modules/SearchInstalledSoftware.cmake
+++ cmake/modules/SearchInstalledSoftware.cmake
@@ -1741,8 +1741,15 @@
         set(cudnn OFF CACHE BOOL "Disabled because cudnn is not found" FORCE)
       endif()
     endif()
-  elseif(fail-on-missing)
-    message(FATAL_ERROR "CUDA not found. Ensure that the installation of CUDA is in the CMAKE_PREFIX_PATH")
+  else()
+    if(fail-on-missing)
+       message(FATAL_ERROR "CUDA not found. Ensure that the installation of CUDA is in the CMAKE_PREFIX_PATH")
+    else()
+       message(STATUS "CUDA not found. Disable RooFit and TMVA cuda computation")
+       set(cuda OFF CACHE BOOL "Disabled because Cuda is not found" FORCE)
+       set(cudnn OFF)
+       set(tmva-gpu OFF)
+    endif()
   endif()
 else()
   if (cudnn)


Fix for ROOT-7891 - installation instructions for root notebooks incomplete Ensure that the same Python version is used for the interpreter and the library.

--- cmake/modules/SearchInstalledSoftware.cmake
+++ cmake/modules/SearchInstalledSoftware.cmake
@@ -368,6 +368,7 @@
                     OUTPUT_VARIABLE PYTHON_PREFIX)
     set(CMAKE_PREFIX_PATH ${CMAKE_PREFIX_PATH} ${PYTHON_PREFIX})
   endif()
+  set(Python_ADDITIONAL_VERSIONS ${PYTHON_VERSION})
   find_package(PythonLibs)
   if(NOT PYTHONLIBS_FOUND)
     if(fail-on-missing)


Do not switch builtin_vc ON if Vc is not found externally. The use should do it explicitlyly (at least for the time being since Vc is not mandatory for ROOT)

--- cmake/modules/SearchInstalledSoftware.cmake
+++ cmake/modules/SearchInstalledSoftware.cmake
@@ -1114,13 +1114,15 @@
 endif()

 #---Check for Vc---------------------------------------------------------------------
-if(vc)
+if(vc OR builtin_vc)
   if(NOT builtin_vc)
     message(STATUS "Looking for Vc")
     find_package(Vc 1.0 CONFIG QUIET)
     if(NOT Vc_FOUND)
-      message(STATUS "Vc not found. Switching on builtin_vc option")
-      set(builtin_vc ON CACHE BOOL "" FORCE)
+      message(STATUS "Vc not found. Ensure that the installation of Vc is in the CMAKE_PREFIX_PATH")
+      message(STATUS "              Alternatively, you can also enable the option 'builtin_vc' to build the Vc libraries internally")
+      message(STATUS "              For the time being switching OFF 'vc' option")
+      set(vc OFF CACHE BOOL "" FORCE)
     endif()
     set(Vc_INCLUDE_DIRS ${Vc_INCLUDE_DIR})    # Missing from VcConfig.cmake
   endif()
@@ -1135,6 +1137,7 @@
     )
     set(Vc_INCLUDE_DIRS ${CMAKE_BINARY_DIR}/include)
     set(Vc_LIBRARIES ${CMAKE_BINARY_DIR}/lib/${CMAKE_STATIC_LIBRARY_PREFIX}Vc${CMAKE_STATIC_LIBRARY_SUFFIX})
+    set(vc ON CACHE BOOL "" FORCE)
   endif()
 endif()


test: Add option to transform actual xml to expected xml

If TEST_UPDATE is set in the environment and a test fails, transform the
actual xml output into the expected xml and overwrite the .xml.txt file
containing the latter.  This will help make sweeping updates to the
expected test output when sweeping output format changes are made.

--- test/run.cmake
+++ test/run.cmake
@@ -55,6 +55,7 @@
   foreach(e ${expect})
     if(EXISTS ${CMAKE_CURRENT_LIST_DIR}/expect/${e}.${o}.txt)
       file(READ ${CMAKE_CURRENT_LIST_DIR}/expect/${e}.${o}.txt expect_${o})
+      set(expect_${o}_file ${CMAKE_CURRENT_LIST_DIR}/expect/${e}.${o}.txt)
       break()
     endif()
   endforeach()
@@ -73,6 +74,17 @@
 endforeach()

 if(msg)
+  if("$ENV{TEST_UPDATE}" AND expect_xml_file AND EXISTS "${xml}")
+    set(update_xml "${actual_xml}")
+    string(REGEX REPLACE "^<\\?xml version=\"1.0\"\\?>" "^<\\\\?xml version=\"1.0\"\\\\?>" update_xml "${update_xml}")
+    string(REGEX REPLACE "<GCC_XML[^>]*>" "<GCC_XML[^>]*>" update_xml "${update_xml}")
+    string(REGEX REPLACE "artificial=\"1\"( throws=\"\")?" "artificial=\"1\"( throws=\"\")?" update_xml "${update_xml}")
+    string(REGEX REPLACE "size=\"[0-9]+\" align=\"[0-9]+\"" "size=\"[0-9]+\" align=\"[0-9]+\"" update_xml "${update_xml}")
+    string(REGEX REPLACE "<File id=\"(f[0-9]+)\" name=\"[^\"]*/test/input/([^\"]*)\"/>" "<File id=\"\\1\" name=\".*/test/input/\\2\"/>" update_xml "${update_xml}")
+    string(REGEX REPLACE "</GCC_XML>$" "</GCC_XML>$" update_xml "${update_xml}")
+    file(WRITE "${expect_xml_file}" "${update_xml}\n")
+  endif()
+
   string(REPLACE ";" "\" \"" command_string "\"${command}\"")
   set(msg "${msg}Command was:\n command> ${command_string}\n")
   message(SEND_ERROR


ctest: Fix the ctest build script.

ctest: Fix the ctest build script.

--- tests/ctest-default.cmake
+++ tests/ctest-default.cmake
@@ -58,14 +58,14 @@
 ctest_empty_binary_directory(${CTEST_BINARY_DIRECTORY})

 ctest_start(${CTEST_MODEL} TRACK ${CTEST_MODEL})
-ctest_update()
-ctest_configure()
-ctest_build()
-ctest_test()
+ctest_update(SOURCE ${CTEST_SOURCE_DIRECTORY})
+ctest_configure(BUILD ${CTEST_BINARY_DIRECTORY})
+ctest_build(BUILD ${CTEST_BINARY_DIRECTORY})
+ctest_test(BUILD ${CTEST_BINARY_DIRECTORY})
 if (WITH_MEMCHECK AND CTEST_COVERAGE_COMMAND)
-  ctest_coverage()
+  ctest_coverage(BUILD ${CTEST_BINARY_DIRECTORY})
 endif (WITH_MEMCHECK AND CTEST_COVERAGE_COMMAND)
 if (WITH_MEMCHECK AND CTEST_MEMORYCHECK_COMMAND)
-  ctest_memcheck()
+  ctest_memcheck(BUILD ${CTEST_BINARY_DIRECTORY})
 endif (WITH_MEMCHECK AND CTEST_MEMORYCHECK_COMMAND)
 ctest_submit()


minor upd

minor upd

--- cmake/CommonDefs.cmake
+++ cmake/CommonDefs.cmake
@@ -169,8 +169,8 @@
 # Compile tests in "test" subdir
 macro(add_testing)
 option(Testing "Enable testing" ON)
-include(EnableGtests) #defined in common/cmake
 if (Testing)
+    include(EnableGtests) #defined in common/cmake
     enable_testing()
     add_subdirectory(test)
 endif(Testing)


fixing cmake/findCython

fixing cmake/findCython

--- cmake/FindCython.cmake
+++ cmake/FindCython.cmake
@@ -43,9 +43,9 @@
     )
 endif()

-if( ${CYTHON_EXECUTABLE} STREQUAL "" )
+if( ${CYTHON_EXECUTABLE} STREQUAL "" OR ${CYTHON_EXECUTABLE} STREQUAL "CYTHON_EXECUTABLE-NOTFOUND" )
   SET( Cython_FOUND FALSE )
-else( NOT ${CYTHON_EXECUTABLE} STREQUAL "" )
+else()
   SET( Cython_FOUND TRUE )

   # get the version strings


Fixing FindGear2D.cmake

Fixing FindGear2D.cmake

--- cmake/FindGear2D.cmake
+++ cmake/FindGear2D.cmake
@@ -11,26 +11,29 @@
 if (NOT Gear2D_FOUND)

 if (WIN32)
-	message(STATUS "Trying windoze $ENV{PROGRAMFILES}")
-	find_path(Gear2D_INCLUDE_DIR gear2d.h
-		HINTS
-		$ENV{GEAR2DDIR}
-		PATHS
-		"$ENV{PROGRAMFILES}\\Gear2D\\include"
-		"$ENV{PROGRAMFILES(X86)}\\Gear2D\\include"
-		"C:\\Gear2D\\include"
-		"$ENV{PROGRAMFILES}\\Gear2D\\include\\gear2d"
-		"$ENV{PROGRAMFILES(X86)}\\Gear2D\\include\\gear2d"
-		"C:\\Gear2D\\include\\gear2d"
-	)
-
-	find_library(
-		Gear2D_LIBRARY gear2d
-		PATHS
-		"$ENV{PROGRAMFILES}\\Gear2D\\bin"
-		"$ENV{PROGRAMFILES(x86)}\\Gear2D\\bin"
-		"C:\\Gear2D\\bin"
-	)
+  message(STATUS "Trying windoze $ENV{PROGRAMFILES}")
+  find_path(Gear2D_INCLUDE_DIR gear2d.h
+    HINTS
+    $ENV{GEAR2DDIR}
+    PATHS
+    "$ENV{PROGRAMFILES}\\Gear2D\\include"
+    "$ENV{PROGRAMFILES(X86)}\\Gear2D\\include"
+    "C:\\Gear2D\\include"
+    "$ENV{PROGRAMFILES}\\Gear2D\\include\\gear2d"
+    "$ENV{PROGRAMFILES(X86)}\\Gear2D\\include\\gear2d"
+    "C:\\Gear2D\\include\\gear2d"
+  )
+
+  find_library(
+    Gear2D_LIBRARY gear2d
+    HINTS
+    $ENV{GEAR2DDIR}
+    PATHS
+    "$ENV{PROGRAMFILES}\\Gear2D\\"
+    "$ENV{PROGRAMFILES(X86)}\\Gear2D\\"
+    "C:\\Gear2D\\"
+    PATH_SUFFIXES lib bin
+  )

   find_program(
     Gear2D_EXECUTABLE gear2d.exe
@@ -38,79 +41,79 @@
     $ENV{GEAR2DDIR}
     PATHS
     "$ENV{PROGRAMFILES}\\Gear2D\\bin"
-		"$ENV{PROGRAMFILES(x86)}\\Gear2D\\bin"
-		"C:\\Gear2D\\bin"
+    "$ENV{PROGRAMFILES(x86)}\\Gear2D\\bin"
+    "C:\\Gear2D\\bin"
   )
 else ()
-	find_path(Gear2D_INCLUDE_DIR gear2d.h
-		HINTS
-		$ENV{GEAR2DDIR}
-		PATH_SUFFIXES include/gear2d include
-		PATHS
-		~/Library/Frameworks
-		/Library/Frameworks
-		/usr/local/include/gear2d
-		/usr/include/gear2d
-		/sw # Fink
-		/opt/local # DarwinPorts
-		/opt/csw # Blastwave
-		/opt
-	)
-
-	find_library(
-		Gear2D_LIBRARY gear2d
-		HINTS
-		$ENV{GEAR2DDIR}
-		PATH_SUFFIXES lib64 lib
-		PATHS
-		~/Library/Frameworks
-		/Library/Frameworks
-		/usr/local/lib/gear2d
-		/usr/lib/gear2d
-		/opt/local/lib
-		/opt/lib
-		/opt
-		/usr/local
-		/usr
-	)
+  find_path(Gear2D_INCLUDE_DIR gear2d.h
+    HINTS
+    $ENV{GEAR2DDIR}
+    PATH_SUFFIXES include/gear2d include
+    PATHS
+    ~/Library/Frameworks
+    /Library/Frameworks
+    /usr/local/include/gear2d
+    /usr/include/gear2d
+    /sw # Fink
+    /opt/local # DarwinPorts
+    /opt/csw # Blastwave
+    /opt
+  )
+
+  find_library(
+    Gear2D_LIBRARY gear2d
+    HINTS
+    $ENV{GEAR2DDIR}
+    PATH_SUFFIXES lib64 lib
+    PATHS
+    ~/Library/Frameworks
+    /Library/Frameworks
+    /usr/local/lib/gear2d
+    /usr/lib/gear2d
+    /opt/local/lib
+    /opt/lib
+    /opt
+    /usr/local
+    /usr
+  )

   find_program(
     Gear2D_EXECUTABLE gear2d
-		HINTS
-		$ENV{GEAR2DDIR}
-		PATH_SUFFIXES bin
-		PATHS
-		/usr/local/
-		/usr/
-		/opt/local/
-		/opt
+    HINTS
+    $ENV{GEAR2DDIR}
+    PATH_SUFFIXES bin
+    PATHS
+    /usr/local/
+    /usr/
+    /opt/local/
+    /opt
   )
 endif(WIN32)

 IF(Gear2D_INCLUDE_DIR)
-	IF(Gear2D_LIBRARY)
-		SET(Gear2D_FOUND TRUE)
-	ELSE(Gear2D_LIBRARY)
-		message(ERROR "Missing Gear2D_LIBRARY")
-	ENDIF(Gear2D_LIBRARY)
+  IF(Gear2D_LIBRARY)
+    SET(Gear2D_FOUND TRUE)
+  ELSE(Gear2D_LIBRARY)
+    message(ERROR "Missing Gear2D_LIBRARY")
+  ENDIF(Gear2D_LIBRARY)
 ELSE(Gear2D_INCLUDE_DIR)
-	message(ERROR "Missing Gear2D_INCLUDE_DIR")
+  message(FATAL_ERROR "Missing Gear2D_INCLUDE_DIR")
 ENDIF(Gear2D_INCLUDE_DIR)

 IF(Gear2D_FOUND)
-	get_filename_component(Gear2D_LINK_DIR ${Gear2D_LIBRARY} PATH)
+  get_filename_component(Gear2D_LINK_DIR ${Gear2D_LIBRARY} PATH)
     execute_process(COMMAND ${Gear2D_EXECUTABLE} -v OUTPUT_VARIABLE Gear2D_VERSION OUTPUT_STRIP_TRAILING_WHITESPACE)
-	SET(Gear2D_COMPONENT_PREFIX ${Gear2D_LINK_DIR}/../lib/gear2d/component)
-	IF (NOT Gear2D_FIND_QUIETLY)
-		MESSAGE(STATUS "Found Gear2D: ${Gear2D_LIBRARY} version ${Gear2D_VERSION}")
-		MESSAGE(STATUS "Guessed Gear2D component prefix: ${Gear2D_COMPONENT_PREFIX}")
-	ENDIF (NOT Gear2D_FIND_QUIETLY)
+  SET(Gear2D_COMPONENT_PREFIX ${Gear2D_LINK_DIR}/../lib/gear2d/component)
+  IF (NOT Gear2D_FIND_QUIETLY)
+    MESSAGE(STATUS "Found Gear2D: ${Gear2D_LIBRARY} version ${Gear2D_VERSION}")
+    MESSAGE(STATUS "Guessed Gear2D component prefix: ${Gear2D_COMPONENT_PREFIX}")
+  ENDIF (NOT Gear2D_FIND_QUIETLY)
 ELSE(Gear2D_FOUND)
-	IF (Gear2D_FIND_REQUIRED)
-		MESSAGE(FATAL_ERROR "Could not find Gear2D.")
-	ENDIF (Gear2D_FIND_REQUIRED)
+  IF (Gear2D_FIND_REQUIRED)
+    MESSAGE(FATAL_ERROR "Could not find Gear2D.")
+  ENDIF (Gear2D_FIND_REQUIRED)
 ENDIF(Gear2D_FOUND)

 ENDIF(NOT Gear2D_FOUND)


Rename LLVM_LIBS to LLVM_LIBRARY

Rename LLVM_LIBS to LLVM_LIBRARY

--- cmake/clang/link.cmake
+++ cmake/clang/link.cmake
@@ -1,5 +1,5 @@
 if(NOT CUSTOM_CLANG)
-  set(LLVM_LIBS
+  set(LLVM_LIBRARY
     ${LLVM_LIB_PATH}/libLLVMLTO.a
     ${LLVM_LIB_PATH}/libLLVMObjCARCOpts.a
     ${LLVM_LIB_PATH}/libLLVMLinker.a


Fix typo for memqt device.

Fix typo for memqt device.

svn path=/trunk/; revision=11215

--- cmake/modules/qt.cmake
+++ cmake/modules/qt.cmake
@@ -102,7 +102,7 @@
     set(PLD_qtwidget OFF CACHE BOOL "Enable Qt interactive device" FORCE)
     set(PLD_svgqt OFF CACHE BOOL "Enable Qt SVG device" FORCE)
     set(PLD_extqt OFF CACHE BOOL "Enable Qt ext device" FORCE)
-    set(PLD_memqt OFF CACHE BOOL "Enable Qt ext device" FORCE)
+    set(PLD_memqt OFF CACHE BOOL "Enable Qt mem device" FORCE)
 endif(NOT ANY_QT_DEVICE)

 if(DEFAULT_NO_BINDINGS)


Fix indentation

Fix indentation

git-svn-id: 1af002208e930b4d920e7c2b948d1e98a012c795@111 a9d63959-f2ad-4865-b262-bf0e56cfafb6

--- cmake/pcl_openmp.cmake
+++ cmake/pcl_openmp.cmake
@@ -29,7 +29,7 @@
             if(OPENMP_FLAGS_${_flag})
                 set(OPENMP_FLAGS ${_flag})
                 message(STATUS "Found OpenMP flags: ${OPENMP_FLAGS}")
-								set(OPENMP_FLAGS_FOUND true)
+                set(OPENMP_FLAGS_FOUND true)
             endif(OPENMP_FLAGS_${_flag})
         endif(NOT OPENMP_FLAGS_FOUND)
     endforeach(_flag)


Declare a project dependency to force correct build order of externals.

--- config/Externals.cmake
+++ config/Externals.cmake
@@ -16,3 +16,5 @@

 include(SwigJS)
 include(RedisDocStore)
+add_dependencies(store_external swig_js)
+


cmake: group definitions

cmake: group definitions

--- config.h.cmake
+++ config.h.cmake
@@ -1,49 +1,88 @@
 /* config.h.cmake.  Generated from CMakeLists.txt by cmake.  */

-#define CONFIGURE_OPTIONS "${CONFIGURE_OPTIONS}"
+/* general constants */
+#define CONFIGURE_OPTIONS    "${CONFIGURE_OPTIONS}"

-#cmakedefine ENABLE_MEMORY_DEBUG 1
+#define HOST_CPU             "${CMAKE_HOST_SYSTEM_PROCESSOR}"
+#define HOST_OS              "${CMAKE_HOST_SYSTEM_NAME}"

-#define GRN_CONFIG_PATH   "${GRN_CONFIG_PATH}"
-#define GRN_LOG_PATH      "${GRN_LOG_PATH}"
-#define GRN_VERSION       "${GRN_VERSION}"
+#define VERSION              "${GRN_VERSION}"
+#define PACKAGE              "${PROJECT_NAME}"
+#define PACKAGE_NAME         "${PROJECT_NAME}"
+#define PACKAGE_STRING       "${PROJECT_NAME} ${GRN_VERSION}"
+#define PACKAGE_TARNAME      "${PACKAGE_TARNAME}"
+#define PACKAGE_URL          "${PACKAGE_URL}"
+#define PACKAGE_VERSION      "${GRN_VERSION}"

-#define GRN_DEFAULT_DB_KEY "${GRN_DEFAULT_DB_KEY}"
+/* groonga related constants */
+#define GRN_CONFIG_PATH      "${GRN_CONFIG_PATH}"
+#define GRN_LOG_PATH         "${GRN_LOG_PATH}"
+#define GRN_VERSION          "${GRN_VERSION}"
+
+#define GRN_DEFAULT_DB_KEY   "${GRN_DEFAULT_DB_KEY}"
 #define GRN_DEFAULT_ENCODING "${GRN_DEFAULT_ENCODING}"
-#define GRN_DEFAULT_MATCH_ESCALATION_THRESHOLD ${GRN_DEFAULT_MATCH_ESCALATION_THRESHOLD}
-#define GRN_DEFAULT_RELATIVE_DOCUMENT_ROOT "${GRN_DEFAULT_RELATIVE_DOCUMENT_ROOT}"
-#define GRN_DEFAULT_DOCUMENT_ROOT "${GRN_DEFAULT_DOCUMENT_ROOT}"
+#define GRN_DEFAULT_MATCH_ESCALATION_THRESHOLD \
+  ${GRN_DEFAULT_MATCH_ESCALATION_THRESHOLD}
+#define GRN_DEFAULT_RELATIVE_DOCUMENT_ROOT \
+  "${GRN_DEFAULT_RELATIVE_DOCUMENT_ROOT}"
+#define GRN_DEFAULT_DOCUMENT_ROOT \
+  "${GRN_DEFAULT_DOCUMENT_ROOT}"

-#define GRN_PLUGINS_DIR "${GRN_PLUGINS_DIR}"
-#define GRN_PLUGIN_SUFFIX "${GRN_PLUGIN_SUFFIX}"
+#define GRN_PLUGINS_DIR      "${GRN_PLUGINS_DIR}"
+#define GRN_PLUGIN_SUFFIX    "${GRN_PLUGIN_SUFFIX}"

-#cmakedefine GROONGA_USE_MAP_HUGETLB
+/* build switches */
+#cmakedefine USE_MEMORY_DEBUG
+#cmakedefine USE_MAP_HUGETLB
+#cmakedefine USE_AIO
+#cmakedefine USE_DYNAMIC_MALLOC_CHANGE
+#cmakedefine USE_EPOLL
+#cmakedefine USE_EXACT_ALLOC_COUNT
+#cmakedefine USE_FAIL_MALLOC
+#cmakedefine USE_FUTEX
+#cmakedefine USE_KQUEUE
+#cmakedefine USE_MSG_MORE
+#cmakedefine USE_MSG_NOSIGNAL
+#cmakedefine USE_POLL
+#cmakedefine USE_QUERY_ABORT
+#cmakedefine USE_SELECT

-#cmakedefine HAVE_BACKTRACE
-#cmakedefine HAVE_CLOCK_GETTIME
-#cmakedefine HAVE_CLOCK
+/* compiler specific build options */
+#cmakedefine _FILE_OFFSET_BITS
+#cmakedefine _GNU_SOURCE
+#cmakedefine _ISOC99_SOURCE
+#cmakedefine _LARGE_FILES
+#cmakedefine _NETBSD_SOURCE
+#cmakedefine _XOPEN_SOURCE
+#cmakedefine _XPG4_2
+#cmakedefine __EXTENSIONS__
+
+/* build environment */
+#cmakedefine WORDS_BIGENDIAN
+
+/* packages */
+#cmakedefine WITH_BENCHMARK
+#cmakedefine WITH_CUTTER
+#cmakedefine WITH_KYTEA
+#cmakedefine WITH_LIBMEMCACHED
+#cmakedefine WITH_LZO
+#cmakedefine WITH_MECAB
+#cmakedefine WITH_MESSAGE_PACK
+#cmakedefine WITH_NFKC
+#cmakedefine WITH_ZEROMQ
+#cmakedefine WITH_ZLIB
+
+/* headers */
 #cmakedefine HAVE_DLFCN_H
 #cmakedefine HAVE_ERRNO_H
 #cmakedefine HAVE_EXECINFO_H
-#cmakedefine HAVE_FPCLASSIFY
-#cmakedefine HAVE_GMTIME_R
 #cmakedefine HAVE_INTTYPES_H
-#cmakedefine HAVE_LIBEDIT
-#cmakedefine HAVE_LIBEVENT
-#cmakedefine HAVE_LIBM
-#cmakedefine HAVE_LIBRT
 #cmakedefine HAVE_LINUX_FUTEX_H
-#cmakedefine HAVE_LOCALTIME_R
-#cmakedefine HAVE_MECAB_DICTIONARY_INFO_T
 #cmakedefine HAVE_MEMORY_H
-#cmakedefine HAVE_MESSAGE_PACK
-#cmakedefine HAVE_MKOSTEMP
 #cmakedefine HAVE_NETDB_H
 #cmakedefine HAVE_NETINET_IN_H
 #cmakedefine HAVE_NETINET_TCP_H
-#cmakedefine HAVE_OPEN
 #cmakedefine HAVE_PTHREAD_H
-#cmakedefine HAVE_READ
 #cmakedefine HAVE_SIGNAL_H
 #cmakedefine HAVE_STDINT_H
 #cmakedefine HAVE_STDLIB_H
@@ -64,52 +103,24 @@
 #cmakedefine HAVE_TIME_H
 #cmakedefine HAVE_UCONTEXT_H
 #cmakedefine HAVE_UNISTD_H
+
+/* libraries */
+#cmakedefine HAVE_LIBEDIT
+#cmakedefine HAVE_LIBEVENT
+#cmakedefine HAVE_LIBM
+#cmakedefine HAVE_LIBRT
+
+/* structs */
+#cmakedefine HAVE_MECAB_DICTIONARY_INFO_T
+
+/* functions */
+#cmakedefine HAVE_BACKTRACE
+#cmakedefine HAVE_CLOCK
+#cmakedefine HAVE_CLOCK_GETTIME
+#cmakedefine HAVE_FPCLASSIFY
+#cmakedefine HAVE_GMTIME_R
+#cmakedefine HAVE_LOCALTIME_R
+#cmakedefine HAVE_MKOSTEMP
+#cmakedefine HAVE_OPEN
+#cmakedefine HAVE_READ
 #cmakedefine HAVE_WRITE
-#cmakedefine HAVE_ZEROMQ
-
-#define HOST_CPU "${CMAKE_HOST_SYSTEM_PROCESSOR}"
-#define HOST_OS "${CMAKE_HOST_SYSTEM_NAME}"
-
-#cmakedefine WITH_LZO
-#cmakedefine WITH_NFKC
-#cmakedefine WITH_ZLIB
-
-#define PACKAGE "${PROJECT_NAME}"
-#define PACKAGE_NAME "${PROJECT_NAME}"
-#cmakedefine PACKAGE_STRING
-#cmakedefine PACKAGE_TARNAME
-#cmakedefine PACKAGE_URL
-#define PACKAGE_VERSION "${GRN_VERSION}"
-#define VERSION "${GRN_VERSION}"
-
-#cmakedefine STDC_HEADERS
-#cmakedefine USE_AIO
-#cmakedefine USE_DYNAMIC_MALLOC_CHANGE
-#cmakedefine USE_EPOLL
-#cmakedefine USE_EXACT_ALLOC_COUNT
-#cmakedefine USE_FAIL_MALLOC
-#cmakedefine USE_FUTEX
-#cmakedefine USE_KQUEUE
-#cmakedefine USE_MSG_MORE
-#cmakedefine USE_MSG_NOSIGNAL
-#cmakedefine USE_POLL
-#cmakedefine USE_QUERY_ABORT
-#cmakedefine USE_SELECT
-
-#cmakedefine WITH_BENCHMARK
-#cmakedefine WITH_CUTTER
-#cmakedefine WITH_KYTEA
-#cmakedefine WITH_LIBMEMCACHED
-#cmakedefine WITH_MECAB
-
-#cmakedefine WORDS_BIGENDIAN
-
-#cmakedefine _FILE_OFFSET_BITS
-#cmakedefine _GNU_SOURCE
-#cmakedefine _ISOC99_SOURCE
-#cmakedefine _LARGE_FILES
-#cmakedefine _NETBSD_SOURCE
-#cmakedefine _XOPEN_SOURCE
-#cmakedefine _XPG4_2
-#cmakedefine __EXTENSIONS__
-


ENH: Specify minimum allowed python version

When searching for python installation, ensure that a supported
version is found.

--- CMake/ITKSetPython3Vars.cmake
+++ CMake/ITKSetPython3Vars.cmake
@@ -8,18 +8,20 @@
 # implementation gives preference to active virtualenvs.

 cmake_policy(SET CMP0094 NEW) # makes FindPython3 prefer activated virtualenv Python to latest version
+set(PYTHON_REQUIRED_VERSION 3.7)
+set(Python_ADDITIONAL_VERSIONS 3.12 3.11 3.10 3.9 3.8 3.7)
 if(PYTHON_DEVELOPMENT_REQUIRED)
   if(DEFINED Python3_EXECUTABLE) # if already specified
     set(_specified_Python3_EXECUTABLE ${Python3_EXECUTABLE})
   endif()
   # set(Python3_FIND_REGISTRY LAST) # default is FIRST. Do we need/want this?
-  find_package(Python3 COMPONENTS Interpreter Development)
+  find_package(Python3 ${PYTHON_REQUIRED_VERSION} COMPONENTS Interpreter Development)
   if(DEFINED _specified_Python3_EXECUTABLE)
     set(Python3_EXECUTABLE ${_specified_Python3_EXECUTABLE} CACHE INTERNAL
       "Path to the Python interpreter" FORCE)
   endif()
 else() # if not PYTHON_DEVELOPMENT_REQUIRED, just find some version of Python (don't need to be as specific)
-  find_package(Python3 COMPONENTS Interpreter)
+  find_package(Python3 ${PYTHON_REQUIRED_VERSION} COMPONENTS Interpreter)
 endif()
 if(ITK_WRAP_PYTHON)
   set(ITK_WRAP_PYTHON_VERSION "${Python3_VERSION}")


Use anonymous http clone for MITK testing data

--- CMakeExternals/MITKData.cmake
+++ CMakeExternals/MITKData.cmake
@@ -10,7 +10,7 @@
 IF(BUILD_TESTING)
   SET(proj MITK-Data)
   ExternalProject_Add(${proj}
-    GIT_REPOSITORY ssh://git@mbits/MITK-Data
+    GIT_REPOSITORY http://mbits/git/MITK-Data.git
     GIT_TAG "origin/master"
     CONFIGURE_COMMAND ""
     BUILD_COMMAND ""
@@ -18,4 +18,5 @@
   )
   SET(MITK_DATA_DIR ${ep_source_dir}/${proj})
 ENDIF(BUILD_TESTING)
+


Update FindPleora.cmake

Update FindPleora.cmake

--- CMakeModules/FindPleora.cmake
+++ CMakeModules/FindPleora.cmake
@@ -5,23 +5,23 @@
 #  Pleora_LIBRARIES - link these to use pleora eUSB SDK
 #  Pleora_BASE_DIR - set env varivales to this to use pleora eUSB SDK

-if(NOT PLEORA_ARCH)
-  set(PLEORA_ARCH "Ubuntu-12.04-x86_64")
-endif()
-
 set( INCLUDE_SEARCH_PATHS
-	"/opt/pleora/ebus_sdk/${PLEORA_ARCH}/include"
+        "/opt/pleora/ebus_sdk/Ubuntu-12.04-x86_64/include"
+	"/opt/pleora/ebus_sdk/Ubuntu-14.04-x86_64/include"
 	"$ENV{ProgramFiles}/Pleora Technologies Inc/eBUS SDK/Includes"
 )

 set( LIBRARIES_SEARCH_PATHS
-	"/opt/pleora/ebus_sdk/${PLEORA_ARCH}/lib"
+	"/opt/pleora/ebus_sdk/Ubuntu-12.04-x86_64/lib"
+	"/opt/pleora/ebus_sdk/Ubuntu-14.04-x86_64/lib"
 	"$ENV{ProgramFiles}/Pleora Technologies Inc/eBUS SDK/Libraries"
 )

 set( GENAPI_SEARCH_PATHS
-   "/opt/pleora/ebus_sdk/${PLEORA_ARCH}/lib/genicam/bin/Linux64_x64"
-   "/opt/pleora/ebus_sdk/${PLEORA_ARCH}/lib/genicam/bin/Linux32_ARM"
+   "/opt/pleora/ebus_sdk/Ubuntu-12.04-x86_64/lib/genicam/bin/Linux64_x64"
+   "/opt/pleora/ebus_sdk/Ubuntu-12.04-x86_64/lib/genicam/bin/Linux32_ARM"
+   "/opt/pleora/ebus_sdk/Ubuntu-14.04-x86_64/lib/genicam/bin/Linux64_x64"
+   "/opt/pleora/ebus_sdk/Ubuntu-14.04-x86_64/lib/genicam/bin/Linux32_ARM"
    "$ENV{ProgramW6432}/GenICam_v2_4/library/CPP/lib/Win64_x64"
 )


disabling R and RUBY in sitk builds

disabling R and RUBY in sitk builds

--- CMakeExternals/SimpleITK.cmake
+++ CMakeExternals/SimpleITK.cmake
@@ -28,6 +28,8 @@
          -DWRAP_LUA:BOOL=OFF
          -DWRAP_PYTHON:BOOL=OFF
          -DWRAP_JAVA:BOOL=OFF
+         -DWRAP_RUBY:BOOL=OFF
+         -DWRAP_R:BOOL=OFF
         )

     if(MITK_USE_Python)
@@ -41,10 +43,6 @@
       if(NOT MITK_USE_SYSTEM_PYTHON)
         list(APPEND proj_DEPENDENCIES Python)
       endif()
-    else(MITK_USE_Python)
-      list(APPEND additional_cmake_args
-           -DWRAP_PYTHON:BOOL=OFF
-          )
     endif()

     #TODO: Installer and testing works only with static libs on MAC


enh: Use same relative path names for binary modules path as found in source tree [BASIS]

--- CMake/Basis/ProjectTools.cmake
+++ CMake/Basis/ProjectTools.cmake
@@ -961,10 +961,9 @@
     basis_module_info (${F})
     list (APPEND PROJECT_MODULES ${MODULE})
     get_filename_component (${MODULE}_BASE ${F} PATH)
+    basis_get_relative_path (${MODULE}_BASE_REL "${CMAKE_CURRENT_SOURCE_DIR}" "${${MODULE}_BASE}")
     set (MODULE_${MODULE}_SOURCE_DIR "${${MODULE}_BASE}")
-    # use module name as subdirectory name such that the default package
-    # configuration file knows where to find the module configurations
-    set (MODULE_${MODULE}_BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/modules/${MODULE}")
+    set (MODULE_${MODULE}_BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/${${MODULE}_BASE_REL}")
     # help modules to find each other using basis_find_package()
     set (${MODULE}_DIR "${MODULE_${MODULE}_BINARY_DIR}")
     # only set EXCLUDE_<MODULE>_FROM_ALL when not specified on command-line using -D switch


COMP: Added missing build config subdir

COMP: Added missing build config subdir

--- CMake/MITKDashboardSetup.cmake
+++ CMake/MITKDashboardSetup.cmake
@@ -79,7 +79,7 @@
   set(SOFA_BINARY_DIR "${CTEST_BINARY_DIRECTORY}/SOFA-build/bin/${CTEST_BUILD_CONFIGURATION}")
   set(REDLAND_BINARY_DIR "${CTEST_BINARY_DIRECTORY}/Redland-install/bin")
   set(BLUEBERRY_OSGI_DIR "${CTEST_BINARY_DIRECTORY}/MITK-build/bin/BlueBerry/org.blueberry.osgi/bin/${CTEST_BUILD_CONFIGURATION}")
-  set(OpenIGTLink_DIR "${CTEST_BINARY_DIRECTORY}/OpenIGTLink-build/bin")
+  set(OpenIGTLink_DIR "${CTEST_BINARY_DIRECTORY}/OpenIGTLink-build/bin/${CTEST_BUILD_CONFIGURATION}")
   set(CTEST_PATH "${CTEST_PATH};${CPPUNIT_BINARY_DIR};${QT_BINARY_DIR};${VTK_BINARY_DIR};${ANN_BINARY_DIR};${GLUT_BINARY_DIR};${GLEW_BINARY_DIR};${TINYXML_BINARY_DIR};${QWT_BINARY_DIR};${ACVD_BINARY_DIR};${ITK_BINARY_DIR};${BOOST_BINARY_DIR};${GDCM_BINARY_DIR};${DCMTK_BINARY_DIR};${OPENCV_BINARY_DIR};${POCO_BINARY_DIR};${SOFA_BINARY_DIR};${REDLAND_BINARY_DIR};${BLUEBERRY_OSGI_DIR};${OpenIGTLink_DIR}")
 endif()
 set(ENV{PATH} "${CTEST_PATH}")


Added Core and CppMicroServices to Minimal whitelist.

--- CMake/Whitelists/Minimal.cmake
+++ CMake/Whitelists/Minimal.cmake
@@ -1,5 +1,6 @@
 set(enabled_modules
-  ""
+  Core
+  CppMicroServices
 )

 set(enabled_plugins


Don't link the installed version of forge on Linux/OSX

CMake will strip the RPATH from the forge shared library when installing it,
causing link failures later down the line. Use the non-installed version instead.

--- CMakeModules/build_forge.cmake
+++ CMakeModules/build_forge.cmake
@@ -1,8 +1,14 @@
 INCLUDE(ExternalProject)

 SET(prefix ${CMAKE_BINARY_DIR}/third_party/forge)
-SET(forge_location "${prefix}/lib/${CMAKE_SHARED_LIBRARY_PREFIX}forge${CMAKE_SHARED_LIBRARY_SUFFIX}")

+IF(WIN32)
+    SET(forge_lib_prefix "${prefix}/lib")
+ELSE(WIN32)
+    SET(forge_lib_prefix "${prefix}/src/forge-ext-build/src")
+ENDIF(WIN32)
+
+SET(forge_location "${forge_lib_prefix}/${CMAKE_SHARED_LIBRARY_PREFIX}forge${CMAKE_SHARED_LIBRARY_SUFFIX}")
 IF(CMAKE_VERSION VERSION_LESS 3.2)
     IF(CMAKE_GENERATOR MATCHES "Ninja")
         MESSAGE(WARNING "Building forge with Ninja has known issues with CMake older than 3.2")
@@ -33,11 +39,17 @@
     ${byproducts}
     )

+ExternalProject_Get_Property(forge-ext binary_dir)
 ExternalProject_Get_Property(forge-ext install_dir)
 ADD_LIBRARY(forge SHARED IMPORTED)
 SET_TARGET_PROPERTIES(forge PROPERTIES IMPORTED_LOCATION ${forge_location})
 IF(WIN32)
-    SET_TARGET_PROPERTIES(forge PROPERTIES IMPORTED_IMPLIB ${prefix}/lib/forge.lib)
+    SET_TARGET_PROPERTIES(forge PROPERTIES IMPORTED_IMPLIB ${forge_lib_prefix}/forge.lib)
+ELSE(WIN32)
+    SET(forge_bindir_location ${binary_dir}/src/${CMAKE_SHARED_LIBRARY_PREFIX}forge${CMAKE_SHARED_LIBRARY_SUFFIX})
+    IF(NOT (${forge_bindir_location} STREQUAL ${forge_location}))
+        MESSAGE(WARNING "Did the forge binary location move? (Have ${forge_bindir_location} vs ${forge_location})")
+    ENDIF()
 ENDIF(WIN32)
 ADD_DEPENDENCIES(forge forge-ext)
 SET(FORGE_INCLUDE_DIRECTORIES ${install_dir}/include)


Don't overwrite arma_config.hpp unless needed. This should keep the build from being a complete rebuild every time 'make' is typed.

--- CMake/CreateArmaConfigInfo.cmake
+++ CMake/CreateArmaConfigInfo.cmake
@@ -1,6 +1,16 @@
 # Using the CMake tools to create the file arma_config.hpp, which contains
-# information on the Armadillo configuration when mlpack was compiled.  We'll
-# need to open the config.hpp we are using.
+# information on the Armadillo configuration when mlpack was compiled.  This
+# assumes ${ARMADILLO_INCLUDE_DIR} is set.  In addition, we must be careful to
+# avoid overwriting arma_config.hpp with the exact same information, because
+# this may trigger a new complete rebuild, which is undesired.
+if(EXISTS "${CMAKE_SOURCE_DIR}/src/mlpack/core/util/arma_config.hpp")
+  file(READ "${CMAKE_SOURCE_DIR}/src/mlpack/core/util/arma_config.hpp"
+      OLD_FILE_CONTENTS)
+else(EXISTS "${CMAKE_SOURCE_DIR}/src/mlpack/core/util/arma_config.hpp")
+  set(OLD_FILE_CONTENTS "")
+endif(EXISTS "${CMAKE_SOURCE_DIR}/src/mlpack/core/util/arma_config.hpp")
+
+# We'll need to open the config.hpp we are using.
 if(EXISTS "${ARMADILLO_INCLUDE_DIR}/armadillo_bits/config.hpp")
   file(READ "${ARMADILLO_INCLUDE_DIR}/armadillo_bits/config.hpp"
       ARMA_CONFIG)
@@ -13,8 +23,13 @@

   string(LENGTH "${ARMA_HAS_64BIT_WORD_PRE}" ARMA_HAS_64BIT_WORD)

-  file(REMOVE ${CMAKE_SOURCE_DIR}/src/mlpack/core/util/arma_config.hpp)
-  file(WRITE ${CMAKE_SOURCE_DIR}/src/mlpack/core/util/arma_config.hpp
+  if(ARMA_HAS_64BIT_WORD EQUAL 0)
+    set(ARMA_64BIT_WORD_DEFINE "#define MLPACK_ARMA_NO64BIT_WORD")
+  else(ARMA_HAS_64BIT_WORD EQUAL 0)
+    set(ARMA_64BIT_WORD_DEFINE "#define MLPACK_ARMA_64BIT_WORD")
+  endif(ARMA_HAS_64BIT_WORD EQUAL 0)
+
+  set(NEW_FILE_CONTENTS
 "/**
  * @file arma_config.hpp
  *
@@ -32,17 +47,19 @@
 #ifndef __MLPACK_CORE_UTIL_ARMA_CONFIG_HPP
 #define __MLPACK_CORE_UTIL_ARMA_CONFIG_HPP

+${ARMA_64BIT_WORD_DEFINE}
+
+#endif
 ")
-  if(ARMA_HAS_64BIT_WORD EQUAL 0)
-    file(APPEND ${CMAKE_SOURCE_DIR}/src/mlpack/core/util/arma_config.hpp
-        "#define MLPACK_ARMA_NO_64BIT_WORD")
-  else(ARMA_HAS_64BIT_WORD EQUAL 0)
-    file(APPEND ${CMAKE_SOURCE_DIR}/src/mlpack/core/util/arma_config.hpp
-        "#define MLPACK_ARMA_64BIT_WORD")
-  endif(ARMA_HAS_64BIT_WORD EQUAL 0)

-  file(APPEND ${CMAKE_SOURCE_DIR}/src/mlpack/core/util/arma_config.hpp
-      "\n\n#endif\n")
+  # Did the contents of the file change at all?  If not, don't write it.
+  if(NOT "${OLD_FILE_CONTENTS}" STREQUAL "${NEW_FILE_CONTENTS}")
+    # We have a reason to write the new file.
+    message(STATUS "Regenerating arma_config.hpp.")
+    file(REMOVE "${CMAKE_SOURCE_DIR}/src/mlpack/core/util/arma_config.hpp")
+    file(WRITE "${CMAKE_SOURCE_DIR}/src/mlpack/core/util/arma_config.hpp"
+        "${NEW_FILE_CONTENTS}")
+  endif(NOT "${OLD_FILE_CONTENTS}" STREQUAL "${NEW_FILE_CONTENTS}")

 else(EXISTS "${ARMADILLO_INCLUDE_DIR}/armadillo_bits/config.hpp")
   message(WARNING "Armadillo configuration file


Revert FindDirectX and guard the win8 search path inside OGRE_BUILD_PLATFORM_WINRT

--- CMake/Packages/FindDirectX.cmake
+++ CMake/Packages/FindDirectX.cmake
@@ -38,6 +38,17 @@
 	"$ENV{ProgramFiles}/Microsoft DirectX SDK*"
   )

+if(OGRE_BUILD_PLATFORM_WINRT)
+  # Windows 8 SDK has custom layout
+  set(DirectX_INC_SEARCH_PATH
+    "C:/Program Files (x86)/Windows Kits/8.0/Include/shared"
+    "C:/Program Files (x86)/Windows Kits/8.0/Include/um"
+  )
+  set(DirectX_LIB_SEARCH_PATH
+    "C:/Program Files (x86)/Windows Kits/8.0/Lib/win8/um"
+  )
+endif()
+
   create_search_paths(DirectX)
   # redo search if prefix path changed
   clear_if_changed(DirectX_PREFIX_PATH
@@ -46,7 +57,6 @@
   )

   find_path(DirectX_INCLUDE_DIR NAMES d3d9.h HINTS ${DirectX_INC_SEARCH_PATH})
-
   # dlls are in DirectX_ROOT_DIR/Developer Runtime/x64|x86
   # lib files are in DirectX_ROOT_DIR/Lib/x64|x86
   if(CMAKE_CL_64)
@@ -59,6 +69,13 @@
   find_library(DirectX_DXERR_LIBRARY NAMES DxErr HINTS ${DirectX_LIB_SEARCH_PATH} PATH_SUFFIXES ${DirectX_LIBPATH_SUFFIX})
   find_library(DirectX_DXGUID_LIBRARY NAMES dxguid HINTS ${DirectX_LIB_SEARCH_PATH} PATH_SUFFIXES ${DirectX_LIBPATH_SUFFIX})

+
+  # look for dxgi (needed by both 10 and 11)
+  find_library(DirectX_DXGI_LIBRARY NAMES dxgi HINTS ${DirectX_LIB_SEARCH_PATH} PATH_SUFFIXES ${DirectX_LIBPATH_SUFFIX})
+
+  # look for d3dcompiler (needed by 11)
+  find_library(DirectX_D3DCOMPILER_LIBRARY NAMES d3dcompiler HINTS ${DirectX_LIB_SEARCH_PATH} PATH_SUFFIXES ${DirectX_LIBPATH_SUFFIX})
+
   findpkg_finish(DirectX)
   set(DirectX_LIBRARIES ${DirectX_LIBRARIES}
     ${DirectX_D3DX9_LIBRARY}
@@ -66,31 +83,17 @@
     ${DirectX_DXGUID_LIBRARY}
   )

+  mark_as_advanced(DirectX_D3DX9_LIBRARY DirectX_DXERR_LIBRARY DirectX_DXGUID_LIBRARY
+    DirectX_DXGI_LIBRARY DirectX_D3DCOMPILER_LIBRARY)
+
+
   # look for D3D11 components
   if (DirectX_FOUND)
-    find_library(DirectX_D3DX11_LIBRARY NAMES d3dx11 HINTS ${DirectX_LIB_SEARCH_PATH} PATH_SUFFIXES ${DirectX_LIBPATH_SUFFIX})
-
-    # Windows 8 SDK has custom layout
-    set(DirectX_INC_SEARCH_PATH
-	  "C:/Program Files (x86)/Windows Kits/8.0/Include/shared"
-	  "C:/Program Files (x86)/Windows Kits/8.0/Include/um"
-    )
-
-    set(DirectX_LIB_SEARCH_PATH
-	  "C:/Program Files (x86)/Windows Kits/8.0/Lib/win8/um"
-    )
-
-    # look for dxgi (needed by both 10 and 11)
-    find_library(DirectX_DXGI_LIBRARY NAMES dxgi HINTS ${DirectX_LIB_SEARCH_PATH} PATH_SUFFIXES ${DirectX_LIBPATH_SUFFIX})
-
-    # look for d3dcompiler (needed by 11)
-    find_library(DirectX_D3DCOMPILER_LIBRARY NAMES d3dcompiler HINTS ${DirectX_LIB_SEARCH_PATH} PATH_SUFFIXES ${DirectX_LIBPATH_SUFFIX})
-
     find_path(DirectX_D3D11_INCLUDE_DIR NAMES D3D11Shader.h HINTS ${DirectX_INC_SEARCH_PATH})
 	get_filename_component(DirectX_LIBRARY_DIR "${DirectX_LIBRARY}" PATH)
 	message(STATUS "DX lib dir: ${DirectX_LIBRARY_DIR}")
     find_library(DirectX_D3D11_LIBRARY NAMES d3d11 HINTS ${DirectX_LIB_SEARCH_PATH} PATH_SUFFIXES ${DirectX_LIBPATH_SUFFIX})
-
+    find_library(DirectX_D3DX11_LIBRARY NAMES d3dx11 HINTS ${DirectX_LIB_SEARCH_PATH} PATH_SUFFIXES ${DirectX_LIBPATH_SUFFIX})
 	if (DirectX_D3D11_INCLUDE_DIR AND DirectX_D3D11_LIBRARY)
 	  set(DirectX_D3D11_FOUND TRUE)
 	  set(DirectX_D3D11_INCLUDE_DIR ${DirectX_D3D11_INCLUDE_DIR})
@@ -110,5 +113,4 @@
 	mark_as_advanced(DirectX_D3D11_INCLUDE_DIR DirectX_D3D11_LIBRARY DirectX_D3DX11_LIBRARY)
   endif ()

-  mark_as_advanced(DirectX_D3DX9_LIBRARY DirectX_DXERR_LIBRARY DirectX_DXGUID_LIBRARY DirectX_DXGI_LIBRARY DirectX_D3DCOMPILER_LIBRARY)
-endif(WIN32)
+endif(WIN32)


Error out when sm70 build requested

Error out when sm70 build requested

refs #292

--- CMake/hoomd/HOOMDCUDASetup.cmake
+++ CMake/hoomd/HOOMDCUDASetup.cmake
@@ -56,10 +56,15 @@
     set(_cuda_arch_list_sorted ${CUDA_ARCH_LIST})
     list(SORT _cuda_arch_list_sorted)
     list(GET _cuda_arch_list_sorted 0 _cuda_min_arch)
+    list(GET _cuda_arch_list_sorted -1 _cuda_max_arch)
     add_definitions(-DCUDA_ARCH=${_cuda_min_arch})

     if (_cuda_min_arch LESS 20)
         message(SEND_ERROR "SM1x builds are not supported")
+    endif ()
+
+    if (_cuda_max_arch GREATER_EQUAL 70)
+        message(SEND_ERROR "HOOMD does not support SM7x builds")
     endif ()

     # only generage ptx code for the maximum supported CUDA_ARCH (saves on file size)


typo

typo

git-svn-id: 7720f8ced686bbe1e9a8fc98aef2dd4d5d9a3e92@47 995b7d7e-cf50-0410-b6c9-9f4ebe303554

--- CMakeModules/FindlibSquish.cmake
+++ CMakeModules/FindlibSquish.cmake
@@ -4,7 +4,7 @@
 #  LIBSQUISH_LIBRARIES

 FIND_PATH(LIBSQUISH_INCLUDE_DIR squish.h PATHS . .. DOC "Directory containing libSquish headers")
-FIND_LIBRARY(LIBSQUISH_LIBRARY NAMES Squish libsquish PATHS . .. DOC "Path to libSquish library")
+FIND_LIBRARY(LIBSQUISH_LIBRARY NAMES squish libsquish PATHS . .. DOC "Path to libSquish library")

 SET(LIBSQUISH_LIBRARIES ${LIBSQUISH_LIBRARY})


COMP: the argument is char*, not const char*

Alex

--- CMake/FindPythonLibs.cmake
+++ CMake/FindPythonLibs.cmake
@@ -163,7 +163,7 @@

   FOREACH(_currentModule ${PY_STATIC_MODULES_LIST})
-    FILE(APPEND ${_filename} "int CMakeLoadPythonModule_${_currentModule}(void) \n{\n  return PyImport_AppendInittab(\"${PYTHON_MODULE_PREFIX}${_currentModule}\", init${PYTHON_MODULE_PREFIX}${_currentModule});\n}\n\n")
+    FILE(APPEND ${_filename} "int CMakeLoadPythonModule_${_currentModule}(void) \n{\n  char name[]=\"${PYTHON_MODULE_PREFIX}${_currentModule}\"; return PyImport_AppendInittab(name, init${PYTHON_MODULE_PREFIX}${_currentModule});\n}\n\n")
   ENDFOREACH(_currentModule ${PY_STATIC_MODULES_LIST})

   FILE(APPEND ${_filename} "#ifndef EXCLUDE_LOAD_ALL_FUNCTION\nvoid CMakeLoadAllPythonModules(void)\n{\n")


COMP: vtk{KIT}PythonD should link to the vtk python library only on Windows and OSX.  See the comments for an explanation.  KIT_PYTHON_DEPS need to be attached to the vtk{KIT}PythonD target not vtk{KIT}Python.

--- CMake/KitCommonBlock.cmake
+++ CMake/KitCommonBlock.cmake
@@ -35,25 +35,43 @@
 # source files
 #
 IF (VTK_WRAP_PYTHON)
+  # Create custom commands to generate the python wrappers for this kit.
   VTK_WRAP_PYTHON3(vtk${KIT}Python KitPython_SRCS "${Kit_SRCS}")
+
+  # Create a shared library containing the python wrappers.  Executables
+  # can link to this but it is not directly loaded dynamically as a
+  # module.
   ADD_LIBRARY(vtk${KIT}PythonD ${KitPython_SRCS} ${Kit_PYTHON_EXTRA_SRCS})
-  ADD_LIBRARY(vtk${KIT}Python MODULE vtk${KIT}PythonInit.cxx)
-  TARGET_LINK_LIBRARIES(vtk${KIT}PythonD vtk${KIT} ${KIT_PYTHON_LIBS}
-                        ${VTK_PYTHON_LIBRARIES})
-  TARGET_LINK_LIBRARIES(vtk${KIT}Python vtk${KIT}PythonD)
+  TARGET_LINK_LIBRARIES(vtk${KIT}PythonD vtk${KIT} ${KIT_PYTHON_LIBS})
   IF(NOT VTK_INSTALL_NO_LIBRARIES)
     INSTALL_TARGETS(${VTK_INSTALL_LIB_DIR} vtk${KIT}PythonD)
   ENDIF(NOT VTK_INSTALL_NO_LIBRARIES)
   SET(KIT_LIBRARY_TARGETS ${KIT_LIBRARY_TARGETS} vtk${KIT}PythonD)
-  IF(WIN32)
-    TARGET_LINK_LIBRARIES (vtk${KIT}Python ${VTK_PYTHON_LIBRARIES})
-  ENDIF(WIN32)
+
+  # On some UNIX platforms the python library is static and therefore
+  # should not be linked into the shared library.  Instead the symbols
+  # are exported from the python executable so that they can be used by
+  # shared libraries that are linked or loaded.  On Windows and OSX we
+  # want to link to the python libray to resolve its symbols
+  # immediately.
+  IF(WIN32 OR APPLE)
+    TARGET_LINK_LIBRARIES (vtk${KIT}PythonD ${VTK_PYTHON_LIBRARIES})
+  ENDIF(WIN32 OR APPLE)
+
+  # Add dependencies that may have been generated by VTK_WRAP_PYTHON3 to
+  # the python wrapper library.  This is needed for the
+  # pre-custom-command hack in Visual Studio 6.
+  IF(KIT_PYTHON_DEPS)
+    ADD_DEPENDENCIES(vtk${KIT}PythonD ${KIT_PYTHON_DEPS})
+  ENDIF(KIT_PYTHON_DEPS)
+
+  # Create a python module that can be loaded dynamically.  It links to
+  # the shared library containing the wrappers for this kit.
+  ADD_LIBRARY(vtk${KIT}Python MODULE vtk${KIT}PythonInit.cxx)
+  TARGET_LINK_LIBRARIES(vtk${KIT}Python vtk${KIT}PythonD)
   IF(NOT VTK_INSTALL_NO_LIBRARIES)
     INSTALL_TARGETS(${VTK_INSTALL_LIB_DIR} vtk${KIT}Python)
   ENDIF(NOT VTK_INSTALL_NO_LIBRARIES)
-  IF(KIT_PYTHON_DEPS)
-    ADD_DEPENDENCIES(vtk${KIT}Python ${KIT_PYTHON_DEPS})
-  ENDIF(KIT_PYTHON_DEPS)
 ENDIF (VTK_WRAP_PYTHON)

 # if we are wrapping into Java then add the library and extra


Reduce Boost build to single project again

--- CMakeExternals/Boost.cmake
+++ CMakeExternals/Boost.cmake
@@ -138,26 +138,18 @@
       COMMAND ${CMAKE_COMMAND} -E copy_directory "<SOURCE_DIR>/boost" "<INSTALL_DIR>/${_boost_install_include_dir}")
   endif()

-  ExternalProject_Add(${proj}-download
-      URL ${MITK_THIRDPARTY_DOWNLOAD_PREFIX_URL}/boost_${_boost_version}_0.7z
-      URL_MD5 ace404a1c6be8b74544a77b85f828d40
-      CONFIGURE_COMMAND ""
-      BUILD_COMMAND ""
-      INSTALL_COMMAND ""
-    )
-
   ExternalProject_Add(${proj}
     LIST_SEPARATOR ${sep}
-    SOURCE_DIR "${ep_prefix}/src/${proj}-download"
-    BINARY_DIR "${ep_prefix}/src/${proj}-download"
-    DOWNLOAD_COMMAND ""
+    URL ${MITK_THIRDPARTY_DOWNLOAD_PREFIX_URL}/boost_${_boost_version}_0.7z
+    URL_MD5 ace404a1c6be8b74544a77b85f828d40
+    BINARY_DIR "${ep_prefix}/src/${proj}"
     CONFIGURE_COMMAND "<SOURCE_DIR>/bootstrap${_shell_extension}"
       --with-toolset=${_boost_with_toolset}
       --with-libraries=${_boost_libs}
       "--prefix=<INSTALL_DIR>"
     ${_boost_build_cmd}
     INSTALL_COMMAND "" # done in BUILD_COMMAND
-    DEPENDS ${proj}-download ${proj_DEPENDENCIES}
+    DEPENDS ${proj_DEPENDENCIES}
     )

   ExternalProject_Get_Property(${proj} install_dir)


From Michael Platings, "the attached cmake file recognises the latest version of the FBX SDK, and now works correctly on 64 bit Windows."

--- CMakeModules/FindFBX.cmake
+++ CMakeModules/FindFBX.cmake
@@ -35,11 +35,16 @@
 ENDIF()

 # SET final path
-#osg_fbx code is compatible with 2011.2 and 2011.3 so find either directory
+#osg_fbx code is compatible with 2011.2, 2011.3 and 2011.3.1 so find any directory
 SET( FBX_SEARCH_PATHS
     $ENV{FBX_DIR}
+    $ENV{ProgramW6432}/Autodesk/FBX/FbxSdk/2011.3.1
+    $ENV{PROGRAMFILES}/Autodesk/FBX/FbxSdk/2011.3.1
+    /Applications/Autodesk/FBXSDK201131
+    $ENV{ProgramW6432}/Autodesk/FBX/FbxSdk/2011.3
     $ENV{PROGRAMFILES}/Autodesk/FBX/FbxSdk/2011.3
     /Applications/Autodesk/FBXSDK20113
+    $ENV{ProgramW6432}/Autodesk/FBX/FbxSdk/2011.2
     $ENV{PROGRAMFILES}/Autodesk/FBX/FbxSdk/2011.2
     /Applications/Autodesk/FBXSDK20112
 )


FindGSL.cmake: better error message

FindGSL.cmake: better error message

--- CMakeModules/FindGSL.cmake
+++ CMakeModules/FindGSL.cmake
@@ -38,17 +38,19 @@
   endforeach(LIB)
 #endif (NOT BUILD_SHARED_LIBS)

-include(CheckLibraryExists)
-check_library_exists("${GSL_LIBRARY}" gsl_linalg_QR_decomp "" FOUND_QR_DECOMP)
-if(NOT FOUND_QR_DECOMP)
-  message(FATAL_ERROR "Could not find gsl_linalg_QR_decompx in ${GSL_LIBRARY}, take look at the error message in ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log to find out what was going wrong. If you don't have pkg-config installed you will most likely have to set GSL_LIBRARY by hand and include libgslcblas and libm in there (i.e. -DGSL_LIBRARY='/path/to/libgsl.so;/path/to/libgslcblas.so;/path/to/libm.so') !")
-endif(NOT FOUND_QR_DECOMP)
-
 include(FindPackageHandleStandardArgs)
 # handle the QUIETLY and REQUIRED arguments and set GSL_FOUND to TRUE
 # if all listed variables are TRUE
 find_package_handle_standard_args(GSL DEFAULT_MSG GSL_LIBRARY GSL_INCLUDE_DIR )

+if (GSL_FOUND)
+  include(CheckLibraryExists)
+  check_library_exists("${GSL_LIBRARY}" gsl_linalg_QR_decomp "" FOUND_QR_DECOMP)
+  if(NOT FOUND_QR_DECOMP)
+    message(FATAL_ERROR "Could not find gsl_linalg_QR_decompx in ${GSL_LIBRARY}, take look at the error message in ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log to find out what was going wrong. If you don't have pkg-config installed you will most likely have to set GSL_LIBRARY by hand and include libgslcblas and libm in there (i.e. -DGSL_LIBRARY='/path/to/libgsl.so;/path/to/libgslcblas.so;/path/to/libm.so') !")
+  endif(NOT FOUND_QR_DECOMP)
+endif (GSL_FOUND)
+
 set(GSL_LIBRARIES ${GSL_LIBRARY} )
 set(GSL_INCLUDE_DIRS ${GSL_INCLUDE_DIR} )


changed threading handling

changed threading handling

--- CMakeModules/FindMKL.cmake
+++ CMakeModules/FindMKL.cmake
@@ -62,7 +62,12 @@
 check_type_size("int" INT_SIZE
   BUILTIN_TYPES_ONLY LANGUAGE C)

-set(MKL_THREAD_LAYER "Sequential" CACHE STRING "The thread layer to choose for MKL")
+
+if(NOT MKL_THREAD_LAYER)
+    set(MKL_THREAD_LAYER "TBB")
+endif()
+
+set(MKL_THREAD_LAYER ${MKL_THREAD_LAYER} CACHE STRING "The thread layer to choose for MKL")
 set_property(CACHE MKL_THREAD_LAYER PROPERTY STRINGS "TBB" "GNU OpenMP" "Intel OpenMP" "Sequential")

 if(NOT MKL_THREAD_LAYER STREQUAL MKL_THREAD_LAYER_LAST)
@@ -278,3 +283,5 @@
         IMPORTED_IMPLIB "${MKL_Core_LINK_LIBRARY}")
   endif()
 endif()
+
+message("-- " ${MKL_THREAD_LAYER} " used for MKL parallelisation")


Default to Release build if CMAKE_BUILD_TYPE unspecified

--- standard/StandardProject.cmake
+++ standard/StandardProject.cmake
@@ -44,6 +44,10 @@
       # Build Fat binaries on OSX by default
       set(CMAKE_OSX_ARCHITECTURES "x86_64;i386" CACHE STRING "Mac OS X build architectures" FORCE)
     endif()
+  endif()
+
+  if(NOT MSVC AND NOT CMAKE_BUILD_TYPE)
+    set(CMAKE_BUILD_TYPE "Release" CACHE STRING "Choose the type of build, options are: Debug Release." FORCE)
   endif()

   # These do not strictly *have* to be set prior to project, but they can be so we will


add curl include dirs

add curl include dirs

--- project/cmake/ProjectBuildOption.cmake
+++ project/cmake/ProjectBuildOption.cmake
@@ -48,6 +48,7 @@
 if(CURL_FOUND)
     message(STATUS "Curl support disabled")
     set(NETWORK_ENABLE_CURL 1)
+    include_directories(${CURL_INCLUDE_DIRS})
 else()
     message(STATUS "Curl support disabled")
 endif()


fixed: opt build (propagate params)

fixed: opt build (propagate params)

--- CMake/ConfigurePackages.cmake
+++ CMake/ConfigurePackages.cmake
@@ -824,6 +824,8 @@

     IF(OSG_WITH_QT)
       OSG_SET(OSG_WITH_QT5 1)
+
+      OSG_ADD_OPT(QT5_CMAKE_DIR)
     ENDIF()

 #    MESSAGE(STATUS "BAR ${OSG_QT_INC_DIR} ${OSG_QT_LIBS} ${OSG_QT_DEFS}")