Update facts.cmake

Update facts.cmake

--- facts/facts.cmake
+++ facts/facts.cmake
@@ -252,22 +252,22 @@
 		find_package(${PACKAGE} ${VERSION} REQUIRED)
 	endif()

-	# 13 añadir los includes
+	# 13 aÃ±adir los includes
 	string(TOUPPER "${PACKAGE}" PACKAGE_UPPER)
 	foreach(INCLUDE_DIR ${${PACKAGE_UPPER}_INCLUDE_DIRS})
 		list(APPEND CMAKI_INCLUDE_DIRS "${INCLUDE_DIR}")
 	endforeach()

-	# 14. aadir los libdir
+	# 14. añadir los libdir
 	foreach(LIB_DIR ${${PACKAGE_UPPER}_LIBRARIES})
 		list(APPEND CMAKI_LIBRARIES "${LIB_DIR}")
 	endforeach()

-	# 15. añadir variables especificas
+	# 15. aÃ±adir variables especificas
 	set(${PACKAGE_UPPER}_INCLUDE_DIRS "${${PACKAGE_UPPER}_INCLUDE_DIRS}" PARENT_SCOPE)
 	set(${PACKAGE_UPPER}_LIBRARIES "${${PACKAGE_UPPER}_LIBRARIES}" PARENT_SCOPE)

-	# 16. añaadir variabes generales
+	# 16. aÃ±aadir variabes generales
 	set(CMAKI_INCLUDE_DIRS "${CMAKI_INCLUDE_DIRS}" PARENT_SCOPE)
 	set(CMAKI_LIBRARIES "${CMAKI_LIBRARIES}" PARENT_SCOPE)

@@ -517,6 +517,7 @@
 endfunction()

 macro(cmaki2_gtest)
+	cmaki_find_package(google-gtest)
 	cmaki_find_package(google-gmock)
 	cmaki2_test(${ARGV})
 endmacro()


Update facts.cmake

Update facts.cmake

--- facts/facts.cmake
+++ facts/facts.cmake
@@ -422,7 +422,7 @@
 	set(_EXECUTABLE_NAME ${_MAIN_NAME})
 	source_group( "Source Files" FILES ${_SOURCES} )
 	common_flags()
-	include_directories(..)
+	include_directories(${CMAKE_SOURCE_DIR}/..)
 	foreach(INCLUDE_DIR ${CMAKI_INCLUDE_DIRS})
 		include_directories(${INCLUDE_DIR})
 	endforeach()
@@ -456,7 +456,7 @@
 	set(_LIBRARY_NAME ${_MAIN_NAME})
 	source_group( "Source Files" FILES ${_SOURCES} )
 	common_flags()
-	include_directories(..)
+	include_directories(${CMAKE_SOURCE_DIR}/..)
 	foreach(INCLUDE_DIR ${CMAKI_INCLUDE_DIRS})
 		include_directories(${INCLUDE_DIR})
 	endforeach()
@@ -485,7 +485,7 @@
 	set(_LIBRARY_NAME ${_MAIN_NAME})
 	source_group( "Source Files" FILES ${_SOURCES} )
 	common_flags()
-	include_directories(..)
+	include_directories(${CMAKE_SOURCE_DIR}/..)
 	foreach(INCLUDE_DIR ${CMAKI_INCLUDE_DIRS})
 		include_directories(${INCLUDE_DIR})
 	endforeach()
@@ -520,9 +520,7 @@
 	endif()
 	add_executable(${_TEST_NAME}_exe ${_SOURCES})
 	target_link_libraries(${_TEST_NAME}_exe ${_DEPENDS})
-	# message("-- link ${_DEPENDS}_exe with ${LIB_DIR}")
 	foreach(LIB_DIR ${CMAKI_LIBRARIES})
-		# message("-- link ${_TEST_NAME}_exe with ${LIB_DIR}")
 		target_link_libraries(${_TEST_NAME}_exe ${LIB_DIR})
 		cmaki_install_3rdparty(${LIB_DIR})
 	endforeach()


Use the cuda environment variable on windows when looking for thrust

--- src/unit_PARALLEL/cmake/FindThrust.cmake
+++ src/unit_PARALLEL/cmake/FindThrust.cmake
@@ -32,6 +32,7 @@
     /usr/local/cuda/include
     /opt/cuda/include
     ${CUDA_INCLUDE_DIRS}
+    $ENV{CUDA_PATH}/include
   NAMES thrust/version.h
   DOC "Thrust headers"
   )


Enable Valgrind's leak checking separately from other checks.

We should move towards a leak-free code base, but many of the detected
checks seem to be triggered by the OS and/or GTest.  In the likely
case we can't do anything about those, they will need suppressions,
so I want to be able to disable leak checks for the time being.

--- CMake/SurgSimUtilities.cmake
+++ CMake/SurgSimUtilities.cmake
@@ -23,18 +23,33 @@
 if(NOT WIN32)
 	option(SURGSIM_TESTS_RUN_WITH_VALGRIND
 		"Run the unit tests using Valgrind's memcheck tool." OFF)
+	option(SURGSIM_TESTS_RUN_WITH_VALGRIND_VERBOSE
+		"When running the unit tests using Valgrind, add verbose info." OFF)
+	mark_as_advanced(SURGSIM_TESTS_RUN_WITH_VALGRIND_VERBOSE)
+	option(SURGSIM_TESTS_RUN_WITH_VALGRIND_LEAK_CHECK
+		"When running the unit tests using Valgrind, also check for leaks." OFF)
+	mark_as_advanced(SURGSIM_TESTS_RUN_WITH_VALGRIND_LEAK_CHECK)
 endif(NOT WIN32)
 option(SURGSIM_TESTS_ALL_IN_ONE
 	"Build a single binary with all unit tests.  [Does not work yet!]" OFF)
+mark_as_advanced(SURGSIM_TESTS_ALL_IN_ONE)  # hide it as long as it's broken
 option(SURGSIM_EXAMPLES_BUILD "Include the examples in the build" ON)
-mark_as_advanced(SURGSIM_TESTS_ALL_IN_ONE)  # hide it as long as it's broken

 set(SURGSIM_COPY_WARNING_ONCE TRUE)
 set(SURGSIM_TEST_RUN_PREFIX)
 if(NOT WIN32)
 	if(SURGSIM_TESTS_RUN_WITH_VALGRIND)
-		set(SURGSIM_TEST_RUN_PREFIX valgrind -v --tool=memcheck --error-exitcode=1
-			--fullpath-after= --leak-check=full)
+		set(SURGSIM_TEST_RUN_PREFIX valgrind --tool=memcheck --error-exitcode=1
+			--fullpath-after=)
+		if(SURGSIM_TESTS_RUN_WITH_VALGRIND_VERBOSE)
+			set(SURGSIM_TEST_RUN_PREFIX ${SURGSIM_TEST_RUN_PREFIX} -v)
+		endif(SURGSIM_TESTS_RUN_WITH_VALGRIND_VERBOSE)
+		if(SURGSIM_TESTS_RUN_WITH_VALGRIND_LEAK_CHECK)
+			set(SURGSIM_TEST_RUN_PREFIX ${SURGSIM_TEST_RUN_PREFIX}
+				--leak-check=full --show-reachable=yes)
+		else()
+			set(SURGSIM_TEST_RUN_PREFIX ${SURGSIM_TEST_RUN_PREFIX} --leak-check=none)
+		endif()
 	endif(SURGSIM_TESTS_RUN_WITH_VALGRIND)
 endif(NOT WIN32)


BUG: don't quote argument to URL_HASH for FFTW

The hash method was switched from URL_MD5 to URL_HASH in:

https://github.com/InsightSoftwareConsortium/ITK/commit/716fe079a6fad64f63f1166c7cb1565acef982ee#diff-3410c0d07b017317e4e05d74e9ad6941

Unfortunately, doing so with quoting breaks the the build due to a subtle difference in how URL_MD5 and URL_HASH are interpreted. See the following CMake MR for more information:

https://gitlab.kitware.com/cmake/cmake/merge_requests/2718

--- CMake/itkExternal_FFTW.cmake
+++ CMake/itkExternal_FFTW.cmake
@@ -90,7 +90,7 @@
       ExternalProject_add(fftwf
         PREFIX fftwf
         URL "${_fftw_url}"
-        URL_HASH SHA512="${_fftw_url_hash}"
+        URL_HASH SHA512=${_fftw_url_hash}
         DOWNLOAD_NAME "fftw-${_fftw_target_version}.tar.gz"
         CONFIGURE_COMMAND
           env
@@ -118,7 +118,7 @@
       ExternalProject_add(fftwd
         PREFIX fftwd
         URL "${_fftw_url}"
-        URL_HASH SHA512="${_fftw_url_hash}"
+        URL_HASH SHA512=${_fftw_url_hash}
         DOWNLOAD_NAME "fftw-${_fftw_target_version}.tar.gz"
         CONFIGURE_COMMAND
           env


Adding add_test_tcl() macro.

Adding add_test_tcl() macro.

This macro lets one add a tcl test. It takes the name of the file used in the
test as the first argument and an optional base image directory as the second
argument. However this general macro may not suit all tests in which case a
specifiy cmake code may be required.

Example:

add_test_tcl(mcubes Graphics)

Change-Id: Ie8ab5d344c3fa0bfc880bf637fa77a08b8c34dae

--- CMake/vtkTestingMacros.cmake
+++ CMake/vtkTestingMacros.cmake
@@ -45,3 +45,36 @@
     $<TARGET_FILE:${name}>
     ${VTK_MPI_POSTFLAGS})
 endmacro()
+
+# -----------------------------------------------------------------------------
+# add_test_tcl() macro takes a tcl file and an optional base directory where the
+# corresponding test image is found and list of tcl files and makes them into
+# proper tcl tests.
+
+macro(add_test_tcl)
+  if(VTK_TCL_EXE)
+    # Parse Command line args
+    get_filename_component(TName ${ARGV0} NAME_WE)
+    string (REPLACE "vtk" "" _baselinedname ${vtk-module})
+    # Check if data root and second parameter is present
+    if(VTK_DATA_ROOT AND NOT ARGV1)
+      add_test(NAME ${vtk-module}Tcl-${TName}
+        COMMAND ${VTK_TCL_EXE}
+        ${vtkTestingRendering_SOURCE_DIR}/rtImageTest.tcl
+        ${CMAKE_CURRENT_SOURCE_DIR}/${TName}.tcl
+        -D ${VTK_DATA_ROOT}
+        -T ${VTK_TEST_OUTPUT_DIR}
+        -V Baseline/${ARGV1}/${TName}.png
+        -A ${VTK_SOURCE_DIR}/Wrapping/Tcl)
+    else()
+      add_test(NAME ${vtk-module}Tcl-${TName}
+        COMMAND ${VTK_TCL_EXE}
+        ${CMAKE_CURRENT_SOURCE_DIR}/${TName}.tcl
+        -A ${VTK_SOURCE_DIR}/Wrapping/Tcl
+        ${${TName}_ARGS})
+    endif()
+  else()
+    messge(FATAL "VTK_TCL_EXE not set")
+  endif()
+endmacro(add_test_tcl)
+


[CMake] Build all XLA protos as part of the CMake build.

PiperOrigin-RevId: 202155905

--- tensorflow/contrib/cmake/tf_core_framework.cmake
+++ tensorflow/contrib/cmake/tf_core_framework.cmake
@@ -125,6 +125,7 @@

 file(GLOB_RECURSE tf_protos_cc_srcs RELATIVE ${tensorflow_source_dir}
     "${tensorflow_source_dir}/tensorflow/core/*.proto"
+    "${tensorflow_source_dir}/tensorflow/compiler/xla/*.proto"
     "${tensorflow_source_dir}/tensorflow/contrib/boosted_trees/proto/*.proto"
     "${tensorflow_source_dir}/tensorflow/contrib/tpu/proto/*.proto"
 )


Coverage: Added quotes around LCOV_EXCLUDE variable

--- Coverage.cmake
+++ Coverage.cmake
@@ -89,7 +89,7 @@
     get_property(GENERATED_FILES GLOBAL PROPERTY COMMON_GENERATED_FILES)
     add_custom_target(${PROJECT_NAME}-lcov-remove
       COMMAND ${LCOV} -q --remove lcov.info '*.l' 'CMake/test/*'
-        '*/install/*' 'moc_*' 'qrc_*' ${GENERATED_FILES} ${LCOV_EXCLUDE}
+        '*/install/*' 'moc_*' 'qrc_*' ${GENERATED_FILES} '${LCOV_EXCLUDE}'
         --output-file lcov2.info
       COMMENT "Cleaning up code coverage counters"
       WORKING_DIRECTORY ${PROJECT_BINARY_DIR}


fbcode_builder: cmake: propagate thrift include dependencies correctly

Summary:
Update `add_thrift_cpp2_library()` to pass in the correct `-I` flags when
invoking the thrift compiler so that it can find all of the other thrift files
that this library depends on.

D16062657 was a previous attempt to do this, but suffered from a few problems:
- It required all dependencies to be defined before
  `add_thrift_cpp2_library()` was called.  This requires users to carefully
  order their CMake files and subdirectory include ordering.
- It only handled one level of dependencies, and did not propagate include
  paths for deeper dependencies.
- It set the include path for dependencies to the source directory path where
  the dependency was originally built, rather than the directory where the
  thrift file for that dependency would be installed.

This change does require CMake 3.8+.  Previous versions of CMake do not
support using generator expressions to generate multiple arguments for a
custom command.

Reviewed By: strager

Differential Revision: D17005381

fbshipit-source-id: 31190beba94b4d1010445375a5e2791450230f7d

--- build/fbcode_builder/CMake/ThriftCppLibrary.cmake
+++ build/fbcode_builder/CMake/ThriftCppLibrary.cmake
@@ -17,13 +17,24 @@
 #   The sub-directory where generated headers will be installed.
 #   Defaults to "include" if not specified.  The caller must still call
 #   install() to install the thrift library if desired.
+# - THRIFT_INCLUDE_DIR <path>
+#   The sub-directory where generated headers will be installed.
+#   Defaults to "${INCLUDE_DIR}/thrift-files" if not specified.
+#   The caller must still call install() to install the thrift library if
+#   desired.
 function(add_thrift_cpp2_library LIB_NAME THRIFT_FILE)
   # Parse the arguments
   set(one_value_args INCLUDE_DIR)
-  set(multi_value_args SERVICES DEPENDS OPTIONS)
+  set(multi_value_args SERVICES DEPENDS OPTIONS THRIFT_INCLUDE_DIR)
   fb_cmake_parse_args(
     ARG "" "${one_value_args}" "${multi_value_args}" "${ARGN}"
   )
+  if(NOT DEFINED ARG_INCLUDE_DIR)
+    set(ARG_INCLUDE_DIR "include")
+  endif()
+  if(NOT DEFINED ARG_THRIFT_INCLUDE_DIR)
+    set(ARG_THRIFT_INCLUDE_DIR "${ARG_INCLUDE_DIR}/thrift-files")
+  endif()

   get_filename_component(base ${THRIFT_FILE} NAME_WE)
   get_filename_component(
@@ -39,9 +50,6 @@
     "${CMAKE_CURRENT_SOURCE_DIR}/${THRIFT_FILE}"
   )
   get_filename_component(include_prefix ${include_prefix} DIRECTORY)
-  if(NOT DEFINED ARG_INCLUDE_DIR)
-    set(ARG_INCLUDE_DIR "include")
-  endif()

   if (NOT "${include_prefix}" STREQUAL "")
     list(APPEND ARG_OPTIONS "include_prefix=${include_prefix}")
@@ -78,22 +86,21 @@
     )
   endforeach()

-  list(APPEND thrift_include_options -I "${CMAKE_SOURCE_DIR}")
-  foreach(depends IN LISTS ARG_DEPENDS)
-    get_property(thrift_include_directory
-      TARGET ${depends}
-      PROPERTY THRIFT_INCLUDE_DIRECTORY)
-
-    if (thrift_include_directory STREQUAL "")
-      message(STATUS "No thrift dependency found for ${depends}")
-    else()
-      list(
-        APPEND thrift_include_options
-        -I "${thrift_include_directory}"
-      )
-    endif()
-  endforeach()
-
+  # This generator expression gets the list of include directories required
+  # for all of our dependencies.
+  # It requires using COMMAND_EXPAND_LISTS in the add_custom_command() call
+  # below.  COMMAND_EXPAND_LISTS is only available in CMake 3.8+
+  # If we really had to support older versions of CMake we would probably need
+  # to use a wrapper script around the thrift compiler that could take the
+  # include list as a single argument and split it up before invoking the
+  # thrift compiler.
+  if (NOT POLICY CMP0067)
+    message(FATAL_ERROR "add_thrift_cpp2_library() requires CMake 3.8+")
+  endif()
+  set(
+    thrift_include_options
+    "-I;$<JOIN:$<TARGET_PROPERTY:${LIB_NAME}.thrift_includes,INTERFACE_INCLUDE_DIRECTORIES>,;-I;>"
+  )
   file(
     GLOB_RECURSE THRIFT_TEMPLATE_FILES
     FOLLOW_SYMLINKS "${FBTHRIFT_TEMPLATES_DIR}/cpp2/*.mustache"
@@ -104,6 +111,7 @@
     OUTPUT
       ${generated_headers}
       ${generated_sources}
+    COMMAND_EXPAND_LISTS
     COMMAND
       "${CMAKE_COMMAND}" -E make_directory "${output_dir}"
     COMMAND
@@ -111,7 +119,7 @@
       --strict
       --templates "${FBTHRIFT_TEMPLATES_DIR}"
       --gen "mstch_cpp2:${GEN_ARG_STR}"
-      ${thrift_include_options}
+      "${thrift_include_options}"
       -o "${output_dir}"
       "${CMAKE_CURRENT_SOURCE_DIR}/${THRIFT_FILE}"
     WORKING_DIRECTORY
@@ -159,11 +167,27 @@
     PROPERTY PUBLIC_HEADER ${generated_headers}
   )

+  # Define a dummy interface library to help propagate the thrift include
+  # directories between dependencies.
+  add_library("${LIB_NAME}.thrift_includes" INTERFACE)
+  target_include_directories(
+    "${LIB_NAME}.thrift_includes"
+    INTERFACE
+      "$<BUILD_INTERFACE:${CMAKE_SOURCE_DIR}>"
+      "$<INSTALL_INTERFACE:${ARG_THRIFT_INCLUDE_DIR}>"
+  )
+  foreach(dep IN LISTS ARG_DEPENDS)
+    target_link_libraries(
+      "${LIB_NAME}.thrift_includes"
+      INTERFACE "${dep}.thrift_includes"
+    )
+  endforeach()
+
   set_target_properties(
     "${LIB_NAME}"
     PROPERTIES
-      EXPORT_PROPERTIES "THRIFT_INCLUDE_DIRECTORY"
-      THRIFT_INCLUDE_DIRECTORY "${CMAKE_SOURCE_DIR}"
+      EXPORT_PROPERTIES "THRIFT_INSTALL_DIR"
+      THRIFT_INSTALL_DIR "${ARG_THRIFT_INCLUDE_DIR}/${include_prefix}"
       HEADER_INSTALL_DIR "${ARG_INCLUDE_DIR}/${include_prefix}/gen-cpp2"
   )
 endfunction()


Use the same print style as everything else.

--- lib/FindOctomap.cmake
+++ lib/FindOctomap.cmake
@@ -5,11 +5,11 @@

 find_library(OCTOMAP_LIBRARY octomap
 	PATH ${OCTOMAP_LIBPATH})
-message("Find octomap lib ${OCTOMAP_LIBRARY}")
+message("-- Find octomap lib ${OCTOMAP_LIBRARY}")

 find_library(OCTOMAP_OCTOMATH_LIBRARY octomath
 	PATH ${OCTOMAP_LIBPATH})
-message("Find octomath lib ${OCTOMAP_OCTOMATH_LIBRARY}")
+message("-- Find octomath lib ${OCTOMAP_OCTOMATH_LIBRARY}")

 set(OCTOMAP_LIBRARIES


Adding missing set of MATH_LIBS from MATH_LIBS_AT_CONFIG if ScaLAPACK was disabled

--- cmake/external_projects/ElMath.cmake
+++ cmake/external_projects/ElMath.cmake
@@ -177,9 +177,12 @@
   if(EL_HAVE_SCALAPACK)
     set(MATH_LIBS ${SCALAPACK_LIBS})
     set(MATH_LIBS_AT_CONFIG ${SCALAPACK_LIBS_AT_CONFIG})
-  elseif(MATH_LIBS_AT_CONFIG)
-    set(MATH_LIBS ${MATH_LIBS_AT_CONFIG})
-  endif()
+  endif()
+endif()
+if(MATH_LIBS_AT_CONFIG AND NOT MATH_LIBS)
+  # We could not extend MATH_LIBS_AT_CONFIG with ScaLAPACK, so use the
+  # specified BLAS/LAPACK libraries
+  set(MATH_LIBS ${MATH_LIBS_AT_CONFIG})
 endif()

 # Decide on the BLAS/LAPACK libraries


- Put Android libraries in ABI-specific output directory

--- cmake/Modules/BuildFunctions.cmake
+++ cmake/Modules/BuildFunctions.cmake
@@ -74,13 +74,21 @@

     target_enable_cxx11(${TARGET})

-    if(NOT WIN32)
+    if(ANDROID)
+        install(
+            TARGETS
+            ${TARGET}
+
+            DESTINATION
+            lib/${ANDROID_ABI}
+            )
+    elseif(NOT WIN32)
 	install(
 	    TARGETS
 	    ${TARGET}

 	    DESTINATION
-	    lib
+            lib
 	    )
     else()
 	install(


Enable GCC 10 to pass version check

Enable GCC 10 to pass version check

--- cmake/Modules/cvmfs_compiler.cmake
+++ cmake/Modules/cvmfs_compiler.cmake
@@ -38,12 +38,12 @@
 if (CMAKE_COMPILER_IS_GNUCC)
   message (STATUS "checking gcc version...")
   execute_process (
-    COMMAND ${CMAKE_C_COMPILER} -v
+    COMMAND ${CMAKE_C_COMPILER} -dumpfullversion
     OUTPUT_VARIABLE CVMFS_GCC_VERSION
     ERROR_VARIABLE  CVMFS_GCC_VERSION
   )
-  STRING(REGEX REPLACE ".*([0-9]+)\\.[0-9]+\\.[0-9]+.*" "\\1" CVMFS_GCC_MAJOR "${CVMFS_GCC_VERSION}")
-  STRING(REGEX REPLACE ".*[0-9]+\\.([0-9]+)\\.[0-9]+.*" "\\1" CVMFS_GCC_MINOR "${CVMFS_GCC_VERSION}")
+  STRING(REGEX REPLACE "([0-9]+)\\.[0-9]+\\.[0-9]+" "\\1" CVMFS_GCC_MAJOR "${CVMFS_GCC_VERSION}")
+  STRING(REGEX REPLACE "[0-9]+\\.([0-9]+)\\.[0-9]+" "\\1" CVMFS_GCC_MINOR "${CVMFS_GCC_VERSION}")
   if (${CVMFS_GCC_MAJOR} LESS 4)
     message (FATAL_ERROR "GCC < 4.1 unsupported")
   endif (${CVMFS_GCC_MAJOR} LESS 4)
@@ -94,4 +94,4 @@
     message("Enable inotify support")
     set(CVMFS_ENABLE_INOTIFY ON)
   endif(HAS_INOTIFY_INIT1)
-endif(${CMAKE_SYSTEM_NAME} STREQUAL "Linux")+endif(${CMAKE_SYSTEM_NAME} STREQUAL "Linux")


Simplifying CMake dependency handling

Simplifying CMake dependency handling

* Update FindMKL.cmake module
* Separate find/cmake package manager mode
* Fixed conan build

Former-commit-id: a7f5cb4be5d3adf4ffcf81a712b50610f9a58f47

--- cmake/SetupDependenciesConan.cmake
+++ cmake/SetupDependenciesConan.cmake
@@ -3,23 +3,19 @@

     #  Make sure we use DMRG's own find modules
     list(INSERT CMAKE_MODULE_PATH 0  ${PROJECT_SOURCE_DIR}/cmake)
-    ##############################################################################
-    ###  Required OpenMP support                                               ###
-    ###  Note that Clang has some  trouble with static openmp and that         ###
-    ###  and that static openmp is not recommended. This tries to enable       ###
-    ###  static openmp anyway because I find it useful. Installing             ###
-    ###  libiomp5 might help for shared linking.                               ###
-    ##############################################################################
     if(DMRG_ENABLE_OPENMP)
-        find_package(OpenMP COMPONENTS CXX REQUIRED) # Uses DMRG's own find module
-    endif()
-
+        find_package(OpenMP COMPONENTS CXX REQUIRED)
+        set(mkl_thread gnu_thread)
+    else()
+        set(mkl_thread sequential)
+    endif()
+
+    find_package(Fortran REQUIRED)
     ##############################################################################
     ###  Optional Intel MKL support. Uses OpenBLAS as fall-back                ###
     ##############################################################################
     if(DMRG_ENABLE_MKL)
-        find_package(Fortran REQUIRED)
-        include(cmake/SetupMKL.cmake)         # MKL - Intel's math Kernel Library, use the BLAS implementation in Eigen and Arpack. Includes lapack.
+        find_package(MKL COMPONENTS blas lapack gf ${mkl_thread} lp64 REQUIRED)  # MKL - Intel's math Kernel Library, use the BLAS implementation in Eigen and Arpack. Includes lapack.
         if(TARGET mkl::mkl)
             include(cmake/getExpandedTarget.cmake)
             expand_target_libs(mkl::mkl MKL_LIBRARIES)
@@ -32,9 +28,6 @@
                     OPTIONS arpack-ng:blas=All
                     OPTIONS arpack-ng:blas_libraries=${MKL_LIBRARIES}
                     OPTIONS arpack-ng:lapack_libraries=${MKL_LIBRARIES}
-                    #OPTIONS ceres-solver:blas=All
-                    #OPTIONS ceres-solver:blas_libraries=${MKL_LIBRARIES}
-                    #OPTIONS ceres-solver:lapack_libraries=${MKL_LIBRARIES}
                     )
         else()
             message(FATAL_ERROR "Undefined target: mkl::mkl")
@@ -96,7 +89,7 @@
                 CONAN_COMMAND
                 conan
                 HINTS ${CONAN_PREFIX} $ENV{CONAN_PREFIX} ${CONDA_PREFIX} $ENV{CONDA_PREFIX}
-                PATHS $ENV{HOME}/anaconda3  $ENV{HOME}/miniconda3 $ENV{HOME}/anaconda $ENV{HOME}/miniconda $ENV{HOME}/.conda
+                PATHS $ENV{HOME}/.local $ENV{HOME}/anaconda3  $ENV{HOME}/miniconda3 $ENV{HOME}/anaconda $ENV{HOME}/miniconda $ENV{HOME}/.conda
                 PATH_SUFFIXES bin envs/dmrg/bin
         )
         if(NOT CONAN_COMMAND)
@@ -197,39 +190,15 @@

     # Make aliases
-    add_library(OpenBLAS::OpenBLAS  ALIAS CONAN_PKG::openblas)
     add_library(Eigen3::Eigen       ALIAS CONAN_PKG::eigen)
     add_library(h5pp::h5pp          ALIAS CONAN_PKG::h5pp)
     add_library(spdlog::spdlog      ALIAS CONAN_PKG::spdlog)
     add_library(arpack::arpack++    ALIAS CONAN_PKG::arpack++)
     add_library(Ceres::ceres        ALIAS CONAN_PKG::ceres-solver)
+    if(TARGET CONAN_PKG::openblas)
+        add_library(OpenBLAS::OpenBLAS  ALIAS CONAN_PKG::openblas)
+    endif()
     if(TARGET CONAN_PKG::libunwind)
         add_library(unwind::unwind      ALIAS CONAN_PKG::libunwind)
     endif()
-
-    # Gather the targets
-#    if(TARGET OpenMP::OpenMP_CXX)
-#        target_link_libraries(dmrg-flags INTERFACE OpenMP::OpenMP_CXX)
-#    else()
-#        target_compile_options(dmrg-flags INTERFACE -Wno-unknown-pragmas)
-#    endif()
-#    target_link_libraries(dmrg-deps INTERFACE
-#            CONAN_PKG::h5pp
-#            CONAN_PKG::ceres-solver
-#            CONAN_PKG::eigen
-#            CONAN_PKG::arpack++)
-#    target_link_libraries(dmrg-main PUBLIC CONAN_PKG::h5pp)
-#    target_link_libraries(dmrg-opt PUBLIC CONAN_PKG::spdlog CONAN_PKG::eigen CONAN_PKG::ceres-solver)
-#    target_link_libraries(dmrg-eig PUBLIC CONAN_PKG::spdlog CONAN_PKG::eigen)
-#    target_link_libraries(dmrg-arp PUBLIC CONAN_PKG::spdlog CONAN_PKG::arpack++)
-#    if(TARGET mkl::mkl)
-#        target_link_libraries(dmrg-arp PUBLIC mkl::mkl)
-#    elseif(TARGET CONAN_PKG::openblas)
-#        target_link_libraries(dmrg-arp PUBLIC CONAN_PKG::openblas)
-#    endif()
-#
-#    if(TARGET CONAN_PKG::libunwind)
-#        target_link_libraries(dmrg-dbg PRIVATE CONAN_PKG::libunwind)
-#        target_compile_definitions(dmrg-dbg PUBLIC DMRG_HAS_UNWIND=1)
-#    endif()
 endif()


added boost timer library for Gadgetron

added boost timer library for Gadgetron

--- SuperBuild/External_Boost_configureboost.cmake
+++ SuperBuild/External_Boost_configureboost.cmake
@@ -3,7 +3,7 @@
     WORKING_DIRECTORY ${BUILD_DIR} RESULT_VARIABLE bootstrap_result)
 else(WIN32)
   execute_process(COMMAND ./bootstrap.sh --prefix=${BOOST_INSTALL_DIR}
-    --with-libraries=system,filesystem,thread,program_options,chrono,date_time,atomic
+    --with-libraries=system,filesystem,thread,program_options,chrono,date_time,atomic,timer
     #--with-libraries=system,thread,program_options,log,math...
     #--without-libraries=atomic...


cmake: stage: better message when staging lib with other name

--- cmake/qibuild/internal/stage.cmake
+++ cmake/qibuild/internal/stage.cmake
@@ -248,7 +248,7 @@
   file(WRITE "${_sdk_file}" "${_sdk}")

   if(_staged_name)
-    message(STATUS "Staging with an other name!")
+    message(STATUS "Staging ${_staged_name} instead of ${target}!")
     string(TOUPPER ${target} _U_target)
     string(TOLOWER ${_staged_name} _other_name)
     string(REPLACE ${_U_target} ${_staged_name} _other_redist "${_redist}")


Remove flags which have already been defined in configure.cmake.

Add a note to investigate -felide-constructors usage on OSX.

--- cmake/build_configurations/mysql_release.cmake
+++ cmake/build_configurations/mysql_release.cmake
@@ -136,7 +136,7 @@
     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 -fno-implicit-templates -felide-constructors -fno-exceptions -fno-rtti")
+    SET(COMMON_CXX_FLAGS               "-g -static-libgcc -fno-omit-frame-pointer")
     SET(CMAKE_CXX_FLAGS_DEBUG          "-O ${COMMON_CXX_FLAGS}")
     SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O3 ${COMMON_CXX_FLAGS}")
   ENDIF()
@@ -161,7 +161,7 @@
   IF(CMAKE_SYSTEM_NAME MATCHES "Linux")
     IF(CMAKE_C_COMPILER_ID MATCHES "Intel")
       SET(COMMON_C_FLAGS                 "-static-intel -static-libgcc -g -mp -restrict")
-      SET(COMMON_CXX_FLAGS               "-static-intel -static-libgcc -g -mp -restrict -fno-implicit-templates -fno-exceptions -fno-rtti")
+      SET(COMMON_CXX_FLAGS               "-static-intel -static-libgcc -g -mp -restrict -fno-exceptions -fno-rtti")
       IF(CMAKE_SYSTEM_PROCESSOR MATCHES "ia64")
         SET(COMMON_C_FLAGS               "${COMMON_C_FLAGS} -no-ftz -no-prefetch")
         SET(COMMON_CXX_FLAGS             "${COMMON_CXX_FLAGS} -no-ftz -no-prefetch")
@@ -177,7 +177,8 @@
   # OSX flags
   IF(APPLE)
     SET(COMMON_C_FLAGS                 "-g -fno-common")
-    SET(COMMON_CXX_FLAGS               "-g -fno-common -felide-constructors -fno-implicit-templates -fno-exceptions -fno-rtti")
+    # XXX: why are we using -felide-constructors on OSX?
+    SET(COMMON_CXX_FLAGS               "-g -fno-common -felide-constructors")
     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}")


ARROW-3147: [C++] Improve MSVC version detection

There is no space between "Microsoft" and "(R)" in cl.exe output on
code page 932.

Author: Kouhei Sutou <kou@clear-code.com>

Closes #2499 from kou/cpp-windows-improve-msvc-version-detection and squashes the following commits:

f00ef330 <Kouhei Sutou>  Improve MSVC version detection

--- cpp/cmake_modules/CompilerInfo.cmake
+++ cpp/cmake_modules/CompilerInfo.cmake
@@ -33,7 +33,7 @@

 if(MSVC)
   set(COMPILER_FAMILY "msvc")
-  if ("${COMPILER_VERSION_FULL}" MATCHES ".*Microsoft \\(R\\) C/C\\+\\+ Optimizing Compiler Version 19.*x64")
+  if ("${COMPILER_VERSION_FULL}" MATCHES ".*Microsoft ?\\(R\\) C/C\\+\\+ Optimizing Compiler Version 19.*x64")
     string(REGEX REPLACE ".*Optimizing Compiler Version ([0-9]+\\.[0-9]+\\.[0-9]+\\.[0-9]+).*" "\\1"
       COMPILER_VERSION "${COMPILER_VERSION_FULL}")
   elseif(NOT "${COMPILER_VERSION_FULL}" STREQUAL "")


ARROW-4360: [C++] Query homebrew for Thrift

Author: Korn, Uwe <Uwe.Korn@blue-yonder.com>

Closes #3473 from xhochy/ARROW-4360 and squashes the following commits:

11503a2b <Korn, Uwe> ARROW-4360:  Query homebrew for Thrift

--- cpp/cmake_modules/FindThrift.cmake
+++ cpp/cmake_modules/FindThrift.cmake
@@ -34,6 +34,17 @@
     list( APPEND _thrift_roots ${_native_path} )
 elseif ( Thrift_HOME )
     list( APPEND _thrift_roots ${Thrift_HOME} )
+elseif (APPLE)
+  # Also look in homebrew for a matching llvm version
+  find_program(BREW_BIN brew)
+  if (BREW_BIN)
+    execute_process(
+      COMMAND ${BREW_BIN} --prefix "thrift"
+      OUTPUT_VARIABLE THRIFT_BREW_PREFIX
+      OUTPUT_STRIP_TRAILING_WHITESPACE
+    )
+    list( APPEND _thrift_roots ${THRIFT_BREW_PREFIX} )
+  endif()
 endif()

 message(STATUS "THRIFT_HOME: ${THRIFT_HOME}")


Minor formatting fix.

Minor formatting fix.

--- cmake/fp.cmake
+++ cmake/fp.cmake
@@ -1,7 +1,7 @@
 message(STATUS "Prime field arithmetic configuration (FP module):\n")

 message("   ** Arithmetic precision of the prime field module (default = 256,0,off,off):")
-message("      FP_PRIME=n        The prime modulus size in bits.\n")
+message("      FP_PRIME=n        The prime modulus size in bits.")
 message("      FP_KARAT=n        The number of Karatsuba levels.")
 message("      FP_PMERS=[off|on] Prefer Pseudo-Mersenne primes over random primes.")
 message("      FP_QNRES=[off|on] Use -1 as quadratic non-residue (make sure that p = 3 mod 8).")


fix: Use basis_target_link_libraries to add another target as link dependency [CMake]

This allows basis_export_targets to check that all targets that a given target depends on are being exported as well.

--- CMake/Modules/mirtkTargetDependencies.cmake
+++ CMake/Modules/mirtkTargetDependencies.cmake
@@ -44,9 +44,12 @@
       mirtk_get_target_name(dep_name "${dep}")
       if (TARGET "${dep_name}")
         get_target_property(dep_type ${dep_name} TYPE)
-        # Add dependency on imported link library
+        # Add dependency on (imported|other) library target
         if (dep_type MATCHES "LIBRARY")
-          target_link_libraries(${target_uid} ${dep_attr} ${dep_name})
+          # Need to use basis_target_link_libraries such that BASIS can add
+          # link dependencies of non-imported targets added via add_library
+          # instead of basis_add_library to the export set if necessary
+          basis_target_link_libraries(${target_uid} ${dep_attr} ${dep_name})
           get_property(dep_imported TARGET ${dep_name} PROPERTY IMPORTED)
           if (dep_imported)
             basis_get_target_location(dep_path ${dep_name} PATH)


Disable warning #135 on intel compilers.

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

--- deal.II/cmake/setup_compiler_flags_intel.cmake
+++ deal.II/cmake/setup_compiler_flags_intel.cmake
@@ -62,6 +62,14 @@
 #   -w68   integer conversion resulted in a change of sign
 #          (triggers a lot in functionparser)
 #   -w175  subscript out of range
+#   -w135  class template "dealii::FE_Q_Base<POLY, dim, spacedim>"
+#          has no member "Implementation"
+#          (the compiler is objectively wrong since the warning
+#           triggers also on code of the form
+#           class FE_Q_Base {
+#             struct Implementation; // forward declaration
+#             friend struct Implementation;
+#           };)
 #   -w177  declared but not referenced
 #   -w279  controlling expression is constant
 #   -w327  NULL reference is not allowed
@@ -78,6 +86,7 @@
 #   -w2536 type qualifiers are meaningless here
 #
 ENABLE_IF_SUPPORTED(CMAKE_CXX_FLAGS "-wd68")
+ENABLE_IF_SUPPORTED(CMAKE_CXX_FLAGS "-wd135")
 ENABLE_IF_SUPPORTED(CMAKE_CXX_FLAGS "-wd175")
 ENABLE_IF_SUPPORTED(CMAKE_CXX_FLAGS "-wd177")
 ENABLE_IF_SUPPORTED(CMAKE_CXX_FLAGS "-wd279")


Fix header installation path.

Fix header installation path.

--- include/SCD/SourcesLib.cmake
+++ include/SCD/SourcesLib.cmake
@@ -7,8 +7,8 @@
   source_group("${sub_folder}" FILES ${allfiles})

   install(FILES ${allfiles}
-	DESTINATION ${CMAKE_INSTALL_PREFIX}/include/${PROJECT_NAME}/${sub_folder}
-	PERMISSIONS OWNER_READ GROUP_READ WORLD_READ OWNER_WRITE
+       DESTINATION ${CMAKE_INSTALL_PREFIX}/include/SCD/${sub_folder}
+       PERMISSIONS OWNER_READ GROUP_READ WORLD_READ OWNER_WRITE
   )

   list(APPEND  HEADERS 	${allfiles})


Adding auto detection of gcc version for the mingw and linux cases.

--- Resources/MXAFindBoost.cmake
+++ Resources/MXAFindBoost.cmake
@@ -242,37 +242,52 @@
 ENDMACRO (_BOOST_ADJUST_LIB_VARS)

 #-------------------------------------------------------------------------------
-    SET (BOOST_LIB_PREFIX "")
-    IF ( MSVC )
-        SET (BOOST_LIB_PREFIX "lib")  # Looks for the static libraries by default
-    ENDIF ( MSVC )
+SET (BOOST_LIB_PREFIX "")
+IF ( MSVC )
+    SET (BOOST_LIB_PREFIX "lib")  # Looks for the static libraries by default
+ENDIF ( MSVC )

-    IF (NOT DEFINED BOOST_COMPILER)
-      SET (BOOST_COMPILER "-gcc")
-      IF (MSVC71)
+IF (NOT DEFINED BOOST_COMPILER)
+    SET (BOOST_COMPILER "-gcc")
+    IF (MSVC71)
         SET (BOOST_COMPILER "-vc71")
-      ENDIF(MSVC71)
-       IF (MSVC80)
+    ENDIF(MSVC71)
+    IF (MSVC80)
         SET (BOOST_COMPILER "-vc80")
-      ENDIF(MSVC80)
-      IF (MINGW)
-        SET (BOOST_COMPILER "-mgw34")
-      ENDIF(MINGW)
-      IF (CYGWIN)
+    ENDIF(MSVC80)
+    IF (MSVC90)
+        SET (_boost_COMPILER "-vc90")
+    ENDIF (MSVC90)
+    IF (MINGW)
+        EXEC_PROGRAM(${CMAKE_CXX_COMPILER}
+            ARGS --version
+            OUTPUT_VARIABLE _boost_COMPILER_VERSION
+        )
+        STRING(REGEX REPLACE ".* ([0-9])\\.([0-9])\\.[0-9] .*" "\\1\\2"
+           _boost_COMPILER_VERSION ${_boost_COMPILER_VERSION})
+        SET (_boost_COMPILER "-mgw${_boost_COMPILER_VERSION}")
+    ENDIF(MINGW)
+    IF (CYGWIN)
         SET (BOOST_COMPILER "-gcc")
-      ENDIF (CYGWIN)
-        IF (UNIX)
-            IF (APPLE)
-                SET (BOOST_COMPILER "")
-            ELSE (APPLE)
-                IF (NOT CMAKE_COMPILER_IS_GNUCC)
-                    SET (BOOST_COMPILER "-il")  # This is for the intel compiler
-                ELSE (NOT CMAKE_COMPILER_IS_GNUCC)
-                    SET (BOOST_COMPILER "-gcc34")
-                ENDIF (NOT CMAKE_COMPILER_IS_GNUCC)
-            ENDIF (APPLE)
-        ENDIF(UNIX)
-    ENDIF (NOT DEFINED BOOST_COMPILER)
+    ENDIF (CYGWIN)
+    IF (UNIX)
+        IF (APPLE)
+            SET (BOOST_COMPILER "")
+        ELSE (APPLE)
+            IF (NOT CMAKE_COMPILER_IS_GNUCC)
+                SET (BOOST_COMPILER "-il")  # This is for the intel compiler
+            ELSE (NOT CMAKE_COMPILER_IS_GNUCC)
+                EXEC_PROGRAM(${CMAKE_CXX_COMPILER}
+                    ARGS --version
+                    OUTPUT_VARIABLE _boost_COMPILER_VERSION
+                )
+                STRING(REGEX REPLACE ".* ([0-9])\\.([0-9])\\.[0-9] .*" "\\1\\2"
+                   _boost_COMPILER_VERSION ${_boost_COMPILER_VERSION})
+                SET (_boost_COMPILER "-gcc${_boost_COMPILER_VERSION}")
+            ENDIF (NOT CMAKE_COMPILER_IS_GNUCC)
+        ENDIF (APPLE)
+    ENDIF(UNIX)
+  ENDIF (NOT DEFINED BOOST_COMPILER)

   IF(BOOST_USE_MULTITHREADED)
     SET (BOOST_MULTITHREADED "-mt")


comment SET(CTEST_NIGHTLY_START_TIME "20:00:00 EST") because it seems to produce error on svn update in ctest script.
see: http://cmake.3232098.n2.nabble.com/CTest-Update-not-updating-to-head-revision-svn-td5003895.html

git-svn-id: ed1ce8e5c168003d808aec37bc6fda77b178f7bb@3419 c330d7e9-fc0c-0410-a5b3-fd85c6f5aa8f

--- trunk/test/openVibeTests.cmake
+++ trunk/test/openVibeTests.cmake
@@ -109,7 +109,7 @@
 ctest_read_custom_files("${CTEST_BINARY_DIRECTORY}")

 SET(CTEST_PROJECT_NAME "OpenViBe")
-SET(CTEST_NIGHTLY_START_TIME "20:00:00 EST")
+#SET(CTEST_NIGHTLY_START_TIME "20:00:00 EST")
 SET(CTEST_DROP_METHOD "http")
 SET(CTEST_DROP_SITE "cdash.inria.fr")
 SET(CTEST_DROP_LOCATION "/CDash/submit.php?project=OpenViBe")


Add msvc cxx arch check.

Add msvc cxx arch check.

--- src/inserts/functions.cmake
+++ src/inserts/functions.cmake
@@ -278,7 +278,7 @@
     endif()

     set(msvc_arch)
-    if (MSVC AND MSVC_C_ARCHITECTURE_ID)
+    if (MSVC AND (MSVC_C_ARCHITECTURE_ID OR MSVC_CXX_ARCHITECTURE_ID))
         prepare_config_part(msvc_arch ${MSVC_C_ARCHITECTURE_ID})
         set(msvc_arch ${CPPAN_CONFIG_PART_DELIMETER}${msvc_arch})


perf(android): enable all processors when building android

--- cmake/Toolchain-Android.cmake
+++ cmake/Toolchain-Android.cmake
@@ -4,3 +4,6 @@

 # Use the clang tool set because it's support for C++11 is superior
 set(CMAKE_GENERATOR_TOOLSET DefaultClang)
+
+# Make sure we use all our processors when building
+set(CMAKE_ANDROID_PROCESS_MAX $ENV{NUMBER_OF_PROCESSORS})


first check CLFFT_ROOT, then system paths.

--- cmake/modules/FindclFFT.cmake
+++ cmake/modules/FindclFFT.cmake
@@ -14,37 +14,39 @@
 # may provide a hint to where it may be found. Simply set the value CLFFT_ROOT
 # to the directory containing 'include/clFFT.h" prior to calling this script.

+if(CLFFT_ROOT)
+  find_path(CLFFT_ROOT_DIR
+    NAMES include/clFFT.h
+    PATHS ${CLFFT_ROOT}
+    PATHS ENV CLFFT_ROOT
+    DOC "clFFT root directory."
+    NO_DEFAULT_PATH)
+  find_path(_CLFFT_INCLUDE_DIRS
+    NAMES clFFT.h
+    PATHS ${CLFFT_ROOT_DIR} /usr
+    PATH_SUFFIXES include
+    DOC "clFFT include directory"
+    NO_DEFAULT_PATH)
+  find_library(_CLFFT_LIBRARY
+    NAMES clFFT
+    PATHS ${CLFFT_ROOT_DIR} /usr
+    PATH_SUFFIXES lib lib64 lib/import lib64/import
+    DOC "clFFT library directory"
+    NO_DEFAULT_PATH)

-find_path(CLFFT_ROOT_DIR
-  NAMES include/clFFT.h
-  PATHS CLFFT_ROOT
-  PATHS ENV CLFFT_ROOT
-  DOC "clFFT root directory.")
+else()
+  find_path(CLFFT_ROOT_DIR
+    NAMES include/clFFT.h
+    DOC "clFFT root directory.")

-find_path(CLFFT_ROOT_DIR
-  NAMES include/clFFT.h
-  DOC "clFFT root directory.")
+  find_path(_CLFFT_INCLUDE_DIRS
+    NAMES clFFT.h
+    DOC "clFFT include directory")

-find_path(_CLFFT_INCLUDE_DIRS
-  NAMES clFFT.h
-  PATHS "${CLFFT_ROOT_DIR}" "/usr"
-  PATH_SUFFIXES "include"
-  DOC "clFFT include directory")
-
-find_path(_CLFFT_INCLUDE_DIRS
-  NAMES clFFT.h
-  DOC "clFFT include directory")
-
-find_library(_CLFFT_LIBRARY
-  NAMES clFFT
-  PATHS "${CLFFT_ROOT_DIR}" "/usr"
-  PATH_SUFFIXES "lib" "lib64"
-  DOC "clFFT library directory")
-
-find_library(_CLFFT_LIBRARY
-  NAMES clFFT
-  DOC "clFFT library directory")
-
+  find_library(_CLFFT_LIBRARY
+    NAMES clFFT
+    DOC "clFFT library directory")
+endif()

 set(clFFT_INCLUDE_DIRS ${_CLFFT_INCLUDE_DIRS})
 set(clFFT_LIBRARIES ${_CLFFT_LIBRARY})


ENH: Change default TEST_LABELS for module

Currently, the TEST_LABELS for a vtk module defaults to the empty
string. Currently, only one VTK module sets TEST_LABELS in its
module.cmake file (vtkWebCore). This patch sets the default to the
name of the module. This faciliates testing of individuyal modules.

For example, when using the testing script vtk_common.cmake, one can set

set(MODULE "vtkCommonCore")

set(CTEST_TEST_ARGS INCLUDE_LABEL ${MODULE})

and the testing script will only test those tests which have the label
vtkCommponCore. This is especially useful for remote modules. Rather
than running all of vtk's tests, a test script would just run the remote
module's tests.

--- CMake/vtkModuleMacros.cmake
+++ CMake/vtkModuleMacros.cmake
@@ -57,7 +57,7 @@
   set(${vtk-module}_EXCLUDE_FROM_ALL 0)
   set(${vtk-module}_EXCLUDE_FROM_WRAPPING 0)
   set(${vtk-module}_EXCLUDE_FROM_WRAP_HIERARCHY 0)
-  set(${vtk-module}_TEST_LABELS "")
+  set(${vtk-module}_TEST_LABELS "${vtk-module}")
   set(${vtk-module}_KIT "")
   foreach(arg ${ARGN})
     # XXX: Adding a new keyword? Update Utilities/Maintenance/WhatModulesVTK.py


cmake-modules:
 * FindThirdPartyMatlab.cmake : delay-load matlab dlls.

git-svn-id: ed1ce8e5c168003d808aec37bc6fda77b178f7bb@3068 c330d7e9-fc0c-0410-a5b3-fd85c6f5aa8f

--- trunk/cmake-modules/FindThirdPartyMatlab.cmake
+++ trunk/cmake-modules/FindThirdPartyMatlab.cmake
@@ -24,6 +24,9 @@
 			IF(WIN32)
 				SET(Matlab_LIBRARIES libmex libmx libeng)
 				SET(Matlab_LIB_DIRECTORIES ${Matlab_ROOT}/extern/lib/win32/microsoft)
+				# for delayed importation on windows
+				TARGET_LINK_LIBRARIES(${PROJECT_NAME}-dynamic Delayimp )
+				SET_TARGET_PROPERTIES(${PROJECT_NAME}-dynamic PROPERTIES LINK_FLAGS "/DELAYLOAD:libeng.dll /DELAYLOAD:libmx.dll /DELAYLOAD:libmex.dll")
 			ENDIF(WIN32)
 			SET(Matlab_FOUND TRUE)
 		ELSE(Matlab_INCLUDE)
@@ -47,7 +50,6 @@
 			MESSAGE(STATUS "    [FAILED] Third party lib ${Matlab_LIB}")
 		ENDIF(Matlab_LIB1)
 	ENDFOREACH(Matlab_LIB)
-
 	ADD_DEFINITIONS(-DTARGET_HAS_ThirdPartyMatlab)
 ELSE(Matlab_FOUND)
 	MESSAGE(STATUS "  FAILED to find Matlab...")


Modified targets file writing for earlier versions of CMake.

--- pkg/CMakeCommon.cmake
+++ pkg/CMakeCommon.cmake
@@ -21,7 +21,12 @@
     endforeach()

     # Output the list of files to be installed in the package
-    file(GENERATE OUTPUT "${OUTPUT_FILE}" CONTENT "${PKG_INSTALL_LIBS_FILES}")
+    IF(${CMAKE_MAJOR_VERSION} LESS 3)
+        file(WRITE "${OUTPUT_FILE}" "${PKG_INSTALL_LIBS_FILES}")
+    ELSE ()
+        file(GENERATE OUTPUT "${OUTPUT_FILE}"
+             CONTENT "${PKG_INSTALL_LIBS_FILES}")
+    ENDIF ()
 endfunction ()

 function (write_bin_files PKG_INSTALL_BINS OUTPUT_FILE)
@@ -40,7 +45,12 @@
     endforeach()

     # Output the list of files to be installed in the package
-    file(GENERATE OUTPUT "${OUTPUT_FILE}" CONTENT "${PKG_INSTALL_BINS_FILES}")
+    IF(${CMAKE_MAJOR_VERSION} LESS 3)
+        file(WRITE "${OUTPUT_FILE}" "${PKG_INSTALL_BINS_FILES}")
+    ELSE ()
+        file(GENERATE OUTPUT "${OUTPUT_FILE}"
+             CONTENT "${PKG_INSTALL_BINS_FILES}")
+    ENDIF ()
 endfunction ()

 macro (add_deb_package)


Compiled with Python 2.6.4 (for MODO)

Compiled with Python 2.6.4 (for MODO)

--- cmake/SpecializedConfig/Config_Dade-win64.cmake
+++ cmake/SpecializedConfig/Config_Dade-win64.cmake
@@ -29,7 +29,7 @@
 set(FREEIMAGE_ROOT_DIR "${FREEIMAGE_SEARCH_PATH}/Dist")

 #set(Boost_DEBUG 1)
-set(BOOST_SEARCH_PATH         "E:/projects/luxrays-64bit/boost_1_48_0")
+set(BOOST_SEARCH_PATH         "E:/projects/luxrays-64bit/boost_1_48_0-python26")
 set(BOOST_LIBRARYDIR          "${BOOST_SEARCH_PATH}/stage/lib")

 set(OPENCL_SEARCH_PATH        "C:/Program Files (x86)/AMD APP")


ENH: Update niral_utilities version to r89 to support ITK being built with DCMTK

--- SuperBuild/External_niral_utilities.cmake
+++ SuperBuild/External_niral_utilities.cmake
@@ -77,7 +77,7 @@

   ### --- End Project specific additions
   set(${proj}_REPOSITORY "https://www.nitrc.org/svn/niral_utilities/trunk")
-  set(${proj}_SVN_REVISION -r "88")
+  set(${proj}_SVN_REVISION -r "89")
   ExternalProject_Add(${proj}
     SVN_REPOSITORY ${${proj}_REPOSITORY}
     SVN_REVISION ${${proj}_SVN_REVISION}


[cmake] FindBinaryen search for include dir and libraries

--- CMakeModules/FindBinaryen.cmake
+++ CMakeModules/FindBinaryen.cmake
@@ -6,9 +6,13 @@
 #  BINARYEN_DEFINITIONS - Compiler switches required for using BINARYEN

 find_program(BINARYEN_BIN s2wasm HINTS ${BINARYEN_ROOT}/bin)
+find_path(BINARYEN_INCLUDE_DIRS binaryen-c.h HINTS ${BINARYEN_ROOT}/include)
+find_library(BINARYEN_LIBRARIES binaryen HINTS ${BINARYEN_ROOT}/lib)

 include(FindPackageHandleStandardArgs)
 # handle the QUIETLY and REQUIRED arguments and set BINARYEN_FOUND to TRUE
 # if all listed variables are TRUE

-find_package_handle_standard_args(BINARYEN DEFAULT_MSG BINARYEN_BIN)
+find_package_handle_standard_args(BINARYEN DEFAULT_MSG BINARYEN_BIN BINARYEN_INCLUDE_DIRS BINARYEN_LIBRARIES )
+
+mark_as_advanced(BINARYEN_BIN BINARYEN_INCLUDE_DIRS BINARYEN_LIBRARIES)


cmake: Add system specific information for Rocky Linux 8.

Signed-off-by: Oliver Freyermuth <297815a44ac0d229e08a814adf0f210787d04d87@googlemail.com>

--- build/cmake/macros/SystemSpecificInformations.cmake
+++ build/cmake/macros/SystemSpecificInformations.cmake
@@ -150,6 +150,15 @@
 	set(SYSTEM_NAME "centos${CMAKE_MATCH_1}")
 	set(RPM_SYSTEM_NAME "${SYSTEM_NAME}")
       endif(LINUX_ISSUE MATCHES "CentOS")
+      # Rocky case
+      # Rocky Linux release 8.4 (Green Obsidian)
+      if(LINUX_ISSUE MATCHES "Rocky Linux")
+	string(REGEX MATCH "release ([0-9]+\\.*[0-9]*)" ROCKY "${LINUX_ISSUE}")
+        set(LINUX_NAME "Rocky")
+	set(LINUX_VER "${CMAKE_MATCH_1}")
+	set(SYSTEM_NAME "rocky${CMAKE_MATCH_1}")
+	set(RPM_SYSTEM_NAME "${SYSTEM_NAME}")
+      endif(LINUX_ISSUE MATCHES "Rocky Linux")
       # Redhat case
       # Red Hat Enterprise Linux Server release 5 (Tikanga)
       if(LINUX_ISSUE MATCHES "Red Hat")


use ThriftCppLibrary.cmake from fbcode_builder

Summary:
Update fboss to use `ThriftCppLibrary.cmake` directly from fbcode_builder
rather than maintaining its own copy of this file.

Reviewed By: chadaustin

Differential Revision: D17005421

fbshipit-source-id: a64df426118df6088b47f09410dad7b8b7e79a43

--- build/fbcode_builder/CMake/ThriftCppLibrary.cmake
+++ build/fbcode_builder/CMake/ThriftCppLibrary.cmake
@@ -1,6 +1,4 @@
 # Copyright (c) Facebook, Inc. and its affiliates.
-# NOTE: If you change this file, fbcode/fboss/github/ThriftCppLibrary.cmake also
-# needs to be changed.  TODO: this should be handled via shipit.

 include(FBCMakeParseArgs)


cpp-example: fix issue with "fixed" soname

--- cpp-example/cpp-part/cmake/rust_part_lib.cmake
+++ cpp-example/cpp-part/cmake/rust_part_lib.cmake
@@ -84,7 +84,11 @@
   COMMAND ${CARGO_BUILD}
   WORKING_DIRECTORY "${RUST_BUILD_CWD}")
 add_custom_target(rust_part_lib_target DEPENDS ${RUST_PART_LIB_PATH})
-add_library(rust_part_lib UNKNOWN IMPORTED GLOBAL)
+if (MSVC)
+  add_library(rust_part_lib UNKNOWN IMPORTED GLOBAL)
+else ()
+  add_library(rust_part_lib SHARED IMPORTED GLOBAL)
+endif ()
 add_dependencies(rust_part_lib rust_part_lib_target)
 add_dependencies(rust_part_lib rust_swig_gen_headers)
 set_target_properties(rust_part_lib


添加文件的md5计算

添加文件的md5计算

--- build/cmake/dxm_module/dxm_module_md5.cmake
+++ build/cmake/dxm_module/dxm_module_md5.cmake
@@ -42,6 +42,12 @@
 macro(dxm_module_add_directory_md5 MODULE DIRECTORY)
 	if(EXISTS ${DXM_MODULE_${MODULE}_DIRECTORY}/${DIRECTORY})
 		dxm_file_md5dir(${DXM_MODULE_${MODULE}_DIRECTORY}/${DIRECTORY} DXM_MODULE_${MODULE}_MD5)
+	endif()
+endmacro()
+
+macro(dxm_module_add_file_md5 MODULE FILE_PATH)
+	if(EXISTS ${DXM_MODULE_${MODULE}_DIRECTORY}/${FILE_PATH})
+		dxm_file_md5file(${DXM_MODULE_${MODULE}_DIRECTORY}/${FILE_PATH} DXM_MODULE_${MODULE}_MD5)
 	endif()
 endmacro()
 #


Reactivate -O2 for icc-14*

Reactivate -O2 for icc-14*

git-svn-id: 59f82343654cec32357d3b049d399063e4e4cfc7@31193 0785d39b-7218-0410-832d-ea1e28bc413d

--- deal.II/cmake/setup_compiler_flags_intel.cmake
+++ deal.II/cmake/setup_compiler_flags_intel.cmake
@@ -118,9 +118,7 @@
   # General optimization flags:
   #

-  IF(CMAKE_CXX_COMPILER_VERSION VERSION_LESS "13.0" )
-    ADD_FLAGS(DEAL_II_CXX_FLAGS_RELEASE "-O2")
-  ELSE()
+  IF(CMAKE_CXX_COMPILER_VERSION MATCHES "^13\\.")
     #
     # Disable aggressive optimization for intel-13* compilers, until we
     # resolve a lot of funny miscompilations...
@@ -128,13 +126,16 @@
     # - Maier, 2013
     #
     ADD_FLAGS(DEAL_II_CXX_FLAGS_RELEASE "-O1")
+  ELSE()
+    ADD_FLAGS(DEAL_II_CXX_FLAGS_RELEASE "-O2")
   ENDIF()
+
+  # equivalent to -fno-strict-aliasing:
+  ENABLE_IF_SUPPORTED(DEAL_II_CXX_FLAGS_RELEASE "-no-ansi-alias")

   ENABLE_IF_SUPPORTED(DEAL_II_CXX_FLAGS_RELEASE "-ip")

   ENABLE_IF_SUPPORTED(DEAL_II_CXX_FLAGS_RELEASE "-funroll-loops")
-  # equivalent to -fno-strict-aliasing:
-  ENABLE_IF_SUPPORTED(DEAL_II_CXX_FLAGS_RELEASE "-no-ansi-alias")
 ENDIF()


Fix virtual folder for other platforms

Fix virtual folder for other platforms

--- CMake/Tools.cmake
+++ CMake/Tools.cmake
@@ -1,6 +1,8 @@
 include(${CMAKE_CURRENT_LIST_DIR}/Config.cmake)

 macro(OE_add_resources folder target)
+	set(virtual_folder "")
+
 	if(EMSCRIPTEN)
 		set(virtual_folder /vfs)
 	elseif(ANDROID)


build rpm

build rpm

--- CPackConfig.cmake
+++ CPackConfig.cmake
@@ -1,4 +1,4 @@
-SET(CPACK_GENERATOR "DEB")
+SET(CPACK_GENERATOR "DEB" "RPM")
 SET(CPACK_INSTALLED_DIRECTORIES "${CMAKE_CURRENT_LIST_DIR}/lib" "/usr/lib" "${CMAKE_CURRENT_LIST_DIR}/include" "/usr/include" "${CMAKE_CURRENT_LIST_DIR}/bin" "/usr/bin" "${CMAKE_CURRENT_LIST_DIR}/etc" "/etc")
 SET(CPACK_PACKAGE_DESCRIPTION_FILE "LICENSE.txt")
 SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY "QueryArrow is a semantically unified SQL and NoSQL query system")


Fix typo and tidy up tab usage

Fix typo and tidy up tab usage

--- CMakeUnit.cmake
+++ CMakeUnit.cmake
@@ -339,6 +339,7 @@
                   PROPERTY INTERFACE_LINK_LIBRARIES)

     set (${RESULT_VARIABLE} FALSE PARENT_SCOPE)
+    set (${LIBRARIES_VARIABLE} ${TARGET_LIBS})

     foreach (_lib ${TARGET_LIBS})

@@ -354,11 +355,11 @@

 function (_print_all_libraries_in_list LIBRARIES_VARIABLE)

-	foreach (_lib ${${LIBRARIES_VARIABLE}})
-
-		message (STATUS "Found library: " ${_lib})
-
-	endforeach (${_lib})
+    foreach (_lib ${${LIBRARIES_VARIABLE}})
+
+        message (STATUS "Found library: " ${_lib})
+
+    endforeach (${_lib})

 endfunction (_print_all_libraries_in_list)

@@ -488,4 +489,4 @@

     endif (RESULT)

-endfunction (assert_does_not_have_property_with_value)+endfunction (assert_does_not_have_property_with_value)


FindGMOCK: Don't cache variables like GMOCK_FOUND

That will just cause the configure script to return early the next
time it is run without actually setting the library names for
GMock. The correct solution is to set these variables as global
properties that can be checked later.

--- FindGMOCK.cmake
+++ FindGMOCK.cmake
@@ -3,7 +3,7 @@
 # This CMake script will search for or add an external project target
 # for both Google Test and Google Mock. It sets the following variables:
 #
-# GOOGLE_MOCK_FOUND: Whether Google Test and Mock were found
+# GMOCK_FOUND: Whether Google Test and Mock were found
 # GTEST_INCLUDE_DIR : Include directory containing gtest/gtest.h
 # GMOCK_INCLUDE_DIR : Include directory containing gmock/gmock.h
 # GTEST_LIBRARY : Linker line for the Google Test library
@@ -98,12 +98,10 @@
     set (GTEST_PREFER_SOURCE_BUILD ON CACHE BOOL "" FORCE)
     set (GMOCK_PREFER_SOURCE_BUILD ON CACHE BOOL "" FORCE)

-endif ()
-
-# Already found, return
-if (GOOGLE_MOCK_FOUND)
-
-    return ()
+else ()
+
+    set (GTEST_PREFER_SOURCE_BUILD OFF CACHE BOOL "" FORCE)
+    set (GMOCK_PREFER_SOURCE_BUILD OFF CACHE BOOL "" FORCE)

 endif ()

@@ -335,13 +333,12 @@

     if (NOT GMOCK_SET_FOUND_EXTERNALLY_OVERRIDDEN)

-        set (_GMOCK_AND_GTEST_INSIDE_FINDING_PROJECT
-             ON CACHE BOOL "" FORCE)
-        mark_as_advanced (_GMOCK_AND_GTEST_INSIDE_FINDING_PROJECT)
+        set_property (GLOBAL PROPERTY _GMOCK_AND_GTEST_INSIDE_FINDING_PROJECT
+                      ON)

     endif ()

-    set (GMOCK_FOUND ON CACHE BOOL "Whether Google Mock was found" FORCE)
+    set (GMOCK_FOUND ON PARENT_SCOPE)
     set (GMOCK_FOUND_WHERE "${FOUND_WHERE}" PARENT_SCOPE)

 endfunction ()
@@ -349,6 +346,9 @@
 # Situation 0. Google Test and Google Mock were provided by the user. Ignore
 # any cache versions of these if we're actually just inside the same project
 # (and reconfiguring it as such)
+get_property (_GMOCK_AND_GTEST_INSIDE_FINDING_PROJECT
+              GLOBAL PROPERTY _GMOCK_AND_GTEST_INSIDE_FINDING_PROJECT)
+
 if (NOT _GMOCK_AND_GTEST_INSIDE_FINDING_PROJECT)

     if (GTEST_INCLUDE_DIR AND


Updated bootloader to release 0.0.19

Updated bootloader to release 0.0.19

--- cmake/Depthai/DepthaiBootloaderConfig.cmake
+++ cmake/Depthai/DepthaiBootloaderConfig.cmake
@@ -1,7 +1,7 @@
 # Maturity level "snapshot" / "release"
-# set(DEPTHAI_BOOTLOADER_MATURITY "release")
-set(DEPTHAI_BOOTLOADER_MATURITY "snapshot")
+set(DEPTHAI_BOOTLOADER_MATURITY "release")
+# set(DEPTHAI_BOOTLOADER_MATURITY "snapshot")

 # "version if applicable"
-# set(DEPTHAI_BOOTLOADER_VERSION "0.0.17")
-set(DEPTHAI_BOOTLOADER_VERSION "0.0.19+4af3b8fe5c0dc6f9a31dedac17affe2e490f81a0")
+set(DEPTHAI_BOOTLOADER_VERSION "0.0.19")
+# set(DEPTHAI_BOOTLOADER_VERSION "0.0.19+4af3b8fe5c0dc6f9a31dedac17affe2e490f81a0")


Update FW with stereo fixes for instance number; RGB depth alignment

--- 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 "1c3271f30b6bf60cc9f2000ebf2948e5fc0cf416")
+set(DEPTHAI_DEVICE_SIDE_COMMIT "3632be26e225b8078b2ce91f02910e32f478f7a2")

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


px4fmu-v2 stop building unused drivers and examples

--- cmake/configs/nuttx_px4fmu-v2_default.cmake
+++ cmake/configs/nuttx_px4fmu-v2_default.cmake
@@ -41,7 +41,7 @@
 	modules/sensors
 	#drivers/mkblctrl
 	drivers/px4flow
-	drivers/oreoled
+	#drivers/oreoled
 	drivers/gimbal
 	drivers/pwm_input
 	drivers/camera_trigger
@@ -138,7 +138,7 @@
 	#
 	# Rover apps
 	#
-	examples/rover_steering_control
+	#examples/rover_steering_control

 	#
 	# Demo apps
@@ -146,7 +146,7 @@
 	#examples/math_demo
 	# Tutorial code from
 	# https://px4.io/dev/px4_simple_app
-	examples/px4_simple_app
+	#examples/px4_simple_app

 	# Tutorial code from
 	# https://px4.io/dev/daemon


Fix to force builtin jpeg and png libraries for libafterimage when not found.

--- cmake/modules/SearchInstalledSoftware.cmake
+++ cmake/modules/SearchInstalledSoftware.cmake
@@ -324,9 +324,13 @@
     message(STATUS "Building AfterImage library included in ROOT itself")
     if(JPEG_FOUND)
       set(_jpeginclude --with-jpeg-includes=${JPEG_INCLUDE_DIR})
+    else()
+      set(_jpeginclude --with-builtin-jpeg)
     endif()
     if(PNG_FOUND)
       set(_pnginclude  --with-png-includes=${PNG_PNG_INCLUDE_DIR})
+    else()
+       set(_pnginclude  --with-builtin-png)
     endif()
     if(TIFF_FOUND)
       set(_tiffinclude --with-tiff-includes=${TIFF_INCLUDE_DIR})


Only use utf8 characters in comments

Only use utf8 characters in comments

--- cmake/modules/VisionarayHandleOptions.cmake
+++ cmake/modules/VisionarayHandleOptions.cmake
@@ -35,7 +35,7 @@
     if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
         if(CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 6.0)
             # Disable warnings like:
-            # warning: ignoring attributes on template argument ‘__m128i
+            # warning: ignoring attributes on template argument __m128i
             add_definitions(-Wno-ignored-attributes)
         endif()
     endif()


Reenable TBB_DO_ASSERT=1 when configuring tbb

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

--- deal.II/cmake/configure/configure_1_threads.cmake
+++ deal.II/cmake/configure/configure_1_threads.cmake
@@ -156,7 +156,8 @@

   IF(CMAKE_BUILD_TYPE MATCHES "Debug")
     IF(TBB_WITH_DEBUG_LIB)
-      LIST(APPEND DEAL_II_DEFINITIONS_DEBUG "TBB_USE_DEBUG")
+      LIST(APPEND DEAL_II_DEFINITIONS_DEBUG "TBB_USE_DEBUG" "TBB_DO_ASSERT=1")
+      LIST(APPEND DEAL_II_USER_DEFINITIONS_DEBUG "TBB_USE_DEBUG" "TBB_DO_ASSERT=1")
     ENDIF()
   ENDIF()

@@ -191,7 +192,8 @@
   # Add some definitions to use the header files in debug mode:
   #
   IF (CMAKE_BUILD_TYPE MATCHES "Debug")
-    LIST(APPEND DEAL_II_DEFINITIONS_DEBUG "TBB_USE_DEBUG")
+    LIST(APPEND DEAL_II_DEFINITIONS_DEBUG "TBB_USE_DEBUG" "TBB_DO_ASSERT=1")
+    LIST(APPEND DEAL_II_USER_DEFINITIONS_DEBUG "TBB_USE_DEBUG" "TBB_DO_ASSERT=1")
   ENDIF()

   #


GC HAVE_MMAP and HAVE_MMAP_FILE

GC HAVE_MMAP and HAVE_MMAP_FILE

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

--- include/llvm/Config/config.h.cmake
+++ include/llvm/Config/config.h.cmake
@@ -156,12 +156,6 @@

 /* Define to 1 if you have the `mktemp' function. */
 #cmakedefine HAVE_MKTEMP ${HAVE_MKTEMP}
-
-/* Define to 1 if you have a working `mmap' system call. */
-#undef HAVE_MMAP
-
-/* Define if mmap() can map files into memory */
-#undef HAVE_MMAP_FILE

 /* Define to 1 if you have the <ndir.h> header file, and it defines `DIR'. */
 #cmakedefine HAVE_NDIR_H ${HAVE_NDIR_H}


Implemented linux staging for DEV-41722 normalizing shared lib staging.

--- indra/cmake/Copy3rdPartyLibs.cmake
+++ indra/cmake/Copy3rdPartyLibs.cmake
@@ -184,18 +184,48 @@
         endif (EXISTS "${release_src_dir}/libllkdu.dylib")
     endif (NOT EXISTS ${internal_llkdu_path})
 elseif(LINUX)
+    # linux is weird, multiple side by side configurations aren't supported
+    # and we don't seem to have any debug shared libs built yet anyways...
+    set(SHARED_LIB_STAGING_DIR_DEBUG            "${SHARED_LIB_STAGING_DIR}")
+    set(SHARED_LIB_STAGING_DIR_RELWITHDEBINFO   "${SHARED_LIB_STAGING_DIR}")
+    set(SHARED_LIB_STAGING_DIR_RELEASE          "${SHARED_LIB_STAGING_DIR}")
+
     set(vivox_src_dir "${CMAKE_SOURCE_DIR}/newview/vivox-runtime/i686-linux")
     set(vivox_files
-       )
-    # *TODO - update this to use LIBS_PREBUILT_DIR and LL_ARCH_DIR variables
-    # or ARCH_PREBUILT_DIRS
-    set(debug_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-linux/lib/debug")
+        libalut.so
+        libopenal.so.1
+        libortp.so
+        libvivoxsdk.so
+        SLVoice
+       )
+    # *TODO - update this to use LIBS_PREBUILT_DIR and LL_ARCH_DIR variables
+    # or ARCH_PREBUILT_DIRS
+    set(debug_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-linux/lib_debug")
     set(debug_files
        )
     # *TODO - update this to use LIBS_PREBUILT_DIR and LL_ARCH_DIR variables
     # or ARCH_PREBUILT_DIRS
-    set(release_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-linux/lib/release")
+    set(release_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-linux/lib_release_client")
+    # *FIX - figure out what to do with duplicate libalut.so here -brad
     set(release_files
+        libapr-1.so
+        libaprutil-1.so
+        libatk-1.0.so
+        libcrypto.so
+        libexpat.so
+        libgmock_main.so
+        libgmock.so
+        libgmodule-2.0.so
+        libgobject-2.0.so
+        libgtest_main.so
+        libgtest.so
+        libopenal.so
+        libopenjpeg.so
+        libssl.so
+        libstacktrace.so
+        libtcmalloc.so
+        libuuid.so
+        libz.so
        )

     if (FMOD_SDK_DIR)


Removed some remaining traces of Tetgen.

--- geometry/component_definitions.cmake
+++ geometry/component_definitions.cmake
@@ -100,7 +100,6 @@
         add_library(${${COMPONENT}_DYNAMIC_LIB} SHARED ${${COMPONENT}_SRCS})
         add_dependencies(${${COMPONENT}_DYNAMIC_LIB} ${FIBER_BUNDLES_IMPORT_LIBS})
         target_link_libraries(${${COMPONENT}_DYNAMIC_LIB} ${FIBER_BUNDLES_IMPORT_LIBS})
-        target_link_libraries(${${COMPONENT}_DYNAMIC_LIB} LINK_PRIVATE ${TETGEN_LIB})
         set_target_properties(${${COMPONENT}_DYNAMIC_LIB} PROPERTIES FOLDER "Library Targets")
         # Override cmake's placing of "${${COMPONENT}_DYNAMIC_LIB}_EXPORTS into the preproc symbol table.
         set_target_properties(${${COMPONENT}_DYNAMIC_LIB} PROPERTIES DEFINE_SYMBOL "SHEAF_DLL_EXPORTS")
@@ -131,9 +130,8 @@
         add_dependencies(${PROJECT_NAME}-static-lib ${${COMPONENT}_STATIC_LIBS})

         target_link_libraries(${${COMPONENT}_SHARED_LIB} ${FIBER_BUNDLES_SHARED_LIBS})
-        target_link_libraries(${${COMPONENT}_SHARED_LIB} LINK_PRIVATE -Wl,-Bstatic ${TETGEN_LIB} -Wl,-Bdynamic)
         target_link_libraries(${${COMPONENT}_STATIC_LIB} ${FIBER_BUNDLES_STATIC_LIBS})
-        target_link_libraries(${${COMPONENT}_STATIC_LIB} LINK_PRIVATE ${TETGEN_LIB})
+
     endif()

 endfunction(add_library_targets)


Testsuite: Bugfix: Do not forget to export SOURCE_DIR for tests

--- cmake/macros/macro_deal_ii_add_test.cmake
+++ cmake/macros/macro_deal_ii_add_test.cmake
@@ -181,12 +181,16 @@
           ${_test_name}.cc
           ${CMAKE_CURRENT_BINARY_DIR}/${_target}/interrupt_guard.cc
           )
+
         DEAL_II_SETUP_TARGET(${_target} ${_build})
         TARGET_LINK_LIBRARIES(${_target}
           ${TEST_LIBRARIES} ${TEST_LIBRARIES_${_build}}
           )

-        SET_TARGET_PROPERTIES(${_target} PROPERTIES
+        SET_PROPERTY(TARGET ${_target} APPEND PROPERTY
+          COMPILE_DEFINITIONS SOURCE_DIR="${CMAKE_CURRENT_SOURCE_DIR}"
+          )
+        SET_PROPERTY(TARGET ${_target} PROPERTY
           RUNTIME_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/${_target}"
           )


KAA-1183 ESP8266 toolchain style fix

KAA-1183 ESP8266 toolchain style fix

--- client/client-multi/client-c/toolchains/esp8266.cmake
+++ client/client-multi/client-c/toolchains/esp8266.cmake
@@ -22,20 +22,20 @@

 set(XTENSA_GCC_COMPILER "xtensa-lx106-elf-gcc${CMAKE_EXECUTABLE_SUFFIX}")

-if (NOT DEFINED ESP8266_TOOLCHAIN_PATH)
-  # Check if GCC is reachable.
-  find_path(ESP8266_TOOLCHAIN_PATH bin/${XTENSA_GCC_COMPILER})
+if(NOT DEFINED ESP8266_TOOLCHAIN_PATH)
+    # Check if GCC is reachable.
+    find_path(ESP8266_TOOLCHAIN_PATH bin/${XTENSA_GCC_COMPILER})

-  if (NOT ESP8266_TOOLCHAIN_PATH)
-    # Set default path.
-    set(ESP8266_TOOLCHAIN_PATH /opt/Espressif/crosstool-NG/builds/xtensa-lx106-elf)
-    message(STATUS "GCC not found, default path will be used: ${ESP8266_TOOLCHAIN_PATH}")
-  endif ()
-else ()
-  message(STATUS "Toolchain path: ${ESP8266_TOOLCHAIN_PATH}")
-endif ()
+    if(NOT ESP8266_TOOLCHAIN_PATH)
+        # Set default path.
+        set(ESP8266_TOOLCHAIN_PATH /opt/Espressif/crosstool-NG/builds/xtensa-lx106-elf)
+        message(STATUS "GCC not found, default path will be used: ${ESP8266_TOOLCHAIN_PATH}")
+    endif()
+else()
+    message(STATUS "Toolchain path: ${ESP8266_TOOLCHAIN_PATH}")
+endif()

-CMAKE_FORCE_C_COMPILER(${ESP8266_TOOLCHAIN_PATH}/bin/${XTENSA_GCC_COMPILER} GNU)
+cmake_force_c_compiler(${ESP8266_TOOLCHAIN_PATH}/bin/${XTENSA_GCC_COMPILER} GNU)

 set(CMAKE_OBJCOPY ${ESP8266_TOOLCHAIN_PATH}/bin/xtensa-lx106-elf-objcopy CACHE PATH "")

@@ -43,24 +43,24 @@
 ### ESP8266 SDK setup ###
 #########################

-if (NOT DEFINED ESP8266_SDK_PATH)
+if(NOT DEFINED ESP8266_SDK_PATH)
     set(ESP8266_SDK_PATH /opt/Espressif/esp-rtos-sdk)
     message(STATUS "Default SDK location will be used: ${ESP8266_SDK_PATH}")
-else ()
-  message(STATUS "ESP8266 SDK path: ${ESP8266_SDK_PATH}")
-endif ()
+else()
+    message(STATUS "ESP8266 SDK path: ${ESP8266_SDK_PATH}")
+endif()

 set(CMAKE_LIBRARY_PATH ${ESP8266_SDK_PATH}/lib/)

 set(ESP8266_INCDIRS
-    ${ESP8266_SDK_PATH}/extra_include
-    ${ESP8266_SDK_PATH}/include
-    ${ESP8266_SDK_PATH}/include/lwip
-    ${ESP8266_SDK_PATH}/include/lwip/ipv4
-    ${ESP8266_SDK_PATH}/include/lwip/ipv6
-    ${ESP8266_SDK_PATH}/include/espressif/
-    ${ESP8266_TOOLCHAIN_PATH}/lib/gcc/xtensa-lx106-elf/4.8.2/include/
-    )
+        ${ESP8266_SDK_PATH}/extra_include
+        ${ESP8266_SDK_PATH}/include
+        ${ESP8266_SDK_PATH}/include/lwip
+        ${ESP8266_SDK_PATH}/include/lwip/ipv4
+        ${ESP8266_SDK_PATH}/include/lwip/ipv6
+        ${ESP8266_SDK_PATH}/include/espressif/
+        ${ESP8266_TOOLCHAIN_PATH}/lib/gcc/xtensa-lx106-elf/4.8.2/include/
+        )

 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-comment -fno-builtin -Wno-implicit-function-declaration -Os -Wpointer-arith -Wl,-EL,--gc-sections -fno-inline-functions -nostdlib -mlongcalls -mtext-section-literals -ffunction-sections" CACHE FORCE "")
 set(CMAKE_C_LINK_EXECUTABLE "<CMAKE_C_COMPILER> <FLAGS> <CMAKE_C_LINK_FLAGS> <LINK_FLAGS> -o <TARGET> -Wl,--start-group <OBJECTS> <LINK_LIBRARIES> -Wl,--end-group" CACHE FORCE "")


Qt: Remove debug messages

Qt: Remove debug messages

--- src/platform/qt/ts.cmake
+++ src/platform/qt/ts.cmake
@@ -1,8 +1,6 @@
 file(GLOB TRANSLATION_FILES "${QM_BASE}/*.qm")
 file(WRITE ${TRANSLATION_QRC} "<RCC>\n\t<qresource prefix=\"/translations/\">\n")
-message(STATUS ${TRANSLATION_FILES})
 foreach(TS ${TRANSLATION_FILES})
-	message(STATUS ${TS})
 	get_filename_component(TS_BASE "${TS}" NAME)
 	file(APPEND ${TRANSLATION_QRC} "\t\t<file>${TS_BASE}</file>\n")
 endforeach()


cleanup

cleanup

--- mod/FindMKL.cmake
+++ mod/FindMKL.cmake
@@ -1,114 +0,0 @@
-# - Find Intel MKL
-# Find the MKL libraries
-#
-# Options:
-#
-#   MKL_STATAIC       :   use static linking
-#   MKL_MULTI_THREADED:   use multi-threading
-#   MKL_SDL           :   Single Dynamic Library interface
-#
-# This module defines the following variables:
-#
-#   MKL_FOUND            : True if MKL_INCLUDE_DIR are found
-#   MKL_INCLUDE_DIR      : where to find mkl.h, etc.
-#   MKL_INCLUDE_DIRS     : set when MKL_INCLUDE_DIR found
-#   MKL_LIBRARIES        : the library to link against.
-
-
-include(FindPackageHandleStandardArgs)
-
-set(INTEL_ROOT "/opt/intel" CACHE PATH "Folder contains intel libs")
-set(MKL_ROOT $ENV{MKLROOT} CACHE PATH "Folder contains MKL")
-
-# Find include dir
-find_path(MKL_INCLUDE_DIR mkl.h
-    PATHS ${MKL_ROOT}/include)
-
-# Find include directory
-#  There is no include folder under linux
-if(WIN32)
-    find_path(INTEL_INCLUDE_DIR omp.h
-        PATHS ${INTEL_ROOT}/include)
-    set(MKL_INCLUDE_DIR ${MKL_INCLUDE_DIR} ${INTEL_INCLUDE_DIR})
-endif()
-
-# Find libraries
-
-# Handle suffix
-set(_MKL_ORIG_CMAKE_FIND_LIBRARY_SUFFIXES ${CMAKE_FIND_LIBRARY_SUFFIXES})
-
-if(WIN32)
-    if(MKL_STATAIC)
-        set(CMAKE_FIND_LIBRARY_SUFFIXES .lib)
-    else()
-        set(CMAKE_FIND_LIBRARY_SUFFIXES _dll.lib)
-    endif()
-else()
-    if(MKL_STATAIC)
-        set(CMAKE_FIND_LIBRARY_SUFFIXES .a)
-    else()
-        set(CMAKE_FIND_LIBRARY_SUFFIXES .so)
-    endif()
-endif()
-
-
-# MKL is composed by four layers: Interface, Threading, Computational and RTL
-
-if(MKL_SDL)
-    find_library(MKL_LIBRARY mkl_rt
-        PATHS ${MKL_ROOT}/lib/ia32/)
-
-    set(MKL_MINIMAL_LIBRARY ${MKL_LIBRARY})
-else()
-    ######################### Interface layer #######################
-    if(WIN32)
-        set(MKL_INTERFACE_LIBNAME mkl_intel_c)
-    else()
-        set(MKL_INTERFACE_LIBNAME mkl_intel)
-    endif()
-
-    find_library(MKL_INTERFACE_LIBRARY ${MKL_INTERFACE_LIBNAME}
-        PATHS ${MKL_ROOT}/lib/ia32/)
-
-    ######################## Threading layer ########################
-    if(MKL_MULTI_THREADED)
-        set(MKL_THREADING_LIBNAME mkl_intel_thread)
-    else()
-        set(MKL_THREADING_LIBNAME mkl_sequential)
-    endif()
-
-    find_library(MKL_THREADING_LIBRARY ${MKL_THREADING_LIBNAME}
-        PATHS ${MKL_ROOT}/lib/ia32/)
-
-    ####################### Computational layer #####################
-    find_library(MKL_CORE_LIBRARY mkl_core
-        PATHS ${MKL_ROOT}/lib/ia32/)
-    find_library(MKL_FFT_LIBRARY mkl_cdft_core
-        PATHS ${MKL_ROOT}/lib/ia32/)
-    find_library(MKL_SCALAPACK_LIBRARY mkl_scalapack_core
-        PATHS ${MKL_ROOT}/lib/ia32/)
-
-    ############################ RTL layer ##########################
-    if(WIN32)
-        set(MKL_RTL_LIBNAME libiomp5md)
-    else()
-        set(MKL_RTL_LIBNAME libiomp5)
-    endif()
-    find_library(MKL_RTL_LIBRARY ${MKL_RTL_LIBNAME}
-        PATHS ${INTEL_RTL_ROOT}/lib)
-
-    set(MKL_LIBRARY ${MKL_INTERFACE_LIBRARY} ${MKL_THREADING_LIBRARY} ${MKL_CORE_LIBRARY} ${MKL_FFT_LIBRARY} ${MKL_SCALAPACK_LIBRARY} ${MKL_RTL_LIBRARY})
-    set(MKL_MINIMAL_LIBRARY ${MKL_INTERFACE_LIBRARY} ${MKL_THREADING_LIBRARY} ${MKL_CORE_LIBRARY} ${MKL_RTL_LIBRARY})
-endif()
-
-set(CMAKE_FIND_LIBRARY_SUFFIXES ${_MKL_ORIG_CMAKE_FIND_LIBRARY_SUFFIXES})
-
-find_package_handle_standard_args(MKL DEFAULT_MSG
-    MKL_INCLUDE_DIR MKL_LIBRARY MKL_MINIMAL_LIBRARY)
-
-if(MKL_FOUND)
-    set(MKL_INCLUDE_DIRS ${MKL_INCLUDE_DIR})
-    set(MKL_LIBRARIES ${MKL_LIBRARY})
-    set(MKL_MINIMAL_LIBRARIES ${MKL_LIBRARY})
-endif()
-


Fix warnings

Fix warnings

--- modules/fmt.cmake
+++ modules/fmt.cmake
@@ -6,8 +6,9 @@
     set_source_files_properties(${SOURCE_FILES} PROPERTIES COMPILE_FLAGS "${PEDANTIC_COMPILE_FLAGS}")
   else()
     # C4127: conditional expression is constant
+    # C4244: 'conversion' conversion from 'type1' to 'type2', possible loss of data
     # C4702: unreachable code
-    set_source_files_properties(${SOURCE_FILES} PROPERTIES COMPILE_FLAGS "${PEDANTIC_COMPILE_FLAGS} /wd4127 /wd4702")
+    set_source_files_properties(${SOURCE_FILES} PROPERTIES COMPILE_FLAGS "${PEDANTIC_COMPILE_FLAGS} /wd4127 /wd4244 /wd4702")
   endif()
   add_library(fmt ${SOURCE_FILES} ${ASSEMBLER_FILES})
   target_include_directories(fmt PRIVATE "fmt")


SK:

SK:

-BUG: typo

--- src/Testing/Dashboard/elxDashboard_BIGR_winXP32_VS2008.cmake
+++ src/Testing/Dashboard/elxDashboard_BIGR_winXP32_VS2008.cmake
@@ -24,7 +24,7 @@

 # default: automatically determined
 #set(CTEST_UPDATE_COMMAND /path/to/svn)
-set(CTEST_UPDATE_COMMAND "C:/Program Files/Subversion/bin")
+set(CTEST_UPDATE_COMMAND "C:/Program Files/Subversion/bin/svn.exe")

 # Specify the kind of dashboard to submit
 # default: Nightly


Split a comment into generic description and note about the specific
cmake use.

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

--- include/llvm/Config/config.h.cmake
+++ include/llvm/Config/config.h.cmake
@@ -329,9 +329,8 @@
 /* Define if we link Polly to the tools */
 #cmakedefine LINK_POLLY_INTO_TOOLS

-/* Target triple LLVM will generate code for by default
- * Doesn't use `cmakedefine` because it is allowed to be empty.
- */
+/* Target triple LLVM will generate code for by default */
+/* Doesn't use `cmakedefine` because it is allowed to be empty. */
 #define LLVM_DEFAULT_TARGET_TRIPLE "${LLVM_DEFAULT_TARGET_TRIPLE}"

 /* Define to enable checks that alter the LLVM C++ ABI */


Added copy of libfmodex .so for linux

Added copy of libfmodex .so for linux

--- indra/cmake/Copy3rdPartyLibs.cmake
+++ indra/cmake/Copy3rdPartyLibs.cmake
@@ -1,373 +1,377 @@
-# -*- cmake -*-
-
-# The copy_win_libs folder contains file lists and a script used to
-# copy dlls, exes and such needed to run the SecondLife from within
-# VisualStudio.
-
-include(CMakeCopyIfDifferent)
-include(Linking)
-
-###################################################################
-# set up platform specific lists of files that need to be copied
-###################################################################
-if(WINDOWS)
-    set(SHARED_LIB_STAGING_DIR_DEBUG            "${SHARED_LIB_STAGING_DIR}/Debug")
-    set(SHARED_LIB_STAGING_DIR_RELWITHDEBINFO   "${SHARED_LIB_STAGING_DIR}/RelWithDebInfo")
-    set(SHARED_LIB_STAGING_DIR_RELEASE          "${SHARED_LIB_STAGING_DIR}/Release")
-
-    #*******************************
-    # VIVOX - *NOTE: no debug version
-    set(vivox_src_dir "${ARCH_PREBUILT_DIRS_RELEASE}")
-    set(vivox_files
-        SLVoice.exe
-        libsndfile-1.dll
-        vivoxplatform.dll
-        vivoxsdk.dll
-        ortp.dll
-        zlib1.dll
-        vivoxoal.dll
-        )
-
-    #*******************************
-    # Misc shared libs
-
-    set(debug_src_dir "${ARCH_PREBUILT_DIRS_DEBUG}")
-    set(debug_files
-        openjpegd.dll
-        libapr-1.dll
-        libaprutil-1.dll
-        libapriconv-1.dll
-        ssleay32.dll
-        libeay32.dll
-        libcollada14dom22-d.dll
-        glod.dll
-        libhunspell.dll
-        )
-
-    set(release_src_dir "${ARCH_PREBUILT_DIRS_RELEASE}")
-    set(release_files
-        openjpeg.dll
-        libapr-1.dll
-        libaprutil-1.dll
-        libapriconv-1.dll
-        ssleay32.dll
-        libeay32.dll
-        libcollada14dom22.dll
-        glod.dll
-        libhunspell.dll
-        )
-
-    if(USE_TCMALLOC)
-      set(debug_files ${debug_files} libtcmalloc_minimal-debug.dll)
-      set(release_files ${release_files} libtcmalloc_minimal.dll)
-    endif(USE_TCMALLOC)
-
-    if (FMODEX)
-      set(debug_files ${debug_files} fmodexL.dll)
-      set(release_files ${release_files} fmodex.dll)
-    endif (FMODEX)
-
-#*******************************
-# Copy MS C runtime dlls, required for packaging.
-# *TODO - Adapt this to support VC9
-if (MSVC80)
-    FIND_PATH(debug_msvc8_redist_path msvcr80d.dll
-        PATHS
-        ${MSVC_DEBUG_REDIST_PATH}
-         [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\8.0\\Setup\\VC;ProductDir]/redist/Debug_NonRedist/x86/Microsoft.VC80.DebugCRT
-        NO_DEFAULT_PATH
-        NO_DEFAULT_PATH
-        )
-
-    if(EXISTS ${debug_msvc8_redist_path})
-        set(debug_msvc8_files
-            msvcr80d.dll
-            msvcp80d.dll
-            Microsoft.VC80.DebugCRT.manifest
-            )
-
-        copy_if_different(
-            ${debug_msvc8_redist_path}
-            "${SHARED_LIB_STAGING_DIR_DEBUG}"
-            out_targets
-            ${debug_msvc8_files}
-            )
-        set(third_party_targets ${third_party_targets} ${out_targets})
-
-    endif (EXISTS ${debug_msvc8_redist_path})
-
-    FIND_PATH(release_msvc8_redist_path msvcr80.dll
-        PATHS
-        ${MSVC_REDIST_PATH}
-         [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\8.0\\Setup\\VC;ProductDir]/redist/x86/Microsoft.VC80.CRT
-        NO_DEFAULT_PATH
-        NO_DEFAULT_PATH
-        )
-
-    if(EXISTS ${release_msvc8_redist_path})
-        set(release_msvc8_files
-            msvcr80.dll
-            msvcp80.dll
-            Microsoft.VC80.CRT.manifest
-            )
-
-        copy_if_different(
-            ${release_msvc8_redist_path}
-            "${SHARED_LIB_STAGING_DIR_RELEASE}"
-            out_targets
-            ${release_msvc8_files}
-            )
-        set(third_party_targets ${third_party_targets} ${out_targets})
-
-        copy_if_different(
-            ${release_msvc8_redist_path}
-            "${SHARED_LIB_STAGING_DIR_RELWITHDEBINFO}"
-            out_targets
-            ${release_msvc8_files}
-            )
-        set(third_party_targets ${third_party_targets} ${out_targets})
-
-    endif (EXISTS ${release_msvc8_redist_path})
-elseif (MSVC_VERSION EQUAL 1600) # VisualStudio 2010
-    FIND_PATH(debug_msvc10_redist_path msvcr100d.dll
-        PATHS
-        ${MSVC_DEBUG_REDIST_PATH}
-         [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\10.0\\Setup\\VC;ProductDir]/redist/Debug_NonRedist/x86/Microsoft.VC100.DebugCRT
-        [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Windows;Directory]/SysWOW64
-        [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Windows;Directory]/System32
-        NO_DEFAULT_PATH
-        )
-
-    if(EXISTS ${debug_msvc10_redist_path})
-        set(debug_msvc10_files
-            msvcr100d.dll
-            msvcp100d.dll
-            )
-
-        copy_if_different(
-            ${debug_msvc10_redist_path}
-            "${SHARED_LIB_STAGING_DIR_DEBUG}"
-            out_targets
-            ${debug_msvc10_files}
-            )
-        set(third_party_targets ${third_party_targets} ${out_targets})
-
-    endif ()
-
-    FIND_PATH(release_msvc10_redist_path msvcr100.dll
-        PATHS
-        ${MSVC_REDIST_PATH}
-         [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\10.0\\Setup\\VC;ProductDir]/redist/x86/Microsoft.VC100.CRT
-        [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Windows;Directory]/SysWOW64
-        [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Windows;Directory]/System32
-        NO_DEFAULT_PATH
-        )
-
-    if(EXISTS ${release_msvc10_redist_path})
-        set(release_msvc10_files
-            msvcr100.dll
-            msvcp100.dll
-            )
-
-        copy_if_different(
-            ${release_msvc10_redist_path}
-            "${SHARED_LIB_STAGING_DIR_RELEASE}"
-            out_targets
-            ${release_msvc10_files}
-            )
-        set(third_party_targets ${third_party_targets} ${out_targets})
-
-        copy_if_different(
-            ${release_msvc10_redist_path}
-            "${SHARED_LIB_STAGING_DIR_RELWITHDEBINFO}"
-            out_targets
-            ${release_msvc10_files}
-            )
-        set(third_party_targets ${third_party_targets} ${out_targets})
-
-    endif ()
-endif (MSVC80)
-
-elseif(DARWIN)
-    set(SHARED_LIB_STAGING_DIR_DEBUG            "${SHARED_LIB_STAGING_DIR}/Debug/Resources")
-    set(SHARED_LIB_STAGING_DIR_RELWITHDEBINFO   "${SHARED_LIB_STAGING_DIR}/RelWithDebInfo/Resources")
-    set(SHARED_LIB_STAGING_DIR_RELEASE          "${SHARED_LIB_STAGING_DIR}/Release/Resources")
-
-    set(vivox_src_dir "${ARCH_PREBUILT_DIRS_RELEASE}")
-    set(vivox_files
-        SLVoice
-        libsndfile.dylib
-        libvivoxoal.dylib
-        libortp.dylib
-        libvivoxplatform.dylib
-        libvivoxsdk.dylib
-       )
-    set(debug_src_dir "${ARCH_PREBUILT_DIRS_DEBUG}")
-    set(debug_files
-       )
-    set(release_src_dir "${ARCH_PREBUILT_DIRS_RELEASE}")
-    set(release_files
-        libapr-1.0.dylib
-        libapr-1.dylib
-        libaprutil-1.0.dylib
-        libaprutil-1.dylib
-        libexpat.1.5.2.dylib
-        libexpat.dylib
-        libGLOD.dylib
-        libllqtwebkit.dylib
-        libminizip.a
-        libndofdev.dylib
-        libhunspell-1.3.0.dylib
-        libexception_handler.dylib
-        libcollada14dom.dylib
-       )
-
-    if (FMODEX)
-      #set(debug_files ${debug_files} libfmodexL.dylib)
-      set(release_files ${release_files} libfmodex.dylib)
-    endif (FMODEX)
-
-elseif(LINUX)
-    # linux is weird, multiple side by side configurations aren't supported
-    # and we don't seem to have any debug shared libs built yet anyways...
-    set(SHARED_LIB_STAGING_DIR_DEBUG            "${SHARED_LIB_STAGING_DIR}")
-    set(SHARED_LIB_STAGING_DIR_RELWITHDEBINFO   "${SHARED_LIB_STAGING_DIR}")
-    set(SHARED_LIB_STAGING_DIR_RELEASE          "${SHARED_LIB_STAGING_DIR}")
-
-    set(vivox_src_dir "${ARCH_PREBUILT_DIRS_RELEASE}")
-    set(vivox_files
-        libsndfile.so.1
-        libortp.so
-        libvivoxoal.so.1
-        libvivoxplatform.so
-        libvivoxsdk.so
-        SLVoice
-       )
-    # *TODO - update this to use LIBS_PREBUILT_DIR and LL_ARCH_DIR variables
-    # or ARCH_PREBUILT_DIRS
-    set(debug_src_dir "${ARCH_PREBUILT_DIRS_DEBUG}")
-    set(debug_files
-       )
-    # *TODO - update this to use LIBS_PREBUILT_DIR and LL_ARCH_DIR variables
-    # or ARCH_PREBUILT_DIRS
-    set(release_src_dir "${ARCH_PREBUILT_DIRS_RELEASE}")
-    # *FIX - figure out what to do with duplicate libalut.so here -brad
-    set(release_files
-        libapr-1.so.0
-        libaprutil-1.so.0
-        libatk-1.0.so
-        libboost_program_options-mt.so.${BOOST_VERSION}.0
-        libboost_regex-mt.so.${BOOST_VERSION}.0
-        libboost_thread-mt.so.${BOOST_VERSION}.0
-        libboost_filesystem-mt.so.${BOOST_VERSION}.0
-        libboost_signals-mt.so.${BOOST_VERSION}.0
-        libboost_system-mt.so.${BOOST_VERSION}.0
-        libbreakpad_client.so.0
-        libcollada14dom.so
-        libcrypto.so.1.0.0
-        libdb-5.1.so
-        libexpat.so
-        libexpat.so.1
-        libglod.so
-        libgmock_main.so
-        libgmock.so.0
-        libgmodule-2.0.so
-        libgobject-2.0.so
-        libgtest_main.so
-        libgtest.so.0
-        libhunspell-1.3.so.0.0.0
-        libminizip.so
-        libopenal.so
-        libopenjpeg.so
-        libssl.so
-        libuuid.so.16
-        libuuid.so.16.0.22
-        libssl.so.1.0.0
-        libfontconfig.so.1.4.4
-       )
-
-    if (USE_TCMALLOC)
-      set(release_files ${release_files} "libtcmalloc_minimal.so")
-    endif (USE_TCMALLOC)
-
-else(WINDOWS)
-    message(STATUS "WARNING: unrecognized platform for staging 3rd party libs, skipping...")
-    set(vivox_src_dir "${CMAKE_SOURCE_DIR}/newview/vivox-runtime/i686-linux")
-    set(vivox_files "")
-    # *TODO - update this to use LIBS_PREBUILT_DIR and LL_ARCH_DIR variables
-    # or ARCH_PREBUILT_DIRS
-    set(debug_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-linux/lib/debug")
-    set(debug_files "")
-    # *TODO - update this to use LIBS_PREBUILT_DIR and LL_ARCH_DIR variables
-    # or ARCH_PREBUILT_DIRS
-    set(release_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-linux/lib/release")
-    set(release_files "")
-
-    set(debug_llkdu_src "")
-    set(debug_llkdu_dst "")
-    set(release_llkdu_src "")
-    set(release_llkdu_dst "")
-    set(relwithdebinfo_llkdu_dst "")
-endif(WINDOWS)
-
-
-################################################################
-# Done building the file lists, now set up the copy commands.
-################################################################
-
-copy_if_different(
-    ${vivox_src_dir}
-    "${SHARED_LIB_STAGING_DIR_DEBUG}"
-    out_targets
-    ${vivox_files}
-    )
-set(third_party_targets ${third_party_targets} ${out_targets})
-
-copy_if_different(
-    ${vivox_src_dir}
-    "${SHARED_LIB_STAGING_DIR_RELEASE}"
-    out_targets
-    ${vivox_files}
-    )
-set(third_party_targets ${third_party_targets} ${out_targets})
-
-copy_if_different(
-    ${vivox_src_dir}
-    "${SHARED_LIB_STAGING_DIR_RELWITHDEBINFO}"
-    out_targets
-    ${vivox_files}
-    )
-set(third_party_targets ${third_party_targets} ${out_targets})
-
-
-
-copy_if_different(
-    ${debug_src_dir}
-    "${SHARED_LIB_STAGING_DIR_DEBUG}"
-    out_targets
-    ${debug_files}
-    )
-set(third_party_targets ${third_party_targets} ${out_targets})
-
-copy_if_different(
-    ${release_src_dir}
-    "${SHARED_LIB_STAGING_DIR_RELEASE}"
-    out_targets
-    ${release_files}
-    )
-set(third_party_targets ${third_party_targets} ${out_targets})
-
-copy_if_different(
-    ${release_src_dir}
-    "${SHARED_LIB_STAGING_DIR_RELWITHDEBINFO}"
-    out_targets
-    ${release_files}
-    )
-set(third_party_targets ${third_party_targets} ${out_targets})
-
-if(NOT STANDALONE)
-  add_custom_target(
-      stage_third_party_libs ALL
-      DEPENDS ${third_party_targets}
-      )
-endif(NOT STANDALONE)
+# -*- cmake -*-
+
+# The copy_win_libs folder contains file lists and a script used to
+# copy dlls, exes and such needed to run the SecondLife from within
+# VisualStudio.
+
+include(CMakeCopyIfDifferent)
+include(Linking)
+
+###################################################################
+# set up platform specific lists of files that need to be copied
+###################################################################
+if(WINDOWS)
+    set(SHARED_LIB_STAGING_DIR_DEBUG            "${SHARED_LIB_STAGING_DIR}/Debug")
+    set(SHARED_LIB_STAGING_DIR_RELWITHDEBINFO   "${SHARED_LIB_STAGING_DIR}/RelWithDebInfo")
+    set(SHARED_LIB_STAGING_DIR_RELEASE          "${SHARED_LIB_STAGING_DIR}/Release")
+
+    #*******************************
+    # VIVOX - *NOTE: no debug version
+    set(vivox_src_dir "${ARCH_PREBUILT_DIRS_RELEASE}")
+    set(vivox_files
+        SLVoice.exe
+        libsndfile-1.dll
+        vivoxplatform.dll
+        vivoxsdk.dll
+        ortp.dll
+        zlib1.dll
+        vivoxoal.dll
+        )
+
+    #*******************************
+    # Misc shared libs
+
+    set(debug_src_dir "${ARCH_PREBUILT_DIRS_DEBUG}")
+    set(debug_files
+        openjpegd.dll
+        libapr-1.dll
+        libaprutil-1.dll
+        libapriconv-1.dll
+        ssleay32.dll
+        libeay32.dll
+        libcollada14dom22-d.dll
+        glod.dll
+        libhunspell.dll
+        )
+
+    set(release_src_dir "${ARCH_PREBUILT_DIRS_RELEASE}")
+    set(release_files
+        openjpeg.dll
+        libapr-1.dll
+        libaprutil-1.dll
+        libapriconv-1.dll
+        ssleay32.dll
+        libeay32.dll
+        libcollada14dom22.dll
+        glod.dll
+        libhunspell.dll
+        )
+
+    if(USE_TCMALLOC)
+      set(debug_files ${debug_files} libtcmalloc_minimal-debug.dll)
+      set(release_files ${release_files} libtcmalloc_minimal.dll)
+    endif(USE_TCMALLOC)
+
+    if (FMODEX)
+      set(debug_files ${debug_files} fmodexL.dll)
+      set(release_files ${release_files} fmodex.dll)
+    endif (FMODEX)
+
+#*******************************
+# Copy MS C runtime dlls, required for packaging.
+# *TODO - Adapt this to support VC9
+if (MSVC80)
+    FIND_PATH(debug_msvc8_redist_path msvcr80d.dll
+        PATHS
+        ${MSVC_DEBUG_REDIST_PATH}
+         [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\8.0\\Setup\\VC;ProductDir]/redist/Debug_NonRedist/x86/Microsoft.VC80.DebugCRT
+        NO_DEFAULT_PATH
+        NO_DEFAULT_PATH
+        )
+
+    if(EXISTS ${debug_msvc8_redist_path})
+        set(debug_msvc8_files
+            msvcr80d.dll
+            msvcp80d.dll
+            Microsoft.VC80.DebugCRT.manifest
+            )
+
+        copy_if_different(
+            ${debug_msvc8_redist_path}
+            "${SHARED_LIB_STAGING_DIR_DEBUG}"
+            out_targets
+            ${debug_msvc8_files}
+            )
+        set(third_party_targets ${third_party_targets} ${out_targets})
+
+    endif (EXISTS ${debug_msvc8_redist_path})
+
+    FIND_PATH(release_msvc8_redist_path msvcr80.dll
+        PATHS
+        ${MSVC_REDIST_PATH}
+         [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\8.0\\Setup\\VC;ProductDir]/redist/x86/Microsoft.VC80.CRT
+        NO_DEFAULT_PATH
+        NO_DEFAULT_PATH
+        )
+
+    if(EXISTS ${release_msvc8_redist_path})
+        set(release_msvc8_files
+            msvcr80.dll
+            msvcp80.dll
+            Microsoft.VC80.CRT.manifest
+            )
+
+        copy_if_different(
+            ${release_msvc8_redist_path}
+            "${SHARED_LIB_STAGING_DIR_RELEASE}"
+            out_targets
+            ${release_msvc8_files}
+            )
+        set(third_party_targets ${third_party_targets} ${out_targets})
+
+        copy_if_different(
+            ${release_msvc8_redist_path}
+            "${SHARED_LIB_STAGING_DIR_RELWITHDEBINFO}"
+            out_targets
+            ${release_msvc8_files}
+            )
+        set(third_party_targets ${third_party_targets} ${out_targets})
+
+    endif (EXISTS ${release_msvc8_redist_path})
+elseif (MSVC_VERSION EQUAL 1600) # VisualStudio 2010
+    FIND_PATH(debug_msvc10_redist_path msvcr100d.dll
+        PATHS
+        ${MSVC_DEBUG_REDIST_PATH}
+         [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\10.0\\Setup\\VC;ProductDir]/redist/Debug_NonRedist/x86/Microsoft.VC100.DebugCRT
+        [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Windows;Directory]/SysWOW64
+        [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Windows;Directory]/System32
+        NO_DEFAULT_PATH
+        )
+
+    if(EXISTS ${debug_msvc10_redist_path})
+        set(debug_msvc10_files
+            msvcr100d.dll
+            msvcp100d.dll
+            )
+
+        copy_if_different(
+            ${debug_msvc10_redist_path}
+            "${SHARED_LIB_STAGING_DIR_DEBUG}"
+            out_targets
+            ${debug_msvc10_files}
+            )
+        set(third_party_targets ${third_party_targets} ${out_targets})
+
+    endif ()
+
+    FIND_PATH(release_msvc10_redist_path msvcr100.dll
+        PATHS
+        ${MSVC_REDIST_PATH}
+         [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\10.0\\Setup\\VC;ProductDir]/redist/x86/Microsoft.VC100.CRT
+        [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Windows;Directory]/SysWOW64
+        [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Windows;Directory]/System32
+        NO_DEFAULT_PATH
+        )
+
+    if(EXISTS ${release_msvc10_redist_path})
+        set(release_msvc10_files
+            msvcr100.dll
+            msvcp100.dll
+            )
+
+        copy_if_different(
+            ${release_msvc10_redist_path}
+            "${SHARED_LIB_STAGING_DIR_RELEASE}"
+            out_targets
+            ${release_msvc10_files}
+            )
+        set(third_party_targets ${third_party_targets} ${out_targets})
+
+        copy_if_different(
+            ${release_msvc10_redist_path}
+            "${SHARED_LIB_STAGING_DIR_RELWITHDEBINFO}"
+            out_targets
+            ${release_msvc10_files}
+            )
+        set(third_party_targets ${third_party_targets} ${out_targets})
+
+    endif ()
+endif (MSVC80)
+
+elseif(DARWIN)
+    set(SHARED_LIB_STAGING_DIR_DEBUG            "${SHARED_LIB_STAGING_DIR}/Debug/Resources")
+    set(SHARED_LIB_STAGING_DIR_RELWITHDEBINFO   "${SHARED_LIB_STAGING_DIR}/RelWithDebInfo/Resources")
+    set(SHARED_LIB_STAGING_DIR_RELEASE          "${SHARED_LIB_STAGING_DIR}/Release/Resources")
+
+    set(vivox_src_dir "${ARCH_PREBUILT_DIRS_RELEASE}")
+    set(vivox_files
+        SLVoice
+        libsndfile.dylib
+        libvivoxoal.dylib
+        libortp.dylib
+        libvivoxplatform.dylib
+        libvivoxsdk.dylib
+       )
+    set(debug_src_dir "${ARCH_PREBUILT_DIRS_DEBUG}")
+    set(debug_files
+       )
+    set(release_src_dir "${ARCH_PREBUILT_DIRS_RELEASE}")
+    set(release_files
+        libapr-1.0.dylib
+        libapr-1.dylib
+        libaprutil-1.0.dylib
+        libaprutil-1.dylib
+        libexpat.1.5.2.dylib
+        libexpat.dylib
+        libGLOD.dylib
+        libllqtwebkit.dylib
+        libminizip.a
+        libndofdev.dylib
+        libhunspell-1.3.0.dylib
+        libexception_handler.dylib
+        libcollada14dom.dylib
+       )
+
+    if (FMODEX)
+      #set(debug_files ${debug_files} libfmodexL.dylib)
+      set(release_files ${release_files} libfmodex.dylib)
+    endif (FMODEX)
+
+elseif(LINUX)
+    # linux is weird, multiple side by side configurations aren't supported
+    # and we don't seem to have any debug shared libs built yet anyways...
+    set(SHARED_LIB_STAGING_DIR_DEBUG            "${SHARED_LIB_STAGING_DIR}")
+    set(SHARED_LIB_STAGING_DIR_RELWITHDEBINFO   "${SHARED_LIB_STAGING_DIR}")
+    set(SHARED_LIB_STAGING_DIR_RELEASE          "${SHARED_LIB_STAGING_DIR}")
+
+    set(vivox_src_dir "${ARCH_PREBUILT_DIRS_RELEASE}")
+    set(vivox_files
+        libsndfile.so.1
+        libortp.so
+        libvivoxoal.so.1
+        libvivoxplatform.so
+        libvivoxsdk.so
+        SLVoice
+       )
+    # *TODO - update this to use LIBS_PREBUILT_DIR and LL_ARCH_DIR variables
+    # or ARCH_PREBUILT_DIRS
+    set(debug_src_dir "${ARCH_PREBUILT_DIRS_DEBUG}")
+    set(debug_files
+       )
+    # *TODO - update this to use LIBS_PREBUILT_DIR and LL_ARCH_DIR variables
+    # or ARCH_PREBUILT_DIRS
+    set(release_src_dir "${ARCH_PREBUILT_DIRS_RELEASE}")
+    # *FIX - figure out what to do with duplicate libalut.so here -brad
+    set(release_files
+        libapr-1.so.0
+        libaprutil-1.so.0
+        libatk-1.0.so
+        libboost_program_options-mt.so.${BOOST_VERSION}.0
+        libboost_regex-mt.so.${BOOST_VERSION}.0
+        libboost_thread-mt.so.${BOOST_VERSION}.0
+        libboost_filesystem-mt.so.${BOOST_VERSION}.0
+        libboost_signals-mt.so.${BOOST_VERSION}.0
+        libboost_system-mt.so.${BOOST_VERSION}.0
+        libbreakpad_client.so.0
+        libcollada14dom.so
+        libcrypto.so.1.0.0
+        libdb-5.1.so
+        libexpat.so
+        libexpat.so.1
+        libglod.so
+        libgmock_main.so
+        libgmock.so.0
+        libgmodule-2.0.so
+        libgobject-2.0.so
+        libgtest_main.so
+        libgtest.so.0
+        libhunspell-1.3.so.0.0.0
+        libminizip.so
+        libopenal.so
+        libopenjpeg.so
+        libssl.so
+        libuuid.so.16
+        libuuid.so.16.0.22
+        libssl.so.1.0.0
+        libfontconfig.so.1.4.4
+       )
+
+    if (USE_TCMALLOC)
+      set(release_files ${release_files} "libtcmalloc_minimal.so")
+    endif (USE_TCMALLOC)
+
+    if (FMODEX)
+      set(release_file ${release_files} "libfmodex-4.44.so")
+    endif (FMODEX)
+
+else(WINDOWS)
+    message(STATUS "WARNING: unrecognized platform for staging 3rd party libs, skipping...")
+    set(vivox_src_dir "${CMAKE_SOURCE_DIR}/newview/vivox-runtime/i686-linux")
+    set(vivox_files "")
+    # *TODO - update this to use LIBS_PREBUILT_DIR and LL_ARCH_DIR variables
+    # or ARCH_PREBUILT_DIRS
+    set(debug_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-linux/lib/debug")
+    set(debug_files "")
+    # *TODO - update this to use LIBS_PREBUILT_DIR and LL_ARCH_DIR variables
+    # or ARCH_PREBUILT_DIRS
+    set(release_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-linux/lib/release")
+    set(release_files "")
+
+    set(debug_llkdu_src "")
+    set(debug_llkdu_dst "")
+    set(release_llkdu_src "")
+    set(release_llkdu_dst "")
+    set(relwithdebinfo_llkdu_dst "")
+endif(WINDOWS)
+
+
+################################################################
+# Done building the file lists, now set up the copy commands.
+################################################################
+
+copy_if_different(
+    ${vivox_src_dir}
+    "${SHARED_LIB_STAGING_DIR_DEBUG}"
+    out_targets
+    ${vivox_files}
+    )
+set(third_party_targets ${third_party_targets} ${out_targets})
+
+copy_if_different(
+    ${vivox_src_dir}
+    "${SHARED_LIB_STAGING_DIR_RELEASE}"
+    out_targets
+    ${vivox_files}
+    )
+set(third_party_targets ${third_party_targets} ${out_targets})
+
+copy_if_different(
+    ${vivox_src_dir}
+    "${SHARED_LIB_STAGING_DIR_RELWITHDEBINFO}"
+    out_targets
+    ${vivox_files}
+    )
+set(third_party_targets ${third_party_targets} ${out_targets})
+
+
+
+copy_if_different(
+    ${debug_src_dir}
+    "${SHARED_LIB_STAGING_DIR_DEBUG}"
+    out_targets
+    ${debug_files}
+    )
+set(third_party_targets ${third_party_targets} ${out_targets})
+
+copy_if_different(
+    ${release_src_dir}
+    "${SHARED_LIB_STAGING_DIR_RELEASE}"
+    out_targets
+    ${release_files}
+    )
+set(third_party_targets ${third_party_targets} ${out_targets})
+
+copy_if_different(
+    ${release_src_dir}
+    "${SHARED_LIB_STAGING_DIR_RELWITHDEBINFO}"
+    out_targets
+    ${release_files}
+    )
+set(third_party_targets ${third_party_targets} ${out_targets})
+
+if(NOT STANDALONE)
+  add_custom_target(
+      stage_third_party_libs ALL
+      DEPENDS ${third_party_targets}
+      )
+endif(NOT STANDALONE)


compressible: remove valgrind tests

compressible: remove valgrind tests

--- phSolver/compressible/test/compressible.cmake
+++ phSolver/compressible/test/compressible.cmake
@@ -1,12 +1,5 @@
 c_serial_test(linkProcsDir-sync
   ln -snf ${CDIR}/2-procs_case-SyncIO-1 ${CDIR}/2-procs_case)
-if(HAS_VALGRIND)
-  c_serial_test(resetNumStartValgrind-sync
-    cp ${CDIR}/numstart.dat ${CDIR}/2-procs_case/numstart.dat)
-  c_parallel_test(valgrind-sync 2 ${CDIR}
-    valgrind --leak-check=yes --log-file=cSyncValgrind.%p
-    ${PHASTA_BINARY_DIR}/bin/phastaC.exe)
-endif(HAS_VALGRIND)
 c_serial_test(resetNumStart-sync
   cp ${CDIR}/numstart.dat ${CDIR}/2-procs_case/numstart.dat)
 c_parallel_test( sync 2 ${CDIR} ${PHASTA_BINARY_DIR}/bin/phastaC.exe)
@@ -22,13 +15,6 @@

 c_serial_test(linkProcsDir-posix
   ln -snf ${CDIR}/2-procs_case-Posix ${CDIR}/2-procs_case)
-if(HAS_VALGRIND)
-  c_serial_test(resetNumStartValgrind-posix
-    cp ${CDIR}/numstart.dat ${CDIR}/2-procs_case/numstart.dat)
-  c_parallel_test(compressibleValgrind-posix 2 ${CDIR}
-    valgrind --leak-check=yes --log-file=cPosixValgrind.%p
-    ${PHASTA_BINARY_DIR}/bin/phastaC.exe)
-endif(HAS_VALGRIND)
 c_serial_test(resetNumStart-posix
   cp ${CDIR}/numstart.dat ${CDIR}/2-procs_case/numstart.dat)
 c_parallel_test(posix 2 ${CDIR} ${PHASTA_BINARY_DIR}/bin/phastaC.exe)


Fixed regexp for code coverage script

Fixed regexp for code coverage script

--- cmake/AddCodeCoverage.cmake
+++ cmake/AddCodeCoverage.cmake
@@ -28,10 +28,10 @@
 # POSSIBILITY OF SUCH DAMAGE.

 if (CMAKE_BUILD_TYPE MATCHES "Coverage")
-    get_filename_component(COMPILER_ROOT ${CMAKE_CXX_COMPILER} DIRECTORY)
-    get_filename_component(COMPILER_NAME ${CMAKE_CXX_COMPILER} NAME)
+    get_filename_component(COMPILER_ROOT ${CMAKE_C_COMPILER} DIRECTORY)
+    get_filename_component(COMPILER_NAME ${CMAKE_C_COMPILER} NAME)

-    if (CMAKE_CXX_COMPILER_ID MATCHES Clang)
+    if (CMAKE_C_COMPILER_ID MATCHES Clang)
         string(REGEX REPLACE "([a-z0-9-]*)clang.*" "\\1"
             COMPILER_PREFIX ${COMPILER_NAME})

@@ -61,7 +61,7 @@

             set(GCOV_COMMAND ${CMAKE_BINARY_DIR}/bin/llvm-gcov.sh)
         endif()
-    elseif (CMAKE_CXX_COMPILER_ID MATCHES GNU)
+    elseif (CMAKE_C_COMPILER_ID MATCHES GNU)
         string(REGEX REPLACE "([a-z0-9-]*)gcc.*" "\\1"
             COMPILER_PREFIX ${COMPILER_NAME})


Fixed duplicate PATH in TBB_DEFAULT_INCLUDE_DIRS

--- cmake/OpenCVDetectTBB.cmake
+++ cmake/OpenCVDetectTBB.cmake
@@ -24,7 +24,7 @@
   set(TBB_DEFAULT_INCLUDE_DIRS
     "/opt/intel/tbb/include" "/usr/local/include" "/usr/include"
     "C:/Program Files/Intel/TBB" "C:/Program Files (x86)/Intel/TBB"
-    "C:/Program Files (x86)/tbb/include"
+    "C:/Program Files/tbb/include"
     "C:/Program Files (x86)/tbb/include"
     "${CMAKE_INSTALL_PREFIX}/include")


CMake: Avoid Google Test error when re-configuring with latest Abseil

Abseil insists on having a Google Test directory, even if we're not going to
run (or even build) the tests.

This changes forces all test settings to `OFF` just for Abseil, allowing
SAPI builds to complete normally. Embedding projects should not be affected,
if they already included Abseil.

PiperOrigin-RevId: 309035680
Change-Id: Ie46297d8b502d92d0c10ef04360e992bcee4964b

--- cmake/abseil/Download.cmake
+++ cmake/abseil/Download.cmake
@@ -33,13 +33,20 @@
 endif()

 set(_sapi_saved_CMAKE_CXX_STANDARD ${CMAKE_CXX_STANDARD})
+set(_sapi_saved_BUILD_TESTING ${BUILD_TESTING})
+
 set(CMAKE_CXX_STANDARD ${SAPI_CXX_STANDARD})
 set(ABSL_USE_GOOGLETEST_HEAD OFF CACHE BOOL "" FORCE)
+set(ABSL_RUN_TESTS OFF CACHE BOOL "" FORCE)
+set(BUILD_TESTING OFF)  # Avoid errors when re-configuring SAPI
 set(ABSL_CXX_STANDARD ${SAPI_CXX_STANDARD} CACHE STRING "" FORCE)

 add_subdirectory("${CMAKE_BINARY_DIR}/absl-src"
                  "${CMAKE_BINARY_DIR}/absl-build" EXCLUDE_FROM_ALL)

+if(_sapi_saved_BUILD_TESTING)
+  set(BUILD_TESTING "${_sapi_saved_BUILD_TESTING}")
+endif()
 if(_sapi_saved_CMAKE_CXX_STANDARD)
   set(CMAKE_CXX_STANDARD "${_sapi_saved_CMAKE_CXX_STANDARD}")
 endif()


Added definitions to the build system to handle vrpn presence.

--- cmake/dtkDependencies.cmake
+++ cmake/dtkDependencies.cmake
@@ -4,9 +4,9 @@
 ## Copyright (C) 2008 - Julien Wintz, Inria.
 ## Created: Fri Apr  2 09:11:53 2010 (+0200)
 ## Version: $Id$
-## Last-Updated: Mon Aug 23 20:33:36 2010 (+0200)
-##           By: jwintz
-##     Update #: 37
+## Last-Updated: Wed Sep  8 10:10:21 2010 (+0200)
+##           By: Julien Wintz
+##     Update #: 38
 ######################################################################
 ##
 ### Commentary:
@@ -190,5 +190,9 @@
 link_directories(${VRPN_LIBRARIES})
 endif(QUAT_LIBRARIES AND VRPN_LIBRARIES)

+if(QUAT_LIBRARIES AND VRPN_LIBRARIES)
+  add_definitions(-DHAVE_VRPN)
+endif(QUAT_LIBRARIES AND VRPN_LIBRARIES)
+
 mark_as_advanced(QUAT_LIBRARIES)
 mark_as_advanced(VRPN_LIBRARIES)


upgrade ngraph to support mkldnn v1.0 (#19689)

--- cmake/external/ngraph.cmake
+++ cmake/external/ngraph.cmake
@@ -37,7 +37,7 @@
 INCLUDE(ExternalProject)

 SET(NGRAPH_PROJECT         "extern_ngraph")
-SET(NGRAPH_GIT_TAG         "v0.24.0-rc.2")
+SET(NGRAPH_GIT_TAG         "e26d602a756f5f83e6c8220f910b61d7089fa951")
 SET(NGRAPH_SOURCES_DIR     ${THIRD_PARTY_PATH}/ngraph)
 SET(NGRAPH_INSTALL_DIR     ${THIRD_PARTY_PATH}/install/ngraph)
 SET(NGRAPH_INC_DIR         ${NGRAPH_INSTALL_DIR}/include)
@@ -76,6 +76,7 @@
     CMAKE_ARGS               -DMKLDNN_INCLUDE_DIR=${MKLDNN_INC_DIR}
     CMAKE_ARGS               -DMKLDNN_LIB_DIR=${MKLDNN_INSTALL_DIR}/${CMAKE_INSTALL_LIBDIR}
     CMAKE_ARGS               -DMKLML_LIB_DIR=${MKLML_INSTALL_DIR}/lib
+    CMAKE_ARGS               -NGRAPH_USE_LEGACY_MKLDNN=TRUE
 )

 add_dependencies(ngraph ${NGRAPH_PROJECT})


[cmake] Fix get_llvm_lit_path() to respect LLVM_EXTERNAL_LIT always

Refactor the get_llvm_lit_path() logic to respect LLVM_EXTERNAL_LIT,
and require the fallback to be defined explicitly
as LLVM_DEFAULT_EXTERNAL_LIT. This fixes building libcxx standalone
after r346888.

The old logic was using LLVM_EXTERNAL_LIT both as user-defined cache
variable and an optional pre-definition of default value from caller
(e.g. libcxx). It included a hack to make this work by assigning
the value back and forth but it was fragile and stopped working
in libcxx.

The new logic is simpler and more transparent. Default value is
provided in a separate variable, and used only when user-specified
variable is empty (i.e. not overriden).

Differential Revision: https://reviews.llvm.org/D57282

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

--- cmake/modules/AddLLVM.cmake
+++ cmake/modules/AddLLVM.cmake
@@ -1280,7 +1280,6 @@
   cmake_parse_arguments(ARG "ALLOW_EXTERNAL" "" "" ${ARGN})

   if (ARG_ALLOW_EXTERNAL)
-    set(LLVM_DEFAULT_EXTERNAL_LIT "${LLVM_EXTERNAL_LIT}")
     set (LLVM_EXTERNAL_LIT "" CACHE STRING "Command used to spawn lit")
     if ("${LLVM_EXTERNAL_LIT}" STREQUAL "")
       set(LLVM_EXTERNAL_LIT "${LLVM_DEFAULT_EXTERNAL_LIT}")