idl cmake: qi_create_idl

idl cmake: qi_create_idl

Change-Id: Ie135633673ef21a173c7c39b8067d8cdef392862
Reviewed-on: http://gerrit.aldebaran.lan:8080/13768
Reviewed-by: mnottale <e3ccf1b6558404e921a21fa09cebb1153b50ec36@aldebaran-robotics.com>
Tested-by: mnottale <e3ccf1b6558404e921a21fa09cebb1153b50ec36@aldebaran-robotics.com>

--- codegen/src/idl-config.cmake
+++ codegen/src/idl-config.cmake
@@ -1,5 +1,56 @@

 qi_global_set(qi_create_service_file ${CMAKE_CURRENT_LIST_FILE})
+
+#! \ Find idl.py or error
+function(_qi_find_idl where)
+  #First, locate idl.py
+  qi_global_get(qi_create_service_file_local qi_create_service_file)
+  get_filename_component(cdir "${qi_create_service_file_local}" PATH)
+  find_program(_python_executable
+    NAMES python2 python python.exe
+    NO_CMAKE_FIND_ROOT_PATH)
+  if (NOT _python_executable)
+    qi_error("needs python executable in PATH")
+  endif()
+  find_program(IDLPY
+    name idl.py
+    PATHS ${cdir}/../../../codegen/src ${cdir}/../../../bin
+    )
+  if (NOT IDLPY)
+    qi_error("idl.py not found")
+  endif()
+  qi_persistent_set(${where} ${IDLPY})
+endfunction()
+
+#! Create an IDL file by parsing C++ header files.
+# \group:SRC C++ source/headers file to parse
+# \group:CLASSES name of the classes for which to generate idl
+# \param:PREFIX path where to generate IDL files
+# \param:files name of variable that is filled by generated file names
+function(qi_create_idl files)
+  cmake_parse_arguments(ARG
+    ""
+    "PREFIX"
+    "SRC;CLASSES"
+    ${ARGN})
+  _qi_find_idl(IDL)
+  set(names "")
+  if (NOT ARG_PREFIX)
+    set(ARG_PREFIX ".")
+  endif()
+  foreach(c ${ARG_CLASSES})
+    set(target "${ARG_PREFIX}/${c}.xml")
+    qi_generate_src(${target}
+      SRC ${ARG_SRC}
+      COMMAND  ${_python_executable} ${IDL}
+      ${ARG_SRC}
+      -c ${c}
+      -o ${target}
+      -m idl)
+    list(APPEND names "${target}")
+  endforeach(c)
+  qi_persistent_set(${files} "${names}")
+endfunction()

 #! Create a naoqi service and companion files
 # \group:CLASSES list of class names to be exposed to naoqi as objects
@@ -17,21 +68,7 @@
     "SRC;DOXYSRC;SUBMODULE;DEPENDS;CLASSES;SERVICES;INCLUDE;INCLUDE_SERVICE" ${ARGN})
   message("parsing args: ${ARG_CLASSES}")
   #First, locate idl.py
-  qi_global_get(qi_create_service_file_local qi_create_service_file)
-  get_filename_component(cdir "${qi_create_service_file_local}" PATH)
-  find_program(_python_executable
-    NAMES python2 python python.exe
-    NO_CMAKE_FIND_ROOT_PATH)
-  if (NOT _python_executable)
-    qi_error("needs python executable in PATH")
-  endif()
-  find_program(IDLPY
-    name idl.py
-    PATHS ${cdir}/../../../codegen/src ${cdir}/../../../bin
-    )
-  if (NOT IDLPY)
-    qi_error("idl.py not found")
-  endif()
+  _qi_find_idl(IDLPY)
   #ARGN are sources too
   set(ARG_SRC ${ARG_UNPARSED_ARGUMENTS} ${ARG_SRC})
   #Reformat arguments to be able to bounce them


Fix assets folder using wrong path with multiple projects

--- CMake/Tools.cmake
+++ CMake/Tools.cmake
@@ -2,9 +2,9 @@

 macro(OE_add_resources folder target)
 	if(EMSCRIPTEN)
-		set(virtual_folder ${virtual_folder}/vfs)
+		set(virtual_folder /vfs)
 	elseif(ANDROID)
-		set(virtual_folder ${virtual_folder}/APK/assets)
+		set(virtual_folder /APK/assets)
 	endif()

 	get_filename_component(folder_name ${folder} NAME)


update package description

update package description

--- CPackConfig.cmake
+++ CPackConfig.cmake
@@ -1,7 +1,7 @@
 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")
+SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY "QueryArrow is a semantically unified SQL and NoSQL query and update system")
 # SET(CPACK_PACKAGE_EXECUTABLES "QueryArrow")
 SET(CPACK_PACKAGE_FILE_NAME "queryarrow-0.2-Linux-amd64")
 SET(CPACK_PACKAGE_INSTALL_DIRECTORY "queryarrow-0.2")


changed CDash to viennastar.iue.tuwien.ac.at

--- CTestConfig.cmake
+++ CTestConfig.cmake
@@ -2,6 +2,6 @@
 set(CTEST_NIGHTLY_START_TIME "01:00:00 UTC")

 set(CTEST_DROP_METHOD "http")
-set(CTEST_DROP_SITE "frudo.iue.tuwien.ac.at:50080")
+set(CTEST_DROP_SITE "viennastar.iue.tuwien.ac.at")
 set(CTEST_DROP_LOCATION "/CDash/submit.php?project=ViennaFVM")
 set(CTEST_DROP_SITE_CDASH TRUE)


[t:4871] don't run stress-gc2.tdb under valgrind

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

--- CTestCustom.cmake
+++ CTestCustom.cmake
@@ -28,6 +28,7 @@
   ydb/preload-db-nested.tdb
   ydb/recovery_fileops_unit.tdb
   ydb/stress-gc.tdb
+  ydb/stress-gc2.tdb
   ydb/stress-test.bdb
   ydb/stress-test.tdb
   ydb/test-prepare.tdb


[t:4814] suppress xz compilation warnings on the dashboard

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

--- CTestCustom.cmake
+++ CTestCustom.cmake
@@ -157,3 +157,6 @@
   list(APPEND CTEST_CUSTOM_MEMCHECK_IGNORE ${long_running_tests})
   list(APPEND CTEST_CUSTOM_TESTS_IGNORE ${long_running_tests})
 endif()
+
+## don't complain about warnings in xz source
+list(APPEND CTEST_CUSTOM_WARNING_EXCEPTION "xz-4.999.9beta/src/liblzma")


FIX (#6482): do not install Qt plugins if using system Qt

--- CMake/CoreHelpers.cmake
+++ CMake/CoreHelpers.cmake
@@ -472,6 +472,10 @@
   LIST(APPEND DIRS "/usr/lib")
 ENDIF(APPLE)

+if(QT_LIBRARY_DIR MATCHES "^(/lib/|/lib32/|/lib64/|/usr/lib/|/usr/lib32/|/usr/lib64/|/usr/X11R6/)")
+  set(_qt_is_system_qt 1)
+endif()
+
 FOREACH(_target ${_install_EXECUTABLES})

 SET(_qt_plugins_install_dirs "")
@@ -505,25 +509,29 @@

 FOREACH(_target_location ${_target_locations})

-IF(QT_PLUGINS_DIR)
-    INSTALL(DIRECTORY "${QT_PLUGINS_DIR}"
-	    DESTINATION ${${_target_location}_qt_plugins_install_dir}
-		    CONFIGURATIONS Release
-		    FILES_MATCHING REGEX "[^d]4?\\${CMAKE_SHARED_LIBRARY_SUFFIX}$"
-		    )
-
-    INSTALL(DIRECTORY "${QT_PLUGINS_DIR}"
-	    DESTINATION ${${_target_location}_qt_plugins_install_dir}
-		    CONFIGURATIONS Debug
-		    FILES_MATCHING REGEX "d4?\\${CMAKE_SHARED_LIBRARY_SUFFIX}$"
-		    )
-
-ENDIF(QT_PLUGINS_DIR)
+IF(NOT _qt_is_system_qt)
+  IF(QT_PLUGINS_DIR)
+      INSTALL(DIRECTORY "${QT_PLUGINS_DIR}"
+        DESTINATION ${${_target_location}_qt_plugins_install_dir}
+          CONFIGURATIONS Release
+          FILES_MATCHING REGEX "[^d]4?\\${CMAKE_SHARED_LIBRARY_SUFFIX}$"
+          )
+
+      INSTALL(DIRECTORY "${QT_PLUGINS_DIR}"
+        DESTINATION ${${_target_location}_qt_plugins_install_dir}
+          CONFIGURATIONS Debug
+          FILES_MATCHING REGEX "d4?\\${CMAKE_SHARED_LIBRARY_SUFFIX}$"
+          )
+
+  ENDIF(QT_PLUGINS_DIR)
+ENDIF(NOT _qt_is_system_qt)
+

   _fixup_target()
 ENDFOREACH(_target_location)

+IF(NOT _qt_is_system_qt)
   #--------------------------------------------------------------------------------
   # install a qt.conf file
   # this inserts some cmake code into the install script to write the file
@@ -540,6 +548,7 @@
 \")
 	")
   ENDFOREACH()
+ENDIF(NOT _qt_is_system_qt)

@@ -572,6 +581,10 @@
   ${MITK_BINARY_DIR}/bin/${intermediate_dir}
   ${_install_LIBRARY_DIRS}
   )
+
+if(QT_LIBRARY_DIR MATCHES "^(/lib/|/lib32/|/lib64/|/usr/lib/|/usr/lib32/|/usr/lib64/|/usr/X11R6/)")
+  set(_qt_is_system_qt 1)
+endif()

 FOREACH(_target ${_install_EXECUTABLES})

@@ -616,25 +629,29 @@

 FOREACH(_target_location ${_target_locations})
-
-IF(QT_PLUGINS_DIR)
-    INSTALL(DIRECTORY "${QT_PLUGINS_DIR}"
-	    DESTINATION ${${_target_location}_qt_plugins_install_dir}
-		    CONFIGURATIONS Release
-		    FILES_MATCHING REGEX "[^d]4?\\${CMAKE_SHARED_LIBRARY_SUFFIX}$"
-		    )
-
-    INSTALL(DIRECTORY "${QT_PLUGINS_DIR}"
-	    DESTINATION ${${_target_location}_qt_plugins_install_dir}
-		    CONFIGURATIONS Debug
-		    FILES_MATCHING REGEX "d4?\\${CMAKE_SHARED_LIBRARY_SUFFIX}$"
-		    )
-
-ENDIF(QT_PLUGINS_DIR)
+  IF(NOT _qt_is_system_qt)
+
+    IF(QT_PLUGINS_DIR)
+        INSTALL(DIRECTORY "${QT_PLUGINS_DIR}"
+          DESTINATION ${${_target_location}_qt_plugins_install_dir}
+            CONFIGURATIONS Release
+            FILES_MATCHING REGEX "[^d]4?\\${CMAKE_SHARED_LIBRARY_SUFFIX}$"
+            )
+
+        INSTALL(DIRECTORY "${QT_PLUGINS_DIR}"
+          DESTINATION ${${_target_location}_qt_plugins_install_dir}
+            CONFIGURATIONS Debug
+            FILES_MATCHING REGEX "d4?\\${CMAKE_SHARED_LIBRARY_SUFFIX}$"
+            )
+
+    ENDIF(QT_PLUGINS_DIR)
+  ENDIF(NOT _qt_is_system_qt)

   _fixup_target()
 ENDFOREACH(_target_location)

+
+IF(NOT _qt_is_system_qt)

   #--------------------------------------------------------------------------------
   # install a qt.conf file
@@ -653,6 +670,7 @@
 	")
   ENDFOREACH()

+ENDIF(NOT _qt_is_system_qt)


fix to poco cmake module to find the lib on Ubuntu, where it is in /usr/lib directly

git-svn-id: 65dd0ccd495961f396d5302e5521154b071f0302@1041 5b2332b8-efa3-11de-8684-7d64432d61a3

--- CMakeModules/PoCo.cmake
+++ CMakeModules/PoCo.cmake
@@ -16,6 +16,7 @@
     /opt/poco
     /opt/Poco
     /usr/local
+    /usr/lib
     /usr/lib/PoCo
     /usr/lib/Poco
     /usr/local/Poco


Force gecode to install libraries in lib directory instead of lib64

--- cmake-support/Gecode.cmake
+++ cmake-support/Gecode.cmake
@@ -19,6 +19,7 @@
     PATCH_COMMAND ""
     CONFIGURE_COMMAND ${GECODE_SRC_DIR}/configure
       --enable-static --disable-shared --prefix=${GECODE_INSTALL_DIR}
+      --libdir=${GECODE_INSTALL_DIR}/lib
       --disable-gist --disable-flatzinc --disable-examples
       --disable-qt --disable-driver --disable-minimodel
     BUILD_COMMAND make


MINIFICPP-1974 - Update rocksdb to compile with clang15

Signed-off-by: Gabor Gyimesi <gamezbird@gmail.com>

This closes #1445

--- cmake/BundledRocksDB.cmake
+++ cmake/BundledRocksDB.cmake
@@ -49,8 +49,8 @@
     # Build project
     ExternalProject_Add(
             rocksdb-external
-            URL "https://github.com/facebook/rocksdb/archive/v6.20.3.tar.gz"
-            URL_HASH "SHA256=c6502c7aae641b7e20fafa6c2b92273d935d2b7b2707135ebd9a67b092169dca"
+            URL "https://github.com/facebook/rocksdb/archive/refs/tags/v6.29.5.tar.gz"
+            URL_HASH "SHA256=ddbf84791f0980c0bbce3902feb93a2c7006f6f53bfd798926143e31d4d756f0"
             SOURCE_DIR "${BINARY_DIR}/thirdparty/rocksdb-src"
             CMAKE_ARGS ${ROCKSDB_CMAKE_ARGS}
             BUILD_BYPRODUCTS "${BINARY_DIR}/thirdparty/rocksdb-install/${BYPRODUCT}"


cmake: add export_complex_library function

parameters LIBNAME and MODULE (module)

* adds LIBNAME to a global property ${${MODULE}_EXPORTS}
* if MODULE isn't given LIBNAME is expected to be in the format
  "module-libname"

--- cmake/ComplexLibrary.cmake
+++ cmake/ComplexLibrary.cmake
@@ -30,6 +30,37 @@
 	set(${${PREFIX}_VARIABLE} ${${${PREFIX}_VARIABLE}} ${${PREFIX}_LIBS})

 endmacro(set_complex_link_libraries)
+
+# - add a new library to a module for export
+#  MODULE - module the library belongs to
+#  LIBNAME - name of the library
+#   - if MODULE isn't set the NAME should must be in the form MODULE-NAME
+function(export_complex_library)
+	set(PREFIX "EXPORT_COMPLEX_LIBRARY")
+	cmake_parse_arguments(${PREFIX}
+			""
+			"LIBNAME;MODULE"
+			""
+			${ARGN})
+
+	if (NOT ${PREFIX}_LIBNAME)
+		message(FATAL_ERROR "export_complex_library requires a name to be set")
+	endif()
+	if (NOT ${PREFIX}_MODULE)
+		string(REPLACE "-" ";" LIBNAME_LIST "${${PREFIX}_LIBNAME}")
+		list(GET LIBNAME_LIST 0 MODULE)
+		list(GET LIBNAME_LIST 1 LIBNAME)
+	else()
+		set(MODULE ${${PREFIX}_MODULE})
+		set(LIBNAME ${${PREFIX}_LIBNAME})
+	endif()
+	if (NOT MODULE)
+		message(FATAL_ERROR "export_complex_library couldn't identify MODULE")
+	endif()
+	get_property(MEXPORTS GLOBAL PROPERTY ${MODULE}_EXPORTS)
+	list(APPEND MEXPORTS ${LIBNAME})
+	set_property(GLOBAL PROPERTY ${MODULE}_EXPORTS "${MEXPORTS}")
+endfunction(export_complex_library)

 macro(add_complex_library)


change boost url, which block warning of Unknown compiler version (#36857)

--- cmake/external/boost.cmake
+++ cmake/external/boost.cmake
@@ -23,7 +23,10 @@
 # checked that the devtools package of CentOS 6 installs boost 1.41.0.
 # So we use 1.41.0 here.
 set(BOOST_VER   "1.41.0")
-set(BOOST_TAR   "boost_1_41_0" CACHE STRING "" FORCE)
+# boost_1_41_0_2021_10.tar.gz is almost the same with boost_1_41_0.tar.gz,
+# except in visualc.hpp i comment a warning of "unknown compiler version",
+# so if you need to change boost, you may need to block the warning similarly.
+set(BOOST_TAR   "boost_1_41_0_2021_10" CACHE STRING "" FORCE)
 set(BOOST_URL   "http://paddlepaddledeps.bj.bcebos.com/${BOOST_TAR}.tar.gz" CACHE STRING "" FORCE)

 MESSAGE(STATUS "BOOST_VERSION: ${BOOST_VER}, BOOST_URL: ${BOOST_URL}")
@@ -46,7 +49,7 @@
     ${BOOST_PROJECT}
     ${EXTERNAL_PROJECT_LOG_ARGS}
     "${BOOST_DOWNLOAD_CMD}"
-    URL_MD5               f891e8c2c9424f0565f0129ad9ab4aff
+    URL_MD5               51be7cc203628dc0848e97eee32d79e3
     PREFIX                ${BOOST_PREFIX_DIR}
     DOWNLOAD_DIR          ${BOOST_SOURCE_DIR}
     SOURCE_DIR            ${BOOST_SOURCE_DIR}


Fixed the logic for finding isnan/finite/isinf for Visual C++ compilers.

svn path=/trunk/; revision=9630

--- cmake/modules/plplot.cmake
+++ cmake/modules/plplot.cmake
@@ -201,46 +201,63 @@

 # Check for FP functions, including underscored version which
 # are sometimes all that is available on windows
+
+
 check_symbol_exists(finite "math.h" HAVE_FINITE)
 if(NOT HAVE_FINITE)
   check_function_exists(finite HAVE_FINITE2)
-endif(NOT HAVE_FINITE)
-set(HAVE_FINITE ${HAVE_FINITE2})
-if(NOT HAVE_FINITE)
-  check_symbol_exists(_finite "math.h" _HAVE_FINITE)
-  if(NOT _HAVE_FINITE)
-    check_function_exists(_finite _HAVE_FINITE2)
-  endif(NOT _HAVE_FINITE)
-  set(_HAVE_FINITE ${_HAVE_FINITE2})
-  set(HAVE_FINITE ${_HAVE_FINITE} CACHE INTERNAL "Have function _finite")
+  if(HAVE_FINITE2)
+    set(HAVE_FINITE ${HAVE_FINITE2} CACHE INTERNAL "Have function finite")
+  else(HAVE_FINITE2)
+    check_symbol_exists(_finite "math.h" _HAVE_FINITE)
+    if(NOT _HAVE_FINITE)
+      check_function_exists(_finite _HAVE_FINITE2)
+      if(_HAVE_FINITE2)
+        set(_HAVE_FINITE ${_HAVE_FINITE2} CACHE INTERNAL "Have function _finite")
+        set(HAVE_FINITE ${_HAVE_FINITE} CACHE INTERNAL "Have function _finite")
+      endif(_HAVE_FINITE2)
+      set(_HAVE_FINITE2 "" CACHE INTERNAL "Have function _finite")
+    endif(NOT _HAVE_FINITE)
+  endif(HAVE_FINITE2)
+  set(HAVE_FINITE2 "" CACHE INTERNAL "Have function finite")
 endif(NOT HAVE_FINITE)

 check_symbol_exists(isnan "math.h" HAVE_ISNAN)
 if(NOT HAVE_ISNAN)
   check_function_exists(isnan HAVE_ISNAN2)
+  if(HAVE_ISNAN2)
+    set(HAVE_ISNAN ${HAVE_ISNAN2} CACHE INTERNAL "Have function isnan")
+  else(HAVE_ISNAN2)
+    check_symbol_exists(_isnan "math.h" _HAVE_ISNAN)
+    if(NOT _HAVE_ISNAN)
+      check_function_exists(_isnan _HAVE_ISNAN2)
+      if(_HAVE_ISNAN2)
+        set(_HAVE_ISNAN ${_HAVE_ISNAN2} CACHE INTERNAL "Have function _isnan")
+        set(HAVE_ISNAN ${_HAVE_ISNAN} CACHE INTERNAL "Have function _isnan")
+      endif(_HAVE_ISNAN2)
+      set(_HAVE_ISNAN2 "" CACHE INTERNAL "Have function _isnan")
+    endif(NOT _HAVE_ISNAN)
+  endif(HAVE_ISNAN2)
+  set(HAVE_ISNAN2 "" CACHE INTERNAL "Have function isnan")
 endif(NOT HAVE_ISNAN)
-set(HAVE_ISNAN ${HAVE_ISNAN2})
-if(NOT HAVE_ISNAN)
-  check_symbol_exists(_isnan "math.h" _HAVE_ISNAN)
-  if(NOT _HAVE_ISNAN)
-    check_function_exists(_isnan _HAVE_ISNAN2)
-  endif(NOT _HAVE_ISNAN)
-  set(_HAVE_ISNAN ${_HAVE_ISNAN2})
-  set(HAVE_ISNAN ${_HAVE_ISNAN} CACHE INTERNAL "Have function _isnan")
-endif(NOT HAVE_ISNAN)
-
-check_symbol_exists(isinf "math.h" HAVE_ISINF)
+
+check_symbol_exists(ising "math.h" HAVE_ISINF)
 if(NOT HAVE_ISINF)
-  check_function_exists(isinf HAVE_ISINF2)
-endif(NOT HAVE_ISINF)
-set(HAVE_ISINF ${HAVE_ISINF2})
-if(NOT HAVE_ISINF)
-  check_symbol_exists(_isinf "math.h" _HAVE_ISINF)
-  if(NOT _HAVE_ISINF)
-    check_function_exists(_isinf _HAVE_ISINF2)
-  endif(NOT _HAVE_ISINF)
-  set(_HAVE_ISINF ${_HAVE_ISINF2})
-  set(HAVE_ISINF ${_HAVE_ISINF} CACHE INTERNAL "Have function _isinf")
+  check_function_exists(ising HAVE_ISINF2)
+  if(HAVE_ISINF2)
+    set(HAVE_ISINF ${HAVE_ISINF2} CACHE INTERNAL "Have function ising")
+  else(HAVE_ISINF2)
+    check_symbol_exists(_ising "math.h" _HAVE_ISINF)
+    if(NOT _HAVE_ISINF)
+      check_function_exists(_ising _HAVE_ISINF2)
+      if(_HAVE_ISINF2)
+        set(_HAVE_ISINF ${_HAVE_ISINF2} CACHE INTERNAL "Have function _ising")
+        set(HAVE_ISINF ${_HAVE_ISINF} CACHE INTERNAL "Have function _ising")
+      endif(_HAVE_ISINF2)
+      set(_HAVE_ISINF2 "" CACHE INTERNAL "Have function _ising")
+    endif(NOT _HAVE_ISINF)
+  endif(HAVE_ISINF2)
+  set(HAVE_ISINF2 "" CACHE INTERNAL "Have function ising")
 endif(NOT HAVE_ISINF)

 check_function_exists(snprintf PL_HAVE_SNPRINTF)


Implement equivalent of AC_CHECK_HEADERS(unistd.h termios.h)

svn path=/trunk/; revision=6910

--- cmake/modules/plplot.cmake
+++ cmake/modules/plplot.cmake
@@ -80,6 +80,10 @@
   set(STDC_HEADERS 0 CACHE INTERNAL "System has ANSI C header files")
 endif(NOT STDC_HEADERS)

+# AC_CHECK_HEADERS(unistd.h termios.h)
+check_include_files(unistd.h HAVE_UNISTD_H)
+check_include_files(termios.h HAVE_TERMIOS_H)
+
 # Reasonable approximation to AC_HEADER_DIRENT without the SCO stuff.
 include(CheckDIRSymbolExists)
 check_dirsymbol_exists("sys/types.h;dirent.h" HAVE_DIRENT_H)


Use "brute force" to determine the import libraries for gdi32.dll and
comdlg32.dll under MSYS.

svn path=/trunk/; revision=9820

--- cmake/modules/wingcc.cmake
+++ cmake/modules/wingcc.cmake
@@ -23,16 +23,26 @@
 # PLD_wingcc		  - ON means the wingcc device is enabled.
 # wingcc_COMPILE_FLAGS	  - individual COMPILE_FLAGS required to compile wingcc
 # 			    device.
-# wingcc_LINK_FLAGS	  - list of pathnames of libraries for dynamic
+# wingcc_LINK_FLAGS	  - list of pathnames of libraries for dynamic
 # 			    wingcc device.
 # DRIVERS_LINK_FLAGS	  - list of LINK_FLAGS for all static devices.

 if(PLD_wingcc)
   message(STATUS "Looking for gdi32 header and library")
-  find_library(GDI32_LIBRARY gdi32 HINTS ${MINGWLIBPATH} ${BORLANDLIBPATH})
-  if(GDI32_LIBRARY)
-    find_library(COMDLG32_LIBRARY comdlg32 HINTS ${MINGWLIBPATH} ${BORLANDLIBPATH})
-  endif(GDI32_LIBRARY)
+  if(NOT MSYS)
+    find_library(GDI32_LIBRARY gdi32 HINTS ${MINGWLIBPATH} ${BORLANDLIBPATH})
+    if(GDI32_LIBRARY)
+      find_library(COMDLG32_LIBRARY comdlg32 HINTS ${MINGWLIBPATH} ${BORLANDLIBPATH})
+    endif(GDI32_LIBRARY)
+  else(NOT MSYS)
+    # Use fixed names instead
+    # Note: MINGWLIBPATH gave problem: CACHE unknown component
+    get_filename_component(msys_BIN ${CMAKE_C_COMPILER} PATH)
+    set(msys_LIBDIR ${msys_BIN}/../lib)
+    #get_filename_component(msys_LIBDIR ${msys_LIBS} PATH)
+    set(GDI32_LIBRARY ${msys_LIBDIR}/libgdi32.a)
+    set(COMDLG32_LIBRARY ${msys_LIBDIR}/libcomdlg32.a)
+  endif(NOT MSYS)
   if(GDI32_LIBRARY AND COMDLG32_LIBRARY)
     message(STATUS "Looking for gdi32 header and library - found")
     set(wingcc_LINK_FLAGS "${GDI32_LIBRARY};${COMDLG32_LIBRARY}")
@@ -51,6 +61,6 @@
   else(GDI32_LIBRARY AND COMDLG32_LIBRARY)
     message(STATUS "Looking for gdi32 header and library - not found")
     message(STATUS "WARNING: Setting PLD_wingcc to OFF.")
-    set(PLD_wingcc OFF CACHE BOOL "Enable wingcc device" FORCE)
+    set(PLD_wingcc OFF CACHE BOOL "Enable wingcc device" FORCE)
   endif(GDI32_LIBRARY AND COMDLG32_LIBRARY)
 endif(PLD_wingcc)


qi_create_python_ext: install using qi_install_python

Change-Id: I918fba76095fd30778f77f1aa432de389b7e27ad

--- cmake/qibuild/python.cmake
+++ cmake/qibuild/python.cmake
@@ -127,8 +127,7 @@
   )

   qi_use_lib(${target} PYTHON)
-  install(TARGETS ${target} DESTINATION lib/python2.7/site-packages
-         COMPONENT runtime)
+  qi_install_python(TARGETS ${target} COMPONENT runtime)

   # Register the target into the build dir for qipy
   file(WRITE ${QI_SDK_DIR}/qi.pth


cmake: uselib: store fat deps in the PKG_FAT_DEPENDS instead of the last dependencies..

works better as you may guess...

--- cmake/qibuild/uselib.cmake
+++ cmake/qibuild/uselib.cmake
@@ -38,12 +38,14 @@

 #compute the dependencies list, removing duplicate
 #TODO: store computed dependencies in ${_U_PKG}_FLAT_DEPENDS ?
-function(_qi_use_lib_get_deps _OUT_list)
+function(_qi_use_lib_get_deps name _OUT_list)
   set(_result ${ARGN})
   list(LENGTH _result _count)
   if (_count EQUAL 0)
     return()
   endif()
+
+  string(TOUPPER ${name} _U_NAME)

   foreach(_pkg ${ARGN})
     string(TOUPPER ${_pkg} _U_PKG)
@@ -77,7 +79,7 @@
       string(TOUPPER ${_sub_dep} _u_sub_dep)
       if (_is_present EQUAL -1)
         if (NOT ${_u_sub_dep}_FAT_DEPENDS)
-          _qi_use_lib_get_deps(_new_deps "${_sub_dep}")
+          _qi_use_lib_get_deps("${_U_PKG}" _new_deps "${_sub_dep}")
         else()
           set(_new_deps ${${_u_sub_dep}_FAT_DEPENDS})
         endif()
@@ -98,7 +100,7 @@

   #why? because it will avoid many recursion. we store the complete dependencies of a project
   # in cache, and use that, instead of digging into deps by recursion.
-  qi_set_cache(${_U_PKG}_FAT_DEPENDS "${_result}")
+  qi_set_cache(${_U_NAME}_FAT_DEPENDS "${_result}")
   set(${_OUT_list} ${_result} PARENT_SCOPE)
 endfunction()

@@ -120,7 +122,7 @@

   set(ARG_DEPENDS ${ARG_UNPARSED_ARGUMENTS} ${ARG_DEPENDS})

-  _qi_use_lib_get_deps(_DEPS ${ARG_DEPENDS})
+  _qi_use_lib_get_deps("${name}" _DEPS ${ARG_DEPENDS})

   foreach(_pkg ${_DEPS})
     string(TOUPPER ${_pkg} _U_PKG)


rewrite hydrogen removal to be more efficient

remove 30 cuda version

--- cmake/Cuda.cmake
+++ cmake/Cuda.cmake
@@ -4,7 +4,7 @@

 # Known NVIDIA GPU achitectures Caffe can be compiled for.
 # This list will be used for CUDA_ARCH_NAME = All option
-set(Caffe_known_gpu_archs "30 35 50 60 61")
+set(Caffe_known_gpu_archs "35 50 60 61")

 ################################################################################################
 # A function for automatic detection of GPUs installed  (if autodetection is enabled)
@@ -86,7 +86,7 @@
   if(${CUDA_ARCH_NAME} STREQUAL "Fermi")
     set(__cuda_arch_bin "20 21(20)")
   elseif(${CUDA_ARCH_NAME} STREQUAL "Kepler")
-    set(__cuda_arch_bin "30 35")
+    set(__cuda_arch_bin "35")
   elseif(${CUDA_ARCH_NAME} STREQUAL "Maxwell")
     set(__cuda_arch_bin "50")
   elseif(${CUDA_ARCH_NAME} STREQUAL "Pascal")


Fail if "Error: " occurs at beginning of lines

--- cmake/test.cmake
+++ cmake/test.cmake
@@ -151,7 +151,7 @@
   set_tests_properties(test-${testname}-${instance}
     PROPERTIES
       WORKING_DIRECTORY       "${EXECUTABLE_OUTPUT_PATH}"
-      FAIL_REGULAR_EXPRESSION "^Error: ")
+      FAIL_REGULAR_EXPRESSION "^Error: ;\nError: ")
   if (test_environment)
     set_tests_properties(test-${testname}-${instance}
       PROPERTIES


Use Boost 1.54 (temporarily) for OS X builds until 1.56 is available. Necessary because boost atomic does not build with the latest clang.

--- src/CMake/BoostConfig.cmake
+++ src/CMake/BoostConfig.cmake
@@ -62,7 +62,14 @@

   IF(${compress_type} MATCHES "GIT")

-    SET(boost_GIT_TAG "origin/master")
+    IF(APPLE)
+      # TODO: temporary - switch git tag back to master for all
+      #       builds once boost 1.56 is available and boost atomic
+      #       library fix is verified.
+      SET(boost_GIT_TAG "origin/boost_1_54")
+    ELSE()
+      SET(boost_GIT_TAG "origin/master")
+    ENDIF()

     # TODO: fix install step
     #


make the llvm bitcode build script support more suffixes

The original script only support .cpp files, but users may give
some .c files or suffixes of other languages.

--- scripts/buildBitcode.cmake
+++ scripts/buildBitcode.cmake
@@ -30,15 +30,16 @@

 macro(build_llvm_bc_object f_temp_src)
   get_filename_component(f_abso_temp_src ${f_temp_src} ABSOLUTE)
+  get_filename_component(f_file_ext ${f_temp_src} EXT)

-  # cpp -> obj.bc
-  STRING(REPLACE ".cpp" ".obj.${LLVM_EXT}" f_temp_object ${f_abso_temp_src})
+  # file extension(.cpp .c) -> obj.bc
+  STRING(REPLACE "${f_file_ext}" ".obj.${LLVM_EXT}" f_temp_object ${f_abso_temp_src})
   # source_dir -> binary_dir
   STRING(REPLACE ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR}
       	   f_temp_object ${f_temp_object})

   # In case that the corresponding directory of binary_dir does not exist.
-  get_filename_component(f_temp_object_dir ${f_temp_object} PATH)
+  get_filename_component(f_temp_object_dir ${f_temp_object} DIRECTORY)
   if(NOT EXISTS ${f_temp_object_dir})
      file(MAKE_DIRECTORY ${f_temp_object_dir})
   endif()


removed superfluous test

removed superfluous test

--- tests/date_tests.cmake
+++ tests/date_tests.cmake
@@ -1,12 +0,0 @@
-function(date)
-
-
-
-
-
-
-datetime()
-ans(dt)
-json_print(${dt})
-
-endfunction()


TEST: fix test script for win32 and non-win32

--- Packaging/testing.cmake
+++ Packaging/testing.cmake
@@ -3,7 +3,6 @@
 #          [WORKING_DIRECTORY <dir>])

 set(testing_dir ${CMAKE_BINARY_DIR}/tests)
-
 if(EXISTS "${testing_dir}")
   execute_process(COMMAND ${CMAKE_COMMAND} -E remove_directory ${testing_dir})
   execute_process(COMMAND ${CMAKE_COMMAND} -E make_directory   ${testing_dir})
@@ -11,36 +10,33 @@
   execute_process(COMMAND ${CMAKE_COMMAND} -E make_directory   ${testing_dir})
 endif()

+set(install_package_ARGS)
+set(selftester_ARGS)
 set(pkg_extracted_dir "${testing_dir}/${PKG_STAGE_DIR}")
 if(WIN32)
-  set(extract_opts "x;${PACKAGE_OUTPUT_FILE}")
-  set(extract_cmd "${ZIP_EXECUTABLE}")
-  set(my_ext ".bat")
+  set(install_package_ARGS "x;${PACKAGE_OUTPUT_FILE}")
+  set(install_package_CMD "${ZIP_EXECUTABLE}")
+  #selftester
+  set(selftester_CMD ${pkg_extracted_dir}/tools/selftester.bat)
+  set(selftester_ARGS "/q")
 else()
-  set(extract_opts "--target;${pkg_extracted_dir}")
-  set(extract_cmd "${PACKAGE_OUTPUT_FILE}")
-  set(my_ext ".sh")
+  set(install_package_ARGS "--target;${pkg_extracted_dir};--no-progress")
+  set(install_package_CMD "${PACKAGE_OUTPUT_FILE}")
+  #selftester
+  set(selftester_CMD ${pkg_extracted_dir}/tools/selftester.sh)
+  set(selftester_ARGS)
 endif()
-
 add_test(
   NAME Tu_install_package
-  COMMAND ${extract_cmd}
-  ${extract_opts}
+  COMMAND ${install_package_CMD} ${install_package_ARGS}
   WORKING_DIRECTORY ${testing_dir}
   )

-set(Tu_selftester_ARGS)
-if(WIN32)
-  set(Tu_selftester_ARGS "/q")
-endif()
-
 add_test(
   NAME Tu_selftester
-  COMMAND ${pkg_extracted_dir}/tools/selftester${my_ext}
-  ${Tu_selftester_ARGS}
+  COMMAND ${selftester_CMD} ${selftester_ARGS}
   WORKING_DIRECTORY ${pkg_extracted_dir}
   )
-

 add_test(
   NAME Tu_build_examples


Update FindGEANT4.cmake

Update FindGEANT4.cmake

--- ndsim/build/FindGEANT4.cmake
+++ ndsim/build/FindGEANT4.cmake
@@ -15,7 +15,7 @@
 SET(GEANT4_INCLUDE_DIR ${Geant4_INCLUDE_DIR})
  #message("Geant4_INCLUDE_DIRS : ${Geant4_INCLUDE_DIRS}")

-FIND_PATH(GEANT4_LIBRARY_DIR NAMES libG4event.so             PATHS
+FIND_PATH(GEANT4_LIBRARY_DIR NAMES libG4event.so libG4event.dylib          PATHS
                                                              ${Geant4_INCLUDE_DIR}/../../lib64/
                                                              ${Geant4_INCLUDE_DIR}/../../lib/
                                                              NO_DEFAULT_PATH)


Print more variables.

Print more variables.

	* build-aux/cmake/modules/PrintCMakeInternalInfo.cmake: Do that.

Signed-off-by: Nicolas Despres <abdeb541ca46f1651c9cc594d44e707056e73d5d@gostai.com>

--- build-aux/cmake/modules/PrintCMakeInternalInfo.cmake
+++ build-aux/cmake/modules/PrintCMakeInternalInfo.cmake
@@ -60,5 +60,25 @@
   CMAKE_COMPILER_IS_GNUCXX
   CMAKE_AR
   CMAKE_RANLIB
+  CMAKE_C_IGNORE_EXTENSIONS
+  CMAKE_C_OUTPUT_EXTENSION
+  CMAKE_C_SOURCE_FILE_EXTENSIONS
+  CMAKE_CXX_IGNORE_EXTENSIONS
+  CMAKE_CXX_OUTPUT_EXTENSION
+  CMAKE_CXX_SOURCE_FILE_EXTENSIONS
+  CMAKE_EXECUTABLE_SUFFIX
+  CMAKE_FIND_LIBRARY_PREFIXES
+  CMAKE_FIND_LIBRARY_SUFFIXES
+  CMAKE_IMPORT_LIBRARY_PREFIX
+  CMAKE_IMPORT_LIBRARY_SUFFIX
+  CMAKE_LINK_LIBRARY_SUFFIX
+  CMAKE_RC_OUTPUT_EXTENSION
+  CMAKE_RC_SOURCE_FILE_EXTENSIONS
+  CMAKE_SHARED_LIBRARY_PREFIX
+  CMAKE_SHARED_LIBRARY_SUFFIX
+  CMAKE_SHARED_MODULE_PREFIX
+  CMAKE_SHARED_MODULE_SUFFIX
+  CMAKE_STATIC_LIBRARY_PREFIX
+  CMAKE_STATIC_LIBRARY_SUFFIX
   )


:lipstick:

:lipstick:


nacl.cmake: Update to support new NaCl implementation

--- cmake/nacl.cmake
+++ cmake/nacl.cmake
@@ -18,13 +18,27 @@
 set(NACL_DIR ${INCLUDEOS_ROOT}/NaCl)
 set(NACL_EXE ${NACL_DIR}/NaCl.py)
 set(NACL_SRC
-  ${NACL_DIR}/cpp_transpile_function.py
   ${NACL_DIR}/cpp_template.mustache
-  ${NACL_DIR}/cpp_resolve_values.py
-  ${NACL_DIR}/shared_constants.py
+  ${NACL_DIR}/shared.py
+  )
+set(NACL_SUBTRANS_SRC
+  ${NACL_DIR}/subtranspilers/__init__.py
+  ${NACL_DIR}/subtranspilers/function_transpiler.py
+  ${NACL_DIR}/subtranspilers/value_transpiler.py
+  )
+set(NACL_TYPEPROC_SRC
+  ${NACL_DIR}/type_processors/__init__.py
+  ${NACL_DIR}/type_processors/conntrack.py
+  ${NACL_DIR}/type_processors/function.py
+  ${NACL_DIR}/type_processors/gateway.py
+  ${NACL_DIR}/type_processors/iface.py
+  ${NACL_DIR}/type_processors/load_balancer.py
+  ${NACL_DIR}/type_processors/syslog.py
   )
 set(NACL_BIN ${CMAKE_CURRENT_BINARY_DIR}/nacl_bin/src/nacl_bin)

 install(PROGRAMS ${NACL_EXE} DESTINATION includeos/nacl)
 install(FILES ${NACL_SRC} DESTINATION includeos/nacl)
+install(FILES ${NACL_SUBTRANS_SRC} DESTINATION includeos/nacl/subtranspilers)
+install(FILES ${NACL_TYPEPROC_SRC} DESTINATION includeos/nacl/type_processors)
 install(DIRECTORY ${NACL_BIN}/ DESTINATION includeos/nacl)


BUG: update dead link for muparser sources

--- SuperBuild/CMake/External_muparser.cmake
+++ SuperBuild/CMake/External_muparser.cmake
@@ -15,7 +15,8 @@

   ExternalProject_Add(${proj}
     PREFIX ${proj}
-    URL "http://downloads.sourceforge.net/project/muparser/muparser/Version%202.2.3/muparser_v2_2_3.zip"
+    DOWNLOAD_NAME muparser_v2_2_3.zip
+    URL "https://docs.google.com/uc?export=download&id=0BzuB-ydOOoduLUNRanpDNV9iVk0"
     URL_MD5 9de40ec1dab5bd2787ee344fce5846ad
     BINARY_DIR ${MUPARSER_SB_BUILD_DIR}
     INSTALL_DIR ${SB_INSTALL_PREFIX}


reverted change of cil python file

reverted change of cil python file

--- SuperBuild/External_CCPi-Framework.cmake
+++ SuperBuild/External_CCPi-Framework.cmake
@@ -60,7 +60,7 @@
           -DPYTHON_DEST_DIR:PATH=${PYTHON_DEST}
           -DOPENMP_INCLUDES:PATH=${OPENMP_INCLUDES}
           -DCIL_VERSION:STRING=${${proj}_TAG}
-      INSTALL_COMMAND ${CMAKE_COMMAND} --build . --target install && ${CMAKE_COMMAND} -E copy_directory ${${proj}_SOURCE_DIR}/Wrappers/Python/data ${SUPERBUILD_INSTALL_DIR}/share/cil/ && ${PYTHON_EXECUTABLE} ${CMAKE_SOURCE_DIR}/patches/cil-patch.py ${${proj}_SOURCE_DIR}/Wrappers/Python/ccpi/utilities/dataexample.py ${PYTHON_DEST}/ccpi/utilities/dataexample.py
+      INSTALL_COMMAND ${CMAKE_COMMAND} --build . --target install && ${CMAKE_COMMAND} -E copy_directory ${${proj}_SOURCE_DIR}/Wrappers/Python/data ${SUPERBUILD_INSTALL_DIR}/share/cil/ && ${PYTHON_EXECUTABLE} ${CMAKE_SOURCE_DIR}/patches/cil-patch.py ${${proj}_SOURCE_DIR}/Wrappers/Python/cil/utilities/dataexample.py ${PYTHON_DEST}/cil/utilities/dataexample.py
       DEPENDS ${${proj}_DEPENDENCIES}
     )


Adjust compiler options for RHEL 8 to get openblas header files.

Use same default build settings setup function for minor RHEL releases.

--- default_build_settings.cmake
+++ default_build_settings.cmake
@@ -8,15 +8,16 @@
   set(DEFAULT_CMAKE_SHARED_LINKER_FLAGS "-lrt" PARENT_SCOPE)
 endfunction()

-function(setup_vespa_default_build_settings_rhel_7_7)
-  message("-- Setting up default build settings for rhel 7.7")
+function(setup_vespa_default_build_settings_rhel_7)
+  message("-- Setting up default build settings for rhel 7")
   set(DEFAULT_EXTRA_LINK_DIRECTORY "${VESPA_DEPS}/lib64" "/usr/lib64/llvm7.0/lib" PARENT_SCOPE)
   set(DEFAULT_EXTRA_INCLUDE_DIRECTORY "${VESPA_DEPS}/include" "/usr/include/llvm7.0" "/usr/include/openblas" PARENT_SCOPE)
   set(DEFAULT_VESPA_LLVM_VERSION "7" PARENT_SCOPE)
 endfunction()

-function(setup_vespa_default_build_settings_rhel_8_1)
-  message("-- Setting up default build settings for rhel 8.1")
+function(setup_vespa_default_build_settings_rhel_8)
+  message("-- Setting up default build settings for rhel 8")
+  set(DEFAULT_EXTRA_INCLUDE_DIRECTORY "${VESPA_DEPS}/include" "/usr/include/openblas" PARENT_SCOPE)
   set(DEFAULT_VESPA_LLVM_VERSION "8" PARENT_SCOPE)
 endfunction()

@@ -159,9 +160,9 @@
   if(VESPA_OS_DISTRO_COMBINED STREQUAL "rhel 6.10")
     setup_vespa_default_build_settings_rhel_6_10()
   elseif(VESPA_OS_DISTRO_COMBINED STREQUAL "rhel 7.7")
-    setup_vespa_default_build_settings_rhel_7_7()
+    setup_vespa_default_build_settings_rhel_7()
   elseif(VESPA_OS_DISTRO_COMBINED STREQUAL "rhel 8.1")
-    setup_vespa_default_build_settings_rhel_8_1()
+    setup_vespa_default_build_settings_rhel_8()
   elseif(VESPA_OS_DISTRO_COMBINED STREQUAL "centos 7")
     setup_vespa_default_build_settings_centos_7()
   elseif(VESPA_OS_DISTRO_COMBINED STREQUAL "centos 8")


Add explicit dependency on libatomic.

Add explicit dependency on libatomic.

--- default_build_settings.cmake
+++ default_build_settings.cmake
@@ -35,6 +35,10 @@
     set(DEFAULT_VESPA_LLVM_VERSION "12" PARENT_SCOPE)
   else()
     set(DEFAULT_VESPA_LLVM_VERSION "11" PARENT_SCOPE)
+  endif()
+  if(CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
+    set(DEFAULT_CMAKE_SHARED_LINKER_FLAGS " -latomic " PARENT_SCOPE)
+    set(DEFAULT_CMAKE_LINKER_FLAGS " -latomic " PARENT_SCOPE)
   endif()
 endfunction()


do not overwrite init files (#146)

do not overwrite init files (#146)

--- rosidl_generator_py/cmake/rosidl_generator_py_generate_interfaces.cmake
+++ rosidl_generator_py/cmake/rosidl_generator_py_generate_interfaces.cmake
@@ -68,15 +68,15 @@
   endif()
 endforeach()

+file(MAKE_DIRECTORY "${_output_path}")
+file(WRITE "${_output_path}/__init__.py" "")
+
 if(NOT "${_generated_msg_py_files} " STREQUAL " ")
   list(GET _generated_msg_py_files 0 _msg_file)
   get_filename_component(_parent_folder "${_msg_file}" DIRECTORY)
   list(APPEND _generated_msg_py_files
     "${_parent_folder}/__init__.py"
   )
-  # TODO(dirk-thomas) since this are being generated at configure time
-  # it should not be a dependency of the custom command
-  file(WRITE "${_parent_folder}/__init__.py" "")
 endif()

 if(NOT "${_generated_srv_files} " STREQUAL " ")
@@ -85,9 +85,6 @@
   list(APPEND _generated_srv_files
     "${_parent_folder}/__init__.py"
   )
-  # TODO(dirk-thomas) since this are being generated at configure time
-  # it should not be a dependency of the custom command
-  file(WRITE "${_parent_folder}/__init__.py" "")
 endif()

 set(_dependency_files "")
@@ -127,8 +124,6 @@
   TARGET_DEPENDENCIES ${target_dependencies}
 )

-file(MAKE_DIRECTORY "${_output_path}")
-file(WRITE "${_output_path}/__init__.py" "")

 if(NOT "${_generated_msg_py_files} " STREQUAL " ")
   list(GET _generated_msg_py_files 0 _msg_file)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Modules/ThirdParty/KWSys/src/KWSys/kwsysDateStamp.cmake
+++ Modules/ThirdParty/KWSys/src/KWSys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 10)

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


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Modules/ThirdParty/KWSys/src/KWSys/kwsysDateStamp.cmake
+++ Modules/ThirdParty/KWSys/src/KWSys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 04)

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


fix config.cmake

fix config.cmake

--- libzeug-config.cmake
+++ libzeug-config.cmake
@@ -61,7 +61,7 @@
 		PATHS ${HINT_PATHS}
 		DOC "The ${LIB_NAME} debug library")

-	if(${${LIB_NAME_UPPER}_LIBRARY_DEBUG})
+	if(${LIB_NAME_UPPER}_LIBRARY_DEBUG)
 		set(${LIB_NAME_UPPER}_LIBRARIES optimized ${${LIB_NAME_UPPER}_LIBRARY} debug ${${LIB_NAME_UPPER}_LIBRARY_DEBUG})
 	else()
 		set(${LIB_NAME_UPPER}_LIBRARIES ${${LIB_NAME_UPPER}_LIBRARY})


cmake: set CMAKE_CXX_FLAGS in FBCompilerSettingsUnix.cmake

Summary:
It looks like the various CMAKE_CXX_FLAGS_* are simply ineffective, and I'm not
sure why, setting CMAKE_CXX_FLAGS does work though, and CMake appears to add
some release/debug flags to it when generating Ninja files.

Reviewed By: fanzeyi

Differential Revision: D27862117

fbshipit-source-id: a89f6182b5bae9a087f8fcfd4c5f9526f91e2adf

--- build/fbcode_builder/CMake/FBCompilerSettingsUnix.cmake
+++ build/fbcode_builder/CMake/FBCompilerSettingsUnix.cmake
@@ -6,6 +6,4 @@
 # to these shared compiler settings in order to avoid accidentally
 # breaking a build in another project!

-set(CMAKE_CXX_FLAGS_COMMON "-g -Wall -Wextra -Wno-deprecated -Wno-deprecated-declarations")
-set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} ${CMAKE_CXX_FLAGS_COMMON}")
-set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} ${CMAKE_CXX_FLAGS_COMMON} -O3")
+set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -Wall -Wextra -Wno-deprecated -Wno-deprecated-declarations")


cmake: Use tar.xz source package generator

Signed-off-by: Andreas Schneider <5be00ddc76278cf6077f5047ca3384a88460c671@cryptomilk.org>
(cherry picked from commit 1f3a9105ffecb93123eed7a86bc74ac44faa6852)

--- CPackConfig.cmake
+++ CPackConfig.cmake
@@ -18,7 +18,7 @@

 ### source generator
-set(CPACK_SOURCE_GENERATOR "TGZ")
+set(CPACK_SOURCE_GENERATOR "TXZ")
 set(CPACK_SOURCE_IGNORE_FILES "~$;[.]swp$;/[.]svn/;/[.]git/;.gitignore;/build/;/obj/;tags;cscope.*")
 set(CPACK_SOURCE_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}")


enable our own ctest dashboard

enable our own ctest dashboard

--- CTestConfig.cmake
+++ CTestConfig.cmake
@@ -5,9 +5,9 @@
 ##   ENABLE_TESTING()
 ##   INCLUDE(CTest)
 set(CTEST_PROJECT_NAME "Eigen")
-set(CTEST_NIGHTLY_START_TIME "05:00:00 UTC")
+set(CTEST_NIGHTLY_START_TIME "06:00:00 UTC")

 set(CTEST_DROP_METHOD "http")
-set(CTEST_DROP_SITE "my.cdash.org")
-set(CTEST_DROP_LOCATION "/submit.php?project=Eigen")
+set(CTEST_DROP_SITE "eigen.tuxfamily.org")
+set(CTEST_DROP_LOCATION "/CDash/submit.php?project=Eigen")
 set(CTEST_DROP_SITE_CDASH TRUE)


changed models hash

changed models hash

--- CTestConfig.cmake
+++ CTestConfig.cmake
@@ -16,7 +16,7 @@

 set(CTEST_PROJECT_NAME "Embree")
 set(CTEST_NIGHTLY_START_TIME "22:00:00 UTC")
-set(TEST_MODELS_HASH 1890ce6da5ff9fb258d54c70420c0b0bf75b9293)
+set(TEST_MODELS_HASH 3d3c2deab84677efdf061c64fc623ed955068fb4)

 IF (NOT CTEST_DROP_SITE)
   set(CTEST_DROP_METHOD "http")


dashboard: set the project name

dashboard: set the project name

--- CTestConfig.cmake
+++ CTestConfig.cmake
@@ -4,7 +4,7 @@
 ## # The following are required to uses Dart and the Cdash dashboard
 ##   ENABLE_TESTING()
 ##   INCLUDE(CTest)
-#set(CTEST_PROJECT_NAME "MatViz")
+set(CTEST_PROJECT_NAME "MatViz")
 set(CTEST_NIGHTLY_START_TIME "21:00:00 EDT")

 set(CTEST_DROP_METHOD "http")


refs #5940 bump version of jemalloc whose warnings we can ignore

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

--- CTestCustom.cmake
+++ CTestCustom.cmake
@@ -233,7 +233,7 @@
   # don't complain about clang missing warnings from xz code
   "clang: warning: unknown warning option"
   # don't complain about warnings in jemalloc source
-  "jemalloc-3.2.0/src"
+  "jemalloc-3.3.0/src"
   "jemalloc/internal"
   # don't complain about ranlib or libtool on empty archive
   "has no symbols"


Update copyright

Update copyright

--- android-ndk-r15c-api-21-arm64-v8a-neon-clang-libcxx.cmake
+++ android-ndk-r15c-api-21-arm64-v8a-neon-clang-libcxx.cmake
@@ -1,4 +1,5 @@
 # Copyright (c) 2015, Ruslan Baratov
+# Copyright (c) 2017, Robert Nitsch
 # All rights reserved.

 if(DEFINED POLLY_ANDROID_NDK_R15C_API_21_ARM64_V8A_NEON_CLANG_LIBCXX_CMAKE_)


Remove the flag out of the variable names so that the C++ flags can also be added there

--- cmake/Modules/CppUTestWarningFlags.cmake
+++ cmake/Modules/CppUTestWarningFlags.cmake
@@ -16,10 +16,10 @@

     macro(check_and_append_cxx_warning_flags)
       foreach (flag ${ARGN})
-        check_cxx_compiler_flag("-${flag}" WARNING_CXX_FLAG_${flag})
-        if (WARNING_CXX_FLAG_${flag})
+        check_cxx_compiler_flag("-${flag}" WARNING_CXX_FLAG_TO_CHECK)
+        if (WARNING_CXX_FLAG_TO_CHECK)
             set(CPPUTEST_CXX_WARNING_FLAGS "${CPPUTEST_CXX_WARNING_FLAGS} -${flag}")
-        endif (WARNING_CXX_FLAG_${flag})
+          endif (WARNING_CXX_FLAG_TO_CHECK)
       endforeach (flag)
     endmacro(check_and_append_cxx_warning_flags)


Improve C++14 test for clang

Improve C++14 test for clang

--- cmake/checks/check_01_cxx_features.cmake
+++ cmake/checks/check_01_cxx_features.cmake
@@ -132,7 +132,10 @@
       {
         auto func();
       };
-      int main() {}
+      int main()
+      {
+        foo bar;
+      }
       "
       DEAL_II_HAVE_CXX14_CLANGAUTODEBUG_BUG_OK)


Remove debug output

Remove debug output

CMake 2.8.12.1 on windows does not support empty messages

--- cmake/modules/VisionarayUsePackage.cmake
+++ cmake/modules/VisionarayUsePackage.cmake
@@ -25,7 +25,6 @@
         endif()
     endif()

-message(${pkg_INCDIRS})
     include_directories(SYSTEM ${pkg_INCDIRS})

     #


Silence OpenGL deprecation warnings on macOS

--- CMake/Common.cmake
+++ CMake/Common.cmake
@@ -77,6 +77,7 @@

 if(APPLE)
     set(CMAKE_MACOSX_RPATH 1)
+	add_definitions(-DGL_SILENCE_DEPRECATION)
 endif()

 set (CMAKE_CXX_STANDARD 11)


remove obsolete stuff from CMake module

remove obsolete stuff from CMake module

--- fastrtps_cmake_module/cmake/Modules/FindFastRTPS.cmake
+++ fastrtps_cmake_module/cmake/Modules/FindFastRTPS.cmake
@@ -16,22 +16,10 @@
 #
 # CMake module for finding eProsima FastRTPS.
 #
-# Input variables:
-#
-# - FASTRTPSHOME (optional): When specified, header files and libraries
-#   will be searched for in `${FASTRTPSHOME}/include`
-#   and `${FASTRTPSHOME}/lib` respectively.
-#
 # Output variables:
 #
 # - FastRTPS_FOUND: flag indicating if the package was found
 # - FastRTPS_INCLUDE_DIR: Paths to the header files
-# - FastRTPS_HOME: Root directory for the eProsima FastRTPS install. Might be
-#   not set.
-# - FastRTPS_LIBRARIES: Name to the C++ libraries including the path
-# - FastRTPS_LIBRARY_DIRS: Paths to the libraries
-# - FastRTPS_LIBRARY_DIR: Path to libraries; guaranteed to be a single path
-# - FastRTPS_DEFINITIONS: Definitions to be passed on
 #
 # Example usage:
 #
@@ -45,24 +33,8 @@

 set(FastRTPS_FOUND FALSE)

-# -----------------------------------------
-# Detect environment variable
-# -----------------------------------------
-if($ENV{FASTRPCHOME})
-    set(FastRTPS_HOME $ENV{FASTRPCHOME})
-endif()
-
-# -----------------------------------------
-# Search for eProsima FastRTPS include DIR
-# -----------------------------------------
-set(_fastrtps_INCLUDE_SEARCH_DIRS "")
-
-if(FastRTPS_HOME)
-    list(APPEND _fastrtps_INCLUDE_SEARCH_DIRS ${FastRTPS_HOME}/include)
-endif()
-
 find_path(FastRTPS_INCLUDE_DIR
-    NAMES fastrtps/)
+  NAMES fastrtps/)

 include(FindPackageHandleStandardArgs)
 find_package_handle_standard_args(FastRTPS


no reason to mark_as_advanced these variables

--- FindICU.cmake
+++ FindICU.cmake
@@ -159,11 +159,6 @@
 mark_as_advanced(
     ICU_INCLUDE_DIRS
     ICU_LIBRARIES
-    ICU_DEFINITIONS
-    ICU_VERSION
-    ICU_MAJOR_VERSION
-    ICU_MINOR_VERSION
-    ICU_PATCH_VERSION
 )

 # IN (args)


Fixing OpenSSL being mis-identified as not available

* Case sensitive issue with OPENSSL_FOUND flag; FindOpenSSL.cmake
  is always uppercase.

--- cpp-driver/cmake/modules/CppDriver.cmake
+++ cpp-driver/cmake/modules/CppDriver.cmake
@@ -579,14 +579,14 @@
   if(WIN32 AND OPENSSL_VERSION) # Store the current version of OpenSSL to prevent corruption
     set(SAVED_OPENSSL_VERSION ${OPENSSL_VERSION})
   endif()
-  find_package(OpenSSL QUIET)
-  if(WIN32 AND NOT OpenSSL_FOUND)
+  find_package(OpenSSL)
+  if(WIN32 AND NOT OPENSSL_FOUND)
     message(STATUS "Unable to Locate OpenSSL: Third party build step will be performed")
     if(SAVED_OPENSSL_VERSION)
       set(OPENSSL_VERSION ${SAVED_OPENSSL_VERSION})
     endif()
     include(ExternalProject-OpenSSL)
-  elseif(NOT OpenSSL_FOUND)
+  elseif(NOT OPENSSL_FOUND)
     message(FATAL_ERROR "Unable to Locate OpenSSL: Ensure OpenSSL is installed in order to build the driver")
   else()
     message(STATUS "OpenSSL version: v${OPENSSL_VERSION}")


Using LIST APPEND in FindFFMPEG

Using LIST APPEND in FindFFMPEG

--- FindFFMPEG.cmake
+++ FindFFMPEG.cmake
@@ -75,7 +75,7 @@
    IF ( TMP_ )
       message( "found: " ${TMP_} )
       MATH( EXPR INC_SUCCESS ${INC_SUCCESS}+1 )
-      SET( FFMPEG_INCLUDE_DIR ${FFMPEG_INCLUDE_DIR} ${TMP_} )
+      LIST( APPEND FFMPEG_INCLUDE_DIR ${TMP_} )
    ENDIF ( TMP_ )
    SET( TMP_ TMP-NOTFOUND )
 ENDFOREACH( INC_ )


Improve libcheck finding

Improve libcheck finding

This patch allows the libcheck package to provide two targets:

  - Check::LibCompat
  - Check::LibCheck

The libcompat is needed on Windows so should be defined as a target. The
dependencies are correctly defined so that the external project is built
before the libraries are used. This patch also adds the dependent
system libraries into the LIBCHECK_LIBRARIES variable if the user would
like to use that.

--- FindLibCheck.cmake
+++ FindLibCheck.cmake
@@ -8,8 +8,9 @@
 # IMPORTED Targets
 # ^^^^^^^^^^^^^^^^
 #
-# This module defines :prop_tgt:`IMPORTED` target ``LIBCHECK::LIBCHECK``, if
-# LIBCHECK has been found.
+# This module defines :prop_tgt:`IMPORTED` target ``Check::LibCheck``, if
+# LIBCHECK has been found. On certain systems the
+# :prop_tgt:`IMPORTED` target ``Check::LibCompat`` is also defined
 #
 # Result Variables
 # ^^^^^^^^^^^^^^^^
@@ -23,7 +24,6 @@
 #   LIBCHECK_FOUND             - True if check library found.
 #   LIBCHECK_VERSION           - the version of libcheck that will be built from source
 #   LIBCHECK_MD5_HASH          - the hash of the downloaded source code
-#   LIBCHECK_BUILT_FROM_SOURCE - True if the check library was built from source
 #
 # Hints
 # ^^^^^
@@ -31,77 +31,150 @@
 # A user may set ``LIBCHECK_ROOT`` to a check installation root to tell this
 # module where to look.

-set(LIBCHECK_VERSION 0.10.0 CACHE STRING
-  "The version of Check unit testing framework to build and include statically")
-set_property(CACHE LIBCHECK_VERSION PROPERTY VALUE ${LIBCHECK_VERSION})
-mark_as_advanced(LIBCHECK_VERSION)
-
-set(LIBCHECK_MD5_HASH 53c5e5c77d090e103a17f3ed7fd7d8b8 CACHE STRING
-  "The hash of Check unit testing framework archive to be downloaded")
-set_property(CACHE LIBCHECK_MD5_HASH PROPERTY VALUE ${LIBCHECK_MD5_HASH})
-mark_as_advanced(LIBCHECK_MD5_HASH)
+include(FindPackageHandleStandardArgs)

 find_path(LIBCHECK_INCLUDE_DIRS
   NAMES check.h
   PATHS ${LIBCHECK_ROOT}/include/
 )
-find_library(LIBCHECK_LIBRARIES check compat
+find_library(LIBCHECK_LIBRARY
+  NAMES check
   PATHS ${LIBCHECK_ROOT}/lib/
 )
-include(FindPackageHandleStandardArgs)
-find_package_handle_standard_args(LibCheck DEFAULT_MSG LIBCHECK_LIBRARIES LIBCHECK_INCLUDE_DIRS)
+find_package_handle_standard_args(LibCheck DEFAULT_MSG LIBCHECK_LIBRARY LIBCHECK_INCLUDE_DIRS)

-set(LIBCHECK_BUILT_FROM_SOURCE NO)
-if((NOT LIBCHECK_FOUND))
-    if(CMAKE_ENABLE_THIRD_PARTY_OUTPUT)
-      set(THIRD_PARTY_LOGGING 0)
-    else()
-      set(THIRD_PARTY_LOGGING 1)
-    endif()
-    if(CMAKE_ENABLE_THIRD_PARTY_DIR)
-      set(THIRD_PARTY_DIR "${CMAKE_ENABLE_THIRD_PARTY_DIR}")
-    else()
-      set(THIRD_PARTY_DIR third-party)
-    endif()
-    set(LIBCHECK_BUILT_FROM_SOURCE YES)
-    include(ExternalProject)
-    message(STATUS "Check Unit Testing Framework Version - ${LIBCHECK_VERSION}")
-    ExternalProject_Add(libcheck
-        URL "https://downloads.sourceforge.net/project/check/check/${LIBCHECK_VERSION}/check-${LIBCHECK_VERSION}.tar.gz"
-        URL_MD5 ${LIBCHECK_MD5_HASH}
-        PREFIX ${THIRD_PARTY_DIR}
-        BUILD_IN_SOURCE 1
-        CMAKE_ARGS
-          "-DCMAKE_BUILD_TYPE=Release"
-          "-DCMAKE_C_COMPILER=${CMAKE_C_COMPILER}"
-          "-DCMAKE_INSTALL_PREFIX=<INSTALL_DIR>"
-        LOG_DOWNLOAD ${THIRD_PARTY_LOGGING}
-        LOG_UPDATE ${THIRD_PARTY_LOGGING}
-        LOG_CONFIGURE ${THIRD_PARTY_LOGGING}
-        LOG_BUILD ${THIRD_PARTY_LOGGING}
-        LOG_TEST ${THIRD_PARTY_LOGGING}
-        LOG_INSTALL ${THIRD_PARTY_LOGGING})
-    ExternalProject_Get_Property(libcheck INSTALL_DIR)
-    set(LIBCHECK_ROOT ${INSTALL_DIR})
-    unset(INSTALL_DIR)
-    set(LIBCHECK_INCLUDE_DIRS "${LIBCHECK_ROOT}/include")
-    file(MAKE_DIRECTORY ${LIBCHECK_ROOT}/include/)
-    find_path(LIBCHECK_INCLUDE_DIRS
-      NAMES check.h
-      PATHS ${LIBCHECK_ROOT}/include/
-    )
-    find_library(LIBCHECK_LIBRARIES check compat
-      PATHS ${LIBCHECK_ROOT}/lib/
-    )
-    include(FindPackageHandleStandardArgs)
-    find_package_handle_standard_args(LibCheck DEFAULT_MSG LIBCHECK_LIBRARIES LIBCHECK_INCLUDE_DIRS)
+if(WIN32)
+  find_path(LIBCOMPAT_INCLUDE_DIRS
+    NAMES compat.h
+    PATHS ${LIBCHECK_ROOT}/include/
+  )
+  find_library(LIBCOMPAT_LIBRARY
+    NAMES compat
+    PATHS ${LIBCHECK_ROOT}/lib/
+  )
+  find_package_handle_standard_args(LibCompat DEFAULT_MSG LIBCOMPAT_LIBRARY LIBCOMPAT_INCLUDE_DIRS)
 endif()

-mark_as_advanced(LIBCHECK_INCLUDE_DIRS LIBCHECK_LIBRARIES)
+# Build from source if not found
+if(NOT LIBCHECK_FOUND)
+  # We need a version of libcheck to build if not found
+  set(LIBCHECK_VERSION 0.10.0 CACHE STRING
+    "The version of Check unit testing framework to build and include statically")
+  set_property(CACHE LIBCHECK_VERSION PROPERTY VALUE ${LIBCHECK_VERSION})
+  mark_as_advanced(LIBCHECK_VERSION)

-if(NOT TARGET LIBCHECK::LIBCHECK)
-  add_library(LIBCHECK::LIBCHECK UNKNOWN IMPORTED)
-  set_target_properties(LIBCHECK::LIBCHECK PROPERTIES
-    IMPORTED_LOCATION "${LIBCHECK_LIBRARIES}"
+  # The hash of the downloaded data
+  set(LIBCHECK_MD5_HASH 53c5e5c77d090e103a17f3ed7fd7d8b8 CACHE STRING
+    "The hash of Check unit testing framework archive to be downloaded")
+  set_property(CACHE LIBCHECK_MD5_HASH PROPERTY VALUE ${LIBCHECK_MD5_HASH})
+  mark_as_advanced(LIBCHECK_MD5_HASH)
+
+  # Remove the previously set variables
+  unset(LIBCHECK_LIBRARY)
+  unset(LIBCHECK_INCLUDE_DIRS)
+  unset(LIBCOMPAT_LIBRARY)
+  unset(LIBCOMPAT_INCLUDE_DIRS)
+
+  # Determine if the user would like to see the build
+  if(CMAKE_ENABLE_THIRD_PARTY_OUTPUT)
+    set(THIRD_PARTY_LOGGING 0)
+  else()
+    set(THIRD_PARTY_LOGGING 1)
+  endif()
+
+  # The user can specify an output location
+  if(CMAKE_ENABLE_THIRD_PARTY_DIR)
+    set(THIRD_PARTY_DIR "${CMAKE_ENABLE_THIRD_PARTY_DIR}")
+  else()
+    set(THIRD_PARTY_DIR third-party)
+  endif()
+
+  # Build libcheck
+  include(ExternalProject)
+  message(STATUS "Building check from source - ${LIBCHECK_VERSION}")
+  ExternalProject_Add(libcheck
+    URL "https://downloads.sourceforge.net/project/check/check/${LIBCHECK_VERSION}/check-${LIBCHECK_VERSION}.tar.gz"
+    URL_MD5 ${LIBCHECK_MD5_HASH}
+    PREFIX ${THIRD_PARTY_DIR}
+    BUILD_IN_SOURCE 1
+    CMAKE_ARGS
+      "-DCMAKE_BUILD_TYPE=Release"
+      "-DCMAKE_C_COMPILER=${CMAKE_C_COMPILER}"
+      "-DCMAKE_INSTALL_PREFIX=<INSTALL_DIR>"
+    LOG_DOWNLOAD ${THIRD_PARTY_LOGGING}
+    LOG_UPDATE ${THIRD_PARTY_LOGGING}
+    LOG_CONFIGURE ${THIRD_PARTY_LOGGING}
+    LOG_BUILD ${THIRD_PARTY_LOGGING}
+    LOG_TEST ${THIRD_PARTY_LOGGING}
+    LOG_INSTALL ${THIRD_PARTY_LOGGING})
+
+  # Set up the root of the project
+  ExternalProject_Get_Property(libcheck INSTALL_DIR)
+  set(LIBCHECK_ROOT ${INSTALL_DIR})
+  unset(INSTALL_DIR)
+
+  # Create the folders so that the find_package command succeeds
+  file(MAKE_DIRECTORY ${LIBCHECK_ROOT}/include/)
+  file(MAKE_DIRECTORY ${LIBCHECK_ROOT}/lib/)
+
+  # Set the include directories
+  set(LIBCHECK_INCLUDE_DIRS "${LIBCHECK_ROOT}/include")
+
+  # We cannot use find_libary here because the libcheck isn't actually built until build time so will fail
+  if (WIN32 AND MINGW)
+    set(LIBCHECK_LIBRARY "${LIBCHECK_ROOT}/lib/libcheck.a")
+    set(LIBCOMPAT_LIBRARY "${LIBCHECK_ROOT}/lib/libcompat.a")
+    set(LIBCOMPAT_INCLUDE_DIRS ${LIBCHECK_INCLUDE_DIRS})
+  elseif (WIN32)
+    set(LIBCHECK_LIBRARY "${LIBCHECK_ROOT}/lib/check.lib;")
+    set(LIBCOMPAT_LIBRARY "${LIBCHECK_ROOT}/lib/compat.lib")
+    set(LIBCOMPAT_INCLUDE_DIRS ${LIBCHECK_INCLUDE_DIRS})
+  else()
+    set(LIBCHECK_LIBRARY "${LIBCHECK_ROOT}/lib/libcheck.a")
+  endif()
+
+  # Do the normal finding of the package
+  find_package_handle_standard_args(LibCheck DEFAULT_MSG LIBCHECK_LIBRARY LIBCHECK_INCLUDE_DIRS)
+  if(WIN32)
+    find_package_handle_standard_args(LibCompat DEFAULT_MSG LIBCOMPAT_LIBRARY LIBCOMPAT_INCLUDE_DIRS)
+  endif()
+endif()
+
+# Set up the libraries list correctly with all dependencies
+set(LIBCHECK_LIBRARIES ${LIBCHECK_LIBRARY})
+if(NOT LIBCOMPAT_FOUND)
+  list(APPEND LIBCHECK_LIBRARIES ${LIBCOMPAT_LIBRARY})
+endif()
+find_package(LibM)
+if (LIBM_FOUND)
+  list(APPEND LIBCHECK_LIBRARIES ${LIBM_LIBRARIES})
+endif()
+find_package(LibRt)
+if (LIBRT_FOUND)
+  list(APPEND LIBCHECK_LIBRARIES ${LIBRT_LIBRARIES})
+endif()
+
+# Make these variables as advanced as they shouldn't really be modified
+mark_as_advanced(LIBCHECK_BUILT_FROM_SOURCE LIBCHECK_INCLUDE_DIRS LIBCHECK_LIBRARIES)
+
+# Set up the imported target for libcheck
+if(NOT TARGET Check::LibCheck)
+  add_library(Check::LibCheck STATIC IMPORTED)
+  set_target_properties(Check::LibCheck PROPERTIES
+    IMPORTED_LOCATION ${LIBCHECK_LIBRARY}
     INTERFACE_INCLUDE_DIRECTORIES "${LIBCHECK_INCLUDE_DIRS}")
+  add_dependencies(Check::LibCheck libcheck)
 endif()
+
+# Set up the imported target for libcompat if found
+if((LIBCOMPAT_LIBRARY) AND (NOT TARGET Check::LibCompat))
+  add_library(Check::LibCompat STATIC IMPORTED)
+  set_target_properties(Check::LibCompat PROPERTIES
+    IMPORTED_LOCATION ${LIBCOMPAT_LIBRARY}
+    INTERFACE_INCLUDE_DIRECTORIES "${LIBCOMPAT_INCLUDE_DIRS}")
+  add_dependencies(Check::LibCompat libcheck)
+endif()
+
+# Remove the library variables as the user can use the IMPORTED_* variable from the imported target libraries
+unset(LIBCHECK_LIBRARY)
+unset(LIBCOMPAT_LIBRARY)


GithubInfo: provide main github page

GithubInfo: provide main github page

--- GithubInfo.cmake
+++ GithubInfo.cmake
@@ -6,6 +6,7 @@
 # CI_ROOT_URL: The travis-ci.org URL for the root remote
 # CI_ROOT_PNG: The travis-ci.org status png for the root remote
 # ${UPPER_PROJECT_NAME}_ISSUES_URL: The URL for tickets on the root remote
+# ${UPPER_PROJECT_NAME}_URL: The URL for the project, unless set already

 include(GitInfo)

@@ -41,4 +42,8 @@
     string(REPLACE ".git" "/issues"
            ${UPPER_PROJECT_NAME}_ISSUES_URL ${GIT_ROOT_URL})
   endif()
+  if(NOT ${UPPER_PROJECT_NAME}_URL)
+    string(REGEX REPLACE ".*(github.com[/[a-zA-Z]+).*" "https://\\1"
+      ${UPPER_PROJECT_NAME}_URL ${GIT_ROOT_URL})
+  endif()
 endif()


CMake: Print a hint on how to get the help message in the autopilot macro

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

--- deal.II/cmake/macros/macro_deal_ii_invoke_autopilot.cmake
+++ deal.II/cmake/macros/macro_deal_ii_invoke_autopilot.cmake
@@ -169,6 +169,8 @@
     IF(NOT USAGE_PRINTED)
       INCLUDE(${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/print_usage.cmake)
       SET(USAGE_PRINTED TRUE CACHE INTERNAL "")
+    ELSE()
+      MESSAGE(STATUS "Run   $ make help   to print a detailed help message")
     ENDIF()

   ENDIF()


CELIX-237: small change in find ffi.h for macport to support older cmake versions

--- cmake/FindFFI.cmake
+++ cmake/FindFFI.cmake
@@ -32,11 +32,9 @@

 #NOTE on OSX ffi.h from macport is located at /opt/local/lib/libffi-<version>/ffi.h
 #Using FFI_LIBRARY location as hint to find it
-get_filename_component(FFI_LIB_DIR ${FFI_LIBRARY} DIRECTORY)
 find_path(FFI_INCLUDE_DIR ffi.h
-		HINTS ${FFI_LIB_DIR}/*
+		HINTS /opt/local/lib/*
         PATH_SUFFIXES include include/ffi)
-unset(FFI_LIB_DIR)

 find_path(FFI_INCLUDE_DIR ffi.h
 		PATHS $ENV{FFI_DIR} ${FFI_DIR} /usr /usr/local /opt/local


Enable GSL tests (reverts part of changeset 88c50cd078dd).

--- cmake/FindGSL.cmake
+++ cmake/FindGSL.cmake
@@ -160,7 +160,6 @@
   ENDIF(UNIX)
 ENDIF(WIN32)

-set(GSL_LIBRARIES "")

 IF(GSL_LIBRARIES)
   IF(GSL_INCLUDE_DIR OR GSL_CXX_FLAGS)


New version: 0.3.14

New version: 0.3.14

--- VERSION.cmake
+++ VERSION.cmake
@@ -1,3 +1,3 @@
 SET(HAWKEY_MAJOR "0")
 SET(HAWKEY_MINOR "3")
-SET(HAWKEY_PATCH "13")
+SET(HAWKEY_PATCH "14")


updating deprecated tribits warning

updating deprecated tribits warning

--- PackagesList.cmake
+++ PackagesList.cmake
@@ -8,4 +8,4 @@
   DataTransferKit         .     SS
   )

-PACKAGE_DISABLE_ON_PLATFORMS(DataTransferKit Windows)
+TRIBITS_DISABLE_PACKAGE_ON_PLATFORMS(DataTransferKit Windows)


Update mongodb and ngx_dyups dependencies.

--- build/cmake/versions.cmake
+++ build/cmake/versions.cmake
@@ -46,12 +46,12 @@
 set(LUA_RESTY_LOGGER_SOCKET_HASH 6d7273438100ddcdfa57bdbf1a8c3a01)
 set(LUA_RESTY_SHCACHE_VERSION fb2e275c2cdca08eaa34a7b73375e41ac3eff200)
 set(LUA_RESTY_SHCACHE_HASH 5d3cbcf8fbad1954cdcb3826afa41afe)
-set(MONGODB_VERSION 3.0.10)
-set(MONGODB_HASH 11bbde5690a4bf8ecab11983d0c65159)
+set(MONGODB_VERSION 3.0.11)
+set(MONGODB_HASH ce20c4caac31c49aaf10ca44c703a9ed)
 set(MORA_VERSION fea22d544a961ef5cd66dde405cf452b1ae33d2c)
 set(MORA_HASH 1e9c63acbbb0795ed00820a59c6cdcbc)
-set(NGX_DYUPS_VERSION df1301c7458752fdbc21b9bfa913e13dc56cd855)
-set(NGX_DYUPS_HASH 723ca4835a9557b92d50710b706e6caa)
+set(NGX_DYUPS_VERSION 8c3ef150538c3fd643f9e47dd94df4722c8c3e4a)
+set(NGX_DYUPS_HASH 95de90f77a5bc08c6d653cdc45d3535c)
 set(NGX_TXID_VERSION f1c197cb9c42e364a87fbb28d5508e486592ca42)
 set(NGX_TXID_HASH 408ee86eb6e42e27a51514f711c41d6b)
 set(OPENRESTY_VERSION 1.9.7.4)


Add command line arguments to Rscript to remove local options

The local user settings are suppressed, to ensure that the tests run
just what is intended without user setting having potential side
effects during test execution.

--- CMake/sitkAddTest.cmake
+++ CMake/sitkAddTest.cmake
@@ -229,7 +229,8 @@
     return()
   endif()

-  set(command "${RSCRIPT_EXECUTABLE}")
+  set(command "${RSCRIPT_EXECUTABLE}" "--no-save" "--no-restore"
+  "--no-site-file" "--no-init-file")

   # add extra command which may be needed on some systems
   if(CMAKE_OSX_ARCHITECTURES)


Fix bug of missing JAR_FILE variable

Fix bug of missing JAR_FILE variable

Change-Id: I1822a98f4add76e618f7a8077e60e03701341f8f

--- CMake/sitkAddTest.cmake
+++ CMake/sitkAddTest.cmake
@@ -165,6 +165,7 @@
   # the root is with out extension or path, it is also assumed to the the name of the main class
   get_filename_component( _java_class ${java_file} NAME_WE )
   set( _java_file_class "${_java_class}.class" )
+  set(JAR_FILE "simpleitk-${SimpleITK_VERSION}.jar")  # from target?

   set( _JAVA_LIBRARY_PATH  "$<TARGET_FILE_DIR:SimpleITKJava_JAVA>")
   if(WIN32)


ENH: By default, when compiling the project in Superbuild, the libraries are built statically.

--- SuperBuild.cmake
+++ SuperBuild.cmake
@@ -63,7 +63,7 @@
 option(USE_SYSTEM_ITK "Build using an externally defined version of ITK" OFF)
 option(USE_SYSTEM_SlicerExecutionModel "Build using an externally defined version of SlicerExecutionModel"  OFF)
 option(USE_SYSTEM_VTK "Build using an externally defined version of VTK" OFF)
-option(BUILD_SHARED_LIBS "Build shared libraries" ON)
+option(BUILD_SHARED_LIBS "Build shared libraries" OFF)
 #------------------------------------------------------------------------------
 # ${LOCAL_PROJECT_NAME} dependency list
 #------------------------------------------------------------------------------


ffmpeg/4.x: update FFmpeg plugin

ffmpeg/4.x: update FFmpeg plugin

--- 3rdparty/ffmpeg/ffmpeg.cmake
+++ 3rdparty/ffmpeg/ffmpeg.cmake
@@ -1,8 +1,8 @@
-# Binaries branch name: ffmpeg/master_20190910
-# Binaries were created for OpenCV: bea2c7545243ba2dabce6badc94dd55894a8e5ca
-ocv_update(FFMPEG_BINARIES_COMMIT "197f87f7e811a9ded35d989b37e50501ff6afaa4")
-ocv_update(FFMPEG_FILE_HASH_BIN32 "ab380c9dde361f30dd3604f88eef6c48")
-ocv_update(FFMPEG_FILE_HASH_BIN64 "90260a4da737fc045c9279567313ee9d")
+# Binaries branch name: ffmpeg/master_20191119
+# Binaries were created for OpenCV: 318cba4ce37319ba0b0870aab384d5dc066bb124
+ocv_update(FFMPEG_BINARIES_COMMIT "a66a24e9f410ae05da4baeeb8b451912664ce49c")
+ocv_update(FFMPEG_FILE_HASH_BIN32 "5de6044cad9398549e57bc46fc13908d")
+ocv_update(FFMPEG_FILE_HASH_BIN64 "55c0bc8ad27db00116fabf06508de196")
 ocv_update(FFMPEG_FILE_HASH_CMAKE "ad57c038ba34b868277ccbe6dd0f9602")

 function(download_win_ffmpeg script_var)


Add new data download service

Add new data download service

Replace old NLM servers with AWS S3 mirrored data service.

--- CMake/sitkExternalData.cmake
+++ CMake/sitkExternalData.cmake
@@ -34,10 +34,7 @@
   list(APPEND ExternalData_URL_TEMPLATES

     # Data mirrored from SimpleITKExternalData repository
-    "https://erie.nlm.nih.gov/SimpleITKExternalData/%(algo)/%(hash)"
-
-    # Data published by MIDAS
-    "https://placid.nlm.nih.gov/api/rest?method=midas.bitstream.download&checksum=%(hash)&algorithm=%(algo)"
+    "https://s3.amazonaws.com/simpleitk/public/%(algo)/%(hash)"

     # Data published on GitHub Pages
     "https://simpleitk.github.io/SimpleITKExternalData/%(algo)/%(hash)"


Make fix_repo_update do nothing if version less than 3.2.0.

--- cmake/Utils.cmake
+++ cmake/Utils.cmake
@@ -31,12 +31,14 @@
 # Workaround for: ExternalProject: detect if SCM source changed before triggering subsequent steps.
 # https://gitlab.kitware.com/cmake/cmake/issues/15914
 function(fix_repo_update name)
-    # internal function available since cmake 2.8.9
-    _ep_get_step_stampfile(${name} skip-update skip-update_stamp_file)
+    if("${CMAKE_VERSION}" VERSION_GREATER 3.2.0)
+        # internal function available since cmake 2.8.9
+        _ep_get_step_stampfile(${name} skip-update skip-update_stamp_file)

-    ExternalProject_Add_Step(${name}
-        skip-workaround
-        DEPENDEES skip-update
-        COMMAND ${CMAKE_COMMAND} -E touch "${skip-update_stamp_file}"
-        )
+        ExternalProject_Add_Step(${name}
+            skip-workaround
+            DEPENDEES skip-update
+            COMMAND ${CMAKE_COMMAND} -E touch "${skip-update_stamp_file}"
+            )
+    endif()
 endfunction()


Added headless define for unittests (ORYOL_UNITTESTS_HEADLESS)

--- cmake/oryol.cmake
+++ cmake/oryol.cmake
@@ -20,6 +20,7 @@
     option(ORYOL_UNITTESTS "Enable unit tests" ON)
 endif()
 option(ORYOL_UNITTESTS_RUN_AFTER_BUILD "Automatically run unit tests after building" OFF)
+option(ORYOL_UNITTESTS_HEADLESS "If enabled don't run tests which require a display" OFF)
 option(ORYOL_EXCEPTIONS "Enable C++ exceptions" OFF)
 option(ORYOL_ALLOCATOR_DEBUG "Enable allocator debugging code (slow)" OFF)
 option(ORYOL_SAMPLES "Compile sample programs" ON)
@@ -96,6 +97,11 @@
     endif()
     if (ORYOL_UNITTESTS)
         add_definitions(-DORYOL_UNITTESTS=1)
+        if (ORYOL_UNITTESTS_HEADLESS)
+            add_definitions(-DORYOL_UNITTESTS_HEADLESS=1)
+        else()
+            add_definitions(-DORYOL_UNITTESTS_HEADLESS=0)
+        endif()
     else()
         add_definitions(-DORYOL_UNITTESTS=0)
     endif()


cmake: cleanup utils.cmake

cmake: cleanup utils.cmake

--- cmake/utils.cmake
+++ cmake/utils.cmake
@@ -55,13 +55,6 @@
   set(${VERSION} "${MAJOR}.${MINOR}.${PATCH}" PARENT_SCOPE)
 endfunction()

-function(check_target my_target)
-  if(NOT TARGET ${my_target})
-    message(FATAL_ERROR " Or-Tools: compiling Or-Tools requires a ${my_target}
-    CMake target in your project, see CMake/README.md for more details")
-  endif(NOT TARGET ${my_target})
-endfunction()
-

 # fetch_git_dependency()
 #
@@ -72,9 +65,11 @@
 # NAME: name of the dependency
 # REPOSITORY: git url of the dependency
 # TAG: tag of the dependency
-# APPLY_PATCH: apply patch
+# PATCH_COMMAND: apply patch
+# SOURCE_SUBDIR: Path to source CMakeLists.txt relative to root dir
 # CMAKE_ARGS: List of specific CMake args to add
 #
+# e.g.:
 # fetch_git_dependency(
 #   NAME
 #     abseil-cpp
@@ -82,7 +77,7 @@
 #     https://github.com/abseil/abseil-cpp.git
 #   TAG
 #     master
-#   APPLY_PATCH
+#   PATCH_COMMAND
 #     "git apply ${CMAKE_SOURCE_DIR}/patches/abseil-cpp.patch"
 # )
 function(fetch_git_dependency)


Fix the system-test driver

Fix the system-test driver

--- tests/system_tests/run_system_tests.sh.cmake
+++ tests/system_tests/run_system_tests.sh.cmake
@@ -1,11 +1,5 @@
 #!/usr/bin/env bash
-# Copyright 2011, Tokyo Institute of Technology.
-# All rights reserved.
-#
-# This file is distributed under the license described in
-# LICENSE.txt.
-#
-# Author: Naoya Maruyama (naoya@matsulab.is.titech.ac.jp)
+# Licensed under the BSD license. See LICENSE.txt for more details.

 #
 # For usage, see the help message by executing this script with option --help.
@@ -789,7 +783,6 @@
     local src_name=${1%%.*}
     local target=$2
     local ref_exe=$(get_reference_exe_name $1 $2)
-	echo $ref_exe
     local ref_out=$ref_exe.out
     # Do nothing if no reference implementation is found.
     if [ ! -x $ref_exe ]; then
@@ -864,7 +857,9 @@
 			exit_error "Unsupported target: $2"
 			;;
     esac
-    if [ $? -ne 0 ] || grep -q "orted was unable to" $exename.err; then
+	# Note OpenMPI does not necessarily return non-zero even upon failures
+    if [ $? -ne 0 ] || \
+		egrep -qiw "orted was unable to|exited on signal" $exename.err; then
 		cat $exename.err
 		return 1
     fi
@@ -1205,10 +1200,13 @@
 			FAILED_TESTS="$FAILED_TESTS $test_sig"
 			;;
 		$FAIL_COMPILE)
+			inc NUM_SUCCESS_TRANS
 			inc NUM_FAIL_COMPILE
 			FAILED_TESTS="$FAILED_TESTS $test_sig"
 			;;
 		$FAIL_EXECUTE)
+			inc NUM_SUCCESS_TRANS
+			inc NUM_SUCCESS_COMPILE
 			inc NUM_FAIL_EXECUTE
 			FAILED_TESTS="$FAILED_TESTS $test_sig"
 			;;


Enable public/private encryption and dep in sodium

--- ext/sodium.cmake
+++ ext/sodium.cmake
@@ -47,11 +47,11 @@
 	libsodium/src/libsodium/crypto_generichash/blake2/ref/blake2b-ref.c
 	libsodium/src/libsodium/crypto_generichash/blake2/ref/generichash_blake2b.c
 	libsodium/src/libsodium/crypto_generichash/crypto_generichash.c
-	# libsodium/src/libsodium/crypto_hash/crypto_hash.c
+	libsodium/src/libsodium/crypto_hash/crypto_hash.c
 	# libsodium/src/libsodium/crypto_hash/sha256/hash_sha256_api.c
 	# libsodium/src/libsodium/crypto_hash/sha256/cp/hash_sha256.c
-	# libsodium/src/libsodium/crypto_hash/sha512/hash_sha512_api.c
-	# libsodium/src/libsodium/crypto_hash/sha512/cp/hash_sha512.c
+	libsodium/src/libsodium/crypto_hash/sha512/hash_sha512_api.c
+	libsodium/src/libsodium/crypto_hash/sha512/cp/hash_sha512.c
 	# libsodium/src/libsodium/crypto_onetimeauth/crypto_onetimeauth.c
 	# libsodium/src/libsodium/crypto_onetimeauth/poly1305/donna/auth_poly1305_donna.c
 	# libsodium/src/libsodium/crypto_onetimeauth/poly1305/donna/verify_poly1305_donna.c
@@ -89,52 +89,52 @@
 	# libsodium/src/libsodium/crypto_shorthash/crypto_shorthash.c
 	# libsodium/src/libsodium/crypto_shorthash/siphash24/ref/shorthash_siphash24.c
 	# libsodium/src/libsodium/crypto_shorthash/siphash24/shorthash_siphash24_api.c
-	# libsodium/src/libsodium/crypto_sign/crypto_sign.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_0.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_1.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_add.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_cmov.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_copy.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_frombytes.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_invert.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_isnegative.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_isnonzero.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_mul.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_neg.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_pow22523.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_sq.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_sq2.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_sub.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_tobytes.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_add.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_double_scalarmult.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_frombytes.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_madd.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_msub.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p1p1_to_p2.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p1p1_to_p3.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p2_0.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p2_dbl.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p3_0.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p3_dbl.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p3_tobytes.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p3_to_cached.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p3_to_p2.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_precomp_0.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_scalarmult_base.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_sub.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_tobytes.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/keypair.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/open.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/sc_muladd.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/sc_reduce.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/ref10/sign.c
-	# libsodium/src/libsodium/crypto_sign/ed25519/sign_ed25519_api.c
-	# libsodium/src/libsodium/crypto_sign/edwards25519sha512batch/ref/fe25519_edwards25519sha512batch.c
-	# libsodium/src/libsodium/crypto_sign/edwards25519sha512batch/ref/ge25519_edwards25519sha512batch.c
-	# libsodium/src/libsodium/crypto_sign/edwards25519sha512batch/ref/sc25519_edwards25519sha512batch.c
-	# libsodium/src/libsodium/crypto_sign/edwards25519sha512batch/ref/sign_edwards25519sha512batch.c
-	# libsodium/src/libsodium/crypto_sign/edwards25519sha512batch/sign_edwards25519sha512batch_api.c
+	libsodium/src/libsodium/crypto_sign/crypto_sign.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_0.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_1.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_add.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_cmov.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_copy.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_frombytes.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_invert.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_isnegative.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_isnonzero.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_mul.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_neg.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_pow22523.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_sq.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_sq2.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_sub.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/fe_tobytes.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_add.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_double_scalarmult.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_frombytes.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_madd.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_msub.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p1p1_to_p2.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p1p1_to_p3.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p2_0.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p2_dbl.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p3_0.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p3_dbl.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p3_tobytes.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p3_to_cached.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_p3_to_p2.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_precomp_0.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_scalarmult_base.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_sub.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/ge_tobytes.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/keypair.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/open.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/sc_muladd.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/sc_reduce.c
+	libsodium/src/libsodium/crypto_sign/ed25519/ref10/sign.c
+	libsodium/src/libsodium/crypto_sign/ed25519/sign_ed25519_api.c
+	libsodium/src/libsodium/crypto_sign/edwards25519sha512batch/ref/fe25519_edwards25519sha512batch.c
+	libsodium/src/libsodium/crypto_sign/edwards25519sha512batch/ref/ge25519_edwards25519sha512batch.c
+	libsodium/src/libsodium/crypto_sign/edwards25519sha512batch/ref/sc25519_edwards25519sha512batch.c
+	libsodium/src/libsodium/crypto_sign/edwards25519sha512batch/ref/sign_edwards25519sha512batch.c
+	libsodium/src/libsodium/crypto_sign/edwards25519sha512batch/sign_edwards25519sha512batch_api.c
 	# libsodium/src/libsodium/crypto_stream/aes128ctr/portable/afternm_aes128ctr.c
 	# libsodium/src/libsodium/crypto_stream/aes128ctr/portable/beforenm_aes128ctr.c
 	# libsodium/src/libsodium/crypto_stream/aes128ctr/portable/common_aes128ctr.c
@@ -160,8 +160,8 @@
 	# libsodium/src/libsodium/crypto_stream/xsalsa20/stream_xsalsa20_api.c
 	# libsodium/src/libsodium/crypto_verify/16/ref/verify_16.c
 	# libsodium/src/libsodium/crypto_verify/16/verify_16_api.c
-	# libsodium/src/libsodium/crypto_verify/32/ref/verify_32.c
-	# libsodium/src/libsodium/crypto_verify/32/verify_32_api.c
+	libsodium/src/libsodium/crypto_verify/32/ref/verify_32.c
+	libsodium/src/libsodium/crypto_verify/32/verify_32_api.c
 	# libsodium/src/libsodium/crypto_verify/64/ref/verify_64.c
 	# libsodium/src/libsodium/crypto_verify/64/verify_64_api.c
 	libsodium/src/libsodium/randombytes/randombytes.c


remove comments

remove comments

--- share/cmake/FindGMP.cmake
+++ share/cmake/FindGMP.cmake
@@ -2,11 +2,6 @@
 #
 # Redistribution and use is allowed according to the terms of the BSD license.
 # For details see the accompanying COPYING-CMAKE-SCRIPTS file.
-#   PATHS ${GMP_PREFIX}/include /usr/include /usr/local/include)
-# message(${GMP_INCLUDE_DIR})
-
-# find_library(GMP_LIBRARY gmp
-#   PATHS ${GMP_PREFIX}/lib /usr/lib /usr/local/lib)

 if (GMP_INCLUDE_DIR AND GMP_LIBRARIES)
   # Already in cache, be silent


minor bug fix

minor bug fix

--HG--
extra : convert_revision : 1701e99c0e4ee8f2480e460eca79d9a3d678dba2

--- trunk/CMakeModules/PythonBindingsUtils.cmake
+++ trunk/CMakeModules/PythonBindingsUtils.cmake
@@ -24,6 +24,8 @@
 	set(PY_OMPL_COMPILE ON CACHE BOOL
 		"Whether the OMPL Python modules can be built")
 	mark_as_advanced(PY_OMPL_COMPILE)
+	set(OMPL_PYTHON_INSTALL_DIR "${PYTHON_SITE_MODULES}" CACHE STRING
+	    "Path to directory where OMPL python modules will be installed")
 endif()
 if(PYTHON_FOUND AND Boost_PYTHON_LIBRARY AND PY_PYPLUSPLUS
 	AND PY_PYGCCXML AND GCCXML)
@@ -38,8 +40,6 @@
 	set(PY_OMPL_GENERATE ON CACHE BOOL
 		"Whether the C++ code for the OMPL Python module can be generated")
 	mark_as_advanced(PY_OMPL_GENERATE)
-	set(OMPL_PYTHON_INSTALL_DIR "${PYTHON_SITE_MODULES}" CACHE STRING
-	    "Path to directory where OMPL python modules will be installed")
 endif()

 function(create_module_header_file_target module dir)


Next try...

Next try...

--- cmake/FindOpenALSoft.cmake
+++ cmake/FindOpenALSoft.cmake
@@ -19,6 +19,7 @@
     # Linux Include PATH
     /usr/include/AL/
     # Windows SDK Include PATH
+    /include/OpenAL
     /include/
 )


Another try to fix macos build to use the correct openalsoft lib

--- cmake/FindOpenALSoft.cmake
+++ cmake/FindOpenALSoft.cmake
@@ -29,14 +29,13 @@
 ENDIF(NOT APPLE)

 IF (APPLE)
-  find_path(OPENALSOFT_INCLUDE_DIR al.h
+  find_path(OPENALSOFT_INCLUDE_DIR al.h alext.h
   PATHS
     /usr/local/opt/openal-soft/include/
   )
   find_library(OPENALSOFT_LIBRARY
   NAMES libopenal.dylib openal.dylib
   PATHS
-    ${OPENALSOFT_INCLUDE_DIR}/../lib
     /usr/local/opt/openal-soft/lib
   )
 ENDIF (APPLE)


remove freetype stuff

remove freetype stuff

--- cmake/get-sdl2_image.cmake
+++ cmake/get-sdl2_image.cmake
@@ -52,7 +52,7 @@
     PREFIX ${DEPENDENCY_EXTRACT_DIR}
     DOWNLOAD_DIR ${DEPENDENCY_DOWNLOAD_DIR}
     URL https://libsdl.org/projects/SDL_image/release/SDL2_image-${SDL2_IMAGE_VERSION}.tar.gz
-    CONFIGURE_COMMAND <SOURCE_DIR>/configure --prefix=${EXTERNAL_ROOT} --with-freetype-prefix=${EXTERNAL_ROOT}
+    CONFIGURE_COMMAND <SOURCE_DIR>/configure --prefix=${EXTERNAL_ROOT}
   )

 endif()


Corrects test binary paths in the CMake build script.

--- cmake/internal_utils.cmake
+++ cmake/internal_utils.cmake
@@ -184,7 +184,7 @@
     # only at ctest runtime (by calling ctest -c <Configuration>), so
     # we have to escape $ to delay variable substitution here.
     add_test(${name}
-      ${PYTHON_EXECUTABLE} ${CMAKE_SOURCE_DIR}/test/${name}.py
-          --build_dir=${CMAKE_BINARY_DIR}/\${CTEST_CONFIGURATION_TYPE})
+      ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/test/${name}.py
+          --build_dir=${CMAKE_CURRENT_BINARY_DIR}/\${CTEST_CONFIGURATION_TYPE})
   endif()
 endfunction()


Search for wxWidgets in quiet mode. This suppresses an error message that would be displayed if wxWidgets was not found. Since we do not expect all builds to have wxWidgets this is ok.

svn path=/trunk/; revision=7661

--- cmake/modules/plplot.cmake
+++ cmake/modules/plplot.cmake
@@ -255,7 +255,7 @@

 # Find wxWidgets needed for driver and bindings
 SET(wxWidgets_USE_LIBS core base)
-find_package(wxWidgets)
+find_package(wxWidgets QUIET)

 # =======================================================================
 # additional library support


Clarify the SubProject documentation.

Clarify the SubProject documentation.

--- SubProject.cmake
+++ SubProject.cmake
@@ -1,18 +1,29 @@

-# When included, automatically reads, parses and updates a .gitsubprojects file.
+# Include this file in a top-level CMakeLists to build several CMake
+# subprojects (which may depend on each other).
+#
+# When included, it will automatically parse a .gitsubprojects file if one is
+# present in the same CMake source directory.
 # .gitsubprojects contains lines in the form:
-#   "git_subproject(<project> <giturl> <gittag>)"
-# All projects are cloned, updated and added using the the (separately usable)
-# git_subproject(project giturl gittag) macro as a sub project to the parent
-# project. The git_subproject macro uses the add_subproject(name) function to add
-# the project as a sub directory.
+# "git_subproject(<project> <giturl> <gittag>)"
 #
-# Using a simple top level CMakeLists, several CMake subprojects
-# (which may depend on each other) can be built. To use the SubProject
-# feature, the sub projects should modify their CMake scripts. In the
-# scripts CMAKE_BINARY_DIR should be changed to PROJECT_BINARY_DIR and
-# CMAKE_SOURCE_DIR should be changed to PROJECT_SOURCE_DIR. A sample
-# project can be found at https://github.com/bilgili/SubProjects.git
+# All the subprojects will be cloned and configured during the CMake configure
+# step thanks to the 'git_subproject(project giturl gittag)' macro
+# (also usable separately).
+# The latter relies on the add_subproject(name) function to add projects as
+# sub directories. See also: cmake command 'add_subdirectory'.
+#
+# The following targets are created by SubProject.cmake:
+# - An 'update_git_subprojects_${PROJECT_NAME}' target to update the <gittag> of
+#   all the .gitsubprojects entries to their latest respective origin/master ref
+# - A generic 'update' target to execute 'update_git_subrojects' recursively
+#
+# To be compatible with the SubProject feature, (sub)projects might need to
+# adapt their CMake scripts in the following way:
+# - CMAKE_BINARY_DIR should be changed to PROJECT_BINARY_DIR
+# - CMAKE_SOURCE_DIR should be changed to PROJECT_SOURCE_DIR
+#
+# A sample project can be found at https://github.com/Eyescale/Collage.git

 include(${CMAKE_CURRENT_LIST_DIR}/GitExternal.cmake)


fixed location of SIRF_SRC_PATH

fixed location of SIRF_SRC_PATH

--- SuperBuild.cmake
+++ SuperBuild.cmake
@@ -154,7 +154,7 @@
 #set(proj ${PRIMARY_PROJECT_NAME})

 # Make environment files
-set(SIRF_SRC_PATH ${SOURCE_DOWNLOAD_CACHE}/SIRF)
+set(SIRF_SRC_PATH ${SOURCE_DOWNLOAD_CACHE}/sources/SIRF)
 set(CCPPETMR_INSTALL ${SUPERBUILD_INSTALL_DIR})

 ## configure the environment files env_ccppetmr.sh/csh


Removed unused if-else

Removed unused if-else

--- SuperBuild.cmake
+++ SuperBuild.cmake
@@ -93,21 +93,11 @@
 configure_file(env_ccppetmr.sh.in ${CCPPETMR_INSTALL}/bin/env_ccppetmr.sh)
 configure_file(env_ccppetmr.csh.in ${CCPPETMR_INSTALL}/bin/env_ccppetmr.csh)

-# Creates sirfrc and appends to the bashrc
+# Creates sirfrc
+# copy new version of the env veriables to the file
+configure_file(env_ccppetmr.sh.in $ENV{HOME}/.sirfrc)
+essage("To set up all the environmental variables for SIRF, just type: source ~/.sirfrc")

-if (EXISTS $ENV{HOME}/.sirfrc)
-   # copy new version of the env veriables to the file
-   configure_file(env_ccppetmr.sh.in $ENV{HOME}/.sirfrc)
-else()
-  # create .sirfrc
-  configure_file(env_ccppetmr.sh.in $ENV{HOME}/.sirfrc)
-  # append .sirfrc to .bashrc
-#  file(APPEND $ENV{HOME}/.bashrc "#Environment variables for SIRF
-#source ~/.sirfrc")
-endif()
-message("To set up all the environmental variables for SIRF, just type: source ~/.sirfrc")
-
-configure_file(env_ccppetmr.csh.in ${CCPPETMR_INSTALL}/bin/env_ccppetmr.csh)

 # add tests


Missing dollar sign

Missing dollar sign

--- cmake/ALICE_CMake.cmake
+++ cmake/ALICE_CMake.cmake
@@ -407,7 +407,7 @@
     # and so that the interpreter can parse the header files.
     #
     # THIS SHOULD BE A TEMPORARY HACK!
-    ALICE_Format(DINC "-I{PROJECT_SOURCE_DIR}/" ""
+    ALICE_Format(DINC "-I${PROJECT_SOURCE_DIR}/" ""
       "${DINC};${CMAKE_INCLUDE_EXPORT_DIRECTORY}")
   else()
   ALICE_Format(DINC "-I" "" "${DINC};${CMAKE_INCLUDE_EXPORT_DIRECTORY}")


Sync FindGObject.cmake with kdelibs' e02cae5.

It now looks similar to FindGLIB2.cmake. Notable changes include:

 * pkg-config is now optional.
 * Unnecessary WIN32 checks have been removed.
 * Use FindPackageHandleStandardArgs instead of duplicating its
   functionality.
 * GOBJECT_LIBRARIES always contains the result of
   find_library(). This should fix the build when gobject is not
   installed in a path automatically searched by the compiler: the
   pkg-config output only returned '-lgobject-2.0', find_library()
   returns '/path/to/libgobject-2.0'.

Acked-by: apachelogger on IRC.

--- cmake/FindGObject.cmake
+++ cmake/FindGObject.cmake
@@ -6,70 +6,47 @@
 #  GOBJECT_LIBRARIES - the libraries needed to use GObject
 #  GOBJECT_DEFINITIONS - Compiler switches required for using GObject

-# Copyright (c) 2008 Helio Chissini de Castro, <helio@kde.org>
-#  (c)2006, Tim Beaulen <tbscope@gmail.com>
+# Copyright (c) 2011, Raphael Kubo da Costa <kubito@gmail.com>
+# Copyright (c) 2006, Tim Beaulen <tbscope@gmail.com>
+#
+# Redistribution and use is allowed according to the terms of the BSD license.
+# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

+FIND_PACKAGE(PkgConfig)
+PKG_CHECK_MODULES(PC_GOBJECT gobject-2.0)
+SET(GOBJECT_DEFINITIONS ${PC_GOBJECT_CFLAGS_OTHER})

-IF (GOBJECT_INCLUDE_DIR AND GOBJECT_LIBRARIES)
-   # in cache already
-   SET(GObject_FIND_QUIETLY TRUE)
-ELSE (GOBJECT_INCLUDE_DIR AND GOBJECT_LIBRARIES)
-   SET(GObject_FIND_QUIETLY FALSE)
-ENDIF (GOBJECT_INCLUDE_DIR AND GOBJECT_LIBRARIES)
-
-IF (NOT WIN32)
-   FIND_PACKAGE(PkgConfig REQUIRED)
-   # use pkg-config to get the directories and then use these values
-   # in the FIND_PATH() and FIND_LIBRARY() calls
-   PKG_CHECK_MODULES(PKG_GOBJECT2 REQUIRED gobject-2.0)
-   SET(GOBJECT_DEFINITIONS ${PKG_GOBJECT2_CFLAGS})
-ENDIF (NOT WIN32)
-
-FIND_PATH(GOBJECT_INCLUDE_DIR gobject/gobject.h
-   PATHS
-   ${PKG_GOBJECT2_INCLUDE_DIRS}
-   /usr/include/glib-2.0/
-   PATH_SUFFIXES glib-2.0
+FIND_PATH(GOBJECT_INCLUDE_DIR gobject.h
+   HINTS
+   ${PC_GOBJECT_INCLUDEDIR}
+   ${PC_GOBJECT_INCLUDE_DIRS}
+   PATH_SUFFIXES glib-2.0/gobject/
    )

 FIND_LIBRARY(_GObjectLibs NAMES gobject-2.0
-   PATHS
-   ${PKG_GOBJECT2_LIBRARY_DIRS}
+   HINTS
+   ${PC_GOBJECT_LIBDIR}
+   ${PC_GOBJECT_LIBRARY_DIRS}
    )
 FIND_LIBRARY(_GModuleLibs NAMES gmodule-2.0
-   PATHS
-   ${PKG_GOBJECT2_LIBRARY_DIRS}
+   HINTS
+   ${PC_GOBJECT_LIBDIR}
+   ${PC_GOBJECT_LIBRARY_DIRS}
    )
 FIND_LIBRARY(_GThreadLibs NAMES gthread-2.0
-   PATHS
-   ${PKG_GOBJECT2_LIBRARY_DIRS}
+   HINTS
+   ${PC_GOBJECT_LIBDIR}
+   ${PC_GOBJECT_LIBRARY_DIRS}
    )
 FIND_LIBRARY(_GLibs NAMES glib-2.0
-   PATHS
-   ${PKG_GOBJECT2_LIBRARY_DIRS}
+   HINTS
+   ${PC_GOBJECT_LIBDIR}
+   ${PC_GOBJECT_LIBRARY_DIRS}
    )

-IF (WIN32)
-SET (GOBJECT_LIBRARIES ${_GObjectLibs} ${_GModuleLibs} ${_GThreadLibs} ${_GLibs})
-ELSE (WIN32)
-SET (GOBJECT_LIBRARIES ${PKG_GOBJECT2_LIBRARIES})
-ENDIF (WIN32)
+SET( GOBJECT_LIBRARIES ${_GObjectLibs} ${_GModuleLibs} ${_GThreadLibs} ${_GLibs} )

-IF (GOBJECT_INCLUDE_DIR AND GOBJECT_LIBRARIES)
-   SET(GOBJECT_FOUND TRUE)
-ELSE (GOBJECT_INCLUDE_DIR AND GOBJECT_LIBRARIES)
-   SET(GOBJECT_FOUND FALSE)
-ENDIF (GOBJECT_INCLUDE_DIR AND GOBJECT_LIBRARIES)
+INCLUDE(FindPackageHandleStandardArgs)
+FIND_PACKAGE_HANDLE_STANDARD_ARGS(GOBJECT DEFAULT_MSG GOBJECT_LIBRARIES GOBJECT_INCLUDE_DIR)

-IF (GOBJECT_FOUND)
-   IF (NOT GObject_FIND_QUIETLY)
-      MESSAGE(STATUS "Found GObject libraries: ${GOBJECT_LIBRARIES}")
-      MESSAGE(STATUS "Found GObject includes : ${GOBJECT_INCLUDE_DIR}")
-   ENDIF (NOT GObject_FIND_QUIETLY)
-ELSE (GOBJECT_FOUND)
-    IF (GObject_FIND_REQUIRED)
-      MESSAGE(STATUS "Could NOT find GObject")
-    ENDIF(GObject_FIND_REQUIRED)
-ENDIF (GOBJECT_FOUND)
-
-MARK_AS_ADVANCED(GOBJECT_INCLUDE_DIR GOBJECT_LIBRARIES)
+MARK_AS_ADVANCED(GOBJECT_INCLUDE_DIR _GObjectLibs _GModuleLibs _GThreadLibs _GLibs)


Only install test exe if built

Only install test exe if built

--- cmake/InstallFAST.cmake
+++ cmake/InstallFAST.cmake
@@ -5,10 +5,12 @@
 	DESTINATION fast/lib
 )

-# Install test executable
-install(TARGETS testFAST
-	DESTINATION fast/bin
-)
+if(FAST_BUILD_TESTS)
+    # Install test executable
+    install(TARGETS testFAST
+        DESTINATION fast/bin
+    )
+endif()

 # Examples are installed in the macro fast_add_example


[cmake] Use target depend dir for windeplyqt.

--- cmake/Windeployqt.cmake
+++ cmake/Windeployqt.cmake
@@ -41,10 +41,10 @@
 	# execute windeployqt in a tmp directory after build
     add_custom_command(TARGET ${target}
         POST_BUILD
-        COMMAND ${CMAKE_COMMAND} -E rm -rf "${CMAKE_CURRENT_BINARY_DIR}/windeployqt"
+        COMMAND ${CMAKE_COMMAND} -E rm -rf "${CMAKE_CURRENT_BINARY_DIR}/windeployqt-${target}"
         COMMAND set PATH="${_qt_bin_dir}"
-        COMMAND ${CMAKE_COMMAND} -E make_directory "${CMAKE_CURRENT_BINARY_DIR}/windeployqt"
-        COMMAND "${WINDEPLOYQT_EXECUTABLE}" --dir "${CMAKE_CURRENT_BINARY_DIR}/windeployqt" --verbose 0 --no-compiler-runtime --no-translations --no-angle --release --no-opengl-sw "$<TARGET_FILE:${target}>"
+        COMMAND ${CMAKE_COMMAND} -E make_directory "${CMAKE_CURRENT_BINARY_DIR}/windeployqt-${target}"
+        COMMAND "${WINDEPLOYQT_EXECUTABLE}" --dir "${CMAKE_CURRENT_BINARY_DIR}/windeployqt-${target}" --verbose 0 --no-compiler-runtime --no-translations --no-angle --release --no-opengl-sw "$<TARGET_FILE:${target}>"
         COMMENT "Run WinQTDeploy on ${target}"
         USES_TERMINAL
         COMMAND_EXPAND_LISTS
@@ -53,7 +53,7 @@
 	# copy deployment directory during installation
     install(
         DIRECTORY
-        "${CMAKE_CURRENT_BINARY_DIR}/windeployqt/"
+        "${CMAKE_CURRENT_BINARY_DIR}/windeployqt-${target}/"
         DESTINATION ${directory}
     )


More unified regexp for F2

More unified regexp for F2

--- cmake/gcc_stm32f2.cmake
+++ cmake/gcc_stm32f2.cmake
@@ -10,7 +10,7 @@
 SET(STM32_CODES "205.B" "205.C" "205.E" "205.F" "205.G" "215.E" "215.G" "207.C" "207.E" "207.F" "207.G" "217.E" "217.G")

 MACRO(STM32_GET_CHIP_TYPE CHIP CHIP_TYPE)
-    STRING(REGEX REPLACE "^[sS][tT][mM]32[fF](2[01][57].[BCDEFG]).+$" "\\1" STM32_CODE ${CHIP})
+    STRING(REGEX REPLACE "^[sS][tT][mM]32[fF](2[01][57].[BCDEFG]).*$" "\\1" STM32_CODE ${CHIP})
     SET(INDEX 0)
     FOREACH(C_TYPE ${STM32_CHIP_TYPES})
         LIST(GET STM32_CODES ${INDEX} CHIP_TYPE_REGEXP)
@@ -23,7 +23,7 @@
 ENDMACRO()

 MACRO(STM32_GET_CHIP_PARAMETERS CHIP FLASH_SIZE RAM_SIZE)
-    STRING(REGEX REPLACE "^[sS][tT][mM]32[fF]2[01][57].([BCDEFG]).*" "\\1" STM32_SIZE_CODE ${CHIP})
+    STRING(REGEX REPLACE "^[sS][tT][mM]32[fF]2[01][57].([BCDEFG]).*$" "\\1" STM32_SIZE_CODE ${CHIP})

     IF(STM32_SIZE_CODE STREQUAL "B")
         SET(FLASH "128K")
@@ -68,4 +68,4 @@
         SET(TARGET_DEFS "STM32F2;STM32F${DEVICE_NUM}xx")
     ENDIF()
     SET_TARGET_PROPERTIES(${TARGET} PROPERTIES COMPILE_DEFINITIONS "${TARGET_DEFS}")
-ENDFUNCTION()+ENDFUNCTION()


MAINT: AppVeyor fix?

MAINT: AppVeyor fix?

--- cmake/sara_macros.cmake
+++ cmake/sara_macros.cmake
@@ -342,8 +342,12 @@

   set_target_properties(${_test_name}
     PROPERTIES
-    COMPILE_FLAGS ${SARA_DEFINITIONS}
-    RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin")
+    COMPILE_FLAGS ${SARA_DEFINITIONS})
+  if (NOT WIN32)
+    set_target_properties(${_test_name}
+      PROPERTIES
+      RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin")
+  endif ()

   add_test(NAME ${_test_name} COMMAND $<TARGET_FILE:${_test_name}>)


fix use of else(), endif()

fix use of else(), endif()

follow current CMake conventions not to use conditional names as in `else(BLA)`

--- SuperBuild.cmake
+++ SuperBuild.cmake
@@ -2,8 +2,8 @@
 # Author: Benjamin A Thomas
 # Author: Edoardo Pasca
 # Author: Casper da Costa-Luis
-# Copyright 2017 University College London
-# Copyright 2017 Science Technology Facilities Council
+# Copyright 2017-2020 University College London
+# Copyright 2017-2020 Science Technology Facilities Council
 #
 # This file is part of the CCP PETMR Synergistic Image Reconstruction Framework (SIRF) SuperBuild.
 #
@@ -82,7 +82,7 @@
 option(DISABLE_PYTHON "Disable building SIRF python support" OFF)
 if (DISABLE_PYTHON)
   message(STATUS "Python support disabled")
-else(DISABLE_PYTHON)
+else()

   # Attempt to make Python settings consistent
   set(PYVER 0 CACHE STRING "Python version")
@@ -125,13 +125,13 @@
       CONDA:      do nothing")
     set_property(CACHE PYTHON_STRATEGY PROPERTY STRINGS PYTHONPATH SETUP_PY CONDA)
   endif()
-endif(DISABLE_PYTHON)
+endif()

 #### MATLAB support
 option(DISABLE_Matlab "Disable building MATLAB support" OFF)
 if (DISABLE_Matlab)
   message(STATUS "Matlab support disabled")
-else(DISABLE_Matlab)
+else()
   # Find Matlab
   set(Matlab_ROOT_DIR $ENV{Matlab_ROOT_DIR} CACHE PATH "Path to Matlab root directory" )
   # Note that we need the main program for the configuration files and the tests)
@@ -149,7 +149,7 @@
     message(STATUS "Matlab libraries found")
     message(STATUS "SIRF and/or STIR Matlab libraries will be installed in " ${MATLAB_DEST})
   endif()
-endif(DISABLE_Matlab)
+endif()

 # Include macro to sets ${proj}_URL_MODIFIED and ${proj}_TAG_MODIFIED
 # If the user doesn't want git checkout to be performed,


fptu-make: fix message space (cosmetic).

--- cmake.fptu/compiler.cmake
+++ cmake.fptu/compiler.cmake
@@ -3,7 +3,7 @@
 #
 if(NOT (CMAKE_C_COMPILER_ID STREQUAL CMAKE_CXX_COMPILER_ID))
   message(WARNING "CMAKE_C_COMPILER_ID (${CMAKE_C_COMPILER_ID}) is different "
-    "from CMAKE_CXX_COMPILER_ID (${CMAKE_CXX_COMPILER_ID})."
+    "from CMAKE_CXX_COMPILER_ID (${CMAKE_CXX_COMPILER_ID}). "
     "The final binary may be unusable.")
 endif()


updating submodule linking

updating submodule linking

--- cmake/Hunter/config.cmake
+++ cmake/Hunter/config.cmake
@@ -13,13 +13,14 @@

 hunter_config(
     XLink
-    VERSION "luxonis-2020.2-test_usb_info"
-    URL "https://github.com/luxonis/XLink/archive/test_usb_info.zip"
-    SHA1 "1ce5d55a3b0a0b9df85837afe5024986c857c57c"
+    VERSION "luxonis-2020.2"
+    URL  "https://github.com/luxonis/XLink/archive/test_usb_info.zip"
+    SHA1 "1af32e324a18cd0caebba7d768b1b068e24d5709"
     CMAKE_ARGS
         CMAKE_POSITION_INDEPENDENT_CODE=ON
 )

+# "https://github.com/luxonis/XLink/archive/test_usb_info.zip"
 hunter_config(
     BZip2
     VERSION "1.0.8-p0"


Use `list(APPEND` instead of `set`

Use `list(APPEND` instead of `set`

--- cmake/Hunter/config.cmake
+++ cmake/Hunter/config.cmake
@@ -1,4 +1,4 @@
-set(CMAKE_MODULE_PATH @CMAKE_MODULE_PATH@) # fetch top level CMAKE_MODULE_PATH
+list(APPEND CMAKE_MODULE_PATH @CMAKE_MODULE_PATH@) # fetch top level CMAKE_MODULE_PATH

 message(">:>:>:>:>:>:>:>:>:>:>:>:>:>:>:>:>: ${CMAKE_MODULE_PATH} <:<:<:<:<:<:<:<:<:<:<:<:<:<:<:<:<:<:<:<:<:<:<:")


Fix message output.

Fix message output.

--- cmake/PlatformMacOS.cmake
+++ cmake/PlatformMacOS.cmake
@@ -20,7 +20,7 @@
     # Therefore, we re-define the CMAKE_CONFIGURATION_TYPES here according to the value
     # in CMAKE_BUILD_TYPES.
     set(CMAKE_CONFIGURATION_TYPES ${CMAKE_BUILD_TYPE})
-    message(STATUS ">> Re-defining as follows: CMAKE_CONFIGURATION_TYPES = ${CMAKE_CONFIGURATION_TYPES}")
+    message(STATUS ">> Re-defining variable CMAKE_CONFIGURATION_TYPES := ${CMAKE_CONFIGURATION_TYPES}")

 endif()


Fix compile warning on clang.

Fix compile warning on clang.

--- cmake/compile_flags.cmake
+++ cmake/compile_flags.cmake
@@ -14,7 +14,7 @@
         set(release -Weverything -Wno-system-headers -Wno-c++98-compat
                     -Wno-c++98-compat-pedantic -Wno-exit-time-destructors
                     -Wno-global-constructors -Wno-missing-prototypes
-                    -Wno-padded)
+                    -Wno-padded -Wno-documentation-unknown-command)
         set(debug -Werror)
     else()
         message(WARNING "Custom compiler flags not set.\n"


add ISPC v1.12.0 to working list, add fatal error if using v1.11.0

--- cmake/compiler/ispc.cmake
+++ cmake/compiler/ispc.cmake
@@ -15,7 +15,7 @@
 ## ======================================================================== ##

 # ISPC versions to look for, in decending order (newest first)
-set(ISPC_VERSION_WORKING "1.10.0" "1.9.2" "1.9.1")
+set(ISPC_VERSION_WORKING "1.12.0" "1.10.0" "1.9.2" "1.9.1")
 list(GET ISPC_VERSION_WORKING -1 ISPC_VERSION_REQUIRED)

 if (NOT ISPC_EXECUTABLE)
@@ -69,6 +69,10 @@
   set(ISPC_VERSION ${ISPC_VERSION} CACHE STRING "ISPC Version")
   mark_as_advanced(ISPC_VERSION)
   mark_as_advanced(ISPC_EXECUTABLE)
+endif()
+
+if ("${ISPC_VERSION}" STREQUAL "1.11.0")
+  message(FATAL_ERROR "ISPC v1.11.0 is incompatible with OSPRay.")
 endif()

 set(OSPRAY_ISPC_ADDRESSING 32 CACHE STRING "32 vs 64 bit addressing in ispc")


Add all dependent libraries to mlsl linkage interface (#2501)

* Add all dependent libraries to mlsl linkage interface

* Use ${CMAKE_SHARED_LIBRARY_PREFIX} and ${CMAKE_SHARED_LIBRARY_SUFFIX}

--- cmake/external_mlsl.cmake
+++ cmake/external_mlsl.cmake
@@ -43,12 +43,17 @@
     EXCLUDE_FROM_ALL TRUE
     )

+add_library(libmlsl INTERFACE)
 ExternalProject_Get_Property(MLSL SOURCE_DIR)
 ExternalProject_Get_Property(MLSL INSTALL_DIR)
-add_library(libmlsl INTERFACE)
 target_include_directories(libmlsl SYSTEM INTERFACE ${SOURCE_DIR}/include)
-target_link_libraries(libmlsl INTERFACE ${INSTALL_DIR}/intel64/lib/thread/libmlsl.so)
-link_directories(${INSTALL_DIR}/intel64/lib/thread)
+
+set(MLSL_LINK_LIBRARIES
+    ${INSTALL_DIR}/intel64/lib/thread/${CMAKE_SHARED_LIBRARY_PREFIX}mlsl${CMAKE_SHARED_LIBRARY_SUFFIX}
+    ${INSTALL_DIR}/intel64/lib/thread/${CMAKE_SHARED_LIBRARY_PREFIX}mpi${CMAKE_SHARED_LIBRARY_SUFFIX}
+    ${INSTALL_DIR}/intel64/lib/thread/${CMAKE_SHARED_LIBRARY_PREFIX}fabric${CMAKE_SHARED_LIBRARY_SUFFIX})
+
+target_link_libraries(libmlsl PRIVATE INTERFACE ${MLSL_LINK_LIBRARIES})
 add_dependencies(libmlsl MLSL)

 #installation


switching from CUDA v4.1 to 4

switching from CUDA v4.1 to 4

git-svn-id: e7ea667a1d39a4453c4efcc4ba7bca3d620c3f19@6676 a9d63959-f2ad-4865-b262-bf0e56cfafb6

--- cmake/pcl_find_cuda.cmake
+++ cmake/pcl_find_cuda.cmake
@@ -1,6 +1,6 @@
 # Find CUDA
 set(CUDA_FIND_QUIETLY TRUE)
-find_package(CUDA 4.1)
+find_package(CUDA 4)

 if(CUDA_FOUND)
 	message(STATUS "Found CUDA Toolkit v${CUDA_VERSION_STRING}")


Revert "[Conf] The ZeroMQ header file is zmq.h, not zmq.hpp"

This reverts commit 0a1f826f785d9031aa8cbddf317ecb46a75feba8.

--- config/FindZeroMQ.cmake
+++ config/FindZeroMQ.cmake
@@ -18,14 +18,14 @@
 #  ZeroMQ_INCLUDE_DIR        The location of ZeroMQ headers

 find_path (ZeroMQ_ROOT_DIR
-  NAMES include/zmq.h)
+  NAMES include/zmq.hpp)

 find_library (ZeroMQ_LIBRARIES
   NAMES zmq
   HINTS ${ZeroMQ_ROOT_DIR}/lib)

 find_path (ZeroMQ_INCLUDE_DIR
-  NAMES zmq.h
+  NAMES zmq.hpp
   HINTS ${ZeroMQ_ROOT_DIR}/include)

 #


Stop CMake when failed to find one of required library

--- macros.cmake
+++ macros.cmake
@@ -142,9 +142,13 @@
 # Use pkg-config to find Linux libraries and update compiler/linker variables.
 macro(FIND_LINUX_LIBRARIES libraries)
   # Read pkg-config info into variables.
-  execute_process(COMMAND pkg-config --cflags ${libraries} OUTPUT_VARIABLE FLL_CFLAGS)
-  execute_process(COMMAND pkg-config --libs-only-L --libs-only-other ${libraries} OUTPUT_VARIABLE FLL_LDFLAGS)
-  execute_process(COMMAND pkg-config --libs-only-l ${libraries} OUTPUT_VARIABLE FLL_LIBS)
+  execute_process(COMMAND pkg-config --cflags ${libraries} OUTPUT_VARIABLE FLL_CFLAGS RESULT_VARIABLE RV_CFLAGS)
+  execute_process(COMMAND pkg-config --libs-only-L --libs-only-other ${libraries} OUTPUT_VARIABLE FLL_LDFLAGS RESULT_VARIABLE RV_LDFLAGS)
+  execute_process(COMMAND pkg-config --libs-only-l ${libraries} OUTPUT_VARIABLE FLL_LIBS RESULT_VARIABLE RV_LIBS)
+
+  if((NOT RV_CFLAGS EQUAL 0) OR (NOT RV_LDFLAGS EQUAL 0) OR (NOT RV_LIBS EQUAL 0))
+    message(FATAL_ERROR "Failed to find one of these libraries: ${libraries'")
+  endif()

   # Strip leading and trailing whitepspace.
   STRING(STRIP "${FLL_CFLAGS}"  FLL_CFLAGS)


Libraries now specify which external libs they depend on

--- tools/cmake/ANHLibrary.cmake
+++ tools/cmake/ANHLibrary.cmake
@@ -121,6 +121,22 @@
     IF(UNIX)
         SET_TARGET_PROPERTIES(${name} PROPERTIES COMPILE_FLAGS -fPIC)
     ENDIF()
+
+    IF(_debug_list_length GREATER 0)
+        FOREACH(debug_library ${ANHLIB_DEBUG_LIBRARIES})
+            if (NOT ${debug_library} MATCHES ".*NOTFOUND")
+                TARGET_LINK_LIBRARIES(${name} debug ${debug_library})
+            endif()
+        ENDFOREACH()
+    ENDIF()
+
+    IF(_optimized_list_length GREATER 0)
+        FOREACH(optimized_library ${ANHLIB_OPTIMIZED_LIBRARIES})
+            if (NOT ${optimized_library} MATCHES ".*NOTFOUND")
+                TARGET_LINK_LIBRARIES(${name} optimized ${optimized_library})
+            endif()
+        ENDFOREACH()
+    ENDIF()

     IF(_tests_list_length GREATER 0)
         # Create an executable for the test and link it to gtest and anh